@@ -1,4 +1,3 @@
1−import React from 'react';
2import { useEffect } from 'react';
1import { useEffect } from 'react';
3import { Just, Nothing } from 'folktale/maybe';
2import { Just, Nothing } from 'folktale/maybe';
4import { IndigoApp } from 'indigo-react';
3import { IndigoApp } from 'indigo-react';
@@ -26,6 +25,8 @@ import { useRollerStore } from 'store/rollerStore';
26import { Box } from '@tlon/indigo-react';
25import { Box } from '@tlon/indigo-react';
27import LoadingOverlay from 'components/L2/LoadingOverlay';
26import LoadingOverlay from 'components/L2/LoadingOverlay';
28import { useRollerPoller } from 'lib/useRollerPoller';
27import { useRollerPoller } from 'lib/useRollerPoller';
28+import { BrowserRouter, Route, Routes } from 'react-router-dom';
29+import InviteCohort from 'views/Invite/Cohort';
30const INITIAL_NETWORK_TYPE = isRopsten
31const INITIAL_NETWORK_TYPE = isRopsten
31 ? NETWORK_TYPES.ROPSTEN
32 ? NETWORK_TYPES.ROPSTEN
@@ -39,8 +40,8 @@ const IS_STUBBED = isDevelopment && SHOULD_STUB_LOCAL;
40const INITIAL_WALLET = IS_STUBBED
41const INITIAL_WALLET = IS_STUBBED
41 ? walletFromMnemonic(
42 ? walletFromMnemonic(
42− process.env.REACT_APP_DEV_MNEMONIC,
43+ process.env.REACT_APP_DEV_MNEMONIC as string,
43− process.env.REACT_APP_HD_PATH
44+ process.env.REACT_APP_HD_PATH as string
45 : undefined;
46 : undefined;
46const INITIAL_MNEMONIC = IS_STUBBED
47const INITIAL_MNEMONIC = IS_STUBBED
@@ -94,7 +95,8 @@ function Bridge() {
97− <WithErrorBoundary render={error => <GlobalErrorBoundary error={error} />}>
99+ render={(error: Error) => <GlobalErrorBoundary error={error} />}>
98 <Provider
100 <Provider
99 views={ROUTES}
101 views={ROUTES}
100 names={ROUTE_NAMES}
102 names={ROUTE_NAMES}
@@ -103,16 +105,24 @@ function Bridge() {
103 initialWallet={INITIAL_WALLET}
105 initialWallet={INITIAL_WALLET}
104 initialMnemonic={INITIAL_MNEMONIC}
106 initialMnemonic={INITIAL_MNEMONIC}
105 initialPointCursor={INITIAL_POINT_CURSOR}>
107 initialPointCursor={INITIAL_POINT_CURSOR}>
106− <IndigoApp>
108+ <BrowserRouter>
107− <ThemeProvider theme={light}>
110+ <ThemeProvider theme={light}>
108− <Router />
111+ <Router />
113+ <Route path="/" element={null} />
114+ <Route path="/point/:point">
115+ <Route path="invites" element={<InviteCohort />} />
109− </ThemeProvider>
118+ </ThemeProvider>
110− </IndigoApp>
119+ </IndigoApp>
111− <Modal show={modalText !== undefined} hide={() => setModalText()}>
120+ <Modal show={modalText !== undefined} hide={() => setModalText('')}>
112− <Box width="280px">{modalText}</Box>
121+ <Box width="280px">{modalText}</Box>
113− </Modal>
122+ </Modal>
114− <LoadingOverlay loading={loading} />
123+ <LoadingOverlay loading={loading} />
115− <Poller />
124+ <Poller />
116 </Provider>
126 </Provider>
117 </WithErrorBoundary>
127 </WithErrorBoundary>