fix(tui): restore showDetails check removed in Permission rework#7285
Merged
rekram1-node merged 1 commit intoanomalyco:devfrom Jan 8, 2026
Merged
Conversation
Contributor
|
The following comment was made by an LLM, it may be inaccurate: No duplicate PRs found |
Collaborator
|
/review |
rekram1-node
reviewed
Jan 8, 2026
Comment on lines
1332
to
1338
| const shouldHide = createMemo(() => { | ||
| if (ctx.showDetails()) return false | ||
| if (props.part.state.status !== "completed") return false | ||
| const permissions = sync.data.permission[props.message.sessionID] ?? [] | ||
| if (permissions.some((x) => x.tool?.callID === props.part.callID)) return false | ||
| return true | ||
| }) |
Collaborator
There was a problem hiding this comment.
Wait i dont think this part makes sense anymore w/ new dialog changes for permissions
Contributor
Author
There was a problem hiding this comment.
You're right. Updated and pushed.
Contributor
|
lgtm |
## Problem The 'Hide tool details' toggle in the command palette (Ctrl+P) has no effect on the UI - completed tools are always displayed regardless of the setting. ## Root Cause The Permission rework commit 351ddee (merged 2026-01-01, PR anomalyco#6319) accidentally removed the showDetails check from the ToolPart function. ## Fix Restore the showDetails check with simplified logic: - Show all tools when showDetails is true - Show running/pending tools (so users see progress) - Hide completed tools when showDetails is false Removed the permission-based visibility check as the new PermissionPrompt dialog handles permissions separately at the bottom of the screen.
52d607c to
9becced
Compare
Contributor
|
This does seem like it works to me. Fingers crossed that we'll see it merged soon - I (and probably others, I'd guess) do frequently use this feature, so I'd love to see its functionality restored. |
aryasaatvik
pushed a commit
to aryasaatvik/opencode
that referenced
this pull request
Jan 10, 2026
zerone0x
pushed a commit
to zerone0x/opencode
that referenced
this pull request
Jan 12, 2026
zerone0x
pushed a commit
to zerone0x/opencode
that referenced
this pull request
Jan 12, 2026
liorshk
pushed a commit
to liorshk/opencode
that referenced
this pull request
Jan 17, 2026
triklozoid
pushed a commit
to triklozoid/opencode
that referenced
this pull request
Feb 2, 2026
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.
Fixes #7286
Problem
The 'Hide tool details' toggle in the command palette (Ctrl+P) has no effect on the UI - completed tools are always displayed regardless of the setting.
Root Cause
The Permission rework commit 351ddee (merged 2026-01-01, PR #6319) accidentally removed the
showDetailscheck from theToolPartfunction when refactoring the tool rendering system.Before Permission rework (working):
After Permission rework (broken):
Fix
Restore the showDetails check by:
const ctx = use()to access the contextshouldHidememo with the original logic<Show when={!shouldHide()}>The fix preserves the original behavior:
The fix uses the same permission data structure (
x.tool?.callID) as the existing code, aligning with the new permission system introduced in the rework.