Skip to content

Add arbitrary-variants section in arbitrary-values#1378

Merged
adamwathan merged 2 commits intotailwindlabs:masterfrom
Sleepful:master
Oct 14, 2022
Merged

Add arbitrary-variants section in arbitrary-values#1378
adamwathan merged 2 commits intotailwindlabs:masterfrom
Sleepful:master

Conversation

@Sleepful
Copy link

@Sleepful Sleepful commented Oct 7, 2022

When reading the section on arbitrary variants it is difficult to know that there are documents for arbitrary variants, which are very relevant. arbitrary variants are a little hidden, under a title that doesn't mention anything about CSS selectors, therefore this PR: Adds a link to the related content.

I added this right after ### Arbitrary properties because it is almost as essential, and I added it before ### Handling whitespace given that white space is a CSS selector and the order of question tends to be:

  1. How do I add a custom selector?
  2. How do I add the specific white space (descendant) selector?

@vercel
Copy link

vercel bot commented Oct 7, 2022

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Updated
tailwindcss-com ✅ Ready (Inspect) Visit Preview Oct 14, 2022 at 1:23PM (UTC)


### Arbitrary variants

In the same vein as arbitrary values, **arbitrary variants** allow you to write custom CSS selector modifiers, please refer to [arbitrary variants](/docs/hover-focus-and-other-states#using-arbitrary-variants).
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I added the bold here because it's easy to gloss over the words given how similar they are to arbitrary values.

@adamwathan
Copy link
Member

Thanks! Made a couple of tweaks but I think it's good to surface this here for sure.

@adamwathan adamwathan merged commit f29b64e into tailwindlabs:master Oct 14, 2022
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.

2 participants