Repository navigation
feat(variables): revamp the read-only Variables tab - #8784
Conversation
|
Note Reviews pausedIt looks like this branch is under active development. To avoid overwhelming you with review comments due to an influx of new commits, CodeRabbit has automatically paused this review. You can configure this behavior by changing the Use the following commands to manage reviews:
Use the checkboxes below for quick actions:
WalkthroughThe PR replaces the Variables tab with a persisted, sectioned editor. It adds object inspection, secret controls, folding, scrolling, shared CodeMirror styling, scoped persistence, and Playwright coverage. ChangesVariables editor
Estimated code review effort: 4 (Complex) | ~60 minutes Possibly related PRs
Suggested reviewers: Poem
🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✨ Finishing Touches 💡 1🛠️ Fix failing CI checks 💡
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
82ba3cf to
2b2512e
Compare
Co-Authored-By: Claude Opus 5 (1M context) <[email protected]>
BRU-3956
Description
Rewrites the read-only Variables tab so it uses the same table as requests and environments, keeps object values foldable with that state remembered across tab switches, and adds a per-row copy button.
Problem
Expanding a large nested object did not survive a tab switch. react-inspector keeps its expand state in component state, so leaving the tab and returning collapsed everything and you expanded it again from scratch on every visit.
There was no way to copy a value. A collapsed object could not be copied at all, and an expanded one meant selecting text by hand across several lines.
The table also did not match the tables in requests and environments: different row height, borders, header styling, and hover behaviour.
Fix
Replaced the
react-inspectortree withEditableTable, which requests and environments already use, so row height, borders, header, hover states, and column resizing all come from one place.Object and array values now render in a CodeMirror editor inside the cell, with line numbers and a fold gutter. Folding writes the fold position to localStorage against the tab, so the cell comes back folded on the next visit. The cell is height-capped and scrolls internally, which stops a large value from stretching the row. A value can also be opened in a resizable drawer on the right.
Each row has a copy button that appears on hover.
Secrets are revealed one row at a time now. Previously a single toggle unmasked every secret in the tab at once.
Runtime and environment variables sit in separate collapsible sections with counts. Scroll position, collapsed sections, revealed secrets, the open drawer and its width, and column widths are all remembered per tab. Switching environment clears the state that belonged to the old environment's values.
Contribution Checklist:
Screen.Recording.2026-08-07.at.7.17.55.PM.mov
Summary by CodeRabbit