@celldl/editor 0.20260212.0 → 0.20260217.0

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 (87) hide show
  1. package/README.md +13 -0
  2. package/dist/CellDLEditor-ZFePDCI0.js +13851 -0
  3. package/dist/CellDLEditor-ZFePDCI0.js.map +1 -0
  4. package/dist/CellDLEditor.css +1 -1
  5. package/dist/CellDLEditor.es.js +6 -5
  6. package/dist/app/src/App.vue.d.ts +2 -0
  7. package/dist/app/src/common/common.d.ts +8 -0
  8. package/dist/app/src/common/constants.d.ts +5 -0
  9. package/dist/app/src/common/electron.d.ts +5 -0
  10. package/dist/app/src/common/electronApi.d.ts +8 -0
  11. package/dist/app/src/common/settings.d.ts +18 -0
  12. package/dist/app/src/common/version.d.ts +7 -0
  13. package/dist/app/src/common/vueCommon.d.ts +9 -0
  14. package/dist/app/src/main.d.ts +1 -0
  15. package/dist/{vendor-DFPLRrnP.js → index--lsZkhLY.js} +24316 -30274
  16. package/dist/index--lsZkhLY.js.map +1 -0
  17. package/dist/index.d.ts +54 -16
  18. package/dist/{index-DtCZg5ZV.js → oxigraph-Dx4bu2IN.js} +221 -843
  19. package/dist/oxigraph-Dx4bu2IN.js.map +1 -0
  20. package/dist/package.json.d.ts +106 -0
  21. package/dist/src/CellDL/SVGElements/boundedelement.d.ts +21 -0
  22. package/dist/src/CellDL/SVGElements/index.d.ts +66 -0
  23. package/dist/src/CellDL/SVGElements/linearpath.d.ts +11 -0
  24. package/dist/src/CellDL/SVGElements/pathelement.d.ts +53 -0
  25. package/dist/src/CellDL/SVGElements/rectilinearpath.d.ts +50 -0
  26. package/dist/src/CellDL/SVGElements/svgconnection.d.ts +22 -0
  27. package/dist/src/CellDL/celldlObjects/index.d.ts +151 -0
  28. package/dist/src/CellDL/components/index.d.ts +39 -0
  29. package/dist/src/CellDL/components/properties.d.ts +61 -0
  30. package/dist/src/CellDL/connections/index.d.ts +35 -0
  31. package/dist/src/CellDL/connections/pathmaker.d.ts +38 -0
  32. package/dist/src/CellDL/diagram/index.d.ts +45 -0
  33. package/dist/src/CellDL/editor/alerts.d.ts +27 -0
  34. package/dist/src/CellDL/editor/editguides.d.ts +31 -0
  35. package/dist/src/CellDL/editor/editorframe.d.ts +13 -0
  36. package/dist/src/CellDL/editor/index.d.ts +40 -0
  37. package/dist/src/CellDL/editor/panzoom.d.ts +30 -0
  38. package/dist/src/CellDL/editor/selectionbox.d.ts +17 -0
  39. package/dist/src/CellDL/editor/undoredo.d.ts +46 -0
  40. package/dist/src/CellDL/geometry/controls.d.ts +53 -0
  41. package/dist/src/CellDL/geometry/index.d.ts +92 -0
  42. package/dist/src/CellDL/geometry/intersections.d.ts +6 -0
  43. package/dist/src/CellDL/geometry/pathutils.d.ts +12 -0
  44. package/dist/src/CellDL/geometry/spatialindex.d.ts +22 -0
  45. package/dist/src/CellDL/geometry/transforms.d.ts +21 -0
  46. package/dist/src/CellDL/geometry/units.d.ts +23 -0
  47. package/dist/src/CellDL/utils.d.ts +6 -0
  48. package/dist/src/assets/oxigraph/web.d.ts +279 -0
  49. package/dist/src/common/EditorTypes.d.ts +39 -0
  50. package/dist/src/common/common.d.ts +7 -0
  51. package/dist/src/common/constants.d.ts +5 -0
  52. package/dist/src/common/points.d.ts +57 -0
  53. package/dist/src/common/styling.d.ts +36 -0
  54. package/dist/src/common/svgUtils.d.ts +48 -0
  55. package/dist/src/common/themeCssVariables.d.ts +9 -0
  56. package/dist/src/common/types.d.ts +23 -0
  57. package/dist/src/common/vueCommon.d.ts +9 -0
  58. package/dist/src/components/CellDLEditor.vue.d.ts +19 -0
  59. package/dist/src/components/WrappedEditor.vue.d.ts +19 -0
  60. package/dist/src/components/panels/FillStyle.vue.d.ts +20 -0
  61. package/dist/src/components/panels/PathStyle.vue.d.ts +20 -0
  62. package/dist/src/components/panels/PropertiesPanel.vue.d.ts +21 -0
  63. package/dist/src/components/popovers/ComponentPopover.vue.d.ts +19 -0
  64. package/dist/src/components/popovers/ConnectionStylePopover.vue.d.ts +19 -0
  65. package/dist/src/components/toolbar/EditorToolbar.vue.d.ts +23 -0
  66. package/dist/src/components/toolbar/ToolButton.vue.d.ts +26 -0
  67. package/dist/src/components/toolbar/ToolPanel.vue.d.ts +2 -0
  68. package/dist/src/components/toolbar/ToolPopover.vue.d.ts +3 -0
  69. package/dist/src/components/widgets/InputWidget.vue.d.ts +34 -0
  70. package/dist/src/libopencor/locUIJsonApi.d.ts +54 -0
  71. package/dist/src/mathjax/index.d.ts +2 -0
  72. package/dist/src/metadata/index.d.ts +50 -0
  73. package/dist/src/metadata/namespaces.d.ts +46 -0
  74. package/dist/src/metadata/oxigraphStore.d.ts +61 -0
  75. package/dist/src/metadata/oximock.d.ts +36 -0
  76. package/dist/src/metadata/store.d.ts +23 -0
  77. package/dist/src/plugins/bondgraph/definitions.d.ts +6 -0
  78. package/dist/src/plugins/bondgraph/index.d.ts +40 -0
  79. package/dist/src/plugins/bondgraph/utils.d.ts +27 -0
  80. package/dist/src/plugins/index.d.ts +75 -0
  81. package/dist/vite.config.d.ts +3 -0
  82. package/dist/vite.lib.config.d.ts +3 -0
  83. package/package.json +4 -3
  84. package/dist/CellDLEditor-CRG_Fjg2.js +0 -7262
  85. package/dist/CellDLEditor-CRG_Fjg2.js.map +0 -1
  86. package/dist/index-DtCZg5ZV.js.map +0 -1
  87. package/dist/vendor-DFPLRrnP.js.map +0 -1
@@ -0,0 +1,6 @@
1
+ import { Pair } from '../common/types';
2
+ export declare function sleep(ms: number): Promise<unknown>;
3
+ export declare function round(length: number, decimalPlaces?: number): number;
4
+ export declare function roundEqual(l1: number, l2: number, decimalPlaces?: number): boolean;
5
+ export declare function range(startOrStop: number, stop?: number | null, step?: number | null): Generator<number, void, unknown>;
6
+ export declare function pairwise<T>(a: T[]): Pair<T>[];
@@ -0,0 +1,279 @@
1
+ /* tslint:disable */
2
+ /* eslint-disable */
3
+
4
+ /**
5
+ * RDF/JS DataFactory-compatible methods
6
+ */
7
+ export function literal(value: string | undefined, languageOrDataType?: string | NamedNode | {language: string, direction?: "ltr" | "rtl"}): Literal;
8
+ export function quad(subject: Quad_Subject, predicate: Quad_Predicate, object: Quad_Object, graph?: Quad_Graph): Quad;
9
+
10
+ /**
11
+ * RDF/JS-compatible BlankNode term
12
+ */
13
+ export class BlankNode {
14
+ readonly termType: "BlankNode";
15
+ readonly value: string;
16
+
17
+ equals(other: Term | null | undefined): boolean;
18
+ toString(): string;
19
+ }
20
+
21
+ /**
22
+ * RDF/JS-compatible DefaultGraph term
23
+ */
24
+ export class DefaultGraph {
25
+ readonly termType: "DefaultGraph";
26
+ readonly value: "";
27
+
28
+ equals(other: Term | null | undefined): boolean;
29
+ toString(): string;
30
+ }
31
+
32
+ /**
33
+ * RDF/JS-compatible Literal term
34
+ */
35
+ export class Literal {
36
+ readonly datatype: NamedNode;
37
+ readonly language: string;
38
+ readonly direction: "ltr" | "rtl" | "";
39
+ readonly termType: "Literal";
40
+ readonly value: string;
41
+
42
+ equals(other: Term | null | undefined): boolean;
43
+ toString(): string;
44
+ }
45
+
46
+ /**
47
+ * RDF/JS-compatible BlankNode term
48
+ */
49
+ export class NamedNode {
50
+ readonly termType: "NamedNode";
51
+ readonly value: string;
52
+
53
+ equals(other: Term | null | undefined): boolean;
54
+ toString(): string;
55
+ }
56
+
57
+ /**
58
+ * BaseQuad is part of the RDF/JS spec and has no direct equivalent in Oxigraph.
59
+ *
60
+ * It's copied here from the RDF/JS reference types (https://github.com/rdfjs/types , MIT license) because:
61
+ * - RDF/JS DatasetCore's match method takes Term parameters.
62
+ * - RDF/JS's Term is defined in terms of BaseQuad and not Quad.
63
+ */
64
+ export interface BaseQuad {
65
+ readonly graph: Term;
66
+ readonly object: Term;
67
+ readonly predicate: Term;
68
+ readonly subject: Term;
69
+ readonly termType: "Quad";
70
+ readonly value: "";
71
+
72
+ equals(other: Term | null | undefined): boolean;
73
+ toString(): string;
74
+ }
75
+
76
+ /**
77
+ * RDF/JS-compatible Quad term
78
+ */
79
+ export class Quad implements BaseQuad {
80
+ readonly graph: Quad_Graph;
81
+ readonly object: Quad_Object;
82
+ readonly predicate: Quad_Predicate;
83
+ readonly subject: Quad_Subject;
84
+ readonly termType: "Quad";
85
+ readonly value: "";
86
+
87
+ equals(other: Term | null | undefined): boolean;
88
+ toString(): string;
89
+ }
90
+
91
+ /**
92
+ * Typedefs copied from the RDF/JS reference types (https://github.com/rdfjs/types)
93
+ */
94
+ export type Quad_Graph = DefaultGraph | NamedNode | BlankNode | Variable;
95
+ export type Quad_Object = NamedNode | Literal | BlankNode | Quad | Variable;
96
+ export type Quad_Predicate = NamedNode | Variable;
97
+ export type Quad_Subject = NamedNode | BlankNode | Quad | Variable;
98
+
99
+ /**
100
+ * RDF/JS-compatible Term typedef. See note above re: BaseQuad.
101
+ */
102
+ export type Term = NamedNode | BlankNode | Literal | Variable | DefaultGraph | BaseQuad;
103
+
104
+ /**
105
+ * RDF/JS-compatible Variable term
106
+ */
107
+ export class Variable {
108
+ readonly termType: "Variable";
109
+ readonly value: string;
110
+
111
+ equals(other: Term | null | undefined): boolean;
112
+ toString(): string;
113
+ }
114
+
115
+
116
+
117
+ export class Store {
118
+ readonly size: number;
119
+
120
+ constructor(quads?: Iterable<Quad>);
121
+
122
+ add(quad: Quad): void;
123
+
124
+ delete(quad: Quad): void;
125
+
126
+ dump(
127
+ options: {
128
+ format: string;
129
+ from_graph_name?: BlankNode | DefaultGraph | NamedNode;
130
+ }
131
+ ): string;
132
+
133
+ has(quad: Quad): boolean;
134
+
135
+ load(
136
+ data: string,
137
+ options: {
138
+ base_iri?: NamedNode | string;
139
+ format: string;
140
+ no_transaction?: boolean;
141
+ to_graph_name?: BlankNode | DefaultGraph | NamedNode;
142
+ unchecked?: boolean;
143
+ lenient?: boolean;
144
+ }
145
+ ): void;
146
+
147
+ match(subject?: Term | null, predicate?: Term | null, object?: Term | null, graph?: Term | null): Quad[];
148
+
149
+ query(
150
+ query: string,
151
+ options?: {
152
+ base_iri?: NamedNode | string;
153
+ results_format?: string;
154
+ default_graph?: BlankNode | DefaultGraph | NamedNode | Iterable<BlankNode | DefaultGraph | NamedNode>;
155
+ named_graphs?: Iterable<BlankNode | NamedNode>;
156
+ use_default_graph_as_union?: boolean;
157
+ }
158
+ ): boolean | Map<string, Term>[] | Quad[] | string;
159
+
160
+ update(
161
+ update: string,
162
+ options?: {
163
+ base_iri?: NamedNode | string;
164
+ }
165
+ ): void;
166
+ }
167
+
168
+
169
+
170
+ export function blankNode(value?: string | null): BlankNode;
171
+
172
+ export function defaultGraph(): DefaultGraph;
173
+
174
+ export function fromQuad(original: any): any;
175
+
176
+ export function fromTerm(original: any): any;
177
+
178
+ export function main(): void;
179
+
180
+ export function namedNode(value: string): NamedNode;
181
+
182
+ export function triple(subject: any, predicate: any, object: any): Quad;
183
+
184
+ export function variable(value: string): Variable;
185
+
186
+ export type InitInput = RequestInfo | URL | Response | BufferSource | WebAssembly.Module;
187
+
188
+ export interface InitOutput {
189
+ readonly memory: WebAssembly.Memory;
190
+ readonly __wbg_blanknode_free: (a: number, b: number) => void;
191
+ readonly __wbg_defaultgraph_free: (a: number, b: number) => void;
192
+ readonly __wbg_literal_free: (a: number, b: number) => void;
193
+ readonly __wbg_namednode_free: (a: number, b: number) => void;
194
+ readonly __wbg_quad_free: (a: number, b: number) => void;
195
+ readonly __wbg_store_free: (a: number, b: number) => void;
196
+ readonly blankNode: (a: number, b: number) => [number, number, number];
197
+ readonly blanknode_equals: (a: number, b: any) => number;
198
+ readonly blanknode_term_type: (a: number) => [number, number];
199
+ readonly blanknode_toString: (a: number) => [number, number];
200
+ readonly blanknode_value: (a: number) => [number, number];
201
+ readonly defaultGraph: () => number;
202
+ readonly defaultgraph_equals: (a: number, b: any) => number;
203
+ readonly defaultgraph_term_type: (a: number) => [number, number];
204
+ readonly defaultgraph_toString: (a: number) => [number, number];
205
+ readonly defaultgraph_value: (a: number) => [number, number];
206
+ readonly fromQuad: (a: any) => [number, number, number];
207
+ readonly fromTerm: (a: any) => [number, number, number];
208
+ readonly literal: (a: number, b: number, c: any) => [number, number, number];
209
+ readonly literal_datatype: (a: number) => number;
210
+ readonly literal_direction: (a: number) => [number, number];
211
+ readonly literal_equals: (a: number, b: any) => number;
212
+ readonly literal_language: (a: number) => [number, number];
213
+ readonly literal_term_type: (a: number) => [number, number];
214
+ readonly literal_toString: (a: number) => [number, number];
215
+ readonly literal_value: (a: number) => [number, number];
216
+ readonly main: () => void;
217
+ readonly namedNode: (a: number, b: number) => [number, number, number];
218
+ readonly namednode_equals: (a: number, b: any) => number;
219
+ readonly namednode_term_type: (a: number) => [number, number];
220
+ readonly namednode_toString: (a: number) => [number, number];
221
+ readonly namednode_value: (a: number) => [number, number];
222
+ readonly quad: (a: any, b: any, c: any, d: any) => [number, number, number];
223
+ readonly quad_equals: (a: number, b: any) => number;
224
+ readonly quad_graph: (a: number) => any;
225
+ readonly quad_object: (a: number) => any;
226
+ readonly quad_predicate: (a: number) => any;
227
+ readonly quad_subject: (a: number) => any;
228
+ readonly quad_term_type: (a: number) => [number, number];
229
+ readonly quad_toString: (a: number) => [number, number];
230
+ readonly quad_value: (a: number) => [number, number];
231
+ readonly store_add: (a: number, b: any) => [number, number];
232
+ readonly store_delete: (a: number, b: any) => [number, number];
233
+ readonly store_dump: (a: number, b: any, c: any) => [number, number, number, number];
234
+ readonly store_has: (a: number, b: any) => [number, number, number];
235
+ readonly store_load: (a: number, b: number, c: number, d: any, e: any, f: any) => [number, number];
236
+ readonly store_match: (a: number, b: any, c: any, d: any, e: any) => [number, number, number, number];
237
+ readonly store_new: (a: any) => [number, number, number];
238
+ readonly store_query: (a: number, b: number, c: number, d: any) => [number, number, number];
239
+ readonly store_size: (a: number) => [number, number, number];
240
+ readonly store_update: (a: number, b: number, c: number, d: any) => [number, number];
241
+ readonly triple: (a: any, b: any, c: any) => [number, number, number];
242
+ readonly variable: (a: number, b: number) => [number, number, number];
243
+ readonly variable_equals: (a: number, b: any) => number;
244
+ readonly variable_term_type: (a: number) => [number, number];
245
+ readonly variable_toString: (a: number) => [number, number];
246
+ readonly variable_value: (a: number) => [number, number];
247
+ readonly __wbg_variable_free: (a: number, b: number) => void;
248
+ readonly __wbindgen_malloc: (a: number, b: number) => number;
249
+ readonly __wbindgen_realloc: (a: number, b: number, c: number, d: number) => number;
250
+ readonly __wbindgen_exn_store: (a: number) => void;
251
+ readonly __externref_table_alloc: () => number;
252
+ readonly __wbindgen_externrefs: WebAssembly.Table;
253
+ readonly __wbindgen_free: (a: number, b: number, c: number) => void;
254
+ readonly __externref_table_dealloc: (a: number) => void;
255
+ readonly __externref_drop_slice: (a: number, b: number) => void;
256
+ readonly __wbindgen_start: () => void;
257
+ }
258
+
259
+ export type SyncInitInput = BufferSource | WebAssembly.Module;
260
+
261
+ /**
262
+ * Instantiates the given `module`, which can either be bytes or
263
+ * a precompiled `WebAssembly.Module`.
264
+ *
265
+ * @param {{ module: SyncInitInput }} module - Passing `SyncInitInput` directly is deprecated.
266
+ *
267
+ * @returns {InitOutput}
268
+ */
269
+ export function initSync(module: { module: SyncInitInput } | SyncInitInput): InitOutput;
270
+
271
+ /**
272
+ * If `module_or_path` is {RequestInfo} or {URL}, makes a request and
273
+ * for everything else, calls `WebAssembly.instantiate` directly.
274
+ *
275
+ * @param {{ module_or_path: InitInput | Promise<InitInput> }} module_or_path - Passing `InitInput` directly is deprecated.
276
+ *
277
+ * @returns {Promise<InitOutput>}
278
+ */
279
+ export default function __wbg_init (module_or_path?: { module_or_path: InitInput | Promise<InitInput> } | InitInput | Promise<InitInput>): Promise<InitOutput>;
@@ -0,0 +1,39 @@
1
+ /******************************************************************************
2
+
3
+ CellDL Editor
4
+
5
+ Copyright (c) 2022 - 2025 David Brooks
6
+
7
+ Licensed under the Apache License, Version 2.0 (the "License");
8
+ you may not use this file except in compliance with the License.
9
+ You may obtain a copy of the License at
10
+
11
+ http://www.apache.org/licenses/LICENSE-2.0
12
+
13
+ Unless required by applicable law or agreed to in writing, software
14
+ distributed under the License is distributed on an "AS IS" BASIS,
15
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
16
+ See the License for the specific language governing permissions and
17
+ limitations under the License.
18
+
19
+ ******************************************************************************/
20
+ import type * as vue from 'vue';
21
+ export interface EditorToolButton {
22
+ toolId: string;
23
+ active?: boolean;
24
+ prompt: string;
25
+ icon?: string;
26
+ image?: string;
27
+ panel?: vue.Raw<vue.Component>;
28
+ }
29
+ export interface EditorState {
30
+ fileModified?: boolean;
31
+ itemSelected?: boolean;
32
+ pasteContents?: boolean;
33
+ redoContents?: boolean;
34
+ }
35
+ export interface ViewState {
36
+ showGrid?: boolean;
37
+ gridSpacing?: number;
38
+ snapToGrid?: number;
39
+ }
@@ -0,0 +1,7 @@
1
+ export declare function isWindows(): boolean;
2
+ export declare function isLinux(): boolean;
3
+ export declare function isMacOs(): boolean;
4
+ export declare function isDesktop(): boolean;
5
+ export declare function isCtrlOrCmd(event: KeyboardEvent): boolean;
6
+ export declare function formatTime(time: number): string;
7
+ export declare function formatIssue(issue: string): string;
@@ -0,0 +1,5 @@
1
+ export declare const SHORT_DELAY: number;
2
+ export declare const MEDIUM_DELAY: number;
3
+ export declare const LONG_DELAY: number;
4
+ export declare const TOAST_LIFE: number;
5
+ export declare const COPYRIGHT: string;
@@ -0,0 +1,57 @@
1
+ /******************************************************************************
2
+
3
+ CellDL Editor
4
+
5
+ Copyright (c) 2022 - 2025 David Brooks
6
+
7
+ Licensed under the Apache License, Version 2.0 (the "License");
8
+ you may not use this file except in compliance with the License.
9
+ You may obtain a copy of the License at
10
+
11
+ http://www.apache.org/licenses/LICENSE-2.0
12
+
13
+ Unless required by applicable law or agreed to in writing, software
14
+ distributed under the License is distributed on an "AS IS" BASIS,
15
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
16
+ See the License for the specific language governing permissions and
17
+ limitations under the License.
18
+
19
+ ******************************************************************************/
20
+ export interface PointLike {
21
+ x: number;
22
+ y: number;
23
+ }
24
+ export type PointArray = [number, number];
25
+ export declare const POINT_EPSILON = 0.0001;
26
+ export declare const POINT_EPSILON_SQUARED: number;
27
+ export declare class Point implements PointLike {
28
+ readonly x: number;
29
+ readonly y: number;
30
+ constructor(x?: number, y?: number);
31
+ static fromPoint(point: PointLike): Point;
32
+ static fromArray(coords: PointArray): Point;
33
+ asArray(): PointArray;
34
+ add(point: PointLike): Point;
35
+ colinear(p1: PointLike, p2: PointLike, between?: boolean): boolean;
36
+ copy(): Point;
37
+ distance(point: PointLike): number;
38
+ equals(point: PointLike): boolean;
39
+ isZero(): boolean;
40
+ apply(fn: (n: number) => number): Point;
41
+ scalarScale(scale: number): Point;
42
+ scale(scale: PointLike): Point;
43
+ snapTo(point: PointLike, snapDistance?: number): Point;
44
+ subtract(point: PointLike): Point;
45
+ toString(): string;
46
+ }
47
+ export declare class PointMath {
48
+ static add(p1: PointLike, p2: PointLike): Point;
49
+ static apply(p1: PointLike, fn: (number: number) => number): Point;
50
+ static colinear(p0: PointLike, p1: PointLike, p2: PointLike, between?: boolean): boolean;
51
+ static distance(p1: PointLike, p2: PointLike): number;
52
+ static equals(p1: PointLike, p2: PointLike): boolean;
53
+ static isZero(pt: PointLike): boolean;
54
+ static scalarScale(p1: PointLike, scale: number): Point;
55
+ static scale(p1: PointLike, scale: PointLike): Point;
56
+ static subtract(p1: PointLike, p2: PointLike): Point;
57
+ }
@@ -0,0 +1,36 @@
1
+ /******************************************************************************
2
+
3
+ CellDL Editor
4
+
5
+ Copyright (c) 2022 - 2025 David Brooks
6
+
7
+ Licensed under the Apache License, Version 2.0 (the "License");
8
+ you may not use this file except in compliance with the License.
9
+ You may obtain a copy of the License at
10
+
11
+ http://www.apache.org/licenses/LICENSE-2.0
12
+
13
+ Unless required by applicable law or agreed to in writing, software
14
+ distributed under the License is distributed on an "AS IS" BASIS,
15
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
16
+ See the License for the specific language governing permissions and
17
+ limitations under the License.
18
+
19
+ ******************************************************************************/
20
+ export declare const CONNECTION_ARROW_SIZE: number[];
21
+ export declare const CONNECTION_SPLAY_PADDING = 16;
22
+ export declare const MAX_CONNECTION_SPLAY_PADDING = 20;
23
+ export declare const CONNECTION_COLOUR = "#567";
24
+ export declare const OLD_CONNECTION_COLOUR = "#334155";
25
+ export declare const CONNECTION_WIDTH = 2;
26
+ export declare const CONNECTION_DASH = 2;
27
+ export declare const INTERFACE_PORT_RADIUS = 4;
28
+ export declare const SELECTION_STROKE_WIDTH = 3;
29
+ export declare const CELLDL_BACKGROUND_CLASS = "celldl-background";
30
+ export declare function arrowMarkerDefinition(markerId: string, markerType: string): string;
31
+ export type GradientStop = {
32
+ offset: string;
33
+ colour: string;
34
+ };
35
+ export declare function gradientDefinition(type: string, gradientId: string, stops: GradientStop[]): string;
36
+ export declare const CellDLStylesheet: string;
@@ -0,0 +1,48 @@
1
+ import { PointLike } from './points';
2
+ import { StringProperties } from './types';
3
+ import { Extent } from '../CellDL/geometry/index';
4
+ export declare const SVG_URI = "http://www.w3.org/2000/svg";
5
+ export interface INodeStyle {
6
+ gradientFill: boolean;
7
+ colours: string[];
8
+ direction?: string;
9
+ }
10
+ export interface IPathStyle {
11
+ colour: string;
12
+ width: number;
13
+ dashed: boolean;
14
+ }
15
+ export interface LatexMathSvgOptions {
16
+ background?: string | string[];
17
+ border?: string;
18
+ 'border-width'?: string;
19
+ class?: string;
20
+ 'corner-radius'?: string;
21
+ 'middle-colour'?: string;
22
+ 'min-height'?: string;
23
+ 'min-width'?: string;
24
+ padding?: string;
25
+ 'vertical-align'?: string;
26
+ }
27
+ export declare function svgSize(svgDocument: Document): PointLike | null;
28
+ export declare function getViewbox(svgElement: SVGGraphicsElement): Extent;
29
+ type Attributes = StringProperties;
30
+ export declare function createSVGElement(tagName: string, attributes: Attributes): SVGElement;
31
+ export declare function svgCircle(centre: PointLike, radius: number, attributes?: Attributes): string;
32
+ export declare function svgCircleElement(centre: PointLike, radius: number, attributes?: Attributes): SVGCircleElement;
33
+ export declare function svgPath(points: PointLike[], attributes?: Attributes): string;
34
+ export declare function svgPathDescription(points: PointLike[]): string;
35
+ export declare function svgPathElement(points: PointLike[], attributes?: Attributes): SVGPathElement;
36
+ export declare function svgRect(topLeft: PointLike, bottomRight: PointLike, attributes?: Attributes): string;
37
+ export declare function svgRectElement(topLeft: PointLike, bottomRight: PointLike, attributes?: StringProperties): SVGRectElement;
38
+ export declare const LatexStyleRules: string;
39
+ export declare class LatexMathSvg {
40
+ #private;
41
+ static svgRect(latex: string, suffix?: string, options?: LatexMathSvgOptions): string;
42
+ }
43
+ export declare function base64Svg(svg: string): string;
44
+ export declare function getSvgImageFromBase64(svgText: string): string | undefined;
45
+ export declare function getSvgFillStyle(svgText: string): string[];
46
+ export declare function getSvgPathStyle(svgElement: SVGGraphicsElement): IPathStyle;
47
+ export declare function setSvgPathStyle(svgElement: SVGGraphicsElement, pathStyle: IPathStyle): void;
48
+ export {};
@@ -0,0 +1,9 @@
1
+ /**
2
+ * Composable utility for injecting PrimeVue theme CSS variables into the DOM.
3
+ *
4
+ * Ex https://github.com/CellDL/CellDLEditor/pull/4/changes from https://github.com/akhuoa
5
+ */
6
+ /**
7
+ * @param componentName The key name in the preset (e.g., 'card', 'button', 'select')
8
+ */
9
+ export declare function useThemeCssVariables(componentName: string): void;
@@ -0,0 +1,23 @@
1
+ /******************************************************************************
2
+
3
+ CellDL Editor
4
+
5
+ Copyright (c) 2022 - 2025 David Brooks
6
+
7
+ Licensed under the Apache License, Version 2.0 (the "License");
8
+ you may not use this file except in compliance with the License.
9
+ You may obtain a copy of the License at
10
+
11
+ http://www.apache.org/licenses/LICENSE-2.0
12
+
13
+ Unless required by applicable law or agreed to in writing, software
14
+ distributed under the License is distributed on an "AS IS" BASIS,
15
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
16
+ See the License for the specific language governing permissions and
17
+ limitations under the License.
18
+
19
+ ******************************************************************************/
20
+ export type Constructor<T> = new (...args: any[]) => T;
21
+ export type Pair<T> = [T, T];
22
+ export type PropertiesType = Record<string, string | number | boolean>;
23
+ export type StringProperties = Record<string, string>;
@@ -0,0 +1,9 @@
1
+ import { Theme } from '../../index.ts';
2
+ import * as vue from 'vue';
3
+ export declare const activeInstanceUid: () => vue.Ref<string | null>;
4
+ export declare const useTheme: () => {
5
+ theme: () => Theme;
6
+ setTheme: (newTheme: Theme | undefined) => void;
7
+ useLightMode: () => boolean;
8
+ useDarkMode: () => boolean;
9
+ };
@@ -0,0 +1,19 @@
1
+ import { CellDLEditorProps, EditorData } from '../../index';
2
+ import * as vue from 'vue';
3
+ declare const _default: vue.DefineComponent<__VLS_TypePropsToOption<CellDLEditorProps>, {}, unknown, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin, {
4
+ error: (msg: string) => void;
5
+ "editor-data": (data: EditorData) => void;
6
+ }, string, vue.PublicProps, Readonly<vue.ExtractPropTypes<__VLS_TypePropsToOption<CellDLEditorProps>>> & {
7
+ onError?: ((msg: string) => any) | undefined;
8
+ "onEditor-data"?: ((data: EditorData) => any) | undefined;
9
+ }, {}, {}>;
10
+ export default _default;
11
+ type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
12
+ type __VLS_TypePropsToOption<T> = {
13
+ [K in keyof T]-?: {} extends Pick<T, K> ? {
14
+ type: import('vue').PropType<__VLS_NonUndefinedable<T[K]>>;
15
+ } : {
16
+ type: import('vue').PropType<T[K]>;
17
+ required: true;
18
+ };
19
+ };
@@ -0,0 +1,19 @@
1
+ import { CellDLEditorProps, EditorData } from '../../index';
2
+ import * as vue from 'vue';
3
+ declare const _default: vue.DefineComponent<__VLS_TypePropsToOption<CellDLEditorProps>, {}, unknown, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin, {
4
+ error: (msg: string) => void;
5
+ "editor-data": (data: EditorData) => void;
6
+ }, string, vue.PublicProps, Readonly<vue.ExtractPropTypes<__VLS_TypePropsToOption<CellDLEditorProps>>> & {
7
+ onError?: ((msg: string) => any) | undefined;
8
+ "onEditor-data"?: ((data: EditorData) => any) | undefined;
9
+ }, {}, {}>;
10
+ export default _default;
11
+ type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
12
+ type __VLS_TypePropsToOption<T> = {
13
+ [K in keyof T]-?: {} extends Pick<T, K> ? {
14
+ type: import('vue').PropType<__VLS_NonUndefinedable<T[K]>>;
15
+ } : {
16
+ type: import('vue').PropType<T[K]>;
17
+ required: true;
18
+ };
19
+ };
@@ -0,0 +1,20 @@
1
+ import { INodeStyle } from '../../common/svgUtils';
2
+ import * as vue from 'vue';
3
+ type __VLS_Props = {
4
+ fillStyle: INodeStyle;
5
+ };
6
+ declare const _default: vue.DefineComponent<__VLS_TypePropsToOption<__VLS_Props>, {}, unknown, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin, {
7
+ change: (...args: any[]) => void;
8
+ }, string, vue.PublicProps, Readonly<vue.ExtractPropTypes<__VLS_TypePropsToOption<__VLS_Props>>> & {
9
+ onChange?: ((...args: any[]) => any) | undefined;
10
+ }, {}, {}>;
11
+ export default _default;
12
+ type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
13
+ type __VLS_TypePropsToOption<T> = {
14
+ [K in keyof T]-?: {} extends Pick<T, K> ? {
15
+ type: import('vue').PropType<__VLS_NonUndefinedable<T[K]>>;
16
+ } : {
17
+ type: import('vue').PropType<T[K]>;
18
+ required: true;
19
+ };
20
+ };
@@ -0,0 +1,20 @@
1
+ import { IPathStyle } from '../../common/svgUtils';
2
+ import * as vue from 'vue';
3
+ type __VLS_Props = {
4
+ pathStyle: IPathStyle;
5
+ };
6
+ declare const _default: vue.DefineComponent<__VLS_TypePropsToOption<__VLS_Props>, {}, unknown, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin, {
7
+ change: (...args: any[]) => void;
8
+ }, string, vue.PublicProps, Readonly<vue.ExtractPropTypes<__VLS_TypePropsToOption<__VLS_Props>>> & {
9
+ onChange?: ((...args: any[]) => any) | undefined;
10
+ }, {}, {}>;
11
+ export default _default;
12
+ type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
13
+ type __VLS_TypePropsToOption<T> = {
14
+ [K in keyof T]-?: {} extends Pick<T, K> ? {
15
+ type: import('vue').PropType<__VLS_NonUndefinedable<T[K]>>;
16
+ } : {
17
+ type: import('vue').PropType<T[K]>;
18
+ required: true;
19
+ };
20
+ };
@@ -0,0 +1,21 @@
1
+ import * as vue from 'vue';
2
+ type __VLS_Props = {
3
+ toolId: string;
4
+ };
5
+ declare const _default: vue.DefineComponent<__VLS_TypePropsToOption<__VLS_Props>, {}, unknown, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin, {
6
+ "panel-event": (...args: any[]) => void;
7
+ "style-event": (...args: any[]) => void;
8
+ }, string, vue.PublicProps, Readonly<vue.ExtractPropTypes<__VLS_TypePropsToOption<__VLS_Props>>> & {
9
+ "onPanel-event"?: ((...args: any[]) => any) | undefined;
10
+ "onStyle-event"?: ((...args: any[]) => any) | undefined;
11
+ }, {}, {}>;
12
+ export default _default;
13
+ type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
14
+ type __VLS_TypePropsToOption<T> = {
15
+ [K in keyof T]-?: {} extends Pick<T, K> ? {
16
+ type: import('vue').PropType<__VLS_NonUndefinedable<T[K]>>;
17
+ } : {
18
+ type: import('vue').PropType<T[K]>;
19
+ required: true;
20
+ };
21
+ };
@@ -0,0 +1,19 @@
1
+ import * as vue from 'vue';
2
+ type __VLS_Props = {
3
+ toolId: string;
4
+ };
5
+ declare const _default: vue.DefineComponent<__VLS_TypePropsToOption<__VLS_Props>, {}, unknown, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin, {
6
+ "popover-event": (...args: any[]) => void;
7
+ }, string, vue.PublicProps, Readonly<vue.ExtractPropTypes<__VLS_TypePropsToOption<__VLS_Props>>> & {
8
+ "onPopover-event"?: ((...args: any[]) => any) | undefined;
9
+ }, {}, {}>;
10
+ export default _default;
11
+ type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
12
+ type __VLS_TypePropsToOption<T> = {
13
+ [K in keyof T]-?: {} extends Pick<T, K> ? {
14
+ type: import('vue').PropType<__VLS_NonUndefinedable<T[K]>>;
15
+ } : {
16
+ type: import('vue').PropType<T[K]>;
17
+ required: true;
18
+ };
19
+ };