import React from 'react'; import { Provider } from 'react-redux'; import { useHistory, useLocation } from 'react-router'; import { HashRouter, Route } from 'react-router-dom'; import { SnackbarProvider } from 'notistack'; import { MuiThemeProvider } from '@material-ui/core/styles'; import CssBaseline from '@material-ui/core/CssBaseline'; import { unstable_createMuiStrictModeTheme as createMuiTheme } from '@material-ui/core/styles'; import { PublicKey } from '@solana/web3.js'; import { store } from './store'; import WalletProvider from './components/WalletProvider'; import Layout from './components/Layout'; import Multisig from './components/Multisig'; function App() { const theme = createMuiTheme({ palette: { background: { default: 'rgb(255,255,255)', }, }, typography: { fontFamily: ['Source Sans Pro', 'sans-serif'].join(','), }, overrides: {}, }); return ( ); } function MultisigPage() { return ( ); } export function MultisigInstancePage() { const history = useHistory(); const location = useLocation(); const path = location.pathname.split('/'); if (path.length !== 2) { history.push(`/multisig`); return <>; } else { const multisig = new PublicKey(path[1]); return ; } } export default App;