Skip to content
Merged
Show file tree
Hide file tree
Changes from 2 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 | skip",
"text-emphasis" : 1,
"text-height" : 1,
"text-indent" : "<length> | <percentage>",
Expand Down
36 changes: 36 additions & 0 deletions tests/css/Validation.js
Original file line number Diff line number Diff line change
Expand Up @@ -1488,6 +1488,42 @@ var YUITest = require("yuitest"),
}
}));

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

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

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

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

valid: [
"none",
"skip"
],

invalid: {
"skip foo" : "Expected end of value but found 'foo'.",
"foo" : "Expected (none | skip) but found 'foo'."
}
}));

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

Expand Down