mirror of
https://github.com/Memo-2023/mana-monorepo.git
synced 2026-05-15 18:39:40 +02:00
feat: show build date/time on login screen across all apps
- Add BUILD_TIME and BUILD_HASH exports to all version.ts files - Add getBuildDefines() to all vite.config.ts for compile-time injection - Add buildTime prop to shared LoginPage component - Display formatted date/time next to version number (e.g. "v1.0.0 · 21.03.2026 10:30") - Add app.d.ts type declarations for __BUILD_TIME__ and __BUILD_HASH__ Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
parent
a6a5265332
commit
fc5dfe2f0f
69 changed files with 210 additions and 34 deletions
3
apps/chat/apps/web/src/app.d.ts
vendored
3
apps/chat/apps/web/src/app.d.ts
vendored
|
|
@ -1,3 +1,6 @@
|
|||
declare const __BUILD_HASH__: string;
|
||||
declare const __BUILD_TIME__: string;
|
||||
|
||||
// See https://svelte.dev/docs/kit/types#app.d.ts
|
||||
// for information about these interfaces
|
||||
|
||||
|
|
|
|||
|
|
@ -1 +1,4 @@
|
|||
export const APP_VERSION = '0.3.0';
|
||||
export const BUILD_TIME: string =
|
||||
typeof __BUILD_TIME__ !== 'undefined' ? __BUILD_TIME__ : new Date().toISOString();
|
||||
export const BUILD_HASH: string = typeof __BUILD_HASH__ !== 'undefined' ? __BUILD_HASH__ : 'dev';
|
||||
|
|
|
|||
|
|
@ -9,7 +9,7 @@
|
|||
import { authStore } from '$lib/stores/auth.svelte';
|
||||
import AppSlider from '$lib/components/AppSlider.svelte';
|
||||
import LanguageSelector from '$lib/components/LanguageSelector.svelte';
|
||||
import { APP_VERSION } from '$lib/version';
|
||||
import { APP_VERSION, BUILD_TIME } from '$lib/version';
|
||||
import '$lib/i18n';
|
||||
|
||||
// Dev credentials - pre-filled in development mode
|
||||
|
|
@ -76,6 +76,7 @@
|
|||
{initialEmail}
|
||||
{initialPassword}
|
||||
version={APP_VERSION}
|
||||
buildTime={BUILD_TIME}
|
||||
>
|
||||
{#snippet headerControls()}
|
||||
<LanguageSelector />
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@ import { sveltekit } from '@sveltejs/kit/vite';
|
|||
import { SvelteKitPWA } from '@vite-pwa/sveltekit';
|
||||
import tailwindcss from '@tailwindcss/vite';
|
||||
import { defineConfig } from 'vite';
|
||||
import { MANACORE_SHARED_PACKAGES } from '@manacore/shared-vite-config';
|
||||
import { MANACORE_SHARED_PACKAGES, getBuildDefines } from '@manacore/shared-vite-config';
|
||||
import { createPWAConfig } from '@manacore/shared-pwa';
|
||||
|
||||
export default defineConfig({
|
||||
|
|
@ -29,4 +29,7 @@ export default defineConfig({
|
|||
optimizeDeps: {
|
||||
exclude: [...MANACORE_SHARED_PACKAGES, 'marked'],
|
||||
},
|
||||
define: {
|
||||
...getBuildDefines(),
|
||||
},
|
||||
});
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue