Commit Graph

6686 Commits

Author SHA1 Message Date
Muki Kiboigo
fd8cb46f41 header callback returns a HeaderResult 2026-06-08 07:58:42 -07:00
Muki Kiboigo
06b430db85 working cache revalid 2026-06-08 07:40:35 -07:00
Muki Kiboigo
7cc07f340b better handling of stale entry 2026-06-08 07:18:53 -07:00
Muki Kiboigo
e30a8cb32d send served from cache notification in one place 2026-06-08 07:15:32 -07:00
Muki Kiboigo
ea2ef08b92 simplify CacheLayer request logic 2026-06-08 07:15:12 -07:00
Muki Kiboigo
e34e9b4188 update CacheControl test 2026-06-08 07:14:18 -07:00
Muki Kiboigo
23b2da34ea etag and last_modified null by default 2026-06-08 07:14:18 -07:00
Muki Kiboigo
c06dd755b6 Cache.revalidate -> Cache.renew 2026-06-08 07:14:18 -07:00
Muki Kiboigo
ee8fbbce41 properly notify and serve from cache on revalidation 2026-06-08 07:14:17 -07:00
Muki Kiboigo
422ba672ea don't treat 304 as a redirect 2026-06-08 07:14:17 -07:00
Muki Kiboigo
c808015c47 Cache Revalidation 2026-06-08 07:14:17 -07:00
Muki Kiboigo
dc6fc5b353 add Cache.revalidate + supporting logic 2026-06-08 07:14:16 -07:00
Pierre Tachoire
bf9df04509 Merge pull request #2669 from lightpanda-io/fix-integration-cache
Fix integration cache
2026-06-08 14:24:08 +02:00
Pierre Tachoire
8d98d7aa99 ci: add missing cache key for integration test 2026-06-08 12:05:44 +02:00
Pierre Tachoire
22d1c5ecd1 Merge pull request #2654 from lightpanda-io/form-upload-file
form: encode file inputs as multipart/form-data on submit
2026-06-08 11:47:54 +02:00
Karl Seguin
4fc0ba7dcb Merge pull request #2667 from lightpanda-io/arena_pool_debug_cleanup
Improve ArenaPool release debug reporting
2026-06-08 17:32:52 +08:00
Pierre Tachoire
3ec0c25dde Merge pull request #2665 from mvanhorn/fix/2610-axnode-password-input-textbox-role
fix: map password inputs to textbox accessibility role
2026-06-08 11:21:32 +02:00
Pierre Tachoire
a7705abde0 Merge pull request #2660 from lightpanda-io/ci-save-cache
ci: save LP cache for integration tests
2026-06-08 11:20:28 +02:00
Pierre Tachoire
41cff18e75 ci: save LP cache for integration tests 2026-06-08 10:56:26 +02:00
Pierre Tachoire
b2002a8dca Merge pull request #2657 from rohitsux/feat/cdp-mouse-button-clickcount
feat(cdp): support mouse button and clickCount in Input.dispatchMouseEvent
2026-06-08 10:53:59 +02:00
Pierre Tachoire
530a9e0765 deinit FormData to release files 2026-06-08 10:26:02 +02:00
Karl Seguin
e64aa70c34 Improve ArenaPool release debug reporting
Cherry-picked from https://github.com/lightpanda-io/browser/pull/2623 since the
main issue in that PR was directly solved by https://github.com/lightpanda-io/browser/pull/2625
but the ArenaPool change is still worth keeping. The change is: that we
check for a double-release BEFORE resetting the arena, which would cause the
invalid flow to appear in a harder-to-debug spot.
2026-06-08 15:24:27 +08:00
Pierre Tachoire
845dac86ba FormData: fix file leak on deletion 2026-06-08 09:10:01 +02:00
Pierre Tachoire
6aa4ef074f call the ref count release after releasing coupled data 2026-06-08 08:51:01 +02:00
Pierre Tachoire
4c06cfb17c use u8 for reference counter
Co-authored-by: Karl Seguin <karlseguin@users.noreply.github.com>
2026-06-08 08:49:07 +02:00
Matt Van Horn
e7cce250d3 fix: map password inputs to textbox accessibility role 2026-06-07 23:45:20 -07:00
Pierre Tachoire
fdf6276f39 cdp: use Frame.mouse_button consts from cdp.input.zig 2026-06-08 08:42:54 +02:00
Karl Seguin
8b16a5a650 Merge pull request #2661 from lightpanda-io/async_action_sequence
Fire actionSequence on the next tick
2026-06-08 06:39:31 +08:00
Karl Seguin
c8df32b98a Merge pull request #2659 from rohitsux/feat/element-scroll-into-view
feat(webapi): implement Element.scrollIntoView
2026-06-07 13:55:56 +08:00
Karl Seguin
6522615e21 zig fmt 2026-06-07 12:34:30 +08:00
Karl Seguin
1ffc84d947 implement the IfNeeded part of scrollIntoViewIfNeeded 2026-06-07 12:32:39 +08:00
Rohit
e68def97b3 refactor(cdp): use named constants for mouse button values
Address review: replace the bare 0/1/2 button values in the
mousedown/release switch (Frame.zig) and the CDP button mapping
(input.zig) with named constants so the code self-documents.
2026-06-06 19:03:45 +05:30
Karl Seguin
802163308e zig fmt 2026-06-06 19:04:15 +08:00
Karl Seguin
c55dcf0484 Fire actionSequence on the next tick
Apparently, that's what's expected and not doing this can break some tests
2026-06-06 19:01:16 +08:00
Pierre Tachoire
29b407bc30 Merge pull request #2653 from lightpanda-io/element_set_style
add Element.style setter
2026-06-06 09:24:13 +02:00
Karl Seguin
a68598fa5d Merge pull request #2650 from lightpanda-io/fix_arena_leaks
Fix two arena leaks
2026-06-06 07:21:39 +08:00
Karl Seguin
0406451750 Merge pull request #2596 from lightpanda-io/robots-next-tick-on-sync-deny
Robots Deny on Next Tick
2026-06-06 07:21:10 +08:00
Karl Seguin
b82af40453 Merge pull request #2655 from lightpanda-io/improve_import_fail_error
Better import error return
2026-06-06 07:20:23 +08:00
Karl Seguin
50e1003be5 Merge pull request #2651 from lightpanda-io/extend_cdp_test_timeout
Extend the TCP read/write timeout from 2 second to 10.
2026-06-06 07:20:09 +08:00
Karl Seguin
c7d8cb4bb9 Merge pull request #2656 from lightpanda-io/atob_btoa
Fix atob/btoa
2026-06-06 07:19:50 +08:00
Pierre Tachoire
8c1c3c93f8 couple FormData and its Files lifetime 2026-06-05 18:13:01 +02:00
Rohit
b77d0f8ed1 feat(webapi): implement Element.scrollIntoView
Element.scrollIntoView and scrollIntoViewIfNeeded were no-op stubs.
Implement them to scroll the window so the element's position is
brought into the viewport, using the element's document position (the
same source getBoundingClientRect uses) and Window.scrollTo.

This lets automation reach below-the-fold elements before interacting
with them.
2026-06-05 20:22:34 +05:30
Rohit
1776d0ea71 feat(cdp): support mouse button and clickCount in Input.dispatchMouseEvent
Input.dispatchMouseEvent ignored the button and clickCount params, and
mousePressed only fired a click event (never mousedown). Add them:

- mousePressed now fires mousedown carrying the pressed button.
- mouseReleased fires mouseup, then the button-appropriate activation
  event: click for the main button, auxclick for the auxiliary button,
  and contextmenu for the secondary (right) button.
- a clickCount of 2 additionally fires dblclick.

This unblocks right-click, middle-click and double-click interactions
for Playwright/Puppeteer scripts. Follows the mouse event work in
#2636, #2640 and #2641.
2026-06-05 20:08:46 +05:30
Muki Kiboigo
22410510db Synthetic runNextTick takes null as ctx 2026-06-05 07:26:40 -07:00
Muki Kiboigo
572267802d fire RobotsBlocked in nextTickRun 2026-06-05 07:25:32 -07:00
Muki Kiboigo
ffcdcc6e09 add optional ctx to runNextTick 2026-06-05 07:25:29 -07:00
Pierre Tachoire
6ae3233f0e form: fix no file selection case 2026-06-05 15:55:56 +02:00
Karl Seguin
c4e859d735 fix tests 2026-06-05 21:19:46 +08:00
Karl Seguin
b0ebbf7b35 zig fmt 2026-06-05 20:46:48 +08:00
Karl Seguin
14aec37652 Fix atob/btoa
Passes WPT /html/webappapis/atob/base64.html

Two changes
1 - Use the forgiving decoder already in data_url
2 - Coerce input (3 => "3")

The 2nd change was more interesting. These take a js.String.OneByte as an
optimization, which doesn't coerce. To preserve this optimization a union was
used with a `raw: []const u8` fallback (and our bridge always coerces to
a `[]const u8`)
2026-06-05 20:44:19 +08:00