Skip to content
Open
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
25 changes: 23 additions & 2 deletions css-values-4/Overview.bs
Original file line number Diff line number Diff line change
Expand Up @@ -1153,7 +1153,7 @@ URL Processing Model</h4>
1. If |cssRuleOrDeclaration| is a [=CSS declaration block=] whose [=parent CSS rule=] is not null,
set |cssRuleOrDeclaration| to |cssRuleOrDeclaration|'s [=parent CSS rule=].

1. If |cssRuleOrDeclaration| is a [=CSS rule=], set |sheet| to |cssRuleOrDeclaration|'s {{CSSRule/parentStyleSheet|parent style sheet}}</a>.
1. If |cssRuleOrDeclaration| is a [=CSS rule=], set |sheet| to |cssRuleOrDeclaration|'s {{CSSRule/parentStyleSheet|parent style sheet}}.

1. If |sheet| is not null:
1. If |sheet|'s <a spec=cssom>stylesheet base URL</a> is not null,
Expand Down Expand Up @@ -4906,7 +4906,28 @@ Simplification</h4>
(0 - value).
2. If |root|'s child is a Negate node,
return the child's child.
3. Return |root|.
3. If |root|'s child is a Sum node:

1. Let |negated grandchildren| be an empty list

2. For each |grandchild| of the child's children:

1. If |grandchild| is a numeric value,
create an equivalent numeric value,
but with the value negated
(0 - value),
and append the result to |negated grandchildren|.

2. If |grandchild| is a Negate node
append |grandchild|'s child to |negated grandchildren|

3. Otherwise,
create a Negate node with |grandchild| as its child,
and append the result to |negated grandchildren|

3. Return a Sum node with |negated grandchildren| as its children

4. Return |root|.

7. If |root| is an Invert node:

Expand Down