From 343fcd7bc9004c0fef3b7ad57d1bb0b9a0a3410d Mon Sep 17 00:00:00 2001 From: Nikita Karamov Date: Mon, 27 Mar 2023 19:17:35 +0200 Subject: [PATCH] Extract layout --- src/layouts/layout.astro | 56 ++++++++++++ src/pages/index.astro | 193 +++++++++++++++------------------------ 2 files changed, 130 insertions(+), 119 deletions(-) create mode 100644 src/layouts/layout.astro diff --git a/src/layouts/layout.astro b/src/layouts/layout.astro new file mode 100644 index 0000000..d740a3b --- /dev/null +++ b/src/layouts/layout.astro @@ -0,0 +1,56 @@ +--- +/*! + * © 2023 Nikita Karamov + * Licensed under AGPL v3 or later + */ +import "../styles/main.scss"; + +const { title } = Astro.props; +--- + + + + + + + {title} + + + + + + + + + + + + + + diff --git a/src/pages/index.astro b/src/pages/index.astro index 2a8636b..8bcdef0 100644 --- a/src/pages/index.astro +++ b/src/pages/index.astro @@ -3,135 +3,90 @@ * © 2023 Nikita Karamov * Licensed under AGPL v3 or later */ +import Layout from "../layouts/layout.astro"; import InstanceSelect from "../components/instance-select.astro"; import { Content as PrivacyNotice } from "./_privacy.md"; import { Content as Licence } from "./_licence.md"; -import "../styles/main.scss"; const searchParameters = new URL(Astro.request.url).searchParams; const prefilledText = searchParameters.get("text"); const prefilledInstance = searchParameters.get("instance"); --- - - - - - - - Share₂Fedi — an instance-agnostic share page for the Fediverse - - - +
+ Share2Fedi +
+
+
+ - - - - + - - - -
- Share2Fedi -
-
- - - - - - - -
- - - + +
+ +