Include stylesheet in static file generation

This commit is contained in:
thiloho
2024-08-17 20:21:23 +02:00
parent f3278fb1f6
commit dc9a2eabe9
5 changed files with 36 additions and 4 deletions

View File

@@ -14,6 +14,7 @@
<svelte:head>
<head>
<title>{title}</title>
<link rel="stylesheet" href="../styles.css" />
</head>
</svelte:head>
@@ -28,7 +29,9 @@
</nav>
<header>
<img src={coverImage} alt="" />
{#if coverImage}
<img src={coverImage} alt="" />
{/if}
<h1>{title}</h1>
<p>{publicationDate}</p>
</header>

View File

@@ -12,6 +12,7 @@
<svelte:head>
<head>
<title>{title}</title>
<link rel="stylesheet" href="./styles.css" />
</head>
</svelte:head>
@@ -45,7 +46,9 @@
<h3>
<a href="./articles/{articleFileName}.html">{article.title}</a>
</h3>
<p>{article.meta_description ?? "No description provided"}</p>
{#if article.meta_description}
<p>{article.meta_description}</p>
{/if}
</article>
{/each}
</section>

View File

@@ -0,0 +1,18 @@
:root {
color-scheme: light dark;
}
body {
margin-inline: auto;
inline-size: min(100% - 2rem, 75ch);
line-height: 1.5;
font-family: system-ui, sans-serif;
}
img,
picture,
svg,
video {
max-inline-size: 100%;
block-size: auto;
}