Skip to content

Commit 71a0e2b

Browse files
committed
Update WheelPicker.tsx
1 parent f77956f commit 71a0e2b

1 file changed

Lines changed: 4 additions & 1 deletion

File tree

src/WheelPicker.tsx

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -95,8 +95,11 @@ const WheelPicker: React.FC<Props> = ({
9595
});
9696
}, [selectedIndex]);
9797

98+
9899
useEffect(() => {
99-
//onChange(scrollIndex)
100+
if (onChange) {
101+
onChange(scrollIndex)
102+
}
100103
}, [scrollIndex])
101104

102105
const handleScroll = (event: {

0 commit comments

Comments
 (0)