Repository navigation
feat(desktop): streamline preset creation, prompt modes and custom icons - #142
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
preset-…fallback.Verification
ErrorMessage, close replacement controllers before the hot-rebuild fixture removes its temporary store, and guard icon lookup against inherited object keys (includingconstructor).bench/agent-presets.mjspassed: keyboard creation and switches, all prompt modes, dynamic body requirements, advanced disclosure, crop/save/list/picker readback, upload validation, cancel/reset, stale decode, color save/copy and random selection. Inspected standard and 800px layouts.composer-menu-viewport(4 checks),ci-contract(2 checks), and test TypeScript check passed.go test ./internal/agentpresetand focused agent preset tests in./internal/boot,./internal/controland the separate Desktop module passed.make lintpassed: zero golangci-lint issues and clean repolint.Documentation and compatibility
Updated both preset guides and Chinese/English copy. Adds optional
icon-image/icon-colorYAML fields andiconImage/iconColorDTO fields. Existing glyph-only presets and prompt/tool flags retain their format. Older hosts/CLIs reject unfamiliar YAML fields and must be updated before sharing image/color presets.Input images: PNG/JPEG/WebP, up to 5 MB and 8192 × 8192 pixels. Stored images: square PNG, up to 128 KiB and 128 × 128 pixels. Colors: validated six-digit hex values.
Cache-impact: none; icon/image/color metadata is display-only and stripped from runtime fingerprints. The prompt-mode UI maps to the existing prompt/tool fields.
Cache-guard:
TestAgentPresetIconsDoNotChangeRuntimeFingerprintOrPrompt; focused agent preset boot/control tests.System-prompt-review: no provider-visible prompt construction changes.
Related issues
None.