gt-react 2.0.197 → 2.0.198

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.
@@ -1 +1 @@
1
- {"version":3,"file":"getValueBranch.d.ts","sourceRoot":"","sources":["../../../src/primitives/value/getValueBranch.ts"],"names":[],"mappings":"AAuBA;;;;;;GAMG;AACH,MAAM,CAAC,OAAO,UAAU,cAAc,CAAC,MAAM,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,EAAE,QAAQ,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,GAAG,GAAG,CA6BtG"}
1
+ {"version":3,"file":"getValueBranch.d.ts","sourceRoot":"","sources":["../../../src/primitives/value/getValueBranch.ts"],"names":[],"mappings":"AAuBA;;;;;;GAMG;AACH,MAAM,CAAC,OAAO,UAAU,cAAc,CAAC,MAAM,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,EAAE,QAAQ,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,GAAG,GAAG,CA8BtG"}
@@ -37,14 +37,14 @@ function getValueBranch(values, branches) {
37
37
  * Handles the navigation through a given branch object.
38
38
  *
39
39
  * @param {any} branch - The current branch object to navigate.
40
- * @returns {any} - Returns the matched React node or undefined if no match is found.
40
+ * @returns {any} - Returns the matched React node or null if no match is found.
41
41
  */
42
42
  const handleBranch = (branch) => {
43
43
  var _a, _b;
44
44
  for (const key of Object.keys(branch)) {
45
45
  let value = values[key];
46
46
  if (value) {
47
- // we know branch[key] exists
47
+ // we already know branch[key] exists
48
48
  if (branch[key][value]) {
49
49
  if (typeof ((_b = (_a = branch[key][value].props) === null || _a === void 0 ? void 0 : _a['data-generaltranslation']) === null || _b === void 0 ? void 0 : _b.id) === 'number') {
50
50
  return branch[key][value];
@@ -57,6 +57,7 @@ function getValueBranch(values, branches) {
57
57
  }
58
58
  }
59
59
  }
60
+ return (branch === null || branch === void 0 ? void 0 : branch["*"]) || null;
60
61
  };
61
62
  // Start the recursive navigation from the root branches
62
63
  return handleBranch(branches);
@@ -1 +1 @@
1
- {"version":3,"file":"getValueBranch.js","sourceRoot":"","sources":["../../../src/primitives/value/getValueBranch.ts"],"names":[],"mappings":";;;;;AA8BA,iCA6BC;AA3DD,kDAA0B;AAC1B,0EAAkD;AAElD;;;;;;;;;;;;;;;;;;EAkBE;AAEF;;;;;;GAMG;AACH,SAAwB,cAAc,CAAC,MAA2B,EAAE,QAA6B;IAE7F;;;;;OAKG;IACH,MAAM,YAAY,GAAG,CAAC,MAAW,EAAO,EAAE;;QACtC,KAAK,MAAM,GAAG,IAAI,MAAM,CAAC,IAAI,CAAC,MAAM,CAAC,EAAE,CAAC;YACpC,IAAI,KAAK,GAAG,MAAM,CAAC,GAAG,CAAC,CAAC;YACxB,IAAI,KAAK,EAAE,CAAC;gBACR,6BAA6B;gBAC7B,IAAI,MAAM,CAAC,GAAG,CAAC,CAAC,KAAK,CAAC,EAAE,CAAC;oBACrB,IAAI,OAAO,CAAA,MAAA,MAAA,MAAM,CAAC,GAAG,CAAC,CAAC,KAAK,CAAC,CAAC,KAAK,0CAAG,yBAAyB,CAAC,0CAAE,EAAE,CAAA,KAAK,QAAQ,EAAE,CAAC;wBAChF,OAAO,MAAM,CAAC,GAAG,CAAC,CAAC,KAAK,CAAC,CAAC;oBAC9B,CAAC;oBACD,oEAAoE;oBACpE,IAAI,IAAA,0BAAgB,EAAC,MAAM,CAAC,GAAG,CAAC,CAAC,KAAK,CAAC,CAAC,IAAI,MAAM,CAAC,GAAG,CAAC,CAAC,KAAK,CAAC,CAAC,QAAQ,KAAK,eAAK,CAAC,IAAI,CAAC,GAAG,EAAE,GAAE,CAAC,CAAC,CAAC,QAAQ,EAAE,CAAC;wBACxG,OAAO,MAAM,CAAC,GAAG,CAAC,CAAC,KAAK,CAAC,CAAC;oBAC9B,CAAC;oBACD,OAAO,YAAY,CAAC,MAAM,CAAC,GAAG,CAAC,CAAC,KAAK,CAAC,CAAC,CAAA;g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Y,CAAC,MAAM,CAAC,GAAG,CAAC,CAAC,KAAK,CAAC,CAAC,CAAA;gBAC3C,CAAC;YACL,CAAC;QACL,CAAC;QACD,OAAO,CAAA,MAAM,aAAN,MAAM,uBAAN,MAAM,CAAG,GAAG,CAAC,KAAI,IAAI,CAAC;IACjC,CAAC,CAAA;IAED,wDAAwD;IACxD,OAAO,YAAY,CAAC,QAAQ,CAAC,CAAC;AAClC,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "gt-react",
3
- "version": "2.0.197",
3
+ "version": "2.0.198",
4
4
  "description": "",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",