Table of Contents

Class TwFlexItem

Namespace
TwBlazor.Components
Assembly
TwBlazor.dll

A child of a TwFlex that controls how it grows, shrinks and aligns: flex size, basis, its own cross-axis alignment, visual order and whether it pushes the items after it to the end.

public class TwFlexItem : TwLayoutComponentBase, IComponent, IHandleEvent, IHandleAfterRender, ITwComponent
Inheritance
TwFlexItem
Implements
Inherited Members

Remarks

Any element can be a child of a TwFlex; use TwFlexItem only when a child needs one of these settings.

Constructors

TwFlexItem()

public TwFlexItem()

Properties

AlignSelf

Gets or sets the item's own alignment on the cross axis, overriding the layout's.

[Parameter]
public AlignSelf? AlignSelf { get; set; }

Property Value

AlignSelf?

Basis

Gets or sets the item's starting size along the main axis, before free space is shared out.

[Parameter]
public FlexBasis? Basis { get; set; }

Property Value

FlexBasis?

Flex

Gets or sets how the item grows and shrinks, such as Fill to take an equal share of the free space.

[Parameter]
public FlexSize? Flex { get; set; }

Property Value

FlexSize?

Grow

Gets or sets whether the item may grow into free space. Leave it unset to keep the browser's choice.

[Parameter]
public bool? Grow { get; set; }

Property Value

bool?

MinWidthZero

Gets or sets whether the item may shrink below the width of its content, so long text inside it can wrap or truncate instead of overflowing.

[Parameter]
public bool MinWidthZero { get; set; }

Property Value

bool

Order

Gets or sets where the item is drawn, from 1 to 12, or First or Last. Only the visual order changes, so screen readers and the Tab key still follow the markup.

[Parameter]
public int? Order { get; set; }

Property Value

int?

PushEnd

Gets or sets whether the item, and every item after it, is pushed to the end of the layout: to the end of a row, or to the bottom of a column. The way it pushes follows the enclosing TwFlex's Direction.

[Parameter]
public bool PushEnd { get; set; }

Property Value

bool

Shrink

Gets or sets whether the item may shrink when space runs out. Leave it unset to keep the browser's choice.

[Parameter]
public bool? Shrink { get; set; }

Property Value

bool?

rootClasses

Gets the classes for the rendered element, with Class merged last.

protected override string rootClasses { get; }

Property Value

string