Bluesky app fork with some witchin' additions 馃挮
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

at cope-settings-sync 48 lines 2.0 kB view raw
1diff --git a/src/components/KeyboardChatScrollView/useExtraContentPadding/index.ts b/src/components/KeyboardChatScrollView/useExtraContentPadding/index.ts 2index 24a25ae..2c5ff6d 100644 3--- a/src/components/KeyboardChatScrollView/useExtraContentPadding/index.ts 4+++ b/src/components/KeyboardChatScrollView/useExtraContentPadding/index.ts 5@@ -1,8 +1,6 @@ 6 import { useCallback } from "react"; 7-import { Platform } from "react-native"; 8 import { scrollTo, useAnimatedReaction } from "react-native-reanimated"; 9 10-import { IS_FABRIC } from "../../../architecture"; 11 import { isScrollAtEnd, shouldShiftContent } from "../useChatKeyboard/helpers"; 12 13 import type { KeyboardLiftBehavior } from "../useChatKeyboard/types"; 14@@ -52,7 +50,6 @@ function useExtraContentPadding(options: UseExtraContentPaddingOptions): void { 15 scroll, 16 layout, 17 size, 18- contentOffsetY, 19 inverted, 20 keyboardLiftBehavior, 21 freeze, 22@@ -62,20 +59,14 @@ function useExtraContentPadding(options: UseExtraContentPaddingOptions): void { 23 (target: number) => { 24 "worklet"; 25 26- if (contentOffsetY && IS_FABRIC) { 27- // eslint-disable-next-line react-compiler/react-compiler 28- contentOffsetY.value = target; 29- } else if (Platform.OS === "android") { 30- // Defer scrollTo so the animatedProps inset commit lands first; 31- // otherwise the native ScrollView clamps to the old range. 32- requestAnimationFrame(() => { 33- scrollTo(scrollViewRef, 0, target, false); 34- }); 35- } else { 36+ // Always defer scrollTo so the animatedProps inset commit lands first; 37+ // otherwise the native ScrollView clamps contentOffset to the old 38+ // contentInset range (iOS Fabric) or the old contentInsetBottom (Android). 39+ requestAnimationFrame(() => { 40 scrollTo(scrollViewRef, 0, target, false); 41- } 42+ }); 43 }, 44- [scrollViewRef, contentOffsetY], 45+ [scrollViewRef], 46 ); 47 48 useAnimatedReaction(