diff --git a/web/src/routes/+layout.svelte b/web/src/routes/+layout.svelte index 8f8a61dbde727..eaafca5fbbc6c 100644 --- a/web/src/routes/+layout.svelte +++ b/web/src/routes/+layout.svelte @@ -19,6 +19,26 @@ import { dragAndDropFilesStore } from '$lib/stores/drag-and-drop-files.store'; import { api } from '@api'; import { closeWebsocketConnection, openWebsocketConnection } from '$lib/stores/websocket'; + import Icon from '$lib/components/elements/icon.svelte'; + import { mdiOpenInNew } from '@mdi/js'; + import Button from '$lib/components/elements/buttons/button.svelte'; + + // remove after v1.87 is released + let isOutdated = false; + const handleCheckOutdated = async () => { + try { + let response = await api.serverInfoApi.getServerVersion(); + if (!response.headers['content-type'].startsWith('application/json')) { + api.setBaseUrl('/api/api'); + response = await api.serverInfoApi.getServerVersion(); + } + if (response.data.major === 1 && response.data.minor >= 88) { + isOutdated = true; + } + } catch { + // noop + } + }; let showNavigationLoadingBar = false; export let data: LayoutData; @@ -48,6 +68,8 @@ }); onMount(async () => { + handleCheckOutdated(); + if ($page.route.id?.startsWith('/auth') === false) { openWebsocketConnection(); } @@ -110,12 +132,40 @@ +{#if isOutdated} + +
+

+ This container (immich-web) is no longer in use. +

+

+ Please read the announcement about the breaking changes released in v1.88.0 and update your configuration + accordingly. +

+ + + + +
+
+{:else} + +{/if} + {#if showNavigationLoadingBar} {/if} - -