@mittwald/flow-react-components 0.2.0-alpha.160 → 0.2.0-alpha.162

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/CHANGELOG.md CHANGED
@@ -3,6 +3,16 @@
3
3
  All notable changes to this project will be documented in this file.
4
4
  See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
5
5
 
6
+ # [0.2.0-alpha.162](https://github.com/mittwald/flow/compare/0.2.0-alpha.161...0.2.0-alpha.162) (2025-04-26)
7
+
8
+ **Note:** Version bump only for package @mittwald/flow-react-components
9
+
10
+ # [0.2.0-alpha.161](https://github.com/mittwald/flow/compare/0.2.0-alpha.160...0.2.0-alpha.161) (2025-04-25)
11
+
12
+ ### Bug Fixes
13
+
14
+ * less strict children empty check ([cff5a23](https://github.com/mittwald/flow/commit/cff5a2344048383e99f494ce43a2009c967829b2))
15
+
6
16
  # [0.2.0-alpha.160](https://github.com/mittwald/flow/compare/0.2.0-alpha.159...0.2.0-alpha.160) (2025-04-25)
7
17
 
8
18
  ### Bug Fixes
@@ -1,7 +1,5 @@
1
1
  "use client"
2
2
  /* */
3
- import React from 'react';
4
-
5
3
  const isNullish = (children) => children === null || children === void 0 || children === false;
6
4
  const areChildrenEmpty = (children) => {
7
5
  if (isNullish(children)) {
@@ -10,13 +8,7 @@ const areChildrenEmpty = (children) => {
10
8
  if (Array.isArray(children)) {
11
9
  return children.length === 0 || children.every(isNullish);
12
10
  }
13
- if (typeof children === "string" || typeof children === "number") {
14
- return false;
15
- }
16
- if (React.isValidElement(children)) {
17
- return false;
18
- }
19
- return true;
11
+ return false;
20
12
  };
21
13
 
22
14
  export { areChildrenEmpty };
@@ -1 +1 @@
1
- {"version":3,"file":"areChildrenEmpty.mjs","sources":["../../../../../../src/lib/react/areChildrenEmpty.ts"],"sourcesContent":["import React from \"react\";\n\nconst isNullish = (children: React.ReactNode) =>\n children === null || children === undefined || children === false;\n\nexport const areChildrenEmpty = (children: React.ReactNode): boolean => {\n if (isNullish(children)) {\n return true;\n }\n\n if (Array.isArray(children)) {\n return children.length === 0 || children.every(isNullish);\n }\n\n if (typeof children === \"string\" || typeof children === \"number\") {\n return false;\n }\n\n if (React.isValidElement(children)) {\n return false;\n }\n\n return true;\n};\n"],"names":[],"mappings":";;AAEA,MAAM,YAAY,CAAC,QAAA,KACjB,aAAa,IAAQ,IAAA,QAAA,KAAa,UAAa,QAAa,KAAA,KAAA;AAEjD,MAAA,gBAAA,GAAmB,CAAC,QAAuC,KAAA;AACtE,EAAI,IAAA,SAAA,CAAU,QAAQ,CAAG,EAAA;AACvB,IAAO,OAAA,IAAA;AAAA;AAGT,EAAI,IAAA,KAAA,CAAM,OAAQ,CAAA,QAAQ,CAAG,EAAA;AAC3B,IAAA,OAAO,QAAS,CAAA,MAAA,KAAW,CAAK,IAAA,QAAA,CAAS,MAAM,SAAS,CAAA;AAAA;AAG1D,EAAA,IAAI,OAAO,QAAA,KAAa,QAAY,IAAA,OAAO,aAAa,QAAU,EAAA;AAChE,IAAO,OAAA,KAAA;AAAA;AAGT,EAAI,IAAA,KAAA,CAAM,cAAe,CAAA,QAAQ,CAAG,EAAA;AAClC,IAAO,OAAA,KAAA;AAAA;AAGT,EAAO,OAAA,IAAA;AACT;;;;"}
1
+ {"version":3,"file":"areChildrenEmpty.mjs","sources":["../../../../../../src/lib/react/areChildrenEmpty.ts"],"sourcesContent":["const isNullish = (children: React.ReactNode) =>\n children === null || children === undefined || children === false;\n\nexport const areChildrenEmpty = (children: React.ReactNode): boolean => {\n if (isNullish(children)) {\n return true;\n }\n\n if (Array.isArray(children)) {\n return children.length === 0 || children.every(isNullish);\n }\n\n return false;\n};\n"],"names":[],"mappings":"AAAA,MAAM,YAAY,CAAC,QAAA,KACjB,aAAa,IAAQ,IAAA,QAAA,KAAa,UAAa,QAAa,KAAA,KAAA;AAEjD,MAAA,gBAAA,GAAmB,CAAC,QAAuC,KAAA;AACtE,EAAI,IAAA,SAAA,CAAU,QAAQ,CAAG,EAAA;AACvB,IAAO,OAAA,IAAA;AAAA;AAGT,EAAI,IAAA,KAAA,CAAM,OAAQ,CAAA,QAAQ,CAAG,EAAA;AAC3B,IAAA,OAAO,QAAS,CAAA,MAAA,KAAW,CAAK,IAAA,QAAA,CAAS,MAAM,SAAS,CAAA;AAAA;AAG1D,EAAO,OAAA,KAAA;AACT;;;;"}
@@ -1,3 +1,2 @@
1
- import { default as React } from 'react';
2
1
  export declare const areChildrenEmpty: (children: React.ReactNode) => boolean;
3
2
  //# sourceMappingURL=areChildrenEmpty.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"areChildrenEmpty.d.ts","sourceRoot":"","sources":["../../../../src/lib/react/areChildrenEmpty.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAK1B,eAAO,MAAM,gBAAgB,GAAI,UAAU,KAAK,CAAC,SAAS,KAAG,OAkB5D,CAAC"}
1
+ {"version":3,"file":"areChildrenEmpty.d.ts","sourceRoot":"","sources":["../../../../src/lib/react/areChildrenEmpty.ts"],"names":[],"mappings":"AAGA,eAAO,MAAM,gBAAgB,GAAI,UAAU,KAAK,CAAC,SAAS,KAAG,OAU5D,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@mittwald/flow-react-components",
3
- "version": "0.2.0-alpha.160",
3
+ "version": "0.2.0-alpha.162",
4
4
  "type": "module",
5
5
  "description": "A React implementation of Flow, mittwald’s design system",
6
6
  "homepage": "https://mittwald.github.io/flow",
@@ -53,7 +53,7 @@
53
53
  "dependencies": {
54
54
  "@chakra-ui/live-region": "^2.1.0",
55
55
  "@internationalized/string-compiler": "^3.2.6",
56
- "@mittwald/react-tunnel": "0.2.0-alpha.160",
56
+ "@mittwald/react-tunnel": "0.2.0-alpha.162",
57
57
  "@mittwald/react-use-promise": "^3.0.4",
58
58
  "@react-aria/form": "^3.0.14",
59
59
  "@react-aria/utils": "^3.28.1",
@@ -92,7 +92,7 @@
92
92
  "devDependencies": {
93
93
  "@faker-js/faker": "^9.6.0",
94
94
  "@internationalized/date": "^3.7.0",
95
- "@mittwald/flow-design-tokens": "0.2.0-alpha.160",
95
+ "@mittwald/flow-design-tokens": "0.2.0-alpha.162",
96
96
  "@mittwald/react-use-promise": "^2.6.0",
97
97
  "@mittwald/remote-dom-react": "1.2.2-mittwald.3",
98
98
  "@mittwald/typescript-config": "",
@@ -173,5 +173,5 @@
173
173
  "optional": true
174
174
  }
175
175
  },
176
- "gitHead": "26ace20488aa0e330d4885b769123bd9905479ae"
176
+ "gitHead": "0dd42e56678baad71cfcdc6bb127ef98b338acfb"
177
177
  }