From 0a327f64bd0ebe4cb41269f89b196d003721db77 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?John=20Molakvo=C3=A6?=
<14975046+skjnldsv@users.noreply.github.com>
Date: Tue, 17 Nov 2026 13:12:41 +0100
Subject: [PATCH 1/2] fix(ui): make list rows, page headers and page widths
consistent
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Sick leave and other HR-recorded rows had no status chip once booked, while
every other row had one. They now show a "Recorded" chip, in the lists and
in the request sidebar; the approval stepper stays hidden for them.
My leave and Absences repeated the navigation's "New request" and "Record
absence" as header buttons. These header buttons now only show while the
app navigation is closed, so each action is offered once.
Centered reading-width pages pushed their title about 50 px right of their
content, to clear the navigation toggle, while full-width pages did not.
The shared page wrapper now keeps the whole page clear of the toggle and
left-aligned: every view has its title on the content's left edge, tables
and timelines use the full width, forms, lists and cards a reading width.
Assisted-by: ClaudeCode:claude-opus-5-5
Signed-off-by: John Molakvoæ <14975046+skjnldsv@users.noreply.github.com>
---
SPECIFICATION.md | 16 +++++++++-----
src/App.vue | 6 -----
src/components/RequestListItem.vue | 6 ++---
src/components/RequestSidebar.vue | 9 ++++----
src/components/StatusChip.vue | 4 ++--
src/stores/leaveTypes.spec.ts | 12 +++++-----
src/stores/leaveTypes.ts | 12 +++++-----
src/styles/page.scss | 35 ++++++++++++++++++++++++++----
src/types/requests.ts | 3 +++
src/utils/status.spec.ts | 2 +-
src/utils/status.ts | 6 +++--
src/views/MyLeave.vue | 2 +-
src/views/hr/HrAbsences.vue | 2 +-
13 files changed, 73 insertions(+), 42 deletions(-)
diff --git a/SPECIFICATION.md b/SPECIFICATION.md
index 55ca6ce7..9e512cea 100644
--- a/SPECIFICATION.md
+++ b/SPECIFICATION.md
@@ -609,9 +609,10 @@ employees — sick leave is the canonical example (`employee_requestable = false
edits or cancels it from the standard detail sidebar. There is **no delete**: a wrong
entry is cancelled (`CANCELLED`), so the row and its history stay intact for the audit
trail (§17). HR's cancel skips the withdrawal step and applies immediately (§5.5).
-- **No "Approved" label shown.** Since approval isn't a concept for HR-recorded leave,
- the UI hides the status chip and the approval **progress stepper** when such a request
- is `APPROVED` (a cancelled one still shows its status). The leave-type chip (e.g.
+- **"Recorded", not "Approved".** Since approval isn't a concept for HR-recorded leave,
+ the status chip reads **Recorded** and the approval **progress stepper** is hidden when
+ such a request is `APPROVED` (a cancelled one still shows its status). Every row of a
+ list carries a chip, so these rows look like the others. The leave-type chip (e.g.
"🤒 Sick leave") still identifies it.
---
@@ -1587,8 +1588,13 @@ NcContent(app-name="absence")
count adds the escalated requests, which HR decides on that page. HR sees
the *HR* section (grouped under an `NcAppNavigationCaption`). Every item uses an
`@mdi` icon. The **`NcAppNavigationNew` "New request"** button sits at the top as the
- single prominent primary action.
-- **Center `NcAppContent`** hosts the routed view.
+ single prominent primary action. A page header button that repeats a navigation action
+ (*New request* on My leave, *Record absence* on Absences) only shows while the
+ navigation is closed, so there is always exactly one.
+- **Center `NcAppContent`** hosts the routed view. Every view uses the one page wrapper
+ (`src/styles/page.scss`): title and content share the same left edge, clear of the
+ navigation toggle; tables and timelines take the full width, forms, lists and cards
+ stop at a reading width.
- **Right `NcAppSidebar`** opens when a request is selected, with tabbed detail
(Details / Coverage / Comments / History) — the standard Nextcloud master-detail
pattern, used instead of a modal for *viewing* a request. Each comment shows when it
diff --git a/src/App.vue b/src/App.vue
index 6ccfaeca..d4020b35 100644
--- a/src/App.vue
+++ b/src/App.vue
@@ -338,10 +338,4 @@ function onChanged(): void {
// The page shell and table styles every view builds on. Global on purpose —
// see the file header.
@use './styles/page.scss';
-
-// Keep the page titles clear of the floating app-navigation toggle button,
-// which overlays the top-left corner of the content area (applies to every view).
-.app-absence .page__header {
- padding-inline-start: calc(var(--default-clickable-area, 44px) + var(--app-navigation-padding, 4px) * 2);
-}
diff --git a/src/components/RequestListItem.vue b/src/components/RequestListItem.vue
index b3bfbae4..16f31fb5 100644
--- a/src/components/RequestListItem.vue
+++ b/src/components/RequestListItem.vue
@@ -23,7 +23,7 @@
⚠️
{{ othersOff.label }}
-
+
@@ -65,9 +65,7 @@ const leaveTypesStore = useLeaveTypesStore()
const type = computed(() => leaveTypesStore.leaveType(props.request.typeId))
// On a decision queue every row waits, so the status only tells a withdrawal apart
-const showStatus = computed(() => props.request.decision
- ? props.request.status === 'WITHDRAWAL_PENDING'
- : leaveTypesStore.statusVisible(props.request))
+const showStatus = computed(() => !props.request.decision || props.request.status === 'WITHDRAWAL_PENDING')
const waiting = computed(() => {
const since = props.request.decision?.waitingSince
diff --git a/src/components/RequestSidebar.vue b/src/components/RequestSidebar.vue
index 9f900569..32e21e3a 100644
--- a/src/components/RequestSidebar.vue
+++ b/src/components/RequestSidebar.vue
@@ -8,8 +8,8 @@
:name="type.label"
:subname="subLabel"
@close="$emit('close')">
-
-
+
+
@@ -22,7 +22,7 @@
{{ shortNoticeLabel }}
-
+
- {{ t('absence', 'Employee') }}
-
@@ -430,7 +430,8 @@ const shortNoticeLabel = computed(() => {
/** A confidential absence seen by someone outside HR: no category, no thread. */
const withheld = computed(() => detail.value?.typeId === null)
-const showStatus = computed(() => detail.value ? leaveTypesStore.statusVisible(detail.value) : true)
+/** Leave HR booked without an approval: there are no steps to show */
+const recorded = computed(() => detail.value !== null && leaveTypesStore.displayStatus(detail.value) === 'RECORDED')
const isDecidable = computed(() => detail.value !== null && ['PENDING', 'ESCALATED', 'WITHDRAWAL_PENDING'].includes(detail.value.status))
diff --git a/src/components/StatusChip.vue b/src/components/StatusChip.vue
index 17c63bdf..bcc71712 100644
--- a/src/components/StatusChip.vue
+++ b/src/components/StatusChip.vue
@@ -10,13 +10,13 @@