Skip to content

Add text-decoration-skip #242

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 4 commits into from
Dec 29, 2017
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions src/css/Properties.js
Original file line number Diff line number Diff line change
Expand Up @@ -435,6 +435,8 @@ var Properties = module.exports = {
"text-decoration-color" : "<text-decoration-color>",
"text-decoration-line" : "<text-decoration-line>",
"text-decoration-style" : "<text-decoration-style>",
"text-decoration-skip" : "none | [ objects || spaces || ink || edges || box-decoration ]",
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The formal syntax in English differs from the version on the Russian translation.

none | [ objects || [ spaces | [ leading-spaces || trailing-spaces ] ] || edges || box-decoration ]

Can you check which is more up2date?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes. I Update Formal Syntax. Get it in Specification

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Okay, MDN finally confused me =)
There are CSS Text Decoration Module Level 3 [CR] That has formal syntax none | [ objects || spaces || ink || edges || box-decoration ]

And CSS Text Decoration Module Level 4 [ED] with formal syntax none | [ objects || [ spaces | [ leading-spaces || trailing-spaces ] ] || edges || box-decoration ]

I Think, it will be better to to use [CR] formal syntax instead [ED] version

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ok, sounds good.

"-webkit-text-decoration-skip" : "none | [ objects || spaces || ink || edges || box-decoration ]",
"text-emphasis" : 1,
"text-height" : 1,
"text-indent" : "<length> | <percentage>",
Expand Down
38 changes: 38 additions & 0 deletions tests/css/Validation.js
Original file line number Diff line number Diff line change
Expand Up @@ -1488,6 +1488,44 @@ var YUITest = require("yuitest"),
}
}));

suite.add(new ValidationTestCase({
property: "text-decoration-skip",

valid: [
"none",
"objects",
"spaces",
"ink",
"edges",
"box-decoration",
"objects spaces ink"
],

invalid: {
"none objects" : "Expected end of value but found 'objects'.",
"foo" : "Expected (none | [ objects || spaces || ink || edges || box-decoration ]) but found 'foo'."
}
}));

suite.add(new ValidationTestCase({
property: "-webkit-text-decoration-skip",

valid: [
"none",
"objects",
"spaces",
"ink",
"edges",
"box-decoration",
"objects spaces ink"
],

invalid: {
"none objects" : "Expected end of value but found 'objects'.",
"foo" : "Expected (none | [ objects || spaces || ink || edges || box-decoration ]) but found 'foo'."
}
}));

suite.add(new ValidationTestCase({
property: "text-rendering",

Expand Down