Repository navigation
fix(visual-skin): allow disabling the active skin - #3946
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.
Summary
After activating a visual skin, users could only switch to another installed package or remove it. Add Disable skin in Appearance settings to restore the existing built-in theme while keeping imported packages available.
Type and Areas
Type: Bug fix.
Areas: Web UI Appearance settings, visual-skin runtime, locale resources, and regression tests.
Motivation / Impact
Deactivation clears the saved selection through the existing IndexedDB transaction, then clears the applied skin and any temporary preview. A failed save preserves the previous selection and visible skin or preview, reports the error, and allows retry. Imported packages remain available for later activation. No persisted schema or remote protocol changes are required.
Verification
All local checks passed:
pnpm --dir src/web-ui run test:run src/infrastructure/visual-skin src/infrastructure/config/components/common/ConfigPageLayout.skin.test.tsx src/infrastructure/config/components/VisualSkinConfigSection.test.tsx src/app/scenes/session/ChatPane.composer-layout.test.tsx— 21 files, 169 tests passed.pnpm run check:web— typography, Appearance contracts, theme color/visual governance, and TypeScript checks passed.pnpm run i18n:audit— zero warnings.pnpm --dir src/web-ui exec eslint src/infrastructure/visual-skin/runtime.ts src/infrastructure/visual-skin/index.ts src/infrastructure/config/components/VisualSkinConfigSection.tsxgit diff --check upstream/main..HEADnode scripts/check-git-object-sizes.mjs --base upstream/main --head HEAD— all 9 introduced blobs passed.Regression coverage includes restoring native theme values, retaining packages, staying disabled after runtime restart, deactivating during preview, save-failure preservation/retry, and preventing duplicate actions while saving.
Reviewer Notes
AI-assisted change; testing level: focused automated local coverage. Native WebView screenshots were not captured. Live SSH workspaces, Remote Control, Peer Device Mode, and Detached Dispatch were not exercised; skin selection remains owned by the rendering Web UI host.
Manual acceptance: activate a package, select Disable skin, confirm that the previous built-in appearance returns and the package remains listed, then reload and confirm that it stays disabled. Re-enable it, preview another package, and verify that Disable skin also exits the preview.
Checklist