Repository navigation
fix(console-ui): one legacy-theme migration for every console - #5479
Conversation
Why D1 (#5468) gave Delivery a copy of Tracker's theme.ts and theme.test.ts: the same migrateLegacyTheme, browser wrapper and tests with only the old key changed. main's jscpd ratchet now fails on that clone, and the repo-wide pre-commit hook rejects every commit until it is gone. What - console-ui exports migrateLegacyTheme(legacyKey, storage) and migrateLegacyThemeInBrowser(legacyKey) beside createThemeStore; its tests cover carry-over, shared-key-wins and no-op. - Delivery's and Tracker's theme.ts call it with their old key ("delivery-theme", "tracker.theme"); their duplicated tests are removed. Verification - `bun run jscpd`: baseline ratchet passed (failed on main 369ca51 before). - `bunx turbo run build typecheck test lint --filter=@shepherdjerred/console-ui --filter=@shepherdjerred/delivery --filter=@shepherdjerred/tracker`: pass. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
This change is part of the following stack: Change managed by git-spice. |
|
Automatic reviews are disabled for this repository. Configure in Code Review Settings. |
|
Important Review skippedAuto reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the
|
|
@codex review Automated re-review request for |
Codex Review Summary: ✅ CompletedThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
|
Codex Review: Didn't find any major issues. 👍 Reviewed commit: ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
If Codex has suggestions, it will comment; otherwise it will react with 👍. Codex can also answer questions or update the PR. Try commenting "@codex address that feedback". |
Why
D1 (#5468) gave Delivery a copy of Tracker's
theme.tsandtheme.test.ts: the samemigrateLegacyTheme, browser wrapper and tests, with only the old storage key changed. As a result:What
migrateLegacyTheme(legacyKey, storage)andmigrateLegacyThemeInBrowser(legacyKey)besidecreateThemeStore. Its tests cover:theme.tscall it with their own old key (delivery-theme,tracker.theme). Their duplicated tests are removed.Demo
None — mechanical move of an identical helper into the shared package, with no behaviour change. The browser storage migration is unchanged and still tested once in console-ui.
Verification
bun run jscpd: ratchet passed.bunx turbo run build typecheck test lint --filter=@shepherdjerred/console-ui --filter=@shepherdjerred/delivery --filter=@shepherdjerred/tracker: all pass.bunx lefthook run pre-commitpasses, including the repo-wide jscpd hook.🤖 Generated with Claude Code