@applicaster/zapp-react-native-utils 15.0.0-rc.139 → 15.0.0-rc.140

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.
@@ -142,6 +142,10 @@ export const isTabsScreenOnContentFocused = (node) => {
142
142
  };
143
143
 
144
144
  export const isCurrentFocusOnMenu = (node) => {
145
+ if (isNil(node)) {
146
+ return false;
147
+ }
148
+
145
149
  if (isRoot(node)) {
146
150
  return false;
147
151
  }
@@ -154,10 +158,14 @@ export const isCurrentFocusOnMenu = (node) => {
154
158
  return false;
155
159
  }
156
160
 
157
- return isCurrentFocusOnMenu(node.parent);
161
+ return isCurrentFocusOnMenu(node?.parent);
158
162
  };
159
163
 
160
164
  export const isCurrentFocusOnContent = (node) => {
165
+ if (isNil(node)) {
166
+ return false;
167
+ }
168
+
161
169
  if (isRoot(node)) {
162
170
  return false;
163
171
  }
@@ -170,7 +178,7 @@ export const isCurrentFocusOnContent = (node) => {
170
178
  return true;
171
179
  }
172
180
 
173
- return isCurrentFocusOnContent(node.parent);
181
+ return isCurrentFocusOnContent(node?.parent);
174
182
  };
175
183
 
176
184
  export const isCurrentFocusOn = (id, node) => {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@applicaster/zapp-react-native-utils",
3
- "version": "15.0.0-rc.139",
3
+ "version": "15.0.0-rc.140",
4
4
  "description": "Applicaster Zapp React Native utilities package",
5
5
  "main": "index.js",
6
6
  "types": "index.d.ts",
@@ -27,7 +27,7 @@
27
27
  },
28
28
  "homepage": "https://github.com/applicaster/quickbrick#readme",
29
29
  "dependencies": {
30
- "@applicaster/applicaster-types": "15.0.0-rc.139",
30
+ "@applicaster/applicaster-types": "15.0.0-rc.140",
31
31
  "buffer": "^5.2.1",
32
32
  "camelize": "^1.0.0",
33
33
  "dayjs": "^1.11.10",