@bitrise/bitkit 10.23.0 → 10.23.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/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@bitrise/bitkit",
3
3
  "description": "Bitrise React component library",
4
- "version": "10.23.0",
4
+ "version": "10.23.1",
5
5
  "repository": "git@github.com:bitrise-io/bitkit.git",
6
6
  "main": "src/index.ts",
7
7
  "license": "UNLICENSED",
@@ -70,7 +70,7 @@
70
70
  "@types/enzyme": "^3.10.12",
71
71
  "@types/jest": "^28.1.6",
72
72
  "@types/luxon": "^2.4.0",
73
- "@types/react": "18.0.15",
73
+ "@types/react": "18.0.18",
74
74
  "@types/react-dom": "^18.0.6",
75
75
  "@types/vfile-message": "^2.0.0",
76
76
  "@typescript-eslint/eslint-plugin": "^5.30.7",
@@ -104,7 +104,7 @@
104
104
  "ts-jest": "^28.0.7",
105
105
  "ts-node": "^10.9.1",
106
106
  "tsconfig-paths-webpack-plugin": "^3.5.2",
107
- "typescript": "^4.7.4",
107
+ "typescript": "^4.8.2",
108
108
  "webpack": "^5.73.0"
109
109
  },
110
110
  "files": [
@@ -15,12 +15,12 @@ function isNodeMatch(node: ReactNode, filter: string): boolean {
15
15
  return node.toLowerCase().includes(filter.toLowerCase());
16
16
  }
17
17
  if (Array.isArray(node)) {
18
- return node.some((child) => isNodeMatch(child, filter));
18
+ return Array.from(node).some((child) => isNodeMatch(child, filter));
19
19
  }
20
20
  if ('children' in node) {
21
21
  return isNodeMatch(node.children, filter);
22
22
  }
23
- if (React.isValidElement(node)) {
23
+ if (React.isValidElement<any>(node)) {
24
24
  if (node.type === 'svg') {
25
25
  return false;
26
26
  }
@@ -30,10 +30,7 @@ function isNodeMatch(node: ReactNode, filter: string): boolean {
30
30
  }
31
31
  return isNodeMatch(node.props.children, filter);
32
32
  }
33
- if (Symbol.iterator in node) {
34
- return isNodeMatch(Array.from(node), filter);
35
- }
36
- return false;
33
+ return isNodeMatch(Array.from(node), filter);
37
34
  }
38
35
 
39
36
  export default isNodeMatch;