Skip to content

Commit 2b8fd54

Browse files
authored
fix(input): handleBlur callback value is undefined in mini-programs (#3266)
1 parent c17af68 commit 2b8fd54

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/packages/input/input.taro.tsx

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -141,7 +141,8 @@ export const Input = forwardRef((props: Partial<TaroInputProps>, ref) => {
141141
}
142142

143143
const handleBlur = (event: any) => {
144-
const val = Taro.getEnv() === 'WEB' ? (event.target as any).value : value
144+
const val =
145+
Taro.getEnv() === 'WEB' ? (event.target as any).value : event.detail.value
145146
updateValue(val, 'onBlur')
146147
setTimeout(() => setActive(false), 200)
147148
}

0 commit comments

Comments
 (0)