From a0c1dedf59e489a6310e9614a7ff0ed206bea057 Mon Sep 17 00:00:00 2001 From: get Date: Tue, 30 Jan 2024 11:02:11 -0500 Subject: [PATCH] Add global components --- src/components/global/Footer.astro | 0 src/components/global/Head.astro | 23 ++++++ src/components/global/Header.astro | 108 +++++++++++++++++++++++++++++ 3 files changed, 131 insertions(+) create mode 100644 src/components/global/Footer.astro create mode 100644 src/components/global/Head.astro create mode 100644 src/components/global/Header.astro diff --git a/src/components/global/Footer.astro b/src/components/global/Footer.astro new file mode 100644 index 0000000..e69de29 diff --git a/src/components/global/Head.astro b/src/components/global/Head.astro new file mode 100644 index 0000000..2130d72 --- /dev/null +++ b/src/components/global/Head.astro @@ -0,0 +1,23 @@ +--- +const { Title, Description } = Astro.props +--- + + + + {Title} + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/src/components/global/Header.astro b/src/components/global/Header.astro new file mode 100644 index 0000000..6a82f0e --- /dev/null +++ b/src/components/global/Header.astro @@ -0,0 +1,108 @@ +--- +// Properties +const {Selected} = Astro.props + +// Icons +import {Language, Menu} from '@iconoir/vue' + +// i18n +import i18next, { t } from "i18next"; +import { Trans, HeadHrefLangs } from "astro-i18next/components"; + +// User Agent +import { useUserAgent } from "astro-useragent" +const uaString = Astro.request.headers.get("user-agent") +const { source, isMobile } = useUserAgent(uaString) + +// Properties - Selected +if (Selected === "Home") {var Select_Home = true} +else if (Selected === "Products") {var Select_Products = true} +else if (Selected === "Pricing") {var Select_Pricing = true} +else if (Selected === "Support") {var Select_Support = true} + +--- + +
+
+ + {isMobile ? + null + : + + } +
+ {t("Header.Login")} + {t("Header.SignUp")} + + + + English + Japanese + + + {isMobile ? + + + + Home + Products + Pricing + Support + + Sign Up + Login + + + : + null + } +
+
+
+ +{Select_Home ? + + : null +} +{Select_Products ? + + : null +} +{Select_Pricing ? + + : null +} +{Select_Support ? + + : null +} \ No newline at end of file