You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[selectors-4] Case-insensitive health warning #13645
To match attribute values ASCII case-insensitively regardless of document language rules, the attribute selector may include the identifier i before the closing bracket (]). When this flag is present, UAs must match the attribute’s value ASCII case-insensitively (i.e. [a-z] and [A-Z] are considered equivalent).
Alternately, the attribute selector may include the identifier s before the closing bracket (]); in this case the UA must match the value case-sensitively, with “identical to” semantics [INFRA], regardless of document language rules.
The text about case insensitive (ASCII case fold) matching probably should have some sort of prominent health warning so that users understand this is only an ASCII case fold.
@aphillips sorry to be obtuse but what are we missing here? It seems simple and obvious to us, and the ASCII case-insensitively is used all over CSS specifications.
The challenge here is that ASCII case-insensitivity is quirky wrt CSS. Usually ASCII case-insensitivity is used where the value space is also limited to ASCII. But attribute values are not limited in this way. So green matches GREEN but grün doesn't match GRÜN (it does, however, match GRüN). The "ASCII" decoration of the case matching scheme normatively means this and most of us who have been around CSS know about this, but newcomers may be surprised.
Activity
svgeesus commentedon Mar 12, 2026
Isn't the name ASCII case-insensitively already a strong indication that this folds the ASCII range only? Even before one follows the link and reads:
and
svgeesus commentedon Mar 12, 2026
svgeesus commentedon Mar 12, 2026
tabatkins commentedon Mar 12, 2026
I'm also not sure how a warning could provide more 'this is ASCII' information than the 'ASCII' already in the name of the operation.
svgeesus commentedon Mar 12, 2026
@aphillips sorry to be obtuse but what are we missing here? It seems simple and obvious to us, and the
ASCII case-insensitivelyis used all over CSS specifications.aphillips commentedon Mar 12, 2026
The challenge here is that ASCII case-insensitivity is quirky wrt CSS. Usually ASCII case-insensitivity is used where the value space is also limited to ASCII. But attribute values are not limited in this way. So
greenmatchesGREENbutgründoesn't matchGRÜN(it does, however, matchGRüN). The "ASCII" decoration of the case matching scheme normatively means this and most of us who have been around CSS know about this, but newcomers may be surprised.svgeesus commentedon Mar 13, 2026
Okay, so an example illustrating that would be helpful.
[selectors] Add example showing the difference between general case-i…
svgeesus commentedon Mar 31, 2026
@aphillips does this example address your concern?
aphillips commentedon Mar 31, 2026
@svgeesus asked:
Thanks, it does.