@opendaw/lib-dom 0.0.19 → 0.0.20

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/dist/errors.d.ts CHANGED
@@ -1,5 +1,6 @@
1
1
  export declare namespace Errors {
2
2
  const AbortError: number | Readonly<DOMException>;
3
3
  const isAbort: (error: unknown) => boolean;
4
+ const CatchAbort: (error: unknown) => undefined;
4
5
  }
5
6
  //# sourceMappingURL=errors.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"errors.d.ts","sourceRoot":"","sources":["../src/errors.ts"],"names":[],"mappings":"AAAA,yBAAiB,MAAM,CAAC;IACb,MAAM,UAAU,iCACkC,CAAA;IAElD,MAAM,OAAO,GAAI,OAAO,OAAO,YACoD,CAAA;CAC7F"}
1
+ {"version":3,"file":"errors.d.ts","sourceRoot":"","sources":["../src/errors.ts"],"names":[],"mappings":"AAEA,yBAAiB,MAAM,CAAC;IACb,MAAM,UAAU,iCACkC,CAAA;IAElD,MAAM,OAAO,GAAI,OAAO,OAAO,YACoD,CAAA;IAEnF,MAAM,UAAU,GAAI,OAAO,OAAO,cAAoD,CAAA;CAChG"}
package/dist/errors.js CHANGED
@@ -1,6 +1,8 @@
1
+ import { panic } from "@opendaw/lib-std";
1
2
  export var Errors;
2
3
  (function (Errors) {
3
4
  Errors.AbortError = typeof DOMException === "undefined"
4
5
  ? NaN : Object.freeze(new DOMException("AbortError"));
5
6
  Errors.isAbort = (error) => error === Errors.AbortError || (error instanceof DOMException && error.name === "AbortError");
7
+ Errors.CatchAbort = (error) => error === Errors.AbortError ? undefined : panic(error);
6
8
  })(Errors || (Errors = {}));
package/dist/events.d.ts CHANGED
@@ -1,6 +1,7 @@
1
1
  import { Nullable, Procedure, Subscription } from "@opendaw/lib-std";
2
+ type KnownEventMap = WindowEventMap & MIDIInputEventMap & MIDIPortEventMap;
2
3
  export declare class Events {
3
- static subscribe<K extends keyof WindowEventMap>(eventTarget: EventTarget, type: K, listener: (ev: WindowEventMap[K]) => void, options?: boolean | AddEventListenerOptions): Subscription;
4
+ static subscribe<K extends keyof KnownEventMap>(eventTarget: EventTarget, type: K, listener: (ev: KnownEventMap[K]) => void, options?: boolean | AddEventListenerOptions): Subscription;
4
5
  static subscribeAny<E extends Event>(eventTarget: EventTarget, type: string, listener: (event: E) => void, options?: boolean | AddEventListenerOptions): Subscription;
5
6
  static DOUBLE_DOWN_THRESHOLD: 200;
6
7
  static subscribeDblDwn: (eventTarget: EventTarget, listener: (event: PointerEvent) => void) => Subscription;
@@ -12,4 +13,5 @@ export interface PointerCaptureTarget extends EventTarget {
12
13
  releasePointerCapture(pointerId: number): void;
13
14
  hasPointerCapture(pointerId: number): boolean;
14
15
  }
16
+ export {};
15
17
  //# sourceMappingURL=events.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"events.d.ts","sourceRoot":"","sources":["../src/events.ts"],"names":[],"mappings":"AAAA,OAAO,EAAY,QAAQ,EAAE,SAAS,EAAE,YAAY,EAAC,MAAM,kBAAkB,CAAA;AAE7E,qBAAa,MAAM;IACf,MAAM,CAAC,SAAS,CAAC,CAAC,SAAS,MAAM,cAAc,EAAE,WAAW,EAAE,WAAW,EACxB,IAAI,EAAE,CAAC,EACP,QAAQ,EAAE,CAAC,EAAE,EAAE,cAAc,CAAC,CAAC,CAAC,KAAK,IAAI,EACzC,OAAO,CAAC,EAAE,OAAO,GAAG,uBAAuB,GAAG,YAAY;IAK3G,MAAM,CAAC,YAAY,CAAC,CAAC,SAAS,KAAK,EAAE,WAAW,EAAE,WAAW,EACxB,IAAI,EAAE,MAAM,EACZ,QAAQ,EAAE,CAAC,KAAK,EAAE,CAAC,KAAK,IAAI,EAC5B,OAAO,CAAC,EAAE,OAAO,GAAG,uBAAuB,GAAG,YAAY;IAK/F,MAAM,CAAC,qBAAqB,EAAG,GAAG,CAAS;IAE3C,MAAM,CAAC,eAAe,GAAI,aAAa,WAAW,EAAE,UAAU,CAAC,KAAK,EAAE,YAA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KAAG,YAAY,CASzG;IAED,MAAM,CAAC,QAAQ,CAAC,cAAc,EAAE,SAAS,CAAC,KAAK,CAAC,CAAkC;IAElF,MAAM,CAAC,QAAQ,CAAC,WAAW,GAAI,QAAQ,QAAQ,CAAC,WAAW,CAAC,KAAG,OAAO,CAEqB;CAC9F;AAED,MAAM,WAAW,oBAAqB,SAAQ,WAAW;IACrD,iBAAiB,CAAC,SAAS,EAAE,MAAM,GAAG,IAAI,CAAA;IAC1C,qBAAqB,CAAC,SAAS,EAAE,MAAM,GAAG,IAAI,CAAA;IAC9C,iBAAiB,CAAC,SAAS,EAAE,MAAM,GAAG,OAAO,CAAA;CAChD"}
@@ -1 +1 @@
1
- {"version":3,"file":"terminable.d.ts","sourceRoot":"","sources":["../src/terminable.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,IAAI,EAAE,UAAU,EAAC,MAAM,kBAAkB,CAAA;AAEjD,yBAAiB,eAAe,CAAC;IAE7B;;;;;;;OAOG;IACI,MAAM,SAAS,GAAI,CAAC,SAAS,OAAO,EAAE,KAAK,CAAC,EAAE,WAAW,IAAI,CAAC,OAAO,CAAC,CAAC,CAAC,EAAE,UAAU,CAAC,KAAG,CAQ9F,CAAA;CAmBJ"}
1
+ {"version":3,"file":"terminable.d.ts","sourceRoot":"","sources":["../src/terminable.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,IAAI,EAAE,UAAU,EAAC,MAAM,kBAAkB,CAAA;AAEjD,yBAAiB,eAAe,CAAC;IAE7B;;;;;;;OAOG;IACI,MAAM,SAAS,GAAI,CAAC,SAAS,OAAO,EAAE,KAAK,CAAC,EAAE,WAAW,IAAI,CAAC,OAAO,CAAC,CAAC,CAAC,EAAE,UAAU,CAAC,KAAG,CAQ9F,CAAA;CAkBJ"}
@@ -28,7 +28,6 @@ export var TerminatorUtils;
28
28
  entry[1].terminate();
29
29
  weakRefs.splice(index, 1);
30
30
  if (weakRefs.length === 0) {
31
- console.debug("stop weak watching");
32
31
  clearInterval(id);
33
32
  }
34
33
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@opendaw/lib-dom",
3
- "version": "0.0.19",
3
+ "version": "0.0.20",
4
4
  "main": "./dist/index.js",
5
5
  "types": "./dist/index.d.ts",
6
6
  "license": "LGPL-3.0-or-later",
@@ -22,13 +22,13 @@
22
22
  "test": "vitest run"
23
23
  },
24
24
  "dependencies": {
25
- "@opendaw/lib-runtime": "^0.0.19",
26
- "@opendaw/lib-std": "^0.0.19",
25
+ "@opendaw/lib-runtime": "^0.0.20",
26
+ "@opendaw/lib-std": "^0.0.20",
27
27
  "@types/wicg-file-system-access": "^2023.10.6"
28
28
  },
29
29
  "devDependencies": {
30
30
  "@opendaw/eslint-config": "^0.0.18",
31
31
  "@opendaw/typescript-config": "^0.0.19"
32
32
  },
33
- "gitHead": "8d9e873aad633820cd26f76dc447674728401495"
33
+ "gitHead": "de891be4fc9e418776b3a6c433748e287abab912"
34
34
  }