Open Bug 1106296 Opened 10 years ago Updated 1 month ago

Update `:empty` to also match whitespace‑only elements (like `:-moz-only-whitespace`)

Categories

(Core :: CSS Parsing and Computation, enhancement)

enhancement

Tracking

()

ASSIGNED

People

(Reporter: sjw+bugzilla, Assigned: dshin)

References

(Blocks 2 open bugs, )

Details

(Keywords: dev-doc-needed, site-compat)

Attachments

(1 obsolete file)

We already have :-moz-only-whitespace and we should also support the standardized pseudo-class :blank.
At the moment it's not sure, if :blank will be the final name.
Today the group resolved to drop :blank and change :empty to be like :blank, although I'm skeptical that this will be Web-compatible.  We should do this after Blink does it, but I don't think it's worth risking Web compat on before they move first.
Keywords: site-compat
We should probably do this sooner, rather than later, as `:blank` is now documented on MDN with support for `:‑moz‑only‑whitespace` being documented in the browser compatibility table.

https://developer.mozilla.org/docs/Web/CSS/:blank
https://github.com/mdn/browser-compat-data/pull/2841
https://github.com/mdn/data/pull/298
Type: defect → enhancement
Summary: Support the standardized version of :-moz-only-whitespace (:blank) → Update `:empty` to also match whitespace‑only elements (like `:-moz-only-whitespace`)
See Also: → 1197736
Severity: normal → S3
See Also: → 1847072

This merges -moz-only-whitespace, which had this behaviour already, into empty.

Assignee: nobody → dshin
Status: NEW → ASSIGNED

Looking through https://github.com/w3c/csswg-drafts/issues/1967, it's not clear to me that there's any firm agreement on this.... has there been recent discussion, beyond what's in that issue? What's the status in other browsers?

Flags: needinfo?(dshin)

Hmm... you're right. Should've gone through all the link before trying to follow the spec.
No other browsers currently do this.
I'll shelve the change and contribute to that discussion.

Flags: needinfo?(dshin)
Attachment #9349583 - Attachment is obsolete: true
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: