From e481146bf9c61ac0be2b99511f6cf0421885ad5f Mon Sep 17 00:00:00 2001 From: prototypa Date: Sat, 13 Aug 2022 06:19:45 -0400 Subject: [PATCH] Fix format --- CODE_OF_CONDUCT.md | 22 +- .../astro/blog/BlogFeaturesFourCols.astro | 71 ++-- src/components/astro/ctas/BasicCTA.astro | 16 +- src/components/astro/faqs/FAQsBasic.astro | 27 +- .../astro/features/BasicFeatures.astro | 57 +-- .../astro/features/StepsFeatures.astro | 35 +- src/components/astro/features/StepsLeft.astro | 254 ++++++++------ .../astro/features/TwoColsFeatures.astro | 325 +++++++++--------- .../astro/footers/BasicFooter.astro | 137 ++++---- .../astro/headers/BasicHeader.astro | 59 +++- src/components/astro/hero/HeroWithImage.astro | 42 ++- src/components/astro/stats/BasicStats.astro | 48 ++- src/components/astro/utils/Picture.astro | 37 +- src/layouts/Default.astro | 16 +- src/layouts/Empty.astro | 12 +- src/pages/404.astro | 39 ++- src/pages/index.astro | 8 +- 17 files changed, 632 insertions(+), 573 deletions(-) diff --git a/CODE_OF_CONDUCT.md b/CODE_OF_CONDUCT.md index 2fbff37..8ebe5b0 100644 --- a/CODE_OF_CONDUCT.md +++ b/CODE_OF_CONDUCT.md @@ -17,23 +17,23 @@ diverse, inclusive, and healthy community. Examples of behavior that contributes to a positive environment for our community include: -* Demonstrating empathy and kindness toward other people -* Being respectful of differing opinions, viewpoints, and experiences -* Giving and gracefully accepting constructive feedback -* Accepting responsibility and apologizing to those affected by our mistakes, +- Demonstrating empathy and kindness toward other people +- Being respectful of differing opinions, viewpoints, and experiences +- Giving and gracefully accepting constructive feedback +- Accepting responsibility and apologizing to those affected by our mistakes, and learning from the experience -* Focusing on what is best not just for us as individuals, but for the +- Focusing on what is best not just for us as individuals, but for the overall community Examples of unacceptable behavior include: -* The use of sexualized language or imagery, and sexual attention or +- The use of sexualized language or imagery, and sexual attention or advances of any kind -* Trolling, insulting or derogatory comments, and personal or political attacks -* Public or private harassment -* Publishing others' private information, such as a physical or email +- Trolling, insulting or derogatory comments, and personal or political attacks +- Public or private harassment +- Publishing others' private information, such as a physical or email address, without their explicit permission -* Other conduct which could reasonably be considered inappropriate in a +- Other conduct which could reasonably be considered inappropriate in a professional setting ## Enforcement Responsibilities @@ -106,7 +106,7 @@ Violating these terms may lead to a permanent ban. ### 4. Permanent Ban **Community Impact**: Demonstrating a pattern of violation of community -standards, including sustained inappropriate behavior, harassment of an +standards, including sustained inappropriate behavior, harassment of an individual, or aggression toward or disparagement of classes of individuals. **Consequence**: A permanent ban from any sort of public interaction within diff --git a/src/components/astro/blog/BlogFeaturesFourCols.astro b/src/components/astro/blog/BlogFeaturesFourCols.astro index deffc52..1edbc7d 100644 --- a/src/components/astro/blog/BlogFeaturesFourCols.astro +++ b/src/components/astro/blog/BlogFeaturesFourCols.astro @@ -1,12 +1,12 @@ --- import Picture from "~/components/astro/utils/Picture.astro"; -const { } = Astro.props; +const {} = Astro.props; ---

- Find out more content in our Blog + Find out more content in our Blog

The blog will be used to display AstroWind documentation. Each new article will be an important step that you will @@ -16,53 +16,64 @@ const { } = Astro.props;

- -

- Get started with AstroWind -

+ +

Get started with AstroWind

I'll be sure to note that in my log. Smooth as an android's bottom, eh, Data? When has justice ever been as simple as a rule book?

- -

- How to customize the template -

+ +

How to customize the template

O for awesome, this chocka full cuzzie is as rip-off as a cracker. Meanwhile, in behind the bicycle shed, Hercules Morse.

- -

- Helpful tools and resources to design -

+ +

Helpful tools and resources to design

- Yolo ipsum dolor sit amet, consectetur adipiscing elit. Ut ac suscipit leo. Carpe diem vulputate est nec - commodo rutrum. + Yolo ipsum dolor sit amet, consectetur adipiscing elit. Ut ac suscipit leo. Carpe diem vulputate est nec commodo + rutrum.

- -

- AstroWind template in depth -

+ +

AstroWind template in depth

I'll be sure to note that in my log. Smooth as an android's bottom, eh, Data? When has justice ever been as simple as a rule book?

- -
\ No newline at end of file + diff --git a/src/components/astro/ctas/BasicCTA.astro b/src/components/astro/ctas/BasicCTA.astro index 01afe77..ca56092 100644 --- a/src/components/astro/ctas/BasicCTA.astro +++ b/src/components/astro/ctas/BasicCTA.astro @@ -1,5 +1,5 @@ --- -const { } = Astro.props; +const {} = Astro.props; ---
@@ -13,10 +13,16 @@ const { } = Astro.props; Be very surprised by these huge fake numbers you are seeing on this page.
Don't waste more time! :P

- + -
\ No newline at end of file + diff --git a/src/components/astro/faqs/FAQsBasic.astro b/src/components/astro/faqs/FAQsBasic.astro index a1f021c..22b3aec 100644 --- a/src/components/astro/faqs/FAQsBasic.astro +++ b/src/components/astro/faqs/FAQsBasic.astro @@ -1,13 +1,10 @@ --- - ---
-

- Frequently Asked Questions

@@ -16,9 +13,7 @@
-

- What do I need to start? -

+

What do I need to start?

Space, the final frontier. These are the voyages of the Starship Enterprise. Its five-year mission: to explore strange new worlds. @@ -28,17 +23,14 @@

-

- How to install the Astro + Tailwind CSS template? -

+

How to install the Astro + Tailwind CSS template?

Well, the way they make shows is, they make one show. That show's called a pilot.

Then they show that show to the people who make shows, and on the strength of that one show they decide if they're going to make more shows. Some pilots get picked and become television programs.Some don't, become - nothing. She - starred in one of the ones that became nothing. + nothing. She starred in one of the ones that became nothing.

@@ -59,19 +51,16 @@

-

- Galaxies Orion's sword globular star cluster? -

+

Galaxies Orion's sword globular star cluster?

- A business big enough that it could be listed on the NASDAQ goes belly up. Disappears!

+ A business big enough that it could be listed on the NASDAQ goes belly up. Disappears! +

It ceases to exist without me. No, you clearly don't know who you're talking to, so let me clue you in.

-

- When has justice ever been as simple as a rule book? -

+

When has justice ever been as simple as a rule book?

This is not about revenge. This is about justice. A lot of things can change in twelve years, Admiral. Well, that's certainly good to know. About four years. I got tired of hearing how young I looked. @@ -80,4 +69,4 @@

-
\ No newline at end of file +
diff --git a/src/components/astro/features/BasicFeatures.astro b/src/components/astro/features/BasicFeatures.astro index 8bb930d..242ea97 100644 --- a/src/components/astro/features/BasicFeatures.astro +++ b/src/components/astro/features/BasicFeatures.astro @@ -1,26 +1,22 @@ --- -const { } = Astro.props; +const {} = Astro.props; ---
- +
-

- Components -

-

- Most used widgets -

+

Components

+

Most used widgets

Provides frequently used components for building websites using Tailwind CSS

+ class="relative flex flex-col p-6 bg-white dark:bg-slate-900 rounded shadow-xl dark:border dark:border-slate-800" + >
@@ -35,12 +31,13 @@ const { } = Astro.props;
Headers

- Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do - eiusmod tempor incididunt ut labore et dolore. + Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et + dolore.

+ class="relative flex flex-col p-6 bg-white dark:bg-slate-900 rounded shadow-xl dark:border dark:border-slate-800" + >
@@ -56,12 +53,13 @@ const { } = Astro.props;
Footers

- Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do - eiusmod tempor incididunt ut labore et dolore. + Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et + dolore.

+ class="relative flex flex-col p-6 bg-white dark:bg-slate-900 rounded shadow-xl dark:border dark:border-slate-800" + >
@@ -76,12 +74,13 @@ const { } = Astro.props;
Features

- Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do - eiusmod tempor incididunt ut labore et dolore. + Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et + dolore.

+ class="relative flex flex-col p-6 bg-white dark:bg-slate-900 rounded shadow-xl dark:border dark:border-slate-800" + >
@@ -97,12 +96,13 @@ const { } = Astro.props;
Call-to-Action

- Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do - eiusmod tempor incididunt ut labore et dolore. + Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et + dolore.

+ class="relative flex flex-col p-6 bg-white dark:bg-slate-900 rounded shadow-xl dark:border dark:border-slate-800" + >
@@ -117,12 +117,13 @@ const { } = Astro.props;
Pricing

- Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do - eiusmod tempor incididunt ut labore et dolore. + Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et + dolore.

+ class="relative flex flex-col p-6 bg-white dark:bg-slate-900 rounded shadow-xl dark:border dark:border-slate-800" + >
@@ -137,11 +138,11 @@ const { } = Astro.props;
Testimonial

- Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do - eiusmod tempor incididunt ut labore et dolore. + Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et + dolore.

-
\ No newline at end of file + diff --git a/src/components/astro/features/StepsFeatures.astro b/src/components/astro/features/StepsFeatures.astro index a6f5e12..6ad31e7 100644 --- a/src/components/astro/features/StepsFeatures.astro +++ b/src/components/astro/features/StepsFeatures.astro @@ -1,5 +1,5 @@ --- -const { } = Astro.props; +const {} = Astro.props; ---
@@ -10,18 +10,20 @@ const { } = Astro.props;

- Sed ac magna sit amet risus tristique interdum, at vel velit in - hac habitasse platea dictumst. + Sed ac magna sit amet risus tristique interdum, at vel velit in hac habitasse platea dictumst.

- Lorem ipsum dolor sit amet, consectetur adipiscing elit. Morbi - sagittis, quam nec venenatis lobortis, mi risus tempus nulla, - sed porttitor est nibh at nulla. Praesent placerat enim ut ex - tincidunt vehicula. Fusce sit amet dui tellus. + Lorem ipsum dolor sit amet, consectetur adipiscing elit. Morbi sagittis, quam nec venenatis lobortis, mi + risus tempus nulla, sed porttitor est nibh at nulla. Praesent placerat enim ut ex tincidunt vehicula. + Fusce sit amet dui tellus.

@@ -32,14 +34,13 @@ const { } = Astro.props;
  • + class="flex w-16 h-16 mx-auto items-center justify-center text-2xl font-bold font-heading rounded-full bg-blue-50 text-blue-600" + > 1
    -

    - Responsive Elements -

    +

    Responsive Elements

    Lorem ipsum dolor sit amet, consectetur adipiscing elit. Morbi sagittis, quam nec venenatis lobortis, mi risus tempus nulla. @@ -49,7 +50,8 @@ const { } = Astro.props;

  • + class="flex w-16 h-16 mx-auto items-center justify-center text-2xl font-bold font-heading rounded-full bg-blue-50 text-blue-600" + > 2
    @@ -64,7 +66,8 @@ const { } = Astro.props;
  • + class="flex w-16 h-16 mx-auto items-center justify-center text-2xl font-bold font-heading rounded-full bg-blue-50 text-blue-600" + > 3
    @@ -82,4 +85,4 @@ const { } = Astro.props;
  • -
    \ No newline at end of file + diff --git a/src/components/astro/features/StepsLeft.astro b/src/components/astro/features/StepsLeft.astro index 5c6183c..30b49e5 100644 --- a/src/components/astro/features/StepsLeft.astro +++ b/src/components/astro/features/StepsLeft.astro @@ -1,119 +1,151 @@ --- -import Picture from "~/components/astro/utils/Picture.astro" -const { } = Astro.props; +import Picture from "~/components/astro/utils/Picture.astro"; +const {} = Astro.props; ---
    -
    -
    -
    -
    -
    -
    - - - - - -
    -
    -
    -
    -
    -

    Step 1

    -

    - Lorem ipsum dolor sit amet, consectetur adipiscing elit. Morbi sagittis, quam nec venenatis - lobortis, mi risus tempus nulla, sed porttitor est nibh at nulla. Praesent placerat enim ut ex - tincidunt vehicula. Fusce sit amet dui tellus. - - - -

    -
    -
    -
    -
    -
    -
    - - - - - -
    -
    -
    -
    -
    -

    Step 2

    -

    - Lorem ipsum dolor sit amet, consectetur adipiscing elit. Morbi sagittis, quam nec venenatis - lobortis, mi risus tempus nulla, sed porttitor est nibh at nulla. - - -

    -
    -
    -
    -
    -
    -
    - - - - - -
    -
    -
    -
    -
    -

    Step 3

    -

    - Lorem ipsum dolor sit amet, consectetur adipiscing elit. Morbi sagittis, quam nec venenatis - lobortis, mi risus tempus nulla, sed porttitor est nibh at nulla. - - -

    -
    -
    -
    -
    -
    -
    - - - - -
    -
    -
    -
    -

    Ready!

    -

    -
    +
    +
    +
    +
    +
    +
    + + + + +
    +
    +
    -
    - +
    +

    Step 1

    +

    + Lorem ipsum dolor sit amet, consectetur adipiscing elit. Morbi sagittis, quam nec venenatis lobortis, mi + risus tempus nulla, sed porttitor est nibh at nulla. Praesent placerat enim ut ex tincidunt vehicula. Fusce + sit amet dui tellus. +

    +
    +
    +
    +
    +
    + + + + + +
    +
    +
    +
    +
    +

    Step 2

    +

    + Lorem ipsum dolor sit amet, consectetur adipiscing elit. Morbi sagittis, quam nec venenatis lobortis, mi + risus tempus nulla, sed porttitor est nibh at nulla. +

    +
    +
    +
    +
    +
    +
    + + + + + +
    +
    +
    +
    +
    +

    Step 3

    +

    + Lorem ipsum dolor sit amet, consectetur adipiscing elit. Morbi sagittis, quam nec venenatis lobortis, mi + risus tempus nulla, sed porttitor est nibh at nulla. +

    +
    +
    +
    +
    +
    +
    + + + + +
    +
    +
    +
    +

    Ready!

    +

    +
    +
    -
    \ No newline at end of file +
    + +
    + + diff --git a/src/components/astro/features/TwoColsFeatures.astro b/src/components/astro/features/TwoColsFeatures.astro index d05e73e..1b45ce8 100644 --- a/src/components/astro/features/TwoColsFeatures.astro +++ b/src/components/astro/features/TwoColsFeatures.astro @@ -1,176 +1,163 @@ --- -const { } = Astro.props; +const {} = Astro.props; ---
    -
    -

    - Features -

    -

    - What's interesting about AstroWind -

    -

    - Sed ut perspiciatis unde omnis iste natus error sit voluptatem accusantium doloremque rem aperiam, eaque - ipsa quae. -

    -
    -
    -
    -
    -
    -
    - - - - - - - - - - - -
    -
    -
    -

    Integration with Tailwind CSS

    -

    - Lorem ipsum dolor sit amet, consectetur adipiscing elit. Morbi sagittis, quam nec venenatis - lobortis, mi risus tempus nulla. -

    -
    -
    -
    -
    -
    - - - - - - - - - - - -
    -
    -
    -

    Ready-to-use Components

    -

    - Lorem ipsum dolor sit amet, consectetur adipiscing elit. Morbi sagittis, quam nec venenatis - lobortis, mi risus tempus nulla. -

    -
    -
    -
    -
    -
    - - - - - - - - - - - -
    -
    -
    -

    Best Practices

    -

    - Lorem ipsum dolor sit amet, consectetur adipiscing elit. Morbi sagittis, quam nec venenatis - lobortis, mi risus tempus nulla. -

    -
    -
    +
    +

    Features

    +

    + What's interesting about AstroWind + +

    +

    + Sed ut perspiciatis unde omnis iste natus error sit voluptatem accusantium doloremque rem aperiam, eaque ipsa + quae. +

    +
    +
    +
    +
    +
    +
    + + + + + + + + + + +
    -
    -
    -
    -
    - - - - - - - - - - - -
    -
    -
    -

    Excelent Page Speed

    -

    - Lorem ipsum dolor sit amet, consectetur adipiscing elit. Morbi sagittis, quam nec venenatis - lobortis, mi risus tempus nulla. -

    -
    -
    -
    -
    -
    - - - - - - - - - - - -
    -
    -
    -

    Frequently updated

    -

    - Lorem ipsum dolor sit amet, consectetur adipiscing elit. Morbi sagittis, quam nec venenatis - lobortis, mi risus tempus nulla. -

    -
    -
    -
    -
    -
    - - - - - - - - - - - -
    -
    -
    -

    Open to new ideas and contributions -

    -

    - Lorem ipsum dolor sit amet, consectetur adipiscing elit. Morbi sagittis, quam nec venenatis - lobortis, mi risus tempus nulla. -

    -
    -
    +
    +

    Integration with Tailwind CSS

    +

    + Lorem ipsum dolor sit amet, consectetur adipiscing elit. Morbi sagittis, quam nec venenatis lobortis, mi + risus tempus nulla. +

    +
    +
    +
    +
    + + + + + + + + + + +
    +
    +
    +

    Ready-to-use Components

    +

    + Lorem ipsum dolor sit amet, consectetur adipiscing elit. Morbi sagittis, quam nec venenatis lobortis, mi + risus tempus nulla. +

    +
    +
    +
    +
    +
    + + + + + + + + + + +
    +
    +
    +

    Best Practices

    +

    + Lorem ipsum dolor sit amet, consectetur adipiscing elit. Morbi sagittis, quam nec venenatis lobortis, mi + risus tempus nulla. +

    +
    +
    -
    \ No newline at end of file +
    +
    +
    +
    + + + + + + + + + + +
    +
    +
    +

    Excelent Page Speed

    +

    + Lorem ipsum dolor sit amet, consectetur adipiscing elit. Morbi sagittis, quam nec venenatis lobortis, mi + risus tempus nulla. +

    +
    +
    +
    +
    +
    + + + + + + + + + + +
    +
    +
    +

    Frequently updated

    +

    + Lorem ipsum dolor sit amet, consectetur adipiscing elit. Morbi sagittis, quam nec venenatis lobortis, mi + risus tempus nulla. +

    +
    +
    +
    +
    +
    + + + + + + + + + + +
    +
    +
    +

    Open to new ideas and contributions

    +

    + Lorem ipsum dolor sit amet, consectetur adipiscing elit. Morbi sagittis, quam nec venenatis lobortis, mi + risus tempus nulla. +

    +
    +
    +
    + + diff --git a/src/components/astro/footers/BasicFooter.astro b/src/components/astro/footers/BasicFooter.astro index 1065833..cbc5f13 100644 --- a/src/components/astro/footers/BasicFooter.astro +++ b/src/components/astro/footers/BasicFooter.astro @@ -1,11 +1,6 @@ --- -import { - IconTwitter, - IconInstagram, - IconFacebook, - IconArrowRight, -} from "~/components/astro/icons"; -const { } = Astro.props; +import { IconTwitter, IconInstagram, IconFacebook, IconArrowRight } from "~/components/astro/icons"; +const {} = Astro.props; --- \ No newline at end of file + diff --git a/src/components/astro/headers/BasicHeader.astro b/src/components/astro/headers/BasicHeader.astro index de0fad4..75ffef6 100644 --- a/src/components/astro/headers/BasicHeader.astro +++ b/src/components/astro/headers/BasicHeader.astro @@ -1,58 +1,79 @@ --- import { IconSun, IconGithub, IconMenu } from "~/components/astro/icons"; -const { } = Astro.props; +const {} = Astro.props; ---
    + class="fixed top-0 z-40 flex-none mx-auto w-full bg-white/90 dark:bg-transparent backdrop-blur-sm border-b dark:border-b-0" +>
    - AstroWind + AstroWind
    -
    -
    -
    \ No newline at end of file + diff --git a/src/components/astro/hero/HeroWithImage.astro b/src/components/astro/hero/HeroWithImage.astro index 1e6f5f3..d9e2d84 100644 --- a/src/components/astro/hero/HeroWithImage.astro +++ b/src/components/astro/hero/HeroWithImage.astro @@ -1,6 +1,6 @@ --- import Picture from "~/components/astro/utils/Picture.astro"; -const { } = Astro.props; +const {} = Astro.props; ---
    @@ -9,28 +9,32 @@ const { } = Astro.props;

    Your website with - Astro - + - Tailwind - CSS + Astro + + Tailwind CSS

    - AstroWind is a production ready template to start your new website using Astro + Tailwind CSS. - It has been designed following Best Practices, SEO, Accessibility, Dark Mode, great Page Speed, image - optimization, sitemap generation and more. + AstroWind is a production ready template to start your new website using Astro + Tailwind CSS. It has been + designed following Best Practices, SEO, Accessibility, Dark Mode, great Page Speed, image optimization, + sitemap generation and more.

    @@ -39,11 +43,17 @@ const { } = Astro.props;
    - +
    -
    \ No newline at end of file + diff --git a/src/components/astro/stats/BasicStats.astro b/src/components/astro/stats/BasicStats.astro index 7c0697d..17a9bf9 100644 --- a/src/components/astro/stats/BasicStats.astro +++ b/src/components/astro/stats/BasicStats.astro @@ -1,32 +1,26 @@ --- -const { } = Astro.props; +const {} = Astro.props; ---
    -
    -
    -
    132K
    -

    - Downloads -

    -
    -
    -
    24.8K
    -

    - Stars -

    -
    -
    -
    10.3K
    -

    - Forks -

    -
    -
    -
    48.4K
    -

    - Users -

    -
    +
    +
    +
    132K
    +

    + Downloads +

    -
    \ No newline at end of file +
    +
    24.8K
    +

    Stars

    +
    +
    +
    10.3K
    +

    Forks

    +
    +
    +
    48.4K
    +

    Users

    +
    +
    +
    diff --git a/src/components/astro/utils/Picture.astro b/src/components/astro/utils/Picture.astro index 63c8c92..7868d67 100644 --- a/src/components/astro/utils/Picture.astro +++ b/src/components/astro/utils/Picture.astro @@ -2,28 +2,33 @@ import { getPicture } from "@astrojs/image"; const { - src, - alt, - sizes, - widths, - aspectRatio, - formats = ['avif', 'webp'], - loading = 'lazy', - decoding = 'async', - class :className = "", - ...attrs + src, + alt, + sizes, + widths, + aspectRatio, + formats = ["avif", "webp"], + loading = "lazy", + decoding = "async", + class: className = "", + ...attrs } = Astro.props; -const { image, sources } = await getPicture({ src, widths, formats, aspectRatio }); +const { image, sources } = await getPicture({ + src, + widths, + formats, + aspectRatio, +}); --- - {sources.map((attrs) => )} - + {sources.map((attrs) => )} + diff --git a/src/layouts/Default.astro b/src/layouts/Default.astro index cc059c5..ca85479 100644 --- a/src/layouts/Default.astro +++ b/src/layouts/Default.astro @@ -17,14 +17,9 @@ const { title = "", description = "", withHeader = true } = Astro.props; - - + function toggleDarkMode() { document.documentElement.classList.toggle("dark"); - localStorage.theme = document.documentElement.classList.contains("dark") - ? "dark" - : "light"; + localStorage.theme = document.documentElement.classList.contains("dark") ? "dark" : "light"; } window.toggleDarkMode = toggleDarkMode; if ( localStorage.theme === "dark" || - (!("theme" in localStorage) && - window.matchMedia("(prefers-color-scheme: dark)").matches) + (!("theme" in localStorage) && window.matchMedia("(prefers-color-scheme: dark)").matches) ) { document.documentElement.classList.add("dark"); } else { diff --git a/src/layouts/Empty.astro b/src/layouts/Empty.astro index 4fac623..1b78069 100644 --- a/src/layouts/Empty.astro +++ b/src/layouts/Empty.astro @@ -14,14 +14,9 @@ const { title = "", description = "", withHeader = true } = Astro.props; - - + if ( localStorage.theme === "dark" || - (!("theme" in localStorage) && - window.matchMedia("(prefers-color-scheme: dark)").matches) + (!("theme" in localStorage) && window.matchMedia("(prefers-color-scheme: dark)").matches) ) { document.documentElement.classList.add("dark"); } else { diff --git a/src/pages/404.astro b/src/pages/404.astro index 208b77f..7f23224 100644 --- a/src/pages/404.astro +++ b/src/pages/404.astro @@ -3,18 +3,27 @@ import Layout from "~/layouts/Empty.astro"; --- -
    -
    -
    -
    -

    - Error404 -

    -

    Sorry, we couldn't find this page.

    -

    But dont worry, you can find plenty of other things on our homepage.

    - Back to homepage -
    -
    -
    -
    -
    \ No newline at end of file +
    +
    +
    +
    +

    + Error404 +

    +

    Sorry, we couldn't find this page.

    +

    + But dont worry, you can find plenty of other things on our homepage. +

    + Back to homepage + +
    +
    +
    +
    + diff --git a/src/pages/index.astro b/src/pages/index.astro index 44c7e76..70d4d5d 100644 --- a/src/pages/index.astro +++ b/src/pages/index.astro @@ -12,8 +12,10 @@ import BasicStats from "~/components/astro/stats/BasicStats.astro"; import BlogFeaturesFourCols from "~/components/astro/blog/BlogFeaturesFourCols.astro"; --- - +
    @@ -25,4 +27,4 @@ import BlogFeaturesFourCols from "~/components/astro/blog/BlogFeaturesFourCols.a
    -
    \ No newline at end of file +