File tree Expand file tree Collapse file tree 1 file changed +7
-0
lines changed Expand file tree Collapse file tree 1 file changed +7
-0
lines changed Original file line number Diff line number Diff line change @@ -1669,6 +1669,13 @@ Type Checking</h4>
1669
1669
(''cm'' is <<length>> , ''deg'' is <<angle>> , etc.).
1670
1670
An ''attr()'' expression's type is given by its <<type-or-unit>> argument.
1671
1671
1672
+ Note: Because <<number-token>> s are always interpreted as <<number>> s or <<integer>> s,
1673
+ "unitless 0" <<length>> s or <<angle>> s aren't supported in ''calc()'' .
1674
+ That is, ''width: calc(0 + 5px);'' is invalid,
1675
+ even though both ''width: 0;''
1676
+ and ''width: 5px;''
1677
+ are valid.
1678
+
1672
1679
If percentages are accepted in the context in which the expression is placed,
1673
1680
a <<percentage-token>> has the type of the value that percentages are relative to.
1674
1681
For example, in the 'width' property, percentages have the <<length>> type,
You can’t perform that action at this time.
0 commit comments