Expand description
Utilities for setting the maximum height of an element.
| Class | Properties |
|---|---|
| max-h-<float> | max-height: <float / 4>rem; |
| max-h-<integer>/<integer> | max-height: (<integer>/<integer>)%; |
| max-h-px | max-height: 1px; |
| max-h-none | max-height: none; |
| max-h-full | max-height: 100%; |
| max-h-auto | max-height: auto; |
| max-h-screen | max-height: 100vh; |
| max-h-min | max-height: min-content; |
| max-h-max | max-height: max-content; |
| max-h-fit | max-height: fit-content; |
| max-h-svh | max-height: 100svh; |
| max-h-lvh | max-height: 100lvh; |
| max-h-dvh | max-height: 100dvh; |
§Tailwind compatibility
Maximum height values don’t follow Tailwind’s philosophy of limiting possible values and all spacing values are supported. They are however perfectly compatible with Tailwind’s values.
§Arbitrary values
Any <length> or <percentage> property is allowed as arbitrary value.
For example, max-h-[3rem].