new style
This commit is contained in:
@@ -15,6 +15,7 @@ interface Props {
|
||||
const canonicalURL = new URL(Astro.url.pathname, Astro.site);
|
||||
|
||||
const { title, description, image = FallbackImage } = Astro.props;
|
||||
|
||||
---
|
||||
|
||||
<!-- Global Metadata -->
|
||||
@@ -56,3 +57,14 @@ const { title, description, image = FallbackImage } = Astro.props;
|
||||
<meta property="twitter:title" content={title} />
|
||||
<meta property="twitter:description" content={description} />
|
||||
<meta property="twitter:image" content={new URL(image.src, Astro.url)} />
|
||||
<script is:inline>
|
||||
|
||||
if (sessionStorage.getItem("theme")) {
|
||||
document.documentElement.setAttribute("data-theme", sessionStorage.getItem("theme"));
|
||||
} else {
|
||||
sessionStorage.setItem("theme", "light")
|
||||
document.documentElement.setAttribute("data-theme", "light");
|
||||
}
|
||||
|
||||
|
||||
</script>
|
||||
Reference in New Issue
Block a user