Files
voyage/frontend/src/routes/+layout.svelte
alex 49abfad192 chore: update dependencies
Backend:
- gunicorn 23.0.0 → 25.1.0
- setuptools 79.0.1 → 82.0.1
- litellm >=1.72.3 → >=1.82.1

Frontend:
- Migrate Tailwind CSS 3 → 4, daisyUI 4 → 5
  - Add @tailwindcss/vite plugin, remove autoprefixer
  - Replace tailwind.config.js with src/app.css (CSS-based config)
  - Convert custom themes (aestheticDark, catppuccinMocha, aestheticLight,
    northernLights) to daisyUI 5 CSS variable format
  - Remove daisyUI v4-only '-bordered' classes from 45 component files
    (input-bordered, select-bordered, textarea-bordered, file-input-bordered
    are removed in v5; borders are default)
- @types/node 22 → 25
- @lukulent/svelte-umami 0.0.3 → 0.0.4
- packageManager: bun@1.2.22 → bun@1.3.10

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
2026-03-10 13:34:49 +00:00

109 lines
2.7 KiB
Svelte

<script lang="ts">
import { browser } from '$app/environment';
import { register, init, locale, waitLocale } from 'svelte-i18n';
import { UmamiAnalyticsEnv } from '@lukulent/svelte-umami';
export let data;
// Register your translations for each locale
register('en', () => import('../locales/en.json'));
register('es', () => import('../locales/es.json'));
register('fr', () => import('../locales/fr.json'));
register('de', () => import('../locales/de.json'));
register('it', () => import('../locales/it.json'));
register('zh', () => import('../locales/zh.json'));
register('nl', () => import('../locales/nl.json'));
register('sv', () => import('../locales/sv.json'));
register('pl', () => import('../locales/pl.json'));
register('ko', () => import('../locales/ko.json'));
register('no', () => import('../locales/no.json'));
register('ru', () => import('../locales/ru.json'));
register('ja', () => import('../locales/ja.json'));
register('ar', () => import('../locales/ar.json'));
register('pt-br', () => import('../locales/pt-br.json'));
register('ro', () => import('../locales/ro.json'));
register('sk', () => import('../locales/sk.json'));
register('tr', () => import('../locales/tr.json'));
register('uk', () => import('../locales/uk.json'));
register('hu', () => import('../locales/hu.json'));
let locales = [
'en',
'es',
'fr',
'de',
'it',
'zh',
'nl',
'sv',
'pl',
'ko',
'no',
'ru',
'ja',
'ar',
'pt-br',
'ro',
'sk',
'tr',
'uk',
'hu'
];
if (browser) {
init({
fallbackLocale: 'en',
initialLocale: data.locale
});
// get the locale cookie if it exists and set it as the initial locale if it exists
const localeCookie = document.cookie
.split(';')
.find((cookie) => cookie.trim().startsWith('locale='));
if (localeCookie) {
const localeValue = localeCookie.split('=')[1];
locale.set(localeValue);
}
}
import Navbar from '$lib/components/Navbar.svelte';
import Toast from '$lib/components/Toast.svelte';
import '../app.css';
// Create a promise that resolves when the locale is ready
export const localeLoaded = browser ? waitLocale() : Promise.resolve();
</script>
{#await localeLoaded}
<!-- You can add a loading indicator here if needed -->
{:then}
<Navbar {data} />
<Toast />
<slot />
{/await}
<UmamiAnalyticsEnv />
<svelte:head>
<title>Voyage</title>
<meta
name="description"
content="Embark, explore, remember with Voyage. Voyage is the ultimate travel companion."
/>
</svelte:head>
<style>
/* Prevent unwanted horizontal scroll and ensure single scrollbar */
:global(html) {
overflow-x: hidden;
overflow-y: auto;
}
:global(body) {
overflow: hidden;
}
/* Ensure slot content doesn't create nested scrollbars */
:global(body > div) {
overflow: visible;
}
</style>