Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

User authentication #333

Draft
wants to merge 26 commits into
base: main
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
26 commits
Select commit Hold shift + click to select a range
35acc08
adding user add/update/verify functionality
PhillipsOwen Nov 26, 2024
cf35e99
adding a secure random number generator
PhillipsOwen Nov 27, 2024
164b54b
adding paths to the branding and auth locations
PhillipsOwen Nov 27, 2024
e32dadb
adding a default background image
PhillipsOwen Nov 27, 2024
101977a
adding a default background image
PhillipsOwen Nov 27, 2024
ac97dcc
shifting the location of logging out and user profile updating to the…
PhillipsOwen Nov 27, 2024
3392139
completing add user functionality
PhillipsOwen Nov 27, 2024
e6743a5
making the form submit when the enter key is pressed, tidying up
PhillipsOwen Nov 27, 2024
551bab1
exporting the branding so i can use it on the login page
PhillipsOwen Nov 27, 2024
6979264
adding buttins for user profile updating
PhillipsOwen Nov 27, 2024
485c54f
tidying up
PhillipsOwen Nov 27, 2024
b3e8bf1
adding branding, tidying up
PhillipsOwen Nov 27, 2024
7eaa2bf
fixing the way the user profile is saved, tidying up
PhillipsOwen Nov 27, 2024
581bb11
altering the way that user profile is checked (cookie)
PhillipsOwen Nov 27, 2024
c232d32
moving away from local storage, now using cookies
PhillipsOwen Nov 27, 2024
b7918e6
tidying up
PhillipsOwen Nov 27, 2024
9bf59ee
adding some reformatting, validations
PhillipsOwen Jan 3, 2025
69edeca
adding some reformatting, validations
PhillipsOwen Jan 3, 2025
f85b342
updating to remove vulnerabilities
PhillipsOwen Jan 3, 2025
4a2824f
no longer used
PhillipsOwen Jan 3, 2025
f2153ad
refactoring for clarity, making the page a form
PhillipsOwen Jan 3, 2025
c2a4a04
adding some reformatting, adding validations
PhillipsOwen Jan 3, 2025
6dc0841
Merge branch 'main' of https://github.com/RENCI/APSViz-UI-V3 into use…
PhillipsOwen Jan 21, 2025
d37d27c
Merge branch 'main' of https://github.com/RENCI/APSViz-UI-V3 into use…
PhillipsOwen Jan 21, 2025
b56bac0
removing the state branch from the json metadata
PhillipsOwen Jan 23, 2025
46edf7d
adding guest login
PhillipsOwen Jan 24, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
81 changes: 71 additions & 10 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 6 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -72,22 +72,28 @@
"dotenv": "^16.4.5",
"geostyler-sld-parser": "^6.1.2",
"html-to-image": "^1.11.11",
"isaac": "^0.0.5",
"leaflet": "^1.9.4",
"mapbox-gl": "^3.7.0",
"prop-types": "^15.8.1",
"react": "^18.3.1",
"react-beautiful-dnd": "^13.1.1",
"react-cookie": "^7.2.2",
"react-dom": "^18.3.1",
"react-draggable": "^4.4.6",
"react-leaflet": "^4.2.1",
"react-map-gl": "^7.1.7",
"react-native-bcrypt": "^2.4.0",
"react-query": "^3.39.3",
"react-resizable": "^3.0.5",
"react-router-dom": "^6.26.2",
"recharts": "^2.12.7",
"stream": "^0.0.3",
"ws": "^8.18.0"
},
"browser": {
"crypto": false
},
"overrides": {
"json5": "^2.2.2",
"lodash": "^4.17.11",
Expand Down
17 changes: 10 additions & 7 deletions src/app.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import React, { Fragment } from 'react';
import { BrowserRouter, Route, Routes } from "react-router-dom";
import { Map } from '@components/map';
import { ObservationDialog } from "@components/dialog/observation-dialog";
import { ObservationDialog } from "@dialog/observation-dialog";
import { useLayers } from '@context';
import { Sidebar } from '@components/sidebar';
import { ControlPanel } from '@components/control-panel';
Expand All @@ -10,6 +10,7 @@ import { MapLegend } from '@components/legend';
import { AlertUser } from '@components/alert-user';
import { Config } from '@components/config';
import { Acknowledgements } from "@components/acknowledgements";
import { Login, AddUser, AuthProvider, ProtectedRoute } from '@auth';

/**
* renders the main content
Expand Down Expand Up @@ -57,12 +58,14 @@ const Content = () => {
export const App = () => {
// render the application
return (
<Fragment>
<BrowserRouter>
<BrowserRouter>
<AuthProvider>
<Routes>
<Route path="/" element={ <Content/> } />
</Routes>
</BrowserRouter>
</Fragment>
<Route path="/" element={<ProtectedRoute><Content /></ProtectedRoute>}/>
<Route path="/login" element={<Login />} />
<Route path="/add-user" element={<AddUser />} />
</Routes>
</AuthProvider>
</BrowserRouter>
);
};
Loading