You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
feat: redesign countdown timer UI and migrate to TypeScript - #8
Redesigns the Countdown Timer to match the new look of the Clock and Simple Timer apps, and moves it onto the shared @screenly/edge-apps TypeScript stack.
UI
Dark canvas with a brand-accent glow at the top (light theme when the brand color is light), same as the Clock app
Headline as a tracked uppercase label; large Inter digits for days / hours / minutes / seconds, seconds in the accent color
Unit labels and dates are localized via Intl (e.g. "jours", "Stunden")
Thin progress bar from starting_timestamp to target_timestamp, with the start and target dates underneath (hidden if the start is not before the target)
When the countdown ends, countdown_end_text replaces the digits (replaces the old circular overlay)
2×2 unit grid in portrait
Removed: "Powered by Screenly" brand logo card and the day/date card
Under the hood
TypeScript + Bun + edge-apps-scripts, same setup as Clock / Simple Timer
Drops moment.js and all vendored scripts/fonts in static/
Naive timestamps (YYYY-MM-DDTHH:MM:SS) are read as wall-clock time in the screen's timezone, now DST-correct; explicit offsets (Z, +02:00) are respected
Sentry via setupSentry, error handling via setupErrorHandling
screenly.yml settings migrated to schema_version: 1 help text with display order / advanced flags; added display_errors
Added checks.yml workflow, unit tests, screenshot spec and screenshots for all resolutions; README rewritten
Rebuild the app on @screenly/edge-apps with Bun/Vite, following the
visual language of the redesigned clock and simple-timer apps.
- Dark canvas with brand-accent radial wash and light-brand variant
- Large Inter digits with localized unit labels, accent seconds
- Start-to-target progress bar with localized dates
- End text replaces the digits when the countdown finishes
- 2x2 unit grid in portrait
- DST-correct parsing of naive timestamps in the screen's timezone
- Drop moment.js and vendored static scripts/fonts
- Settings migrated to schema_version 1 help text; add display_errors
- Unit tests, screenshot spec and generated screenshots
- Reject out-of-range dates/times (e.g. 2028-02-31) instead of letting
Date.UTC roll them over
- Resolve wall-clock times with Temporal 'compatible' disambiguation:
spring-forward gaps move forward, fall-back overlaps take the earlier
instant
- Use a repository-relative README screenshot path
The reason will be displayed to describe this comment to others. Learn more.
🔵 Needs a closer look
An active moderate issue allows documented explicit-offset timestamps with invalid calendar fields to be silently normalized by Date, so invalid countdown settings are not reliably rejected.
No open issues 🎉
1 previously missed issue
In code that hasn't changed since last review
Validate date and time components in offset-bearing timestamps
src/countdown.ts:98
The component validation only runs when NAIVE_TIMESTAMP matches. An explicit-offset value (which the README documents as supported) takes this branch and is delegated to Date, which normalizes out-of-range fields: 2028-02-31T00:00:00Z becomes 2028-03-02T00:00:00.000Z instead of being rejected. Apply the same calendar/time-component validation to offset-bearing ISO timestamps before accepting them, so invalid target or start settings cannot silently move the countdown.
Parse explicit-offset ISO timestamps (Z, ±HH:MM, ±HHMM) with the same
component validation as naive ones instead of delegating to Date, which
normalizes out-of-range fields. Non-ISO strings are now rejected.
Addressed Copilot's Validate date and time components in offset-bearing timestamps in ebb9179: parseTimestamp now parses Z / ±HH:MM / ±HHMM timestamps itself and applies the same component validation as naive ones (so 2028-02-31T00:00:00Z, 25:00, +24:00 and +05:60 are rejected) instead of falling back to Date. Non-ISO strings are rejected too. Tests added.
The reason will be displayed to describe this comment to others. Learn more.
🟡 Changes recommended
A moderate active finding shows fractional-second timestamps are silently truncated, causing countdowns to finish early and contradicting documented and tested behavior.
The reason will be displayed to describe this comment to others. Learn more.
🔵 Needs a closer look
Human assessment is needed because an invalid target_timestamp can be treated as successful startup while showing a misleading zero countdown, leaving configuration failure unclear to users.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Redesigns the Countdown Timer to match the new look of the Clock and Simple Timer apps, and moves it onto the shared
@screenly/edge-appsTypeScript stack.UI
Intl(e.g. "jours", "Stunden")starting_timestamptotarget_timestamp, with the start and target dates underneath (hidden if the start is not before the target)countdown_end_textreplaces the digits (replaces the old circular overlay)Under the hood
edge-apps-scripts, same setup as Clock / Simple Timerstatic/YYYY-MM-DDTHH:MM:SS) are read as wall-clock time in the screen's timezone, now DST-correct; explicit offsets (Z,+02:00) are respectedsetupSentry, error handling viasetupErrorHandlingscreenly.ymlsettings migrated toschema_version: 1help text with display order / advanced flags; addeddisplay_errorschecks.ymlworkflow, unit tests, screenshot spec and screenshots for all resolutions; README rewritten