@@ -2,7 +2,6 @@ import React from 'react'
22import {
33 majorScale ,
44 minorScale ,
5- Link ,
65 Pane ,
76 Text ,
87 StatusIndicator
@@ -11,15 +10,16 @@ import {
1110import { initIPFS , initOrbitDB , getAllDatabases } from '../database'
1211import { actions , useStateValue } from '../state'
1312
13+ import ConnectToWalletButton from './ConnectToWalletButton'
14+
1415function Systems ( ) {
1516 const [ appState , dispatch ] = useStateValue ( )
1617
17-
1818 React . useEffect ( ( ) => {
1919 dispatch ( { type : actions . PROGRAMS . SET_PROGRAMS_LOADING , loading : true } )
2020
2121 initIPFS ( ) . then ( async ( ipfs ) => {
22- dispatch ( { type : actions . SYSTEMS . SET_IPFS , ipfsStatus : 'Started' } )
22+ dispatch ( { type : actions . SYSTEMS . SET_IPFS , ipfsStatus : 'Started' } )
2323
2424 initOrbitDB ( ipfs ) . then ( async ( databases ) => {
2525 dispatch ( { type : actions . SYSTEMS . SET_ORBITDB , orbitdbStatus : 'Started' } )
@@ -32,38 +32,35 @@ function Systems () {
3232 } , [ dispatch ] )
3333
3434 return (
35-
3635 < Pane background = 'white' elevation = { 1 } >
37- < Pane
36+ < Pane
3837 display = 'flex'
39- flexDirection = 'column '
38+ flexDirection = 'row '
4039 alignItems = 'left'
4140 paddingX = { majorScale ( 6 ) }
4241 paddingY = { majorScale ( 1 ) }
4342 >
44- < Link href = '#/' textDecoration = 'none' display = 'flex' flexDirection = 'row' >
45- < Text fontWeight = '600' marginRight = { minorScale ( 1 ) } > Systems:</ Text >
46- < Pane
47- display = 'flex'
48- alignItems = 'center'
49- marginX = { minorScale ( 1 ) }
50- >
51- { appState . ipfsStatus === 'Started'
52- ? < StatusIndicator color = "success" > IPFS</ StatusIndicator >
53- : < StatusIndicator color = "warning" > IPFS</ StatusIndicator >
54- }
55- </ Pane >
56- < Pane
43+ < Pane display = 'flex' flexDirection = 'row' width = '100%' >
44+ < Text
5745 display = 'flex'
5846 alignItems = 'center'
59- marginX = { majorScale ( 1 ) }
47+ fontWeight = '600'
48+ marginRight = { minorScale ( 1 ) }
6049 >
61- { appState . orbitdbStatus === 'Started'
62- ? < StatusIndicator color = "success" > OrbitDB</ StatusIndicator >
63- : < StatusIndicator color = "warning" > OrbitDB</ StatusIndicator >
64- }
65- </ Pane >
66- </ Link >
50+ Systems:
51+ </ Text >
52+ {
53+ appState . ipfsStatus === 'Started'
54+ ? < StatusIndicator color = 'success' > IPFS</ StatusIndicator >
55+ : < StatusIndicator color = 'warning' > IPFS</ StatusIndicator >
56+ }
57+ {
58+ appState . orbitdbStatus === 'Started'
59+ ? < StatusIndicator color = 'success' > OrbitDB</ StatusIndicator >
60+ : < StatusIndicator color = 'warning' > OrbitDB</ StatusIndicator >
61+ }
62+ < ConnectToWalletButton style = { { marginLeft : 'auto' } } />
63+ </ Pane >
6764 </ Pane >
6865 </ Pane >
6966 )
0 commit comments