Consolidate dev improvements: pane zoom, font sizing, quit confirm, preview cleanup, security hardening#154
Open
alxjrvs wants to merge 5 commits into
Open
Consolidate dev improvements: pane zoom, font sizing, quit confirm, preview cleanup, security hardening#154alxjrvs wants to merge 5 commits into
alxjrvs wants to merge 5 commits into
Conversation
- Cmd/Ctrl+Enter toggles a maximized ("zoomed") pane that fills the
workspace, hiding sibling panes until toggled off.
- Cmd/Ctrl +/-/0 adjust the terminal font size (clamped 8-32px),
persisted to config and re-fit across every open terminal.
- Intercept the window close request and confirm when live PTYs exist
via a new in-app ConfirmPrompt (WKWebView has no window.confirm).
Co-Authored-By: alxjrvs <alxjrvs@gmail.com>
Previewers may now return a cleanup function from render(); openPreview threads it through and exposes a dispose() on the surface so the PreviewSurface component can release resources on close. - PDF previewer revokes its Blob URL and removes the iframe on dispose, guarding against a teardown that races the async file read. - The file-changed listener handle is captured and detached on dispose, fixing a listener leak of one per preview opened. Co-Authored-By: alxjrvs <alxjrvs@gmail.com>
- Strip C0/C1/DEL control characters and cap notification text at 500 chars so malicious PTY output can't inject control sequences into native system notifications. - Humanize OSC 777 'notify;<title>;<body>' payloads to '<title>: <body>' so the raw prefix never reaches the workspace row. - validate_read_path now fails closed: the literal path is checked before canonicalize so a sensitive-but-absent path (e.g. ~/.ssh/id_rsa) is still denied, and the canonical path is re-checked to reject symlinks into blocked dirs. - Extend the blocklist (.netrc, .git-credentials, .npmrc, .pypirc, shell histories, macOS keychains) and make file_exists report blocked paths as non-existent so callers can't probe for sensitive files. Co-Authored-By: alxjrvs <alxjrvs@gmail.com>
11 tasks
The pull_request trigger was filtered to base=main, so stacked PRs (whose base is a feature branch) got no CI. Drop the base-branch filter so every PR runs CI regardless of its base. Co-Authored-By: alxjrvs <alxjrvs@gmail.com>
The prior commit added an explanatory comment but left the `branches: [main]` line under `pull_request` in place, so stacked PRs were still filtered out. Remove the filter for real. Co-Authored-By: alxjrvs <alxjrvs@gmail.com>
8 tasks
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.
Consolidates several independent improvements developed on the
devline intomain. Each is isolated to its own commit.What's included
1. Pane zoom (
feat(terminal))Cmd/Ctrl+Entertoggles a maximized ("zoomed") pane that fills the workspace, hiding sibling panes and the split divider. Toggling again — or zooming a different surface — restores the split layout. Ephemeral, not persisted.2. Adjustable terminal font size (
feat(terminal))Cmd/Ctrl +/-adjust font size (clamped 8–32px);Cmd/Ctrl 0resets to 14px. Persisted to config and re-fit across every open terminal, so it survives restart.3. Quit confirmation (
feat(terminal))ConfirmPromptmodal asks before tearing them down (WKWebView has nowindow.confirm). With zero live terminals, quit proceeds with no prompt.4. Preview resource cleanup (
fix(preview))render(); the PDF previewer now revokes its Blob URL and removes the iframe on dispose. Also fixes afile-changedlistener leak (one per preview opened).5. PTY notification sanitization & humanization (
feat(security))notify;<title>;<body>payloads render as<title>: <body>instead of leaking the raw prefix.6. Filesystem path hardening (
feat(security))validate_read_pathfails closed (literal check before canonicalize) and rejects symlinks into blocked dirs. Blocklist extended (.netrc,.git-credentials,.npmrc,.pypirc, shell histories, macOS keychains).file_existsreports blocked paths as non-existent so callers can't probe for sensitive files.Adds ~69 tests (293 → 362) plus new Rust unit tests for notification sanitization and path validation.
Test plan
Pane zoom
Cmd+Enter(macOS) /Ctrl+Enter(Linux/Win) — focused pane fills the workspace, siblings + divider hiddenFont size
Cmd/Ctrl +enlarges every open terminal;Cmd/Ctrl -shrinks themCmd/Ctrl 0resets to default (14px)Quit confirmation
PDF preview
.pdffrom the file tree — renders in an iframeNotifications
printf '\e]777;notify;Title;Body\a') notification — workspace row showsTitle: Body, not the rawnotify;prefixPath security
~/.ssh/id_rsa(or~/.netrc) via the app — access denied🤖 Generated with Claude Code