@dpuse/dpuse-shared 1.0.217 → 1.0.219

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -270,16 +270,16 @@ _Note: Sonda's Vite reports currently exclude CSS files, since Vite does not gen
270
270
 
271
271
  | Chunk/Module/File | Composition |
272
272
  | :-------------------------------------------------------------------------- | :--------------------------------------------------------------------------------------------- |
273
- | **dist/dpuse-shared.es.js** | 66.8 kB · gzip 15.9 kB · 100.0% of the build |
274
- |     src → index.ts + 16 more | `███████████████░░░░░` 73.9% · 49.4 kB |
275
- |         ↳ index.ts | `▒▒▒▒▒▒▒▒▒░░░░░░░░░░░` 46.6% · 31.1 kB |
276
- |         ↳ objectParsing.ts | `▒▒▒░░░░░░░░░░░░░░░░░` 14.7% · 9.8 kB |
273
+ | **dist/dpuse-shared.es.js** | 67.1 kB · gzip 16.0 kB · 100.0% of the build |
274
+ |     src → index.ts + 16 more | `███████████████░░░░░` 74.0% · 49.6 kB |
275
+ |         ↳ index.ts | `▒▒▒▒▒▒▒▒▒░░░░░░░░░░░` 46.4% · 31.1 kB |
276
+ |         ↳ objectParsing.ts | `▒▒▒░░░░░░░░░░░░░░░░░` 14.6% · 9.8 kB |
277
277
  |         ↳ tableSchema.ts | `▒░░░░░░░░░░░░░░░░░░░` 3.0% · 2.0 kB |
278
278
  |         ↳ delimitedText.ts | `░░░░░░░░░░░░░░░░░░░░` 2.4% · 1.6 kB |
279
279
  |         ↳ connectorConfig.schema.ts | `░░░░░░░░░░░░░░░░░░░░` 2.0% · 1.3 kB |
280
280
  |         ↳ componentConfig.schema.ts | `░░░░░░░░░░░░░░░░░░░░` 1.4% · 942 B |
281
- |         ↳ 11 smaller files | `▒░░░░░░░░░░░░░░░░░░░` 3.9% · 2.6 kB |
282
- |     valibot → dist/index.mjs | `███░░░░░░░░░░░░░░░░░` 13.5% · 9.0 kB |
281
+ |         ↳ 11 smaller files | `▒░░░░░░░░░░░░░░░░░░░` 4.2% · 2.8 kB |
282
+ |     valibot → dist/index.mjs | `███░░░░░░░░░░░░░░░░░` 13.4% · 9.0 kB |
283
283
  |     (bundler output, whitespace & JSON) | `███░░░░░░░░░░░░░░░░░` 12.6% · 8.4 kB |
284
284
 
285
285
  Bars show each row's share of its output file. ↳ rows are part of the row above.
@@ -2463,17 +2463,21 @@ function Ct(e) {
2463
2463
  return e == null ? null : e instanceof Date ? e.toISOString() : String(e);
2464
2464
  }
2465
2465
  // src/component/module/connector/webLock.ts
2466
- async function wt(e) {
2467
- let t = Promise.withResolvers(), n = navigator.locks.request(e, { ifAvailable: !0 }, (e) => {
2468
- if (e == null) t.resolve(void 0);
2469
- else return new Promise((e) => {
2470
- t.resolve(e);
2466
+ async function wt(e, t = {}) {
2467
+ let n = Promise.withResolvers(), r = { isGranted: !1 }, i = navigator.locks.request(e, t.takeOver === !0 ? { steal: !0 } : { ifAvailable: !0 }, (e) => {
2468
+ if (e == null) n.resolve(void 0);
2469
+ else return r.isGranted = !0, new Promise((e) => {
2470
+ n.resolve(e);
2471
2471
  });
2472
- }), r = (async () => {
2473
- await n;
2474
- })(), i = await Promise.race([t.promise, r]);
2475
- if (i != null) return async () => {
2476
- i(), await n;
2472
+ }), a = (async () => {
2473
+ try {
2474
+ await i;
2475
+ } catch (e) {
2476
+ r.isGranted ? e instanceof DOMException && e.name === "AbortError" && t.onLost?.() : n.reject(e instanceof Error ? e : Error(String(e)));
2477
+ }
2478
+ })(), o = await n.promise;
2479
+ if (o != null) return async () => {
2480
+ o(), await a;
2477
2481
  };
2478
2482
  }
2479
2483
  var Tt = /* @__PURE__ */ v({ fields: /* @__PURE__ */ h(/* @__PURE__ */ v({
@@ -2809,10 +2813,10 @@ var Qt = /* @__PURE__ */ new Map([
2809
2813
  ["millisecond", 1]
2810
2814
  ], $t = [
2811
2815
  ["byte", 1],
2812
- ["kilobyte", 1024],
2813
- ["megabyte", 1048576],
2814
- ["gigabyte", 1073741824],
2815
- ["terabyte", 1099511627776]
2816
+ ["KiB", 1024],
2817
+ ["MiB", 1048576],
2818
+ ["GiB", 1073741824],
2819
+ ["TiB", 1099511627776]
2816
2820
  ], en = /* @__PURE__ */ new Map(), tn = /* @__PURE__ */ new Map();
2817
2821
  function nn(e, t = 2, n = t, r = Z) {
2818
2822
  return e == null ? "" : $(r, {
@@ -2835,13 +2839,13 @@ function an(e, t = 1, n = Z) {
2835
2839
  }
2836
2840
  function on(e, t = 1, n = Z) {
2837
2841
  if (e == null || !Number.isFinite(e)) return "";
2838
- let [r, i] = $t.find(([, n]) => hn(Math.abs(e) / n, n === 1 ? 0 : t) < 1024) ?? ["terabyte", 1099511627776];
2839
- return $(n, {
2840
- maximumFractionDigits: i === 1 ? 0 : t,
2842
+ let [r, i] = $t.find(([, n]) => hn(Math.abs(e) / n, n === 1 ? 0 : t) < 1024) ?? ["TiB", 1099511627776];
2843
+ return i === 1 ? $(n, {
2844
+ maximumFractionDigits: 0,
2841
2845
  style: "unit",
2842
- unit: r,
2843
- unitDisplay: i === 1 ? "long" : "short"
2844
- }).format(e / i);
2846
+ unit: "byte",
2847
+ unitDisplay: "long"
2848
+ }).format(e) : `${$(n, { maximumFractionDigits: t }).format(e / i)} ${r}`;
2845
2849
  }
2846
2850
  function sn(e, t = "millisecond", n = Z) {
2847
2851
  if (e == null || !Number.isFinite(e)) return "";