@@ -39,6 +39,40 @@ export function MyComponent() {
3939}
4040```
4141
42+ ## Properties
43+
44+ | TextInputOTP | Type | Description |
45+ | ------------ | --------------------------------- | ------------------------------------------------------------------------------------------------------------------------------ |
46+ | ` maxLength ` | number - Required | The max number of digits to OTP code. |
47+ | ` onFilled ` | (code: string) => void - Optional | The callback function is executed when the OTP input has been entirely completed, and it receives the OTP code as a parameter. |
48+
49+ | TextInputOTPGroup | Type | Description |
50+ | ----------------- | -------------------- | ----------------------------- |
51+ | ` groupStyles ` | ViewStyle - Optional | Custom styles for the ` View ` . |
52+
53+ | TextInputOTPSlot | Type | Description |
54+ | ----------------------- | -------------------- | ----------------------------------------------------------------------------------------------------------- |
55+ | ` index ` | number - Required | The position of the slot within the OTP input sequence. Each slot must have a unique index starting from 0. |
56+ | ` slotStyles ` | ViewStyle - Optional | Custom styles for the ` View ` . |
57+ | ` focusedSlotStyles ` | ViewStyle - Optional | Custom styles applied to the slot ` View ` when it is focused. |
58+ | ` slotTextStyles ` | TextStyle - Optional | Custom styles for the ` Text ` . |
59+ | ` focusedSlotTextStyles ` | TextStyle - Optional | Custom styles applied to the slot ` Text ` when it is focused. |
60+
61+ | TextInputOTPSeparator | Type | Description |
62+ | --------------------- | -------------------- | ----------------------------- |
63+ | ` separatorStyles ` | ViewStyle - Optional | Custom styles for the ` View ` . |
64+
65+ ## Methods
66+
67+ The ` TextInputOTP ` component exposes these functions with ` ref ` :
68+
69+ | Prop | Type | Description |
70+ | ---------- | ------------------------ | -------------------------------------------------------------------------- |
71+ | ` clear ` | () => void; | Resets the OTP input by clearing all entered values. |
72+ | ` focus ` | () => void; | Activates the OTP input field, allowing the user to type. |
73+ | ` blue ` | () => void; | Deactivates the OTP input field, removing focus. |
74+ | ` setValue ` | (value: string) => void; | Sets a custom value to the OTP input fields, overriding any current input. |
75+
4276## Contributing
4377
4478Contributions are welcome! Please feel free to open issues or submit pull requests.
0 commit comments