@schmitech/chatbot-widget 0.5.3 → 0.6.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 (64) hide show
  1. package/dist/_basePickBy-C3-QE0dl-5eQ6L29l.js +152 -0
  2. package/dist/_baseUniq-CstiM9Lp-AFR_Ns0a.js +615 -0
  3. package/dist/arc-W3NKKXLI-DHbDwLx0.js +84 -0
  4. package/dist/architecture-U656AL7Q-fn9wJZsH-BLoGjtkP.js +6 -0
  5. package/dist/architectureDiagram-VXUJARFQ-zzJsgPC6-C4OfUE0m.js +4667 -0
  6. package/dist/blockDiagram-VD42YOAC-D-In4h7h-BYXdRmeG.js +2266 -0
  7. package/dist/c4Diagram-YG6GDRKO-DBs8r9gh-BdLuHgPT.js +1582 -0
  8. package/dist/channel-RBWQyMSg-Cx0HUumY.js +6 -0
  9. package/dist/chatbot-widget.bundle.js +4473 -1556
  10. package/dist/chatbot-widget.css +1 -1
  11. package/dist/chatbot-widget.es.js +12 -63659
  12. package/dist/chatbot-widget.umd.js +4472 -1555
  13. package/dist/chunk-4BX2VUAB-BqD7w0AR-CbA2613c.js +10 -0
  14. package/dist/chunk-55IACEB6-D8pvDVEJ-DrL4SJSR.js +9 -0
  15. package/dist/chunk-B4BG7PRW-Dwma1pSy-BWjG5dc6.js +1375 -0
  16. package/dist/chunk-DI55MBZ5-BY2XXvZz-DbAvz3Pq.js +1383 -0
  17. package/dist/chunk-FMBD7UC4-BeiLbQ8U-BNaZTCv4.js +20 -0
  18. package/dist/chunk-QN33PNHL-BkO3hOeq-DkU1EzGA.js +21 -0
  19. package/dist/chunk-QZHKN3VN-Cwlo2qTG-DMmeZmp5.js +16 -0
  20. package/dist/chunk-TZMSLE5B-BnXK-OiF-RfzVsOBe.js +65 -0
  21. package/dist/classDiagram-2ON5EDUG-Crd6O69V-kCZrFOLN.js +17 -0
  22. package/dist/classDiagram-v2-WZHVMYZB-Crd6O69V-kCZrFOLN.js +17 -0
  23. package/dist/clone-CfLgyC8S-DsDOh4B4.js +9 -0
  24. package/dist/config/index.d.ts +4 -2
  25. package/dist/cose-bilkent-S5V4N54A-DKeVcPDK-de_7nZTY.js +2609 -0
  26. package/dist/cytoscape.esm-CjI2IsL8-Be2K4mI6.js +18723 -0
  27. package/dist/dagre-6UL2VRFP-BPf604Df-BhZs6zCq.js +448 -0
  28. package/dist/diagram-PSM6KHXK-DeLcpEV3-qb4rujeN.js +532 -0
  29. package/dist/diagram-QEK2KX5R-C_5RR1NJ-C5kZWmRl.js +222 -0
  30. package/dist/diagram-S2PKOQOG-DVx43aon-4nlw6iDz.js +144 -0
  31. package/dist/erDiagram-Q2GNP2WA-DgUeO5_h-DHc9Yphl.js +841 -0
  32. package/dist/flowDiagram-NV44I4VS-C5HQUzU9-DHjbmAtJ.js +1628 -0
  33. package/dist/ganttDiagram-JELNMOA3-DgSZ1ixF-C3hJs_k9.js +1936 -0
  34. package/dist/gitGraph-F6HP7TQM-UL7-Bx1s-Cog5rj3j.js +6 -0
  35. package/dist/gitGraphDiagram-NY62KEGX-DY5loT9K-CEcKQNrM.js +713 -0
  36. package/dist/graph-BfwqPHx6-DErF9dBN.js +248 -0
  37. package/dist/index-B5s_uaP2.js +124168 -0
  38. package/dist/index-BAOVR-xx-thst7Pu6.js +13251 -0
  39. package/dist/info-NVLQJR56-BsqQ0RXQ-BcYgZCCY.js +6 -0
  40. package/dist/infoDiagram-WHAUD3N6-DIqQ6vCk-BuiAAMSH.js +25 -0
  41. package/dist/journeyDiagram-XKPGCS4Q-DXjg3S3r-Byi_TGXs.js +835 -0
  42. package/dist/kanban-definition-3W4ZIXB7-Uxt7Am6n-jy96nA-g.js +721 -0
  43. package/dist/layout-CSfkE668-BjigbqJL.js +1333 -0
  44. package/dist/mermaid-parser.core-LjuO4CL3-BLqmPe8-.js +12891 -0
  45. package/dist/mindmap-definition-VGOIOE7T-DXwVuAPE-SK4e1Sse.js +787 -0
  46. package/dist/packet-BFZMPI3H-DJWkrKrV-BamBev9S.js +6 -0
  47. package/dist/pie-7BOR55EZ-DC8hTFwn-D1bcIQbR.js +6 -0
  48. package/dist/pieDiagram-ADFJNKIX-Cj0EHHtj-Dbr09c-S.js +161 -0
  49. package/dist/quadrantDiagram-AYHSOK5B-CnLDz007-Ci0DQl2T.js +1024 -0
  50. package/dist/radar-NHE76QYJ-Bijk-Fk9-9nAmDCMr.js +6 -0
  51. package/dist/requirementDiagram-UZGBJVZJ-rDaI-8Be-CSEc4S33.js +851 -0
  52. package/dist/sankeyDiagram-TZEHDZUN-A0YO8ixs-Zj8Z0j0n.js +810 -0
  53. package/dist/sequenceDiagram-WL72ISMW-BFF7TtP7-Dcofckjv.js +2519 -0
  54. package/dist/shared/styles.d.ts +1 -1
  55. package/dist/stateDiagram-FKZM4ZOC-ofFsB7HJ-BJBX12rE.js +264 -0
  56. package/dist/stateDiagram-v2-4FDKWEC3-CEZFbksU-BywmU88h.js +17 -0
  57. package/dist/timeline-definition-IT6M3QCI-5W361ZNm-MP_ufVe7.js +800 -0
  58. package/dist/treemap-KMMF4GRG-pGRoYcSn-BeZ7sXgP.js +6 -0
  59. package/dist/ui/Message.d.ts +1 -5
  60. package/dist/ui/MessagesList.d.ts +1 -5
  61. package/dist/utils/contentFiltering.d.ts +12 -0
  62. package/dist/xychartDiagram-PRI3JC2R-CSr0GxaP-DBgCtplP.js +1297 -0
  63. package/package.json +3 -3
  64. package/dist/ui/TypingEffect.d.ts +0 -18
@@ -0,0 +1,6 @@
1
+ import { u as a, c as d } from "./mermaid-parser.core-LjuO4CL3-BLqmPe8-.js";
2
+ typeof window < "u" && (window.global = window);
3
+ export {
4
+ a as PacketModule,
5
+ d as createPacketServices
6
+ };
@@ -0,0 +1,6 @@
1
+ import { h as o, p as d } from "./mermaid-parser.core-LjuO4CL3-BLqmPe8-.js";
2
+ typeof window < "u" && (window.global = window);
3
+ export {
4
+ o as PieModule,
5
+ d as createPieServices
6
+ };
@@ -0,0 +1,161 @@
1
+ import { x as c, B as U, h as _, g as j, u as H, z as J, w as K, a as O, p as X, Q as Y, al as Z, an as ee, ao as te, G as ae, L as ne, T as ie, ap as x, aq as re, ar as z } from "./index-B5s_uaP2.js";
2
+ import { m as le } from "./chunk-4BX2VUAB-BqD7w0AR-CbA2613c.js";
3
+ import { N as se } from "./mermaid-parser.core-LjuO4CL3-BLqmPe8-.js";
4
+ import { h as G } from "./arc-W3NKKXLI-DHbDwLx0.js";
5
+ typeof window < "u" && (window.global = window);
6
+ function oe(e, a) {
7
+ return a < e ? -1 : a > e ? 1 : a >= e ? 0 : NaN;
8
+ }
9
+ function pe(e) {
10
+ return e;
11
+ }
12
+ function ue() {
13
+ var e = pe, a = oe, g = null, s = x(0), o = x(z), y = x(0);
14
+ function l(t) {
15
+ var i, p = (t = re(t)).length, d, v, w = 0, u = new Array(p), r = new Array(p), h = +s.apply(this, arguments), S = Math.min(z, Math.max(-z, o.apply(this, arguments) - h)), m, b = Math.min(Math.abs(S) / p, y.apply(this, arguments)), C = b * (S < 0 ? -1 : 1), f;
16
+ for (i = 0; i < p; ++i)
17
+ (f = r[u[i] = i] = +e(t[i], i, t)) > 0 && (w += f);
18
+ for (a != null ? u.sort(function($, A) {
19
+ return a(r[$], r[A]);
20
+ }) : g != null && u.sort(function($, A) {
21
+ return g(t[$], t[A]);
22
+ }), i = 0, v = w ? (S - p * C) / w : 0; i < p; ++i, h = m)
23
+ d = u[i], f = r[d], m = h + (f > 0 ? f * v : 0) + C, r[d] = {
24
+ data: t[d],
25
+ index: i,
26
+ value: f,
27
+ startAngle: h,
28
+ endAngle: m,
29
+ padAngle: b
30
+ };
31
+ return r;
32
+ }
33
+ return l.value = function(t) {
34
+ return arguments.length ? (e = typeof t == "function" ? t : x(+t), l) : e;
35
+ }, l.sortValues = function(t) {
36
+ return arguments.length ? (a = t, g = null, l) : a;
37
+ }, l.sort = function(t) {
38
+ return arguments.length ? (g = t, a = null, l) : g;
39
+ }, l.startAngle = function(t) {
40
+ return arguments.length ? (s = typeof t == "function" ? t : x(+t), l) : s;
41
+ }, l.endAngle = function(t) {
42
+ return arguments.length ? (o = typeof t == "function" ? t : x(+t), l) : o;
43
+ }, l.padAngle = function(t) {
44
+ return arguments.length ? (y = typeof t == "function" ? t : x(+t), l) : y;
45
+ }, l;
46
+ }
47
+ var ce = ie.pie, R = {
48
+ sections: /* @__PURE__ */ new Map(),
49
+ showData: !1
50
+ }, T = R.sections, B = R.showData, de = structuredClone(ce), fe = /* @__PURE__ */ c(() => structuredClone(de), "getConfig"), ge = /* @__PURE__ */ c(() => {
51
+ T = /* @__PURE__ */ new Map(), B = R.showData, ne();
52
+ }, "clear"), he = /* @__PURE__ */ c(({ label: e, value: a }) => {
53
+ if (a < 0)
54
+ throw new Error(
55
+ `"${e}" has invalid value: ${a}. Negative values are not allowed in pie charts. All slice values must be >= 0.`
56
+ );
57
+ T.has(e) || (T.set(e, a), O.debug(`added new section: ${e}, with value: ${a}`));
58
+ }, "addSection"), me = /* @__PURE__ */ c(() => T, "getSections"), we = /* @__PURE__ */ c((e) => {
59
+ B = e;
60
+ }, "setShowData"), xe = /* @__PURE__ */ c(() => B, "getShowData"), V = {
61
+ getConfig: fe,
62
+ clear: ge,
63
+ setDiagramTitle: K,
64
+ getDiagramTitle: J,
65
+ setAccTitle: H,
66
+ getAccTitle: j,
67
+ setAccDescription: _,
68
+ getAccDescription: U,
69
+ addSection: he,
70
+ getSections: me,
71
+ setShowData: we,
72
+ getShowData: xe
73
+ }, ye = /* @__PURE__ */ c((e, a) => {
74
+ le(e, a), a.setShowData(e.showData), e.sections.map(a.addSection);
75
+ }, "populateDb"), ve = {
76
+ parse: /* @__PURE__ */ c(async (e) => {
77
+ const a = await se("pie", e);
78
+ O.debug(a), ye(a, V);
79
+ }, "parse")
80
+ }, Se = /* @__PURE__ */ c((e) => `
81
+ .pieCircle{
82
+ stroke: ${e.pieStrokeColor};
83
+ stroke-width : ${e.pieStrokeWidth};
84
+ opacity : ${e.pieOpacity};
85
+ }
86
+ .pieOuterCircle{
87
+ stroke: ${e.pieOuterStrokeColor};
88
+ stroke-width: ${e.pieOuterStrokeWidth};
89
+ fill: none;
90
+ }
91
+ .pieTitleText {
92
+ text-anchor: middle;
93
+ font-size: ${e.pieTitleTextSize};
94
+ fill: ${e.pieTitleTextColor};
95
+ font-family: ${e.fontFamily};
96
+ }
97
+ .slice {
98
+ font-family: ${e.fontFamily};
99
+ fill: ${e.pieSectionTextColor};
100
+ font-size:${e.pieSectionTextSize};
101
+ // fill: white;
102
+ }
103
+ .legend text {
104
+ fill: ${e.pieLegendTextColor};
105
+ font-family: ${e.fontFamily};
106
+ font-size: ${e.pieLegendTextSize};
107
+ }
108
+ `, "getStyles"), $e = Se, Ae = /* @__PURE__ */ c((e) => {
109
+ const a = [...e.values()].reduce((s, o) => s + o, 0), g = [...e.entries()].map(([s, o]) => ({ label: s, value: o })).filter((s) => s.value / a * 100 >= 1).sort((s, o) => o.value - s.value);
110
+ return ue().value((s) => s.value)(g);
111
+ }, "createPieArcs"), be = /* @__PURE__ */ c((e, a, g, s) => {
112
+ O.debug(`rendering pie chart
113
+ ` + e);
114
+ const o = s.db, y = X(), l = Y(o.getConfig(), y.pie), t = 40, i = 18, p = 4, d = 450, v = d, w = Z(a), u = w.append("g");
115
+ u.attr("transform", "translate(" + v / 2 + "," + d / 2 + ")");
116
+ const { themeVariables: r } = y;
117
+ let [h] = ee(r.pieOuterStrokeWidth);
118
+ h ?? (h = 2);
119
+ const S = l.textPosition, m = Math.min(v, d) / 2 - t, b = G().innerRadius(0).outerRadius(m), C = G().innerRadius(m * S).outerRadius(m * S);
120
+ u.append("circle").attr("cx", 0).attr("cy", 0).attr("r", m + h / 2).attr("class", "pieOuterCircle");
121
+ const f = o.getSections(), $ = Ae(f), A = [
122
+ r.pie1,
123
+ r.pie2,
124
+ r.pie3,
125
+ r.pie4,
126
+ r.pie5,
127
+ r.pie6,
128
+ r.pie7,
129
+ r.pie8,
130
+ r.pie9,
131
+ r.pie10,
132
+ r.pie11,
133
+ r.pie12
134
+ ];
135
+ let D = 0;
136
+ f.forEach((n) => {
137
+ D += n;
138
+ });
139
+ const F = $.filter((n) => (n.data.value / D * 100).toFixed(0) !== "0"), k = te(A);
140
+ u.selectAll("mySlices").data(F).enter().append("path").attr("d", b).attr("fill", (n) => k(n.data.label)).attr("class", "pieCircle"), u.selectAll("mySlices").data(F).enter().append("text").text((n) => (n.data.value / D * 100).toFixed(0) + "%").attr("transform", (n) => "translate(" + C.centroid(n) + ")").style("text-anchor", "middle").attr("class", "slice"), u.append("text").text(o.getDiagramTitle()).attr("x", 0).attr("y", -400 / 2).attr("class", "pieTitleText");
141
+ const W = [...f.entries()].map(([n, N]) => ({
142
+ label: n,
143
+ value: N
144
+ })), M = u.selectAll(".legend").data(W).enter().append("g").attr("class", "legend").attr("transform", (n, N) => {
145
+ const E = i + p, P = E * W.length / 2, I = 12 * i, Q = N * E - P;
146
+ return "translate(" + I + "," + Q + ")";
147
+ });
148
+ M.append("rect").attr("width", i).attr("height", i).style("fill", (n) => k(n.label)).style("stroke", (n) => k(n.label)), M.append("text").attr("x", i + p).attr("y", i - p).text((n) => o.getShowData() ? `${n.label} [${n.value}]` : n.label);
149
+ const q = Math.max(
150
+ ...M.selectAll("text").nodes().map((n) => (n == null ? void 0 : n.getBoundingClientRect().width) ?? 0)
151
+ ), L = v + t + i + p + q;
152
+ w.attr("viewBox", `0 0 ${L} ${d}`), ae(w, d, L, l.useMaxWidth);
153
+ }, "draw"), Ce = { draw: be }, Ne = {
154
+ parser: ve,
155
+ db: V,
156
+ renderer: Ce,
157
+ styles: $e
158
+ };
159
+ export {
160
+ Ne as diagram
161
+ };