w3c / w3c/csswg-drafts

[selectors-4] Clarify :blank application to radio buttons etc.

Open
#3,339 4 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

selectors-4
Dominant language
Bikeshed
Stars
4.9k
Forks
816
PR merge metrics
PR metrics pending

Description

Andrew Fedoniouk points out that it's not entirely clear whether/how :blank applies to radio buttons etc.
https://lists.w3.org/Archives/Public/www-style/2018Nov/0028.html
We should clarify this. Some options are:

  • :blank checks the 'value' on radio buttons and checkboxes; :not(:blank) effectively always applies
    -:not(:blank) applies when a radio button or checkbox is has a non-blank 'value' and is checked (will submit if not disabled); :blank applies otherwise
  • :blank applies to each input element in a group when no radio button or checkbox in its group is checked

Probably the most simple definition is 1; it largely falls out of the existing definition. However the last definition is perhaps more useful. It would be good to hear from authors here what they expect.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reading this issue and the linked www-style discussion to understand the competing interpretations of :blank for radio buttons and checkboxes. Resolve which behavior authors and the specification should adopt, then update the relevant editor-draft text so the rule is explicit.

Written by the indexing model from the issue text.

Assessment

Tech stack
css
Domain
documentation
Issue type
Documentation
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.