@loopstack/loopstack-studio 0.25.0 → 0.25.2
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/components/ai-elements/message.js +2 -2
- package/dist/components/ai-elements/reasoning.js +9 -9
- package/dist/loopstack-studio.css +1 -1
- package/dist/node_modules/@chevrotain/gast/lib/src/helpers.js +2 -5
- package/dist/node_modules/@chevrotain/gast/lib/src/model.js +69 -72
- package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/{architecture-7HQA4BMR.js → architecture-YZFGNWBL.js} +2 -2
- package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/{chunk-TQ3KTPDO.js → chunk-2KRD3SAO.js} +1 -1
- package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/{chunk-4F5CHEZ2.js → chunk-67CJDMHE.js} +1 -1
- package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/{chunk-UMXZTB3W.js → chunk-7N4EOEYR.js} +5 -2
- package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/{chunk-PL6DKKU2.js → chunk-AA7GKIK3.js} +1 -1
- package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/chunk-CIAEETIT.js +23 -0
- package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/{chunk-SJTYNZTY.js → chunk-FOC6F5B3.js} +1 -1
- package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/chunk-K5T4RW27.js +1197 -0
- package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/{chunk-FRFDVMJY.js → chunk-KGLVRYIC.js} +1 -1
- package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/{chunk-B2363JML.js → chunk-LIHQZDEY.js} +1 -1
- package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/chunk-ORNJ4GCN.js +29 -0
- package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/{gitGraph-G5XIXVHT.js → gitGraph-7Q5UKJZL.js} +2 -2
- package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/info-OMHHGYJF.js +3 -0
- package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/packet-4T2RLAQJ.js +3 -0
- package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/pie-ZZUOXDRM.js +3 -0
- package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/radar-PYXPWWZC.js +3 -0
- package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/treeView-SZITEDCU.js +3 -0
- package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/treemap-W4RFUUIX.js +3 -0
- package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/wardley-RL74JXVD.js +3 -0
- package/dist/node_modules/@mermaid-js/parser/dist/mermaid-parser.core.js +27 -17
- package/dist/node_modules/@upsetjs/venn.js/build/venn.esm.js +903 -0
- package/dist/node_modules/@xyflow/react/dist/esm/index.js +76 -75
- package/dist/node_modules/@xyflow/system/dist/esm/index.js +30 -28
- package/dist/node_modules/chevrotain/lib/src/parse/cst/cst_visitor.js +31 -40
- package/dist/node_modules/chevrotain/lib/src/parse/errors_public.js +23 -26
- package/dist/node_modules/chevrotain/lib/src/parse/exceptions_public.js +12 -13
- package/dist/node_modules/chevrotain/lib/src/parse/grammar/checks.js +181 -205
- package/dist/node_modules/chevrotain/lib/src/parse/grammar/first.js +11 -13
- package/dist/node_modules/chevrotain/lib/src/parse/grammar/follow.js +12 -13
- package/dist/node_modules/chevrotain/lib/src/parse/grammar/gast/gast_resolver_public.js +8 -9
- package/dist/node_modules/chevrotain/lib/src/parse/grammar/interpreter.js +176 -183
- package/dist/node_modules/chevrotain/lib/src/parse/grammar/llk_lookahead.js +17 -19
- package/dist/node_modules/chevrotain/lib/src/parse/grammar/lookahead.js +153 -160
- package/dist/node_modules/chevrotain/lib/src/parse/grammar/resolver.js +10 -12
- package/dist/node_modules/chevrotain/lib/src/parse/grammar/rest.js +36 -38
- package/dist/node_modules/chevrotain/lib/src/parse/parser/parser.js +37 -45
- package/dist/node_modules/chevrotain/lib/src/parse/parser/traits/error_handler.js +12 -14
- package/dist/node_modules/chevrotain/lib/src/parse/parser/traits/gast_recorder.js +80 -86
- package/dist/node_modules/chevrotain/lib/src/parse/parser/traits/lexer_adapter.js +6 -2
- package/dist/node_modules/chevrotain/lib/src/parse/parser/traits/looksahead.js +39 -41
- package/dist/node_modules/chevrotain/lib/src/parse/parser/traits/perf_tracer.js +7 -8
- package/dist/node_modules/chevrotain/lib/src/parse/parser/traits/recognizer_api.js +69 -70
- package/dist/node_modules/chevrotain/lib/src/parse/parser/traits/recognizer_engine.js +215 -205
- package/dist/node_modules/chevrotain/lib/src/parse/parser/traits/recoverable.js +76 -76
- package/dist/node_modules/chevrotain/lib/src/parse/parser/traits/tree_builder.js +29 -39
- package/dist/node_modules/chevrotain/lib/src/scan/lexer.js +252 -274
- package/dist/node_modules/chevrotain/lib/src/scan/lexer_public.js +93 -106
- package/dist/node_modules/chevrotain/lib/src/scan/reg_exp.js +61 -61
- package/dist/node_modules/chevrotain/lib/src/scan/tokens.js +31 -41
- package/dist/node_modules/chevrotain/lib/src/scan/tokens_public.js +15 -18
- package/dist/node_modules/chevrotain-allstar/lib/all-star-lookahead.js +226 -226
- package/dist/node_modules/chevrotain-allstar/lib/atn.js +17 -17
- package/dist/node_modules/cytoscape/dist/cytoscape.esm.js +17 -14
- package/dist/node_modules/dagre-d3-es/src/dagre/greedy-fas.js +19 -19
- package/dist/node_modules/dagre-d3-es/src/dagre/layout.js +48 -48
- package/dist/node_modules/dagre-d3-es/src/dagre/nesting-graph.js +9 -9
- package/dist/node_modules/dagre-d3-es/src/dagre/order/cross-count.js +3 -3
- package/dist/node_modules/dagre-d3-es/src/dagre/order/index.js +11 -11
- package/dist/node_modules/dagre-d3-es/src/dagre/order/init-order.js +4 -4
- package/dist/node_modules/dagre-d3-es/src/dagre/order/resolve-conflicts.js +4 -4
- package/dist/node_modules/dagre-d3-es/src/dagre/order/sort-subgraph.js +8 -8
- package/dist/node_modules/dagre-d3-es/src/dagre/order/sort.js +5 -5
- package/dist/node_modules/dagre-d3-es/src/dagre/position/bk.js +61 -61
- package/dist/node_modules/dagre-d3-es/src/dagre/position/index.js +1 -1
- package/dist/node_modules/dagre-d3-es/src/dagre/rank/network-simplex.js +25 -25
- package/dist/node_modules/dagre-d3-es/src/dagre/rank/util.js +8 -8
- package/dist/node_modules/dagre-d3-es/src/dagre/util.js +48 -48
- package/dist/node_modules/dagre-d3-es/src/graphlib/graph.js +109 -109
- package/dist/node_modules/dagre-d3-es/src/graphlib/json.js +17 -17
- package/dist/node_modules/dompurify/dist/purify.es.js +67 -67
- package/dist/node_modules/katex/dist/katex.js +1256 -1209
- package/dist/node_modules/khroma/dist/methods/transparentize.js +3 -0
- package/dist/node_modules/lodash-es/_baseClone.js +2 -2
- package/dist/node_modules/lodash-es/_baseMatchesProperty.js +6 -6
- package/dist/node_modules/lodash-es/_baseToString.js +1 -1
- package/dist/node_modules/lodash-es/_baseUniq.js +1 -1
- package/dist/node_modules/lodash-es/_createSet.js +1 -1
- package/dist/node_modules/lodash-es/_getAllKeys.js +2 -2
- package/dist/node_modules/lodash-es/_getAllKeysIn.js +1 -1
- package/dist/node_modules/lodash-es/findIndex.js +2 -2
- package/dist/node_modules/lodash-es/flatMap.js +1 -1
- package/dist/node_modules/lodash-es/forEach.js +1 -1
- package/dist/node_modules/lodash-es/max.js +1 -1
- package/dist/node_modules/lodash-es/min.js +1 -1
- package/dist/node_modules/lodash-es/minBy.js +1 -1
- package/dist/node_modules/lodash-es/reduce.js +1 -1
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/architectureDiagram-Q4EWVU46.js +691 -0
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{blockDiagram-VD42YOAC.js → blockDiagram-DXYQGD6D.js} +183 -157
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{c4Diagram-YG6GDRKO.js → c4Diagram-AHTNJAMY.js} +65 -63
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/chunk-336JU56O.js +47 -0
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{chunk-EXTU4WIE.js → chunk-426QAEUC.js} +1 -1
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{chunk-B4BG7PRW.js → chunk-4TB4RGXK.js} +533 -393
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/chunk-5FUZZQ4R.js +3638 -0
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{chunk-S3R3BYOJ.js → chunk-5PVQY5BW.js} +1 -1
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{chunk-HN2XXSSU.js → chunk-BSJP7CBP.js} +20 -14
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{chunk-QN33PNHL.js → chunk-EDXVE4YY.js} +1 -1
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/chunk-ENJZ2VHE.js +568 -0
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/chunk-ICPOFSXX.js +2320 -0
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{chunk-DI55MBZ5.js → chunk-OYMX7WX6.js} +35 -21
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/chunk-U2HBQHQK.js +272 -0
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{chunk-ATLVNIR6.js → chunk-X2U36JSP.js} +1 -1
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{chunk-MI3HLSF2.js → chunk-XPW4576I.js} +11 -7
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/chunk-YZCP3GAM.js +60 -0
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/chunk-ZZ45TVLE.js +30 -0
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{classDiagram-2ON5EDUG.js → classDiagram-6PBFFD2Q.js} +12 -11
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{classDiagram-v2-WZHVMYZB.js → classDiagram-v2-HSJHXN6E.js} +12 -11
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{dagre-6UL2VRFP.js → dagre-KV5264BT.js} +8 -8
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/diagram-5BDNPKRD.js +99 -0
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{diagram-PSM6KHXK.js → diagram-G4DWMVQ6.js} +20 -23
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/diagram-MMDJMWI5.js +211 -0
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{diagram-S2PKOQOG.js → diagram-TYMM5635.js} +4 -4
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{erDiagram-Q2GNP2WA.js → erDiagram-SMLLAGMA.js} +486 -386
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{flowDiagram-NV44I4VS.js → flowDiagram-DWJPFMVM.js} +915 -898
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{ganttDiagram-JELNMOA3.js → ganttDiagram-T4ZO3ILL.js} +59 -29
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/gitGraphDiagram-UUTBAWPF.js +728 -0
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/infoDiagram-42DDH7IO.js +17 -0
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/ishikawaDiagram-UXIWVN3A.js +714 -0
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{journeyDiagram-XKPGCS4Q.js → journeyDiagram-VCZTEJTY.js} +32 -32
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{kanban-definition-3W4ZIXB7.js → kanban-definition-6JOO6SKY.js} +13 -9
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{mindmap-definition-VGOIOE7T.js → mindmap-definition-QFDTVHPH.js} +105 -59
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/pieDiagram-DEJITSTG.js +117 -0
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{quadrantDiagram-AYHSOK5B.js → quadrantDiagram-34T5L4WZ.js} +1 -1
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{requirementDiagram-UZGBJVZJ.js → requirementDiagram-MS252O5E.js} +49 -19
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{sankeyDiagram-TZEHDZUN.js → sankeyDiagram-XADWPNL6.js} +1 -1
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/sequenceDiagram-FGHM5R23.js +4155 -0
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{stateDiagram-FKZM4ZOC.js → stateDiagram-FHFEXIEX.js} +12 -12
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{stateDiagram-v2-4FDKWEC3.js → stateDiagram-v2-QKLJ7IA2.js} +11 -11
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/timeline-definition-GMOUNBTQ.js +1071 -0
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/vennDiagram-DHZGUBPP.js +959 -0
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/wardleyDiagram-NUSXRM2D.js +574 -0
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{xychartDiagram-PRI3JC2R.js → xychartDiagram-5P7HB3ND.js} +38 -35
- package/dist/node_modules/mermaid/dist/mermaid.core.js +235 -192
- package/dist/node_modules/nanoid/url-alphabet/index.js +1 -1
- package/dist/node_modules/remend/dist/index.js +333 -264
- package/dist/node_modules/streamdown/dist/chunk-BO2N2NFS.js +2498 -0
- package/dist/node_modules/streamdown/dist/highlighted-body-OFNGDK62.js +35 -0
- package/dist/node_modules/streamdown/dist/index.js +1 -1
- package/dist/node_modules/streamdown/dist/mermaid-GHXKKRXX.js +3 -0
- package/dist/node_modules/streamdown/node_modules/marked/lib/marked.esm.js +672 -667
- package/dist/pages/DashboardPage.js +3 -3
- package/package.json +2 -2
- package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/chunk-TCCFYFTB.js +0 -787
- package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/info-VBDWY6EO.js +0 -3
- package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/packet-DYOGHKS2.js +0 -3
- package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/pie-VRWISCQL.js +0 -3
- package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/radar-ZZBFDIW7.js +0 -3
- package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/treemap-GDKQZRPO.js +0 -3
- package/dist/node_modules/chevrotain/lib/src/parse/parser/traits/context_assist.js +0 -16
- package/dist/node_modules/lodash-es/_arrayAggregator.js +0 -9
- package/dist/node_modules/lodash-es/_arrayEvery.js +0 -6
- package/dist/node_modules/lodash-es/_baseAggregator.js +0 -8
- package/dist/node_modules/lodash-es/_baseDifference.js +0 -22
- package/dist/node_modules/lodash-es/_baseEvery.js +0 -9
- package/dist/node_modules/lodash-es/_baseIsRegExp.js +0 -8
- package/dist/node_modules/lodash-es/_baseSlice.js +0 -8
- package/dist/node_modules/lodash-es/_baseSome.js +0 -9
- package/dist/node_modules/lodash-es/_createAggregator.js +0 -12
- package/dist/node_modules/lodash-es/assign.js +0 -14
- package/dist/node_modules/lodash-es/compact.js +0 -9
- package/dist/node_modules/lodash-es/difference.js +0 -8
- package/dist/node_modules/lodash-es/drop.js +0 -8
- package/dist/node_modules/lodash-es/dropRight.js +0 -8
- package/dist/node_modules/lodash-es/every.js +0 -11
- package/dist/node_modules/lodash-es/groupBy.js +0 -6
- package/dist/node_modules/lodash-es/head.js +0 -5
- package/dist/node_modules/lodash-es/includes.js +0 -13
- package/dist/node_modules/lodash-es/indexOf.js +0 -11
- package/dist/node_modules/lodash-es/isRegExp.js +0 -5
- package/dist/node_modules/lodash-es/negate.js +0 -16
- package/dist/node_modules/lodash-es/pickBy.js +0 -15
- package/dist/node_modules/lodash-es/reject.js +0 -10
- package/dist/node_modules/lodash-es/some.js +0 -11
- package/dist/node_modules/lodash-es/uniq.js +0 -6
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/architectureDiagram-VXUJARFQ.js +0 -673
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/chunk-ABZYJK2D.js +0 -1547
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/chunk-CVBHYZKI.js +0 -10
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/chunk-DR5Q36YT.js +0 -135
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/chunk-JA3XYJ7Z.js +0 -247
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/chunk-JZLCHNYA.js +0 -3516
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/chunk-N4CR4FBY.js +0 -39
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/chunk-QXUST7PY.js +0 -497
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/chunk-TZMSLE5B.js +0 -55
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/diagram-QEK2KX5R.js +0 -211
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/gitGraphDiagram-V2S2FVAM.js +0 -621
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/infoDiagram-HS3SLOUP.js +0 -18
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/pieDiagram-ADFJNKIX.js +0 -117
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/sequenceDiagram-WL72ISMW.js +0 -3560
- package/dist/node_modules/mermaid/dist/chunks/mermaid.core/timeline-definition-IT6M3QCI.js +0 -833
- package/dist/node_modules/streamdown/dist/chunk-RLXIAIE6.js +0 -2189
- package/dist/node_modules/streamdown/dist/highlighted-body-B3W2YXNL.js +0 -33
- package/dist/node_modules/streamdown/dist/mermaid-3ZIDBTTL.js +0 -3
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { __name } from "./chunk-AGHRB4JF.js";
|
|
2
|
-
import { clear, configureSvgSize, getAccDescription, getAccTitle, getConfig2, getDiagramTitle, setAccDescription, setAccTitle, setDiagramTitle } from "./chunk-
|
|
2
|
+
import { clear, configureSvgSize, getAccDescription, getAccTitle, getConfig2, getDiagramTitle, setAccDescription, setAccTitle, setDiagramTitle } from "./chunk-ICPOFSXX.js";
|
|
3
3
|
import select_default from "../../../../d3-selection/src/select.js";
|
|
4
4
|
import arc_default from "../../../../d3-shape/src/arc.js";
|
|
5
5
|
import "../../../../d3/src/index.js";
|
|
6
6
|
import { getIconStyles } from "./chunk-FMBD7UC4.js";
|
|
7
|
-
import { drawBackgroundRect, drawRect, drawText, getNoteRect } from "./chunk-
|
|
7
|
+
import { drawBackgroundRect, drawRect, drawText, getNoteRect } from "./chunk-YZCP3GAM.js";
|
|
8
8
|
var parser = (function() {
|
|
9
9
|
var S = /* @__PURE__ */ __name(function(e, S, C, w) {
|
|
10
10
|
for (C ||= {}, w = e.length; w--; C[e[w]] = S);
|
|
@@ -673,28 +673,28 @@ var journey_default = parser, currentSection = "", sections = [], tasks = [], ra
|
|
|
673
673
|
}, "drawLabel"), drawSection = /* @__PURE__ */ __name(function(e, S, C) {
|
|
674
674
|
let w = e.append("g"), T = getNoteRect();
|
|
675
675
|
T.x = S.x, T.y = S.y, T.fill = S.fill, T.width = C.width * S.taskCount + C.diagramMarginX * (S.taskCount - 1), T.height = C.height, T.class = "journey-section section-type-" + S.num, T.rx = 3, T.ry = 3, drawRect2(w, T), _drawTextCandidateFunc(C)(S.text, w, T.x, T.y, T.width, T.height, { class: "journey-section section-type-" + S.num }, C, S.colour);
|
|
676
|
-
}, "drawSection"), taskCount = -1, drawTask = /* @__PURE__ */ __name(function(e, S, C) {
|
|
677
|
-
let
|
|
678
|
-
taskCount++,
|
|
679
|
-
cx:
|
|
676
|
+
}, "drawSection"), taskCount = -1, drawTask = /* @__PURE__ */ __name(function(e, S, C, w) {
|
|
677
|
+
let T = S.x + C.width / 2, E = e.append("g");
|
|
678
|
+
taskCount++, E.append("line").attr("id", w + "-task" + taskCount).attr("x1", T).attr("y1", S.y).attr("x2", T).attr("y2", 450).attr("class", "task-line").attr("stroke-width", "1px").attr("stroke-dasharray", "4 2").attr("stroke", "#666"), drawFace(E, {
|
|
679
|
+
cx: T,
|
|
680
680
|
cy: 300 + (5 - S.score) * 30,
|
|
681
681
|
score: S.score
|
|
682
682
|
});
|
|
683
|
-
let
|
|
684
|
-
|
|
685
|
-
let
|
|
683
|
+
let D = getNoteRect();
|
|
684
|
+
D.x = S.x, D.y = S.y, D.fill = S.fill, D.width = C.width, D.height = C.height, D.class = "task task-type-" + S.num, D.rx = 3, D.ry = 3, drawRect2(E, D);
|
|
685
|
+
let O = S.x + 14;
|
|
686
686
|
S.people.forEach((e) => {
|
|
687
687
|
let C = S.actors[e].color;
|
|
688
|
-
drawCircle(
|
|
689
|
-
cx:
|
|
688
|
+
drawCircle(E, {
|
|
689
|
+
cx: O,
|
|
690
690
|
cy: S.y,
|
|
691
691
|
r: 7,
|
|
692
692
|
fill: C,
|
|
693
693
|
stroke: "#000",
|
|
694
694
|
title: e,
|
|
695
695
|
pos: S.actors[e].position
|
|
696
|
-
}),
|
|
697
|
-
}), _drawTextCandidateFunc(C)(S.task,
|
|
696
|
+
}), O += 10;
|
|
697
|
+
}), _drawTextCandidateFunc(C)(S.task, E, D.x, D.y, D.width, D.height, { class: "task" }, C, S.colour);
|
|
698
698
|
}, "drawTask"), drawBackgroundRect2 = /* @__PURE__ */ __name(function(e, S) {
|
|
699
699
|
drawBackgroundRect(e, S);
|
|
700
700
|
}, "drawBackgroundRect"), _drawTextCandidateFunc = /* @__PURE__ */ (function() {
|
|
@@ -729,8 +729,8 @@ var journey_default = parser, currentSection = "", sections = [], tasks = [], ra
|
|
|
729
729
|
drawLabel,
|
|
730
730
|
drawTask,
|
|
731
731
|
drawBackgroundRect: drawBackgroundRect2,
|
|
732
|
-
initGraphics: /* @__PURE__ */ __name(function(e) {
|
|
733
|
-
e.append("defs").append("marker").attr("id", "arrowhead").attr("refX", 5).attr("refY", 2).attr("markerWidth", 6).attr("markerHeight", 4).attr("orient", "auto").append("path").attr("d", "M 0,0 V 4 L6,2 Z");
|
|
732
|
+
initGraphics: /* @__PURE__ */ __name(function(e, S) {
|
|
733
|
+
taskCount = -1, e.append("defs").append("marker").attr("id", S + "-arrowhead").attr("refX", 5).attr("refY", 2).attr("markerWidth", 6).attr("markerHeight", 4).attr("orient", "auto").append("path").attr("d", "M 0,0 V 4 L6,2 Z");
|
|
734
734
|
}, "initGraphics")
|
|
735
735
|
}, setConf = /* @__PURE__ */ __name(function(e) {
|
|
736
736
|
Object.keys(e).forEach(function(S) {
|
|
@@ -787,7 +787,7 @@ var conf = getConfig2().journey, leftMargin = 0, draw = /* @__PURE__ */ __name(f
|
|
|
787
787
|
let P = select_default(M === "sandbox" ? N.nodes()[0].contentDocument.body : "body");
|
|
788
788
|
bounds.init();
|
|
789
789
|
let F = P.select("#" + S);
|
|
790
|
-
svgDraw_default.initGraphics(F);
|
|
790
|
+
svgDraw_default.initGraphics(F, S);
|
|
791
791
|
let I = T.db.getTasks(), L = T.db.getDiagramTitle(), R = T.db.getActors();
|
|
792
792
|
for (let e in actors) delete actors[e];
|
|
793
793
|
let z = 0;
|
|
@@ -796,11 +796,11 @@ var conf = getConfig2().journey, leftMargin = 0, draw = /* @__PURE__ */ __name(f
|
|
|
796
796
|
color: conf.actorColours[z % conf.actorColours.length],
|
|
797
797
|
position: z
|
|
798
798
|
}, z++;
|
|
799
|
-
}), drawActorLegend(F), leftMargin = conf.leftMargin + maxWidth, bounds.insert(0, 0, leftMargin, Object.keys(actors).length * 50), drawTasks(F, I, 0);
|
|
799
|
+
}), drawActorLegend(F), leftMargin = conf.leftMargin + maxWidth, bounds.insert(0, 0, leftMargin, Object.keys(actors).length * 50), drawTasks(F, I, 0, S);
|
|
800
800
|
let B = bounds.getBounds();
|
|
801
801
|
L && F.append("text").text(L).attr("x", leftMargin).attr("font-size", k).attr("font-weight", "bold").attr("y", 25).attr("fill", O).attr("font-family", A);
|
|
802
802
|
let V = B.stopy - B.starty + 2 * conf.diagramMarginY, H = leftMargin + B.stopx + 2 * conf.diagramMarginX;
|
|
803
|
-
configureSvgSize(F, V, H, conf.useMaxWidth), F.append("line").attr("x1", leftMargin).attr("y1", conf.height * 4).attr("x2", H - leftMargin - 4).attr("y2", conf.height * 4).attr("stroke-width", 4).attr("stroke", "black").attr("marker-end", "url(#arrowhead)");
|
|
803
|
+
configureSvgSize(F, V, H, conf.useMaxWidth), F.append("line").attr("x1", leftMargin).attr("y1", conf.height * 4).attr("x2", H - leftMargin - 4).attr("y2", conf.height * 4).attr("stroke-width", 4).attr("stroke", "black").attr("marker-end", "url(#" + S + "-arrowhead)");
|
|
804
804
|
let U = L ? 70 : 0;
|
|
805
805
|
F.attr("viewBox", `${B.startx} -25 ${H} ${V + U}`), F.attr("preserveAspectRatio", "xMinYMin meet"), F.attr("height", V + U + 25);
|
|
806
806
|
}, "draw"), bounds = {
|
|
@@ -847,26 +847,26 @@ var conf = getConfig2().journey, leftMargin = 0, draw = /* @__PURE__ */ __name(f
|
|
|
847
847
|
getBounds: /* @__PURE__ */ __name(function() {
|
|
848
848
|
return this.data;
|
|
849
849
|
}, "getBounds")
|
|
850
|
-
}, fills = conf.sectionFills, textColours = conf.sectionColours, drawTasks = /* @__PURE__ */ __name(function(e, S, C) {
|
|
851
|
-
let
|
|
850
|
+
}, fills = conf.sectionFills, textColours = conf.sectionColours, drawTasks = /* @__PURE__ */ __name(function(e, S, C, w) {
|
|
851
|
+
let T = getConfig2().journey, D = "", O = C + (T.height * 2 + T.diagramMarginY), k = 0, A = "#CCC", j = "black", M = 0;
|
|
852
852
|
for (let [C, E] of S.entries()) {
|
|
853
|
-
if (
|
|
854
|
-
|
|
855
|
-
let
|
|
856
|
-
for (let e = C; e < S.length && S[e].section ==
|
|
853
|
+
if (D !== E.section) {
|
|
854
|
+
A = fills[k % fills.length], M = k % fills.length, j = textColours[k % textColours.length];
|
|
855
|
+
let w = 0, O = E.section;
|
|
856
|
+
for (let e = C; e < S.length && S[e].section == O; e++) w += 1;
|
|
857
857
|
let N = {
|
|
858
|
-
x: C *
|
|
858
|
+
x: C * T.taskMargin + C * T.width + leftMargin,
|
|
859
859
|
y: 50,
|
|
860
860
|
text: E.section,
|
|
861
|
-
fill:
|
|
862
|
-
num:
|
|
863
|
-
colour:
|
|
864
|
-
taskCount:
|
|
861
|
+
fill: A,
|
|
862
|
+
num: M,
|
|
863
|
+
colour: j,
|
|
864
|
+
taskCount: w
|
|
865
865
|
};
|
|
866
|
-
svgDraw_default.drawSection(e, N,
|
|
866
|
+
svgDraw_default.drawSection(e, N, T), D = E.section, k++;
|
|
867
867
|
}
|
|
868
|
-
let
|
|
869
|
-
E.x = C *
|
|
868
|
+
let N = E.people.reduce((e, S) => (actors[S] && (e[S] = actors[S]), e), {});
|
|
869
|
+
E.x = C * T.taskMargin + C * T.width + leftMargin, E.y = O, E.width = T.diagramMarginX, E.height = T.diagramMarginY, E.colour = j, E.fill = A, E.num = M, E.actors = N, svgDraw_default.drawTask(e, E, T, w), bounds.insert(E.x, E.y, E.x + E.width + T.taskMargin, 450);
|
|
870
870
|
}
|
|
871
871
|
}, "drawTasks"), journeyRenderer_default = {
|
|
872
872
|
setConf,
|
|
@@ -2,14 +2,14 @@ import { __name, log } from "./chunk-AGHRB4JF.js";
|
|
|
2
2
|
import is_dark_default from "../../../../khroma/dist/methods/is_dark.js";
|
|
3
3
|
import lighten_default from "../../../../khroma/dist/methods/lighten.js";
|
|
4
4
|
import darken_default from "../../../../khroma/dist/methods/darken.js";
|
|
5
|
-
import { defaultConfig_default, getConfig2, sanitizeText, setupGraphViewbox } from "./chunk-
|
|
6
|
-
import { selectSvgElement } from "./chunk-
|
|
7
|
-
import { JSON_SCHEMA, load } from "./chunk-
|
|
8
|
-
import "./chunk-
|
|
9
|
-
import "./chunk-
|
|
10
|
-
import "./chunk-
|
|
11
|
-
import "./chunk-
|
|
12
|
-
import { insertCluster, insertNode, positionNode } from "./chunk-
|
|
5
|
+
import { defaultConfig_default, getConfig2, sanitizeText, setupGraphViewbox } from "./chunk-ICPOFSXX.js";
|
|
6
|
+
import { selectSvgElement } from "./chunk-426QAEUC.js";
|
|
7
|
+
import { JSON_SCHEMA, load } from "./chunk-XPW4576I.js";
|
|
8
|
+
import "./chunk-5PVQY5BW.js";
|
|
9
|
+
import "./chunk-ZZ45TVLE.js";
|
|
10
|
+
import "./chunk-X2U36JSP.js";
|
|
11
|
+
import "./chunk-U2HBQHQK.js";
|
|
12
|
+
import { insertCluster, insertNode, positionNode } from "./chunk-5FUZZQ4R.js";
|
|
13
13
|
import { getIconStyles } from "./chunk-FMBD7UC4.js";
|
|
14
14
|
var parser = (function() {
|
|
15
15
|
var t = /* @__PURE__ */ __name(function(e, t, n, r) {
|
|
@@ -739,6 +739,7 @@ var kanban_default = parser, nodes = [], sections = [], cnt = 0, elements = {},
|
|
|
739
739
|
let n = {
|
|
740
740
|
id: e.id,
|
|
741
741
|
label: sanitizeText(e.label ?? "", r),
|
|
742
|
+
labelType: "markdown",
|
|
742
743
|
isGroup: !0,
|
|
743
744
|
ticket: e.ticket,
|
|
744
745
|
shape: "kanbanSection",
|
|
@@ -752,6 +753,7 @@ var kanban_default = parser, nodes = [], sections = [], cnt = 0, elements = {},
|
|
|
752
753
|
id: n.id,
|
|
753
754
|
parentId: e.id,
|
|
754
755
|
label: sanitizeText(n.label ?? "", r),
|
|
756
|
+
labelType: "markdown",
|
|
755
757
|
isGroup: !1,
|
|
756
758
|
ticket: n?.ticket,
|
|
757
759
|
priority: n?.priority,
|
|
@@ -848,7 +850,9 @@ var kanban_default = parser, nodes = [], sections = [], cnt = 0, elements = {},
|
|
|
848
850
|
log.debug("Rendering kanban diagram\n" + e);
|
|
849
851
|
let s = i.db.getData(), u = getConfig2();
|
|
850
852
|
u.htmlLabels = !1;
|
|
851
|
-
let d = selectSvgElement(n)
|
|
853
|
+
let d = selectSvgElement(n);
|
|
854
|
+
for (let e of s.nodes) e.domId = `${n}-${e.id}`;
|
|
855
|
+
let h = d.append("g");
|
|
852
856
|
h.attr("class", "sections");
|
|
853
857
|
let g = d.append("g");
|
|
854
858
|
g.attr("class", "items");
|
|
@@ -2,17 +2,17 @@ import { __name, log } from "./chunk-AGHRB4JF.js";
|
|
|
2
2
|
import is_dark_default from "../../../../khroma/dist/methods/is_dark.js";
|
|
3
3
|
import lighten_default from "../../../../khroma/dist/methods/lighten.js";
|
|
4
4
|
import darken_default from "../../../../khroma/dist/methods/darken.js";
|
|
5
|
-
import { defaultConfig_default, getConfig2, getUserDefinedConfig, sanitizeText } from "./chunk-
|
|
6
|
-
import "./chunk-
|
|
7
|
-
import "./chunk-
|
|
8
|
-
import "./chunk-
|
|
9
|
-
import "./chunk-
|
|
10
|
-
import "./chunk-
|
|
11
|
-
import "./chunk-
|
|
12
|
-
import "./chunk-
|
|
13
|
-
import { getRegisteredLayoutAlgorithm, render } from "./chunk-
|
|
5
|
+
import { defaultConfig_default, getConfig, getConfig2, getUserDefinedConfig, sanitizeText } from "./chunk-ICPOFSXX.js";
|
|
6
|
+
import "./chunk-BSJP7CBP.js";
|
|
7
|
+
import "./chunk-5PVQY5BW.js";
|
|
8
|
+
import "./chunk-ZZ45TVLE.js";
|
|
9
|
+
import "./chunk-X2U36JSP.js";
|
|
10
|
+
import "./chunk-U2HBQHQK.js";
|
|
11
|
+
import "./chunk-5FUZZQ4R.js";
|
|
12
|
+
import "./chunk-ENJZ2VHE.js";
|
|
13
|
+
import { getRegisteredLayoutAlgorithm, render } from "./chunk-336JU56O.js";
|
|
14
14
|
import { getDiagramElement } from "./chunk-55IACEB6.js";
|
|
15
|
-
import { setupViewPortForSVG } from "./chunk-
|
|
15
|
+
import { setupViewPortForSVG } from "./chunk-EDXVE4YY.js";
|
|
16
16
|
import v4_default from "../../../../uuid/dist/esm-browser/v4.js";
|
|
17
17
|
var parser = (function() {
|
|
18
18
|
var t = /* @__PURE__ */ __name(function(e, t, n, r) {
|
|
@@ -662,7 +662,7 @@ var parser = (function() {
|
|
|
662
662
|
return __name(y, "Parser"), y.prototype = v, v.Parser = y, new y();
|
|
663
663
|
})();
|
|
664
664
|
parser.parser = parser;
|
|
665
|
-
var mindmap_default = parser, nodeType = {
|
|
665
|
+
var mindmap_default = parser, MAX_SECTIONS = 12, nodeType = {
|
|
666
666
|
DEFAULT: 0,
|
|
667
667
|
NO_BORDER: 0,
|
|
668
668
|
ROUNDED_RECT: 1,
|
|
@@ -688,9 +688,9 @@ var mindmap_default = parser, nodeType = {
|
|
|
688
688
|
}
|
|
689
689
|
addNode(e, n, r, i) {
|
|
690
690
|
log.info("addNode", e, n, r, i);
|
|
691
|
-
let
|
|
692
|
-
this.nodes.length === 0 ? (this.baseLevel = e, e = 0,
|
|
693
|
-
let
|
|
691
|
+
let o = !1;
|
|
692
|
+
this.nodes.length === 0 ? (this.baseLevel = e, e = 0, o = !0) : this.baseLevel !== void 0 && (e -= this.baseLevel, o = !1);
|
|
693
|
+
let c = getConfig2(), u = c.mindmap?.padding ?? defaultConfig_default.mindmap.padding;
|
|
694
694
|
switch (i) {
|
|
695
695
|
case this.nodeType.ROUNDED_RECT:
|
|
696
696
|
case this.nodeType.RECT:
|
|
@@ -700,17 +700,17 @@ var mindmap_default = parser, nodeType = {
|
|
|
700
700
|
}
|
|
701
701
|
let d = {
|
|
702
702
|
id: this.count++,
|
|
703
|
-
nodeId: sanitizeText(n,
|
|
703
|
+
nodeId: sanitizeText(n, c),
|
|
704
704
|
level: e,
|
|
705
|
-
descr: sanitizeText(r,
|
|
705
|
+
descr: sanitizeText(r, c),
|
|
706
706
|
type: i,
|
|
707
707
|
children: [],
|
|
708
|
-
width:
|
|
708
|
+
width: c.mindmap?.maxNodeWidth ?? defaultConfig_default.mindmap.maxNodeWidth,
|
|
709
709
|
padding: u,
|
|
710
|
-
isRoot:
|
|
710
|
+
isRoot: o
|
|
711
711
|
}, f = this.getParent(e);
|
|
712
712
|
if (f) f.children.push(d), this.nodes.push(d);
|
|
713
|
-
else if (
|
|
713
|
+
else if (o) this.nodes.push(d);
|
|
714
714
|
else throw Error(`There can be only one root. No parent could be found for ("${d.descr}")`);
|
|
715
715
|
}
|
|
716
716
|
getType(e, n) {
|
|
@@ -749,14 +749,15 @@ var mindmap_default = parser, nodeType = {
|
|
|
749
749
|
}
|
|
750
750
|
assignSections(e, t) {
|
|
751
751
|
if (e.level === 0 ? e.section = void 0 : e.section = t, e.children) for (let [n, r] of e.children.entries()) {
|
|
752
|
-
let i = e.level === 0 ? n : t;
|
|
752
|
+
let i = e.level === 0 ? n % (MAX_SECTIONS - 1) : t;
|
|
753
753
|
this.assignSections(r, i);
|
|
754
754
|
}
|
|
755
755
|
}
|
|
756
756
|
flattenNodes(t, n) {
|
|
757
|
-
let r = ["mindmap-node"];
|
|
758
|
-
t.isRoot === !0 ?
|
|
759
|
-
let
|
|
757
|
+
let r = getConfig2(), i = ["mindmap-node"];
|
|
758
|
+
t.isRoot === !0 ? i.push("section-root", "section--1") : t.section !== void 0 && i.push(`section-${t.section}`), t.class && i.push(t.class);
|
|
759
|
+
let a = i.join(" "), o = /* @__PURE__ */ __name((e) => {
|
|
760
|
+
let t = (r.theme?.toLowerCase() ?? "").includes("redux");
|
|
760
761
|
switch (e) {
|
|
761
762
|
case nodeType.CIRCLE: return "mindmapCircle";
|
|
762
763
|
case nodeType.RECT: return "rect";
|
|
@@ -764,22 +765,23 @@ var mindmap_default = parser, nodeType = {
|
|
|
764
765
|
case nodeType.CLOUD: return "cloud";
|
|
765
766
|
case nodeType.BANG: return "bang";
|
|
766
767
|
case nodeType.HEXAGON: return "hexagon";
|
|
767
|
-
case nodeType.DEFAULT: return "defaultMindmapNode";
|
|
768
|
+
case nodeType.DEFAULT: return t ? "rounded" : "defaultMindmapNode";
|
|
768
769
|
case nodeType.NO_BORDER:
|
|
769
770
|
default: return "rect";
|
|
770
771
|
}
|
|
771
|
-
}, "getShapeFromType"),
|
|
772
|
+
}, "getShapeFromType"), c = {
|
|
772
773
|
id: t.id.toString(),
|
|
773
774
|
domId: "node_" + t.id.toString(),
|
|
774
775
|
label: t.descr,
|
|
776
|
+
labelType: "markdown",
|
|
775
777
|
isGroup: !1,
|
|
776
|
-
shape:
|
|
778
|
+
shape: o(t.type),
|
|
777
779
|
width: t.width,
|
|
778
780
|
height: t.height ?? 0,
|
|
779
781
|
padding: t.padding,
|
|
780
|
-
cssClasses:
|
|
782
|
+
cssClasses: a,
|
|
781
783
|
cssStyles: [],
|
|
782
|
-
look:
|
|
784
|
+
look: r.look,
|
|
783
785
|
icon: t.icon,
|
|
784
786
|
x: t.x,
|
|
785
787
|
y: t.y,
|
|
@@ -788,27 +790,29 @@ var mindmap_default = parser, nodeType = {
|
|
|
788
790
|
type: t.type,
|
|
789
791
|
section: t.section
|
|
790
792
|
};
|
|
791
|
-
if (n.push(
|
|
793
|
+
if (n.push(c), t.children) for (let e of t.children) this.flattenNodes(e, n);
|
|
792
794
|
}
|
|
793
795
|
generateEdges(e, t) {
|
|
794
|
-
if (e.children)
|
|
795
|
-
|
|
796
|
-
|
|
797
|
-
let i =
|
|
798
|
-
r += ` edge
|
|
799
|
-
let a =
|
|
800
|
-
|
|
796
|
+
if (!e.children) return;
|
|
797
|
+
let n = getConfig2();
|
|
798
|
+
for (let r of e.children) {
|
|
799
|
+
let i = "edge";
|
|
800
|
+
r.section !== void 0 && (i += ` section-edge-${r.section}`);
|
|
801
|
+
let a = e.level + 1;
|
|
802
|
+
i += ` edge-depth-${a}`;
|
|
803
|
+
let o = {
|
|
804
|
+
id: `edge_${e.id}_${r.id}`,
|
|
801
805
|
start: e.id.toString(),
|
|
802
|
-
end:
|
|
806
|
+
end: r.id.toString(),
|
|
803
807
|
type: "normal",
|
|
804
808
|
curve: "basis",
|
|
805
809
|
thickness: "normal",
|
|
806
|
-
look:
|
|
807
|
-
classes:
|
|
810
|
+
look: n.look,
|
|
811
|
+
classes: i,
|
|
808
812
|
depth: e.level,
|
|
809
|
-
section:
|
|
813
|
+
section: r.section
|
|
810
814
|
};
|
|
811
|
-
t.push(
|
|
815
|
+
t.push(o), this.generateEdges(r, t);
|
|
812
816
|
}
|
|
813
817
|
}
|
|
814
818
|
getData() {
|
|
@@ -819,8 +823,8 @@ var mindmap_default = parser, nodeType = {
|
|
|
819
823
|
config: i
|
|
820
824
|
};
|
|
821
825
|
log.debug("getData: mindmapRoot", e, n), this.assignSections(e);
|
|
822
|
-
let a = [],
|
|
823
|
-
this.flattenNodes(e, a), this.generateEdges(e,
|
|
826
|
+
let a = [], o = [];
|
|
827
|
+
this.flattenNodes(e, a), this.generateEdges(e, o), log.debug(`getData: processed ${a.length} nodes and ${o.length} edges`);
|
|
824
828
|
let l = /* @__PURE__ */ new Map();
|
|
825
829
|
for (let e of a) l.set(e.id, {
|
|
826
830
|
shape: e.shape,
|
|
@@ -830,7 +834,7 @@ var mindmap_default = parser, nodeType = {
|
|
|
830
834
|
});
|
|
831
835
|
return {
|
|
832
836
|
nodes: a,
|
|
833
|
-
edges:
|
|
837
|
+
edges: o,
|
|
834
838
|
config: i,
|
|
835
839
|
rootNode: e,
|
|
836
840
|
markers: ["point"],
|
|
@@ -847,21 +851,31 @@ var mindmap_default = parser, nodeType = {
|
|
|
847
851
|
}
|
|
848
852
|
}, mindmapRenderer_default = { draw: /* @__PURE__ */ __name(async (e, n, r, i) => {
|
|
849
853
|
log.debug("Rendering mindmap diagram\n" + e);
|
|
850
|
-
let
|
|
851
|
-
|
|
852
|
-
|
|
853
|
-
|
|
854
|
+
let s = i.db, c = s.getData(), l = getDiagramElement(n, c.config.securityLevel);
|
|
855
|
+
if (c.type = i.type, c.layoutAlgorithm = getRegisteredLayoutAlgorithm(c.config.layout, { fallback: "cose-bilkent" }), c.diagramId = n, !s.getMindmap()) return;
|
|
856
|
+
c.nodes.forEach((e) => {
|
|
857
|
+
e.shape === "rounded" ? (e.radius = 15, e.taper = 15, e.stroke = "none", e.width = 0, e.padding = 15) : e.shape === "circle" ? e.padding = 10 : e.shape === "rect" ? (e.width = 0, e.padding = 10) : e.shape === "hexagon" && (e.width = 0, e.height = 0);
|
|
858
|
+
}), await render(c, l);
|
|
859
|
+
let { themeVariables: m } = getConfig(), { useGradient: h, gradientStart: g, gradientStop: _ } = m;
|
|
860
|
+
if (h && g && _) {
|
|
861
|
+
let e = l.attr("id"), t = l.append("defs").append("linearGradient").attr("id", `${e}-gradient`).attr("gradientUnits", "objectBoundingBox").attr("x1", "0%").attr("y1", "0%").attr("x2", "100%").attr("y2", "0%");
|
|
862
|
+
t.append("stop").attr("offset", "0%").attr("stop-color", g).attr("stop-opacity", 1), t.append("stop").attr("offset", "100%").attr("stop-color", _).attr("stop-opacity", 1);
|
|
863
|
+
}
|
|
864
|
+
setupViewPortForSVG(l, c.config.mindmap?.padding ?? defaultConfig_default.mindmap.padding, "mindmapDiagram", c.config.mindmap?.useMaxWidth ?? defaultConfig_default.mindmap.useMaxWidth);
|
|
854
865
|
}, "draw") }, genSections = /* @__PURE__ */ __name((e) => {
|
|
855
|
-
let t = "";
|
|
866
|
+
let { theme: t, look: a } = e, o = "";
|
|
856
867
|
for (let t = 0; t < e.THEME_COLOR_LIMIT; t++) e["lineColor" + t] = e["lineColor" + t] || e["cScaleInv" + t], is_dark_default(e["lineColor" + t]) ? e["lineColor" + t] = lighten_default(e["lineColor" + t], 20) : e["lineColor" + t] = darken_default(e["lineColor" + t], 20);
|
|
857
868
|
for (let n = 0; n < e.THEME_COLOR_LIMIT; n++) {
|
|
858
|
-
let r = "" + (17 - 3 * n);
|
|
859
|
-
|
|
869
|
+
let r = "" + (a === "neo" ? Math.max(10 - (n - 1) * 2, 2) : 17 - 3 * n);
|
|
870
|
+
o += `
|
|
860
871
|
.section-${n - 1} rect, .section-${n - 1} path, .section-${n - 1} circle, .section-${n - 1} polygon, .section-${n - 1} path {
|
|
861
872
|
fill: ${e["cScale" + n]};
|
|
862
873
|
}
|
|
863
874
|
.section-${n - 1} text {
|
|
864
875
|
fill: ${e["cScaleLabel" + n]};
|
|
876
|
+
}
|
|
877
|
+
.section-${n - 1} span {
|
|
878
|
+
color: ${e["cScaleLabel" + n]};
|
|
865
879
|
}
|
|
866
880
|
.node-icon-${n - 1} {
|
|
867
881
|
font-size: 40px;
|
|
@@ -884,16 +898,40 @@ var mindmap_default = parser, nodeType = {
|
|
|
884
898
|
.disabled text {
|
|
885
899
|
fill: #efefef;
|
|
886
900
|
}
|
|
901
|
+
[data-look="neo"].mindmap-node.section-${n - 1} rect, [data-look="neo"].mindmap-node.section-${n - 1} path, [data-look="neo"].mindmap-node.section-${n - 1} circle, [data-look="neo"].mindmap-node.section-${n - 1} polygon {
|
|
902
|
+
fill: ${t === "redux" || t === "redux-dark" || t === "neutral" ? e.mainBkg : e["cScale" + n]};
|
|
903
|
+
stroke: ${t === "redux" || t === "redux-dark" ? e.nodeBorder : e["cScale" + n]};
|
|
904
|
+
stroke-width: ${e.strokeWidth ?? 2}px;
|
|
905
|
+
}
|
|
906
|
+
[data-look="neo"].section-edge-${n - 1}{
|
|
907
|
+
stroke: ${t?.includes("redux") || t === "neo-dark" ? e.nodeBorder : e["cScale" + n]};
|
|
908
|
+
}
|
|
909
|
+
[data-look="neo"].mindmap-node.section-${n - 1} text {
|
|
910
|
+
fill: ${t === "redux" || t === "redux-dark" ? e.nodeBorder : e["cScaleLabel" + (t === "neutral" ? 1 : n)]};
|
|
911
|
+
}
|
|
887
912
|
`;
|
|
888
913
|
}
|
|
889
|
-
return
|
|
890
|
-
}, "genSections"),
|
|
914
|
+
return o;
|
|
915
|
+
}, "genSections"), genGradient = /* @__PURE__ */ __name((e, t, n) => {
|
|
916
|
+
let r = "";
|
|
917
|
+
for (let i = 0; i < e; i++) r += `
|
|
918
|
+
[data-look="neo"].mindmap-node.section-${i - 1} rect, [data-look="neo"].mindmap-node.section-${i - 1} path, [data-look="neo"].mindmap-node.section-${i - 1} circle, [data-look="neo"].mindmap-node.section-${i - 1} polygon {
|
|
919
|
+
stroke: url(${t}-gradient);
|
|
920
|
+
fill: ${n};
|
|
921
|
+
}
|
|
922
|
+
.section-${i - 1} line {
|
|
923
|
+
stroke-width: 0;
|
|
924
|
+
}`;
|
|
925
|
+
return r;
|
|
926
|
+
}, "genGradient"), diagram = {
|
|
891
927
|
get db() {
|
|
892
928
|
return new MindmapDB();
|
|
893
929
|
},
|
|
894
930
|
renderer: mindmapRenderer_default,
|
|
895
931
|
parser: mindmap_default,
|
|
896
|
-
styles: /* @__PURE__ */ __name((e) =>
|
|
932
|
+
styles: /* @__PURE__ */ __name((e) => {
|
|
933
|
+
let { theme: t } = e, n = e.svgId, r = e.dropShadow ? e.dropShadow.replace("url(#drop-shadow)", `url(${n}-drop-shadow)`) : "none";
|
|
934
|
+
return `
|
|
897
935
|
.edge {
|
|
898
936
|
stroke-width: 3;
|
|
899
937
|
}
|
|
@@ -905,10 +943,7 @@ var mindmap_default = parser, nodeType = {
|
|
|
905
943
|
fill: ${e.gitBranchLabel0};
|
|
906
944
|
}
|
|
907
945
|
.section-root span {
|
|
908
|
-
color: ${e.gitBranchLabel0};
|
|
909
|
-
}
|
|
910
|
-
.section-2 span {
|
|
911
|
-
color: ${e.gitBranchLabel0};
|
|
946
|
+
color: ${t?.includes("redux") ? e.nodeBorder : e.gitBranchLabel0};
|
|
912
947
|
}
|
|
913
948
|
.icon-container {
|
|
914
949
|
height:100%;
|
|
@@ -926,6 +961,17 @@ var mindmap_default = parser, nodeType = {
|
|
|
926
961
|
dominant-baseline: middle;
|
|
927
962
|
text-align: center;
|
|
928
963
|
}
|
|
929
|
-
|
|
964
|
+
[data-look="neo"].mindmap-node {
|
|
965
|
+
filter: ${r};
|
|
966
|
+
}
|
|
967
|
+
[data-look="neo"].mindmap-node.section-root rect, [data-look="neo"].mindmap-node.section-root path, [data-look="neo"].mindmap-node.section-root circle, [data-look="neo"].mindmap-node.section-root polygon {
|
|
968
|
+
fill: ${t?.includes("redux") ? e.mainBkg : e.git0};
|
|
969
|
+
}
|
|
970
|
+
[data-look="neo"].mindmap-node.section-root .text-inner-tspan {
|
|
971
|
+
fill: ${t?.includes("redux") ? e.nodeBorder : e["cScaleLabel" + (t === "neutral" ? 1 : 0)]};
|
|
972
|
+
}
|
|
973
|
+
${e.useGradient && n && e.mainBkg ? genGradient(e.THEME_COLOR_LIMIT, n, e.mainBkg) : ""}
|
|
974
|
+
`;
|
|
975
|
+
}, "getStyles")
|
|
930
976
|
};
|
|
931
977
|
export { diagram };
|
|
@@ -0,0 +1,117 @@
|
|
|
1
|
+
import { __name, log } from "./chunk-AGHRB4JF.js";
|
|
2
|
+
import { clear, configureSvgSize, defaultConfig_default, getAccDescription, getAccTitle, getConfig2, getDiagramTitle, setAccDescription, setAccTitle, setDiagramTitle } from "./chunk-ICPOFSXX.js";
|
|
3
|
+
import ordinal from "../../../../d3-scale/src/ordinal.js";
|
|
4
|
+
import arc_default from "../../../../d3-shape/src/arc.js";
|
|
5
|
+
import pie_default from "../../../../d3-shape/src/pie.js";
|
|
6
|
+
import "../../../../d3/src/index.js";
|
|
7
|
+
import { selectSvgElement } from "./chunk-426QAEUC.js";
|
|
8
|
+
import { cleanAndMerge, parseFontSize } from "./chunk-5PVQY5BW.js";
|
|
9
|
+
import { populateCommonDb } from "./chunk-4BX2VUAB.js";
|
|
10
|
+
import { parse } from "../../../../@mermaid-js/parser/dist/mermaid-parser.core.js";
|
|
11
|
+
var DEFAULT_PIE_CONFIG = defaultConfig_default.pie, DEFAULT_PIE_DB = {
|
|
12
|
+
sections: /* @__PURE__ */ new Map(),
|
|
13
|
+
showData: !1,
|
|
14
|
+
config: DEFAULT_PIE_CONFIG
|
|
15
|
+
}, sections = DEFAULT_PIE_DB.sections, showData = DEFAULT_PIE_DB.showData, config = structuredClone(DEFAULT_PIE_CONFIG), db = {
|
|
16
|
+
getConfig: /* @__PURE__ */ __name(() => structuredClone(config), "getConfig"),
|
|
17
|
+
clear: /* @__PURE__ */ __name(() => {
|
|
18
|
+
sections = /* @__PURE__ */ new Map(), showData = DEFAULT_PIE_DB.showData, clear();
|
|
19
|
+
}, "clear"),
|
|
20
|
+
setDiagramTitle,
|
|
21
|
+
getDiagramTitle,
|
|
22
|
+
setAccTitle,
|
|
23
|
+
getAccTitle,
|
|
24
|
+
setAccDescription,
|
|
25
|
+
getAccDescription,
|
|
26
|
+
addSection: /* @__PURE__ */ __name(({ label: t, value: u }) => {
|
|
27
|
+
if (u < 0) throw Error(`"${t}" has invalid value: ${u}. Negative values are not allowed in pie charts. All slice values must be >= 0.`);
|
|
28
|
+
sections.has(t) || (sections.set(t, u), log.debug(`added new section: ${t}, with value: ${u}`));
|
|
29
|
+
}, "addSection"),
|
|
30
|
+
getSections: /* @__PURE__ */ __name(() => sections, "getSections"),
|
|
31
|
+
setShowData: /* @__PURE__ */ __name((t) => {
|
|
32
|
+
showData = t;
|
|
33
|
+
}, "setShowData"),
|
|
34
|
+
getShowData: /* @__PURE__ */ __name(() => showData, "getShowData")
|
|
35
|
+
}, populateDb = /* @__PURE__ */ __name((t, l) => {
|
|
36
|
+
populateCommonDb(t, l), l.setShowData(t.showData), t.sections.map(l.addSection);
|
|
37
|
+
}, "populateDb"), parser = { parse: /* @__PURE__ */ __name(async (t) => {
|
|
38
|
+
let u = await parse("pie", t);
|
|
39
|
+
log.debug(u), populateDb(u, db);
|
|
40
|
+
}, "parse") }, pieStyles_default = /* @__PURE__ */ __name((t) => `
|
|
41
|
+
.pieCircle{
|
|
42
|
+
stroke: ${t.pieStrokeColor};
|
|
43
|
+
stroke-width : ${t.pieStrokeWidth};
|
|
44
|
+
opacity : ${t.pieOpacity};
|
|
45
|
+
}
|
|
46
|
+
.pieOuterCircle{
|
|
47
|
+
stroke: ${t.pieOuterStrokeColor};
|
|
48
|
+
stroke-width: ${t.pieOuterStrokeWidth};
|
|
49
|
+
fill: none;
|
|
50
|
+
}
|
|
51
|
+
.pieTitleText {
|
|
52
|
+
text-anchor: middle;
|
|
53
|
+
font-size: ${t.pieTitleTextSize};
|
|
54
|
+
fill: ${t.pieTitleTextColor};
|
|
55
|
+
font-family: ${t.fontFamily};
|
|
56
|
+
}
|
|
57
|
+
.slice {
|
|
58
|
+
font-family: ${t.fontFamily};
|
|
59
|
+
fill: ${t.pieSectionTextColor};
|
|
60
|
+
font-size:${t.pieSectionTextSize};
|
|
61
|
+
// fill: white;
|
|
62
|
+
}
|
|
63
|
+
.legend text {
|
|
64
|
+
fill: ${t.pieLegendTextColor};
|
|
65
|
+
font-family: ${t.fontFamily};
|
|
66
|
+
font-size: ${t.pieLegendTextSize};
|
|
67
|
+
}
|
|
68
|
+
`, "getStyles"), createPieArcs = /* @__PURE__ */ __name((t) => {
|
|
69
|
+
let l = [...t.values()].reduce((t, l) => t + l, 0), u = [...t.entries()].map(([t, l]) => ({
|
|
70
|
+
label: t,
|
|
71
|
+
value: l
|
|
72
|
+
})).filter((t) => t.value / l * 100 >= 1);
|
|
73
|
+
return pie_default().value((t) => t.value).sort(null)(u);
|
|
74
|
+
}, "createPieArcs"), diagram = {
|
|
75
|
+
parser,
|
|
76
|
+
db,
|
|
77
|
+
renderer: { draw: /* @__PURE__ */ __name((t, u, d, f) => {
|
|
78
|
+
log.debug("rendering pie chart\n" + t);
|
|
79
|
+
let p = f.db, m = getConfig2(), h = cleanAndMerge(p.getConfig(), m.pie), g = selectSvgElement(u), _ = g.append("g");
|
|
80
|
+
_.attr("transform", "translate(225,225)");
|
|
81
|
+
let { themeVariables: v } = m, [y] = parseFontSize(v.pieOuterStrokeWidth);
|
|
82
|
+
y ??= 2;
|
|
83
|
+
let b = h.textPosition, x = arc_default().innerRadius(0).outerRadius(185), S = arc_default().innerRadius(185 * b).outerRadius(185 * b);
|
|
84
|
+
_.append("circle").attr("cx", 0).attr("cy", 0).attr("r", 185 + y / 2).attr("class", "pieOuterCircle");
|
|
85
|
+
let C = p.getSections(), w = createPieArcs(C), T = [
|
|
86
|
+
v.pie1,
|
|
87
|
+
v.pie2,
|
|
88
|
+
v.pie3,
|
|
89
|
+
v.pie4,
|
|
90
|
+
v.pie5,
|
|
91
|
+
v.pie6,
|
|
92
|
+
v.pie7,
|
|
93
|
+
v.pie8,
|
|
94
|
+
v.pie9,
|
|
95
|
+
v.pie10,
|
|
96
|
+
v.pie11,
|
|
97
|
+
v.pie12
|
|
98
|
+
], E = 0;
|
|
99
|
+
C.forEach((t) => {
|
|
100
|
+
E += t;
|
|
101
|
+
});
|
|
102
|
+
let D = w.filter((t) => (t.data.value / E * 100).toFixed(0) !== "0"), O = ordinal(T).domain([...C.keys()]);
|
|
103
|
+
_.selectAll("mySlices").data(D).enter().append("path").attr("d", x).attr("fill", (t) => O(t.data.label)).attr("class", "pieCircle"), _.selectAll("mySlices").data(D).enter().append("text").text((t) => (t.data.value / E * 100).toFixed(0) + "%").attr("transform", (t) => "translate(" + S.centroid(t) + ")").style("text-anchor", "middle").attr("class", "slice");
|
|
104
|
+
let k = _.append("text").text(p.getDiagramTitle()).attr("x", 0).attr("y", -400 / 2).attr("class", "pieTitleText"), A = [...C.entries()].map(([t, l]) => ({
|
|
105
|
+
label: t,
|
|
106
|
+
value: l
|
|
107
|
+
})), j = _.selectAll(".legend").data(A).enter().append("g").attr("class", "legend").attr("transform", (t, l) => {
|
|
108
|
+
let u = 22 * A.length / 2;
|
|
109
|
+
return "translate(216," + (l * 22 - u) + ")";
|
|
110
|
+
});
|
|
111
|
+
j.append("rect").attr("width", 18).attr("height", 18).style("fill", (t) => O(t.label)).style("stroke", (t) => O(t.label)), j.append("text").attr("x", 22).attr("y", 14).text((t) => p.getShowData() ? `${t.label} [${t.value}]` : t.label);
|
|
112
|
+
let M = 512 + Math.max(...j.selectAll("text").nodes().map((t) => t?.getBoundingClientRect().width ?? 0)), N = k.node()?.getBoundingClientRect().width ?? 0, P = 450 / 2 - N / 2, F = 450 / 2 + N / 2, I = Math.min(0, P), L = Math.max(M, F) - I;
|
|
113
|
+
g.attr("viewBox", `${I} 0 ${L} 450`), configureSvgSize(g, 450, L, h.useMaxWidth);
|
|
114
|
+
}, "draw") },
|
|
115
|
+
styles: pieStyles_default
|
|
116
|
+
};
|
|
117
|
+
export { diagram };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { __name, log } from "./chunk-AGHRB4JF.js";
|
|
2
|
-
import { clear, configureSvgSize, defaultConfig_default, getAccDescription, getAccTitle, getConfig2, getDiagramTitle, getThemeVariables3, sanitizeText, setAccDescription, setAccTitle, setDiagramTitle } from "./chunk-
|
|
2
|
+
import { clear, configureSvgSize, defaultConfig_default, getAccDescription, getAccTitle, getConfig2, getDiagramTitle, getThemeVariables3, sanitizeText, setAccDescription, setAccTitle, setDiagramTitle } from "./chunk-ICPOFSXX.js";
|
|
3
3
|
import select_default from "../../../../d3-selection/src/select.js";
|
|
4
4
|
import linear from "../../../../d3-scale/src/linear.js";
|
|
5
5
|
import "../../../../d3/src/index.js";
|