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

JIT: Add exhaustive pseudo-class and pseudo-element variant support #4482

Merged
merged 6 commits into from
May 27, 2021

Conversation

adamwathan
Copy link
Member

@adamwathan adamwathan commented May 26, 2021

This PR adds support for the following new variants to the JIT engine:

  • first-letter
  • first-line
  • marker
  • selection
  • only (only-child)
  • first-of-type
  • last-of-type
  • only-of-type
  • target
  • default
  • indeterminate
  • placeholder-shown
  • autofill
  • required
  • valid
  • invalid
  • in-range
  • out-of-range

I've left out a few pseudo-classes that either have very poor or non-existent browser support, or just don't seem useful because of how Tailwind works. If we're missing anything anyone actually needs though happy to add support since there isn't really any cost.

This was referenced May 26, 2021
@surjithctly
Copy link

surjithctly commented May 27, 2021

Please add support for :not and ~

 :not(:placeholder-shown):invalid ~ .feedback {
…
}

Use case: Form Validation.
Demo: https://tailwindcomponents.com/component/contact-form-popup-widget

Thank you:

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

Successfully merging this pull request may close these issues.

3 participants