[go: nahoru, domu]

Skip to content

Commit

Permalink
fix implicit defaulting of ‘color’ at :root (w3c#6774)
Browse files Browse the repository at this point in the history
  • Loading branch information
delan committed Apr 15, 2022
1 parent 4e4fb90 commit ce77850
Showing 1 changed file with 5 additions and 17 deletions.
22 changes: 5 additions & 17 deletions css-pseudo-4/Overview.bs
Original file line number Diff line number Diff line change
Expand Up @@ -704,12 +704,6 @@ Styling Highlights</h3>
like 'fill-color'
must not be treated as highlight colors.

The 'color' property specifies the color of both the text
and all line decorations (underline, overline, line-through)
and emphasis marks ('text-emphasis')
applied to the text
by the <a>originating element</a> and its ancestors and descendants.

<!-- Add this back if for some reason someone wants to implement 'outline'?
The outline, if supported, must be drawn
around the union of the active portions of the <a>highlight overlay</a>
Expand Down Expand Up @@ -740,17 +734,6 @@ Default UA Styles</h3>
and doing so is recommended
for ''::selection'' and ''::target-text''.

Otherwise,
the default highlight colors for that highlight must be
'currentColor' (<em>not</em> 'initial' or 'inherit')
and 'transparent' respectively.
In other words,
when the UA doesn’t define default highlight colors
for a given highlight,
highlighted content retains the 'color'
that would otherwise have been used
without that highlight.

Note: the painting behavior of highlight colors
means that default highlight colors
can't be expressed in terms of 'color' and 'background-color'
Expand Down Expand Up @@ -827,6 +810,11 @@ Cascading and Per-Element Highlight Styles</h3>
of its <a>originating element</a>'s parent element
(regardless of whether that property is an <a>inherited property</a>).

For the root element,
the [=inherited value=] of 'color'
is ''currentColor'',
not the [=initial value=].

<wpt>
css/css-pseudo/active-selection-051.html
css/css-pseudo/active-selection-052.html
Expand Down

0 comments on commit ce77850

Please sign in to comment.