fix(tui): hide no-op slash commands (/settings) in lean mode#3724
Merged
Conversation
…ette Lean mode silently drops OpenSettingsDialogMsg (and other tab/sidebar messages) in appModel.update, so /settings does nothing there. Yet it still autocompleted and ran from the command palette. Seed disabledCommands from a new leanModeDisabledSlashCommands list when WithLeanMode is applied, reusing the existing disabledCommands filter in commandCategories() so both inline completion and the palette/parser stay consistent. To avoid the two lean-mode lists (dropped message types vs. disabled slash commands) drifting apart, the message-drop switch in update() now runs off the same leanModeDroppedMessageTypes slice used to validate leanModeDisabledSlashCommands, and a guard test executes every built-in command to cross-check the two.
Sayt-0
approved these changes
Jul 17, 2026
Sayt-0
enabled auto-merge
July 17, 2026 15:40
Member
|
Did /settings really show? |
rumpl
added a commit
that referenced
this pull request
Jul 17, 2026
revert: pkg/tui lean-mode machinery from #3724
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.
Follows #3723.
In LEAN TUI mode, slash commands that are no-ops should not be offered in autocompletion, the command palette, or the slash-command parser. This excludes /settings in lean mode while leaving classic mode unaffected.
A single source of truth now drives both runtime message dropping and disabled slash-command derivation, with a guard test preventing drift.
Validation: task build, task test, and task lint pass.