Skip to content

Commit

Permalink
🎨 Format: apply prettier
Browse files Browse the repository at this point in the history
  • Loading branch information
ilp-sys committed Apr 10, 2024
1 parent 722859a commit c9a0a44
Show file tree
Hide file tree
Showing 9 changed files with 276 additions and 303 deletions.
2 changes: 1 addition & 1 deletion aeye/app/(nav)/cams/page.tsx
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
export default function Cams() {
return <div></div>;
return <div></div>;
}
102 changes: 51 additions & 51 deletions aeye/app/(nav)/home/page.tsx
Original file line number Diff line number Diff line change
@@ -1,62 +1,62 @@
'use client'
"use client";

import * as React from 'react';
import { styled, alpha } from '@mui/material/styles';
import SearchIcon from '@mui/icons-material/Search';
import InputBase from '@mui/material/InputBase';
import * as React from "react";
import { styled, alpha } from "@mui/material/styles";
import SearchIcon from "@mui/icons-material/Search";
import InputBase from "@mui/material/InputBase";

const Search = styled('div')(({ theme }) => ({
position: 'relative',
borderRadius: theme.shape.borderRadius,
backgroundColor: '#efefef',
'&:hover': {
backgroundColor: alpha(theme.palette.common.white, 0.25),
},
marginLeft: 0,
width: '100%',
[theme.breakpoints.up('sm')]: {
marginLeft: theme.spacing(1),
width: 'auto',
},
const Search = styled("div")(({ theme }) => ({
position: "relative",
borderRadius: theme.shape.borderRadius,
backgroundColor: "#efefef",
"&:hover": {
backgroundColor: alpha(theme.palette.common.white, 0.25),
},
marginLeft: 0,
width: "100%",
[theme.breakpoints.up("sm")]: {
marginLeft: theme.spacing(1),
width: "auto",
},
}));

const SearchIconWrapper = styled('div')(({ theme }) => ({
padding: theme.spacing(0, 2),
height: '100%',
position: 'absolute',
pointerEvents: 'none',
display: 'flex',
alignItems: 'center',
justifyContent: 'center',
const SearchIconWrapper = styled("div")(({ theme }) => ({
padding: theme.spacing(0, 2),
height: "100%",
position: "absolute",
pointerEvents: "none",
display: "flex",
alignItems: "center",
justifyContent: "center",
}));

const StyledInputBase = styled(InputBase)(({ theme }) => ({
color: 'inherit',
width: '100%',
'& .MuiInputBase-input': {
padding: theme.spacing(1, 1, 1, 0),
// vertical padding + font size from searchIcon
paddingLeft: `calc(1em + ${theme.spacing(4)})`,
transition: theme.transitions.create('width'),
[theme.breakpoints.up('sm')]: {
width: '12ch',
'&:focus': {
width: '20ch',
},
},
},
color: "inherit",
width: "100%",
"& .MuiInputBase-input": {
padding: theme.spacing(1, 1, 1, 0),
// vertical padding + font size from searchIcon
paddingLeft: `calc(1em + ${theme.spacing(4)})`,
transition: theme.transitions.create("width"),
[theme.breakpoints.up("sm")]: {
width: "12ch",
"&:focus": {
width: "20ch",
},
},
},
}));

export default function Home() {
return (
<Search>
<SearchIconWrapper>
<SearchIcon />
</SearchIconWrapper>
<StyledInputBase
placeholder="Search…"
inputProps={{ 'aria-label': 'search' }}
/>
</Search>
);
return (
<Search>
<SearchIconWrapper>
<SearchIcon />
</SearchIconWrapper>
<StyledInputBase
placeholder="Search…"
inputProps={{ "aria-label": "search" }}
/>
</Search>
);
}
20 changes: 8 additions & 12 deletions aeye/app/(nav)/layout.tsx
Original file line number Diff line number Diff line change
@@ -1,14 +1,10 @@
import Navbar from '@/app/components/Navbar'
import Navbar from "@/app/components/Navbar";

export default function NavLayout({
children,
}: {
children: React.ReactNode
}) {
return (
<>
<Navbar />
<div>{children}</div>
</>
);
export default function NavLayout({ children }: { children: React.ReactNode }) {
return (
<>
<Navbar />
<div>{children}</div>
</>
);
}
59 changes: 26 additions & 33 deletions aeye/app/(nav)/my/page.tsx
Original file line number Diff line number Diff line change
@@ -1,23 +1,16 @@
'use client'
"use client";

import React, { useState } from "react";
import { styled } from '@mui/material/styles';
import {
Box,
Grid,
Paper,
Avatar,
Tooltip,
Typography
} from "@mui/material";
import React, { useEffect, useState } from "react";
import { styled } from "@mui/material/styles";
import { Box, Grid, Paper, Avatar, Tooltip, Typography } from "@mui/material";

const Item = styled(Paper)(({ theme }) => ({
backgroundColor: theme.palette.mode === 'dark' ? '#1A2027' : '#fff',
...theme.typography.body2,
padding: theme.spacing(1),
textAlign: 'center',
color: theme.palette.text.secondary,
margin: theme.spacing(1),
backgroundColor: theme.palette.mode === "dark" ? "#1A2027" : "#fff",
...theme.typography.body2,
padding: theme.spacing(1),
textAlign: "center",
color: theme.palette.text.secondary,
margin: theme.spacing(1),
}));

type Member = {
Expand Down Expand Up @@ -87,19 +80,19 @@ function ProfileAvatar() {
}

export default function MyPage() {
return (
<Box sx={{ flexGrow: 1 }}>
<Grid container spacing={4}>
<Grid item xs={12} md={8} lg={9} container direction="column">
<ProfileAvatar />
<Grid item>
<Item>xs=8</Item>
</Grid>
<Grid item>
<Item>xs=4</Item>
</Grid>
</Grid>
</Grid>
</Box>
);
};
return (
<Box sx={{ flexGrow: 1 }}>
<Grid container spacing={4}>
<Grid item xs={12} md={8} lg={9} container direction="column">
<ProfileAvatar />
<Grid item>
<Item>itme1</Item>
</Grid>
<Grid item>
<Item>item2</Item>
</Grid>
</Grid>
</Grid>
</Box>
);
}
4 changes: 1 addition & 3 deletions aeye/app/(nav)/stat/page.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
export default function Stat() {
return (
<div>stat page</div>
);
return <div>stat page</div>;
}
Loading

0 comments on commit c9a0a44

Please sign in to comment.