feat: collapse slash command expansion in user messages - #338
Open
Kabochar wants to merge 1 commit into
Open
Conversation
Show a compact clickable command reference for slash-command messages (/skill:name and prompt templates) instead of the full SDK-expanded text. The user-supplied arguments stay fully visible; clicking the command name toggles the expanded skill/template body. - lib/slash-display.ts: pure helpers (command parsing, skill expansion reverse-matching, FIFO tracker) + 17 unit tests - rpc-manager.ts: inject originalText on message_end for user messages via a new message object (never mutates SDK-shared state), always consume one FIFO entry per message, clear the tracker on prompt failures - session-reader.ts: reverse-match skill expansions when loading session history - MessageView.tsx: render command name as accent-colored toggle with args shown verbatim; keep image blocks in both branches; add aria-expanded Storage and model input stay unchanged: session JSONL keeps the expanded text and originalText is a display-only field.
Kabochar
force-pushed
the
feat/slash-command-display
branch
from
August 1, 2026 07:16
6e3c41b to
be89a60
Compare
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.
Show a compact clickable command reference for slash-command messages (/skill:name and prompt templates) instead of the full SDK-expanded text. The user-supplied arguments stay fully visible; clicking the command name toggles the expanded skill/template body.
Storage and model input stay unchanged: session JSONL keeps the expanded text and originalText is a display-only field.