diff --git a/components/Card.module.css b/components/Card.module.css new file mode 100644 index 00000000..b34c043a --- /dev/null +++ b/components/Card.module.css @@ -0,0 +1,66 @@ +.cardTitle{ + font-size: 37px; + font-weight: 500; +} +.cardSun{ + width: 50px; + height: 50px; +} +.cardHeader{ + display: flex; + justify-content: space-between; + align-items: center; + padding: 25px; + width: 100%; + height: 93px; +} +.cardBodyText{ + width: 100%; + font-size: 16px; + font-weight: 400; + letter-spacing: 0.5px; + line-height: 23px; +} +.cardBody{ + display: flex; + flex-direction: column; + align-items: flex-start; + height: fit-content; + padding: 25px; + width: 100%; +} +.cardTheme{ + font-size: 15px; + font-weight: 500; +} +.cardButtonText{ + font-size: 15px; + font-weight: 500; +} +.cardButton{ + overflow: hidden; + display: flex; + align-items: center; + width: fit-content; + height: fit-content; + padding: 10px; + border-radius: 5px; +} +.cardFooter{ + overflow: hidden; + display: flex; + justify-content: space-between; + align-items: center; + height: fit-content; + padding: 25px; + width: 100%; +} +.cardComponent{ + overflow: hidden; + display: flex; + flex-direction: column; + align-items: flex-start; + height: fit-content; + border-radius: 20px; + width: 360px; +} \ No newline at end of file diff --git a/components/Card.tsx b/components/Card.tsx new file mode 100644 index 00000000..68b3eaf1 --- /dev/null +++ b/components/Card.tsx @@ -0,0 +1,139 @@ +import styles from "./Card.module.css"; +import sunImage from "./sunImage.svg"; +import sun from "./sun.svg"; + +export const Card = ({ + override, + mode, +}: { + override?: React.CSSProperties; + mode: string; +}) => { + const titleMode = + mode === "Dark" + ? { + color: "rgb(255, 255, 255)", + } + : { + color: "rgb(0, 0, 0)", + }; + const bodyTextMode = + mode === "Dark" + ? { + color: "rgb(255, 255, 255)", + } + : { + color: "rgb(0, 0, 0)", + }; + const themeMode = + mode === "Dark" + ? { + color: "rgb(255, 255, 255)", + } + : { + color: "rgb(0, 0, 0)", + }; + const buttonTextMode = + mode === "Dark" + ? { + color: "rgb(0, 0, 0)", + } + : { + color: "rgb(255, 255, 255)", + }; + const buttonMode = + mode === "Dark" + ? { + backgroundColor: "rgb(255, 255, 255)", + } + : { + backgroundColor: "rgb(7, 14, 19)", + }; + const cardMode = + mode === "Dark" + ? { + backgroundColor: "rgb(7, 14, 19)", + } + : { + backgroundColor: "rgb(255, 255, 255)", + }; + let sunSrc; + if (mode === "Light") { + sunSrc = sunImage; + } else { + sunSrc = sun; + } + return ( +
+ + + +
+ ); +}; + +const CardHeader = ({ titleMode, sunSrc }: any) => ( +
+

+ Trends +

+ +
+); + +const CardBodyText = ({ bodyTextMode }: any) => ( +
+

+ Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod + tempor incididun... +

+
+); + +const CardFooter = ({ themeMode, buttonMode, buttonTextMode }: any) => ( +
+

+ Theme +

+
+

+ Click me! +

+
+
+); diff --git a/components/CardPage.tsx b/components/CardPage.tsx new file mode 100644 index 00000000..8c99b42b --- /dev/null +++ b/components/CardPage.tsx @@ -0,0 +1,11 @@ +import { Card } from "./Card"; +export const CardPage = ({ override }: { override?: React.CSSProperties }) => { + return ( + + ); +}; diff --git a/components/sun.svg b/components/sun.svg new file mode 100644 index 00000000..3b44e256 --- /dev/null +++ b/components/sun.svg @@ -0,0 +1,4 @@ + + + + diff --git a/components/sunImage.svg b/components/sunImage.svg new file mode 100644 index 00000000..3e84712e --- /dev/null +++ b/components/sunImage.svg @@ -0,0 +1,4 @@ + + + +