Replies: 3 comments 5 replies
|
Can you give a real world example of where you'd need this? Not opposed to adding it if there's a good practical use case 👍 |
5 replies
|
For anyone wondering how to do it in 2026, you just need to add a new @utility max-size-* {
max-width: calc(--value(number) * var(--spacing));
max-height: calc(--value(number) * var(--spacing));
}
@utility min-size-* {
min-width: calc(--value(number) * var(--spacing));
min-height: calc(--value(number) * var(--spacing));
} |
0 replies
|
Ran into a scenario today where I needed both <div className="aspect-portrait min-h-full w-full min-w-full">
...
</div> |
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment

Uh oh!
There was an error while loading. Please reload this page.
Referencing the discussion about
size-[*]utility classIt would be convenient to use
min-sizeandmax-sizein addition to just using size.Comparison: min-h, max-h, min-w, max-w VS min-size & max-size
All reactions