From 42defa567e6ed65caf2906c3b181ea3866c58125 Mon Sep 17 00:00:00 2001 From: kirillzyusko Date: Thu, 24 Oct 2024 11:18:29 +0200 Subject: [PATCH] chore: added logger to debug issues in release variants --- src/components/KeyboardAwareScrollView/index.tsx | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/components/KeyboardAwareScrollView/index.tsx b/src/components/KeyboardAwareScrollView/index.tsx index 250478fb9..1bce4732c 100644 --- a/src/components/KeyboardAwareScrollView/index.tsx +++ b/src/components/KeyboardAwareScrollView/index.tsx @@ -242,6 +242,7 @@ const KeyboardAwareScrollView = forwardRef< return; } + console.debug("maybeScroll - onChangeText"); scrollFromCurrentPosition(customHeight); }, [scrollFromCurrentPosition], @@ -255,6 +256,7 @@ const KeyboardAwareScrollView = forwardRef< "worklet"; if (e.selection.start.position !== e.selection.end.position) { + console.debug("onSelectionChange - onChangeText"); scrollFromCurrentPosition(e.selection.end.y); } @@ -320,6 +322,7 @@ const KeyboardAwareScrollView = forwardRef< if (focusWasChanged && !keyboardWillAppear.value) { // update position on scroll value, so `onEnd` handler // will pick up correct values + console.debug("maybeScroll - onStart"); position.value += maybeScroll(e.height, true); } }, @@ -330,6 +333,7 @@ const KeyboardAwareScrollView = forwardRef< // if the user has set disableScrollOnKeyboardHide, only auto-scroll when the keyboard opens if (!disableScrollOnKeyboardHide || keyboardWillAppear.value) { + console.debug("maybeScroll - onMove"); maybeScroll(e.height); } }, @@ -355,6 +359,7 @@ const KeyboardAwareScrollView = forwardRef< const prevLayout = layout.value; layout.value = input.value; + console.debug("maybeScroll - animated reaction"); scrollPosition.value += maybeScroll(keyboardHeight.value, true); layout.value = prevLayout; }