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

:focus-within sometimes gives an invalid selector warning #51

Closed
ip1981 opened this issue Feb 6, 2020 · 0 comments
Closed

:focus-within sometimes gives an invalid selector warning #51

ip1981 opened this issue Feb 6, 2020 · 0 comments

Comments

@ip1981
Copy link

ip1981 commented Feb 6, 2020

The pseudo-class :focus-within sometimes gives an invalid selector warning.

For example, this code .group:focus-within .group-focus\:block {...} produces:

  .group:focus-within .group-focus\ -> '.group:focus-within .group-focus\' is not a valid selector

I doubt that any class with :focus-within will ever be used in critical CSS, but those warnings create some noise. A workaround if to set logLevel to "error".

This issue probably causes #47.

On the other side, I am sure some simple selectors like foo::focus-within are accepted.

alan-agius4 added a commit to alan-agius4/critters that referenced this issue Dec 14, 2020
At the moment critters doesn't correctly handle pseudo-class in the middle of the selector string and pseudo-class which take a value such as `:not`

Example
```
.mat-slider:hover .mat-slider-track-background
.mat-slider-min-value:not(.mat-slider-thumb-label-showing):hover.mat-slider-disabled .mat-slider-thumb
```

More context about CSS pseudo-classes can be found https://developer.mozilla.org/en-US/docs/Web/CSS/Pseudo-classes

Closes GoogleChromeLabs#51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant