Commit graph

65406 commits

Author SHA1 Message Date
Timothy Flynn
82b540e501 LibJS: Implement Temporal.PlainDate.prototype.toPlainDateTime 2024-11-24 11:43:59 +01:00
Timothy Flynn
d22ea4db4c LibJS: Implement Temporal.PlainDateTime.prototype.valueOf 2024-11-24 11:43:59 +01:00
Timothy Flynn
649328fed2 LibJS: Implement Temporal.PlainDateTime.prototype.toPlainDate/Time 2024-11-24 11:43:59 +01:00
Timothy Flynn
990daaf63a LibJS: Implement Temporal.PlainDateTime.prototype.with* methods
Includes with, withCalendar, and withPlainTime.
2024-11-24 11:43:59 +01:00
Timothy Flynn
e3082b5bed LibJS: Implement Temporal.PlainDateTime.prototype.round 2024-11-24 11:43:59 +01:00
Timothy Flynn
906d951104 LibJS: Implement Temporal.PlainDateTime.prototype.since/until 2024-11-24 11:43:59 +01:00
Timothy Flynn
85ffacacde LibJS: Implement Temporal.PlainDateTime.prototype.add/subtract/equals 2024-11-24 11:43:59 +01:00
Timothy Flynn
d314fcce7a LibJS: Implement stringification Temporal.PlainDateTime prototypes 2024-11-24 11:43:59 +01:00
Timothy Flynn
1a80161011 LibJS: Fix Temporal.PlainMonthDay.prototype.calendarId references
Small mistake porting old Temporal tests to the new spec. This getter
was `.calendar` in the old Temporal spec.
2024-11-24 11:43:59 +01:00
Timothy Flynn
029b6ad1a8 LibJS: Implement the Temporal.PlainDateTime constructor
And the simple Temporal.PlainDateTime.prototype getters, so that the
constructed Temporal.PlainDateTime may actually be validated.
2024-11-24 11:43:59 +01:00
Kenneth Myhra
a61cdeba24 LibWeb: Switch to using TemporaryExecutionContext
TemporaryExecutionContext has support to prepare for callbacks so we can
use it here now instead of setting this up manually.
2024-11-24 11:12:08 +01:00
Kenneth Myhra
968c38e54f LibWeb: Implement FetchController::abort() 2024-11-24 11:11:44 +01:00
Kenneth Myhra
4c5019f89c LibWeb: Add serialization and deserilization steps to DOMException
This makes DOMException a Serializable object.
2024-11-24 11:11:44 +01:00
Kenneth Myhra
490c05ef29 LibWeb: Make create_serialized_type() in-fallible
The ::create() functions have all been converted into in-fallible
versions so there is no longer any point in create_serialized_type()
being fallible.
2024-11-24 11:11:44 +01:00
Kenneth Myhra
53394230ca LibWeb: Reorganize definitions and includes to avoid circular references
This is necessary to avoid a circular reference when including
Serializable.h in DOMException.h.

This moves the definition of SerializationRecord, SerializationMemory,
and DeserializationMemory into LibWeb/Forward.h so that Serializable.h
only needs to include LibWeb/Forward.h.
2024-11-24 11:11:44 +01:00
Kenneth Myhra
4569b997a6 LibWeb: Add missing spec links for pipe_through() and pipe_to() 2024-11-24 11:11:44 +01:00
Psychpsyo
1d44df74f7 LibWeb: Stop zero-area children from causing scrollable overflow 2024-11-24 11:10:47 +01:00
Marc Jessome
efcaf991e6 LibRegex: Ensure nested capture groups have non-conflicting names
Take record of the named capture group prior to parsing the group's
body. This requires removal of the recorded minimum length of the named
capture group directly, and now needs to be looked up via the group
minimu lengths table.
2024-11-24 10:26:09 +01:00
Timothy Flynn
e37c9eaeff LibJS: Implement Temporal.PlainTime.prototype.valueOf
Some checks are pending
CI / Lagom (false, FUZZ, ubuntu-24.04, Linux, Clang) (push) Waiting to run
CI / Lagom (false, NO_FUZZ, macos-15, macOS, Clang) (push) Waiting to run
CI / Lagom (false, NO_FUZZ, ubuntu-24.04, Linux, GNU) (push) Waiting to run
CI / Lagom (true, NO_FUZZ, ubuntu-24.04, Linux, Clang) (push) Waiting to run
Package the js repl as a binary artifact / build-and-package (macos-14, macOS, macOS-universal2) (push) Waiting to run
Package the js repl as a binary artifact / build-and-package (ubuntu-24.04, Linux, Linux-x86_64) (push) Waiting to run
Run test262 and test-wasm / run_and_update_results (push) Waiting to run
Lint Code / lint (push) Waiting to run
Push notes / build (push) Waiting to run
2024-11-23 19:35:36 -05:00
Timothy Flynn
d639e9429f LibJS: Implement Temporal.PlainTime.prototype.round/equals 2024-11-23 19:35:36 -05:00
Timothy Flynn
a0df194528 LibJS: Implement Temporal.PlainTime.prototype.with 2024-11-23 19:35:36 -05:00
Timothy Flynn
85eef698b9 LibJS: Implement Temporal.PlainTime.prototype.since/until 2024-11-23 19:35:36 -05:00
Timothy Flynn
1c22011ed6 LibJS: Implement Temporal.PlainTime.prototype.add/subtract 2024-11-23 19:35:36 -05:00
Timothy Flynn
ab3c825fa8 LibJS: Implement stringification Temporal.PlainTime prototypes 2024-11-23 19:35:36 -05:00
Timothy Flynn
66365fef57 LibJS: Implement the Temporal.PlainTime constructor
And the simple Temporal.PlainTime.prototype getters, so that the
constructed Temporal.PlainTime may actually be validated.
2024-11-23 19:35:36 -05:00
Timothy Flynn
971f794127 LibJS: Add and use a BigInt-aware override of BalanceTime
With Temporal.PlainTime, we will need precise results for extremely
large values.
2024-11-23 19:35:36 -05:00
Timothy Flynn
7f3de3be9c LibJS: Capture sub-second nanoseconds as a u64 in FormatTimeString
This is not a plain nanosecond value (which has a range of [0, 999]).
Rather, it is all of the sub-second components added together.
2024-11-23 19:35:36 -05:00
Timothy Flynn
0b59971ef9 LibJS: Reject ambiguous annotated time strings
This missing rejection will be caught by an upcoming Temporal.PlainTime
test.
2024-11-23 19:35:36 -05:00
Timothy Flynn
c83a3db542 LibJS: Handle Temporal.PlainDate in dynamic calendar operations 2024-11-23 19:35:36 -05:00
Andrew Kaster
5be4825504 LibWeb: Report exceptions from custom element upgrades to global object
Some checks are pending
CI / Lagom (false, FUZZ, ubuntu-24.04, Linux, Clang) (push) Waiting to run
CI / Lagom (false, NO_FUZZ, macos-15, macOS, Clang) (push) Waiting to run
CI / Lagom (false, NO_FUZZ, ubuntu-24.04, Linux, GNU) (push) Waiting to run
CI / Lagom (true, NO_FUZZ, ubuntu-24.04, Linux, Clang) (push) Waiting to run
Package the js repl as a binary artifact / build-and-package (macos-14, macOS, macOS-universal2) (push) Waiting to run
Package the js repl as a binary artifact / build-and-package (ubuntu-24.04, Linux, Linux-x86_64) (push) Waiting to run
Run test262 and test-wasm / run_and_update_results (push) Waiting to run
Lint Code / lint (push) Waiting to run
Push notes / build (push) Waiting to run
2024-11-24 00:15:59 +00:00
Milo van der Tier
54b0476d70 LibWeb: Handle second condition in NamedNodeMap's property names
This removes the FIXME and fixes a WPT subtest.
2024-11-23 23:21:50 +00:00
Psychpsyo
8aaa9324b2 LibWeb: Unapply CSS filters after applying them to SVG 2024-11-23 21:39:50 +00:00
Tim Ledbetter
f378f41526 LibWeb: Use correct comparison logic in NamedNodeMap::get_attribute()
Previously, we were doing a case insensitive comparison, which could
return the wrong result if the attribute name was uppercase.
2024-11-23 21:19:28 +00:00
Jonne Ransijn
a0fb092d94 LibWeb: Transform PaintableBox::hit_test positions
Elements with transforms were tested on their pre-transformed
positions, causing incorrect hits.

Copy the position transformation done in `StackingContext::hit_test`
to ensure that hit tests are done on the _actual_ position.
2024-11-23 22:06:32 +01:00
Jonne Ransijn
d2ca522540 LibWeb: Use is_viewport helper
This method exists precicely to simplify the check being done here,
so lets use it!
2024-11-23 22:06:32 +01:00
Pavel Shliak
6ad93d2b21 UI/Qt: Use Qt-reported dark theme
For Qt >= 6.5, the system theme can be determined reliably, so no
guesswork is needed. A fallback remains for Qt < 6.5, but it is
hacky and less reliable.
2024-11-23 19:53:43 +00:00
Saksham Mittal
ecdb53cca6 LibWeb: Deduplicate opacity code in ApplyFilters
The opacity is still being set separately by using
ApplyOpacity for both CSS and SVG
2024-11-23 20:20:12 +01:00
Saksham Mittal
ab1cf8f89b LibWeb: Use ApplyFilters command for SVGs 2024-11-23 20:20:12 +01:00
Saksham Mittal
8562b0e33b LibWeb: Migrate CSS filter application to new ApplyFilters command
This helps reuse this code in other areas, such as for filters for SVGs
2024-11-23 20:20:12 +01:00
Psychpsyo
628e1d9853 LibWeb: Fix incorrect spec link for the @supports rule 2024-11-23 18:44:38 +00:00
Pavel Shliak
442629064b LibCore: Remove deprecated ElapsedTimer::elapsed()
This follows FIXME in the code.
2024-11-23 19:20:03 +01:00
Andreas Kling
69367194a6 LibWeb: Make HTML tokenizer stop at insertion point after state switch
If we reach the insertion point at the same time as we switch to another
tokenizer state, we have to bail immediately without proceeding with the
next code point. Otherwise we'd fetch the next token, get an EOF marker,
and then proceed as if we're at the end of the input stream, even though
more data may be coming (with more calls to document.write()..)
2024-11-23 19:19:31 +01:00
Andreas Kling
1d554f97de LibWeb: Reset the "stop parsing" flag when entering HTML parser
Otherwise we'll always bail after processing one token, which is not
what we want.
2024-11-23 19:19:31 +01:00
Andreas Kling
7309f2a6f9 LibWeb: Add spec comments to HTML parser's "initial" insertion mode 2024-11-23 19:19:31 +01:00
Andreas Kling
701ed8470d Tests: Import a bunch of WPT tests related to dynamic markup insertion 2024-11-23 19:19:31 +01:00
Shannon Booth
e565e3c557 LibWeb: Implement BroadcastChannel.postMessage
Some checks are pending
CI / Lagom (false, FUZZ, ubuntu-24.04, Linux, Clang) (push) Waiting to run
CI / Lagom (false, NO_FUZZ, macos-15, macOS, Clang) (push) Waiting to run
CI / Lagom (false, NO_FUZZ, ubuntu-24.04, Linux, GNU) (push) Waiting to run
CI / Lagom (true, NO_FUZZ, ubuntu-24.04, Linux, Clang) (push) Waiting to run
Package the js repl as a binary artifact / build-and-package (macos-14, macOS, macOS-universal2) (push) Waiting to run
Package the js repl as a binary artifact / build-and-package (ubuntu-24.04, Linux, Linux-x86_64) (push) Waiting to run
Run test262 and test-wasm / run_and_update_results (push) Waiting to run
Lint Code / lint (push) Waiting to run
Push notes / build (push) Waiting to run
The repository being in static storage is a bit of a hodgepodge, but in
line with how our current storage partitioning is done. We should
eventually move this, along with other across browsing context APIs to a
proper location at a later stage. But for now, this makes progress on
the meat of the BroadcastChannel API.
2024-11-23 16:43:55 +01:00
Shannon Booth
8f6fe1de83 LibURL+LibWeb: Make URL serialization return a String
This can only ever fail from OOM, and will never by string containing
random byte sequences.
2024-11-23 16:43:55 +01:00
Shannon Booth
9724c67be2 LibWeb: Default initialize StructuredDeserialize memory argument
This is optional in the spec, so let's make it actually optional at the
call site.
2024-11-23 16:43:55 +01:00
Shannon Booth
617b8eed75 LibWeb: Const qualify many functions in EnvironmentSettingsObject
Which also allows us to remove a const_cast :^)
2024-11-23 16:43:55 +01:00
Shannon Booth
473bebc9a8 LibWeb: Tidy up return types of BroadcastChannel
Use GC::Ptr over a raw pointer and make the name() function const
qualfied returning a reference instead of a copy.
2024-11-23 16:43:55 +01:00