From 2980eb9c0ad2ff0bc411646673687316bd1b4118 Mon Sep 17 00:00:00 2001 From: xjdqq <40536295+xjdqq@users.noreply.github.com> Date: Thu, 8 Sep 2022 15:47:56 +0800 Subject: [PATCH] Update index.tsx --- src/index.tsx | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/index.tsx b/src/index.tsx index 7fd9e45..28d6972 100644 --- a/src/index.tsx +++ b/src/index.tsx @@ -152,6 +152,12 @@ const OtpInputs = forwardRef( ) { handleInputTextChange(text, index); } + if (Platform.OS === 'ios' && index === 0 && text.length > 1) { + inputs.current[index].current.setNativeProps({ + value: text[0], + text: text[0], + }); + } }; const handleKeyPress = (