From a91ee1f26d580bac073f598ec1d696f1ec4a420f Mon Sep 17 00:00:00 2001 From: Marcel Date: Sat, 25 Apr 2026 19:41:24 +0200 Subject: [PATCH] refactor(documents): unify count + action links into one row Move result count, bulk-edit button, and new-document link into a shared flex row so they appear on the same line. Adds an edit icon to the bulk-edit button to visually match the existing plus icon on the add link. Co-Authored-By: Claude Sonnet 4.6 --- frontend/src/routes/DocumentList.svelte | 25 --------- frontend/src/routes/documents/+page.svelte | 64 +++++++++++++++------- 2 files changed, 45 insertions(+), 44 deletions(-) diff --git a/frontend/src/routes/DocumentList.svelte b/frontend/src/routes/DocumentList.svelte index d982a46a..6ec6dd83 100644 --- a/frontend/src/routes/DocumentList.svelte +++ b/frontend/src/routes/DocumentList.svelte @@ -13,14 +13,12 @@ let { items, canWrite, error, - total = 0, q = '', sort = 'DATE' }: { items: DocumentSearchItem[]; canWrite: boolean; error?: string | null; - total?: number; q?: string; sort?: SortMode; } = $props(); @@ -71,29 +69,6 @@ function groupByReceiver(docItems: DocumentSearchItem[]) { } - -
- {#if canWrite} - - - {m.docs_btn_new()} - - {/if} -
- - -{#if total > 0} -

{m.docs_result_count({ count: total })}

-{/if} - {#if error}
diff --git a/frontend/src/routes/documents/+page.svelte b/frontend/src/routes/documents/+page.svelte index 40e9db49..60c0c299 100644 --- a/frontend/src/routes/documents/+page.svelte +++ b/frontend/src/routes/documents/+page.svelte @@ -234,28 +234,54 @@ $effect(() => { onblur={() => (qFocused = false)} /> - {#if data.canWrite && data.totalElements > 0} -
- - {#if editAllError} - - {/if} -
- {/if} +
+

+ {#if data.totalElements > 0}{m.docs_result_count({ count: data.totalElements })}{/if} +

+ {#if data.canWrite} +
+
+ {#if data.totalElements > 0} + + {/if} + + + {m.docs_btn_new()} + +
+ {#if editAllError} + + {/if} +
+ {/if} +