mirror of
https://github.com/LadybirdBrowser/ladybird
synced 2026-04-26 17:55:07 +02:00
LibWeb: Implement text-wrap-style CSS property
This commit is contained in:
Notes:
github-actions[bot]
2025-06-04 11:49:41 +00:00
Author: https://github.com/Calme1709 Commit: https://github.com/LadybirdBrowser/ladybird/commit/9ba74316d2e Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/4943 Reviewed-by: https://github.com/AtkinsSJ ✅
@@ -0,0 +1,21 @@
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<title>CSS Text: getComputedStyle().textWrapStyle</title>
|
||||
<link rel="author" title="Tim Nguyen" href="https://github.com/nt1m">
|
||||
<link rel="help" href="https://drafts.csswg.org/css-text-4/#text-wrap-style">
|
||||
<meta name="assert" content="text-wrap-style computed value is auto | balance | pretty | stable">
|
||||
<script src="../../../resources/testharness.js"></script>
|
||||
<script src="../../../resources/testharnessreport.js"></script>
|
||||
<script src="../../../css/support/computed-testcommon.js"></script>
|
||||
</head>
|
||||
<body>
|
||||
<div id="target"></div>
|
||||
<script>
|
||||
test_computed_value("text-wrap-style", "auto");
|
||||
test_computed_value("text-wrap-style", "balance");
|
||||
test_computed_value("text-wrap-style", "stable");
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
||||
@@ -0,0 +1,29 @@
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<title>CSS Text Module Test: parsing text-wrap-style with invalid values</title>
|
||||
<link rel="author" title="Tim Nguyen" href="https://github.com/nt1m">
|
||||
<link rel="help" href="https://drafts.csswg.org/css-text-4/#text-wrap-style">
|
||||
<meta name="assert" content="text-wrap-style supports only the grammar '<text-wrap-style>'.">
|
||||
<script src="../../../resources/testharness.js"></script>
|
||||
<script src="../../../resources/testharnessreport.js"></script>
|
||||
<script src="../../../css/support/parsing-testcommon.js"></script>
|
||||
</head>
|
||||
<body>
|
||||
<script>
|
||||
test_invalid_value("text-wrap-style", "normal");
|
||||
test_invalid_value("text-wrap-style", "none");
|
||||
test_invalid_value("text-wrap-style", "wrap");
|
||||
test_invalid_value("text-wrap-style", "nowrap");
|
||||
test_invalid_value("text-wrap-style", "wrap wrap");
|
||||
test_invalid_value("text-wrap-style", "nowrap nowrap");
|
||||
test_invalid_value("text-wrap-style", "wrap nowrap");
|
||||
test_invalid_value("text-wrap-style", "pretty balance");
|
||||
test_invalid_value("text-wrap-style", "balance stable");
|
||||
test_invalid_value("text-wrap-style", "stable pretty");
|
||||
test_invalid_value("text-wrap-style", "delicious wrap");
|
||||
test_invalid_value("text-wrap-style", "5px");
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
||||
@@ -0,0 +1,26 @@
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<title>CSS Text Module Test: parsing text-wrap-style with valid values</title>
|
||||
<link rel="author" title="Tim Nguyen" href="https://github.com/nt1m">
|
||||
<link rel="help" href="https://drafts.csswg.org/css-text-4/#text-wrap-style">
|
||||
<meta name="assert" content="text-wrap-style supports the full grammar.">
|
||||
<script src="../../../resources/testharness.js"></script>
|
||||
<script src="../../../resources/testharnessreport.js"></script>
|
||||
<script src="../../../css/support/parsing-testcommon.js"></script>
|
||||
</head>
|
||||
<body>
|
||||
<script>
|
||||
test_valid_value("text-wrap-style", "auto");
|
||||
test_valid_value("text-wrap-style", "balance");
|
||||
test_valid_value("text-wrap-style", "stable");
|
||||
|
||||
test_valid_value("text-wrap-style", "initial");
|
||||
test_valid_value("text-wrap-style", "inherit");
|
||||
test_valid_value("text-wrap-style", "unset");
|
||||
test_valid_value("text-wrap-style", "revert");
|
||||
test_valid_value("text-wrap-style", "revert-layer");
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
||||
Reference in New Issue
Block a user