File tree Expand file tree Collapse file tree 1 file changed +21
-2
lines changed
Expand file tree Collapse file tree 1 file changed +21
-2
lines changed Original file line number Diff line number Diff line change 11---
22import ' @/styles/global.css' ;
3+ import ' @/assets/fonts/inter.css' ;
4+ import BannerFloat from ' @/components/BannerFloat.astro' ;
5+ import Header from ' @/components/partials/Header.astro' ;
6+ import Footer from ' @/components/partials/Footer.astro' ;
7+ import SwitchTheme from ' @/components/SwitchTheme.tsx' ;
38---
49
5- <html lang =" en" class = " dark " >
10+ <html lang =" en" >
611 <head >
712 <meta charset =" utf-8" />
813 <link rel =" icon" type =" image/svg+xml" href =" /favicon.svg" />
914 <meta name =" viewport" content =" width=device-width" />
1015 <meta name =" generator" content ={ Astro .generator } />
1116 <title >Astro</title >
17+ <script is:inline >
18+ // Prevent FOUC by applying theme before page renders
19+ (function() {
20+ const theme = localStorage.getItem('theme') ||
21+ (window.matchMedia('(prefers-color-scheme: dark)').matches ? 'dark' : 'light');
22+ if (theme === 'dark') {
23+ document.documentElement.classList.add('dark');
24+ }
25+ })();
26+ </script >
1227 </head >
13- <body class =" bg-background text-foreground" >
28+ <body class =" bg-background text-foreground py-8 pb-12" >
29+ <Header />
1430 <main >
1531 <slot />
1632 </main >
33+ <Footer />
34+ <SwitchTheme client:load />
35+ <BannerFloat />
1736 </body >
1837</html >
You can’t perform that action at this time.
0 commit comments