Commit 19d84593 authored by Kent Tamura's avatar Kent Tamura Committed by Commit Bot

Enable "RestrictedWebkitAppearance" flag as "experimental".

* insert_paragraph_separator_command_test.cc
  <colgroup>'s actual appearance will be 'none', and it has no height.

* external/wpt/css/css-lists/list-and-margin-collapse-003.html and -004.html
  <div> can't have 'checkbox' appearance any longer, and we couldn't find other
  ways to reproduce the original issue.  So we remove the tests.

* fast/css/invalid-appearance.html
  Removed.  It was made to check deprecation messages.

* fast/css/square-button-appearance.html
  Removed. -webkit-appearance:square-button doesn't work for arbitrary elements
  any longer, and its appearance is tested in input[type=color] tests.

* fast/forms/file/file-style-inheritance.html
  -webkit-appearance:square-button doesn't work for ::-webkit-file-upload-button
  any longer. -webkit-appearnace:none works well in the test.

* fast/forms/range/thumbslider-no-parent-slider.html
  -webkit-appearance:slider-thumb-* don't work in this case any longer. Its
  pixel result has nothing. This CL converts the test to a reference test.

* scrollbars/custom-scrollbar-appearance-property.html
  -webkit-appearance:searchfield-cancel-button doesn't work for
  ::-webkit-scrollbar* any longer, and pixel result of this test would be
  changed.  This CL converts the test to a testharness.js test.

* fast/css/invalid-appearance-progress-bar-meter-expected.txt
* fast/forms/datalist/slider-appearance-with-ticks-crash-expected.txt
* fast/forms/range/slider-appearance-crash-expected.txt
* fast/forms/range/thumbslider-crash-expected.txt
* fast/text/whitespace/pre-block-normal-inline-crash-2-expected.txt
* paint/invalidation/selection/multiple-body-remove-selection-crash-expected.txt
* paint/theme/anonymous-element-menulist-painting-expected.txt
  Remove deprecation messages.


Bug: 981720
Change-Id: I91068c8265cdfc682a06b1b4588b04ea30a318d0
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1727654Reviewed-by: default avatarYoshifumi Inoue <yosin@chromium.org>
Commit-Queue: Kent Tamura <tkent@chromium.org>
Cr-Commit-Position: refs/heads/master@{#684247}
parent df792cd1
...@@ -31,7 +31,7 @@ TEST_F(InsertParagraphSeparatorCommandTest, ...@@ -31,7 +31,7 @@ TEST_F(InsertParagraphSeparatorCommandTest,
EXPECT_EQ( EXPECT_EQ(
"<table contenteditable>" "<table contenteditable>"
" <colgroup style=\"-webkit-appearance:radio;\">|<br></colgroup>" "| <colgroup style=\"-webkit-appearance:radio;\"></colgroup>"
"</table>", "</table>",
GetSelectionTextFromBody()); GetSelectionTextFromBody());
} }
...@@ -53,7 +53,7 @@ TEST_F(InsertParagraphSeparatorCommandTest, ...@@ -53,7 +53,7 @@ TEST_F(InsertParagraphSeparatorCommandTest,
command->Apply(); command->Apply();
EXPECT_EQ( EXPECT_EQ(
"<table contenteditable>" "<table contenteditable>"
" <colgroup style=\"-webkit-appearance:radio;\">|<br>" "| <colgroup style=\"-webkit-appearance:radio;\">"
" <col>" " <col>"
" </colgroup>" " </colgroup>"
"</table>", "</table>",
......
...@@ -1343,6 +1343,7 @@ ...@@ -1343,6 +1343,7 @@
}, },
{ {
name: "RestrictedWebkitAppearance", name: "RestrictedWebkitAppearance",
status: "experimental",
}, },
{ {
name: "RtcAudioJitterBufferMaxPackets", name: "RtcAudioJitterBufferMaxPackets",
......
<!DOCTYPE html>
<meta charset="utf-8">
<title>CSS Lists: test the margin collapse of marker</title>
<link rel=help href="https://www.w3.org/TR/CSS22/generate.html#lists">
<link rel="help" href="http://crbug.com/969741">
<script src="/resources/testharness.js"></script>
<script src="/resources/testharnessreport.js"></script>
<style type="text/css">
.checkbox{
-moz-appearance: checkbox;
-webkit-appearance: checkbox;
height: 0px;
}
</style>
<div id="log"></div>
<div id="target_with_marker" style="overflow:hidden; width:100px;">
<div style="margin-bottom:100px;"></div>
<div style="display:list-item; margin-left:100px; height:0px;"><div class="checkbox"></div></div>
<div style="margin-top:100px;"></div>
</div>
<div id="target_without_marker" style="overflow:hidden; width:100px;">
<div style="margin-bottom:100px;"></div>
<div style="display:list-item; margin-left:100px; list-style:none;"><div class="checkbox"></div></div>
<div style="margin-top:100px;"></div>
</div>
<script>
test(function() {
var height_with_marker = document.getElementById("target_with_marker").clientHeight;
assert_equals(height_with_marker, 200, "Should not allow margin-collapsing through if list is with marker.");
var height_without_marker = document.getElementById("target_without_marker").clientHeight;
assert_equals(height_without_marker, 100, "Should allow margin-collapsing through if list is without marker.");
}, "list and margin collapse");
</script>
<!DOCTYPE html>
<title>Test if it doesn't crash when resolving BFC block-offset abort</title>
<link rel=help href="https://www.w3.org/TR/CSS22/generate.html#lists">
<link rel="help" href="http://crbug.com/969741">
<script src="/resources/testharness.js"></script>
<script src="/resources/testharnessreport.js"></script>
<style type="text/css">
#checkbox{
-moz-appearance: checkbox;
-webkit-appearance: checkbox;
height: 0px;
}
</style>
<body>
<div style="float: left; width: 100px; height: 100px;"></div>
<div style="display: list-item;">
<div id="checkbox"></div>
</div>
<script>
test(() => {}, "Layout should not crash");
</script>
</body>
CONSOLE WARNING: '-webkit-appearance: checkbox' for elements other than input[type=checkbox] is deprecated and will be removed in M79, around December 2019. See https://www.chromestatus.com/features/5070237827334144 for more details.
CONSOLE WARNING: '-webkit-appearance: radio' for elements other than input[type=radio] is deprecated and will be removed in M79, around December 2019. See https://www.chromestatus.com/features/5070237827334144 for more details.
CONSOLE WARNING: '-webkit-appearance: push-button' for elements other than input[type=button], input[type=reset], and input[type=submit] is deprecated and will be removed in M79, around December 2019. See https://www.chromestatus.com/features/5070237827334144 for more details.
CONSOLE WARNING: '-webkit-appearance: square-button' for elements other than input[type=color] is deprecated and will be removed in M79, around December 2019. See https://www.chromestatus.com/features/5070237827334144 for more details.
CONSOLE WARNING: '-webkit-appearance: button' for a is deprecated and will be removed in M79, around December 2019. See https://www.chromestatus.com/features/5070237827334144 for more details.
CONSOLE WARNING: '-webkit-appearance: button' for drop-down box select is deprecated and will be removed in M79, around December 2019. See https://www.chromestatus.com/features/5070237827334144 for more details.
CONSOLE WARNING: '-webkit-appearance: inner-spin-button' for elements other than :-webkit-inner-spin-button is deprecated and will be removed in M79, around December 2019. See https://www.chromestatus.com/features/5070237827334144 for more details.
CONSOLE WARNING: '-webkit-appearance: listbox' for elements other than listbox select is deprecated and will be removed in M79, around December 2019. See https://www.chromestatus.com/features/5070237827334144 for more details.
CONSOLE WARNING: '-webkit-appearance: menulist' for elements other than select and input[type=color][list] is deprecated and will be removed in M79, around December 2019. See https://www.chromestatus.com/features/5070237827334144 for more details.
CONSOLE WARNING: '-webkit-appearance: menulist-button' for elements other than select and input[type=color][list] is deprecated and will be removed in M79, around December 2019. See https://www.chromestatus.com/features/5070237827334144 for more details.
CONSOLE WARNING: '-webkit-appearance: meter' for elements other than meter is deprecated and will be removed in M79, around December 2019. See https://www.chromestatus.com/features/5070237827334144 for more details.
CONSOLE WARNING: '-webkit-appearance: progress-bar' for elements other than progress is deprecated and will be removed in M79, around December 2019. See https://www.chromestatus.com/features/5070237827334144 for more details.
CONSOLE WARNING: '-webkit-appearance: slider-horizontal' for elements other than input[type=range] is deprecated and will be removed in M79, around December 2019. See https://www.chromestatus.com/features/5070237827334144 for more details.
CONSOLE WARNING: '-webkit-appearance: slider-vertical' for elements other than input[type=range] is deprecated and will be removed in M79, around December 2019. See https://www.chromestatus.com/features/5070237827334144 for more details.
CONSOLE WARNING: '-webkit-appearance: sliderthumb-horizontal' for elements other than ::-webkit-slider-thumb and ::-webkit-media-slider-thumb is deprecated and will be removed in M79, around December 2019. See https://www.chromestatus.com/features/5070237827334144 for more details.
CONSOLE WARNING: '-webkit-appearance: sliderthumb-vertical' for elements other than ::-webkit-slider-thumb and ::-webkit-media-slider-thumb is deprecated and will be removed in M79, around December 2019. See https://www.chromestatus.com/features/5070237827334144 for more details.
CONSOLE WARNING: '-webkit-appearance: searchfield' for elements other than input[type=search] is deprecated and will be removed in M79, around December 2019. See https://www.chromestatus.com/features/5070237827334144 for more details.
CONSOLE WARNING: '-webkit-appearance: searchfield-cancel-button' for elements other than ::-webkit-clear-button and ::-webkit-search-cancel-button is deprecated and will be removed in M79, around December 2019. See https://www.chromestatus.com/features/5070237827334144 for more details.
CONSOLE WARNING: '-webkit-appearance: textfield' for elements other than input[type=email], input[type=number], input[type=password], input[type=search], input[type=tel], input[type=text], input[type=url], input[type=date], input[type=datetime-local], input[type=month], input[type=time], and input[type=week] is deprecated and will be removed in M79, around December 2019. See https://www.chromestatus.com/features/5070237827334144 for more details.
CONSOLE WARNING: '-webkit-appearance: textarea' for elements other than textarea is deprecated and will be removed in M79, around December 2019. See https://www.chromestatus.com/features/5070237827334144 for more details.
See if we have deprecation messages for -webkit-appearance.
menulist
CONSOLE WARNING: '-webkit-appearance: progress-bar' for elements other than progress is deprecated and will be removed in M79, around December 2019. See https://www.chromestatus.com/features/5070237827334144 for more details.
CONSOLE WARNING: '-webkit-appearance: meter' for elements other than meter is deprecated and will be removed in M79, around December 2019. See https://www.chromestatus.com/features/5070237827334144 for more details.
PASS if it doesn't crash. See Bug 40158. PASS if it doesn't crash. See Bug 40158.
On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE". On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
......
<!DOCTYPE html>
<style>
span, a {
display: inline-block;
width: 1em;
height: 1em;
}
</style>
<body>
<br>
<p>See if we have deprecation messages for -webkit-appearance.</p>
<span style="-webkit-appearance: checkbox"></span>
<span style="-webkit-appearance: radio"></span>
<span style="-webkit-appearance: push-button"></span>
<span style="-webkit-appearance: square-button"></span>
<a style="-webkit-appearance: button"></a>
<select style="-webkit-appearance: button"></select>
<span style="-webkit-appearance: inner-spin-button"></span>
<select style="-webkit-appearance: listbox"></select>
<span style="-webkit-appearance: listbox"></span>
<!-- font and height are necessary to avoid fallback to 'menulist-button'. -->
<span style="-webkit-appearance: menulist; font: -webkit-small-control; height: auto">menulist</span>
<span style="-webkit-appearance: menulist-button"></span>
<span style="-webkit-appearance: meter"></span>
<span style="-webkit-appearance: progress-bar"></span>
<span style="-webkit-appearance: slider-horizontal"></span>
<span style="-webkit-appearance: slider-vertical"></span>
<span style="-webkit-appearance: sliderthumb-horizontal"></span>
<span style="-webkit-appearance: sliderthumb-vertical"></span>
<span style="-webkit-appearance: searchfield"></span>
<span style="-webkit-appearance: searchfield-cancel-button"></span>
<textarea style="-webkit-appearance: textfield"></textarea>
<input style="-webkit-appearance: textarea">
<script>
testRunner.dumpAsText();
</script>
</body>
CONSOLE WARNING: '-webkit-appearance: square-button' for elements other than input[type=color] is deprecated and will be removed in M79, around December 2019. See https://www.chromestatus.com/features/5070237827334144 for more details.
<!DOCTYPE html>
<html>
<head>
<script>
enablePixelTesting = true;
</script>
<script src="../resources/js-test.js"></script>
<style>
.squarebutton {
-webkit-appearance: square-button;
width: 100px;
height: 100px;
}
</style>
</head>
<body>
<!-- Test if square-button appearance is rendered properly. -->
<div class="squarebutton"></div>
</body>
</html>
CONSOLE WARNING: '-webkit-appearance: slider-vertical' for elements other than input[type=range] is deprecated and will be removed in M79, around December 2019. See https://www.chromestatus.com/features/5070237827334144 for more details.
CONSOLE WARNING: '-webkit-appearance: slider-horizontal' for elements other than input[type=range] is deprecated and will be removed in M79, around December 2019. See https://www.chromestatus.com/features/5070237827334144 for more details.
No crash means test PASS. No crash means test PASS.
CONSOLE WARNING: '-webkit-appearance: square-button' for elements other than input[type=color] is deprecated and will be removed in M79, around December 2019. See https://www.chromestatus.com/features/5070237827334144 for more details.
Tests internal components of a file upload control correctly inherit the style of the container input element. Tests internal components of a file upload control correctly inherit the style of the container input element.
PASS document.defaultView.getComputedStyle(button1, null).getPropertyValue("font-size") is "30px" PASS document.defaultView.getComputedStyle(button1, null).getPropertyValue("font-size") is "30px"
......
...@@ -5,8 +5,8 @@ ...@@ -5,8 +5,8 @@
font-size: 30px; font-size: 30px;
} }
#large::-webkit-file-upload-button { #large::-webkit-file-upload-button {
/* Uses square-button for ease of testing on Mac. */ /* Uses none for ease of testing on Mac. */
-webkit-appearance: square-button; -webkit-appearance: none;
} }
#dark { #dark {
......
CONSOLE WARNING: '-webkit-appearance: slider-horizontal' for elements other than input[type=range] is deprecated and will be removed in M79, around December 2019. See https://www.chromestatus.com/features/5070237827334144 for more details.
Checks that slider appearance on regular node doesn't crash. Checks that slider appearance on regular node doesn't crash.
CONSOLE WARNING: '-webkit-appearance: sliderthumb-horizontal' for elements other than ::-webkit-slider-thumb and ::-webkit-media-slider-thumb is deprecated and will be removed in M79, around December 2019. See https://www.chromestatus.com/features/5070237827334144 for more details.
PASS If this test does not crash. http://bugs.webkit.org/show_bug.cgi?id=12045 PASS If this test does not crash. http://bugs.webkit.org/show_bug.cgi?id=12045
CONSOLE WARNING: '-webkit-appearance: sliderthumb-horizontal' for elements other than ::-webkit-slider-thumb and ::-webkit-media-slider-thumb is deprecated and will be removed in M79, around December 2019. See https://www.chromestatus.com/features/5070237827334144 for more details.
CONSOLE WARNING: '-webkit-appearance: sliderthumb-vertical' for elements other than ::-webkit-slider-thumb and ::-webkit-media-slider-thumb is deprecated and will be removed in M79, around December 2019. See https://www.chromestatus.com/features/5070237827334144 for more details.
...@@ -16,7 +16,7 @@ ...@@ -16,7 +16,7 @@
</style> </style>
</head> </head>
<body> <body>
<!-- There should be a horizontal slider thumb and a vertical slider thumb. --> <!-- There should be nothing. -->
<span id="thumbHorizontal"></span><br> <span id="thumbHorizontal"></span><br>
<span id="thumbVertical"></span> <span id="thumbVertical"></span>
</body> </body>
......
CONSOLE WARNING: '-webkit-appearance: sliderthumb-vertical' for elements other than ::-webkit-slider-thumb and ::-webkit-media-slider-thumb is deprecated and will be removed in M79, around December 2019. See https://www.chromestatus.com/features/5070237827334144 for more details.
This test passes if it does not CRASH. This test passes if it does not CRASH.
CONSOLE WARNING: '-webkit-appearance: radio' for elements other than input[type=radio] is deprecated and will be removed in M79, around December 2019. See https://www.chromestatus.com/features/5070237827334144 for more details.
CONSOLE WARNING: '-webkit-appearance: menulist-button' for elements other than select and input[type=color][list] is deprecated and will be removed in M79, around December 2019. See https://www.chromestatus.com/features/5070237827334144 for more details.
CONSOLE WARNING: '-webkit-appearance: menulist' for elements other than select and input[type=color][list] is deprecated and will be removed in M79, around December 2019. See https://www.chromestatus.com/features/5070237827334144 for more details.
CONSOLE WARNING: '-webkit-appearance: searchfield-cancel-button' for elements other than ::-webkit-clear-button and ::-webkit-search-cancel-button is deprecated and will be removed in M79, around December 2019. See https://www.chromestatus.com/features/5070237827334144 for more details.
<!DOCTYPE html> <!DOCTYPE html>
<html> <html>
<head> <head>
<script src="../resources/testharness.js"></script>
<script src="../resources/testharnessreport.js"></script>
<script src="../resources/run-after-layout-and-paint.js"></script>
<style> <style>
::-webkit-scrollbar { ::-webkit-scrollbar {
width: 16px; width: 16px;
...@@ -32,5 +35,10 @@ ...@@ -32,5 +35,10 @@
<body> <body>
PASS if not crashed. PASS if not crashed.
<div class="scroll-container"><div class="overflowing"></div></div> <div class="scroll-container"><div class="overflowing"></div></div>
<script>
async_test(t => {
runAfterLayoutAndPaint(t.step_func_done(() => {}));
}, 'Do not crash if -webkit-scrollbar* has -webkit-appearance:searchfield-cancel-button');
</script>
</body> </body>
</html> </html>
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment