Skip to content

@radix-ui/one-time-password-field: prop type ('text' | 'password') do nothing #3493

@sidoruk-sv

Description

@sidoruk-sv

Bug report

Current Behavior

Setting type prop on a <OneTimePasswordField.Root> component do nothing.

Expected behavior

type property changes the representation of the symbols inside input:

  • text - current behavior;
  • password - dots (•) are shown instead of characters.

Reproducible example

https://codesandbox.io/p/sandbox/red-dream-87jv8y

Suggested solution

type property should belongs to <OneTimePasswordField.Input /> and sets the type of the generated <input>.

Your environment

Software Name(s) Version
Radix Package(s) @radix-ui/react-one-time-password-field 0.1.3
React n/a 19

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions