Streamline the cred explorer UI (#581)

This commit removes some unecessary text and whitespace from the cred
explorer. The result is more minimal. It's not super pretty, but that
will come later.

Test plan: Visual inspection
This commit is contained in:
Dandelion Mané 2018-07-31 19:59:37 -07:00 committed by GitHub
parent 48275590ba
commit 56f0b8b1b9
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 8 additions and 19 deletions

View File

@ -1,7 +1,6 @@
// @flow
import React from "react";
import {StyleSheet, css} from "aphrodite/no-important";
import type {LocalStore} from "../localStore";
import CheckedLocalStore from "../checkedLocalStore";
@ -65,15 +64,13 @@ export class App extends React.Component<Props, State> {
const {graphWithAdapters, pnd} = this.state.data;
return (
<div style={{maxWidth: "66em", margin: "0 auto", padding: "0 10px"}}>
<header className={css(styles.header)}>
<h1>Cred Explorer</h1>
</header>
<div>
<div style={{marginBottom: 10}}>
<RepositorySelect
localStore={localStore}
onChange={(selectedRepo) => this.setState({selectedRepo})}
/>
<br />
</div>
<button
disabled={selectedRepo == null}
onClick={() => this.loadData()}
@ -102,9 +99,8 @@ export class App extends React.Component<Props, State> {
});
}}
>
Run basic PageRank
Run PageRank
</button>
{graphWithAdapters ? <p>Graph loaded.</p> : <p>Graph not loaded.</p>}
<WeightConfig
localStore={localStore}
onChange={(ee) => this.setState({edgeEvaluator: ee})}
@ -139,9 +135,3 @@ export class App extends React.Component<Props, State> {
});
}
}
const styles = StyleSheet.create({
header: {
color: "#090",
},
});

View File

@ -102,8 +102,7 @@ export class PagerankTable extends React.PureComponent<
throw new Error("maxEntriesPerList not set");
}
return (
<div>
<h2>PageRank results</h2>
<div style={{marginTop: 10}}>
{this.renderFilterSelect()}
{this.renderTable()}
</div>