[#40] Address search #89

Merged
mattn merged 6 commits from matt/40-batch into main 2023-02-10 14:22:49 +13:00
4 changed files with 28 additions and 35 deletions
Showing only changes of commit fe59b0c854 - Show all commits

View file

@ -1,23 +0,0 @@
import MainPage from './pages/MainPage';
import { createTheme, ThemeProvider } from '@mui/material/styles';
function App() {
const darkTheme = createTheme({
palette: {
mode: 'dark',
},
typography: {
fontFamily: 'Poppins, sans-serif',
},
});
return (
<div className="App">
<ThemeProvider theme={darkTheme}>
<MainPage />
</ThemeProvider>
</div>
);
}
export default App;

View file

@ -1,8 +0,0 @@
import { render, screen } from '@testing-library/react';
import App from './App';
test('renders learn react link', () => {
render(<App />);
const linkElement = screen.getByText(/learn react/i);
expect(linkElement).toBeInTheDocument();
});

View file

@ -1,26 +1,45 @@
import React from 'react'; import React from 'react';
import ReactDOM from 'react-dom'; import ReactDOM from 'react-dom';
import App from './App'; import { createTheme, ThemeProvider } from '@mui/material/styles';
import reportWebVitals from './reportWebVitals'; import reportWebVitals from './reportWebVitals';
import { import {
createBrowserRouter, createBrowserRouter,
RouterProvider, RouterProvider,
} from 'react-router-dom'; } from 'react-router-dom';
import MainPage from './pages/MainPage';
// Styles // Styles
import './assets/styles/main.scss'; import './assets/styles/main.scss';
import 'bootstrap/dist/css/bootstrap.min.css'; import 'bootstrap/dist/css/bootstrap.min.css';
import RegisterPage from './pages/RegisterPage';
const router = createBrowserRouter([ const router = createBrowserRouter([
{ {
path: "/", path: "/",
element: <App /> element: <MainPage />,
}, },
]) {
path: "/register",
element: <RegisterPage />,
},
]);
const darkTheme = createTheme({
palette: {
mode: 'dark',
},
typography: {
fontFamily: 'Poppins, sans-serif',
},
});
ReactDOM.render( ReactDOM.render(
<React.StrictMode> <React.StrictMode>
<div className="App">
<ThemeProvider theme={darkTheme}>
<RouterProvider router={router} /> <RouterProvider router={router} />
</ThemeProvider>
</div>
</React.StrictMode>, </React.StrictMode>,
document.getElementById('root') document.getElementById('root')
); );

View file

@ -0,0 +1,5 @@
const RegisterPage = () => {
return <></>;
};
export default RegisterPage;