@draftably/editor 0.1.0 → 0.2.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.
- package/README.md +4 -5
- package/dist/assets/{engine.worker-DmHew5f6.js → engine.worker-DwN9io_m.js} +2765 -2722
- package/dist/element.js +1 -1
- package/dist/index.js +19553 -2
- package/dist/types/src/components/controls.d.ts +8 -5
- package/dist/types/src/state/canvas-commands.d.ts +169 -0
- package/dist/types/src/state/canvas-keyboard.d.ts +15 -0
- package/dist/types/src/state/links.d.ts +4 -1
- package/dist/types/src/state/workspace.d.ts +3 -0
- package/package.json +1 -1
- package/dist/assets/import-d2.worker-CnXfFXoa.js +0 -5395
- package/dist/chunks/abnfDiagram-WEYOIA3C-llcpthp5.js +0 -87
- package/dist/chunks/arc-rJj0TtXf.js +0 -83
- package/dist/chunks/architectureDiagram-ZHVYKT53-CfiXg0Lk.js +0 -4781
- package/dist/chunks/blockDiagram-RJAE7QA3-CO-14jWz.js +0 -1440
- package/dist/chunks/browser-iNhbPsGc.js +0 -40
- package/dist/chunks/c4Diagram-XDPPPE54-DYKuxA4n.js +0 -1524
- package/dist/chunks/channel-qMvPU6eH.js +0 -5
- package/dist/chunks/chunk-2E7WHVMD-BEZwsFS3.js +0 -670
- package/dist/chunks/chunk-2Q5K7J3B-gqtzQ8ux.js +0 -18
- package/dist/chunks/chunk-4EMNKR2T-MC54CXVe.js +0 -262
- package/dist/chunks/chunk-55XCU76K-DkZUAaqC.js +0 -68
- package/dist/chunks/chunk-5VM5RSS4-CaKe4sjM.js +0 -19
- package/dist/chunks/chunk-JWPE2WC7-CnAFS2xF.js +0 -8
- package/dist/chunks/chunk-VQ5W62QI-CXRv7FiX.js +0 -19
- package/dist/chunks/chunk-XXDRQBXY-B-AMQgD2.js +0 -8
- package/dist/chunks/chunk-ZCHMQSOR-BALpdc3g.js +0 -451
- package/dist/chunks/classDiagram-v2-4MYWR3UA-wPjgJTg4.js +0 -1570
- package/dist/chunks/cose-bilkent-JH36ORCC-Bbh5ggBc.js +0 -2608
- package/dist/chunks/cynefin-EF2NZ3EQ-Bt6b88hY.js +0 -22361
- package/dist/chunks/cynefinDiagram-WF24UDRP-BHWZvxoF.js +0 -299
- package/dist/chunks/cytoscape.esm-CRsF_JA3.js +0 -18791
- package/dist/chunks/dagre-NK4GIZVX-Cz37yPrT.js +0 -2157
- package/dist/chunks/defaultLocale-BgPVtth8.js +0 -171
- package/dist/chunks/diagram-CBK3MWTC-Q2R6FJ0B.js +0 -531
- package/dist/chunks/diagram-I5XIIV2D-a2Kdu_wA.js +0 -153
- package/dist/chunks/diagram-ODIL2UCW-DTWXxcOn.js +0 -346
- package/dist/chunks/diagram-PFBEJUXE-DIAQQ5KX.js +0 -480
- package/dist/chunks/diagram-RJA3I4VV-BPD0GghS.js +0 -219
- package/dist/chunks/diagram-TYUNFSNR-BmdkONfG.js +0 -2586
- package/dist/chunks/dot-importer-B23jwEkx.js +0 -1547
- package/dist/chunks/ebnfDiagram-V4P3TTPT-C5IKvYlb.js +0 -109
- package/dist/chunks/elk-QONTBCTQ-CtdQFvh2.js +0 -49229
- package/dist/chunks/erDiagram-KYQIGQAA-5wguK9Dx.js +0 -1064
- package/dist/chunks/flowDiagram-IUGLLWBU-BijvFPku.js +0 -1771
- package/dist/chunks/ganttDiagram-R7GPNTJY-BaqGPz-O.js +0 -2729
- package/dist/chunks/gitGraphDiagram-PDYL7XHY-DZfMGyHE.js +0 -815
- package/dist/chunks/graph-CKJmgLki.js +0 -1541
- package/dist/chunks/import-core-C-I1wGfw.js +0 -145
- package/dist/chunks/infoDiagram-MVDRKAX5-C2vH_59e.js +0 -24
- package/dist/chunks/init-DjUOC4st.js +0 -16
- package/dist/chunks/ishikawaDiagram-HPEHV2GE-q149MFlV.js +0 -624
- package/dist/chunks/journeyDiagram-BOSHW7O7-D-2Z3VtR.js +0 -834
- package/dist/chunks/kanban-definition-FNSA4HC5-wvAjV5ub.js +0 -724
- package/dist/chunks/katex-BsrBVQKd.js +0 -11314
- package/dist/chunks/linear-4t7D_ros.js +0 -259
- package/dist/chunks/mermaid-facade-BoLWBerE.js +0 -289
- package/dist/chunks/mermaid-importer-Cgx1IhmR.js +0 -478
- package/dist/chunks/mermaid.core-DXv6D2Sm.js +0 -19244
- package/dist/chunks/mindmap-definition-6OY57UG3-r9wTKul_.js +0 -837
- package/dist/chunks/mount-C1Xk_GQz.js +0 -22131
- package/dist/chunks/ordinal-DfAQgscy.js +0 -61
- package/dist/chunks/pegDiagram-ECIUJNBX-CmKlFWiP.js +0 -95
- package/dist/chunks/pieDiagram-GNMPY74T-DNTw_qan.js +0 -208
- package/dist/chunks/quadrantDiagram-D57K4MC3-CT_tvVub.js +0 -1029
- package/dist/chunks/railroadDiagram-Y72NRBL7-C5TUvZBe.js +0 -77
- package/dist/chunks/requirementDiagram-EQYSW5RA-C_c65aCa.js +0 -889
- package/dist/chunks/sankeyDiagram-SY24JHO5-CKcbizM1.js +0 -859
- package/dist/chunks/sequenceDiagram-BLEHNHQU-GpVnHOjf.js +0 -2972
- package/dist/chunks/sizeCapture-INFHLROL-CToN3JSu.js +0 -46
- package/dist/chunks/stateDiagram-v2-A6IESKWZ-rJYd2FfM.js +0 -1520
- package/dist/chunks/swimlanes-B3ENRKFQ-C7w5pfxG.js +0 -4991
- package/dist/chunks/swimlanesDiagram-AYQRV4AK-BpGY_bvE.js +0 -13
- package/dist/chunks/timeline-definition-JXYKGLGB-ChKFPBKc.js +0 -1058
- package/dist/chunks/usecaseDiagram-WPOLBNNX-skXH8Dcu.js +0 -7945
- package/dist/chunks/vennDiagram-Q3Y3IDCW-C5KknmJf.js +0 -1578
- package/dist/chunks/wardleyDiagram-IVAIDKWA-DY4Lkfpu.js +0 -678
- package/dist/chunks/xychartDiagram-4URNHDU4-BHScsL7h.js +0 -1536
- package/dist/types/src/import/browser.d.ts +0 -3
- package/dist/types/src/import/detect.d.ts +0 -31
- package/dist/types/src/import/dot-importer.d.ts +0 -3
- package/dist/types/src/import/import-core.d.ts +0 -105
- package/dist/types/src/import/mermaid-facade.d.ts +0 -120
- package/dist/types/src/import/mermaid-importer.d.ts +0 -4
- package/dist/types/src/import/mermaid-sequence.d.ts +0 -8
- package/dist/types/src/import/scratch.d.ts +0 -3
- package/dist/types/src/lib/source-hash.d.ts +0 -7
- package/dist/types/src/model/candidates.d.ts +0 -53
- package/dist/types/src/model/examples.d.ts +0 -15
- package/dist/types/src/model/label-hits.d.ts +0 -27
- package/dist/types/src/model/static-scene.d.ts +0 -15
- package/dist/types/src/state/commands.d.ts +0 -529
- package/dist/types/src/state/comparison.d.ts +0 -151
- package/dist/types/src/state/files.d.ts +0 -61
- package/dist/types/src/state/keyboard.d.ts +0 -6
- package/dist/types/src/state/launch.d.ts +0 -61
- package/dist/types/src/state/ui.d.ts +0 -39
|
@@ -1,109 +0,0 @@
|
|
|
1
|
-
import { g as l, r as m, d as n } from "./chunk-2E7WHVMD-BEZwsFS3.js";
|
|
2
|
-
import { p } from "./chunk-JWPE2WC7-CnAFS2xF.js";
|
|
3
|
-
import { _ as t, l as o } from "./mermaid.core-DXv6D2Sm.js";
|
|
4
|
-
import { M as u, a as f } from "./cynefin-EF2NZ3EQ-Bt6b88hY.js";
|
|
5
|
-
var c = f().RailroadEbnf.parser.LangiumParser, s = /* @__PURE__ */ t((e) => {
|
|
6
|
-
const r = e.alternatives.map(E);
|
|
7
|
-
return r.length === 1 ? r[0] : {
|
|
8
|
-
type: "choice",
|
|
9
|
-
alternatives: r
|
|
10
|
-
};
|
|
11
|
-
}, "transformChoice"), E = /* @__PURE__ */ t((e) => {
|
|
12
|
-
const r = e.elements.map(d);
|
|
13
|
-
return r.length === 1 ? r[0] : {
|
|
14
|
-
type: "sequence",
|
|
15
|
-
elements: r
|
|
16
|
-
};
|
|
17
|
-
}, "transformSequence"), i = /* @__PURE__ */ t((e) => {
|
|
18
|
-
switch (e.$type) {
|
|
19
|
-
case "EbnfTerminal":
|
|
20
|
-
return {
|
|
21
|
-
type: "terminal",
|
|
22
|
-
value: e.value
|
|
23
|
-
};
|
|
24
|
-
case "EbnfNonTerminal":
|
|
25
|
-
return {
|
|
26
|
-
type: "nonterminal",
|
|
27
|
-
name: e.name
|
|
28
|
-
};
|
|
29
|
-
case "EbnfSpecial":
|
|
30
|
-
return {
|
|
31
|
-
type: "special",
|
|
32
|
-
text: e.text
|
|
33
|
-
};
|
|
34
|
-
case "EbnfGroup":
|
|
35
|
-
return s(e.element);
|
|
36
|
-
case "EbnfOptional":
|
|
37
|
-
return {
|
|
38
|
-
type: "optional",
|
|
39
|
-
element: s(e.element)
|
|
40
|
-
};
|
|
41
|
-
case "EbnfRepetition":
|
|
42
|
-
return {
|
|
43
|
-
type: "repetition",
|
|
44
|
-
element: s(e.element),
|
|
45
|
-
min: 0,
|
|
46
|
-
max: 1 / 0
|
|
47
|
-
};
|
|
48
|
-
default:
|
|
49
|
-
throw new Error(`Unsupported EBNF primary node: ${e.$type}`);
|
|
50
|
-
}
|
|
51
|
-
}, "transformPrimary"), b = /* @__PURE__ */ t((e, r) => {
|
|
52
|
-
switch (r.$type) {
|
|
53
|
-
case "EbnfOptionalPostfix":
|
|
54
|
-
return {
|
|
55
|
-
type: "optional",
|
|
56
|
-
element: e
|
|
57
|
-
};
|
|
58
|
-
case "EbnfZeroOrMorePostfix":
|
|
59
|
-
return {
|
|
60
|
-
type: "repetition",
|
|
61
|
-
element: e,
|
|
62
|
-
min: 0,
|
|
63
|
-
max: 1 / 0
|
|
64
|
-
};
|
|
65
|
-
case "EbnfOneOrMorePostfix":
|
|
66
|
-
return {
|
|
67
|
-
type: "repetition",
|
|
68
|
-
element: e,
|
|
69
|
-
min: 1,
|
|
70
|
-
max: 1 / 0
|
|
71
|
-
};
|
|
72
|
-
case "EbnfExceptionPostfix":
|
|
73
|
-
return {
|
|
74
|
-
type: "sequence",
|
|
75
|
-
elements: [
|
|
76
|
-
e,
|
|
77
|
-
{ type: "terminal", value: "-" },
|
|
78
|
-
i(r.except)
|
|
79
|
-
]
|
|
80
|
-
};
|
|
81
|
-
default:
|
|
82
|
-
throw new Error(`Unsupported EBNF postfix node: ${r.$type}`);
|
|
83
|
-
}
|
|
84
|
-
}, "transformPostfix"), d = /* @__PURE__ */ t((e) => e.postfixes.reduce((r, a) => b(r, a), i(e.base)), "transformTerm"), y = /* @__PURE__ */ t((e) => ({
|
|
85
|
-
name: e.name,
|
|
86
|
-
definition: s(e.definition)
|
|
87
|
-
}), "transformRule"), v = /* @__PURE__ */ t((e) => {
|
|
88
|
-
p(e, n), e.title && n.setTitle(e.title), e.rules.map((r) => n.addRule(y(r)));
|
|
89
|
-
}, "populateDb"), g = {
|
|
90
|
-
parse: /* @__PURE__ */ t((e) => {
|
|
91
|
-
n.clear(), o.debug("[EBNF Parser] Starting Langium parse");
|
|
92
|
-
const r = c.parse(e);
|
|
93
|
-
if (r.lexerErrors.length > 0 || r.parserErrors.length > 0)
|
|
94
|
-
throw new u(r);
|
|
95
|
-
const a = r.value;
|
|
96
|
-
o.debug("[EBNF Parser] Parsed rules:", a.rules.length), v(a), o.debug("[EBNF Parser] Parse complete");
|
|
97
|
-
}, "parse"),
|
|
98
|
-
parser: {
|
|
99
|
-
yy: n
|
|
100
|
-
}
|
|
101
|
-
}, N = {
|
|
102
|
-
parser: g,
|
|
103
|
-
db: n,
|
|
104
|
-
renderer: m,
|
|
105
|
-
styles: l
|
|
106
|
-
};
|
|
107
|
-
export {
|
|
108
|
-
N as diagram
|
|
109
|
-
};
|