github lightpanda-io/browser 1.0.6

one hour ago

Behavior changes

  • Screenshots now use the layout engine: Page.captureScreenshot, BiDi screenshots and fetch --dump png draw boxes where getBoundingClientRect puts them. --png-mode reader gives the old one-column text rendering. The agent's /screenshot keeps reader by default (mode= to change it). PDF is always reader.
  • Page.getLayoutMetrics now comes from the layout engine, and the root container is as wide as the viewport instead of a fixed 1920px.
  • CORS: a * in Access-Control-Allow-Headers now covers Authorization, as every browser does.
  • A response with no declared charset that is clearly not UTF-8 is decoded as windows-1252.
  • CDP: DOM, CSS, Accessibility and Input commands (other than enable/disable) now fail on the startup placeholder target.

Serve / CLI

  • --cdp-allow-timezone-override: lets Emulation.setTimezoneOverride change the time zone used by Date and Intl. The zone is shared by the whole process. Without the flag, the command is accepted and ignored with a warning
  • --png-mode layout|reader for fetch --dump png
  • agent --temperature <FLOAT>

Layout

  • Padding and box-sizing
  • Margins move boxes horizontally; margin: 0 auto centers, margin-left: auto pushes right
  • gap, row-gap and column-gap in flex layouts; text between flex items counts as an item
  • bottom sizes a fixed or absolute box
  • Every z-index value is used for hit testing
  • html and body take their declared height (height: 100%); canvas and video without a size are 300×150
  • Every display value is tracked, for layout and getComputedStyle

New Web APIs

  • navigator.clipboard.readText() and writeText() (a per-session buffer, never the system clipboard; secure contexts only)
  • HTMLMediaElement timeline: duration, a currentTime that advances while playing, seeking, ended, loop and the matching events (nothing is decoded or played)
  • ReadableStreamDefaultReader.closed
  • OffscreenCanvas is an EventTarget (Flutter web apps now start)

Web API behavior / fixes

  • CSS rules inside an @supports block are applied when the condition holds
  • Streams: pull() waits for start() and for its own previous call, and runs again when a read waits (fixes Next.js 16 prefetch streams); cancel() handles a returned promise, and both tee() branches share one cancel promise
  • XML parsing keeps namespace declarations (xmlns, xmlns:b) and creates CDATASection nodes

CDP

  • Emulation.setTimezoneOverride applies the zone (with --cdp-allow-timezone-override) and rejects unknown zone ids
  • LP.detectForms includeValidation option: returns each field's validation message

BiDi

  • script.addPreloadScript
  • script.getRealms
  • browsingContext.captureScreenshot
  • browsingContext.handleUserPrompt, and a new lp.handleUserPrompt, like CDP's LP.handleJavaScriptDialog

Tools / MCP

  • detectForms includeValidation option: returns each field's validation message, so an agent can read why a form was rejected

Performance / memory

  • Startup no longer loads every CA certificate twice (about 30% of a simple fetch)
  • Semantic tree dumps register far fewer nodes (HTML spec: 672k → 314k)
  • getBoundingClientRect and other DOMRect returns skip the identity map
  • Less memory for the identity map, cloned attributes, inline scripts, selectors, node lists and PNG rendering (drawn 128 rows at a time)
  • Faster style matching: better :where() bucketing, an ancestor bloom filter, and selectors that can never match are dropped
  • A class change that can't move a box no longer clears the layout cache

Don't miss a new browser release

NewReleases is sending notifications on new releases.