Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- import {
- Box,
- CssBaseline,
- List,
- ListItem,
- Stack,
- Typography,
- } from "@mui/material";
- export const Footer = () => {
- return (
- <Box component="footer" sx={{ height: "20rem", backgroundColor: "pink" }}>
- <Box
- sx={{
- height: "100%",
- paddingBlock: "5rem",
- paddingRight: "12rem",
- paddingLeft: "3rem",
- display: "flex",
- flexDirection: {
- xs: "column",
- md: "row",
- },
- gap: {
- xs: "1rem", // smaller gap when stacked
- md: "3rem", // larger gap when side-by-side
- },
- }}
- >
- <Box
- sx={{
- minWidth: "13rem",
- width: "13rem",
- minHeight: "4rem",
- height: "4rem",
- backgroundColor: "red",
- display: "flex",
- justifyContent: "center",
- alignItems: "center",
- }}
- >
- <Typography
- sx={{ color: "white", fontWeight: "bold", fontSize: "1.5rem" }}
- >
- Logo
- </Typography>
- </Box>
- <Box
- sx={{
- height: "100%",
- display: "flex",
- flexWrap: "wrap",
- gap: "1rem",
- overflow: "auto",
- backgroundColor: "yellow",
- }}
- >
- {[1, 2, 3, 4, 5].map((value) => (
- <Box
- key={value}
- sx={{
- width: "10rem",
- backgroundColor: "blue",
- display: "flex",
- justifyContent: "center",
- alignItems: "center",
- }}
- >
- <List>
- {[69, 420, 666].map((x) => (
- <ListItem key={x}>
- <Typography
- sx={{
- color: "white",
- fontWeight: "bold",
- fontSize: "1.5rem",
- }}
- >
- link
- </Typography>
- </ListItem>
- ))}
- </List>
- </Box>
- ))}
- </Box>
- </Box>
- </Box>
- );
- };
- export const App = () => {
- return (
- <>
- <CssBaseline />
- <Stack dir="rtl">
- <Box
- component="nav"
- sx={{ minHeight: "7.5em", backgroundColor: "olivedrab" }}
- >
- <Typography>Navbar</Typography>
- </Box>
- <Box component="main" sx={{ height: "65rem" }}>
- <Typography>Main</Typography>
- </Box>
- <Footer />
- </Stack>
- </>
- );
- };
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement