@witchcraft/layout 0.5.9 → 0.5.10

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/module.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@witchcraft/layout",
3
3
  "configKey": "witchcraftLayout",
4
- "version": "0.5.9",
4
+ "version": "0.5.10",
5
5
  "builder": {
6
6
  "@nuxt/module-builder": "1.0.2",
7
7
  "unbuild": "unknown"
@@ -1,9 +1,8 @@
1
- import { type EdgeMoveStartData } from "../types/index.js";
2
- import type { Edge, EdgeCss } from "../types/index.js";
1
+ import type { Edge, EdgeCss, UseFramesContext } from "../types/index.js";
3
2
  type __VLS_Props = {
4
3
  edge: Edge;
5
4
  css: EdgeCss;
6
- onPointerDown?: (e: PointerEvent, type: "edge", data: EdgeMoveStartData) => void;
5
+ onPointerDown?: UseFramesContext["moveStart"];
7
6
  };
8
7
  declare const _default: import("vue").DefineComponent<__VLS_Props, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
9
8
  export default _default;
@@ -34,7 +34,7 @@ defineOptions({
34
34
  const props = defineProps({
35
35
  edge: { type: null, required: true },
36
36
  css: { type: Object, required: true },
37
- onPointerDown: { type: Function, required: false }
37
+ onPointerDown: { type: null, required: false }
38
38
  });
39
39
  const ctx = inject(layoutContextInjectionKey, void 0);
40
40
  if (!ctx) throw new Error("LayoutEdges must be used within a LayoutWindow");
@@ -1,9 +1,8 @@
1
- import { type EdgeMoveStartData } from "../types/index.js";
2
- import type { Edge, EdgeCss } from "../types/index.js";
1
+ import type { Edge, EdgeCss, UseFramesContext } from "../types/index.js";
3
2
  type __VLS_Props = {
4
3
  edge: Edge;
5
4
  css: EdgeCss;
6
- onPointerDown?: (e: PointerEvent, type: "edge", data: EdgeMoveStartData) => void;
5
+ onPointerDown?: UseFramesContext["moveStart"];
7
6
  };
8
7
  declare const _default: import("vue").DefineComponent<__VLS_Props, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
9
8
  export default _default;
@@ -19,7 +19,7 @@
19
19
  edge: visualEdges[i]
20
20
  }">
21
21
  <LayoutDragEdgeVisible
22
- :edge="visualEdges[i]"
22
+ :edge="visualEdges[i]"
23
23
  :css="css.visible"
24
24
  />
25
25
  </slot>
@@ -1,10 +1,9 @@
1
1
  import { getIntersectionsCss } from "../helpers/getIntersectionsCss.js";
2
- import { type EdgeMoveStartData } from "../types/index.js";
3
- import type { IntersectionEntry } from "../types/index.js";
2
+ import type { IntersectionEntry, UseFramesContext } from "../types/index.js";
4
3
  type __VLS_Props = {
5
4
  css: ReturnType<typeof getIntersectionsCss>[number];
6
5
  intersection: IntersectionEntry;
7
- onPointerDown?: (e: PointerEvent, type: "edge", data: EdgeMoveStartData) => void;
6
+ onPointerDown?: UseFramesContext["moveStart"];
8
7
  };
9
8
  declare const _default: import("vue").DefineComponent<__VLS_Props, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
10
9
  export default _default;
@@ -18,7 +18,6 @@ import { useAttrs, inject } from "vue";
18
18
  import { twMerge } from "@witchcraft/ui/utils/twMerge";
19
19
  import LayoutShapeRect from "./LayoutShapeRect.vue";
20
20
  import { getIntersectionsCss } from "../helpers/getIntersectionsCss.js";
21
- import {} from "../types/index.js";
22
21
  import { moveContextInjectionKey } from "../types/vue.js";
23
22
  const $attrs = useAttrs();
24
23
  defineOptions({
@@ -27,7 +26,7 @@ defineOptions({
27
26
  const props = defineProps({
28
27
  css: { type: null, required: true },
29
28
  intersection: { type: Object, required: true },
30
- onPointerDown: { type: Function, required: false }
29
+ onPointerDown: { type: null, required: false }
31
30
  });
32
31
  const ctx = inject(layoutContextInjectionKey, void 0);
33
32
  if (!ctx) throw new Error("LayoutEdges must be used within a LayoutWindow");
@@ -1,10 +1,9 @@
1
1
  import { getIntersectionsCss } from "../helpers/getIntersectionsCss.js";
2
- import { type EdgeMoveStartData } from "../types/index.js";
3
- import type { IntersectionEntry } from "../types/index.js";
2
+ import type { IntersectionEntry, UseFramesContext } from "../types/index.js";
4
3
  type __VLS_Props = {
5
4
  css: ReturnType<typeof getIntersectionsCss>[number];
6
5
  intersection: IntersectionEntry;
7
- onPointerDown?: (e: PointerEvent, type: "edge", data: EdgeMoveStartData) => void;
6
+ onPointerDown?: UseFramesContext["moveStart"];
8
7
  };
9
8
  declare const _default: import("vue").DefineComponent<__VLS_Props, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
10
9
  export default _default;