0.2.7
lightpanda-io/browser0.2.7Mar 25, 2026by github-actions[bot]
AI Summary
Adds `Form.requestSubmit`, window.postMessage across frames, and ShadowRoot.adoptedStyleSheets. Improves Promise/Error handling.
Key Highlights
- `Form.requestSubmit` and submitter fixes
- window.postMessage across frames
- ShadowRoot.adoptedStyleSheets
- Improved Promise error handling
New Features
- Form.requestSubmit and form.iterator()
- Image.currentSrc / Media.currentSrc
- Request.signal and blob URL support
- window.postMessage across frames
- ShadowRoot.adoptedStyleSheets
- InputEvent dispatched on input/textarea
- Keyboard events bubble, cancelable and composed
- StyleManager (CSSOM + enhanced visibility filtering)
Full Release Notes
## New Web APIs
- **`Form.requestSubmit`** (+ fix submitter on `SubmitEvent`); expose `form.iterator()`
- `Image.currentSrc` / `Media.currentSrc`
- `Request.signal`; blob URL support in XHR and Fetch
- `window.postMessage` across frames; `window.event` property
- `ShadowRoot.adoptedStyleSheets` (like Document)
- `InputEvent` dispatched on input/textarea changes
- Keyboard events bubble, cancelable and composed
- Special-case `Window#onerror` per WHATWG spec (5-arg signature)
- `new URL('about:blank')`; percent-encode pathname in `URL.setPathname`
## CSS / styling
- **Introduce `StyleManager`** (bucket stylesheet rules; dirty-state handling; restore on rebuild failure)
- **CSSOM + enhanced visibility filtering**; optimize CSS visibility engine (lazy parsing, cache-friendly evaluation)
- Gracefully handle at-rules in `CSSStyleSheet.insertRule` (fixes Expo Web crash)
- Anchor CSS property normalization
## MCP
- **DOM interaction tools**: `click`, `fill`, `scroll` (MCP + CDP); return page state from these tools
- `detectForms` tool for structured form discovery; `waitForSelector` tool
- `SemanticTree`: progressive discoverability, `interactiveOnly` filter, token-usage optimization
- Initialize server in `mcpThread` to avoid V8 isolate crashes; `ping` request handling
- Fix MCP error responses missing `jsonrpc` field
## CDP (Chrome DevTools Protocol)
- `waitForSelector` in `lp.actions`; `Target.detachedFromTarget` on detach
- Fix `Page.getFrameId` on startup when context+target exist
- Missing `disable` methods for Performance/Inspector/Security domains
- Trusted click events dispatched from CDP; serialize `AXValue` integer as string per spec
- Encode non-UTF-8 `Network.getResponseBody` in base64
- Fix WebSocket connection dying during complex navigation; don't kill WS on unknown domain/method errors
- `Emulation.setUserAgentOverride` fix
## Charset / encoding
- Charset detection from first 1024 bytes of HTML; set charset based on BOM
## CLI / serve
- `--advertise_host` option for serve; fetch wait options
- Actionable error when server port already in use
- `git_version` build option for release version detection; automate version resolution in `build.zig`
## Promises / errors
- Improved unhandled-rejection handling; return correct errors in promise rejections
- Better ergonomics for rejecting a promise with a proper JS error
- Fix DOMException default messages; fetch error reject; DOMParser error doc
## Stability fixes
- Switch MutationObserver + IntersectionObserver to reference counting; disable observer weak ref
- Move ScriptManager to ArenaPool (fix memory leak + resource handover)
- Fix UAF with certain CDP scripts; remove frame double-free on navigate error
- Handle `appendAllChildren` mutating child list; nested `document.write` where parent gets deleted
- Double-queue for recursive navigation; more aggressive timer cleanup; only run idle tasks from root page
- Fallback to Incumbent Context when Current Context is dangling
- Handle `Connection: close` without TLS close_notify; graceful WS socket close
## Build / CI / docs
- Support dash-separated CLI arguments; upgrade GitHub Actions for Node 24
- Move WPT runs to dedicated host; refactor markdown renderer into a struct
- README cleanup (remove js-runtime / zig-js-runtime references); LICENSING.md update