Skip to content

Commit

Permalink
[css-values-5] Address cdoublev's review #10457
Browse files Browse the repository at this point in the history
  • Loading branch information
fantasai committed Nov 1, 2024
1 parent 34036bb commit 963fd9f
Showing 1 changed file with 8 additions and 7 deletions.
15 changes: 8 additions & 7 deletions css-values-5/Overview.bs
Original file line number Diff line number Diff line change
Expand Up @@ -224,8 +224,8 @@ Boolean Expression Multiplier <<boolean[]>></h3>

The <<boolean[]>> notation wraps another value type in the square brackets within it,
e.g. &lt;boolean[ &lt;test&gt; ]&gt;,
and represents that value alone as well as
boolean combinations of those values
and represents that value type alone as well as
boolean combinations
using the ''not'', ''and'', and ''or'' keywords
and grouping parenthesis.
It is formally equivalent to:
Expand All @@ -235,21 +235,22 @@ Boolean Expression Multiplier <<boolean[]>></h3>
[ [ and <boolean-group> ]*
| [ or <boolean-group> ]* ]

<boolean-group> = <test> | ( <boolean> ) | <general-enclosed>
<boolean-group> = <test> | ( <boolean[ <test> ]> ) | <general-enclosed>
</xmp>

The <<boolean[]>> production represents a true, false, or unknown value,
The <<boolean[]>> production represents a true, false, or unknown value.
Its value is resolved using 3-value Kleene logic,
with top-level unknown values
(those not directly nested inside the grammar of another <<boolean[]>>)
resolving to false unless otherwise specified.
Its value is resolved using 3-value Kleene logic;
resolving to false unless otherwise specified;
see [[#boolean-logic]] for details.

<div class=example>
For example, the ''@container'' rule allows a wide variety of tests:
including size queries, style queries, and scroll-state queries.
All of these are arbitrarily combinable with boolean logic.
Using <<boolean[]>>, the grammar for an ''@container'' query is:
Using <<boolean[]>>, the grammar for an ''@container'' query
could be written as:

<xmp class=prod>
<container-query> = <boolean[ <cq-test> ]>
Expand Down

0 comments on commit 963fd9f

Please sign in to comment.