FlowLayout class
A layout that spreads elements horizontally and wraps them across multiple rows, as needed.
Constructors
| Flow |
Properties
| column |
The space between items. |
| horizontal |
Controls how the content of the container should be horizontally aligned. |
| item |
Controls how item should fit inside the container. |
| item |
The width, in pixels, of each item, in the |
| max |
The maximum width, in pixels, of each item, in the |
| min |
The minimum width, in pixels, of each item, in the |
| row |
The space between rows of items. |
| target |
Controls for which card width the layout should be used. |
| type | Must be Layout.Flow. |
| vertical |
Controls how the content of the container should be vertically aligned. |
Methods
Constructor Details
FlowLayout(FlowLayoutOptions)
Property Details
columnSpacing
horizontalItemsAlignment
Controls how the content of the container should be horizontally aligned.
horizontalItemsAlignment?: HorizontalAlignment
Property Value
itemFit
Controls how item should fit inside the container.
itemFit?: FlowLayoutItemFit
Property Value
itemWidth
The width, in pixels, of each item, in the <number>px format. Should not be used if maxItemWidth and/or minItemWidth are set.
itemWidth?: string
Property Value
string
maxItemWidth
The maximum width, in pixels, of each item, in the <number>px format. Should not be used if itemWidth is set.
maxItemWidth?: string
Property Value
string
minItemWidth
The minimum width, in pixels, of each item, in the <number>px format. Should not be used if itemWidth is set.
minItemWidth?: string
Property Value
string
rowSpacing
targetWidth
Controls for which card width the layout should be used.
targetWidth?: TargetWidth
Property Value
type
Must be Layout.Flow.
type: "Layout.Flow" = "Layout.Flow"
Property Value
"Layout.Flow"
verticalItemsAlignment
Controls how the content of the container should be vertically aligned.
verticalItemsAlignment?: VerticalAlignment
Property Value
Method Details
from(Omit<IFlowLayout, "type">)
static function from(options: Omit<IFlowLayout, "type">): FlowLayout
Parameters
- options
-
Omit<IFlowLayout, "type">
Returns
withColumnSpacing(Spacing)
function withColumnSpacing(columnSpacing: Spacing): FlowLayout
Parameters
- columnSpacing
- Spacing
Returns
withHorizontalItemsAlignment(HorizontalAlignment)
function withHorizontalItemsAlignment(horizontalItemsAlignment: HorizontalAlignment): FlowLayout
Parameters
- horizontalItemsAlignment
- HorizontalAlignment
Returns
withItemFit(FlowLayoutItemFit)
function withItemFit(itemFit: FlowLayoutItemFit): FlowLayout
Parameters
- itemFit
- FlowLayoutItemFit
Returns
withItemWidth(string)
function withItemWidth(itemWidth: string): FlowLayout
Parameters
- itemWidth
-
string
Returns
withMaxItemWidth(string)
function withMaxItemWidth(maxItemWidth: string): FlowLayout
Parameters
- maxItemWidth
-
string
Returns
withMinItemWidth(string)
function withMinItemWidth(minItemWidth: string): FlowLayout
Parameters
- minItemWidth
-
string
Returns
withRowSpacing(Spacing)
withTargetWidth(TargetWidth)
function withTargetWidth(targetWidth: TargetWidth): FlowLayout
Parameters
- targetWidth
- TargetWidth
Returns
withVerticalItemsAlignment(VerticalAlignment)
function withVerticalItemsAlignment(verticalItemsAlignment: VerticalAlignment): FlowLayout
Parameters
- verticalItemsAlignment
- VerticalAlignment