Both Element's and ShadowRoot's setHTMLUnsafe, and Document's static
parseHTMLUnsafe methods are implemented.
(cherry picked from commit ce8d3d17c4f2fcca8fac0ff4a832c8f50a011fc7)
Dialog elements now correctly establish a close watcher when
shown modally.
This means modal dialogs now correctly close with an escape key press.
(cherry picked from commit d86a6e1bec858a35935ba6839c154ba2482d33e6)
No other browser allows opening the select element dropdown with the
select.click() function.
This change stops this happening in Ladybird.
(cherry picked from commit 564e546ff0bd78cc7ba770b53377457bf1ef88d6)
Adds the showPicker() function for select elements.
This doesn't do the check for "being rendered" which is in the spec.
(cherry picked from commit 5098ed6b1f881659dbdab10c74a0e17b362ce7a8)
This implements most of the CloseWatcher API from the html spec.
AbortSignal support is unimplemented.
Integration with dialogs and popovers is also unimplemented.
(cherry picked from commit b216046234560df531e1a32269e5dfa18f8f240c,
manually amended to replace a single `UIEvents::KeyCode::Key_Escape`
with `KeyCode::Key_Escape` in EventHandler.cpp since we don't have
the second commit of https://github.com/LadybirdBrowser/ladybird/pull/86)
Multiple APIs have moved from the DOM Parsing and Serialization spec to
HTML.
Updates spec URLs and comments.
Delete InnerHTML file:
- Make parse_fragment a member of Element, matching serialize_fragment
on Node.
- Move inner_html_setter inline into Element and ShadowRoot as per the
spec.
Add FIXME to Range.idl for Trusted Types createContextualFragment
(cherry picked from commit 9171c3518358cd2d146ffbd7582e4c1247a1daa7)
Previously, no event was fired on middle click. This change also allows
the UI to open a link in a new tab on middle click.
(cherry picked from commit 31d7fa244232c2a2239dbf6017ba9e3dd191ec2e)
This simulates click of the middle mouse button, which is necessary for
testing whether the `auxevent` fires correctly.
(cherry picked from commit 728fca1b1ffd8b472bc8524e5e8ec8443de011a5)
...and shadow tree with TextNode for "value" attribute is created.
This means InlineFormattingContext is used, and button's text now
respects CSS text-decoration properties and unicode-ranges.
(cherry picked from commit 8feaecd5c8d02a2fdb989a9a9671e008d1c3a7de)
Apple Clang doesn't like this, rather than waiting for their version of
random-clang-commit-to-call-a-release to catch up with llvm trunk, just
work around the issue.
Fixes#186.
(cherry picked from commit 8c9d3b30cf62016ffb03e425f1e7e3f2461262bf)
This fixes https://html5test.com/ as previously an exception was being
thrown after trying to access this attribute which would then result in
a popup about the test failing (and none of the test results being
shown).
(cherry picked from commit e0bbbc729b6aad04ceff5f67c3e2868b65970047,
manually amended with the output of `git clang-format master`)
Now that EasingStyleValue is a lot nicer to use, there isn't much reason
to keep TimingFunction around.
(cherry picked from commit 7950992fc21e2428a7f32954bbe893a2b2d58cf7,
manually amended with the output of `git clang-format master`)
The values aren't that complex, so it doesn't make much sense to have a
dedicated generator for them. Parsing them manually also allows us to
have much more control over the produced values, so as a result of this
change, EasingStyleValue becomes much more ergonomic.
(cherry picked from commit 667e313731f06fabf2a3f75893c3e8f15a4172be,
manually amended with the output of `git clang-format master`)
This fixes an issue where entering EXAMPLE.COM into the URL bar in the
browser would fail to load as expected.
(cherry picked from commit 1a4b042664f8fddbfa70f009c5873b1f8575bf0b)
Previously, part of the procedure we used to sanitize URLs entered via
the command line would check the host against the public suffix
database. This led to some valid, but not publicly accessible URLs
being treated as invalid.
(cherry picked from commit e9f34c7bd1e72da9a57a721d4ad501e8208cc986)
The Encoding specification maps ISO-8859-1 to windows-1252 and expects
the windows-1252 translation table to be used, which differs from
ISO-8859-1 for 0x80-0x9F.
Other contexts expect to get the actual ISO-8859-1 encoding, with 1-to-1
mapping to U+0000-U+00FF, when requesting it.
`decoder_for_exact_name` is introduced, which skips the mapping from
aliases to the encoding name done by `get_standardized_encoding`.
(cherry picked from commit 6b2c4599017f512279cb26c0d3c48aa5a9453007)
They are now blocked on pages which:
- Don't have an opaque origin (should be only user-initiated or about:)
- Aren't other file: pages
- Aren't other resource: pages
(cherry picked from commit 1f3285eb0410ff5c902e148932205d9e4b7fbd9b)
Implements enough of HTMLImageElement::decode for it to not break
websites and actually load an image :)
(cherry picked from commit 862fc91b2cf9bee9b7f180cdf930c6c99b5dd053)
Let's log which property we're trying to look up, since that's the most
interesting part!
(cherry picked from commit f7a83e57554c7a98cda165ea1fa18356a6ee54d9)
To make this straightforward, CSSKeyframesRule now uses a CSSRuleList
for internal storage.
(cherry picked from commit 7f2c833a39e150c7372299dcfe4d2d5590ae779f)
This readonly attribute returns the containing CSS rule, or null (in the
case of element inline style).
(cherry picked from commit a12d28fd3053638ce6f4215bed2d8d45cda86375)
The data segment offset should be checked _before_ checking if the
contents of the segment are non-existent.
(cherry picked from commit 78c56d80f90f913e4cbc14c865af308c6af9aeae)
Previously, navigating to or from `about:newtab` caused a crash due to
inadvertent null dereferences when checking whether a request or
response to a request should be blocked as mixed content.
(cherry picked from commit 572ebe00eacd5aaeecc17207c75c6bf2327a3897)
If the Document's navigable has been destroyed since we started this
timer, or it's no longer the active document of its navigable, we
shouldn't navigate to it.
(cherry picked from commit 7b67fa706fd2dabfda3c72a752ac70d8c95bb060;
amended commit message to say "LibWeb:" instead of "DOM:")