react-native-navigation-mode 1.1.1 → 1.2.0-beta.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
CHANGED
|
@@ -167,10 +167,10 @@ console.log('Navigation bar height:', height); // number (dp)
|
|
|
167
167
|
| ------------------- | ----------------------------------------------------------- | --------------------------------------------------------- |
|
|
168
168
|
| type | `'3_button'` or `'2_button'` or `'gesture'` or `'unknown'` | 4 possible Android navigation modes that can be detected. |
|
|
169
169
|
| isGestureNavigation | `boolean` | Whether gesture navigation is active. |
|
|
170
|
-
| interactionMode | `number` or `undefined` | See [
|
|
170
|
+
| interactionMode | `number` or `undefined` | See [Interaction Mode Values](#interaction-mode-values) |
|
|
171
171
|
| navigationBarHeight | `number` or `undefined` | Navigation bar height in density-independent pixels (dp). |
|
|
172
172
|
|
|
173
|
-
###
|
|
173
|
+
### Interaction Mode Values
|
|
174
174
|
|
|
175
175
|
| Android Mode | Type | Description |
|
|
176
176
|
| ------------ | ---------- | --------------------------------------------------- |
|
package/app.plugin.js
ADDED
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
const { createRunOncePlugin } = require('@expo/config-plugins');
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* Expo Config Plugin for react-native-navigation-mode
|
|
5
|
+
* This plugin ensures the native module is properly linked in managed workflow
|
|
6
|
+
*/
|
|
7
|
+
const withNavigationMode = (config) => {
|
|
8
|
+
// No additional configuration needed for this module
|
|
9
|
+
// The module will be auto-linked through the Expo modules system
|
|
10
|
+
return config;
|
|
11
|
+
};
|
|
12
|
+
|
|
13
|
+
const pkg = require('./package.json');
|
|
14
|
+
|
|
15
|
+
module.exports = createRunOncePlugin(withNavigationMode, pkg.name, pkg.version);
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"withNavigationMode.d.ts","sourceRoot":"","sources":["../../../../plugin/src/withNavigationMode.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,YAAY,EAAE,MAAM,sBAAsB,CAAC;AAEzD,QAAA,MAAM,kBAAkB,EAAE,YAEzB,CAAC;AAEF,eAAe,kBAAkB,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,17 +1,9 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "react-native-navigation-mode",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.2.0-beta.2",
|
|
4
4
|
"description": "Detect Android navigation mode (3-button, 2-button, or gesture)",
|
|
5
5
|
"main": "./lib/module/index.js",
|
|
6
6
|
"types": "./lib/typescript/src/index.d.ts",
|
|
7
|
-
"exports": {
|
|
8
|
-
".": {
|
|
9
|
-
"source": "./src/index.tsx",
|
|
10
|
-
"types": "./lib/typescript/src/index.d.ts",
|
|
11
|
-
"default": "./lib/module/index.js"
|
|
12
|
-
},
|
|
13
|
-
"./package.json": "./package.json"
|
|
14
|
-
},
|
|
15
7
|
"files": [
|
|
16
8
|
"src",
|
|
17
9
|
"lib",
|
|
@@ -20,6 +12,9 @@
|
|
|
20
12
|
"cpp",
|
|
21
13
|
"*.podspec",
|
|
22
14
|
"react-native.config.js",
|
|
15
|
+
"expo-module.config.json",
|
|
16
|
+
"app.plugin.js",
|
|
17
|
+
"plugin/build",
|
|
23
18
|
"!ios/build",
|
|
24
19
|
"!android/build",
|
|
25
20
|
"!android/gradle",
|
|
@@ -73,6 +68,7 @@
|
|
|
73
68
|
"@eslint/eslintrc": "^3.3.0",
|
|
74
69
|
"@eslint/js": "^9.22.0",
|
|
75
70
|
"@evilmartians/lefthook": "^1.5.0",
|
|
71
|
+
"@expo/config-plugins": "^10.1.2",
|
|
76
72
|
"@react-native-community/cli": "15.0.0-alpha.2",
|
|
77
73
|
"@react-native/babel-preset": "0.79.5",
|
|
78
74
|
"@react-native/eslint-config": "0.79.5",
|
|
@@ -99,9 +95,15 @@
|
|
|
99
95
|
"typescript": "^5.8.3"
|
|
100
96
|
},
|
|
101
97
|
"peerDependencies": {
|
|
98
|
+
"expo": "*",
|
|
102
99
|
"react": "*",
|
|
103
100
|
"react-native": ">=0.77.0"
|
|
104
101
|
},
|
|
102
|
+
"peerDependenciesMeta": {
|
|
103
|
+
"expo": {
|
|
104
|
+
"optional": true
|
|
105
|
+
}
|
|
106
|
+
},
|
|
105
107
|
"workspaces": [
|
|
106
108
|
"example"
|
|
107
109
|
],
|