feat: tabbed response viewer, actions, and safer Restore in History - #25
Merged
Conversation
Covers enlarging/tabbing the History response body, adding Copy/Download/Open-in-Editor actions to it, and adding a tooltip + confirmation dialog to the Restore button.
…d helper Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
…lone History panel Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
…story entries Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
…meta in History panel Fixes four issues found in final review of the History response viewer: enable Monaco in the standalone History webview (missing config import and CSP directives), restore the JSON-editor base CSS in the history bundle, correct truncation-notice wording to not imply it's always the response body, and bring back the statusText/size line that was dropped when the response section was replaced with HistoryResponseViewer. Also merges a duplicate helper import in HistoryEntryList. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
The Body/Headers/Cookies viewer reused flex:1 sizing from the live Response panel, which only works because that panel gets a JS-set pixel height from an ancestor. History has no such bounded ancestor, so the same rules collapsed the Monaco body editor to zero height and let long header names (e.g. access-control-allow-origin) run into their values with no gap. Also makes the truncation notice report exact stored-vs-original sizes instead of a generic message, using the marker HistoryManager already embeds in truncated fields. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
.btn-primary ("New Collection") and the folder/request tree labels are
flex items that defaulted to min-width: auto, so none of them could
shrink below their content's natural width. In a narrow sidebar the
header row overflowed past .sb's overflow: hidden, hiding the New
Collection button instead of shrinking it; tree labels had ellipsis CSS
but nothing to reveal the truncated text.
Fixes: label now truncates with an ellipsis and gets a hover tooltip
(wrapping it in the shared Tooltip component required a matching fix,
since Tooltip's own wrapper div — not the button — is the real flex
item here); folder/request names get a native title attribute so the
full name is still discoverable on hover.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
The webview's New Collection button and the equivalent restlab.createFolder command palette entry both create a root-level folder, which the rest of the UI calls a "Collection" (empty-state text, button label). The input prompt and command title still said "folder", which was confusing since it doesn't match what's being created. Subfolder creation and renaming keep their existing wording — those are a different, correctly-named concept. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
slverma
pushed a commit
that referenced
this pull request
Jul 29, 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.
Description
Summary
<pre>block capped at 240px.Why
The History response body was cramped, had no way to inspect headers/cookies side by side with actions, and "Restore" silently overwrote request state with no explanation — all called out directly as UX gaps. The layout fixes were found via manual verification in the Extension Development Host after the initial implementation, since VS Code's webview CSP and CSS particulars can't be caught by type-checking alone.
Changes
src/utils/responseFileActions.ts(new): shared download/open-in-editor logic, used by bothRequestEditorProviderandHistoryEditorProvider.src/webview/components/HistoryResponseViewer.tsx(new): tabbed response viewer with actions, reused by both History surfaces.src/webview/components/ConfirmDialog.tsx(new): generic confirm/cancel modal, used by the Restore flow.src/webview/components/HistoryEntryList.tsx,src/webview/history/*,src/webview/request/HistoryTab.tsx: wiring for the above.src/webview/history/styles.css,src/webview/request/styles.css: response-viewer sizing, confirm-dialog styles, header-row layout fixes.src/webview/sidebar/*: narrow-width fixes for the header action buttons and tree row labels.package.json,src/extension.ts,src/providers/SidebarProvider.ts: "Create Collection" wording fix.docs/superpowers/specs/2026-07-29-history-response-viewer-design.md,docs/superpowers/plans/2026-07-29-history-response-viewer.md: design spec and implementation plan.Test plan
access-control-allow-origin) and confirm it wraps cleanly instead of overflowing.