Skip to content

Commit

Permalink
correctly set up hitslop for useAutoHitSlop
Browse files Browse the repository at this point in the history
  • Loading branch information
robertKozik committed Apr 24, 2023
1 parent 46241f1 commit d270158
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/libs/Accessibility/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ const useAutoHitSlop = () => {
const onLayout = useCallback((event) => {
const {layout} = event.nativeEvent;
if (layout.width !== frameSize.x && layout.height !== frameSize.y) {
setFrameSize({frameSize: {x: layout.width, y: layout.height}});
setFrameSize({x: layout.width, y: layout.height});
}
}, [frameSize]);
return [getHitSlopForSize(frameSize), onLayout];
Expand Down

0 comments on commit d270158

Please sign in to comment.