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

add support for optimizing the CSS :has / :is pseudo-selectors #1106

Closed
Tracked by #1120
thescientist13 opened this issue May 5, 2023 · 0 comments · Fixed by #1107
Closed
Tracked by #1120

add support for optimizing the CSS :has / :is pseudo-selectors #1106

thescientist13 opened this issue May 5, 2023 · 0 comments · Fixed by #1107
Assignees
Labels
Milestone

Comments

@thescientist13
Copy link
Member

thescientist13 commented May 5, 2023

Type of Change

Feature

Summary

The CSS :has psuedo-selector is neat new CSS feature (almost*) available in all browsers and can [come in pretty handy]
(https://twitter.com/wesbos/status/1653401308022607874?s=43&t=23JfvPjOIJyZ9W8iFiZYyg).
https://www.smashingmagazine.com/2023/01/level-up-css-skills-has-selector/

/* Selects an h1 heading with a
paragraph element that immediately follows
the h1 and applies the style to h1 */
h1:has(+ p) {
  margin-bottom: 0;
}

It is still outstanding in FF but will be coming soon but it is a standard now, so no harm in supporting it in Greenwood
https://caniuse.com/css-has
Screen Shot 2023-05-05 at 7 44 48 PM

Details

So will just need to add support for this in our CSS resource plugin and add a test case.

@thescientist13 thescientist13 added the feature New feature or request label May 5, 2023
@thescientist13 thescientist13 added this to the 1.0 milestone May 5, 2023
@thescientist13 thescientist13 self-assigned this May 5, 2023
@thescientist13 thescientist13 changed the title add support for optimizing the CSS :has psuedo-selector add support for optimizing the CSS :has pseudo-selector May 5, 2023
@thescientist13 thescientist13 moved this from 🏗 In progress to 👀 In review in [Greenwood] Phase 9 - Standards and Conventions May 6, 2023
@thescientist13 thescientist13 mentioned this issue Jun 29, 2023
25 tasks
@thescientist13 thescientist13 changed the title add support for optimizing the CSS :has pseudo-selector add support for optimizing the CSS :has / :is pseudo-selectora Nov 4, 2023
@thescientist13 thescientist13 changed the title add support for optimizing the CSS :has / :is pseudo-selectora add support for optimizing the CSS :has / :is pseudo-selectors Nov 4, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
No open projects
Development

Successfully merging a pull request may close this issue.

1 participant