Skip to content
IzzyBlazor 0.1.0-alpha.17

Enter all results ↑ ↓ move Esc close

TextField

A labeled text input with add-ons and a password reveal.

IzzyBlazor.TextField in the IzzyBlazor.Core package, generated from the 0.1.0-alpha.17 assembly and its doc comments.

Properties (14)

ReadOnlybool = falseAdded in 0.1.0-alpha.13

Makes the field read-only: it can be focused and its text selected, and it still posts.

TypeTextFieldType?

The kind of text. Defaults from the model: [EmailAddress], [Phone], [Url], [DataType(DataType.Password)]; otherwise text.

Placeholderstring?

Example text shown when empty. Not a substitute for a label.

AutoCompletestring?

The browser autofill hint, such as email, name, new-password.

MaxLengthint? (computed)

Maximum length. Defaults to [StringLength] or [MaxLength].

MinLengthint? (computed)

Minimum length. Defaults to [StringLength(MinimumLength)] or [MinLength].

StartIconIconData?

An icon inside the field, before the text.

EndIconIconData?

An icon inside the field, after the text. Ignored for passwords with Reveal.

StartAddonRenderFragment?

Content attached before the control, outside its border: short text (https://, $), a button, or another field such as a Select<T> (its label is kept for screen readers but not shown). Text here is not part of the field's accessible name, so say it in the label when it matters, as in "Price (USD)".

EndAddonRenderFragment?

Content attached after the control, outside its border. See StartAddon.

Revealbool = true

For passwords: a button that shows or hides the text. Appears once scripts run. Defaults to true.

ShowPasswordLabelstring? = "Show password"

The reveal button's name; it's a toggle, pressed while the password shows. Defaults to "Show password".

@bind-Valuestring?

The value, bound with @bind-Value.

DisplayNamestring?

The field's name in validation messages from the input itself, such as a value that can't be parsed.

Field props (from FieldBase)

Labelstring? (computed)

The visible label. Defaults to the model property's [Display(Name)], or its name.

HideLabelbool = false

Keeps the label for screen readers but doesn't show it, as in a toolbar or a one-field newsletter form. Checkboxes and switches show their label beside the box, so this doesn't apply.

Hintstring?

Help text shown under the field and linked to it for screen readers.

Requiredbool? (computed)

Whether a value is required. Defaults to whether the property has [Required].

Disabledbool = false

Disables the field. Disabled fields are not posted with the form.

SizeControlSize = ControlSize.Md

Height, shared with buttons. Defaults to ControlSize.Md.

Classstring?

Classes for the field's outer wrapper (label, control, hint and error).

Stylestring?

Inline style for the field's outer wrapper, after its generated custom properties.

HiddenFromBreakpoint?

Hides the field from this breakpoint up.

VisibleFromBreakpoint?

Shows the field only from this breakpoint up.

MarginResponsive<int>Responsive

Margin on all sides, in spacing steps (-16 to 16; one step = 4px).

MarginXResponsive<int>Responsive

Horizontal margin. When set, replaces Margin on this axis.

MarginYResponsive<int>Responsive

Vertical margin. When set, replaces Margin on this axis.

MarginTopResponsive<int>Responsive

Top margin. When set, replaces MarginY and Margin on this side.

MarginBottomResponsive<int>Responsive

Bottom margin. When set, replaces MarginY and Margin on this side.

MarginStartResponsive<int>Responsive

Margin at the start (left in left-to-right text). Replaces MarginX and Margin on this side.

MarginEndResponsive<int>Responsive

Margin at the end (right in left-to-right text). Replaces MarginX and Margin on this side.

WidthResponsive<Length>Responsive

Width of the whole field (label, control, hint).

MinWidthResponsive<Length>Responsive

Minimum width of the whole field.

MaxWidthResponsive<Length>Responsive

Maximum width of the whole field.

Growbool = false

Whether to grow into free space inside a Stack, Row or Column: <TextField Grow />.

Shrinkbool = true

Whether to shrink when space is short inside a Stack, Row or Column. Defaults to true.

BasisResponsive<Length>Responsive

Starting size inside a Stack, before growing or shrinking.

AlignSelfResponsive<Align>Responsive

Alignment across the parent's direction, overriding the parent's Align for this field only.

ColSpanResponsive<int>Responsive

How many columns the field spans in a Form or Fieldset with Columns; GridSpan.Full for the whole row. Never more than the columns shown.

NewRowbool = false

Starts a new row in a Form or Fieldset with Columns, or a Grid, leaving the rest of the row before it empty.

Events (0)

No events.

Types (1)

TextFieldType

enum

The kind of text a TextField takes. Sets the input type and the mobile keyboard.

TextFieldType values
ValueDescription
Text

Plain text.

Email

An email address.

Password

A password, masked, with a show/hide toggle.

Search

A search query.

Tel

A phone number.

Url

A URL.