2022-08-24 21:10:48 -07:00
|
|
|
<script>
|
2023-07-01 00:50:47 -04:00
|
|
|
import { page } from '$app/stores';
|
2023-10-25 09:48:25 -04:00
|
|
|
import Icon from '$lib/components/elements/icon.svelte';
|
2023-08-25 19:44:52 +02:00
|
|
|
import ImmichLogo from '$lib/components/shared-components/immich-logo.svelte';
|
2024-05-04 18:29:50 +00:00
|
|
|
import CircleIconButton from '$lib/components/elements/buttons/circle-icon-button.svelte';
|
2024-02-14 06:38:57 -08:00
|
|
|
import { copyToClipboard } from '$lib/utils';
|
2023-10-25 09:48:25 -04:00
|
|
|
import { mdiCodeTags, mdiContentCopy, mdiMessage, mdiPartyPopper } from '@mdi/js';
|
2024-06-04 21:53:00 +02:00
|
|
|
import { t } from 'svelte-i18n';
|
2023-01-13 17:04:59 -05:00
|
|
|
|
2023-07-01 00:50:47 -04:00
|
|
|
const handleCopy = async () => {
|
|
|
|
|
//
|
|
|
|
|
const error = $page.error || null;
|
|
|
|
|
if (!error) {
|
|
|
|
|
return;
|
|
|
|
|
}
|
2023-01-13 17:04:59 -05:00
|
|
|
|
2023-08-25 19:44:52 +02:00
|
|
|
await copyToClipboard(`${error.message} - ${error.code}\n${error.stack}`);
|
2023-07-01 00:50:47 -04:00
|
|
|
};
|
2022-08-24 21:10:48 -07:00
|
|
|
</script>
|
|
|
|
|
|
2023-01-13 17:04:59 -05:00
|
|
|
<div class="h-screen w-screen">
|
2023-07-01 00:50:47 -04:00
|
|
|
<section class="bg-immich-bg dark:bg-immich-dark-bg">
|
2023-07-18 13:19:39 -05:00
|
|
|
<div class="flex place-items-center border-b px-6 py-4 dark:border-b-immich-dark-gray">
|
|
|
|
|
<a class="flex place-items-center gap-2 hover:cursor-pointer" href="/photos">
|
2024-03-13 12:14:45 -05:00
|
|
|
<ImmichLogo width="55%" />
|
2023-07-01 00:50:47 -04:00
|
|
|
</a>
|
|
|
|
|
</div>
|
|
|
|
|
</section>
|
2022-08-24 21:10:48 -07:00
|
|
|
|
2023-07-18 13:19:39 -05:00
|
|
|
<div class="fixed top-0 flex h-full w-full place-content-center place-items-center overflow-hidden bg-black/50">
|
2023-07-01 00:50:47 -04:00
|
|
|
<div>
|
|
|
|
|
<div
|
2023-07-18 13:19:39 -05:00
|
|
|
class="w-[500px] max-w-[95vw] rounded-3xl border bg-immich-bg shadow-sm dark:border-immich-dark-gray dark:bg-immich-dark-gray dark:text-immich-dark-fg"
|
2023-07-01 00:50:47 -04:00
|
|
|
>
|
|
|
|
|
<div>
|
|
|
|
|
<div class="flex items-center justify-between gap-4 px-4 py-4">
|
2023-07-18 13:19:39 -05:00
|
|
|
<h1 class="font-medium text-immich-primary dark:text-immich-dark-primary">
|
2023-07-01 00:50:47 -04:00
|
|
|
🚨 Error - Something went wrong
|
|
|
|
|
</h1>
|
|
|
|
|
<div class="flex justify-end">
|
2024-05-04 18:29:50 +00:00
|
|
|
<CircleIconButton
|
|
|
|
|
color="primary"
|
|
|
|
|
icon={mdiContentCopy}
|
2024-06-04 21:53:00 +02:00
|
|
|
title={$t('copy_error')}
|
2023-07-01 00:50:47 -04:00
|
|
|
on:click={() => handleCopy()}
|
2024-05-04 18:29:50 +00:00
|
|
|
/>
|
2023-07-01 00:50:47 -04:00
|
|
|
</div>
|
|
|
|
|
</div>
|
2023-01-13 17:04:59 -05:00
|
|
|
|
2023-07-01 00:50:47 -04:00
|
|
|
<hr />
|
2023-01-13 17:04:59 -05:00
|
|
|
|
2023-07-18 13:19:39 -05:00
|
|
|
<div class="immich-scrollbar max-h-[75vh] min-h-[300px] gap-4 overflow-y-auto p-4 pb-4">
|
|
|
|
|
<div class="flex w-full flex-col gap-2">
|
2023-07-01 00:50:47 -04:00
|
|
|
<p class="text-red-500">{$page.error?.message} ({$page.error?.code})</p>
|
|
|
|
|
{#if $page.error?.stack}
|
2024-06-04 21:53:00 +02:00
|
|
|
<label for="stacktrace">{$t('stacktrace')}</label>
|
2023-07-01 00:50:47 -04:00
|
|
|
<pre id="stacktrace" class="text-xs">{$page.error?.stack || 'No stack'}</pre>
|
|
|
|
|
{/if}
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
2023-01-13 17:04:59 -05:00
|
|
|
|
2023-07-01 00:50:47 -04:00
|
|
|
<hr />
|
2023-01-13 17:04:59 -05:00
|
|
|
|
2023-07-18 13:19:39 -05:00
|
|
|
<div class="flex place-content-center place-items-center justify-around">
|
2023-07-01 00:50:47 -04:00
|
|
|
<!-- href="https://github.com/immich-app/immich/issues/new" -->
|
|
|
|
|
<a
|
2024-06-14 02:27:01 +02:00
|
|
|
href="https://discord.immich.app"
|
2023-07-01 00:50:47 -04:00
|
|
|
target="_blank"
|
|
|
|
|
rel="noopener noreferrer"
|
2023-07-18 13:19:39 -05:00
|
|
|
class="flex grow basis-0 justify-center p-4"
|
2023-07-01 00:50:47 -04:00
|
|
|
>
|
2024-05-27 09:06:15 +02:00
|
|
|
<div class="flex flex-col place-content-center place-items-center gap-2">
|
2023-10-25 09:48:25 -04:00
|
|
|
<Icon path={mdiMessage} size={24} />
|
2024-06-04 21:53:00 +02:00
|
|
|
<p class="text-sm">{$t('get_help')}</p>
|
2024-05-27 09:06:15 +02:00
|
|
|
</div>
|
2023-07-01 00:50:47 -04:00
|
|
|
</a>
|
2023-01-13 17:04:59 -05:00
|
|
|
|
2023-07-01 00:50:47 -04:00
|
|
|
<a
|
|
|
|
|
href="https://github.com/immich-app/immich/releases"
|
|
|
|
|
target="_blank"
|
|
|
|
|
rel="noopener noreferrer"
|
2023-07-18 13:19:39 -05:00
|
|
|
class="flex grow basis-0 justify-center p-4"
|
2023-07-01 00:50:47 -04:00
|
|
|
>
|
2024-05-27 09:06:15 +02:00
|
|
|
<div class="flex flex-col place-content-center place-items-center gap-2">
|
2023-10-25 09:48:25 -04:00
|
|
|
<Icon path={mdiPartyPopper} size={24} />
|
2024-06-04 21:53:00 +02:00
|
|
|
<p class="text-sm">{$t('read_changelog')}</p>
|
2024-05-27 09:06:15 +02:00
|
|
|
</div>
|
2023-07-01 00:50:47 -04:00
|
|
|
</a>
|
2023-01-13 17:04:59 -05:00
|
|
|
|
2023-07-01 00:50:47 -04:00
|
|
|
<a
|
|
|
|
|
href="https://immich.app/docs/guides/docker-help"
|
|
|
|
|
target="_blank"
|
|
|
|
|
rel="noopener noreferrer"
|
2023-07-18 13:19:39 -05:00
|
|
|
class="flex grow basis-0 justify-center p-4"
|
2023-07-01 00:50:47 -04:00
|
|
|
>
|
2024-05-27 09:06:15 +02:00
|
|
|
<div class="flex flex-col place-content-center place-items-center gap-2">
|
2023-10-25 09:48:25 -04:00
|
|
|
<Icon path={mdiCodeTags} size={24} />
|
2024-06-04 21:53:00 +02:00
|
|
|
<p class="text-sm">{$t('check_logs')}</p>
|
2024-05-27 09:06:15 +02:00
|
|
|
</div>
|
2023-07-01 00:50:47 -04:00
|
|
|
</a>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
2022-08-24 21:10:48 -07:00
|
|
|
</div>
|