on master help sign in
Merge branch 'master' into gen-keyfile-improvements
commit133c3076d890f2246565e40b18f23c849aeb2ea3 authorChris Johnson <chris@cjohnson.io> dateWed 27 Mar 2019, 15:05 (8 years ago) parent05c1914ee3c56d
6 files changed+32−5
README.md+4 src/Bridge.js+6−1 src/components/DropdownItem.js+1−1 src/components/RenderedPoint.js+12−2 src/style/extend.css+8 src/views/Network.js+1−1
README.md+4
@@ -104,6 +104,10 @@ Chrome by pasting the following into the URL bar:
104104chrome://flags/#allow-insecure-localhost
105105```
106106
107+In Firefox, you may need to allow connecting to the unsecured local node
108+websocket. Do this by going to `about:config` and setting the
109+`network.websocket.allowInsecureFromHTTPS` flag to `true`.
110+
107111Additionally you need to run with the `HTTPS` environment variable set to
108112`true`. Note that `npm run pilot` will handle this automatically.
109113
src/Bridge.js+6−1
@@ -76,6 +76,12 @@ class Bridge extends React.Component {
7676 }
7777
7878 componentDidMount() {
79+ window.history.pushState(null, null, null);
80+
81+ window.onpopstate = (e) => {
82+ window.history.pushState(null, null, null);
83+ this.popRoute();
84+ }
7985
8086 // NB (jtobin):
8187 //
@@ -275,7 +281,6 @@ class Bridge extends React.Component {
275281
276282 <Footer />
277283 </Col>
278− <Col className='col-md-1' />
279284 </Row>
280285 </Container>
281286 )
src/components/DropdownItem.js+1−1
@@ -12,7 +12,7 @@ const DropdownItem = props => {
1212 <button
1313 disabled={props.disabled}
1414 style={props.style}
15− className={`h-10 m-0 p-0 ph-2 bg-white flex items-start bs-solid brw-2 blw-2 btw-0 bbw-0 sans ${_disabled} ${props.className}`}
15+ className={`h-10 m-0 p-0 ph-2 bg-white flex align-center items-start bs-solid brw-2 blw-2 btw-0 bbw-0 sans ${_disabled} ${props.className}`}
1616 onClick={props.onClick}>
1717 { props.children }
1818 </button>
src/components/RenderedPoint.js+12−2
@@ -20,10 +20,20 @@ const RenderedPoint = (props) => {
2020
2121 return (
2222 <Col className={'col-md-3 mb-8'} key={ `rendered-${point}` }>
23− <div key={ `rendered-sigil-${point}` }>
23+ <div key={ `rendered-sigil-${point}` }
24+ className="clickable"
25+ onClick={ () => {
26+ setPointCursor(Maybe.Just(point))
27+ routeHandler(ROUTE_NAMES.SHIP)
28+ }}>
2429 { sigil }
2530 </div>
26− <div key={ `rendered-name-${point}` }>
31+ <div key={ `rendered-name-${point}` }
32+ className="clickable"
33+ onClick={ () => {
34+ setPointCursor(Maybe.Just(point))
35+ routeHandler(ROUTE_NAMES.SHIP)
36+ }}>
2737 <code>{ name }</code>
2838 </div>
2939 <div key={ `rendered-deets-${point}` }>
src/style/extend.css+8
@@ -455,3 +455,11 @@ code {
455455.align-baseline {
456456 align-items: baseline;
457457}
458+
459+.align-center {
460+ align-items: center;
461+}
462+
463+.clickable {
464+ cursor: pointer;
465+}
src/views/Network.js+1−1
@@ -45,7 +45,7 @@ class Network extends React.Component {
4545 if (network === NETWORK_NAMES.LOCAL) {
4646 setNetworkType(network)
4747
48− const endpoint = 'wss://localhost:8545'
48+ const endpoint = 'ws://localhost:8545'
4949 const provider = new Web3.providers.WebsocketProvider(endpoint)
5050 const web3 = new Web3(provider)
5151 const contracts = azimuth.initContracts(web3, CONTRACT_ADDRESSES.DEV)