chore: refresh types and formatting

This commit is contained in:
2026-06-24 13:56:41 +01:00
parent 44bfb083f9
commit 2339fa02f8
6 changed files with 26 additions and 28 deletions
+6 -4
View File
@@ -1,19 +1,21 @@
<script lang="ts">
import HomeIcon from '@lucide/svelte/icons/home';
import RefreshCwIcon from '@lucide/svelte/icons/refresh-cw';
import { resolve } from '$app/paths';
import { page } from '$app/state';
import { Button } from '$lib/components/ui/button/index.js';
const status = $derived(page.status);
const message = $derived(page.error?.message ?? 'Something went wrong.');
const currentPath = $derived(page.url.pathname);
const title = $derived(status === 404 ? message : 'Something went wrong');
const description = $derived(
status === 404
? 'This item may be archived, deleted, or unavailable in the active organization.'
: 'The dashboard could not finish loading this view.'
);
function retry() {
window.location.reload();
}
</script>
<svelte:head>
@@ -29,11 +31,11 @@
</div>
<div class="flex justify-center gap-2">
<Button href={resolve('/dashboard')} variant="outline">
<Button href="/dashboard" variant="outline">
<HomeIcon data-icon="inline-start" />
Dashboard
</Button>
<Button href={currentPath}>
<Button onclick={retry}>
<RefreshCwIcon data-icon="inline-start" />
Retry
</Button>
@@ -46,7 +46,6 @@
dueDate: string;
lines: BillingLine[];
clients: BillingClient[];
totalGbp: number;
};
formatMoney: (value: unknown) => string;
formatDate: (value: unknown) => string;
@@ -35,7 +35,13 @@
<Dialog.Description>Update this contract record.</Dialog.Description>
</Dialog.Header>
{#if editingRecord}
<form id="edit-contract-form" method="POST" action="?/edit" class="grid gap-2" use:enhanceEdit>
<form
id="edit-contract-form"
method="POST"
action="?/edit"
class="grid gap-2"
use:enhanceEdit
>
<input type="hidden" name="id" value={$editData.id} />
<ContractFormFields form={editForm} data={editData} {options} prefix="edit" />
</form>