mirror of
https://github.com/ArthurDanjou/artsite.git
synced 2026-01-14 15:54:13 +01:00
Ajout de ClientOnly autour de ContentRenderer pour améliorer le rendu côté client dans les composants projets et écrits.
This commit is contained in:
@@ -91,10 +91,12 @@ const { copy, copied } = useClipboard({
|
|||||||
class="my-4"
|
class="my-4"
|
||||||
icon="i-ph-pencil-line-duotone"
|
icon="i-ph-pencil-line-duotone"
|
||||||
/>
|
/>
|
||||||
<ContentRenderer
|
<ClientOnly>
|
||||||
|
<ContentRenderer
|
||||||
:value="project"
|
:value="project"
|
||||||
class="!max-w-none prose dark:prose-invert"
|
class="!max-w-none prose dark:prose-invert"
|
||||||
/>
|
/>
|
||||||
|
</ClientOnly>
|
||||||
<div class="space-y-4 mt-8">
|
<div class="space-y-4 mt-8">
|
||||||
<PostFooter />
|
<PostFooter />
|
||||||
<div class="flex gap-4 items-center flex-wrap">
|
<div class="flex gap-4 items-center flex-wrap">
|
||||||
|
|||||||
@@ -157,13 +157,15 @@ function scrollToSection(id: string) {
|
|||||||
icon="i-ph-pencil-line-duotone"
|
icon="i-ph-pencil-line-duotone"
|
||||||
/>
|
/>
|
||||||
<article class="mt-8">
|
<article class="mt-8">
|
||||||
<ContentRenderer
|
<ClientOnly>
|
||||||
|
<ContentRenderer
|
||||||
:value="post"
|
:value="post"
|
||||||
class="!max-w-none prose dark:prose-invert"
|
class="!max-w-none prose dark:prose-invert"
|
||||||
/>
|
/>
|
||||||
|
</ClientOnly>
|
||||||
<div class="space-y-4 mt-8">
|
<div class="space-y-4 mt-8">
|
||||||
<PostFooter />
|
<PostFooter />
|
||||||
<div class="flex gap-4 items-center flex-wrap">
|
<div class="flex gap-4 items-center flex-wrap justify-between sm:justify-start">
|
||||||
<UButton
|
<UButton
|
||||||
:label="(postDB?.likes ?? 0) > 1 ? `${postDB?.likes ?? 0} likes` : `${postDB?.likes ?? 0} like`"
|
:label="(postDB?.likes ?? 0) > 1 ? `${postDB?.likes ?? 0} likes` : `${postDB?.likes ?? 0} like`"
|
||||||
:color="likeCookie ? 'red' : 'neutral'"
|
:color="likeCookie ? 'red' : 'neutral'"
|
||||||
|
|||||||
Reference in New Issue
Block a user