Shannon Booth
1308cab372
LibURL+LibWeb: Do not percent decode in password/username getters
...
Doing it is not part of the spec. Whenever needed, the spec will
explicitly percent decode the username and password.
This fixes some URL WPT tests.
(cherry picked from commit f511c0b441a591bc85f409242229c7b295e118e4)
2024-10-15 12:08:50 -04:00
Tim Ledbetter
84187c2252
LibWeb: Don't crash when parsing HTMLInputElement invalid time values
...
(cherry picked from commit fe42e2719f1ba92e04a530ca3910a7c8bfbbf1af)
2024-10-11 21:15:10 -04:00
Andreas Kling
dc8eb851ca
LibWeb: Make requestAnimationFrame() callback IDs sequential
...
This is required by the spec, so let's stop returning random IDs in
favor of a simple sequential integer sequence.
(cherry picked from commit 0e1256e5a405627fda18b597d8fd08073dd60b77)
2024-10-11 09:27:51 -04:00
Timur Sultanov
ff18de7f46
Tests: Add test for selection option in <select>
...
Verify that we can select option using JS
(cherry picked from commit 1ce9bbdd6dcf0f1634014e57d700b697635a79d8)
2024-07-28 12:59:58 -04:00
Jamie Mansfield
a28019e98b
LibWeb/HTML: Implement HTMLMediaElement.addTextTrack
...
Removes some noise from the console when browsing bbc.co.uk :^)
(cherry picked from commit 793248aec977d4b15006d6e55a960da2e115a734,
amended to s/UIEvents::KeyCode/KeyCode/ to resolve cherry-pick conflict)
2024-07-28 07:32:58 -04:00
Timur Sultanov
a74e721c09
Tests: Add tests for <select> element behavior
...
Check that `<select>` element has options available immediately
(cherry picked from commit 2bf37cb91444dbdaa8e0ccf965b7c9e84717da12)
2024-07-28 07:30:11 -04:00
Andreas Kling
99a06079ce
LibWeb: Don't proceed with Element.click() on disabled form controls
...
Fixes an infinite reload loop on some of the dom/events/ tests in WPT.
(cherry picked from commit 273593afba71a42f1d760ac5b6664b77f74ffb7a)
2024-07-28 07:29:46 -04:00
Edwin Hoksberg
a4ed72afae
LibWeb: Implement Element::check_visibility
...
(cherry picked from commit 5f154ba372f9a667351a026aa4a31306c45fd2a5)
2024-07-24 08:08:15 -04:00
Jamie Mansfield
2ad1fa17fb
LibWeb/SVG: Implement SVGAElement.relList
...
(cherry picked from commit 6ca4c2beb08a81bc4aaa2571ee8c5b3207d0b3a2)
2024-07-21 16:55:11 -04:00
Andreas Kling
7ddd8bac62
LibWeb: Cap HTML dimension values at 17895700 (same as Firefox)
...
Instead of allowing arbitrarily large values (which could eventually
overflow an i32), let's just cap them at the same limit as Firefox does.
Found by Domato.
(cherry picked from commit 4e0edd42b95abf8ad707c64414dbe618313ce89e)
2024-07-21 14:07:57 -04:00
Andreas Kling
d2ae01f8ad
LibWeb: Fix StringView OOB access when parsing 3-character legacy color
...
Found by Domato.
(cherry picked from commit 1c00e5688d3330626f809e758bb63c8348776971)
2024-07-21 14:07:57 -04:00
Tim Ledbetter
1506f72219
LibWeb: Populate filename in WindowOrWorkerGlobalScope.reportError()
...
Previously, when `WindowOrWorkerGlobalScope.reportError()` was called
the `filename` property of the dispatched error event was blank. It is
now populated with the full path of the active script.
(cherry picked from commit 34b987366449313c96a73ec1d70e88e60f2c4510)
2024-07-14 06:57:29 -04:00
Natsuki Ikeguchi
fceb6e021f
LibWeb: Add initial implementation of global.reportError()
...
(cherry picked from commit ccb3a2f7add22105a92ca997b67bbe02ec65b535)
2024-07-13 21:40:50 -04:00
Tim Ledbetter
d9245bc5ac
LibWeb: Implement the HTMLTrackElement.kind attribute
...
This reflects the HTML `kind` attribute.
(cherry picked from commit bdaa7f0e8ed738ad0bd6e19878f296436fe40377)
2024-07-01 12:45:34 +02:00
Tim Ledbetter
1d47886430
Tests/LibWeb: Wait until document fully loaded before simulating click
...
This makes the `form-image-submission.html` test pass more reliably.
(cherry picked from commit 2fed064791d3117e0571453210000d285ee9359c)
2024-06-27 13:42:20 +02:00
circl
462abc242e
Tests/LibWeb: Add test to verify correctness of getImageData
...
(cherry picked from commit dbc94ce92e09e987f8a07a5b1e978250286b015a)
2024-06-14 18:18:40 -04:00
Jamie Mansfield
ea69ec8e52
LibWeb: Use a single test for loading attribute
2024-06-08 14:16:48 -04:00
Jamie Mansfield
e5a1f1e582
LibWeb: Test fetchPriority attribute on all elements
2024-06-08 14:16:48 -04:00
Jamie Mansfield
91c7920b34
LibWeb: Implement HTMLAreaElement.referrerPolicy
2024-06-08 14:07:38 -04:00
Jamie Mansfield
07cd441e95
LibWeb: Implement HTMLIFrameElement.referrerPolicy
2024-06-08 14:07:38 -04:00
Jamie Mansfield
c8e87352d8
LibWeb: Implement HTMLImageElement.referrerPolicy
2024-06-08 14:07:38 -04:00
Jamie Mansfield
901fb0d068
LibWeb: Implement HTMLLinkElement.referrerPolicy
2024-06-08 14:07:38 -04:00
Jamie Mansfield
a6fd653afa
LibWeb: Use Reflect for HTMLAnchorElement.referrerPolicy
2024-06-08 14:07:38 -04:00
Jamie Mansfield
ade7c6c8fb
LibWeb: Use Enumerated for HTMLScriptElement.referrerPolicy
2024-06-08 14:07:38 -04:00
Jamie Mansfield
82fba65faa
LibWeb: Implement HTMLImageElement.crossOrigin
2024-06-05 05:02:55 +01:00
Jamie Mansfield
5adce08003
LibWeb: Implement HTMLLinkElement.crossOrigin
2024-06-05 05:02:55 +01:00
Jamie Mansfield
5ae9b49099
LibWeb: Implement HTMLImageElement.fetchPriority
2024-06-05 05:02:55 +01:00
Tim Ledbetter
7d192ed8c1
LibWeb: Don't crash on clicking a label with an associated text input
...
Previously, we assumed that all label control paintables were of type
`LabelablePaintable`. This caused a crash when clicking on a label with
a text input control.
2024-05-28 08:07:05 +02:00
Kenneth Myhra
dacba5e610
Tests/LibWeb: Initialize 'arrayBuffer' to an UInt8Array
...
This initializes 'arrayBuffer' to an UInt8Array so that we can
manipulate the contents of 'arrayBuffer'. The test verifies that the
internal buffer is an ArrayBuffer.
Also:
* Correct comparison in test so that we compare arrayBuffer to
arrayClone, not to itself.
* Remove FIXME, this outputs [object ArrayBuffer] in Firefox and Chrome
too.
2024-05-27 17:37:27 +02:00
Jamie Mansfield
600daea544
LibWeb: Implement HTMLIFrameElement.loading
2024-05-27 17:34:59 +02:00
Jamie Mansfield
9ee061ea14
LibWeb: Implement HTMLImageElement.loading
...
Removes some console noise while loading mmu.ac.uk :)
2024-05-27 17:34:59 +02:00
Andreas Kling
802af5ad9d
LibWeb: Allow Element.insertAdjacentHTML on the document element
...
This fixes wpt/domparsing/insert_adjacent_html.html
2024-05-27 17:33:29 +02:00
Shannon Booth
67b1f4af55
LibWeb: Implement HTMLFormElement.encoding
2024-05-26 07:47:59 +02:00
Shannon Booth
aeb815cc66
LibWeb: Implement HTMLFormElement.enctype
2024-05-26 07:47:59 +02:00
Tim Ledbetter
d2b3007248
IDLGenerators: Use spec-compliant algorithm to parse integer values
2024-05-23 04:15:46 +02:00
Tim Ledbetter
2a7cf1c588
LibWeb: Implement the width and height attributes where missing
...
This change adds the `width` and `height` properties to
`HTMLVideoElement` and `HTMLSourceElement`. These properties reflect
their respective content attribute values.
2024-05-21 19:28:43 +02:00
Tim Ledbetter
9f9aa62128
LibWeb: Implement the hspace and vspace attributes
...
These properties reflect their respective content attributes.
2024-05-21 19:28:43 +02:00
Tim Ledbetter
c36ba450be
LibWeb: Generate binding for HTMLObjectElement.contentWindow attribute
...
This only required adding the appropriate definition to the IDL file,
as `NavigableContainer` already implements the logic that we need.
2024-05-18 18:12:08 +02:00
Tim Ledbetter
2447a25753
LibWeb: Implement the labels attribute for all labelable elements
...
This returns a `NodeList` of all the labels associated with the given
element.
2024-05-18 18:09:18 +02:00
Tim Ledbetter
3dc86747f0
LibWeb: Implement the HTMLOutputElement.htmlFor attribute
...
This returns a DOMTokenList that reflects the `for` attribute.
2024-05-18 11:23:20 +02:00
Tim Ledbetter
acc1fa3c62
LibWeb: Generate binding for the HTMLObjectElement.form attribute
...
This only required adding the appropriate definition to the IDL file,
as `FormAssociatedElement` already implements the logic that we need.
2024-05-18 11:04:04 +02:00
Tim Ledbetter
6bf22075ed
LibWeb: Implement the HTMLLabelElement.form attribute
...
This returns the form element associated with the given label element's
control or null if the label has no control.
2024-05-18 11:04:04 +02:00
Tim Ledbetter
51fc30a191
LibWeb: Implement the HTMLLinkElement.relList attribute
...
This returns a DOMTokenList that reflects the `rel` attribute.
2024-05-16 08:06:26 +02:00
Tim Ledbetter
fc4e0cf10e
LibWeb: Implement the HTMLFormElement.relList attribute
...
This returns a DOMTokenList that reflects the `rel` attribute.
2024-05-16 08:06:26 +02:00
Tim Ledbetter
0a3e1846f0
LibWeb: Implement the HTMLAreaElement.relList attribute
...
This returns a DOMTokenList that reflects the `rel` attribute.
2024-05-16 08:06:26 +02:00
Tim Ledbetter
b7fd39c2e6
LibWeb: Implement the HTMLAnchorElement.relList attribute
...
This returns a DOMTokenList that reflects the `rel` attribute.
2024-05-16 08:06:26 +02:00
Tim Ledbetter
763b7f0e0c
LibWeb: Implement the HTMLOptionElement.form attribute
...
This returns the parent form of a HTMLOptionElement or null if the
element has no parent form.
2024-05-16 08:03:13 +02:00
Timothy Flynn
1fbf1bc4ac
LibWeb: Don't try to click a form image until it has loaded
...
We are often trying to click the image before it has finished loading.
This results in us trying to click a 0x0 rect. Instead, wait until the
image load event.
This fixes a flake with form-image-submission.html often seen on CI.
2024-05-09 19:29:47 +02:00
Shannon Booth
e070309258
LibWeb: Implement Element.outerHTML setter
2024-05-04 13:54:33 +02:00
Tim Ledbetter
dda730c46b
LibWeb: Exclude [Global] interfaces from legacy platform object method
...
Previously, [Global] interfaces were not excluded from the
`internal_own_property_keys()` call. This caused a crash when iterating
over the properties of the Window object.
2024-04-26 20:02:21 +02:00