Skip to content

[OneTimePasswordField] autoComplete not working in Chrome on iOS #3641

@timblackwell

Description

@timblackwell

Bug report

Current Behavior

When using autoComplete in Chrome on iOS, only the first character of the password is entered.

Expected behavior

When using autoComplete in Chrome on iOS, the entire password is input.

Reproducible example

  1. Navigate to the Radix UI One Time Password Field demo in Chrome on iOS device:
    https://www.radix-ui.com/primitives/docs/components/one-time-password-field
  2. Send an SMS to your device with the following contents:
Test OTP: 123456

@www.radix-ui.com #123456
  1. Observe only the first character '1' is entered and the second input is selected.

Suggested solution

Remove the max length property and if more than one character is entered, spread them into the other boxes.

Additional context

Your environment

Software Name(s) Version
Radix Package(s) @radix-ui/react-one-time-password-field 0.1.7
React n/a
Browser chrome 139.7.7258.60
Assistive tech
Node n/a
npm/yarn/pnpm
Operating System iOS 18.5

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