@synnaxlabs/x 0.49.3 → 0.52.3

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 (240) hide show
  1. package/.turbo/turbo-build.log +10 -10
  2. package/dist/eslint.config.d.ts +2 -2
  3. package/dist/eslint.config.d.ts.map +1 -1
  4. package/dist/src/color/color.d.ts +26 -2
  5. package/dist/src/color/color.d.ts.map +1 -1
  6. package/dist/src/color/gradient.d.ts +10 -0
  7. package/dist/src/color/gradient.d.ts.map +1 -1
  8. package/dist/src/color/palette.d.ts +22 -2
  9. package/dist/src/color/palette.d.ts.map +1 -1
  10. package/dist/src/index.d.ts +0 -1
  11. package/dist/src/index.d.ts.map +1 -1
  12. package/dist/src/kv/types.d.ts.map +1 -1
  13. package/dist/src/label/label.d.ts +15 -1
  14. package/dist/src/label/label.d.ts.map +1 -1
  15. package/dist/src/record/record.d.ts +23 -9
  16. package/dist/src/record/record.d.ts.map +1 -1
  17. package/dist/src/status/status.d.ts +5 -0
  18. package/dist/src/status/status.d.ts.map +1 -1
  19. package/dist/src/sync/mutex.d.ts +3 -3
  20. package/dist/src/zod/util.d.ts +2 -0
  21. package/dist/src/zod/util.d.ts.map +1 -1
  22. package/dist/x.cjs +11 -8
  23. package/dist/x.js +1106 -1129
  24. package/eslint.config.ts +3 -3
  25. package/package.json +9 -8
  26. package/src/array/external.ts +1 -1
  27. package/src/array/index.ts +1 -1
  28. package/src/array/nullable.ts +1 -1
  29. package/src/array/toArray.spec.ts +1 -1
  30. package/src/array/toArray.ts +1 -1
  31. package/src/array/update.spec.ts +1 -1
  32. package/src/array/update.ts +1 -1
  33. package/src/binary/codec.spec.ts +1 -1
  34. package/src/binary/codec.ts +1 -1
  35. package/src/binary/index.ts +1 -1
  36. package/src/breaker/breaker.spec.ts +1 -1
  37. package/src/breaker/breaker.ts +1 -1
  38. package/src/breaker/index.ts +1 -1
  39. package/src/caseconv/caseconv.spec.ts +1 -1
  40. package/src/caseconv/caseconv.ts +1 -1
  41. package/src/caseconv/index.ts +1 -1
  42. package/src/change/change.ts +1 -1
  43. package/src/change/index.ts +1 -1
  44. package/src/clamp/clamp.ts +1 -1
  45. package/src/color/color.spec.ts +27 -2
  46. package/src/color/color.ts +10 -4
  47. package/src/color/external.ts +1 -1
  48. package/src/color/gradient.ts +1 -1
  49. package/src/color/index.ts +1 -1
  50. package/src/color/palette.ts +1 -1
  51. package/src/compare/binary.spec.ts +1 -1
  52. package/src/compare/binary.ts +1 -1
  53. package/src/compare/compare.spec.ts +1 -1
  54. package/src/compare/compare.ts +1 -1
  55. package/src/compare/external.ts +1 -1
  56. package/src/compare/index.ts +1 -1
  57. package/src/control/control.ts +1 -1
  58. package/src/control/index.ts +1 -1
  59. package/src/csv/csv.spec.ts +1 -1
  60. package/src/csv/csv.ts +1 -1
  61. package/src/csv/index.ts +1 -1
  62. package/src/debounce/debounce.spec.ts +1 -1
  63. package/src/debounce/debounce.ts +1 -1
  64. package/src/debounce/index.ts +1 -1
  65. package/src/deep/copy.spec.ts +1 -1
  66. package/src/deep/copy.ts +1 -1
  67. package/src/deep/difference.spec.ts +1 -1
  68. package/src/deep/difference.ts +1 -1
  69. package/src/deep/equal.spec.ts +1 -1
  70. package/src/deep/equal.ts +1 -1
  71. package/src/deep/external.ts +1 -1
  72. package/src/deep/get.bench.ts +1 -1
  73. package/src/deep/get.spec.ts +1 -1
  74. package/src/deep/get.ts +1 -1
  75. package/src/deep/index.ts +1 -1
  76. package/src/deep/join.ts +1 -1
  77. package/src/deep/merge.spec.ts +1 -1
  78. package/src/deep/merge.ts +1 -1
  79. package/src/deep/partial.spec.ts +1 -1
  80. package/src/deep/partial.ts +1 -1
  81. package/src/deep/path.spec.ts +1 -1
  82. package/src/deep/path.ts +1 -1
  83. package/src/deep/remove.bench.ts +1 -1
  84. package/src/deep/remove.spec.ts +1 -1
  85. package/src/deep/remove.ts +1 -1
  86. package/src/deep/set.bench.ts +1 -1
  87. package/src/deep/set.spec.ts +1 -1
  88. package/src/deep/set.ts +1 -1
  89. package/src/destructor/destructor.ts +1 -1
  90. package/src/destructor/index.ts +1 -1
  91. package/src/errors/errors.spec.ts +1 -1
  92. package/src/errors/errors.ts +1 -1
  93. package/src/errors/index.ts +1 -1
  94. package/src/id/id.spec.ts +1 -1
  95. package/src/id/id.ts +1 -1
  96. package/src/id/index.ts +1 -1
  97. package/src/index.ts +1 -2
  98. package/src/instance/index.ts +1 -1
  99. package/src/instance/matcher.spec.ts +1 -1
  100. package/src/instance/matcher.ts +1 -1
  101. package/src/kv/external.ts +1 -1
  102. package/src/kv/index.ts +1 -1
  103. package/src/kv/mock.spec.ts +1 -1
  104. package/src/kv/mock.ts +1 -1
  105. package/src/kv/types.ts +2 -4
  106. package/src/label/index.ts +1 -1
  107. package/src/label/label.ts +4 -2
  108. package/src/link/index.ts +1 -1
  109. package/src/link/link.spec.ts +1 -1
  110. package/src/link/link.ts +1 -1
  111. package/src/map/index.ts +1 -1
  112. package/src/map/map.spec.ts +1 -1
  113. package/src/map/map.ts +1 -1
  114. package/src/math/constants.ts +1 -1
  115. package/src/math/external.ts +1 -1
  116. package/src/math/index.ts +1 -1
  117. package/src/math/math.spec.ts +1 -1
  118. package/src/math/math.ts +1 -1
  119. package/src/math/round.spec.ts +1 -1
  120. package/src/math/round.ts +1 -1
  121. package/src/migrate/index.ts +1 -1
  122. package/src/migrate/migrate.spec.ts +1 -1
  123. package/src/migrate/migrate.ts +5 -5
  124. package/src/mock/MockGLBufferController.ts +1 -1
  125. package/src/narrow/index.ts +1 -1
  126. package/src/narrow/narrow.spec.ts +1 -1
  127. package/src/narrow/narrow.ts +1 -1
  128. package/src/notation/index.ts +1 -1
  129. package/src/notation/notation.spec.ts +1 -1
  130. package/src/notation/notation.ts +1 -1
  131. package/src/numeric/index.ts +1 -1
  132. package/src/numeric/numeric.ts +1 -1
  133. package/src/observe/index.ts +1 -1
  134. package/src/observe/observe.ts +1 -1
  135. package/src/observe/obsever.spec.ts +1 -1
  136. package/src/optional/index.ts +1 -1
  137. package/src/optional/optional.ts +1 -1
  138. package/src/primitive/index.ts +1 -1
  139. package/src/primitive/primitive.spec.ts +1 -1
  140. package/src/primitive/primitive.ts +1 -1
  141. package/src/record/index.ts +1 -1
  142. package/src/record/record.spec.ts +32 -18
  143. package/src/record/record.ts +30 -14
  144. package/src/runtime/detect.ts +1 -1
  145. package/src/runtime/external.ts +1 -1
  146. package/src/runtime/index.ts +1 -1
  147. package/src/runtime/os.ts +1 -1
  148. package/src/scheduler/index.ts +1 -1
  149. package/src/scheduler/scheduler.spec.ts +1 -1
  150. package/src/scheduler/scheduler.ts +1 -1
  151. package/src/shallow/copy.spec.ts +1 -1
  152. package/src/shallow/copy.ts +1 -1
  153. package/src/shallow/index.ts +1 -1
  154. package/src/singleton/define.spec.ts +1 -1
  155. package/src/singleton/define.ts +1 -1
  156. package/src/singleton/index.ts +1 -1
  157. package/src/sleep/index.ts +1 -1
  158. package/src/sleep/sleep.ts +1 -1
  159. package/src/spatial/base.ts +1 -1
  160. package/src/spatial/bounds/bounds.spec.ts +1 -1
  161. package/src/spatial/bounds/bounds.ts +1 -1
  162. package/src/spatial/bounds/index.ts +1 -1
  163. package/src/spatial/box/box.spec.ts +1 -1
  164. package/src/spatial/box/box.ts +1 -1
  165. package/src/spatial/box/index.ts +1 -1
  166. package/src/spatial/dimensions/dimensions.spec.ts +1 -1
  167. package/src/spatial/dimensions/dimensions.ts +1 -1
  168. package/src/spatial/dimensions/index.ts +1 -1
  169. package/src/spatial/direction/direction.spec.ts +1 -1
  170. package/src/spatial/direction/direction.ts +1 -1
  171. package/src/spatial/direction/index.ts +1 -1
  172. package/src/spatial/external.ts +1 -1
  173. package/src/spatial/index.ts +1 -1
  174. package/src/spatial/location/index.ts +1 -1
  175. package/src/spatial/location/location.spec.ts +1 -1
  176. package/src/spatial/location/location.ts +1 -1
  177. package/src/spatial/scale/index.ts +1 -1
  178. package/src/spatial/scale/scale.spec.ts +1 -1
  179. package/src/spatial/scale/scale.ts +1 -1
  180. package/src/spatial/spatial.ts +1 -1
  181. package/src/spatial/sticky/index.ts +1 -1
  182. package/src/spatial/sticky/sticky.spec.ts +1 -1
  183. package/src/spatial/sticky/sticky.ts +1 -1
  184. package/src/spatial/xy/index.ts +1 -1
  185. package/src/spatial/xy/xy.spec.ts +1 -1
  186. package/src/spatial/xy/xy.ts +1 -1
  187. package/src/status/index.ts +1 -1
  188. package/src/status/status.spec.ts +168 -1
  189. package/src/status/status.ts +47 -1
  190. package/src/strings/deduplicateFileName.spec.ts +1 -1
  191. package/src/strings/deduplicateFileName.ts +1 -1
  192. package/src/strings/external.ts +1 -1
  193. package/src/strings/index.ts +1 -1
  194. package/src/strings/strings.spec.ts +1 -1
  195. package/src/strings/strings.ts +1 -1
  196. package/src/sync/index.ts +1 -1
  197. package/src/sync/mutex.ts +4 -4
  198. package/src/telem/gl.ts +1 -1
  199. package/src/telem/index.ts +1 -1
  200. package/src/telem/series.spec.ts +1 -1
  201. package/src/telem/series.ts +4 -4
  202. package/src/telem/telem.spec.ts +1 -1
  203. package/src/telem/telem.ts +1 -1
  204. package/src/testutil/index.ts +1 -1
  205. package/src/testutil/testutil.spec.ts +1 -1
  206. package/src/testutil/testutil.ts +1 -1
  207. package/src/types/index.ts +1 -1
  208. package/src/unique/index.ts +1 -1
  209. package/src/unique/unique.spec.ts +1 -1
  210. package/src/unique/unique.ts +1 -1
  211. package/src/url/index.ts +1 -1
  212. package/src/url/url.spec.ts +1 -1
  213. package/src/url/url.ts +1 -1
  214. package/src/uuid/index.ts +1 -1
  215. package/src/uuid/uuid.spec.ts +1 -1
  216. package/src/uuid/uuid.ts +1 -1
  217. package/src/worker/index.ts +1 -1
  218. package/src/worker/worker.spec.ts +1 -1
  219. package/src/worker/worker.ts +1 -1
  220. package/src/zod/external.ts +1 -1
  221. package/src/zod/index.ts +1 -1
  222. package/src/zod/nullToUndefined.spec.ts +1 -1
  223. package/src/zod/nullToUndefined.ts +1 -1
  224. package/src/zod/schemas.spec.ts +1 -1
  225. package/src/zod/schemas.ts +1 -1
  226. package/src/zod/toArray.spec.ts +1 -1
  227. package/src/zod/toArray.ts +1 -1
  228. package/src/zod/util.spec.ts +31 -1
  229. package/src/zod/util.ts +14 -1
  230. package/tsconfig.tsbuildinfo +1 -1
  231. package/vite.config.ts +1 -2
  232. package/dist/src/jsonrpc/index.d.ts +0 -2
  233. package/dist/src/jsonrpc/index.d.ts.map +0 -1
  234. package/dist/src/jsonrpc/jsonrpc.d.ts +0 -70
  235. package/dist/src/jsonrpc/jsonrpc.d.ts.map +0 -1
  236. package/dist/src/jsonrpc/jsonrpc.spec.d.ts +0 -2
  237. package/dist/src/jsonrpc/jsonrpc.spec.d.ts.map +0 -1
  238. package/src/jsonrpc/index.ts +0 -10
  239. package/src/jsonrpc/jsonrpc.spec.ts +0 -135
  240. package/src/jsonrpc/jsonrpc.ts +0 -125
package/dist/x.js CHANGED
@@ -1,67 +1,67 @@
1
- import b, { z as c } from "zod";
2
- const dn = (e) => b.union([
3
- b.union([b.null(), b.undefined()]).transform(() => []),
1
+ import k, { z as c } from "zod";
2
+ const gn = (e) => k.union([
3
+ k.union([k.null(), k.undefined()]).transform(() => []),
4
4
  e.array()
5
- ]), zr = (e) => Array.isArray(e) ? e : e == null ? [] : [e], gn = (e, t) => {
5
+ ]), Vr = (e) => Array.isArray(e) ? e : e == null ? [] : [e], yn = (e, t) => {
6
6
  if (Array.isArray(t))
7
- return t.reduce((s, i) => gn(s, i), e ?? []);
7
+ return t.reduce((s, i) => yn(s, i), e ?? []);
8
8
  if (e == null) return [t];
9
9
  const n = e.findIndex((s) => s == t), r = [...e];
10
10
  return n === -1 ? r.push(t) : r[n] = t, r;
11
- }, Yr = ((e, t) => {
11
+ }, Wr = ((e, t) => {
12
12
  if (e != null)
13
13
  return Array.isArray(t) ? e.filter((n) => !t.includes(n)) : e.filter((n) => n != t);
14
- }), yn = (e, t) => {
14
+ }), mn = (e, t) => {
15
15
  if (Array.isArray(t))
16
- return t.reduce((s, i) => yn(s, i), e ?? []);
16
+ return t.reduce((s, i) => mn(s, i), e ?? []);
17
17
  if (e == null) return [t];
18
18
  const n = e.findIndex((s) => s.key === t.key), r = [...e];
19
19
  return n === -1 ? r.push(t) : r[n] = t, r;
20
- }, Gr = ((e, t) => {
20
+ }, zr = ((e, t) => {
21
21
  if (e != null)
22
22
  return Array.isArray(t) ? e.filter((n) => !t.includes(n.key)) : e.filter((n) => n.key !== t);
23
- }), fu = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
23
+ }), uu = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
24
24
  __proto__: null,
25
- nullableZ: dn,
26
- remove: Yr,
27
- removeKeyed: Gr,
28
- toArray: zr,
29
- upsert: gn,
30
- upsertKeyed: yn
31
- }, Symbol.toStringTag, { value: "Module" })), Hr = (e) => {
25
+ nullableZ: gn,
26
+ remove: Wr,
27
+ removeKeyed: zr,
28
+ toArray: Vr,
29
+ upsert: yn,
30
+ upsertKeyed: mn
31
+ }, Symbol.toStringTag, { value: "Module" })), Yr = (e) => {
32
32
  const t = e.replace(/_[a-z]/g, (n) => n[1].toUpperCase());
33
33
  return t.length > 1 && t[0] === t[0].toUpperCase() && t[1] === t[1].toUpperCase() || t.length === 0 ? t : t[0].toLowerCase() + t.slice(1);
34
- }, zt = (e) => {
34
+ }, Yt = (e) => {
35
35
  const t = (n, r = oe) => {
36
36
  if (typeof n == "string") return e(n);
37
37
  if (Array.isArray(n)) return n.map((o) => t(o, r));
38
38
  if (!ee(n)) return n;
39
- r = Xr(r);
39
+ r = Dr(r);
40
40
  const s = {}, i = n;
41
41
  return "toJSON" in i && typeof i.toJSON == "function" ? t(i.toJSON(), r) : (Object.keys(i).forEach((o) => {
42
42
  let a = i[o];
43
43
  const u = e(o);
44
- r.recursive && (ee(a) ? rn(a) || (a = t(a, r)) : r.recursiveInArray && nn(a) && (a = [...a].map((l) => {
44
+ r.recursive && (ee(a) ? sn(a) || (a = t(a, r)) : r.recursiveInArray && rn(a) && (a = [...a].map((l) => {
45
45
  let h = l;
46
- return ee(l) ? rn(h) || (h = t(l, r)) : nn(l) && (h = t({ key: l }, r).key), h;
46
+ return ee(l) ? sn(h) || (h = t(l, r)) : rn(l) && (h = t({ key: l }, r).key), h;
47
47
  }))), s[u] = a;
48
48
  }), s);
49
49
  };
50
50
  return t;
51
- }, Ae = zt(Hr), Dr = (e) => (
51
+ }, Ae = Yt(Yr), Gr = (e) => (
52
52
  // Don't convert the first character and don't convert a character that is after a
53
53
  // non-alphanumeric character
54
54
  e.replace(
55
55
  /([a-z0-9])([A-Z])/g,
56
56
  (t, n, r) => `${n}_${r.toLowerCase()}`
57
57
  )
58
- ), mn = zt(Dr), pn = (e) => e.length === 0 ? e : e[0].toUpperCase() + e.slice(1), Jr = [Number, String, Uint8Array], oe = {
58
+ ), pn = Yt(Gr), bn = (e) => e.length === 0 ? e : e[0].toUpperCase() + e.slice(1), Hr = [Number, String, Uint8Array], oe = {
59
59
  recursive: !0,
60
60
  recursiveInArray: !0
61
- }, Xr = (e = oe) => (e.recursive == null ? e = oe : e.recursiveInArray ??= !1, e), nn = (e) => e != null && Array.isArray(e), ee = (e) => e != null && typeof e == "object" && !Array.isArray(e), rn = (e) => Jr.some((t) => e instanceof t), Kr = (e) => e.replace(/[\s_]+/g, "-").replace(
61
+ }, Dr = (e = oe) => (e.recursive == null ? e = oe : e.recursiveInArray ??= !1, e), rn = (e) => e != null && Array.isArray(e), ee = (e) => e != null && typeof e == "object" && !Array.isArray(e), sn = (e) => Hr.some((t) => e instanceof t), Jr = (e) => e.replace(/[\s_]+/g, "-").replace(
62
62
  /([a-z0-9])([A-Z])/g,
63
63
  (t, n, r) => `${n}-${r.toLowerCase()}`
64
- ).toLowerCase(), Qr = zt(Kr), ts = (e) => {
64
+ ).toLowerCase(), Xr = Yt(Jr), Kr = (e) => {
65
65
  if (e.length === 0) return e;
66
66
  let t = e.replace(/[_-]/g, " ");
67
67
  return t = t.replace(
@@ -71,18 +71,18 @@ const dn = (e) => b.union([
71
71
  /([A-Z]+)([A-Z][a-z])/g,
72
72
  (n, r, s) => `${r} ${s}`
73
73
  ), t = t.replace(/\s+/g, " ").trim(), t = t.replace(/\b\w/g, (n) => n.toUpperCase()), t;
74
- }, es = zt(ts), hu = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
74
+ }, Qr = Yt(Kr), lu = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
75
75
  __proto__: null,
76
- camelToSnake: mn,
77
- capitalize: pn,
76
+ camelToSnake: pn,
77
+ capitalize: bn,
78
78
  snakeToCamel: Ae,
79
- toKebab: Qr,
80
- toProperNoun: es
81
- }, Symbol.toStringTag, { value: "Module" })), pt = (e) => e != null && typeof e == "object" && !Array.isArray(e), du = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
79
+ toKebab: Xr,
80
+ toProperNoun: Qr
81
+ }, Symbol.toStringTag, { value: "Module" })), at = (e) => e != null && typeof e == "object" && !Array.isArray(e), fu = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
82
82
  __proto__: null,
83
- isObject: pt
83
+ isObject: at
84
84
  }, Symbol.toStringTag, { value: "Module" }));
85
- class bn {
85
+ class wn {
86
86
  contentType = "application/json";
87
87
  decoder;
88
88
  encoder;
@@ -100,11 +100,11 @@ class bn {
100
100
  return n != null ? n.parse(s) : s;
101
101
  }
102
102
  encodeString(t) {
103
- const n = mn(t);
103
+ const n = pn(t);
104
104
  return JSON.stringify(n, (r, s) => ArrayBuffer.isView(s) ? Array.from(s) : typeof s == "bigint" ? s.toString() : s);
105
105
  }
106
106
  }
107
- class wn {
107
+ class On {
108
108
  contentType = "text/csv";
109
109
  encode(t) {
110
110
  const n = this.encodeString(t);
@@ -115,7 +115,7 @@ class wn {
115
115
  return this.decodeString(r, n);
116
116
  }
117
117
  encodeString(t) {
118
- if (!Array.isArray(t) || t.length === 0 || !pt(t[0]))
118
+ if (!Array.isArray(t) || t.length === 0 || !at(t[0]))
119
119
  throw new Error("Payload must be an array of objects");
120
120
  const n = Object.keys(t[0]), r = [n.join(",")];
121
121
  return t.forEach((s) => {
@@ -146,7 +146,7 @@ class wn {
146
146
  return isNaN(n) ? t.startsWith('"') && t.endsWith('"') ? t.slice(1, -1) : t : n;
147
147
  }
148
148
  }
149
- class On {
149
+ class xn {
150
150
  contentType = "text/plain";
151
151
  encode(t) {
152
152
  if (typeof t != "string")
@@ -158,17 +158,17 @@ class On {
158
158
  return n != null ? n.parse(r) : r;
159
159
  }
160
160
  }
161
- const at = new bn(), ns = new wn(), rs = new On(), ss = [at], gu = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
161
+ const xt = new wn(), ts = new On(), es = new xn(), ns = [xt], hu = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
162
162
  __proto__: null,
163
- CSVCodec: wn,
164
- CSV_CODEC: ns,
165
- ENCODERS: ss,
166
- JSONCodec: bn,
167
- JSON_CODEC: at,
168
- TEXT_CODEC: rs,
169
- TextCodec: On
170
- }, Symbol.toStringTag, { value: "Module" })), B = (e) => e != null && typeof e == "object" && "value" in e;
171
- class rt {
163
+ CSVCodec: On,
164
+ CSV_CODEC: ts,
165
+ ENCODERS: ns,
166
+ JSONCodec: wn,
167
+ JSON_CODEC: xt,
168
+ TEXT_CODEC: es,
169
+ TextCodec: xn
170
+ }, Symbol.toStringTag, { value: "Module" })), C = (e) => e != null && typeof e == "object" && "value" in e;
171
+ class st {
172
172
  /** The underlying primitive value */
173
173
  value;
174
174
  constructor(t) {
@@ -188,7 +188,7 @@ class rt {
188
188
  return this.value.toString();
189
189
  }
190
190
  }
191
- const Ee = (e) => e != null && typeof e == "object" && "toString" in e, xn = (e) => {
191
+ const Ee = (e) => e != null && typeof e == "object" && "toString" in e, In = (e) => {
192
192
  if (Ee(e)) return e?.toString().length === 0;
193
193
  switch (typeof e) {
194
194
  case "string":
@@ -206,14 +206,14 @@ const Ee = (e) => e != null && typeof e == "object" && "toString" in e, xn = (e)
206
206
  default:
207
207
  return !1;
208
208
  }
209
- }, is = (e) => !xn(e), yu = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
209
+ }, rs = (e) => !In(e), du = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
210
210
  __proto__: null,
211
- ValueExtension: rt,
212
- isCrudeValueExtension: B,
213
- isNonZero: is,
211
+ ValueExtension: st,
212
+ isCrudeValueExtension: C,
213
+ isNonZero: rs,
214
214
  isStringer: Ee,
215
- isZero: xn
216
- }, Symbol.toStringTag, { value: "Module" })), ce = (e) => [...new Set(e)], os = (e, t, n = !0) => {
215
+ isZero: In
216
+ }, Symbol.toStringTag, { value: "Module" })), ce = (e) => [...new Set(e)], ss = (e, t, n = !0) => {
217
217
  const r = /* @__PURE__ */ new Map();
218
218
  return e.forEach((s) => {
219
219
  const i = t(s);
@@ -223,9 +223,9 @@ const Ee = (e) => e != null && typeof e == "object" && "toString" in e, xn = (e)
223
223
  }
224
224
  r.set(i, s);
225
225
  }), Array.from(r.values());
226
- }, mu = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
226
+ }, gu = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
227
227
  __proto__: null,
228
- by: os,
228
+ by: ss,
229
229
  unique: ce
230
230
  }, Symbol.toStringTag, { value: "Module" })), At = (e, t = !1) => {
231
231
  const n = Ee(e) ? "stringer" : typeof e;
@@ -252,19 +252,19 @@ const Ee = (e) => e != null && typeof e == "object" && "toString" in e, xn = (e)
252
252
  default:
253
253
  return console.warn(`sortFunc: unknown type ${n}`), () => -1;
254
254
  }
255
- return t ? Nn(r) : r;
256
- }, cs = (e, t, n) => {
255
+ return t ? vn(r) : r;
256
+ }, is = (e, t, n) => {
257
257
  const r = At(t[e], n);
258
258
  return (s, i) => r(s[e], i[e]);
259
- }, as = (e, t) => e.length !== t.length ? e.length - t.length : e.every((n, r) => n === t[r]) ? 0 : -1, In = (e, t) => {
259
+ }, os = (e, t) => e.length !== t.length ? e.length - t.length : e.every((n, r) => n === t[r]) ? 0 : -1, Nn = (e, t) => {
260
260
  if (e.length !== t.length) return e.length - t.length;
261
261
  if (e.length === 0) return 0;
262
262
  const n = At(e[0]), r = [...e].sort(n), s = [...t].sort(n);
263
263
  return r.every((i, o) => i === s[o]) ? 0 : -1;
264
- }, us = (e, t) => {
264
+ }, cs = (e, t) => {
265
265
  const n = ce(e), r = ce(t);
266
- return In(n, r);
267
- }, ls = (e, t) => e === t ? 0 : e === "first" && t === "last" ? 1 : -1, Nn = (e) => (t, n) => e(n, t), st = 0, z = -1, Y = 1, vn = (e) => e < st, Mn = (e) => e > st, fs = (e) => e >= st, An = (e) => e === st, hs = (e, t) => {
266
+ return Nn(n, r);
267
+ }, as = (e, t) => e === t ? 0 : e === "first" && t === "last" ? 1 : -1, vn = (e) => (t, n) => e(n, t), it = 0, z = -1, Y = 1, Mn = (e) => e < it, An = (e) => e > it, us = (e) => e >= it, En = (e) => e === it, ls = (e, t) => {
268
268
  const n = /([a-zA-Z]+)|(\d+)/g, r = e.replace(/[\s_.-]+/g, "").match(n), s = t.replace(/[\s_.-]+/g, "").match(n);
269
269
  if (!r || !s) return 0;
270
270
  for (let i = 0; i < Math.min(r.length, s.length); i++) {
@@ -278,7 +278,7 @@ const Ee = (e) => e != null && typeof e == "object" && "toString" in e, xn = (e)
278
278
  } else return isNaN(Number(o)) ? -1 : 1;
279
279
  }
280
280
  return r.length - s.length;
281
- }, En = (e, t, n) => {
281
+ }, Sn = (e, t, n) => {
282
282
  let r = 0, s = e.length;
283
283
  const i = n ?? At(t);
284
284
  for (; r < s; ) {
@@ -287,60 +287,60 @@ const Ee = (e) => e != null && typeof e == "object" && "toString" in e, xn = (e)
287
287
  a < 0 ? r = o + 1 : s = o;
288
288
  }
289
289
  return r;
290
- }, ds = (e, t, n) => {
291
- const r = En(e, t, n);
290
+ }, fs = (e, t, n) => {
291
+ const r = Sn(e, t, n);
292
292
  e.splice(r, 0, t);
293
- }, pu = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
293
+ }, yu = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
294
294
  __proto__: null,
295
- EQUAL: st,
295
+ EQUAL: it,
296
296
  GREATER_THAN: Y,
297
297
  LESS_THAN: z,
298
- insert: ds,
299
- isEqualTo: An,
300
- isGreaterThan: Mn,
301
- isGreaterThanEqual: fs,
302
- isLessThan: vn,
298
+ insert: fs,
299
+ isEqualTo: En,
300
+ isGreaterThan: An,
301
+ isGreaterThanEqual: us,
302
+ isLessThan: Mn,
303
303
  newF: At,
304
- newFieldF: cs,
305
- order: ls,
306
- primitiveArrays: as,
307
- reverseF: Nn,
308
- search: En,
309
- stringsWithNumbers: hs,
310
- uniqueUnorderedPrimitiveArrays: us,
311
- unorderedPrimitiveArrays: In
304
+ newFieldF: is,
305
+ order: as,
306
+ primitiveArrays: os,
307
+ reverseF: vn,
308
+ search: Sn,
309
+ stringsWithNumbers: ls,
310
+ uniqueUnorderedPrimitiveArrays: cs,
311
+ unorderedPrimitiveArrays: Nn
312
312
  }, Symbol.toStringTag, { value: "Module" }));
313
- let Sn = (e, t = 21) => (n = t) => {
313
+ let Tn = (e, t = 21) => (n = t) => {
314
314
  let r = "", s = n | 0;
315
315
  for (; s--; )
316
316
  r += e[Math.random() * e.length | 0];
317
317
  return r;
318
318
  };
319
- const Tn = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz", gs = `0123456789${Tn}`, $n = 11, ys = Sn(Tn, 1), ms = Sn(gs, $n - 1), Se = () => `${ys()}${ms()}`, bu = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
319
+ const $n = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz", hs = `0123456789${$n}`, Un = 11, ds = Tn($n, 1), gs = Tn(hs, Un - 1), Se = () => `${ds()}${gs()}`, mu = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
320
320
  __proto__: null,
321
- LENGTH: $n,
321
+ LENGTH: Un,
322
322
  create: Se
323
- }, Symbol.toStringTag, { value: "Module" })), Un = (e, t) => (n) => n instanceof t || typeof n == "object" && n !== null && "discriminator" in n && n.discriminator === e, wu = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
323
+ }, Symbol.toStringTag, { value: "Module" })), jn = (e, t) => (n) => n instanceof t || typeof n == "object" && n !== null && "discriminator" in n && n.discriminator === e, pu = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
324
324
  __proto__: null,
325
- createMatcher: Un
326
- }, Symbol.toStringTag, { value: "Module" })), ps = 2 ** 8 - 1, jn = 2 ** 12 - 1, bs = 2 ** 16 - 1, ws = 2 ** 32 - 1, Os = 2n ** 64n - 1n, xs = 2 ** 64 - 1, Is = -128, Ns = 2 ** 7 - 1, vs = -32768, Ms = 2 ** 15 - 1, As = -2147483648, Es = 2 ** 31 - 1, Ss = -(2n ** 63n), _t = 2n ** 63n - 1n, Ts = -9223372036854776e3, Cn = 2 ** 63 - 1, lt = (e) => (t, n) => {
325
+ createMatcher: jn
326
+ }, Symbol.toStringTag, { value: "Module" })), ys = 2 ** 8 - 1, Cn = 2 ** 12 - 1, ms = 2 ** 16 - 1, ps = 2 ** 32 - 1, bs = 2n ** 64n - 1n, ws = 2 ** 64 - 1, Os = -128, xs = 2 ** 7 - 1, Is = -32768, Ns = 2 ** 15 - 1, vs = -2147483648, Ms = 2 ** 31 - 1, As = -(2n ** 63n), qt = 2n ** 63n - 1n, Es = -9223372036854776e3, Bn = 2 ** 63 - 1, lt = (e) => (t, n) => {
327
327
  if (typeof t == "bigint") {
328
- if (qt(n))
328
+ if (Ft(n))
329
329
  return e(t, BigInt(n));
330
330
  const r = e(Number(t), Number(n));
331
331
  return typeof r == "number" ? BigInt(Math.round(r)) : r;
332
332
  }
333
333
  return e(Number(t), Number(n));
334
- }, F = lt((e, t) => e - t), G = lt((e, t) => e + t), $s = (e, t, n = 1e-4) => Math.abs(e - t) < n, ae = (e, t) => {
334
+ }, F = lt((e, t) => e - t), G = lt((e, t) => e + t), Ss = (e, t, n = 1e-4) => Math.abs(e - t) < n, ae = (e, t) => {
335
335
  const n = typeof e == "bigint", r = typeof t == "bigint";
336
- return n && r ? e === t : n && qt(t) ? e === BigInt(t) : r && qt(e) ? t === BigInt(e) : e === t;
337
- }, Us = (e) => {
336
+ return n && r ? e === t : n && Ft(t) ? e === BigInt(t) : r && Ft(e) ? t === BigInt(e) : e === t;
337
+ }, Ts = (e) => {
338
338
  const t = 10 ** Math.floor(Math.log10(e));
339
339
  return Math.round(e / t) * t;
340
- }, Bn = lt((e, t) => e <= t ? e : t), qt = (e) => typeof e == "bigint" ? !0 : Number.isInteger(e), js = lt((e, t) => e >= t ? e : t), Rn = (e) => typeof e == "bigint" ? e < 0n ? -e : e : e < 0 ? -e : e, L = lt((e, t) => e * t), Et = lt((e, t) => e / t), Pn = c.tuple([c.number(), c.number()]), Te = c.object({ width: c.number(), height: c.number() }), Cs = c.object({
340
+ }, Pn = lt((e, t) => e <= t ? e : t), Ft = (e) => typeof e == "bigint" ? !0 : Number.isInteger(e), $s = lt((e, t) => e >= t ? e : t), Rn = (e) => typeof e == "bigint" ? e < 0n ? -e : e : e < 0 ? -e : e, R = lt((e, t) => e * t), Et = lt((e, t) => e / t), kn = c.tuple([c.number(), c.number()]), Te = c.object({ width: c.number(), height: c.number() }), Us = c.object({
341
341
  signedWidth: c.number(),
342
342
  signedHeight: c.number()
343
- }), Ln = ["start", "center", "end"], ut = c.object({ x: c.number(), y: c.number() }), kn = c.object({ clientX: c.number(), clientY: c.number() }), Yt = ["x", "y"], $e = c.enum(Yt), Ue = ["top", "right", "bottom", "left"], Bs = c.enum(Ue), Gt = ["left", "right"], je = c.enum(Gt), Ht = ["top", "bottom"], Ce = c.enum(Ht), Be = ["center"], ue = c.enum(Be), Rs = [...Ue, ...Be], Re = c.enum(Rs), Ps = c.enum(Ln), Zn = ["first", "last"], Ls = c.enum(Zn), ks = c.object({ lower: c.number(), upper: c.number() }), Zs = c.enum([...$e.options, ...Re.options]), _s = c.union([$e, Re, c.instanceof(String)]), w = (e, t, n) => {
343
+ }), Ln = ["start", "center", "end"], ut = c.object({ x: c.number(), y: c.number() }), Zn = c.object({ clientX: c.number(), clientY: c.number() }), Gt = ["x", "y"], $e = c.enum(Gt), Ue = ["top", "right", "bottom", "left"], js = c.enum(Ue), Ht = ["left", "right"], je = c.enum(Ht), Dt = ["top", "bottom"], Ce = c.enum(Dt), Be = ["center"], ue = c.enum(Be), Cs = [...Ue, ...Be], Pe = c.enum(Cs), Bs = c.enum(Ln), _n = ["first", "last"], Ps = c.enum(_n), Rs = c.object({ lower: c.number(), upper: c.number() }), ks = c.enum([...$e.options, ...Pe.options]), Ls = c.union([$e, Pe, c.instanceof(String)]), b = (e, t, n) => {
344
344
  const r = {};
345
345
  if (typeof t == "object" && (n = t, t = void 0), n = { makeValid: !0, ...n }, typeof e == "number" || typeof e == "bigint")
346
346
  t != null ? (r.lower = e, r.upper = t) : (r.lower = typeof e == "bigint" ? 0n : 0, r.upper = e);
@@ -349,60 +349,60 @@ const Tn = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz", gs = `0123456
349
349
  [r.lower, r.upper] = e;
350
350
  } else
351
351
  r.lower = e.lower, r.upper = e.upper;
352
- return n?.makeValid ? _n(r) : r;
353
- }, qs = Object.freeze({ lower: 0, upper: 0 }), Fs = Object.freeze({ lower: -1 / 0, upper: 1 / 0 }), Vs = Object.freeze({ lower: 0, upper: 1 }), Ws = Object.freeze({ lower: -1, upper: 1 }), zs = (e, t) => {
352
+ return n?.makeValid ? qn(r) : r;
353
+ }, Zs = Object.freeze({ lower: 0, upper: 0 }), _s = Object.freeze({ lower: -1 / 0, upper: 1 / 0 }), qs = Object.freeze({ lower: 0, upper: 1 }), Fs = Object.freeze({ lower: -1, upper: 1 }), Vs = (e, t) => {
354
354
  if (e == null && t == null) return !0;
355
355
  if (e == null || t == null) return !1;
356
- const n = w(e), r = w(t);
356
+ const n = b(e), r = b(t);
357
357
  return n?.lower === r?.lower && n?.upper === r?.upper;
358
- }, _n = (e) => e.lower > e.upper ? { lower: e.upper, upper: e.lower } : e, le = (e, t) => {
359
- const n = w(e);
358
+ }, qn = (e) => e.lower > e.upper ? { lower: e.upper, upper: e.lower } : e, le = (e, t) => {
359
+ const n = b(e);
360
360
  return t < n.lower ? n.lower : t >= n.upper ? n.upper - (typeof n.upper == "number" ? 1 : 1n) : t;
361
- }, k = (e, t) => {
362
- const n = w(e);
361
+ }, L = (e, t) => {
362
+ const n = b(e);
363
363
  if (typeof t == "number" || typeof t == "bigint")
364
364
  return t >= n.lower && t < n.upper;
365
- const r = w(t);
365
+ const r = b(t);
366
366
  return r.lower >= n.lower && r.upper <= n.upper;
367
- }, Ys = (e, t) => {
368
- const n = w(e), r = w(t);
369
- return n.lower === r.lower ? !0 : r.upper === n.lower || r.lower === n.upper ? !1 : k(n, r.upper) || k(n, r.lower) || k(r, n.upper) || k(r, n.lower);
367
+ }, Ws = (e, t) => {
368
+ const n = b(e), r = b(t);
369
+ return n.lower === r.lower ? !0 : r.upper === n.lower || r.lower === n.upper ? !1 : L(n, r.upper) || L(n, r.lower) || L(r, n.upper) || L(r, n.lower);
370
370
  }, ft = (e) => {
371
- const t = w(e);
371
+ const t = b(e);
372
372
  return t.upper - t.lower;
373
- }, Gs = (e) => {
374
- const t = w(e);
373
+ }, zs = (e) => {
374
+ const t = b(e);
375
375
  return typeof t.lower == "bigint" ? t.lower === 0n && t.upper === 0n : t.lower === 0 && t.upper === 0;
376
- }, Hs = (e) => {
376
+ }, Ys = (e) => {
377
377
  const t = ft(e);
378
378
  return typeof t == "number" ? t === 0 : t === 0n;
379
- }, Ds = (e) => {
380
- const t = w(e);
379
+ }, Gs = (e) => {
380
+ const t = b(e);
381
381
  return typeof t.lower == "bigint" ? !0 : Number.isFinite(t.lower) && Number.isFinite(t.upper);
382
- }, Js = (e) => {
383
- const t = w(e);
382
+ }, Hs = (e) => {
383
+ const t = b(e);
384
384
  return (t.upper + t.lower) / 2;
385
- }, qn = (e) => ({
386
- lower: Math.min(...e.map((t) => w(t).lower)),
387
- upper: Math.max(...e.map((t) => w(t).upper))
388
- }), Xs = (e) => ({
389
- lower: Math.max(...e.map((t) => w(t).lower)),
390
- upper: Math.min(...e.map((t) => w(t).upper))
391
- }), Ks = (e) => {
392
- const t = w(e), n = typeof t.lower == "bigint";
385
+ }, Fn = (e) => ({
386
+ lower: Math.min(...e.map((t) => b(t).lower)),
387
+ upper: Math.max(...e.map((t) => b(t).upper))
388
+ }), Ds = (e) => ({
389
+ lower: Math.max(...e.map((t) => b(t).lower)),
390
+ upper: Math.min(...e.map((t) => b(t).upper))
391
+ }), Js = (e) => {
392
+ const t = b(e), n = typeof t.lower == "bigint";
393
393
  return Array.from({ length: Number(ft(e)) }, (r, s) => n ? t.lower + BigInt(s) : t.lower + s);
394
394
  }, fe = (e, t) => {
395
- const n = e.map((i) => w(i)), r = n.findIndex((i) => k(i, t) || t < i.lower);
395
+ const n = e.map((i) => b(i)), r = n.findIndex((i) => L(i, t) || t < i.lower);
396
396
  if (r === -1) return { index: e.length, position: 0 };
397
397
  const s = n[r];
398
- return k(s, t) ? { index: r, position: Number(t - s.lower) } : { index: r, position: 0 };
398
+ return L(s, t) ? { index: r, position: Number(t - s.lower) } : { index: r, position: 0 };
399
399
  }, ne = {
400
400
  removeBefore: 0,
401
401
  removeAfter: 0,
402
402
  insertInto: 0,
403
403
  deleteInBetween: 0
404
- }, Qs = (e, t) => {
405
- const n = e.map((l) => w(l)), r = w(t);
404
+ }, Xs = (e, t) => {
405
+ const n = e.map((l) => b(l)), r = b(t);
406
406
  if (n.length === 0) return ne;
407
407
  const s = fe(n, r.lower), i = fe(n, r.upper);
408
408
  if (s.index === e.length) return { ...ne, insertInto: e.length };
@@ -421,8 +421,8 @@ const Tn = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz", gs = `0123456
421
421
  insertInto: a,
422
422
  deleteInBetween: o
423
423
  };
424
- }, Fn = (e, t, n) => {
425
- const r = e.map((a) => w(a)), s = n > 0 ? 1 : n < 0 ? -1 : 0;
424
+ }, Vn = (e, t, n) => {
425
+ const r = e.map((a) => b(a)), s = n > 0 ? 1 : n < 0 ? -1 : 0;
426
426
  if (s === 0) return t;
427
427
  let i = n, o = t;
428
428
  for (; ae(i, 0) === !1; ) {
@@ -431,7 +431,7 @@ const Tn = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz", gs = `0123456
431
431
  const u = r[a];
432
432
  let l;
433
433
  if (s > 0 ? l = F(u.upper, o) : l = F(o, u.lower), l > 0) {
434
- const h = Bn(Rn(i), l);
434
+ const h = Pn(Rn(i), l);
435
435
  if (o = G(o, s > 0 ? h : -h), i = F(i, s > 0 ? h : -h), ae(i, 0)) return o;
436
436
  continue;
437
437
  }
@@ -448,10 +448,10 @@ const Tn = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz", gs = `0123456
448
448
  }
449
449
  }
450
450
  return o;
451
- }, Vn = (e, t, n) => {
452
- const r = e.map((o) => w(o));
451
+ }, Wn = (e, t, n) => {
452
+ const r = e.map((o) => b(o));
453
453
  if (t === n) return typeof t == "bigint" ? 0n : 0;
454
- const s = t < n ? w([t, n]) : w([n, t]);
454
+ const s = t < n ? b([t, n]) : b([n, t]);
455
455
  let i = typeof t == "bigint" ? 0n : 0;
456
456
  for (const o of r) {
457
457
  const a = o.lower > s.lower ? o.lower : s.lower, u = o.upper < s.upper ? o.upper : s.upper;
@@ -461,40 +461,40 @@ const Tn = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz", gs = `0123456
461
461
  }
462
462
  }
463
463
  return i;
464
- }, Ou = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
464
+ }, bu = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
465
465
  __proto__: null,
466
- CLIP: Ws,
467
- DECIMAL: Vs,
468
- INFINITE: Fs,
469
- ZERO: qs,
470
- bounds: ks,
471
- buildInsertionPlan: Qs,
466
+ CLIP: Fs,
467
+ DECIMAL: qs,
468
+ INFINITE: _s,
469
+ ZERO: Zs,
470
+ bounds: Rs,
471
+ buildInsertionPlan: Xs,
472
472
  clamp: le,
473
- construct: w,
474
- contains: k,
475
- distance: Vn,
476
- equals: zs,
473
+ construct: b,
474
+ contains: L,
475
+ distance: Wn,
476
+ equals: Vs,
477
477
  findInsertPosition: fe,
478
- isFinite: Ds,
479
- isZero: Gs,
480
- linspace: Ks,
481
- makeValid: _n,
482
- max: qn,
483
- mean: Js,
484
- min: Xs,
485
- overlapsWith: Ys,
478
+ isFinite: Gs,
479
+ isZero: zs,
480
+ linspace: Js,
481
+ makeValid: qn,
482
+ max: Fn,
483
+ mean: Hs,
484
+ min: Ds,
485
+ overlapsWith: Ws,
486
486
  span: ft,
487
- spanIsZero: Hs,
488
- traverse: Fn
489
- }, Symbol.toStringTag, { value: "Module" })), he = 2, de = 3, Wn = 2, ti = (e, t) => {
487
+ spanIsZero: Ys,
488
+ traverse: Vn
489
+ }, Symbol.toStringTag, { value: "Module" })), he = 2, de = 3, zn = 2, Ks = (e, t) => {
490
490
  if (Number.isNaN(e) || !Number.isFinite(e)) return e;
491
491
  const n = ft(t);
492
492
  if (n == 0) return e;
493
493
  let r;
494
- n >= 1e3 ? r = he : n >= 1 ? r = de : r = Math.ceil(-Math.log10(n)) + Wn;
494
+ n >= 1e3 ? r = he : n >= 1 ? r = de : r = Math.ceil(-Math.log10(n)) + zn;
495
495
  const s = 10 ** r;
496
496
  return Math.round(e * s) / s;
497
- }, ei = 5, ni = 1e-10, ri = (e, t) => {
497
+ }, Qs = 5, ti = 1e-10, ei = (e, t) => {
498
498
  if (Number.isNaN(e) || !Number.isFinite(e)) return e;
499
499
  const n = Math.abs(e);
500
500
  if (n === 0) return 0;
@@ -502,11 +502,11 @@ const Tn = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz", gs = `0123456
502
502
  if (t != null) {
503
503
  s = ft(t);
504
504
  const u = s / n;
505
- r = s > 0 && u > ni;
505
+ r = s > 0 && u > ti;
506
506
  }
507
507
  if (r) {
508
508
  let u;
509
- s >= 1e3 ? u = he : s >= 1 ? u = de : u = Math.ceil(-Math.log10(s)) + Wn;
509
+ s >= 1e3 ? u = he : s >= 1 ? u = de : u = Math.ceil(-Math.log10(s)) + zn;
510
510
  const l = 10 ** u;
511
511
  return Math.round(e * l) / l;
512
512
  }
@@ -518,98 +518,98 @@ const Tn = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz", gs = `0123456
518
518
  const u = 10 ** de;
519
519
  return Math.round(e * u) / u;
520
520
  }
521
- const i = Math.floor(Math.log10(n)), a = 10 ** (ei - i - 1);
521
+ const i = Math.floor(Math.log10(n)), a = 10 ** (Qs - i - 1);
522
522
  return Math.round(e * a) / a;
523
- }, xu = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
523
+ }, wu = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
524
524
  __proto__: null,
525
- MAX_INT16: Ms,
526
- MAX_INT32: Es,
527
- MAX_INT64: _t,
528
- MAX_INT64_NUMBER: Cn,
529
- MAX_INT8: Ns,
530
- MAX_UINT12: jn,
531
- MAX_UINT16: bs,
532
- MAX_UINT32: ws,
533
- MAX_UINT64: Os,
534
- MAX_UINT64_NUMBER: xs,
535
- MAX_UINT8: ps,
536
- MIN_INT16: vs,
537
- MIN_INT32: As,
538
- MIN_INT64: Ss,
539
- MIN_INT64_NUMBER: Ts,
540
- MIN_INT8: Is,
525
+ MAX_INT16: Ns,
526
+ MAX_INT32: Ms,
527
+ MAX_INT64: qt,
528
+ MAX_INT64_NUMBER: Bn,
529
+ MAX_INT8: xs,
530
+ MAX_UINT12: Cn,
531
+ MAX_UINT16: ms,
532
+ MAX_UINT32: ps,
533
+ MAX_UINT64: bs,
534
+ MAX_UINT64_NUMBER: ws,
535
+ MAX_UINT8: ys,
536
+ MIN_INT16: Is,
537
+ MIN_INT32: vs,
538
+ MIN_INT64: As,
539
+ MIN_INT64_NUMBER: Es,
540
+ MIN_INT8: Os,
541
541
  abs: Rn,
542
542
  add: G,
543
- closeTo: $s,
543
+ closeTo: Ss,
544
544
  div: Et,
545
545
  equal: ae,
546
- isInteger: qt,
547
- max: js,
548
- min: Bn,
549
- mult: L,
550
- roundBySpan: ti,
551
- roundToNearestMagnitude: Us,
552
- smartRound: ri,
546
+ isInteger: Ft,
547
+ max: $s,
548
+ min: Pn,
549
+ mult: R,
550
+ roundBySpan: Ks,
551
+ roundToNearestMagnitude: Ts,
552
+ smartRound: ei,
553
553
  sub: F
554
- }, Symbol.toStringTag, { value: "Module" })), zn = Zs, _ = (e) => Yt.includes(e) ? e : Ht.includes(e) ? "y" : "x", si = (e) => _(e) === "x" ? "y" : "x", ii = (e) => _(e) === "x" ? "width" : "height", oi = (e) => _(e) === "x" ? "left" : "top", ci = (e) => zn.safeParse(e).success, ai = (e) => _(e) === "x" ? "signedWidth" : "signedHeight", ui = (e) => e === "center" ? !1 : _(e) === "x", li = (e) => _(e) === "y", Iu = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
554
+ }, Symbol.toStringTag, { value: "Module" })), Yn = ks, _ = (e) => Gt.includes(e) ? e : Dt.includes(e) ? "y" : "x", ni = (e) => _(e) === "x" ? "y" : "x", ri = (e) => _(e) === "x" ? "width" : "height", si = (e) => _(e) === "x" ? "left" : "top", ii = (e) => Yn.safeParse(e).success, oi = (e) => _(e) === "x" ? "signedWidth" : "signedHeight", ci = (e) => e === "center" ? !1 : _(e) === "x", ai = (e) => _(e) === "y", Ou = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
555
555
  __proto__: null,
556
- DIRECTIONS: Yt,
556
+ DIRECTIONS: Gt,
557
557
  construct: _,
558
- crude: zn,
559
- dimension: ii,
558
+ crude: Yn,
559
+ dimension: ri,
560
560
  direction: $e,
561
- isDirection: ci,
562
- isX: ui,
563
- isY: li,
564
- location: oi,
565
- signedDimension: ai,
566
- swap: si
567
- }, Symbol.toStringTag, { value: "Module" })), fi = je, hi = Ce, di = ue, gi = {
561
+ isDirection: ii,
562
+ isX: ci,
563
+ isY: ai,
564
+ location: si,
565
+ signedDimension: oi,
566
+ swap: ni
567
+ }, Symbol.toStringTag, { value: "Module" })), ui = je, li = Ce, fi = ue, hi = {
568
568
  top: "bottom",
569
569
  right: "left",
570
570
  bottom: "top",
571
571
  left: "right",
572
572
  center: "center"
573
- }, yi = {
573
+ }, di = {
574
574
  top: { clockwise: "left", counterclockwise: "right" },
575
575
  right: { clockwise: "top", counterclockwise: "bottom" },
576
576
  bottom: { clockwise: "right", counterclockwise: "left" },
577
577
  left: { clockwise: "bottom", counterclockwise: "top" }
578
- }, mi = _s, et = (e) => e instanceof String || !Yt.includes(e) ? e : e === "x" ? "left" : "top", pi = (e) => gi[et(e)], bi = (e, t) => yi[e][t], It = (e) => {
579
- const t = et(e);
578
+ }, gi = Ls, nt = (e) => e instanceof String || !Gt.includes(e) ? e : e === "x" ? "left" : "top", yi = (e) => hi[nt(e)], mi = (e, t) => di[e][t], It = (e) => {
579
+ const t = nt(e);
580
580
  return t === "top" || t === "bottom" ? "y" : "x";
581
- }, wi = c.object({
581
+ }, pi = c.object({
582
582
  x: je.or(ue),
583
583
  y: Ce.or(ue)
584
- }), Pe = c.object({ x: je, y: Ce }), ht = Object.freeze({ x: "left", y: "top" }), Le = Object.freeze({ x: "right", y: "top" }), Dt = Object.freeze({ x: "left", y: "bottom" }), ke = Object.freeze({ x: "right", y: "bottom" }), Ze = Object.freeze({ x: "center", y: "center" }), _e = Object.freeze({ x: "center", y: "top" }), qe = Object.freeze({ x: "center", y: "bottom" }), Fe = Object.freeze({ x: "right", y: "center" }), Ve = Object.freeze({ x: "left", y: "center" }), Oi = Object.freeze([
584
+ }), Re = c.object({ x: je, y: Ce }), ht = Object.freeze({ x: "left", y: "top" }), ke = Object.freeze({ x: "right", y: "top" }), Jt = Object.freeze({ x: "left", y: "bottom" }), Le = Object.freeze({ x: "right", y: "bottom" }), Ze = Object.freeze({ x: "center", y: "center" }), _e = Object.freeze({ x: "center", y: "top" }), qe = Object.freeze({ x: "center", y: "bottom" }), Fe = Object.freeze({ x: "right", y: "center" }), Ve = Object.freeze({ x: "left", y: "center" }), bi = Object.freeze([
585
585
  Ve,
586
586
  Fe,
587
587
  _e,
588
588
  qe,
589
589
  ht,
590
- Le,
591
- Dt,
592
590
  ke,
591
+ Jt,
592
+ Le,
593
593
  Ze
594
- ]), We = (e, t) => e.x === t.x && e.y === t.y, xi = (e, t) => {
594
+ ]), We = (e, t) => e.x === t.x && e.y === t.y, wi = (e, t) => {
595
595
  if (typeof t == "object") {
596
596
  let n = !0;
597
597
  return "x" in t && (e.x === t.x || (n = !1)), "y" in t && (e.y === t.y || (n = !1)), n;
598
598
  }
599
599
  return e.x === t || e.y === t;
600
- }, Yn = (e) => [e.x, e.y], Rt = (e) => It(et(e)) === "x", Ii = (e) => It(et(e)) === "y", Ni = (e) => `${e.x}${pn(e.y)}`, vi = (e, t) => {
600
+ }, Gn = (e) => [e.x, e.y], Rt = (e) => It(nt(e)) === "x", Oi = (e) => It(nt(e)) === "y", xi = (e) => `${e.x}${bn(e.y)}`, Ii = (e, t) => {
601
601
  let n, r;
602
- if (typeof e == "object" && "x" in e ? (n = e.x, r = e.y) : (n = et(e), r = et(t ?? e)), It(n) === It(r) && n !== "center" && r !== "center")
602
+ if (typeof e == "object" && "x" in e ? (n = e.x, r = e.y) : (n = nt(e), r = nt(t ?? e)), It(n) === It(r) && n !== "center" && r !== "center")
603
603
  throw new Error(
604
604
  `[XYLocation] - encountered two locations with the same direction: ${n.toString()} - ${r.toString()}`
605
605
  );
606
606
  const s = { ...Ze };
607
607
  return n === "center" ? Rt(r) ? [s.x, s.y] = [r, n] : [s.x, s.y] = [n, r] : r === "center" ? Rt(n) ? [s.x, s.y] = [n, r] : [s.x, s.y] = [r, n] : Rt(n) ? [s.x, s.y] = [n, r] : [s.x, s.y] = [r, n], s;
608
- }, Nu = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
608
+ }, xu = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
609
609
  __proto__: null,
610
610
  BOTTOM_CENTER: qe,
611
- BOTTOM_LEFT: Dt,
612
- BOTTOM_RIGHT: ke,
611
+ BOTTOM_LEFT: Jt,
612
+ BOTTOM_RIGHT: Le,
613
613
  CENTER: Ze,
614
614
  CENTER_LEFT: Ve,
615
615
  CENTER_LOCATIONS: Be,
@@ -617,107 +617,107 @@ const Tn = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz", gs = `0123456
617
617
  OUTER_LOCATIONS: Ue,
618
618
  TOP_CENTER: _e,
619
619
  TOP_LEFT: ht,
620
- TOP_RIGHT: Le,
621
- XY_LOCATIONS: Oi,
622
- X_LOCATIONS: Gt,
623
- Y_LOCATIONS: Ht,
624
- center: di,
625
- construct: et,
626
- constructXY: vi,
627
- corner: Pe,
628
- crude: mi,
620
+ TOP_RIGHT: ke,
621
+ XY_LOCATIONS: bi,
622
+ X_LOCATIONS: Ht,
623
+ Y_LOCATIONS: Dt,
624
+ center: fi,
625
+ construct: nt,
626
+ constructXY: Ii,
627
+ corner: Re,
628
+ crude: gi,
629
629
  direction: It,
630
630
  isX: Rt,
631
- isY: Ii,
632
- location: Re,
633
- outer: Bs,
634
- rotate: bi,
635
- swap: pi,
636
- x: fi,
637
- xy: wi,
638
- xyCouple: Yn,
631
+ isY: Oi,
632
+ location: Pe,
633
+ outer: js,
634
+ rotate: mi,
635
+ swap: yi,
636
+ x: ui,
637
+ xy: pi,
638
+ xyCouple: Gn,
639
639
  xyEquals: We,
640
- xyMatches: xi,
641
- xyToString: Ni,
642
- y: hi
640
+ xyMatches: wi,
641
+ xyToString: xi,
642
+ y: li
643
643
  }, Symbol.toStringTag, { value: "Module" })), ge = c.union([
644
644
  c.number(),
645
645
  ut,
646
- Pn,
646
+ kn,
647
647
  Te,
648
- Cs,
649
- kn
650
- ]), I = (e, t) => {
648
+ Us,
649
+ Zn
650
+ ]), x = (e, t) => {
651
651
  if (typeof e == "string") {
652
652
  if (t === void 0) throw new Error("The y coordinate must be given.");
653
653
  return e === "x" ? { x: t, y: 0 } : { x: 0, y: t };
654
654
  }
655
655
  return typeof e == "number" ? { x: e, y: t ?? e } : Array.isArray(e) ? { x: e[0], y: e[1] } : "signedWidth" in e ? { x: e.signedWidth, y: e.signedHeight } : "clientX" in e ? { x: e.clientX, y: e.clientY } : "width" in e ? { x: e.width, y: e.height } : { x: e.x, y: e.y };
656
- }, V = Object.freeze({ x: 0, y: 0 }), Gn = Object.freeze({ x: 1, y: 1 }), Mi = Object.freeze({ x: 1 / 0, y: 1 / 0 }), Ai = Object.freeze({ x: NaN, y: NaN }), Ft = (e, t, n = 0) => {
657
- const r = I(e), s = I(t);
656
+ }, V = Object.freeze({ x: 0, y: 0 }), Hn = Object.freeze({ x: 1, y: 1 }), Ni = Object.freeze({ x: 1 / 0, y: 1 / 0 }), vi = Object.freeze({ x: NaN, y: NaN }), Vt = (e, t, n = 0) => {
657
+ const r = x(e), s = x(t);
658
658
  return n === 0 ? r.x === s.x && r.y === s.y : Math.abs(r.x - s.x) <= n && Math.abs(r.y - s.y) <= n;
659
- }, Ei = (e) => Ft(e, V), ze = (e, t, n) => {
660
- const r = I(e), s = I(t, n);
659
+ }, Mi = (e) => Vt(e, V), ze = (e, t, n) => {
660
+ const r = x(e), s = x(t, n);
661
661
  return { x: r.x * s.x, y: r.y * s.y };
662
- }, Hn = (e, t) => {
663
- const n = I(e);
664
- return { x: n.x + t, y: n.y };
665
662
  }, Dn = (e, t) => {
666
- const n = I(e);
663
+ const n = x(e);
664
+ return { x: n.x + t, y: n.y };
665
+ }, Jn = (e, t) => {
666
+ const n = x(e);
667
667
  return { x: n.x, y: n.y + t };
668
668
  }, Nt = (e, t, n, ...r) => {
669
669
  if (typeof t == "string") {
670
670
  if (typeof n != "number") throw new Error("The value must be a number.");
671
- return t === "x" ? Hn(e, n) : Dn(e, n);
671
+ return t === "x" ? Dn(e, n) : Jn(e, n);
672
672
  }
673
673
  if (typeof t == "object" && "x" in t && typeof t.x == "string") {
674
- const s = I(n), i = I(e);
674
+ const s = x(n), i = x(e);
675
675
  return t.x === "left" ? s.x = -s.x : t.x === "center" && (s.x = 0), t.y === "top" ? s.y = -s.y : t.y === "center" && (s.y = 0), { x: i.x + s.x, y: i.y + s.y };
676
676
  }
677
677
  return [e, t, n ?? V, ...r].reduce((s, i) => {
678
- const o = I(i);
678
+ const o = x(i);
679
679
  return { x: s.x + o.x, y: s.y + o.y };
680
680
  }, V);
681
- }, Si = (e, t, n) => {
682
- const r = I(e);
681
+ }, Ai = (e, t, n) => {
682
+ const r = x(e);
683
683
  return _(t) === "x" ? { x: n, y: r.y } : { x: r.x, y: n };
684
- }, Ti = (e, t) => {
685
- const n = I(e), r = I(t);
684
+ }, Ei = (e, t) => {
685
+ const n = x(e), r = x(t);
686
686
  return Math.sqrt((n.x - r.x) ** 2 + (n.y - r.y) ** 2);
687
- }, $i = (e, t) => {
688
- const n = I(e), r = I(t);
687
+ }, Si = (e, t) => {
688
+ const n = x(e), r = x(t);
689
689
  return { x: r.x - n.x, y: r.y - n.y };
690
- }, Ui = (e) => {
691
- const t = I(e);
690
+ }, Ti = (e) => {
691
+ const t = x(e);
692
692
  return Number.isNaN(t.x) || Number.isNaN(t.y);
693
- }, ji = (e) => {
694
- const t = I(e);
693
+ }, $i = (e) => {
694
+ const t = x(e);
695
695
  return Number.isFinite(t.x) && Number.isFinite(t.y);
696
- }, Ci = (e) => {
697
- const t = I(e);
696
+ }, Ui = (e) => {
697
+ const t = x(e);
698
698
  return [t.x, t.y];
699
- }, Bi = (e) => {
700
- const t = I(e);
699
+ }, ji = (e) => {
700
+ const t = x(e);
701
701
  return { left: t.x, top: t.y };
702
- }, Vt = (e, t = 0) => {
703
- const n = I(e);
702
+ }, Wt = (e, t = 0) => {
703
+ const n = x(e);
704
704
  return {
705
705
  x: Number(n.x.toFixed(t)),
706
706
  y: Number(n.y.toFixed(t))
707
707
  };
708
708
  }, gt = (e, t) => {
709
- const n = I(e), r = I(t);
709
+ const n = x(e), r = x(t);
710
710
  return { x: n.x - r.x, y: n.y - r.y };
711
711
  }, yt = (e) => {
712
- const t = I(e), n = Math.hypot(t.x, t.y);
712
+ const t = x(e), n = Math.hypot(t.x, t.y);
713
713
  return n === 0 ? { x: 0, y: 0 } : { x: -t.y / n, y: t.x / n };
714
- }, Jn = (e) => {
715
- const t = I(e), n = Math.hypot(t.x, t.y);
714
+ }, Xn = (e) => {
715
+ const t = x(e), n = Math.hypot(t.x, t.y);
716
716
  return n === 0 ? { x: 0, y: 0 } : { x: t.x / n, y: t.y / n };
717
- }, Xn = (...e) => {
717
+ }, Kn = (...e) => {
718
718
  const t = e.reduce((n, r) => Nt(n, r), V);
719
719
  return ze(t, 1 / e.length);
720
- }, Ri = (e, t) => {
720
+ }, Ci = (e, t) => {
721
721
  const n = [];
722
722
  for (let r = 0; r < e.length; r++) {
723
723
  const s = e[r];
@@ -731,81 +731,81 @@ const Tn = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz", gs = `0123456
731
731
  } else {
732
732
  const l = e[r - 1], h = e[r + 1], y = gt(s, l), m = gt(h, s);
733
733
  i = yt(y), o = yt(m);
734
- const A = Math.acos(
734
+ const M = Math.acos(
735
735
  (y.x * m.x + y.y * m.y) / (Math.hypot(y.x, y.y) * Math.hypot(m.x, m.y))
736
- ), T = Math.sin(A / 2);
737
- T === 0 ? u = t : u = t / T, a = Jn(Xn(i, o));
736
+ ), S = Math.sin(M / 2);
737
+ S === 0 ? u = t : u = t / S, a = Xn(Kn(i, o));
738
738
  }
739
739
  n.push(ze(a, u));
740
740
  }
741
741
  return n;
742
- }, Pi = (e) => {
743
- const t = I(e);
742
+ }, Bi = (e) => {
743
+ const t = x(e);
744
744
  return { x: t.y, y: t.x };
745
745
  }, ye = (e) => {
746
- const t = I(e);
746
+ const t = x(e);
747
747
  return { x: Math.round(t.x), y: Math.round(t.y) };
748
- }, Li = (e) => {
749
- const t = I(e);
748
+ }, Pi = (e) => {
749
+ const t = x(e);
750
750
  return { x: 1 / t.x, y: 1 / t.y };
751
- }, ki = (e, t, n) => {
752
- const r = I(e), s = I(t), i = n === "clockwise" ? Math.PI / 2 : -Math.PI / 2, o = r.x - s.x, a = r.y - s.y, u = o * Math.cos(i) - a * Math.sin(i), l = o * Math.sin(i) + a * Math.cos(i);
751
+ }, Ri = (e, t, n) => {
752
+ const r = x(e), s = x(t), i = n === "clockwise" ? Math.PI / 2 : -Math.PI / 2, o = r.x - s.x, a = r.y - s.y, u = o * Math.cos(i) - a * Math.sin(i), l = o * Math.sin(i) + a * Math.cos(i);
753
753
  return {
754
754
  x: u + s.x,
755
755
  y: l + s.y
756
756
  };
757
- }, vu = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
757
+ }, Iu = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
758
758
  __proto__: null,
759
- INFINITY: Mi,
760
- NAN: Ai,
761
- ONE: Gn,
759
+ INFINITY: Ni,
760
+ NAN: vi,
761
+ ONE: Hn,
762
762
  ZERO: V,
763
- average: Xn,
764
- calculateMiters: Ri,
765
- clientXY: kn,
766
- construct: I,
767
- couple: Ci,
763
+ average: Kn,
764
+ calculateMiters: Ci,
765
+ clientXY: Zn,
766
+ construct: x,
767
+ couple: Ui,
768
768
  crudeZ: ge,
769
- css: Bi,
770
- distance: Ti,
771
- equals: Ft,
772
- isFinite: ji,
773
- isNan: Ui,
774
- isZero: Ei,
769
+ css: ji,
770
+ distance: Ei,
771
+ equals: Vt,
772
+ isFinite: $i,
773
+ isNan: Ti,
774
+ isZero: Mi,
775
775
  normal: yt,
776
- normalize: Jn,
777
- reciprocal: Li,
778
- rotate: ki,
776
+ normalize: Xn,
777
+ reciprocal: Pi,
778
+ rotate: Ri,
779
779
  round: ye,
780
780
  scale: ze,
781
- set: Si,
781
+ set: Ai,
782
782
  sub: gt,
783
- swap: Pi,
783
+ swap: Bi,
784
784
  translate: Nt,
785
- translateX: Hn,
786
- translateY: Dn,
787
- translation: $i,
788
- truncate: Vt,
785
+ translateX: Dn,
786
+ translateY: Jn,
787
+ translation: Si,
788
+ truncate: Wt,
789
789
  xy: ut
790
- }, Symbol.toStringTag, { value: "Module" })), $t = c.union([c.number(), c.string()]), Zi = c.object({
791
- top: $t,
792
- left: $t,
793
- width: $t,
794
- height: $t
795
- }), _i = c.object({
790
+ }, Symbol.toStringTag, { value: "Module" })), Ut = c.union([c.number(), c.string()]), ki = c.object({
791
+ top: Ut,
792
+ left: Ut,
793
+ width: Ut,
794
+ height: Ut
795
+ }), Li = c.object({
796
796
  left: c.number(),
797
797
  top: c.number(),
798
798
  right: c.number(),
799
799
  bottom: c.number()
800
- }), qi = c.object({
800
+ }), Zi = c.object({
801
801
  one: ut,
802
802
  two: ut,
803
- root: Pe
804
- }), Kn = { one: V, two: V, root: ht }, Fi = { one: V, two: Gn, root: Dt }, Qn = (e, t) => ({
803
+ root: Re
804
+ }), Qn = { one: V, two: V, root: ht }, _i = { one: V, two: Hn, root: Jt }, tr = (e, t) => ({
805
805
  one: e.one,
806
806
  two: e.two,
807
807
  root: t ?? e.root
808
- }), v = (e, t, n = 0, r = 0, s) => {
808
+ }), N = (e, t, n = 0, r = 0, s) => {
809
809
  const i = {
810
810
  one: { ...V },
811
811
  two: { ...V },
@@ -823,217 +823,217 @@ const Tn = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz", gs = `0123456
823
823
  x: i.one.x + t.signedWidth,
824
824
  y: i.one.y + t.signedHeight
825
825
  } : i.two = t, i));
826
- }, Vi = (e, t, n) => {
827
- const r = v(e);
826
+ }, qi = (e, t, n) => {
827
+ const r = N(e);
828
828
  if (typeof t == "string") {
829
829
  if (n == null) throw new Error("Invalid arguments for resize");
830
830
  const s = _(t);
831
- return v(
831
+ return N(
832
832
  r.one,
833
833
  void 0,
834
- s === "x" ? n : U(r),
835
- s === "y" ? n : j(r),
834
+ s === "x" ? n : $(r),
835
+ s === "y" ? n : U(r),
836
836
  r.root
837
837
  );
838
838
  }
839
- return v(r.one, t, void 0, void 0, r.root);
840
- }, Wi = (e, t, n = !0) => {
841
- const r = v(e);
839
+ return N(r.one, t, void 0, void 0, r.root);
840
+ }, Fi = (e, t, n = !0) => {
841
+ const r = N(e);
842
842
  let s = (i, o) => i < o;
843
- return n && (s = (i, o) => i <= o), "one" in t ? s(J(r), J(t)) && s(Q(t), Q(r)) && s(X(r), X(t)) && s(tt(t), tt(r)) : s(J(r), t.x) && s(t.x, Q(r)) && s(X(r), t.y) && s(t.y, tt(r));
844
- }, zi = (e, t) => Ft(e.one, t.one) && Ft(e.two, t.two) && We(e.root, t.root), tr = (e) => ({
845
- width: U(e),
846
- height: j(e)
847
- }), Yi = (e) => ({
848
- signedWidth: Jt(e),
849
- signedHeight: Xt(e)
850
- }), Gi = (e) => ({
851
- top: X(e),
852
- left: J(e),
853
- width: U(e),
854
- height: j(e)
843
+ return n && (s = (i, o) => i <= o), "one" in t ? s(X(r), X(t)) && s(tt(t), tt(r)) && s(K(r), K(t)) && s(et(t), et(r)) : s(X(r), t.x) && s(t.x, tt(r)) && s(K(r), t.y) && s(t.y, et(r));
844
+ }, Vi = (e, t) => Vt(e.one, t.one) && Vt(e.two, t.two) && We(e.root, t.root), er = (e) => ({
845
+ width: $(e),
846
+ height: U(e)
847
+ }), Wi = (e) => ({
848
+ signedWidth: Xt(e),
849
+ signedHeight: Kt(e)
850
+ }), zi = (e) => ({
851
+ top: K(e),
852
+ left: X(e),
853
+ width: $(e),
854
+ height: U(e)
855
855
  }), Ye = (e, t, n = !1) => {
856
- const r = _(t) === "y" ? Xt(e) : Jt(e);
856
+ const r = _(t) === "y" ? Kt(e) : Xt(e);
857
857
  return n ? r : Math.abs(r);
858
- }, H = (e, t) => {
859
- const n = v(e);
858
+ }, D = (e, t) => {
859
+ const n = N(e);
860
860
  return {
861
- x: t.x === "center" ? me(n).x : nt(n, t.x),
862
- y: t.y === "center" ? me(n).y : nt(n, t.y)
861
+ x: t.x === "center" ? me(n).x : rt(n, t.x),
862
+ y: t.y === "center" ? me(n).y : rt(n, t.y)
863
863
  };
864
- }, nt = (e, t) => {
865
- const n = v(e), r = Yn(n.root).includes(t) ? Math.min : Math.max;
866
- return Gt.includes(t) ? r(n.one.x, n.two.x) : r(n.one.y, n.two.y);
867
- }, Hi = (e) => rr(e) === 0, U = (e) => Ye(e, "x"), j = (e) => Ye(e, "y"), Jt = (e) => {
868
- const t = v(e);
864
+ }, rt = (e, t) => {
865
+ const n = N(e), r = Gn(n.root).includes(t) ? Math.min : Math.max;
866
+ return Ht.includes(t) ? r(n.one.x, n.two.x) : r(n.one.y, n.two.y);
867
+ }, Yi = (e) => sr(e) === 0, $ = (e) => Ye(e, "x"), U = (e) => Ye(e, "y"), Xt = (e) => {
868
+ const t = N(e);
869
869
  return t.two.x - t.one.x;
870
- }, Xt = (e) => {
871
- const t = v(e);
870
+ }, Kt = (e) => {
871
+ const t = N(e);
872
872
  return t.two.y - t.one.y;
873
- }, er = (e) => H(e, ht), Di = (e) => H(e, _e), Ji = (e) => H(e, Le), Xi = (e) => H(e, Dt), Ki = (e) => H(e, qe), Qi = (e) => H(e, ke), to = (e) => H(e, Ve), eo = (e) => H(e, Fe), Q = (e) => nt(e, "right"), tt = (e) => nt(e, "bottom"), J = (e) => nt(e, "left"), X = (e) => nt(e, "top"), me = (e) => Nt(er(e), {
874
- x: Jt(e) / 2,
875
- y: Xt(e) / 2
873
+ }, nr = (e) => D(e, ht), Gi = (e) => D(e, _e), Hi = (e) => D(e, ke), Di = (e) => D(e, Jt), Ji = (e) => D(e, qe), Xi = (e) => D(e, Le), Ki = (e) => D(e, Ve), Qi = (e) => D(e, Fe), tt = (e) => rt(e, "right"), et = (e) => rt(e, "bottom"), X = (e) => rt(e, "left"), K = (e) => rt(e, "top"), me = (e) => Nt(nr(e), {
874
+ x: Xt(e) / 2,
875
+ y: Kt(e) / 2
876
876
  }), Ge = (e) => {
877
- const t = v(e);
878
- return t.root.x === "left" ? J(t) : Q(t);
877
+ const t = N(e);
878
+ return t.root.x === "left" ? X(t) : tt(t);
879
879
  }, He = (e) => {
880
- const t = v(e);
881
- return t.root.y === "top" ? X(t) : tt(t);
882
- }, no = (e) => ({ x: Ge(e), y: He(e) }), Pt = (e) => {
883
- const t = v(e);
880
+ const t = N(e);
881
+ return t.root.y === "top" ? K(t) : et(t);
882
+ }, to = (e) => ({ x: Ge(e), y: He(e) }), kt = (e) => {
883
+ const t = N(e);
884
884
  return { lower: t.one.x, upper: t.two.x };
885
885
  }, Lt = (e) => {
886
- const t = v(e);
886
+ const t = N(e);
887
887
  return { lower: t.one.y, upper: t.two.y };
888
- }, ro = (e, t) => Qn(e, t), so = (e, t) => {
889
- const n = v(e), r = Gt.includes(t) ? "x" : Ht.includes(t) ? "y" : null;
888
+ }, eo = (e, t) => tr(e, t), no = (e, t) => {
889
+ const n = N(e), r = Ht.includes(t) ? "x" : Dt.includes(t) ? "y" : null;
890
890
  if (r === null) throw new Error(`Invalid location: ${t}`);
891
891
  const s = t === "top" || t === "left" ? Math.min : Math.max, i = { ...n.one }, o = { ...n.two };
892
892
  return i[r] = s(n.one[r], n.two[r]), o[r] = s(n.one[r], n.two[r]), [i, o];
893
- }, io = (e, t) => {
894
- const n = v(e), r = v(t), s = Ge(r) + (U(r) - U(n)) / 2, i = He(r) + (j(r) - j(n)) / 2;
895
- return v({ x: s, y: i }, tr(n));
896
- }, nr = (e) => typeof e != "object" || e == null ? !1 : "one" in e && "two" in e && "root" in e, oo = (e) => U(e) / j(e), co = (e, t, n) => {
893
+ }, ro = (e, t) => {
894
+ const n = N(e), r = N(t), s = Ge(r) + ($(r) - $(n)) / 2, i = He(r) + (U(r) - U(n)) / 2;
895
+ return N({ x: s, y: i }, er(n));
896
+ }, rr = (e) => typeof e != "object" || e == null ? !1 : "one" in e && "two" in e && "root" in e, so = (e) => $(e) / U(e), io = (e, t, n) => {
897
897
  if (typeof t == "string") {
898
898
  if (n == null) throw new Error("Undefined amount passed into box.translate");
899
899
  const s = _(t);
900
- t = I(s, n);
900
+ t = x(s, n);
901
901
  }
902
- const r = v(e);
903
- return v(
902
+ const r = N(e);
903
+ return N(
904
904
  Nt(r.one, t),
905
905
  Nt(r.two, t),
906
906
  void 0,
907
907
  void 0,
908
908
  r.root
909
909
  );
910
- }, ao = (e, t) => {
911
- const n = Math.max(J(e), J(t)), r = Math.max(X(e), X(t)), s = Math.min(Q(e), Q(t)), i = Math.min(tt(e), tt(t));
912
- return n > s || r > i ? Kn : v({ x: n, y: r }, { x: s, y: i }, void 0, void 0, e.root);
913
- }, rr = (e) => U(e) * j(e), uo = (e, t) => {
914
- const n = v(e);
915
- return v(
916
- Vt(n.one, t),
917
- Vt(n.two, t),
910
+ }, oo = (e, t) => {
911
+ const n = Math.max(X(e), X(t)), r = Math.max(K(e), K(t)), s = Math.min(tt(e), tt(t)), i = Math.min(et(e), et(t));
912
+ return n > s || r > i ? Qn : N({ x: n, y: r }, { x: s, y: i }, void 0, void 0, e.root);
913
+ }, sr = (e) => $(e) * U(e), co = (e, t) => {
914
+ const n = N(e);
915
+ return N(
916
+ Wt(n.one, t),
917
+ Wt(n.two, t),
918
918
  void 0,
919
919
  void 0,
920
920
  n.root
921
921
  );
922
- }, lo = (e, t, n, r, s, i) => {
922
+ }, ao = (e, t, n, r, s, i) => {
923
923
  const o = { x: e, y: t }, a = { x: e + n, y: t + r };
924
- return s.x !== i.x && (s.x === "center" ? (o.x -= n / 2, a.x -= n / 2) : (o.x -= n, a.x -= n)), s.y !== i.y && (s.y === "center" ? (o.y -= r / 2, a.y -= r / 2) : (o.y -= r, a.y -= r)), v(o, a, void 0, void 0, i);
925
- }, fo = (e) => {
926
- const t = v(e);
927
- return v(ye(t.one), ye(t.two), void 0, void 0, t.root);
928
- }, Mu = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
924
+ return s.x !== i.x && (s.x === "center" ? (o.x -= n / 2, a.x -= n / 2) : (o.x -= n, a.x -= n)), s.y !== i.y && (s.y === "center" ? (o.y -= r / 2, a.y -= r / 2) : (o.y -= r, a.y -= r)), N(o, a, void 0, void 0, i);
925
+ }, uo = (e) => {
926
+ const t = N(e);
927
+ return N(ye(t.one), ye(t.two), void 0, void 0, t.root);
928
+ }, Nu = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
929
929
  __proto__: null,
930
- DECIMAL: Fi,
931
- ZERO: Kn,
932
- area: rr,
933
- areaIsZero: Hi,
934
- aspect: oo,
935
- bottom: tt,
936
- bottomCenter: Ki,
937
- bottomLeft: Xi,
938
- bottomRight: Qi,
939
- box: qi,
930
+ DECIMAL: _i,
931
+ ZERO: Qn,
932
+ area: sr,
933
+ areaIsZero: Yi,
934
+ aspect: so,
935
+ bottom: et,
936
+ bottomCenter: Ji,
937
+ bottomLeft: Di,
938
+ bottomRight: Xi,
939
+ box: Zi,
940
940
  center: me,
941
- centerLeft: to,
942
- centerRight: eo,
943
- construct: v,
944
- constructWithAlternateRoot: lo,
945
- contains: Wi,
946
- copy: Qn,
947
- css: Gi,
948
- cssBox: Zi,
941
+ centerLeft: Ki,
942
+ centerRight: Qi,
943
+ construct: N,
944
+ constructWithAlternateRoot: ao,
945
+ contains: Fi,
946
+ copy: tr,
947
+ css: zi,
948
+ cssBox: ki,
949
949
  dim: Ye,
950
- dims: tr,
951
- domRect: _i,
952
- edgePoints: so,
953
- equals: zi,
954
- height: j,
955
- intersection: ao,
956
- isBox: nr,
957
- left: J,
958
- loc: nt,
959
- positionInCenter: io,
960
- reRoot: ro,
961
- resize: Vi,
962
- right: Q,
963
- root: no,
964
- round: fo,
965
- signedDims: Yi,
966
- signedHeight: Xt,
967
- signedWidth: Jt,
968
- top: X,
969
- topCenter: Di,
970
- topLeft: er,
971
- topRight: Ji,
972
- translate: co,
973
- truncate: uo,
974
- width: U,
950
+ dims: er,
951
+ domRect: Li,
952
+ edgePoints: no,
953
+ equals: Vi,
954
+ height: U,
955
+ intersection: oo,
956
+ isBox: rr,
957
+ left: X,
958
+ loc: rt,
959
+ positionInCenter: ro,
960
+ reRoot: eo,
961
+ resize: qi,
962
+ right: tt,
963
+ root: to,
964
+ round: uo,
965
+ signedDims: Wi,
966
+ signedHeight: Kt,
967
+ signedWidth: Xt,
968
+ top: K,
969
+ topCenter: Gi,
970
+ topLeft: nr,
971
+ topRight: Hi,
972
+ translate: io,
973
+ truncate: co,
974
+ width: $,
975
975
  x: Ge,
976
- xBounds: Pt,
977
- xyLoc: H,
976
+ xBounds: kt,
977
+ xyLoc: D,
978
978
  y: He,
979
979
  yBounds: Lt
980
- }, Symbol.toStringTag, { value: "Module" })), sr = c.object({ signedWidth: c.number(), signedHeight: c.number() }), ho = c.union([Te, sr, ut, Pn]), go = { width: 0, height: 0 }, yo = { width: 1, height: 1 }, Z = (e, t) => typeof e == "number" ? { width: e, height: t ?? e } : Array.isArray(e) ? { width: e[0], height: e[1] } : "x" in e ? { width: e.x, height: e.y } : "signedWidth" in e ? { width: e.signedWidth, height: e.signedHeight } : { ...e }, mo = (e, t) => {
980
+ }, Symbol.toStringTag, { value: "Module" })), ir = c.object({ signedWidth: c.number(), signedHeight: c.number() }), lo = c.union([Te, ir, ut, kn]), fo = { width: 0, height: 0 }, ho = { width: 1, height: 1 }, Z = (e, t) => typeof e == "number" ? { width: e, height: t ?? e } : Array.isArray(e) ? { width: e[0], height: e[1] } : "x" in e ? { width: e.x, height: e.y } : "signedWidth" in e ? { width: e.signedWidth, height: e.signedHeight } : { ...e }, go = (e, t) => {
981
981
  if (t == null) return !1;
982
982
  const n = Z(e), r = Z(t);
983
983
  return n.width === r.width && n.height === r.height;
984
- }, po = (e) => {
984
+ }, yo = (e) => {
985
985
  const t = Z(e);
986
986
  return { width: t.height, height: t.width };
987
- }, bo = (e) => {
987
+ }, mo = (e) => {
988
988
  const t = Z(e);
989
989
  return `0 0 ${t.width} ${t.height}`;
990
- }, wo = (e) => {
990
+ }, po = (e) => {
991
991
  const t = Z(e);
992
992
  return [t.width, t.height];
993
- }, Oo = (e) => ({
993
+ }, bo = (e) => ({
994
994
  width: Math.max(...e.map((t) => Z(t).width)),
995
995
  height: Math.max(...e.map((t) => Z(t).height))
996
- }), xo = (e) => ({
996
+ }), wo = (e) => ({
997
997
  width: Math.min(...e.map((t) => Z(t).width)),
998
998
  height: Math.min(...e.map((t) => Z(t).height))
999
- }), Io = (e, t) => {
999
+ }), Oo = (e, t) => {
1000
1000
  const n = Z(e);
1001
1001
  return { width: n.width * t, height: n.height * t };
1002
- }, Au = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
1002
+ }, vu = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
1003
1003
  __proto__: null,
1004
- DECIMAL: yo,
1005
- ZERO: go,
1004
+ DECIMAL: ho,
1005
+ ZERO: fo,
1006
1006
  construct: Z,
1007
- couple: wo,
1008
- crude: ho,
1007
+ couple: po,
1008
+ crude: lo,
1009
1009
  dimensions: Te,
1010
- equals: mo,
1011
- max: Oo,
1012
- min: xo,
1013
- scale: Io,
1014
- signed: sr,
1015
- svgViewBox: bo,
1016
- swap: po
1017
- }, Symbol.toStringTag, { value: "Module" })), No = (e, t, n) => t !== void 0 && e < t ? t : n !== void 0 && e > n ? n : e, vo = c.object({ offset: ge, scale: ge }), Mo = c.object({ offset: c.number(), scale: c.number() }), Ao = (e) => (t, n, r, s) => n === "dimension" ? [t, r] : [
1010
+ equals: go,
1011
+ max: bo,
1012
+ min: wo,
1013
+ scale: Oo,
1014
+ signed: ir,
1015
+ svgViewBox: mo,
1016
+ swap: yo
1017
+ }, Symbol.toStringTag, { value: "Module" })), xo = (e, t, n) => t !== void 0 && e < t ? t : n !== void 0 && e > n ? n : e, Io = c.object({ offset: ge, scale: ge }), No = c.object({ offset: c.number(), scale: c.number() }), vo = (e) => (t, n, r, s) => n === "dimension" ? [t, r] : [
1018
1018
  t,
1019
1019
  s ? r - e : r + e
1020
- ], Eo = (e) => (t, n, r, s) => [
1020
+ ], Mo = (e) => (t, n, r, s) => [
1021
1021
  t,
1022
1022
  s ? r / e : r * e
1023
- ], So = (e) => (t, n, r) => {
1023
+ ], Ao = (e) => (t, n, r) => {
1024
1024
  if (t === null) return [e, r];
1025
1025
  const { lower: s, upper: i } = t, { lower: o, upper: a } = e, u = i - s, l = a - o;
1026
1026
  if (n === "dimension") return [e, r * (l / u)];
1027
1027
  const h = (r - s) * (l / u) + o;
1028
1028
  return [e, h];
1029
- }, To = (e) => (t, n, r) => [e, r], $o = () => (e, t, n) => {
1029
+ }, Eo = (e) => (t, n, r) => [e, r], So = () => (e, t, n) => {
1030
1030
  if (e === null) throw new Error("cannot invert without bounds");
1031
1031
  if (t === "dimension") return [e, n];
1032
1032
  const { lower: r, upper: s } = e;
1033
1033
  return [e, s - (n - r)];
1034
- }, Uo = (e) => (t, n, r) => {
1034
+ }, To = (e) => (t, n, r) => {
1035
1035
  const { lower: s, upper: i } = e;
1036
- return r = No(r, s, i), [t, r];
1036
+ return r = xo(r, s, i), [t, r];
1037
1037
  };
1038
1038
  class W {
1039
1039
  ops = [];
@@ -1069,7 +1069,7 @@ class W {
1069
1069
  * @param value - The amount to translate by.
1070
1070
  */
1071
1071
  translate(t) {
1072
- const n = this.new(), r = Ao(t);
1072
+ const n = this.new(), r = vo(t);
1073
1073
  return r.type = "translate", n.ops.push(r), n;
1074
1074
  }
1075
1075
  /**
@@ -1079,23 +1079,23 @@ class W {
1079
1079
  * @param value - The amount to magnify by.
1080
1080
  */
1081
1081
  magnify(t) {
1082
- const n = this.new(), r = Eo(t);
1082
+ const n = this.new(), r = Mo(t);
1083
1083
  return r.type = "magnify", n.ops.push(r), n;
1084
1084
  }
1085
1085
  scale(t, n) {
1086
- const r = w(t, n), s = this.new(), i = So(r);
1086
+ const r = b(t, n), s = this.new(), i = Ao(r);
1087
1087
  return i.type = "scale", s.ops.push(i), s;
1088
1088
  }
1089
1089
  clamp(t, n) {
1090
- const r = w(t, n), s = this.new(), i = Uo(r);
1090
+ const r = b(t, n), s = this.new(), i = To(r);
1091
1091
  return i.type = "clamp", s.ops.push(i), s;
1092
1092
  }
1093
1093
  reBound(t, n) {
1094
- const r = w(t, n), s = this.new(), i = To(r);
1094
+ const r = b(t, n), s = this.new(), i = Eo(r);
1095
1095
  return i.type = "re-bound", s.ops.push(i), s;
1096
1096
  }
1097
1097
  invert() {
1098
- const t = $o();
1098
+ const t = So();
1099
1099
  t.type = "invert";
1100
1100
  const n = this.new();
1101
1101
  return n.ops.push(t), n;
@@ -1164,7 +1164,7 @@ class P {
1164
1164
  return new P().reBound(t);
1165
1165
  }
1166
1166
  translate(t, n) {
1167
- const r = I(t, n), s = this.copy();
1167
+ const r = x(t, n), s = this.copy();
1168
1168
  return s.x = this.x.translate(r.x), s.y = this.y.translate(r.y), s;
1169
1169
  }
1170
1170
  translateX(t) {
@@ -1181,19 +1181,19 @@ class P {
1181
1181
  }
1182
1182
  scale(t) {
1183
1183
  const n = this.copy();
1184
- if (nr(t)) {
1184
+ if (rr(t)) {
1185
1185
  const r = this.currRoot;
1186
- return n.currRoot = t.root, r != null && !We(r, t.root) && (r.x !== t.root.x && (n.x = n.x.invert()), r.y !== t.root.y && (n.y = n.y.invert())), n.x = n.x.scale(Pt(t)), n.y = n.y.scale(Lt(t)), n;
1186
+ return n.currRoot = t.root, r != null && !We(r, t.root) && (r.x !== t.root.x && (n.x = n.x.invert()), r.y !== t.root.y && (n.y = n.y.invert())), n.x = n.x.scale(kt(t)), n.y = n.y.scale(Lt(t)), n;
1187
1187
  }
1188
1188
  return n.x = n.x.scale(t.width), n.y = n.y.scale(t.height), n;
1189
1189
  }
1190
1190
  reBound(t) {
1191
1191
  const n = this.copy();
1192
- return n.x = this.x.reBound(Pt(t)), n.y = this.y.reBound(Lt(t)), n;
1192
+ return n.x = this.x.reBound(kt(t)), n.y = this.y.reBound(Lt(t)), n;
1193
1193
  }
1194
1194
  clamp(t) {
1195
1195
  const n = this.copy();
1196
- return n.x = this.x.clamp(Pt(t)), n.y = this.y.clamp(Lt(t)), n;
1196
+ return n.x = this.x.clamp(kt(t)), n.y = this.y.clamp(Lt(t)), n;
1197
1197
  }
1198
1198
  copy() {
1199
1199
  const t = new P();
@@ -1210,7 +1210,7 @@ class P {
1210
1210
  return { x: this.x.dim(t.x), y: this.y.dim(t.y) };
1211
1211
  }
1212
1212
  box(t) {
1213
- return v(
1213
+ return N(
1214
1214
  this.pos(t.one),
1215
1215
  this.pos(t.two),
1216
1216
  0,
@@ -1226,35 +1226,35 @@ class P {
1226
1226
  }
1227
1227
  static IDENTITY = new P();
1228
1228
  }
1229
- const Eu = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
1229
+ const Mu = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
1230
1230
  __proto__: null,
1231
1231
  Scale: W,
1232
1232
  XY: P,
1233
- crudeXYTransform: vo,
1234
- transform: Mo
1235
- }, Symbol.toStringTag, { value: "Module" })), Su = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
1233
+ crudeXYTransform: Io,
1234
+ transform: No
1235
+ }, Symbol.toStringTag, { value: "Module" })), Au = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
1236
1236
  __proto__: null,
1237
1237
  ALIGNMENTS: Ln,
1238
- ORDERS: Zn,
1239
- alignment: Ps,
1240
- order: Ls
1241
- }, Symbol.toStringTag, { value: "Module" })), ir = ut.extend({
1242
- root: Pe,
1243
- units: b.object({
1244
- x: b.enum(["px", "decimal"]),
1245
- y: b.enum(["px", "decimal"])
1238
+ ORDERS: _n,
1239
+ alignment: Bs,
1240
+ order: Ps
1241
+ }, Symbol.toStringTag, { value: "Module" })), or = ut.extend({
1242
+ root: Re,
1243
+ units: k.object({
1244
+ x: k.enum(["px", "decimal"]),
1245
+ y: k.enum(["px", "decimal"])
1246
1246
  })
1247
- }), jo = ir.partial({ root: !0, units: !0 }), Co = (e) => {
1247
+ }), $o = or.partial({ root: !0, units: !0 }), Uo = (e) => {
1248
1248
  const t = {};
1249
1249
  return t[e.root?.x ?? "left"] = e?.units?.x === "px" ? `${e.x}px` : `${e.x * 100}%`, t[e.root?.y ?? "top"] = e?.units?.y === "px" ? `${e.y}px` : `${e.y * 100}%`, t;
1250
- }, Bo = ({
1250
+ }, jo = ({
1251
1251
  position: e,
1252
1252
  element: t,
1253
1253
  container: n
1254
1254
  }) => {
1255
1255
  const r = { x: e.x, y: e.y };
1256
- return e.units?.x === "decimal" ? e.root?.x === "right" && (r.x = 1 - e.x) : e.root?.x === "right" ? r.x = 1 - (e.x + U(t)) / U(n) : r.x /= U(n), e.units?.y === "decimal" ? e.root?.y === "bottom" && (r.y = 1 - e.y) : e.root?.y === "bottom" ? r.y = 1 - (e.y + j(t)) / j(n) : r.y /= j(n), r;
1257
- }, Ro = ({
1256
+ return e.units?.x === "decimal" ? e.root?.x === "right" && (r.x = 1 - e.x) : e.root?.x === "right" ? r.x = 1 - (e.x + $(t)) / $(n) : r.x /= $(n), e.units?.y === "decimal" ? e.root?.y === "bottom" && (r.y = 1 - e.y) : e.root?.y === "bottom" ? r.y = 1 - (e.y + U(t)) / U(n) : r.y /= U(n), r;
1257
+ }, Co = ({
1258
1258
  position: e,
1259
1259
  element: t,
1260
1260
  container: n,
@@ -1267,19 +1267,19 @@ const Eu = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
1267
1267
  root: { ...ht },
1268
1268
  units: { x: "px", y: "px" }
1269
1269
  };
1270
- return e.x > s ? (i.x = (1 - e.x) * U(n) - U(t), i.root.x = "right") : e.x < r ? i.x = e.x * U(n) : i.units.x = "decimal", e.y > s ? (i.y = (1 - e.y) * j(n) - j(t), i.root.y = "bottom") : e.y < r ? i.y = e.y * j(n) : i.units.y = "decimal", i.x = Math.round(i.x * 100) / 100, { ...i, ...Vt(i, 3) };
1271
- }, Tu = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
1270
+ return e.x > s ? (i.x = (1 - e.x) * $(n) - $(t), i.root.x = "right") : e.x < r ? i.x = e.x * $(n) : i.units.x = "decimal", e.y > s ? (i.y = (1 - e.y) * U(n) - U(t), i.root.y = "bottom") : e.y < r ? i.y = e.y * U(n) : i.units.y = "decimal", i.x = Math.round(i.x * 100) / 100, { ...i, ...Wt(i, 3) };
1271
+ }, Eu = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
1272
1272
  __proto__: null,
1273
- calculate: Ro,
1274
- completeXY: ir,
1275
- toCSS: Co,
1276
- toDecimal: Bo,
1277
- xy: jo
1278
- }, Symbol.toStringTag, { value: "Module" })), Po = c.enum(["static", "dynamic"]), sn = 365, Ut = 30, Lo = c.union([
1273
+ calculate: Co,
1274
+ completeXY: or,
1275
+ toCSS: Uo,
1276
+ toDecimal: jo,
1277
+ xy: $o
1278
+ }, Symbol.toStringTag, { value: "Module" })), Bo = c.enum(["static", "dynamic"]), on = 365, jt = 30, Po = c.union([
1279
1279
  c.tuple([c.int()]),
1280
1280
  c.tuple([c.int(), c.int().min(1).max(12)]),
1281
1281
  c.tuple([c.int(), c.int().min(1).max(12), c.int().min(1).max(31)])
1282
- ]), or = (e, t) => {
1282
+ ]), cr = (e, t) => {
1283
1283
  const n = new d(t);
1284
1284
  if (![
1285
1285
  g.DAY,
@@ -1296,7 +1296,7 @@ const Eu = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
1296
1296
  const r = e.valueOf() % n.valueOf();
1297
1297
  return e instanceof d ? new d(r) : new g(r);
1298
1298
  };
1299
- class d extends rt {
1299
+ class d extends st {
1300
1300
  constructor(t, n = "UTC") {
1301
1301
  if (t == null) super(d.now().valueOf());
1302
1302
  else if (t instanceof Date)
@@ -1306,7 +1306,7 @@ class d extends rt {
1306
1306
  else if (Array.isArray(t)) super(d.parseDate(t));
1307
1307
  else {
1308
1308
  let r = 0n;
1309
- t instanceof Number && (t = t.valueOf()), n === "local" && (r = d.utcOffset.valueOf()), typeof t == "number" && (isFinite(t) ? t === Cn ? t = _t : t = Math.trunc(t) : (isNaN(t) && (t = 0), t === 1 / 0 ? t = d.MAX : t = d.MIN)), B(t) && (t = t.value), super(BigInt(t.valueOf()) + r);
1309
+ t instanceof Number && (t = t.valueOf()), n === "local" && (r = d.utcOffset.valueOf()), typeof t == "number" && (isFinite(t) ? t === Bn ? t = qt : t = Math.trunc(t) : (isNaN(t) && (t = 0), t === 1 / 0 ? t = d.MAX : t = d.MIN)), C(t) && (t = t.value), super(BigInt(t.valueOf()) + r);
1310
1310
  }
1311
1311
  }
1312
1312
  static parseDate([t = 1970, n = 1, r = 1]) {
@@ -1403,7 +1403,7 @@ class d extends rt {
1403
1403
  * valid, regardless of the TimeStamp order.
1404
1404
  */
1405
1405
  range(t) {
1406
- return new E(this, t).makeValid();
1406
+ return new A(this, t).makeValid();
1407
1407
  }
1408
1408
  /**
1409
1409
  * Creates a TimeRange starting at the TimeStamp and spanning the given
@@ -1673,7 +1673,7 @@ class d extends rt {
1673
1673
  * @example TimeStamp.now().remainder(TimeStamp.DAY) // => TimeStamp representing the current day
1674
1674
  */
1675
1675
  remainder(t) {
1676
- return or(this, t);
1676
+ return cr(this, t);
1677
1677
  }
1678
1678
  /** @returns true if the day portion TimeStamp is today, false otherwise. */
1679
1679
  get isToday() {
@@ -1788,7 +1788,7 @@ class d extends rt {
1788
1788
  /** One day after the unix epoch */
1789
1789
  static DAY = d.days(1);
1790
1790
  /** The maximum possible value for a timestamp */
1791
- static MAX = new d(_t);
1791
+ static MAX = new d(qt);
1792
1792
  /** The minimum possible value for a timestamp */
1793
1793
  static MIN = new d(0);
1794
1794
  /** The unix epoch */
@@ -1802,7 +1802,7 @@ class d extends rt {
1802
1802
  c.bigint().transform((t) => new d(t)),
1803
1803
  c.date().transform((t) => new d(t)),
1804
1804
  c.custom((t) => t instanceof g).transform((t) => new d(t)),
1805
- Lo.transform((t) => new d(t))
1805
+ Po.transform((t) => new d(t))
1806
1806
  ]);
1807
1807
  /**
1808
1808
  * Sorts two timestamps.
@@ -1816,9 +1816,9 @@ class d extends rt {
1816
1816
  return Number(t.valueOf() - n.valueOf());
1817
1817
  }
1818
1818
  }
1819
- class g extends rt {
1819
+ class g extends st {
1820
1820
  constructor(t) {
1821
- typeof t == "number" && (t = Math.trunc(t.valueOf())), B(t) && (t = t.value), super(BigInt(t.valueOf()));
1821
+ typeof t == "number" && (t = Math.trunc(t.valueOf())), C(t) && (t = t.value), super(BigInt(t.valueOf()));
1822
1822
  }
1823
1823
  /**
1824
1824
  * Creates a TimeSpan representing the given number of seconds.
@@ -1827,7 +1827,7 @@ class g extends rt {
1827
1827
  * @returns A TimeSpan representing the given number of seconds.
1828
1828
  */
1829
1829
  static fromSeconds(t) {
1830
- return t instanceof g ? t : t instanceof $ ? t.period : t instanceof d ? new g(t) : (B(t) && (t = t.value), ["number", "bigint"].includes(typeof t) ? g.seconds(t) : new g(t));
1830
+ return t instanceof g ? t : t instanceof T ? t.period : t instanceof d ? new g(t) : (C(t) && (t = t.value), ["number", "bigint"].includes(typeof t) ? g.seconds(t) : new g(t));
1831
1831
  }
1832
1832
  /**
1833
1833
  * Creates a TimeSpan representing the given number of milliseconds.
@@ -1836,7 +1836,7 @@ class g extends rt {
1836
1836
  * @returns A TimeSpan representing the given number of milliseconds.
1837
1837
  */
1838
1838
  static fromMilliseconds(t) {
1839
- return t instanceof g ? t : t instanceof $ ? t.period : t instanceof d ? new g(t) : (B(t) && (t = t.value), ["number", "bigint"].includes(typeof t) ? g.milliseconds(t) : new g(t));
1839
+ return t instanceof g ? t : t instanceof T ? t.period : t instanceof d ? new g(t) : (C(t) && (t = t.value), ["number", "bigint"].includes(typeof t) ? g.milliseconds(t) : new g(t));
1840
1840
  }
1841
1841
  /**
1842
1842
  * @returns the primitive value of the TimeSpan. Overrides standard JS valueOf()
@@ -1888,7 +1888,7 @@ class g extends rt {
1888
1888
  * @returns A new TimeSpan representing the remainder.
1889
1889
  */
1890
1890
  remainder(t) {
1891
- return or(this, t);
1891
+ return cr(this, t);
1892
1892
  }
1893
1893
  /**
1894
1894
  * Truncates the TimeSpan to the nearest multiple of the given span.
@@ -1911,65 +1911,65 @@ class g extends rt {
1911
1911
  */
1912
1912
  toString(t = "full") {
1913
1913
  if (t === "semantic") return this.toSemanticString();
1914
- const n = this.truncate(g.DAY), r = this.truncate(g.HOUR), s = this.truncate(g.MINUTE), i = this.truncate(g.SECOND), o = this.truncate(g.MILLISECOND), a = this.truncate(g.MICROSECOND), u = this.truncate(g.NANOSECOND), l = n, h = r.sub(n), y = s.sub(r), m = i.sub(s), A = o.sub(i), T = a.sub(o), R = u.sub(a);
1915
- let O = "";
1916
- return l.isZero || (O += `${l.days}d `), h.isZero || (O += `${h.hours}h `), y.isZero || (O += `${y.minutes}m `), m.isZero || (O += `${m.seconds}s `), A.isZero || (O += `${A.milliseconds}ms `), T.isZero || (O += `${T.microseconds}µs `), R.isZero || (O += `${R.nanoseconds}ns`), O.trim();
1914
+ const n = this.truncate(g.DAY), r = this.truncate(g.HOUR), s = this.truncate(g.MINUTE), i = this.truncate(g.SECOND), o = this.truncate(g.MILLISECOND), a = this.truncate(g.MICROSECOND), u = this.truncate(g.NANOSECOND), l = n, h = r.sub(n), y = s.sub(r), m = i.sub(s), M = o.sub(i), S = a.sub(o), B = u.sub(a);
1915
+ let w = "";
1916
+ return l.isZero || (w += `${l.days}d `), h.isZero || (w += `${h.hours}h `), y.isZero || (w += `${y.minutes}m `), m.isZero || (w += `${m.seconds}s `), M.isZero || (w += `${M.milliseconds}ms `), S.isZero || (w += `${S.microseconds}µs `), B.isZero || (w += `${B.nanoseconds}ns`), w.trim();
1917
1917
  }
1918
1918
  toSemanticString() {
1919
1919
  const t = this.valueOf() < 0n ? -this.valueOf() : this.valueOf(), n = new g(t), r = this.valueOf() < 0n;
1920
1920
  if (n.valueOf() === 0n) return "0s";
1921
1921
  if (n.lessThan(g.SECOND)) return "< 1s";
1922
- const s = n.days, i = n.hours, o = n.minutes, a = n.seconds, u = Math.floor(s / sn), l = Math.floor(s / Ut), h = Math.floor(s / 7), y = Math.floor(s), m = Math.floor(i), A = Math.floor(o), T = Math.floor(a), R = r ? "-" : "";
1922
+ const s = n.days, i = n.hours, o = n.minutes, a = n.seconds, u = Math.floor(s / on), l = Math.floor(s / jt), h = Math.floor(s / 7), y = Math.floor(s), m = Math.floor(i), M = Math.floor(o), S = Math.floor(a), B = r ? "-" : "";
1923
1923
  if (u >= 1) {
1924
- let O = `${u}y`;
1924
+ let w = `${u}y`;
1925
1925
  if (u < 2) {
1926
- const M = Math.floor(
1927
- s % sn / Ut
1926
+ const v = Math.floor(
1927
+ s % on / jt
1928
1928
  );
1929
- M > 0 && (O += ` ${M}mo`);
1929
+ v > 0 && (w += ` ${v}mo`);
1930
1930
  }
1931
- return R + O;
1931
+ return B + w;
1932
1932
  }
1933
- if (h >= 1 && s < Ut && s % 7 === 0) {
1934
- let O = `${h}w`;
1935
- const M = Math.floor(s % 7), K = Math.floor(i - h * 7 * 24);
1936
- return h < 2 && (M > 0 ? O += ` ${M}d` : K > 0 && K < 24 && (O += ` ${K}h`)), R + O;
1933
+ if (h >= 1 && s < jt && s % 7 === 0) {
1934
+ let w = `${h}w`;
1935
+ const v = Math.floor(s % 7), Q = Math.floor(i - h * 7 * 24);
1936
+ return h < 2 && (v > 0 ? w += ` ${v}d` : Q > 0 && Q < 24 && (w += ` ${Q}h`)), B + w;
1937
1937
  }
1938
1938
  if (l >= 1) {
1939
- let O = `${l}mo`;
1939
+ let w = `${l}mo`;
1940
1940
  if (l < 3) {
1941
- const M = Math.floor(s % Ut);
1942
- M > 0 && (O += ` ${M}d`);
1941
+ const v = Math.floor(s % jt);
1942
+ v > 0 && (w += ` ${v}d`);
1943
1943
  }
1944
- return R + O;
1944
+ return B + w;
1945
1945
  }
1946
1946
  if (h >= 1) {
1947
- let O = `${h}w`;
1948
- const M = Math.floor(s % 7), K = Math.floor(i - h * 7 * 24);
1949
- return h < 2 && (M > 0 ? O += ` ${M}d` : K > 0 && K < 24 && (O += ` ${K}h`)), R + O;
1947
+ let w = `${h}w`;
1948
+ const v = Math.floor(s % 7), Q = Math.floor(i - h * 7 * 24);
1949
+ return h < 2 && (v > 0 ? w += ` ${v}d` : Q > 0 && Q < 24 && (w += ` ${Q}h`)), B + w;
1950
1950
  }
1951
1951
  if (y >= 1) {
1952
- let O = `${y}d`;
1953
- const M = Math.floor(i - y * 24);
1954
- return y < 2 && M > 0 && (O += ` ${M}h`), R + O;
1952
+ let w = `${y}d`;
1953
+ const v = Math.floor(i - y * 24);
1954
+ return y < 2 && v > 0 && (w += ` ${v}h`), B + w;
1955
1955
  }
1956
1956
  if (m >= 1) {
1957
- let O = `${m}h`;
1957
+ let w = `${m}h`;
1958
1958
  if (m < 3) {
1959
- const M = Math.floor(o - m * 60);
1960
- M > 0 && (O += ` ${M}m`);
1959
+ const v = Math.floor(o - m * 60);
1960
+ v > 0 && (w += ` ${v}m`);
1961
1961
  }
1962
- return R + O;
1962
+ return B + w;
1963
1963
  }
1964
- if (A >= 1) {
1965
- let O = `${A}m`;
1966
- if (A < 5) {
1967
- const M = Math.floor(a - A * 60);
1968
- M > 0 && (O += ` ${M}s`);
1964
+ if (M >= 1) {
1965
+ let w = `${M}m`;
1966
+ if (M < 5) {
1967
+ const v = Math.floor(a - M * 60);
1968
+ v > 0 && (w += ` ${v}s`);
1969
1969
  }
1970
- return R + O;
1970
+ return B + w;
1971
1971
  }
1972
- return `${R}${T}s`;
1972
+ return `${B}${S}s`;
1973
1973
  }
1974
1974
  /**
1975
1975
  * Multiplies the TimeSpan by a scalar value.
@@ -1978,7 +1978,7 @@ class g extends rt {
1978
1978
  * @returns A new TimeSpan that is this TimeSpan multiplied by the provided value.
1979
1979
  */
1980
1980
  mult(t) {
1981
- return new g(L(this.valueOf(), t));
1981
+ return new g(R(this.valueOf(), t));
1982
1982
  }
1983
1983
  /**
1984
1984
  * Divides the TimeSpan by a scalar value.
@@ -2067,7 +2067,7 @@ class g extends rt {
2067
2067
  * @returns A TimeSpan representing the given number of microseconds.
2068
2068
  */
2069
2069
  static microseconds(t = 1) {
2070
- return g.nanoseconds(L(t, 1e3));
2070
+ return g.nanoseconds(R(t, 1e3));
2071
2071
  }
2072
2072
  /** A microsecond. */
2073
2073
  static MICROSECOND = g.microseconds(1);
@@ -2078,7 +2078,7 @@ class g extends rt {
2078
2078
  * @returns A TimeSpan representing the given number of milliseconds.
2079
2079
  */
2080
2080
  static milliseconds(t = 1) {
2081
- return g.microseconds(L(t, 1e3));
2081
+ return g.microseconds(R(t, 1e3));
2082
2082
  }
2083
2083
  /** A millisecond. */
2084
2084
  static MILLISECOND = g.milliseconds(1);
@@ -2089,7 +2089,7 @@ class g extends rt {
2089
2089
  * @returns A TimeSpan representing the given number of seconds.
2090
2090
  */
2091
2091
  static seconds(t = 1) {
2092
- return g.milliseconds(L(t, 1e3));
2092
+ return g.milliseconds(R(t, 1e3));
2093
2093
  }
2094
2094
  /** A second. */
2095
2095
  static SECOND = g.seconds(1);
@@ -2100,7 +2100,7 @@ class g extends rt {
2100
2100
  * @returns A TimeSpan representing the given number of minutes.
2101
2101
  */
2102
2102
  static minutes(t = 1) {
2103
- return g.seconds(L(t, 60));
2103
+ return g.seconds(R(t, 60));
2104
2104
  }
2105
2105
  /** A minute. */
2106
2106
  static MINUTE = g.minutes(1);
@@ -2111,7 +2111,7 @@ class g extends rt {
2111
2111
  * @returns A TimeSpan representing the given number of hours.
2112
2112
  */
2113
2113
  static hours(t) {
2114
- return g.minutes(L(t, 60));
2114
+ return g.minutes(R(t, 60));
2115
2115
  }
2116
2116
  /** Represents an hour. */
2117
2117
  static HOUR = g.hours(1);
@@ -2122,12 +2122,12 @@ class g extends rt {
2122
2122
  * @returns A TimeSpan representing the given number of days.
2123
2123
  */
2124
2124
  static days(t) {
2125
- return g.hours(L(t, 24));
2125
+ return g.hours(R(t, 24));
2126
2126
  }
2127
2127
  /** Represents a day. */
2128
2128
  static DAY = g.days(1);
2129
2129
  /** The maximum possible value for a TimeSpan. */
2130
- static MAX = new g(_t);
2130
+ static MAX = new g(qt);
2131
2131
  /** The minimum possible value for a TimeSpan. */
2132
2132
  static MIN = new g(0);
2133
2133
  /** The zero value for a TimeSpan. */
@@ -2140,12 +2140,12 @@ class g extends rt {
2140
2140
  c.bigint().transform((t) => new g(t)),
2141
2141
  c.instanceof(g),
2142
2142
  c.instanceof(d).transform((t) => new g(t)),
2143
- c.custom((t) => t instanceof $).transform((t) => new g(t))
2143
+ c.custom((t) => t instanceof T).transform((t) => new g(t))
2144
2144
  ]);
2145
2145
  }
2146
- class $ extends rt {
2146
+ class T extends st {
2147
2147
  constructor(t) {
2148
- B(t) && (t = t.value), super(t.valueOf());
2148
+ C(t) && (t = t.value), super(t.valueOf());
2149
2149
  }
2150
2150
  /** @returns a pretty string representation of the rate in the format "X Hz". */
2151
2151
  toString() {
@@ -2153,7 +2153,7 @@ class $ extends rt {
2153
2153
  }
2154
2154
  /** @returns The number of seconds in the Rate. */
2155
2155
  equals(t) {
2156
- return this.valueOf() === new $(t).valueOf();
2156
+ return this.valueOf() === new T(t).valueOf();
2157
2157
  }
2158
2158
  /**
2159
2159
  * Calculates the period of the Rate as a TimeSpan.
@@ -2180,7 +2180,7 @@ class $ extends rt {
2180
2180
  * @returns The number of bytes in the given TimeSpan at this rate.
2181
2181
  */
2182
2182
  byteCount(t, n) {
2183
- return this.sampleCount(t) * new x(n).valueOf();
2183
+ return this.sampleCount(t) * new O(n).valueOf();
2184
2184
  }
2185
2185
  /**
2186
2186
  * Calculates a TimeSpan given the number of samples at this rate.
@@ -2199,7 +2199,7 @@ class $ extends rt {
2199
2199
  * @returns A TimeSpan that corresponds to the given number of bytes.
2200
2200
  */
2201
2201
  byteSpan(t, n) {
2202
- return this.span(t.valueOf() / new x(n).valueOf());
2202
+ return this.span(t.valueOf() / new O(n).valueOf());
2203
2203
  }
2204
2204
  /**
2205
2205
  * Adds another Rate to this Rate.
@@ -2208,7 +2208,7 @@ class $ extends rt {
2208
2208
  * @returns A new Rate representing the sum of the two rates.
2209
2209
  */
2210
2210
  add(t) {
2211
- return new $(G(this.valueOf(), new $(t).valueOf()));
2211
+ return new T(G(this.valueOf(), new T(t).valueOf()));
2212
2212
  }
2213
2213
  /**
2214
2214
  * Subtracts another Rate from this Rate.
@@ -2217,7 +2217,7 @@ class $ extends rt {
2217
2217
  * @returns A new Rate representing the difference of the two rates.
2218
2218
  */
2219
2219
  sub(t) {
2220
- return new $(F(this.valueOf(), new $(t).valueOf()));
2220
+ return new T(F(this.valueOf(), new T(t).valueOf()));
2221
2221
  }
2222
2222
  /**
2223
2223
  * Multiplies this Rate by a scalar value.
@@ -2226,7 +2226,7 @@ class $ extends rt {
2226
2226
  * @returns A new Rate representing this Rate multiplied by the value.
2227
2227
  */
2228
2228
  mult(t) {
2229
- return new $(L(this.valueOf(), t));
2229
+ return new T(R(this.valueOf(), t));
2230
2230
  }
2231
2231
  /**
2232
2232
  * Divides this Rate by a scalar value.
@@ -2235,7 +2235,7 @@ class $ extends rt {
2235
2235
  * @returns A new Rate representing this Rate divided by the value.
2236
2236
  */
2237
2237
  div(t) {
2238
- return new $(Et(this.valueOf(), t));
2238
+ return new T(Et(this.valueOf(), t));
2239
2239
  }
2240
2240
  /**
2241
2241
  * Creates a Rate representing the given number of Hz.
@@ -2244,7 +2244,7 @@ class $ extends rt {
2244
2244
  * @returns A Rate representing the given number of Hz.
2245
2245
  */
2246
2246
  static hz(t) {
2247
- return new $(t);
2247
+ return new T(t);
2248
2248
  }
2249
2249
  /**
2250
2250
  * Creates a Rate representing the given number of kHz.
@@ -2253,15 +2253,15 @@ class $ extends rt {
2253
2253
  * @returns A Rate representing the given number of kHz.
2254
2254
  */
2255
2255
  static khz(t) {
2256
- return $.hz(t * 1e3);
2256
+ return T.hz(t * 1e3);
2257
2257
  }
2258
2258
  /** A zod schema for validating and transforming rates */
2259
2259
  static z = c.union([
2260
- c.number().transform((t) => new $(t)),
2261
- c.instanceof($)
2260
+ c.number().transform((t) => new T(t)),
2261
+ c.instanceof(T)
2262
2262
  ]);
2263
2263
  }
2264
- class x extends rt {
2264
+ class O extends st {
2265
2265
  /**
2266
2266
  * Creates a Density representing the given number of bytes per value.
2267
2267
  *
@@ -2270,7 +2270,7 @@ class x extends rt {
2270
2270
  * @returns A Density representing the given number of bytes per value.
2271
2271
  */
2272
2272
  constructor(t) {
2273
- B(t) && (t = t.value), super(t.valueOf());
2273
+ C(t) && (t = t.value), super(t.valueOf());
2274
2274
  }
2275
2275
  /**
2276
2276
  * Calculates the number of values in the given Size.
@@ -2297,7 +2297,7 @@ class x extends rt {
2297
2297
  * @returns A new Density representing the sum of the two densities.
2298
2298
  */
2299
2299
  add(t) {
2300
- return new x(G(this.valueOf(), new x(t).valueOf()));
2300
+ return new O(G(this.valueOf(), new O(t).valueOf()));
2301
2301
  }
2302
2302
  /**
2303
2303
  * Subtracts another Density from this Density.
@@ -2306,7 +2306,7 @@ class x extends rt {
2306
2306
  * @returns A new Density representing the difference of the two densities.
2307
2307
  */
2308
2308
  sub(t) {
2309
- return new x(F(this.valueOf(), new x(t).valueOf()));
2309
+ return new O(F(this.valueOf(), new O(t).valueOf()));
2310
2310
  }
2311
2311
  /**
2312
2312
  * Multiplies this Density by a scalar value.
@@ -2315,7 +2315,7 @@ class x extends rt {
2315
2315
  * @returns A new Density representing this Density multiplied by the value.
2316
2316
  */
2317
2317
  mult(t) {
2318
- return new x(L(this.valueOf(), t));
2318
+ return new O(R(this.valueOf(), t));
2319
2319
  }
2320
2320
  /**
2321
2321
  * Divides this Density by a scalar value.
@@ -2324,27 +2324,27 @@ class x extends rt {
2324
2324
  * @returns A new Density representing this Density divided by the value.
2325
2325
  */
2326
2326
  div(t) {
2327
- return new x(Et(this.valueOf(), t));
2327
+ return new O(Et(this.valueOf(), t));
2328
2328
  }
2329
2329
  /** Unknown/Invalid Density. */
2330
- static UNKNOWN = new x(0);
2330
+ static UNKNOWN = new O(0);
2331
2331
  /** 128 bits per value. */
2332
- static BIT128 = new x(16);
2332
+ static BIT128 = new O(16);
2333
2333
  /** 64 bits per value. */
2334
- static BIT64 = new x(8);
2334
+ static BIT64 = new O(8);
2335
2335
  /** 32 bits per value. */
2336
- static BIT32 = new x(4);
2336
+ static BIT32 = new O(4);
2337
2337
  /** 16 bits per value. */
2338
- static BIT16 = new x(2);
2338
+ static BIT16 = new O(2);
2339
2339
  /** 8 bits per value. */
2340
- static BIT8 = new x(1);
2340
+ static BIT8 = new O(1);
2341
2341
  /** A zod schema for validating and transforming densities */
2342
2342
  static z = c.union([
2343
- c.number().transform((t) => new x(t)),
2344
- c.instanceof(x)
2343
+ c.number().transform((t) => new O(t)),
2344
+ c.instanceof(O)
2345
2345
  ]);
2346
2346
  }
2347
- class E {
2347
+ class A {
2348
2348
  /**
2349
2349
  * The starting TimeStamp of the TimeRange.
2350
2350
  *
@@ -2412,7 +2412,7 @@ class E {
2412
2412
  * @returns A TimeRange with the start and end swapped.
2413
2413
  */
2414
2414
  swap() {
2415
- return new E(this.end, this.start);
2415
+ return new A(this.end, this.start);
2416
2416
  }
2417
2417
  get numericBounds() {
2418
2418
  return {
@@ -2468,7 +2468,7 @@ class E {
2468
2468
  return i.before(s) ? !1 : new g(i.sub(s)).greaterThanOrEqual(n);
2469
2469
  }
2470
2470
  contains(t) {
2471
- return t instanceof E ? this.contains(t.start) && this.contains(t.end) : this.start.beforeEq(t) && this.end.after(t);
2471
+ return t instanceof A ? this.contains(t.start) && this.contains(t.end) : this.start.beforeEq(t) && this.end.after(t);
2472
2472
  }
2473
2473
  /**
2474
2474
  * Returns a new TimeRange that is bound by the given TimeRange.
@@ -2482,23 +2482,23 @@ class E {
2482
2482
  * console.log(bounded); // TimeRange(1500, 2000)
2483
2483
  */
2484
2484
  boundBy(t) {
2485
- const n = new E(this.start, this.end);
2485
+ const n = new A(this.start, this.end);
2486
2486
  return t.start.after(this.start) && (n.start = t.start), t.start.after(this.end) && (n.end = t.start), t.end.before(this.end) && (n.end = t.end), t.end.before(this.start) && (n.start = t.end), n;
2487
2487
  }
2488
2488
  static max(...t) {
2489
- return new E(
2489
+ return new A(
2490
2490
  d.min(...t.map((n) => n.start)),
2491
2491
  d.max(...t.map((n) => n.end))
2492
2492
  );
2493
2493
  }
2494
2494
  /** The maximum possible time range. */
2495
- static MAX = new E(d.MIN, d.MAX);
2495
+ static MAX = new A(d.MIN, d.MAX);
2496
2496
  /** A time range whose start and end are both zero. */
2497
- static ZERO = new E(d.ZERO, d.ZERO);
2497
+ static ZERO = new A(d.ZERO, d.ZERO);
2498
2498
  /** A zod schema for validating and transforming time ranges */
2499
2499
  static z = c.union([
2500
- c.object({ start: d.z, end: d.z }).transform((t) => new E(t.start, t.end)),
2501
- c.instanceof(E)
2500
+ c.object({ start: d.z, end: d.z }).transform((t) => new A(t.start, t.end)),
2501
+ c.instanceof(A)
2502
2502
  ]);
2503
2503
  /**
2504
2504
  * Sorts two time ranges. The range with the earlier start time is considered less than
@@ -2522,12 +2522,12 @@ class E {
2522
2522
  * is the minimum of the start times and the end is the maximum of the end times.
2523
2523
  */
2524
2524
  static merge(...t) {
2525
- return E.max(...t.map((n) => new E(n).makeValid()));
2525
+ return A.max(...t.map((n) => new A(n).makeValid()));
2526
2526
  }
2527
2527
  }
2528
- class f extends rt {
2528
+ class f extends st {
2529
2529
  constructor(t) {
2530
- if (B(t) && (t = t.value), t instanceof f || typeof t == "string" || typeof t.valueOf() == "string")
2530
+ if (C(t) && (t = t.value), t instanceof f || typeof t == "string" || typeof t.valueOf() == "string")
2531
2531
  super(t.valueOf());
2532
2532
  else {
2533
2533
  const n = f.ARRAY_CONSTRUCTOR_DATA_TYPES.get(t.constructor.name);
@@ -2705,20 +2705,20 @@ class f extends rt {
2705
2705
  [BigInt64Array.name, f.INT64]
2706
2706
  ]);
2707
2707
  static DENSITIES = /* @__PURE__ */ new Map([
2708
- [f.UINT8.toString(), x.BIT8],
2709
- [f.UINT16.toString(), x.BIT16],
2710
- [f.UINT32.toString(), x.BIT32],
2711
- [f.UINT64.toString(), x.BIT64],
2712
- [f.FLOAT32.toString(), x.BIT32],
2713
- [f.FLOAT64.toString(), x.BIT64],
2714
- [f.INT8.toString(), x.BIT8],
2715
- [f.INT16.toString(), x.BIT16],
2716
- [f.INT32.toString(), x.BIT32],
2717
- [f.INT64.toString(), x.BIT64],
2718
- [f.TIMESTAMP.toString(), x.BIT64],
2719
- [f.STRING.toString(), x.UNKNOWN],
2720
- [f.JSON.toString(), x.UNKNOWN],
2721
- [f.UUID.toString(), x.BIT128]
2708
+ [f.UINT8.toString(), O.BIT8],
2709
+ [f.UINT16.toString(), O.BIT16],
2710
+ [f.UINT32.toString(), O.BIT32],
2711
+ [f.UINT64.toString(), O.BIT64],
2712
+ [f.FLOAT32.toString(), O.BIT32],
2713
+ [f.FLOAT64.toString(), O.BIT64],
2714
+ [f.INT8.toString(), O.BIT8],
2715
+ [f.INT16.toString(), O.BIT16],
2716
+ [f.INT32.toString(), O.BIT32],
2717
+ [f.INT64.toString(), O.BIT64],
2718
+ [f.TIMESTAMP.toString(), O.BIT64],
2719
+ [f.STRING.toString(), O.UNKNOWN],
2720
+ [f.JSON.toString(), O.UNKNOWN],
2721
+ [f.UUID.toString(), O.BIT128]
2722
2722
  ]);
2723
2723
  /** All the data types. */
2724
2724
  static ALL = [
@@ -2762,25 +2762,25 @@ class f extends rt {
2762
2762
  c.instanceof(f)
2763
2763
  ]);
2764
2764
  }
2765
- class p extends rt {
2765
+ class p extends st {
2766
2766
  constructor(t) {
2767
- B(t) && (t = t.value), super(t.valueOf());
2767
+ C(t) && (t = t.value), super(t.valueOf());
2768
2768
  }
2769
2769
  /** @returns true if the Size is larger than the other size. */
2770
2770
  largerThan(t) {
2771
- return B(t) && (t = t.value), this.valueOf() > t.valueOf();
2771
+ return C(t) && (t = t.value), this.valueOf() > t.valueOf();
2772
2772
  }
2773
2773
  /** @returns true if the Size is smaller than the other size. */
2774
2774
  smallerThan(t) {
2775
- return B(t) && (t = t.value), this.valueOf() < t.valueOf();
2775
+ return C(t) && (t = t.value), this.valueOf() < t.valueOf();
2776
2776
  }
2777
2777
  /** @returns a new Size representing the sum of the two Sizes. */
2778
2778
  add(t) {
2779
- return B(t) && (t = t.value), new p(G(this.valueOf(), t.valueOf()));
2779
+ return C(t) && (t = t.value), new p(G(this.valueOf(), t.valueOf()));
2780
2780
  }
2781
2781
  /** @returns a new Size representing the difference of the two Sizes. */
2782
2782
  sub(t) {
2783
- return B(t) && (t = t.value), new p(F(this.valueOf(), t.valueOf()));
2783
+ return C(t) && (t = t.value), new p(F(this.valueOf(), t.valueOf()));
2784
2784
  }
2785
2785
  /**
2786
2786
  * Multiplies this Size by a scalar value.
@@ -2789,7 +2789,7 @@ class p extends rt {
2789
2789
  * @returns A new Size representing this Size multiplied by the value.
2790
2790
  */
2791
2791
  mult(t) {
2792
- return new p(L(this.valueOf(), t));
2792
+ return new p(R(this.valueOf(), t));
2793
2793
  }
2794
2794
  /**
2795
2795
  * Divides this Size by a scalar value.
@@ -2899,10 +2899,10 @@ class p extends rt {
2899
2899
  return this.valueOf() === 0;
2900
2900
  }
2901
2901
  }
2902
- const $u = c.object({
2902
+ const Su = c.object({
2903
2903
  start: c.number(),
2904
2904
  end: c.number()
2905
- }), Uu = c.union([
2905
+ }), Tu = c.union([
2906
2906
  c.instanceof(Uint8Array),
2907
2907
  c.instanceof(Uint16Array),
2908
2908
  c.instanceof(Uint32Array),
@@ -2913,64 +2913,64 @@ const $u = c.object({
2913
2913
  c.instanceof(Int16Array),
2914
2914
  c.instanceof(Int32Array),
2915
2915
  c.instanceof(BigInt64Array)
2916
- ]), cr = (e) => {
2916
+ ]), ar = (e) => {
2917
2917
  const t = typeof e;
2918
2918
  return t === "string" || t === "number" || t === "boolean" || t === "bigint" || e instanceof d || e instanceof g || e instanceof Date;
2919
- }, ko = (e, t, n, r = 0) => e.usesBigInt && !t.usesBigInt ? Number(n) - Number(r) : !e.usesBigInt && t.usesBigInt ? BigInt(n.valueOf()) - BigInt(r.valueOf()) : F(n, r), Zo = "00000000-0000-0000-0000-000000000000", _o = /^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-8][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$/i;
2920
- function qo(e) {
2921
- return typeof e == "string" && _o.test(e);
2919
+ }, Ro = (e, t, n, r = 0) => e.usesBigInt && !t.usesBigInt ? Number(n) - Number(r) : !e.usesBigInt && t.usesBigInt ? BigInt(n.valueOf()) - BigInt(r.valueOf()) : F(n, r), ko = "00000000-0000-0000-0000-000000000000", Lo = /^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-8][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$/i;
2920
+ function Zo(e) {
2921
+ return typeof e == "string" && Lo.test(e);
2922
2922
  }
2923
- const S = [];
2923
+ const E = [];
2924
2924
  for (let e = 0; e < 256; ++e)
2925
- S.push((e + 256).toString(16).slice(1));
2926
- function ar(e, t = 0) {
2927
- return (S[e[t + 0]] + S[e[t + 1]] + S[e[t + 2]] + S[e[t + 3]] + "-" + S[e[t + 4]] + S[e[t + 5]] + "-" + S[e[t + 6]] + S[e[t + 7]] + "-" + S[e[t + 8]] + S[e[t + 9]] + "-" + S[e[t + 10]] + S[e[t + 11]] + S[e[t + 12]] + S[e[t + 13]] + S[e[t + 14]] + S[e[t + 15]]).toLowerCase();
2925
+ E.push((e + 256).toString(16).slice(1));
2926
+ function ur(e, t = 0) {
2927
+ return (E[e[t + 0]] + E[e[t + 1]] + E[e[t + 2]] + E[e[t + 3]] + "-" + E[e[t + 4]] + E[e[t + 5]] + "-" + E[e[t + 6]] + E[e[t + 7]] + "-" + E[e[t + 8]] + E[e[t + 9]] + "-" + E[e[t + 10]] + E[e[t + 11]] + E[e[t + 12]] + E[e[t + 13]] + E[e[t + 14]] + E[e[t + 15]]).toLowerCase();
2928
2928
  }
2929
- function Fo(e, t = 0) {
2930
- const n = ar(e, t);
2931
- if (!qo(n))
2929
+ function _o(e, t = 0) {
2930
+ const n = ur(e, t);
2931
+ if (!Zo(n))
2932
2932
  throw TypeError("Stringified UUID is invalid");
2933
2933
  return n;
2934
2934
  }
2935
2935
  let re;
2936
- const Vo = new Uint8Array(16);
2937
- function Wo() {
2936
+ const qo = new Uint8Array(16);
2937
+ function Fo() {
2938
2938
  if (!re) {
2939
2939
  if (typeof crypto > "u" || !crypto.getRandomValues)
2940
2940
  throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");
2941
2941
  re = crypto.getRandomValues.bind(crypto);
2942
2942
  }
2943
- return re(Vo);
2943
+ return re(qo);
2944
2944
  }
2945
- const zo = typeof crypto < "u" && crypto.randomUUID && crypto.randomUUID.bind(crypto), on = { randomUUID: zo };
2946
- function Yo(e, t, n) {
2945
+ const Vo = typeof crypto < "u" && crypto.randomUUID && crypto.randomUUID.bind(crypto), cn = { randomUUID: Vo };
2946
+ function Wo(e, t, n) {
2947
2947
  e = e || {};
2948
- const r = e.random ?? e.rng?.() ?? Wo();
2948
+ const r = e.random ?? e.rng?.() ?? Fo();
2949
2949
  if (r.length < 16)
2950
2950
  throw new Error("Random bytes length must be >= 16");
2951
- return r[6] = r[6] & 15 | 64, r[8] = r[8] & 63 | 128, ar(r);
2951
+ return r[6] = r[6] & 15 | 64, r[8] = r[8] & 63 | 128, ur(r);
2952
2952
  }
2953
- function Go(e, t, n) {
2954
- return on.randomUUID && !e ? on.randomUUID() : Yo(e);
2953
+ function zo(e, t, n) {
2954
+ return cn.randomUUID && !e ? cn.randomUUID() : Wo(e);
2955
2955
  }
2956
- const Ho = () => Go(), De = (e, t) => Fo(e, t), Do = Zo, ju = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
2956
+ const Yo = () => zo(), De = (e, t) => _o(e, t), Go = ko, $u = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
2957
2957
  __proto__: null,
2958
- ZERO: Do,
2959
- create: Ho,
2958
+ ZERO: Go,
2959
+ create: Yo,
2960
2960
  parse: De
2961
- }, Symbol.toStringTag, { value: "Module" })), D = -1, pe = {
2961
+ }, Symbol.toStringTag, { value: "Module" })), J = -1, pe = {
2962
2962
  [Symbol.iterator]: () => pe,
2963
2963
  next: () => ({ done: !0, value: void 0 })
2964
- }, Jo = c.string().transform(
2964
+ }, Ho = c.string().transform(
2965
2965
  (e) => new Uint8Array(
2966
2966
  atob(e).split("").map((t) => t.charCodeAt(0))
2967
2967
  ).buffer
2968
- ), Xo = c.union([c.null(), c.undefined()]).transform(() => new Uint8Array().buffer), be = 10, ur = (e, t) => {
2968
+ ), Do = c.union([c.null(), c.undefined()]).transform(() => new Uint8Array().buffer), be = 10, lr = (e, t) => {
2969
2969
  if (e === "number" && !t.isNumeric)
2970
2970
  throw new Error(`cannot convert series of type ${t.toString()} to number`);
2971
2971
  if (e === "bigint" && !t.usesBigInt)
2972
2972
  throw new Error(`cannot convert series of type ${t.toString()} to bigint`);
2973
- }, lr = "sy_x_telem_series";
2973
+ }, fr = "sy_x_telem_series";
2974
2974
  class q {
2975
2975
  /**
2976
2976
  * A unique identifier for the series. If specified by the user, it is their
@@ -2982,7 +2982,7 @@ class q {
2982
2982
  * A discriminator used for identifying instances of the series class even
2983
2983
  * when bundlers mangle the class name.
2984
2984
  */
2985
- discriminator = lr;
2985
+ discriminator = fr;
2986
2986
  /** The data type of the series. */
2987
2987
  dataType;
2988
2988
  /**
@@ -2998,7 +2998,7 @@ class q {
2998
2998
  /** The underlying data. */
2999
2999
  _data;
3000
3000
  /** The time range occupied by the series' data. */
3001
- timeRange = E.ZERO;
3001
+ timeRange = A.ZERO;
3002
3002
  /**
3003
3003
  * Alignment defines the location of the series relative to other series in a logical
3004
3004
  * group. Useful for defining the position of the series within a channel's data.
@@ -3015,7 +3015,7 @@ class q {
3015
3015
  /** A cached maximum value. */
3016
3016
  cachedMax;
3017
3017
  /** The write position of the buffer. */
3018
- writePos = D;
3018
+ writePos = J;
3019
3019
  /** Tracks the number of entities currently using this array. */
3020
3020
  _refCount = 0;
3021
3021
  /** Caches the length of the array for variable length data types. */
@@ -3027,16 +3027,16 @@ class q {
3027
3027
  * can be constructed into a series.
3028
3028
  */
3029
3029
  static crudeZ = c.object({
3030
- timeRange: E.z.optional(),
3030
+ timeRange: A.z.optional(),
3031
3031
  dataType: f.z,
3032
3032
  alignment: c.coerce.bigint().optional(),
3033
3033
  data: c.union([
3034
- Jo,
3035
- Xo,
3034
+ Ho,
3035
+ Do,
3036
3036
  c.instanceof(ArrayBuffer),
3037
3037
  c.instanceof(Uint8Array)
3038
3038
  ]),
3039
- glBufferUsage: Po.default("static").optional()
3039
+ glBufferUsage: Bo.default("static").optional()
3040
3040
  });
3041
3041
  /**
3042
3042
  * A zod schema that validates and constructs a series from it's crude
@@ -3117,7 +3117,7 @@ class q {
3117
3117
  * @throws Error if data type cannot be inferred from input
3118
3118
  */
3119
3119
  constructor(t) {
3120
- Ko(t) && (t = { data: t }), t.data ??= [];
3120
+ Jo(t) && (t = { data: t }), t.data ??= [];
3121
3121
  const {
3122
3122
  dataType: n,
3123
3123
  timeRange: r,
@@ -3128,12 +3128,12 @@ class q {
3128
3128
  key: u = Se(),
3129
3129
  data: l
3130
3130
  } = t;
3131
- if (fr(l)) {
3131
+ if (hr(l)) {
3132
3132
  const m = l;
3133
3133
  this.key = m.key, this.dataType = m.dataType, this.sampleOffset = m.sampleOffset, this.gl = m.gl, this._data = m._data, this.timeRange = m.timeRange, this.alignment = m.alignment, this.alignmentMultiple = m.alignmentMultiple, this.cachedMin = m.cachedMin, this.cachedMax = m.cachedMax, this.writePos = m.writePos, this._refCount = m._refCount, this.cachedLength = m.cachedLength;
3134
3134
  return;
3135
3135
  }
3136
- const h = cr(l), y = Array.isArray(l);
3136
+ const h = ar(l), y = Array.isArray(l);
3137
3137
  if (n != null) this.dataType = new f(n);
3138
3138
  else {
3139
3139
  if (l instanceof ArrayBuffer)
@@ -3167,20 +3167,20 @@ class q {
3167
3167
  this._data = new this.dataType.Array([]).buffer;
3168
3168
  else {
3169
3169
  let m = h ? [l] : l;
3170
- const A = m[0];
3171
- (A instanceof d || A instanceof Date || A instanceof g) && (m = m.map((T) => new d(T).valueOf())), this.dataType.equals(f.STRING) ? (this.cachedLength = m.length, this._data = new TextEncoder().encode(`${m.join(`
3170
+ const M = m[0];
3171
+ (M instanceof d || M instanceof Date || M instanceof g) && (m = m.map((S) => new d(S).valueOf())), this.dataType.equals(f.STRING) ? (this.cachedLength = m.length, this._data = new TextEncoder().encode(`${m.join(`
3172
3172
  `)}
3173
3173
  `).buffer) : this.dataType.equals(f.JSON) ? (this.cachedLength = m.length, this._data = new TextEncoder().encode(
3174
- `${m.map((T) => at.encodeString(T)).join(`
3174
+ `${m.map((S) => xt.encodeString(S)).join(`
3175
3175
  `)}
3176
3176
  `
3177
- ).buffer) : this.dataType.usesBigInt && typeof A == "number" ? this._data = new this.dataType.Array(
3178
- m.map((T) => BigInt(Math.round(T)))
3179
- ).buffer : !this.dataType.usesBigInt && typeof A == "bigint" ? this._data = new this.dataType.Array(
3177
+ ).buffer) : this.dataType.usesBigInt && typeof M == "number" ? this._data = new this.dataType.Array(
3178
+ m.map((S) => BigInt(Math.round(S)))
3179
+ ).buffer : !this.dataType.usesBigInt && typeof M == "bigint" ? this._data = new this.dataType.Array(
3180
3180
  m.map(Number)
3181
3181
  ).buffer : this._data = new this.dataType.Array(m).buffer;
3182
3182
  }
3183
- this.key = u, this.alignment = o, this.alignmentMultiple = a, this.sampleOffset = s ?? 0, this.timeRange = r ?? E.ZERO, this.gl = {
3183
+ this.key = u, this.alignment = o, this.alignmentMultiple = a, this.sampleOffset = s ?? 0, this.timeRange = r ?? A.ZERO, this.gl = {
3184
3184
  control: null,
3185
3185
  buffer: null,
3186
3186
  prevBuffer: 0,
@@ -3240,12 +3240,12 @@ class q {
3240
3240
  return this.dataType.isVariable ? this.writeVariable(t) : this.writeFixed(t);
3241
3241
  }
3242
3242
  writeVariable(t) {
3243
- if (this.writePos === D) return 0;
3243
+ if (this.writePos === J) return 0;
3244
3244
  const n = this.byteCapacity.valueOf() - this.writePos, r = t.subBytes(0, n);
3245
3245
  return this.writeToUnderlyingData(r), this.writePos += r.byteLength.valueOf(), this.cachedLength != null && (this.cachedLength += r.length, this.calculateCachedLength()), r.length;
3246
3246
  }
3247
3247
  writeFixed(t) {
3248
- if (this.writePos === D) return 0;
3248
+ if (this.writePos === J) return 0;
3249
3249
  const n = this.capacity - this.writePos, r = t.sub(0, n);
3250
3250
  return this.writeToUnderlyingData(r), this.cachedLength = void 0, this.maybeRecomputeMinMax(r), this.writePos += r.length, r.length;
3251
3251
  }
@@ -3268,7 +3268,7 @@ class q {
3268
3268
  * @returns A typed array containing the series data.
3269
3269
  */
3270
3270
  get data() {
3271
- return this.writePos === D ? this.underlyingData : new this.dataType.Array(this._data, 0, this.writePos);
3271
+ return this.writePos === J ? this.underlyingData : new this.dataType.Array(this._data, 0, this.writePos);
3272
3272
  }
3273
3273
  /**
3274
3274
  * Returns an array of the values in the series as strings.
@@ -3289,7 +3289,7 @@ class q {
3289
3289
  parseJSON(t) {
3290
3290
  if (!this.dataType.equals(f.JSON))
3291
3291
  throw new Error("cannot parse non-JSON series as JSON");
3292
- return this.toStrings().map((n) => t.parse(at.decodeString(n)));
3292
+ return this.toStrings().map((n) => t.parse(xt.decodeString(n)));
3293
3293
  }
3294
3294
  /**
3295
3295
  * Returns the capacity of the series in bytes.
@@ -3312,7 +3312,7 @@ class q {
3312
3312
  * @returns The size of the data in bytes.
3313
3313
  */
3314
3314
  get byteLength() {
3315
- return this.writePos === D ? this.byteCapacity : this.dataType.isVariable ? new p(this.writePos) : this.dataType.density.size(this.writePos);
3315
+ return this.writePos === J ? this.byteCapacity : this.dataType.isVariable ? new p(this.writePos) : this.dataType.density.size(this.writePos);
3316
3316
  }
3317
3317
  /**
3318
3318
  * Returns the number of samples in this array.
@@ -3320,7 +3320,7 @@ class q {
3320
3320
  * @returns The number of samples in the series.
3321
3321
  */
3322
3322
  get length() {
3323
- return this.cachedLength != null ? this.cachedLength : this.dataType.isVariable ? this.calculateCachedLength() : this.writePos === D ? this.byteCapacity.valueOf() / this.dataType.density.valueOf() : this.writePos;
3323
+ return this.cachedLength != null ? this.cachedLength : this.dataType.isVariable ? this.calculateCachedLength() : this.writePos === J ? this.byteCapacity.valueOf() / this.dataType.density.valueOf() : this.writePos;
3324
3324
  }
3325
3325
  calculateCachedLength() {
3326
3326
  if (!this.dataType.isVariable)
@@ -3344,7 +3344,7 @@ class q {
3344
3344
  if (this.dataType.equals(t)) return this;
3345
3345
  const r = new t.Array(this.length);
3346
3346
  for (let s = 0; s < this.length; s++)
3347
- r[s] = ko(this.dataType, t, this.data[s], n);
3347
+ r[s] = Ro(this.dataType, t, this.data[s], n);
3348
3348
  return new q({
3349
3349
  data: r.buffer,
3350
3350
  dataType: t,
@@ -3399,7 +3399,7 @@ class q {
3399
3399
  }
3400
3400
  /** @returns the bounds of the series. */
3401
3401
  get bounds() {
3402
- return w(Number(this.min), Number(this.max), { makeValid: !1 });
3402
+ return b(Number(this.min), Number(this.max), { makeValid: !1 });
3403
3403
  }
3404
3404
  maybeRecomputeMinMax(t) {
3405
3405
  if (this.cachedMin != null) {
@@ -3490,7 +3490,7 @@ class q {
3490
3490
  throw new Error("Only FLOAT32 and UINT8 arrays can be used in WebGL");
3491
3491
  const { buffer: n, bufferUsage: r, prevBuffer: s } = this.gl;
3492
3492
  if (n == null && (this.gl.buffer = t.createBuffer()), this.writePos !== s)
3493
- if (t.bindBuffer(t.ARRAY_BUFFER, this.gl.buffer), this.writePos !== D) {
3493
+ if (t.bindBuffer(t.ARRAY_BUFFER, this.gl.buffer), this.writePos !== J) {
3494
3494
  s === 0 && t.bufferData(t.ARRAY_BUFFER, this.byteCapacity.valueOf(), t.STATIC_DRAW);
3495
3495
  const i = this.dataType.density.size(s).valueOf(), o = this.underlyingData.slice(this.gl.prevBuffer, this.writePos);
3496
3496
  t.bufferSubData(t.ARRAY_BUFFER, i, o.buffer), this.gl.prevBuffer = this.writePos;
@@ -3499,10 +3499,10 @@ class q {
3499
3499
  t.ARRAY_BUFFER,
3500
3500
  this.buffer,
3501
3501
  r === "static" ? t.STATIC_DRAW : t.DYNAMIC_DRAW
3502
- ), this.gl.prevBuffer = D;
3502
+ ), this.gl.prevBuffer = J;
3503
3503
  }
3504
3504
  as(t) {
3505
- return ur(t, this.dataType), this;
3505
+ return lr(t, this.dataType), this;
3506
3506
  }
3507
3507
  /** @returns a digest containing information about the series. */
3508
3508
  get digest() {
@@ -3511,8 +3511,8 @@ class q {
3511
3511
  dataType: this.dataType.toString(),
3512
3512
  sampleOffset: this.sampleOffset,
3513
3513
  alignment: {
3514
- lower: an(this.alignmentBounds.lower),
3515
- upper: an(this.alignmentBounds.upper),
3514
+ lower: un(this.alignmentBounds.lower),
3515
+ upper: un(this.alignmentBounds.upper),
3516
3516
  multiple: this.alignmentMultiple
3517
3517
  },
3518
3518
  timeRange: this.timeRange.toString(),
@@ -3530,7 +3530,7 @@ class q {
3530
3530
  * is exclusive.
3531
3531
  */
3532
3532
  get alignmentBounds() {
3533
- return w(
3533
+ return b(
3534
3534
  this.alignment,
3535
3535
  this.alignment + BigInt(this.length) * this.alignmentMultiple
3536
3536
  );
@@ -3550,10 +3550,10 @@ class q {
3550
3550
  }
3551
3551
  [Symbol.iterator]() {
3552
3552
  if (this.dataType.isVariable) {
3553
- const t = new Qo(this);
3553
+ const t = new Xo(this);
3554
3554
  return this.dataType.equals(f.JSON) ? new Je(t) : t;
3555
3555
  }
3556
- return this.dataType.equals(f.UUID) ? new tc(this) : new ec(this);
3556
+ return this.dataType.equals(f.UUID) ? new Ko(this) : new Qo(this);
3557
3557
  }
3558
3558
  /**
3559
3559
  * Returns a slice of the series from start to end.
@@ -3580,7 +3580,7 @@ class q {
3580
3580
  * @returns An iterator over the specified range.
3581
3581
  */
3582
3582
  subIterator(t, n) {
3583
- return new cn(this, t, n ?? this.length);
3583
+ return new an(this, t, n ?? this.length);
3584
3584
  }
3585
3585
  /**
3586
3586
  * Returns an iterator over a portion of the series based on alignment.
@@ -3594,7 +3594,7 @@ class q {
3594
3594
  ), s = Math.ceil(
3595
3595
  Number(n - this.alignment) / Number(this.alignmentMultiple)
3596
3596
  );
3597
- return new cn(this, r, s);
3597
+ return new an(this, r, s);
3598
3598
  }
3599
3599
  subBytes(t, n) {
3600
3600
  if (t >= 0 && (n == null || n >= this.byteLength.valueOf())) return this;
@@ -3629,7 +3629,7 @@ class q {
3629
3629
  return new q({
3630
3630
  data: this.buffer,
3631
3631
  dataType: this.dataType,
3632
- timeRange: E.ZERO,
3632
+ timeRange: A.ZERO,
3633
3633
  sampleOffset: this.sampleOffset,
3634
3634
  glBufferUsage: "static",
3635
3635
  alignment: t
@@ -3653,21 +3653,21 @@ class q {
3653
3653
  return t += "])", t;
3654
3654
  }
3655
3655
  }
3656
- const Ko = (e) => e == null ? !1 : Array.isArray(e) || e instanceof ArrayBuffer || ArrayBuffer.isView(e) && !(e instanceof DataView) || e instanceof q ? !0 : cr(e), fr = Un(lr, q);
3657
- class cn {
3656
+ const Jo = (e) => e == null ? !1 : Array.isArray(e) || e instanceof ArrayBuffer || ArrayBuffer.isView(e) && !(e instanceof DataView) || e instanceof q ? !0 : ar(e), hr = jn(fr, q);
3657
+ class an {
3658
3658
  series;
3659
3659
  end;
3660
3660
  index;
3661
3661
  constructor(t, n, r) {
3662
3662
  this.series = t;
3663
- const s = w(0, t.length + 1);
3663
+ const s = b(0, t.length + 1);
3664
3664
  this.end = le(s, r), this.index = le(s, n);
3665
3665
  }
3666
3666
  next() {
3667
3667
  return this.index >= this.end ? { done: !0, value: void 0 } : { done: !1, value: this.series.at(this.index++, !0) };
3668
3668
  }
3669
3669
  }
3670
- class Qo {
3670
+ class Xo {
3671
3671
  series;
3672
3672
  index;
3673
3673
  decoder;
@@ -3695,11 +3695,11 @@ class Je {
3695
3695
  const t = this.wrapped.next();
3696
3696
  return t.done === !0 ? { done: !0, value: void 0 } : {
3697
3697
  done: !1,
3698
- value: at.decodeString(t.value, Je.schema)
3698
+ value: xt.decodeString(t.value, Je.schema)
3699
3699
  };
3700
3700
  }
3701
3701
  }
3702
- class tc {
3702
+ class Ko {
3703
3703
  series;
3704
3704
  index;
3705
3705
  data;
@@ -3715,7 +3715,7 @@ class tc {
3715
3715
  return this.index++, { done: !1, value: t };
3716
3716
  }
3717
3717
  }
3718
- class ec {
3718
+ class Qo {
3719
3719
  series;
3720
3720
  index;
3721
3721
  constructor(t) {
@@ -3728,7 +3728,7 @@ class ec {
3728
3728
  };
3729
3729
  }
3730
3730
  }
3731
- class Cu {
3731
+ class Uu {
3732
3732
  /** The array of series in this collection */
3733
3733
  series;
3734
3734
  /**
@@ -3781,7 +3781,7 @@ class Cu {
3781
3781
  this.series = t;
3782
3782
  }
3783
3783
  as(t) {
3784
- return ur(t, this.dataType), this;
3784
+ return lr(t, this.dataType), this;
3785
3785
  }
3786
3786
  /**
3787
3787
  * Returns the data type of the series in this collection. If the collection is empty,
@@ -3796,7 +3796,7 @@ class Cu {
3796
3796
  * series to the end of the last series.
3797
3797
  */
3798
3798
  get timeRange() {
3799
- return this.series.length === 0 ? E.ZERO : new E(
3799
+ return this.series.length === 0 ? A.ZERO : new A(
3800
3800
  this.series[0].timeRange.start,
3801
3801
  this.series[this.series.length - 1].timeRange.end
3802
3802
  );
@@ -3814,7 +3814,7 @@ class Cu {
3814
3814
  * series + its length. If the collection is empty, returns bounds.construct(0n, 0n).
3815
3815
  */
3816
3816
  get alignmentBounds() {
3817
- return this.series.length === 0 ? w(0n, 0n) : w(
3817
+ return this.series.length === 0 ? b(0n, 0n) : b(
3818
3818
  this.series[0].alignmentBounds.lower,
3819
3819
  this.series[this.series.length - 1].alignmentBounds.upper
3820
3820
  );
@@ -3823,7 +3823,7 @@ class Cu {
3823
3823
  const n = () => new Error(
3824
3824
  `cannot push a ${t.dataType.toString()} series to a ${this.dataType.toString()} multi-series`
3825
3825
  ), r = t.dataType.equals(this.dataType);
3826
- if (fr(t)) {
3826
+ if (hr(t)) {
3827
3827
  if (this.series.length !== 0 && !r) throw n();
3828
3828
  this.series.push(t);
3829
3829
  } else {
@@ -3841,7 +3841,7 @@ class Cu {
3841
3841
  }
3842
3842
  atAlignment(t, n) {
3843
3843
  for (const r of this.series)
3844
- if (k(r.alignmentBounds, t))
3844
+ if (L(r.alignmentBounds, t))
3845
3845
  return r.atAlignment(t, n);
3846
3846
  if (n) throw new Error(`[series] - no value at alignment ${t}`);
3847
3847
  }
@@ -3876,7 +3876,7 @@ class Cu {
3876
3876
  const o = this.series[i];
3877
3877
  if (t < o.alignment) break;
3878
3878
  if (t >= o.alignmentBounds.upper) r += o.length;
3879
- else if (k(o.alignmentBounds, t)) {
3879
+ else if (L(o.alignmentBounds, t)) {
3880
3880
  r += Math.ceil(
3881
3881
  Number(t - o.alignment) / Number(o.alignmentMultiple)
3882
3882
  );
@@ -3888,7 +3888,7 @@ class Cu {
3888
3888
  const o = this.series[i];
3889
3889
  if (n < o.alignment) break;
3890
3890
  if (n >= o.alignmentBounds.upper) s += o.length;
3891
- else if (k(o.alignmentBounds, n)) {
3891
+ else if (L(o.alignmentBounds, n)) {
3892
3892
  s += Math.ceil(
3893
3893
  Number(n - o.alignment) / Number(o.alignmentMultiple)
3894
3894
  );
@@ -3911,7 +3911,7 @@ class Cu {
3911
3911
  const i = this.series[s];
3912
3912
  if (t < i.alignment) break;
3913
3913
  if (t >= i.alignmentBounds.upper) r += i.length;
3914
- else if (k(i.alignmentBounds, t)) {
3914
+ else if (L(i.alignmentBounds, t)) {
3915
3915
  r += Number(t - i.alignment);
3916
3916
  break;
3917
3917
  }
@@ -3929,7 +3929,7 @@ class Cu {
3929
3929
  * Returns the bounds containing the minimum and maximum values across all series.
3930
3930
  */
3931
3931
  get bounds() {
3932
- return qn(this.series.map((t) => t.bounds));
3932
+ return Fn(this.series.map((t) => t.bounds));
3933
3933
  }
3934
3934
  /**
3935
3935
  * Returns the sum of the byte lengths of all series.
@@ -3956,7 +3956,7 @@ class Cu {
3956
3956
  */
3957
3957
  traverseAlignment(t, n) {
3958
3958
  const r = this.series.map((s) => s.alignmentBounds);
3959
- return Fn(r, t, n);
3959
+ return Vn(r, t, n);
3960
3960
  }
3961
3961
  /**
3962
3962
  * Acquires a reference to the WebGL buffer for all series.
@@ -3979,7 +3979,7 @@ class Cu {
3979
3979
  */
3980
3980
  distance(t, n) {
3981
3981
  const r = this.series.map((s) => s.alignmentBounds);
3982
- return Vn(r, t, n);
3982
+ return Wn(r, t, n);
3983
3983
  }
3984
3984
  /**
3985
3985
  * Parses a JSON multi-series into an array of values using the provided zod schema.
@@ -4002,7 +4002,7 @@ class Cu {
4002
4002
  next() {
4003
4003
  return { done: !0, value: void 0 };
4004
4004
  }
4005
- } : new nc(this.series);
4005
+ } : new tc(this.series);
4006
4006
  }
4007
4007
  /**
4008
4008
  * Returns an array of the values in the multi-series as strings.
@@ -4013,7 +4013,7 @@ class Cu {
4013
4013
  return this.series.flatMap((t) => t.toStrings());
4014
4014
  }
4015
4015
  }
4016
- class nc {
4016
+ class tc {
4017
4017
  series;
4018
4018
  seriesIndex;
4019
4019
  internal;
@@ -4042,16 +4042,16 @@ class se {
4042
4042
  return this;
4043
4043
  }
4044
4044
  }
4045
- const an = (e) => {
4045
+ const un = (e) => {
4046
4046
  const t = e >> 32n, n = e & 0xffffffffn;
4047
4047
  return { domain: t, sample: n };
4048
- }, hr = async (e) => await new Promise(
4048
+ }, dr = async (e) => await new Promise(
4049
4049
  (t) => setTimeout(t, g.fromMilliseconds(e).milliseconds)
4050
- ), Bu = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
4050
+ ), ju = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
4051
4051
  __proto__: null,
4052
- sleep: hr
4052
+ sleep: dr
4053
4053
  }, Symbol.toStringTag, { value: "Module" }));
4054
- class rc {
4054
+ class ec {
4055
4055
  config;
4056
4056
  retries;
4057
4057
  interval;
@@ -4060,7 +4060,7 @@ class rc {
4060
4060
  baseInterval: new g(t?.baseInterval ?? g.seconds(1)),
4061
4061
  maxRetries: t?.maxRetries ?? 5,
4062
4062
  scale: t?.scale ?? 1,
4063
- sleepFn: t?.sleepFn ?? hr
4063
+ sleepFn: t?.sleepFn ?? dr
4064
4064
  }, this.retries = 0, this.interval = new g(this.config.baseInterval);
4065
4065
  }
4066
4066
  async wait() {
@@ -4074,80 +4074,80 @@ class rc {
4074
4074
  this.retries = 0, this.interval = this.config.baseInterval;
4075
4075
  }
4076
4076
  }
4077
- const sc = c.object({
4077
+ const nc = c.object({
4078
4078
  baseInterval: g.z.optional(),
4079
4079
  maxRetries: c.number().optional(),
4080
4080
  scale: c.number().optional()
4081
- }), Ru = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
4081
+ }), Cu = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
4082
4082
  __proto__: null,
4083
- Breaker: rc,
4084
- breakerConfigZ: sc
4085
- }, Symbol.toStringTag, { value: "Module" })), ic = (e) => c.object({
4083
+ Breaker: ec,
4084
+ breakerConfigZ: nc
4085
+ }, Symbol.toStringTag, { value: "Module" })), rc = (e) => c.object({
4086
4086
  variant: c.enum(["set", "delete"]),
4087
4087
  key: c.string(),
4088
4088
  value: e
4089
- }), Pu = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
4089
+ }), Bu = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
4090
4090
  __proto__: null,
4091
- Z: ic
4092
- }, Symbol.toStringTag, { value: "Module" })), oc = /^#?([0-9a-f]{6}|[0-9a-f]{8})$/i, Wt = c.string().regex(oc), ct = c.number().min(0).max(255), dr = c.number().min(0).max(1), Kt = c.tuple([ct, ct, ct, dr]), cc = c.tuple([ct, ct, ct]), ac = c.object({ rgba255: Kt }), uc = c.number().min(0).max(360), lc = c.number().min(0).max(100), fc = c.number().min(0).max(100), gr = c.tuple([uc, lc, fc, dr]), Qt = c.union([Wt, cc, Kt, gr, ac]), te = Qt.transform((e) => N(e)), hc = (e) => te.safeParse(e).success, dc = (e) => Kt.safeParse(e).success, gc = ((e) => {
4091
+ Z: rc
4092
+ }, Symbol.toStringTag, { value: "Module" })), sc = /^#?([0-9a-f]{6}|[0-9a-f]{8})$/i, zt = c.string().regex(sc), H = c.number().min(0).max(255), Xe = c.number().min(0).max(1), Qt = c.tuple([H, H, H, Xe]), ic = c.tuple([H, H, H]), oc = c.object({ rgba255: Qt }), cc = c.object({ r: H, g: H, b: H, a: Xe }), ac = c.number().min(0).max(360), uc = c.number().min(0).max(100), lc = c.number().min(0).max(100), gr = c.tuple([ac, uc, lc, Xe]), te = c.union([zt, ic, Qt, gr, oc, cc]), St = te.transform((e) => I(e)), fc = (e) => St.safeParse(e).success, hc = (e) => Qt.safeParse(e).success, dc = ((e) => {
4093
4093
  if (e == null) return;
4094
- const t = te.safeParse(e);
4094
+ const t = St.safeParse(e);
4095
4095
  if (t.success) return mr(t.data);
4096
4096
  if (typeof e == "string") return e;
4097
4097
  throw t.error;
4098
- }), N = (e, t = 1) => {
4099
- if (e = Qt.parse(e), typeof e == "string") return kt(e, t);
4098
+ }), I = (e, t = 1) => {
4099
+ if (e = te.parse(e), typeof e == "string") return Zt(e, t);
4100
4100
  if (Array.isArray(e)) {
4101
4101
  if (e.length < 3 || e.length > 4)
4102
4102
  throw new Error(`Invalid color: [${e.join(", ")}]`);
4103
4103
  return e.length === 3 ? [...e, t] : e;
4104
4104
  }
4105
- return e.rgba255;
4105
+ return "a" in e && "r" in e ? [e.r, e.g, e.b, e.a] : e.rgba255;
4106
4106
  }, yr = (e, t) => {
4107
4107
  if (e == null || t == null) return e == t;
4108
- const n = N(e), r = N(t);
4108
+ const n = I(e), r = I(t);
4109
4109
  return n.every((s, i) => s === r[i]);
4110
- }, yc = ((e) => {
4110
+ }, gc = ((e) => {
4111
4111
  if (e == null) return;
4112
- const [t, n, r, s] = N(e);
4113
- return `#${jt(t)}${jt(n)}${jt(r)}${s === 1 ? "" : jt(s * 255)}`;
4112
+ const [t, n, r, s] = I(e), i = Math.round(s * 255);
4113
+ return `#${Ct(t)}${Ct(n)}${Ct(r)}${i === 255 ? "" : Ct(i)}`;
4114
4114
  }), mr = (e) => {
4115
- const [t, n, r, s] = N(e);
4115
+ const [t, n, r, s] = I(e);
4116
4116
  return `rgba(${t}, ${n}, ${r}, ${s})`;
4117
- }, mc = (e) => `rgb(${pr(e)})`, pr = (e) => {
4118
- const [t, n, r] = N(e);
4117
+ }, yc = (e) => `rgb(${pr(e)})`, pr = (e) => {
4118
+ const [t, n, r] = I(e);
4119
4119
  return `${t}, ${n}, ${r}`;
4120
- }, pc = (e) => [...Xe(e), xt(e)], Xe = (e) => [
4120
+ }, mc = (e) => [...Ke(e), Ot(e)], Ke = (e) => [
4121
+ pt(e) / 255,
4121
4122
  bt(e) / 255,
4122
- wt(e) / 255,
4123
- Ot(e) / 255
4124
- ], bt = (e) => N(e)[0], wt = (e) => N(e)[1], Ot = (e) => N(e)[2], xt = (e) => N(e)[3], bc = (e) => yr(Ke, e), wc = (e) => Sc(N(e)), Oc = (e, t) => {
4125
- const [n, r, s] = N(e);
4123
+ wt(e) / 255
4124
+ ], pt = (e) => I(e)[0], bt = (e) => I(e)[1], wt = (e) => I(e)[2], Ot = (e) => I(e)[3], pc = (e) => yr(Qe, e), bc = (e) => Ec(I(e)), wc = (e, t) => {
4125
+ const [n, r, s] = I(e);
4126
4126
  if (t > 100)
4127
4127
  throw new Error(`Color opacity must be between 0 and 100, got ${t}`);
4128
4128
  return t > 1 && (t /= 100), [n, r, s, t];
4129
4129
  }, vt = (e) => {
4130
- const [t, n, r] = Xe(e).map(
4130
+ const [t, n, r] = Ke(e).map(
4131
4131
  (s) => s <= 0.03928 ? s / 12.92 : ((s + 0.055) / 1.055) ** 2.4
4132
4132
  );
4133
4133
  return Number((0.2126 * t + 0.7152 * n + 0.0722 * r).toFixed(3));
4134
- }, xc = (e) => {
4135
- const [t, n, r] = Xe(e);
4134
+ }, Oc = (e) => {
4135
+ const [t, n, r] = Ke(e);
4136
4136
  return 1 - (Math.max(t, n, r) - Math.min(t, n, r));
4137
4137
  }, we = (e, t) => {
4138
- const n = N(e), r = N(t), s = vt(n), i = vt(r);
4138
+ const n = I(e), r = I(t), s = vt(n), i = vt(r);
4139
4139
  return (Math.max(s, i) + 0.5) / (Math.min(s, i) + 0.5);
4140
- }, Ic = (e, ...t) => {
4140
+ }, xc = (e, ...t) => {
4141
4141
  if (t.length === 0)
4142
4142
  throw new Error("[Color.pickByContrast] - must provide at least one color");
4143
- const n = N(e), [r] = t.sort((s, i) => we(n, i) - we(n, s));
4144
- return N(r);
4145
- }, Nc = (e) => vt(e) < 0.5, vc = (e) => vt(e) > 0.5, kt = (e, t = 1) => (e = Wt.parse(e), e = Mc(e), [
4146
- Ct(e, 0),
4147
- Ct(e, 2),
4148
- Ct(e, 4),
4149
- e.length === 8 ? Ct(e, 6) / 255 : t
4150
- ]), Ke = [0, 0, 0, 0], jt = (e) => Math.floor(e).toString(16).padStart(2, "0"), Ct = (e, t) => parseInt(e.slice(t, t + 2), 16), Mc = (e) => e.startsWith("#") ? e.slice(1) : e, un = {
4143
+ const n = I(e), [r] = t.sort((s, i) => we(n, i) - we(n, s));
4144
+ return I(r);
4145
+ }, Ic = (e) => vt(e) < 0.5, Nc = (e) => vt(e) > 0.5, Zt = (e, t = 1) => (e = zt.parse(e), e = vc(e), [
4146
+ Bt(e, 0),
4147
+ Bt(e, 2),
4148
+ Bt(e, 4),
4149
+ e.length === 8 ? Bt(e, 6) / 255 : t
4150
+ ]), Qe = [0, 0, 0, 0], Ct = (e) => Math.floor(e).toString(16).padStart(2, "0"), Bt = (e, t) => parseInt(e.slice(t, t + 2), 16), vc = (e) => e.startsWith("#") ? e.slice(1) : e, ln = {
4151
4151
  black: "#000000",
4152
4152
  white: "#ffffff",
4153
4153
  red: "#ff0000",
@@ -4179,16 +4179,16 @@ const sc = c.object({
4179
4179
  khaki: "#f0e68c",
4180
4180
  crimson: "#dc143c",
4181
4181
  transparent: "transparent"
4182
- }, Ac = (e) => {
4182
+ }, Mc = (e) => {
4183
4183
  if (!e) return;
4184
4184
  const t = e.trim().toLowerCase();
4185
4185
  if (!(t === "transparent" || t === "none")) {
4186
4186
  if (t.startsWith("#")) {
4187
4187
  if (t.length === 4) {
4188
4188
  const n = t[1], r = t[2], s = t[3], i = `#${n}${n}${r}${r}${s}${s}`;
4189
- if (Wt.safeParse(i).success) return kt(i);
4189
+ if (zt.safeParse(i).success) return Zt(i);
4190
4190
  }
4191
- return (t.length === 7 || t.length === 9) && Wt.safeParse(t).success ? kt(t) : void 0;
4191
+ return (t.length === 7 || t.length === 9) && zt.safeParse(t).success ? Zt(t) : void 0;
4192
4192
  }
4193
4193
  if (t.startsWith("rgb")) {
4194
4194
  const n = t.match(
@@ -4199,9 +4199,9 @@ const sc = c.object({
4199
4199
  return [parseInt(r), parseInt(s), parseInt(i), o ? parseFloat(o) : 1];
4200
4200
  }
4201
4201
  }
4202
- if (un[t]) return kt(un[t]);
4202
+ if (ln[t]) return Zt(ln[t]);
4203
4203
  }
4204
- }, Ec = (e) => {
4204
+ }, Ac = (e) => {
4205
4205
  e = gr.parse(e);
4206
4206
  let [t, n, r] = e;
4207
4207
  const s = e[3];
@@ -4214,8 +4214,8 @@ const sc = c.object({
4214
4214
  i = ie(l, u, t + 1 / 3), o = ie(l, u, t), a = ie(l, u, t - 1 / 3);
4215
4215
  }
4216
4216
  return [Math.round(i * 255), Math.round(o * 255), Math.round(a * 255), s];
4217
- }, ie = (e, t, n) => (n < 0 && (n += 1), n > 1 && (n -= 1), n < 1 / 6 ? e + (t - e) * 6 * n : n < 1 / 2 ? t : n < 2 / 3 ? e + (t - e) * (2 / 3 - n) * 6 : e), Sc = (e) => {
4218
- e = Kt.parse(e);
4217
+ }, ie = (e, t, n) => (n < 0 && (n += 1), n > 1 && (n -= 1), n < 1 / 6 ? e + (t - e) * 6 * n : n < 1 / 2 ? t : n < 2 / 3 ? e + (t - e) * (2 / 3 - n) * 6 : e), Ec = (e) => {
4218
+ e = Qt.parse(e);
4219
4219
  let [t, n, r] = e;
4220
4220
  const s = e[3];
4221
4221
  t /= 255, n /= 255, r /= 255;
@@ -4228,76 +4228,76 @@ const sc = c.object({
4228
4228
  u = l > 0.5 ? h / (2 - i - o) : h / (i + o), i === t ? a = (n - r) / h + (n < r ? 6 : 0) : i === n ? a = (r - t) / h + 2 : a = (t - n) / h + 4, a /= 6;
4229
4229
  }
4230
4230
  return a *= 360, u *= 100, l *= 100, [Math.round(a), Math.round(u), Math.round(l), s];
4231
- }, Tc = N("#000000"), $c = N("#ffffff"), br = c.object({
4231
+ }, Sc = I("#000000"), Tc = I("#ffffff"), br = c.object({
4232
4232
  key: c.string(),
4233
- color: Qt,
4233
+ color: te,
4234
4234
  position: c.number(),
4235
4235
  switched: c.boolean().optional()
4236
- }), Uc = c.array(br), jc = (e, t) => {
4237
- if (e.length === 0) return Ke;
4238
- if (e = e.slice().sort((n, r) => n.position - r.position), t <= e[0].position) return N(e[0].color);
4236
+ }), $c = c.array(br), Uc = (e, t) => {
4237
+ if (e.length === 0) return Qe;
4238
+ if (e = e.slice().sort((n, r) => n.position - r.position), t <= e[0].position) return I(e[0].color);
4239
4239
  if (t >= e[e.length - 1].position)
4240
- return N(e[e.length - 1].color);
4240
+ return I(e[e.length - 1].color);
4241
4241
  for (let n = 0; n < e.length - 1; n++) {
4242
4242
  const r = e[n], s = e[n + 1];
4243
4243
  if (t < r.position || t > s.position) continue;
4244
- if (t === r.position) return N(r.color);
4245
- if (t === s.position) return N(s.color);
4246
- const i = (t - r.position) / (s.position - r.position), o = N(r.color), a = N(s.color), u = Math.round(
4247
- bt(o) + i * (bt(a) - bt(o))
4244
+ if (t === r.position) return I(r.color);
4245
+ if (t === s.position) return I(s.color);
4246
+ const i = (t - r.position) / (s.position - r.position), o = I(r.color), a = I(s.color), u = Math.round(
4247
+ pt(o) + i * (pt(a) - pt(o))
4248
4248
  ), l = Math.round(
4249
- wt(o) + i * (wt(a) - wt(o))
4249
+ bt(o) + i * (bt(a) - bt(o))
4250
4250
  ), h = Math.round(
4251
- Ot(o) + i * (Ot(a) - Ot(o))
4252
- ), y = xt(o) + i * (xt(a) - xt(o));
4253
- return N([u, l, h, y]);
4251
+ wt(o) + i * (wt(a) - wt(o))
4252
+ ), y = Ot(o) + i * (Ot(a) - Ot(o));
4253
+ return I([u, l, h, y]);
4254
4254
  }
4255
- return N(e[e.length - 1].color);
4256
- }, Cc = c.object({
4255
+ return I(e[e.length - 1].color);
4256
+ }, jc = c.object({
4257
4257
  key: c.string(),
4258
4258
  name: c.string(),
4259
- color: te
4260
- }), Bc = c.object({
4259
+ color: St
4260
+ }), Cc = c.object({
4261
4261
  key: c.string(),
4262
4262
  name: c.string(),
4263
- swatches: c.array(Cc)
4264
- }), Lu = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
4263
+ swatches: c.array(jc)
4264
+ }), Pu = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
4265
4265
  __proto__: null,
4266
- BLACK: Tc,
4267
- WHITE: $c,
4268
- ZERO: Ke,
4269
- aValue: xt,
4270
- bValue: Ot,
4271
- colorZ: te,
4272
- construct: N,
4266
+ BLACK: Sc,
4267
+ WHITE: Tc,
4268
+ ZERO: Qe,
4269
+ aValue: Ot,
4270
+ bValue: wt,
4271
+ colorZ: St,
4272
+ construct: I,
4273
4273
  contrast: we,
4274
- crudeZ: Qt,
4275
- cssString: gc,
4274
+ crudeZ: te,
4275
+ cssString: dc,
4276
4276
  equals: yr,
4277
- fromCSS: Ac,
4278
- fromGradient: jc,
4279
- fromHSLA: Ec,
4280
- gValue: wt,
4281
- gradientZ: Uc,
4282
- grayness: xc,
4283
- hex: yc,
4284
- hsla: wc,
4285
- isColor: dc,
4286
- isCrude: hc,
4287
- isDark: Nc,
4288
- isLight: vc,
4289
- isZero: bc,
4277
+ fromCSS: Mc,
4278
+ fromGradient: Uc,
4279
+ fromHSLA: Ac,
4280
+ gValue: bt,
4281
+ gradientZ: $c,
4282
+ grayness: Oc,
4283
+ hex: gc,
4284
+ hsla: bc,
4285
+ isColor: hc,
4286
+ isCrude: fc,
4287
+ isDark: Ic,
4288
+ isLight: Nc,
4289
+ isZero: pc,
4290
4290
  luminance: vt,
4291
- paletteZ: Bc,
4292
- pickByContrast: Ic,
4293
- rValue: bt,
4294
- rgbCSS: mc,
4291
+ paletteZ: Cc,
4292
+ pickByContrast: xc,
4293
+ rValue: pt,
4294
+ rgbCSS: yc,
4295
4295
  rgbString: pr,
4296
- rgba1: pc,
4296
+ rgba1: mc,
4297
4297
  rgbaCSS: mr,
4298
- setAlpha: Oc,
4298
+ setAlpha: wc,
4299
4299
  stopZ: br
4300
- }, Symbol.toStringTag, { value: "Module" })), wr = c.int().min(0).max(255), Or = 255, xr = 0, Rc = {
4300
+ }, Symbol.toStringTag, { value: "Module" })), wr = c.int().min(0).max(255), Or = 255, xr = 0, Bc = {
4301
4301
  lower: xr,
4302
4302
  upper: Or + 1
4303
4303
  }, Ir = c.object({
@@ -4316,17 +4316,17 @@ const sc = c.object({
4316
4316
  }), vr = (e) => c.object({
4317
4317
  from: c.null(),
4318
4318
  to: Mt(e)
4319
- }), Lc = (e) => c.union([
4319
+ }), Rc = (e) => c.union([
4320
4320
  Nr(e),
4321
4321
  vr(e),
4322
4322
  c.object({
4323
4323
  from: Mt(e),
4324
4324
  to: Mt(e)
4325
4325
  })
4326
- ]), ku = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
4326
+ ]), Ru = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
4327
4327
  __proto__: null,
4328
4328
  ABSOLUTE_AUTHORITY: Or,
4329
- AUTHORITY_BOUNDS: Rc,
4329
+ AUTHORITY_BOUNDS: Bc,
4330
4330
  ZERO_AUTHORITY: xr,
4331
4331
  acquireZ: vr,
4332
4332
  authorityZ: wr,
@@ -4334,7 +4334,7 @@ const sc = c.object({
4334
4334
  releaseZ: Nr,
4335
4335
  stateZ: Mt,
4336
4336
  subjectZ: Ir,
4337
- transferZ: Lc
4337
+ transferZ: Rc
4338
4338
  }, Symbol.toStringTag, { value: "Module" })), kc = (e) => {
4339
4339
  switch (typeof e) {
4340
4340
  case "bigint":
@@ -4347,26 +4347,26 @@ const sc = c.object({
4347
4347
  case "string":
4348
4348
  case "symbol":
4349
4349
  case "function":
4350
- return ln(e.toString());
4350
+ return fn(e.toString());
4351
4351
  case "object":
4352
- return e == null ? "" : ln(JSON.stringify(e));
4352
+ return e == null ? "" : fn(JSON.stringify(e));
4353
4353
  }
4354
- }, Zc = /[",\n]/, ln = (e) => Zc.test(e) ? `"${e.replace(/"/g, '""')}"` : e, Zu = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
4354
+ }, Lc = /[",\n]/, fn = (e) => Lc.test(e) ? `"${e.replace(/"/g, '""')}"` : e, ku = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
4355
4355
  __proto__: null,
4356
4356
  formatValue: kc
4357
- }, Symbol.toStringTag, { value: "Module" })), _u = (e, t) => {
4357
+ }, Symbol.toStringTag, { value: "Module" })), Lu = (e, t) => {
4358
4358
  let n = null;
4359
4359
  return t === 0 ? e : (...s) => {
4360
4360
  n !== null && (clearTimeout(n), n = null), n = setTimeout(() => e(...s), t);
4361
4361
  };
4362
- }, qu = (e, t) => {
4362
+ }, Zu = (e, t) => {
4363
4363
  let n = null;
4364
4364
  return t === 0 ? e : (...s) => {
4365
4365
  n === null && (n = setTimeout(() => {
4366
4366
  e(...s), n = null;
4367
4367
  }, t));
4368
4368
  };
4369
- }, _c = (e) => {
4369
+ }, Zc = (e) => {
4370
4370
  try {
4371
4371
  return structuredClone(e);
4372
4372
  } catch {
@@ -4375,7 +4375,7 @@ const sc = c.object({
4375
4375
  e
4376
4376
  ), console.trace(), JSON.parse(JSON.stringify(e));
4377
4377
  }
4378
- }, qc = (e, t, n = "") => {
4378
+ }, _c = (e, t, n = "") => {
4379
4379
  const r = {}, s = (i, o, a) => {
4380
4380
  if (typeof i != typeof o || i === null || o === null) {
4381
4381
  r[a] = [i, o];
@@ -4431,7 +4431,7 @@ const sc = c.object({
4431
4431
  } else if (i !== o) return !1;
4432
4432
  }
4433
4433
  return !0;
4434
- }, C = ".", Ar = (e, t, n = C) => {
4434
+ }, j = ".", Ar = (e, t, n = j) => {
4435
4435
  const r = e.split(n);
4436
4436
  return r.map((i, o) => {
4437
4437
  const a = t(i, o, r);
@@ -4444,17 +4444,17 @@ const sc = c.object({
4444
4444
  const r = e[0];
4445
4445
  if (typeof r == "object" && "key" in r)
4446
4446
  return e.find((s) => s.key === t);
4447
- }, Fc = (e, t) => {
4448
- const n = e.split(C);
4447
+ }, qc = (e, t) => {
4448
+ const n = e.split(j);
4449
4449
  return n.forEach((r, s) => {
4450
4450
  t = dt(t, r), t != null && typeof t == "object" && "key" in t && (n[s] = t.key);
4451
- }), n.join(C);
4452
- }, Vc = (e, t) => {
4453
- const n = e.split(C);
4451
+ }), n.join(j);
4452
+ }, Fc = (e, t) => {
4453
+ const n = e.split(j);
4454
4454
  return t < 0 ? n[n.length + t] : n[t];
4455
- }, Wc = (e, t) => {
4455
+ }, Vc = (e, t) => {
4456
4456
  if (t.length === 0) return !0;
4457
- const n = e.split(C), r = t.split(C);
4457
+ const n = e.split(j), r = t.split(j);
4458
4458
  if (r.length > n.length) return !1;
4459
4459
  for (let s = 0; s < r.length; s++) {
4460
4460
  const i = n[s], o = r[s];
@@ -4462,19 +4462,19 @@ const sc = c.object({
4462
4462
  return !1;
4463
4463
  }
4464
4464
  return !0;
4465
- }, it = (e) => {
4465
+ }, ot = (e) => {
4466
4466
  const t = parseInt(e);
4467
4467
  return isNaN(t) || t < 0 || t.toString() !== e ? null : t;
4468
4468
  }, xe = (e, t) => {
4469
4469
  for (let n = 1; n <= t.length; n++) {
4470
- const r = t.slice(0, n).join(C);
4470
+ const r = t.slice(0, n).join(j);
4471
4471
  if (dt(e, r) != null) return [r, n];
4472
4472
  }
4473
4473
  return null;
4474
- }, Qe = ((e, t, n = { optional: !1 }) => {
4474
+ }, tn = ((e, t, n = { optional: !1 }) => {
4475
4475
  const { optional: r, getter: s = dt } = n;
4476
4476
  if (t === "") return e;
4477
- const i = t.split(C);
4477
+ const i = t.split(j);
4478
4478
  if (i.length === 1) {
4479
4479
  const a = s(e, i[0]);
4480
4480
  if (a === void 0) {
@@ -4486,7 +4486,7 @@ const sc = c.object({
4486
4486
  const o = (a, u) => {
4487
4487
  if (u >= i.length) return a;
4488
4488
  for (let l = i.length - u; l >= 1; l--) {
4489
- const h = i.slice(u, u + l).join(C), y = s(a, h);
4489
+ const h = i.slice(u, u + l).join(j), y = s(a, h);
4490
4490
  if (y !== void 0) {
4491
4491
  if (u + l === i.length) return y;
4492
4492
  if (y === null) {
@@ -4500,18 +4500,18 @@ const sc = c.object({
4500
4500
  throw new Error(`Path ${t} does not exist. ${i[u]} is undefined`);
4501
4501
  };
4502
4502
  return o(e, 0);
4503
- }), zc = (e, t) => Qe(e, t, { optional: !0 }) !== null, Ie = (e, ...t) => {
4503
+ }), Wc = (e, t) => tn(e, t, { optional: !0 }) !== null, Ie = (e, ...t) => {
4504
4504
  if (t.length === 0) return e;
4505
4505
  const n = t.shift();
4506
- if (pt(e) && pt(n))
4506
+ if (at(e) && at(n))
4507
4507
  for (const r in n)
4508
4508
  try {
4509
- pt(n[r]) ? (r in e || Object.assign(e, { [r]: {} }), Ie(e[r], n[r])) : Object.assign(e, { [r]: n[r] });
4509
+ at(n[r]) ? (r in e || Object.assign(e, { [r]: {} }), Ie(e[r], n[r])) : Object.assign(e, { [r]: n[r] });
4510
4510
  } catch (s) {
4511
4511
  throw s instanceof TypeError ? new TypeError(`.${r}: ${s.message}`) : s;
4512
4512
  }
4513
4513
  return Ie(e, ...t);
4514
- }, Yc = (e, t, n) => {
4514
+ }, zc = (e, t, n) => {
4515
4515
  const r = (s, i, o) => {
4516
4516
  if (o.def?.type === "union")
4517
4517
  return o.def.options.reduce(
@@ -4541,8 +4541,8 @@ const sc = c.object({
4541
4541
  return s;
4542
4542
  };
4543
4543
  return r({ ...e }, t, n);
4544
- }, Gc = (e, t) => {
4545
- const n = t.split(C);
4544
+ }, Yc = (e, t) => {
4545
+ const n = t.split(j);
4546
4546
  let r = e, s = 0;
4547
4547
  for (; s < n.length; ) {
4548
4548
  if (s === n.length - 1) {
@@ -4571,7 +4571,7 @@ const sc = c.object({
4571
4571
  const o = r[0];
4572
4572
  if (typeof o == "object" && "key" in o)
4573
4573
  for (let a = n.length - s; a >= 1; a--) {
4574
- const u = n.slice(s, s + a).join(C), l = r.find((h) => h.key === u);
4574
+ const u = n.slice(s, s + a).join(j), l = r.find((h) => h.key === u);
4575
4575
  if (l != null) {
4576
4576
  if (s + a === n.length) {
4577
4577
  const h = r.findIndex((y) => y.key === u);
@@ -4585,7 +4585,7 @@ const sc = c.object({
4585
4585
  }
4586
4586
  if (!i)
4587
4587
  for (let o = n.length - s; o >= 1; o--) {
4588
- const a = n.slice(s, s + o).join(C);
4588
+ const a = n.slice(s, s + o).join(j);
4589
4589
  if (!Array.isArray(r) && typeof r == "object" && r !== null && a in r) {
4590
4590
  if (s + o === n.length) {
4591
4591
  delete r[a];
@@ -4601,8 +4601,8 @@ const sc = c.object({
4601
4601
  r = o, s++;
4602
4602
  }
4603
4603
  }
4604
- }, Hc = (e, t, n) => {
4605
- const r = t.split(C);
4604
+ }, Gc = (e, t, n) => {
4605
+ const r = t.split(j);
4606
4606
  let s = e, i = 0;
4607
4607
  for (; i < r.length - 1; ) {
4608
4608
  const o = xe(s, r.slice(i, r.length - 1));
@@ -4611,23 +4611,23 @@ const sc = c.object({
4611
4611
  let u = dt(s, a);
4612
4612
  if (u == null) {
4613
4613
  const l = r[i];
4614
- let h = it(l);
4615
- h == null && l.startsWith("-") && it(l.substring(1)) != null && (h = 0), u = h != null ? [] : {}, s[a] = u;
4614
+ let h = ot(l);
4615
+ h == null && l.startsWith("-") && ot(l.substring(1)) != null && (h = 0), u = h != null ? [] : {}, s[a] = u;
4616
4616
  }
4617
4617
  s = u;
4618
4618
  }
4619
4619
  try {
4620
4620
  const o = r[r.length - 1];
4621
4621
  if (Array.isArray(s)) {
4622
- let u = it(o);
4622
+ let u = ot(o);
4623
4623
  if (u == null) {
4624
4624
  if (o.startsWith("-")) {
4625
- const l = it(o.substring(1));
4625
+ const l = ot(o.substring(1));
4626
4626
  l != null && (u = s.length - l);
4627
4627
  }
4628
4628
  if (u == null) {
4629
4629
  if (s.length === 0) {
4630
- const h = it(o);
4630
+ const h = ot(o);
4631
4631
  if (h != null) {
4632
4632
  s[h] = n;
4633
4633
  return;
@@ -4656,47 +4656,47 @@ const sc = c.object({
4656
4656
  } catch (o) {
4657
4657
  throw console.error("failed to set value", n, "at path", t, "on object", e), o;
4658
4658
  }
4659
- }, Fu = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
4659
+ }, _u = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
4660
4660
  __proto__: null,
4661
- SEPARATOR: C,
4662
- copy: _c,
4661
+ SEPARATOR: j,
4662
+ copy: Zc,
4663
4663
  defaultGetter: dt,
4664
- difference: qc,
4665
- element: Vc,
4664
+ difference: _c,
4665
+ element: Fc,
4666
4666
  equal: Oe,
4667
4667
  findBestKey: xe,
4668
- get: Qe,
4669
- getIndex: it,
4670
- has: zc,
4668
+ get: tn,
4669
+ getIndex: ot,
4670
+ has: Wc,
4671
4671
  override: Ie,
4672
- overrideValidItems: Yc,
4672
+ overrideValidItems: zc,
4673
4673
  partialEqual: Mr,
4674
- pathsMatch: Wc,
4675
- remove: Gc,
4676
- resolvePath: Fc,
4677
- set: Hc,
4674
+ pathsMatch: Vc,
4675
+ remove: Yc,
4676
+ resolvePath: qc,
4677
+ set: Gc,
4678
4678
  transformPath: Ar
4679
- }, Symbol.toStringTag, { value: "Module" })), Vu = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
4679
+ }, Symbol.toStringTag, { value: "Module" })), qu = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
4680
4680
  __proto__: null
4681
- }, Symbol.toStringTag, { value: "Module" })), Dc = (e) => Object.getOwnPropertySymbols(globalThis).includes(e), Jc = (e, t) => {
4681
+ }, Symbol.toStringTag, { value: "Module" })), Hc = (e) => Object.getOwnPropertySymbols(globalThis).includes(e), Dc = (e, t) => {
4682
4682
  const n = Symbol.for(e);
4683
- if (!Dc(n)) {
4683
+ if (!Hc(n)) {
4684
4684
  const r = t();
4685
4685
  Object.defineProperty(globalThis, n, { value: r });
4686
4686
  }
4687
4687
  return () => globalThis[n];
4688
- }, Er = "sy_x_error", Xc = (e) => (t) => t != null && typeof t == "object" && "type" in t && typeof t.type == "string" ? t.type.startsWith(e) : t instanceof Error ? t.message.startsWith(e) : typeof t != "string" ? !1 : t.startsWith(e), St = (e) => class mt extends Error {
4688
+ }, Er = "sy_x_error", Jc = (e) => (t) => t != null && typeof t == "object" && "type" in t && typeof t.type == "string" ? t.type.startsWith(e) : t instanceof Error ? t.message.startsWith(e) : typeof t != "string" ? !1 : t.startsWith(e), Tt = (e) => class mt extends Error {
4689
4689
  static discriminator = Er;
4690
4690
  discriminator = mt.discriminator;
4691
4691
  static TYPE = e;
4692
4692
  type = mt.TYPE;
4693
- static matches = Xc(e);
4693
+ static matches = Jc(e);
4694
4694
  matches = mt.matches;
4695
4695
  constructor(n, r) {
4696
4696
  super(n, r), this.name = mt.TYPE;
4697
4697
  }
4698
4698
  static sub(n) {
4699
- return St(`${e}.${n}`);
4699
+ return Tt(`${e}.${n}`);
4700
4700
  }
4701
4701
  }, Sr = (e) => {
4702
4702
  if (e == null || typeof e != "object") return !1;
@@ -4707,8 +4707,8 @@ const sc = c.object({
4707
4707
  `X Error is missing its type property: ${JSON.stringify(t)}`
4708
4708
  );
4709
4709
  return !0;
4710
- }, ot = "unknown", Ne = "nil";
4711
- class Kc {
4710
+ }, ct = "unknown", Ne = "nil";
4711
+ class Xc {
4712
4712
  providers = [];
4713
4713
  register(t) {
4714
4714
  this.providers.push(t);
@@ -4720,17 +4720,17 @@ class Kc {
4720
4720
  const r = n.encode(t);
4721
4721
  if (r != null) return r;
4722
4722
  }
4723
- if (t instanceof Error) return { type: ot, data: t.message };
4724
- if (typeof t == "string") return { type: ot, data: t };
4723
+ if (t instanceof Error) return { type: ct, data: t.message };
4724
+ if (typeof t == "string") return { type: ct, data: t };
4725
4725
  try {
4726
- return { type: ot, data: JSON.stringify(t) };
4726
+ return { type: ct, data: JSON.stringify(t) };
4727
4727
  } catch {
4728
- return { type: ot, data: "unable to encode error information" };
4728
+ return { type: ct, data: "unable to encode error information" };
4729
4729
  }
4730
4730
  }
4731
4731
  decode(t) {
4732
4732
  if (t == null || t.type === Ne) return null;
4733
- if (t.type === ot) return new ve(t.data);
4733
+ if (t.type === ct) return new ve(t.data);
4734
4734
  for (const n of this.providers) {
4735
4735
  const r = n.decode(t);
4736
4736
  if (r != null) return r;
@@ -4738,85 +4738,29 @@ class Kc {
4738
4738
  return new ve(t.data);
4739
4739
  }
4740
4740
  }
4741
- const tn = Jc("synnax-error-registry", () => new Kc()), Qc = ({ encode: e, decode: t }) => tn().register({ encode: e, decode: t }), ta = (e) => tn().encode(e), ea = (e) => e == null ? null : tn().decode(e);
4742
- class ve extends St("unknown") {
4741
+ const en = Dc("synnax-error-registry", () => new Xc()), Kc = ({ encode: e, decode: t }) => en().register({ encode: e, decode: t }), Qc = (e) => en().encode(e), ta = (e) => e == null ? null : en().decode(e);
4742
+ class ve extends Tt("unknown") {
4743
4743
  }
4744
- const na = c.object({ type: c.string(), data: c.string() });
4745
- class ra extends St("canceled") {
4744
+ const ea = c.object({ type: c.string(), data: c.string() });
4745
+ class na extends Tt("canceled") {
4746
4746
  }
4747
- class sa extends St("not_implemented") {
4747
+ class ra extends Tt("not_implemented") {
4748
4748
  }
4749
- const Wu = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
4749
+ const Fu = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
4750
4750
  __proto__: null,
4751
- Canceled: ra,
4751
+ Canceled: na,
4752
4752
  NONE: Ne,
4753
- NotImplemented: sa,
4754
- UNKNOWN: ot,
4753
+ NotImplemented: ra,
4754
+ UNKNOWN: ct,
4755
4755
  Unknown: ve,
4756
- createTyped: St,
4757
- decode: ea,
4758
- encode: ta,
4756
+ createTyped: Tt,
4757
+ decode: ta,
4758
+ encode: Qc,
4759
4759
  isTyped: Sr,
4760
- payloadZ: na,
4761
- register: Qc
4762
- }, Symbol.toStringTag, { value: "Module" })), Tr = b.object({
4763
- jsonrpc: b.literal("2.0"),
4764
- method: b.string(),
4765
- // params should be z.union([z.record(z.string(), z.json()),
4766
- // z.array(z.json())]).optional() but the VSCode JSON RPC implementation uses a looser
4767
- // definition of params then in the JSON-RPC spec.
4768
- params: b.any().optional(),
4769
- id: b.union([b.string(), b.number(), b.null()]).optional()
4770
- }), $r = b.object({
4771
- jsonrpc: b.literal("2.0"),
4772
- id: b.union([b.string(), b.number(), b.null()])
4773
- }), ia = $r.extend({
4774
- result: b.json()
4775
- }), oa = $r.extend({
4776
- error: b.object({
4777
- code: b.number().int(),
4778
- // This should be z.string(), but the VSCode JSON RPC implementation uses a looser
4779
- // definition of error than the JSON-RPC spec.
4780
- message: b.string().optional(),
4781
- data: b.json().optional()
4782
- })
4783
- }), Ur = b.union([ia, oa]), jr = b.union([Tr, Ur]), ca = (e) => {
4784
- const t = new TextDecoder();
4785
- let n = new Uint8Array(0), r = null;
4786
- return (s) => {
4787
- let i;
4788
- typeof s == "string" ? i = new TextEncoder().encode(s) : s instanceof ArrayBuffer ? i = new Uint8Array(s) : i = s;
4789
- const o = new Uint8Array(n.length + i.length);
4790
- for (o.set(n), o.set(i, n.length), n = o; n.length > 0; ) {
4791
- if (r === null) {
4792
- const u = t.decode(n).match(/^Content-Length: (\d+)\r?\n\r?\n/);
4793
- if (!u) break;
4794
- r = parseInt(u[1]);
4795
- const l = new TextEncoder().encode(u[0]).length;
4796
- n = n.slice(l);
4797
- }
4798
- if (r !== null && n.length >= r) {
4799
- const a = n.slice(0, r);
4800
- n = n.slice(r), r = null;
4801
- const u = t.decode(a), l = at.decodeString(u, jr);
4802
- e(l);
4803
- } else break;
4804
- }
4805
- };
4806
- }, aa = (e) => {
4807
- const t = JSON.stringify(e);
4808
- return `Content-Length: ${new TextEncoder().encode(t).length}\r
4809
- \r
4810
- ` + t;
4811
- }, zu = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
4812
- __proto__: null,
4813
- encodeMessage: aa,
4814
- messageZ: jr,
4815
- requestZ: Tr,
4816
- responseZ: Ur,
4817
- streamDecodeChunks: ca
4760
+ payloadZ: ea,
4761
+ register: Kc
4818
4762
  }, Symbol.toStringTag, { value: "Module" }));
4819
- class ua {
4763
+ class sa {
4820
4764
  store = /* @__PURE__ */ new Map();
4821
4765
  async get(t) {
4822
4766
  return this.store.get(t) ?? null;
@@ -4834,7 +4778,7 @@ class ua {
4834
4778
  this.store.clear();
4835
4779
  }
4836
4780
  }
4837
- class la {
4781
+ class ia {
4838
4782
  store = /* @__PURE__ */ new Map();
4839
4783
  get(t) {
4840
4784
  return this.store.get(t) ?? null;
@@ -4846,32 +4790,32 @@ class la {
4846
4790
  this.store.delete(t);
4847
4791
  }
4848
4792
  }
4849
- const fa = c.object({ key: c.string(), value: c.string() }), Yu = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
4793
+ const oa = c.object({ key: c.string(), value: c.string() }), Vu = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
4850
4794
  __proto__: null,
4851
- MockAsync: ua,
4852
- MockSync: la,
4853
- stringPairZ: fa
4854
- }, Symbol.toStringTag, { value: "Module" })), Cr = b.uuid(), Br = b.object({
4855
- key: Cr,
4856
- name: b.string().min(1),
4857
- color: b.string()
4858
- }), Gu = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
4795
+ MockAsync: sa,
4796
+ MockSync: ia,
4797
+ stringPairZ: oa
4798
+ }, Symbol.toStringTag, { value: "Module" })), Tr = k.uuid(), $r = k.object({
4799
+ key: Tr,
4800
+ name: k.string().min(1),
4801
+ color: St
4802
+ }), Wu = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
4859
4803
  __proto__: null,
4860
- keyZ: Cr,
4861
- labelZ: Br
4862
- }, Symbol.toStringTag, { value: "Module" })), ha = new RegExp(
4804
+ keyZ: Tr,
4805
+ labelZ: $r
4806
+ }, Symbol.toStringTag, { value: "Module" })), ca = new RegExp(
4863
4807
  "^(https?:\\/\\/)?((([a-zA-Z0-9][a-zA-Z0-9-]*\\.)+[a-zA-Z]{2,})|localhost|(\\d{1,3}\\.){3}\\d{1,3})(\\:\\d+)?(\\/[-a-zA-Z0-9@:%._\\+~#=]*)*(\\?[;&a-zA-Z0-9%_.,~+=-]*)?(#[-a-zA-Z0-9_]*)?$"
4864
4808
  // fragment identifier (optional)
4865
- ), da = (e) => ha.test(e), Hu = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
4809
+ ), aa = (e) => ca.test(e), zu = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
4866
4810
  __proto__: null,
4867
- is: da
4868
- }, Symbol.toStringTag, { value: "Module" })), ga = (e, t, n) => {
4811
+ is: aa
4812
+ }, Symbol.toStringTag, { value: "Module" })), ua = (e, t, n) => {
4869
4813
  const r = e.get(t);
4870
4814
  return r === void 0 ? (e.set(t, n), n) : r;
4871
- }, Du = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
4815
+ }, Yu = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
4872
4816
  __proto__: null,
4873
- getOrSetDefault: ga
4874
- }, Symbol.toStringTag, { value: "Module" })), Me = c.string().regex(/^\d+\.\d+\.\d+(-[0-9A-Za-z-]+(\.[0-9A-Za-z-]+)*)?$/), ya = (e, t) => {
4817
+ getOrSetDefault: ua
4818
+ }, Symbol.toStringTag, { value: "Module" })), Me = c.string().regex(/^\d+\.\d+\.\d+(-[0-9A-Za-z-]+(\.[0-9A-Za-z-]+)*)?$/), la = (e, t) => {
4875
4819
  const n = e.split("."), r = t.split("."), s = Math.max(n.length, r.length);
4876
4820
  for (let i = 0; i < s; i++) {
4877
4821
  const o = n[i], a = r[i];
@@ -4889,24 +4833,24 @@ const fa = c.object({ key: c.string(), value: c.string() }), Yu = /* @__PURE__ *
4889
4833
  if (o > a) return Y;
4890
4834
  }
4891
4835
  }
4892
- return st;
4893
- }, Tt = ((e, t, n = {}) => {
4836
+ return it;
4837
+ }, $t = ((e, t, n = {}) => {
4894
4838
  n.checkMajor ??= !0, n.checkMinor ??= !0, n.checkPatch ??= !0;
4895
- const r = Me.parse(e), s = Me.parse(t), [i, o] = r.split("-"), [a, u] = s.split("-"), [l, h, y] = i.split(".").map(Number), [m, A, T] = a.split(".").map(Number);
4839
+ const r = Me.parse(e), s = Me.parse(t), [i, o] = r.split("-"), [a, u] = s.split("-"), [l, h, y] = i.split(".").map(Number), [m, M, S] = a.split(".").map(Number);
4896
4840
  if (n.checkMajor) {
4897
4841
  if (l < m) return z;
4898
4842
  if (l > m) return Y;
4899
4843
  }
4900
4844
  if (n.checkMinor) {
4901
- if (h < A) return z;
4902
- if (h > A) return Y;
4845
+ if (h < M) return z;
4846
+ if (h > M) return Y;
4903
4847
  }
4904
4848
  if (n.checkPatch) {
4905
- if (y < T) return z;
4906
- if (y > T) return Y;
4849
+ if (y < S) return z;
4850
+ if (y > S) return Y;
4907
4851
  }
4908
- return o === void 0 && u === void 0 ? st : o === void 0 ? Y : u === void 0 ? z : ya(o, u);
4909
- }), ma = (e, t, n = {}) => An(Tt(e, t, n)), Rr = (e, t, n = {}) => Mn(Tt(e, t, n)), pa = (e, t, n = {}) => vn(Tt(e, t, n)), ba = ({
4852
+ return o === void 0 && u === void 0 ? it : o === void 0 ? Y : u === void 0 ? z : la(o, u);
4853
+ }), fa = (e, t, n = {}) => En($t(e, t, n)), Ur = (e, t, n = {}) => An($t(e, t, n)), ha = (e, t, n = {}) => Mn($t(e, t, n)), da = ({
4910
4854
  name: e,
4911
4855
  migrate: t
4912
4856
  }) => (n) => {
@@ -4916,14 +4860,14 @@ const fa = c.object({ key: c.string(), value: c.string() }), Yu = /* @__PURE__ *
4916
4860
  } catch (r) {
4917
4861
  throw console.log(`${e} failed to migrate from ${n.version}`), console.error(r), r;
4918
4862
  }
4919
- }, wa = ({
4863
+ }, ga = ({
4920
4864
  name: e,
4921
4865
  migrations: t,
4922
4866
  targetSchema: n,
4923
4867
  defaultVersion: r,
4924
4868
  def: s
4925
4869
  }) => {
4926
- const i = Object.keys(t).sort(Tt).pop();
4870
+ const i = Object.keys(t).sort($t).pop();
4927
4871
  if (i == null)
4928
4872
  return (l) => {
4929
4873
  if (l.version ??= r, l.version !== s.version)
@@ -4942,7 +4886,7 @@ const fa = c.object({ key: c.string(), value: c.string() }), Yu = /* @__PURE__ *
4942
4886
  let a = !1;
4943
4887
  const u = (l) => {
4944
4888
  try {
4945
- if (o === 0 || Rr(l.version, i))
4889
+ if (o === 0 || Ur(l.version, i))
4946
4890
  return console.log(a ? `${e} ${l.version} now up to date` : `${e} version ${l.version} is up to date with target version ${s.version}`), l;
4947
4891
  const h = l.version, y = t[h], m = y(l);
4948
4892
  return a = !0, u(m);
@@ -4968,16 +4912,16 @@ const fa = c.object({ key: c.string(), value: c.string() }), Yu = /* @__PURE__ *
4968
4912
  return console.log(`${e} failed to parse final result. Exiting with default`), console.error(h), s;
4969
4913
  }
4970
4914
  };
4971
- }, Ju = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
4915
+ }, Gu = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
4972
4916
  __proto__: null,
4973
- compareSemVer: Tt,
4974
- createMigration: ba,
4975
- migrator: wa,
4976
- semVerNewer: Rr,
4977
- semVerOlder: pa,
4917
+ compareSemVer: $t,
4918
+ createMigration: da,
4919
+ migrator: ga,
4920
+ semVerNewer: Ur,
4921
+ semVerOlder: ha,
4978
4922
  semVerZ: Me,
4979
- versionsEqual: ma
4980
- }, Symbol.toStringTag, { value: "Module" })), Pr = ["standard", "scientific", "engineering"], Oa = c.enum(Pr), xa = (e, t, n) => {
4923
+ versionsEqual: fa
4924
+ }, Symbol.toStringTag, { value: "Module" })), jr = ["standard", "scientific", "engineering"], ya = c.enum(jr), ma = (e, t, n) => {
4981
4925
  if (Number.isNaN(e)) return "NaN";
4982
4926
  if (e === 1 / 0) return "∞";
4983
4927
  if (e === -1 / 0) return "-∞";
@@ -4986,13 +4930,13 @@ const fa = c.object({ key: c.string(), value: c.string() }), Yu = /* @__PURE__ *
4986
4930
  return t === 0 ? "0ᴇ0" : `0.${"0".repeat(t)}ᴇ0`;
4987
4931
  let r;
4988
4932
  return n === "scientific" ? r = Math.floor(Math.log10(Math.abs(e))) : r = Math.floor(Math.log10(Math.abs(e)) / 3) * 3, `${(e / 10 ** r).toFixed(t)}ᴇ${r}`;
4989
- }, Xu = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
4933
+ }, Hu = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
4990
4934
  __proto__: null,
4991
- NOTATIONS: Pr,
4992
- notationZ: Oa,
4993
- stringifyNumber: xa
4935
+ NOTATIONS: jr,
4936
+ notationZ: ya,
4937
+ stringifyNumber: ma
4994
4938
  }, Symbol.toStringTag, { value: "Module" }));
4995
- class Ia {
4939
+ class pa {
4996
4940
  handlers;
4997
4941
  transform;
4998
4942
  closer;
@@ -5020,7 +4964,7 @@ class Ia {
5020
4964
  return await this.closer?.();
5021
4965
  }
5022
4966
  }
5023
- class Na {
4967
+ class ba {
5024
4968
  handlers;
5025
4969
  constructor(t) {
5026
4970
  this.handlers = t ?? /* @__PURE__ */ new Map();
@@ -5032,117 +4976,150 @@ class Na {
5032
4976
  this.handlers.forEach((n, r) => r(t));
5033
4977
  }
5034
4978
  }
5035
- const Ku = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
4979
+ const Du = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
5036
4980
  __proto__: null,
5037
- BaseObserver: Na,
5038
- Observer: Ia
5039
- }, Symbol.toStringTag, { value: "Module" })), Qu = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
4981
+ BaseObserver: ba,
4982
+ Observer: pa
4983
+ }, Symbol.toStringTag, { value: "Module" })), Ju = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
5040
4984
  __proto__: null
5041
- }, Symbol.toStringTag, { value: "Module" })), va = c.record(
5042
- c.union([c.number(), c.string(), c.symbol()]),
5043
- c.unknown()
5044
- ), en = (e) => Object.entries(e), Ma = (e, t) => Object.fromEntries(en(e).map(([n, r]) => [n, t(r, n)])), Aa = (e) => Object.fromEntries(en(e).filter(([t, n]) => n !== void 0)), Ea = (e, ...t) => {
4985
+ }, Symbol.toStringTag, { value: "Module" })), Cr = c.union([c.string(), c.number()]), Br = c.record(Cr, c.unknown()), wa = () => c.union([
4986
+ c.union([c.null(), c.undefined()]).transform(() => ({})),
4987
+ Br
4988
+ ]), nn = (e) => Object.entries(e), Oa = (e, t) => Object.fromEntries(nn(e).map(([n, r]) => [n, t(r, n)])), xa = (e) => Object.fromEntries(nn(e).filter(([t, n]) => n !== void 0)), Ia = (e, ...t) => {
5045
4989
  const n = { ...e };
5046
4990
  for (const r of t) delete n[r];
5047
4991
  return n;
5048
- }, tl = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
4992
+ }, Xu = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
5049
4993
  __proto__: null,
5050
- entries: en,
5051
- map: Ma,
5052
- omit: Ea,
5053
- purgeUndefined: Aa,
5054
- unknownZ: va
5055
- }, Symbol.toStringTag, { value: "Module" })), Lr = () => typeof process < "u" && process.versions != null && process.versions.node != null ? "node" : typeof window > "u" || window.document === void 0 ? "webworker" : "browser", Sa = Lr(), kr = ["macOS", "Windows", "Linux"], Ta = ["macos", "windows", "linux"], $a = {
4994
+ entries: nn,
4995
+ keyZ: Cr,
4996
+ map: Oa,
4997
+ nullishToEmpty: wa,
4998
+ omit: Ia,
4999
+ purgeUndefined: xa,
5000
+ unknownZ: Br
5001
+ }, Symbol.toStringTag, { value: "Module" })), Pr = () => typeof process < "u" && process.versions != null && process.versions.node != null ? "node" : typeof window > "u" || window.document === void 0 ? "webworker" : "browser", Na = Pr(), Rr = ["macOS", "Windows", "Linux"], va = ["macos", "windows", "linux"], Ma = {
5056
5002
  macos: "macOS",
5057
5003
  windows: "Windows",
5058
5004
  linux: "Linux"
5059
- }, Ua = c.enum(kr).or(
5060
- c.enum(Ta).transform((e) => $a[e])
5061
- ), ja = () => {
5005
+ }, Aa = c.enum(Rr).or(
5006
+ c.enum(va).transform((e) => Ma[e])
5007
+ ), Ea = () => {
5062
5008
  if (typeof window > "u") return;
5063
5009
  const e = window.navigator.userAgent.toLowerCase();
5064
5010
  if (e.includes("mac")) return "macOS";
5065
5011
  if (e.includes("win")) return "Windows";
5066
5012
  if (e.includes("linux")) return "Linux";
5067
5013
  };
5068
- let Bt;
5069
- const Ca = ((e = {}) => {
5014
+ let Pt;
5015
+ const Sa = ((e = {}) => {
5070
5016
  const { force: t, default: n } = e;
5071
- return t ?? Bt ?? (Bt = ja(), Bt ?? n);
5072
- }), el = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
5017
+ return t ?? Pt ?? (Pt = Ea(), Pt ?? n);
5018
+ }), Ku = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
5073
5019
  __proto__: null,
5074
- OPERATING_SYSTEMS: kr,
5075
- RUNTIME: Sa,
5076
- detect: Lr,
5077
- getOS: Ca,
5078
- osZ: Ua
5079
- }, Symbol.toStringTag, { value: "Module" })), Ba = () => Promise.resolve(), Ra = () => new Promise((e) => setTimeout(e, 0)), nl = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
5020
+ OPERATING_SYSTEMS: Rr,
5021
+ RUNTIME: Na,
5022
+ detect: Pr,
5023
+ getOS: Sa,
5024
+ osZ: Aa
5025
+ }, Symbol.toStringTag, { value: "Module" })), Ta = () => Promise.resolve(), $a = () => new Promise((e) => setTimeout(e, 0)), Qu = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
5080
5026
  __proto__: null,
5081
- flushMicrotasks: Ba,
5082
- flushTaskQueue: Ra
5083
- }, Symbol.toStringTag, { value: "Module" })), Pa = (e) => Array.isArray(e) ? [...e] : typeof e == "object" && e !== null ? { ...e } : e, rl = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
5027
+ flushMicrotasks: Ta,
5028
+ flushTaskQueue: $a
5029
+ }, Symbol.toStringTag, { value: "Module" })), Ua = (e) => Array.isArray(e) ? [...e] : typeof e == "object" && e !== null ? { ...e } : e, tl = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
5084
5030
  __proto__: null,
5085
- copy: Pa
5086
- }, Symbol.toStringTag, { value: "Module" })), Zr = c.enum([
5031
+ copy: Ua
5032
+ }, Symbol.toStringTag, { value: "Module" })), kr = c.enum([
5087
5033
  "success",
5088
5034
  "info",
5089
5035
  "warning",
5090
5036
  "error",
5091
5037
  "loading",
5092
5038
  "disabled"
5093
- ]), La = (e) => c.object({
5039
+ ]), ja = (e) => c.object({
5094
5040
  key: c.string(),
5095
5041
  name: c.string().default(""),
5096
- variant: Zr,
5042
+ variant: kr,
5097
5043
  message: c.string(),
5098
5044
  description: c.string().optional(),
5099
5045
  time: d.z,
5100
- labels: dn(Br).optional(),
5046
+ labels: gn($r).optional(),
5101
5047
  details: e ?? c.unknown().optional()
5102
- }), ka = c.object({
5048
+ }), Ca = c.object({
5103
5049
  stack: c.string(),
5104
5050
  error: c.instanceof(Error)
5105
- }), Za = (e, t) => {
5051
+ }), Ba = (e, t) => {
5106
5052
  if (!(e instanceof Error)) throw e;
5107
- return _r({
5053
+ return Lr({
5108
5054
  variant: "error",
5109
5055
  message: t ?? e.message,
5110
5056
  description: t != null ? e.message : void 0,
5111
5057
  details: { stack: e.stack ?? "", error: e }
5112
5058
  });
5113
- }, _r = (e) => ({
5059
+ }, Lr = (e) => ({
5114
5060
  key: Se(),
5115
5061
  time: d.now(),
5116
5062
  name: "",
5117
5063
  ...e
5118
- }), _a = (e, t = []) => {
5064
+ }), Pa = (e, t = []) => {
5119
5065
  if (e != null)
5120
5066
  return Array.isArray(t) ? t.includes(e) ? e : void 0 : t === e ? e : void 0;
5121
- }, qa = (e, t = []) => {
5067
+ }, Ra = (e, t = []) => {
5122
5068
  if (e != null)
5123
5069
  return Array.isArray(t) ? t.includes(e) ? void 0 : e : t === e ? void 0 : e;
5124
- }, sl = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
5070
+ }, ka = {
5071
+ includeTimestamp: !1,
5072
+ includeName: !0
5073
+ }, La = (e, t = {}) => {
5074
+ const n = { ...ka, ...t }, r = [];
5075
+ let s = e.variant.toUpperCase();
5076
+ if (n.includeName && e.name.length > 0 && (s += ` [${e.name}]`), s += `: ${e.message}`, n.includeTimestamp && (s += ` (${e.time.toString("dateTime", "local")})`), r.push(s), e.description != null) {
5077
+ let i;
5078
+ try {
5079
+ const o = JSON.parse(e.description);
5080
+ i = `Description:
5081
+ ${JSON.stringify(o, null, 2)}`;
5082
+ } catch {
5083
+ i = `Description: ${e.description}`;
5084
+ }
5085
+ r.push(i);
5086
+ }
5087
+ if ("details" in e && at(e.details)) {
5088
+ const i = e.details;
5089
+ "stack" in i && r.push(`Stack Trace:
5090
+ ${String(i.stack)}`);
5091
+ const o = Object.fromEntries(
5092
+ Object.entries(i).filter(([a]) => a !== "stack" && a !== "error")
5093
+ );
5094
+ Object.keys(o).length > 0 && r.push(`Details:
5095
+ ${JSON.stringify(o, null, 2)}`);
5096
+ }
5097
+ return r.join(`
5098
+
5099
+ `);
5100
+ }, el = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
5125
5101
  __proto__: null,
5126
- create: _r,
5127
- exceptionDetailsSchema: ka,
5128
- fromException: Za,
5129
- keepVariants: _a,
5130
- removeVariants: qa,
5131
- statusZ: La,
5132
- variantZ: Zr
5133
- }, Symbol.toStringTag, { value: "Module" })), Fa = (e, t) => {
5102
+ create: Lr,
5103
+ exceptionDetailsSchema: Ca,
5104
+ fromException: Ba,
5105
+ keepVariants: Pa,
5106
+ removeVariants: Ra,
5107
+ statusZ: ja,
5108
+ toString: La,
5109
+ variantZ: kr
5110
+ }, Symbol.toStringTag, { value: "Module" })), Za = (e, t) => {
5134
5111
  if (!t.has(e)) return e;
5135
5112
  let n = e, r = 1, s = e;
5136
5113
  for (; t.has(s); ) {
5137
- const i = s.match(Va);
5114
+ const i = s.match(_a);
5138
5115
  i ? (n = s.slice(0, i.index).trim(), r = parseInt(i[1]) + 1) : (n = s, r = 1), s = `${n} (${r})`;
5139
5116
  }
5140
5117
  return s;
5141
- }, Va = /\((\d+)\)$/, Wa = (e, t = "") => {
5118
+ }, _a = /\((\d+)\)$/, qa = (e, t = "") => {
5142
5119
  if (typeof e == "string") return e;
5143
5120
  const n = e.length;
5144
5121
  return n === 0 ? t : n === 1 ? e[0] : n === 2 ? `${e[0]} and ${e[1]}` : `${e.slice(0, -1).join(", ")}, and ${e[n - 1]}`;
5145
- }, za = (e) => {
5122
+ }, Fa = (e) => {
5146
5123
  const t = e.split(" "), n = /* @__PURE__ */ new Set(), r = t.map((u) => u.charAt(0).toLowerCase()).join("");
5147
5124
  n.add(r.replace(/-/g, "_")), n.add(r.replace(/(.)(.)/g, "$1_$2").replace(/-/g, "_"));
5148
5125
  const s = /\d+/g;
@@ -5160,14 +5137,14 @@ const Ca = ((e = {}) => {
5160
5137
  return n.add(o.join("").replace(/-/g, "_")), n.add(o.join("_").replace(/-/g, "_")), Array.from(n).filter(
5161
5138
  (u) => u.length >= 2 && u.length <= 12 && !/^\d/.test(u)
5162
5139
  );
5163
- }, Ya = (e, t) => e.startsWith(t) ? e.slice(t.length) : e, il = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
5140
+ }, Va = (e, t) => e.startsWith(t) ? e.slice(t.length) : e, nl = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
5164
5141
  __proto__: null,
5165
- createShortIdentifiers: za,
5166
- deduplicateFileName: Fa,
5167
- naturalLanguageJoin: Wa,
5168
- trimPrefix: Ya
5169
- }, Symbol.toStringTag, { value: "Module" })), Ga = new Error("request for lock canceled");
5170
- var Ha = function(e, t, n, r) {
5142
+ createShortIdentifiers: Fa,
5143
+ deduplicateFileName: Za,
5144
+ naturalLanguageJoin: qa,
5145
+ trimPrefix: Va
5146
+ }, Symbol.toStringTag, { value: "Module" })), Wa = new Error("request for lock canceled");
5147
+ var za = function(e, t, n, r) {
5171
5148
  function s(i) {
5172
5149
  return i instanceof n ? i : new n(function(o) {
5173
5150
  o(i);
@@ -5194,20 +5171,20 @@ var Ha = function(e, t, n, r) {
5194
5171
  l((r = r.apply(e, t || [])).next());
5195
5172
  });
5196
5173
  };
5197
- class Da {
5198
- constructor(t, n = Ga) {
5174
+ class Ya {
5175
+ constructor(t, n = Wa) {
5199
5176
  this._value = t, this._cancelError = n, this._queue = [], this._weightedWaiters = [];
5200
5177
  }
5201
5178
  acquire(t = 1, n = 0) {
5202
5179
  if (t <= 0)
5203
5180
  throw new Error(`invalid weight ${t}: must be positive`);
5204
5181
  return new Promise((r, s) => {
5205
- const i = { resolve: r, reject: s, weight: t, priority: n }, o = qr(this._queue, (a) => n <= a.priority);
5182
+ const i = { resolve: r, reject: s, weight: t, priority: n }, o = Zr(this._queue, (a) => n <= a.priority);
5206
5183
  o === -1 && t <= this._value ? this._dispatchItem(i) : this._queue.splice(o + 1, 0, i);
5207
5184
  });
5208
5185
  }
5209
5186
  runExclusive(t) {
5210
- return Ha(this, arguments, void 0, function* (n, r = 1, s = 0) {
5187
+ return za(this, arguments, void 0, function* (n, r = 1, s = 0) {
5211
5188
  const [i, o] = yield this.acquire(r, s);
5212
5189
  try {
5213
5190
  return yield n(i);
@@ -5220,7 +5197,7 @@ class Da {
5220
5197
  if (t <= 0)
5221
5198
  throw new Error(`invalid weight ${t}: must be positive`);
5222
5199
  return this._couldLockImmediately(t, n) ? Promise.resolve() : new Promise((r) => {
5223
- this._weightedWaiters[t - 1] || (this._weightedWaiters[t - 1] = []), Ja(this._weightedWaiters[t - 1], { resolve: r, priority: n });
5200
+ this._weightedWaiters[t - 1] || (this._weightedWaiters[t - 1] = []), Ga(this._weightedWaiters[t - 1], { resolve: r, priority: n });
5224
5201
  });
5225
5202
  }
5226
5203
  isLocked() {
@@ -5275,17 +5252,17 @@ class Da {
5275
5252
  return (this._queue.length === 0 || this._queue[0].priority < n) && t <= this._value;
5276
5253
  }
5277
5254
  }
5278
- function Ja(e, t) {
5279
- const n = qr(e, (r) => t.priority <= r.priority);
5255
+ function Ga(e, t) {
5256
+ const n = Zr(e, (r) => t.priority <= r.priority);
5280
5257
  e.splice(n + 1, 0, t);
5281
5258
  }
5282
- function qr(e, t) {
5259
+ function Zr(e, t) {
5283
5260
  for (let n = e.length - 1; n >= 0; n--)
5284
5261
  if (t(e[n]))
5285
5262
  return n;
5286
5263
  return -1;
5287
5264
  }
5288
- var Xa = function(e, t, n, r) {
5265
+ var Ha = function(e, t, n, r) {
5289
5266
  function s(i) {
5290
5267
  return i instanceof n ? i : new n(function(o) {
5291
5268
  o(i);
@@ -5312,12 +5289,12 @@ var Xa = function(e, t, n, r) {
5312
5289
  l((r = r.apply(e, t || [])).next());
5313
5290
  });
5314
5291
  };
5315
- class Ka {
5292
+ class Da {
5316
5293
  constructor(t) {
5317
- this._semaphore = new Da(1, t);
5294
+ this._semaphore = new Ya(1, t);
5318
5295
  }
5319
5296
  acquire() {
5320
- return Xa(this, arguments, void 0, function* (t = 0) {
5297
+ return Ha(this, arguments, void 0, function* (t = 0) {
5321
5298
  const [, n] = yield this._semaphore.acquire(1, t);
5322
5299
  return n;
5323
5300
  });
@@ -5338,25 +5315,25 @@ class Ka {
5338
5315
  return this._semaphore.cancel();
5339
5316
  }
5340
5317
  }
5341
- class Fr extends Ka {
5318
+ class _r extends Da {
5342
5319
  constructor(t) {
5343
5320
  super(), Object.assign(this, t);
5344
5321
  }
5345
5322
  }
5346
- const Qa = (e) => new Fr(e), ol = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
5323
+ const Ja = (e) => new _r(e), rl = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
5347
5324
  __proto__: null,
5348
- mutex: Fr,
5349
- newMutex: Qa
5350
- }, Symbol.toStringTag, { value: "Module" })), tu = (e) => JSON.stringify(e, (t, n) => typeof n == "bigint" ? n.toString() : n), eu = async (e, t = 200, n = 20) => {
5325
+ mutex: _r,
5326
+ newMutex: Ja
5327
+ }, Symbol.toStringTag, { value: "Module" })), Xa = (e) => JSON.stringify(e, (t, n) => typeof n == "bigint" ? n.toString() : n), Ka = async (e, t = 200, n = 20) => {
5351
5328
  const r = Date.now();
5352
5329
  for (; Date.now() - r < t; )
5353
5330
  await e(), await new Promise((s) => setTimeout(s, n));
5354
- }, cl = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
5331
+ }, sl = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
5355
5332
  __proto__: null,
5356
- expectAlways: eu,
5357
- toString: tu
5358
- }, Symbol.toStringTag, { value: "Module" })), nu = (...e) => e.map(Vr).join(""), Vr = (e) => (e.endsWith("/") || (e += "/"), e.startsWith("/") && (e = e.slice(1)), e), ru = (e) => e.endsWith("/") ? e.slice(0, -1) : e, al = (e, t = "") => e === null ? "" : `?${Object.entries(e).filter(([, n]) => n == null ? !1 : Array.isArray(n) ? n.length > 0 : !0).map(([n, r]) => `${t}${n}=${r}`).join("&")}`;
5359
- class Zt {
5333
+ expectAlways: Ka,
5334
+ toString: Xa
5335
+ }, Symbol.toStringTag, { value: "Module" })), Qa = (...e) => e.map(qr).join(""), qr = (e) => (e.endsWith("/") || (e += "/"), e.startsWith("/") && (e = e.slice(1)), e), tu = (e) => e.endsWith("/") ? e.slice(0, -1) : e, il = (e, t = "") => e === null ? "" : `?${Object.entries(e).filter(([, n]) => n == null ? !1 : Array.isArray(n) ? n.length > 0 : !0).map(([n, r]) => `${t}${n}=${r}`).join("&")}`;
5336
+ class _t {
5360
5337
  protocol;
5361
5338
  host;
5362
5339
  port;
@@ -5368,7 +5345,7 @@ class Zt {
5368
5345
  * @param pathPrefix - A path prefix to use for all requests. Defaults to "".
5369
5346
  */
5370
5347
  constructor({ host: t, port: n, protocol: r = "", pathPrefix: s = "" }) {
5371
- this.protocol = r, this.host = t, this.port = n, this.path = Vr(s);
5348
+ this.protocol = r, this.host = t, this.port = n, this.path = qr(s);
5372
5349
  }
5373
5350
  /**
5374
5351
  * Replaces creates a new URL with the specified properties replaced.
@@ -5376,7 +5353,7 @@ class Zt {
5376
5353
  * @returns a new URL.
5377
5354
  */
5378
5355
  replace(t) {
5379
- return new Zt({
5356
+ return new _t({
5380
5357
  host: t.host ?? this.host,
5381
5358
  port: t.port ?? this.port,
5382
5359
  protocol: t.protocol ?? this.protocol,
@@ -5389,20 +5366,20 @@ class Zt {
5389
5366
  * @returns a new URL.
5390
5367
  */
5391
5368
  child(t) {
5392
- return new Zt({
5369
+ return new _t({
5393
5370
  ...this,
5394
- pathPrefix: nu(this.path, t)
5371
+ pathPrefix: Qa(this.path, t)
5395
5372
  });
5396
5373
  }
5397
5374
  /** @returns a string representation of the url */
5398
5375
  toString() {
5399
- return ru(
5376
+ return tu(
5400
5377
  `${this.protocol}://${this.host}:${this.port}/${this.path}`
5401
5378
  );
5402
5379
  }
5403
- static UNKNOWN = new Zt({ host: "unknown", port: 0 });
5380
+ static UNKNOWN = new _t({ host: "unknown", port: 0 });
5404
5381
  }
5405
- class fn {
5382
+ class hn {
5406
5383
  sender;
5407
5384
  handlers;
5408
5385
  constructor(t) {
@@ -5413,12 +5390,12 @@ class fn {
5413
5390
  n == null ? console.warn(`No handler for ${t.type}`) : n(t.payload);
5414
5391
  }
5415
5392
  route(t) {
5416
- const n = su(t, this.sender), r = new iu(n);
5393
+ const n = eu(t, this.sender), r = new nu(n);
5417
5394
  return this.handlers.set(t, r), r;
5418
5395
  }
5419
5396
  }
5420
- const su = (e, t) => (n, r) => t({ type: e, payload: n }, r);
5421
- class iu {
5397
+ const eu = (e, t) => (n, r) => t({ type: e, payload: n }, r);
5398
+ class nu {
5422
5399
  _send;
5423
5400
  handler;
5424
5401
  constructor(t) {
@@ -5431,101 +5408,101 @@ class iu {
5431
5408
  this.handler = t;
5432
5409
  }
5433
5410
  }
5434
- const ul = () => {
5411
+ const ol = () => {
5435
5412
  let e, t;
5436
5413
  const n = (s) => {
5437
5414
  t.handle({ data: s });
5438
5415
  }, r = (s) => {
5439
5416
  e.handle({ data: s });
5440
5417
  };
5441
- return e = new fn(n), t = new fn(r), [e, t];
5442
- }, ou = (e) => e.nullable().transform((t) => t === null ? void 0 : t).optional(), cu = c.int().min(0).max(jn), au = (e) => b.array(e).or(e.transform((t) => [t])), Wr = (e) => Ar(e, (t, n, r) => {
5418
+ return e = new hn(n), t = new hn(r), [e, t];
5419
+ }, ru = (e) => e.nullable().transform((t) => t === null ? void 0 : t).optional(), su = c.int().min(0).max(Cn), iu = (e) => k.array(e).or(e.transform((t) => [t])), ou = (e) => e._zod.def.output, Fr = (e) => Ar(e, (t, n, r) => {
5443
5420
  const s = n === r.length - 1, i = !isNaN(parseInt(t)), o = !isNaN(parseInt(r[n + 1]));
5444
5421
  return i && (t = "element"), s || o ? t : [t, "shape"];
5445
- }), hn = (e, t) => {
5422
+ }), dn = (e, t) => {
5446
5423
  if (e == null) return null;
5447
5424
  const n = e[t];
5448
5425
  return n == null && typeof e == "object" && "sourceType" in e ? e.sourceType()[t] : n;
5449
- }, uu = ((e, t, n) => t === "" ? e : Qe(
5450
- hn(e, "shape"),
5451
- Wr(t),
5452
- { ...n, getter: hn }
5453
- )), ll = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
5426
+ }, cu = ((e, t, n) => t === "" ? e : tn(
5427
+ dn(e, "shape"),
5428
+ Fr(t),
5429
+ { ...n, getter: dn }
5430
+ )), cl = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
5454
5431
  __proto__: null,
5455
- getFieldSchema: uu,
5456
- getFieldSchemaPath: Wr,
5457
- nullToUndefined: ou,
5458
- toArray: au,
5459
- uint12: cu
5432
+ functionOutput: ou,
5433
+ getFieldSchema: cu,
5434
+ getFieldSchemaPath: Fr,
5435
+ nullToUndefined: ru,
5436
+ toArray: iu,
5437
+ uint12: su
5460
5438
  }, Symbol.toStringTag, { value: "Module" }));
5461
5439
  export {
5462
5440
  f as DataType,
5463
- x as Density,
5464
- Cu as MultiSeries,
5465
- $ as Rate,
5466
- fn as RoutedWorker,
5441
+ O as Density,
5442
+ Uu as MultiSeries,
5443
+ T as Rate,
5444
+ hn as RoutedWorker,
5467
5445
  q as Series,
5468
5446
  p as Size,
5469
- E as TimeRange,
5447
+ A as TimeRange,
5470
5448
  g as TimeSpan,
5471
5449
  d as TimeStamp,
5472
- iu as TypedWorker,
5473
- Zt as URL,
5474
- fu as array,
5475
- gu as binary,
5476
- Ou as bounds,
5477
- Mu as box,
5478
- Ru as breaker,
5479
- al as buildQueryString,
5480
- hu as caseconv,
5481
- Pu as change,
5482
- No as clamp,
5483
- Lu as color,
5484
- pu as compare,
5485
- ku as control,
5486
- ko as convertDataType,
5487
- ul as createMockWorkers,
5488
- Zu as csv,
5489
- _u as debounce,
5490
- Fu as deep,
5491
- Vu as destructor,
5492
- Au as dimensions,
5493
- Iu as direction,
5494
- Wu as errors,
5495
- bu as id,
5496
- wu as instance,
5497
- Ko as isCrudeSeries,
5498
- cr as isTelemValue,
5499
- zu as jsonRPC,
5500
- Yu as kv,
5501
- Gu as label,
5502
- Hu as link,
5503
- Nu as location,
5504
- Du as map,
5505
- xu as math,
5506
- Ju as migrate,
5507
- du as narrow,
5508
- Xu as notation,
5509
- $u as numericTimeRangeZ,
5510
- Ku as observe,
5511
- Qu as optional,
5512
- yu as primitive,
5513
- tl as record,
5514
- el as runtime,
5515
- Eu as scale,
5516
- nl as scheduler,
5517
- rl as shallow,
5518
- Bu as sleep,
5519
- Su as spatial,
5520
- sl as status,
5521
- Tu as sticky,
5522
- il as strings,
5523
- ol as sync,
5524
- cl as testutil,
5525
- qu as throttle,
5526
- Uu as typedArrayZ,
5527
- mu as unique,
5528
- ju as uuid,
5529
- vu as xy,
5530
- ll as zod
5450
+ nu as TypedWorker,
5451
+ _t as URL,
5452
+ uu as array,
5453
+ hu as binary,
5454
+ bu as bounds,
5455
+ Nu as box,
5456
+ Cu as breaker,
5457
+ il as buildQueryString,
5458
+ lu as caseconv,
5459
+ Bu as change,
5460
+ xo as clamp,
5461
+ Pu as color,
5462
+ yu as compare,
5463
+ Ru as control,
5464
+ Ro as convertDataType,
5465
+ ol as createMockWorkers,
5466
+ ku as csv,
5467
+ Lu as debounce,
5468
+ _u as deep,
5469
+ qu as destructor,
5470
+ vu as dimensions,
5471
+ Ou as direction,
5472
+ Fu as errors,
5473
+ mu as id,
5474
+ pu as instance,
5475
+ Jo as isCrudeSeries,
5476
+ ar as isTelemValue,
5477
+ Vu as kv,
5478
+ Wu as label,
5479
+ zu as link,
5480
+ xu as location,
5481
+ Yu as map,
5482
+ wu as math,
5483
+ Gu as migrate,
5484
+ fu as narrow,
5485
+ Hu as notation,
5486
+ Su as numericTimeRangeZ,
5487
+ Du as observe,
5488
+ Ju as optional,
5489
+ du as primitive,
5490
+ Xu as record,
5491
+ Ku as runtime,
5492
+ Mu as scale,
5493
+ Qu as scheduler,
5494
+ tl as shallow,
5495
+ ju as sleep,
5496
+ Au as spatial,
5497
+ el as status,
5498
+ Eu as sticky,
5499
+ nl as strings,
5500
+ rl as sync,
5501
+ sl as testutil,
5502
+ Zu as throttle,
5503
+ Tu as typedArrayZ,
5504
+ gu as unique,
5505
+ $u as uuid,
5506
+ Iu as xy,
5507
+ cl as zod
5531
5508
  };