From 1f315e6c9cf9a7c07fc4fa8a7c7e88a439279f89 Mon Sep 17 00:00:00 2001 From: Fuguo <1782765876@qq.com> Date: Thu, 29 May 2025 16:20:01 +0800 Subject: [PATCH] Add a user agent style for the `` element (#37174) In Chromium, the slot user agent stylesheet is located in [html.css](https://source.chromium.org/chromium/chromium/src/+/main:third_party/blink/renderer/core/html/resources/html.css;l=1654). Testing: This change fixes `tests/wpt/meta/shadow-dom/directionality-001.tentative.html.ini`. Signed-off-by: kongbai1996 <1782765876@qq.com> --- components/layout/stylesheets/servo.css | 4 ++++ .../wpt/meta/shadow-dom/directionality-001.tentative.html.ini | 2 -- 2 files changed, 4 insertions(+), 2 deletions(-) delete mode 100644 tests/wpt/meta/shadow-dom/directionality-001.tentative.html.ini diff --git a/components/layout/stylesheets/servo.css b/components/layout/stylesheets/servo.css index c025b19f364..cb206bbcd00 100644 --- a/components/layout/stylesheets/servo.css +++ b/components/layout/stylesheets/servo.css @@ -265,4 +265,8 @@ select { padding: 0 0.25em; /* Don't show a text cursor when hovering selected option */ cursor: default; +} + +slot { + display: contents; } \ No newline at end of file diff --git a/tests/wpt/meta/shadow-dom/directionality-001.tentative.html.ini b/tests/wpt/meta/shadow-dom/directionality-001.tentative.html.ini deleted file mode 100644 index 8929df10f67..00000000000 --- a/tests/wpt/meta/shadow-dom/directionality-001.tentative.html.ini +++ /dev/null @@ -1,2 +0,0 @@ -[directionality-001.tentative.html] - expected: FAIL