From 7fc31f6a262b4435bc5512fafe7bdaf1d4d0e76f Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Dandelion=20Man=C3=A9?=
Date: Thu, 10 May 2018 14:49:00 -0700
Subject: [PATCH] Add `PagerankTable` for exploring PageRank results (#264)
`PagerankTable` is forked from `ContributionList`.
Test plan: I took it for a spin and it seemed OK. I'm not inclined to
write formal tests because we are in rapid prototyping mode stil.
---
src/app/credExplorer/App.js | 42 ++-----
src/app/credExplorer/pagerankTable.js | 151 ++++++++++++++++++++++++++
2 files changed, 161 insertions(+), 32 deletions(-)
create mode 100644 src/app/credExplorer/pagerankTable.js
diff --git a/src/app/credExplorer/App.js b/src/app/credExplorer/App.js
index 4ecbf89..e88b7be 100644
--- a/src/app/credExplorer/App.js
+++ b/src/app/credExplorer/App.js
@@ -1,19 +1,20 @@
// @flow
-import stringify from "json-stable-stringify";
import React from "react";
import {StyleSheet, css} from "aphrodite/no-important";
import {Graph} from "../../core/graph";
-import type {PagerankResult} from "./basicPagerank";
import basicPagerank from "./basicPagerank";
import LocalStore from "./LocalStore";
+import type {PagerankResult} from "./basicPagerank";
+import {PagerankTable} from "./pagerankTable";
type Props = {};
type State = {
repoOwner: string,
repoName: string,
graph: ?Graph,
+ pagerankResult: ?PagerankResult,
};
const REPO_OWNER_KEY = "repoOwner";
@@ -26,6 +27,7 @@ export default class App extends React.Component {
repoOwner: "",
repoName: "",
graph: null,
+ pagerankResult: null,
};
}
@@ -44,6 +46,10 @@ export default class App extends React.Component {