@@ -18,8 +18,6 @@ import Notify from './components/notify/Notify.js'
1818import Connected from './components/connected/Connected.js'
1919import TourHelper from './components/tour/TourHelper.js'
2020import FilesExploreForm from './files/explore-form/files-explore-form.tsx'
21- import { ThemeProvider , ThemeContext } from './context/theme-provider.tsx'
22- import { ThemeToggle } from './components/theme-toggle/toggle.tsx'
2321
2422export class App extends Component {
2523 static propTypes = {
@@ -34,8 +32,6 @@ export class App extends Component {
3432 isOver : PropTypes . bool . isRequired
3533 }
3634
37- static contextType = ThemeContext
38-
3935 constructor ( props ) {
4036 super ( props )
4137 props . doSetupLocalStorage ( )
@@ -67,49 +63,44 @@ export class App extends Component {
6763 render ( ) {
6864 const { t, route : Page , ipfsReady, doFilesNavigateTo, routeInfo : { url } , connectDropTarget, canDrop, isOver, showTooltip } = this . props
6965 return connectDropTarget (
70- < div >
71- < ThemeProvider >
72- { /* eslint-disable-next-line jsx-a11y/click-events-have-key-events, jsx-a11y/no-static-element-interactions */ }
73- < div className = 'sans-serif h-100 relative' onClick = { getNavHelper ( this . props . doUpdateUrl ) } >
74- { /* Tinted overlay that appears when dragging and dropping an item */ }
75- { canDrop && isOver && < div className = 'h-100 top-0 right-0 fixed appOverlay' style = { { background : 'rgba(99, 202, 210, 0.2)' } } /> }
76- < div className = 'flex flex-row-reverse-l flex-column-reverse justify-end justify-start-l' style = { { minHeight : '100vh' } } >
77- < div className = 'flex-auto-l' >
78- < div className = 'flex items-center ph3 ph4-l webui-header' style = { { WebkitAppRegion : 'drag' , height : 75 , background : '#F0F6FA' , paddingTop : '20px' , paddingBottom : '15px' } } >
79- < div className = 'joyride-app-explore' style = { { width : 560 } } >
80- < FilesExploreForm onBrowse = { doFilesNavigateTo } />
81- </ div >
82- < div className = 'dn flex-ns flex-auto items-center justify-end' >
83- < TourHelper />
84- < Connected className = 'joyride-app-status' />
85- < div className = 'pa3' >
86- < ThemeToggle />
87- </ div >
88- </ div >
89- </ div >
90- < main className = 'bg-white pv3 pa3 pa4-l' >
91- { ( ipfsReady || url === '/welcome' || url . startsWith ( '/settings' ) )
92- ? < Page />
93- : < ComponentLoader />
94- }
95- </ main >
66+ // eslint-disable-next-line jsx-a11y/click-events-have-key-events, jsx-a11y/no-static-element-interactions
67+ < div className = 'sans-serif h-100 relative' onClick = { getNavHelper ( this . props . doUpdateUrl ) } >
68+ { /* Tinted overlay that appears when dragging and dropping an item */ }
69+ { canDrop && isOver && < div className = 'h-100 top-0 right-0 fixed appOverlay' style = { { background : 'rgba(99, 202, 210, 0.2)' } } /> }
70+ < div className = 'flex flex-row-reverse-l flex-column-reverse justify-end justify-start-l' style = { { minHeight : '100vh' } } >
71+ < div className = 'flex-auto-l' >
72+ < div className = 'flex items-center ph3 ph4-l' style = { { WebkitAppRegion : 'drag' , height : 75 , background : '#F0F6FA' , paddingTop : '20px' , paddingBottom : '15px' } } >
73+ < div className = 'joyride-app-explore' style = { { width : 560 } } >
74+ < FilesExploreForm onBrowse = { doFilesNavigateTo } />
9675 </ div >
97- < div className = 'navbar-container flex-none-l bg-navy' >
98- < NavBar />
76+ < div className = 'dn flex-ns flex-auto items-center justify-end' >
77+ < TourHelper />
78+ < Connected className = 'joyride-app-status' />
9979 </ div >
10080 </ div >
101- < ReactJoyride
102- run = { showTooltip }
103- steps = { appTour . getSteps ( { t } ) }
104- styles = { appTour . styles }
105- callback = { this . handleJoyrideCb }
106- scrollToFirstStep
107- disableOverlay
108- locale = { getJoyrideLocales ( t ) }
109- />
110- < Notify />
81+ < main className = 'bg-white pv3 pa3 pa4-l' >
82+ { ( ipfsReady || url === '/welcome' || url . startsWith ( '/settings' ) )
83+ ? < Page />
84+ : < ComponentLoader />
85+ }
86+ </ main >
87+ </ div >
88+ < div className = 'navbar-container flex-none-l bg-navy' >
89+ < NavBar />
11190 </ div >
112- </ ThemeProvider >
91+ </ div >
92+
93+ < ReactJoyride
94+ run = { showTooltip }
95+ steps = { appTour . getSteps ( { t } ) }
96+ styles = { appTour . styles }
97+ callback = { this . handleJoyrideCb }
98+ scrollToFirstStep
99+ disableOverlay
100+ locale = { getJoyrideLocales ( t ) }
101+ />
102+
103+ < Notify />
113104 </ div >
114105 )
115106 }
0 commit comments