Commit graph

65968 commits

Author SHA1 Message Date
Pavel Shliak
6f81b80114 Everywhere: Include HashMap only where it's actually used 2024-12-09 12:31:16 +01:00
Pavel Shliak
97d99aa8d6 AK: Verify that HashMap is not empty in take_first
This makes the behavior uniform with:
- HashTable
- SinglyLinkedList
- Vector
2024-12-09 12:31:16 +01:00
Pavel Shliak
e08f6a69b2 LibWasm: Respect instance.types() bounds 2024-12-09 12:30:41 +01:00
Lucien Fiorini
3c2bbd45cf Tests: Mark test as passing in XMLSerializer-serializeToString.txt 2024-12-09 09:13:24 +00:00
Lucien Fiorini
ae8033b80f LibWeb: Rename abbreviated variable name 2024-12-09 09:13:24 +00:00
Lucien Fiorini
7feb8eb5bf Tests: Import WPT test for firstElementChild namespace in xhtml 2024-12-09 09:13:24 +00:00
Lucien Fiorini
0c24c9150a LibWeb: Parse the qualified name of XML dom elements correctly 2024-12-09 09:13:24 +00:00
sideshowbarker
0a2aa87107 LibWeb: Assign ARIA role “switch” to <input type=checkbox switch> 2024-12-09 09:47:36 +01:00
R-Goc
18132a0be1 LibJS: Remove compile flag for Windows 2024-12-08 17:37:26 -07:00
R-Goc
f380b4b95b AK: Port BumpAllocator.h to Windows
Done by forward declaring the required functions and defining the needed
constants. The defines shouldn't collide as they are from memoryapi.h.
This is done to avoid including windows.h.
2024-12-08 17:36:37 -07:00
R-Goc
c66eb5db11 LibCore: Add includes for S_ISDIR on Windows 2024-12-08 17:29:22 -07:00
stasoid
777dcdf6d0 LibCore: Port SharedCircularQueue to Windows 2024-12-08 17:25:40 -07:00
stasoid
85da489f39 LibThreading: Build on Windows 2024-12-08 17:19:42 -07:00
R-Goc
e2b6ab4a69 LibCrypto: DER.cpp use uz literals 2024-12-08 17:18:12 -07:00
R-Goc
3e69794c7d LibCrypto: Use size_t integer literal 2024-12-08 17:18:12 -07:00
Konstantin Konstantin
b03138cbff LibWeb: Support creation of shared memory in WebAssembly API
Add support for shared memory creation in WebAssembly memory API.
This API is needed for WPT tests that use shared array buffers.

Import related WPT tests.
2024-12-08 22:10:45 +01:00
Pavel Shliak
6ec06a01a2 LibCore: Do not include math.h in ArgsParser 2024-12-08 16:38:13 +00:00
sideshowbarker
aa2c296489 Docs: Add “Is [some particular site] usable in Ladybird” to FAQ 2024-12-08 15:30:03 +01:00
Pavel Shliak
116e7baead LibGfx: Remove aligned_within from Rect
The CenterRight and TopCenter alignment cases were
mistakenly identical due to a copy-paste error,
causing the function to behave unexpectedly.
Rather than attempting to fix it, remove aligned_within entirely.
2024-12-08 13:32:10 +00:00
Jelle Raaijmakers
4c6cb13f7f CI: Make stalebot actually close PRs after 30 days
Now stalebot has run to completion on notifying stale PRs, we can
enable its PR closing behavior.
2024-12-07 22:09:45 +01:00
Jelle Raaijmakers
681531d0e5 CI: Increase stalebot operations per run to 500
No need to limit ourselves to 30 API calls per run :^)
2024-12-07 22:07:15 +01:00
Jelle Raaijmakers
ea58dbd507 CI: Set actions permission for stalebot
The stale action has a weird interaction with the cache which requires
the `actions: write` permission. Without this, it is unable to overwrite
any existing cache key.
2024-12-07 21:58:53 +01:00
Jelle Raaijmakers
3da855e0cc CI: Fix Stalebot not progressing on PRs between runs 2024-12-07 21:43:06 +01:00
Jelle Raaijmakers
643eb1c2a6 CI: Configure stale bot for PRs
We want to remind both contributors and maintainers that PRs should be
up-to-date, reviewed and merged. Stale bot does a pretty good job of
notifying the right people :^)
2024-12-07 21:12:17 +01:00
devgianlu
c7a1287a4f LibCrypto: Remove ASN1 encoding/decoding from SECPxxxr1
Little refactoring to remove the last bits of ASN1 decoding/encoding
from within the `SECPxxxr1` class. It was a bit confusing for the
`SECPxxxr1` methods to handle ASN1 internally implicitly. Some explicit
methods are available to achieve the same functionality on the data
structures.
2024-12-07 19:08:40 +01:00
devgianlu
27fbcf70bf LibTLS: Parse SECP256r1 parameters separately 2024-12-07 19:08:40 +01:00
devgianlu
bce2893638 LibCrypto: Add utility functions to SECPxxxr1
This allows to move ASN1 logic from inside the `SECPxxxr1` curve
itself to the data structures. It makes more sense to have dedicated and
explicit methods to handle transformation between formats.
2024-12-07 19:08:40 +01:00
rmg-x
0cd4c26ae8 Tests/LibWeb: Fix type for delay_ms property in HTTP echo server
This was mistakenly changed from int -> str in a previous commit:
08b8c88ac3
2024-12-07 15:49:15 +00:00
Felipe Muñoz Mazur
e27c59047a LibWeb: Handle abort signal in CloseWatcher 2024-12-07 12:06:53 +00:00
Glenn Skrzypczak
156f9fff32 LibWeb: Support the X-Frame-Options header
Navigation responses are now checked for adherence to the
`X-Frame-Options` header and an error is shown accordingly.
2024-12-07 08:38:02 +00:00
Glenn Skrzypczak
88884c370c LibWeb: Act as if parsing stopped when generating an error document
The user agent now acts as if it has stopped parsing when creating a
document for inline content to display an error.
2024-12-07 08:38:02 +00:00
Andreas Kling
6d7bb074fc LibWeb: Don't serialize resolved CSS color values as named colors
With all the plumbing in place, we can handle this quirk at the
serialization layer.

This allows us to remove the pass where StyleComputer would loop over
all computed values and replace any color values with new values
stripped of their original name strings.
2024-12-07 08:31:03 +00:00
Andreas Kling
b3c4b4fd97 LibWeb: Serialize resolved CSS values in dedicated serialization mode
This doesn't actually do anything differently yet, but it will in the
very next commit.
2024-12-07 08:31:03 +00:00
Andreas Kling
e85c3c97fb LibWeb: Add mode flag to CSSStyleValue::to_string()
This will be used to differentiate between serialization for resolved
style (i.e window.getComputedStyle()) and serialization for all other
purposes.
2024-12-07 08:31:03 +00:00
sideshowbarker
c1b29e7cc4 Tests: Import the WPT accname/basic.html test
This change imports the https://wpt.live/accname/basic.html — which we
had overlooked earlier when importing all the other WPT accname tests.
(Note that this one of the six upstream WPT tests that directly call
test_driver.get_computed_label(element) — and so that we’d otherwise
need to patch our copy of, if we weren’t patching it in testdriver.js).
2024-12-07 08:25:26 +00:00
sideshowbarker
e10db3aaf0 Tests: Move window.internals.getComputedLabel into testdriver.js file
This change takes the change we made in 120bc52f23 to patch the imported
WPT aria-utils.js file to use our window.internals.getComputedLabel(el)
function, and moves that patching into the imported WPT testdriver.js
file — in the same way we did in c5966bbdcb.

That centralizes the patching, and avoids the need to patch multiple
other WPT tests we’re likely to import eventually. There are actually
six different WPT test files upstream which we haven’t imported yet that
call window.test_driver_internal.get_computed_label(el) directly — and
that, without this change, we’d otherwise end up needing to patch.
2024-12-07 08:25:26 +00:00
Aliaksandr Kalenik
46b95182a0 CodeGenerators: Delete unnecessary overrides in WebGL generator
getAttribLocation() and getAttribLocation() could be generated
automatically so we don't need to have overriden function bodies for
them.
2024-12-07 01:36:08 +01:00
Aliaksandr Kalenik
f074df171b CodeGenerators: Use snake case for function parameter names in WebGL 2024-12-07 01:36:08 +01:00
Aliaksandr Kalenik
86c230cd8e LibWeb/WebGL: Implement vertex array calls for WebGL2 2024-12-07 00:05:36 +01:00
Aliaksandr Kalenik
eec4b71351 LibWeb/WebGL: Remove FIXME from supported calls in WebGL2
These calls were inherited from WebGL 1 and our implementation generator
already supports them.
2024-12-07 00:05:36 +01:00
Pavel Shliak
2159a4f14e Tests: Remove SerenityOS Check
This check can be safely removed, as we no longer support
building Ladybird for SerenityOS ;^)
2024-12-06 14:21:56 -07:00
Lucien Fiorini
6260e18de6 Tests: Add fillstyle gradients screenshot test for canvas 2024-12-06 20:21:57 +01:00
Lucien Fiorini
beb621665f LibGfx: Add missing return and fix center of radial gradients 2024-12-06 20:21:57 +01:00
sideshowbarker
68894306e2 LibWeb: Compute default ARIA roles context-sensitively where required
This change implements spec-conformant computation of default ARIA roles
for elements whose expected default role depends on the element’s
context — specifically, either on the element’s ancestry, or on whether
the element has an accessible name, or both. This affects the “aside”,
“footer”, “header”, and “section” elements.

Otherwise, without this change, “aside”, “footer”, “header”, and
“section” elements may unexpectedly end up with the wrong default roles.
2024-12-06 18:31:45 +00:00
sideshowbarker
7a4a9cc7bc LibWeb: Extract ARIA role-attribute checking out from role_or_default()
This change separates the steps for checking the string value of the
ARIA “role” attribute out from the element.role_or_default() function
into a separate function — in order to expose a way to just check if the
ARIA “role” attribute actually has a value, without also then computing
a default role value if no “role” attribute value was found.

Otherwise, without this change, the only available function for
retrieving ARIA role values is the element.role_or_default() function —
which always does the additional step of computing (and returning) a
default role value if no “role” attribute is found.
2024-12-06 18:31:45 +00:00
sideshowbarker
c5966bbdcb LibWeb: Add window.internals.getComputedRole(element)
This change adds a window.internals.getComputedLabel(element) function,
for use in testing ARIA-related behavior. It also patches the imported
WPT testdriver.js script’s test_driver.get_computed_role(element)
function to call our window.internals.getComputedRole(element) function.
2024-12-06 18:31:45 +00:00
Tim Ledbetter
d946d94e2d LibWeb: Improve relList feature detection support
`DOMTokenList.supports()` is now correct for all possible `rel`
attribute values for `link`, `a`, `area` and `form` elements.
2024-12-06 18:09:53 +00:00
Timothy Flynn
234f218803 LibJS: Ensure GetDateTimeFormat returns nonnull for the best format
This is an editorial change in the Temporal proposal. See:
https://github.com/tc39/proposal-temporal/commit/8a52801
2024-12-06 11:13:10 -05:00
Timothy Flynn
7104d724ee LibJS: Simplify condition in GetDateTimeFormat
This is an editorial change in the Temporal proposal. See:
https://github.com/tc39/proposal-temporal/commit/23c74b6
2024-12-06 11:13:10 -05:00
Timothy Flynn
6b8acc0af5 LibJS: Ensure DifferenceISODateTime receives valid ISO date-times
This is an editorial change in the Temporal proposal. See:
https://github.com/tc39/proposal-temporal/commit/b5da334
2024-12-06 11:13:10 -05:00