Skip to content

Commit 9342406

Browse files
authored
Merge pull request #16 from CS-ZSC/feat/components/card
feat: `Card` component
2 parents 07ac1d4 + df7e1eb commit 9342406

File tree

2 files changed

+24
-13
lines changed

2 files changed

+24
-13
lines changed

components/ui/internal/card.tsx

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
import React from "react";
2+
import { Stack } from "@chakra-ui/react";
3+
4+
export default function Card({ children }: { children: React.ReactNode }) {
5+
return (
6+
<Stack
7+
w="full"
8+
align={"center"}
9+
justify={"center"}
10+
bgColor={"card-bg-3"}
11+
color={"white"}
12+
border="1px solid"
13+
borderColor="card-border-3"
14+
padding="var(--card-padding)"
15+
borderRadius={20}
16+
gapY={10}
17+
>
18+
{children}
19+
</Stack>
20+
);
21+
}

components/ui/internal/footer/index.tsx

Lines changed: 3 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@ import {
1313
} from "@chakra-ui/react";
1414
import Link from "next/link";
1515
import Logo from "@/components/ui/internal/logo";
16+
import Card from "@/components/ui/internal/card";
1617
import { LogoType } from "@/components/ui/internal/logo";
1718
import { useWindowType } from "@/hooks/use-window-type";
1819
import { SocialMediaLinks } from "../socialmedialinks";
@@ -41,18 +42,7 @@ export default function Footer() {
4142
const textopacity = 0.8;
4243
return (
4344
<Flex px={"var(--global-spacing)"}>
44-
<Stack
45-
w="full"
46-
align={"center"}
47-
justify={"center"}
48-
bgColor={"card-bg-3"}
49-
color={"white"}
50-
border="1px solid"
51-
borderColor="card-border-3"
52-
padding="var(--card-padding)"
53-
borderRadius={20}
54-
gapY={10}
55-
>
45+
<Card>
5646
<Logo
5747
logoType={LogoType.White}
5848
width={isDesktop ? 180 : 110}
@@ -202,7 +192,7 @@ export default function Footer() {
202192
All rights reserved to IEEE-ZSB
203193
</Text>
204194
</Stack>
205-
</Stack>
195+
</Card>
206196
</Flex>
207197
);
208198
}

0 commit comments

Comments
 (0)