Extracted from development commit 7f7d222c41.
Adapted to the target branch APIs. Validated with cargo fmt --all, full workspace Clippy (-D warnings), and cargo nextest run --no-fail-fast before committing.
Discover font demand from computed styles without triggering layout.
Honor the FONT policy, recheck fallback demand before readiness, and
invalidate child-document scans for ancestor style and viewport changes.
Share rendered control labels, marker counters and text normalization,
including generated items, inline boundaries, leaf boxes and suppressed
contents. Cover Unicode subsets, readiness and zero layout passes.
Completes native SVG value and element interface exposure in one independently mergeable PR against main, refreshing the former SVG constructor PR. Animated scalar values, angles, preserve-aspect-ratio values and live point/string/number/length/transform lists provide the shared native DOM foundation for the added elements.
Adds the remaining component-transfer, flood, image, merge, merge-node and tile filter interfaces; SVGSwitchElement and SVGMPathElement; and the animation, animate, set, animate-motion and animate-transform interfaces. Native factories, inheritance, SVGTests lists, attribute reflection, receiver validation and animation event handlers use native objects and the existing DOM backend.
Tests cover main/iframe realms, live and windowless documents, native identity, value/list mutation, units, Trusted Types, animation target resolution, handlers and timing argument validation. All internal SVG dependencies are included here, with no external PR merge order.
Filter raster rendering and SMIL scheduling remain unimplemented. Timing controls reject NotSupportedError, getStartTime reports no interval, and getCurrentTime remains zero. The separate SVG path parser changes and animated-string UTF-16 storage migration are excluded. The retained length synchronization is included; a separate ignored regression records the lone-surrogate limitation in the current DOM attribute storage.
SVG event-handler properties reuse main's existing shared event backend. Tests verify replacement, clearing, canonical event types, cancellation and realm/receiver identity; complete handler/listener registration-order semantics remain part of the separate event-handler backend migration.
Document teardown used the document.open reset, which preserves compiled
module records and pending dynamic imports. Their strong V8 handles rooted
retired Contexts and native Documents across shared-isolate navigations.
Release module records, pending imports, graph fetches and owner events on
context teardown. Preserve import-map metadata so externally retained module
functions can still access native DOM values and import.meta.resolve aliases.
Leave document.open module-map semantics unchanged.
Add regressions for compiled modules, pending dynamic imports, and exported
functions retained across teardown. All three collection regressions fail
before the fix; retained functions remain usable until their last V8 reference
is released.
Validation: cargo fmt --all; cargo clippy --workspace --all-targets
--all-features -- -D warnings; cargo nextest run --no-fail-fast
(19,646 passed, 16 skipped). The initial run hit a 250ms CLI timeout
stage assertion; a full run with unchanged sources passed.
Release build with default Cargo parallelism. The CI real-site spider's
48-site peak RSS drops from 485.5 to 281.1 MiB, and last alive RSS drops
from 398.9 to 171.6 MiB. No forced GC was added to production navigation.
Expose secure Document.modelContext APIs with document-owned registrations,
callback realm and input validation, task-based result delivery, and independent
caller cancellation and target completion. Preserve cancellation reasons and
emit lifecycle events only for live owners.
Register native declarative forms in light and shadow trees through indexed
mutation candidates. Track schema changes to valid forms even before a
registration succeeds, including controls associated through a form attribute.
Use changed containers only for ancestor and form-owner checks; inspect added
and removed subtrees for discovery. Retire registrations at actual removal and
owner transitions while preserving submit handling and captured pending responses. Apply validated
fill intents to current options and checkable values in control event order.
Compute tools delegation from committed security origins, ancestor header
allowlists, container declarations, redirects, and combined sandbox policies.
Carry invocation identity, original origin, and resolved target through form
navigation; accept same-origin JSON-LD results and reject cross-origin commits.
Connect typed renderer observations to CDP discovery, invocation, cancellation,
and Runtime result projection. Include renderer and protocol regression coverage
for document lifetime, reentrancy, permissions, dynamic controls, and cancellation.
Validation on this commit tree: cargo fmt --all;
cargo clippy --workspace --all-targets --all-features -- -D warnings;
cargo nextest run --no-fail-fast.
Summary [ 100.619s] 19320 tests run: 19320 passed, 16 skipped
A one-millisecond timer could become runnable immediately after registration.
Remove the early dispatch allowance from the shared scheduler so registered
and rescheduled timers become runnable only at or after their actual
monotonic deadline. All readiness queries use the same rule.
Regression coverage checks registration-time and pre-deadline queries,
exact-deadline dispatch through filtered and unfiltered paths, and interval
rescheduling without advancing the new deadline.
Apply the shared script nonceability check to parser scripts, buffered preloads and runtime script preparation. Suspicious script attribute names and values must not authorize execution merely because a nonce matches. Includes parser, preload and dynamic-preparation regressions.
The attribute checks follow the [CSP3 nonceability algorithm](https://www.w3.org/TR/CSP3/#is-element-nonceable), including case-insensitive `<link`, `<script` and `<style` matches and parser duplicate attributes.
Validation: all branch checks passed. Summary [ 115.690s] 18925 tests run: 18925 passed (9 slow), 16 skipped
Snapshot the initiating script nonce when scheduling string timeouts and intervals, then restore it on the compiled timer source. Cover dynamic imports, nested timers, identical source scheduled under different nonces, and functions invoked by another script.
Compile inline modules with their document base URL and read import.meta.url from the V8 module resource name. Preserve separate internal module-map identities and cover both page and child inline modules.
Source: f8de9b7ed0
Own callback microtask nesting in with_webidl_callback_contexts so operation
lookup, invocation, and return conversion share one boundary. Exit the
incumbent scope before Scoped-policy checkpoints and preserve Auto timing.
Route scripts, functions, modules, and constructors through named renderer
entry points, including worker execution. Keep the generic scope helper
private and remove manual callback wrappers from callers.
Cover microtask policies, exception cleanup, and incumbent cleanup ordering
with regression tests. Guard script and module execution entry points with
the existing source inventory checks.
Validation:
- cargo fmt --all
- cargo clippy --workspace --all-targets --all-features -- -D warnings
- cargo nextest run --no-fail-fast
Expose native MicrotasksScope bindings and use them explicitly at Moli script, module, callback, constructor, and popup execution boundaries. Keep rusty_v8 call APIs unchanged.
Checkpoint custom element constructors before validation only when no outer script or microtask is active. Cover parser, document.write, createElement, and host-owned popup execution; update the document.write reaction-order regression.