Skip to content

Commit

Permalink
Added types to handleKeyboardEvent callback (#206)
Browse files Browse the repository at this point in the history
  • Loading branch information
JDMathew authored Jun 26, 2024
1 parent 7277c2a commit cbbfa23
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion packages/extras/src/hooks/useKeyboard.ts
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,12 @@ export const useKeyboard = (shouldHandleKeyboardEvents: boolean) => {
const isKeyboardVisible = useSharedValue(false);

const handleKeyboardEvent = useCallback(
(isVisible, height, duration, easing) => {
(
isVisible: boolean,
height: number,
duration: number,
easing: KeyboardEventEasing,
) => {
const finalHeight = isVisible ? height : 0;

const animationConfig = getKeyboardAnimationConfigs(easing, duration);
Expand Down

0 comments on commit cbbfa23

Please sign in to comment.