Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CustomStateSet doc: Add feature detection for :state pseudo-class and browser compatibility warning #33656

Merged
merged 4 commits into from
May 19, 2024

Conversation

minimalsm
Copy link
Contributor

@minimalsm minimalsm commented May 17, 2024

Description

Added feature detection for the :state CSS pseudo-class and provided a warning message if the browser does not support this syntax.

Motivation

The current syntax isn't supported in Chrome browsers yet, and although Chrome 125 is adding support, there will be a transition period where I suspect the majority of readers will be using an incompatible browser.

Additional details

Per @hamishwillee's comment in 33636:

Closing this, but if you wanted we'd accept a PR that modifies the examples to check for support of the new state syntax and put a "not supported by this browser warning" when the examples don't work.

Related issues and pull requests

@github-actions github-actions bot added Content:WebAPI Web API docs size/s 6-50 LoC changed labels May 17, 2024
Copy link
Contributor

github-actions bot commented May 17, 2024

Preview URLs

(comment last updated: 2024-05-17 10:01:36)

@github-actions github-actions bot added size/m 51-500 LoC changed and removed size/s 6-50 LoC changed labels May 17, 2024
files/en-us/web/api/customstateset/index.md Outdated Show resolved Hide resolved
files/en-us/web/api/customstateset/index.md Outdated Show resolved Hide resolved
files/en-us/web/api/customstateset/index.md Outdated Show resolved Hide resolved
files/en-us/web/api/customstateset/index.md Outdated Show resolved Hide resolved
files/en-us/web/api/customstateset/index.md Outdated Show resolved Hide resolved
files/en-us/web/api/customstateset/index.md Outdated Show resolved Hide resolved
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
@minimalsm minimalsm changed the title Update state examples CustomStateSet doc: Add feature detection for :state pseudo-class and browser compatibility warning May 17, 2024
@minimalsm minimalsm marked this pull request as ready for review May 17, 2024 10:14
@minimalsm minimalsm requested a review from a team as a code owner May 17, 2024 10:14
@minimalsm minimalsm requested review from sideshowbarker and removed request for a team May 17, 2024 10:14
@sideshowbarker sideshowbarker merged commit 08dfcad into mdn:main May 19, 2024
8 checks passed
@hamishwillee
Copy link
Collaborator

Thank you.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Content:WebAPI Web API docs size/m 51-500 LoC changed
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants