@m3e/core 1.1.1 → 1.1.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 (31) hide show
  1. package/dist/custom-elements.json +4075 -3618
  2. package/dist/html-custom-data.json +6 -1
  3. package/dist/index.js +275 -29
  4. package/dist/index.js.map +1 -1
  5. package/dist/index.min.js +9 -9
  6. package/dist/index.min.js.map +1 -1
  7. package/dist/src/shared/controllers/AnimationLoopController.d.ts +13 -0
  8. package/dist/src/shared/controllers/AnimationLoopController.d.ts.map +1 -0
  9. package/dist/src/shared/controllers/FocusController.d.ts.map +1 -1
  10. package/dist/src/shared/controllers/index.d.ts +1 -0
  11. package/dist/src/shared/controllers/index.d.ts.map +1 -1
  12. package/dist/src/shared/mixins/HtmlFor.d.ts.map +1 -1
  13. package/dist/src/shared/mixins/KeyboardClick.d.ts.map +1 -1
  14. package/dist/src/shared/primitives/ActionElementBase.d.ts +22 -0
  15. package/dist/src/shared/primitives/ActionElementBase.d.ts.map +1 -0
  16. package/dist/src/shared/primitives/CollapsibleElement.d.ts.map +1 -1
  17. package/dist/src/shared/primitives/StateLayerElement.d.ts +9 -2
  18. package/dist/src/shared/primitives/StateLayerElement.d.ts.map +1 -1
  19. package/dist/src/shared/primitives/index.d.ts +1 -0
  20. package/dist/src/shared/primitives/index.d.ts.map +1 -1
  21. package/dist/src/shared/utils/focusWhenReady.d.ts +8 -0
  22. package/dist/src/shared/utils/focusWhenReady.d.ts.map +1 -0
  23. package/dist/src/shared/utils/index.d.ts +4 -0
  24. package/dist/src/shared/utils/index.d.ts.map +1 -1
  25. package/dist/src/shared/utils/interceptProperty.d.ts +17 -0
  26. package/dist/src/shared/utils/interceptProperty.d.ts.map +1 -0
  27. package/dist/src/shared/utils/resolveElementById.d.ts +8 -0
  28. package/dist/src/shared/utils/resolveElementById.d.ts.map +1 -0
  29. package/dist/src/shared/utils/resolveFragmentUrl.d.ts +22 -0
  30. package/dist/src/shared/utils/resolveFragmentUrl.d.ts.map +1 -0
  31. package/package.json +1 -1
@@ -0,0 +1,13 @@
1
+ import { ReactiveController, ReactiveControllerHost } from "lit";
2
+ /** A `ReactiveController` used to execute a function in an animation loop. */
3
+ export declare class AnimationLoopController implements ReactiveController {
4
+ #private;
5
+ constructor(host: ReactiveControllerHost, callback: (deltaTime: number, elapsedTime: number) => void);
6
+ /** @inheritdoc */
7
+ hostDisconnected(): void;
8
+ /** Starts the animation loop. */
9
+ start(): void;
10
+ /** Stops the animation loop. */
11
+ stop(): void;
12
+ }
13
+ //# sourceMappingURL=AnimationLoopController.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"AnimationLoopController.d.ts","sourceRoot":"","sources":["../../../../src/shared/controllers/AnimationLoopController.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,kBAAkB,EAAE,sBAAsB,EAAE,MAAM,KAAK,CAAC;AAEjE,8EAA8E;AAC9E,qBAAa,uBAAwB,YAAW,kBAAkB;;gBAepD,IAAI,EAAE,sBAAsB,EAAE,QAAQ,EAAE,CAAC,SAAS,EAAE,MAAM,EAAE,WAAW,EAAE,MAAM,KAAK,IAAI;IAKpG,kBAAkB;IAClB,gBAAgB;IAIhB,iCAAiC;IACjC,KAAK;IAQL,gCAAgC;IAChC,IAAI;CASL"}
@@ -1 +1 @@
1
- {"version":3,"file":"FocusController.d.ts","sourceRoot":"","sources":["../../../../src/shared/controllers/FocusController.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,sBAAsB,EAAE,MAAM,KAAK,CAAC;AAE7C,OAAO,EAAE,qBAAqB,EAAE,wBAAwB,EAAE,MAAM,yBAAyB,CAAC;AAG1F,kFAAkF;AAClF,MAAM,MAAM,uBAAuB,GAAG,CAAC,OAAO,EAAE,OAAO,EAAE,YAAY,EAAE,OAAO,EAAE,MAAM,EAAE,WAAW,KAAK,IAAI,CAAC;AAE7G,kEAAkE;AAClE,MAAM,WAAW,sBAAuB,SAAQ,wBAAwB;IACtE,yEAAyE;IACzE,QAAQ,EAAE,uBAAuB,CAAC;CACnC;AAED,wFAAwF;AACxF,qBAAa,eAAgB,SAAQ,qBAAqB;;IAKxD;;;;OAIG;gBACS,IAAI,EAAE,sBAAsB,GAAG,WAAW,EAAE,OAAO,EAAE,sBAAsB;IAKvF;;;OAGG;cACgB,QAAQ,CAAC,MAAM,EAAE,WAAW,GAAG,IAAI;IAMtD;;;OAGG;cACgB,UAAU,CAAC,MAAM,EAAE,WAAW,GAAG,IAAI;CAgBzD"}
1
+ {"version":3,"file":"FocusController.d.ts","sourceRoot":"","sources":["../../../../src/shared/controllers/FocusController.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,sBAAsB,EAAE,MAAM,KAAK,CAAC;AAE7C,OAAO,EAAE,qBAAqB,EAAE,wBAAwB,EAAE,MAAM,yBAAyB,CAAC;AAG1F,kFAAkF;AAClF,MAAM,MAAM,uBAAuB,GAAG,CAAC,OAAO,EAAE,OAAO,EAAE,YAAY,EAAE,OAAO,EAAE,MAAM,EAAE,WAAW,KAAK,IAAI,CAAC;AAE7G,kEAAkE;AAClE,MAAM,WAAW,sBAAuB,SAAQ,wBAAwB;IACtE,yEAAyE;IACzE,QAAQ,EAAE,uBAAuB,CAAC;CACnC;AAED,wFAAwF;AACxF,qBAAa,eAAgB,SAAQ,qBAAqB;;IASxD;;;;OAIG;gBACS,IAAI,EAAE,sBAAsB,GAAG,WAAW,EAAE,OAAO,EAAE,sBAAsB;IAKvF;;;OAGG;cACgB,QAAQ,CAAC,MAAM,EAAE,WAAW,GAAG,IAAI;IAStD;;;OAGG;cACgB,UAAU,CAAC,MAAM,EAAE,WAAW,GAAG,IAAI;CA6BzD"}
@@ -1,3 +1,4 @@
1
+ export * from "./AnimationLoopController";
1
2
  export * from "./FocusController";
2
3
  export * from "./HoverController";
3
4
  export * from "./IntersectionController";
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/shared/controllers/index.ts"],"names":[],"mappings":"AAAA,cAAc,mBAAmB,CAAC;AAClC,cAAc,mBAAmB,CAAC;AAClC,cAAc,0BAA0B,CAAC;AACzC,cAAc,uBAAuB,CAAC;AACtC,cAAc,sBAAsB,CAAC;AACrC,cAAc,qBAAqB,CAAC;AACpC,cAAc,oBAAoB,CAAC;AACnC,cAAc,oBAAoB,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/shared/controllers/index.ts"],"names":[],"mappings":"AAAA,cAAc,2BAA2B,CAAC;AAC1C,cAAc,mBAAmB,CAAC;AAClC,cAAc,mBAAmB,CAAC;AAClC,cAAc,0BAA0B,CAAC;AACzC,cAAc,uBAAuB,CAAC;AACtC,cAAc,sBAAsB,CAAC;AACrC,cAAc,qBAAqB,CAAC;AACpC,cAAc,oBAAoB,CAAC;AACnC,cAAc,oBAAoB,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"HtmlFor.d.ts","sourceRoot":"","sources":["../../../../src/shared/mixins/HtmlFor.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAkB,MAAM,KAAK,CAAC;AAGjD,OAAO,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AAG5C,4FAA4F;AAC5F,MAAM,WAAW,YAAY;IAC3B,mFAAmF;IACnF,OAAO,EAAE,MAAM,GAAG,IAAI,CAAC;IAEvB,iEAAiE;IACjE,QAAQ,CAAC,OAAO,EAAE,WAAW,GAAG,IAAI,CAAC;IAErC;;;OAGG;IACH,MAAM,CAAC,OAAO,EAAE,WAAW,GAAG,IAAI,CAAC;IAEnC,iEAAiE;IACjE,MAAM,IAAI,IAAI,CAAC;CAChB;AAED;;;;GAIG;AACH,wBAAgB,cAAc,CAAC,KAAK,EAAE,OAAO,GAAG,KAAK,IAAI,YAAY,CAEpE;AAKD;;;;;GAKG;AACH,wBAAgB,OAAO,CAAC,CAAC,SAAS,WAAW,CAAC,UAAU,CAAC,EAAE,IAAI,EAAE,CAAC,GAAG,WAAW,CAAC,YAAY,CAAC,GAAG,CAAC,CAuDjG"}
1
+ {"version":3,"file":"HtmlFor.d.ts","sourceRoot":"","sources":["../../../../src/shared/mixins/HtmlFor.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAkB,MAAM,KAAK,CAAC;AAGjD,OAAO,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AAI5C,4FAA4F;AAC5F,MAAM,WAAW,YAAY;IAC3B,mFAAmF;IACnF,OAAO,EAAE,MAAM,GAAG,IAAI,CAAC;IAEvB,iEAAiE;IACjE,QAAQ,CAAC,OAAO,EAAE,WAAW,GAAG,IAAI,CAAC;IAErC;;;OAGG;IACH,MAAM,CAAC,OAAO,EAAE,WAAW,GAAG,IAAI,CAAC;IAEnC,iEAAiE;IACjE,MAAM,IAAI,IAAI,CAAC;CAChB;AAED;;;;GAIG;AACH,wBAAgB,cAAc,CAAC,KAAK,EAAE,OAAO,GAAG,KAAK,IAAI,YAAY,CAEpE;AAKD;;;;;GAKG;AACH,wBAAgB,OAAO,CAAC,CAAC,SAAS,WAAW,CAAC,UAAU,CAAC,EAAE,IAAI,EAAE,CAAC,GAAG,WAAW,CAAC,YAAY,CAAC,GAAG,CAAC,CA2DjG"}
@@ -1 +1 @@
1
- {"version":3,"file":"KeyboardClick.d.ts","sourceRoot":"","sources":["../../../../src/shared/mixins/KeyboardClick.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,KAAK,CAAC;AAEjC,OAAO,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AAI5C;;;;;;GAMG;AACH,wBAAgB,aAAa,CAAC,CAAC,SAAS,WAAW,CAAC,UAAU,CAAC,EAAE,IAAI,EAAE,CAAC,EAAE,UAAU,GAAE,OAAc,GAAG,CAAC,CA0CvG"}
1
+ {"version":3,"file":"KeyboardClick.d.ts","sourceRoot":"","sources":["../../../../src/shared/mixins/KeyboardClick.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,KAAK,CAAC;AAEjC,OAAO,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AAI5C;;;;;;GAMG;AACH,wBAAgB,aAAa,CAAC,CAAC,SAAS,WAAW,CAAC,UAAU,CAAC,EAAE,IAAI,EAAE,CAAC,EAAE,UAAU,GAAE,OAAc,GAAG,CAAC,CAgEvG"}
@@ -0,0 +1,22 @@
1
+ import { CSSResultGroup, LitElement } from "lit";
2
+ /**
3
+ * A base implementation for an element, nested within a clickable element, used to
4
+ * perform an action. This class must be inherited.
5
+ */
6
+ export declare abstract class ActionElementBase extends LitElement {
7
+ #private;
8
+ /** The styles of the element. */
9
+ static styles: CSSResultGroup;
10
+ /** @inheritdoc */
11
+ connectedCallback(): void;
12
+ /** @inheritdoc */
13
+ disconnectedCallback(): void;
14
+ /** @inheritdoc */
15
+ protected render(): unknown;
16
+ /**
17
+ * When implemented by a derived class, handles the specified click event.
18
+ * @param {Event} e The click event to handle.
19
+ */
20
+ protected abstract _onClick(e: Event): void;
21
+ }
22
+ //# sourceMappingURL=ActionElementBase.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ActionElementBase.d.ts","sourceRoot":"","sources":["../../../../src/shared/primitives/ActionElementBase.ts"],"names":[],"mappings":"AAAA,OAAO,EAAO,cAAc,EAAQ,UAAU,EAAE,MAAM,KAAK,CAAC;AAE5D;;;GAGG;AACH,8BAAsB,iBAAkB,SAAQ,UAAU;;IACxD,iCAAiC;IACjC,OAAgB,MAAM,EAAE,cAAc,CAOpC;IAQF,kBAAkB;IACT,iBAAiB,IAAI,IAAI;IAKlC,kBAAkB;IACT,oBAAoB,IAAI,IAAI;IAKrC,kBAAkB;cACC,MAAM,IAAI,OAAO;IAIpC;;;OAGG;IACH,SAAS,CAAC,QAAQ,CAAC,QAAQ,CAAC,CAAC,EAAE,KAAK,GAAG,IAAI;CAC5C"}
@@ -1 +1 @@
1
- {"version":3,"file":"CollapsibleElement.d.ts","sourceRoot":"","sources":["../../../../src/shared/primitives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QAAQ,EAAE,CAAC,IAAI,EAAE,qBAAqB,EAAE,EAAE,EAAE,6BAA6B,CAAC,CAAC,CAAC,KAAK,IAAI,EACrF,OAAO,CAAC,EAAE,OAAO,GAAG,oBAAoB,GACvC,IAAI,CAAC;IAER,mBAAmB,CACjB,IAAI,EAAE,MAAM,EACZ,QAAQ,EAAE,kCAAkC,EAC5C,OAAO,CAAC,EAAE,OAAO,GAAG,oBAAoB,GACvC,IAAI,CAAC;CACT;AAED,OAAO,CAAC,MAAM,CAAC;IACb,UAAU,qBAAqB;QAC7B,iBAAiB,EAAE,qBAAqB,CAAC;KAC1C;CACF"}
@@ -24,7 +24,8 @@ declare const M3eStateLayerElement_base: import("../mixins/Constructor").Constru
24
24
  *
25
25
  * @tag m3e-state-layer
26
26
  *
27
- * @attr disabled - Whether hover and focus event will not trigger the state layer.Whether hover and focus event will not trigger the state layer. State layers can still be controlled manually using the `show` and `hide` methods.
27
+ * @attr disabled - Whether hover and focus events will not trigger the state layer. State layers can still be controlled manually using the `show` and `hide` methods.
28
+ * @attr disable-hover - Whether hover events will not trigger the state layer. State layers can still be controlled manually using the `show` and `hide` methods.
28
29
  *
29
30
  * @cssprop --m3e-state-layer-duration - Duration of state layer changes.
30
31
  * @cssprop --m3e-state-layer-easing - Easing curve of state layer changes.
@@ -39,11 +40,17 @@ export declare class M3eStateLayerElement extends M3eStateLayerElement_base {
39
40
  static styles: CSSResultGroup;
40
41
  /** @private */ private readonly _layer?;
41
42
  /**
42
- * Whether hover and focus event will not trigger the state layer. State layers can still
43
+ * Whether hover and focus events will not trigger the state layer. State layers can still
43
44
  * be controlled manually using the `show` and `hide` methods.
44
45
  * @default false
45
46
  */
46
47
  disabled: boolean;
48
+ /**
49
+ * Whether hover events will not trigger the state layer. State layers can still
50
+ * be controlled manually using the `show` and `hide` methods.
51
+ * @default false
52
+ */
53
+ disableHover: boolean;
47
54
  /**
48
55
  * Launches a manual state layer.
49
56
  * @param {"hover" | "focused"} state The state of the layer to show.
@@ -1 +1 @@
1
- {"version":3,"file":"StateLayerElement.d.ts","sourceRoot":"","sources":["../../../../src/shared/primitives/StateLayerElement.ts"],"names":[],"mappings":"AAAA,OAAO,EAAO,cAAc,EAAQ,UAAU,EAAE,cAAc,EAAa,MAAM,KAAK,CAAC;;AAQvF;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAgCG;AACH,qBACa,oBAAqB,SAAQ,yBAAiC;;IACzE,iCAAiC;IACjC,OAAgB,MAAM,EAAE,cAAc,CAkCpC;IAcF,eAAe,CAAkB,OAAO,CAAC,QAAQ,CAAC,MAAM,CAAC,CAAc;IAEvE;;;;OAIG;IACyC,QAAQ,UAAS;IAE7D;;;OAGG;IACH,IAAI,CAAC,KAAK,EAAE,OAAO,GAAG,SAAS,GAAG,IAAI;IAItC;;;OAGG;IACH,IAAI,CAAC,KAAK,EAAE,OAAO,GAAG,SAAS,GAAG,IAAI;IAItC,kBAAkB;IACT,MAAM,CAAC,OAAO,EAAE,WAAW,GAAG,IAAI;IAM3C,kBAAkB;IACT,MAAM,IAAI,IAAI;IAQvB,kBAAkB;IACT,iBAAiB,IAAI,IAAI;IAKlC,kBAAkB;IACT,oBAAoB,IAAI,IAAI;IAOrC,kBAAkB;cACC,OAAO,CAAC,kBAAkB,EAAE,cAAc,CAAC,IAAI,CAAC,GAAG,IAAI;IAS1E,kBAAkB;cACC,MAAM,IAAI,OAAO;CAyBrC;AAED,OAAO,CAAC,MAAM,CAAC;IACb,UAAU,qBAAqB;QAC7B,iBAAiB,EAAE,oBAAoB,CAAC;KACzC;CACF"}
1
+ {"version":3,"file":"StateLayerElement.d.ts","sourceRoot":"","sources":["../../../../src/shared/primitives/StateLayerElement.ts"],"names":[],"mappings":"AAAA,OAAO,EAAO,cAAc,EAAQ,UAAU,EAAE,cAAc,EAAa,MAAM,KAAK,CAAC;;AAQvF;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAiCG;AACH,qBACa,oBAAqB,SAAQ,yBAAiC;;IACzE,iCAAiC;IACjC,OAAgB,MAAM,EAAE,cAAc,CAkCpC;IAcF,eAAe,CAAkB,OAAO,CAAC,QAAQ,CAAC,MAAM,CAAC,CAAc;IAEvE;;;;OAIG;IACyC,QAAQ,UAAS;IAE7D;;;;OAIG;IACqE,YAAY,UAAS;IAE7F;;;OAGG;IACH,IAAI,CAAC,KAAK,EAAE,OAAO,GAAG,SAAS,GAAG,IAAI;IAItC;;;OAGG;IACH,IAAI,CAAC,KAAK,EAAE,OAAO,GAAG,SAAS,GAAG,IAAI;IAItC,kBAAkB;IACT,MAAM,CAAC,OAAO,EAAE,WAAW,GAAG,IAAI;IAM3C,kBAAkB;IACT,MAAM,IAAI,IAAI;IAQvB,kBAAkB;IACT,iBAAiB,IAAI,IAAI;IAKlC,kBAAkB;IACT,oBAAoB,IAAI,IAAI;IAOrC,kBAAkB;cACC,OAAO,CAAC,kBAAkB,EAAE,cAAc,CAAC,IAAI,CAAC,GAAG,IAAI;IAY1E,kBAAkB;cACC,MAAM,IAAI,OAAO;CAyBrC;AAED,OAAO,CAAC,MAAM,CAAC;IACb,UAAU,qBAAqB;QAC7B,iBAAiB,EAAE,oBAAoB,CAAC;KACzC;CACF"}
@@ -1,3 +1,4 @@
1
+ export * from "./ActionElementBase";
1
2
  export * from "./CollapsibleElement";
2
3
  export * from "./ElevationElement";
3
4
  export * from "./ElevationLevel";
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/shared/primitives/index.ts"],"names":[],"mappings":"AAAA,cAAc,sBAAsB,CAAC;AACrC,cAAc,oBAAoB,CAAC;AACnC,cAAc,kBAAkB,CAAC;AACjC,cAAc,oBAAoB,CAAC;AACnC,cAAc,yBAAyB,CAAC;AACxC,cAAc,sBAAsB,CAAC;AACrC,cAAc,iBAAiB,CAAC;AAChC,cAAc,0BAA0B,CAAC;AACzC,cAAc,kBAAkB,CAAC;AACjC,cAAc,gBAAgB,CAAC;AAC/B,cAAc,qBAAqB,CAAC;AACpC,cAAc,uBAAuB,CAAC;AACtC,cAAc,wBAAwB,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/shared/primitives/index.ts"],"names":[],"mappings":"AAAA,cAAc,qBAAqB,CAAC;AACpC,cAAc,sBAAsB,CAAC;AACrC,cAAc,oBAAoB,CAAC;AACnC,cAAc,kBAAkB,CAAC;AACjC,cAAc,oBAAoB,CAAC;AACnC,cAAc,yBAAyB,CAAC;AACxC,cAAc,sBAAsB,CAAC;AACrC,cAAc,iBAAiB,CAAC;AAChC,cAAc,0BAA0B,CAAC;AACzC,cAAc,kBAAkB,CAAC;AACjC,cAAc,gBAAgB,CAAC;AAC/B,cAAc,qBAAqB,CAAC;AACpC,cAAc,uBAAuB,CAAC;AACtC,cAAc,wBAAwB,CAAC"}
@@ -0,0 +1,8 @@
1
+ /**
2
+ * Asynchronously attempts to focus an element once it becomes focusable.
3
+ * @param {HTMLElement} element The element to to focus.
4
+ * @param {number} [timeout=200] The maximum amount of time to attempt to focus `el`.
5
+ * @returns {Promise<boolean>} A `Promise` that resolves to whether `el` was focused.
6
+ */
7
+ export declare function focusWhenReady(element: HTMLElement, timeout?: number): Promise<boolean>;
8
+ //# sourceMappingURL=focusWhenReady.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"focusWhenReady.d.ts","sourceRoot":"","sources":["../../../../src/shared/utils/focusWhenReady.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AACH,wBAAsB,cAAc,CAAC,OAAO,EAAE,WAAW,EAAE,OAAO,GAAE,MAAY,GAAG,OAAO,CAAC,OAAO,CAAC,CAclG"}
@@ -1,8 +1,12 @@
1
+ export * from "./focusWhenReady";
1
2
  export * from "./forcedColorsActive";
2
3
  export * from "./generateClipPaths";
3
4
  export * from "./getTextContent";
4
5
  export * from "./guid";
5
6
  export * from "./hasAssignedNodes";
7
+ export * from "./interceptProperty";
6
8
  export * from "./prefersReducedMotion";
9
+ export * from "./resolveElementById";
10
+ export * from "./resolveFragmentUrl";
7
11
  export * from "./scrollIntoViewIfNeeded";
8
12
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/shared/utils/index.ts"],"names":[],"mappings":"AAAA,cAAc,sBAAsB,CAAC;AACrC,cAAc,qBAAqB,CAAC;AACpC,cAAc,kBAAkB,CAAC;AACjC,cAAc,QAAQ,CAAC;AACvB,cAAc,oBAAoB,CAAC;AACnC,cAAc,wBAAwB,CAAC;AACvC,cAAc,0BAA0B,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/shared/utils/index.ts"],"names":[],"mappings":"AAAA,cAAc,kBAAkB,CAAC;AACjC,cAAc,sBAAsB,CAAC;AACrC,cAAc,qBAAqB,CAAC;AACpC,cAAc,kBAAkB,CAAC;AACjC,cAAc,QAAQ,CAAC;AACvB,cAAc,oBAAoB,CAAC;AACnC,cAAc,qBAAqB,CAAC;AACpC,cAAc,wBAAwB,CAAC;AACvC,cAAc,sBAAsB,CAAC;AACrC,cAAc,sBAAsB,CAAC;AACrC,cAAc,0BAA0B,CAAC"}
@@ -0,0 +1,17 @@
1
+ /**
2
+ * Intercepts property access and mutations on a target object, allowing custom logic
3
+ * to run when the property is read or written to.
4
+ *
5
+ * @template T - The type of the target object.
6
+ * @template K - The key of the property being intercepted (must be a valid key of T).
7
+ * @param target - The object whose property should be intercepted.
8
+ * @param prop - The property key to intercept.
9
+ * @param options - Configuration object for interceptor callbacks.
10
+ * @returns A cleanup function that removes the interceptors and restores the original property descriptor.
11
+ * @throws {Error} If the property does not exist on the target object or its prototype chain.
12
+ */
13
+ export declare function interceptProperty<T extends object, K extends keyof T>(target: T, prop: K, options: {
14
+ get?: (getter: () => T[K]) => T[K];
15
+ set?: (value: T[K], setter: (v: T[K]) => void) => void;
16
+ }): () => void;
17
+ //# sourceMappingURL=interceptProperty.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"interceptProperty.d.ts","sourceRoot":"","sources":["../../../../src/shared/utils/interceptProperty.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;GAWG;AACH,wBAAgB,iBAAiB,CAAC,CAAC,SAAS,MAAM,EAAE,CAAC,SAAS,MAAM,CAAC,EACnE,MAAM,EAAE,CAAC,EACT,IAAI,EAAE,CAAC,EACP,OAAO,EAAE;IACP,GAAG,CAAC,EAAE,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,CAAC;IACnC,GAAG,CAAC,EAAE,CAAC,KAAK,EAAE,CAAC,CAAC,CAAC,CAAC,EAAE,MAAM,EAAE,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,KAAK,IAAI,KAAK,IAAI,CAAC;CACxD,GACA,MAAM,IAAI,CA4BZ"}
@@ -0,0 +1,8 @@
1
+ /**
2
+ * Resolves an element by ID, waiting for document readiness if needed.
3
+ * @param {string} id - The element ID to resolve.
4
+ * @param {ParentNode} root - Optional root node to query from (defaults to document).
5
+ * @returns {Promise<T | null>} A promise that resolves with the element or `null` if not found.
6
+ */
7
+ export declare function resolveElementById<T extends Element>(id: string, root?: ParentNode): Promise<T | null>;
8
+ //# sourceMappingURL=resolveElementById.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"resolveElementById.d.ts","sourceRoot":"","sources":["../../../../src/shared/utils/resolveElementById.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AACH,wBAAgB,kBAAkB,CAAC,CAAC,SAAS,OAAO,EAAE,EAAE,EAAE,MAAM,EAAE,IAAI,GAAE,UAAqB,GAAG,OAAO,CAAC,CAAC,GAAG,IAAI,CAAC,CAehH"}
@@ -0,0 +1,22 @@
1
+ /**
2
+ * Resolves a URL fragment reference (`url(path#id)`) based on the current document location.
3
+ *
4
+ * This helper is typically used when constructing fragment-based URLs for SVG
5
+ * references (e.g., masks, clipPaths, filters) where the browser requires a fully
6
+ * qualified `url(...)` value that includes the current path.
7
+ *
8
+ * How it works:
9
+ * - Safely reads `document.location` (guarded for SSR environments).
10
+ * - Extracts the current page's path + query string.
11
+ * - Removes any existing hash fragment from the URL.
12
+ * - Appends `#${id}` to produce a stable fragment reference.
13
+ *
14
+ * Example:
15
+ * // If the current page is /viewer/page?mode=edit#section2
16
+ * resolveFragmentUrl("clip") → "url(/viewer/page?mode=edit#clip)"
17
+ *
18
+ * @param id - The fragment identifier to append (e.g., an SVG element's ID).
19
+ * @returns A `url(...)` string pointing to the fragment within the current document.
20
+ */
21
+ export declare function resolveFragmentUrl(id: string): string;
22
+ //# sourceMappingURL=resolveFragmentUrl.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"resolveFragmentUrl.d.ts","sourceRoot":"","sources":["../../../../src/shared/utils/resolveFragmentUrl.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;GAmBG;AACH,wBAAgB,kBAAkB,CAAC,EAAE,EAAE,MAAM,GAAG,MAAM,CAIrD"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@m3e/core",
3
- "version": "1.1.1",
3
+ "version": "1.1.3",
4
4
  "description": "Core for M3E",
5
5
  "author": "matraic <matraic@yahoo.com>",
6
6
  "license": "MIT",