[webkit-changes] [WebKit/WebKit] ac733e: Limit non-initial <input type=checkbox switch> sty...
Anne van Kesteren
noreply at github.com
Tue Jan 16 10:45:11 PST 2024
Branch: refs/heads/main
Home: https://github.com/WebKit/WebKit
Commit: ac733e6cb304cd07c2456b71f170d8758755aad6
https://github.com/WebKit/WebKit/commit/ac733e6cb304cd07c2456b71f170d8758755aad6
Author: Anne van Kesteren <annevk at annevk.nl>
Date: 2024-01-16 (Tue, 16 Jan 2024)
Changed paths:
A LayoutTests/fast/forms/switch/display-expected.txt
A LayoutTests/fast/forms/switch/display.html
M LayoutTests/imported/w3c/web-platform-tests/html/rendering/widgets/input-checkbox-switch.tentative.window-expected.txt
M LayoutTests/imported/w3c/web-platform-tests/html/rendering/widgets/input-checkbox-switch.tentative.window.js
M LayoutTests/platform/ios/TestExpectations
M Source/WebCore/css/htmlSwitchControl.css
M Source/WebCore/rendering/RenderTheme.cpp
M Source/WebCore/rendering/RenderTheme.h
M Source/WebCore/rendering/RenderThemeIOS.mm
Log Message:
-----------
Limit non-initial <input type=checkbox switch> styling to appearance:auto
https://bugs.webkit.org/show_bug.cgi?id=267334
Reviewed by Aditya Keerthi and Tim Nguyen.
Per discussion in https://github.com/whatwg/html/issues/4180 we do not
want styles intended for appearance:auto to leak into appearance:none.
Ideally we pay more attention to this with all form controls going
forward, but that is a much larger undertaking.
* LayoutTests/fast/forms/switch/display-expected.txt: Added.
* LayoutTests/fast/forms/switch/display.html: Added.
* LayoutTests/imported/w3c/web-platform-tests/html/rendering/widgets/input-checkbox-switch.tentative.window-expected.txt:
* LayoutTests/imported/w3c/web-platform-tests/html/rendering/widgets/input-checkbox-switch.tentative.window.js:
* LayoutTests/platform/ios/TestExpectations:
Enable WebKit-specific switch tests on iOS too, except for those that
currently do not work.
* Source/WebCore/css/htmlSwitchControl.css:
(@namespace "http://www.w3.org/1999/xhtml";):
(input[type="checkbox"][switch]::thumb, input[type="checkbox"][switch]::track):
* Source/WebCore/rendering/RenderTheme.cpp:
(WebCore::RenderTheme::adjustStyle):
(WebCore::RenderTheme::adjustSwitchStyleDisplay const):
(WebCore::RenderTheme::adjustSwitchStyle const):
(WebCore::RenderTheme::adjustSwitchThumbOrSwitchTrackStyle const):
* Source/WebCore/rendering/RenderTheme.h:
* Source/WebCore/rendering/RenderThemeIOS.mm:
(WebCore::RenderThemeIOS::adjustSwitchStyle const):
No longer skip most of the iOS style adjusting logic for non-auto sizes.
Canonical link: https://commits.webkit.org/273078@main
More information about the webkit-changes
mailing list