feat(web): collapse resolved approval rows
Resolved permission boxes vanish from the transcript instead of lingering as "answered" cards. When a turn has 2+ tools the resolved approval is absorbed into the tool group as a compact italic line; otherwise it is hidden entirely. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Opus 4.6
parent
bc0fd6ee60
commit
60e57fde31
@@ -368,13 +368,14 @@ describe("buildTranscriptRow: approval", () => {
|
||||
expect(el.querySelector(".st-approval-path")!.textContent).toBe("/etc/x");
|
||||
});
|
||||
|
||||
it("hides the buttons and shows an answered note once resolved", () => {
|
||||
it("renders a compact one-liner once resolved", () => {
|
||||
const el = buildTranscriptRow(approvalRow(allThreeOptions), {
|
||||
pending: false,
|
||||
onDecide: () => Promise.resolve(),
|
||||
});
|
||||
expect(el.querySelector(".st-approval-acts")).toBeNull();
|
||||
expect(el.querySelector(".st-approval-resolved")!.textContent).toBe("answered");
|
||||
expect(el.classList.contains("st-approval-compact")).toBe(true);
|
||||
expect(el.textContent).toContain("approved");
|
||||
});
|
||||
|
||||
it("invokes onDecide with the clicked decision and disables the buttons", () => {
|
||||
|
||||
Reference in New Issue
Block a user