@cnvx/nodal 0.2.2 → 0.2.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.
|
@@ -1,14 +1,5 @@
|
|
|
1
|
-
<script lang="ts">
|
|
2
|
-
|
|
3
|
-
import Diagram, {
|
|
4
|
-
type DiagramNodeDef,
|
|
5
|
-
type DiagramEdgeDef,
|
|
6
|
-
} from "./Diagram.svelte";
|
|
7
|
-
import { onMount, setContext, type Snippet } from "svelte";
|
|
8
|
-
import type { HTMLAttributes } from "svelte/elements";
|
|
9
|
-
import PrerenderDiagram from "./PrerenderDiagram.svelte";
|
|
10
|
-
|
|
11
|
-
type PassthroughDiagramControllerProps = ({
|
|
1
|
+
<script lang="ts" module>
|
|
2
|
+
export type PassthroughDiagramControllerProps = ({
|
|
12
3
|
eagerLoad?: boolean;
|
|
13
4
|
rootMargin?: string;
|
|
14
5
|
figureAttributes?: HTMLAttributes<HTMLElement>;
|
|
@@ -25,6 +16,17 @@
|
|
|
25
16
|
}
|
|
26
17
|
)) &
|
|
27
18
|
Omit<HTMLAttributes<HTMLDivElement>, "width" | "height">;
|
|
19
|
+
</script>
|
|
20
|
+
|
|
21
|
+
<script lang="ts">
|
|
22
|
+
import { SvelteMap } from "svelte/reactivity";
|
|
23
|
+
import Diagram, {
|
|
24
|
+
type DiagramNodeDef,
|
|
25
|
+
type DiagramEdgeDef,
|
|
26
|
+
} from "./Diagram.svelte";
|
|
27
|
+
import { onMount, setContext, type Snippet } from "svelte";
|
|
28
|
+
import type { HTMLAttributes } from "svelte/elements";
|
|
29
|
+
import PrerenderDiagram from "./PrerenderDiagram.svelte";
|
|
28
30
|
|
|
29
31
|
let {
|
|
30
32
|
children,
|
|
@@ -1,6 +1,4 @@
|
|
|
1
|
-
|
|
2
|
-
import type { HTMLAttributes } from "svelte/elements";
|
|
3
|
-
type PassthroughDiagramControllerProps = ({
|
|
1
|
+
export type PassthroughDiagramControllerProps = ({
|
|
4
2
|
eagerLoad?: boolean;
|
|
5
3
|
rootMargin?: string;
|
|
6
4
|
figureAttributes?: HTMLAttributes<HTMLElement>;
|
|
@@ -13,6 +11,8 @@ type PassthroughDiagramControllerProps = ({
|
|
|
13
11
|
width: number;
|
|
14
12
|
height: number;
|
|
15
13
|
})) & Omit<HTMLAttributes<HTMLDivElement>, "width" | "height">;
|
|
14
|
+
import { type Snippet } from "svelte";
|
|
15
|
+
import type { HTMLAttributes } from "svelte/elements";
|
|
16
16
|
type $$ComponentProps = PassthroughDiagramControllerProps & {
|
|
17
17
|
children: Snippet;
|
|
18
18
|
};
|
package/dist/index.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
export { default as Diagram } from './Diagram.svelte';
|
|
2
|
-
export { default as DiagramController } from './DiagramController.svelte';
|
|
2
|
+
export { default as DiagramController, type PassthroughDiagramControllerProps } from './DiagramController.svelte';
|
|
3
3
|
export { default as DiagramNode } from './DiagramNode.svelte';
|
|
4
4
|
export { default as PrerenderDiagram } from './PrerenderDiagram.svelte';
|
|
5
5
|
export * from './diagram-lib.js';
|