react-native-external-keyboard 0.6.2-rc → 0.6.2
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 +11 -11
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -6,7 +6,7 @@ React Native library for enhanced external keyboard support.
|
|
|
6
6
|
- ⚡️ Bridgeless
|
|
7
7
|
|
|
8
8
|
> [!NOTE]
|
|
9
|
-
> React Native `0.80.0` includes a fix for `TextInput` focus on Android.
|
|
9
|
+
> React Native `0.80.0` (`0.79.0`) includes a fix for `TextInput` focus on Android.
|
|
10
10
|
> `TextInput`: Can now focus TextInput with keyboard ([e00028f6bb](https://github.com/facebook/react-native/commit/e00028f6bb6c19de861f9a25f377295755f3671b) by [@joevilches](https://github.com/joevilches))
|
|
11
11
|
>
|
|
12
12
|
> This means that there is no need to use the workaround with `KeyboardExtendedInput`, and it is recommended to use the default `TextInput` instead. Additionally, because of changes in `TextInput`, `focusType="press"` for `KeyboardExtendedInput` no longer works on Android.
|
|
@@ -21,10 +21,10 @@ Improved keyboard focus control with features like focus order, ordered links, a
|
|
|
21
21
|
|
|
22
22
|
<details>
|
|
23
23
|
<summary>More Information</summary>
|
|
24
|
-
|
|
24
|
+
|
|
25
25
|
Advanced focus order functionality for Android and iOS, plus focus lock!
|
|
26
26
|
|
|
27
|
-
It can be really challenging to manage focus in React Native, but fortunately, there are tools available to simplify the process.
|
|
27
|
+
It can be really challenging to manage focus in React Native, but fortunately, there are tools available to simplify the process.
|
|
28
28
|
|
|
29
29
|
## Link Focus Order
|
|
30
30
|
|
|
@@ -119,7 +119,7 @@ You can find more examples here: [Focus Order via indexes](https://github.com/Ar
|
|
|
119
119
|
|
|
120
120
|
## Focus Lock
|
|
121
121
|
|
|
122
|
-
Finally, you can lock focus to specific directions.
|
|
122
|
+
Finally, you can lock focus to specific directions.
|
|
123
123
|
|
|
124
124
|
```tsx
|
|
125
125
|
<Pressable
|
|
@@ -134,7 +134,7 @@ Finally, you can lock focus to specific directions.
|
|
|
134
134
|
| :-- | :-- | :-- |
|
|
135
135
|
| lockFocus? | An array of directions to lock focus. | Array of 'left' | 'right' | 'up' | 'down' | 'forward' | 'backward' | 'first' | 'last' |
|
|
136
136
|
|
|
137
|
-
> [!NOTE]
|
|
137
|
+
> [!NOTE]
|
|
138
138
|
> `first` and `last` are specific to `iOS`. When focus is blocked for `forward` and `backward` on iOS, it checks for the `last` and `first` elements to focus.
|
|
139
139
|
</details>
|
|
140
140
|
|
|
@@ -191,7 +191,7 @@ const KeybardedButton = withKeyboardFocus(Button);
|
|
|
191
191
|
</TouchableOpacity>
|
|
192
192
|
```
|
|
193
193
|
|
|
194
|
-
After wrapping a `Pressable` or `Touchable` with `withKeyboardFocus`, you will be able to handle `focus` and `blur` events, control the `tint color`, apply focus and container focus styles, `focus` the component using a `ref`, or configure `autoFocus`.
|
|
194
|
+
After wrapping a `Pressable` or `Touchable` with `withKeyboardFocus`, you will be able to handle `focus` and `blur` events, control the `tint color`, apply focus and container focus styles, `focus` the component using a `ref`, or configure `autoFocus`.
|
|
195
195
|
|
|
196
196
|
|
|
197
197
|
Props | Description | Type
|
|
@@ -372,7 +372,7 @@ lockFocus? | An array of directions to lock focus. | Array of 'left' \| 'right'
|
|
|
372
372
|
The `KeyboardFocusGroup` is a View-based component developed based on the iOS API. It can be used for defining focus groups or setting the `tintColor` globally.
|
|
373
373
|
|
|
374
374
|
```tsx
|
|
375
|
-
<KeyboardFocusGroup
|
|
375
|
+
<KeyboardFocusGroup
|
|
376
376
|
tintColor="orange">
|
|
377
377
|
<ScrollView
|
|
378
378
|
contentContainerStyle={styles.contentContainer}
|
|
@@ -381,7 +381,7 @@ The `KeyboardFocusGroup` is a View-based component developed based on the iOS AP
|
|
|
381
381
|
...
|
|
382
382
|
</ScrollView>
|
|
383
383
|
</KeyboardFocusGroup>
|
|
384
|
-
<KeyboardFocusGroup
|
|
384
|
+
<KeyboardFocusGroup
|
|
385
385
|
focusStyle={{ backgroundColor: 'green' }}
|
|
386
386
|
onFocusChange={(e) => console.log('green', e)}
|
|
387
387
|
groupIdentifier="green"
|
|
@@ -515,7 +515,7 @@ You can find more examples here: [Focus Order via indexes](https://github.com/Ar
|
|
|
515
515
|
|
|
516
516
|
## Focus Lock
|
|
517
517
|
|
|
518
|
-
Finally, you can lock focus to specific directions.
|
|
518
|
+
Finally, you can lock focus to specific directions.
|
|
519
519
|
|
|
520
520
|
```tsx
|
|
521
521
|
<Pressable
|
|
@@ -530,7 +530,7 @@ Finally, you can lock focus to specific directions.
|
|
|
530
530
|
| :-- | :-- | :-- |
|
|
531
531
|
| lockFocus? | An array of directions to lock focus. | Array of 'left' \| 'right' \| 'up' \| 'down' \| 'forward' \| 'backward' \| 'first' \| 'last' |
|
|
532
532
|
|
|
533
|
-
> [!NOTE]
|
|
533
|
+
> [!NOTE]
|
|
534
534
|
> `first` and `last` are specific to `iOS`. When focus is blocked for `forward` and `backward` on iOS, it checks for the `last` and `first` elements to focus.
|
|
535
535
|
|
|
536
536
|
|
|
@@ -547,7 +547,7 @@ import { KeyboardExtendedModule } from 'react-native-external-keyboard';
|
|
|
547
547
|
KeyboardExtendedModule.setKeyboardFocus(ref); //or A11yModule.setKeyboardFocus(ref);
|
|
548
548
|
```
|
|
549
549
|
|
|
550
|
-
Updated:
|
|
550
|
+
Updated:
|
|
551
551
|
```
|
|
552
552
|
import { KeyboardExtendedPressable, type KeyboardFocus } from 'react-native-external-keyboard';
|
|
553
553
|
...
|
package/package.json
CHANGED