Repository navigation
feat(settings): add dev-only update mocks and sidebar counts - #1844
Merged
Merged
Conversation
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Problem
Developers need a repeatable way to exercise update-related UI without waiting for a real release. Settings has no build-gated mock surface, and update/mock state is not visible as sidebar counts.
Solution
99.0.0) through the shared update availability state, so sidebar and chat start-page update actions appear. Keep native updater resources untouched; mock install/confirm/later actions only control the shared dialog, without downloading, installing, restarting or saving reminders.Potential risks
The shared update prompt and availability metadata projection also serve real updates; existing updater tests cover those paths, but an actual native install/relaunch was not performed. Shared row spacing affects every label badge and has not been visually checked across themes or narrow windows. Screenshots and native interaction checks were not captured because desktop computer control was not authorized.
Production exclusion is covered by development/production/test-mode route, navigation and state tests; a packaged production build was not executed. Mock state is per window/Jotai store and is intentionally not persisted or synchronized. There are no dependency, database, persistence-format or IPC changes. Reverting this commit removes the feature without data migration.
Verification
pnpm check:typed-lint— passed: 1084 existing findings, 0 new or increased findings.CI follow-up: wrap the confirm click callback with explicit promise rejection handling, and wait for installation completion in the regression test.
pnpm exec eslint --no-eslintrc --config config/eslint.typed.cjs src/scaffold/AppUpdater/UpdateInstallPrompt.tsx— passed against the CI typed-lint rules.pnpm test -- src/scaffold/AppUpdater/index.test.ts src/scaffold/AppUpdater/service.test.ts— 51 tests passed after the callback fix.pnpm test -- src/scaffold/AppUpdater src/config/settingsDevelopment.test.ts src/config/settingsNavigation.test.ts src/modules/MainApp/Settings/sections/__tests__/DevelopmentSection.test.ts src/scaffold/NavigationSidebar/variants/SettingsSidebarCount.test.ts src/scaffold/NavigationSidebar/variants/SettingsSidebar.search.test.ts src/scaffold/NavigationSidebar/components/NavigationMenu/NavigationMenu/NavigationMenuRow.test.ts src/engines/ChatPanel/ChatPanelStartPage.test.ts— 125 tests across 16 files passed; rerun after integrating latest develop.pnpm typecheck:fast— passed; commit hook also passed TypeScript checking.pnpm check:test-placement— passed after moving the new settings test into the existing__tests__directory.Commit hook commands
oxlint -c .oxlintrc.json --max-warnings 0,eslint --fix, andprettier --write— passed on staged source/documentation files.git diff origin/develop...HEAD --check— passed. Final scope/diff inspected for unrelated changes, credentials, personal paths, debug logging and generated artifacts.Native screenshots, packaged-build execution and real update installation were not run, as detailed above.
Audit
UI reports: 0 fix candidates, 5 keeps with reasons, 0 abstractions. Lifecycle review passed for bounded session state and reactive scalar counts; no background jobs were added and no CPU/RSS improvement is claimed.