aboutsummaryrefslogtreecommitdiffstats
path: root/tests/wpt/meta/css/cssom
Commit message (Collapse)AuthorAgeFilesLines
* Implement `ShadowRoot.innerHtml` attribute (#34335)Simon Wülker2024-11-222-9/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Implement DocumentFragment::fragment_serialization_algorithm Signed-off-by: Simon Wülker <simon.wuelker@arcor.de> * Implement ShadowRoot innerHtml attribute Signed-off-by: Simon Wülker <simon.wuelker@arcor.de> * Update WPT expectations Signed-off-by: Simon Wülker <simon.wuelker@arcor.de> * cargo-clippy Signed-off-by: Simon Wülker <simon.wuelker@arcor.de> * Reuse existing serialization code and move helpers into Node Signed-off-by: Simon Wülker <simon.wuelker@arcor.de> * Fix typo Signed-off-by: Simon Wülker <simon.wuelker@arcor.de> --------- Signed-off-by: Simon Wülker <simon.wuelker@arcor.de>
* Include non-shadowdom children of shadow hosts in style calculation (#34298)Simon Wülker2024-11-202-4/+0
| | | | | | | | | | | | | | | | * Include non-shadowdom children of shadow hosts in style calculation This was previously causing crashes because the layout nodes of those children would never be assigned style data by stylo. Signed-off-by: Simon Wülker <simon.wuelker@arcor.de> * Update WPT expectations Signed-off-by: Simon Wülker <simon.wuelker@arcor.de> --------- Signed-off-by: Simon Wülker <simon.wuelker@arcor.de>
* Enable Shadow DOM for tests (#34299)Josh Matthews2024-11-206-4/+113
| | | | | | | | | | | | | * Enable shadowdom implementation in all tests. Signed-off-by: Josh Matthews <josh@joshmatthews.net> * Update test expectations. Signed-off-by: Josh Matthews <josh@joshmatthews.net> --------- Signed-off-by: Josh Matthews <josh@joshmatthews.net>
* Remove BoxFragment::overconstrained (#33907)Oriol Brufau2024-10-192-216/+0
| | | | | | | | This was only used for serializing inset properties in getComputedStyle, but it was unnecessary and the logic was wrong anyways: an `auto` size doesn't imply that we won't be overconstrained, because it won't become negative even if the insets are big enough. Signed-off-by: Oriol Brufau <obrufau@igalia.com>
* Fix resolved value of insets to use margin box instead of content box (#33906)Oriol Brufau2024-10-181-3/+0
| | | Signed-off-by: Oriol Brufau <obrufau@igalia.com>
* layout: Enable flexbox by default on non-legacy layout (#33186)Martin Robinson2024-08-261-12/+0
| | | | | | | Flexbox is still very much in progress, but things are working well enough that we can enable it by default. It improves most pages that use flexbox now. Signed-off-by: Martin Robinson <mrobinson@igalia.com>
* layout: Add initial support for bidirectional text (BiDi) (#33148)Martin Robinson2024-08-212-27/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This adds supports for right-to-left text assigning bidi levels to all line items when necessary. This includes support for the `dir` attribute as well as corresponding CSS properties like `unicode-bidi`. It only implements right-to-left rendering for inline layout at the moment and doesn't include support for `dir=auto`. Because of missing features, this causes quite a few tests to start failing, as references become incorrect due to right-to-left rendering being active in some cases, but not others (before it didn't exist at all). Analysis of most of the new failures: ``` - /css/css-flexbox/gap-001-rtl.html /css/css-flexbox/gap-004-rtl.html - Require implementing BiDi in Flexbox, because the start and end inline margins are opposite the order of items. - /css/CSS2/bidi-text/direction-applies-to-*.xht /css/CSS2/bidi-text/direction-applies-to-002.xht /css/CSS2/bidi-text/direction-applies-to-003.xht /css/CSS2/bidi-text/direction-applies-to-004.xht - Broken due to a bug in tables, not allocating the right amount of width for a column. - /css/css-lists/inline-list.html - This fails because we wrongly insert a soft wrap opportunity between the start of an inline box and its first content. - /css/css-text/bidi/bidi-lines-001.html /css/css-text/bidi/bidi-lines-002.html /css/CSS2/text/bidi-flag-emoji.html - We do not fully support unicode-bidi: plaintext - /css/css-text/text-align/text-align-end-010.html /css/css-text/text-align/text-align-justify-006.html /css/css-text/text-align/text-align-start-010.html /html/dom/elements/global-attributes/* - We do not support dir=auto yet. - /css/css-text/white-space/tab-bidi-001.html - Servo doesn't support tab stops - /css/CSS2/positioning/abspos-block-level-001.html /css/css-text/word-break/word-break-normal-ar-000.html - Do not yet support RTL layout in block - /css/css-text/white-space/pre-wrap-018.html - Even in RTL contexts, spaces at the end of the line must hang and not be reordered - /css/css-text/white-space/trailing-space-and-text-alignment-rtl-002.html - We are letting spaces hang with white-space: pre, but they shouldn't hang. ``` Signed-off-by: Martin Robinson <mrobinson@igalia.com> Co-authored-by: Rakhi Sharma <atbrakhi@igalia.com>
* Update web-platform-tests to revision ↵Servo WPT Sync2024-08-111-0/+6
| | | | | b'3b3beee1bf2469013583bafe702f2d4821d76c1f' (#33000) Signed-off-by: WPT Sync Bot <ghbot+wpt-sync@servo.org>
* Update web-platform-tests to revision ↵Servo WPT Sync2024-08-071-0/+3
| | | | | b'3634d5a63f2fa3969616396d95537c91c3348fe5' (#32959) Signed-off-by: WPT Sync Bot <ghbot+wpt-sync@servo.org>
* layout: Port `border-image` support for legacy layout (#32874)Martin Robinson2024-07-301-12/+0
| | | Signed-off-by: Martin Robinson <mrobinson@igalia.com>
* Upgrade stylo to 2024-07-16 (#32812)Martin Robinson2024-07-241-9/+0
| | | | | | | | | | | | | | * Upgrade stylo to 2024-07-16 Signed-off-by: Martin Robinson <mrobinson@igalia.com> * Use the new `dom` crate from stylo Signed-off-by: Martin Robinson <mrobinson@igalia.com> --------- Signed-off-by: Martin Robinson <mrobinson@igalia.com> Co-authored-by: Oriol Brufau <obrufau@igalia.com>
* Update web-platform-tests to revision ↵Servo WPT Sync2024-07-072-0/+6
| | | | | b'4e3b5de2eb8218cf18a1674618994efeb96e2cc0' (#32717) Signed-off-by: WPT Sync Bot <ghbot+wpt-sync@servo.org>
* layout: Add support for table captions (#32657)Martin Robinson2024-07-031-9/+0
| | | | | | | | | | | | | This adds initial support for table captions. To do this, the idea of the table wrapper becomes a bit more concrete. Even so, the wrapper is still reponsible for allocating space for the grid's border and padding, as those properties are specified on the wrapper and not grid in CSS. In order to account for this weirdness of HTML/CSS captions and grid are now laid out and placed with a negative offset in the table wrapper content rect. Signed-off-by: Martin Robinson <mrobinson@igalia.com> Co-authored-by: Oriol Brufau <obrufau@igalia.com>
* Fix getComputedStyle for width and height (#32437)Oriol Brufau2024-06-041-4/+0
| | | | | It was providing a length whenever the element generates a box. However, these properties don't apply to non-replaced inlines, so the computed value should be provided instead.
* Update web-platform-tests to revision ↵Servo WPT Sync2024-06-021-0/+2
| | | | b'17375f41ccf41e081764d2786ec535dede108c47' (#32426)
* Implement 'empty-cells' for layout 2020 (#32331)Oriol Brufau2024-05-211-9/+0
| | | | | https://drafts.csswg.org/css-tables/#empty-cell-rendering Co-authored-by: Martin Robinson <mrobinson@igalia.com>
* tables: Add a naive implementation of `border-collapse` (#32309)Martin Robinson2024-05-181-9/+0
| | | | | | | | | This change adds a very simple implementation of `border-collapse` for tables. No harmonization or merging is done at all for borders. Instead, the largest border for every continuous border sets the size. Instead of merging different border styles, they are squashed to half size -- which isn't great, but ensures appropriate positioning. Co-authored-by: Oriol Brufau <obrufau@igalia.com>
* Update web-platform-tests to revision ↵Servo WPT Sync2024-05-121-4/+3
| | | | b'8f48f40aab7f7f8a8118dc1a46972d070622be52' (#32271)
* layout: Add a basic support for `list-style-position: outside` (#32114)Martin Robinson2024-04-222-12/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This change adds very basic support for `list-style-position`. Currently, the marker does not do any kind of baseline alignment with the rest of the list item contents and it also doesn't force the list item to be at least as tall as the marker. This adds a few new failures: - Four failures because markers do not ensure that list-items have at least the same block size as they do: - FAIL [expected PASS] /css/CSS2/lists/list-style-applies-to-012.xht - FAIL [expected PASS] /css/CSS2/lists/list-style-applies-to-014.xht - FAIL [expected PASS] /css/CSS2/lists/list-style-type-applies-to-012.xht - FAIL [expected PASS] /css/CSS2/lists/list-style-type-applies-to-014.xht - One failure because we don't yet support the `::marker` pseudo-selector: - FAIL [expected PASS] /css/css-position/position-absolute-dynamic-list-marker.html - One failure because we don't support the list item exception for the line height quirk: - FAIL [expected PASS] /quirks/line-height-in-list-item.tentative.html Co-authored-by: Oriol Brufau <obrufau@igalia.com> <!-- Please describe your changes on the following line: --> Fixes #27383. --- <!-- 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 #27383. - [ ] 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. --> Co-authored-by: Oriol Brufau <obrufau@igalia.com>
* Update web-platform-tests to revision ↵Servo WPT Sync2024-03-311-0/+75
| | | | b'16f18d8135a80e89f2e910ca7548999fa2f7937e' (#31951)
* Update Stylo to 2023-10-16 (#31932)Oriol Brufau2024-03-301-18/+0
| | | | | | | | | | | | | | | | | | | | | | | * Update Stylo to 2023-10-16 * Fixup for https://phabricator.services.mozilla.com/D185154 * Fixup for https://phabricator.services.mozilla.com/D188216 * Fixup for https://phabricator.services.mozilla.com/D185677 * Fixup for https://phabricator.services.mozilla.com/D188566 * Fixup for https://phabricator.services.mozilla.com/D188727 * Fixup for https://phabricator.services.mozilla.com/D189475 * Fixup for https://phabricator.services.mozilla.com/D189521 * Fixup for https://phabricator.services.mozilla.com/D188812 * Fixup for https://phabricator.services.mozilla.com/D189484 * Update test expectations
* Sync WPT with upstream (17-03-2024) (#31715)Servo WPT Sync2024-03-172-0/+26
| | | | | | | | | | | * Update raw lags path for WPT import I forgot to do this in #31616 * Update web-platform-tests to revision b'298d1599dbf6255aea63506daaa1702ff0c4fdc5' --------- Co-authored-by: Samson <16504129+sagudev@users.noreply.github.com>
* Implement HTMLStyleElement.disabled attribute (#31682)Oriol Brufau2024-03-141-3/+0
| | | https://html.spec.whatwg.org/multipage/#dom-style-disabled
* Add basic support for enumerating computed styles (#31499)Oriol Brufau2024-03-066-19/+32
| | | | | | | | | | | * Add basic support for enumerating computed styles The old code was so broken, it was enumerating the style attribute instead of the computed styles. So this patch implements a basic enumeration, but not including custom properties whose computed value is not the guaranteed-invalid value. * Feedback
* Add CSSOM support for CSS layers (#31481)Oriol Brufau2024-03-031-3/+0
| | | Instead of just crashing.
* Sync WPT with upstream (03-03-2024) (#31482)Servo WPT Sync2024-03-031-0/+9
| | | | | | | | | * Update web-platform-tests to revision b'1b88c8bd56a924f9865daa15834d444c55dd7327' * Update expectations --------- Co-authored-by: sagudev <16504129+sagudev@users.noreply.github.com>
* layout: Turn on synthetic small-caps for layout 2020 (#31435)Martin Robinson2024-02-282-13/+4
| | | | | | | | | | | | Synthetic small caps is supported by the font subsystem, but this is disabled in Layout 2020. We can turn this on to bring support to parity with the old layout system. In addition to turning on synthetic small-caps this change also improves the way that they work. Before, synthetic small caps meant that every character was a small version of capitalized character. After this change, capital letters are larger than small caps versions of small letters -- matching other browsers and the common expectation of how small caps works.
* layout: Add initial support for `text-transform` (#31396)Martin Robinson2024-02-221-15/+0
| | | | | | | | | | | | | This adds basic support for `text-transform` in a way that is more complete than legacy layout. There are still many missing elements of proper `text-transform` support such as: 1. Support for `full-width` and `full-size-kana` 2. Support for grapheme based uppercasing, lowercasing, and capitalization. These are all done per-code point right now. 3. Support for the language-specific `SpecialCasing.txt` cases for case mapping such as the ones for Irish and Turkish. Co-authored-by: Rakhi Sharma <atbrakhi@igalia.com>
* Update web-platform-tests to revision ↵Servo WPT Sync2024-02-181-0/+15
| | | | b'504dbb9401e985461bdc3fb534cb26fd5bb9d9ad' (#31372)
* Fix list-style serialization (#31314)Oriol Brufau2024-02-111-6/+0
| | | | | | | In layout2020, 'list-style-position' is disabled behind a pref, so the list_style_position field is an Option. The serialization of the 'list-style' shorthand wasn't correctly handling the case of it being None.
* Don't escape property name in CSSStyleDeclaration's item() (#31305)Oriol Brufau2024-02-091-6/+0
| | | Just return the raw name. This is only relevant for custom properties.
* Fix CSSStyleDeclaration's item() to provide properties instead of values ↵Oriol Brufau2024-02-098-57/+1
| | | | | | | | | | | | | | | | (#31299) For example, style.cssText = "margin: 1px 2px 3px 4px"; [...style]; will now be ["margin-top", "margin-right", "margin-bottom", "margin-left"] instead of ["1px", "2px", "3px", "4px"]
* layout: Add support for table `border-spacing` (#31166)Martin Robinson2024-01-262-18/+0
| | | | | | This adds support for table `border-spacing` property. Note that we do not yet support the collapsed border model. Co-authored-by: Oriol Brufau <obrufau@igalia.com>
* layout: Implement support for `line-height` and `vertical-align` (#30902)Martin Robinson2024-01-081-42/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * layout: Implement support for `line-height` and `vertical-align` This is an initial implementation of proper `line-height` and `vertical-align` support. While this change includes the bulk of the work there are still many missing pieces for full support. In particular some big missing things are: - Flex containers do not properly compute their baselines. The idea is to tackle this in a followup change. This causes various flex tests to start failing because everything used to be top aligned. - The implementation of the line-height quirks (only active in quirks mode) are incomplete. While the quirk works in many cases, there are still some cases where it is handled incorrectly. This requires more redesign and refinement, better suited for a followup. - Most of the features are CSS 3 such as precision control of the baseline and first and last baselines are not implemented. This change gets us close to CSS 2.x support. While there are many new test passes with this change some tests are starting to fail. An accounting of new failures: Tests failing also in Layout 2013: - /css/css2/positioning/toogle-abspos-on-relpos-inline-child.html (only passes in Chrome) - /css/CSS2/fonts/font-applies-to-001.xht (potentially an issue with font size) Invalid tests: - /css/CSS2/visudet/inline-block-baseline-003.xht - /css/CSS2/visudet/inline-block-baseline-004.xht - These are are failing in all browsers. See https://bugs.chromium.org/p/chromium/issues/detail?id=1222151. Missing table support: - /_mozilla/mozilla/table_valign_middle.html Missing `font-size-adjust` support : - /css/css-fonts/font-size-adjust-zero-2.html (also failing in 2013) Incomplete form field support : - /html/rendering/widgets/the-select-element/option-add-label-quirks.html (label isn't rendered so button isn't the right size in quirks mode due to line height quirk) Need support for calculating flexbox baseline: - /css/css-flexbox/fieldset-baseline-alignment.html - /css/css-flexbox/flex-inline.html - /css/css-flexbox/flexbox-baseline-multi-line-horiz-001.html - /css/css-flexbox/flexbox-baseline-single-item-001a.html - /css/css-flexbox/flexbox-baseline-single-item-001b.html Failing because we don't create anonymous inline boxes for text children of blocks: - /css/CSS2/linebox/anonymous-inline-inherit-001.html Passes locally (potentially related to fonts): - /css/CSS2/css1/c414-flt-fit-004.xht - /css/css-transforms/transform-input-017.html - /html/obsolete/requirements-for-implementations/the-marquee-element-0/marquee-min-intrinsic-size.html - /css/css-fonts/first-available-font-005.html - /css/css-fonts/first-available-font-006.html * Some cleanups after live review with @mukilan Also update results.
* Sync WPT with upstream (07-01-2024) (#31018)Servo WPT Sync2024-01-081-0/+3
| | | | | | | | | | | | | * Update web-platform-tests to revision b'ecbab417501c89bca2265314e35719a950b07e02' * update expectation for service-worker-registration.https.html.ini The expectation of CRASH was added during the import seemingly due to an intermittent crash in CI. The test is no longer crashing. --------- Co-authored-by: Mukilan Thiyagarajan <mukilan@igalia.com>
* Sync WPT with upstream (25-12-2023) (#30938)Servo WPT Sync2023-12-261-0/+39
| | | | | | | | | * Update web-platform-tests to revision b'73caf716542762aab6646f0a02de208bc0ec4124' * Update expectations --------- Co-authored-by: sagudev <16504129+sagudev@users.noreply.github.com>
* Update web-platform-tests to revision ↵Servo WPT Sync2023-12-171-0/+6
| | | | b'a85f0dfe538b9cb894388a65dba7a2a21db050c7' (#30879)
* Sync WPT with upstream (03-12-2023) (#30814)Servo WPT Sync2023-12-062-2/+2
| | | | | | | | | * Update web-platform-tests to revision b'dd47ca67f55ac9df45235b2335200fb885dd1357' * Update test expectations --------- Co-authored-by: Martin Robinson <mrobinson@igalia.com>
* Add initial support for sticky positioning for non-legacy layout (#30686)Martin Robinson2023-11-293-1084/+0
| | | | | | | | | | * Add initial support for sticky positioning for non-legacy layout Many tests still fail for a variety of reasons. One of the primary ones is that CSSOM currently does not return correct values for elements positioned by sticky nodes. This requires changes to WebRender to work properly. * Fix an assertion failure in the legacy layout sticky code
* Sync WPT with upstream (26-11-2023) (#30783)Servo WPT Sync2023-11-271-0/+1
| | | | | | | | | | | * Update web-platform-tests to revision b'a59ba94da3f2638beee8950e423c5fedfe02e809' * Update expectations * Update expectations again --------- Co-authored-by: sagudev <16504129+sagudev@users.noreply.github.com>
* Update test expectationsOriol Brufau2023-11-241-18/+0
|
* Update web-platform-tests to revision ↵Servo WPT Sync2023-11-192-2/+13
| | | | b'7aaad11d87d7a02515081e55609d31ab6ff173fc' (#30753)
* Sync WPT with upstream (12-11-2023) (#30724)Servo WPT Sync2023-11-151-0/+3
| | | | | | | | | | | | * Update web-platform-tests to revision b'46476776fdbf0a62522621002ba8af68e4d478b6' * wpt import: update expectation Signed-off-by: Mukilan Thiyagarajan <mukilan@igalia.com> --------- Signed-off-by: Mukilan Thiyagarajan <mukilan@igalia.com> Co-authored-by: Mukilan Thiyagarajan <mukilan@igalia.com>
* Update test expectationsOriol Brufau2023-11-042-19/+0
|
* Sync WPT with upstream (04-10-2023) (#30493)Servo WPT Sync2023-10-062-45/+21
| | | | | | | | | | | | | | | * Update web-platform-tests to revision b'dfda99176a5d552fb1129fa353b7e4c69f6ed92c' * fix linter errors after WPT import Signed-off-by: Mukilan Thiyagarajan <mukilan@igalia.com> * Update expectations --------- Signed-off-by: Mukilan Thiyagarajan <mukilan@igalia.com> Co-authored-by: Mukilan Thiyagarajan <mukilan@igalia.com> Co-authored-by: sagudev <16504129+sagudev@users.noreply.github.com>
* Sync WPT with upstream (07-08-2023) (#30078)Servo WPT Sync2023-08-081-0/+21
| | | | | | | | | | | | * Update web-platform-tests to revision b'6d5a1f7fb272973c2a951831b4f9fb25f05f96b0' * Revert some expectations updated by WPT import Signed-off-by: Mukilan Thiyagarajan <mukilan@igalia.com> --------- Signed-off-by: Mukilan Thiyagarajan <mukilan@igalia.com> Co-authored-by: Mukilan Thiyagarajan <mukilan@igalia.com>
* Make the choice of layout runtime settingMartin Robinson2023-07-064-57/+1080
| | | | Co-authored-by: Samson <16504129+sagudev@users.noreply.github.com>
* Update web-platform-tests to revision ↵WPT Sync Bot2023-07-021-0/+3
| | | | b'f513c41310ebb13de9a0c5ea5e1c22544e0b5000'
* Update web-platform-tests to revision ↵WPT Sync Bot2023-06-259-37/+17
| | | | b'7b682ab07397d72fceb6594d0f27cb36cf1d8ee3'
* Rename metadata directoriesMartin Robinson2023-06-2297-0/+2409
This renames: - `tests/wpt/metadata` → `tests/wpt/meta-legacy-layout` - `tests/wpt/metadata-layout-2020` → `tests/wpt/meta` - `tests/wpt/mozilla/meta` → `tests/wpt/mozilla/meta-legacy-layout` - `tests/wpt/mozilla/meta-layout-2020` → `tests/wpt/mozilla/meta`