fix: use env object from \$env/dynamic/public instead of named imports
All checks were successful
Build and Push Docker Image to Gitea / build-and-push (push) Successful in 5m13s

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
2026-03-04 17:19:26 +01:00
parent 1e69d0b158
commit de16b64255
3 changed files with 27 additions and 24 deletions

View File

@@ -1,24 +1,27 @@
<script lang="ts">
import { _ } from "svelte-i18n";
import { PUBLIC_URL } from "$env/dynamic/public";
import { _ } from "svelte-i18n";
import { env } from "$env/dynamic/public";
interface Props {
title: string;
description: string;
image?: string;
}
interface Props {
title: string;
description: string;
image?: string;
}
let {
title,
description,
image = `${PUBLIC_URL || "http://localhost:3000"}/img/kamasutra.jpg`,
}: Props = $props();
let {
title,
description,
image = `${env.PUBLIC_URL || "http://localhost:3000"}/img/kamasutra.jpg`,
}: Props = $props();
</script>
<svelte:head>
<title>{$_("head.title", { values: { title } })}</title>
<meta name="description" content={description} />
<meta property="og:title" content={$_("head.title", { values: { title } })} />
<meta property="og:description" content={description} />
<meta property="og:image" content={image} />
<title>{$_("head.title", { values: { title } })}</title>
<meta name="description" content={description} />
<meta
property="og:title"
content={$_("head.title", { values: { title } })}
/>
<meta property="og:description" content={description} />
<meta property="og:image" content={image} />
</svelte:head>