From d358d39ee06b6e5c66fe5a2edaba3d388d1f550b Mon Sep 17 00:00:00 2001 From: Sergio Arroutbi Date: Fri, 17 Apr 2026 15:31:42 +0200 Subject: [PATCH] Add FR-079: date format selection New functional requirement allowing users to choose a date display format (YYYY/MM/DD, DD/MM/YYYY, MM/DD/YYYY, YYYY-MM-DD, DD-MM-YYYY, MM-DD-YYYY) in Visualization Settings. Includes summary table entry and detailed section with four Gherkin acceptance scenarios. Co-Authored-By: Claude Opus 4.6 Signed-off-by: Sergio Arroutbi --- spec/SDD-Keylime-Monitoring-Tool.md | 2 ++ spec/SRS-Keylime-Monitoring-Tool.md | 35 +++++++++++++++++++++++++++++ 2 files changed, 37 insertions(+) diff --git a/spec/SDD-Keylime-Monitoring-Tool.md b/spec/SDD-Keylime-Monitoring-Tool.md index 8c29a03..d73ffed 100644 --- a/spec/SDD-Keylime-Monitoring-Tool.md +++ b/spec/SDD-Keylime-Monitoring-Tool.md @@ -1037,6 +1037,7 @@ Maximum 5 parallel concurrent log fetches to the Verifier API, enforced via Toki | Mock/Production URL presets | Reduces configuration friction; auto-detects active mode from saved URLs | FR-074 | | `#[serde(default)]` on Keylime models | Tolerates missing/renamed fields across Keylime API versions without breaking deserialization | NFR-002 | | Timezone auto-detect with manual override | Default to browser timezone for zero-config; IANA dropdown for operators in different timezones than their fleet | FR-078 | +| Explicit date format selection | Eliminates locale-dependent ambiguity (e.g., 04/05 = April 5 vs May 4); ISO 8601 default for cross-region consistency | FR-079 | --- @@ -1133,6 +1134,7 @@ Maximum 5 parallel concurrent log fetches to the Verifier API, enforced via Toki | FR-076 | 3.2.2 | Layout hamburger button, sidebar CSS transition | | FR-077 | 3.2.2, 3.7.3 | 1s polling via `refetchInterval`, `probe_verifier()`/`probe_registrar()` | | FR-078 | 3.8.2 | `visualizationStore`: timezone with auto-detect, IANA timezone dropdown in Settings | +| FR-079 | 3.8.2 | `visualizationStore`: date format selection (6 formats), ISO 8601 default, applied to all timestamp rendering | ### 6.2 Non-Functional Requirements diff --git a/spec/SRS-Keylime-Monitoring-Tool.md b/spec/SRS-Keylime-Monitoring-Tool.md index c83814f..be945d2 100644 --- a/spec/SRS-Keylime-Monitoring-Tool.md +++ b/spec/SRS-Keylime-Monitoring-Tool.md @@ -112,6 +112,7 @@ The System transforms Keylime from a CLI-driven security tool into a visual oper | FR-076 | Sidebar visibility toggle (hamburger button) | MUST | Dashboard - Navigation Structure | | FR-077 | Webtool backend health check with polling | MUST | Integration Status - Backend Connectivity | | FR-078 | Timezone selection with auto-detect | SHOULD | Settings - Visualization | +| FR-079 | Date format selection for timestamp rendering | MUST | Settings - Visualization | ### 2.2 Non-Functional Requirements @@ -2436,6 +2437,40 @@ Feature: Timezone Selection And the user MUST be able to select a different timezone ``` +### FR-079: Date Format Selection for Timestamp Rendering + +**Description:** The System MUST provide a date format setting in the Visualization Settings section, alongside the timezone setting (FR-078). The user MUST be able to select a date display format from the following options: `YYYY/MM/DD`, `DD/MM/YYYY`, `MM/DD/YYYY`, `YYYY-MM-DD`, `DD-MM-YYYY`, `MM-DD-YYYY`. The default SHOULD be `YYYY-MM-DD` (ISO 8601). The selected format MUST be persisted in localStorage via the visualization store. The selected format MUST be applied consistently to all timestamp and date rendering across the dashboard, including the agent list, agent detail timeline, audit log, alerts, and dashboard charts. + +**Trace:** Settings - Visualization + +```gherkin +Feature: Date Format Selection + + Scenario: Select a date format + Given the user navigates to Settings > Visualization + When the user selects "DD/MM/YYYY" from the date format dropdown + Then all timestamps across the dashboard MUST render dates in DD/MM/YYYY format + And the date format dropdown MUST show "DD/MM/YYYY" as the active selection + + Scenario: Date format persists across sessions + Given the user has selected "MM/DD/YYYY" as the date format + When the user closes and reopens the browser + Then the date format MUST remain "MM/DD/YYYY" + And all timestamps MUST render in MM/DD/YYYY format without requiring reconfiguration + + Scenario: Date format applied to agent list timestamps + Given the user has selected "YYYY-MM-DD" as the date format + When the user navigates to the Agent Fleet list view + Then the "Last Attestation" column timestamps MUST render dates in YYYY-MM-DD format + And the "Registration Date" column timestamps MUST render dates in YYYY-MM-DD format + + Scenario: Default date format on first visit + Given the user has never configured a date format preference + When the user navigates to any page displaying timestamps + Then timestamps SHOULD render dates in YYYY-MM-DD (ISO 8601) format + And the Settings > Visualization date format dropdown SHOULD show "YYYY-MM-DD" as the default +``` + --- ## 4. Non-Functional Requirements Detail