-
released this
2026-02-21 15:59:32 +01:00 | 75 commits to main since this release📅 Originally published on GitHub: Sat, 21 Feb 2026 15:00:09 GMT
🏷️ Git tag created: Sat, 21 Feb 2026 14:59:32 GMTTip
Human here: re-connected my keyboard for a second to give a Big Fat Well Done to Claude on this one, being the first code agent to succesfully add a light theme this far in the development cycle (aka very late) on the basis of 1 inquiring, and 1 clarifying prompt. With zero mistakes, up to and including releasing the new feature here.
What's new
Adds full light and dark colour themes, with a System option (the new default) that follows your OS preference in real time.
Settings → Appearance
A new Light / System / Dark toggle sits between Work week and About in Settings. The choice is saved to
localStorageand takes effect instantly — no page reload.Technical highlights
- No flash on load — an inline
<head>script applies the correct.darkclass before the first paint, so there's never a visible flicker - Live OS sync — selecting System registers a
prefers-color-schememedia-query listener; switching your phone or Mac between light and dark updates the app immediately without touching Settings - CSS variable split —
:rootis now the light palette;.darkholds the original dark palette; every existingbg-background,text-muted-foreground, etc. adapts automatically - Browser chrome aware — two
<meta name="theme-color">tags withmediaattributes keep the address bar colour in sync with the active scheme - 18 new unit tests covering all theme utility functions (
getStoredTheme,setStoredTheme,applyTheme,resolveTheme,getSystemTheme)
Files changed
File Change src/index.css:root→ light palette;.dark→ original dark palettesrc/lib/theme.tsNew — pure theme utilities src/context/ThemeContext.tsxNew — ThemeProvider+useThemehooksrc/components/ThemeSetting.tsxNew — Settings UI component src/lib/__tests__/theme.test.tsNew — 18 unit tests index.htmlAnti-flash inline script; dual theme-colormeta tagsvitest.config.tsNew — vitest config (jsdom) package.json0.9.0 → 0.10.0; addedvitest+jsdomdevDepsScreenshots (
docs/screenshots/settings.png) may need regenerating to show the new Appearance card.Downloads
-
Source code (ZIP)
0 downloads
-
Source code (TAR.GZ)
0 downloads
- No flash on load — an inline
mirror of
https://github.com/niels-emmer/time-keeper.git
synced 2026-09-13 23:53:35 +02:00