From 3ed200a85c7b0c180a2d1c7a4b99b40c9f647ecd 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 15:10:03 +0100
Subject: [PATCH] fix(ui): let request rows wrap on narrow screens
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
On a phone, request rows in My leave, Approvals and HR Absences cut the
name, the leave type and the dates with an ellipsis, while the status
chip, the clash chip and the waiting time kept their full width.
When a row is narrower than 512 px it now stacks: the name and the date
line wrap, each part of the date line stays on one line, and the waiting
time and the chips move under them. A container query decides, so a
list next to the open sidebar stacks too. Wider rows keep their layout.
Assisted-by: ClaudeCode:claude-opus-5-5
Signed-off-by: John Molakvoæ <14975046+skjnldsv@users.noreply.github.com>
---
SPECIFICATION.md | 5 ++-
src/components/RequestListItem.vue | 53 +++++++++++++++++++++++++++---
2 files changed, 53 insertions(+), 5 deletions(-)
diff --git a/SPECIFICATION.md b/SPECIFICATION.md
index 1ffcd736..82f8d9e8 100644
--- a/SPECIFICATION.md
+++ b/SPECIFICATION.md
@@ -1589,7 +1589,10 @@ generic form-over-table CRUD tool.
`prefers-reduced-motion` and high-contrast themes. Playfulness decorates; it never
carries meaning alone.
- **Responsive.** Works from mobile width up; navigation collapses per Nextcloud
- behavior; tables become card lists on narrow screens.
+ behavior; tables become card lists on narrow screens. A request row narrower than
+ 512 px (a phone, or a list next to the open sidebar) stacks: the name and the
+ date line wrap instead of being cut, and the waiting time and the chips go under
+ them.
### 15.1 App shell & layout (standard three-region Nextcloud frame)
diff --git a/src/components/RequestListItem.vue b/src/components/RequestListItem.vue
index f7173144..6a3140c0 100644
--- a/src/components/RequestListItem.vue
+++ b/src/components/RequestListItem.vue
@@ -13,7 +13,10 @@
{{ type.icon }}
- {{ subtitle }}
+
+ ·
+ {{ part }}
+
{{ waiting.label }}
@@ -101,19 +104,20 @@ const title = computed(() => {
return type.value.label
})
+/** The parts of the date line, each kept on one line when the row wraps. */
const subtitle = computed(() => {
const range = formatRange(props.request.startDate, props.request.endDate)
const days = n('absence', '%n day', '%n days', props.request.workingDays)
const after = props.request.decision?.availableAfter
if (after !== undefined && after !== null) {
- return `${range} · ${days} · ${n('absence', '%n available after', '%n available after', Math.round(after * 10) / 10)}`
+ return [range, days, n('absence', '%n available after', '%n available after', Math.round(after * 10) / 10)]
}
if (props.available === null) {
- return `${range} · ${days}`
+ return [range, days]
}
// Days taken alone does not answer the question the list is scanned for.
const available = n('absence', '%n available', '%n available', Math.round(props.available * 10) / 10)
- return `${range} · ${days} · ${available}`
+ return [range, days, available]
})
/**
@@ -136,6 +140,7 @@ function select(event?: MouseEvent) {