2018-02-13 03:50:31 -08:00
|
|
|
---
|
2018-02-19 02:55:30 -08:00
|
|
|
path: "/docs/min-max"
|
2018-02-13 03:50:31 -08:00
|
|
|
title: "Max / Min Width and Height"
|
|
|
|
hasPlayground: true
|
|
|
|
---
|
|
|
|
|
2018-02-14 07:53:07 -08:00
|
|
|
## Max / Min Width and Height
|
|
|
|
|
2018-02-16 06:41:54 -08:00
|
|
|
All the following properties set the maximum and minimum size constraints of an element.
|
|
|
|
These properties have higher priority than all other properties and will always be respected.
|
|
|
|
Constraints can be specified as either absolute pixel values or as percentages of their
|
2018-02-16 06:41:56 -08:00
|
|
|
parent's size. By default all these constraints are `undefined`.
|
2018-02-16 06:41:54 -08:00
|
|
|
|
2018-02-15 06:12:16 -08:00
|
|
|
### Max Width
|
2018-02-14 07:53:07 -08:00
|
|
|
|
2018-02-16 06:41:54 -08:00
|
|
|
<controls prop="maxWidth"></controls>
|
2018-02-14 07:53:07 -08:00
|
|
|
|
2018-02-15 06:12:16 -08:00
|
|
|
### Min Width
|
|
|
|
|
2018-02-16 06:41:54 -08:00
|
|
|
<controls prop="minWidth"></controls>
|
2018-02-15 06:12:16 -08:00
|
|
|
|
|
|
|
### Max Height
|
|
|
|
|
2018-02-16 06:41:54 -08:00
|
|
|
<controls prop="maxHeight"></controls>
|
2018-02-15 06:12:16 -08:00
|
|
|
|
2018-03-01 05:55:18 -08:00
|
|
|
### Min Height
|
2018-02-15 06:12:16 -08:00
|
|
|
|
|
|
|
<controls prop="minHeight"></controls>
|