OtpSlotState
Per-slot state handed to <OtpSlot> (via context), to the render prop, and
returned by the hook as slots. The analogue of RatingIconState in the
sibling repo — a plain, serializable description of one slot, no handlers.
Properties
Section titled “Properties”char: string | null;The character in this slot, or null when empty. Already masked when mask is set.
hasFakeCaret
Section titled “hasFakeCaret”hasFakeCaret: boolean;Render the blinking caret here.
index: number;0-based position in the row.
isActive
Section titled “isActive”isActive: boolean;The caret is at this slot, or a selection covers it.
isDisabled
Section titled “isDisabled”isDisabled: boolean;isFilled
Section titled “isFilled”isFilled: boolean;char !== null
isReadOnly
Section titled “isReadOnly”isReadOnly: boolean;placeholder
Section titled “placeholder”placeholder: string | null;Placeholder char for this slot, or null.