From 931ed19f7fa4e8607c9e2f84e43e047de4cd25ae Mon Sep 17 00:00:00 2001 From: jakubmanczak Date: Sun, 11 Dec 2022 20:03:56 +0100 Subject: [PATCH] link chips --- components/Icon.tsx | 60 ++++++++++++++++++++++++++++++++++++++-- pages/index.tsx | 17 +++++++++++- styles/Index.module.scss | 35 +++++++++++++++++++++++ styles/globals.scss | 1 + 4 files changed, 110 insertions(+), 3 deletions(-) diff --git a/components/Icon.tsx b/components/Icon.tsx index 0433463..d67c12f 100644 --- a/components/Icon.tsx +++ b/components/Icon.tsx @@ -1,6 +1,9 @@ enum IconSet { Menu, Twitter, + GitHub, + YouTube, + MessageSquare, } type iconprops = { @@ -35,7 +38,6 @@ const Icon = ({ icon, width, height, ...props }: iconprops) => { ); - break; case IconSet.Twitter: return ( { ); - break; + case IconSet.GitHub: + return ( + + + + ); + case IconSet.YouTube: + return ( + + + + + ); + case IconSet.MessageSquare: + return ( + + + + ); } }; diff --git a/pages/index.tsx b/pages/index.tsx index 34b7af8..b0e2eeb 100644 --- a/pages/index.tsx +++ b/pages/index.tsx @@ -1,8 +1,9 @@ import styles from "../styles/Index.module.scss"; - import { useEffect, useState } from "react"; import { SEO } from "../components/SEO"; +import { Icon, IconSet } from "../components/Icon"; import splashes from "../data/splashes.json"; +import Link from "next/link"; const PageIndex = () => { const [splash, setSplash] = useState(""); @@ -49,6 +50,20 @@ const PageIndex = () => { +
+ + discord + + + youtube + + + twitter + + + github + +
); }; diff --git a/styles/Index.module.scss b/styles/Index.module.scss index c76545b..f856226 100644 --- a/styles/Index.module.scss +++ b/styles/Index.module.scss @@ -92,3 +92,38 @@ } } } +.chips { + display: flex; + flex-direction: row; + justify-content: center; + flex-wrap: wrap; + gap: 1rem; +} +.chip { + display: inline-flex; + text-decoration: none; + gap: 0.5rem; + align-items: center; + color: inherit; + padding: 6px 8px; + border: 1px solid var(--grey); + border-radius: 8px; + transition-duration: 100ms; + text-rendering: geometricPrecision; + // font-family: var(--fonts-bold); + // color: var(--grey); + svg { + color: var(--grey); + } + &:hover, + &:focus { + outline: none; + background: var(--black1); + border: 1px solid var(--black1); + box-shadow: var(--shadow0); + transform: scale(1.1); + svg { + color: var(--color); + } + } +} diff --git a/styles/globals.scss b/styles/globals.scss index e1c9db9..e4048d5 100644 --- a/styles/globals.scss +++ b/styles/globals.scss @@ -8,6 +8,7 @@ --grey: #444; --accent: #61f2ea; --shadow0: 0 0 1rem rgba(0, 0, 0, 0.35); + --shadow1: 0 0 8px var(--grey); --fonts-norm: "Quicksand", -apple-system, BlinkMacSystemFont, Segoe UI, Roboto, Oxygen, Ubuntu, Cantarell, Fira Sans, Droid Sans, Helvetica Neue, sans-serif; --fonts-bold: "Lexend", -apple-system, BlinkMacSystemFont, Segoe UI, Roboto,