Skip to content

Commit

Permalink
fix: using PageRouter
Browse files Browse the repository at this point in the history
  • Loading branch information
jimcase committed Aug 24, 2023
1 parent 6ff1c91 commit 33f09b2
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 14 deletions.
12 changes: 3 additions & 9 deletions ui/summit-2023/src/App.tsx
Original file line number Diff line number Diff line change
@@ -1,12 +1,11 @@
import React from 'react';
import { Footer } from './components/common/Footer/Footer';
import { Route, Routes, BrowserRouter } from 'react-router-dom';

import { BrowserRouter } from 'react-router-dom';
import './App.scss';
import BackgroundPolygon1 from './common/resources/images/polygon1.svg';
import { Box, Container } from '@mui/material';
import Header from './components/common/Header/Header';
import { Home } from './pages/Home';
import {PageRouter} from './routes';

function App() {
return (
Expand All @@ -22,12 +21,7 @@ function App() {
<div className="main-content">
<Container maxWidth="xl">
<Box my={2}>
<Routes>
<Route
path="/"
element={<Home />}
/>
</Routes>
<PageRouter />
</Box>
</Container>
</div>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,18 +24,18 @@ type ConnectWalletModalProps = {
title: string;
action: boolean;
onConnectWallet: () => void;
onCloseFn: () => void;
onClose: () => void;
buttonLabel: string;
};

const ConnectWalletModal = (props: ConnectWalletModalProps) => {
const theme = useTheme();
const { name, id, openStatus, title, action, onConnectWallet, onCloseFn, buttonLabel } = props;
const { name, id, openStatus, title, action, onConnectWallet, onClose, buttonLabel } = props;

return (
<Dialog
open={openStatus}
onClose={onCloseFn}
onClose={onClose}
aria-labelledby={name}
>
<DialogTitle id={id}>{title}</DialogTitle>
Expand Down Expand Up @@ -83,7 +83,7 @@ const ConnectWalletModal = (props: ConnectWalletModalProps) => {
<DialogActions>
<Button
autoFocus
onClick={onCloseFn}
onClick={onClose}
>
{buttonLabel}
</Button>
Expand Down
2 changes: 1 addition & 1 deletion ui/summit-2023/src/components/common/Header/Header.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -171,7 +171,7 @@ const Header: React.FC = () => {

<ConnectWalletModal
openStatus={openAuthDialog}
onCloseFn={handleCloseAuthDialog}
onClose={handleCloseAuthDialog}
name="connect-wallet-list"
id="connect-wallet-list"
title="Choose your preferred wallet to connect"
Expand Down

0 comments on commit 33f09b2

Please sign in to comment.