fix(enrich): use fixed positioning for fullscreen layout and fix done icon
Align enrich/[id] with the document detail page pattern: position fixed with runtime header height measurement instead of a hardcoded calc value. The root layout is reverted to its original simple form with no per-route detection. Also replaces the missing check icon on the done page with Check-Double-LG from the icon library. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
<script lang="ts">
|
||||
import { enhance } from '$app/forms';
|
||||
import { untrack } from 'svelte';
|
||||
import { onMount, untrack } from 'svelte';
|
||||
import { m } from '$lib/paraglide/messages.js';
|
||||
import DocumentViewer from '$lib/components/DocumentViewer.svelte';
|
||||
import WhoWhenSection from '$lib/components/document/WhoWhenSection.svelte';
|
||||
@@ -15,6 +15,11 @@ let fileUrl = $state('');
|
||||
let fileError = $state('');
|
||||
let isLoading = $state(false);
|
||||
|
||||
let navHeight = $state(0);
|
||||
onMount(() => {
|
||||
navHeight = document.querySelector('header')?.getBoundingClientRect().height ?? 0;
|
||||
});
|
||||
|
||||
// Dummy bindable state required by DocumentViewer
|
||||
let annotateMode = $state(false);
|
||||
let activeAnnotationId = $state<string | null>(null);
|
||||
@@ -52,7 +57,7 @@ let selectedReceivers = $state(untrack(() => doc.receivers ?? []));
|
||||
<title>{doc.title || doc.originalFilename || 'Dokument'} — Anreicherung</title>
|
||||
</svelte:head>
|
||||
|
||||
<div class="flex h-[calc(100vh-68px)] flex-col">
|
||||
<div class="fixed inset-x-0 bottom-0 flex flex-col" style="top: {navHeight}px">
|
||||
<!-- Top bar -->
|
||||
<div class="flex items-center justify-between border-b border-line bg-surface px-6 py-3">
|
||||
<a
|
||||
|
||||
@@ -7,7 +7,7 @@ import { m } from '$lib/paraglide/messages.js';
|
||||
class="border-brand-sand flex flex-col items-center justify-center rounded-sm border bg-white py-20 text-center shadow-sm"
|
||||
>
|
||||
<img
|
||||
src="/degruyter-icons/Simple/Large-32px/SVG/Action/Check/Check-Circle-LG.svg"
|
||||
src="/degruyter-icons/Simple/Large-32px/SVG/Action/Check/Check-Double-LG.svg"
|
||||
alt=""
|
||||
aria-hidden="true"
|
||||
class="mb-6 h-16 w-16"
|
||||
|
||||
Reference in New Issue
Block a user