react-native-keyboard-controller 1.21.3 → 1.21.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/android/src/fabric/java/com/reactnativekeyboardcontroller/KeyboardControllerModule.kt +2 -0
- package/android/src/main/java/com/reactnativekeyboardcontroller/listeners/WindowDimensionListener.kt +1 -0
- package/android/src/main/java/com/reactnativekeyboardcontroller/managers/KeyboardControllerViewManagerImpl.kt +5 -1
- package/android/src/main/java/com/reactnativekeyboardcontroller/modules/KeyboardControllerModuleImpl.kt +8 -0
- package/android/src/paper/java/com/reactnativekeyboardcontroller/KeyboardControllerModule.kt +2 -0
- package/ios/KeyboardControllerModule.mm +12 -0
- package/ios/observers/FocusedInputObserver.swift +9 -2
- package/ios/views/KeyboardExtenderContainerView.swift +14 -4
- package/lib/commonjs/bindings.js +4 -1
- package/lib/commonjs/bindings.js.map +1 -1
- package/lib/commonjs/components/KeyboardAwareScrollView/index.js +47 -10
- package/lib/commonjs/components/KeyboardAwareScrollView/index.js.map +1 -1
- package/lib/commonjs/components/KeyboardAwareScrollView/types.js.map +1 -1
- package/lib/commonjs/components/KeyboardToolbar/constants.js +2 -2
- package/lib/commonjs/components/KeyboardToolbar/constants.js.map +1 -1
- package/lib/commonjs/components/index.js.map +1 -1
- package/lib/commonjs/constants.js +3 -1
- package/lib/commonjs/constants.js.map +1 -1
- package/lib/commonjs/index.js.map +1 -1
- package/lib/commonjs/specs/NativeKeyboardController.js.map +1 -1
- package/lib/commonjs/types/module.js.map +1 -1
- package/lib/module/bindings.js +4 -1
- package/lib/module/bindings.js.map +1 -1
- package/lib/module/components/KeyboardAwareScrollView/index.js +48 -11
- package/lib/module/components/KeyboardAwareScrollView/index.js.map +1 -1
- package/lib/module/components/KeyboardAwareScrollView/types.js.map +1 -1
- package/lib/module/components/KeyboardToolbar/constants.js +2 -2
- package/lib/module/components/KeyboardToolbar/constants.js.map +1 -1
- package/lib/module/components/index.js.map +1 -1
- package/lib/module/constants.js +3 -0
- package/lib/module/constants.js.map +1 -1
- package/lib/module/index.js.map +1 -1
- package/lib/module/specs/NativeKeyboardController.js.map +1 -1
- package/lib/module/types/module.js.map +1 -1
- package/lib/typescript/components/KeyboardAwareScrollView/index.d.ts +1 -0
- package/lib/typescript/components/KeyboardAwareScrollView/types.d.ts +10 -0
- package/lib/typescript/components/index.d.ts +1 -1
- package/lib/typescript/constants.d.ts +1 -0
- package/lib/typescript/index.d.ts +1 -1
- package/lib/typescript/specs/NativeKeyboardController.d.ts +3 -1
- package/lib/typescript/types/module.d.ts +3 -0
- package/package.json +1 -1
- package/src/bindings.ts +3 -0
- package/src/components/KeyboardAwareScrollView/index.tsx +79 -29
- package/src/components/KeyboardAwareScrollView/types.ts +11 -0
- package/src/components/KeyboardToolbar/constants.ts +2 -3
- package/src/components/index.ts +1 -0
- package/src/constants.ts +4 -0
- package/src/index.ts +1 -0
- package/src/specs/NativeKeyboardController.ts +3 -1
- package/src/types/module.ts +4 -0
package/android/src/fabric/java/com/reactnativekeyboardcontroller/KeyboardControllerModule.kt
CHANGED
|
@@ -11,6 +11,8 @@ class KeyboardControllerModule(
|
|
|
11
11
|
|
|
12
12
|
override fun getName(): String = KeyboardControllerModuleImpl.NAME
|
|
13
13
|
|
|
14
|
+
override fun getTypedExportedConstants(): Map<String, Any> = module.getConstants()
|
|
15
|
+
|
|
14
16
|
override fun setInputMode(mode: Double) {
|
|
15
17
|
module.setInputMode(mode.toInt())
|
|
16
18
|
}
|
|
@@ -13,11 +13,14 @@ import com.reactnativekeyboardcontroller.views.EdgeToEdgeReactViewGroup
|
|
|
13
13
|
|
|
14
14
|
class KeyboardControllerViewManagerImpl {
|
|
15
15
|
private var listener: WindowDimensionListener? = null
|
|
16
|
+
private var listenerContext: ThemedReactContext? = null
|
|
16
17
|
|
|
17
18
|
fun createViewInstance(reactContext: ThemedReactContext): EdgeToEdgeReactViewGroup {
|
|
18
|
-
if (listener == null) {
|
|
19
|
+
if (listener == null || listenerContext !== reactContext) {
|
|
20
|
+
listener?.detachListener()
|
|
19
21
|
listener = WindowDimensionListener(reactContext)
|
|
20
22
|
listener?.attachListener()
|
|
23
|
+
listenerContext = reactContext
|
|
21
24
|
}
|
|
22
25
|
return EdgeToEdgeReactViewGroup(reactContext)
|
|
23
26
|
}
|
|
@@ -25,6 +28,7 @@ class KeyboardControllerViewManagerImpl {
|
|
|
25
28
|
fun invalidate() {
|
|
26
29
|
listener?.detachListener()
|
|
27
30
|
listener = null
|
|
31
|
+
listenerContext = null
|
|
28
32
|
}
|
|
29
33
|
|
|
30
34
|
fun synchronizeFocusedInputLayout(view: EdgeToEdgeReactViewGroup) {
|
|
@@ -23,6 +23,7 @@ class KeyboardControllerModuleImpl(
|
|
|
23
23
|
private val controller = KeyboardAnimationController()
|
|
24
24
|
private val mDefaultMode: Int = getCurrentMode()
|
|
25
25
|
|
|
26
|
+
// region Module methods
|
|
26
27
|
fun setInputMode(mode: Int) {
|
|
27
28
|
setSoftInputMode(mode)
|
|
28
29
|
}
|
|
@@ -102,7 +103,9 @@ class KeyboardControllerModuleImpl(
|
|
|
102
103
|
promise.resolve(map)
|
|
103
104
|
}
|
|
104
105
|
}
|
|
106
|
+
// endregion
|
|
105
107
|
|
|
108
|
+
// region Helpers
|
|
106
109
|
private fun setSoftInputMode(mode: Int) {
|
|
107
110
|
UiThreadUtil.runOnUiThread {
|
|
108
111
|
if (getCurrentMode() != mode) {
|
|
@@ -118,8 +121,13 @@ class KeyboardControllerModuleImpl(
|
|
|
118
121
|
?.attributes
|
|
119
122
|
?.softInputMode
|
|
120
123
|
?: WindowManager.LayoutParams.SOFT_INPUT_STATE_UNSPECIFIED
|
|
124
|
+
// endregion
|
|
125
|
+
|
|
126
|
+
// region Module constants
|
|
127
|
+
fun getConstants(): MutableMap<String, Any> = mutableMapOf("keyboardBorderRadius" to 0)
|
|
121
128
|
|
|
122
129
|
companion object {
|
|
123
130
|
const val NAME = "KeyboardController"
|
|
124
131
|
}
|
|
132
|
+
// endregion
|
|
125
133
|
}
|
package/android/src/paper/java/com/reactnativekeyboardcontroller/KeyboardControllerModule.kt
CHANGED
|
@@ -13,6 +13,8 @@ class KeyboardControllerModule(
|
|
|
13
13
|
|
|
14
14
|
override fun getName(): String = KeyboardControllerModuleImpl.NAME
|
|
15
15
|
|
|
16
|
+
override fun getConstants(): MutableMap<String, Any> = module.getConstants()
|
|
17
|
+
|
|
16
18
|
@ReactMethod
|
|
17
19
|
fun setInputMode(mode: Int) {
|
|
18
20
|
module.setInputMode(mode)
|
|
@@ -53,6 +53,18 @@ RCT_EXPORT_MODULE()
|
|
|
53
53
|
return NO;
|
|
54
54
|
}
|
|
55
55
|
|
|
56
|
+
- (NSDictionary *)constantsToExport
|
|
57
|
+
{
|
|
58
|
+
return @{
|
|
59
|
+
@"keyboardBorderRadius" : @([KeyboardExtenderContainerView keyboardBorderRadius]),
|
|
60
|
+
};
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
- (NSDictionary *)getConstants
|
|
64
|
+
{
|
|
65
|
+
return [self constantsToExport];
|
|
66
|
+
}
|
|
67
|
+
|
|
56
68
|
#ifdef RCT_NEW_ARCH_ENABLED
|
|
57
69
|
- (void)setDefaultMode
|
|
58
70
|
#else
|
|
@@ -112,9 +112,16 @@ public class FocusedInputObserver: NSObject {
|
|
|
112
112
|
NotificationCenter.default.removeObserver(self)
|
|
113
113
|
}
|
|
114
114
|
|
|
115
|
-
@objc func didReceiveFocus(_: Notification) {
|
|
115
|
+
@objc func didReceiveFocus(_ notification: Notification) {
|
|
116
116
|
if UIResponder.current == currentResponder {
|
|
117
|
-
//
|
|
117
|
+
// The same input is still focused — no need to re-run the full onFocus()
|
|
118
|
+
// setup (observers, delegate substitution, focusDidSet event). However,
|
|
119
|
+
// keyboardWillShowNotification also fires when the keyboard *resizes*
|
|
120
|
+
// (e.g. switching between text and emoji keyboards). In that case we must
|
|
121
|
+
// refresh the layout so consumers receive an up-to-date absoluteY.
|
|
122
|
+
if notification.name == UIResponder.keyboardWillShowNotification {
|
|
123
|
+
syncUpLayout()
|
|
124
|
+
}
|
|
118
125
|
return
|
|
119
126
|
}
|
|
120
127
|
|
|
@@ -9,16 +9,26 @@ import UIKit
|
|
|
9
9
|
|
|
10
10
|
@objc
|
|
11
11
|
public class KeyboardExtenderContainerView: NSObject {
|
|
12
|
-
|
|
12
|
+
private static func usesModernKeyboard() -> Bool {
|
|
13
13
|
#if canImport(UIKit.UIGlassEffect)
|
|
14
14
|
if #available(iOS 26.0, *) {
|
|
15
15
|
let requiresCompat = Bundle.main.object(forInfoDictionaryKey: "UIDesignRequiresCompatibility") as? Bool ?? false
|
|
16
|
-
|
|
17
|
-
return ModernContainerView(frame: frame, contentView: contentView)
|
|
18
|
-
}
|
|
16
|
+
return !requiresCompat
|
|
19
17
|
}
|
|
20
18
|
#endif
|
|
19
|
+
return false
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
@objc public static func keyboardBorderRadius() -> CGFloat {
|
|
23
|
+
return usesModernKeyboard() ? 30 : 0
|
|
24
|
+
}
|
|
21
25
|
|
|
26
|
+
@objc public static func create(frame: CGRect, contentView: UIView) -> UIView {
|
|
27
|
+
if usesModernKeyboard() {
|
|
28
|
+
if #available(iOS 26.0, *) {
|
|
29
|
+
return ModernContainerView(frame: frame, contentView: contentView)
|
|
30
|
+
}
|
|
31
|
+
}
|
|
22
32
|
return LegacyContainerView(frame: frame, contentView: contentView)
|
|
23
33
|
}
|
|
24
34
|
}
|
package/lib/commonjs/bindings.js
CHANGED
|
@@ -19,7 +19,10 @@ const KeyboardControllerNative = exports.KeyboardControllerNative = {
|
|
|
19
19
|
height: 0
|
|
20
20
|
}),
|
|
21
21
|
addListener: NOOP,
|
|
22
|
-
removeListeners: NOOP
|
|
22
|
+
removeListeners: NOOP,
|
|
23
|
+
getConstants: () => ({
|
|
24
|
+
keyboardBorderRadius: 0
|
|
25
|
+
})
|
|
23
26
|
};
|
|
24
27
|
/**
|
|
25
28
|
* An event emitter that provides a way to subscribe to next keyboard events:
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["_reactNative","require","NOOP","KeyboardControllerNative","exports","setDefaultMode","setInputMode","preload","dismiss","setFocusTo","viewPositionInWindow","Promise","resolve","x","y","width","height","addListener","removeListeners","KeyboardEvents","remove","FocusedInputEvents","WindowDimensionsEvents","KeyboardControllerView","View","KeyboardControllerViewCommands","synchronizeFocusedInputLayout","_ref","KeyboardGestureArea","RCTOverKeyboardView","KeyboardBackgroundView","RCTKeyboardExtender","ClippingScrollView","RCTKeyboardToolbarGroupView"],"sources":["bindings.ts"],"sourcesContent":["import { View } from \"react-native\";\n\nimport type {\n ClippingScrollViewProps,\n FocusedInputEventsModule,\n KeyboardBackgroundViewProps,\n KeyboardControllerNativeModule,\n KeyboardControllerProps,\n KeyboardEventsModule,\n KeyboardExtenderProps,\n KeyboardGestureAreaProps,\n KeyboardToolbarGroupViewProps,\n OverKeyboardViewProps,\n WindowDimensionsEventsModule,\n} from \"./types\";\nimport type { EmitterSubscription } from \"react-native\";\n\nconst NOOP = () => {};\n\nexport const KeyboardControllerNative: KeyboardControllerNativeModule = {\n setDefaultMode: NOOP,\n setInputMode: NOOP,\n preload: NOOP,\n dismiss: NOOP,\n setFocusTo: NOOP,\n viewPositionInWindow: () =>\n Promise.resolve({ x: 0, y: 0, width: 0, height: 0 }),\n addListener: NOOP,\n removeListeners: NOOP,\n};\n/**\n * An event emitter that provides a way to subscribe to next keyboard events:\n * - `keyboardWillShow`;\n * - `keyboardDidShow`;\n * - `keyboardWillHide`;\n * - `keyboardDidHide`.\n *\n * Use `addListener` function to add your event listener for a specific keyboard event.\n */\nexport const KeyboardEvents: KeyboardEventsModule = {\n addListener: () => ({ remove: NOOP } as EmitterSubscription),\n};\n/**\n * This API is not documented, it's for internal usage only (for now), and is a subject to potential breaking changes in future.\n * Use it with cautious.\n */\nexport const FocusedInputEvents: FocusedInputEventsModule = {\n addListener: () => ({ remove: NOOP } as EmitterSubscription),\n};\nexport const WindowDimensionsEvents: WindowDimensionsEventsModule = {\n addListener: () => ({ remove: NOOP } as EmitterSubscription),\n};\n/**\n * A view that sends events whenever keyboard or focused events are happening.\n *\n * @see {@link https://kirillzyusko.github.io/react-native-keyboard-controller/docs/api/keyboard-controller-view|Documentation} page for more details.\n */\nexport const KeyboardControllerView =\n View as unknown as React.FC<KeyboardControllerProps>;\nexport const KeyboardControllerViewCommands = {\n synchronizeFocusedInputLayout: (\n _ref: React.Component<KeyboardControllerProps> | null,\n ) => {},\n};\n/**\n * A view that defines a region on the screen, where gestures will control the keyboard position.\n *\n * @see {@link https://kirillzyusko.github.io/react-native-keyboard-controller/docs/api/keyboard-gesture-area|Documentation} page for more details.\n */\nexport const KeyboardGestureArea =\n View as unknown as React.FC<KeyboardGestureAreaProps>;\nexport const RCTOverKeyboardView =\n View as unknown as React.FC<OverKeyboardViewProps>;\n/**\n * A view that matches keyboard background.\n *\n * @see {@link https://kirillzyusko.github.io/react-native-keyboard-controller/docs/api/keyboard-background-view|Documentation} page for more details.\n */\nexport const KeyboardBackgroundView =\n View as unknown as React.FC<KeyboardBackgroundViewProps>;\n/**\n * A container that will embed its children into the keyboard\n * and will always show them above the keyboard.\n *\n * @see {@link https://kirillzyusko.github.io/react-native-keyboard-controller/docs/api/keyboard-extender|Documentation} page for more details.\n */\nexport const RCTKeyboardExtender =\n View as unknown as React.FC<KeyboardExtenderProps>;\n/**\n * A decorator that will clip the content of the `ScrollView`. It helps to simulate `contentInset` behavior on Android\n * Supports only `bottom` property (`paddingBottom` is not supported property of `ScrollView.style`).\n * Using this component we can modify bottom inset without having a fake view.\n *\n * On iOS we use swizzling to apply runtime patches to fix some broken internal methods.\n * Ideally this component shouldn't exist and all its fixes/polyfills must be added directly to react-native and\n * we will port features/fixes back to upstream, but at the moment we use this view to\n * deliver desired functionality regardless of react-native version used.\n */\nexport const ClippingScrollView =\n View as unknown as React.FC<ClippingScrollViewProps>;\n/**\n * A View that defines a group of `TextInput`s.\n * Used in toolbar navigation to assure that you can navigate only between inputs withing the same group.\n */\nexport const RCTKeyboardToolbarGroupView =\n View as unknown as React.FC<KeyboardToolbarGroupViewProps>;\n"],"mappings":";;;;;;AAAA,IAAAA,YAAA,GAAAC,OAAA;AAiBA,MAAMC,IAAI,GAAGA,CAAA,KAAM,CAAC,CAAC;AAEd,MAAMC,wBAAwD,GAAAC,OAAA,CAAAD,wBAAA,GAAG;EACtEE,cAAc,EAAEH,IAAI;EACpBI,YAAY,EAAEJ,IAAI;EAClBK,OAAO,EAAEL,IAAI;EACbM,OAAO,EAAEN,IAAI;EACbO,UAAU,EAAEP,IAAI;EAChBQ,oBAAoB,EAAEA,CAAA,KACpBC,OAAO,CAACC,OAAO,CAAC;IAAEC,CAAC,EAAE,CAAC;IAAEC,CAAC,EAAE,CAAC;IAAEC,KAAK,EAAE,CAAC;IAAEC,MAAM,EAAE;EAAE,CAAC,CAAC;EACtDC,WAAW,EAAEf,IAAI;EACjBgB,eAAe,EAAEhB;
|
|
1
|
+
{"version":3,"names":["_reactNative","require","NOOP","KeyboardControllerNative","exports","setDefaultMode","setInputMode","preload","dismiss","setFocusTo","viewPositionInWindow","Promise","resolve","x","y","width","height","addListener","removeListeners","getConstants","keyboardBorderRadius","KeyboardEvents","remove","FocusedInputEvents","WindowDimensionsEvents","KeyboardControllerView","View","KeyboardControllerViewCommands","synchronizeFocusedInputLayout","_ref","KeyboardGestureArea","RCTOverKeyboardView","KeyboardBackgroundView","RCTKeyboardExtender","ClippingScrollView","RCTKeyboardToolbarGroupView"],"sources":["bindings.ts"],"sourcesContent":["import { View } from \"react-native\";\n\nimport type {\n ClippingScrollViewProps,\n FocusedInputEventsModule,\n KeyboardBackgroundViewProps,\n KeyboardControllerNativeModule,\n KeyboardControllerProps,\n KeyboardEventsModule,\n KeyboardExtenderProps,\n KeyboardGestureAreaProps,\n KeyboardToolbarGroupViewProps,\n OverKeyboardViewProps,\n WindowDimensionsEventsModule,\n} from \"./types\";\nimport type { EmitterSubscription } from \"react-native\";\n\nconst NOOP = () => {};\n\nexport const KeyboardControllerNative: KeyboardControllerNativeModule = {\n setDefaultMode: NOOP,\n setInputMode: NOOP,\n preload: NOOP,\n dismiss: NOOP,\n setFocusTo: NOOP,\n viewPositionInWindow: () =>\n Promise.resolve({ x: 0, y: 0, width: 0, height: 0 }),\n addListener: NOOP,\n removeListeners: NOOP,\n getConstants: () => ({\n keyboardBorderRadius: 0,\n }),\n};\n/**\n * An event emitter that provides a way to subscribe to next keyboard events:\n * - `keyboardWillShow`;\n * - `keyboardDidShow`;\n * - `keyboardWillHide`;\n * - `keyboardDidHide`.\n *\n * Use `addListener` function to add your event listener for a specific keyboard event.\n */\nexport const KeyboardEvents: KeyboardEventsModule = {\n addListener: () => ({ remove: NOOP } as EmitterSubscription),\n};\n/**\n * This API is not documented, it's for internal usage only (for now), and is a subject to potential breaking changes in future.\n * Use it with cautious.\n */\nexport const FocusedInputEvents: FocusedInputEventsModule = {\n addListener: () => ({ remove: NOOP } as EmitterSubscription),\n};\nexport const WindowDimensionsEvents: WindowDimensionsEventsModule = {\n addListener: () => ({ remove: NOOP } as EmitterSubscription),\n};\n/**\n * A view that sends events whenever keyboard or focused events are happening.\n *\n * @see {@link https://kirillzyusko.github.io/react-native-keyboard-controller/docs/api/keyboard-controller-view|Documentation} page for more details.\n */\nexport const KeyboardControllerView =\n View as unknown as React.FC<KeyboardControllerProps>;\nexport const KeyboardControllerViewCommands = {\n synchronizeFocusedInputLayout: (\n _ref: React.Component<KeyboardControllerProps> | null,\n ) => {},\n};\n/**\n * A view that defines a region on the screen, where gestures will control the keyboard position.\n *\n * @see {@link https://kirillzyusko.github.io/react-native-keyboard-controller/docs/api/keyboard-gesture-area|Documentation} page for more details.\n */\nexport const KeyboardGestureArea =\n View as unknown as React.FC<KeyboardGestureAreaProps>;\nexport const RCTOverKeyboardView =\n View as unknown as React.FC<OverKeyboardViewProps>;\n/**\n * A view that matches keyboard background.\n *\n * @see {@link https://kirillzyusko.github.io/react-native-keyboard-controller/docs/api/keyboard-background-view|Documentation} page for more details.\n */\nexport const KeyboardBackgroundView =\n View as unknown as React.FC<KeyboardBackgroundViewProps>;\n/**\n * A container that will embed its children into the keyboard\n * and will always show them above the keyboard.\n *\n * @see {@link https://kirillzyusko.github.io/react-native-keyboard-controller/docs/api/keyboard-extender|Documentation} page for more details.\n */\nexport const RCTKeyboardExtender =\n View as unknown as React.FC<KeyboardExtenderProps>;\n/**\n * A decorator that will clip the content of the `ScrollView`. It helps to simulate `contentInset` behavior on Android\n * Supports only `bottom` property (`paddingBottom` is not supported property of `ScrollView.style`).\n * Using this component we can modify bottom inset without having a fake view.\n *\n * On iOS we use swizzling to apply runtime patches to fix some broken internal methods.\n * Ideally this component shouldn't exist and all its fixes/polyfills must be added directly to react-native and\n * we will port features/fixes back to upstream, but at the moment we use this view to\n * deliver desired functionality regardless of react-native version used.\n */\nexport const ClippingScrollView =\n View as unknown as React.FC<ClippingScrollViewProps>;\n/**\n * A View that defines a group of `TextInput`s.\n * Used in toolbar navigation to assure that you can navigate only between inputs withing the same group.\n */\nexport const RCTKeyboardToolbarGroupView =\n View as unknown as React.FC<KeyboardToolbarGroupViewProps>;\n"],"mappings":";;;;;;AAAA,IAAAA,YAAA,GAAAC,OAAA;AAiBA,MAAMC,IAAI,GAAGA,CAAA,KAAM,CAAC,CAAC;AAEd,MAAMC,wBAAwD,GAAAC,OAAA,CAAAD,wBAAA,GAAG;EACtEE,cAAc,EAAEH,IAAI;EACpBI,YAAY,EAAEJ,IAAI;EAClBK,OAAO,EAAEL,IAAI;EACbM,OAAO,EAAEN,IAAI;EACbO,UAAU,EAAEP,IAAI;EAChBQ,oBAAoB,EAAEA,CAAA,KACpBC,OAAO,CAACC,OAAO,CAAC;IAAEC,CAAC,EAAE,CAAC;IAAEC,CAAC,EAAE,CAAC;IAAEC,KAAK,EAAE,CAAC;IAAEC,MAAM,EAAE;EAAE,CAAC,CAAC;EACtDC,WAAW,EAAEf,IAAI;EACjBgB,eA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AAoD;AACtD;AACA;AACA;AACA;AACO,MAAMS,2BAA2B,GAAA/B,OAAA,CAAA+B,2BAAA,GACtCT,iBAA0D","ignoreList":[]}
|
|
@@ -77,6 +77,7 @@ const KeyboardAwareScrollView = /*#__PURE__*/(0, _react.forwardRef)(({
|
|
|
77
77
|
disableScrollOnKeyboardHide = false,
|
|
78
78
|
enabled = true,
|
|
79
79
|
extraKeyboardSpace = 0,
|
|
80
|
+
mode = "insets",
|
|
80
81
|
ScrollViewComponent = _reactNativeReanimated.default.ScrollView,
|
|
81
82
|
snapToOffsets,
|
|
82
83
|
...rest
|
|
@@ -162,15 +163,21 @@ const KeyboardAwareScrollView = /*#__PURE__*/(0, _react.forwardRef)(({
|
|
|
162
163
|
const removeGhostPadding = (0, _react.useCallback)(e => {
|
|
163
164
|
"worklet";
|
|
164
165
|
|
|
165
|
-
//
|
|
166
|
-
//
|
|
167
|
-
|
|
166
|
+
// layout mode: the spacer view participates in layout, so the ScrollView
|
|
167
|
+
// reflows naturally when it shrinks — no manual scroll correction needed.
|
|
168
|
+
if (mode === "layout") {
|
|
169
|
+
return false;
|
|
170
|
+
}
|
|
171
|
+
|
|
172
|
+
// insets mode: `ScrollViewWithBottomPadding` extends scrollable area without
|
|
173
|
+
// changing layout, so when the keyboard hides and we're at the end of the
|
|
174
|
+
// ScrollView we must manually scroll back.
|
|
168
175
|
if (!keyboardWillAppear.value && ghostViewSpace.value > 0) {
|
|
169
176
|
(0, _reactNativeReanimated.scrollTo)(scrollViewAnimatedRef, 0, scrollPosition.value - (0, _reactNativeReanimated.interpolate)(e, [initialKeyboardSize.value, keyboardHeight.value], [ghostViewSpace.value, 0]), false);
|
|
170
177
|
return true;
|
|
171
178
|
}
|
|
172
179
|
return false;
|
|
173
|
-
}, []);
|
|
180
|
+
}, [mode]);
|
|
174
181
|
const performScrollWithPositionRestoration = (0, _react.useCallback)(newPosition => {
|
|
175
182
|
"worklet";
|
|
176
183
|
|
|
@@ -280,8 +287,14 @@ const KeyboardAwareScrollView = /*#__PURE__*/(0, _react.forwardRef)(({
|
|
|
280
287
|
scrollPosition.value = position.value;
|
|
281
288
|
// just persist height - later will be used in interpolation
|
|
282
289
|
keyboardHeight.value = e.height;
|
|
283
|
-
|
|
284
|
-
|
|
290
|
+
|
|
291
|
+
// insets mode: set the full contentInset upfront so that maybeScroll
|
|
292
|
+
// calculations are correct from the very first onMove frame.
|
|
293
|
+
// layout mode: do NOT set it here — the spacer must grow frame-by-frame
|
|
294
|
+
// in onMove to avoid a premature full-height jump before the keyboard moves.
|
|
295
|
+
if (mode === "insets") {
|
|
296
|
+
syncKeyboardFrame(e);
|
|
297
|
+
}
|
|
285
298
|
}
|
|
286
299
|
|
|
287
300
|
// focus was changed
|
|
@@ -318,9 +331,11 @@ const KeyboardAwareScrollView = /*#__PURE__*/(0, _react.forwardRef)(({
|
|
|
318
331
|
position.value += maybeScroll(e.height, true);
|
|
319
332
|
}
|
|
320
333
|
}
|
|
321
|
-
|
|
322
|
-
|
|
323
|
-
|
|
334
|
+
if (mode === "insets") {
|
|
335
|
+
ghostViewSpace.value = position.value + scrollViewLayout.value.height - scrollViewContentSize.value.height;
|
|
336
|
+
if (ghostViewSpace.value > 0) {
|
|
337
|
+
scrollPosition.value = position.value;
|
|
338
|
+
}
|
|
324
339
|
}
|
|
325
340
|
},
|
|
326
341
|
onMove: e => {
|
|
@@ -330,6 +345,11 @@ const KeyboardAwareScrollView = /*#__PURE__*/(0, _react.forwardRef)(({
|
|
|
330
345
|
return;
|
|
331
346
|
}
|
|
332
347
|
|
|
348
|
+
// layout mode: drive the spacer view animation frame-by-frame
|
|
349
|
+
if (mode === "layout") {
|
|
350
|
+
syncKeyboardFrame(e);
|
|
351
|
+
}
|
|
352
|
+
|
|
333
353
|
// if the user has set disableScrollOnKeyboardHide, only auto-scroll when the keyboard opens
|
|
334
354
|
if (!disableScrollOnKeyboardHide || keyboardWillAppear.value) {
|
|
335
355
|
maybeScroll(e.height);
|
|
@@ -353,7 +373,7 @@ const KeyboardAwareScrollView = /*#__PURE__*/(0, _react.forwardRef)(({
|
|
|
353
373
|
}
|
|
354
374
|
syncKeyboardFrame(e);
|
|
355
375
|
}
|
|
356
|
-
}, [maybeScroll, removeGhostPadding, disableScrollOnKeyboardHide, syncKeyboardFrame]);
|
|
376
|
+
}, [mode, maybeScroll, removeGhostPadding, disableScrollOnKeyboardHide, syncKeyboardFrame]);
|
|
357
377
|
const synchronize = (0, _react.useCallback)(async () => {
|
|
358
378
|
await update();
|
|
359
379
|
(0, _reactNativeReanimated.runOnUI)(() => {
|
|
@@ -389,6 +409,23 @@ const KeyboardAwareScrollView = /*#__PURE__*/(0, _react.forwardRef)(({
|
|
|
389
409
|
}
|
|
390
410
|
}, []);
|
|
391
411
|
const padding = (0, _reactNativeReanimated.useDerivedValue)(() => enabled ? currentKeyboardFrameHeight.value : 0, [enabled]);
|
|
412
|
+
// layout mode only: a spacer view whose paddingBottom grows with the keyboard.
|
|
413
|
+
// The `+ 1` ensures the scroll view never reaches its absolute end during animation,
|
|
414
|
+
// avoiding the layout recalculation that triggers on every frame at the boundary.
|
|
415
|
+
// see: https://github.com/kirillzyusko/react-native-keyboard-controller/pull/342
|
|
416
|
+
const layoutSpacerStyle = (0, _reactNativeReanimated.useAnimatedStyle)(() => enabled && mode === "layout" ? {
|
|
417
|
+
paddingBottom: currentKeyboardFrameHeight.value + 1
|
|
418
|
+
} : {}, [enabled, mode]);
|
|
419
|
+
if (mode === "layout") {
|
|
420
|
+
return /*#__PURE__*/_react.default.createElement(ScrollViewComponent, _extends({
|
|
421
|
+
ref: onRef
|
|
422
|
+
}, rest, {
|
|
423
|
+
scrollEventThrottle: 16,
|
|
424
|
+
onLayout: onScrollViewLayout
|
|
425
|
+
}), children, enabled && /*#__PURE__*/_react.default.createElement(_reactNativeReanimated.default.View, {
|
|
426
|
+
style: layoutSpacerStyle
|
|
427
|
+
}));
|
|
428
|
+
}
|
|
392
429
|
return /*#__PURE__*/_react.default.createElement(_ScrollViewWithBottomPadding.default, _extends({
|
|
393
430
|
ref: onRef
|
|
394
431
|
}, rest, {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["_react","_interopRequireWildcard","require","_reactNativeReanimated","_bindings","_hooks","_findNodeHandle","_useCombinedRef","_interopRequireDefault","_useScrollState","_ScrollViewWithBottomPadding","_useSmoothKeyboardHandler","_utils","e","__esModule","default","t","WeakMap","r","n","o","i","f","__proto__","has","get","set","hasOwnProperty","call","Object","defineProperty","getOwnPropertyDescriptor","_extends","assign","bind","arguments","length","apply","KeyboardAwareScrollView","forwardRef","children","onLayout","bottomOffset","disableScrollOnKeyboardHide","enabled","extraKeyboardSpace","ScrollViewComponent","Reanimated","ScrollView","snapToOffsets","rest","ref","scrollViewAnimatedRef","useAnimatedRef","scrollViewRef","React","useRef","onRef","useCombinedRef","scrollViewTarget","useSharedValue","scrollPosition","offset","position","layout","scrollViewLayout","size","scrollViewContentSize","useScrollState","currentKeyboardFrameHeight","keyboardHeight","keyboardWillAppear","tag","initialKeyboardSize","scrollBeforeKeyboardMovement","input","update","useReanimatedFocusedInput","lastSelection","ghostViewSpace","pendingSelectionForFocus","selectionUpdatedSinceHide","scrollViewPageY","height","useWindowDimensions","onScrollViewLayout","useCallback","handle","findNodeHandle","current","value","y","KeyboardControllerNative","viewPositionInWindow","maybeScroll","animated","_layout$value","_layout$value2","_layout$value3","parentScrollViewTarget","visibleRect","absoluteY","inputHeight","point","relativeScrollTo","interpolatedScrollTo","interpolate","scrollDistanceWithRespectToSnapPoints","targetScrollY","Math","max","scrollTo","positionOnScreen","topOfScreen","removeGhostPadding","performScrollWithPositionRestoration","newPosition","prevScroll","syncKeyboardFrame","keyboardFrame","updateLayoutFromSelection","_lastSelection$value","_input$value","customHeight","selection","end","clamp","scrollFromCurrentPosition","prevLayout","onChangeText","onChangeTextHandler","useMemo","debounce","onSelectionChange","_lastSelection$value2","_lastSelection$value3","lastTarget","target","latestSelection","start","useFocusedInputHandler","useSmoothKeyboardHandler","onStart","keyboardWillChangeSize","keyboardWillHide","focusWasChanged","_lastSelection$value4","_lastSelection$value5","onMove","onEnd","synchronize","runOnUI","useImperativeHandle","scrollView","scrollViewWithMethods","assureFocusedInputVisible","useEffect","useAnimatedReaction","previous","padding","useDerivedValue","createElement","bottomPadding","scrollEventThrottle","_default","exports"],"sources":["index.tsx"],"sourcesContent":["import React, {\n forwardRef,\n useCallback,\n useEffect,\n useImperativeHandle,\n useMemo,\n} from \"react\";\nimport Reanimated, {\n clamp,\n interpolate,\n runOnUI,\n scrollTo,\n useAnimatedReaction,\n useAnimatedRef,\n useDerivedValue,\n useSharedValue,\n} from \"react-native-reanimated\";\n\nimport { KeyboardControllerNative } from \"../../bindings\";\nimport {\n useFocusedInputHandler,\n useReanimatedFocusedInput,\n useWindowDimensions,\n} from \"../../hooks\";\nimport { findNodeHandle } from \"../../utils/findNodeHandle\";\nimport useCombinedRef from \"../hooks/useCombinedRef\";\nimport useScrollState from \"../hooks/useScrollState\";\nimport ScrollViewWithBottomPadding from \"../ScrollViewWithBottomPadding\";\n\nimport { useSmoothKeyboardHandler } from \"./useSmoothKeyboardHandler\";\nimport { debounce, scrollDistanceWithRespectToSnapPoints } from \"./utils\";\n\nimport type { LayoutChangeEvent, ScrollView } from \"react-native\";\nimport type {\n FocusedInputLayoutChangedEvent,\n FocusedInputSelectionChangedEvent,\n KeyboardAwareScrollViewProps,\n KeyboardAwareScrollViewRef,\n NativeEvent,\n} from \"react-native-keyboard-controller\";\n\n// Everything begins from `onStart` handler. This handler is called every time,\n// when keyboard changes its size or when focused `TextInput` was changed. In\n// this handler we are calculating/memoizing values which later will be used\n// during layout movement. For that we calculate:\n// - layout of focused field (`layout`) - to understand whether there will be overlap\n// - initial keyboard size (`initialKeyboardSize`) - used in scroll interpolation\n// - future keyboard height (`keyboardHeight`) - used in scroll interpolation\n// - current scroll position (`scrollPosition`) - used to scroll from this point\n//\n// Once we've calculated all necessary variables - we can actually start to use them.\n// It happens in `onMove` handler - this function simply calls `maybeScroll` with\n// current keyboard frame height. This functions makes the smooth transition.\n//\n// When the transition has finished we go to `onEnd` handler. In this handler\n// we verify, that the current field is not overlapped within a keyboard frame.\n// For full `onStart`/`onMove`/`onEnd` flow it may look like a redundant thing,\n// however there could be some cases, when `onMove` is not called:\n// - on iOS when TextInput was changed - keyboard transition is instant\n// - on Android when TextInput was changed and keyboard size wasn't changed\n// So `onEnd` handler handle the case, when `onMove` wasn't triggered.\n//\n// ====================================================================================================================+\n// -----------------------------------------------------Flow chart-----------------------------------------------------+\n// ====================================================================================================================+\n//\n// +============================+ +============================+ +==================================+\n// + User Press on TextInput + => + Keyboard starts showing + => + As keyboard moves frame by frame + =>\n// + + + (run `onStart`) + + `onMove` is getting called +\n// +============================+ +============================+ +==================================+\n//\n// +============================+ +============================+ +=====================================+\n// + Keyboard is shown and we + => + User moved focus to + => + Only `onStart`/`onEnd` maybe called +\n// + call `onEnd` handler + + another `TextInput` + + (without involving `onMove`) +\n// +============================+ +============================+ +=====================================+\n//\n\n/**\n * A ScrollView component that automatically handles keyboard appearance and disappearance\n * by adjusting its content position to ensure the focused input remains visible.\n *\n * The component uses a sophisticated animation system to smoothly handle keyboard transitions\n * and maintain proper scroll position during keyboard interactions.\n *\n * @returns A ScrollView component that handles keyboard interactions.\n * @see {@link https://kirillzyusko.github.io/react-native-keyboard-controller/docs/api/components/keyboard-aware-scroll-view|Documentation} page for more details.\n * @example\n * ```tsx\n * <KeyboardAwareScrollView bottomOffset={20}>\n * <TextInput placeholder=\"Enter text\" />\n * <TextInput placeholder=\"Another input\" />\n * </KeyboardAwareScrollView>\n * ```\n */\nconst KeyboardAwareScrollView = forwardRef<\n KeyboardAwareScrollViewRef,\n React.PropsWithChildren<KeyboardAwareScrollViewProps>\n>(\n (\n {\n children,\n onLayout,\n bottomOffset = 0,\n disableScrollOnKeyboardHide = false,\n enabled = true,\n extraKeyboardSpace = 0,\n ScrollViewComponent = Reanimated.ScrollView,\n snapToOffsets,\n ...rest\n },\n ref,\n ) => {\n const scrollViewAnimatedRef = useAnimatedRef<Reanimated.ScrollView>();\n const scrollViewRef = React.useRef<ScrollView>(null);\n const onRef = useCombinedRef(scrollViewAnimatedRef, scrollViewRef);\n const scrollViewTarget = useSharedValue<number | null>(null);\n const scrollPosition = useSharedValue(0);\n const {\n offset: position,\n layout: scrollViewLayout,\n size: scrollViewContentSize,\n } = useScrollState(scrollViewAnimatedRef);\n const currentKeyboardFrameHeight = useSharedValue(0);\n const keyboardHeight = useSharedValue(0);\n const keyboardWillAppear = useSharedValue(false);\n const tag = useSharedValue(-1);\n const initialKeyboardSize = useSharedValue(0);\n const scrollBeforeKeyboardMovement = useSharedValue(0);\n const { input, update } = useReanimatedFocusedInput();\n const layout = useSharedValue<FocusedInputLayoutChangedEvent | null>(null);\n const lastSelection =\n useSharedValue<FocusedInputSelectionChangedEvent | null>(null);\n const ghostViewSpace = useSharedValue(-1);\n const pendingSelectionForFocus = useSharedValue(false);\n const selectionUpdatedSinceHide = useSharedValue(false);\n const scrollViewPageY = useSharedValue(0);\n\n const { height } = useWindowDimensions();\n\n const onScrollViewLayout = useCallback(\n async (e: LayoutChangeEvent) => {\n const handle = findNodeHandle(scrollViewAnimatedRef.current);\n\n scrollViewTarget.value = handle;\n\n onLayout?.(e);\n\n if (handle !== null) {\n try {\n const { y } = await KeyboardControllerNative.viewPositionInWindow(\n handle,\n );\n\n scrollViewPageY.value = y;\n } catch {\n // ignore\n }\n }\n },\n [onLayout],\n );\n\n /**\n * Function that will scroll a ScrollView as keyboard gets moving.\n */\n const maybeScroll = useCallback(\n (e: number, animated: boolean = false) => {\n \"worklet\";\n\n if (!enabled) {\n return 0;\n }\n\n // input belongs to ScrollView\n if (layout.value?.parentScrollViewTarget !== scrollViewTarget.value) {\n return 0;\n }\n\n const visibleRect = height - keyboardHeight.value;\n const absoluteY = layout.value?.layout.absoluteY || 0;\n const inputHeight = layout.value?.layout.height || 0;\n const point = absoluteY + inputHeight;\n\n if (visibleRect - point <= bottomOffset) {\n const relativeScrollTo =\n keyboardHeight.value - (height - point) + bottomOffset;\n const interpolatedScrollTo = interpolate(\n e,\n [initialKeyboardSize.value, keyboardHeight.value],\n [\n 0,\n scrollDistanceWithRespectToSnapPoints(\n relativeScrollTo + scrollPosition.value,\n snapToOffsets,\n ) - scrollPosition.value,\n ],\n );\n const targetScrollY =\n Math.max(interpolatedScrollTo, 0) + scrollPosition.value;\n\n scrollTo(scrollViewAnimatedRef, 0, targetScrollY, animated);\n\n return interpolatedScrollTo;\n }\n\n if (point < scrollViewPageY.value) {\n const positionOnScreen = visibleRect - bottomOffset;\n const topOfScreen = scrollPosition.value + point;\n\n scrollTo(\n scrollViewAnimatedRef,\n 0,\n topOfScreen - positionOnScreen,\n animated,\n );\n }\n\n return 0;\n },\n [bottomOffset, enabled, height, snapToOffsets],\n );\n const removeGhostPadding = useCallback((e: number) => {\n \"worklet\";\n\n // new `ScrollViewWithBottomPadding` behavior: if we hide keyboard and we are in the end of `ScrollView`\n // then we always need to scroll back, because we apply a padding that doesn't change layout, so we will\n // not have auto scroll back in this case\n if (!keyboardWillAppear.value && ghostViewSpace.value > 0) {\n scrollTo(\n scrollViewAnimatedRef,\n 0,\n scrollPosition.value -\n interpolate(\n e,\n [initialKeyboardSize.value, keyboardHeight.value],\n [ghostViewSpace.value, 0],\n ),\n false,\n );\n\n return true;\n }\n\n return false;\n }, []);\n const performScrollWithPositionRestoration = useCallback(\n (newPosition: number) => {\n \"worklet\";\n\n const prevScroll = scrollPosition.value;\n\n // eslint-disable-next-line react-compiler/react-compiler\n scrollPosition.value = newPosition;\n maybeScroll(keyboardHeight.value, true);\n scrollPosition.value = prevScroll;\n },\n [scrollPosition, keyboardHeight, maybeScroll],\n );\n const syncKeyboardFrame = useCallback(\n (e: NativeEvent) => {\n \"worklet\";\n\n const keyboardFrame = interpolate(\n e.height,\n [0, keyboardHeight.value],\n [0, keyboardHeight.value + extraKeyboardSpace],\n );\n\n currentKeyboardFrameHeight.value = keyboardFrame;\n },\n [extraKeyboardSpace],\n );\n\n const updateLayoutFromSelection = useCallback(() => {\n \"worklet\";\n\n const customHeight = lastSelection.value?.selection.end.y;\n\n if (!input.value?.layout || !customHeight) {\n return false;\n }\n\n layout.value = {\n ...input.value,\n layout: {\n ...input.value.layout,\n // when we have multiline input with limited amount of lines, then custom height can be very big\n // so we clamp it to max input height\n height: clamp(customHeight, 0, input.value.layout.height),\n },\n };\n\n return true;\n }, [input, lastSelection, layout]);\n const scrollFromCurrentPosition = useCallback(() => {\n \"worklet\";\n\n const prevLayout = layout.value;\n\n if (!updateLayoutFromSelection()) {\n return;\n }\n\n performScrollWithPositionRestoration(position.value);\n\n layout.value = prevLayout;\n }, [performScrollWithPositionRestoration]);\n const onChangeText = useCallback(() => {\n \"worklet\";\n scrollFromCurrentPosition();\n }, [scrollFromCurrentPosition]);\n const onChangeTextHandler = useMemo(\n () => debounce(onChangeText, 200),\n [onChangeText],\n );\n const onSelectionChange = useCallback(\n (e: FocusedInputSelectionChangedEvent) => {\n \"worklet\";\n\n const lastTarget = lastSelection.value?.target;\n const latestSelection = lastSelection.value?.selection;\n\n lastSelection.value = e;\n selectionUpdatedSinceHide.value = true;\n\n if (e.target !== lastTarget || pendingSelectionForFocus.value) {\n if (pendingSelectionForFocus.value) {\n // selection arrived after onStart - complete the deferred setup\n pendingSelectionForFocus.value = false;\n updateLayoutFromSelection();\n\n // if keyboard was already visible (focus change, no onMove expected),\n // perform the deferred scroll now\n if (!keyboardWillAppear.value && keyboardHeight.value > 0) {\n position.value += maybeScroll(keyboardHeight.value, true);\n }\n }\n\n return;\n }\n // caret in the end + end coordinates has been changed -> we moved to a new line\n // so input may grow\n if (\n e.selection.end.position === e.selection.start.position &&\n latestSelection?.end.y !== e.selection.end.y\n ) {\n return scrollFromCurrentPosition();\n }\n // selection has been changed\n if (e.selection.start.position !== e.selection.end.position) {\n return scrollFromCurrentPosition();\n }\n\n onChangeTextHandler();\n },\n [\n scrollFromCurrentPosition,\n onChangeTextHandler,\n updateLayoutFromSelection,\n maybeScroll,\n ],\n );\n\n useFocusedInputHandler(\n {\n onSelectionChange: onSelectionChange,\n },\n [onSelectionChange],\n );\n\n useSmoothKeyboardHandler(\n {\n onStart: (e) => {\n \"worklet\";\n\n const keyboardWillChangeSize =\n keyboardHeight.value !== e.height && e.height > 0;\n\n keyboardWillAppear.value = e.height > 0 && keyboardHeight.value === 0;\n\n const keyboardWillHide = e.height === 0;\n const focusWasChanged =\n (tag.value !== e.target && e.target !== -1) ||\n keyboardWillChangeSize;\n\n if (keyboardWillChangeSize) {\n initialKeyboardSize.value = keyboardHeight.value;\n }\n\n if (keyboardWillHide) {\n // on back transition need to interpolate as [0, keyboardHeight]\n initialKeyboardSize.value = 0;\n scrollPosition.value = scrollBeforeKeyboardMovement.value;\n pendingSelectionForFocus.value = false;\n }\n\n if (\n keyboardWillAppear.value ||\n keyboardWillChangeSize ||\n focusWasChanged\n ) {\n // persist scroll value\n scrollPosition.value = position.value;\n // just persist height - later will be used in interpolation\n keyboardHeight.value = e.height;\n // and update keyboard spacer size\n syncKeyboardFrame(e);\n }\n\n // focus was changed\n if (focusWasChanged) {\n tag.value = e.target;\n\n if (\n lastSelection.value?.target === e.target &&\n selectionUpdatedSinceHide.value\n ) {\n // fresh selection arrived before onStart - use it to update layout\n updateLayoutFromSelection();\n pendingSelectionForFocus.value = false;\n } else {\n // selection hasn't arrived yet for the new target (iOS 15),\n // or it's stale from previous session (Android refocus same input).\n // Use stale selection as best-effort fallback if available for same target,\n // otherwise fall back to full input layout.\n // Will be corrected if a fresh onSelectionChange arrives.\n if (lastSelection.value?.target === e.target) {\n updateLayoutFromSelection();\n } else if (input.value) {\n layout.value = input.value;\n }\n pendingSelectionForFocus.value = true;\n }\n\n // save current scroll position - when keyboard will hide we'll reuse\n // this value to achieve smooth hide effect\n scrollBeforeKeyboardMovement.value = position.value;\n }\n\n if (focusWasChanged && !keyboardWillAppear.value) {\n if (!pendingSelectionForFocus.value) {\n // update position on scroll value, so `onEnd` handler\n // will pick up correct values\n position.value += maybeScroll(e.height, true);\n }\n }\n\n ghostViewSpace.value =\n position.value +\n scrollViewLayout.value.height -\n scrollViewContentSize.value.height;\n\n if (ghostViewSpace.value > 0) {\n scrollPosition.value = position.value;\n }\n },\n onMove: (e) => {\n \"worklet\";\n\n if (removeGhostPadding(e.height)) {\n return;\n }\n\n // if the user has set disableScrollOnKeyboardHide, only auto-scroll when the keyboard opens\n if (!disableScrollOnKeyboardHide || keyboardWillAppear.value) {\n maybeScroll(e.height);\n }\n },\n onEnd: (e) => {\n \"worklet\";\n\n removeGhostPadding(e.height);\n\n keyboardHeight.value = e.height;\n scrollPosition.value = position.value;\n\n if (e.height === 0) {\n selectionUpdatedSinceHide.value = false;\n } else if (keyboardWillAppear.value) {\n // keyboard fully shown after appearing from hidden state — clear\n // pending flag to prevent leaking into next focus-change session.\n // Only when the keyboard was actually appearing (not a focus switch\n // with same keyboard height), otherwise we'd clear the flag before\n // onSelectionChange has a chance to process it.\n pendingSelectionForFocus.value = false;\n }\n\n syncKeyboardFrame(e);\n },\n },\n [\n maybeScroll,\n removeGhostPadding,\n disableScrollOnKeyboardHide,\n syncKeyboardFrame,\n ],\n );\n\n const synchronize = useCallback(async () => {\n await update();\n\n runOnUI(() => {\n \"worklet\";\n\n scrollFromCurrentPosition();\n })();\n }, [update, scrollFromCurrentPosition]);\n\n useImperativeHandle(\n ref,\n () => {\n const scrollView = scrollViewRef.current;\n\n if (scrollView) {\n const scrollViewWithMethods =\n scrollView as KeyboardAwareScrollViewRef;\n\n scrollViewWithMethods.assureFocusedInputVisible = () => {\n synchronize();\n };\n\n return scrollViewWithMethods;\n }\n\n return {\n assureFocusedInputVisible: () => {\n synchronize();\n },\n } as KeyboardAwareScrollViewRef;\n },\n [synchronize],\n );\n\n useEffect(() => {\n synchronize();\n }, [bottomOffset]);\n\n useAnimatedReaction(\n () => input.value,\n (current, previous) => {\n if (\n current?.target === previous?.target &&\n current?.layout.height !== previous?.layout.height\n ) {\n // input has changed layout - let's check if we need to scroll\n // may happen when you paste text, then onSelectionChange will be\n // fired earlier than text actually changes its layout\n scrollFromCurrentPosition();\n }\n },\n [],\n );\n\n const padding = useDerivedValue(\n () => (enabled ? currentKeyboardFrameHeight.value : 0),\n [enabled],\n );\n\n return (\n <ScrollViewWithBottomPadding\n ref={onRef}\n {...rest}\n bottomPadding={padding}\n scrollEventThrottle={16}\n ScrollViewComponent={ScrollViewComponent}\n onLayout={onScrollViewLayout}\n >\n {children}\n </ScrollViewWithBottomPadding>\n );\n },\n);\n\nexport default KeyboardAwareScrollView;\n"],"mappings":";;;;;;AAAA,IAAAA,MAAA,GAAAC,uBAAA,CAAAC,OAAA;AAOA,IAAAC,sBAAA,GAAAF,uBAAA,CAAAC,OAAA;AAWA,IAAAE,SAAA,GAAAF,OAAA;AACA,IAAAG,MAAA,GAAAH,OAAA;AAKA,IAAAI,eAAA,GAAAJ,OAAA;AACA,IAAAK,eAAA,GAAAC,sBAAA,CAAAN,OAAA;AACA,IAAAO,eAAA,GAAAD,sBAAA,CAAAN,OAAA;AACA,IAAAQ,4BAAA,GAAAF,sBAAA,CAAAN,OAAA;AAEA,IAAAS,yBAAA,GAAAT,OAAA;AACA,IAAAU,MAAA,GAAAV,OAAA;AAA0E,SAAAM,uBAAAK,CAAA,WAAAA,CAAA,IAAAA,CAAA,CAAAC,UAAA,GAAAD,CAAA,KAAAE,OAAA,EAAAF,CAAA;AAAA,SAAAZ,wBAAAY,CAAA,EAAAG,CAAA,6BAAAC,OAAA,MAAAC,CAAA,OAAAD,OAAA,IAAAE,CAAA,OAAAF,OAAA,YAAAhB,uBAAA,YAAAA,CAAAY,CAAA,EAAAG,CAAA,SAAAA,CAAA,IAAAH,CAAA,IAAAA,CAAA,CAAAC,UAAA,SAAAD,CAAA,MAAAO,CAAA,EAAAC,CAAA,EAAAC,CAAA,KAAAC,SAAA,QAAAR,OAAA,EAAAF,CAAA,iBAAAA,CAAA,uBAAAA,CAAA,yBAAAA,CAA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AC,sCAAe,EAC7B,MAAOpH,OAAO,GAAGyB,0BAA0B,CAACqB,KAAK,GAAG,CAAE,EACtD,CAAC9C,OAAO,CACV,CAAC;EAED,oBACE5C,MAAA,CAAAe,OAAA,CAAAkJ,aAAA,CAACvJ,4BAAA,CAAAK,OAA2B,EAAAiB,QAAA;IAC1BmB,GAAG,EAAEM;EAAM,GACPP,IAAI;IACRgH,aAAa,EAAEH,OAAQ;IACvBI,mBAAmB,EAAE,EAAG;IACxBrH,mBAAmB,EAAEA,mBAAoB;IACzCL,QAAQ,EAAE4C;EAAmB,IAE5B7C,QAC0B,CAAC;AAElC,CACF,CAAC;AAAC,IAAA4H,QAAA,GAAAC,OAAA,CAAAtJ,OAAA,GAEauB,uBAAuB","ignoreList":[]}
|
|
1
|
+
{"version":3,"names":["_react","_interopRequireWildcard","require","_reactNativeReanimated","_bindings","_hooks","_findNodeHandle","_useCombinedRef","_interopRequireDefault","_useScrollState","_ScrollViewWithBottomPadding","_useSmoothKeyboardHandler","_utils","e","__esModule","default","t","WeakMap","r","n","o","i","f","__proto__","has","get","set","hasOwnProperty","call","Object","defineProperty","getOwnPropertyDescriptor","_extends","assign","bind","arguments","length","apply","KeyboardAwareScrollView","forwardRef","children","onLayout","bottomOffset","disableScrollOnKeyboardHide","enabled","extraKeyboardSpace","mode","ScrollViewComponent","Reanimated","ScrollView","snapToOffsets","rest","ref","scrollViewAnimatedRef","useAnimatedRef","scrollViewRef","React","useRef","onRef","useCombinedRef","scrollViewTarget","useSharedValue","scrollPosition","offset","position","layout","scrollViewLayout","size","scrollViewContentSize","useScrollState","currentKeyboardFrameHeight","keyboardHeight","keyboardWillAppear","tag","initialKeyboardSize","scrollBeforeKeyboardMovement","input","update","useReanimatedFocusedInput","lastSelection","ghostViewSpace","pendingSelectionForFocus","selectionUpdatedSinceHide","scrollViewPageY","height","useWindowDimensions","onScrollViewLayout","useCallback","handle","findNodeHandle","current","value","y","KeyboardControllerNative","viewPositionInWindow","maybeScroll","animated","_layout$value","_layout$value2","_layout$value3","parentScrollViewTarget","visibleRect","absoluteY","inputHeight","point","relativeScrollTo","interpolatedScrollTo","interpolate","scrollDistanceWithRespectToSnapPoints","targetScrollY","Math","max","scrollTo","positionOnScreen","topOfScreen","removeGhostPadding","performScrollWithPositionRestoration","newPosition","prevScroll","syncKeyboardFrame","keyboardFrame","updateLayoutFromSelection","_lastSelection$value","_input$value","customHeight","selection","end","clamp","scrollFromCurrentPosition","prevLayout","onChangeText","onChangeTextHandler","useMemo","debounce","onSelectionChange","_lastSelection$value2","_lastSelection$value3","lastTarget","target","latestSelection","start","useFocusedInputHandler","useSmoothKeyboardHandler","onStart","keyboardWillChangeSize","keyboardWillHide","focusWasChanged","_lastSelection$value4","_lastSelection$value5","onMove","onEnd","synchronize","runOnUI","useImperativeHandle","scrollView","scrollViewWithMethods","assureFocusedInputVisible","useEffect","useAnimatedReaction","previous","padding","useDerivedValue","layoutSpacerStyle","useAnimatedStyle","paddingBottom","createElement","scrollEventThrottle","View","style","bottomPadding","_default","exports"],"sources":["index.tsx"],"sourcesContent":["import React, {\n forwardRef,\n useCallback,\n useEffect,\n useImperativeHandle,\n useMemo,\n} from \"react\";\nimport Reanimated, {\n clamp,\n interpolate,\n runOnUI,\n scrollTo,\n useAnimatedReaction,\n useAnimatedRef,\n useAnimatedStyle,\n useDerivedValue,\n useSharedValue,\n} from \"react-native-reanimated\";\n\nimport { KeyboardControllerNative } from \"../../bindings\";\nimport {\n useFocusedInputHandler,\n useReanimatedFocusedInput,\n useWindowDimensions,\n} from \"../../hooks\";\nimport { findNodeHandle } from \"../../utils/findNodeHandle\";\nimport useCombinedRef from \"../hooks/useCombinedRef\";\nimport useScrollState from \"../hooks/useScrollState\";\nimport ScrollViewWithBottomPadding from \"../ScrollViewWithBottomPadding\";\n\nimport { useSmoothKeyboardHandler } from \"./useSmoothKeyboardHandler\";\nimport { debounce, scrollDistanceWithRespectToSnapPoints } from \"./utils\";\n\nimport type { LayoutChangeEvent, ScrollView } from \"react-native\";\nimport type {\n FocusedInputLayoutChangedEvent,\n FocusedInputSelectionChangedEvent,\n KeyboardAwareScrollViewProps,\n KeyboardAwareScrollViewRef,\n NativeEvent,\n} from \"react-native-keyboard-controller\";\n\n// Everything begins from `onStart` handler. This handler is called every time,\n// when keyboard changes its size or when focused `TextInput` was changed. In\n// this handler we are calculating/memoizing values which later will be used\n// during layout movement. For that we calculate:\n// - layout of focused field (`layout`) - to understand whether there will be overlap\n// - initial keyboard size (`initialKeyboardSize`) - used in scroll interpolation\n// - future keyboard height (`keyboardHeight`) - used in scroll interpolation\n// - current scroll position (`scrollPosition`) - used to scroll from this point\n//\n// Once we've calculated all necessary variables - we can actually start to use them.\n// It happens in `onMove` handler - this function simply calls `maybeScroll` with\n// current keyboard frame height. This functions makes the smooth transition.\n//\n// When the transition has finished we go to `onEnd` handler. In this handler\n// we verify, that the current field is not overlapped within a keyboard frame.\n// For full `onStart`/`onMove`/`onEnd` flow it may look like a redundant thing,\n// however there could be some cases, when `onMove` is not called:\n// - on iOS when TextInput was changed - keyboard transition is instant\n// - on Android when TextInput was changed and keyboard size wasn't changed\n// So `onEnd` handler handle the case, when `onMove` wasn't triggered.\n//\n// ====================================================================================================================+\n// -----------------------------------------------------Flow chart-----------------------------------------------------+\n// ====================================================================================================================+\n//\n// +============================+ +============================+ +==================================+\n// + User Press on TextInput + => + Keyboard starts showing + => + As keyboard moves frame by frame + =>\n// + + + (run `onStart`) + + `onMove` is getting called +\n// +============================+ +============================+ +==================================+\n//\n// +============================+ +============================+ +=====================================+\n// + Keyboard is shown and we + => + User moved focus to + => + Only `onStart`/`onEnd` maybe called +\n// + call `onEnd` handler + + another `TextInput` + + (without involving `onMove`) +\n// +============================+ +============================+ +=====================================+\n//\n\n/**\n * A ScrollView component that automatically handles keyboard appearance and disappearance\n * by adjusting its content position to ensure the focused input remains visible.\n *\n * The component uses a sophisticated animation system to smoothly handle keyboard transitions\n * and maintain proper scroll position during keyboard interactions.\n *\n * @returns A ScrollView component that handles keyboard interactions.\n * @see {@link https://kirillzyusko.github.io/react-native-keyboard-controller/docs/api/components/keyboard-aware-scroll-view|Documentation} page for more details.\n * @example\n * ```tsx\n * <KeyboardAwareScrollView bottomOffset={20}>\n * <TextInput placeholder=\"Enter text\" />\n * <TextInput placeholder=\"Another input\" />\n * </KeyboardAwareScrollView>\n * ```\n */\nconst KeyboardAwareScrollView = forwardRef<\n KeyboardAwareScrollViewRef,\n React.PropsWithChildren<KeyboardAwareScrollViewProps>\n>(\n (\n {\n children,\n onLayout,\n bottomOffset = 0,\n disableScrollOnKeyboardHide = false,\n enabled = true,\n extraKeyboardSpace = 0,\n mode = \"insets\",\n ScrollViewComponent = Reanimated.ScrollView,\n snapToOffsets,\n ...rest\n },\n ref,\n ) => {\n const scrollViewAnimatedRef = useAnimatedRef<Reanimated.ScrollView>();\n const scrollViewRef = React.useRef<ScrollView>(null);\n const onRef = useCombinedRef(scrollViewAnimatedRef, scrollViewRef);\n const scrollViewTarget = useSharedValue<number | null>(null);\n const scrollPosition = useSharedValue(0);\n const {\n offset: position,\n layout: scrollViewLayout,\n size: scrollViewContentSize,\n } = useScrollState(scrollViewAnimatedRef);\n const currentKeyboardFrameHeight = useSharedValue(0);\n const keyboardHeight = useSharedValue(0);\n const keyboardWillAppear = useSharedValue(false);\n const tag = useSharedValue(-1);\n const initialKeyboardSize = useSharedValue(0);\n const scrollBeforeKeyboardMovement = useSharedValue(0);\n const { input, update } = useReanimatedFocusedInput();\n const layout = useSharedValue<FocusedInputLayoutChangedEvent | null>(null);\n const lastSelection =\n useSharedValue<FocusedInputSelectionChangedEvent | null>(null);\n const ghostViewSpace = useSharedValue(-1);\n const pendingSelectionForFocus = useSharedValue(false);\n const selectionUpdatedSinceHide = useSharedValue(false);\n const scrollViewPageY = useSharedValue(0);\n\n const { height } = useWindowDimensions();\n\n const onScrollViewLayout = useCallback(\n async (e: LayoutChangeEvent) => {\n const handle = findNodeHandle(scrollViewAnimatedRef.current);\n\n scrollViewTarget.value = handle;\n\n onLayout?.(e);\n\n if (handle !== null) {\n try {\n const { y } = await KeyboardControllerNative.viewPositionInWindow(\n handle,\n );\n\n scrollViewPageY.value = y;\n } catch {\n // ignore\n }\n }\n },\n [onLayout],\n );\n\n /**\n * Function that will scroll a ScrollView as keyboard gets moving.\n */\n const maybeScroll = useCallback(\n (e: number, animated: boolean = false) => {\n \"worklet\";\n\n if (!enabled) {\n return 0;\n }\n\n // input belongs to ScrollView\n if (layout.value?.parentScrollViewTarget !== scrollViewTarget.value) {\n return 0;\n }\n\n const visibleRect = height - keyboardHeight.value;\n const absoluteY = layout.value?.layout.absoluteY || 0;\n const inputHeight = layout.value?.layout.height || 0;\n const point = absoluteY + inputHeight;\n\n if (visibleRect - point <= bottomOffset) {\n const relativeScrollTo =\n keyboardHeight.value - (height - point) + bottomOffset;\n const interpolatedScrollTo = interpolate(\n e,\n [initialKeyboardSize.value, keyboardHeight.value],\n [\n 0,\n scrollDistanceWithRespectToSnapPoints(\n relativeScrollTo + scrollPosition.value,\n snapToOffsets,\n ) - scrollPosition.value,\n ],\n );\n const targetScrollY =\n Math.max(interpolatedScrollTo, 0) + scrollPosition.value;\n\n scrollTo(scrollViewAnimatedRef, 0, targetScrollY, animated);\n\n return interpolatedScrollTo;\n }\n\n if (point < scrollViewPageY.value) {\n const positionOnScreen = visibleRect - bottomOffset;\n const topOfScreen = scrollPosition.value + point;\n\n scrollTo(\n scrollViewAnimatedRef,\n 0,\n topOfScreen - positionOnScreen,\n animated,\n );\n }\n\n return 0;\n },\n [bottomOffset, enabled, height, snapToOffsets],\n );\n const removeGhostPadding = useCallback(\n (e: number) => {\n \"worklet\";\n\n // layout mode: the spacer view participates in layout, so the ScrollView\n // reflows naturally when it shrinks — no manual scroll correction needed.\n if (mode === \"layout\") {\n return false;\n }\n\n // insets mode: `ScrollViewWithBottomPadding` extends scrollable area without\n // changing layout, so when the keyboard hides and we're at the end of the\n // ScrollView we must manually scroll back.\n if (!keyboardWillAppear.value && ghostViewSpace.value > 0) {\n scrollTo(\n scrollViewAnimatedRef,\n 0,\n scrollPosition.value -\n interpolate(\n e,\n [initialKeyboardSize.value, keyboardHeight.value],\n [ghostViewSpace.value, 0],\n ),\n false,\n );\n\n return true;\n }\n\n return false;\n },\n [mode],\n );\n const performScrollWithPositionRestoration = useCallback(\n (newPosition: number) => {\n \"worklet\";\n\n const prevScroll = scrollPosition.value;\n\n // eslint-disable-next-line react-compiler/react-compiler\n scrollPosition.value = newPosition;\n maybeScroll(keyboardHeight.value, true);\n scrollPosition.value = prevScroll;\n },\n [scrollPosition, keyboardHeight, maybeScroll],\n );\n const syncKeyboardFrame = useCallback(\n (e: NativeEvent) => {\n \"worklet\";\n\n const keyboardFrame = interpolate(\n e.height,\n [0, keyboardHeight.value],\n [0, keyboardHeight.value + extraKeyboardSpace],\n );\n\n currentKeyboardFrameHeight.value = keyboardFrame;\n },\n [extraKeyboardSpace],\n );\n\n const updateLayoutFromSelection = useCallback(() => {\n \"worklet\";\n\n const customHeight = lastSelection.value?.selection.end.y;\n\n if (!input.value?.layout || !customHeight) {\n return false;\n }\n\n layout.value = {\n ...input.value,\n layout: {\n ...input.value.layout,\n // when we have multiline input with limited amount of lines, then custom height can be very big\n // so we clamp it to max input height\n height: clamp(customHeight, 0, input.value.layout.height),\n },\n };\n\n return true;\n }, [input, lastSelection, layout]);\n const scrollFromCurrentPosition = useCallback(() => {\n \"worklet\";\n\n const prevLayout = layout.value;\n\n if (!updateLayoutFromSelection()) {\n return;\n }\n\n performScrollWithPositionRestoration(position.value);\n\n layout.value = prevLayout;\n }, [performScrollWithPositionRestoration]);\n const onChangeText = useCallback(() => {\n \"worklet\";\n scrollFromCurrentPosition();\n }, [scrollFromCurrentPosition]);\n const onChangeTextHandler = useMemo(\n () => debounce(onChangeText, 200),\n [onChangeText],\n );\n const onSelectionChange = useCallback(\n (e: FocusedInputSelectionChangedEvent) => {\n \"worklet\";\n\n const lastTarget = lastSelection.value?.target;\n const latestSelection = lastSelection.value?.selection;\n\n lastSelection.value = e;\n selectionUpdatedSinceHide.value = true;\n\n if (e.target !== lastTarget || pendingSelectionForFocus.value) {\n if (pendingSelectionForFocus.value) {\n // selection arrived after onStart - complete the deferred setup\n pendingSelectionForFocus.value = false;\n updateLayoutFromSelection();\n\n // if keyboard was already visible (focus change, no onMove expected),\n // perform the deferred scroll now\n if (!keyboardWillAppear.value && keyboardHeight.value > 0) {\n position.value += maybeScroll(keyboardHeight.value, true);\n }\n }\n\n return;\n }\n // caret in the end + end coordinates has been changed -> we moved to a new line\n // so input may grow\n if (\n e.selection.end.position === e.selection.start.position &&\n latestSelection?.end.y !== e.selection.end.y\n ) {\n return scrollFromCurrentPosition();\n }\n // selection has been changed\n if (e.selection.start.position !== e.selection.end.position) {\n return scrollFromCurrentPosition();\n }\n\n onChangeTextHandler();\n },\n [\n scrollFromCurrentPosition,\n onChangeTextHandler,\n updateLayoutFromSelection,\n maybeScroll,\n ],\n );\n\n useFocusedInputHandler(\n {\n onSelectionChange: onSelectionChange,\n },\n [onSelectionChange],\n );\n\n useSmoothKeyboardHandler(\n {\n onStart: (e) => {\n \"worklet\";\n\n const keyboardWillChangeSize =\n keyboardHeight.value !== e.height && e.height > 0;\n\n keyboardWillAppear.value = e.height > 0 && keyboardHeight.value === 0;\n\n const keyboardWillHide = e.height === 0;\n const focusWasChanged =\n (tag.value !== e.target && e.target !== -1) ||\n keyboardWillChangeSize;\n\n if (keyboardWillChangeSize) {\n initialKeyboardSize.value = keyboardHeight.value;\n }\n\n if (keyboardWillHide) {\n // on back transition need to interpolate as [0, keyboardHeight]\n initialKeyboardSize.value = 0;\n scrollPosition.value = scrollBeforeKeyboardMovement.value;\n pendingSelectionForFocus.value = false;\n }\n\n if (\n keyboardWillAppear.value ||\n keyboardWillChangeSize ||\n focusWasChanged\n ) {\n // persist scroll value\n scrollPosition.value = position.value;\n // just persist height - later will be used in interpolation\n keyboardHeight.value = e.height;\n\n // insets mode: set the full contentInset upfront so that maybeScroll\n // calculations are correct from the very first onMove frame.\n // layout mode: do NOT set it here — the spacer must grow frame-by-frame\n // in onMove to avoid a premature full-height jump before the keyboard moves.\n if (mode === \"insets\") {\n syncKeyboardFrame(e);\n }\n }\n\n // focus was changed\n if (focusWasChanged) {\n tag.value = e.target;\n\n if (\n lastSelection.value?.target === e.target &&\n selectionUpdatedSinceHide.value\n ) {\n // fresh selection arrived before onStart - use it to update layout\n updateLayoutFromSelection();\n pendingSelectionForFocus.value = false;\n } else {\n // selection hasn't arrived yet for the new target (iOS 15),\n // or it's stale from previous session (Android refocus same input).\n // Use stale selection as best-effort fallback if available for same target,\n // otherwise fall back to full input layout.\n // Will be corrected if a fresh onSelectionChange arrives.\n if (lastSelection.value?.target === e.target) {\n updateLayoutFromSelection();\n } else if (input.value) {\n layout.value = input.value;\n }\n pendingSelectionForFocus.value = true;\n }\n\n // save current scroll position - when keyboard will hide we'll reuse\n // this value to achieve smooth hide effect\n scrollBeforeKeyboardMovement.value = position.value;\n }\n\n if (focusWasChanged && !keyboardWillAppear.value) {\n if (!pendingSelectionForFocus.value) {\n // update position on scroll value, so `onEnd` handler\n // will pick up correct values\n position.value += maybeScroll(e.height, true);\n }\n }\n\n if (mode === \"insets\") {\n ghostViewSpace.value =\n position.value +\n scrollViewLayout.value.height -\n scrollViewContentSize.value.height;\n\n if (ghostViewSpace.value > 0) {\n scrollPosition.value = position.value;\n }\n }\n },\n onMove: (e) => {\n \"worklet\";\n\n if (removeGhostPadding(e.height)) {\n return;\n }\n\n // layout mode: drive the spacer view animation frame-by-frame\n if (mode === \"layout\") {\n syncKeyboardFrame(e);\n }\n\n // if the user has set disableScrollOnKeyboardHide, only auto-scroll when the keyboard opens\n if (!disableScrollOnKeyboardHide || keyboardWillAppear.value) {\n maybeScroll(e.height);\n }\n },\n onEnd: (e) => {\n \"worklet\";\n\n removeGhostPadding(e.height);\n\n keyboardHeight.value = e.height;\n scrollPosition.value = position.value;\n\n if (e.height === 0) {\n selectionUpdatedSinceHide.value = false;\n } else if (keyboardWillAppear.value) {\n // keyboard fully shown after appearing from hidden state — clear\n // pending flag to prevent leaking into next focus-change session.\n // Only when the keyboard was actually appearing (not a focus switch\n // with same keyboard height), otherwise we'd clear the flag before\n // onSelectionChange has a chance to process it.\n pendingSelectionForFocus.value = false;\n }\n\n syncKeyboardFrame(e);\n },\n },\n [\n mode,\n maybeScroll,\n removeGhostPadding,\n disableScrollOnKeyboardHide,\n syncKeyboardFrame,\n ],\n );\n\n const synchronize = useCallback(async () => {\n await update();\n\n runOnUI(() => {\n \"worklet\";\n\n scrollFromCurrentPosition();\n })();\n }, [update, scrollFromCurrentPosition]);\n\n useImperativeHandle(\n ref,\n () => {\n const scrollView = scrollViewRef.current;\n\n if (scrollView) {\n const scrollViewWithMethods =\n scrollView as KeyboardAwareScrollViewRef;\n\n scrollViewWithMethods.assureFocusedInputVisible = () => {\n synchronize();\n };\n\n return scrollViewWithMethods;\n }\n\n return {\n assureFocusedInputVisible: () => {\n synchronize();\n },\n } as KeyboardAwareScrollViewRef;\n },\n [synchronize],\n );\n\n useEffect(() => {\n synchronize();\n }, [bottomOffset]);\n\n useAnimatedReaction(\n () => input.value,\n (current, previous) => {\n if (\n current?.target === previous?.target &&\n current?.layout.height !== previous?.layout.height\n ) {\n // input has changed layout - let's check if we need to scroll\n // may happen when you paste text, then onSelectionChange will be\n // fired earlier than text actually changes its layout\n scrollFromCurrentPosition();\n }\n },\n [],\n );\n\n const padding = useDerivedValue(\n () => (enabled ? currentKeyboardFrameHeight.value : 0),\n [enabled],\n );\n // layout mode only: a spacer view whose paddingBottom grows with the keyboard.\n // The `+ 1` ensures the scroll view never reaches its absolute end during animation,\n // avoiding the layout recalculation that triggers on every frame at the boundary.\n // see: https://github.com/kirillzyusko/react-native-keyboard-controller/pull/342\n const layoutSpacerStyle = useAnimatedStyle(\n () =>\n enabled && mode === \"layout\"\n ? { paddingBottom: currentKeyboardFrameHeight.value + 1 }\n : {},\n [enabled, mode],\n );\n\n if (mode === \"layout\") {\n return (\n <ScrollViewComponent\n ref={onRef}\n {...rest}\n scrollEventThrottle={16}\n onLayout={onScrollViewLayout}\n >\n {children}\n {enabled && <Reanimated.View style={layoutSpacerStyle} />}\n </ScrollViewComponent>\n );\n }\n\n return (\n <ScrollViewWithBottomPadding\n ref={onRef}\n {...rest}\n bottomPadding={padding}\n scrollEventThrottle={16}\n ScrollViewComponent={ScrollViewComponent}\n onLayout={onScrollViewLayout}\n >\n {children}\n </ScrollViewWithBottomPadding>\n );\n },\n);\n\nexport default KeyboardAwareScrollView;\n"],"mappings":";;;;;;AAAA,IAAAA,MAAA,GAAAC,uBAAA,CAAAC,OAAA;AAOA,IAAAC,sBAAA,GAAAF,uBAAA,CAAAC,OAAA;AAYA,IAAAE,SAAA,GAAAF,OAAA;AACA,IAAAG,MAAA,GAAAH,OAAA;AAKA,IAAAI,eAAA,GAAAJ,OAAA;AACA,IAAAK,eAAA,GAAAC,sBAAA,CAAAN,OAAA;AACA,IAAAO,eAAA,GAAAD,sBAAA,CAAAN,OAAA;AACA,IAAAQ,4BAAA,GAAAF,sBAAA,CAAAN,OAAA;AAEA,IAAAS,yBAAA,GAAAT,OAAA;AACA,IAAAU,MAAA,GAAAV,OAAA;AAA0E,SAAAM,uBAAAK,CAAA,WAAAA,CAAA,IAAAA,CAAA,CAAAC,UAAA,GAAAD,CAAA,KAAAE,OAAA,EAAAF,CAAA;AAAA,SAAAZ,wBAAAY,CAAA,EAAAG,CAAA,6BAAAC,OAAA,MAAAC,CAAA,OAAAD,OAAA,IAAAE,CAAA,OAAAF,OAAA,YAAAhB,uBAAA,YAAAA,CAAAY,CAAA,EAAAG,CAAA,SAAAA,CAAA,IAAAH,CAAA,IAAAA,CAAA,CAAAC,UAAA,SAAAD,CAAA,MAAAO,CAAA,EAAAC,CAAA,EAAAC,CAAA,KAAAC,SAAA,QAAAR,OAAA,EAAAF,CAAA,iBAAAA,CAAA,uBAAAA,CAAA,yBAAAA,CAAA,SAAAS,CAAA,MAAAF,CAAA,GA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QAAQ,EAAE6C;EAAmB,IAE5B9C,QAC0B,CAAC;AAElC,CACF,CAAC;AAAC,IAAAkI,QAAA,GAAAC,OAAA,CAAA5J,OAAA,GAEauB,uBAAuB","ignoreList":[]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":[],"sources":["types.ts"],"sourcesContent":["import type { AnimatedScrollViewComponent } from \"../ScrollViewWithBottomPadding\";\nimport type { ScrollView, ScrollViewProps } from \"react-native\";\n\nexport type KeyboardAwareScrollViewProps = {\n /** The distance between the keyboard and the caret inside a focused `TextInput` when the keyboard is shown. Default is `0`. */\n bottomOffset?: number;\n /** Prevents automatic scrolling of the `ScrollView` when the keyboard gets hidden, maintaining the current screen position. Default is `false`. */\n disableScrollOnKeyboardHide?: boolean;\n /** Controls whether this `KeyboardAwareScrollView` instance should take effect. Default is `true`. */\n enabled?: boolean;\n /** Adjusting the bottom spacing of KeyboardAwareScrollView. Default is `0`. */\n extraKeyboardSpace?: number;\n /** Custom component for `ScrollView`. Default is `ScrollView`. */\n ScrollViewComponent?: AnimatedScrollViewComponent;\n} & ScrollViewProps;\nexport type KeyboardAwareScrollViewRef = {\n assureFocusedInputVisible: () => void;\n} & ScrollView;\n"],"mappings":"","ignoreList":[]}
|
|
1
|
+
{"version":3,"names":[],"sources":["types.ts"],"sourcesContent":["import type { AnimatedScrollViewComponent } from \"../ScrollViewWithBottomPadding\";\nimport type { ScrollView, ScrollViewProps } from \"react-native\";\n\nexport type KeyboardAwareScrollViewMode = \"insets\" | \"layout\";\n\nexport type KeyboardAwareScrollViewProps = {\n /** The distance between the keyboard and the caret inside a focused `TextInput` when the keyboard is shown. Default is `0`. */\n bottomOffset?: number;\n /** Prevents automatic scrolling of the `ScrollView` when the keyboard gets hidden, maintaining the current screen position. Default is `false`. */\n disableScrollOnKeyboardHide?: boolean;\n /** Controls whether this `KeyboardAwareScrollView` instance should take effect. Default is `true`. */\n enabled?: boolean;\n /** Adjusting the bottom spacing of KeyboardAwareScrollView. Default is `0`. */\n extraKeyboardSpace?: number;\n /**\n * Controls how keyboard space is created at the bottom of the `ScrollView`.\n *\n * - `\"insets\"` *(default)*: Extends the scrollable area via `contentInset` (iOS) and `ClippingScrollView` (Android). No layout reflow occurs — content positions remain stable during keyboard animation. Recommended for most use cases.\n * - `\"layout\"`: Appends a spacer `View` as the last child of the `ScrollView`. The spacer participates in layout, so flex-based arrangements (e.g. `justifyContent: \"space-between\"`, `gap`) reflow naturally when the keyboard appears. Use this when you need content to physically rearrange around the keyboard space.\n *\n * Default is `\"insets\"`.\n */\n mode?: KeyboardAwareScrollViewMode;\n /** Custom component for `ScrollView`. Default is `ScrollView`. */\n ScrollViewComponent?: AnimatedScrollViewComponent;\n} & ScrollViewProps;\nexport type KeyboardAwareScrollViewRef = {\n assureFocusedInputVisible: () => void;\n} & ScrollView;\n"],"mappings":"","ignoreList":[]}
|
|
@@ -4,7 +4,7 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
6
|
exports.TEST_ID_KEYBOARD_TOOLBAR_PREVIOUS = exports.TEST_ID_KEYBOARD_TOOLBAR_NEXT = exports.TEST_ID_KEYBOARD_TOOLBAR_DONE = exports.TEST_ID_KEYBOARD_TOOLBAR_CONTENT = exports.TEST_ID_KEYBOARD_TOOLBAR = exports.OPENED_OFFSET = exports.KEYBOARD_TOOLBAR_HEIGHT = exports.KEYBOARD_HAS_ROUNDED_CORNERS = exports.DEFAULT_OPACITY = void 0;
|
|
7
|
-
var
|
|
7
|
+
var _constants = require("../../constants");
|
|
8
8
|
const TEST_ID_KEYBOARD_TOOLBAR = exports.TEST_ID_KEYBOARD_TOOLBAR = "keyboard.toolbar";
|
|
9
9
|
const TEST_ID_KEYBOARD_TOOLBAR_PREVIOUS = exports.TEST_ID_KEYBOARD_TOOLBAR_PREVIOUS = `${TEST_ID_KEYBOARD_TOOLBAR}.previous`;
|
|
10
10
|
const TEST_ID_KEYBOARD_TOOLBAR_NEXT = exports.TEST_ID_KEYBOARD_TOOLBAR_NEXT = `${TEST_ID_KEYBOARD_TOOLBAR}.next`;
|
|
@@ -12,6 +12,6 @@ const TEST_ID_KEYBOARD_TOOLBAR_CONTENT = exports.TEST_ID_KEYBOARD_TOOLBAR_CONTEN
|
|
|
12
12
|
const TEST_ID_KEYBOARD_TOOLBAR_DONE = exports.TEST_ID_KEYBOARD_TOOLBAR_DONE = `${TEST_ID_KEYBOARD_TOOLBAR}.done`;
|
|
13
13
|
const KEYBOARD_TOOLBAR_HEIGHT = exports.KEYBOARD_TOOLBAR_HEIGHT = 42;
|
|
14
14
|
const DEFAULT_OPACITY = exports.DEFAULT_OPACITY = "FF";
|
|
15
|
-
const KEYBOARD_HAS_ROUNDED_CORNERS = exports.KEYBOARD_HAS_ROUNDED_CORNERS =
|
|
15
|
+
const KEYBOARD_HAS_ROUNDED_CORNERS = exports.KEYBOARD_HAS_ROUNDED_CORNERS = _constants.KEYBOARD_BORDER_RADIUS > 0;
|
|
16
16
|
const OPENED_OFFSET = exports.OPENED_OFFSET = KEYBOARD_HAS_ROUNDED_CORNERS ? -11 : 0;
|
|
17
17
|
//# sourceMappingURL=constants.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["
|
|
1
|
+
{"version":3,"names":["_constants","require","TEST_ID_KEYBOARD_TOOLBAR","exports","TEST_ID_KEYBOARD_TOOLBAR_PREVIOUS","TEST_ID_KEYBOARD_TOOLBAR_NEXT","TEST_ID_KEYBOARD_TOOLBAR_CONTENT","TEST_ID_KEYBOARD_TOOLBAR_DONE","KEYBOARD_TOOLBAR_HEIGHT","DEFAULT_OPACITY","KEYBOARD_HAS_ROUNDED_CORNERS","KEYBOARD_BORDER_RADIUS","OPENED_OFFSET"],"sources":["constants.ts"],"sourcesContent":["import { KEYBOARD_BORDER_RADIUS } from \"../../constants\";\n\nimport type { HEX } from \"./types\";\n\nexport const TEST_ID_KEYBOARD_TOOLBAR = \"keyboard.toolbar\";\nexport const TEST_ID_KEYBOARD_TOOLBAR_PREVIOUS = `${TEST_ID_KEYBOARD_TOOLBAR}.previous`;\nexport const TEST_ID_KEYBOARD_TOOLBAR_NEXT = `${TEST_ID_KEYBOARD_TOOLBAR}.next`;\nexport const TEST_ID_KEYBOARD_TOOLBAR_CONTENT = `${TEST_ID_KEYBOARD_TOOLBAR}.content`;\nexport const TEST_ID_KEYBOARD_TOOLBAR_DONE = `${TEST_ID_KEYBOARD_TOOLBAR}.done`;\n\nexport const KEYBOARD_TOOLBAR_HEIGHT = 42;\nexport const DEFAULT_OPACITY: HEX = \"FF\";\nexport const KEYBOARD_HAS_ROUNDED_CORNERS = KEYBOARD_BORDER_RADIUS > 0;\nexport const OPENED_OFFSET = KEYBOARD_HAS_ROUNDED_CORNERS ? -11 : 0;\n"],"mappings":";;;;;;AAAA,IAAAA,UAAA,GAAAC,OAAA;AAIO,MAAMC,wBAAwB,GAAAC,OAAA,CAAAD,wBAAA,GAAG,kBAAkB;AACnD,MAAME,iCAAiC,GAAAD,OAAA,CAAAC,iCAAA,GAAG,GAAGF,wBAAwB,WAAW;AAChF,MAAMG,6BAA6B,GAAAF,OAAA,CAAAE,6BAAA,GAAG,GAAGH,wBAAwB,OAAO;AACxE,MAAMI,gCAAgC,GAAAH,OAAA,CAAAG,gCAAA,GAAG,GAAGJ,wBAAwB,UAAU;AAC9E,MAAMK,6BAA6B,GAAAJ,OAAA,CAAAI,6BAAA,GAAG,GAAGL,wBAAwB,OAAO;AAExE,MAAMM,uBAAuB,GAAAL,OAAA,CAAAK,uBAAA,GAAG,EAAE;AAClC,MAAMC,eAAoB,GAAAN,OAAA,CAAAM,eAAA,GAAG,IAAI;AACjC,MAAMC,4BAA4B,GAAAP,OAAA,CAAAO,4BAAA,GAAGC,iCAAsB,GAAG,CAAC;AAC/D,MAAMC,aAAa,GAAAT,OAAA,CAAAS,aAAA,GAAGF,4BAA4B,GAAG,CAAC,EAAE,GAAG,CAAC","ignoreList":[]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["_KeyboardAvoidingView","_interopRequireDefault","require","_KeyboardStickyView","_KeyboardAwareScrollView","_KeyboardToolbar","_interopRequireWildcard","_KeyboardChatScrollView","e","t","WeakMap","r","n","__esModule","o","i","f","__proto__","default","has","get","set","hasOwnProperty","call","Object","defineProperty","getOwnPropertyDescriptor"],"sources":["index.ts"],"sourcesContent":["export { default as KeyboardAvoidingView } from \"./KeyboardAvoidingView\";\nexport { default as KeyboardStickyView } from \"./KeyboardStickyView\";\nexport { default as KeyboardAwareScrollView } from \"./KeyboardAwareScrollView\";\nexport {\n default as KeyboardToolbar,\n DefaultKeyboardToolbarTheme,\n} from \"./KeyboardToolbar\";\nexport { default as KeyboardChatScrollView } from \"./KeyboardChatScrollView\";\nexport type { KeyboardAvoidingViewProps } from \"./KeyboardAvoidingView\";\nexport type { KeyboardStickyViewProps } from \"./KeyboardStickyView\";\nexport type {\n KeyboardAwareScrollViewProps,\n KeyboardAwareScrollViewRef,\n} from \"./KeyboardAwareScrollView/types\";\nexport type { KeyboardToolbarProps } from \"./KeyboardToolbar\";\nexport type { KeyboardChatScrollViewProps } from \"./KeyboardChatScrollView/types\";\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,IAAAA,qBAAA,GAAAC,sBAAA,CAAAC,OAAA;AACA,IAAAC,mBAAA,GAAAF,sBAAA,CAAAC,OAAA;AACA,IAAAE,wBAAA,GAAAH,sBAAA,CAAAC,OAAA;AACA,IAAAG,gBAAA,GAAAC,uBAAA,CAAAJ,OAAA;AAIA,IAAAK,uBAAA,GAAAN,sBAAA,CAAAC,OAAA;AAA6E,SAAAI,wBAAAE,CAAA,EAAAC,CAAA,6BAAAC,OAAA,MAAAC,CAAA,OAAAD,OAAA,IAAAE,CAAA,OAAAF,OAAA,YAAAJ,uBAAA,YAAAA,CAAAE,CAAA,EAAAC,CAAA,SAAAA,CAAA,IAAAD,CAAA,IAAAA,CAAA,CAAAK,UAAA,SAAAL,CAAA,MAAAM,CAAA,EAAAC,CAAA,EAAAC,CAAA,KAAAC,SAAA,QAAAC,OAAA,EAAAV,CAAA,iBAAAA,CAAA,uBAAAA,CAAA,yBAAAA,CAAA,SAAAQ,CAAA,MAAAF,CAAA,GAAAL,CAAA,GAAAG,CAAA,GAAAD,CAAA,QAAAG,CAAA,CAAAK,GAAA,CAAAX,CAAA,UAAAM,CAAA,CAAAM,GAAA,CAAAZ,CAAA,GAAAM,CAAA,CAAAO,GAAA,CAAAb,CAAA,EAAAQ,CAAA,gBAAAP,CAAA,IAAAD,CAAA,gBAAAC,CAAA,OAAAa,cAAA,CAAAC,IAAA,CAAAf,CAAA,EAAAC,CAAA,OAAAM,CAAA,IAAAD,CAAA,GAAAU,MAAA,CAAAC,cAAA,KAAAD,MAAA,CAAAE,wBAAA,CAAAlB,CAAA,EAAAC,CAAA,OAAAM,CAAA,CAAAK,GAAA,IAAAL,CAAA,CAAAM,GAAA,IAAAP,CAAA,CAAAE,CAAA,EAAAP,CAAA,EAAAM,CAAA,IAAAC,CAAA,CAAAP,CAAA,IAAAD,CAAA,CAAAC,CAAA,WAAAO,CAAA,KAAAR,CAAA,EAAAC,CAAA;AAAA,SAAAR,uBAAAO,CAAA,WAAAA,CAAA,IAAAA,CAAA,CAAAK,UAAA,GAAAL,CAAA,KAAAU,OAAA,EAAAV,CAAA","ignoreList":[]}
|
|
1
|
+
{"version":3,"names":["_KeyboardAvoidingView","_interopRequireDefault","require","_KeyboardStickyView","_KeyboardAwareScrollView","_KeyboardToolbar","_interopRequireWildcard","_KeyboardChatScrollView","e","t","WeakMap","r","n","__esModule","o","i","f","__proto__","default","has","get","set","hasOwnProperty","call","Object","defineProperty","getOwnPropertyDescriptor"],"sources":["index.ts"],"sourcesContent":["export { default as KeyboardAvoidingView } from \"./KeyboardAvoidingView\";\nexport { default as KeyboardStickyView } from \"./KeyboardStickyView\";\nexport { default as KeyboardAwareScrollView } from \"./KeyboardAwareScrollView\";\nexport {\n default as KeyboardToolbar,\n DefaultKeyboardToolbarTheme,\n} from \"./KeyboardToolbar\";\nexport { default as KeyboardChatScrollView } from \"./KeyboardChatScrollView\";\nexport type { KeyboardAvoidingViewProps } from \"./KeyboardAvoidingView\";\nexport type { KeyboardStickyViewProps } from \"./KeyboardStickyView\";\nexport type {\n KeyboardAwareScrollViewMode,\n KeyboardAwareScrollViewProps,\n KeyboardAwareScrollViewRef,\n} from \"./KeyboardAwareScrollView/types\";\nexport type { KeyboardToolbarProps } from \"./KeyboardToolbar\";\nexport type { KeyboardChatScrollViewProps } from \"./KeyboardChatScrollView/types\";\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,IAAAA,qBAAA,GAAAC,sBAAA,CAAAC,OAAA;AACA,IAAAC,mBAAA,GAAAF,sBAAA,CAAAC,OAAA;AACA,IAAAE,wBAAA,GAAAH,sBAAA,CAAAC,OAAA;AACA,IAAAG,gBAAA,GAAAC,uBAAA,CAAAJ,OAAA;AAIA,IAAAK,uBAAA,GAAAN,sBAAA,CAAAC,OAAA;AAA6E,SAAAI,wBAAAE,CAAA,EAAAC,CAAA,6BAAAC,OAAA,MAAAC,CAAA,OAAAD,OAAA,IAAAE,CAAA,OAAAF,OAAA,YAAAJ,uBAAA,YAAAA,CAAAE,CAAA,EAAAC,CAAA,SAAAA,CAAA,IAAAD,CAAA,IAAAA,CAAA,CAAAK,UAAA,SAAAL,CAAA,MAAAM,CAAA,EAAAC,CAAA,EAAAC,CAAA,KAAAC,SAAA,QAAAC,OAAA,EAAAV,CAAA,iBAAAA,CAAA,uBAAAA,CAAA,yBAAAA,CAAA,SAAAQ,CAAA,MAAAF,CAAA,GAAAL,CAAA,GAAAG,CAAA,GAAAD,CAAA,QAAAG,CAAA,CAAAK,GAAA,CAAAX,CAAA,UAAAM,CAAA,CAAAM,GAAA,CAAAZ,CAAA,GAAAM,CAAA,CAAAO,GAAA,CAAAb,CAAA,EAAAQ,CAAA,gBAAAP,CAAA,IAAAD,CAAA,gBAAAC,CAAA,OAAAa,cAAA,CAAAC,IAAA,CAAAf,CAAA,EAAAC,CAAA,OAAAM,CAAA,IAAAD,CAAA,GAAAU,MAAA,CAAAC,cAAA,KAAAD,MAAA,CAAAE,wBAAA,CAAAlB,CAAA,EAAAC,CAAA,OAAAM,CAAA,CAAAK,GAAA,IAAAL,CAAA,CAAAM,GAAA,IAAAP,CAAA,CAAAE,CAAA,EAAAP,CAAA,EAAAM,CAAA,IAAAC,CAAA,CAAAP,CAAA,IAAAD,CAAA,CAAAC,CAAA,WAAAO,CAAA,KAAAR,CAAA,EAAAC,CAAA;AAAA,SAAAR,uBAAAO,CAAA,WAAAA,CAAA,IAAAA,CAAA,CAAAK,UAAA,GAAAL,CAAA,KAAAU,OAAA,EAAAV,CAAA","ignoreList":[]}
|
|
@@ -3,7 +3,8 @@
|
|
|
3
3
|
Object.defineProperty(exports, "__esModule", {
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
|
-
exports.AndroidSoftInputModes = void 0;
|
|
6
|
+
exports.KEYBOARD_BORDER_RADIUS = exports.AndroidSoftInputModes = void 0;
|
|
7
|
+
var _bindings = require("./bindings");
|
|
7
8
|
// copied from `android.view.WindowManager.LayoutParams`
|
|
8
9
|
let AndroidSoftInputModes = exports.AndroidSoftInputModes = /*#__PURE__*/function (AndroidSoftInputModes) {
|
|
9
10
|
AndroidSoftInputModes[AndroidSoftInputModes["SOFT_INPUT_ADJUST_NOTHING"] = 48] = "SOFT_INPUT_ADJUST_NOTHING";
|
|
@@ -24,4 +25,5 @@ let AndroidSoftInputModes = exports.AndroidSoftInputModes = /*#__PURE__*/functio
|
|
|
24
25
|
AndroidSoftInputModes[AndroidSoftInputModes["SOFT_INPUT_STATE_VISIBLE"] = 4] = "SOFT_INPUT_STATE_VISIBLE";
|
|
25
26
|
return AndroidSoftInputModes;
|
|
26
27
|
}({});
|
|
28
|
+
const KEYBOARD_BORDER_RADIUS = exports.KEYBOARD_BORDER_RADIUS = _bindings.KeyboardControllerNative.getConstants().keyboardBorderRadius;
|
|
27
29
|
//# sourceMappingURL=constants.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["AndroidSoftInputModes","exports"],"sources":["constants.ts"],"sourcesContent":["// copied from `android.view.WindowManager.LayoutParams`\nexport enum AndroidSoftInputModes {\n SOFT_INPUT_ADJUST_NOTHING = 48,\n SOFT_INPUT_ADJUST_PAN = 32,\n SOFT_INPUT_ADJUST_RESIZE = 16,\n SOFT_INPUT_ADJUST_UNSPECIFIED = 0,\n SOFT_INPUT_IS_FORWARD_NAVIGATION = 256,\n SOFT_INPUT_MASK_ADJUST = 240,\n SOFT_INPUT_MASK_STATE = 15,\n SOFT_INPUT_MODE_CHANGED = 512,\n SOFT_INPUT_STATE_ALWAYS_HIDDEN = 3,\n SOFT_INPUT_STATE_ALWAYS_VISIBLE = 5,\n SOFT_INPUT_STATE_HIDDEN = 2,\n SOFT_INPUT_STATE_UNCHANGED = 1,\n // temporarily disable this rule to avoid breaking changes.\n // eslint-disable-next-line @typescript-eslint/no-duplicate-enum-values\n SOFT_INPUT_STATE_UNSPECIFIED = 0,\n SOFT_INPUT_STATE_VISIBLE = 4,\n}\n"],"mappings":";;;;;;AAAA;AAAA,
|
|
1
|
+
{"version":3,"names":["_bindings","require","AndroidSoftInputModes","exports","KEYBOARD_BORDER_RADIUS","KeyboardControllerNative","getConstants","keyboardBorderRadius"],"sources":["constants.ts"],"sourcesContent":["import { KeyboardControllerNative } from \"./bindings\";\n\n// copied from `android.view.WindowManager.LayoutParams`\nexport enum AndroidSoftInputModes {\n SOFT_INPUT_ADJUST_NOTHING = 48,\n SOFT_INPUT_ADJUST_PAN = 32,\n SOFT_INPUT_ADJUST_RESIZE = 16,\n SOFT_INPUT_ADJUST_UNSPECIFIED = 0,\n SOFT_INPUT_IS_FORWARD_NAVIGATION = 256,\n SOFT_INPUT_MASK_ADJUST = 240,\n SOFT_INPUT_MASK_STATE = 15,\n SOFT_INPUT_MODE_CHANGED = 512,\n SOFT_INPUT_STATE_ALWAYS_HIDDEN = 3,\n SOFT_INPUT_STATE_ALWAYS_VISIBLE = 5,\n SOFT_INPUT_STATE_HIDDEN = 2,\n SOFT_INPUT_STATE_UNCHANGED = 1,\n // temporarily disable this rule to avoid breaking changes.\n // eslint-disable-next-line @typescript-eslint/no-duplicate-enum-values\n SOFT_INPUT_STATE_UNSPECIFIED = 0,\n SOFT_INPUT_STATE_VISIBLE = 4,\n}\nexport const KEYBOARD_BORDER_RADIUS =\n KeyboardControllerNative.getConstants().keyboardBorderRadius;\n"],"mappings":";;;;;;AAAA,IAAAA,SAAA,GAAAC,OAAA;AAEA;AAAA,IACYC,qBAAqB,GAAAC,OAAA,CAAAD,qBAAA,0BAArBA,qBAAqB;EAArBA,qBAAqB,CAArBA,qBAAqB;EAArBA,qBAAqB,CAArBA,qBAAqB;EAArBA,qBAAqB,CAArBA,qBAAqB;EAArBA,qBAAqB,CAArBA,qBAAqB;EAArBA,qBAAqB,CAArBA,qBAAqB;EAArBA,qBAAqB,CAArBA,qBAAqB;EAArBA,qBAAqB,CAArBA,qBAAqB;EAArBA,qBAAqB,CAArBA,qBAAqB;EAArBA,qBAAqB,CAArBA,qBAAqB;EAArBA,qBAAqB,CAArBA,qBAAqB;EAArBA,qBAAqB,CAArBA,qBAAqB;EAArBA,qBAAqB,CAArBA,qBAAqB;EAa/B;EACA;EAdUA,qBAAqB,CAArBA,qBAAqB;EAArBA,qBAAqB,CAArBA,qBAAqB;EAAA,OAArBA,qBAAqB;AAAA;AAkB1B,MAAME,sBAAsB,GAAAD,OAAA,CAAAC,sBAAA,GACjCC,kCAAwB,CAACC,YAAY,CAAC,CAAC,CAACC,oBAAoB","ignoreList":[]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["_bindings","require","Object","keys","forEach","key","prototype","hasOwnProperty","call","_exportNames","exports","defineProperty","enumerable","get","_animated","_context","_hooks","_constants","_module","_types","_compat","_components","_views"],"sources":["index.ts"],"sourcesContent":["export * from \"./bindings\";\nexport * from \"./animated\";\nexport * from \"./context\";\nexport * from \"./hooks\";\nexport * from \"./constants\";\nexport * from \"./module\";\nexport * from \"./types\";\nexport * from \"./compat\";\n\nexport {\n KeyboardChatScrollView,\n KeyboardAvoidingView,\n KeyboardStickyView,\n KeyboardAwareScrollView,\n // keyboard toolbar\n KeyboardToolbar,\n DefaultKeyboardToolbarTheme,\n} from \"./components\";\nexport type {\n KeyboardChatScrollViewProps,\n KeyboardAvoidingViewProps,\n KeyboardStickyViewProps,\n KeyboardAwareScrollViewProps,\n KeyboardAwareScrollViewRef,\n KeyboardToolbarProps,\n} from \"./components\";\nexport { OverKeyboardView, KeyboardExtender } from \"./views\";\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,IAAAA,SAAA,GAAAC,OAAA;AAAAC,MAAA,CAAAC,IAAA,CAAAH,SAAA,EAAAI,OAAA,WAAAC,GAAA;EAAA,IAAAA,GAAA,kBAAAA,GAAA;EAAA,IAAAH,MAAA,CAAAI,SAAA,CAAAC,cAAA,CAAAC,IAAA,CAAAC,YAAA,EAAAJ,GAAA;EAAA,IAAAA,GAAA,IAAAK,OAAA,IAAAA,OAAA,CAAAL,GAAA,MAAAL,SAAA,CAAAK,GAAA;EAAAH,MAAA,CAAAS,cAAA,CAAAD,OAAA,EAAAL,GAAA;IAAAO,UAAA;IAAAC,GAAA,WAAAA,CAAA;MAAA,OAAAb,SAAA,CAAAK,GAAA;IAAA;EAAA;AAAA;AACA,IAAAS,SAAA,GAAAb,OAAA;AAAAC,MAAA,CAAAC,IAAA,CAAAW,SAAA,EAAAV,OAAA,WAAAC,GAAA;EAAA,IAAAA,GAAA,kBAAAA,GAAA;EAAA,IAAAH,MAAA,CAAAI,SAAA,CAAAC,cAAA,CAAAC,IAAA,CAAAC,YAAA,EAAAJ,GAAA;EAAA,IAAA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AAAe,OAAA,GAAAnB,OAAA;AAAAC,MAAA,CAAAC,IAAA,CAAAiB,OAAA,EAAAhB,OAAA,WAAAC,GAAA;EAAA,IAAAA,GAAA,kBAAAA,GAAA;EAAA,IAAAH,MAAA,CAAAI,SAAA,CAAAC,cAAA,CAAAC,IAAA,CAAAC,YAAA,EAAAJ,GAAA;EAAA,IAAAA,GAAA,IAAAK,OAAA,IAAAA,OAAA,CAAAL,GAAA,MAAAe,OAAA,CAAAf,GAAA;EAAAH,MAAA,CAAAS,cAAA,CAAAD,OAAA,EAAAL,GAAA;IAAAO,UAAA;IAAAC,GAAA,WAAAA,CAAA;MAAA,OAAAO,OAAA,CAAAf,GAAA;IAAA;EAAA;AAAA;AAEA,IAAAgB,WAAA,GAAApB,OAAA;
|
|
1
|
+
{"version":3,"names":["_bindings","require","Object","keys","forEach","key","prototype","hasOwnProperty","call","_exportNames","exports","defineProperty","enumerable","get","_animated","_context","_hooks","_constants","_module","_types","_compat","_components","_views"],"sources":["index.ts"],"sourcesContent":["export * from \"./bindings\";\nexport * from \"./animated\";\nexport * from \"./context\";\nexport * from \"./hooks\";\nexport * from \"./constants\";\nexport * from \"./module\";\nexport * from \"./types\";\nexport * from \"./compat\";\n\nexport {\n KeyboardChatScrollView,\n KeyboardAvoidingView,\n KeyboardStickyView,\n KeyboardAwareScrollView,\n // keyboard toolbar\n KeyboardToolbar,\n DefaultKeyboardToolbarTheme,\n} from \"./components\";\nexport type {\n KeyboardChatScrollViewProps,\n KeyboardAvoidingViewProps,\n KeyboardStickyViewProps,\n KeyboardAwareScrollViewMode,\n KeyboardAwareScrollViewProps,\n KeyboardAwareScrollViewRef,\n KeyboardToolbarProps,\n} from \"./components\";\nexport { OverKeyboardView, KeyboardExtender } from \"./views\";\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,IAAAA,SAAA,GAAAC,OAAA;AAAAC,MAAA,CAAAC,IAAA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