Closed Bug 1121792 Opened 10 years ago Closed 2 years ago

[selectors4] support wildcard (*) argument to :lang() selector and add support for string arguments

Categories

(Core :: CSS Parsing and Computation, defect)

x86_64
Linux
defect

Tracking

()

RESOLVED FIXED
114 Branch
Tracking Status
firefox114 --- fixed

People

(Reporter: dbaron, Assigned: jfkthame)

References

Details

(Keywords: dev-doc-complete)

Attachments

(6 files)

Selectors level 4 adds support for wildcards (*) in the :lang() selector, with reference to RFC4647 language matching. We should probably implement this, and **at the same time** add support for string arguments to :lang(). http://dev.w3.org/csswg/selectors/#the-lang-pseudo https://lists.w3.org/Archives/Public/www-style/2015Jan/0269.html (minutes of meeting, not yet reflected in draft, where WG agreed that argument should either be ident or quoted string)
Severity: normal → S3

This is a Selectors-4 enhancement to the spec for the :lang() pseudo-class.
It seems Safari has been shipping this behavior for some time.

Assignee: nobody → jfkthame
Status: NEW → ASSIGNED

This is the other extension to the :lang() pseudo-class in Selectors-4.
(Also supported in Safari.)

Depends on D174999

Keywords: dev-doc-needed

This allows to clean-up the previous patches by using a single ThinVec
(which stores length / capacity along with the allocation).

Pushed by jkew@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/e535870263d8 Use more complete BCP47/RFC4647 language-range matching rather than simple prefix-dash match for the :lang() pseudo. r=emilio https://hg.mozilla.org/integration/autoland/rev/2e4e3ae6cddd Accept a comma-separated list of language codes in the :lang() pseudo. r=emilio https://hg.mozilla.org/integration/autoland/rev/be24fa5c3e70 Add WPT tests for enhanced :lang() pseudo in css-selectors-4. r=emilio https://hg.mozilla.org/integration/autoland/rev/9726f4b6035a Split document-metadata/the-meta-element/http-equiv-and-name.html into separate tests for color-scheme and lang, using a valid value for each. r=emilio https://hg.mozilla.org/integration/autoland/rev/195d689a6b12 Update selectors/i18n/css3-selectors-lang-014.html because in Selectors 4, :lang() tag matching uses RFC4647 filtering rather than just a prefix match. r=emilio https://hg.mozilla.org/integration/autoland/rev/879211a561cc Allow to use ThinVec/nsTArray in the style crate. r=jfkthame,layout-reviewers
Created web-platform-tests PR https://github.com/web-platform-tests/wpt/pull/39501 for changes under testing/web-platform/tests
Regressions: 1827689

Please also check this crashes "[@ style::gecko_string_cache::WeakAtom::as_slice]" and this xpcshell failures.

Upstream PR was closed without merging
Attachment #9327754 - Attachment description: Bug 1121792 - Allow to use ThinVec/nsTArray in the style crate. r=#style,#layout,jfkthame → Bug 1121792 - Allow to use ThinVec/nsTArray in the style crate. r=jfkthame
Flags: needinfo?(jfkthame)
Pushed by ealvarez@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/b340f31925aa Use more complete BCP47/RFC4647 language-range matching rather than simple prefix-dash match for the :lang() pseudo. r=emilio https://hg.mozilla.org/integration/autoland/rev/95817aa93cfb Accept a comma-separated list of language codes in the :lang() pseudo. r=emilio https://hg.mozilla.org/integration/autoland/rev/bc74ba399e3a Add WPT tests for enhanced :lang() pseudo in css-selectors-4. r=emilio https://hg.mozilla.org/integration/autoland/rev/44278aa68c6a Split document-metadata/the-meta-element/http-equiv-and-name.html into separate tests for color-scheme and lang, using a valid value for each. r=emilio https://hg.mozilla.org/integration/autoland/rev/f1dcf4173070 Update selectors/i18n/css3-selectors-lang-014.html because in Selectors 4, :lang() tag matching uses RFC4647 filtering rather than just a prefix match. r=emilio
Pushed by ealvarez@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/95df5b6a464f Allow to use ThinVec/nsTArray in the style crate. r=jfkthame,layout-reviewers
Upstream PR merged by moz-wptsync-bot

Documentation changes can be tracked in the following GitHub issue: https://github.com/mdn/content/issues/26688

This might have caused bug 1839747, PTAL.

Regressions: 1848491
Regressions: 1857742
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: