Skip to content

Commit

Permalink
Revert "Commit from GitHub Actions (Frontend PR validation)"
Browse files Browse the repository at this point in the history
This reverts commit 106a590.
  • Loading branch information
Samuel-Therrien-Beslogic committed Nov 14, 2024
1 parent f015089 commit ea40b43
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 8 deletions.
6 changes: 5 additions & 1 deletion canopeum_frontend/.eslintrc.cjs
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,11 @@ module.exports = {
],
],
},
],




],
// Using Bootraps directly without a React wrapper
// will cause us to have to add classes to React Components
'react/forbid-component-props': 'off',
Expand Down
11 changes: 6 additions & 5 deletions canopeum_frontend/src/components/Navbar.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -51,24 +51,25 @@ const Navbar = () => {
const location = useLocation()

const handleChangeLanguage = () => {
const newLanguage = currentLanguage === 'en'
? 'fr'
: 'en'
const newLanguage = currentLanguage === 'en' ? 'fr' : 'en'
setCurrentLanguage(newLanguage)
void changeLanguage(newLanguage)
}

const { isAuthenticated, logout } = useContext(AuthenticationContext)
const navigate = useNavigate()

const onLoginLogoutbuttonClick = useCallback(() => {
const onLoginLogoutbuttonClick = (useCallback(() => {
if (isAuthenticated) {
logout()
} else {
navigate(appRoutes.login)
}
}, [isAuthenticated, navigate, logout])
}, [isAuthenticated, navigate, logout]))




return (
<nav className='navbar sticky-top navbar-expand-lg navbar-dark bg-primary'>
<div className='container-fluid'>
Expand Down
1 change: 0 additions & 1 deletion canopeum_frontend/src/components/settings/AdminCard.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@ const AdminCard = ({ admin }: Props) => (
{admin.sites.map(site => (
<div className='d-flex align-items-center text-primary' key={site.id}>
{

/* See TODO
<span className='material-symbols-outlined'>
{getSiteTypeIconKey(site.siteType.id)}
Expand Down
1 change: 0 additions & 1 deletion canopeum_frontend/src/utils/arrayUtils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,6 @@ export const mapSum = <
values.reduce(
(previous, current) =>
previous + (

/* total-functions/no-unsafe-type-assertion --
The retriction using KeysWithValsOfType ensures the value obtained from the key is of known
type. We don't want the the objects to be restricted to *only* those value types */
Expand Down

0 comments on commit ea40b43

Please sign in to comment.