Skip to content

browser: PasClaw UI chrome over the xterm page (branding, boot screen, auto ?net=browser) - #188

Merged
FMXExpress merged 2 commits into
mainfrom
claude/browser-ui
Jun 9, 2026
Merged

FMXExpress merged 2 commits into
mainfrom
claude/browser-ui

Conversation

@FMXExpress

Copy link
Copy Markdown
Owner

Polish the in-browser bundle page

The container2wasm bundle (browser/) shipped the bare upstream xterm page. This layers a thin, framework-free PasClaw chrome over it, injected by build.sh alongside the existing coi-serviceworker.

Framing

The page is the real pasclaw CLI running in an xterm terminal inside the emulated Linux — not a chat UI. A bubble UI (like openbrowserclaw, whose agent is JS) would require parsing the terminal stream, which is brittle. So this enhances the page around the terminal rather than replacing it.

What it adds (web/pasclaw.css + web/pasclaw.js)

  • Auto ?net=browser — if the URL is missing the query, it redirects to add it before the ~160 MB runtime downloads. This is the footgun that otherwise leaves the agent with no network egress (it falls back to a ws://…:8888 host relay that isn't there).
  • Header bar with PasClaw branding + GitHub link, and a data-URI favicon (no extra request under COEP).
  • Boot screen while the runtime downloads/boots, auto-dismissed on the terminal's first output, with click-to-skip and a timeout fallback so it can never trap the user.

Safety

Purely additive: it only touches page chrome and standard xterm.js DOM (#terminal, .xterm-rows), never how the emulator boots. Removing the injected <link>/<script> tags (or the web/ copy step in build.sh) leaves the upstream terminal fully working. Branding/colors live in web/pasclaw.css.

Notes

https://claude.ai/code/session_01LGQKz579j1ZnDRwmr6h1V6


Generated by Claude Code

claude added 2 commits June 8, 2026 22:11
The in-browser bundle was the bare container2wasm xterm page. Layer a
thin, framework-free chrome (web/pasclaw.css + web/pasclaw.js), injected
by build.sh alongside the coi-serviceworker:

- auto ?net=browser (redirects if missing, so the in-browser fetch proxy
  always activates — otherwise the agent has no network egress)
- PasClaw header bar + favicon
- a boot/loading screen that auto-dismisses on first terminal output
  (click-to-skip + timeout fallback)

Purely additive and targets only page chrome + standard xterm.js DOM, so
removing the injected tags leaves the upstream terminal working. It stays
a terminal (the real pasclaw CLI), not a chat UI.
Match the gateway web UI (src/pkg/gateway/webui.html): neon cyan/magenta
on a deep gradient backdrop with glow, instead of the flat blue/red I'd
used. Updates the header wordmark, boot screen, spinner, and favicon.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants