@stryke/helpers 0.10.21 → 0.10.23

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.
Files changed (196) hide show
  1. package/CHANGELOG.md +28 -0
  2. package/dist/arg-identity.cjs +1 -9
  3. package/dist/arg-identity.mjs +1 -4
  4. package/dist/arg-identity.mjs.map +1 -1
  5. package/dist/deep-clone.cjs +1 -9
  6. package/dist/deep-clone.mjs +1 -3
  7. package/dist/deep-clone.mjs.map +1 -1
  8. package/dist/deep-merge.cjs +1 -9
  9. package/dist/deep-merge.mjs +1 -3
  10. package/dist/deep-merge.mjs.map +1 -1
  11. package/dist/filter-empty.cjs +1 -9
  12. package/dist/filter-empty.mjs +1 -3
  13. package/dist/filter-empty.mjs.map +1 -1
  14. package/dist/flatten-object.cjs +1 -9
  15. package/dist/flatten-object.mjs +1 -3
  16. package/dist/flatten-object.mjs.map +1 -1
  17. package/dist/get-field.cjs +1 -9
  18. package/dist/get-field.mjs +1 -3
  19. package/dist/get-field.mjs.map +1 -1
  20. package/dist/get-ordered-by.cjs +1 -9
  21. package/dist/get-ordered-by.mjs +1 -4
  22. package/dist/get-ordered-by.mjs.map +1 -1
  23. package/dist/get-unique.cjs +1 -12
  24. package/dist/get-unique.mjs +1 -7
  25. package/dist/get-unique.mjs.map +1 -1
  26. package/dist/identity.cjs +1 -9
  27. package/dist/identity.mjs +1 -4
  28. package/dist/identity.mjs.map +1 -1
  29. package/dist/index.cjs +0 -41
  30. package/dist/index.mjs +1 -37
  31. package/dist/is-equal.cjs +1 -9
  32. package/dist/is-equal.mjs +1 -3
  33. package/dist/is-equal.mjs.map +1 -1
  34. package/dist/lru-cache.cjs +1 -9
  35. package/dist/lru-cache.mjs +1 -4
  36. package/dist/lru-cache.mjs.map +1 -1
  37. package/dist/match-sorter.cjs +0 -12
  38. package/dist/match-sorter.mjs +1 -7
  39. package/dist/match-sorter.mjs.map +1 -1
  40. package/dist/memoize.cjs +1 -9
  41. package/dist/memoize.mjs +1 -4
  42. package/dist/memoize.mjs.map +1 -1
  43. package/dist/noop.cjs +1 -12
  44. package/dist/noop.mjs +1 -7
  45. package/dist/noop.mjs.map +1 -1
  46. package/dist/omit.cjs +1 -9
  47. package/dist/omit.mjs +1 -4
  48. package/dist/omit.mjs.map +1 -1
  49. package/dist/pick.cjs +1 -9
  50. package/dist/pick.mjs +1 -4
  51. package/dist/pick.mjs.map +1 -1
  52. package/dist/remove-accents.cjs +1 -12
  53. package/dist/remove-accents.mjs +1 -7
  54. package/dist/remove-accents.mjs.map +1 -1
  55. package/dist/remove-empty-items.cjs +1 -9
  56. package/dist/remove-empty-items.mjs +1 -4
  57. package/dist/remove-empty-items.mjs.map +1 -1
  58. package/dist/set-field.cjs +1 -9
  59. package/dist/set-field.mjs +1 -3
  60. package/dist/set-field.mjs.map +1 -1
  61. package/dist/to-deep-key.cjs +1 -12
  62. package/dist/to-deep-key.mjs +1 -6
  63. package/dist/to-deep-key.mjs.map +1 -1
  64. package/dist/to-path.cjs +1 -9
  65. package/dist/to-path.mjs +1 -4
  66. package/dist/to-path.mjs.map +1 -1
  67. package/dist/unflatten-object.cjs +1 -9
  68. package/dist/unflatten-object.mjs +1 -3
  69. package/dist/unflatten-object.mjs.map +1 -1
  70. package/dist/union.cjs +1 -9
  71. package/dist/union.mjs +1 -3
  72. package/dist/union.mjs.map +1 -1
  73. package/package.json +5 -101
  74. package/dist/_virtual/_rolldown/runtime.cjs +0 -19
  75. package/dist/_virtual/_rolldown/runtime.mjs +0 -18
  76. package/dist/arg-identity.test.cjs +0 -12
  77. package/dist/arg-identity.test.d.cts +0 -1
  78. package/dist/arg-identity.test.d.mts +0 -1
  79. package/dist/arg-identity.test.mjs +0 -14
  80. package/dist/arg-identity.test.mjs.map +0 -1
  81. package/dist/deep-clone.test.cjs +0 -12
  82. package/dist/deep-clone.test.d.cts +0 -1
  83. package/dist/deep-clone.test.d.mts +0 -1
  84. package/dist/deep-clone.test.mjs +0 -14
  85. package/dist/deep-clone.test.mjs.map +0 -1
  86. package/dist/deep-merge.test.cjs +0 -12
  87. package/dist/deep-merge.test.d.cts +0 -1
  88. package/dist/deep-merge.test.d.mts +0 -1
  89. package/dist/deep-merge.test.mjs +0 -14
  90. package/dist/deep-merge.test.mjs.map +0 -1
  91. package/dist/filter-empty.test.cjs +0 -12
  92. package/dist/filter-empty.test.d.cts +0 -1
  93. package/dist/filter-empty.test.d.mts +0 -1
  94. package/dist/filter-empty.test.mjs +0 -14
  95. package/dist/filter-empty.test.mjs.map +0 -1
  96. package/dist/flatten-object.test.cjs +0 -12
  97. package/dist/flatten-object.test.d.cts +0 -1
  98. package/dist/flatten-object.test.d.mts +0 -1
  99. package/dist/flatten-object.test.mjs +0 -14
  100. package/dist/flatten-object.test.mjs.map +0 -1
  101. package/dist/get-field.test.cjs +0 -12
  102. package/dist/get-field.test.d.cts +0 -1
  103. package/dist/get-field.test.d.mts +0 -1
  104. package/dist/get-field.test.mjs +0 -14
  105. package/dist/get-field.test.mjs.map +0 -1
  106. package/dist/get-ordered-by.test.cjs +0 -12
  107. package/dist/get-ordered-by.test.d.cts +0 -1
  108. package/dist/get-ordered-by.test.d.mts +0 -1
  109. package/dist/get-ordered-by.test.mjs +0 -14
  110. package/dist/get-ordered-by.test.mjs.map +0 -1
  111. package/dist/get-unique.test.cjs +0 -12
  112. package/dist/get-unique.test.d.cts +0 -1
  113. package/dist/get-unique.test.d.mts +0 -1
  114. package/dist/get-unique.test.mjs +0 -14
  115. package/dist/get-unique.test.mjs.map +0 -1
  116. package/dist/identity.test.cjs +0 -12
  117. package/dist/identity.test.d.cts +0 -1
  118. package/dist/identity.test.d.mts +0 -1
  119. package/dist/identity.test.mjs +0 -14
  120. package/dist/identity.test.mjs.map +0 -1
  121. package/dist/index.mjs.map +0 -1
  122. package/dist/index.test.cjs +0 -12
  123. package/dist/index.test.d.cts +0 -1
  124. package/dist/index.test.d.mts +0 -1
  125. package/dist/index.test.mjs +0 -14
  126. package/dist/index.test.mjs.map +0 -1
  127. package/dist/is-equal.test.cjs +0 -12
  128. package/dist/is-equal.test.d.cts +0 -1
  129. package/dist/is-equal.test.d.mts +0 -1
  130. package/dist/is-equal.test.mjs +0 -14
  131. package/dist/is-equal.test.mjs.map +0 -1
  132. package/dist/lru-cache.test.cjs +0 -12
  133. package/dist/lru-cache.test.d.cts +0 -1
  134. package/dist/lru-cache.test.d.mts +0 -1
  135. package/dist/lru-cache.test.mjs +0 -14
  136. package/dist/lru-cache.test.mjs.map +0 -1
  137. package/dist/match-sorter.test.cjs +0 -12
  138. package/dist/match-sorter.test.d.cts +0 -1
  139. package/dist/match-sorter.test.d.mts +0 -1
  140. package/dist/match-sorter.test.mjs +0 -14
  141. package/dist/match-sorter.test.mjs.map +0 -1
  142. package/dist/memoize.test.cjs +0 -12
  143. package/dist/memoize.test.d.cts +0 -1
  144. package/dist/memoize.test.d.mts +0 -1
  145. package/dist/memoize.test.mjs +0 -14
  146. package/dist/memoize.test.mjs.map +0 -1
  147. package/dist/noop.test.cjs +0 -12
  148. package/dist/noop.test.d.cts +0 -1
  149. package/dist/noop.test.d.mts +0 -1
  150. package/dist/noop.test.mjs +0 -14
  151. package/dist/noop.test.mjs.map +0 -1
  152. package/dist/omit.test.cjs +0 -12
  153. package/dist/omit.test.d.cts +0 -1
  154. package/dist/omit.test.d.mts +0 -1
  155. package/dist/omit.test.mjs +0 -14
  156. package/dist/omit.test.mjs.map +0 -1
  157. package/dist/pick.test.cjs +0 -12
  158. package/dist/pick.test.d.cts +0 -1
  159. package/dist/pick.test.d.mts +0 -1
  160. package/dist/pick.test.mjs +0 -14
  161. package/dist/pick.test.mjs.map +0 -1
  162. package/dist/remove-accents.test.cjs +0 -12
  163. package/dist/remove-accents.test.d.cts +0 -1
  164. package/dist/remove-accents.test.d.mts +0 -1
  165. package/dist/remove-accents.test.mjs +0 -14
  166. package/dist/remove-accents.test.mjs.map +0 -1
  167. package/dist/remove-empty-items.test.cjs +0 -12
  168. package/dist/remove-empty-items.test.d.cts +0 -1
  169. package/dist/remove-empty-items.test.d.mts +0 -1
  170. package/dist/remove-empty-items.test.mjs +0 -14
  171. package/dist/remove-empty-items.test.mjs.map +0 -1
  172. package/dist/set-field.test.cjs +0 -12
  173. package/dist/set-field.test.d.cts +0 -1
  174. package/dist/set-field.test.d.mts +0 -1
  175. package/dist/set-field.test.mjs +0 -14
  176. package/dist/set-field.test.mjs.map +0 -1
  177. package/dist/to-deep-key.test.cjs +0 -12
  178. package/dist/to-deep-key.test.d.cts +0 -1
  179. package/dist/to-deep-key.test.d.mts +0 -1
  180. package/dist/to-deep-key.test.mjs +0 -14
  181. package/dist/to-deep-key.test.mjs.map +0 -1
  182. package/dist/to-path.test.cjs +0 -12
  183. package/dist/to-path.test.d.cts +0 -1
  184. package/dist/to-path.test.d.mts +0 -1
  185. package/dist/to-path.test.mjs +0 -14
  186. package/dist/to-path.test.mjs.map +0 -1
  187. package/dist/unflatten-object.test.cjs +0 -12
  188. package/dist/unflatten-object.test.d.cts +0 -1
  189. package/dist/unflatten-object.test.d.mts +0 -1
  190. package/dist/unflatten-object.test.mjs +0 -14
  191. package/dist/unflatten-object.test.mjs.map +0 -1
  192. package/dist/union.test.cjs +0 -12
  193. package/dist/union.test.d.cts +0 -1
  194. package/dist/union.test.d.mts +0 -1
  195. package/dist/union.test.mjs +0 -14
  196. package/dist/union.test.mjs.map +0 -1
package/dist/pick.mjs CHANGED
@@ -1,7 +1,4 @@
1
- import { __exportAll } from "./_virtual/_rolldown/runtime.mjs";
2
-
3
1
  //#region src/pick.ts
4
- var pick_exports = /* @__PURE__ */ __exportAll({ pick: () => pick });
5
2
  /**
6
3
  * Creates a new object composed of the picked object properties.
7
4
  *
@@ -29,5 +26,5 @@ function pick(obj, keys) {
29
26
  }
30
27
 
31
28
  //#endregion
32
- export { pick, pick_exports };
29
+ export { pick };
33
30
  //# sourceMappingURL=pick.mjs.map
package/dist/pick.mjs.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"pick.mjs","names":[],"sources":["../src/pick.ts"],"sourcesContent":["/* -------------------------------------------------------------------\n\n ⚡ Storm Software - Stryke\n\n This code was released as part of the Stryke project. Stryke\n is maintained by Storm Software under the Apache-2.0 license, and is\n free for commercial and private use. For more information, please visit\n our licensing page at https://stormsoftware.com/licenses/projects/stryke.\n\n Website: https://stormsoftware.com\n Repository: https://github.com/storm-software/stryke\n Documentation: https://docs.stormsoftware.com/projects/stryke\n Contact: https://stormsoftware.com/contact\n\n SPDX-License-Identifier: Apache-2.0\n\n ------------------------------------------------------------------- */\n\n/**\n * Creates a new object composed of the picked object properties.\n *\n * This function takes an object and an array of keys, and returns a new object that\n * includes only the properties corresponding to the specified keys.\n *\n * @param obj - The object to pick keys from.\n * @param keys - An array of keys to be picked from the object.\n * @returns A new object with the specified keys picked.\n *\n * @example\n * ```typescript\n * const obj = { a: 1, b: 2, c: 3 };\n * const result = pick(obj, ['a', 'c']);\n * // result will be { a: 1, c: 3 }\n * ```\n */\nexport function pick<T extends Record<string, any>, K extends keyof T>(\n obj: T,\n keys: readonly K[]\n): Pick<T, K> {\n const result = {} as Pick<T, K>;\n\n for (let i = 0; i < keys.length; i++) {\n const key = keys[i];\n\n if (key && Object.hasOwn(obj, key)) {\n result[key] = obj[key];\n }\n }\n\n return result;\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;AAmCA,SAAgB,KACd,KACA,MACY;CACZ,MAAM,SAAS,EAAE;AAEjB,MAAK,IAAI,IAAI,GAAG,IAAI,KAAK,QAAQ,KAAK;EACpC,MAAM,MAAM,KAAK;AAEjB,MAAI,OAAO,OAAO,OAAO,KAAK,IAAI,CAChC,QAAO,OAAO,IAAI;;AAItB,QAAO"}
1
+ {"version":3,"file":"pick.mjs","names":[],"sources":["../src/pick.ts"],"sourcesContent":["/* -------------------------------------------------------------------\n\n ⚡ Storm Software - Stryke\n\n This code was released as part of the Stryke project. Stryke\n is maintained by Storm Software under the Apache-2.0 license, and is\n free for commercial and private use. For more information, please visit\n our licensing page at https://stormsoftware.com/licenses/projects/stryke.\n\n Website: https://stormsoftware.com\n Repository: https://github.com/storm-software/stryke\n Documentation: https://docs.stormsoftware.com/projects/stryke\n Contact: https://stormsoftware.com/contact\n\n SPDX-License-Identifier: Apache-2.0\n\n ------------------------------------------------------------------- */\n\n/**\n * Creates a new object composed of the picked object properties.\n *\n * This function takes an object and an array of keys, and returns a new object that\n * includes only the properties corresponding to the specified keys.\n *\n * @param obj - The object to pick keys from.\n * @param keys - An array of keys to be picked from the object.\n * @returns A new object with the specified keys picked.\n *\n * @example\n * ```typescript\n * const obj = { a: 1, b: 2, c: 3 };\n * const result = pick(obj, ['a', 'c']);\n * // result will be { a: 1, c: 3 }\n * ```\n */\nexport function pick<T extends Record<string, any>, K extends keyof T>(\n obj: T,\n keys: readonly K[]\n): Pick<T, K> {\n const result = {} as Pick<T, K>;\n\n for (let i = 0; i < keys.length; i++) {\n const key = keys[i];\n\n if (key && Object.hasOwn(obj, key)) {\n result[key] = obj[key];\n }\n }\n\n return result;\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;AAmCA,SAAgB,KACd,KACA,MACY;CACZ,MAAM,SAAS,EAAE;AAEjB,MAAK,IAAI,IAAI,GAAG,IAAI,KAAK,QAAQ,KAAK;EACpC,MAAM,MAAM,KAAK;AAEjB,MAAI,OAAO,OAAO,OAAO,KAAK,IAAI,CAChC,QAAO,OAAO,IAAI;;AAItB,QAAO"}
@@ -1,11 +1,6 @@
1
1
  Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
2
- const require_runtime = require('./_virtual/_rolldown/runtime.cjs');
3
2
 
4
3
  //#region src/remove-accents.ts
5
- var remove_accents_exports = /* @__PURE__ */ require_runtime.__exportAll({
6
- characterMap: () => characterMap,
7
- removeAccents: () => removeAccents
8
- });
9
4
  const characterMap = {
10
5
  À: "A",
11
6
  Á: "A",
@@ -417,10 +412,4 @@ const removeAccents = (str) => str.replace(new RegExp(Object.keys(characterMap).
417
412
 
418
413
  //#endregion
419
414
  exports.characterMap = characterMap;
420
- exports.removeAccents = removeAccents;
421
- Object.defineProperty(exports, 'remove_accents_exports', {
422
- enumerable: true,
423
- get: function () {
424
- return remove_accents_exports;
425
- }
426
- });
415
+ exports.removeAccents = removeAccents;
@@ -1,10 +1,4 @@
1
- import { __exportAll } from "./_virtual/_rolldown/runtime.mjs";
2
-
3
1
  //#region src/remove-accents.ts
4
- var remove_accents_exports = /* @__PURE__ */ __exportAll({
5
- characterMap: () => characterMap,
6
- removeAccents: () => removeAccents
7
- });
8
2
  const characterMap = {
9
3
  À: "A",
10
4
  Á: "A",
@@ -415,5 +409,5 @@ const characterMap = {
415
409
  const removeAccents = (str) => str.replace(new RegExp(Object.keys(characterMap).join("|"), "g"), (match) => characterMap[match]);
416
410
 
417
411
  //#endregion
418
- export { characterMap, removeAccents, remove_accents_exports };
412
+ export { characterMap, removeAccents };
419
413
  //# sourceMappingURL=remove-accents.mjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"remove-accents.mjs","names":[],"sources":["../src/remove-accents.ts"],"sourcesContent":["/* -------------------------------------------------------------------\n\n ⚡ Storm Software - Stryke\n\n This code was released as part of the Stryke project. Stryke\n is maintained by Storm Software under the Apache-2.0 license, and is\n free for commercial and private use. For more information, please visit\n our licensing page at https://stormsoftware.com/licenses/projects/stryke.\n\n Website: https://stormsoftware.com\n Repository: https://github.com/storm-software/stryke\n Documentation: https://docs.stormsoftware.com/projects/stryke\n Contact: https://stormsoftware.com/contact\n\n SPDX-License-Identifier: Apache-2.0\n\n ------------------------------------------------------------------- */\n\nexport const characterMap: Record<string, string> = {\n À: \"A\",\n Á: \"A\",\n Â: \"A\",\n Ã: \"A\",\n Ä: \"A\",\n Å: \"A\",\n Ấ: \"A\",\n Ắ: \"A\",\n Ẳ: \"A\",\n Ẵ: \"A\",\n Ặ: \"A\",\n Æ: \"AE\",\n Ầ: \"A\",\n Ằ: \"A\",\n Ȃ: \"A\",\n Ç: \"C\",\n Ḉ: \"C\",\n È: \"E\",\n É: \"E\",\n Ê: \"E\",\n Ë: \"E\",\n Ế: \"E\",\n Ḗ: \"E\",\n Ề: \"E\",\n Ḕ: \"E\",\n Ḝ: \"E\",\n Ȇ: \"E\",\n Ì: \"I\",\n Í: \"I\",\n Î: \"I\",\n Ï: \"I\",\n Ḯ: \"I\",\n Ȋ: \"I\",\n Ð: \"D\",\n Ñ: \"N\",\n Ò: \"O\",\n Ó: \"O\",\n Ô: \"O\",\n Õ: \"O\",\n Ö: \"O\",\n Ø: \"O\",\n Ố: \"O\",\n Ṍ: \"O\",\n Ṓ: \"O\",\n Ȏ: \"O\",\n Ù: \"U\",\n Ú: \"U\",\n Û: \"U\",\n Ü: \"U\",\n Ý: \"Y\",\n à: \"a\",\n á: \"a\",\n â: \"a\",\n ã: \"a\",\n ä: \"a\",\n å: \"a\",\n ấ: \"a\",\n ắ: \"a\",\n ẳ: \"a\",\n ẵ: \"a\",\n ặ: \"a\",\n æ: \"ae\",\n ầ: \"a\",\n ằ: \"a\",\n ȃ: \"a\",\n ç: \"c\",\n ḉ: \"c\",\n è: \"e\",\n é: \"e\",\n ê: \"e\",\n ë: \"e\",\n ế: \"e\",\n ḗ: \"e\",\n ề: \"e\",\n ḕ: \"e\",\n ḝ: \"e\",\n ȇ: \"e\",\n ì: \"i\",\n í: \"i\",\n î: \"i\",\n ï: \"i\",\n ḯ: \"i\",\n ȋ: \"i\",\n ð: \"d\",\n ñ: \"n\",\n ò: \"o\",\n ó: \"o\",\n ô: \"o\",\n õ: \"o\",\n ö: \"o\",\n ø: \"o\",\n ố: \"o\",\n ṍ: \"o\",\n ṓ: \"o\",\n ȏ: \"o\",\n ù: \"u\",\n ú: \"u\",\n û: \"u\",\n ü: \"u\",\n ý: \"y\",\n ÿ: \"y\",\n Ā: \"A\",\n ā: \"a\",\n Ă: \"A\",\n ă: \"a\",\n Ą: \"A\",\n ą: \"a\",\n Ć: \"C\",\n ć: \"c\",\n Ĉ: \"C\",\n ĉ: \"c\",\n Ċ: \"C\",\n ċ: \"c\",\n Č: \"C\",\n č: \"c\",\n C̆: \"C\",\n c̆: \"c\",\n Ď: \"D\",\n ď: \"d\",\n Đ: \"D\",\n đ: \"d\",\n Ē: \"E\",\n ē: \"e\",\n Ĕ: \"E\",\n ĕ: \"e\",\n Ė: \"E\",\n ė: \"e\",\n Ę: \"E\",\n ę: \"e\",\n Ě: \"E\",\n ě: \"e\",\n Ĝ: \"G\",\n Ǵ: \"G\",\n ĝ: \"g\",\n ǵ: \"g\",\n Ğ: \"G\",\n ğ: \"g\",\n Ġ: \"G\",\n ġ: \"g\",\n Ģ: \"G\",\n ģ: \"g\",\n Ĥ: \"H\",\n ĥ: \"h\",\n Ħ: \"H\",\n ħ: \"h\",\n Ḫ: \"H\",\n ḫ: \"h\",\n Ĩ: \"I\",\n ĩ: \"i\",\n Ī: \"I\",\n ī: \"i\",\n Ĭ: \"I\",\n ĭ: \"i\",\n Į: \"I\",\n į: \"i\",\n İ: \"I\",\n ı: \"i\",\n IJ: \"IJ\",\n ij: \"ij\",\n Ĵ: \"J\",\n ĵ: \"j\",\n Ķ: \"K\",\n ķ: \"k\",\n Ḱ: \"K\",\n ḱ: \"k\",\n K̆: \"K\",\n k̆: \"k\",\n Ĺ: \"L\",\n ĺ: \"l\",\n Ļ: \"L\",\n ļ: \"l\",\n Ľ: \"L\",\n ľ: \"l\",\n Ŀ: \"L\",\n ŀ: \"l\",\n Ł: \"l\",\n ł: \"l\",\n Ḿ: \"M\",\n ḿ: \"m\",\n M̆: \"M\",\n m̆: \"m\",\n Ń: \"N\",\n ń: \"n\",\n Ņ: \"N\",\n ņ: \"n\",\n Ň: \"N\",\n ň: \"n\",\n ʼn: \"n\",\n N̆: \"N\",\n n̆: \"n\",\n Ō: \"O\",\n ō: \"o\",\n Ŏ: \"O\",\n ŏ: \"o\",\n Ő: \"O\",\n ő: \"o\",\n Œ: \"OE\",\n œ: \"oe\",\n P̆: \"P\",\n p̆: \"p\",\n Ŕ: \"R\",\n ŕ: \"r\",\n Ŗ: \"R\",\n ŗ: \"r\",\n Ř: \"R\",\n ř: \"r\",\n R̆: \"R\",\n r̆: \"r\",\n Ȓ: \"R\",\n ȓ: \"r\",\n Ś: \"S\",\n ś: \"s\",\n Ŝ: \"S\",\n ŝ: \"s\",\n Ş: \"S\",\n Ș: \"S\",\n ș: \"s\",\n ş: \"s\",\n Š: \"S\",\n š: \"s\",\n Ţ: \"T\",\n ţ: \"t\",\n ț: \"t\",\n Ț: \"T\",\n Ť: \"T\",\n ť: \"t\",\n Ŧ: \"T\",\n ŧ: \"t\",\n T̆: \"T\",\n t̆: \"t\",\n Ũ: \"U\",\n ũ: \"u\",\n Ū: \"U\",\n ū: \"u\",\n Ŭ: \"U\",\n ŭ: \"u\",\n Ů: \"U\",\n ů: \"u\",\n Ű: \"U\",\n ű: \"u\",\n Ų: \"U\",\n ų: \"u\",\n Ȗ: \"U\",\n ȗ: \"u\",\n V̆: \"V\",\n v̆: \"v\",\n Ŵ: \"W\",\n ŵ: \"w\",\n Ẃ: \"W\",\n ẃ: \"w\",\n X̆: \"X\",\n x̆: \"x\",\n Ŷ: \"Y\",\n ŷ: \"y\",\n Ÿ: \"Y\",\n Y̆: \"Y\",\n y̆: \"y\",\n Ź: \"Z\",\n ź: \"z\",\n Ż: \"Z\",\n ż: \"z\",\n Ž: \"Z\",\n ž: \"z\",\n ſ: \"s\",\n ƒ: \"f\",\n Ơ: \"O\",\n ơ: \"o\",\n Ư: \"U\",\n ư: \"u\",\n Ǎ: \"A\",\n ǎ: \"a\",\n Ǐ: \"I\",\n ǐ: \"i\",\n Ǒ: \"O\",\n ǒ: \"o\",\n Ǔ: \"U\",\n ǔ: \"u\",\n Ǖ: \"U\",\n ǖ: \"u\",\n Ǘ: \"U\",\n ǘ: \"u\",\n Ǚ: \"U\",\n ǚ: \"u\",\n Ǜ: \"U\",\n ǜ: \"u\",\n Ứ: \"U\",\n ứ: \"u\",\n Ṹ: \"U\",\n ṹ: \"u\",\n Ǻ: \"A\",\n ǻ: \"a\",\n Ǽ: \"AE\",\n ǽ: \"ae\",\n Ǿ: \"O\",\n ǿ: \"o\",\n Þ: \"TH\",\n þ: \"th\",\n Ṕ: \"P\",\n ṕ: \"p\",\n Ṥ: \"S\",\n ṥ: \"s\",\n X́: \"X\",\n x́: \"x\",\n Ѓ: \"Г\",\n ѓ: \"г\",\n Ќ: \"К\",\n ќ: \"к\",\n A̋: \"A\",\n a̋: \"a\",\n E̋: \"E\",\n e̋: \"e\",\n I̋: \"I\",\n i̋: \"i\",\n Ǹ: \"N\",\n ǹ: \"n\",\n Ồ: \"O\",\n ồ: \"o\",\n Ṑ: \"O\",\n ṑ: \"o\",\n Ừ: \"U\",\n ừ: \"u\",\n Ẁ: \"W\",\n ẁ: \"w\",\n Ỳ: \"Y\",\n ỳ: \"y\",\n Ȁ: \"A\",\n ȁ: \"a\",\n Ȅ: \"E\",\n ȅ: \"e\",\n Ȉ: \"I\",\n ȉ: \"i\",\n Ȍ: \"O\",\n ȍ: \"o\",\n Ȑ: \"R\",\n ȑ: \"r\",\n Ȕ: \"U\",\n ȕ: \"u\",\n B̌: \"B\",\n b̌: \"b\",\n Č̣: \"C\",\n č̣: \"c\",\n Ê̌: \"E\",\n ê̌: \"e\",\n F̌: \"F\",\n f̌: \"f\",\n Ǧ: \"G\",\n ǧ: \"g\",\n Ȟ: \"H\",\n ȟ: \"h\",\n J̌: \"J\",\n ǰ: \"j\",\n Ǩ: \"K\",\n ǩ: \"k\",\n M̌: \"M\",\n m̌: \"m\",\n P̌: \"P\",\n p̌: \"p\",\n Q̌: \"Q\",\n q̌: \"q\",\n Ř̩: \"R\",\n ř̩: \"r\",\n Ṧ: \"S\",\n ṧ: \"s\",\n V̌: \"V\",\n v̌: \"v\",\n W̌: \"W\",\n w̌: \"w\",\n X̌: \"X\",\n x̌: \"x\",\n Y̌: \"Y\",\n y̌: \"y\",\n A̧: \"A\",\n a̧: \"a\",\n B̧: \"B\",\n b̧: \"b\",\n Ḑ: \"D\",\n ḑ: \"d\",\n Ȩ: \"E\",\n ȩ: \"e\",\n Ɛ̧: \"E\",\n ɛ̧: \"e\",\n Ḩ: \"H\",\n ḩ: \"h\",\n I̧: \"I\",\n i̧: \"i\",\n Ɨ̧: \"I\",\n ɨ̧: \"i\",\n M̧: \"M\",\n m̧: \"m\",\n O̧: \"O\",\n o̧: \"o\",\n Q̧: \"Q\",\n q̧: \"q\",\n U̧: \"U\",\n u̧: \"u\",\n X̧: \"X\",\n x̧: \"x\",\n Z̧: \"Z\",\n z̧: \"z\"\n};\n\n/**\n * Removes accents from a string.\n *\n * @param str - The string to remove accents from\n * @returns The string without accents\n */\nexport const removeAccents = (str: string) =>\n str.replace(\n // eslint-disable-next-line regexp/no-dupe-disjunctions, regexp/prefer-character-class\n new RegExp(Object.keys(characterMap).join(\"|\"), \"g\"),\n match => characterMap[match]!\n );\n"],"mappings":";;;;;;;AAkBA,MAAa,eAAuC;CAClD,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,IAAI;CACJ,IAAI;CACJ,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,IAAI;CACJ,IAAI;CACJ,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,IAAI;CACJ,IAAI;CACJ,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,IAAI;CACJ,IAAI;CACJ,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,IAAI;CACJ,IAAI;CACJ,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,IAAI;CACJ,IAAI;CACJ,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,IAAI;CACJ,IAAI;CACJ,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,IAAI;CACJ,IAAI;CACJ,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,IAAI;CACJ,IAAI;CACJ,GAAG;CACH,GAAG;CACH,GAAG;CACH,IAAI;CACJ,IAAI;CACJ,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,IAAI;CACJ,IAAI;CACJ,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,IAAI;CACJ,IAAI;CACJ,IAAI;CACJ,IAAI;CACJ,IAAI;CACJ,IAAI;CACJ,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,IAAI;CACJ,IAAI;CACJ,IAAI;CACJ,IAAI;CACJ,IAAI;CACJ,IAAI;CACJ,IAAI;CACJ,IAAI;CACJ,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,IAAI;CACJ,GAAG;CACH,GAAG;CACH,GAAG;CACH,IAAI;CACJ,IAAI;CACJ,IAAI;CACJ,IAAI;CACJ,IAAI;CACJ,IAAI;CACJ,IAAI;CACJ,IAAI;CACJ,GAAG;CACH,GAAG;CACH,IAAI;CACJ,IAAI;CACJ,IAAI;CACJ,IAAI;CACJ,IAAI;CACJ,IAAI;CACJ,IAAI;CACJ,IAAI;CACJ,IAAI;CACJ,IAAI;CACJ,IAAI;CACJ,IAAI;CACJ,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,IAAI;CACJ,IAAI;CACJ,GAAG;CACH,GAAG;CACH,IAAI;CACJ,IAAI;CACJ,IAAI;CACJ,IAAI;CACJ,IAAI;CACJ,IAAI;CACJ,IAAI;CACJ,IAAI;CACJ,IAAI;CACJ,IAAI;CACJ,IAAI;CACJ,IAAI;CACJ,IAAI;CACJ,IAAI;CACJ,IAAI;CACJ,IAAI;CACL;;;;;;;AAQD,MAAa,iBAAiB,QAC5B,IAAI,QAEF,IAAI,OAAO,OAAO,KAAK,aAAa,CAAC,KAAK,IAAI,EAAE,IAAI,GACpD,UAAS,aAAa,OACvB"}
1
+ {"version":3,"file":"remove-accents.mjs","names":[],"sources":["../src/remove-accents.ts"],"sourcesContent":["/* -------------------------------------------------------------------\n\n ⚡ Storm Software - Stryke\n\n This code was released as part of the Stryke project. Stryke\n is maintained by Storm Software under the Apache-2.0 license, and is\n free for commercial and private use. For more information, please visit\n our licensing page at https://stormsoftware.com/licenses/projects/stryke.\n\n Website: https://stormsoftware.com\n Repository: https://github.com/storm-software/stryke\n Documentation: https://docs.stormsoftware.com/projects/stryke\n Contact: https://stormsoftware.com/contact\n\n SPDX-License-Identifier: Apache-2.0\n\n ------------------------------------------------------------------- */\n\nexport const characterMap: Record<string, string> = {\n À: \"A\",\n Á: \"A\",\n Â: \"A\",\n Ã: \"A\",\n Ä: \"A\",\n Å: \"A\",\n Ấ: \"A\",\n Ắ: \"A\",\n Ẳ: \"A\",\n Ẵ: \"A\",\n Ặ: \"A\",\n Æ: \"AE\",\n Ầ: \"A\",\n Ằ: \"A\",\n Ȃ: \"A\",\n Ç: \"C\",\n Ḉ: \"C\",\n È: \"E\",\n É: \"E\",\n Ê: \"E\",\n Ë: \"E\",\n Ế: \"E\",\n Ḗ: \"E\",\n Ề: \"E\",\n Ḕ: \"E\",\n Ḝ: \"E\",\n Ȇ: \"E\",\n Ì: \"I\",\n Í: \"I\",\n Î: \"I\",\n Ï: \"I\",\n Ḯ: \"I\",\n Ȋ: \"I\",\n Ð: \"D\",\n Ñ: \"N\",\n Ò: \"O\",\n Ó: \"O\",\n Ô: \"O\",\n Õ: \"O\",\n Ö: \"O\",\n Ø: \"O\",\n Ố: \"O\",\n Ṍ: \"O\",\n Ṓ: \"O\",\n Ȏ: \"O\",\n Ù: \"U\",\n Ú: \"U\",\n Û: \"U\",\n Ü: \"U\",\n Ý: \"Y\",\n à: \"a\",\n á: \"a\",\n â: \"a\",\n ã: \"a\",\n ä: \"a\",\n å: \"a\",\n ấ: \"a\",\n ắ: \"a\",\n ẳ: \"a\",\n ẵ: \"a\",\n ặ: \"a\",\n æ: \"ae\",\n ầ: \"a\",\n ằ: \"a\",\n ȃ: \"a\",\n ç: \"c\",\n ḉ: \"c\",\n è: \"e\",\n é: \"e\",\n ê: \"e\",\n ë: \"e\",\n ế: \"e\",\n ḗ: \"e\",\n ề: \"e\",\n ḕ: \"e\",\n ḝ: \"e\",\n ȇ: \"e\",\n ì: \"i\",\n í: \"i\",\n î: \"i\",\n ï: \"i\",\n ḯ: \"i\",\n ȋ: \"i\",\n ð: \"d\",\n ñ: \"n\",\n ò: \"o\",\n ó: \"o\",\n ô: \"o\",\n õ: \"o\",\n ö: \"o\",\n ø: \"o\",\n ố: \"o\",\n ṍ: \"o\",\n ṓ: \"o\",\n ȏ: \"o\",\n ù: \"u\",\n ú: \"u\",\n û: \"u\",\n ü: \"u\",\n ý: \"y\",\n ÿ: \"y\",\n Ā: \"A\",\n ā: \"a\",\n Ă: \"A\",\n ă: \"a\",\n Ą: \"A\",\n ą: \"a\",\n Ć: \"C\",\n ć: \"c\",\n Ĉ: \"C\",\n ĉ: \"c\",\n Ċ: \"C\",\n ċ: \"c\",\n Č: \"C\",\n č: \"c\",\n C̆: \"C\",\n c̆: \"c\",\n Ď: \"D\",\n ď: \"d\",\n Đ: \"D\",\n đ: \"d\",\n Ē: \"E\",\n ē: \"e\",\n Ĕ: \"E\",\n ĕ: \"e\",\n Ė: \"E\",\n ė: \"e\",\n Ę: \"E\",\n ę: \"e\",\n Ě: \"E\",\n ě: \"e\",\n Ĝ: \"G\",\n Ǵ: \"G\",\n ĝ: \"g\",\n ǵ: \"g\",\n Ğ: \"G\",\n ğ: \"g\",\n Ġ: \"G\",\n ġ: \"g\",\n Ģ: \"G\",\n ģ: \"g\",\n Ĥ: \"H\",\n ĥ: \"h\",\n Ħ: \"H\",\n ħ: \"h\",\n Ḫ: \"H\",\n ḫ: \"h\",\n Ĩ: \"I\",\n ĩ: \"i\",\n Ī: \"I\",\n ī: \"i\",\n Ĭ: \"I\",\n ĭ: \"i\",\n Į: \"I\",\n į: \"i\",\n İ: \"I\",\n ı: \"i\",\n IJ: \"IJ\",\n ij: \"ij\",\n Ĵ: \"J\",\n ĵ: \"j\",\n Ķ: \"K\",\n ķ: \"k\",\n Ḱ: \"K\",\n ḱ: \"k\",\n K̆: \"K\",\n k̆: \"k\",\n Ĺ: \"L\",\n ĺ: \"l\",\n Ļ: \"L\",\n ļ: \"l\",\n Ľ: \"L\",\n ľ: \"l\",\n Ŀ: \"L\",\n ŀ: \"l\",\n Ł: \"l\",\n ł: \"l\",\n Ḿ: \"M\",\n ḿ: \"m\",\n M̆: \"M\",\n m̆: \"m\",\n Ń: \"N\",\n ń: \"n\",\n Ņ: \"N\",\n ņ: \"n\",\n Ň: \"N\",\n ň: \"n\",\n ʼn: \"n\",\n N̆: \"N\",\n n̆: \"n\",\n Ō: \"O\",\n ō: \"o\",\n Ŏ: \"O\",\n ŏ: \"o\",\n Ő: \"O\",\n ő: \"o\",\n Œ: \"OE\",\n œ: \"oe\",\n P̆: \"P\",\n p̆: \"p\",\n Ŕ: \"R\",\n ŕ: \"r\",\n Ŗ: \"R\",\n ŗ: \"r\",\n Ř: \"R\",\n ř: \"r\",\n R̆: \"R\",\n r̆: \"r\",\n Ȓ: \"R\",\n ȓ: \"r\",\n Ś: \"S\",\n ś: \"s\",\n Ŝ: \"S\",\n ŝ: \"s\",\n Ş: \"S\",\n Ș: \"S\",\n ș: \"s\",\n ş: \"s\",\n Š: \"S\",\n š: \"s\",\n Ţ: \"T\",\n ţ: \"t\",\n ț: \"t\",\n Ț: \"T\",\n Ť: \"T\",\n ť: \"t\",\n Ŧ: \"T\",\n ŧ: \"t\",\n T̆: \"T\",\n t̆: \"t\",\n Ũ: \"U\",\n ũ: \"u\",\n Ū: \"U\",\n ū: \"u\",\n Ŭ: \"U\",\n ŭ: \"u\",\n Ů: \"U\",\n ů: \"u\",\n Ű: \"U\",\n ű: \"u\",\n Ų: \"U\",\n ų: \"u\",\n Ȗ: \"U\",\n ȗ: \"u\",\n V̆: \"V\",\n v̆: \"v\",\n Ŵ: \"W\",\n ŵ: \"w\",\n Ẃ: \"W\",\n ẃ: \"w\",\n X̆: \"X\",\n x̆: \"x\",\n Ŷ: \"Y\",\n ŷ: \"y\",\n Ÿ: \"Y\",\n Y̆: \"Y\",\n y̆: \"y\",\n Ź: \"Z\",\n ź: \"z\",\n Ż: \"Z\",\n ż: \"z\",\n Ž: \"Z\",\n ž: \"z\",\n ſ: \"s\",\n ƒ: \"f\",\n Ơ: \"O\",\n ơ: \"o\",\n Ư: \"U\",\n ư: \"u\",\n Ǎ: \"A\",\n ǎ: \"a\",\n Ǐ: \"I\",\n ǐ: \"i\",\n Ǒ: \"O\",\n ǒ: \"o\",\n Ǔ: \"U\",\n ǔ: \"u\",\n Ǖ: \"U\",\n ǖ: \"u\",\n Ǘ: \"U\",\n ǘ: \"u\",\n Ǚ: \"U\",\n ǚ: \"u\",\n Ǜ: \"U\",\n ǜ: \"u\",\n Ứ: \"U\",\n ứ: \"u\",\n Ṹ: \"U\",\n ṹ: \"u\",\n Ǻ: \"A\",\n ǻ: \"a\",\n Ǽ: \"AE\",\n ǽ: \"ae\",\n Ǿ: \"O\",\n ǿ: \"o\",\n Þ: \"TH\",\n þ: \"th\",\n Ṕ: \"P\",\n ṕ: \"p\",\n Ṥ: \"S\",\n ṥ: \"s\",\n X́: \"X\",\n x́: \"x\",\n Ѓ: \"Г\",\n ѓ: \"г\",\n Ќ: \"К\",\n ќ: \"к\",\n A̋: \"A\",\n a̋: \"a\",\n E̋: \"E\",\n e̋: \"e\",\n I̋: \"I\",\n i̋: \"i\",\n Ǹ: \"N\",\n ǹ: \"n\",\n Ồ: \"O\",\n ồ: \"o\",\n Ṑ: \"O\",\n ṑ: \"o\",\n Ừ: \"U\",\n ừ: \"u\",\n Ẁ: \"W\",\n ẁ: \"w\",\n Ỳ: \"Y\",\n ỳ: \"y\",\n Ȁ: \"A\",\n ȁ: \"a\",\n Ȅ: \"E\",\n ȅ: \"e\",\n Ȉ: \"I\",\n ȉ: \"i\",\n Ȍ: \"O\",\n ȍ: \"o\",\n Ȑ: \"R\",\n ȑ: \"r\",\n Ȕ: \"U\",\n ȕ: \"u\",\n B̌: \"B\",\n b̌: \"b\",\n Č̣: \"C\",\n č̣: \"c\",\n Ê̌: \"E\",\n ê̌: \"e\",\n F̌: \"F\",\n f̌: \"f\",\n Ǧ: \"G\",\n ǧ: \"g\",\n Ȟ: \"H\",\n ȟ: \"h\",\n J̌: \"J\",\n ǰ: \"j\",\n Ǩ: \"K\",\n ǩ: \"k\",\n M̌: \"M\",\n m̌: \"m\",\n P̌: \"P\",\n p̌: \"p\",\n Q̌: \"Q\",\n q̌: \"q\",\n Ř̩: \"R\",\n ř̩: \"r\",\n Ṧ: \"S\",\n ṧ: \"s\",\n V̌: \"V\",\n v̌: \"v\",\n W̌: \"W\",\n w̌: \"w\",\n X̌: \"X\",\n x̌: \"x\",\n Y̌: \"Y\",\n y̌: \"y\",\n A̧: \"A\",\n a̧: \"a\",\n B̧: \"B\",\n b̧: \"b\",\n Ḑ: \"D\",\n ḑ: \"d\",\n Ȩ: \"E\",\n ȩ: \"e\",\n Ɛ̧: \"E\",\n ɛ̧: \"e\",\n Ḩ: \"H\",\n ḩ: \"h\",\n I̧: \"I\",\n i̧: \"i\",\n Ɨ̧: \"I\",\n ɨ̧: \"i\",\n M̧: \"M\",\n m̧: \"m\",\n O̧: \"O\",\n o̧: \"o\",\n Q̧: \"Q\",\n q̧: \"q\",\n U̧: \"U\",\n u̧: \"u\",\n X̧: \"X\",\n x̧: \"x\",\n Z̧: \"Z\",\n z̧: \"z\"\n};\n\n/**\n * Removes accents from a string.\n *\n * @param str - The string to remove accents from\n * @returns The string without accents\n */\nexport const removeAccents = (str: string) =>\n str.replace(\n // eslint-disable-next-line regexp/no-dupe-disjunctions, regexp/prefer-character-class\n new RegExp(Object.keys(characterMap).join(\"|\"), \"g\"),\n match => characterMap[match]!\n );\n"],"mappings":";AAkBA,MAAa,eAAuC;CAClD,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,IAAI;CACJ,IAAI;CACJ,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,IAAI;CACJ,IAAI;CACJ,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,IAAI;CACJ,IAAI;CACJ,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,IAAI;CACJ,IAAI;CACJ,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,IAAI;CACJ,IAAI;CACJ,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,IAAI;CACJ,IAAI;CACJ,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,IAAI;CACJ,IAAI;CACJ,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,IAAI;CACJ,IAAI;CACJ,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,IAAI;CACJ,IAAI;CACJ,GAAG;CACH,GAAG;CACH,GAAG;CACH,IAAI;CACJ,IAAI;CACJ,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,IAAI;CACJ,IAAI;CACJ,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,IAAI;CACJ,IAAI;CACJ,IAAI;CACJ,IAAI;CACJ,IAAI;CACJ,IAAI;CACJ,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,IAAI;CACJ,IAAI;CACJ,IAAI;CACJ,IAAI;CACJ,IAAI;CACJ,IAAI;CACJ,IAAI;CACJ,IAAI;CACJ,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,IAAI;CACJ,GAAG;CACH,GAAG;CACH,GAAG;CACH,IAAI;CACJ,IAAI;CACJ,IAAI;CACJ,IAAI;CACJ,IAAI;CACJ,IAAI;CACJ,IAAI;CACJ,IAAI;CACJ,GAAG;CACH,GAAG;CACH,IAAI;CACJ,IAAI;CACJ,IAAI;CACJ,IAAI;CACJ,IAAI;CACJ,IAAI;CACJ,IAAI;CACJ,IAAI;CACJ,IAAI;CACJ,IAAI;CACJ,IAAI;CACJ,IAAI;CACJ,GAAG;CACH,GAAG;CACH,GAAG;CACH,GAAG;CACH,IAAI;CACJ,IAAI;CACJ,GAAG;CACH,GAAG;CACH,IAAI;CACJ,IAAI;CACJ,IAAI;CACJ,IAAI;CACJ,IAAI;CACJ,IAAI;CACJ,IAAI;CACJ,IAAI;CACJ,IAAI;CACJ,IAAI;CACJ,IAAI;CACJ,IAAI;CACJ,IAAI;CACJ,IAAI;CACJ,IAAI;CACJ,IAAI;CACL;;;;;;;AAQD,MAAa,iBAAiB,QAC5B,IAAI,QAEF,IAAI,OAAO,OAAO,KAAK,aAAa,CAAC,KAAK,IAAI,EAAE,IAAI,GACpD,UAAS,aAAa,OACvB"}
@@ -1,8 +1,6 @@
1
1
  Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
2
- const require_runtime = require('./_virtual/_rolldown/runtime.cjs');
3
2
 
4
3
  //#region src/remove-empty-items.ts
5
- var remove_empty_items_exports = /* @__PURE__ */ require_runtime.__exportAll({ removeEmptyItems: () => removeEmptyItems });
6
4
  /**
7
5
  * Removes empty items from an array
8
6
  *
@@ -12,10 +10,4 @@ var remove_empty_items_exports = /* @__PURE__ */ require_runtime.__exportAll({ r
12
10
  const removeEmptyItems = (arr) => arr.filter(Boolean);
13
11
 
14
12
  //#endregion
15
- exports.removeEmptyItems = removeEmptyItems;
16
- Object.defineProperty(exports, 'remove_empty_items_exports', {
17
- enumerable: true,
18
- get: function () {
19
- return remove_empty_items_exports;
20
- }
21
- });
13
+ exports.removeEmptyItems = removeEmptyItems;
@@ -1,7 +1,4 @@
1
- import { __exportAll } from "./_virtual/_rolldown/runtime.mjs";
2
-
3
1
  //#region src/remove-empty-items.ts
4
- var remove_empty_items_exports = /* @__PURE__ */ __exportAll({ removeEmptyItems: () => removeEmptyItems });
5
2
  /**
6
3
  * Removes empty items from an array
7
4
  *
@@ -11,5 +8,5 @@ var remove_empty_items_exports = /* @__PURE__ */ __exportAll({ removeEmptyItems:
11
8
  const removeEmptyItems = (arr) => arr.filter(Boolean);
12
9
 
13
10
  //#endregion
14
- export { removeEmptyItems, remove_empty_items_exports };
11
+ export { removeEmptyItems };
15
12
  //# sourceMappingURL=remove-empty-items.mjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"remove-empty-items.mjs","names":[],"sources":["../src/remove-empty-items.ts"],"sourcesContent":["/* -------------------------------------------------------------------\n\n ⚡ Storm Software - Stryke\n\n This code was released as part of the Stryke project. Stryke\n is maintained by Storm Software under the Apache-2.0 license, and is\n free for commercial and private use. For more information, please visit\n our licensing page at https://stormsoftware.com/licenses/projects/stryke.\n\n Website: https://stormsoftware.com\n Repository: https://github.com/storm-software/stryke\n Documentation: https://docs.stormsoftware.com/projects/stryke\n Contact: https://stormsoftware.com/contact\n\n SPDX-License-Identifier: Apache-2.0\n\n ------------------------------------------------------------------- */\n\n/**\n * Removes empty items from an array\n *\n * @param arr - The array to remove empty items from\n * @returns The array with empty items removed\n */\nexport const removeEmptyItems = <T = any>(\n arr: (T | undefined | null)[]\n): NonNullable<T>[] => arr.filter(Boolean) as NonNullable<T>[];\n"],"mappings":";;;;;;;;;;AAwBA,MAAa,oBACX,QACqB,IAAI,OAAO,QAAQ"}
1
+ {"version":3,"file":"remove-empty-items.mjs","names":[],"sources":["../src/remove-empty-items.ts"],"sourcesContent":["/* -------------------------------------------------------------------\n\n ⚡ Storm Software - Stryke\n\n This code was released as part of the Stryke project. Stryke\n is maintained by Storm Software under the Apache-2.0 license, and is\n free for commercial and private use. For more information, please visit\n our licensing page at https://stormsoftware.com/licenses/projects/stryke.\n\n Website: https://stormsoftware.com\n Repository: https://github.com/storm-software/stryke\n Documentation: https://docs.stormsoftware.com/projects/stryke\n Contact: https://stormsoftware.com/contact\n\n SPDX-License-Identifier: Apache-2.0\n\n ------------------------------------------------------------------- */\n\n/**\n * Removes empty items from an array\n *\n * @param arr - The array to remove empty items from\n * @returns The array with empty items removed\n */\nexport const removeEmptyItems = <T = any>(\n arr: (T | undefined | null)[]\n): NonNullable<T>[] => arr.filter(Boolean) as NonNullable<T>[];\n"],"mappings":";;;;;;;AAwBA,MAAa,oBACX,QACqB,IAAI,OAAO,QAAQ"}
@@ -1,11 +1,9 @@
1
1
  Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
2
- const require_runtime = require('./_virtual/_rolldown/runtime.cjs');
3
2
  const require_to_path = require('./to-path.cjs');
4
3
  let _stryke_type_checks_is_object_index = require("@stryke/type-checks/is-object-index");
5
4
  let _stryke_type_checks_is_string = require("@stryke/type-checks/is-string");
6
5
 
7
6
  //#region src/set-field.ts
8
- var set_field_exports = /* @__PURE__ */ require_runtime.__exportAll({ setField: () => setField });
9
7
  /**
10
8
  * Sets a value at a given deep path in an object.
11
9
  *
@@ -30,10 +28,4 @@ function setField(object, path, value) {
30
28
  }
31
29
 
32
30
  //#endregion
33
- exports.setField = setField;
34
- Object.defineProperty(exports, 'set_field_exports', {
35
- enumerable: true,
36
- get: function () {
37
- return set_field_exports;
38
- }
39
- });
31
+ exports.setField = setField;
@@ -1,10 +1,8 @@
1
- import { __exportAll } from "./_virtual/_rolldown/runtime.mjs";
2
1
  import { toPath } from "./to-path.mjs";
3
2
  import { isObjectIndex } from "@stryke/type-checks/is-object-index";
4
3
  import { isString } from "@stryke/type-checks/is-string";
5
4
 
6
5
  //#region src/set-field.ts
7
- var set_field_exports = /* @__PURE__ */ __exportAll({ setField: () => setField });
8
6
  /**
9
7
  * Sets a value at a given deep path in an object.
10
8
  *
@@ -29,5 +27,5 @@ function setField(object, path, value) {
29
27
  }
30
28
 
31
29
  //#endregion
32
- export { setField, set_field_exports };
30
+ export { setField };
33
31
  //# sourceMappingURL=set-field.mjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"set-field.mjs","names":[],"sources":["../src/set-field.ts"],"sourcesContent":["/* -------------------------------------------------------------------\n\n ⚡ Storm Software - Stryke\n\n This code was released as part of the Stryke project. Stryke\n is maintained by Storm Software under the Apache-2.0 license, and is\n free for commercial and private use. For more information, please visit\n our licensing page at https://stormsoftware.com/licenses/projects/stryke.\n\n Website: https://stormsoftware.com\n Repository: https://github.com/storm-software/stryke\n Documentation: https://docs.stormsoftware.com/projects/stryke\n Contact: https://stormsoftware.com/contact\n\n SPDX-License-Identifier: Apache-2.0\n\n ------------------------------------------------------------------- */\n\nimport { isObjectIndex } from \"@stryke/type-checks/is-object-index\";\nimport { isString } from \"@stryke/type-checks/is-string\";\nimport type { DeepKey } from \"@stryke/types/object\";\nimport { toPath } from \"./to-path\";\n\n/**\n * Sets a value at a given deep path in an object.\n *\n * @param object - The object to set the value in.\n * @param path - The deep path to set the value at.\n * @param value - The value to set.\n * @returns The object with the value set at the given deep path.\n */\nexport function setField<\n TObject extends Record<string, any> = Record<string, any>\n>(object: TObject, path: DeepKey<TObject>, value: unknown): TObject {\n const resolvedPath = Array.isArray(path)\n ? path\n : isString(path)\n ? toPath(path)\n : [path];\n\n // Validate resolvedPath to prevent prototype pollution\n for (const key of resolvedPath) {\n if (key === \"__proto__\" || key === \"constructor\" || key === \"prototype\") {\n throw new Error(`Invalid key in path: ${key}`);\n }\n }\n\n let current: any = object;\n for (let i = 0; i < resolvedPath.length - 1; i++) {\n const key = resolvedPath[i];\n const nextKey = resolvedPath[i + 1];\n\n if (current[key] === null) {\n current[key] = isObjectIndex(nextKey) ? [] : {};\n }\n\n current = current[key];\n }\n\n const lastKey = resolvedPath.at(-1);\n if (lastKey) {\n current[lastKey] = value;\n }\n\n return object;\n}\n"],"mappings":";;;;;;;;;;;;;;;AA+BA,SAAgB,SAEd,QAAiB,MAAwB,OAAyB;CAClE,MAAM,eAAe,MAAM,QAAQ,KAAK,GACpC,OACA,SAAS,KAAK,GACZ,OAAO,KAAK,GACZ,CAAC,KAAK;AAGZ,MAAK,MAAM,OAAO,aAChB,KAAI,QAAQ,eAAe,QAAQ,iBAAiB,QAAQ,YAC1D,OAAM,IAAI,MAAM,wBAAwB,MAAM;CAIlD,IAAI,UAAe;AACnB,MAAK,IAAI,IAAI,GAAG,IAAI,aAAa,SAAS,GAAG,KAAK;EAChD,MAAM,MAAM,aAAa;EACzB,MAAM,UAAU,aAAa,IAAI;AAEjC,MAAI,QAAQ,SAAS,KACnB,SAAQ,OAAO,cAAc,QAAQ,GAAG,EAAE,GAAG,EAAE;AAGjD,YAAU,QAAQ;;CAGpB,MAAM,UAAU,aAAa,GAAG,GAAG;AACnC,KAAI,QACF,SAAQ,WAAW;AAGrB,QAAO"}
1
+ {"version":3,"file":"set-field.mjs","names":[],"sources":["../src/set-field.ts"],"sourcesContent":["/* -------------------------------------------------------------------\n\n ⚡ Storm Software - Stryke\n\n This code was released as part of the Stryke project. Stryke\n is maintained by Storm Software under the Apache-2.0 license, and is\n free for commercial and private use. For more information, please visit\n our licensing page at https://stormsoftware.com/licenses/projects/stryke.\n\n Website: https://stormsoftware.com\n Repository: https://github.com/storm-software/stryke\n Documentation: https://docs.stormsoftware.com/projects/stryke\n Contact: https://stormsoftware.com/contact\n\n SPDX-License-Identifier: Apache-2.0\n\n ------------------------------------------------------------------- */\n\nimport { isObjectIndex } from \"@stryke/type-checks/is-object-index\";\nimport { isString } from \"@stryke/type-checks/is-string\";\nimport type { DeepKey } from \"@stryke/types/object\";\nimport { toPath } from \"./to-path\";\n\n/**\n * Sets a value at a given deep path in an object.\n *\n * @param object - The object to set the value in.\n * @param path - The deep path to set the value at.\n * @param value - The value to set.\n * @returns The object with the value set at the given deep path.\n */\nexport function setField<\n TObject extends Record<string, any> = Record<string, any>\n>(object: TObject, path: DeepKey<TObject>, value: unknown): TObject {\n const resolvedPath = Array.isArray(path)\n ? path\n : isString(path)\n ? toPath(path)\n : [path];\n\n // Validate resolvedPath to prevent prototype pollution\n for (const key of resolvedPath) {\n if (key === \"__proto__\" || key === \"constructor\" || key === \"prototype\") {\n throw new Error(`Invalid key in path: ${key}`);\n }\n }\n\n let current: any = object;\n for (let i = 0; i < resolvedPath.length - 1; i++) {\n const key = resolvedPath[i];\n const nextKey = resolvedPath[i + 1];\n\n if (current[key] === null) {\n current[key] = isObjectIndex(nextKey) ? [] : {};\n }\n\n current = current[key];\n }\n\n const lastKey = resolvedPath.at(-1);\n if (lastKey) {\n current[lastKey] = value;\n }\n\n return object;\n}\n"],"mappings":";;;;;;;;;;;;;AA+BA,SAAgB,SAEd,QAAiB,MAAwB,OAAyB;CAClE,MAAM,eAAe,MAAM,QAAQ,KAAK,GACpC,OACA,SAAS,KAAK,GACZ,OAAO,KAAK,GACZ,CAAC,KAAK;AAGZ,MAAK,MAAM,OAAO,aAChB,KAAI,QAAQ,eAAe,QAAQ,iBAAiB,QAAQ,YAC1D,OAAM,IAAI,MAAM,wBAAwB,MAAM;CAIlD,IAAI,UAAe;AACnB,MAAK,IAAI,IAAI,GAAG,IAAI,aAAa,SAAS,GAAG,KAAK;EAChD,MAAM,MAAM,aAAa;EACzB,MAAM,UAAU,aAAa,IAAI;AAEjC,MAAI,QAAQ,SAAS,KACnB,SAAQ,OAAO,cAAc,QAAQ,GAAG,EAAE,GAAG,EAAE;AAGjD,YAAU,QAAQ;;CAGpB,MAAM,UAAU,aAAa,GAAG,GAAG;AACnC,KAAI,QACF,SAAQ,WAAW;AAGrB,QAAO"}
@@ -1,13 +1,8 @@
1
1
  Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
2
- const require_runtime = require('./_virtual/_rolldown/runtime.cjs');
3
2
  let _stryke_type_checks_is_set_string = require("@stryke/type-checks/is-set-string");
4
3
  let _stryke_type_checks_is_number = require("@stryke/type-checks/is-number");
5
4
 
6
5
  //#region src/to-deep-key.ts
7
- var to_deep_key_exports = /* @__PURE__ */ require_runtime.__exportAll({
8
- addPathToDeepKey: () => addPathToDeepKey,
9
- toDeepKey: () => toDeepKey
10
- });
11
6
  /**
12
7
  * Converts an array of path segments into a deep key string.
13
8
  *
@@ -57,10 +52,4 @@ function addPathToDeepKey(deepKey, path) {
57
52
 
58
53
  //#endregion
59
54
  exports.addPathToDeepKey = addPathToDeepKey;
60
- exports.toDeepKey = toDeepKey;
61
- Object.defineProperty(exports, 'to_deep_key_exports', {
62
- enumerable: true,
63
- get: function () {
64
- return to_deep_key_exports;
65
- }
66
- });
55
+ exports.toDeepKey = toDeepKey;
@@ -1,12 +1,7 @@
1
- import { __exportAll } from "./_virtual/_rolldown/runtime.mjs";
2
1
  import { isSetString } from "@stryke/type-checks/is-set-string";
3
2
  import { isNumber } from "@stryke/type-checks/is-number";
4
3
 
5
4
  //#region src/to-deep-key.ts
6
- var to_deep_key_exports = /* @__PURE__ */ __exportAll({
7
- addPathToDeepKey: () => addPathToDeepKey,
8
- toDeepKey: () => toDeepKey
9
- });
10
5
  /**
11
6
  * Converts an array of path segments into a deep key string.
12
7
  *
@@ -55,5 +50,5 @@ function addPathToDeepKey(deepKey, path) {
55
50
  }
56
51
 
57
52
  //#endregion
58
- export { addPathToDeepKey, toDeepKey, to_deep_key_exports };
53
+ export { addPathToDeepKey, toDeepKey };
59
54
  //# sourceMappingURL=to-deep-key.mjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"to-deep-key.mjs","names":[],"sources":["../src/to-deep-key.ts"],"sourcesContent":["/* -------------------------------------------------------------------\n\n ⚡ Storm Software - Stryke\n\n This code was released as part of the Stryke project. Stryke\n is maintained by Storm Software under the Apache-2.0 license, and is\n free for commercial and private use. For more information, please visit\n our licensing page at https://stormsoftware.com/licenses/projects/stryke.\n\n Website: https://stormsoftware.com\n Repository: https://github.com/storm-software/stryke\n Documentation: https://docs.stormsoftware.com/projects/stryke\n Contact: https://stormsoftware.com/contact\n\n SPDX-License-Identifier: Apache-2.0\n\n ------------------------------------------------------------------- */\n\nimport { isNumber } from \"@stryke/type-checks/is-number\";\nimport { isSetString } from \"@stryke/type-checks/is-set-string\";\n\n/**\n * Converts an array of path segments into a deep key string.\n *\n * This function takes an array of strings and numbers representing path segments and combines them into a deep key string.\n *\n * @example\n * toDeepKey(['a', 'b', 'c']) // Returns 'a.b.c'\n * toDeepKey(['a', 0, 'c']) // Returns 'a[0].c'\n * toDeepKey(['', 'a', 'b', 'c']) // Returns '.a.b.c'\n * toDeepKey(['a', 'b.c', 'd']) // Returns 'a.b.c.d'\n * toDeepKey([]) // Returns ''\n * toDeepKey(['', 'a', 'b', 'c', 'd', 'e', 'f.g', 'h']) // Returns '.a.b.c.d.e.f.g.h'\n *\n * @param path - An array of strings and numbers representing path segments.\n * @returns A deep key string.\n */\nexport function toDeepKey(path: string[]): string {\n return path.reduce((ret, segment) => {\n return addPathToDeepKey(ret, segment);\n });\n}\n\n/**\n * Adds a path segment to a deep key string.\n *\n * @remarks\n * This function takes a deep key string and a path segment and combines them into a new deep key string.\n *\n * @example\n * ```ts\n * addPathToDeepKey('a.b', 'c') // Returns 'a.b.c'\n * addPathToDeepKey('a[0]', 'c') // Returns 'a[0].c'\n * addPathToDeepKey('.a.b', 'c') // Returns '.a.b.c'\n * addPathToDeepKey('a.b', 'b.c') // Returns 'a.b.b.c'\n * addPathToDeepKey('', 'a') // Returns 'a'\n * addPathToDeepKey('.a.b', 'c.d') // Returns '.a.b.c.d'\n * ```\n *\n * @param deepKey - The deep key string to add the path segment to.\n * @param path - The path segment to add to the deep key string.\n * @returns A new deep key string.\n */\nexport function addPathToDeepKey(\n deepKey: string,\n path: string | number\n): string {\n if (isNumber(path) || Number.isInteger(path)) {\n return `${deepKey}[${path}]`;\n }\n if (isSetString(path)) {\n return `${deepKey}.${path}`;\n }\n\n return deepKey;\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;AAqCA,SAAgB,UAAU,MAAwB;AAChD,QAAO,KAAK,QAAQ,KAAK,YAAY;AACnC,SAAO,iBAAiB,KAAK,QAAQ;GACrC;;;;;;;;;;;;;;;;;;;;;;AAuBJ,SAAgB,iBACd,SACA,MACQ;AACR,KAAI,SAAS,KAAK,IAAI,OAAO,UAAU,KAAK,CAC1C,QAAO,GAAG,QAAQ,GAAG,KAAK;AAE5B,KAAI,YAAY,KAAK,CACnB,QAAO,GAAG,QAAQ,GAAG;AAGvB,QAAO"}
1
+ {"version":3,"file":"to-deep-key.mjs","names":[],"sources":["../src/to-deep-key.ts"],"sourcesContent":["/* -------------------------------------------------------------------\n\n ⚡ Storm Software - Stryke\n\n This code was released as part of the Stryke project. Stryke\n is maintained by Storm Software under the Apache-2.0 license, and is\n free for commercial and private use. For more information, please visit\n our licensing page at https://stormsoftware.com/licenses/projects/stryke.\n\n Website: https://stormsoftware.com\n Repository: https://github.com/storm-software/stryke\n Documentation: https://docs.stormsoftware.com/projects/stryke\n Contact: https://stormsoftware.com/contact\n\n SPDX-License-Identifier: Apache-2.0\n\n ------------------------------------------------------------------- */\n\nimport { isNumber } from \"@stryke/type-checks/is-number\";\nimport { isSetString } from \"@stryke/type-checks/is-set-string\";\n\n/**\n * Converts an array of path segments into a deep key string.\n *\n * This function takes an array of strings and numbers representing path segments and combines them into a deep key string.\n *\n * @example\n * toDeepKey(['a', 'b', 'c']) // Returns 'a.b.c'\n * toDeepKey(['a', 0, 'c']) // Returns 'a[0].c'\n * toDeepKey(['', 'a', 'b', 'c']) // Returns '.a.b.c'\n * toDeepKey(['a', 'b.c', 'd']) // Returns 'a.b.c.d'\n * toDeepKey([]) // Returns ''\n * toDeepKey(['', 'a', 'b', 'c', 'd', 'e', 'f.g', 'h']) // Returns '.a.b.c.d.e.f.g.h'\n *\n * @param path - An array of strings and numbers representing path segments.\n * @returns A deep key string.\n */\nexport function toDeepKey(path: string[]): string {\n return path.reduce((ret, segment) => {\n return addPathToDeepKey(ret, segment);\n });\n}\n\n/**\n * Adds a path segment to a deep key string.\n *\n * @remarks\n * This function takes a deep key string and a path segment and combines them into a new deep key string.\n *\n * @example\n * ```ts\n * addPathToDeepKey('a.b', 'c') // Returns 'a.b.c'\n * addPathToDeepKey('a[0]', 'c') // Returns 'a[0].c'\n * addPathToDeepKey('.a.b', 'c') // Returns '.a.b.c'\n * addPathToDeepKey('a.b', 'b.c') // Returns 'a.b.b.c'\n * addPathToDeepKey('', 'a') // Returns 'a'\n * addPathToDeepKey('.a.b', 'c.d') // Returns '.a.b.c.d'\n * ```\n *\n * @param deepKey - The deep key string to add the path segment to.\n * @param path - The path segment to add to the deep key string.\n * @returns A new deep key string.\n */\nexport function addPathToDeepKey(\n deepKey: string,\n path: string | number\n): string {\n if (isNumber(path) || Number.isInteger(path)) {\n return `${deepKey}[${path}]`;\n }\n if (isSetString(path)) {\n return `${deepKey}.${path}`;\n }\n\n return deepKey;\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;AAqCA,SAAgB,UAAU,MAAwB;AAChD,QAAO,KAAK,QAAQ,KAAK,YAAY;AACnC,SAAO,iBAAiB,KAAK,QAAQ;GACrC;;;;;;;;;;;;;;;;;;;;;;AAuBJ,SAAgB,iBACd,SACA,MACQ;AACR,KAAI,SAAS,KAAK,IAAI,OAAO,UAAU,KAAK,CAC1C,QAAO,GAAG,QAAQ,GAAG,KAAK;AAE5B,KAAI,YAAY,KAAK,CACnB,QAAO,GAAG,QAAQ,GAAG;AAGvB,QAAO"}
package/dist/to-path.cjs CHANGED
@@ -1,8 +1,6 @@
1
1
  Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
2
- const require_runtime = require('./_virtual/_rolldown/runtime.cjs');
3
2
 
4
3
  //#region src/to-path.ts
5
- var to_path_exports = /* @__PURE__ */ require_runtime.__exportAll({ toPath: () => toPath });
6
4
  const DOTS_KEY = /^[\w.]+$/g;
7
5
  const ESCAPE_REGEXP = /\\(?<temp1>\\)?/g;
8
6
  const PROPERTY_REGEXP = new RegExp(`${String.raw`[^.[\]]+`}|${String.raw`\[(?:`}([^"'][^[]*)|${String.raw`(["'])((?:(?!\2)[^\\]|\\.)*?)\2`}${String.raw`)\]`}|${String.raw`(?=(?:\.|\[\])(?:\.|\[\]|$))`}`, "g");
@@ -43,10 +41,4 @@ function toPath(deepKey) {
43
41
  }
44
42
 
45
43
  //#endregion
46
- exports.toPath = toPath;
47
- Object.defineProperty(exports, 'to_path_exports', {
48
- enumerable: true,
49
- get: function () {
50
- return to_path_exports;
51
- }
52
- });
44
+ exports.toPath = toPath;
package/dist/to-path.mjs CHANGED
@@ -1,7 +1,4 @@
1
- import { __exportAll } from "./_virtual/_rolldown/runtime.mjs";
2
-
3
1
  //#region src/to-path.ts
4
- var to_path_exports = /* @__PURE__ */ __exportAll({ toPath: () => toPath });
5
2
  const DOTS_KEY = /^[\w.]+$/g;
6
3
  const ESCAPE_REGEXP = /\\(?<temp1>\\)?/g;
7
4
  const PROPERTY_REGEXP = new RegExp(`${String.raw`[^.[\]]+`}|${String.raw`\[(?:`}([^"'][^[]*)|${String.raw`(["'])((?:(?!\2)[^\\]|\\.)*?)\2`}${String.raw`)\]`}|${String.raw`(?=(?:\.|\[\])(?:\.|\[\]|$))`}`, "g");
@@ -42,5 +39,5 @@ function toPath(deepKey) {
42
39
  }
43
40
 
44
41
  //#endregion
45
- export { toPath, to_path_exports };
42
+ export { toPath };
46
43
  //# sourceMappingURL=to-path.mjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"to-path.mjs","names":[],"sources":["../src/to-path.ts"],"sourcesContent":["/* -------------------------------------------------------------------\n\n ⚡ Storm Software - Stryke\n\n This code was released as part of the Stryke project. Stryke\n is maintained by Storm Software under the Apache-2.0 license, and is\n free for commercial and private use. For more information, please visit\n our licensing page at https://stormsoftware.com/licenses/projects/stryke.\n\n Website: https://stormsoftware.com\n Repository: https://github.com/storm-software/stryke\n Documentation: https://docs.stormsoftware.com/projects/stryke\n Contact: https://stormsoftware.com/contact\n\n SPDX-License-Identifier: Apache-2.0\n\n ------------------------------------------------------------------- */\n\nconst DOTS_KEY = /^[\\w.]+$/g;\n\nconst ESCAPE_REGEXP = /\\\\(?<temp1>\\\\)?/g;\nconst PROPERTY_REGEXP = new RegExp(\n // Match anything that isn't a dot or bracket.\n `${String.raw`[^.[\\]]+`}|${\n // Or match property names within brackets.\n String.raw`\\[(?:`\n // Match a non-string expression.\n }([^\"'][^[]*)` +\n `|${\n // Or match strings (supports escaping characters).\n String.raw`([\"'])((?:(?!\\2)[^\\\\]|\\\\.)*?)\\2`\n }${String.raw`)\\]`}|${\n // Or match \"\" as the space between consecutive dots or empty brackets.\n String.raw`(?=(?:\\.|\\[\\])(?:\\.|\\[\\]|$))`\n }`,\n \"g\"\n);\n\n/**\n * Converts a deep key string into an array of path segments.\n *\n * @remarks\n * This function takes a string representing a deep key (e.g., 'a.b.c' or 'a[b][c]') and breaks it down into an array of strings, each representing a segment of the path.\n *\n * @example\n * ```ts\n * toPath('a.b.c') // Returns ['a', 'b', 'c']\n * toPath('a[b][c]') // Returns ['a', 'b', 'c']\n * toPath('.a.b.c') // Returns ['', 'a', 'b', 'c']\n * toPath('a[\"b.c\"].d') // Returns ['a', 'b.c', 'd']\n * toPath('') // Returns []\n * toPath('.a[b].c.d[e][\"f.g\"].h') // Returns ['', 'a', 'b', 'c', 'd', 'e', 'f.g', 'h']\n * ```\n *\n * @param deepKey - The deep key string to convert.\n * @returns An array of strings, each representing a segment of the path.\n */\nexport function toPath(deepKey: string): string[] {\n if (DOTS_KEY.test(deepKey)) {\n return deepKey.split(\".\");\n }\n\n const result: string[] = [];\n\n if (deepKey[0] === \".\") {\n result.push(\"\");\n }\n\n const matches = deepKey.matchAll(PROPERTY_REGEXP);\n\n for (const match of matches) {\n let key = match[0];\n const expr = match[1];\n const quote = match[2];\n const substr = match[3];\n\n if (quote && substr) {\n key = substr.replace(ESCAPE_REGEXP, \"$1\");\n } else if (expr) {\n key = expr;\n }\n\n result.push(key);\n }\n\n return result;\n}\n"],"mappings":";;;;AAkBA,MAAM,WAAW;AAEjB,MAAM,gBAAgB;AACtB,MAAM,kBAAkB,IAAI,OAE1B,GAAG,OAAO,GAAG,WAAW,GAEtB,OAAO,GAAG,QAEX,eAGG,OAAO,GAAG,oCACT,OAAO,GAAG,MAAM,GAEjB,OAAO,GAAG,kCAEd,IACD;;;;;;;;;;;;;;;;;;;;AAqBD,SAAgB,OAAO,SAA2B;AAChD,KAAI,SAAS,KAAK,QAAQ,CACxB,QAAO,QAAQ,MAAM,IAAI;CAG3B,MAAM,SAAmB,EAAE;AAE3B,KAAI,QAAQ,OAAO,IACjB,QAAO,KAAK,GAAG;CAGjB,MAAM,UAAU,QAAQ,SAAS,gBAAgB;AAEjD,MAAK,MAAM,SAAS,SAAS;EAC3B,IAAI,MAAM,MAAM;EAChB,MAAM,OAAO,MAAM;EACnB,MAAM,QAAQ,MAAM;EACpB,MAAM,SAAS,MAAM;AAErB,MAAI,SAAS,OACX,OAAM,OAAO,QAAQ,eAAe,KAAK;WAChC,KACT,OAAM;AAGR,SAAO,KAAK,IAAI;;AAGlB,QAAO"}
1
+ {"version":3,"file":"to-path.mjs","names":[],"sources":["../src/to-path.ts"],"sourcesContent":["/* -------------------------------------------------------------------\n\n ⚡ Storm Software - Stryke\n\n This code was released as part of the Stryke project. Stryke\n is maintained by Storm Software under the Apache-2.0 license, and is\n free for commercial and private use. For more information, please visit\n our licensing page at https://stormsoftware.com/licenses/projects/stryke.\n\n Website: https://stormsoftware.com\n Repository: https://github.com/storm-software/stryke\n Documentation: https://docs.stormsoftware.com/projects/stryke\n Contact: https://stormsoftware.com/contact\n\n SPDX-License-Identifier: Apache-2.0\n\n ------------------------------------------------------------------- */\n\nconst DOTS_KEY = /^[\\w.]+$/g;\n\nconst ESCAPE_REGEXP = /\\\\(?<temp1>\\\\)?/g;\nconst PROPERTY_REGEXP = new RegExp(\n // Match anything that isn't a dot or bracket.\n `${String.raw`[^.[\\]]+`}|${\n // Or match property names within brackets.\n String.raw`\\[(?:`\n // Match a non-string expression.\n }([^\"'][^[]*)` +\n `|${\n // Or match strings (supports escaping characters).\n String.raw`([\"'])((?:(?!\\2)[^\\\\]|\\\\.)*?)\\2`\n }${String.raw`)\\]`}|${\n // Or match \"\" as the space between consecutive dots or empty brackets.\n String.raw`(?=(?:\\.|\\[\\])(?:\\.|\\[\\]|$))`\n }`,\n \"g\"\n);\n\n/**\n * Converts a deep key string into an array of path segments.\n *\n * @remarks\n * This function takes a string representing a deep key (e.g., 'a.b.c' or 'a[b][c]') and breaks it down into an array of strings, each representing a segment of the path.\n *\n * @example\n * ```ts\n * toPath('a.b.c') // Returns ['a', 'b', 'c']\n * toPath('a[b][c]') // Returns ['a', 'b', 'c']\n * toPath('.a.b.c') // Returns ['', 'a', 'b', 'c']\n * toPath('a[\"b.c\"].d') // Returns ['a', 'b.c', 'd']\n * toPath('') // Returns []\n * toPath('.a[b].c.d[e][\"f.g\"].h') // Returns ['', 'a', 'b', 'c', 'd', 'e', 'f.g', 'h']\n * ```\n *\n * @param deepKey - The deep key string to convert.\n * @returns An array of strings, each representing a segment of the path.\n */\nexport function toPath(deepKey: string): string[] {\n if (DOTS_KEY.test(deepKey)) {\n return deepKey.split(\".\");\n }\n\n const result: string[] = [];\n\n if (deepKey[0] === \".\") {\n result.push(\"\");\n }\n\n const matches = deepKey.matchAll(PROPERTY_REGEXP);\n\n for (const match of matches) {\n let key = match[0];\n const expr = match[1];\n const quote = match[2];\n const substr = match[3];\n\n if (quote && substr) {\n key = substr.replace(ESCAPE_REGEXP, \"$1\");\n } else if (expr) {\n key = expr;\n }\n\n result.push(key);\n }\n\n return result;\n}\n"],"mappings":";AAkBA,MAAM,WAAW;AAEjB,MAAM,gBAAgB;AACtB,MAAM,kBAAkB,IAAI,OAE1B,GAAG,OAAO,GAAG,WAAW,GAEtB,OAAO,GAAG,QAEX,eAGG,OAAO,GAAG,oCACT,OAAO,GAAG,MAAM,GAEjB,OAAO,GAAG,kCAEd,IACD;;;;;;;;;;;;;;;;;;;;AAqBD,SAAgB,OAAO,SAA2B;AAChD,KAAI,SAAS,KAAK,QAAQ,CACxB,QAAO,QAAQ,MAAM,IAAI;CAG3B,MAAM,SAAmB,EAAE;AAE3B,KAAI,QAAQ,OAAO,IACjB,QAAO,KAAK,GAAG;CAGjB,MAAM,UAAU,QAAQ,SAAS,gBAAgB;AAEjD,MAAK,MAAM,SAAS,SAAS;EAC3B,IAAI,MAAM,MAAM;EAChB,MAAM,OAAO,MAAM;EACnB,MAAM,QAAQ,MAAM;EACpB,MAAM,SAAS,MAAM;AAErB,MAAI,SAAS,OACX,OAAM,OAAO,QAAQ,eAAe,KAAK;WAChC,KACT,OAAM;AAGR,SAAO,KAAK,IAAI;;AAGlB,QAAO"}
@@ -1,9 +1,7 @@
1
1
  Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
2
- const require_runtime = require('./_virtual/_rolldown/runtime.cjs');
3
2
  const require_set_field = require('./set-field.cjs');
4
3
 
5
4
  //#region src/unflatten-object.ts
6
- var unflatten_object_exports = /* @__PURE__ */ require_runtime.__exportAll({ unflattenObject: () => unflattenObject });
7
5
  /**
8
6
  * Flattens a nested object into a single level object with dot-separated keys.
9
7
  *
@@ -38,10 +36,4 @@ function unflattenObject(deepKeyObject) {
38
36
  }
39
37
 
40
38
  //#endregion
41
- exports.unflattenObject = unflattenObject;
42
- Object.defineProperty(exports, 'unflatten_object_exports', {
43
- enumerable: true,
44
- get: function () {
45
- return unflatten_object_exports;
46
- }
47
- });
39
+ exports.unflattenObject = unflattenObject;
@@ -1,8 +1,6 @@
1
- import { __exportAll } from "./_virtual/_rolldown/runtime.mjs";
2
1
  import { setField } from "./set-field.mjs";
3
2
 
4
3
  //#region src/unflatten-object.ts
5
- var unflatten_object_exports = /* @__PURE__ */ __exportAll({ unflattenObject: () => unflattenObject });
6
4
  /**
7
5
  * Flattens a nested object into a single level object with dot-separated keys.
8
6
  *
@@ -37,5 +35,5 @@ function unflattenObject(deepKeyObject) {
37
35
  }
38
36
 
39
37
  //#endregion
40
- export { unflattenObject, unflatten_object_exports };
38
+ export { unflattenObject };
41
39
  //# sourceMappingURL=unflatten-object.mjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"unflatten-object.mjs","names":[],"sources":["../src/unflatten-object.ts"],"sourcesContent":["/* -------------------------------------------------------------------\n\n ⚡ Storm Software - Stryke\n\n This code was released as part of the Stryke project. Stryke\n is maintained by Storm Software under the Apache-2.0 license, and is\n free for commercial and private use. For more information, please visit\n our licensing page at https://stormsoftware.com/licenses/projects/stryke.\n\n Website: https://stormsoftware.com\n Repository: https://github.com/storm-software/stryke\n Documentation: https://docs.stormsoftware.com/projects/stryke\n Contact: https://stormsoftware.com/contact\n\n SPDX-License-Identifier: Apache-2.0\n\n ------------------------------------------------------------------- */\n\nimport type { DeepKey, DeepValue } from \"@stryke/types\";\nimport { setField } from \"./set-field\";\n\n/**\n * Flattens a nested object into a single level object with dot-separated keys.\n *\n * @example\n * ```typescript\n * const nestedObject = {\n * a: {\n * b: {\n * c: 1\n * }\n * },\n * d: [2, 3]\n * };\n *\n * const flattened = flattenObject(nestedObject);\n * console.log(flattened);\n * // Output:\n * // {\n * // 'a.b.c': 1,\n * // 'd.0': 2,\n * // 'd.1': 3\n * // }\n * ```\n *\n * @param deepKeyObject - The object to flatten.\n * @returns - The flattened object.\n */\nexport function unflattenObject<\n TObject extends Record<string, any> = Record<string, any>,\n TDeepKeyObject extends {\n [TKey in DeepKey<TObject>]: DeepValue<TObject, TKey>;\n } = { [TKey in DeepKey<TObject>]: DeepValue<TObject, TKey> }\n>(deepKeyObject: TDeepKeyObject): TObject {\n return Object.entries(deepKeyObject).reduce(\n (ret: TObject, [key, value]: [string, any]) => {\n return setField<TObject>(ret, key as DeepKey<TObject>, value);\n },\n {} as TObject\n );\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAgDA,SAAgB,gBAKd,eAAwC;AACxC,QAAO,OAAO,QAAQ,cAAc,CAAC,QAClC,KAAc,CAAC,KAAK,WAA0B;AAC7C,SAAO,SAAkB,KAAK,KAAyB,MAAM;IAE/D,EAAE,CACH"}
1
+ {"version":3,"file":"unflatten-object.mjs","names":[],"sources":["../src/unflatten-object.ts"],"sourcesContent":["/* -------------------------------------------------------------------\n\n ⚡ Storm Software - Stryke\n\n This code was released as part of the Stryke project. Stryke\n is maintained by Storm Software under the Apache-2.0 license, and is\n free for commercial and private use. For more information, please visit\n our licensing page at https://stormsoftware.com/licenses/projects/stryke.\n\n Website: https://stormsoftware.com\n Repository: https://github.com/storm-software/stryke\n Documentation: https://docs.stormsoftware.com/projects/stryke\n Contact: https://stormsoftware.com/contact\n\n SPDX-License-Identifier: Apache-2.0\n\n ------------------------------------------------------------------- */\n\nimport type { DeepKey, DeepValue } from \"@stryke/types\";\nimport { setField } from \"./set-field\";\n\n/**\n * Flattens a nested object into a single level object with dot-separated keys.\n *\n * @example\n * ```typescript\n * const nestedObject = {\n * a: {\n * b: {\n * c: 1\n * }\n * },\n * d: [2, 3]\n * };\n *\n * const flattened = flattenObject(nestedObject);\n * console.log(flattened);\n * // Output:\n * // {\n * // 'a.b.c': 1,\n * // 'd.0': 2,\n * // 'd.1': 3\n * // }\n * ```\n *\n * @param deepKeyObject - The object to flatten.\n * @returns - The flattened object.\n */\nexport function unflattenObject<\n TObject extends Record<string, any> = Record<string, any>,\n TDeepKeyObject extends {\n [TKey in DeepKey<TObject>]: DeepValue<TObject, TKey>;\n } = { [TKey in DeepKey<TObject>]: DeepValue<TObject, TKey> }\n>(deepKeyObject: TDeepKeyObject): TObject {\n return Object.entries(deepKeyObject).reduce(\n (ret: TObject, [key, value]: [string, any]) => {\n return setField<TObject>(ret, key as DeepKey<TObject>, value);\n },\n {} as TObject\n );\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAgDA,SAAgB,gBAKd,eAAwC;AACxC,QAAO,OAAO,QAAQ,cAAc,CAAC,QAClC,KAAc,CAAC,KAAK,WAA0B;AAC7C,SAAO,SAAkB,KAAK,KAAyB,MAAM;IAE/D,EAAE,CACH"}
package/dist/union.cjs CHANGED
@@ -1,9 +1,7 @@
1
1
  Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
2
- const require_runtime = require('./_virtual/_rolldown/runtime.cjs');
3
2
  const require_get_unique = require('./get-unique.cjs');
4
3
 
5
4
  //#region src/union.ts
6
- var union_exports = /* @__PURE__ */ require_runtime.__exportAll({ union: () => union });
7
5
  /**
8
6
  * Creates an array of unique values from all given arrays.
9
7
  *
@@ -28,10 +26,4 @@ function union(arr1, arr2) {
28
26
  }
29
27
 
30
28
  //#endregion
31
- exports.union = union;
32
- Object.defineProperty(exports, 'union_exports', {
33
- enumerable: true,
34
- get: function () {
35
- return union_exports;
36
- }
37
- });
29
+ exports.union = union;
package/dist/union.mjs CHANGED
@@ -1,8 +1,6 @@
1
- import { __exportAll } from "./_virtual/_rolldown/runtime.mjs";
2
1
  import { getUnique } from "./get-unique.mjs";
3
2
 
4
3
  //#region src/union.ts
5
- var union_exports = /* @__PURE__ */ __exportAll({ union: () => union });
6
4
  /**
7
5
  * Creates an array of unique values from all given arrays.
8
6
  *
@@ -27,5 +25,5 @@ function union(arr1, arr2) {
27
25
  }
28
26
 
29
27
  //#endregion
30
- export { union, union_exports };
28
+ export { union };
31
29
  //# sourceMappingURL=union.mjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"union.mjs","names":[],"sources":["../src/union.ts"],"sourcesContent":["/* -------------------------------------------------------------------\n\n ⚡ Storm Software - Stryke\n\n This code was released as part of the Stryke project. Stryke\n is maintained by Storm Software under the Apache-2.0 license, and is\n free for commercial and private use. For more information, please visit\n our licensing page at https://stormsoftware.com/licenses/projects/stryke.\n\n Website: https://stormsoftware.com\n Repository: https://github.com/storm-software/stryke\n Documentation: https://docs.stormsoftware.com/projects/stryke\n Contact: https://stormsoftware.com/contact\n\n SPDX-License-Identifier: Apache-2.0\n\n ------------------------------------------------------------------- */\n\nimport { getUnique } from \"./get-unique\";\n\n/**\n * Creates an array of unique values from all given arrays.\n *\n * @remarks\n * This function takes two arrays, merges them into a single array, and returns a new array\n * containing only the unique values from the merged array.\n *\n * @example\n * ```ts\n * const array1 = [1, 2, 3];\n * const array2 = [3, 4, 5];\n * const result = union(array1, array2);\n * // result will be [1, 2, 3, 4, 5]\n * ```\n *\n * @param arr1 - The first array to merge and filter for unique values.\n * @param arr2 - The second array to merge and filter for unique values.\n * @returns A new array of unique values.\n */\nexport function union<T>(arr1: readonly T[], arr2: readonly T[]): T[] {\n return getUnique([...arr1, ...arr2]);\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;AAuCA,SAAgB,MAAS,MAAoB,MAAyB;AACpE,QAAO,UAAU,CAAC,GAAG,MAAM,GAAG,KAAK,CAAC"}
1
+ {"version":3,"file":"union.mjs","names":[],"sources":["../src/union.ts"],"sourcesContent":["/* -------------------------------------------------------------------\n\n ⚡ Storm Software - Stryke\n\n This code was released as part of the Stryke project. Stryke\n is maintained by Storm Software under the Apache-2.0 license, and is\n free for commercial and private use. For more information, please visit\n our licensing page at https://stormsoftware.com/licenses/projects/stryke.\n\n Website: https://stormsoftware.com\n Repository: https://github.com/storm-software/stryke\n Documentation: https://docs.stormsoftware.com/projects/stryke\n Contact: https://stormsoftware.com/contact\n\n SPDX-License-Identifier: Apache-2.0\n\n ------------------------------------------------------------------- */\n\nimport { getUnique } from \"./get-unique\";\n\n/**\n * Creates an array of unique values from all given arrays.\n *\n * @remarks\n * This function takes two arrays, merges them into a single array, and returns a new array\n * containing only the unique values from the merged array.\n *\n * @example\n * ```ts\n * const array1 = [1, 2, 3];\n * const array2 = [3, 4, 5];\n * const result = union(array1, array2);\n * // result will be [1, 2, 3, 4, 5]\n * ```\n *\n * @param arr1 - The first array to merge and filter for unique values.\n * @param arr2 - The second array to merge and filter for unique values.\n * @returns A new array of unique values.\n */\nexport function union<T>(arr1: readonly T[], arr2: readonly T[]): T[] {\n return getUnique([...arr1, ...arr2]);\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;AAuCA,SAAgB,MAAS,MAAoB,MAAyB;AACpE,QAAO,UAAU,CAAC,GAAG,MAAM,GAAG,KAAK,CAAC"}