OtpFieldView.id
property · packages/mixins-ui/src/otpField.ts:31
readonly id?: string | undefinedThe input's id, for a label or a form to name it.
Mixins / foldkit-mixins-ui
interface · packages/mixins-ui/src/otpField.ts:29
interface OtpFieldView<Message> {
readonly id?: string | undefined
readonly name?: string | undefined
readonly label: string
readonly length?: number | undefined
readonly value: string
readonly onChange: (value: string) => NoInfer<Message>
readonly pattern?: keyof typeof PATTERNS | undefined
readonly groups?: ReadonlyArray<number> | undefined
readonly disabled?: boolean | undefined
readonly readOnly?: boolean | undefined
readonly invalid?: boolean | undefined
readonly mask?: boolean | string | undefined
readonly style?: NamedStyle<typeof OtpFieldSlots> | undefined
readonly mixins?: MixinList<Message> | undefined
}OtpFieldView.idproperty · packages/mixins-ui/src/otpField.ts:31
readonly id?: string | undefinedThe input's id, for a label or a form to name it.
OtpFieldView.nameproperty · packages/mixins-ui/src/otpField.ts:33
readonly name?: string | undefinedThe form field the code submits under.
OtpFieldView.labelproperty · packages/mixins-ui/src/otpField.ts:35
readonly label: stringThe field's accessible name: what the code is for.
OtpFieldView.lengthproperty · packages/mixins-ui/src/otpField.ts:37
readonly length?: number | undefinedHow many characters the code has. Default 6.
OtpFieldView.valueproperty · packages/mixins-ui/src/otpField.ts:38
readonly value: stringOtpFieldView.onChangeproperty · packages/mixins-ui/src/otpField.ts:40
readonly onChange: (value: string) => NoInfer<Message>The Message for what was typed, already kept to the pattern and length.
OtpFieldView.patternproperty · packages/mixins-ui/src/otpField.ts:42
readonly pattern?: keyof typeof PATTERNS | undefinedWhich characters a cell takes; default digits.
OtpFieldView.groupsproperty · packages/mixins-ui/src/otpField.ts:44
readonly groups?: ReadonlyArray<number> | undefinedThe cells in runs, a separator between them: [3, 3]. Default one run.
OtpFieldView.disabledproperty · packages/mixins-ui/src/otpField.ts:45
readonly disabled?: boolean | undefinedOtpFieldView.readOnlyproperty · packages/mixins-ui/src/otpField.ts:47
readonly readOnly?: boolean | undefinedThe code can be read and copied, not typed.
OtpFieldView.invalidproperty · packages/mixins-ui/src/otpField.ts:49
readonly invalid?: boolean | undefinedThe code is refused: the input is aria-invalid, and each cell carries data-invalid.
OtpFieldView.maskproperty · packages/mixins-ui/src/otpField.ts:55
readonly mask?: boolean | string | undefinedHide the code: the input is a password field and each filled cell shows a dot
(mask of true), or the mark given. The value the application holds is the
real one.
OtpFieldView.styleproperty · packages/mixins-ui/src/otpField.ts:57
readonly style?: NamedStyle<typeof OtpFieldSlots> | undefinedA style of OtpFieldSlots, for the field's look.
OtpFieldView.mixinsproperty · packages/mixins-ui/src/otpField.ts:59
readonly mixins?: MixinList<Message> | undefinedMixins beside the style.