Karl Seguin
1a7dbd56ac
Dispatch slotchange event
...
The first time a `slotchange` event is registered, we setup a SlotChangeMonitor
on the page. This uses a global (ugh) MutationEvent to detect slot changes.
We could improve the perfomance of this by installing a MutationEvent per
custom element, but a global is obviously a lot easier.
Our MutationEvent currently fired _during_ the changes. This is problematic
(in general, but specifically for slotchange). You can image something like:
```
slot.addEventListener('slotchange', () => {
// do something with slot.assignedNodes()
});
```
But, if we dispatch the `slotchange` during the MutationEvent, assignedNodes
will return old nodes. So, our SlotChangeMonitor uses the page scheduler to
schedule dispatches on the next tick.
2025-09-23 17:41:05 +08:00
nikneym
71bc624a74
add a link element test
2025-09-22 16:35:06 +03:00
Karl Seguin
b248a2515e
Merge pull request #1071 from lightpanda-io/nikneym/element-dir
...
Add `element.dir` getter & setter
2025-09-19 16:51:32 +08:00
nikneym
6826c42c65
check for correct dir in HTML elements
2025-09-19 11:30:15 +03:00
nikneym
4f041e48a3
make sure dir attribute is parsed if provided
2025-09-19 11:26:53 +03:00
nikneym
ec6800500b
add a test for element.dir
2025-09-19 11:11:58 +03:00
Muki Kiboigo
25962326d2
add support for Response.type
2025-09-18 22:27:51 -07:00
Karl Seguin
36ce227bf6
Merge pull request #1055 from lightpanda-io/env_string
...
e2e-test / zig build release (push) Has been cancelled
e2e-test / demo-scripts (push) Has been cancelled
e2e-test / cdp-and-hyperfine-bench (push) Has been cancelled
e2e-test / perf-fmt (push) Has been cancelled
zig-test / zig build dev (push) Has been cancelled
zig-test / browser fetch (push) Has been cancelled
zig-test / zig test (push) Has been cancelled
zig-test / perf-fmt (push) Has been cancelled
Introduces an Env.String for persistent strings
2025-09-18 19:06:46 +08:00
Pierre Tachoire
2d24e3c7f7
Merge pull request #972 from lightpanda-io/fetch
...
Fetch + ReadableStream
2025-09-18 09:29:05 +02:00
Karl Seguin
66362c2762
Give tests <!DOCTYPE html> so they work correct in browser
2025-09-18 10:53:29 +08:00
Muki Kiboigo
2a0964f66b
htmlRunner for ReadableStream tests, fix ReadableStream enqueue
2025-09-17 08:46:25 -07:00
Karl Seguin
24330a7491
remove meaningless text from test
2025-09-17 08:46:16 -07:00
Karl Seguin
cd763a7a35
fix arena, add fetch test
2025-09-17 08:46:03 -07:00
Muki Kiboigo
969bfb4e53
migrate fetch tests to htmlRunner
2025-09-17 08:45:42 -07:00
Karl Seguin
6b9dc90639
Introduces an Env.String for persistent strings
...
If a webapi has a []const u8 parameter, then the page.call_arena is used. This
is our favorite arena to use, but if the string value has a lifetime beyond the
call, it then needs to be duped again (using page.arena).
When a webapi has a Env.String parameter, the page.arena will be used directly
to get the value from V8, removing the need for an intermediary dupe in the
call_arena.
This allows HTMLCollections to be streamlined. They no longer need to dupe the
filter (tag name, class name, ...), which means they can no longer fail. It also
means that we no longer need to needlessly dupe the string literals.
2025-09-17 12:12:42 +08:00
Karl Seguin
4f127c9de3
Bubble events to the Window
2025-09-15 22:24:35 +08:00
Karl Seguin
2aeeb14c21
Merge pull request #1043 from lightpanda-io/html_slot_assigned_elements
...
e2e-test / zig build release (push) Has been cancelled
zig-test / zig build dev (push) Has been cancelled
zig-test / zig test (push) Has been cancelled
e2e-test / demo-scripts (push) Has been cancelled
e2e-test / cdp-and-hyperfine-bench (push) Has been cancelled
e2e-test / perf-fmt (push) Has been cancelled
zig-test / browser fetch (push) Has been cancelled
zig-test / perf-fmt (push) Has been cancelled
nightly build / build-linux-x86_64 (push) Has been cancelled
nightly build / build-linux-aarch64 (push) Has been cancelled
nightly build / build-macos-aarch64 (push) Has been cancelled
nightly build / build-macos-x86_64 (push) Has been cancelled
wpt / web platform tests json output (push) Has been cancelled
wpt / perf-fmt (push) Has been cancelled
add assignedElements to HTMLSlotElement
2025-09-13 10:12:20 +08:00
Karl Seguin
e5e57ab3bd
Merge pull request #1044 from lightpanda-io/script_nonce_and_df_host
...
e2e-test / zig build release (push) Has been cancelled
e2e-test / demo-scripts (push) Has been cancelled
e2e-test / cdp-and-hyperfine-bench (push) Has been cancelled
e2e-test / perf-fmt (push) Has been cancelled
zig-test / zig build dev (push) Has been cancelled
zig-test / browser fetch (push) Has been cancelled
zig-test / zig test (push) Has been cancelled
zig-test / perf-fmt (push) Has been cancelled
nightly build / build-linux-x86_64 (push) Has been cancelled
nightly build / build-linux-aarch64 (push) Has been cancelled
nightly build / build-macos-aarch64 (push) Has been cancelled
nightly build / build-macos-x86_64 (push) Has been cancelled
wpt / web platform tests json output (push) Has been cancelled
wpt / perf-fmt (push) Has been cancelled
Add Script get/set nonce
2025-09-12 20:45:50 +08:00
Karl Seguin
f3ce5dcfbd
Add Script get/set nonce
2025-09-12 19:19:36 +08:00
nikneym
22b4456bce
correct indentation in tests
2025-09-12 13:39:05 +03:00
nikneym
8f31fd778b
add KeyboardEvent tests
2025-09-12 13:38:47 +03:00
nikneym
3964f8649d
initial keyboard event
2025-09-12 13:33:30 +03:00
Karl Seguin
b7fb0ef1d3
add assignedElements to HTMLSlotElement
2025-09-12 17:40:29 +08:00
Karl Seguin
0913abe806
Improve TextDecoder.decode
...
1 - Optional input (why? I don't know, but it's part of the spec and happens)
2 - Optional stream parameter
3 - More test cases
2025-09-12 12:31:28 +08:00
Karl Seguin
75f0cd6e62
fix test
2025-09-11 16:10:06 +08:00
Karl Seguin
ede35718ae
migrate more tests to htmlRunner
2025-09-11 12:07:17 +08:00
Karl Seguin
f77693d768
migrate more tests to htmlRunner
2025-09-10 20:32:15 +08:00
Karl Seguin
edd41b37f0
Merge pull request #1033 from lightpanda-io/nikneym/custom-event
...
Support for CustomEvent in document.createEvent
2025-09-10 15:23:34 +08:00
Karl Seguin
a5d9b658fb
migrate more tests to htmlRunner
2025-09-10 11:54:03 +08:00
nikneym
10fc056184
createEvent should increase tag count by 1
2025-09-09 21:56:10 +03:00
nikneym
7517937155
add createEvent tests
2025-09-09 21:45:09 +03:00
Karl Seguin
56b08bddd8
migrate more tests to htmlRunner
2025-09-09 20:40:19 +08:00
Karl Seguin
4ab7fe26fc
Merge pull request #1025 from lightpanda-io/migrate_some_tests_7
...
migrate more tests to htmlRunner
2025-09-09 19:41:56 +08:00
Karl Seguin
1ca8dc0ac0
Merge pull request #1022 from lightpanda-io/slot
...
e2e-test / zig build release (push) Has been cancelled
e2e-test / demo-scripts (push) Has been cancelled
e2e-test / cdp-and-hyperfine-bench (push) Has been cancelled
e2e-test / perf-fmt (push) Has been cancelled
zig-test / zig build dev (push) Has been cancelled
zig-test / browser fetch (push) Has been cancelled
zig-test / zig test (push) Has been cancelled
zig-test / perf-fmt (push) Has been cancelled
Start working on HTMLSlotElement
2025-09-09 11:52:04 +08:00
Karl Seguin
85d148822e
migrate more tests to htmlRunner
2025-09-09 11:48:08 +08:00
Karl Seguin
15628d9b07
migrate more tests to htmlRunner
2025-09-08 18:40:59 +08:00
Karl Seguin
950182986a
Start working on HTMLSlotElement
2025-09-08 17:36:45 +08:00
Pierre Tachoire
bc82023878
Merge pull request #1020 from lightpanda-io/inline_script_ignore_defer
...
e2e-test / zig build release (push) Has been cancelled
zig-test / zig build dev (push) Has been cancelled
zig-test / zig test (push) Has been cancelled
e2e-test / demo-scripts (push) Has been cancelled
e2e-test / cdp-and-hyperfine-bench (push) Has been cancelled
e2e-test / perf-fmt (push) Has been cancelled
zig-test / browser fetch (push) Has been cancelled
zig-test / perf-fmt (push) Has been cancelled
nightly build / build-linux-x86_64 (push) Has been cancelled
nightly build / build-linux-aarch64 (push) Has been cancelled
nightly build / build-macos-aarch64 (push) Has been cancelled
nightly build / build-macos-x86_64 (push) Has been cancelled
wpt / web platform tests json output (push) Has been cancelled
wpt / perf-fmt (push) Has been cancelled
Inline script tags ignore defer/async
2025-09-05 17:44:45 +02:00
Karl Seguin
eb453f471b
Inline script tags ignore defer/async
...
According to MDN, inline script tags should not have defer/async attributes. But
some do. This ignores those attributes for inline script tags.
(Previously, we were only half ignoring them. We were treating them as inline,
but flagging them as deferred or async, which was causing issues with cleanup)
Fixes: https://github.com/lightpanda-io/browser/issues/1014
2025-09-05 23:23:31 +08:00
Karl Seguin
afd278ca4e
Fix the Screen and ScreenOrientation prototype
2025-09-05 19:08:07 +08:00
Karl Seguin
dd22c55d23
migrate to htmlRunne (plus zig fmt)
2025-09-05 13:52:08 +08:00
Karl Seguin
5087b8004a
Merge pull request #1009 from lightpanda-io/migrate_some_tests_4
...
e2e-test / zig build release (push) Has been cancelled
e2e-test / demo-scripts (push) Has been cancelled
e2e-test / cdp-and-hyperfine-bench (push) Has been cancelled
e2e-test / perf-fmt (push) Has been cancelled
zig-test / zig build dev (push) Has been cancelled
zig-test / browser fetch (push) Has been cancelled
zig-test / zig test (push) Has been cancelled
zig-test / perf-fmt (push) Has been cancelled
nightly build / build-linux-x86_64 (push) Has been cancelled
nightly build / build-linux-aarch64 (push) Has been cancelled
nightly build / build-macos-aarch64 (push) Has been cancelled
nightly build / build-macos-x86_64 (push) Has been cancelled
wpt / web platform tests json output (push) Has been cancelled
wpt / perf-fmt (push) Has been cancelled
migrate to htmlRunner
2025-09-04 18:32:17 +08:00
Karl Seguin
5af55f1d5d
migrate to htmlRunner
2025-09-04 17:46:42 +08:00
Karl Seguin
327b4e4e37
migrate to htmlRunner
2025-09-04 13:11:15 +08:00
Karl Seguin
0382c2775e
Migrate more tests to html runner
...
Implement LocalStorage named get/set (i.e. localStorage["hi"])
2025-09-03 22:54:41 +08:00
Karl Seguin
a0374133cd
migrate tests to new html runner
2025-09-03 22:54:40 +08:00
Karl Seguin
81766c8517
Migrate some tests to the new htmlRunner
...
Fix events.get_timeStamp (was events.get_timestamp, wrong casing).
Rename `newRunner` to `htmlRunner`.
move tests to src/tests (from src/browser/tests). src/runtime and possibly other
parts might want to have html tests too.
2025-09-02 10:40:04 +08:00