fix(frontend): build errors and warnings
This commit is contained in:
parent
a1ccd87b43
commit
d682a46f69
|
|
@ -4,6 +4,7 @@
|
|||
"@next/next/no-img-element": "off",
|
||||
"jsx-a11y/alt-text": "off",
|
||||
"react/display-name": "off",
|
||||
"react/no-unescaped-entities": 0,
|
||||
"react/jsx-max-props-per-line": [
|
||||
1,
|
||||
{
|
||||
|
|
|
|||
3271
frontend/package-lock.json
generated
3271
frontend/package-lock.json
generated
File diff suppressed because it is too large
Load Diff
|
|
@ -39,7 +39,7 @@ export const AuthGuard = (props) => {
|
|||
setChecked(true);
|
||||
}
|
||||
},
|
||||
[router.isReady]
|
||||
[router.isReady, isAuthenticated, router]
|
||||
);
|
||||
|
||||
if (!checked) {
|
||||
|
|
|
|||
|
|
@ -67,7 +67,9 @@ export const SideNav = (props) => {
|
|||
}}
|
||||
>
|
||||
<div style={{display:'flex',justifyContent:'center'}}>
|
||||
<img src="/assets/oktopus.png" width={'60%'}></img>
|
||||
<img src="/assets/oktopus.png"
|
||||
width={'60%'}
|
||||
/>
|
||||
</div>
|
||||
<SvgIcon
|
||||
fontSize="small"
|
||||
|
|
|
|||
|
|
@ -29,38 +29,32 @@ const Favicon = () => (
|
|||
</>
|
||||
);
|
||||
|
||||
const Fonts = () => (
|
||||
<>
|
||||
<link
|
||||
rel="preconnect"
|
||||
href="https://fonts.googleapis.com"
|
||||
/>
|
||||
<link
|
||||
rel="preconnect"
|
||||
href="https://fonts.gstatic.com"
|
||||
/>
|
||||
<link
|
||||
rel="stylesheet"
|
||||
href="https://fonts.googleapis.com/css2?family=Inter:wght@100;200;300;400;500;600;700;800;900&display=swap"
|
||||
/>
|
||||
<link
|
||||
rel="stylesheet"
|
||||
href="https://fonts.googleapis.com/css2?family=Roboto+Mono:wght@300;400&display=swap"
|
||||
/>
|
||||
<link
|
||||
rel="stylesheet"
|
||||
href="https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:wght@600;700&display=swap"
|
||||
/>
|
||||
</>
|
||||
);
|
||||
|
||||
class CustomDocument extends Document {
|
||||
render() {
|
||||
return (
|
||||
<Html lang="en">
|
||||
<Head>
|
||||
<Favicon />
|
||||
<Fonts />
|
||||
<link
|
||||
rel="preconnect"
|
||||
href="https://fonts.googleapis.com"
|
||||
/>
|
||||
<link
|
||||
rel="preconnect"
|
||||
href="https://fonts.gstatic.com"
|
||||
/>
|
||||
<link
|
||||
rel="stylesheet"
|
||||
href="https://fonts.googleapis.com/css2?family=Inter:wght@100;200;300;400;500;600;700;800;900&display=swap"
|
||||
/>
|
||||
<link
|
||||
rel="stylesheet"
|
||||
href="https://fonts.googleapis.com/css2?family=Roboto+Mono:wght@300;400&display=swap"
|
||||
/>
|
||||
<link
|
||||
rel="stylesheet"
|
||||
href="https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:wght@600;700&display=swap"
|
||||
/>
|
||||
</Head>
|
||||
<body>
|
||||
<Main />
|
||||
|
|
|
|||
|
|
@ -93,7 +93,11 @@ const handleOpen = () => {
|
|||
</CardContent>
|
||||
<Divider />
|
||||
<CardActions sx={{ justifyContent: 'flex-end' }}>
|
||||
<Button variant="contained" endIcon={<SvgIcon><PaperAirplane /></SvgIcon>} onClick={handleOpen}>
|
||||
<Button
|
||||
variant="contained"
|
||||
endIcon={<SvgIcon><PaperAirplane /></SvgIcon>}
|
||||
onClick={handleOpen}
|
||||
>
|
||||
Send
|
||||
</Button>
|
||||
</CardActions>
|
||||
|
|
|
|||
|
|
@ -80,7 +80,11 @@ export const OverviewLatestOrders = (props) => {
|
|||
</SeverityPill>
|
||||
</TableCell>
|
||||
<TableCell>
|
||||
<SvgIcon fontSize="small" sx={{cursor:'pointer'}} onClick={()=>router.push("devices/"+order.id)}>
|
||||
<SvgIcon
|
||||
fontSize="small"
|
||||
sx={{cursor:'pointer'}}
|
||||
onClick={()=>router.push("devices/"+order.id)}
|
||||
>
|
||||
<ArrowTopRightOnSquareIcon />
|
||||
</SvgIcon>
|
||||
</TableCell>
|
||||
|
|
|
|||
|
|
@ -24,7 +24,11 @@ function MyApp() {
|
|||
}}
|
||||
>
|
||||
{theme.palette.mode} mode
|
||||
<IconButton sx={{ ml: 1 }} onClick={colorMode.toggleColorMode} color="inherit">
|
||||
<IconButton
|
||||
sx={{ ml: 1 }}
|
||||
onClick={colorMode.toggleColorMode}
|
||||
color="inherit"
|
||||
>
|
||||
{theme.palette.mode === 'dark' ? <Brightness7Icon /> : <Brightness4Icon />}
|
||||
</IconButton>
|
||||
</Box>
|
||||
|
|
@ -39,7 +43,7 @@ export default function ToggleColorMode() {
|
|||
setMode((prevMode) => (prevMode === 'light' ? 'dark' : 'light'));
|
||||
},
|
||||
}),
|
||||
[],
|
||||
[setMode],
|
||||
);
|
||||
|
||||
const theme = React.useMemo(
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user