space-y upgrade #14322
Replies: 2 comments 2 replies
-
I wonder if instead, there could be a distinct CSS layer for "mass-utilities" like Conceptually, I consider an utility like "space-y" to be a custom default value we want for the children. While I consider "mt" to be a specific value that we want in a specific location. But since the selector for In my solution, "mass-utilities" would be a different layer (earlier than "utilities"), and therefore would be overwritten by regular utilities. I feel this behavior would be a lot more intuitive andn flexible without needing tons of variables for every variations. "mass-utilities" may not be the best name, maybe "delegated-utilities" or "descendant-utilities"? Since 4.0 is being worked on right now, this would be a great time to add this feature since this is technically a breaking change if someone had a useless |
Beta Was this translation helpful? Give feedback.
-
Interesting, reading this https://tailwindcss.com/blog/tailwindcss-v4-alpha, I learned that Tailwind doesn't use actual CSS layers! 4.0 is changing that, so what I suggested wasn't possible before. @adamwathan: Any thoughts on this distinct "mass-utilities" CSS layer idea? |
Beta Was this translation helpful? Give feedback.
-
I would like to suggest an upgrade to the classes space-y and space-x, useful to override the margin on a single element
I use to define it like this:
Then i use it like this:
Beta Was this translation helpful? Give feedback.
All reactions