test: verify ghostty-web upstream fixes (coder/ghostty-web#147)#21
Closed
test: verify ghostty-web upstream fixes (coder/ghostty-web#147)#21
Conversation
added 2 commits
March 28, 2026 06:53
…rounds Points ghostty-web to the local fork (jesse23/ghostty-web#fix/pty-input-handling-gaps). Removes the webtty-level workarounds for Bug 2 (Ctrl+V paste listener) and Bug 3 (attachCustomWheelEventHandler + mouseScrollSpeed) — the upstream fixes in handleKeyDown and handleWheel are now sufficient. Bug 1 (cursor shape) workaround kept since the WASM has not been rebuilt yet.
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.
Purpose
Verification branch for coder/ghostty-web#147 — the upstream PR that fixes three PTY input handling gaps directly in ghostty-web. This PR demonstrates that the webtty workarounds for Bug 2 and Bug 3 can be safely removed once the upstream fix lands.
Do not merge. This branch will be deleted after the upstream PR is reviewed and merged.
What changed
main)ghostty-webfile:../ghostty-web(local fork atfix/pty-input-handling-gaps)0.4.0-next.14.g6a1a50d(npm)pastecapture listener)attachCustomWheelEventHandler)cursor.ts)Bug 1 is kept because its upstream fix requires a WASM rebuild (new
ghostty_render_state_get_cursor_style/_blinkingexports).cursor.tsnow has a comment listing exactly what to delete once the rebuilt WASM ships.How to test locally
Setup
Test cases
Bug 2 — Ctrl+V forwards
\x16to PTY (no webtty paste listener)\x16(e.g. opencode image paste).\x16and triggers its OS clipboard read (osascript/wl-paste).handleKeyDownswallowed the event.Bug 3 — Mouse wheel scrolls vim buffer (no webtty custom handler)
set mouse=ain your vimrc (or run:set mouse=aafter opening).Bug 1 — Cursor shape (workaround still active, WASM not rebuilt)
Cursor shape changes (bar in insert mode, block in normal mode) still work via
cursor.ts. This is unchanged frommain. The upstream fix for Bug 1 will take effect after coder/ghostty-web#147 is merged and a new WASM binary is released.Cleanup plan (after coder/ghostty-web#147 merges + new npm release)
ghostty-webversion inpackage.jsonto the new release.src/client/cursor.ts.import { applyDecscusr } from './cursor'fromindex.ts.applyDecscusr(term, event.data)call inws.onmessage.package.jsondiff (removing thefile:path) alongside the above.How to Manual Test This Change
To test locally, three steps:
Reference
coder/ghostty-web#147
coder/ghostty-web#145