@motionscript/math 0.1.0-alpha.5 → 0.1.0-alpha.7
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/CHANGELOG.md +28 -0
- package/README.md +39 -33
- package/dist/annotate/angle-mark.d.ts +77 -27
- package/dist/annotate/angle-mark.d.ts.map +1 -1
- package/dist/annotate/angle-mark.js +80 -115
- package/dist/annotate/angle-mark.js.map +1 -1
- package/dist/annotate/curly-brace.d.ts +94 -25
- package/dist/annotate/curly-brace.d.ts.map +1 -1
- package/dist/annotate/curly-brace.js +85 -100
- package/dist/annotate/curly-brace.js.map +1 -1
- package/dist/annotate/emphasis-mark.d.ts +69 -9
- package/dist/annotate/emphasis-mark.d.ts.map +1 -1
- package/dist/annotate/emphasis-mark.js +33 -34
- package/dist/annotate/emphasis-mark.js.map +1 -1
- package/dist/browser/chunks/chunk-ABYBW64J.js +2 -0
- package/dist/browser/chunks/chunk-ABYBW64J.js.map +7 -0
- package/dist/browser/chunks/chunk-K77KLQX4.js +2 -0
- package/dist/browser/chunks/chunk-K77KLQX4.js.map +7 -0
- package/dist/browser/index.js +1 -1
- package/dist/browser/index.js.map +3 -3
- package/dist/browser/kit.js +1 -1
- package/dist/browser/manifest.json +1 -1
- package/dist/browser/tex.js +1 -1
- package/dist/browser/tex.js.map +2 -2
- package/dist/engine.d.ts +26 -19
- package/dist/engine.d.ts.map +1 -1
- package/dist/engine.js +17 -14
- package/dist/engine.js.map +1 -1
- package/dist/kit/component.d.ts +51 -0
- package/dist/kit/component.d.ts.map +1 -0
- package/dist/kit/component.js +30 -0
- package/dist/kit/component.js.map +1 -0
- package/dist/kit/curve.d.ts +22 -11
- package/dist/kit/curve.d.ts.map +1 -1
- package/dist/kit/curve.js +25 -18
- package/dist/kit/curve.js.map +1 -1
- package/dist/kit/field-mark.d.ts +56 -35
- package/dist/kit/field-mark.d.ts.map +1 -1
- package/dist/kit/field-mark.js +100 -120
- package/dist/kit/field-mark.js.map +1 -1
- package/dist/kit/follow.d.ts +67 -29
- package/dist/kit/follow.d.ts.map +1 -1
- package/dist/kit/follow.js +114 -110
- package/dist/kit/follow.js.map +1 -1
- package/dist/kit/furniture.d.ts +3 -1
- package/dist/kit/furniture.d.ts.map +1 -1
- package/dist/kit/furniture.js +5 -0
- package/dist/kit/furniture.js.map +1 -1
- package/dist/kit/graph.d.ts +46 -0
- package/dist/kit/graph.d.ts.map +1 -0
- package/dist/kit/graph.js +90 -0
- package/dist/kit/graph.js.map +1 -0
- package/dist/kit/mark.d.ts +64 -39
- package/dist/kit/mark.d.ts.map +1 -1
- package/dist/kit/mark.js +80 -96
- package/dist/kit/mark.js.map +1 -1
- package/dist/kit/place.d.ts +10 -8
- package/dist/kit/place.d.ts.map +1 -1
- package/dist/kit/place.js +28 -30
- package/dist/kit/place.js.map +1 -1
- package/dist/kit/system.d.ts +27 -29
- package/dist/kit/system.d.ts.map +1 -1
- package/dist/kit/system.js +62 -58
- package/dist/kit/system.js.map +1 -1
- package/dist/kit/withdrawn.d.ts +3 -3
- package/dist/kit/withdrawn.js +3 -3
- package/dist/kit/withdrawn.js.map +1 -1
- package/dist/marks/curve-area.d.ts +37 -18
- package/dist/marks/curve-area.d.ts.map +1 -1
- package/dist/marks/curve-area.js +50 -73
- package/dist/marks/curve-area.js.map +1 -1
- package/dist/marks/drop-lines.d.ts +45 -10
- package/dist/marks/drop-lines.d.ts.map +1 -1
- package/dist/marks/drop-lines.js +37 -52
- package/dist/marks/drop-lines.js.map +1 -1
- package/dist/marks/plot-point.d.ts +56 -20
- package/dist/marks/plot-point.d.ts.map +1 -1
- package/dist/marks/plot-point.js +65 -91
- package/dist/marks/plot-point.js.map +1 -1
- package/dist/marks/riemann-sum.d.ts +47 -26
- package/dist/marks/riemann-sum.d.ts.map +1 -1
- package/dist/marks/riemann-sum.js +57 -85
- package/dist/marks/riemann-sum.js.map +1 -1
- package/dist/marks/tangent-line.d.ts +58 -14
- package/dist/marks/tangent-line.d.ts.map +1 -1
- package/dist/marks/tangent-line.js +73 -87
- package/dist/marks/tangent-line.js.map +1 -1
- package/dist/marks/vector-arrow.d.ts +48 -20
- package/dist/marks/vector-arrow.d.ts.map +1 -1
- package/dist/marks/vector-arrow.js +58 -78
- package/dist/marks/vector-arrow.js.map +1 -1
- package/dist/nodes.d.ts +13 -5
- package/dist/nodes.d.ts.map +1 -1
- package/dist/nodes.js +0 -6
- package/dist/nodes.js.map +1 -1
- package/dist/plots/function-plot.d.ts +135 -43
- package/dist/plots/function-plot.d.ts.map +1 -1
- package/dist/plots/function-plot.js +146 -177
- package/dist/plots/function-plot.js.map +1 -1
- package/dist/plots/points-plot.d.ts +55 -19
- package/dist/plots/points-plot.d.ts.map +1 -1
- package/dist/plots/points-plot.js +31 -58
- package/dist/plots/points-plot.js.map +1 -1
- package/dist/plots/stream-lines.d.ts +60 -19
- package/dist/plots/stream-lines.d.ts.map +1 -1
- package/dist/plots/stream-lines.js +60 -79
- package/dist/plots/stream-lines.js.map +1 -1
- package/dist/plots/traced-path.d.ts +54 -15
- package/dist/plots/traced-path.d.ts.map +1 -1
- package/dist/plots/traced-path.js +33 -48
- package/dist/plots/traced-path.js.map +1 -1
- package/dist/plots/vector-field.d.ts +48 -11
- package/dist/plots/vector-field.d.ts.map +1 -1
- package/dist/plots/vector-field.js +50 -64
- package/dist/plots/vector-field.js.map +1 -1
- package/dist/structures/network-graph.d.ts +140 -49
- package/dist/structures/network-graph.d.ts.map +1 -1
- package/dist/structures/network-graph.js +168 -217
- package/dist/structures/network-graph.js.map +1 -1
- package/dist/structures/sample-space.d.ts +90 -38
- package/dist/structures/sample-space.d.ts.map +1 -1
- package/dist/structures/sample-space.js +132 -170
- package/dist/structures/sample-space.js.map +1 -1
- package/dist/systems/axes2d.d.ts +159 -37
- package/dist/systems/axes2d.d.ts.map +1 -1
- package/dist/systems/axes2d.js +147 -183
- package/dist/systems/axes2d.js.map +1 -1
- package/dist/systems/number-line.d.ts +80 -28
- package/dist/systems/number-line.d.ts.map +1 -1
- package/dist/systems/number-line.js +82 -118
- package/dist/systems/number-line.js.map +1 -1
- package/dist/systems/number-plane.d.ts +140 -31
- package/dist/systems/number-plane.d.ts.map +1 -1
- package/dist/systems/number-plane.js +142 -149
- package/dist/systems/number-plane.js.map +1 -1
- package/dist/systems/polar-plane.d.ts +76 -26
- package/dist/systems/polar-plane.d.ts.map +1 -1
- package/dist/systems/polar-plane.js +107 -133
- package/dist/systems/polar-plane.js.map +1 -1
- package/dist/tex/index.d.ts.map +1 -1
- package/dist/tex/index.js +1 -0
- package/dist/tex/index.js.map +1 -1
- package/dist/tex/matrix.d.ts +88 -18
- package/dist/tex/matrix.d.ts.map +1 -1
- package/dist/tex/matrix.js +33 -50
- package/dist/tex/matrix.js.map +1 -1
- package/dist/tex/node.d.ts +84 -201
- package/dist/tex/node.d.ts.map +1 -1
- package/dist/tex/node.js +23 -593
- package/dist/tex/node.js.map +1 -1
- package/dist/tex/typeset.d.ts +133 -0
- package/dist/tex/typeset.d.ts.map +1 -0
- package/dist/tex/typeset.js +403 -0
- package/dist/tex/typeset.js.map +1 -0
- package/dist/three/axes3d.d.ts +214 -54
- package/dist/three/axes3d.d.ts.map +1 -1
- package/dist/three/axes3d.js +163 -204
- package/dist/three/axes3d.js.map +1 -1
- package/dist/three/curve-plot3d.d.ts +108 -42
- package/dist/three/curve-plot3d.d.ts.map +1 -1
- package/dist/three/curve-plot3d.js +97 -132
- package/dist/three/curve-plot3d.js.map +1 -1
- package/dist/three/entries.d.ts +17 -0
- package/dist/three/entries.d.ts.map +1 -0
- package/dist/three/entries.js +15 -0
- package/dist/three/entries.js.map +1 -0
- package/dist/three/plot-point3d.d.ts +85 -12
- package/dist/three/plot-point3d.d.ts.map +1 -1
- package/dist/three/plot-point3d.js +27 -53
- package/dist/three/plot-point3d.js.map +1 -1
- package/dist/three/space.d.ts +17 -2
- package/dist/three/space.d.ts.map +1 -1
- package/dist/three/space.js +19 -8
- package/dist/three/space.js.map +1 -1
- package/dist/three/surface-plot3d.d.ts +176 -49
- package/dist/three/surface-plot3d.d.ts.map +1 -1
- package/dist/three/surface-plot3d.js +227 -261
- package/dist/three/surface-plot3d.js.map +1 -1
- package/dist/three/vector-arrow3d.d.ts +87 -16
- package/dist/three/vector-arrow3d.d.ts.map +1 -1
- package/dist/three/vector-arrow3d.js +48 -67
- package/dist/three/vector-arrow3d.js.map +1 -1
- package/package.json +4 -4
- package/src/annotate/angle-mark.ts +95 -105
- package/src/annotate/curly-brace.ts +107 -85
- package/src/annotate/emphasis-mark.ts +55 -26
- package/src/engine.ts +35 -21
- package/src/kit/component.ts +57 -0
- package/src/kit/curve.ts +38 -20
- package/src/kit/field-mark.ts +124 -108
- package/src/kit/follow.ts +146 -120
- package/src/kit/furniture.ts +6 -1
- package/src/kit/graph.ts +116 -0
- package/src/kit/mark.ts +135 -114
- package/src/kit/place.ts +32 -56
- package/src/kit/system.ts +77 -71
- package/src/kit/withdrawn.ts +3 -3
- package/src/marks/curve-area.ts +65 -65
- package/src/marks/drop-lines.ts +50 -42
- package/src/marks/plot-point.ts +77 -82
- package/src/marks/riemann-sum.ts +73 -72
- package/src/marks/tangent-line.ts +87 -71
- package/src/marks/vector-arrow.ts +73 -73
- package/src/nodes.ts +41 -5
- package/src/plots/function-plot.ts +155 -171
- package/src/plots/points-plot.ts +46 -50
- package/src/plots/stream-lines.ts +75 -66
- package/src/plots/traced-path.ts +51 -33
- package/src/plots/vector-field.ts +68 -49
- package/src/structures/network-graph.ts +168 -185
- package/src/structures/sample-space.ts +149 -148
- package/src/systems/axes2d.ts +165 -156
- package/src/systems/number-line.ts +91 -92
- package/src/systems/number-plane.ts +149 -120
- package/src/systems/polar-plane.ts +117 -116
- package/src/tex/index.ts +2 -1
- package/src/tex/matrix.ts +62 -40
- package/src/tex/node.ts +54 -621
- package/src/tex/typeset.ts +461 -0
- package/src/three/axes3d.ts +187 -160
- package/src/three/curve-plot3d.ts +107 -110
- package/src/three/entries.ts +42 -0
- package/src/three/plot-point3d.ts +42 -45
- package/src/three/space.ts +34 -9
- package/src/three/surface-plot3d.ts +312 -323
- package/src/three/vector-arrow3d.ts +65 -54
- package/dist/browser/chunks/chunk-3GJB6AVO.js +0 -2
- package/dist/browser/chunks/chunk-3GJB6AVO.js.map +0 -7
- package/dist/browser/chunks/chunk-D5WHCVBC.js +0 -2
- package/dist/browser/chunks/chunk-D5WHCVBC.js.map +0 -7
- package/dist/browser/chunks/chunk-WL4KEX7Y.js +0 -2
- package/dist/browser/chunks/chunk-WL4KEX7Y.js.map +0 -7
- package/src/kit/placement.ts +0 -8
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { type PartFill } from "../kit/part-fills.js";
|
|
1
|
+
import { type Color, type Fill, type FillResolved, type NodeOf, type NormalizedColor, type PaintProps, type ShadowResolved, type Size2D, type Stroke, type StrokeResolved, type Values, type Vector2, type Node2D as _Node2D, type Node2DProps as _Node2DProps, type Shadow as _Shadow } from "@motionscript/sdk";
|
|
2
|
+
import { type PartFill, type PartFillResolved } from "../kit/part-fills.js";
|
|
3
3
|
import { type GraphEdge, type GraphLayout } from "./graph-layout.js";
|
|
4
4
|
/** A vertex placed by hand, in the graph's box from -1 to 1 each way, y up. */
|
|
5
5
|
export interface GraphPosition {
|
|
@@ -22,6 +22,35 @@ export interface NetworkGraphProps extends PaintProps {
|
|
|
22
22
|
fontFamily?: string;
|
|
23
23
|
partFills?: PartFill[];
|
|
24
24
|
}
|
|
25
|
+
declare const state: {
|
|
26
|
+
vertices: import("@motionscript/sdk").Type<string[], string[], false>;
|
|
27
|
+
edges: import("@motionscript/sdk").Type<GraphEdge[], GraphEdge[], false>;
|
|
28
|
+
/** Draw each edge as an arrow from its `from` to its `to`. */
|
|
29
|
+
directed: import("@motionscript/sdk").Type<boolean, boolean, false>;
|
|
30
|
+
arrangement: import("@motionscript/sdk").Type<GraphLayout, GraphLayout, false>;
|
|
31
|
+
/** The vertex a tree hangs from; left empty, the first. */
|
|
32
|
+
root: import("@motionscript/sdk").Type<string, string, false>;
|
|
33
|
+
/** Vertices placed by hand, whatever the layout says, in the box from -1 to 1 each way. */
|
|
34
|
+
positions: import("@motionscript/sdk").Type<GraphPosition[], GraphPosition[], false>;
|
|
35
|
+
vertexRadius: import("@motionscript/sdk").Type<number, number, false>;
|
|
36
|
+
vertexStroke: import("@motionscript/sdk").Type<Stroke, StrokeResolved[], false>;
|
|
37
|
+
labels: import("@motionscript/sdk").Type<boolean, boolean, false>;
|
|
38
|
+
labelSize: import("@motionscript/sdk").Type<number, number, false>;
|
|
39
|
+
labelColor: import("@motionscript/sdk").Type<Color, NormalizedColor, false>;
|
|
40
|
+
fontFamily: import("@motionscript/sdk").Type<string, string, false>;
|
|
41
|
+
/** Paints for a vertex by its name, or an edge written `a-b`, over the graph's own. */
|
|
42
|
+
partFills: import("@motionscript/sdk").Type<PartFill[], PartFillResolved[], false>;
|
|
43
|
+
/** The arrangement an `arrangeTo` is leaving, and how far it is towards the new one. */
|
|
44
|
+
layoutFrom: import("@motionscript/sdk").Type<string, string, true>;
|
|
45
|
+
layoutMix: import("@motionscript/sdk").Type<number, number, true>;
|
|
46
|
+
fill: import("@motionscript/sdk").Attribute<Fill, FillResolved[]>;
|
|
47
|
+
stroke: import("@motionscript/sdk").Attribute<Stroke, StrokeResolved[]>;
|
|
48
|
+
shadow: import("@motionscript/sdk").Attribute<_Shadow, ShadowResolved[]>;
|
|
49
|
+
start: import("@motionscript/sdk").Type<number, number, false>;
|
|
50
|
+
end: import("@motionscript/sdk").Type<number, number, false>;
|
|
51
|
+
};
|
|
52
|
+
/** What a graph is drawn from: its own entries, as its fields and its node both read them. */
|
|
53
|
+
export type GraphValues = Values<typeof state>;
|
|
25
54
|
/**
|
|
26
55
|
* Vertices and the edges between them, arranged by a rule: in a circle, by
|
|
27
56
|
* springs, as a tree from `root`, or in a grid. Its `fill` is the vertices and
|
|
@@ -29,55 +58,117 @@ export interface NetworkGraphProps extends PaintProps {
|
|
|
29
58
|
* moves every vertex to where another rule places it; `partFillTo` paints a
|
|
30
59
|
* vertex, or an edge written `a-b`. (`layout` is every node's own box.)
|
|
31
60
|
*/
|
|
32
|
-
export declare
|
|
33
|
-
vertices: string[]
|
|
34
|
-
edges: GraphEdge[]
|
|
61
|
+
export declare const NetworkGraph: import("@motionscript/sdk").Component<"networkGraph", import("@motionscript/sdk").Merge<import("@motionscript/sdk").Box2DState, {
|
|
62
|
+
vertices: import("@motionscript/sdk").Type<string[], string[], false>;
|
|
63
|
+
edges: import("@motionscript/sdk").Type<GraphEdge[], GraphEdge[], false>;
|
|
35
64
|
/** Draw each edge as an arrow from its `from` to its `to`. */
|
|
36
|
-
directed: boolean
|
|
37
|
-
arrangement: GraphLayout
|
|
65
|
+
directed: import("@motionscript/sdk").Type<boolean, boolean, false>;
|
|
66
|
+
arrangement: import("@motionscript/sdk").Type<GraphLayout, GraphLayout, false>;
|
|
38
67
|
/** The vertex a tree hangs from; left empty, the first. */
|
|
39
|
-
root: string
|
|
68
|
+
root: import("@motionscript/sdk").Type<string, string, false>;
|
|
40
69
|
/** Vertices placed by hand, whatever the layout says, in the box from -1 to 1 each way. */
|
|
41
|
-
positions: GraphPosition[]
|
|
42
|
-
vertexRadius: number
|
|
43
|
-
vertexStroke: Stroke
|
|
44
|
-
labels: boolean
|
|
45
|
-
labelSize: number
|
|
46
|
-
labelColor: Color
|
|
47
|
-
fontFamily: string
|
|
70
|
+
positions: import("@motionscript/sdk").Type<GraphPosition[], GraphPosition[], false>;
|
|
71
|
+
vertexRadius: import("@motionscript/sdk").Type<number, number, false>;
|
|
72
|
+
vertexStroke: import("@motionscript/sdk").Type<Stroke, StrokeResolved[], false>;
|
|
73
|
+
labels: import("@motionscript/sdk").Type<boolean, boolean, false>;
|
|
74
|
+
labelSize: import("@motionscript/sdk").Type<number, number, false>;
|
|
75
|
+
labelColor: import("@motionscript/sdk").Type<Color, NormalizedColor, false>;
|
|
76
|
+
fontFamily: import("@motionscript/sdk").Type<string, string, false>;
|
|
48
77
|
/** Paints for a vertex by its name, or an edge written `a-b`, over the graph's own. */
|
|
49
|
-
partFills: PartFill[]
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
partFillTo
|
|
63
|
-
part: string
|
|
64
|
-
fill: Fill
|
|
65
|
-
}
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
78
|
+
partFills: import("@motionscript/sdk").Type<PartFill[], PartFillResolved[], false>;
|
|
79
|
+
/** The arrangement an `arrangeTo` is leaving, and how far it is towards the new one. */
|
|
80
|
+
layoutFrom: import("@motionscript/sdk").Type<string, string, true>;
|
|
81
|
+
layoutMix: import("@motionscript/sdk").Type<number, number, true>;
|
|
82
|
+
fill: import("@motionscript/sdk").Attribute<Fill, FillResolved[]>;
|
|
83
|
+
stroke: import("@motionscript/sdk").Attribute<Stroke, StrokeResolved[]>;
|
|
84
|
+
shadow: import("@motionscript/sdk").Attribute<_Shadow, ShadowResolved[]>;
|
|
85
|
+
start: import("@motionscript/sdk").Type<number, number, false>;
|
|
86
|
+
end: import("@motionscript/sdk").Type<number, number, false>;
|
|
87
|
+
}>, {
|
|
88
|
+
readonly arrangeTo: {
|
|
89
|
+
readonly arrangement: import("@motionscript/sdk").Type<GraphLayout | undefined, GraphLayout | undefined, false>;
|
|
90
|
+
};
|
|
91
|
+
readonly partFillTo: {
|
|
92
|
+
readonly part: import("@motionscript/sdk").Type<string, string, false>;
|
|
93
|
+
readonly fill: import("@motionscript/sdk").Type<Fill, Fill, false>;
|
|
94
|
+
};
|
|
95
|
+
readonly fillTo: readonly ["fill"];
|
|
96
|
+
readonly strokeTo: readonly ["stroke"];
|
|
97
|
+
readonly shadowTo: readonly ["shadow"];
|
|
98
|
+
readonly progressTo: readonly ["start", "end"];
|
|
99
|
+
readonly flash: {
|
|
100
|
+
readonly portion: import("@motionscript/sdk").Type<number, number, false>;
|
|
101
|
+
};
|
|
102
|
+
}, null, _Node2D<_Node2DProps>, import("@motionscript/sdk").CallProps<import("@motionscript/sdk").Merge<import("@motionscript/sdk").Box2DState, {
|
|
103
|
+
vertices: import("@motionscript/sdk").Type<string[], string[], false>;
|
|
104
|
+
edges: import("@motionscript/sdk").Type<GraphEdge[], GraphEdge[], false>;
|
|
105
|
+
/** Draw each edge as an arrow from its `from` to its `to`. */
|
|
106
|
+
directed: import("@motionscript/sdk").Type<boolean, boolean, false>;
|
|
107
|
+
arrangement: import("@motionscript/sdk").Type<GraphLayout, GraphLayout, false>;
|
|
108
|
+
/** The vertex a tree hangs from; left empty, the first. */
|
|
109
|
+
root: import("@motionscript/sdk").Type<string, string, false>;
|
|
110
|
+
/** Vertices placed by hand, whatever the layout says, in the box from -1 to 1 each way. */
|
|
111
|
+
positions: import("@motionscript/sdk").Type<GraphPosition[], GraphPosition[], false>;
|
|
112
|
+
vertexRadius: import("@motionscript/sdk").Type<number, number, false>;
|
|
113
|
+
vertexStroke: import("@motionscript/sdk").Type<Stroke, StrokeResolved[], false>;
|
|
114
|
+
labels: import("@motionscript/sdk").Type<boolean, boolean, false>;
|
|
115
|
+
labelSize: import("@motionscript/sdk").Type<number, number, false>;
|
|
116
|
+
labelColor: import("@motionscript/sdk").Type<Color, NormalizedColor, false>;
|
|
117
|
+
fontFamily: import("@motionscript/sdk").Type<string, string, false>;
|
|
118
|
+
/** Paints for a vertex by its name, or an edge written `a-b`, over the graph's own. */
|
|
119
|
+
partFills: import("@motionscript/sdk").Type<PartFill[], PartFillResolved[], false>;
|
|
120
|
+
/** The arrangement an `arrangeTo` is leaving, and how far it is towards the new one. */
|
|
121
|
+
layoutFrom: import("@motionscript/sdk").Type<string, string, true>;
|
|
122
|
+
layoutMix: import("@motionscript/sdk").Type<number, number, true>;
|
|
123
|
+
fill: import("@motionscript/sdk").Attribute<Fill, FillResolved[]>;
|
|
124
|
+
stroke: import("@motionscript/sdk").Attribute<Stroke, StrokeResolved[]>;
|
|
125
|
+
shadow: import("@motionscript/sdk").Attribute<_Shadow, ShadowResolved[]>;
|
|
126
|
+
start: import("@motionscript/sdk").Type<number, number, false>;
|
|
127
|
+
end: import("@motionscript/sdk").Type<number, number, false>;
|
|
128
|
+
}>, null, import("@motionscript/sdk").BuiltNode<import("@motionscript/sdk").Merge<import("@motionscript/sdk").Box2DState, {
|
|
129
|
+
vertices: import("@motionscript/sdk").Type<string[], string[], false>;
|
|
130
|
+
edges: import("@motionscript/sdk").Type<GraphEdge[], GraphEdge[], false>;
|
|
131
|
+
/** Draw each edge as an arrow from its `from` to its `to`. */
|
|
132
|
+
directed: import("@motionscript/sdk").Type<boolean, boolean, false>;
|
|
133
|
+
arrangement: import("@motionscript/sdk").Type<GraphLayout, GraphLayout, false>;
|
|
134
|
+
/** The vertex a tree hangs from; left empty, the first. */
|
|
135
|
+
root: import("@motionscript/sdk").Type<string, string, false>;
|
|
136
|
+
/** Vertices placed by hand, whatever the layout says, in the box from -1 to 1 each way. */
|
|
137
|
+
positions: import("@motionscript/sdk").Type<GraphPosition[], GraphPosition[], false>;
|
|
138
|
+
vertexRadius: import("@motionscript/sdk").Type<number, number, false>;
|
|
139
|
+
vertexStroke: import("@motionscript/sdk").Type<Stroke, StrokeResolved[], false>;
|
|
140
|
+
labels: import("@motionscript/sdk").Type<boolean, boolean, false>;
|
|
141
|
+
labelSize: import("@motionscript/sdk").Type<number, number, false>;
|
|
142
|
+
labelColor: import("@motionscript/sdk").Type<Color, NormalizedColor, false>;
|
|
143
|
+
fontFamily: import("@motionscript/sdk").Type<string, string, false>;
|
|
144
|
+
/** Paints for a vertex by its name, or an edge written `a-b`, over the graph's own. */
|
|
145
|
+
partFills: import("@motionscript/sdk").Type<PartFill[], PartFillResolved[], false>;
|
|
146
|
+
/** The arrangement an `arrangeTo` is leaving, and how far it is towards the new one. */
|
|
147
|
+
layoutFrom: import("@motionscript/sdk").Type<string, string, true>;
|
|
148
|
+
layoutMix: import("@motionscript/sdk").Type<number, number, true>;
|
|
149
|
+
fill: import("@motionscript/sdk").Attribute<Fill, FillResolved[]>;
|
|
150
|
+
stroke: import("@motionscript/sdk").Attribute<Stroke, StrokeResolved[]>;
|
|
151
|
+
shadow: import("@motionscript/sdk").Attribute<_Shadow, ShadowResolved[]>;
|
|
152
|
+
start: import("@motionscript/sdk").Type<number, number, false>;
|
|
153
|
+
end: import("@motionscript/sdk").Type<number, number, false>;
|
|
154
|
+
}>, {
|
|
155
|
+
readonly arrangeTo: {
|
|
156
|
+
readonly arrangement: import("@motionscript/sdk").Type<GraphLayout | undefined, GraphLayout | undefined, false>;
|
|
157
|
+
};
|
|
158
|
+
readonly partFillTo: {
|
|
159
|
+
readonly part: import("@motionscript/sdk").Type<string, string, false>;
|
|
160
|
+
readonly fill: import("@motionscript/sdk").Type<Fill, Fill, false>;
|
|
161
|
+
};
|
|
162
|
+
readonly fillTo: readonly ["fill"];
|
|
163
|
+
readonly strokeTo: readonly ["stroke"];
|
|
164
|
+
readonly shadowTo: readonly ["shadow"];
|
|
165
|
+
readonly progressTo: readonly ["start", "end"];
|
|
166
|
+
readonly flash: {
|
|
167
|
+
readonly portion: import("@motionscript/sdk").Type<number, number, false>;
|
|
168
|
+
};
|
|
169
|
+
}, _Node2D<_Node2DProps>>>>;
|
|
170
|
+
export type NetworkGraph = NodeOf<typeof NetworkGraph>;
|
|
171
|
+
/** Where each vertex is drawn in a graph of `size`, in pixels from its centre, y up. */
|
|
172
|
+
export declare function vertexPoints(graph: GraphValues, size: Size2D): Map<string, Vector2>;
|
|
173
|
+
export {};
|
|
83
174
|
//# sourceMappingURL=network-graph.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"network-graph.d.ts","sourceRoot":"","sources":["../../src/structures/network-graph.ts"],"names":[],"mappings":"AAAA,OAAO,
|
|
1
|
+
{"version":3,"file":"network-graph.d.ts","sourceRoot":"","sources":["../../src/structures/network-graph.ts"],"names":[],"mappings":"AAAA,OAAO,EAIH,KAAK,KAAK,EACV,KAAK,IAAI,EACT,KAAK,YAAY,EACjB,KAAK,MAAM,EACX,KAAK,eAAe,EACpB,KAAK,UAAU,EAEf,KAAK,cAAc,EACnB,KAAK,MAAM,EACX,KAAK,MAAM,EACX,KAAK,cAAc,EACnB,KAAK,MAAM,EACX,KAAK,OAAO,EAEZ,KAAK,MAAM,IAAI,OAAO,EACtB,KAAK,WAAW,IAAI,YAAY,EAChC,KAAK,MAAM,IAAI,OAAO,EACzB,MAAM,mBAAmB,CAAC;AAI3B,OAAO,EAAyD,KAAK,QAAQ,EAAE,KAAK,gBAAgB,EAAE,MAAM,mBAAmB,CAAC;AAChI,OAAO,EAAyB,KAAK,SAAS,EAAE,KAAK,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAEzF,+EAA+E;AAC/E,MAAM,WAAW,aAAa;IAC1B,MAAM,EAAE,MAAM,CAAC;IACf,CAAC,EAAE,MAAM,CAAC;IACV,CAAC,EAAE,MAAM,CAAC;CACb;AAED,MAAM,WAAW,iBAAkB,SAAQ,UAAU;IACjD,QAAQ,CAAC,EAAE,MAAM,EAAE,CAAC;IACpB,KAAK,CAAC,EAAE,SAAS,EAAE,CAAC;IACpB,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,WAAW,CAAC,EAAE,WAAW,CAAC;IAC1B,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,SAAS,CAAC,EAAE,aAAa,EAAE,CAAC;IAC5B,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,MAAM,CAAC,EAAE,OAAO,CAAC;IACjB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,UAAU,CAAC,EAAE,KAAK,CAAC;IACnB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,SAAS,CAAC,EAAE,QAAQ,EAAE,CAAC;CAC1B;AA4BD,QAAA,MAAM,KAAK;;;IAIP,8DAA8D;;;IAG9D,2DAA2D;;IAE3D,2FAA2F;;;;;;;;IAQ3F,uFAAuF;;IAEvF,wFAAwF;;;;;;;;CAG3F,CAAC;AAEF,8FAA8F;AAC9F,MAAM,MAAM,WAAW,GAAG,MAAM,CAAC,OAAO,KAAK,CAAC,CAAC;AAE/C;;;;;;GAMG;AACH,eAAO,MAAM,YAAY;;;IA9BrB,8DAA8D;;;IAG9D,2DAA2D;;IAE3D,2FAA2F;;;;;;;;IAQ3F,uFAAuF;;IAEvF,wFAAwF;;;;;;;;;;;;;;;;;;;;;;;;;;IAfxF,8DAA8D;;;IAG9D,2DAA2D;;IAE3D,2FAA2F;;;;;;;;IAQ3F,uFAAuF;;IAEvF,wFAAwF;;;;;;;;;;;IAfxF,8DAA8D;;;IAG9D,2DAA2D;;IAE3D,2FAA2F;;;;;;;;IAQ3F,uFAAuF;;IAEvF,wFAAwF;;;;;;;;;;;;;;;;;;;;;;;2BAiD1F,CAAC;AAEH,MAAM,MAAM,YAAY,GAAG,MAAM,CAAC,OAAO,YAAY,CAAC,CAAC;AAEvD,wFAAwF;AACxF,wBAAgB,YAAY,CAAC,KAAK,EAAE,WAAW,EAAE,IAAI,EAAE,MAAM,GAAG,GAAG,CAAC,MAAM,EAAE,OAAO,CAAC,CAanF"}
|