aboutsummaryrefslogtreecommitdiffstats
path: root/tests/wpt/meta
Commit message (Collapse)AuthorAgeFilesLines
* Set correct policy-container for worker construction (#36603)Tim van der Lippe3 days21-109/+29
| | | | | | | This makes sure that when workers are created, their global scope has the correct policy-container set so that we can do CSP-checks. Signed-off-by: Tim van der Lippe <tvanderlippe@gmail.com>
* script: `LoadBlocker`'s drop impl shouldn't run after termination. (#36508)Mukilan Thiyagarajan3 days6-0/+18
| | | | | | | | | | | | | The logic in LoadBlocker::terminate was modified in #34122 to `clone` the LoadBlocker's inner `load` member instead of `take`ing it. However, this member serves as a flag so that `LoadBlocker`'s Drop impl can avoid calling `doc.finish_load` on already terminated loads. The change results in unnecessary 'unknown completed load' warnings when Servo is run with logging enabled. Signed-off-by: Mukilan Thiyagarajan <mukilan@igalia.com> Signed-off-by: Mukilan Thiyagarajan <mukilan@igalia.com>
* Implement trusted types url setter (#36596)Tim van der Lippe3 days16-66/+0
| | | | | | | | | | | | | | | | | | | | | | | | We now check the sink of script.src for trusted types. This is the first attribute that we check, other sinks will be implemented in follow-up changes. The algorithms currently hardcode various parts. That's because I need to refactor a couple of algorithms already present in TrustedTypePolicy. They use callbacks at the moment, which made sense for their initial use. However, for these new algorithms they don't work. Therefore, I will align them with the specification by taking in an enum. However, since that's a bigger refactoring, I left that out of this PR (which is already quite big). The other trusted types support (createScript and createHTML) will also be implemented separately. Part of #36258 --------- Signed-off-by: Tim van der Lippe <tvanderlippe@gmail.com> Signed-off-by: Tim van der Lippe <TimvdLippe@users.noreply.github.com> Co-authored-by: Josh Matthews <josh@joshmatthews.net>
* Fix: Slot Assignment mode according to the spec (#36620)saku4 days3-12/+0
| | | | | | | | | | | | | | | | | | | | When parsing a Declarative Shadow DOM, the slot assignment isn't being triggered as mentioned in the [spec](https://html.spec.whatwg.org/multipage/parsing.html#parsing-main-inhead:~:text=Attach%20a%20shadow%20root%20with%20declarative%20shadow%20host%20element%2C%20mode%2C%20clonable%2C%20serializable%2C%20delegatesFocus%2C%20%22named%22%2C%20and%20registry.). When creating a shadow root declaratively, SlotAssignment mode was set to "manual" instead of "named". Tests: The followings should get fully passed with this change, so `.ini`s are removed. - `declarative-shadow-dom-basic.html` - `declarative-shadow-dom-write-to-iframe.html` - `declarative-shadow-dom-repeats.html` Fixes: #36100 --------- Signed-off-by: saku <saku@email.sakupi01.com>
* Fix missing settings in script module requests (#36606)elomscansio4 days6-3/+63
| | | | | | | | | | | | | | | | | | | | | | | | | | | | This PR resolves [#36592](https://github.com/servo/servo/issues/36592) by updating the `RequestBuilder` used in `script_module.rs` to include: - `insecure_requests_policy` - `has_trustworthy_ancestor_origin` - `policy_container` These fields are critical for enforcing proper fetch behavior under modern web security models, and were previously omitted from module script requests. This change ensures that scripts loaded via `<script type="module">` or dynamic `import()` correctly reflect the calling document’s security environment. --- <!-- Thank you for contributing to Servo! Please replace each `[ ]` by `[X]` when the step is complete, and replace `___` with appropriate data: --> - [X] `./mach build -d` does not report any errors - [X] `./mach test-tidy` does not report any errors - [X] These changes fix #36592 <!-- Either: --> - [X] There are tests for these changes Signed-off-by: Emmanuel Elom <elomemmanuel007@gmail.com>
* Sync WPT with upstream (20-04-2025) (#36618)Servo WPT Sync5 days109-441/+2909
| | | | | | Automated downstream sync of changes from upstream as of 20-04-2025 [no-wpt-sync] Signed-off-by: WPT Sync Bot <ghbot+wpt-sync@servo.org>
* content/dom: set navigator.onLine attribute to `true` (#36560)Siddhant N Trivedi6 days4-22/+0
| | | | | | | | | | | | | | | | | | | | Sets the navigator.onLine attribute to true. Testing: Ran `./mach run https://pinterest.com --enable-experimental-web-platform-features`. This doesn't show the "Hmm..you're not connected to the internet" text anymore. <img width="1027" alt="Screenshot 2025-04-16 at 11 31 02 AM" src="https://github.com/user-attachments/assets/3745077b-dc51-42ce-88a0-38d5f157fc0c" /> part of: #36554 --------- Signed-off-by: Siddhant N. Trivedi <sidntrivedi012@gmail.com> Signed-off-by: Siddhant N Trivedi <sidntrivedi012@gmail.com> Co-authored-by: Josh Matthews <josh@joshmatthews.net>
* Streams: make writable streams transferrable (#36588)Gregory Terzian6 days3-29/+1
| | | | | | Making writable streams transferrable, part of https://github.com/servo/servo/issues/34676 Signed-off-by: gterzian <2792687+gterzian@users.noreply.github.com>
* Check CSP for inline event handlers (#36510)Tim van der Lippe7 days58-553/+14
| | | | | | | | | | | | This also ensures that document now reports all violations and we set the correct directive. With these changes, all `script-src-attr-elem` WPT tests pass. Part of #36437 Requires servo/rust-content-security-policy#3 to land first Signed-off-by: Tim van der Lippe <tvanderlippe@gmail.com>
* Fix `/css/css-flexbox/gap-007-*` WPT tests (#36585)Oriol Brufau7 days1-8/+8
| | | | | | | | | | | | These tests were locally failing for me, both on Servo and Gecko, because these browsers choose a different default font than Blink, making the flex items a bit bigger, and thus only fitting 2 items on the first flex line, instead of 3 items. Manually setting the `line-height` provides consistent results. Testing: This doesn't affect CI, but fixes the local problem for me. Signed-off-by: Oriol Brufau <obrufau@igalia.com>
* layout: Always floor the max-content size by the min-content size (#36571)Oriol Brufau7 days1-2/+0
| | | | | | | | | | This is a follow-up to #36518, which only addressed inline formatting contexts. However, flex formatting contexts had the same problem, so it seems safer to address it in general. Testing: this makes a WPT test pass Fixes: #36570 Signed-off-by: Oriol Brufau <obrufau@igalia.com>
* fix writablestream assertion crash when getting chunk size following spec ↵Taym Haddadi8 days1-6/+0
| | | | | | | | change (#36566) One-line change to align with the new spec and avoid a crash. fix #36565 Signed-off-by: Taym Haddadi <haddadi.taym@gmail.com>
* Fix crash when setting custom property on Location (#36494)Josh Matthews8 days3-9/+0
| | | | | | | | | | | | | | | | | The JS engine uses types like `Handle<Maybe<PropertyDescriptor>>` in various places and our automated bindings are not able to handle the Maybe type. We have hand-written bindings that use outparams to indicate a PropertyDescriptor value is actually the Nothing type, but that data was getting lost when we passed the property descriptor to SetPropertyIgnoringNamedGetter, which assumed that the property descriptor was always valid. Depends on https://github.com/servo/mozjs/pull/579. Testing: Manual testing on testcase from https://github.com/servo/servo/issues/34709, and new crashtest added. Fixes: #34709 Signed-off-by: Josh Matthews <josh@joshmatthews.net>
* media element: support seekable attribute (#36541)TIN TUN AUNG8 days2-19/+0
| | | | | | | | | | | | | | | support seekable attribute in `htmlmediaelement`, modify `seek` algorithm to use `seekable` attribute. related [specs](https://html.spec.whatwg.org/multipage/media.html#dom-media-seekable) Testing: Run WPT Test Fixes: https://github.com/servo/servo/issues/22297 Will wait for https://github.com/servo/media/pull/435 before turning this to ready for review. cc @jdm @xiaochengh Signed-off-by: rayguo17 <rayguo17@gmail.com>
* Switch to data_url::mime for document content type (#36522)webbeef9 days3-129/+0
| | | | | | | | The data_url Mime parser has a more conformant behavior in most cases, including dealing with charsets. Testing: wpt expectations with new passes are updated. Signed-off-by: webbeef <me@webbeef.org>
* canvas: Add "EnforceRange" attribute to CanvasImageData interface (#36546)Andrei Volykhin9 days12-45/+0
| | | | | | | | | | | | | Add missing "EnforceRange" attribute to interface methods https://html.spec.whatwg.org/multipage/canvas.html#canvasimagedata -- - [x] ./mach build -d does not report any errors - [x] ./mach test-tidy does not report any errors - [x] There are tests for these changes tests/wpt/tests/html/canvas/element/pixel-manipulation/2d.imageData* tests/wpt/tests/html/canvas/offscreen/pixel-manipulation/2d.imageData* Signed-off-by: Andrei Volykhin <andrei.volykhin@gmail.com>
* script: Implement CSSStyleSheet constructor (#36521)Oriol Brufau9 days5-28/+0
| | | | | | | | https://drafts.csswg.org/cssom/#dom-cssstylesheet-cssstylesheet Testing: covered by WPT This is part of #36162 Signed-off-by: Oriol Brufau <obrufau@igalia.com>
* Make DOMException serializable (#36535)Kingsley Yung9 days2-9/+0
| | | | | | | | | | | Follow the implementation of making DOMPoint and DOMPointReadOnly serializable in PR #35989 Testing: Passed a test previously expected to fail. Fixes: #36463 --------- Signed-off-by: Kingsley Yung <kingsley@kkoyung.dev>
* Transfer ReadableStream (#36181)Gregory Terzian9 days12-18/+97
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | <!-- Please describe your changes on the following line: --> Add transfer support to ReadableStream. Part of https://github.com/servo/servo/issues/34676 --- <!-- Thank you for contributing to Servo! Please replace each `[ ]` by `[X]` when the step is complete, and replace `___` with appropriate data: --> - [ ] `./mach build -d` does not report any errors - [ ] `./mach test-tidy` does not report any errors - [ ] These changes fix #___ (GitHub issue number if applicable) <!-- Either: --> - [ ] There are tests for these changes OR - [ ] These changes do not require tests because ___ <!-- Also, please make sure that "Allow edits from maintainers" checkbox is checked, so that we can help you if you get stuck somewhere along the way.--> <!-- Pull requests that do not address these steps are welcome, but they will require additional verification as part of the review process. --> --------- Signed-off-by: gterzian <2792687+gterzian@users.noreply.github.com>
* Run all tests with --enable-experimental-web-platform-features (#36335)Oriol Brufau10 days2-22/+1
| | | | | Fixes: #36315 Signed-off-by: Oriol Brufau <obrufau@igalia.com>
* Enable all experimental web platform features on all testsuites (#36519)Oriol Brufau10 days12-4063/+11
| | | | | | | | | | | | This affects the following testsuites: - tests/wpt/tests/ - tests/wpt/mozilla/tests/ - tests/wpt/webgl/tests/ - tests/wpt/webgpu/tests/ Testing: Several tests improve This is part of #36315 Signed-off-by: Oriol Brufau <obrufau@igalia.com>
* layout: Floor the max-content size by the min-content size (#36518)Oriol Brufau10 days1-0/+20
| | | | | | | | | | | | | | | It's typically a given that the min-content size can't exceed the max-content size. However, it was possible to break that assumption when an inline formatting context had contents with a negative outer size (due to margins). This could lead to assert failures. This patch avoids the problem by flooring the max-content size to not be smaller than the min-content size. Note there is no interoperability: https://github.com/w3c/csswg-drafts/issues/12076 Testing: adding new reftest and crashtest Fixes: #36481 Signed-off-by: Oriol Brufau <obrufau@igalia.com>
* Implement CSP check for Trusted Types (#36363)Tim van der Lippe10 days9-57/+2
| | | | | | | | | | | | | | The algorithm [1] is implemented in the content-security-policy package. Requires https://github.com/rust-ammonia/rust-content-security-policy/pull/56 This is part of #36258 [1]: https://w3c.github.io/trusted-types/dist/spec/#abstract-opdef-should-trusted-type-policy-creation-be-blocked-by-content-security-policy Signed-off-by: Tim van der Lippe <tvanderlippe@gmail.com> Co-authored-by: Josh Matthews <josh@joshmatthews.net>
* async clipboard: implement `writeText` (#36498)Gae2410 days1-39/+0
| | | | | | | | | | Implement enough of the Clipboard API to have a working `writeText`. Testing: Unfortunately many clipboard-apis tests require testdriver, so only idlharness ones will pass now. --------- Signed-off-by: Gae24 <96017547+Gae24@users.noreply.github.com>
* layout: Let getComputedStyle resolve auto min size as 0px when needed (#36430)Oriol Brufau10 days6-46/+0
| | | | | | | | | The initial value of `min-width` and `min-height` was 0px in CSS2. However, CSS3 changed it to `auto`, so for backwards compatibility, `getComputedStyle` needs to resolve it to 0px in a bunch of cases. Testing: covered by WPT Signed-off-by: Oriol Brufau <obrufau@igalia.com>
* Update FetchTaskTarget to propagate CSP violations. (#36409)Tim van der Lippe11 days115-569/+243
| | | | | | | | | | | | | | | | | | It also updates the FetchResponseListener to process CSP violations to ensure that iframe elements (amongst others) properly generate the CSP events. These iframe elements are used in the Trusted Types tests themselves and weren't propagating the violations before. However, the tests themselves are still not passing since they also use Websockets, which currently aren't using the fetch machinery itself. That is fixed as part of [1]. [1]: https://github.com/servo/servo/issues/35028 --------- Signed-off-by: Tim van der Lippe <tvanderlippe@gmail.com> Signed-off-by: Josh Matthews <josh@joshmatthews.net> Co-authored-by: Josh Matthews <josh@joshmatthews.net>
* Implement "Create a Trusted Type" algorithm (#36454)Tim van der Lippe11 days23-229/+1
| | | | | | | | | | | | | | | | | | | | | | | | | This algorithm is quite straightforward written in the specification, but leads to some type awkwardness in Rust. Most notably, the callbacks have different types and cannot be unified easily. They also return different string types. Similarly, the returning objects are all unique types and don't have a common denominator. Therefore, rather than implementing it in 1-to-1 fashion with the specification text, it instead uses callbacks to instruct the type system of what to call when. This is further complicated by the fact that the callback can exist or not, as well as return a value or not. This requires multiple unwrangling, combined with the fact that the algorithm should throw or not. All in all, the number of lines is relatively low compared to the specification algorithm and the Rust compiler does a lot of heavy lifting figuring out which type is what. Part of https://github.com/servo/servo/issues/36258 Signed-off-by: Tim van der Lippe <tvanderlippe@gmail.com> Co-authored-by: Josh Matthews <josh@joshmatthews.net>
* Sync WPT with upstream (13-04-2025) (#36488)Servo WPT Sync11 days80-929/+1489
| | | | | | Automated downstream sync of changes from upstream as of 13-04-2025 [no-wpt-sync] Signed-off-by: WPT Sync Bot <ghbot+wpt-sync@servo.org>
* Update ProgressEvent to use doubles (#36487)Sebastian C12 days1-9/+0
| | | | | | | See: https://github.com/whatwg/xhr/pull/394 Testing: WPT tests exist for this Signed-off-by: Sebastian C <sebsebmc@gmail.com>
* layout: Enforce min-content min main size of flex-level tables (#36469)Oriol Brufau12 days3-6/+0
| | | | | | | | | | | Additionally to the minimum specified in min-width or min-height, tables also enforce a `min-content` minimum. This was handled in `Sizes::resolve()`, but flex items don't use that. So this patch moves the logic into `Size::resolve_for_min()`. Testing: Covered by WPT Signed-off-by: Oriol Brufau <obrufau@igalia.com>
* Enable dom_svg_enabled on all tests (#36475)Oriol Brufau13 days16-97/+1942
| | | | | | | | | | | This feature is part of --enable-experimental-web-platform-features, so it should be enabled on all tests. This causes some new failures, but mostly it's because the tests were timing out instead of running the failing subtests. This is part of #36315 Signed-off-by: Oriol Brufau <obrufau@igalia.com>
* fix: File to FormData not correctly handling name and lastModified (#36458)Sebastian C13 days2-16/+0
| | | | | | | | | | | Set File's lastModified when reconstructing from Blob for FormData Remove special character replacement in fileName (spec removed this step) Testing: WPT tests exist Fixes: #22744 (if I undertand the issue correctly the filename issue was already fixed and now this fixes the lastModified part) Signed-off-by: Sebastian C <sebsebmc@gmail.com>
* Manually concatenate ACRH headers to not include a space (#36455)Sebastian C13 days2-17/+0
| | | | | | | | | | | | headers library will join values with `, ` (comma space) but Access-Control-Request-Headers specifies that it does not use the normal combining algorithm and values should be joined with `,` (comma). Testing: WPT tests exist Fixes: temporary fix for #36451 until hyperium/headers#207 is fixed --------- Signed-off-by: Sebastian C <sebsebmc@gmail.com>
* Implement attribute and property lookup for Trusted Types (#36422)Tim van der Lippe13 days6-181/+12
| | | | | | | | These algorithms are used to check whether an attribute/property can accept a Trusted Type. Part of #36258 Signed-off-by: Tim van der Lippe <tvanderlippe@gmail.com>
* Handle HTTP Refresh header (#36393)Sebastian C13 days8-248/+20
| | | | | | | | | | | | | | | Move parsing of Refresh values to Document. Send Refresh header to Document and have meta tags reuse the logic. I transplanted the existing Regex and made some updates so that it passed all the existing parser tests. I added the comments that made sense but it is not very clean to add many comments within the regex. Testing: There are existing WPT tests --------- Signed-off-by: Sebastian C <sebsebmc@gmail.com>
* fix: Crashing due to input element hack (#36461)DK Liao13 days2-4/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This PR addresses a crash in text input element due to a hack to prevent text input being trimmed. The updated behavior will only add `zero width space` unicode character to the node if there's no text content instead of adding it constantly. Also by adding the same `zero width space` unicode character to text area when there's no text content within will allow text area element to properly display caret. <img width="197" alt="截圖 2025-04-11 中午12 51 00" src="https://github.com/user-attachments/assets/10bc7314-9aa3-49df-baac-ef26d39a96d8" /> This PR also addresses issues with multiple glyph runs: https://github.com/user-attachments/assets/658db56f-b166-47ec-bc77-c6c13114d669 Testing: This PR is tested using: - `./mach run -d 'data:text/html,<input id="input_element" value="xxxxxxxxxxxxxxxxxxxx">'` - `./mach run -d 'data:text/html,<textarea id="input_element" value="xxxxxxxxxxxxxxxxxxxx">'` without causing crashes, while the results should be covered by WPT tests Fixes: https://github.com/servo/servo/issues/36449 --------- Signed-off-by: DK Liao <dklassic@gmail.com>
* dom: should change media element's currentSrc to children source element's ↵TIN TUN AUNG13 days4-29/+0
| | | | | | | | | | | | | | | | | | | | | | | | src in resource selection algorithm. (#36408) Set the `htmlmediaelement`'s `currenSrc` in resource-selection-algorithm. Change the `htmlsourceelement`'s src and srcset to USVString type. According to [Spec](https://html.spec.whatwg.org/multipage/media.html#concept-media-load-algorithm), Step 9.3 for mode is children, should set the `currentSrc` to `src` of children `htmlsourceelement`. Also, In the `htmlsourceelement` [interface definition](https://html.spec.whatwg.org/multipage/embedded-content.html#the-source-element), the `src` and `srcset` attribute should be type `USVString`. Testing: More WPT tests related to resource selection algorithm are passing. Fix: Some spec fix [Try](https://github.com/rayguo17/servo/actions/runs/14347535616) cc @xiaochengh Signed-off-by: rayguo17 <rayguo17@gmail.com>
* Implement `disabled` attribute for `<link rel="stylesheet">` (#36446)Oriol Brufau14 days6-23/+0
| | | | | | | | | | Adds support for both the content and the IDL attribute. Note this doesn't cover dynamic updates to `document.styleSheets` and the owner node of the sheet. Testing: Covered by WPT Fixes: #26739 Signed-off-by: Oriol Brufau <obrufau@igalia.com>
* feat: Implement display for text selection and caret (#35830)DK Liao14 days1-0/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This PR introduces an initial, straightforward implementation for displaying text selection and the caret. This is achieved by passing the selection range and insertion point index down to `TextFragment`, along with the starting offset of each `TextFragment` to determine the proper range for displaying the caret and text selection. Additionally, the `selected_style` was passed into `TextFragment` to specify the background color. During the final build phase, although whitespace is typically ignored when constructing glyphs, we still need to retrieve it to render both the caret and text selection at the correct location. This ensures that whitespace is not overlooked when the `TextFragment` contains an insertion point or selection range. There are several improvements yet to be made, including: - The caret is static and does not flash. - The caret is not rendered when the input field is empty. (I suppose there should be an easy fix somewhere but I haven't found it yet) **Working Examples** macOS https://github.com/user-attachments/assets/f3622cbe-9fa6-40c0-b2d8-b3a8f9842c28 Windows https://github.com/user-attachments/assets/9b008a0d-0011-4c76-a2e2-0e35869a216c Linux [Screencast from 03-07-2025 11_05_41 AM.webm](https://github.com/user-attachments/assets/09a311ad-f975-4450-a66c-b20be525a5ed) --- - [x] `./mach build -d` does not report any errors - [x] `./mach test-tidy` does not report any errors - [x] These changes fix part of #33237 (But the cursor isn't blinking yet) - [x] These changes do not require tests because there's no behavior change Signed-off-by: DK Liao <dklassic@gmail.com>
* Run all CSP tests in CI by default. (#36436)Josh Matthews2025-04-10508-0/+5491
| | | | | | | | | Extending the original set from #36402 since there are additional tests relevant to the work happening in #36409 and #36363. Testing: New tests in CI. Fixes: Part of https://github.com/servo/servo/issues/4577 Signed-off-by: Josh Matthews <josh@joshmatthews.net>
* script: Correctly convert a jsval to a `Promise` (#36403)Gae242025-04-091-3/+0
| | | | | | | | | | | Fixes an oversight of #36097, in which converting to a Promise would fail if the value passed wasn't actually a Promise, while in binding code we actually call `Promise::new_resolved` on the value. Testing: There are wpt tests that should pass now --------- Signed-off-by: Gae24 <96017547+Gae24@users.noreply.github.com>
* Run subset of CSP tests by default. (#36402)Josh Matthews2025-04-0847-0/+325
| | | | | | | | This will establish a baseline for the changes from #36363. Testing: New tests in CI. Fixes: Part of #4577 Signed-off-by: Josh Matthews <josh@joshmatthews.net>
* fix: meta referrer updating to follow spec (#36390)Sebastian C2025-04-073-9/+0
| | | | | | | | | | Previously the referrer policy used tree order but the spec only cares about the most-recently-updated or most-recently-added meta referrer. Testing: change has existing WPT tests --------- Signed-off-by: Sebastian C <sebsebmc@gmail.com>
* Create a parser for URLPatterns (#36382)Simon Wülker2025-04-073-234/+0
| | | | | | | | | | | This change implements the pattern parser, completing the "parsing pipeline" for URL patterns. Testing: Primarily `urlpattern/urlpattern-hasregexpgroups.any.js`, some other subtests start to pass too. --------- Signed-off-by: Simon Wülker <simon.wuelker@arcor.de>
* layout: Add initial support for the `::marker` pseudo-element (#36317)Martin Robinson2025-04-0717-228/+244
| | | | | | | | | | | | | | | This change adds support for the `::marker` pseudo-element and ensure that markers are cached into the box tree. This is only initial support, there are a few things missing such as animations, transitions, and support the `content` CSS property. Testing: There are WPT tests for this change. Signed-off-by: Martin Robinson <mrobinson@igalia.com> Signed-off-by: Martin Robinson <mrobinson@igalia.com>
* wpt: Unskip acid folder as most tests are passing (#36340)Manuel Rego2025-04-073-0/+46
| | | Signed-off-by: Manuel Rego Casasnovas <rego@igalia.com>
* Fix transition toggle & cancellation & delay (#35978)Euclid Ye2025-04-072-4/+22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | More details in Stylo PR: https://github.com/servo/stylo/pull/145 --- <!-- Thank you for contributing to Servo! Please replace each `[ ]` by `[X]` when the step is complete, and replace `___` with appropriate data: --> - [x] `./mach build -d` does not report any errors - [x] `./mach test-tidy` does not report any errors - [x] These changes - fixes https://github.com/servo/servo/issues/35833 - fixes https://github.com/servo/servo/issues/35982 <!-- Either: --> - [x] There are new passing test: `css/css-logical/animation-004.html: Transitions from physical to logical update when the direction is changed` Created new test files as well: 1. `css-transitions/transition-remove-and-change-immediate.html` 2. `css-transitions/transition-zero-duration-with-delay.html` 3. `css-transitions/transitioncancel-003.html` <!-- Also, please make sure that "Allow edits from maintainers" checkbox is checked, so that we can help you if you get stuck somewhere along the way.--> <!-- Pull requests that do not address these steps are welcome, but they will require additional verification as part of the review process. --> cc @Asun0204 @xiaochengh @stevennovaryo Signed-off-by: Euclid Ye <yezhizhenjiakang@gmail.com>
* layout: Scale images in `image_set` by their specified resolution (#36374)ToBinio2025-04-071-2/+0
| | | | | | | | | | | | | | | | | | | | | | | This PR makes it so the `resolution` factor in `image-set` also affects the image size. For instance, in the example below: ```css background-image: image-set("./small.png" 1x, "./large.png" 2x); ``` if `large.png` is used, an image which is 32x32 will be rendered as 16x16. This is specified in <https://drafts.csswg.org/css-images-4/#image-set-notation>. Testing: - `css/css-images/image-set/image-set-resolution-002.html` --------- Signed-off-by: tobinio <Tobias.frischmann1@gmail.com> Signed-off-by: Martin Robinson <mrobinson@igalia.com> Co-authored-by: Martin Robinson <mrobinson@igalia.com> Co-authored-by: Josh Matthews <josh@joshmatthews.net>
* Enable layout_container_queries_enabled on all WPT tests (#36348)Oriol Brufau2025-04-07109-151/+1495
| | | | | | | | | | | This feature is part of --enable-experimental-web-platform-features, so it should be enabled on all tests. It's not really implemented beyond parsing, but it should be safe to enable. It mostly changes test results from ERROR to FAIL. This is part of #36315 Signed-off-by: Oriol Brufau <obrufau@igalia.com>
* Add a tokenizer for URLPatterns (#36362)Simon Wülker2025-04-072-108/+0
| | | | | | | | | | | | Not a lot of new tests start to pass because the actual parser is still missing, so we're only passing tests for invalid inputs. The parser will be added in the next PR. This is part 3 of upstreaming the changes in https://github.com/simonwuelker/servo/tree/urlpattern --------- Signed-off-by: Simon Wülker <simon.wuelker@arcor.de>