fix(ui): restore the pre-rebrand gittensory_ legacy localStorage keys - #7895
fix(ui): restore the pre-rebrand gittensory_ legacy localStorage keys#7895shin-core wants to merge 1 commit into
Conversation
JSONbored#5743's blanket gittensory->loopover rename overwrote two localStorage legacy-key string literals that were supposed to keep the OLD prefix, so useLocalStorage's migration fallback read the same key it had just missed under -- silently dropping a pre-rebrand preference. Restore LEGACY_DISMISS_KEY in onboarding-preview-card and the notification opt-in legacy key in notification-readiness-card to their gittensory_-prefixed values (matching the still-correct try-it.tsx pattern), so a maintainer's pre-rebrand onboarding dismissal / notification opt-in migrates forward instead of appearing lost. Adds a regression test per component that seeds the legacy key and asserts the value is read forward to the current key.
|
🚨 Contributor flagged. Click here for more info: Superagent Dashboard |
|
Caution 🛑 LoopOver review result - fixes requiredReview updated: 2026-07-21 16:32:18 UTC
Review summary Nits — 3 non-blocking
CI checks failing
Flagged checks (non-blocking)
Decision drivers
Context & advisory signals — never blocks the verdict
Linked issue satisfactionAddressed Review context
Contributor next steps
Signal definitions
🧪 Chat with LoopOverAsk LoopOver a question about this PR directly in a comment — grounded only in the same cached, public-safe facts shown above, never a new claim.
Full command reference: https://loopover.ai/docs/loopover-commands 🧪 Experimental — new and may change. Visual preview
Click any thumbnail to open the full-size screenshot. Before = production · After = this PR's preview deploy. Scroll preview
A short scroll-through clip (desktop) — click either thumbnail to open the full animation. Evidence for scroll-linked behavior a single screenshot can't show. 🟩 Safe / merged · 🟦 Advisory · 🟨 Held for review · 🟥 Blocked / closed 💰 Earn for open-source contributions like this. Gittensor lets GitHub contributors earn for the work they already do — register to start earning →. Checked by LoopOver, a quiet PR intelligence layer for OSS maintainers.
|
|
This pull request changes UI/visual code but its screenshot evidence is incomplete. Every required viewport × theme combination needs its own before/after image pair in a labeled table row (e.g. "Desktop · Light | before | after"). Still missing: Desktop · Dark, Tablet · Dark, Mobile · Dark. Please resubmit with the remaining rows filled in. See https://github.com/JSONbored/loopover/blob/main/.claude/skills/contributing-to-loopover/SKILL.md for the exact format and examples. This is an automated maintenance action. |


What & why
Closes #7782.
Commit
112bc4a83(#5405) gaveuseLocalStoragealegacyKeyparam so a pre-rebrandgittensory_*localStorage value migrates forward to the newloopover_*key. Two days later81e4ac34d(#5743, the fullgittensory→loopovercutover) did a blanket text substitution that also rewrote two string literals that were supposed to keep the old prefix:onboarding-preview-card.tsx—LEGACY_DISMISS_KEYbecame identical to the currentDISMISS_KEY.notification-readiness-card.tsx— the notification opt-in legacy key became identical to its current key.With
key === legacyKey,useLocalStorage's fallback reads the same key it just missed under, so a maintainer who dismissed the onboarding card or opted into notifications before the rebrand silently loses that preference (the card reappears / notifications default back to off). Every other rebrand-migrated key (try-it.tsx'sgittensory.session_token, etc.) survived intact.The fix
Restore both legacy keys to their pre-rebrand
gittensory_-prefixed literals, matching the still-correcttry-it.tsxpattern. No other legacy keys are touched. This is a string-literal-only change — nothing rendered changes, so there's no visual diff.Tests
A regression test per component, extending the existing test file:
gittensory_maintainer_onboarding_preview_dismissedand asserts the card stays hidden, the demo API call is skipped, and the value is written forward to the current key.gittensory_notification_opt_inand asserts the pill shows "opt-in enabled" and the value is migrated to the current key.Verified bug-catching: reverting either key to the corrupted
loopover_value fails its regression test.Validation
apps/loopover-ui:vitest run(both files, 11 tests) pass;tsc --noEmitexit 0; eslint clean; Prettier clean.apps/loopover-uiis not under thesrc/**99% patch gate (UI-only path); the regression tests are the coverage deliverable. Branched off currentmain, mergeable-clean.