react-native-external-keyboard 0.8.5 → 0.9.1
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/README.md +149 -67
- package/android/src/main/java/com/externalkeyboard/delegates/FocusOrderDelegate.java +81 -75
- package/android/src/main/java/com/externalkeyboard/delegates/FocusOrderDelegateHost.java +14 -0
- package/android/src/main/java/com/externalkeyboard/helper/Linking/A11yOrderLinking.java +5 -0
- package/android/src/main/java/com/externalkeyboard/modules/ExternalKeyboardModule.java +10 -10
- package/android/src/main/java/com/externalkeyboard/services/FocusLinkObserver/FocusLinkObserver.java +26 -35
- package/android/src/main/java/com/externalkeyboard/views/ExternalKeyboardLockView/ExternalKeyboardLockView.java +5 -0
- package/android/src/main/java/com/externalkeyboard/views/ExternalKeyboardLockView/ExternalKeyboardLockViewManager.java +6 -0
- package/android/src/main/java/com/externalkeyboard/views/ExternalKeyboardView/ExternalKeyboardView.java +8 -307
- package/android/src/main/java/com/externalkeyboard/views/ExternalKeyboardView/ExternalKeyboardViewManager.java +11 -18
- package/android/src/main/java/com/externalkeyboard/views/TextInputFocusWrapper/TextInputFocusWrapper.java +208 -101
- package/android/src/main/java/com/externalkeyboard/views/TextInputFocusWrapper/TextInputFocusWrapperManager.java +123 -34
- package/android/src/main/java/com/externalkeyboard/views/base/FocusHighlightBase.java +38 -0
- package/android/src/main/java/com/externalkeyboard/views/base/ViewGroupBase.java +19 -0
- package/android/src/main/java/com/externalkeyboard/views/base/ViewOrderGroupBase.java +190 -0
- package/android/src/main/java/com/externalkeyboard/views/base/keyboard/ViewFocusChangeBase.java +39 -0
- package/android/src/main/java/com/externalkeyboard/views/base/keyboard/ViewFocusRequestBase.java +125 -0
- package/android/src/main/java/com/externalkeyboard/views/base/keyboard/ViewKeyHandlerBase.java +40 -0
- package/android/src/newarch/TextInputFocusWrapperManagerSpec.java +2 -8
- package/android/src/oldarch/ExternalKeyboardLockViewManagerSpec.java +1 -0
- package/android/src/oldarch/TextInputFocusWrapperManagerSpec.java +32 -2
- package/ios/Delegates/RNCEKVFocusLinkDelegate/RNCEKVFocusLinkDelegate.h +35 -0
- package/ios/Delegates/RNCEKVFocusLinkDelegate/RNCEKVFocusLinkDelegate.mm +195 -0
- package/ios/Delegates/RNCEKVFocusOrderDelegate/RNCEKVFocusOrderProtocol.h +6 -8
- package/ios/Delegates/RNCEKVFocusSequenceDelegate/RNCEKVFocusSequenceDelegate.h +25 -0
- package/ios/Delegates/RNCEKVFocusSequenceDelegate/RNCEKVFocusSequenceDelegate.mm +163 -0
- package/ios/Delegates/RNCEKVGroupIdentifierDelegate/RNCEKVGroupIdentifierDelegate.h +2 -6
- package/ios/Delegates/RNCEKVGroupIdentifierDelegate/RNCEKVGroupIdentifierDelegate.mm +6 -78
- package/ios/Delegates/RNCEKVHaloDelegate/RNCEKVHaloDelegate.h +3 -4
- package/ios/Delegates/RNCEKVHaloDelegate/RNCEKVHaloDelegate.mm +32 -101
- package/ios/Delegates/RNCEKVHaloDelegate/RNCEKVHaloProtocol.h +1 -1
- package/ios/Extensions/RCTEnhancedScrollView+RNCEKVExternalKeyboard.mm +1 -1
- package/ios/Extensions/RCTTextInputComponentView+RNCEKVExternalKeyboard.mm +15 -0
- package/ios/Extensions/RCTViewComponentView+RNCEKVExternalKeyboard.h +9 -6
- package/ios/Extensions/RCTViewComponentView+RNCEKVExternalKeyboard.mm +16 -29
- package/ios/Extensions/UIViewController+RNCEKVExternalKeyboard.h +1 -0
- package/ios/Extensions/UIViewController+RNCEKVExternalKeyboard.mm +8 -0
- package/ios/Helpers/RNCEKVNativeProps/RNCEKVNativeProps.h +123 -0
- package/ios/Protocols/RNCEKVCustomFocusEffectProtocol.h +15 -0
- package/ios/Protocols/RNCEKVCustomGroudIdProtocol.h +15 -0
- package/ios/Protocols/RNCEKVKeyboardFocusableProtocol.h +15 -0
- package/ios/Services/RNCEKVFocusLinkObserver.mm +2 -3
- package/ios/Services/RNCEKVKeyboardOrderManager/RNCEKVOrderRelationship/RNCEKVOrderRelationship.mm +15 -28
- package/ios/Services/RNCEKVOrderLinking.mm +43 -51
- package/ios/Views/Base/ContextMenu/RNCEKVViewContextMenuBase.h +33 -0
- package/ios/Views/Base/ContextMenu/RNCEKVViewContextMenuBase.mm +84 -0
- package/ios/Views/Base/FocusChange/RNCEKVViewFocusChangeBase.h +37 -0
- package/ios/Views/Base/FocusChange/RNCEKVViewFocusChangeBase.mm +89 -0
- package/ios/Views/Base/FocusOrderGroup/RNCEKVViewOrderGroupBase.h +49 -0
- package/ios/Views/Base/FocusOrderGroup/RNCEKVViewOrderGroupBase.mm +245 -0
- package/ios/Views/Base/FocusRequest/RNCEKVViewFocusRequestBase.h +34 -0
- package/ios/Views/Base/FocusRequest/RNCEKVViewFocusRequestBase.mm +112 -0
- package/ios/Views/Base/GroupIdentifier/RNCEKVViewGroupIdentifierBase.h +27 -0
- package/ios/Views/Base/GroupIdentifier/RNCEKVViewGroupIdentifierBase.mm +69 -0
- package/ios/Views/Base/KeyPress/RNCEKVViewKeyPress.h +30 -0
- package/ios/Views/Base/KeyPress/RNCEKVViewKeyPress.mm +75 -0
- package/ios/Views/Base/KeyboardHallo/RNCEKVExternalKeyboardHalloBase.h +33 -0
- package/ios/Views/Base/KeyboardHallo/RNCEKVExternalKeyboardHalloBase.mm +92 -0
- package/ios/Views/Base/ViewGroup/RNCEKVViewGroupBase.h +36 -0
- package/ios/Views/Base/ViewGroup/RNCEKVViewGroupBase.mm +63 -0
- package/ios/Views/RNCEKVExternalKeyboardLockView/RNCEKVExternalKeyboardLockView.h +8 -0
- package/ios/Views/RNCEKVExternalKeyboardLockView/RNCEKVExternalKeyboardLockView.mm +105 -2
- package/ios/Views/RNCEKVExternalKeyboardLockView/RNCEKVExternalKeyboardLockViewManager.mm +11 -0
- package/ios/Views/RNCEKVExternalKeyboardView/RNCEKVExternalKeyboardView.h +7 -82
- package/ios/Views/RNCEKVExternalKeyboardView/RNCEKVExternalKeyboardView.mm +23 -493
- package/ios/Views/RNCEKVExternalKeyboardView/RNCEKVExternalKeyboardViewManager.mm +5 -7
- package/ios/Views/RNCEKVKeyboardFocusGroupView/RNCEKVKeyboardFocusGroup.mm +20 -17
- package/ios/Views/RNCEKVTextInputFocusWrapper/RNCEKVTextInputFocusWrapper.h +10 -39
- package/ios/Views/RNCEKVTextInputFocusWrapper/RNCEKVTextInputFocusWrapper.mm +40 -73
- package/ios/Views/RNCEKVTextInputFocusWrapper/RNCEKVTextInputFocusWrapperManager.mm +76 -8
- package/lib/commonjs/components/BaseKeyboardView/BaseKeyboardView.js +35 -7
- package/lib/commonjs/components/BaseKeyboardView/BaseKeyboardView.js.map +1 -1
- package/lib/commonjs/components/KeyboardExtendedInput/KeyboardExtendedInput.js +79 -1
- package/lib/commonjs/components/KeyboardExtendedInput/KeyboardExtendedInput.js.map +1 -1
- package/lib/commonjs/components/KeyboardFocusLock/FocusTrap/FocusTrap.js +18 -4
- package/lib/commonjs/components/KeyboardFocusLock/FocusTrap/FocusTrap.js.map +1 -1
- package/lib/commonjs/components/KeyboardFocusLock/KeyboardFocusLockBase/KeyboardFocusLockBase.js +17 -2
- package/lib/commonjs/components/KeyboardFocusLock/KeyboardFocusLockBase/KeyboardFocusLockBase.js.map +1 -1
- package/lib/commonjs/components/KeyboardFocusView/KeyboardFocusView.js +2 -0
- package/lib/commonjs/components/KeyboardFocusView/KeyboardFocusView.js.map +1 -1
- package/lib/commonjs/nativeSpec/ExternalKeyboardLockViewNativeComponent.ts +1 -0
- package/lib/commonjs/nativeSpec/TextInputFocusWrapperNativeComponent.ts +16 -0
- package/lib/commonjs/utils/useFocusStyle.js +3 -9
- package/lib/commonjs/utils/useFocusStyle.js.map +1 -1
- package/lib/commonjs/utils/withKeyboardFocus.js +32 -15
- package/lib/commonjs/utils/withKeyboardFocus.js.map +1 -1
- package/lib/commonjs/utils/wrapOrderPrefix.js +17 -0
- package/lib/commonjs/utils/wrapOrderPrefix.js.map +1 -0
- package/lib/module/components/BaseKeyboardView/BaseKeyboardView.js +35 -7
- package/lib/module/components/BaseKeyboardView/BaseKeyboardView.js.map +1 -1
- package/lib/module/components/KeyboardExtendedInput/KeyboardExtendedInput.js +80 -2
- package/lib/module/components/KeyboardExtendedInput/KeyboardExtendedInput.js.map +1 -1
- package/lib/module/components/KeyboardFocusLock/FocusTrap/FocusTrap.js +18 -4
- package/lib/module/components/KeyboardFocusLock/FocusTrap/FocusTrap.js.map +1 -1
- package/lib/module/components/KeyboardFocusLock/KeyboardFocusLockBase/KeyboardFocusLockBase.js +16 -2
- package/lib/module/components/KeyboardFocusLock/KeyboardFocusLockBase/KeyboardFocusLockBase.js.map +1 -1
- package/lib/module/components/KeyboardFocusView/KeyboardFocusView.js +2 -0
- package/lib/module/components/KeyboardFocusView/KeyboardFocusView.js.map +1 -1
- package/lib/module/nativeSpec/ExternalKeyboardLockViewNativeComponent.ts +1 -0
- package/lib/module/nativeSpec/TextInputFocusWrapperNativeComponent.ts +16 -0
- package/lib/module/utils/useFocusStyle.js +4 -10
- package/lib/module/utils/useFocusStyle.js.map +1 -1
- package/lib/module/utils/withKeyboardFocus.js +32 -15
- package/lib/module/utils/withKeyboardFocus.js.map +1 -1
- package/lib/module/utils/wrapOrderPrefix.js +12 -0
- package/lib/module/utils/wrapOrderPrefix.js.map +1 -0
- package/lib/typescript/src/components/BaseKeyboardView/BaseKeyboardView.d.ts.map +1 -1
- package/lib/typescript/src/components/KeyboardExtendedInput/KeyboardExtendedInput.d.ts.map +1 -1
- package/lib/typescript/src/components/KeyboardExtendedInput/KeyboardExtendedInput.types.d.ts +15 -0
- package/lib/typescript/src/components/KeyboardExtendedInput/KeyboardExtendedInput.types.d.ts.map +1 -1
- package/lib/typescript/src/components/KeyboardFocusLock/FocusTrap/FocusTrap.d.ts +1 -1
- package/lib/typescript/src/components/KeyboardFocusLock/FocusTrap/FocusTrap.d.ts.map +1 -1
- package/lib/typescript/src/components/KeyboardFocusLock/KeyboardFocusLockBase/KeyboardFocusLockBase.d.ts +2 -1
- package/lib/typescript/src/components/KeyboardFocusLock/KeyboardFocusLockBase/KeyboardFocusLockBase.d.ts.map +1 -1
- package/lib/typescript/src/components/KeyboardFocusView/KeyboardFocusView.d.ts.map +1 -1
- package/lib/typescript/src/index.d.ts +1 -1
- package/lib/typescript/src/nativeSpec/ExternalKeyboardLockViewNativeComponent.d.ts +1 -0
- package/lib/typescript/src/nativeSpec/ExternalKeyboardLockViewNativeComponent.d.ts.map +1 -1
- package/lib/typescript/src/nativeSpec/TextInputFocusWrapperNativeComponent.d.ts +16 -1
- package/lib/typescript/src/nativeSpec/TextInputFocusWrapperNativeComponent.d.ts.map +1 -1
- package/lib/typescript/src/types/BaseKeyboardView.d.ts +2 -0
- package/lib/typescript/src/types/BaseKeyboardView.d.ts.map +1 -1
- package/lib/typescript/src/types/KeyboardFocusLock.types.d.ts +1 -0
- package/lib/typescript/src/types/KeyboardFocusLock.types.d.ts.map +1 -1
- package/lib/typescript/src/types/WithKeyboardFocus.d.ts +11 -2
- package/lib/typescript/src/types/WithKeyboardFocus.d.ts.map +1 -1
- package/lib/typescript/src/utils/useFocusStyle.d.ts +1 -0
- package/lib/typescript/src/utils/useFocusStyle.d.ts.map +1 -1
- package/lib/typescript/src/utils/withKeyboardFocus.d.ts.map +1 -1
- package/lib/typescript/src/utils/wrapOrderPrefix.d.ts +9 -0
- package/lib/typescript/src/utils/wrapOrderPrefix.d.ts.map +1 -0
- package/package.json +6 -2
- package/src/components/BaseKeyboardView/BaseKeyboardView.tsx +88 -10
- package/src/components/KeyboardExtendedInput/KeyboardExtendedInput.tsx +138 -2
- package/src/components/KeyboardExtendedInput/KeyboardExtendedInput.types.ts +15 -0
- package/src/components/KeyboardFocusLock/FocusTrap/FocusTrap.tsx +21 -4
- package/src/components/KeyboardFocusLock/KeyboardFocusLockBase/KeyboardFocusLockBase.tsx +20 -3
- package/src/components/KeyboardFocusView/KeyboardFocusView.tsx +2 -0
- package/src/nativeSpec/ExternalKeyboardLockViewNativeComponent.ts +1 -0
- package/src/nativeSpec/TextInputFocusWrapperNativeComponent.ts +16 -0
- package/src/types/BaseKeyboardView.ts +2 -0
- package/src/types/KeyboardFocusLock.types.ts +1 -0
- package/src/types/WithKeyboardFocus.ts +19 -2
- package/src/utils/useFocusStyle.tsx +5 -15
- package/src/utils/withKeyboardFocus.tsx +44 -15
- package/src/utils/wrapOrderPrefix.ts +16 -0
- package/ios/Delegates/RNCEKVFocusOrderDelegate/RNCEKVFocusGuideDelegate/RNCEKVFocusGuideDelegate.h +0 -36
- package/ios/Delegates/RNCEKVFocusOrderDelegate/RNCEKVFocusGuideDelegate/RNCEKVFocusGuideDelegate.mm +0 -150
- package/ios/Delegates/RNCEKVFocusOrderDelegate/RNCEKVFocusOrderDelegate.h +0 -47
- package/ios/Delegates/RNCEKVFocusOrderDelegate/RNCEKVFocusOrderDelegate.mm +0 -326
- package/ios/Services/RNCEKVKeyboardOrderManager/RNCEKVKeyboardOrderManager.h +0 -17
- package/ios/Services/RNCEKVKeyboardOrderManager/RNCEKVKeyboardOrderManager.mm +0 -15
- package/lib/commonjs/components/KeyboardFocusLock/KeyboardFocusLockBase/KeyboardFocusLockBase.android.js +0 -22
- package/lib/commonjs/components/KeyboardFocusLock/KeyboardFocusLockBase/KeyboardFocusLockBase.android.js.map +0 -1
- package/lib/module/components/KeyboardFocusLock/KeyboardFocusLockBase/KeyboardFocusLockBase.android.js +0 -17
- package/lib/module/components/KeyboardFocusLock/KeyboardFocusLockBase/KeyboardFocusLockBase.android.js.map +0 -1
- package/lib/typescript/src/components/KeyboardFocusLock/KeyboardFocusLockBase/KeyboardFocusLockBase.android.d.ts +0 -4
- package/lib/typescript/src/components/KeyboardFocusLock/KeyboardFocusLockBase/KeyboardFocusLockBase.android.d.ts.map +0 -1
- package/src/components/KeyboardFocusLock/KeyboardFocusLockBase/KeyboardFocusLockBase.android.tsx +0 -16
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["_react","_interopRequireWildcard","require","_reactNative","_nativeSpec","_useFocusStyle","_focusEventMapper","_RenderPropComponent","_GroupIdentifierContext","_KeyboardExtendedInput","_jsxRuntime","e","t","WeakMap","r","n","__esModule","o","i","f","__proto__","default","has","get","set","hasOwnProperty","call","Object","defineProperty","getOwnPropertyDescriptor","isIOS","Platform","OS","KeyboardExtendedInput","exports","React","forwardRef","focusType","blurType","containerStyle","onFocusChange","focusStyle","style","haloEffect","canBeFocusable","focusable","containerFocusStyle","tintColor","tintType","FocusHoverComponent","onSubmitEditing","submitBehavior","groupIdentifier","rejectResponderTermination","selectionHandleColor","cursorColor","maxFontSizeMultiplier","props","ref","focused","containerFocusedStyle","componentFocusedStyle","onFocusChangeHandler","hoverColor","useFocusStyle","contextIdentifier","useGroupIdentifierContext","withHaloEffect","nativeFocusHandler","useMemo","focusEventMapper","HoverComonent","jsx","View","styles","absolute","opacity","undefined","blurOnSubmit","jsxs","TextInputFocusWrapperNative","focusMap","blurMap","multiline","onMultiplyTextSubmit","canBeFocused","children","TextInput","editable","RenderPropComponent","render","StyleSheet","create","position","top","left","right","bottom"],"sourceRoot":"../../../../src","sources":["components/KeyboardExtendedInput/KeyboardExtendedInput.tsx"],"mappings":";;;;;;AAAA,IAAAA,MAAA,GAAAC,uBAAA,CAAAC,OAAA;AACA,IAAAC,YAAA,GAAAD,OAAA;AAEA,IAAAE,WAAA,GAAAF,OAAA;AACA,IAAAG,cAAA,GAAAH,OAAA;AACA,IAAAI,iBAAA,GAAAJ,OAAA;AACA,IAAAK,oBAAA,GAAAL,OAAA;AACA,IAAAM,uBAAA,GAAAN,OAAA;
|
|
1
|
+
{"version":3,"names":["_react","_interopRequireWildcard","require","_reactNative","_nativeSpec","_useFocusStyle","_focusEventMapper","_RenderPropComponent","_GroupIdentifierContext","_OrderFocusContext","_KeyboardExtendedInput","_wrapOrderPrefix","_BaseKeyboardView","_jsxRuntime","e","t","WeakMap","r","n","__esModule","o","i","f","__proto__","default","has","get","set","hasOwnProperty","call","Object","defineProperty","getOwnPropertyDescriptor","BITS","focusBinaryValue","LockFocusEnum","Up","BIT_01","Down","BIT_02","Left","BIT_03","Right","BIT_04","Forward","BIT_05","Backward","BIT_06","First","BIT_09","Last","BIT_10","mapLockFocus","values","length","reduce","acc","item","isIOS","Platform","OS","KeyboardExtendedInput","exports","React","forwardRef","focusType","blurType","containerStyle","onFocusChange","focusStyle","style","haloEffect","canBeFocusable","focusable","containerFocusStyle","tintColor","tintType","FocusHoverComponent","onSubmitEditing","submitBehavior","groupIdentifier","lockFocus","orderGroup","orderIndex","orderId","orderForward","orderBackward","orderLeft","orderRight","orderUp","orderDown","rejectResponderTermination","selectionHandleColor","cursorColor","maxFontSizeMultiplier","orderFirst","orderLast","defaultFocusHighlightEnabled","orderPrefix","_orderPrefix","props","ref","focused","containerFocusedStyle","componentFocusedStyle","onFocusChangeHandler","hoverColor","useFocusStyle","contextIdentifier","useGroupIdentifierContext","contextGroupId","useOrderFocusGroup","groupId","withHaloEffect","select","ios","android","nativeFocusHandler","useMemo","focusEventMapper","HoverComonent","jsx","View","styles","absolute","opacity","undefined","blurOnSubmit","useEffect","__DEV__","console","warn","hasOrderLinkProp","wrapPrefix","wrapOrderPrefix","wrappedOrderProps","jsxs","TextInputFocusWrapperNative","focusMap","blurMap","multiline","onMultiplyTextSubmit","canBeFocused","children","TextInput","editable","RenderPropComponent","render","StyleSheet","create","position","top","left","right","bottom"],"sourceRoot":"../../../../src","sources":["components/KeyboardExtendedInput/KeyboardExtendedInput.tsx"],"mappings":";;;;;;AAAA,IAAAA,MAAA,GAAAC,uBAAA,CAAAC,OAAA;AACA,IAAAC,YAAA,GAAAD,OAAA;AAEA,IAAAE,WAAA,GAAAF,OAAA;AACA,IAAAG,cAAA,GAAAH,OAAA;AACA,IAAAI,iBAAA,GAAAJ,OAAA;AACA,IAAAK,oBAAA,GAAAL,OAAA;AACA,IAAAM,uBAAA,GAAAN,OAAA;AACA,IAAAO,kBAAA,GAAAP,OAAA;AAEA,IAAAQ,sBAAA,GAAAR,OAAA;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object.defineProperty(exports, "__esModule", {
|
|
|
6
6
|
exports.FocusTrap = void 0;
|
|
7
7
|
var _reactNative = require("react-native");
|
|
8
8
|
var _FocusTrapMountWrapper = require("./FocusTrapMountWrapper");
|
|
9
|
+
var _KeyboardFocusLockBase = require("../KeyboardFocusLockBase/KeyboardFocusLockBase");
|
|
9
10
|
var _jsxRuntime = require("react/jsx-runtime");
|
|
10
|
-
const FocusTrap =
|
|
11
|
-
|
|
11
|
+
const FocusTrap = ({
|
|
12
|
+
forceLock = false,
|
|
13
|
+
...props
|
|
14
|
+
}) => {
|
|
15
|
+
if (forceLock) {
|
|
16
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_FocusTrapMountWrapper.FocusTrapMountWrapper, {
|
|
17
|
+
children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_KeyboardFocusLockBase.KeyboardFocusLockBase, {
|
|
18
|
+
collapsable: false,
|
|
19
|
+
accessibilityViewIsModal: true,
|
|
20
|
+
forceLock: forceLock,
|
|
21
|
+
...props
|
|
22
|
+
})
|
|
23
|
+
});
|
|
24
|
+
}
|
|
25
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.View, {
|
|
12
26
|
collapsable: false,
|
|
13
27
|
accessibilityViewIsModal: true,
|
|
14
28
|
...props
|
|
15
|
-
})
|
|
16
|
-
}
|
|
29
|
+
});
|
|
30
|
+
};
|
|
17
31
|
exports.FocusTrap = FocusTrap;
|
|
18
32
|
//# sourceMappingURL=FocusTrap.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["_reactNative","require","_FocusTrapMountWrapper","_jsxRuntime","FocusTrap","props","jsx","FocusTrapMountWrapper","children","
|
|
1
|
+
{"version":3,"names":["_reactNative","require","_FocusTrapMountWrapper","_KeyboardFocusLockBase","_jsxRuntime","FocusTrap","forceLock","props","jsx","FocusTrapMountWrapper","children","KeyboardFocusLockBase","collapsable","accessibilityViewIsModal","View","exports"],"sourceRoot":"../../../../../src","sources":["components/KeyboardFocusLock/FocusTrap/FocusTrap.tsx"],"mappings":";;;;;;AAAA,IAAAA,YAAA,GAAAC,OAAA;AACA,IAAAC,sBAAA,GAAAD,OAAA;AAEA,IAAAE,sBAAA,GAAAF,OAAA;AAAuF,IAAAG,WAAA,GAAAH,OAAA;AAEhF,MAAMI,SAAS,GAAGA,CAAC;EACxBC,SAAS,GAAG,KAAK;EACjB,GAAGC;AACmB,CAAC,KAAK;EAC5B,IAAID,SAAS,EAAE;IACb,oBACE,IAAAF,WAAA,CAAAI,GAAA,EAACN,sBAAA,CAAAO,qBAAqB;MAAAC,QAAA,eACpB,IAAAN,WAAA,CAAAI,GAAA,EAACL,sBAAA,CAAAQ,qBAAqB;QACpBC,WAAW,EAAE,KAAM;QACnBC,wBAAwB,EAAE,IAAK;QAC/BP,SAAS,EAAEA,SAAU;QAAA,GACjBC;MAAK,CACV;IAAC,CACmB,CAAC;EAE5B;EAEA,oBACE,IAAAH,WAAA,CAAAI,GAAA,EAACR,YAAA,CAAAc,IAAI;IAACF,WAAW,EAAE,KAAM;IAACC,wBAAwB,EAAE,IAAK;IAAA,GAAKN;EAAK,CAAG,CAAC;AAE3E,CAAC;AAACQ,OAAA,CAAAV,SAAA,GAAAA,SAAA","ignoreList":[]}
|
package/lib/commonjs/components/KeyboardFocusLock/KeyboardFocusLockBase/KeyboardFocusLockBase.js
CHANGED
|
@@ -4,6 +4,21 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
6
|
exports.KeyboardFocusLockBase = void 0;
|
|
7
|
-
var
|
|
8
|
-
|
|
7
|
+
var _react = _interopRequireDefault(require("react"));
|
|
8
|
+
var _ExternalKeyboardLockViewNativeComponent = _interopRequireDefault(require("../../../nativeSpec/ExternalKeyboardLockViewNativeComponent"));
|
|
9
|
+
var _jsxRuntime = require("react/jsx-runtime");
|
|
10
|
+
function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
|
|
11
|
+
const KeyboardFocusLockBase = exports.KeyboardFocusLockBase = /*#__PURE__*/_react.default.memo(({
|
|
12
|
+
lockDisabled = false,
|
|
13
|
+
componentType = 0,
|
|
14
|
+
forceLock = false,
|
|
15
|
+
...props
|
|
16
|
+
}) => {
|
|
17
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_ExternalKeyboardLockViewNativeComponent.default, {
|
|
18
|
+
...props,
|
|
19
|
+
componentType: componentType,
|
|
20
|
+
lockDisabled: lockDisabled,
|
|
21
|
+
forceLock: forceLock
|
|
22
|
+
});
|
|
23
|
+
});
|
|
9
24
|
//# sourceMappingURL=KeyboardFocusLockBase.js.map
|
package/lib/commonjs/components/KeyboardFocusLock/KeyboardFocusLockBase/KeyboardFocusLockBase.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["
|
|
1
|
+
{"version":3,"names":["_react","_interopRequireDefault","require","_ExternalKeyboardLockViewNativeComponent","_jsxRuntime","e","__esModule","default","KeyboardFocusLockBase","exports","React","memo","lockDisabled","componentType","forceLock","props","jsx"],"sourceRoot":"../../../../../src","sources":["components/KeyboardFocusLock/KeyboardFocusLockBase/KeyboardFocusLockBase.tsx"],"mappings":";;;;;;AAAA,IAAAA,MAAA,GAAAC,sBAAA,CAAAC,OAAA;AACA,IAAAC,wCAAA,GAAAF,sBAAA,CAAAC,OAAA;AAAmG,IAAAE,WAAA,GAAAF,OAAA;AAAA,SAAAD,uBAAAI,CAAA,WAAAA,CAAA,IAAAA,CAAA,CAAAC,UAAA,GAAAD,CAAA,KAAAE,OAAA,EAAAF,CAAA;AAI5F,MAAMG,qBAAqB,GAAAC,OAAA,CAAAD,qBAAA,gBAAGE,cAAK,CAACC,IAAI,CAC7C,CAAC;EACCC,YAAY,GAAG,KAAK;EACpBC,aAAa,GAAG,CAAC;EACjBC,SAAS,GAAG,KAAK;EACjB,GAAGC;AACL,CAAC,KAAK;EACJ,oBACE,IAAAX,WAAA,CAAAY,GAAA,EAACb,wCAAA,CAAAI,OAAwB;IAAA,GACnBQ,KAAK;IACTF,aAAa,EAAEA,aAAc;IAC7BD,YAAY,EAAEA,YAAa;IAC3BE,SAAS,EAAEA;EAAU,CACtB,CAAC;AAEN,CACF,CAAC","ignoreList":[]}
|
|
@@ -36,6 +36,7 @@ const KeyboardFocusView = exports.KeyboardFocusView = /*#__PURE__*/_react.defaul
|
|
|
36
36
|
children,
|
|
37
37
|
accessible,
|
|
38
38
|
triggerCodes,
|
|
39
|
+
defaultFocusHighlightEnabled = true,
|
|
39
40
|
...props
|
|
40
41
|
}, ref) => {
|
|
41
42
|
const {
|
|
@@ -83,6 +84,7 @@ const KeyboardFocusView = exports.KeyboardFocusView = /*#__PURE__*/_react.defaul
|
|
|
83
84
|
onFocusChange: onFocusChangeHandler,
|
|
84
85
|
onContextMenuPress: onLongPress,
|
|
85
86
|
haloEffect: withHaloEffect,
|
|
87
|
+
defaultFocusHighlightEnabled: defaultFocusHighlightEnabled,
|
|
86
88
|
autoFocus: autoFocus,
|
|
87
89
|
canBeFocused: canBeFocused,
|
|
88
90
|
focusable: focusable,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["_react","_interopRequireWildcard","require","_reactNative","_BaseKeyboardView","_RenderPropComponent","_useFocusStyle","_useKeyboardPress","_IsViewFocusedContext","_jsxRuntime","e","t","WeakMap","r","n","__esModule","o","i","f","__proto__","default","has","get","set","hasOwnProperty","call","Object","defineProperty","getOwnPropertyDescriptor","KeyboardFocusView","exports","React","forwardRef","tintType","autoFocus","focusStyle","style","onFocusChange","onPress","onLongPress","onKeyUpPress","onKeyDownPress","group","haloEffect","canBeFocused","focusable","withView","tintColor","onFocus","onBlur","FocusHoverComponent","children","accessible","triggerCodes","props","ref","focused","containerFocusedStyle","onFocusChangeHandler","hoverColor","useFocusStyle","containerFocusStyle","withHaloEffect","onKeyUpPressHandler","onKeyDownPressHandler","useKeyboardPress","disabled","HoverComonent","useMemo","jsx","View","styles","absolute","opacity","undefined","a11y","Platform","OS","IsViewFocusedContext","Provider","value","jsxs","BaseKeyboardView","onContextMenuPress","enableContextMenu","Boolean","RenderPropComponent","render","StyleSheet","create","position","top","left","right","bottom"],"sourceRoot":"../../../../src","sources":["components/KeyboardFocusView/KeyboardFocusView.tsx"],"mappings":";;;;;;AAAA,IAAAA,MAAA,GAAAC,uBAAA,CAAAC,OAAA;AACA,IAAAC,YAAA,GAAAD,OAAA;AAEA,IAAAE,iBAAA,GAAAF,OAAA;AAMA,IAAAG,oBAAA,GAAAH,OAAA;AAIA,IAAAI,cAAA,GAAAJ,OAAA;AACA,IAAAK,iBAAA,GAAAL,OAAA;AACA,IAAAM,qBAAA,GAAAN,OAAA;AAA0E,IAAAO,WAAA,GAAAP,OAAA;AAAA,SAAAD,wBAAAS,CAAA,EAAAC,CAAA,6BAAAC,OAAA,MAAAC,CAAA,OAAAD,OAAA,IAAAE,CAAA,OAAAF,OAAA,YAAAX,uBAAA,YAAAA,CAAAS,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;AAEnE,MAAMkB,iBAAiB,GAAAC,OAAA,CAAAD,iBAAA,gBAAGE,cAAK,CAACC,UAAU,CAQ/C,CACE;EACEC,QAAQ,GAAG,SAAS;EACpBC,SAAS;EACTC,UAAU;EACVC,KAAK;EACLC,aAAa;EACbC,OAAO;EACPC,WAAW;EACXC,YAAY;EACZC,cAAc;EACdC,KAAK,GAAG,KAAK;EACbC,UAAU,GAAG,IAAI;EACjBC,YAAY,GAAG,IAAI;EACnBC,SAAS,GAAG,IAAI;EAChBC,QAAQ,GAAG,IAAI;EAAE;EACjBC,SAAS;EACTC,OAAO;EACPC,MAAM;EACNC,mBAAmB;EACnBC,QAAQ;EACRC,UAAU;EACVC,YAAY;
|
|
1
|
+
{"version":3,"names":["_react","_interopRequireWildcard","require","_reactNative","_BaseKeyboardView","_RenderPropComponent","_useFocusStyle","_useKeyboardPress","_IsViewFocusedContext","_jsxRuntime","e","t","WeakMap","r","n","__esModule","o","i","f","__proto__","default","has","get","set","hasOwnProperty","call","Object","defineProperty","getOwnPropertyDescriptor","KeyboardFocusView","exports","React","forwardRef","tintType","autoFocus","focusStyle","style","onFocusChange","onPress","onLongPress","onKeyUpPress","onKeyDownPress","group","haloEffect","canBeFocused","focusable","withView","tintColor","onFocus","onBlur","FocusHoverComponent","children","accessible","triggerCodes","defaultFocusHighlightEnabled","props","ref","focused","containerFocusedStyle","onFocusChangeHandler","hoverColor","useFocusStyle","containerFocusStyle","withHaloEffect","onKeyUpPressHandler","onKeyDownPressHandler","useKeyboardPress","disabled","HoverComonent","useMemo","jsx","View","styles","absolute","opacity","undefined","a11y","Platform","OS","IsViewFocusedContext","Provider","value","jsxs","BaseKeyboardView","onContextMenuPress","enableContextMenu","Boolean","RenderPropComponent","render","StyleSheet","create","position","top","left","right","bottom"],"sourceRoot":"../../../../src","sources":["components/KeyboardFocusView/KeyboardFocusView.tsx"],"mappings":";;;;;;AAAA,IAAAA,MAAA,GAAAC,uBAAA,CAAAC,OAAA;AACA,IAAAC,YAAA,GAAAD,OAAA;AAEA,IAAAE,iBAAA,GAAAF,OAAA;AAMA,IAAAG,oBAAA,GAAAH,OAAA;AAIA,IAAAI,cAAA,GAAAJ,OAAA;AACA,IAAAK,iBAAA,GAAAL,OAAA;AACA,IAAAM,qBAAA,GAAAN,OAAA;AAA0E,IAAAO,WAAA,GAAAP,OAAA;AAAA,SAAAD,wBAAAS,CAAA,EAAAC,CAAA,6BAAAC,OAAA,MAAAC,CAAA,OAAAD,OAAA,IAAAE,CAAA,OAAAF,OAAA,YAAAX,uBAAA,YAAAA,CAAAS,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,EAAA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,IAAA3D,WAAA,CAAA6D,GAAA,EAACjE,oBAAA,CAAAkF,mBAAmB;QAACC,MAAM,EAAEpB;MAAc,CAAE,CAC9C;IAAA,CACe;EAAC,CACU,CAAC;AAEpC,CACF,CAAC;AAED,MAAMI,MAAM,GAAGiB,uBAAU,CAACC,MAAM,CAAC;EAC/BjB,QAAQ,EAAE;IACRkB,QAAQ,EAAE,UAAU;IACpBC,GAAG,EAAE,CAAC;IACNC,IAAI,EAAE,CAAC;IACPC,KAAK,EAAE,CAAC;IACRC,MAAM,EAAE;EACV,CAAC;EACDrB,OAAO,EAAE;IACPA,OAAO,EAAE;EACX;AACF,CAAC,CAAC","ignoreList":[]}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import type { ViewProps, ColorValue } from 'react-native';
|
|
2
2
|
import type {
|
|
3
3
|
DirectEventHandler,
|
|
4
|
+
Float,
|
|
4
5
|
Int32,
|
|
5
6
|
} from 'react-native/Libraries/Types/CodegenTypes';
|
|
6
7
|
// eslint-disable-next-line @react-native/no-deep-imports
|
|
@@ -21,10 +22,25 @@ export interface TextInputFocusWrapperNativeComponent extends ViewProps {
|
|
|
21
22
|
blurType?: Int32;
|
|
22
23
|
canBeFocused?: boolean;
|
|
23
24
|
haloEffect?: boolean;
|
|
25
|
+
haloCornerRadius?: Float;
|
|
26
|
+
haloExpendX?: Float;
|
|
27
|
+
haloExpendY?: Float;
|
|
24
28
|
tintColor?: ColorValue;
|
|
25
29
|
blurOnSubmit?: boolean;
|
|
26
30
|
multiline?: boolean;
|
|
27
31
|
groupIdentifier?: string;
|
|
32
|
+
lockFocus?: Int32;
|
|
33
|
+
orderGroup?: string;
|
|
34
|
+
orderIndex?: Int32;
|
|
35
|
+
orderId?: string;
|
|
36
|
+
orderLeft?: string;
|
|
37
|
+
orderRight?: string;
|
|
38
|
+
orderUp?: string;
|
|
39
|
+
orderDown?: string;
|
|
40
|
+
orderForward?: string;
|
|
41
|
+
orderBackward?: string;
|
|
42
|
+
orderFirst?: string;
|
|
43
|
+
orderLast?: string;
|
|
28
44
|
}
|
|
29
45
|
|
|
30
46
|
export default codegenNativeComponent<TextInputFocusWrapperNativeComponent>(
|
|
@@ -6,15 +6,9 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
6
6
|
exports.useFocusStyle = void 0;
|
|
7
7
|
var _react = require("react");
|
|
8
8
|
var _reactNative = require("react-native");
|
|
9
|
-
const backgroundTintMap =
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
},
|
|
13
|
-
default: {
|
|
14
|
-
background: true,
|
|
15
|
-
default: true
|
|
16
|
-
}
|
|
17
|
-
});
|
|
9
|
+
const backgroundTintMap = {
|
|
10
|
+
background: true
|
|
11
|
+
};
|
|
18
12
|
const DEFAULT_BACKGROUND_TINT = '#dce3f9';
|
|
19
13
|
const useFocusStyle = ({
|
|
20
14
|
focusStyle,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["_react","require","_reactNative","backgroundTintMap","
|
|
1
|
+
{"version":3,"names":["_react","require","_reactNative","backgroundTintMap","background","DEFAULT_BACKGROUND_TINT","useFocusStyle","focusStyle","onFocusChange","containerFocusStyle","tintColor","tintType","style","Component","withPressedStyle","focused","setFocusStatus","useState","onFocusChangeHandler","useCallback","isFocused","componentFocusedStyle","useMemo","specificStyle","undefined","hoverColor","backgroundColor","containerFocusedStyle","dafaultComponentStyle","styleHandlerPressable","pressed","componentStyleViewStyle","Pressable","exports"],"sourceRoot":"../../../src","sources":["utils/useFocusStyle.tsx"],"mappings":";;;;;;AAAA,IAAAA,MAAA,GAAAC,OAAA;AACA,IAAAC,YAAA,GAAAD,OAAA;AAIA,MAAME,iBAAqD,GAAG;EAC5DC,UAAU,EAAE;AACd,CAAC;AAED,MAAMC,uBAAuB,GAAG,SAAS;AAclC,MAAMC,aAAa,GAAGA,CAAe;EAC1CC,UAAU;EACVC,aAAa;EACbC,mBAAmB;EACnBC,SAAS;EACTC,QAAQ,GAAG,SAAS;EACpBC,KAAK;EAC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AG,IAAAN,cAAO,EACnC,MAAM,CAACV,KAAK,EAAES,qBAAqB,CAAC,EACpC,CAACT,KAAK,EAAES,qBAAqB,CAC/B,CAAC;EACD,MAAMQ,qBAAqB,GAAG,IAAAV,kBAAW,EACvC,CAAC;IAAEW;EAA8B,CAAC,KAAK;IACrC,IAAI,OAAOlB,KAAK,KAAK,UAAU,EAAE;MAC/B,OAAO,CAACA,KAAK,CAAC;QAAEkB;MAAQ,CAAC,CAAC,EAAET,qBAAqB,CAAC;IACpD,CAAC,MAAM;MACL,OAAO,CAACT,KAAK,EAAES,qBAAqB,CAAC;IACvC;EACF,CAAC,EACD,CAACA,qBAAqB,EAAET,KAAK,CAC/B,CAAC;EAED,MAAMmB,uBAAuB,GAC3BlB,SAAS,KAAKmB,sBAAS,IAAIlB,gBAAgB,GACvCe,qBAAqB,GACrBD,qBAAqB;EAE3B,OAAO;IACLG,uBAAuB;IACvBV,qBAAqB;IACrBM,qBAAqB;IACrBT,oBAAoB;IACpBO,UAAU;IACVV;EACF,CAAC;AACH,CAAC;AAACkB,OAAA,CAAA3B,aAAA,GAAAA,aAAA","ignoreList":[]}
|
|
@@ -64,6 +64,9 @@ const withKeyboardFocus = Component => {
|
|
|
64
64
|
lockFocus,
|
|
65
65
|
onComponentFocus,
|
|
66
66
|
onComponentBlur,
|
|
67
|
+
renderContent,
|
|
68
|
+
renderFocusable,
|
|
69
|
+
defaultFocusHighlightEnabled,
|
|
67
70
|
...props
|
|
68
71
|
} = allProps;
|
|
69
72
|
const {
|
|
@@ -97,7 +100,14 @@ const withKeyboardFocus = Component => {
|
|
|
97
100
|
triggerCodes,
|
|
98
101
|
disabled: props?.disabled
|
|
99
102
|
});
|
|
100
|
-
const
|
|
103
|
+
const contentChildrenProp = (0, _react.useMemo)(() => renderContent ? state => renderContent({
|
|
104
|
+
...state,
|
|
105
|
+
focused
|
|
106
|
+
}) : undefined, [renderContent, focused]);
|
|
107
|
+
const focusableChildrenProp = (0, _react.useMemo)(() => renderFocusable ? renderFocusable({
|
|
108
|
+
focused
|
|
109
|
+
}) : undefined, [renderFocusable, focused]);
|
|
110
|
+
const hoverContent = (0, _react.useMemo)(() => {
|
|
101
111
|
if (FocusHoverComponent) return FocusHoverComponent;
|
|
102
112
|
if (tintType === 'hover') {
|
|
103
113
|
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.View, {
|
|
@@ -106,6 +116,19 @@ const withKeyboardFocus = Component => {
|
|
|
106
116
|
}
|
|
107
117
|
return undefined;
|
|
108
118
|
}, [FocusHoverComponent, hoverColor, tintType]);
|
|
119
|
+
const focusOrderProps = {
|
|
120
|
+
orderIndex,
|
|
121
|
+
orderGroup,
|
|
122
|
+
orderId,
|
|
123
|
+
orderLeft,
|
|
124
|
+
orderRight,
|
|
125
|
+
orderUp,
|
|
126
|
+
orderDown,
|
|
127
|
+
orderForward,
|
|
128
|
+
orderBackward,
|
|
129
|
+
orderFirst,
|
|
130
|
+
orderLast
|
|
131
|
+
};
|
|
109
132
|
const onContextMenuHandler = (0, _react.useCallback)(() => {
|
|
110
133
|
onLongPress?.();
|
|
111
134
|
}, [onLongPress]);
|
|
@@ -113,6 +136,7 @@ const withKeyboardFocus = Component => {
|
|
|
113
136
|
value: focused,
|
|
114
137
|
children: /*#__PURE__*/(0, _jsxRuntime.jsxs)(_components.BaseKeyboardView, {
|
|
115
138
|
style: [containerStyle, containerFocusedStyle],
|
|
139
|
+
defaultFocusHighlightEnabled: defaultFocusHighlightEnabled,
|
|
116
140
|
ref: ref,
|
|
117
141
|
viewRef: viewRef,
|
|
118
142
|
onKeyUpPress: onKeyUpPressHandler,
|
|
@@ -136,18 +160,8 @@ const withKeyboardFocus = Component => {
|
|
|
136
160
|
enableA11yFocus: enableA11yFocus,
|
|
137
161
|
screenAutoA11yFocus: screenAutoA11yFocus,
|
|
138
162
|
screenAutoA11yFocusDelay: screenAutoA11yFocusDelay,
|
|
139
|
-
orderIndex: orderIndex,
|
|
140
|
-
orderGroup: orderGroup,
|
|
141
163
|
lockFocus: lockFocus,
|
|
142
|
-
|
|
143
|
-
orderLeft: orderLeft,
|
|
144
|
-
orderRight: orderRight,
|
|
145
|
-
orderUp: orderUp,
|
|
146
|
-
orderDown: orderDown,
|
|
147
|
-
orderForward: orderForward,
|
|
148
|
-
orderBackward: orderBackward,
|
|
149
|
-
orderFirst: orderFirst,
|
|
150
|
-
orderLast: orderLast,
|
|
164
|
+
...focusOrderProps,
|
|
151
165
|
children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(Component, {
|
|
152
166
|
ref: componentRef,
|
|
153
167
|
style: componentStyleViewStyle,
|
|
@@ -157,9 +171,12 @@ const withKeyboardFocus = Component => {
|
|
|
157
171
|
onPressOut: onPressOut,
|
|
158
172
|
onFocus: onComponentFocus,
|
|
159
173
|
onBlur: onComponentBlur,
|
|
160
|
-
...props
|
|
161
|
-
|
|
162
|
-
|
|
174
|
+
...props,
|
|
175
|
+
...((contentChildrenProp || focusableChildrenProp) && {
|
|
176
|
+
children: contentChildrenProp ?? focusableChildrenProp
|
|
177
|
+
})
|
|
178
|
+
}), focused && hoverContent && /*#__PURE__*/(0, _jsxRuntime.jsx)(_RenderPropComponent.RenderPropComponent, {
|
|
179
|
+
render: hoverContent
|
|
163
180
|
})]
|
|
164
181
|
})
|
|
165
182
|
});
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["_react","_interopRequireWildcard","require","_reactNative","_components","_useFocusStyle","_RenderPropComponent","_useKeyboardPress","_IsViewFocusedContext","_jsxRuntime","e","t","WeakMap","r","n","__esModule","o","i","f","__proto__","default","has","get","set","hasOwnProperty","call","Object","defineProperty","getOwnPropertyDescriptor","withKeyboardFocus","Component","WithKeyboardFocus","React","memo","forwardRef","allProps","ref","tintType","autoFocus","focusStyle","style","containerStyle","onFocusChange","onPress","onLongPress","onKeyUpPress","onKeyDownPress","onPressIn","onPressOut","group","haloEffect","canBeFocused","focusable","tintColor","onFocus","onBlur","containerFocusStyle","FocusHoverComponent","viewRef","componentRef","haloCornerRadius","haloExpendX","haloExpendY","groupIdentifier","withPressedStyle","triggerCodes","exposeMethods","enableA11yFocus","screenAutoA11yFocus","screenAutoA11yFocusDelay","orderIndex","orderGroup","orderId","orderLeft","orderRight","orderUp","orderDown","orderForward","orderBackward","orderFirst","orderLast","lockFocus","onComponentFocus","onComponentBlur","props","focused","containerFocusedStyle","componentStyleViewStyle","onFocusChangeHandler","hoverColor","useFocusStyle","withHaloEffect","onKeyUpPressHandler","onKeyDownPressHandler","onPressHandler","useKeyboardPress","disabled","
|
|
1
|
+
{"version":3,"names":["_react","_interopRequireWildcard","require","_reactNative","_components","_useFocusStyle","_RenderPropComponent","_useKeyboardPress","_IsViewFocusedContext","_jsxRuntime","e","t","WeakMap","r","n","__esModule","o","i","f","__proto__","default","has","get","set","hasOwnProperty","call","Object","defineProperty","getOwnPropertyDescriptor","withKeyboardFocus","Component","WithKeyboardFocus","React","memo","forwardRef","allProps","ref","tintType","autoFocus","focusStyle","style","containerStyle","onFocusChange","onPress","onLongPress","onKeyUpPress","onKeyDownPress","onPressIn","onPressOut","group","haloEffect","canBeFocused","focusable","tintColor","onFocus","onBlur","containerFocusStyle","FocusHoverComponent","viewRef","componentRef","haloCornerRadius","haloExpendX","haloExpendY","groupIdentifier","withPressedStyle","triggerCodes","exposeMethods","enableA11yFocus","screenAutoA11yFocus","screenAutoA11yFocusDelay","orderIndex","orderGroup","orderId","orderLeft","orderRight","orderUp","orderDown","orderForward","orderBackward","orderFirst","orderLast","lockFocus","onComponentFocus","onComponentBlur","renderContent","renderFocusable","defaultFocusHighlightEnabled","props","focused","containerFocusedStyle","componentStyleViewStyle","onFocusChangeHandler","hoverColor","useFocusStyle","withHaloEffect","onKeyUpPressHandler","onKeyDownPressHandler","onPressHandler","useKeyboardPress","disabled","contentChildrenProp","useMemo","state","undefined","focusableChildrenProp","hoverContent","jsx","View","styles","absolute","opacity","focusOrderProps","onContextMenuHandler","useCallback","IsViewFocusedContext","Provider","value","children","jsxs","BaseKeyboardView","onContextMenuPress","enableContextMenu","Boolean","RenderPropComponent","render","wrappedComponentName","displayName","name","exports","StyleSheet","create","position","top","left","right","bottom"],"sourceRoot":"../../../src","sources":["utils/withKeyboardFocus.tsx"],"mappings":";;;;;;AAAA,IAAAA,MAAA,GAAAC,uBAAA,CAAAC,OAAA;AACA,IAAAC,YAAA,GAAAD,OAAA;AACA,IAAAE,WAAA,GAAAF,OAAA;AAEA,IAAAG,cAAA,GAAAH,OAAA;AAMA,IAAAI,oBAAA,GAAAJ,OAAA;AACA,IAAAK,iBAAA,GAAAL,OAAA;AACA,IAAAM,qBAAA,GAAAN,OAAA;AAAuE,IAAAO,WAAA,GAAAP,OAAA;AAAA,SAAAD,wBAAAS,CAAA,EAAAC,CAAA,6BAAAC,OAAA,MAAAC,CAAA,OAAAD,OAAA,IAAAE,CAAA,OAAAF,OAAA,YAAAX,uBAAA,YAAAA,CAAAS,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,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
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.wrapOrderPrefix = void 0;
|
|
7
|
+
const withPrefix = prefix => id => id ? `${prefix}_${id}` : undefined;
|
|
8
|
+
const identity = id => id;
|
|
9
|
+
|
|
10
|
+
/**
|
|
11
|
+
* Returns a function that prepends `prefix` to an order ID.
|
|
12
|
+
* When `prefix` is empty the identity function is returned — no
|
|
13
|
+
* per-call branch needed.
|
|
14
|
+
*/
|
|
15
|
+
const wrapOrderPrefix = prefix => prefix ? withPrefix(prefix) : identity;
|
|
16
|
+
exports.wrapOrderPrefix = wrapOrderPrefix;
|
|
17
|
+
//# sourceMappingURL=wrapOrderPrefix.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["withPrefix","prefix","id","undefined","identity","wrapOrderPrefix","exports"],"sourceRoot":"../../../src","sources":["utils/wrapOrderPrefix.ts"],"mappings":";;;;;;AAEA,MAAMA,UAAU,GACbC,MAAc,IACdC,EAAE,IACDA,EAAE,GAAG,GAAGD,MAAM,IAAIC,EAAE,EAAE,GAAGC,SAAS;AAEtC,MAAMC,QAAc,GAAIF,EAAE,IAAKA,EAAE;;AAEjC;AACA;AACA;AACA;AACA;AACO,MAAMG,eAAe,GAAIJ,MAAc,IAC5CA,MAAM,GAAGD,UAAU,CAACC,MAAM,CAAC,GAAGG,QAAQ;AAACE,OAAA,CAAAD,eAAA,GAAAA,eAAA","ignoreList":[]}
|
|
@@ -10,6 +10,7 @@ import { useBubbledInfo } from './BaseKeyboardView.hooks';
|
|
|
10
10
|
import { useGroupIdentifierContext } from '../../context/GroupIdentifierContext';
|
|
11
11
|
import { useOnFocusChange } from '../../utils/useOnFocusChange';
|
|
12
12
|
import { useOrderFocusGroup } from '../../context/OrderFocusContext';
|
|
13
|
+
import { wrapOrderPrefix } from '../../utils/wrapOrderPrefix';
|
|
13
14
|
|
|
14
15
|
// @ts-ignore
|
|
15
16
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
@@ -70,7 +71,14 @@ export const BaseKeyboardView = /*#__PURE__*/React.memo(/*#__PURE__*/React.forwa
|
|
|
70
71
|
orderFirst,
|
|
71
72
|
orderLast,
|
|
72
73
|
orderGroup,
|
|
74
|
+
orderLeft,
|
|
75
|
+
orderRight,
|
|
76
|
+
orderUp,
|
|
77
|
+
orderDown,
|
|
78
|
+
orderId,
|
|
73
79
|
enableContextMenu,
|
|
80
|
+
orderPrefix: _orderPrefix,
|
|
81
|
+
defaultFocusHighlightEnabled = true,
|
|
74
82
|
...props
|
|
75
83
|
}, ref) => {
|
|
76
84
|
const localRef = useRef(undefined);
|
|
@@ -79,9 +87,18 @@ export const BaseKeyboardView = /*#__PURE__*/React.memo(/*#__PURE__*/React.forwa
|
|
|
79
87
|
const contextIdentifier = useGroupIdentifierContext();
|
|
80
88
|
const contextGroupId = useOrderFocusGroup();
|
|
81
89
|
const groupId = orderGroup ?? contextGroupId;
|
|
90
|
+
const orderPrefix = _orderPrefix ?? contextGroupId ?? '';
|
|
82
91
|
useEffect(() => {
|
|
92
|
+
if (!__DEV__) return;
|
|
83
93
|
if (orderIndex !== undefined && !groupId) console.warn('`orderIndex` must be declared alongside `orderGroup` for proper functionality. Ensure components are wrapped with `KeyboardOrderFocusGroup` or provide `orderGroup` directly.');
|
|
84
94
|
}, [groupId, orderIndex]);
|
|
95
|
+
useEffect(() => {
|
|
96
|
+
if (!__DEV__) return;
|
|
97
|
+
const hasOrderLinkProp = orderId !== undefined || orderForward !== undefined || orderBackward !== undefined || orderFirst !== undefined || orderLast !== undefined || orderLeft !== undefined || orderRight !== undefined || orderUp !== undefined || orderDown !== undefined;
|
|
98
|
+
if (hasOrderLinkProp && orderPrefix === '') {
|
|
99
|
+
console.warn('[react-native-external-keyboard] orderId, orderForward, orderBackward, orderFirst, orderLast, ' + 'orderLeft, orderRight, orderUp, and orderDown are global IDs. ' + 'Wrap the component in <KeyboardOrderFocusGroup> or pass orderPrefix to avoid ID collisions across screens.');
|
|
100
|
+
}
|
|
101
|
+
}, [orderId, orderForward, orderBackward, orderFirst, orderLast, orderLeft, orderRight, orderUp, orderDown, orderPrefix]);
|
|
85
102
|
useImperativeHandle(ref, () => {
|
|
86
103
|
const actions = {};
|
|
87
104
|
exposeMethods.forEach(method => {
|
|
@@ -105,13 +122,27 @@ export const BaseKeyboardView = /*#__PURE__*/React.memo(/*#__PURE__*/React.forwa
|
|
|
105
122
|
});
|
|
106
123
|
const hasOnFocusChanged = onFocusChange || onFocus || onBlur;
|
|
107
124
|
const ignoreFocusHint = Platform.OS !== 'ios' || !ignoreGroupFocusHint;
|
|
108
|
-
const
|
|
109
|
-
const
|
|
125
|
+
const wrapPrefix = useMemo(() => wrapOrderPrefix(orderPrefix), [orderPrefix]);
|
|
126
|
+
const wrappedOrderProps = useMemo(() => ({
|
|
127
|
+
orderId: wrapPrefix(orderId),
|
|
128
|
+
orderForward: wrapPrefix(orderForward),
|
|
129
|
+
orderBackward: wrapPrefix(orderBackward),
|
|
130
|
+
orderFirst: wrapPrefix(orderFirst === null ? undefined : orderFirst ?? orderForward),
|
|
131
|
+
orderLast: wrapPrefix(orderLast === null ? undefined : orderLast ?? orderBackward),
|
|
132
|
+
orderLeft: wrapPrefix(orderLeft),
|
|
133
|
+
orderRight: wrapPrefix(orderRight),
|
|
134
|
+
orderUp: wrapPrefix(orderUp),
|
|
135
|
+
orderDown: wrapPrefix(orderDown)
|
|
136
|
+
}), [wrapPrefix, orderId, orderForward, orderBackward, orderFirst, orderLast, orderLeft, orderRight, orderUp, orderDown]);
|
|
137
|
+
const platformSpecificHalo = useMemo(() => Platform.select({
|
|
138
|
+
ios: haloEffect,
|
|
139
|
+
android: defaultFocusHighlightEnabled
|
|
140
|
+
}) ?? true, [defaultFocusHighlightEnabled, haloEffect]);
|
|
110
141
|
return /*#__PURE__*/_jsx(KeyPressContext.Provider, {
|
|
111
142
|
value: bubbled.context,
|
|
112
143
|
children: /*#__PURE__*/_jsx(ExternalKeyboardViewNative, {
|
|
113
144
|
...props,
|
|
114
|
-
haloEffect:
|
|
145
|
+
haloEffect: platformSpecificHalo,
|
|
115
146
|
ref: targetRef,
|
|
116
147
|
enableContextMenu: enableContextMenu,
|
|
117
148
|
canBeFocused: ignoreFocusHint && focusable && canBeFocused,
|
|
@@ -133,10 +164,7 @@ export const BaseKeyboardView = /*#__PURE__*/React.memo(/*#__PURE__*/React.forwa
|
|
|
133
164
|
enableA11yFocus: enableA11yFocus,
|
|
134
165
|
screenAutoA11yFocusDelay: screenAutoA11yFocusDelay,
|
|
135
166
|
lockFocus: lockFocusValue,
|
|
136
|
-
|
|
137
|
-
orderBackward: orderBackward,
|
|
138
|
-
orderFirst: _orderFirst,
|
|
139
|
-
orderLast: _orderLast,
|
|
167
|
+
...wrappedOrderProps,
|
|
140
168
|
orderGroup: groupId
|
|
141
169
|
})
|
|
142
170
|
});
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["React","useEffect","useImperativeHandle","useMemo","useRef","Platform","ExternalKeyboardViewNative","Commands","LockFocusEnum","KeyPressContext","useBubbledInfo","useGroupIdentifierContext","useOnFocusChange","useOrderFocusGroup","jsx","_jsx","isIOS","OS","DEFAULT_EXPOSE_METHODS","BITS","focusBinaryValue","Up","BIT_01","Down","BIT_02","Left","BIT_03","Right","BIT_04","Forward","BIT_05","Backward","BIT_06","First","BIT_09","Last","BIT_10","mapFocusValues","values","length","reduce","acc","item","BaseKeyboardView","memo","forwardRef","onFocusChange","onKeyUpPress","onKeyDownPress","onBubbledContextMenuPress","haloEffect","autoFocus","canBeFocused","focusable","group","onFocus","onBlur","viewRef","groupIdentifier","tintColor","ignoreGroupFocusHint","exposeMethods","enableA11yFocus","screenAutoA11yFocusDelay","lockFocus","orderIndex","orderForward","orderBackward","orderFirst","orderLast","orderGroup","enableContextMenu","props","ref","localRef","undefined","targetRef","lockFocusValue","contextIdentifier","contextGroupId","groupId","console","warn","actions","forEach","method","args","componentActions","current","focus","bubbled","onFocusChangeHandler","hasOnFocusChanged","ignoreFocusHint","
|
|
1
|
+
{"version":3,"names":["React","useEffect","useImperativeHandle","useMemo","useRef","Platform","ExternalKeyboardViewNative","Commands","LockFocusEnum","KeyPressContext","useBubbledInfo","useGroupIdentifierContext","useOnFocusChange","useOrderFocusGroup","wrapOrderPrefix","jsx","_jsx","isIOS","OS","DEFAULT_EXPOSE_METHODS","BITS","focusBinaryValue","Up","BIT_01","Down","BIT_02","Left","BIT_03","Right","BIT_04","Forward","BIT_05","Backward","BIT_06","First","BIT_09","Last","BIT_10","mapFocusValues","values","length","reduce","acc","item","BaseKeyboardView","memo","forwardRef","onFocusChange","onKeyUpPress","onKeyDownPress","onBubbledContextMenuPress","haloEffect","autoFocus","canBeFocused","focusable","group","onFocus","onBlur","viewRef","groupIdentifier","tintColor","ignoreGroupFocusHint","exposeMethods","enableA11yFocus","screenAutoA11yFocusDelay","lockFocus","orderIndex","orderForward","orderBackward","orderFirst","orderLast","orderGroup","orderLeft","orderRight","orderUp","orderDown","orderId","enableContextMenu","orderPrefix","_orderPrefix","defaultFocusHighlightEnabled","props","ref","localRef","undefined","targetRef","lockFocusValue","contextIdentifier","contextGroupId","groupId","__DEV__","console","warn","hasOrderLinkProp","actions","forEach","method","args","componentActions","current","focus","bubbled","onFocusChangeHandler","hasOnFocusChanged","ignoreFocusHint","wrapPrefix","wrappedOrderProps","platformSpecificHalo","select","ios","android","Provider","value","context","children","contextMenu","hasKeyDownPress","Boolean","hasKeyUpPress"],"sourceRoot":"../../../../src","sources":["components/BaseKeyboardView/BaseKeyboardView.tsx"],"mappings":";;AAAA,OAAOA,KAAK,IAEVC,SAAS,EACTC,mBAAmB,EACnBC,OAAO,EACPC,MAAM,QACD,OAAO;AACd,SAASC,QAAQ,QAAQ,cAAc;AACvC,SAASC,0BAA0B,QAAQ,kBAAkB;AAC7D,SAASC,QAAQ,QAAQ,sDAAsD;AAC/E,SACEC,aAAa,QAIR,8BAA8B;AAEr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