Commit Graph
140 Commits
Author SHA1 Message Date
ldm0 e7f640003b fix(forms): honor button auto type state 2026-10-11 18:04:07 +08:00
ldm0 1404fa344b perf(accessibility): avoid JSON intermediates in semantic dumps
Large semantic dumps retain a JSON object graph with allocated field names
and string node references for every AX node before formatting the output.

Build compact typed nodes with numeric references and pass them directly
from the renderer to the CLI. Keep one AX traversal for both typed nodes
and CDP payloads, converting protocol nodes individually as they are built.
Preserve omitted/empty fields, field insertion order, list markers, and
frame-root attachment order. Render text iteratively and trim in place.

Add compatibility coverage and a standalone benchmark that stages both
executables on the same filesystem, alternates runs, records peak RSS and
wall time, and rejects changes to dump output bytes.

Against main at 5f5e1fff3 on a generated 40,000-row list (three interleaved
runs, medians):
- semantic_tree_text: 718.42 -> 390.96 MiB; 2.919 -> 2.204 s.
- semantic_tree: 815.71 -> 483.81 MiB; 2.484 -> 2.369 s.
- markdown control: 95.52 -> 95.59 MiB; 0.895 -> 0.913 s.

A generated 200,000-row list also completes with identical bytes (one run):
- semantic_tree_text: 3473.02 -> 1775.07 MiB; 13.245 -> 10.015 s.
- semantic_tree: 3803.45 -> 2137.26 MiB; 12.626 -> 10.397 s.

JSON/text comparisons also match the baseline on a mixed fixture containing
hidden/ignored nodes, form values, list markers, shadow DOM, and child frames.
These generated fixtures are independent of the external MOL-269 evidence.

Validation:
- cargo fmt --all
- cargo clippy --workspace --all-targets --all-features -- -D warnings
- cargo nextest run --no-fail-fast (19,885 passed, 17 skipped)
- cargo build --release -p moli

Refs: MOL-269
2026-10-11 17:37:40 +08:00
ldm0 b2b51a5525 chore(release): bump version to 1.1.16 2026-10-10 19:24:34 +08:00
ldm0 7e93cca631 fix(indexeddb): validate native schema key paths before mutation
Validate native object-store and index schema key paths using Unicode identifier rules, including dotted paths and sequences. Preserve syntax/duplicate/invalid-option precedence and reject invalid metadata before mutating the backend. Map native Syntax and InvalidAccess errors to their DOM names. Tests cover Unicode paths, invalid sequences and failed creations leaving metadata unchanged. Renderer argument/receiver migration is separate.
2026-10-10 12:09:13 +08:00
ldm0 8c1c35df5a chore(release): update version to 1.1.15 2026-10-07 18:47:14 +08:00
ldm0 561edec134 build: refresh Parley fork to d0f5452
Pin Parley and Fontique to the reviewed fork with clarified bidi contracts, a separate first-style line-height compatibility commit, and transparent-marker benchmarks. Update the same-source workspace crates in Cargo.lock without changing package versions or other dependencies.

Validation: cargo fmt --all; cargo clippy --workspace --all-targets --all-features -- -D warnings; cargo nextest run --no-fail-fast (19,676 passed, 16 skipped).
2026-10-07 18:34:42 +08:00
ldm0 b5f4e788aa build: update Parley to the PR1-based inline object fork
Pin Parley and Fontique to 813c8c1120c6dee61f838f2cc2ec4efedc08b9ea on fix/inline-object-bidi-rebased. The fork contains the three inline-box bidi PR commits followed by the transparent marker, visual edge placement and host embolden extensions. Keep the original fix/inline-object-bidi branch intact.

Validation: cargo fmt --all; cargo clippy --workspace --all-targets --all-features -- -D warnings; cargo nextest run --no-fail-fast (19676 passed, 16 skipped).
2026-10-07 18:34:42 +08:00
ldm0 00e18d6aef build(deps): update indexmap to 2.14.2 2026-10-07 18:23:02 +08:00
ldm0 9d16dc1c65 build(deps): update rusqlite and hashlink 2026-10-07 18:23:02 +08:00
ldm0 3e3d4d3e5e perf(style): inline single effects during DOM mutation conversion
Return SmallVec<[StyleMutationEffect; 1]> from from_dom_mutation_effects.
Handle a pure single character-data update inside the converter before
constructing the deduplication set. Keep the notification call uniform;
batches preserve their existing order and deduplication.

Cover repeated text updates, :empty styles, and MutationObserver old values
in live and windowless documents.

Validation of the resulting branch:
- cargo fmt --all
- cargo clippy --workspace --all-targets --all-features -- -D warnings
- cargo nextest run --no-fail-fast (19,490 passed, 16 skipped)

Performance vs parent b75de5c66f (fixed local WeChat HTML, release,
JS/CSS/subframes disabled, 100 balanced randomized pairs):
Wall median 180.575 -> 165.316 ms (-8.45%). Paired median saving
13.885 ms; bootstrap 95% CI [12.364, 19.486] ms. The code tree matches
the previously validated and measured SmallVec version 84c5a81cca.
2026-10-07 03:28:07 +08:00
ldm0 7fe5c0913e fix(layout): place inline decorations at physical bidi edges
Position transparent opening and closing edges around their visual descendants
after bidi reordering and before alignment. Keep the logical edge widths used
by line breaking while honoring CSS direction for physical padding and borders.

Move the inline-object bidi patch onto current upstream Parley main and pin
the fork at 8eb00ef5e628b1bba95dcde88658deb2a5aed1b5. Adapt the new font,
metrics, whitespace and layout APIs while preserving neutral atomic analysis.
Preserve the browser's synthetic-bold policy through Fontique's host threshold.

Use structural style ancestry for inline text masks so physical edge ordering
cannot change which glyphs belong to a background-clip:text target.

Add 96 Chromium-verified decoration cases covering natural RTL and mixed text,
CSS directions, asymmetric padding and borders, and layout publication. Add a
Chromium-verified paint test for ordinary and nested LTR/RTL text masks.
2026-10-06 16:51:41 +08:00
ldm0 d8e7c37723 fix(layout): resolve atomic inline bidi levels through Parley
Resolve inline objects independently so an atomic sibling outside a closed
RTL context follows the surrounding text instead of the preceding RTL run.
Pin the Parley 0.11.1 fork repair and its shared Fontique source.

Declare atomic and transparent boundary roles at the Moli adapter, keeping
opening edges with the next participant and closing edges with the previous
item. Add 336 Chromium-verified geometry cases across document modes,
contexts, directions, breaks and atomic placement, including publication.
2026-10-06 16:51:41 +08:00
ldm0 761b39bc84 feat(webidl): derive native interface brand checks
Add interface and brand_check field attributes to argument and dictionary derives, including variadic object arguments. Preserve native object identity and validate brands at each field conversion position.

Cover nullability, conversion order, cross-realm errors, registered native proxies, and invalid attribute combinations.
2026-10-06 13:35:34 +08:00
ldm0 c345a594f4 feat(webmcp): implement document tools and CDP integration
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
2026-10-05 15:25:06 +08:00
ldm0 ca0a4c81a2 feat(webmcp): add native form schemas, fill intents, and activity states
Introduce moli-webmcp for native form schema synthesis, complete input validation,
numeric conversion, and JSON-LD results. Preserve requested selection values in
fill intents so the renderer can apply them to current controls after author
input events.

Add native tool activity states, selector support, control helpers, and
a namespace-aware form index that includes open and closed shadow trees.
Pin the Stylo revision providing the activity pseudo-classes.

Validation on this commit tree: cargo fmt --all;
cargo clippy --workspace --all-targets --all-features -- -D warnings;
cargo nextest run --no-fail-fast.
Summary [  98.804s] 19248 tests run: 19248 passed, 16 skipped
2026-10-05 15:25:06 +08:00
ldm0 167d1e0195 chore(release): update verstion to 1.1.14 2026-10-05 14:52:42 +08:00
ldm0 c2a927f105 fix(fonts): validate every decoded font table extent 2026-10-05 04:22:55 +08:00
ldm0 ab4c396280 chore(release): update version to 1.1.13 2026-10-04 02:34:46 +08:00
ldm0 6ecf3f0c03 fix(css): parse stylesheet preload type hints as MIME values 2026-10-04 02:33:39 +08:00
ldm0 eb37fce1a3 chore(release): update version to 1.1.12 2026-09-30 23:46:27 +08:00
ldm0 8fbf13300c fix(svg): reject trailing decimal path numbers 2026-09-30 22:57:34 +08:00
ldm0 4c56f704a3 perf(dom): update registry associations without global scans 2026-09-30 12:38:04 +08:00
ldm0 1e2b0bb46e fix(dom): enforce document.domain registrable boundaries 2026-09-30 12:01:16 +08:00
ldm0 ce2edbb9e1 fix(mime): unify JSON/font types and response header extraction
Accept text/json for JSON modules and use one is_json_mime classifier across
modules, documents, JSONPath, and resource inspection. Remove the module and
document aliases and recognize the seven registered application font types.

Use Fetch MIME extraction over the complete Content-Type header list for
script/style checks, workers, WebAssembly, ORB, and JSONPath. Derive classic
script charsets from the same MIME record, including charset inheritance and
resets when the MIME essence changes, while preserving BOM and fallback order.

Cover valid and invalid MIME types, header ordering, combined fields, quoted
commas, nosniff, and charset selection with regression tests.

Validation:
- cargo fmt --all
- cargo clippy --workspace --all-targets --all-features -- -D warnings
- cargo nextest run --no-fail-fast: 19,005 passed, 16 skipped
- Focused WPT: Moli passes 9 cases / 261 subtests, including the three JSON
  regressions and all 31 script Content-Type extraction checks.
2026-09-29 23:17:46 +08:00
ldm0 c3c279cf36 chore(release): update version to 1.1.11 2026-09-26 07:11:39 +08:00
ldm0 74e924c864 refactor(history): extract native Window history storage 2026-09-26 01:38:23 +08:00
ldm0 9b2f86bbf3 chore(release): update version to 1.1.10 2026-09-24 06:14:56 +08:00
ldm0 7e40b17284 refactor(history): extract pure session history state machine 2026-09-24 02:39:25 +08:00
ldm0 99fd6ad7c8 chore(deps): update Stylo lockfile revision 2026-09-23 17:40:55 +08:00
ldm0 c560d8fcfb fix(cssom): use native Stylo content alternative counters 2026-09-23 17:40:55 +08:00
ldm0 2d5b88b3dc fix(tls): use Apple SecTrust by default on macOS
Pin the curl-rust build that enables libcurl's Apple SecTrust verifier
with the existing AWS-LC TLS backend. Leave default CA options unset
so macOS trust comes from the operating system rather than an
automatically discovered certificate file.

Preserve explicit CA files and certificate environment overrides for
origins and HTTPS proxies, including explicit-file precedence over
SSL_CERT_DIR. Keep other platforms' existing trust configuration.

Add macos-latest CI coverage for local HTTPS, WSS, and
HTTPS proxy handshakes, including native-verifier diagnostics,
rejected certificates and hostnames, and CA overrides.

Use distinct CA and server identities, blocking accepted sockets, and
bounded fixture commands. Exercise the generated chains, nonblocking
socket transition, and process deadlines in portable regression tests.

Validated on Linux with cargo fmt --all, workspace Clippy with all
targets and features, and cargo nextest run --no-fail-fast:
18447 passed, 14 skipped. macOS-specific checks run in CI.

Refs #701
2026-09-23 14:07:31 +08:00
ldm0 6d08975a69 refactor(fetch): preserve response header bytes end to end
Carry raw response header values through fetch, caches, redirects,
renderer delivery, workers, and protocol records. Convert explicitly
at WebIDL and protocol text boundaries while preserving opaque bytes.

Keep legacy CacheStorage and service worker metadata readable, and
advance the HTTP cache format for raw header values.

Validation:
- cargo fmt --all
- cargo clippy --workspace --all-targets --all-features -- -D warnings
- cargo nextest run --no-fail-fast
2026-09-23 02:02:54 +08:00
ldm0 18a9f45be2 feat(resource): integrate shared disk-backed response storage
Share one disk pool and parkable-image manager across each browser resource runtime. Adopt completed image receive buffers without a full body clone, share encoded backing with network records and decoders, and drive parking by deadlines. Integrate pooled streaming bodies, release staging capacity after spooling, and use tagged image completions throughout resource loading.
2026-09-21 16:47:19 +08:00
ldm0 0099465abc feat(parkable-image): add managed encoded image parking
Adopt completed image buffers, protect readers with snapshots, and park encoded bytes into one disk extent with a reusable backup. Keep resident and parked registries separate, expose owner-driven deadlines and force parking, and synchronize notifications with a short-lock waiting flag. Include lifecycle, concurrency, scheduling, and failure regressions with documentation and runnable examples.
2026-09-21 16:47:19 +08:00
ldm0 92bdee88a4 feat(disk-pool): add shared temporary-file extent storage
Store immutable resource extents in one anonymous temporary file using positioned I/O. Reuse exact or worst-fit holes through offset and size indexes, coalesce released extents, and preserve bounded-capacity and failure behavior. Include allocator regression tests, concise documentation, and runnable examples.
2026-09-21 16:47:19 +08:00
ldm0 796376878b refactor(curl): use owned byte header lists from curl-rust 2026-09-21 05:37:28 +08:00
ldm0 932a7225ac refactor(network): preserve request header bytes across interception
Carry RequestHeaders through navigation, Fetch/XHR, workers, redirects and auth,
with explicit Unicode and ByteString conversions at protocol and WebIDL boundaries.
Share the raw curl header list with WebSocket transport and decode binary response
headers without UTF-8 replacement. Keep header memory charging concrete.

Cover opaque values, UTF-8 overrides, duplicates, redirect/auth continuation and
WebSocket handshakes with byte-level regression tests.
2026-09-21 03:54:12 +08:00
kevin 107c1536cb Retain image references without inferring content from pixels 2026-09-20 20:50:03 +08:00
kevin 4052110cff Preserve ambiguous embedded images and picture alternatives 2026-09-20 20:50:03 +08:00
kevin 91e9b568bd fix(html2md): detect empty inline SVGs structurally 2026-09-20 20:50:03 +08:00
Donough Liu 4751262331 refactor(profile): use standard library file locking 2026-09-20 10:24:50 +08:00
Random30000 dcdca64d3e fix(profile): recover Windows lock after process exit 2026-09-20 08:22:07 +08:00
ldm0 8668a6f9fc chore(release): update version to 1.1.9 2026-09-19 18:23:13 +08:00
ldm0 984c20ec98 Fix table cell baselines and float vertical alignment 2026-09-18 16:19:13 +08:00
ldm0 d98b2255f1 Fix table cell containing blocks and measured baselines 2026-09-18 16:19:13 +08:00
ldm0 3e3f291e64 chore(release): update version to 1.1.8 2026-09-18 15:14:30 +08:00
ldm0 ad0599b6a9 fix: pin proxy endpoint resolution 2026-09-18 14:13:58 +08:00
ldm0 fcc7168925 fix: prevent DNS rebinding in network policy 2026-09-18 14:13:58 +08:00
ldm0 0f3e3acd4d fix(layout): preserve inline clearance below floats
Move inline content that cannot fit beside floats to the first suitable slot,
and retain that clearance in CSS baseline and container-height calculations.
This places GitHub's full-width Show more activity button below its timeline.

Update Taffy to e4e8f77c for float segment extension and content-slot fallback.
Preserve whitespace collapsing around out-of-flow loading hints and cover
float placement, staggered heights, and pre/nowrap behavior in regressions.
2026-09-18 12:43:03 +08:00
ldm0 b5eb73989e chore(release): update version to 1.1.7 2026-09-16 16:20:32 +08:00