fix: show midnight "0" hour label - was clipped above scroll area

The first time-slot label's translateY(-50%) pushed it above the container
top edge. Added padding-top to time-column-slots and time-slots-container,
and disabled the translate on the first label. Reverted 00→0.

v1.75.5

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
mARTin 2026-03-26 11:06:03 +01:00
parent 94747a9508
commit b126328536
3 changed files with 9 additions and 4 deletions

View File

@ -1,6 +1,6 @@
{ {
"name": "my-weekly-todo-list", "name": "my-weekly-todo-list",
"version": "1.75.4", "version": "1.75.5",
"description": "A web-based weekly task management application that organizes to-dos and calendar events in a single, intuitive weekly view", "description": "A web-based weekly task management application that organizes to-dos and calendar events in a single, intuitive weekly view",
"main": "index.js", "main": "index.js",
"scripts": { "scripts": {

View File

@ -2863,7 +2863,12 @@ h3 {
flex: 1; flex: 1;
overflow-y: visible; /* Unify with parent scroll */ overflow-y: visible; /* Unify with parent scroll */
position: relative; position: relative;
padding-top: 0; /* Flush with header */ padding-top: 0.5em; /* Space for first hour label translateY */
}
/* First hour label: don't translate above container edge */
.time-column-slots .time-slot-label:first-child span {
transform: none;
} }
@ -2913,7 +2918,7 @@ h3 {
flex: 1; flex: 1;
overflow: visible; /* Changed from auto to unify scroll */ overflow: visible; /* Changed from auto to unify scroll */
overflow-x: visible; overflow-x: visible;
padding-top: 0; /* Flush with header */ padding-top: 0.5em; /* Match time-column-slots for alignment */
} }
.time-slot { .time-slot {

View File

@ -1440,7 +1440,7 @@ function formatHour(hour: number, minutes: number = 0, format: "short" | "full"
} }
// 24h format // 24h format
if (format === "short" && minutes === 0) { if (format === "short" && minutes === 0) {
return hour === 0 ? "00" : `${hour}`; return `${hour}`;
} }
return `${hour.toString().padStart(2, "0")}:${minutes.toString().padStart(2, "0")}`; return `${hour.toString().padStart(2, "0")}:${minutes.toString().padStart(2, "0")}`;
} }