From 0bbc0081be1e632d0b09ae0d5dda1a28273dfb8c Mon Sep 17 00:00:00 2001 From: trivernis Date: Mon, 8 Jul 2024 20:15:56 +0200 Subject: [PATCH] Add lang attribute to article content because it's more correct --- src/routes/blog/[slug]/+page.svelte | 128 ++++++++++++---------------- 1 file changed, 55 insertions(+), 73 deletions(-) diff --git a/src/routes/blog/[slug]/+page.svelte b/src/routes/blog/[slug]/+page.svelte index 4f15884..4e683fa 100644 --- a/src/routes/blog/[slug]/+page.svelte +++ b/src/routes/blog/[slug]/+page.svelte @@ -1,33 +1,13 @@ @@ -37,35 +17,37 @@ {@const teaserImage = data.post.attributes.teaserImage.data?.attributes} {@const collection = data.post.attributes.collection.data?.attributes} -
- -
-

{post.attributes.title}

-

by {author?.name}

- {#if collection} -

- in {collection?.name} -

- {/if} - {formatDateRelative(post.attributes.publishedAt)} -
- {#if post.attributes.teaserImage.data} -
- +
+
+ +
+

{post.attributes.title}

+

by {author?.name}

+ {#if collection} +

+ in {collection?.name} +

+ {/if} + {formatDateRelative(post.attributes.publishedAt)}
- {/if} -
+ {#if post.attributes.teaserImage.data} +
+ +
+ {/if} + +
+ {#each post.attributes.content as contentEntry} + + {/each}
- {#each post.attributes.content as contentEntry} - - {/each} {:else if !data.error} {/if} @@ -73,34 +55,34 @@ {#if data.error} {/if} + - - + .head-thumbnail { + position: absolute; + top: 0; + left: 0; + width: 100%; + height: 100%; + z-index: -10; + } + } +