Aliaksandr Kalenik
912cf89727
LibWeb: Update HTMLIFrameElement to use navigables
2023-09-16 16:53:32 +02:00
Aliaksandr Kalenik
623d1a78da
LibWeb: Update HTMLObjectElement to use navigables
2023-09-16 16:53:32 +02:00
Aliaksandr Kalenik
3634749d98
LibWeb: Update Window::open_impl()
to use navigables
2023-09-16 16:53:32 +02:00
Aliaksandr Kalenik
1e54026269
LibWeb: Update History::go()
to use navigables
2023-09-16 16:53:32 +02:00
Aliaksandr Kalenik
7dd01b245b
LibWeb: Remove unused Page::load(LoadRequest&)
2023-09-16 16:53:32 +02:00
Aliaksandr Kalenik
dd9eca254e
LibWeb: Update WindowProxy::internal_get_own_property
for navigables
2023-09-16 16:53:32 +02:00
Aliaksandr Kalenik
d45f2a4952
LibWeb: Update Location::replace()
to use navigables
2023-09-16 16:53:32 +02:00
Aliaksandr Kalenik
acff244335
LibWeb: Use navigate()
instead of did_set_location_href
in Location
2023-09-16 16:53:32 +02:00
Aliaksandr Kalenik
083e4a3f30
LibWeb: Update Location::reload()
to use navigables
2023-09-16 16:53:32 +02:00
Aliaksandr Kalenik
dd7bba66ed
LibWeb: Change viewport ownership from BrowsingContext
to Navigable
2023-09-16 16:53:32 +02:00
Aliaksandr Kalenik
4356d37b2c
LibWeb: Update SVGDecodedImageData to use navigables
2023-09-16 16:53:32 +02:00
Aliaksandr Kalenik
c7a6d418d7
LibWeb: Update HTMLHyperlinkElementUtils to use navigables
2023-09-16 16:53:32 +02:00
Aliaksandr Kalenik
857537f90c
LibWeb: Update HTMLFormElement to use navigables
2023-09-16 16:53:32 +02:00
Aliaksandr Kalenik
4a6ac18cd4
LibWeb: Call did_finish_load when page readiness changes to complete
...
Before, this function were called from FrameLoader and now we have to
move it to another place so it is still called after migrating to
navigables.
2023-09-16 16:53:32 +02:00
Aliaksandr Kalenik
2323c77718
LibWeb: Call page_did_create_main_document() from navigables navigation
...
Before, this function were called from FrameLoader and now we still
have to call it from navigables navigation code so JS Console is
created.
2023-09-16 16:53:32 +02:00
Aliaksandr Kalenik
aef4b84e22
LibWeb+WebContent: Add option to dump session history of a traversable
2023-09-16 16:53:32 +02:00
Aliaksandr Kalenik
537bf4c917
LibWeb: Update Document::is_fully_active() to match latest spec
2023-09-16 16:53:32 +02:00
Aliaksandr Kalenik
bd119b92f1
LibWeb: Update Document::is_active() for navigables
2023-09-16 16:53:32 +02:00
Aliaksandr Kalenik
e5302e0f56
LibWeb: Update Document::unload() to match latest spec
2023-09-16 16:53:32 +02:00
Aliaksandr Kalenik
359d8a3dc2
LibWeb: Update Document::create_and_initialize() to match latest spec
2023-09-16 16:53:32 +02:00
Aliaksandr Kalenik
2c3bb26551
LibWeb: Update the document "abort" algorithm for navigables
2023-09-16 16:53:32 +02:00
Aliaksandr Kalenik
ce9af96f78
LibWeb: Use document from DocumentState in navigation
...
New navigables spec assumes that document pointer is located in
DocumentState instead of SessionHistoryEntry like it was in the
old navigation spec.
2023-09-16 16:53:32 +02:00
Aliaksandr Kalenik
ee50d9b2b5
LibWeb: Update Page to use navigables
2023-09-16 16:53:32 +02:00
Andreas Kling
f91b34ef2e
LibWeb: Update "obtain a BC to use for a navigation response"
...
This no longer calls "discard" on the browsing context, since discarding
is going away.
2023-09-16 16:53:32 +02:00
Andreas Kling
39f16ecd41
LibWeb: Don't break for atomic inline elements in white-space: nowrap
2023-09-16 15:21:16 +02:00
Andreas Kling
35ff38aaea
LibWeb: Visit Document::m_visual_viewport
...
Another day, another missing visit_edges() :^(
2023-09-16 14:46:38 +02:00
Shannon Booth
e74031a396
LibWeb: Port Document interface from DeprecatedString to String
2023-09-16 11:17:19 +02:00
Shannon Booth
9d88e14f20
LibWeb: Add String variants of get_element_by_{} in ParentNode
...
These are required for porting over Document from DeprecatedString to
String. We unfortunately can't port this completely over yet as
ParentNode is included by the Element IDL interface, which has not yet
been ported over from DeprecatedString.
2023-09-16 11:17:19 +02:00
Andrew Kaster
bd131c0bf8
LibWeb: Use "Android" as the OS string on Android
2023-09-15 14:18:52 -06:00
Bastiaan van der Plaat
e267f8e68f
LibWeb: Add modifier keys to MouseEvent
2023-09-15 22:12:56 +02:00
Bastiaan van der Plaat
836a7b00dd
Ladybird+LibWeb: Add MouseEvent screenX and screenY support
2023-09-15 22:12:56 +02:00
Bastiaan van der Plaat
e584189b8f
LibWeb: Reorder MouseEvent items to follow spec more
2023-09-15 22:12:56 +02:00
Kemal Zebari
824c54acaf
LibWeb/URL: Add strip_trailing_spaces_from_an_opaque_path()
...
Also remove 2 FIXMEs by including this function.
2023-09-15 11:15:43 -06:00
Kemal Zebari
ce549eb92a
LibWeb/URL: Don't have URL::pathname()
perform percent decode
...
Since the spec expects us to use AK::URL::serialize_path() without
doing any percent decoding.
2023-09-15 11:15:43 -06:00
Andrew Kaster
ae15b68b79
LibWeb: Call page_did_start_loading from navigate()
...
This fixes a crash in Browser on Serenity
2023-09-15 18:27:17 +02:00
Aliaksandr Kalenik
6522fa8933
LibWeb: Use DocumentLoadEventDelayer to delay load event in Navigable
...
Use a delayer object that actually delays load event for child
navigables instead of boolean flag that does nothing.
2023-09-15 18:27:17 +02:00
Aliaksandr Kalenik
b398d6a35c
LibWeb: Determine origin while populating navigation params from srcdoc
...
Address the FIXMEs by implementing the missing parts of the procedure
from the specification.
2023-09-15 18:27:17 +02:00
Aliaksandr Kalenik
7ad2dd2693
LibWeb: Exit navigation process if navigation id has changed
...
Change of navigation id means that it has been aborted, and we should
return early.
2023-09-15 18:27:17 +02:00
Aliaksandr Kalenik
b7c93cae7f
LibWeb: Set document content type in load_document()
...
Fixes regression in `load_document()` compared to FrameLoader.
2023-09-15 18:27:17 +02:00
Aliaksandr Kalenik
c437f16cc1
LibWeb: Early return navigation process if navigable has been destroyed
...
If a navigable has been destroyed during a navigation process, we
should early return from it. The introduced checks are not in
the spec because, as explained in
https://github.com/whatwg/html/issues/9690 the spec is not written
with such a level of detail.
2023-09-15 18:27:17 +02:00
Aliaksandr Kalenik
c20123378d
LibWeb: Add unloading of child navigables in "apply the history step"
...
Implements missing step from the spec.
2023-09-15 18:27:17 +02:00
Aliaksandr Kalenik
2445205e9d
LibWeb: Align session history step application code with latest spec
...
Replaces direct "apply the history step" calls with new functions from
the spec:
- "update for navigable creation/destruction"
- "apply the push/replace history step"
- "apply the reload history step"
2023-09-15 18:27:17 +02:00
Aliaksandr Kalenik
d3d2e56a68
LibWeb: Call set_ongoing_navigation()
on navigable instead of this
...
This fixes incorrectly implemented spec when `set_ongoing_navigation()`
is called on `this` (=traversable) instead of `navigable` variable.
2023-09-15 18:27:17 +02:00
Aliaksandr Kalenik
799b465fac
LibWeb: Compare urls excluding fragments in Navigable::navigate()
2023-09-15 18:27:17 +02:00
Aliaksandr Kalenik
fbc95440a4
LibWeb: Only return initialized navigables from child_navigables()
...
Fixes a crash in `get_session_history_entries()` that happens when
it attempts to find entries for a navigable that hasn't been fully
initialized and therefore doesn't have a nested history entry yet.
2023-09-15 18:27:17 +02:00
Aliaksandr Kalenik
15d265da65
LibWeb: Fix "stack-use-after-return" in navigate_to_a_fragmement()
...
Callback running on the session history queue should capture necessary
pointers by value instead of reference, because navigate_to_a_fragment
stack will have been destroyed by the time it will be executed.
2023-09-15 18:27:17 +02:00
Andreas Kling
23569f8690
LibWeb: Allow fractional font sizes in CSS
...
Fixes an issue where relative font sizes would "snap" to integer sizes
in an unpleasant-looking way while resizing on some websites.
2023-09-15 18:26:37 +02:00
Luke Wilde
56f0b10d14
LibWeb: Fix setTimeout() when there's no active script
...
Implements https://github.com/whatwg/html/pull/9712
Fixes https://github.com/SerenityOS/serenity/issues/20970
2023-09-15 08:53:21 +02:00
Luke Wilde
9335524f15
LibWeb: Default ScriptFetchOptions parser metadata to NotParserInserted
...
See: https://html.spec.whatwg.org/multipage/webappapis.html#default-classic-script-fetch-options
2023-09-15 08:53:21 +02:00
Aliaksandr Kalenik
6f8be44c0e
LibWeb+WebContent+headless-browser: Support async text tests
...
Previously, we used `on_load_finish` to determine when the text test
was completed. This method did not allow testing of async functions
because there was no way to indicate that the runner should wait for
the async call to end.
This change introduces a function in the `internals` object that is
intended to be called when the text test execution is completed. The
text test runner will now ignore `on_load_finish` which means a test
will timeout if this new function is never called.
`test(f)` function in `include.js` has been modified to automatically
terminate a test once `load` event is fired on `window`.
new `asyncTest(f)` function has been introduces. `f` receives function
that will terminate a test as a first argument.
Every test is expected to call either `test()` or `asyncTest()` to
complete. If not, it will remain hanging until a timeout occurs.
2023-09-15 08:52:25 +02:00