-
-
Notifications
You must be signed in to change notification settings - Fork 562
Description
Reproduction
InputOTP docs examples on the v4-docs branch
Describe the bug
Hey @sadeghbarati (and other maintainers),
sorry for the direct mention, but I noticed some regressions/behavioral differences in the merged version of the InputOTP component for the upcoming v4 in comparison to my initial implementation in #1505.
- The default pattern was reverted to the default numeric pattern provided through
vue-otp-input, which doesn't reflect the default "accept all" pattern in shadcn/ui in c6cfe06 - Minor detail: The "Form" example now validates immediately on focus instead of on submit like in the shadcn/ui docs which I think is the more user-friendly behavior. Commit: d3d119e
As the projects goal is to be closely aligned to shadcn/ui, I suggest we either submit another breaking change PR to align the default "accept all" pattern in https://github.com/wobsoriano/vue-input-otp with https://github.com/guilhermerodz/input-otp or set it here again via withDefaults.
For the minor detail of the validation behavior in the Form example, could we just turn the default VeeValidate validation attributes off again? Like this:
<VeeField v-slot="{ componentField, errors }" name="pin" :validate-on-blur="false" :validate-on-input="false" :validate-on-model-update="false">Screen Recordings
To make it more clear what I mean exactly, I made some screen recordings that show the different behaviour.
InputOTP not accepting all characters by default - shadcn-vue
Screen.Recording.2025-11-02.at.20.32.02.mov
InputOTP accepting all characters by default - shadcn/ui
Screen.Recording.2025-11-02.at.20.38.49.mov
Form example validating immediately - shadcn-vue
Screen.Recording.2025-11-02.at.20.41.46.mov
Form example not validating immediately - shadcn/ui
Screen.Recording.2025-11-02.at.20.39.30.mov
Hope this helps! ❤️
System Info
current v4-docs branchContributes
- I am willing to submit a PR to fix this issue
- I am willing to submit a PR with failing tests