lowcoder-comps 2.7.0 → 2.7.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.
Files changed (45) hide show
  1. package/{575d052e.js → 06bfc8fd.js} +2 -2
  2. package/{7ee7d206.js → 0bc1e750.js} +103 -103
  3. package/{2d79a059.js → 16017dca.js} +1 -1
  4. package/{f2f8423b.js → 188d0a7b.js} +1 -1
  5. package/194933bf.js +21942 -0
  6. package/{fb2284fb.js → 1d548e39.js} +30 -30
  7. package/{92ccb52a.js → 1e6f66fd.js} +4 -4
  8. package/{d32ed410.js → 250dc9f4.js} +11 -11
  9. package/2bab86ad.js +2318 -0
  10. package/{b709e4ac.js → 38362e7c.js} +1 -1
  11. package/{7b30136a.js → 455488fd.js} +2 -2
  12. package/{1a85736c.js → 456027f3.js} +10 -10
  13. package/{0c94161b.js → 4626b6f8.js} +1 -1
  14. package/{0875e0ee.js → 46b8527c.js} +3 -3
  15. package/{4a778606.js → 50383021.js} +1 -1
  16. package/{165388c9.js → 514e4c08.js} +1 -1
  17. package/{a01a1670.js → 5e5d535b.js} +6 -2
  18. package/{1011233b.js → 78f1ff0d.js} +9 -9
  19. package/{aa1ac4eb.js → 816637dc.js} +82976 -86208
  20. package/{9d4e082b.js → 822253e7.js} +2 -2
  21. package/{3f502d2c.js → 87065cc7.js} +1 -1
  22. package/{3d682784.js → 91e84a61.js} +1 -1
  23. package/{34a2ef89.js → 9a7ae50a.js} +4 -4
  24. package/{e99ac745.js → 9dbba476.js} +5 -5
  25. package/{7230d7a3.js → a23f123d.js} +5 -5
  26. package/{be7ead05.js → ac024963.js} +1 -1
  27. package/{4e4e0b0b.js → ba8c6a16.js} +29 -29
  28. package/{65b79f3d.js → c5be1d77.js} +9 -9
  29. package/{f731f7f5.js → cbf03099.js} +2 -2
  30. package/{44256eb5.js → d29b1617.js} +4 -4
  31. package/{18df5327.js → d4b2d80a.js} +2 -2
  32. package/{0a4b51f0.js → d5dbb80b.js} +6 -6
  33. package/{06898aa9.js → d708b9ba.js} +5 -5
  34. package/{e5b014a9.js → e8a70b0f.js} +932 -868
  35. package/{ab815524.js → e9f334a4.js} +22 -22
  36. package/{6f1475e9.js → f06f653d.js} +1 -1
  37. package/{dbb8ea50.js → fb7b2a8c.js} +1 -1
  38. package/{c6a4ccfb.js → ff57e9e3.js} +3 -3
  39. package/ffd1bcb0.js +86 -0
  40. package/{a9cfdef0.js → fff3acf7.js} +11 -11
  41. package/index.js +3 -3
  42. package/package.json +5 -5
  43. package/138f460f.js +0 -19321
  44. package/67dbec5c.js +0 -2501
  45. package/9f8be921.js +0 -86
package/2bab86ad.js ADDED
@@ -0,0 +1,2318 @@
1
+ import { M as Pe, N as Re, R as ze, O as je, P as bn, Q as Kt, T as vn, c as xn, g as wn, U as Cn, V as Dn, e as xt, s as Mn, a as _n, F as Sn, G as Un, d as Fn, b as En, H as An, o as In, l as qt, j as Pt, k as Yn, m as Ln, C as Wn } from "./816637dc.js";
2
+ import { b as On, t as Me, c as Nn, a as Hn, l as Vn } from "./f06f653d.js";
3
+ import { i as Pn } from "./f9637058.js";
4
+ function Rn(t, e) {
5
+ let n;
6
+ if (e === void 0)
7
+ for (const r of t)
8
+ r != null && (n < r || n === void 0 && r >= r) && (n = r);
9
+ else {
10
+ let r = -1;
11
+ for (let i of t)
12
+ (i = e(i, ++r, t)) != null && (n < i || n === void 0 && i >= i) && (n = i);
13
+ }
14
+ return n;
15
+ }
16
+ function zn(t, e) {
17
+ let n;
18
+ if (e === void 0)
19
+ for (const r of t)
20
+ r != null && (n > r || n === void 0 && r >= r) && (n = r);
21
+ else {
22
+ let r = -1;
23
+ for (let i of t)
24
+ (i = e(i, ++r, t)) != null && (n > i || n === void 0 && i >= i) && (n = i);
25
+ }
26
+ return n;
27
+ }
28
+ function jn(t) {
29
+ return t;
30
+ }
31
+ var zt = 1, $t = 2, le = 3, Rt = 4, _e = 1e-6;
32
+ function Bn(t) {
33
+ return "translate(" + t + ",0)";
34
+ }
35
+ function qn(t) {
36
+ return "translate(0," + t + ")";
37
+ }
38
+ function Zn(t) {
39
+ return (e) => +t(e);
40
+ }
41
+ function Xn(t, e) {
42
+ return e = Math.max(0, t.bandwidth() - e * 2) / 2, t.round() && (e = Math.round(e)), (n) => +t(n) + e;
43
+ }
44
+ function Qn() {
45
+ return !this.__axis;
46
+ }
47
+ function Be(t, e) {
48
+ var n = [], r = null, i = null, s = 6, a = 6, x = 3, S = typeof window < "u" && window.devicePixelRatio > 1 ? 0 : 0.5, k = t === zt || t === Rt ? -1 : 1, p = t === Rt || t === $t ? "x" : "y", F = t === zt || t === le ? Bn : qn;
49
+ function T(g) {
50
+ var P = r ?? (e.ticks ? e.ticks.apply(e, n) : e.domain()), E = i ?? (e.tickFormat ? e.tickFormat.apply(e, n) : jn), $ = Math.max(s, 0) + x, et = e.range(), tt = +et[0] + S, B = +et[et.length - 1] + S, q = (e.bandwidth ? Xn : Zn)(e.copy(), S), K = g.selection ? g.selection() : g, v = K.selectAll(".domain").data([null]), H = K.selectAll(".tick").data(P, e).order(), b = H.exit(), U = H.enter().append("g").attr("class", "tick"), _ = H.select("line"), w = H.select("text");
51
+ v = v.merge(v.enter().insert("path", ".tick").attr("class", "domain").attr("stroke", "currentColor")), H = H.merge(U), _ = _.merge(U.append("line").attr("stroke", "currentColor").attr(p + "2", k * s)), w = w.merge(U.append("text").attr("fill", "currentColor").attr(p, k * $).attr("dy", t === zt ? "0em" : t === le ? "0.71em" : "0.32em")), g !== K && (v = v.transition(g), H = H.transition(g), _ = _.transition(g), w = w.transition(g), b = b.transition(g).attr("opacity", _e).attr("transform", function(c) {
52
+ return isFinite(c = q(c)) ? F(c + S) : this.getAttribute("transform");
53
+ }), U.attr("opacity", _e).attr("transform", function(c) {
54
+ var d = this.parentNode.__axis;
55
+ return F((d && isFinite(d = d(c)) ? d : q(c)) + S);
56
+ })), b.remove(), v.attr("d", t === Rt || t === $t ? a ? "M" + k * a + "," + tt + "H" + S + "V" + B + "H" + k * a : "M" + S + "," + tt + "V" + B : a ? "M" + tt + "," + k * a + "V" + S + "H" + B + "V" + k * a : "M" + tt + "," + S + "H" + B), H.attr("opacity", 1).attr("transform", function(c) {
57
+ return F(q(c) + S);
58
+ }), _.attr(p + "2", k * s), w.attr(p, k * $).text(E), K.filter(Qn).attr("fill", "none").attr("font-size", 10).attr("font-family", "sans-serif").attr("text-anchor", t === $t ? "start" : t === Rt ? "end" : "middle"), K.each(function() {
59
+ this.__axis = q;
60
+ });
61
+ }
62
+ return T.scale = function(g) {
63
+ return arguments.length ? (e = g, T) : e;
64
+ }, T.ticks = function() {
65
+ return n = Array.from(arguments), T;
66
+ }, T.tickArguments = function(g) {
67
+ return arguments.length ? (n = g == null ? [] : Array.from(g), T) : n.slice();
68
+ }, T.tickValues = function(g) {
69
+ return arguments.length ? (r = g == null ? null : Array.from(g), T) : r && r.slice();
70
+ }, T.tickFormat = function(g) {
71
+ return arguments.length ? (i = g, T) : i;
72
+ }, T.tickSize = function(g) {
73
+ return arguments.length ? (s = a = +g, T) : s;
74
+ }, T.tickSizeInner = function(g) {
75
+ return arguments.length ? (s = +g, T) : s;
76
+ }, T.tickSizeOuter = function(g) {
77
+ return arguments.length ? (a = +g, T) : a;
78
+ }, T.tickPadding = function(g) {
79
+ return arguments.length ? (x = +g, T) : x;
80
+ }, T.offset = function(g) {
81
+ return arguments.length ? (S = +g, T) : S;
82
+ }, T;
83
+ }
84
+ function Gn(t) {
85
+ return Be(zt, t);
86
+ }
87
+ function Jn(t) {
88
+ return Be(le, t);
89
+ }
90
+ const Kn = Math.PI / 180, $n = 180 / Math.PI, Zt = 18, qe = 0.96422, Ze = 1, Xe = 0.82521, Qe = 4 / 29, wt = 6 / 29, Ge = 3 * wt * wt, tr = wt * wt * wt;
91
+ function Je(t) {
92
+ if (t instanceof it)
93
+ return new it(t.l, t.a, t.b, t.opacity);
94
+ if (t instanceof ot)
95
+ return Ke(t);
96
+ t instanceof ze || (t = bn(t));
97
+ var e = re(t.r), n = re(t.g), r = re(t.b), i = te((0.2225045 * e + 0.7168786 * n + 0.0606169 * r) / Ze), s, a;
98
+ return e === n && n === r ? s = a = i : (s = te((0.4360747 * e + 0.3850649 * n + 0.1430804 * r) / qe), a = te((0.0139322 * e + 0.0971045 * n + 0.7141733 * r) / Xe)), new it(116 * i - 16, 500 * (s - i), 200 * (i - a), t.opacity);
99
+ }
100
+ function er(t, e, n, r) {
101
+ return arguments.length === 1 ? Je(t) : new it(t, e, n, r ?? 1);
102
+ }
103
+ function it(t, e, n, r) {
104
+ this.l = +t, this.a = +e, this.b = +n, this.opacity = +r;
105
+ }
106
+ Pe(it, er, Re(je, {
107
+ brighter(t) {
108
+ return new it(this.l + Zt * (t ?? 1), this.a, this.b, this.opacity);
109
+ },
110
+ darker(t) {
111
+ return new it(this.l - Zt * (t ?? 1), this.a, this.b, this.opacity);
112
+ },
113
+ rgb() {
114
+ var t = (this.l + 16) / 116, e = isNaN(this.a) ? t : t + this.a / 500, n = isNaN(this.b) ? t : t - this.b / 200;
115
+ return e = qe * ee(e), t = Ze * ee(t), n = Xe * ee(n), new ze(
116
+ ne(3.1338561 * e - 1.6168667 * t - 0.4906146 * n),
117
+ ne(-0.9787684 * e + 1.9161415 * t + 0.033454 * n),
118
+ ne(0.0719453 * e - 0.2289914 * t + 1.4052427 * n),
119
+ this.opacity
120
+ );
121
+ }
122
+ }));
123
+ function te(t) {
124
+ return t > tr ? Math.pow(t, 1 / 3) : t / Ge + Qe;
125
+ }
126
+ function ee(t) {
127
+ return t > wt ? t * t * t : Ge * (t - Qe);
128
+ }
129
+ function ne(t) {
130
+ return 255 * (t <= 31308e-7 ? 12.92 * t : 1.055 * Math.pow(t, 1 / 2.4) - 0.055);
131
+ }
132
+ function re(t) {
133
+ return (t /= 255) <= 0.04045 ? t / 12.92 : Math.pow((t + 0.055) / 1.055, 2.4);
134
+ }
135
+ function nr(t) {
136
+ if (t instanceof ot)
137
+ return new ot(t.h, t.c, t.l, t.opacity);
138
+ if (t instanceof it || (t = Je(t)), t.a === 0 && t.b === 0)
139
+ return new ot(NaN, 0 < t.l && t.l < 100 ? 0 : NaN, t.l, t.opacity);
140
+ var e = Math.atan2(t.b, t.a) * $n;
141
+ return new ot(e < 0 ? e + 360 : e, Math.sqrt(t.a * t.a + t.b * t.b), t.l, t.opacity);
142
+ }
143
+ function ue(t, e, n, r) {
144
+ return arguments.length === 1 ? nr(t) : new ot(t, e, n, r ?? 1);
145
+ }
146
+ function ot(t, e, n, r) {
147
+ this.h = +t, this.c = +e, this.l = +n, this.opacity = +r;
148
+ }
149
+ function Ke(t) {
150
+ if (isNaN(t.h))
151
+ return new it(t.l, 0, 0, t.opacity);
152
+ var e = t.h * Kn;
153
+ return new it(t.l, Math.cos(e) * t.c, Math.sin(e) * t.c, t.opacity);
154
+ }
155
+ Pe(ot, ue, Re(je, {
156
+ brighter(t) {
157
+ return new ot(this.h, this.c, this.l + Zt * (t ?? 1), this.opacity);
158
+ },
159
+ darker(t) {
160
+ return new ot(this.h, this.c, this.l - Zt * (t ?? 1), this.opacity);
161
+ },
162
+ rgb() {
163
+ return Ke(this).rgb();
164
+ }
165
+ }));
166
+ function rr(t) {
167
+ return function(e, n) {
168
+ var r = t((e = ue(e)).h, (n = ue(n)).h), i = Kt(e.c, n.c), s = Kt(e.l, n.l), a = Kt(e.opacity, n.opacity);
169
+ return function(x) {
170
+ return e.h = r(x), e.c = i(x), e.l = s(x), e.opacity = a(x), e + "";
171
+ };
172
+ };
173
+ }
174
+ const ir = rr(vn);
175
+ function sr(t, e) {
176
+ t = t.slice();
177
+ var n = 0, r = t.length - 1, i = t[n], s = t[r], a;
178
+ return s < i && (a = n, n = r, r = a, a = i, i = s, s = a), t[n] = e.floor(i), t[r] = e.ceil(s), t;
179
+ }
180
+ const ie = /* @__PURE__ */ new Date(), se = /* @__PURE__ */ new Date();
181
+ function X(t, e, n, r) {
182
+ function i(s) {
183
+ return t(s = arguments.length === 0 ? /* @__PURE__ */ new Date() : /* @__PURE__ */ new Date(+s)), s;
184
+ }
185
+ return i.floor = (s) => (t(s = /* @__PURE__ */ new Date(+s)), s), i.ceil = (s) => (t(s = new Date(s - 1)), e(s, 1), t(s), s), i.round = (s) => {
186
+ const a = i(s), x = i.ceil(s);
187
+ return s - a < x - s ? a : x;
188
+ }, i.offset = (s, a) => (e(s = /* @__PURE__ */ new Date(+s), a == null ? 1 : Math.floor(a)), s), i.range = (s, a, x) => {
189
+ const S = [];
190
+ if (s = i.ceil(s), x = x == null ? 1 : Math.floor(x), !(s < a) || !(x > 0))
191
+ return S;
192
+ let k;
193
+ do
194
+ S.push(k = /* @__PURE__ */ new Date(+s)), e(s, x), t(s);
195
+ while (k < s && s < a);
196
+ return S;
197
+ }, i.filter = (s) => X((a) => {
198
+ if (a >= a)
199
+ for (; t(a), !s(a); )
200
+ a.setTime(a - 1);
201
+ }, (a, x) => {
202
+ if (a >= a)
203
+ if (x < 0)
204
+ for (; ++x <= 0; )
205
+ for (; e(a, -1), !s(a); )
206
+ ;
207
+ else
208
+ for (; --x >= 0; )
209
+ for (; e(a, 1), !s(a); )
210
+ ;
211
+ }), n && (i.count = (s, a) => (ie.setTime(+s), se.setTime(+a), t(ie), t(se), Math.floor(n(ie, se))), i.every = (s) => (s = Math.floor(s), !isFinite(s) || !(s > 0) ? null : s > 1 ? i.filter(r ? (a) => r(a) % s === 0 : (a) => i.count(0, a) % s === 0) : i)), i;
212
+ }
213
+ const Dt = X(() => {
214
+ }, (t, e) => {
215
+ t.setTime(+t + e);
216
+ }, (t, e) => e - t);
217
+ Dt.every = (t) => (t = Math.floor(t), !isFinite(t) || !(t > 0) ? null : t > 1 ? X((e) => {
218
+ e.setTime(Math.floor(e / t) * t);
219
+ }, (e, n) => {
220
+ e.setTime(+e + n * t);
221
+ }, (e, n) => (n - e) / t) : Dt);
222
+ Dt.range;
223
+ const ct = 1e3, nt = ct * 60, lt = nt * 60, ut = lt * 24, ye = ut * 7, Se = ut * 30, ae = ut * 365, ht = X((t) => {
224
+ t.setTime(t - t.getMilliseconds());
225
+ }, (t, e) => {
226
+ t.setTime(+t + e * ct);
227
+ }, (t, e) => (e - t) / ct, (t) => t.getUTCSeconds());
228
+ ht.range;
229
+ const At = X((t) => {
230
+ t.setTime(t - t.getMilliseconds() - t.getSeconds() * ct);
231
+ }, (t, e) => {
232
+ t.setTime(+t + e * nt);
233
+ }, (t, e) => (e - t) / nt, (t) => t.getMinutes());
234
+ At.range;
235
+ const ar = X((t) => {
236
+ t.setUTCSeconds(0, 0);
237
+ }, (t, e) => {
238
+ t.setTime(+t + e * nt);
239
+ }, (t, e) => (e - t) / nt, (t) => t.getUTCMinutes());
240
+ ar.range;
241
+ const It = X((t) => {
242
+ t.setTime(t - t.getMilliseconds() - t.getSeconds() * ct - t.getMinutes() * nt);
243
+ }, (t, e) => {
244
+ t.setTime(+t + e * lt);
245
+ }, (t, e) => (e - t) / lt, (t) => t.getHours());
246
+ It.range;
247
+ const or = X((t) => {
248
+ t.setUTCMinutes(0, 0, 0);
249
+ }, (t, e) => {
250
+ t.setTime(+t + e * lt);
251
+ }, (t, e) => (e - t) / lt, (t) => t.getUTCHours());
252
+ or.range;
253
+ const yt = X(
254
+ (t) => t.setHours(0, 0, 0, 0),
255
+ (t, e) => t.setDate(t.getDate() + e),
256
+ (t, e) => (e - t - (e.getTimezoneOffset() - t.getTimezoneOffset()) * nt) / ut,
257
+ (t) => t.getDate() - 1
258
+ );
259
+ yt.range;
260
+ const ge = X((t) => {
261
+ t.setUTCHours(0, 0, 0, 0);
262
+ }, (t, e) => {
263
+ t.setUTCDate(t.getUTCDate() + e);
264
+ }, (t, e) => (e - t) / ut, (t) => t.getUTCDate() - 1);
265
+ ge.range;
266
+ const cr = X((t) => {
267
+ t.setUTCHours(0, 0, 0, 0);
268
+ }, (t, e) => {
269
+ t.setUTCDate(t.getUTCDate() + e);
270
+ }, (t, e) => (e - t) / ut, (t) => Math.floor(t / ut));
271
+ cr.range;
272
+ function pt(t) {
273
+ return X((e) => {
274
+ e.setDate(e.getDate() - (e.getDay() + 7 - t) % 7), e.setHours(0, 0, 0, 0);
275
+ }, (e, n) => {
276
+ e.setDate(e.getDate() + n * 7);
277
+ }, (e, n) => (n - e - (n.getTimezoneOffset() - e.getTimezoneOffset()) * nt) / ye);
278
+ }
279
+ const Wt = pt(0), Yt = pt(1), $e = pt(2), tn = pt(3), gt = pt(4), en = pt(5), nn = pt(6);
280
+ Wt.range;
281
+ Yt.range;
282
+ $e.range;
283
+ tn.range;
284
+ gt.range;
285
+ en.range;
286
+ nn.range;
287
+ function Tt(t) {
288
+ return X((e) => {
289
+ e.setUTCDate(e.getUTCDate() - (e.getUTCDay() + 7 - t) % 7), e.setUTCHours(0, 0, 0, 0);
290
+ }, (e, n) => {
291
+ e.setUTCDate(e.getUTCDate() + n * 7);
292
+ }, (e, n) => (n - e) / ye);
293
+ }
294
+ const rn = Tt(0), Xt = Tt(1), lr = Tt(2), ur = Tt(3), Mt = Tt(4), fr = Tt(5), hr = Tt(6);
295
+ rn.range;
296
+ Xt.range;
297
+ lr.range;
298
+ ur.range;
299
+ Mt.range;
300
+ fr.range;
301
+ hr.range;
302
+ const Lt = X((t) => {
303
+ t.setDate(1), t.setHours(0, 0, 0, 0);
304
+ }, (t, e) => {
305
+ t.setMonth(t.getMonth() + e);
306
+ }, (t, e) => e.getMonth() - t.getMonth() + (e.getFullYear() - t.getFullYear()) * 12, (t) => t.getMonth());
307
+ Lt.range;
308
+ const dr = X((t) => {
309
+ t.setUTCDate(1), t.setUTCHours(0, 0, 0, 0);
310
+ }, (t, e) => {
311
+ t.setUTCMonth(t.getUTCMonth() + e);
312
+ }, (t, e) => e.getUTCMonth() - t.getUTCMonth() + (e.getUTCFullYear() - t.getUTCFullYear()) * 12, (t) => t.getUTCMonth());
313
+ dr.range;
314
+ const ft = X((t) => {
315
+ t.setMonth(0, 1), t.setHours(0, 0, 0, 0);
316
+ }, (t, e) => {
317
+ t.setFullYear(t.getFullYear() + e);
318
+ }, (t, e) => e.getFullYear() - t.getFullYear(), (t) => t.getFullYear());
319
+ ft.every = (t) => !isFinite(t = Math.floor(t)) || !(t > 0) ? null : X((e) => {
320
+ e.setFullYear(Math.floor(e.getFullYear() / t) * t), e.setMonth(0, 1), e.setHours(0, 0, 0, 0);
321
+ }, (e, n) => {
322
+ e.setFullYear(e.getFullYear() + n * t);
323
+ });
324
+ ft.range;
325
+ const kt = X((t) => {
326
+ t.setUTCMonth(0, 1), t.setUTCHours(0, 0, 0, 0);
327
+ }, (t, e) => {
328
+ t.setUTCFullYear(t.getUTCFullYear() + e);
329
+ }, (t, e) => e.getUTCFullYear() - t.getUTCFullYear(), (t) => t.getUTCFullYear());
330
+ kt.every = (t) => !isFinite(t = Math.floor(t)) || !(t > 0) ? null : X((e) => {
331
+ e.setUTCFullYear(Math.floor(e.getUTCFullYear() / t) * t), e.setUTCMonth(0, 1), e.setUTCHours(0, 0, 0, 0);
332
+ }, (e, n) => {
333
+ e.setUTCFullYear(e.getUTCFullYear() + n * t);
334
+ });
335
+ kt.range;
336
+ function mr(t, e, n, r, i, s) {
337
+ const a = [
338
+ [ht, 1, ct],
339
+ [ht, 5, 5 * ct],
340
+ [ht, 15, 15 * ct],
341
+ [ht, 30, 30 * ct],
342
+ [s, 1, nt],
343
+ [s, 5, 5 * nt],
344
+ [s, 15, 15 * nt],
345
+ [s, 30, 30 * nt],
346
+ [i, 1, lt],
347
+ [i, 3, 3 * lt],
348
+ [i, 6, 6 * lt],
349
+ [i, 12, 12 * lt],
350
+ [r, 1, ut],
351
+ [r, 2, 2 * ut],
352
+ [n, 1, ye],
353
+ [e, 1, Se],
354
+ [e, 3, 3 * Se],
355
+ [t, 1, ae]
356
+ ];
357
+ function x(k, p, F) {
358
+ const T = p < k;
359
+ T && ([k, p] = [p, k]);
360
+ const g = F && typeof F.range == "function" ? F : S(k, p, F), P = g ? g.range(k, +p + 1) : [];
361
+ return T ? P.reverse() : P;
362
+ }
363
+ function S(k, p, F) {
364
+ const T = Math.abs(p - k) / F, g = On(([, , $]) => $).right(a, T);
365
+ if (g === a.length)
366
+ return t.every(Me(k / ae, p / ae, F));
367
+ if (g === 0)
368
+ return Dt.every(Math.max(Me(k, p, F), 1));
369
+ const [P, E] = a[T / a[g - 1][2] < a[g][2] / T ? g - 1 : g];
370
+ return P.every(E);
371
+ }
372
+ return [x, S];
373
+ }
374
+ const [yr, gr] = mr(ft, Lt, Wt, yt, It, At);
375
+ function oe(t) {
376
+ if (0 <= t.y && t.y < 100) {
377
+ var e = new Date(-1, t.m, t.d, t.H, t.M, t.S, t.L);
378
+ return e.setFullYear(t.y), e;
379
+ }
380
+ return new Date(t.y, t.m, t.d, t.H, t.M, t.S, t.L);
381
+ }
382
+ function ce(t) {
383
+ if (0 <= t.y && t.y < 100) {
384
+ var e = new Date(Date.UTC(-1, t.m, t.d, t.H, t.M, t.S, t.L));
385
+ return e.setUTCFullYear(t.y), e;
386
+ }
387
+ return new Date(Date.UTC(t.y, t.m, t.d, t.H, t.M, t.S, t.L));
388
+ }
389
+ function Ut(t, e, n) {
390
+ return { y: t, m: e, d: n, H: 0, M: 0, S: 0, L: 0 };
391
+ }
392
+ function kr(t) {
393
+ var e = t.dateTime, n = t.date, r = t.time, i = t.periods, s = t.days, a = t.shortDays, x = t.months, S = t.shortMonths, k = Ft(i), p = Et(i), F = Ft(s), T = Et(s), g = Ft(a), P = Et(a), E = Ft(x), $ = Et(x), et = Ft(S), tt = Et(S), B = {
394
+ a: o,
395
+ A: z,
396
+ b: h,
397
+ B: f,
398
+ c: null,
399
+ d: Ye,
400
+ e: Ye,
401
+ f: Vr,
402
+ g: Gr,
403
+ G: Kr,
404
+ H: Or,
405
+ I: Nr,
406
+ j: Hr,
407
+ L: sn,
408
+ m: Pr,
409
+ M: Rr,
410
+ p: M,
411
+ q: R,
412
+ Q: Oe,
413
+ s: Ne,
414
+ S: zr,
415
+ u: jr,
416
+ U: Br,
417
+ V: qr,
418
+ w: Zr,
419
+ W: Xr,
420
+ x: null,
421
+ X: null,
422
+ y: Qr,
423
+ Y: Jr,
424
+ Z: $r,
425
+ "%": We
426
+ }, q = {
427
+ a: Y,
428
+ A: W,
429
+ b: I,
430
+ B: O,
431
+ c: null,
432
+ d: Le,
433
+ e: Le,
434
+ f: ri,
435
+ g: di,
436
+ G: yi,
437
+ H: ti,
438
+ I: ei,
439
+ j: ni,
440
+ L: on,
441
+ m: ii,
442
+ M: si,
443
+ p: dt,
444
+ q: mt,
445
+ Q: Oe,
446
+ s: Ne,
447
+ S: ai,
448
+ u: oi,
449
+ U: ci,
450
+ V: li,
451
+ w: ui,
452
+ W: fi,
453
+ x: null,
454
+ X: null,
455
+ y: hi,
456
+ Y: mi,
457
+ Z: gi,
458
+ "%": We
459
+ }, K = {
460
+ a: _,
461
+ A: w,
462
+ b: c,
463
+ B: d,
464
+ c: m,
465
+ d: Ae,
466
+ e: Ae,
467
+ f: Ir,
468
+ g: Ee,
469
+ G: Fe,
470
+ H: Ie,
471
+ I: Ie,
472
+ j: Ur,
473
+ L: Ar,
474
+ m: Sr,
475
+ M: Fr,
476
+ p: U,
477
+ q: _r,
478
+ Q: Lr,
479
+ s: Wr,
480
+ S: Er,
481
+ u: xr,
482
+ U: wr,
483
+ V: Cr,
484
+ w: vr,
485
+ W: Dr,
486
+ x: u,
487
+ X: D,
488
+ y: Ee,
489
+ Y: Fe,
490
+ Z: Mr,
491
+ "%": Yr
492
+ };
493
+ B.x = v(n, B), B.X = v(r, B), B.c = v(e, B), q.x = v(n, q), q.X = v(r, q), q.c = v(e, q);
494
+ function v(y, A) {
495
+ return function(C) {
496
+ var l = [], V = -1, N = 0, j = y.length, Q, J, St;
497
+ for (C instanceof Date || (C = /* @__PURE__ */ new Date(+C)); ++V < j; )
498
+ y.charCodeAt(V) === 37 && (l.push(y.slice(N, V)), (J = Ue[Q = y.charAt(++V)]) != null ? Q = y.charAt(++V) : J = Q === "e" ? " " : "0", (St = A[Q]) && (Q = St(C, J)), l.push(Q), N = V + 1);
499
+ return l.push(y.slice(N, V)), l.join("");
500
+ };
501
+ }
502
+ function H(y, A) {
503
+ return function(C) {
504
+ var l = Ut(1900, void 0, 1), V = b(l, y, C += "", 0), N, j;
505
+ if (V != C.length)
506
+ return null;
507
+ if ("Q" in l)
508
+ return new Date(l.Q);
509
+ if ("s" in l)
510
+ return new Date(l.s * 1e3 + ("L" in l ? l.L : 0));
511
+ if (A && !("Z" in l) && (l.Z = 0), "p" in l && (l.H = l.H % 12 + l.p * 12), l.m === void 0 && (l.m = "q" in l ? l.q : 0), "V" in l) {
512
+ if (l.V < 1 || l.V > 53)
513
+ return null;
514
+ "w" in l || (l.w = 1), "Z" in l ? (N = ce(Ut(l.y, 0, 1)), j = N.getUTCDay(), N = j > 4 || j === 0 ? Xt.ceil(N) : Xt(N), N = ge.offset(N, (l.V - 1) * 7), l.y = N.getUTCFullYear(), l.m = N.getUTCMonth(), l.d = N.getUTCDate() + (l.w + 6) % 7) : (N = oe(Ut(l.y, 0, 1)), j = N.getDay(), N = j > 4 || j === 0 ? Yt.ceil(N) : Yt(N), N = yt.offset(N, (l.V - 1) * 7), l.y = N.getFullYear(), l.m = N.getMonth(), l.d = N.getDate() + (l.w + 6) % 7);
515
+ } else
516
+ ("W" in l || "U" in l) && ("w" in l || (l.w = "u" in l ? l.u % 7 : "W" in l ? 1 : 0), j = "Z" in l ? ce(Ut(l.y, 0, 1)).getUTCDay() : oe(Ut(l.y, 0, 1)).getDay(), l.m = 0, l.d = "W" in l ? (l.w + 6) % 7 + l.W * 7 - (j + 5) % 7 : l.w + l.U * 7 - (j + 6) % 7);
517
+ return "Z" in l ? (l.H += l.Z / 100 | 0, l.M += l.Z % 100, ce(l)) : oe(l);
518
+ };
519
+ }
520
+ function b(y, A, C, l) {
521
+ for (var V = 0, N = A.length, j = C.length, Q, J; V < N; ) {
522
+ if (l >= j)
523
+ return -1;
524
+ if (Q = A.charCodeAt(V++), Q === 37) {
525
+ if (Q = A.charAt(V++), J = K[Q in Ue ? A.charAt(V++) : Q], !J || (l = J(y, C, l)) < 0)
526
+ return -1;
527
+ } else if (Q != C.charCodeAt(l++))
528
+ return -1;
529
+ }
530
+ return l;
531
+ }
532
+ function U(y, A, C) {
533
+ var l = k.exec(A.slice(C));
534
+ return l ? (y.p = p.get(l[0].toLowerCase()), C + l[0].length) : -1;
535
+ }
536
+ function _(y, A, C) {
537
+ var l = g.exec(A.slice(C));
538
+ return l ? (y.w = P.get(l[0].toLowerCase()), C + l[0].length) : -1;
539
+ }
540
+ function w(y, A, C) {
541
+ var l = F.exec(A.slice(C));
542
+ return l ? (y.w = T.get(l[0].toLowerCase()), C + l[0].length) : -1;
543
+ }
544
+ function c(y, A, C) {
545
+ var l = et.exec(A.slice(C));
546
+ return l ? (y.m = tt.get(l[0].toLowerCase()), C + l[0].length) : -1;
547
+ }
548
+ function d(y, A, C) {
549
+ var l = E.exec(A.slice(C));
550
+ return l ? (y.m = $.get(l[0].toLowerCase()), C + l[0].length) : -1;
551
+ }
552
+ function m(y, A, C) {
553
+ return b(y, e, A, C);
554
+ }
555
+ function u(y, A, C) {
556
+ return b(y, n, A, C);
557
+ }
558
+ function D(y, A, C) {
559
+ return b(y, r, A, C);
560
+ }
561
+ function o(y) {
562
+ return a[y.getDay()];
563
+ }
564
+ function z(y) {
565
+ return s[y.getDay()];
566
+ }
567
+ function h(y) {
568
+ return S[y.getMonth()];
569
+ }
570
+ function f(y) {
571
+ return x[y.getMonth()];
572
+ }
573
+ function M(y) {
574
+ return i[+(y.getHours() >= 12)];
575
+ }
576
+ function R(y) {
577
+ return 1 + ~~(y.getMonth() / 3);
578
+ }
579
+ function Y(y) {
580
+ return a[y.getUTCDay()];
581
+ }
582
+ function W(y) {
583
+ return s[y.getUTCDay()];
584
+ }
585
+ function I(y) {
586
+ return S[y.getUTCMonth()];
587
+ }
588
+ function O(y) {
589
+ return x[y.getUTCMonth()];
590
+ }
591
+ function dt(y) {
592
+ return i[+(y.getUTCHours() >= 12)];
593
+ }
594
+ function mt(y) {
595
+ return 1 + ~~(y.getUTCMonth() / 3);
596
+ }
597
+ return {
598
+ format: function(y) {
599
+ var A = v(y += "", B);
600
+ return A.toString = function() {
601
+ return y;
602
+ }, A;
603
+ },
604
+ parse: function(y) {
605
+ var A = H(y += "", !1);
606
+ return A.toString = function() {
607
+ return y;
608
+ }, A;
609
+ },
610
+ utcFormat: function(y) {
611
+ var A = v(y += "", q);
612
+ return A.toString = function() {
613
+ return y;
614
+ }, A;
615
+ },
616
+ utcParse: function(y) {
617
+ var A = H(y += "", !0);
618
+ return A.toString = function() {
619
+ return y;
620
+ }, A;
621
+ }
622
+ };
623
+ }
624
+ var Ue = { "-": "", _: " ", 0: "0" }, G = /^\s*\d+/, pr = /^%/, Tr = /[\\^$*+?|[\]().{}]/g;
625
+ function L(t, e, n) {
626
+ var r = t < 0 ? "-" : "", i = (r ? -t : t) + "", s = i.length;
627
+ return r + (s < n ? new Array(n - s + 1).join(e) + i : i);
628
+ }
629
+ function br(t) {
630
+ return t.replace(Tr, "\\$&");
631
+ }
632
+ function Ft(t) {
633
+ return new RegExp("^(?:" + t.map(br).join("|") + ")", "i");
634
+ }
635
+ function Et(t) {
636
+ return new Map(t.map((e, n) => [e.toLowerCase(), n]));
637
+ }
638
+ function vr(t, e, n) {
639
+ var r = G.exec(e.slice(n, n + 1));
640
+ return r ? (t.w = +r[0], n + r[0].length) : -1;
641
+ }
642
+ function xr(t, e, n) {
643
+ var r = G.exec(e.slice(n, n + 1));
644
+ return r ? (t.u = +r[0], n + r[0].length) : -1;
645
+ }
646
+ function wr(t, e, n) {
647
+ var r = G.exec(e.slice(n, n + 2));
648
+ return r ? (t.U = +r[0], n + r[0].length) : -1;
649
+ }
650
+ function Cr(t, e, n) {
651
+ var r = G.exec(e.slice(n, n + 2));
652
+ return r ? (t.V = +r[0], n + r[0].length) : -1;
653
+ }
654
+ function Dr(t, e, n) {
655
+ var r = G.exec(e.slice(n, n + 2));
656
+ return r ? (t.W = +r[0], n + r[0].length) : -1;
657
+ }
658
+ function Fe(t, e, n) {
659
+ var r = G.exec(e.slice(n, n + 4));
660
+ return r ? (t.y = +r[0], n + r[0].length) : -1;
661
+ }
662
+ function Ee(t, e, n) {
663
+ var r = G.exec(e.slice(n, n + 2));
664
+ return r ? (t.y = +r[0] + (+r[0] > 68 ? 1900 : 2e3), n + r[0].length) : -1;
665
+ }
666
+ function Mr(t, e, n) {
667
+ var r = /^(Z)|([+-]\d\d)(?::?(\d\d))?/.exec(e.slice(n, n + 6));
668
+ return r ? (t.Z = r[1] ? 0 : -(r[2] + (r[3] || "00")), n + r[0].length) : -1;
669
+ }
670
+ function _r(t, e, n) {
671
+ var r = G.exec(e.slice(n, n + 1));
672
+ return r ? (t.q = r[0] * 3 - 3, n + r[0].length) : -1;
673
+ }
674
+ function Sr(t, e, n) {
675
+ var r = G.exec(e.slice(n, n + 2));
676
+ return r ? (t.m = r[0] - 1, n + r[0].length) : -1;
677
+ }
678
+ function Ae(t, e, n) {
679
+ var r = G.exec(e.slice(n, n + 2));
680
+ return r ? (t.d = +r[0], n + r[0].length) : -1;
681
+ }
682
+ function Ur(t, e, n) {
683
+ var r = G.exec(e.slice(n, n + 3));
684
+ return r ? (t.m = 0, t.d = +r[0], n + r[0].length) : -1;
685
+ }
686
+ function Ie(t, e, n) {
687
+ var r = G.exec(e.slice(n, n + 2));
688
+ return r ? (t.H = +r[0], n + r[0].length) : -1;
689
+ }
690
+ function Fr(t, e, n) {
691
+ var r = G.exec(e.slice(n, n + 2));
692
+ return r ? (t.M = +r[0], n + r[0].length) : -1;
693
+ }
694
+ function Er(t, e, n) {
695
+ var r = G.exec(e.slice(n, n + 2));
696
+ return r ? (t.S = +r[0], n + r[0].length) : -1;
697
+ }
698
+ function Ar(t, e, n) {
699
+ var r = G.exec(e.slice(n, n + 3));
700
+ return r ? (t.L = +r[0], n + r[0].length) : -1;
701
+ }
702
+ function Ir(t, e, n) {
703
+ var r = G.exec(e.slice(n, n + 6));
704
+ return r ? (t.L = Math.floor(r[0] / 1e3), n + r[0].length) : -1;
705
+ }
706
+ function Yr(t, e, n) {
707
+ var r = pr.exec(e.slice(n, n + 1));
708
+ return r ? n + r[0].length : -1;
709
+ }
710
+ function Lr(t, e, n) {
711
+ var r = G.exec(e.slice(n));
712
+ return r ? (t.Q = +r[0], n + r[0].length) : -1;
713
+ }
714
+ function Wr(t, e, n) {
715
+ var r = G.exec(e.slice(n));
716
+ return r ? (t.s = +r[0], n + r[0].length) : -1;
717
+ }
718
+ function Ye(t, e) {
719
+ return L(t.getDate(), e, 2);
720
+ }
721
+ function Or(t, e) {
722
+ return L(t.getHours(), e, 2);
723
+ }
724
+ function Nr(t, e) {
725
+ return L(t.getHours() % 12 || 12, e, 2);
726
+ }
727
+ function Hr(t, e) {
728
+ return L(1 + yt.count(ft(t), t), e, 3);
729
+ }
730
+ function sn(t, e) {
731
+ return L(t.getMilliseconds(), e, 3);
732
+ }
733
+ function Vr(t, e) {
734
+ return sn(t, e) + "000";
735
+ }
736
+ function Pr(t, e) {
737
+ return L(t.getMonth() + 1, e, 2);
738
+ }
739
+ function Rr(t, e) {
740
+ return L(t.getMinutes(), e, 2);
741
+ }
742
+ function zr(t, e) {
743
+ return L(t.getSeconds(), e, 2);
744
+ }
745
+ function jr(t) {
746
+ var e = t.getDay();
747
+ return e === 0 ? 7 : e;
748
+ }
749
+ function Br(t, e) {
750
+ return L(Wt.count(ft(t) - 1, t), e, 2);
751
+ }
752
+ function an(t) {
753
+ var e = t.getDay();
754
+ return e >= 4 || e === 0 ? gt(t) : gt.ceil(t);
755
+ }
756
+ function qr(t, e) {
757
+ return t = an(t), L(gt.count(ft(t), t) + (ft(t).getDay() === 4), e, 2);
758
+ }
759
+ function Zr(t) {
760
+ return t.getDay();
761
+ }
762
+ function Xr(t, e) {
763
+ return L(Yt.count(ft(t) - 1, t), e, 2);
764
+ }
765
+ function Qr(t, e) {
766
+ return L(t.getFullYear() % 100, e, 2);
767
+ }
768
+ function Gr(t, e) {
769
+ return t = an(t), L(t.getFullYear() % 100, e, 2);
770
+ }
771
+ function Jr(t, e) {
772
+ return L(t.getFullYear() % 1e4, e, 4);
773
+ }
774
+ function Kr(t, e) {
775
+ var n = t.getDay();
776
+ return t = n >= 4 || n === 0 ? gt(t) : gt.ceil(t), L(t.getFullYear() % 1e4, e, 4);
777
+ }
778
+ function $r(t) {
779
+ var e = t.getTimezoneOffset();
780
+ return (e > 0 ? "-" : (e *= -1, "+")) + L(e / 60 | 0, "0", 2) + L(e % 60, "0", 2);
781
+ }
782
+ function Le(t, e) {
783
+ return L(t.getUTCDate(), e, 2);
784
+ }
785
+ function ti(t, e) {
786
+ return L(t.getUTCHours(), e, 2);
787
+ }
788
+ function ei(t, e) {
789
+ return L(t.getUTCHours() % 12 || 12, e, 2);
790
+ }
791
+ function ni(t, e) {
792
+ return L(1 + ge.count(kt(t), t), e, 3);
793
+ }
794
+ function on(t, e) {
795
+ return L(t.getUTCMilliseconds(), e, 3);
796
+ }
797
+ function ri(t, e) {
798
+ return on(t, e) + "000";
799
+ }
800
+ function ii(t, e) {
801
+ return L(t.getUTCMonth() + 1, e, 2);
802
+ }
803
+ function si(t, e) {
804
+ return L(t.getUTCMinutes(), e, 2);
805
+ }
806
+ function ai(t, e) {
807
+ return L(t.getUTCSeconds(), e, 2);
808
+ }
809
+ function oi(t) {
810
+ var e = t.getUTCDay();
811
+ return e === 0 ? 7 : e;
812
+ }
813
+ function ci(t, e) {
814
+ return L(rn.count(kt(t) - 1, t), e, 2);
815
+ }
816
+ function cn(t) {
817
+ var e = t.getUTCDay();
818
+ return e >= 4 || e === 0 ? Mt(t) : Mt.ceil(t);
819
+ }
820
+ function li(t, e) {
821
+ return t = cn(t), L(Mt.count(kt(t), t) + (kt(t).getUTCDay() === 4), e, 2);
822
+ }
823
+ function ui(t) {
824
+ return t.getUTCDay();
825
+ }
826
+ function fi(t, e) {
827
+ return L(Xt.count(kt(t) - 1, t), e, 2);
828
+ }
829
+ function hi(t, e) {
830
+ return L(t.getUTCFullYear() % 100, e, 2);
831
+ }
832
+ function di(t, e) {
833
+ return t = cn(t), L(t.getUTCFullYear() % 100, e, 2);
834
+ }
835
+ function mi(t, e) {
836
+ return L(t.getUTCFullYear() % 1e4, e, 4);
837
+ }
838
+ function yi(t, e) {
839
+ var n = t.getUTCDay();
840
+ return t = n >= 4 || n === 0 ? Mt(t) : Mt.ceil(t), L(t.getUTCFullYear() % 1e4, e, 4);
841
+ }
842
+ function gi() {
843
+ return "+0000";
844
+ }
845
+ function We() {
846
+ return "%";
847
+ }
848
+ function Oe(t) {
849
+ return +t;
850
+ }
851
+ function Ne(t) {
852
+ return Math.floor(+t / 1e3);
853
+ }
854
+ var vt, Qt;
855
+ ki({
856
+ dateTime: "%x, %X",
857
+ date: "%-m/%-d/%Y",
858
+ time: "%-I:%M:%S %p",
859
+ periods: ["AM", "PM"],
860
+ days: ["Sunday", "Monday", "Tuesday", "Wednesday", "Thursday", "Friday", "Saturday"],
861
+ shortDays: ["Sun", "Mon", "Tue", "Wed", "Thu", "Fri", "Sat"],
862
+ months: ["January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December"],
863
+ shortMonths: ["Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec"]
864
+ });
865
+ function ki(t) {
866
+ return vt = kr(t), Qt = vt.format, vt.parse, vt.utcFormat, vt.utcParse, vt;
867
+ }
868
+ function pi(t) {
869
+ return new Date(t);
870
+ }
871
+ function Ti(t) {
872
+ return t instanceof Date ? +t : +/* @__PURE__ */ new Date(+t);
873
+ }
874
+ function ln(t, e, n, r, i, s, a, x, S, k) {
875
+ var p = Nn(), F = p.invert, T = p.domain, g = k(".%L"), P = k(":%S"), E = k("%I:%M"), $ = k("%I %p"), et = k("%a %d"), tt = k("%b %d"), B = k("%B"), q = k("%Y");
876
+ function K(v) {
877
+ return (S(v) < v ? g : x(v) < v ? P : a(v) < v ? E : s(v) < v ? $ : r(v) < v ? i(v) < v ? et : tt : n(v) < v ? B : q)(v);
878
+ }
879
+ return p.invert = function(v) {
880
+ return new Date(F(v));
881
+ }, p.domain = function(v) {
882
+ return arguments.length ? T(Array.from(v, Ti)) : T().map(pi);
883
+ }, p.ticks = function(v) {
884
+ var H = T();
885
+ return t(H[0], H[H.length - 1], v ?? 10);
886
+ }, p.tickFormat = function(v, H) {
887
+ return H == null ? K : k(H);
888
+ }, p.nice = function(v) {
889
+ var H = T();
890
+ return (!v || typeof v.range != "function") && (v = e(H[0], H[H.length - 1], v ?? 10)), v ? T(sr(H, v)) : p;
891
+ }, p.copy = function() {
892
+ return Hn(p, ln(t, e, n, r, i, s, a, x, S, k));
893
+ }, p;
894
+ }
895
+ function bi() {
896
+ return Pn.apply(ln(yr, gr, ft, Lt, Wt, yt, It, At, ht, Qt).domain([new Date(2e3, 0, 1), new Date(2e3, 0, 2)]), arguments);
897
+ }
898
+ var un = { exports: {} };
899
+ (function(t, e) {
900
+ (function(n, r) {
901
+ t.exports = r();
902
+ })(xn, function() {
903
+ var n = "day";
904
+ return function(r, i, s) {
905
+ var a = function(k) {
906
+ return k.add(4 - k.isoWeekday(), n);
907
+ }, x = i.prototype;
908
+ x.isoWeekYear = function() {
909
+ return a(this).year();
910
+ }, x.isoWeek = function(k) {
911
+ if (!this.$utils().u(k))
912
+ return this.add(7 * (k - this.isoWeek()), n);
913
+ var p, F, T, g, P = a(this), E = (p = this.isoWeekYear(), F = this.$u, T = (F ? s.utc : s)().year(p).startOf("year"), g = 4 - T.isoWeekday(), T.isoWeekday() > 4 && (g += 7), T.add(g, n));
914
+ return P.diff(E, "week") + 1;
915
+ }, x.isoWeekday = function(k) {
916
+ return this.$utils().u(k) ? this.day() || 7 : this.day(this.day() % 7 ? k : k - 7);
917
+ };
918
+ var S = x.startOf;
919
+ x.startOf = function(k, p) {
920
+ var F = this.$utils(), T = !!F.u(p) || p;
921
+ return F.p(k) === "isoweek" ? T ? this.date(this.date() - (this.isoWeekday() - 1)).startOf("day") : this.date(this.date() - 1 - (this.isoWeekday() - 1) + 7).endOf("day") : S.bind(this)(k, p);
922
+ };
923
+ };
924
+ });
925
+ })(un);
926
+ var vi = un.exports;
927
+ const xi = /* @__PURE__ */ wn(vi);
928
+ var fe = function() {
929
+ var t = function(w, c, d, m) {
930
+ for (d = d || {}, m = w.length; m--; d[w[m]] = c)
931
+ ;
932
+ return d;
933
+ }, e = [6, 8, 10, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 30, 32, 33, 35, 37], n = [1, 25], r = [1, 26], i = [1, 27], s = [1, 28], a = [1, 29], x = [1, 30], S = [1, 31], k = [1, 9], p = [1, 10], F = [1, 11], T = [1, 12], g = [1, 13], P = [1, 14], E = [1, 15], $ = [1, 16], et = [1, 18], tt = [1, 19], B = [1, 20], q = [1, 21], K = [1, 22], v = [1, 24], H = [1, 32], b = {
934
+ trace: function() {
935
+ },
936
+ yy: {},
937
+ symbols_: { error: 2, start: 3, gantt: 4, document: 5, EOF: 6, line: 7, SPACE: 8, statement: 9, NL: 10, weekday: 11, weekday_monday: 12, weekday_tuesday: 13, weekday_wednesday: 14, weekday_thursday: 15, weekday_friday: 16, weekday_saturday: 17, weekday_sunday: 18, dateFormat: 19, inclusiveEndDates: 20, topAxis: 21, axisFormat: 22, tickInterval: 23, excludes: 24, includes: 25, todayMarker: 26, title: 27, acc_title: 28, acc_title_value: 29, acc_descr: 30, acc_descr_value: 31, acc_descr_multiline_value: 32, section: 33, clickStatement: 34, taskTxt: 35, taskData: 36, click: 37, callbackname: 38, callbackargs: 39, href: 40, clickStatementDebug: 41, $accept: 0, $end: 1 },
938
+ terminals_: { 2: "error", 4: "gantt", 6: "EOF", 8: "SPACE", 10: "NL", 12: "weekday_monday", 13: "weekday_tuesday", 14: "weekday_wednesday", 15: "weekday_thursday", 16: "weekday_friday", 17: "weekday_saturday", 18: "weekday_sunday", 19: "dateFormat", 20: "inclusiveEndDates", 21: "topAxis", 22: "axisFormat", 23: "tickInterval", 24: "excludes", 25: "includes", 26: "todayMarker", 27: "title", 28: "acc_title", 29: "acc_title_value", 30: "acc_descr", 31: "acc_descr_value", 32: "acc_descr_multiline_value", 33: "section", 35: "taskTxt", 36: "taskData", 37: "click", 38: "callbackname", 39: "callbackargs", 40: "href" },
939
+ productions_: [0, [3, 3], [5, 0], [5, 2], [7, 2], [7, 1], [7, 1], [7, 1], [11, 1], [11, 1], [11, 1], [11, 1], [11, 1], [11, 1], [11, 1], [9, 1], [9, 1], [9, 1], [9, 1], [9, 1], [9, 1], [9, 1], [9, 1], [9, 1], [9, 1], [9, 2], [9, 2], [9, 1], [9, 1], [9, 1], [9, 2], [34, 2], [34, 3], [34, 3], [34, 4], [34, 3], [34, 4], [34, 2], [41, 2], [41, 3], [41, 3], [41, 4], [41, 3], [41, 4], [41, 2]],
940
+ performAction: function(c, d, m, u, D, o, z) {
941
+ var h = o.length - 1;
942
+ switch (D) {
943
+ case 1:
944
+ return o[h - 1];
945
+ case 2:
946
+ this.$ = [];
947
+ break;
948
+ case 3:
949
+ o[h - 1].push(o[h]), this.$ = o[h - 1];
950
+ break;
951
+ case 4:
952
+ case 5:
953
+ this.$ = o[h];
954
+ break;
955
+ case 6:
956
+ case 7:
957
+ this.$ = [];
958
+ break;
959
+ case 8:
960
+ u.setWeekday("monday");
961
+ break;
962
+ case 9:
963
+ u.setWeekday("tuesday");
964
+ break;
965
+ case 10:
966
+ u.setWeekday("wednesday");
967
+ break;
968
+ case 11:
969
+ u.setWeekday("thursday");
970
+ break;
971
+ case 12:
972
+ u.setWeekday("friday");
973
+ break;
974
+ case 13:
975
+ u.setWeekday("saturday");
976
+ break;
977
+ case 14:
978
+ u.setWeekday("sunday");
979
+ break;
980
+ case 15:
981
+ u.setDateFormat(o[h].substr(11)), this.$ = o[h].substr(11);
982
+ break;
983
+ case 16:
984
+ u.enableInclusiveEndDates(), this.$ = o[h].substr(18);
985
+ break;
986
+ case 17:
987
+ u.TopAxis(), this.$ = o[h].substr(8);
988
+ break;
989
+ case 18:
990
+ u.setAxisFormat(o[h].substr(11)), this.$ = o[h].substr(11);
991
+ break;
992
+ case 19:
993
+ u.setTickInterval(o[h].substr(13)), this.$ = o[h].substr(13);
994
+ break;
995
+ case 20:
996
+ u.setExcludes(o[h].substr(9)), this.$ = o[h].substr(9);
997
+ break;
998
+ case 21:
999
+ u.setIncludes(o[h].substr(9)), this.$ = o[h].substr(9);
1000
+ break;
1001
+ case 22:
1002
+ u.setTodayMarker(o[h].substr(12)), this.$ = o[h].substr(12);
1003
+ break;
1004
+ case 24:
1005
+ u.setDiagramTitle(o[h].substr(6)), this.$ = o[h].substr(6);
1006
+ break;
1007
+ case 25:
1008
+ this.$ = o[h].trim(), u.setAccTitle(this.$);
1009
+ break;
1010
+ case 26:
1011
+ case 27:
1012
+ this.$ = o[h].trim(), u.setAccDescription(this.$);
1013
+ break;
1014
+ case 28:
1015
+ u.addSection(o[h].substr(8)), this.$ = o[h].substr(8);
1016
+ break;
1017
+ case 30:
1018
+ u.addTask(o[h - 1], o[h]), this.$ = "task";
1019
+ break;
1020
+ case 31:
1021
+ this.$ = o[h - 1], u.setClickEvent(o[h - 1], o[h], null);
1022
+ break;
1023
+ case 32:
1024
+ this.$ = o[h - 2], u.setClickEvent(o[h - 2], o[h - 1], o[h]);
1025
+ break;
1026
+ case 33:
1027
+ this.$ = o[h - 2], u.setClickEvent(o[h - 2], o[h - 1], null), u.setLink(o[h - 2], o[h]);
1028
+ break;
1029
+ case 34:
1030
+ this.$ = o[h - 3], u.setClickEvent(o[h - 3], o[h - 2], o[h - 1]), u.setLink(o[h - 3], o[h]);
1031
+ break;
1032
+ case 35:
1033
+ this.$ = o[h - 2], u.setClickEvent(o[h - 2], o[h], null), u.setLink(o[h - 2], o[h - 1]);
1034
+ break;
1035
+ case 36:
1036
+ this.$ = o[h - 3], u.setClickEvent(o[h - 3], o[h - 1], o[h]), u.setLink(o[h - 3], o[h - 2]);
1037
+ break;
1038
+ case 37:
1039
+ this.$ = o[h - 1], u.setLink(o[h - 1], o[h]);
1040
+ break;
1041
+ case 38:
1042
+ case 44:
1043
+ this.$ = o[h - 1] + " " + o[h];
1044
+ break;
1045
+ case 39:
1046
+ case 40:
1047
+ case 42:
1048
+ this.$ = o[h - 2] + " " + o[h - 1] + " " + o[h];
1049
+ break;
1050
+ case 41:
1051
+ case 43:
1052
+ this.$ = o[h - 3] + " " + o[h - 2] + " " + o[h - 1] + " " + o[h];
1053
+ break;
1054
+ }
1055
+ },
1056
+ table: [{ 3: 1, 4: [1, 2] }, { 1: [3] }, t(e, [2, 2], { 5: 3 }), { 6: [1, 4], 7: 5, 8: [1, 6], 9: 7, 10: [1, 8], 11: 17, 12: n, 13: r, 14: i, 15: s, 16: a, 17: x, 18: S, 19: k, 20: p, 21: F, 22: T, 23: g, 24: P, 25: E, 26: $, 27: et, 28: tt, 30: B, 32: q, 33: K, 34: 23, 35: v, 37: H }, t(e, [2, 7], { 1: [2, 1] }), t(e, [2, 3]), { 9: 33, 11: 17, 12: n, 13: r, 14: i, 15: s, 16: a, 17: x, 18: S, 19: k, 20: p, 21: F, 22: T, 23: g, 24: P, 25: E, 26: $, 27: et, 28: tt, 30: B, 32: q, 33: K, 34: 23, 35: v, 37: H }, t(e, [2, 5]), t(e, [2, 6]), t(e, [2, 15]), t(e, [2, 16]), t(e, [2, 17]), t(e, [2, 18]), t(e, [2, 19]), t(e, [2, 20]), t(e, [2, 21]), t(e, [2, 22]), t(e, [2, 23]), t(e, [2, 24]), { 29: [1, 34] }, { 31: [1, 35] }, t(e, [2, 27]), t(e, [2, 28]), t(e, [2, 29]), { 36: [1, 36] }, t(e, [2, 8]), t(e, [2, 9]), t(e, [2, 10]), t(e, [2, 11]), t(e, [2, 12]), t(e, [2, 13]), t(e, [2, 14]), { 38: [1, 37], 40: [1, 38] }, t(e, [2, 4]), t(e, [2, 25]), t(e, [2, 26]), t(e, [2, 30]), t(e, [2, 31], { 39: [1, 39], 40: [1, 40] }), t(e, [2, 37], { 38: [1, 41] }), t(e, [2, 32], { 40: [1, 42] }), t(e, [2, 33]), t(e, [2, 35], { 39: [1, 43] }), t(e, [2, 34]), t(e, [2, 36])],
1057
+ defaultActions: {},
1058
+ parseError: function(c, d) {
1059
+ if (d.recoverable)
1060
+ this.trace(c);
1061
+ else {
1062
+ var m = new Error(c);
1063
+ throw m.hash = d, m;
1064
+ }
1065
+ },
1066
+ parse: function(c) {
1067
+ var d = this, m = [0], u = [], D = [null], o = [], z = this.table, h = "", f = 0, M = 0, R = 2, Y = 1, W = o.slice.call(arguments, 1), I = Object.create(this.lexer), O = { yy: {} };
1068
+ for (var dt in this.yy)
1069
+ Object.prototype.hasOwnProperty.call(this.yy, dt) && (O.yy[dt] = this.yy[dt]);
1070
+ I.setInput(c, O.yy), O.yy.lexer = I, O.yy.parser = this, typeof I.yylloc > "u" && (I.yylloc = {});
1071
+ var mt = I.yylloc;
1072
+ o.push(mt);
1073
+ var y = I.options && I.options.ranges;
1074
+ typeof O.yy.parseError == "function" ? this.parseError = O.yy.parseError : this.parseError = Object.getPrototypeOf(this).parseError;
1075
+ function A() {
1076
+ var st;
1077
+ return st = u.pop() || I.lex() || Y, typeof st != "number" && (st instanceof Array && (u = st, st = u.pop()), st = d.symbols_[st] || st), st;
1078
+ }
1079
+ for (var C, l, V, N, j = {}, Q, J, St, Vt; ; ) {
1080
+ if (l = m[m.length - 1], this.defaultActions[l] ? V = this.defaultActions[l] : ((C === null || typeof C > "u") && (C = A()), V = z[l] && z[l][C]), typeof V > "u" || !V.length || !V[0]) {
1081
+ var Jt = "";
1082
+ Vt = [];
1083
+ for (Q in z[l])
1084
+ this.terminals_[Q] && Q > R && Vt.push("'" + this.terminals_[Q] + "'");
1085
+ I.showPosition ? Jt = "Parse error on line " + (f + 1) + `:
1086
+ ` + I.showPosition() + `
1087
+ Expecting ` + Vt.join(", ") + ", got '" + (this.terminals_[C] || C) + "'" : Jt = "Parse error on line " + (f + 1) + ": Unexpected " + (C == Y ? "end of input" : "'" + (this.terminals_[C] || C) + "'"), this.parseError(Jt, {
1088
+ text: I.match,
1089
+ token: this.terminals_[C] || C,
1090
+ line: I.yylineno,
1091
+ loc: mt,
1092
+ expected: Vt
1093
+ });
1094
+ }
1095
+ if (V[0] instanceof Array && V.length > 1)
1096
+ throw new Error("Parse Error: multiple actions possible at state: " + l + ", token: " + C);
1097
+ switch (V[0]) {
1098
+ case 1:
1099
+ m.push(C), D.push(I.yytext), o.push(I.yylloc), m.push(V[1]), C = null, M = I.yyleng, h = I.yytext, f = I.yylineno, mt = I.yylloc;
1100
+ break;
1101
+ case 2:
1102
+ if (J = this.productions_[V[1]][1], j.$ = D[D.length - J], j._$ = {
1103
+ first_line: o[o.length - (J || 1)].first_line,
1104
+ last_line: o[o.length - 1].last_line,
1105
+ first_column: o[o.length - (J || 1)].first_column,
1106
+ last_column: o[o.length - 1].last_column
1107
+ }, y && (j._$.range = [
1108
+ o[o.length - (J || 1)].range[0],
1109
+ o[o.length - 1].range[1]
1110
+ ]), N = this.performAction.apply(j, [
1111
+ h,
1112
+ M,
1113
+ f,
1114
+ O.yy,
1115
+ V[1],
1116
+ D,
1117
+ o
1118
+ ].concat(W)), typeof N < "u")
1119
+ return N;
1120
+ J && (m = m.slice(0, -1 * J * 2), D = D.slice(0, -1 * J), o = o.slice(0, -1 * J)), m.push(this.productions_[V[1]][0]), D.push(j.$), o.push(j._$), St = z[m[m.length - 2]][m[m.length - 1]], m.push(St);
1121
+ break;
1122
+ case 3:
1123
+ return !0;
1124
+ }
1125
+ }
1126
+ return !0;
1127
+ }
1128
+ }, U = function() {
1129
+ var w = {
1130
+ EOF: 1,
1131
+ parseError: function(d, m) {
1132
+ if (this.yy.parser)
1133
+ this.yy.parser.parseError(d, m);
1134
+ else
1135
+ throw new Error(d);
1136
+ },
1137
+ // resets the lexer, sets new input
1138
+ setInput: function(c, d) {
1139
+ return this.yy = d || this.yy || {}, this._input = c, this._more = this._backtrack = this.done = !1, this.yylineno = this.yyleng = 0, this.yytext = this.matched = this.match = "", this.conditionStack = ["INITIAL"], this.yylloc = {
1140
+ first_line: 1,
1141
+ first_column: 0,
1142
+ last_line: 1,
1143
+ last_column: 0
1144
+ }, this.options.ranges && (this.yylloc.range = [0, 0]), this.offset = 0, this;
1145
+ },
1146
+ // consumes and returns one char from the input
1147
+ input: function() {
1148
+ var c = this._input[0];
1149
+ this.yytext += c, this.yyleng++, this.offset++, this.match += c, this.matched += c;
1150
+ var d = c.match(/(?:\r\n?|\n).*/g);
1151
+ return d ? (this.yylineno++, this.yylloc.last_line++) : this.yylloc.last_column++, this.options.ranges && this.yylloc.range[1]++, this._input = this._input.slice(1), c;
1152
+ },
1153
+ // unshifts one char (or a string) into the input
1154
+ unput: function(c) {
1155
+ var d = c.length, m = c.split(/(?:\r\n?|\n)/g);
1156
+ this._input = c + this._input, this.yytext = this.yytext.substr(0, this.yytext.length - d), this.offset -= d;
1157
+ var u = this.match.split(/(?:\r\n?|\n)/g);
1158
+ this.match = this.match.substr(0, this.match.length - 1), this.matched = this.matched.substr(0, this.matched.length - 1), m.length - 1 && (this.yylineno -= m.length - 1);
1159
+ var D = this.yylloc.range;
1160
+ return this.yylloc = {
1161
+ first_line: this.yylloc.first_line,
1162
+ last_line: this.yylineno + 1,
1163
+ first_column: this.yylloc.first_column,
1164
+ last_column: m ? (m.length === u.length ? this.yylloc.first_column : 0) + u[u.length - m.length].length - m[0].length : this.yylloc.first_column - d
1165
+ }, this.options.ranges && (this.yylloc.range = [D[0], D[0] + this.yyleng - d]), this.yyleng = this.yytext.length, this;
1166
+ },
1167
+ // When called from action, caches matched text and appends it on next action
1168
+ more: function() {
1169
+ return this._more = !0, this;
1170
+ },
1171
+ // When called from action, signals the lexer that this rule fails to match the input, so the next matching rule (regex) should be tested instead.
1172
+ reject: function() {
1173
+ if (this.options.backtrack_lexer)
1174
+ this._backtrack = !0;
1175
+ else
1176
+ return this.parseError("Lexical error on line " + (this.yylineno + 1) + `. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).
1177
+ ` + this.showPosition(), {
1178
+ text: "",
1179
+ token: null,
1180
+ line: this.yylineno
1181
+ });
1182
+ return this;
1183
+ },
1184
+ // retain first n characters of the match
1185
+ less: function(c) {
1186
+ this.unput(this.match.slice(c));
1187
+ },
1188
+ // displays already matched input, i.e. for error messages
1189
+ pastInput: function() {
1190
+ var c = this.matched.substr(0, this.matched.length - this.match.length);
1191
+ return (c.length > 20 ? "..." : "") + c.substr(-20).replace(/\n/g, "");
1192
+ },
1193
+ // displays upcoming input, i.e. for error messages
1194
+ upcomingInput: function() {
1195
+ var c = this.match;
1196
+ return c.length < 20 && (c += this._input.substr(0, 20 - c.length)), (c.substr(0, 20) + (c.length > 20 ? "..." : "")).replace(/\n/g, "");
1197
+ },
1198
+ // displays the character position where the lexing error occurred, i.e. for error messages
1199
+ showPosition: function() {
1200
+ var c = this.pastInput(), d = new Array(c.length + 1).join("-");
1201
+ return c + this.upcomingInput() + `
1202
+ ` + d + "^";
1203
+ },
1204
+ // test the lexed token: return FALSE when not a match, otherwise return token
1205
+ test_match: function(c, d) {
1206
+ var m, u, D;
1207
+ if (this.options.backtrack_lexer && (D = {
1208
+ yylineno: this.yylineno,
1209
+ yylloc: {
1210
+ first_line: this.yylloc.first_line,
1211
+ last_line: this.last_line,
1212
+ first_column: this.yylloc.first_column,
1213
+ last_column: this.yylloc.last_column
1214
+ },
1215
+ yytext: this.yytext,
1216
+ match: this.match,
1217
+ matches: this.matches,
1218
+ matched: this.matched,
1219
+ yyleng: this.yyleng,
1220
+ offset: this.offset,
1221
+ _more: this._more,
1222
+ _input: this._input,
1223
+ yy: this.yy,
1224
+ conditionStack: this.conditionStack.slice(0),
1225
+ done: this.done
1226
+ }, this.options.ranges && (D.yylloc.range = this.yylloc.range.slice(0))), u = c[0].match(/(?:\r\n?|\n).*/g), u && (this.yylineno += u.length), this.yylloc = {
1227
+ first_line: this.yylloc.last_line,
1228
+ last_line: this.yylineno + 1,
1229
+ first_column: this.yylloc.last_column,
1230
+ last_column: u ? u[u.length - 1].length - u[u.length - 1].match(/\r?\n?/)[0].length : this.yylloc.last_column + c[0].length
1231
+ }, this.yytext += c[0], this.match += c[0], this.matches = c, this.yyleng = this.yytext.length, this.options.ranges && (this.yylloc.range = [this.offset, this.offset += this.yyleng]), this._more = !1, this._backtrack = !1, this._input = this._input.slice(c[0].length), this.matched += c[0], m = this.performAction.call(this, this.yy, this, d, this.conditionStack[this.conditionStack.length - 1]), this.done && this._input && (this.done = !1), m)
1232
+ return m;
1233
+ if (this._backtrack) {
1234
+ for (var o in D)
1235
+ this[o] = D[o];
1236
+ return !1;
1237
+ }
1238
+ return !1;
1239
+ },
1240
+ // return next match in input
1241
+ next: function() {
1242
+ if (this.done)
1243
+ return this.EOF;
1244
+ this._input || (this.done = !0);
1245
+ var c, d, m, u;
1246
+ this._more || (this.yytext = "", this.match = "");
1247
+ for (var D = this._currentRules(), o = 0; o < D.length; o++)
1248
+ if (m = this._input.match(this.rules[D[o]]), m && (!d || m[0].length > d[0].length)) {
1249
+ if (d = m, u = o, this.options.backtrack_lexer) {
1250
+ if (c = this.test_match(m, D[o]), c !== !1)
1251
+ return c;
1252
+ if (this._backtrack) {
1253
+ d = !1;
1254
+ continue;
1255
+ } else
1256
+ return !1;
1257
+ } else if (!this.options.flex)
1258
+ break;
1259
+ }
1260
+ return d ? (c = this.test_match(d, D[u]), c !== !1 ? c : !1) : this._input === "" ? this.EOF : this.parseError("Lexical error on line " + (this.yylineno + 1) + `. Unrecognized text.
1261
+ ` + this.showPosition(), {
1262
+ text: "",
1263
+ token: null,
1264
+ line: this.yylineno
1265
+ });
1266
+ },
1267
+ // return next match that has a token
1268
+ lex: function() {
1269
+ var d = this.next();
1270
+ return d || this.lex();
1271
+ },
1272
+ // activates a new lexer condition state (pushes the new lexer condition state onto the condition stack)
1273
+ begin: function(d) {
1274
+ this.conditionStack.push(d);
1275
+ },
1276
+ // pop the previously active lexer condition state off the condition stack
1277
+ popState: function() {
1278
+ var d = this.conditionStack.length - 1;
1279
+ return d > 0 ? this.conditionStack.pop() : this.conditionStack[0];
1280
+ },
1281
+ // produce the lexer rule set which is active for the currently active lexer condition state
1282
+ _currentRules: function() {
1283
+ return this.conditionStack.length && this.conditionStack[this.conditionStack.length - 1] ? this.conditions[this.conditionStack[this.conditionStack.length - 1]].rules : this.conditions.INITIAL.rules;
1284
+ },
1285
+ // return the currently active lexer condition state; when an index argument is provided it produces the N-th previous condition state, if available
1286
+ topState: function(d) {
1287
+ return d = this.conditionStack.length - 1 - Math.abs(d || 0), d >= 0 ? this.conditionStack[d] : "INITIAL";
1288
+ },
1289
+ // alias for begin(condition)
1290
+ pushState: function(d) {
1291
+ this.begin(d);
1292
+ },
1293
+ // return the number of states currently on the stack
1294
+ stateStackSize: function() {
1295
+ return this.conditionStack.length;
1296
+ },
1297
+ options: { "case-insensitive": !0 },
1298
+ performAction: function(d, m, u, D) {
1299
+ switch (u) {
1300
+ case 0:
1301
+ return this.begin("open_directive"), "open_directive";
1302
+ case 1:
1303
+ return this.begin("acc_title"), 28;
1304
+ case 2:
1305
+ return this.popState(), "acc_title_value";
1306
+ case 3:
1307
+ return this.begin("acc_descr"), 30;
1308
+ case 4:
1309
+ return this.popState(), "acc_descr_value";
1310
+ case 5:
1311
+ this.begin("acc_descr_multiline");
1312
+ break;
1313
+ case 6:
1314
+ this.popState();
1315
+ break;
1316
+ case 7:
1317
+ return "acc_descr_multiline_value";
1318
+ case 8:
1319
+ break;
1320
+ case 9:
1321
+ break;
1322
+ case 10:
1323
+ break;
1324
+ case 11:
1325
+ return 10;
1326
+ case 12:
1327
+ break;
1328
+ case 13:
1329
+ break;
1330
+ case 14:
1331
+ this.begin("href");
1332
+ break;
1333
+ case 15:
1334
+ this.popState();
1335
+ break;
1336
+ case 16:
1337
+ return 40;
1338
+ case 17:
1339
+ this.begin("callbackname");
1340
+ break;
1341
+ case 18:
1342
+ this.popState();
1343
+ break;
1344
+ case 19:
1345
+ this.popState(), this.begin("callbackargs");
1346
+ break;
1347
+ case 20:
1348
+ return 38;
1349
+ case 21:
1350
+ this.popState();
1351
+ break;
1352
+ case 22:
1353
+ return 39;
1354
+ case 23:
1355
+ this.begin("click");
1356
+ break;
1357
+ case 24:
1358
+ this.popState();
1359
+ break;
1360
+ case 25:
1361
+ return 37;
1362
+ case 26:
1363
+ return 4;
1364
+ case 27:
1365
+ return 19;
1366
+ case 28:
1367
+ return 20;
1368
+ case 29:
1369
+ return 21;
1370
+ case 30:
1371
+ return 22;
1372
+ case 31:
1373
+ return 23;
1374
+ case 32:
1375
+ return 25;
1376
+ case 33:
1377
+ return 24;
1378
+ case 34:
1379
+ return 26;
1380
+ case 35:
1381
+ return 12;
1382
+ case 36:
1383
+ return 13;
1384
+ case 37:
1385
+ return 14;
1386
+ case 38:
1387
+ return 15;
1388
+ case 39:
1389
+ return 16;
1390
+ case 40:
1391
+ return 17;
1392
+ case 41:
1393
+ return 18;
1394
+ case 42:
1395
+ return "date";
1396
+ case 43:
1397
+ return 27;
1398
+ case 44:
1399
+ return "accDescription";
1400
+ case 45:
1401
+ return 33;
1402
+ case 46:
1403
+ return 35;
1404
+ case 47:
1405
+ return 36;
1406
+ case 48:
1407
+ return ":";
1408
+ case 49:
1409
+ return 6;
1410
+ case 50:
1411
+ return "INVALID";
1412
+ }
1413
+ },
1414
+ rules: [/^(?:%%\{)/i, /^(?:accTitle\s*:\s*)/i, /^(?:(?!\n||)*[^\n]*)/i, /^(?:accDescr\s*:\s*)/i, /^(?:(?!\n||)*[^\n]*)/i, /^(?:accDescr\s*\{\s*)/i, /^(?:[\}])/i, /^(?:[^\}]*)/i, /^(?:%%(?!\{)*[^\n]*)/i, /^(?:[^\}]%%*[^\n]*)/i, /^(?:%%*[^\n]*[\n]*)/i, /^(?:[\n]+)/i, /^(?:\s+)/i, /^(?:%[^\n]*)/i, /^(?:href[\s]+["])/i, /^(?:["])/i, /^(?:[^"]*)/i, /^(?:call[\s]+)/i, /^(?:\([\s]*\))/i, /^(?:\()/i, /^(?:[^(]*)/i, /^(?:\))/i, /^(?:[^)]*)/i, /^(?:click[\s]+)/i, /^(?:[\s\n])/i, /^(?:[^\s\n]*)/i, /^(?:gantt\b)/i, /^(?:dateFormat\s[^#\n;]+)/i, /^(?:inclusiveEndDates\b)/i, /^(?:topAxis\b)/i, /^(?:axisFormat\s[^#\n;]+)/i, /^(?:tickInterval\s[^#\n;]+)/i, /^(?:includes\s[^#\n;]+)/i, /^(?:excludes\s[^#\n;]+)/i, /^(?:todayMarker\s[^\n;]+)/i, /^(?:weekday\s+monday\b)/i, /^(?:weekday\s+tuesday\b)/i, /^(?:weekday\s+wednesday\b)/i, /^(?:weekday\s+thursday\b)/i, /^(?:weekday\s+friday\b)/i, /^(?:weekday\s+saturday\b)/i, /^(?:weekday\s+sunday\b)/i, /^(?:\d\d\d\d-\d\d-\d\d\b)/i, /^(?:title\s[^\n]+)/i, /^(?:accDescription\s[^#\n;]+)/i, /^(?:section\s[^\n]+)/i, /^(?:[^:\n]+)/i, /^(?::[^#\n;]+)/i, /^(?::)/i, /^(?:$)/i, /^(?:.)/i],
1415
+ conditions: { acc_descr_multiline: { rules: [6, 7], inclusive: !1 }, acc_descr: { rules: [4], inclusive: !1 }, acc_title: { rules: [2], inclusive: !1 }, callbackargs: { rules: [21, 22], inclusive: !1 }, callbackname: { rules: [18, 19, 20], inclusive: !1 }, href: { rules: [15, 16], inclusive: !1 }, click: { rules: [24, 25], inclusive: !1 }, INITIAL: { rules: [0, 1, 3, 5, 8, 9, 10, 11, 12, 13, 14, 17, 23, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50], inclusive: !0 } }
1416
+ };
1417
+ return w;
1418
+ }();
1419
+ b.lexer = U;
1420
+ function _() {
1421
+ this.yy = {};
1422
+ }
1423
+ return _.prototype = b, b.Parser = _, new _();
1424
+ }();
1425
+ fe.parser = fe;
1426
+ const wi = fe;
1427
+ $dayjs.extend(xi);
1428
+ $dayjs.extend(Cn);
1429
+ $dayjs.extend(Dn);
1430
+ let rt = "", ke = "", pe, Te = "", Ot = [], Nt = [], be = {}, ve = [], Gt = [], _t = "", xe = "";
1431
+ const fn = ["active", "done", "crit", "milestone"];
1432
+ let we = [], Ht = !1, Ce = !1, De = "sunday", he = 0;
1433
+ const Ci = function() {
1434
+ ve = [], Gt = [], _t = "", we = [], jt = 0, me = void 0, Bt = void 0, Z = [], rt = "", ke = "", xe = "", pe = void 0, Te = "", Ot = [], Nt = [], Ht = !1, Ce = !1, he = 0, be = {}, An(), De = "sunday";
1435
+ }, Di = function(t) {
1436
+ ke = t;
1437
+ }, Mi = function() {
1438
+ return ke;
1439
+ }, _i = function(t) {
1440
+ pe = t;
1441
+ }, Si = function() {
1442
+ return pe;
1443
+ }, Ui = function(t) {
1444
+ Te = t;
1445
+ }, Fi = function() {
1446
+ return Te;
1447
+ }, Ei = function(t) {
1448
+ rt = t;
1449
+ }, Ai = function() {
1450
+ Ht = !0;
1451
+ }, Ii = function() {
1452
+ return Ht;
1453
+ }, Yi = function() {
1454
+ Ce = !0;
1455
+ }, Li = function() {
1456
+ return Ce;
1457
+ }, Wi = function(t) {
1458
+ xe = t;
1459
+ }, Oi = function() {
1460
+ return xe;
1461
+ }, Ni = function() {
1462
+ return rt;
1463
+ }, Hi = function(t) {
1464
+ Ot = t.toLowerCase().split(/[\s,]+/);
1465
+ }, Vi = function() {
1466
+ return Ot;
1467
+ }, Pi = function(t) {
1468
+ Nt = t.toLowerCase().split(/[\s,]+/);
1469
+ }, Ri = function() {
1470
+ return Nt;
1471
+ }, zi = function() {
1472
+ return be;
1473
+ }, ji = function(t) {
1474
+ _t = t, ve.push(t);
1475
+ }, Bi = function() {
1476
+ return ve;
1477
+ }, qi = function() {
1478
+ let t = He();
1479
+ const e = 10;
1480
+ let n = 0;
1481
+ for (; !t && n < e; )
1482
+ t = He(), n++;
1483
+ return Gt = Z, Gt;
1484
+ }, hn = function(t, e, n, r) {
1485
+ return r.includes(t.format(e.trim())) ? !1 : t.isoWeekday() >= 6 && n.includes("weekends") || n.includes(t.format("dddd").toLowerCase()) ? !0 : n.includes(t.format(e.trim()));
1486
+ }, Zi = function(t) {
1487
+ De = t;
1488
+ }, Xi = function() {
1489
+ return De;
1490
+ }, dn = function(t, e, n, r) {
1491
+ if (!n.length || t.manualEndTime)
1492
+ return;
1493
+ let i;
1494
+ t.startTime instanceof Date ? i = $dayjs(t.startTime) : i = $dayjs(t.startTime, e, !0), i = i.add(1, "d");
1495
+ let s;
1496
+ t.endTime instanceof Date ? s = $dayjs(t.endTime) : s = $dayjs(t.endTime, e, !0);
1497
+ const [a, x] = Qi(
1498
+ i,
1499
+ s,
1500
+ e,
1501
+ n,
1502
+ r
1503
+ );
1504
+ t.endTime = a.toDate(), t.renderEndTime = x;
1505
+ }, Qi = function(t, e, n, r, i) {
1506
+ let s = !1, a = null;
1507
+ for (; t <= e; )
1508
+ s || (a = e.toDate()), s = hn(t, n, r, i), s && (e = e.add(1, "d")), t = t.add(1, "d");
1509
+ return [e, a];
1510
+ }, de = function(t, e, n) {
1511
+ n = n.trim();
1512
+ const i = /^after\s+(?<ids>[\d\w- ]+)/.exec(n);
1513
+ if (i !== null) {
1514
+ let a = null;
1515
+ for (const S of i.groups.ids.split(" ")) {
1516
+ let k = bt(S);
1517
+ k !== void 0 && (!a || k.endTime > a.endTime) && (a = k);
1518
+ }
1519
+ if (a)
1520
+ return a.endTime;
1521
+ const x = /* @__PURE__ */ new Date();
1522
+ return x.setHours(0, 0, 0, 0), x;
1523
+ }
1524
+ let s = $dayjs(n, e.trim(), !0);
1525
+ if (s.isValid())
1526
+ return s.toDate();
1527
+ {
1528
+ qt.debug("Invalid date:" + n), qt.debug("With date format:" + e.trim());
1529
+ const a = new Date(n);
1530
+ if (a === void 0 || isNaN(a.getTime()) || // WebKit browsers can mis-parse invalid dates to be ridiculously
1531
+ // huge numbers, e.g. new Date('202304') gets parsed as January 1, 202304.
1532
+ // This can cause virtually infinite loops while rendering, so for the
1533
+ // purposes of Gantt charts we'll just treat any date beyond 10,000 AD/BC as
1534
+ // invalid.
1535
+ a.getFullYear() < -1e4 || a.getFullYear() > 1e4)
1536
+ throw new Error("Invalid date:" + n);
1537
+ return a;
1538
+ }
1539
+ }, mn = function(t) {
1540
+ const e = /^(\d+(?:\.\d+)?)([Mdhmswy]|ms)$/.exec(t.trim());
1541
+ return e !== null ? [Number.parseFloat(e[1]), e[2]] : [NaN, "ms"];
1542
+ }, yn = function(t, e, n, r = !1) {
1543
+ n = n.trim();
1544
+ const s = /^until\s+(?<ids>[\d\w- ]+)/.exec(n);
1545
+ if (s !== null) {
1546
+ let p = null;
1547
+ for (const T of s.groups.ids.split(" ")) {
1548
+ let g = bt(T);
1549
+ g !== void 0 && (!p || g.startTime < p.startTime) && (p = g);
1550
+ }
1551
+ if (p)
1552
+ return p.startTime;
1553
+ const F = /* @__PURE__ */ new Date();
1554
+ return F.setHours(0, 0, 0, 0), F;
1555
+ }
1556
+ let a = $dayjs(n, e.trim(), !0);
1557
+ if (a.isValid())
1558
+ return r && (a = a.add(1, "d")), a.toDate();
1559
+ let x = $dayjs(t);
1560
+ const [S, k] = mn(n);
1561
+ if (!Number.isNaN(S)) {
1562
+ const p = x.add(S, k);
1563
+ p.isValid() && (x = p);
1564
+ }
1565
+ return x.toDate();
1566
+ };
1567
+ let jt = 0;
1568
+ const Ct = function(t) {
1569
+ return t === void 0 ? (jt = jt + 1, "task" + jt) : t;
1570
+ }, Gi = function(t, e) {
1571
+ let n;
1572
+ e.substr(0, 1) === ":" ? n = e.substr(1, e.length) : n = e;
1573
+ const r = n.split(","), i = {};
1574
+ Tn(r, i, fn);
1575
+ for (let a = 0; a < r.length; a++)
1576
+ r[a] = r[a].trim();
1577
+ let s = "";
1578
+ switch (r.length) {
1579
+ case 1:
1580
+ i.id = Ct(), i.startTime = t.endTime, s = r[0];
1581
+ break;
1582
+ case 2:
1583
+ i.id = Ct(), i.startTime = de(void 0, rt, r[0]), s = r[1];
1584
+ break;
1585
+ case 3:
1586
+ i.id = Ct(r[0]), i.startTime = de(void 0, rt, r[1]), s = r[2];
1587
+ break;
1588
+ }
1589
+ return s && (i.endTime = yn(i.startTime, rt, s, Ht), i.manualEndTime = $dayjs(s, "YYYY-MM-DD", !0).isValid(), dn(i, rt, Nt, Ot)), i;
1590
+ }, Ji = function(t, e) {
1591
+ let n;
1592
+ e.substr(0, 1) === ":" ? n = e.substr(1, e.length) : n = e;
1593
+ const r = n.split(","), i = {};
1594
+ Tn(r, i, fn);
1595
+ for (let s = 0; s < r.length; s++)
1596
+ r[s] = r[s].trim();
1597
+ switch (r.length) {
1598
+ case 1:
1599
+ i.id = Ct(), i.startTime = {
1600
+ type: "prevTaskEnd",
1601
+ id: t
1602
+ }, i.endTime = {
1603
+ data: r[0]
1604
+ };
1605
+ break;
1606
+ case 2:
1607
+ i.id = Ct(), i.startTime = {
1608
+ type: "getStartDate",
1609
+ startData: r[0]
1610
+ }, i.endTime = {
1611
+ data: r[1]
1612
+ };
1613
+ break;
1614
+ case 3:
1615
+ i.id = Ct(r[0]), i.startTime = {
1616
+ type: "getStartDate",
1617
+ startData: r[1]
1618
+ }, i.endTime = {
1619
+ data: r[2]
1620
+ };
1621
+ break;
1622
+ }
1623
+ return i;
1624
+ };
1625
+ let me, Bt, Z = [];
1626
+ const gn = {}, Ki = function(t, e) {
1627
+ const n = {
1628
+ section: _t,
1629
+ type: _t,
1630
+ processed: !1,
1631
+ manualEndTime: !1,
1632
+ renderEndTime: null,
1633
+ raw: { data: e },
1634
+ task: t,
1635
+ classes: []
1636
+ }, r = Ji(Bt, e);
1637
+ n.raw.startTime = r.startTime, n.raw.endTime = r.endTime, n.id = r.id, n.prevTaskId = Bt, n.active = r.active, n.done = r.done, n.crit = r.crit, n.milestone = r.milestone, n.order = he, he++;
1638
+ const i = Z.push(n);
1639
+ Bt = n.id, gn[n.id] = i - 1;
1640
+ }, bt = function(t) {
1641
+ const e = gn[t];
1642
+ return Z[e];
1643
+ }, $i = function(t, e) {
1644
+ const n = {
1645
+ section: _t,
1646
+ type: _t,
1647
+ description: t,
1648
+ task: t,
1649
+ classes: []
1650
+ }, r = Gi(me, e);
1651
+ n.startTime = r.startTime, n.endTime = r.endTime, n.id = r.id, n.active = r.active, n.done = r.done, n.crit = r.crit, n.milestone = r.milestone, me = n, Gt.push(n);
1652
+ }, He = function() {
1653
+ const t = function(n) {
1654
+ const r = Z[n];
1655
+ let i = "";
1656
+ switch (Z[n].raw.startTime.type) {
1657
+ case "prevTaskEnd": {
1658
+ const s = bt(r.prevTaskId);
1659
+ r.startTime = s.endTime;
1660
+ break;
1661
+ }
1662
+ case "getStartDate":
1663
+ i = de(void 0, rt, Z[n].raw.startTime.startData), i && (Z[n].startTime = i);
1664
+ break;
1665
+ }
1666
+ return Z[n].startTime && (Z[n].endTime = yn(
1667
+ Z[n].startTime,
1668
+ rt,
1669
+ Z[n].raw.endTime.data,
1670
+ Ht
1671
+ ), Z[n].endTime && (Z[n].processed = !0, Z[n].manualEndTime = $dayjs(
1672
+ Z[n].raw.endTime.data,
1673
+ "YYYY-MM-DD",
1674
+ !0
1675
+ ).isValid(), dn(Z[n], rt, Nt, Ot))), Z[n].processed;
1676
+ };
1677
+ let e = !0;
1678
+ for (const [n, r] of Z.entries())
1679
+ t(n), e = e && r.processed;
1680
+ return e;
1681
+ }, ts = function(t, e) {
1682
+ let n = e;
1683
+ xt().securityLevel !== "loose" && (n = In.sanitizeUrl(e)), t.split(",").forEach(function(r) {
1684
+ bt(r) !== void 0 && (pn(r, () => {
1685
+ window.open(n, "_self");
1686
+ }), be[r] = n);
1687
+ }), kn(t, "clickable");
1688
+ }, kn = function(t, e) {
1689
+ t.split(",").forEach(function(n) {
1690
+ let r = bt(n);
1691
+ r !== void 0 && r.classes.push(e);
1692
+ });
1693
+ }, es = function(t, e, n) {
1694
+ if (xt().securityLevel !== "loose" || e === void 0)
1695
+ return;
1696
+ let r = [];
1697
+ if (typeof n == "string") {
1698
+ r = n.split(/,(?=(?:(?:[^"]*"){2})*[^"]*$)/);
1699
+ for (let s = 0; s < r.length; s++) {
1700
+ let a = r[s].trim();
1701
+ a.charAt(0) === '"' && a.charAt(a.length - 1) === '"' && (a = a.substr(1, a.length - 2)), r[s] = a;
1702
+ }
1703
+ }
1704
+ r.length === 0 && r.push(t), bt(t) !== void 0 && pn(t, () => {
1705
+ Wn.runFunc(e, ...r);
1706
+ });
1707
+ }, pn = function(t, e) {
1708
+ we.push(
1709
+ function() {
1710
+ const n = document.querySelector(`[id="${t}"]`);
1711
+ n !== null && n.addEventListener("click", function() {
1712
+ e();
1713
+ });
1714
+ },
1715
+ function() {
1716
+ const n = document.querySelector(`[id="${t}-text"]`);
1717
+ n !== null && n.addEventListener("click", function() {
1718
+ e();
1719
+ });
1720
+ }
1721
+ );
1722
+ }, ns = function(t, e, n) {
1723
+ t.split(",").forEach(function(r) {
1724
+ es(r, e, n);
1725
+ }), kn(t, "clickable");
1726
+ }, rs = function(t) {
1727
+ we.forEach(function(e) {
1728
+ e(t);
1729
+ });
1730
+ }, is = {
1731
+ getConfig: () => xt().gantt,
1732
+ clear: Ci,
1733
+ setDateFormat: Ei,
1734
+ getDateFormat: Ni,
1735
+ enableInclusiveEndDates: Ai,
1736
+ endDatesAreInclusive: Ii,
1737
+ enableTopAxis: Yi,
1738
+ topAxisEnabled: Li,
1739
+ setAxisFormat: Di,
1740
+ getAxisFormat: Mi,
1741
+ setTickInterval: _i,
1742
+ getTickInterval: Si,
1743
+ setTodayMarker: Ui,
1744
+ getTodayMarker: Fi,
1745
+ setAccTitle: Mn,
1746
+ getAccTitle: _n,
1747
+ setDiagramTitle: Sn,
1748
+ getDiagramTitle: Un,
1749
+ setDisplayMode: Wi,
1750
+ getDisplayMode: Oi,
1751
+ setAccDescription: Fn,
1752
+ getAccDescription: En,
1753
+ addSection: ji,
1754
+ getSections: Bi,
1755
+ getTasks: qi,
1756
+ addTask: Ki,
1757
+ findTaskById: bt,
1758
+ addTaskOrg: $i,
1759
+ setIncludes: Hi,
1760
+ getIncludes: Vi,
1761
+ setExcludes: Pi,
1762
+ getExcludes: Ri,
1763
+ setClickEvent: ns,
1764
+ setLink: ts,
1765
+ getLinks: zi,
1766
+ bindFunctions: rs,
1767
+ parseDuration: mn,
1768
+ isInvalidDate: hn,
1769
+ setWeekday: Zi,
1770
+ getWeekday: Xi
1771
+ };
1772
+ function Tn(t, e, n) {
1773
+ let r = !0;
1774
+ for (; r; )
1775
+ r = !1, n.forEach(function(i) {
1776
+ const s = "^\\s*" + i + "\\s*$", a = new RegExp(s);
1777
+ t[0].match(a) && (e[i] = !0, t.shift(1), r = !0);
1778
+ });
1779
+ }
1780
+ const ss = function() {
1781
+ qt.debug("Something is calling, setConf, remove the call");
1782
+ }, Ve = {
1783
+ monday: Yt,
1784
+ tuesday: $e,
1785
+ wednesday: tn,
1786
+ thursday: gt,
1787
+ friday: en,
1788
+ saturday: nn,
1789
+ sunday: Wt
1790
+ }, as = (t, e) => {
1791
+ let n = [...t].map(() => -1 / 0), r = [...t].sort((s, a) => s.startTime - a.startTime || s.order - a.order), i = 0;
1792
+ for (const s of r)
1793
+ for (let a = 0; a < n.length; a++)
1794
+ if (s.startTime >= n[a]) {
1795
+ n[a] = s.endTime, s.order = a + e, a > i && (i = a);
1796
+ break;
1797
+ }
1798
+ return i;
1799
+ };
1800
+ let at;
1801
+ const os = function(t, e, n, r) {
1802
+ const i = xt().gantt, s = xt().securityLevel;
1803
+ let a;
1804
+ s === "sandbox" && (a = Pt("#i" + e));
1805
+ const x = s === "sandbox" ? Pt(a.nodes()[0].contentDocument.body) : Pt("body"), S = s === "sandbox" ? a.nodes()[0].contentDocument : document, k = S.getElementById(e);
1806
+ at = k.parentElement.offsetWidth, at === void 0 && (at = 1200), i.useWidth !== void 0 && (at = i.useWidth);
1807
+ const p = r.db.getTasks();
1808
+ let F = [];
1809
+ for (const b of p)
1810
+ F.push(b.type);
1811
+ F = H(F);
1812
+ const T = {};
1813
+ let g = 2 * i.topPadding;
1814
+ if (r.db.getDisplayMode() === "compact" || i.displayMode === "compact") {
1815
+ const b = {};
1816
+ for (const _ of p)
1817
+ b[_.section] === void 0 ? b[_.section] = [_] : b[_.section].push(_);
1818
+ let U = 0;
1819
+ for (const _ of Object.keys(b)) {
1820
+ const w = as(b[_], U) + 1;
1821
+ U += w, g += w * (i.barHeight + i.barGap), T[_] = w;
1822
+ }
1823
+ } else {
1824
+ g += p.length * (i.barHeight + i.barGap);
1825
+ for (const b of F)
1826
+ T[b] = p.filter((U) => U.type === b).length;
1827
+ }
1828
+ k.setAttribute("viewBox", "0 0 " + at + " " + g);
1829
+ const P = x.select(`[id="${e}"]`), E = bi().domain([
1830
+ zn(p, function(b) {
1831
+ return b.startTime;
1832
+ }),
1833
+ Rn(p, function(b) {
1834
+ return b.endTime;
1835
+ })
1836
+ ]).rangeRound([0, at - i.leftPadding - i.rightPadding]);
1837
+ function $(b, U) {
1838
+ const _ = b.startTime, w = U.startTime;
1839
+ let c = 0;
1840
+ return _ > w ? c = 1 : _ < w && (c = -1), c;
1841
+ }
1842
+ p.sort($), et(p, at, g), Yn(P, g, at, i.useMaxWidth), P.append("text").text(r.db.getDiagramTitle()).attr("x", at / 2).attr("y", i.titleTopMargin).attr("class", "titleText");
1843
+ function et(b, U, _) {
1844
+ const w = i.barHeight, c = w + i.barGap, d = i.topPadding, m = i.leftPadding, u = Vn().domain([0, F.length]).range(["#00B9FA", "#F95002"]).interpolate(ir);
1845
+ B(
1846
+ c,
1847
+ d,
1848
+ m,
1849
+ U,
1850
+ _,
1851
+ b,
1852
+ r.db.getExcludes(),
1853
+ r.db.getIncludes()
1854
+ ), q(m, d, U, _), tt(b, c, d, m, w, u, U), K(c, d), v(m, d, U, _);
1855
+ }
1856
+ function tt(b, U, _, w, c, d, m) {
1857
+ const D = [...new Set(b.map((f) => f.order))].map((f) => b.find((M) => M.order === f));
1858
+ P.append("g").selectAll("rect").data(D).enter().append("rect").attr("x", 0).attr("y", function(f, M) {
1859
+ return M = f.order, M * U + _ - 2;
1860
+ }).attr("width", function() {
1861
+ return m - i.rightPadding / 2;
1862
+ }).attr("height", U).attr("class", function(f) {
1863
+ for (const [M, R] of F.entries())
1864
+ if (f.type === R)
1865
+ return "section section" + M % i.numberSectionStyles;
1866
+ return "section section0";
1867
+ });
1868
+ const o = P.append("g").selectAll("rect").data(b).enter(), z = r.db.getLinks();
1869
+ if (o.append("rect").attr("id", function(f) {
1870
+ return f.id;
1871
+ }).attr("rx", 3).attr("ry", 3).attr("x", function(f) {
1872
+ return f.milestone ? E(f.startTime) + w + 0.5 * (E(f.endTime) - E(f.startTime)) - 0.5 * c : E(f.startTime) + w;
1873
+ }).attr("y", function(f, M) {
1874
+ return M = f.order, M * U + _;
1875
+ }).attr("width", function(f) {
1876
+ return f.milestone ? c : E(f.renderEndTime || f.endTime) - E(f.startTime);
1877
+ }).attr("height", c).attr("transform-origin", function(f, M) {
1878
+ return M = f.order, (E(f.startTime) + w + 0.5 * (E(f.endTime) - E(f.startTime))).toString() + "px " + (M * U + _ + 0.5 * c).toString() + "px";
1879
+ }).attr("class", function(f) {
1880
+ const M = "task";
1881
+ let R = "";
1882
+ f.classes.length > 0 && (R = f.classes.join(" "));
1883
+ let Y = 0;
1884
+ for (const [I, O] of F.entries())
1885
+ f.type === O && (Y = I % i.numberSectionStyles);
1886
+ let W = "";
1887
+ return f.active ? f.crit ? W += " activeCrit" : W = " active" : f.done ? f.crit ? W = " doneCrit" : W = " done" : f.crit && (W += " crit"), W.length === 0 && (W = " task"), f.milestone && (W = " milestone " + W), W += Y, W += " " + R, M + W;
1888
+ }), o.append("text").attr("id", function(f) {
1889
+ return f.id + "-text";
1890
+ }).text(function(f) {
1891
+ return f.task;
1892
+ }).attr("font-size", i.fontSize).attr("x", function(f) {
1893
+ let M = E(f.startTime), R = E(f.renderEndTime || f.endTime);
1894
+ f.milestone && (M += 0.5 * (E(f.endTime) - E(f.startTime)) - 0.5 * c), f.milestone && (R = M + c);
1895
+ const Y = this.getBBox().width;
1896
+ return Y > R - M ? R + Y + 1.5 * i.leftPadding > m ? M + w - 5 : R + w + 5 : (R - M) / 2 + M + w;
1897
+ }).attr("y", function(f, M) {
1898
+ return M = f.order, M * U + i.barHeight / 2 + (i.fontSize / 2 - 2) + _;
1899
+ }).attr("text-height", c).attr("class", function(f) {
1900
+ const M = E(f.startTime);
1901
+ let R = E(f.endTime);
1902
+ f.milestone && (R = M + c);
1903
+ const Y = this.getBBox().width;
1904
+ let W = "";
1905
+ f.classes.length > 0 && (W = f.classes.join(" "));
1906
+ let I = 0;
1907
+ for (const [dt, mt] of F.entries())
1908
+ f.type === mt && (I = dt % i.numberSectionStyles);
1909
+ let O = "";
1910
+ return f.active && (f.crit ? O = "activeCritText" + I : O = "activeText" + I), f.done ? f.crit ? O = O + " doneCritText" + I : O = O + " doneText" + I : f.crit && (O = O + " critText" + I), f.milestone && (O += " milestoneText"), Y > R - M ? R + Y + 1.5 * i.leftPadding > m ? W + " taskTextOutsideLeft taskTextOutside" + I + " " + O : W + " taskTextOutsideRight taskTextOutside" + I + " " + O + " width-" + Y : W + " taskText taskText" + I + " " + O + " width-" + Y;
1911
+ }), xt().securityLevel === "sandbox") {
1912
+ let f;
1913
+ f = Pt("#i" + e);
1914
+ const M = f.nodes()[0].contentDocument;
1915
+ o.filter(function(R) {
1916
+ return z[R.id] !== void 0;
1917
+ }).each(function(R) {
1918
+ var Y = M.querySelector("#" + R.id), W = M.querySelector("#" + R.id + "-text");
1919
+ const I = Y.parentNode;
1920
+ var O = M.createElement("a");
1921
+ O.setAttribute("xlink:href", z[R.id]), O.setAttribute("target", "_top"), I.appendChild(O), O.appendChild(Y), O.appendChild(W);
1922
+ });
1923
+ }
1924
+ }
1925
+ function B(b, U, _, w, c, d, m, u) {
1926
+ if (m.length === 0 && u.length === 0)
1927
+ return;
1928
+ let D, o;
1929
+ for (const { startTime: Y, endTime: W } of d)
1930
+ (D === void 0 || Y < D) && (D = Y), (o === void 0 || W > o) && (o = W);
1931
+ if (!D || !o)
1932
+ return;
1933
+ if ($dayjs(o).diff($dayjs(D), "year") > 5) {
1934
+ qt.warn(
1935
+ "The difference between the min and max time is more than 5 years. This will cause performance issues. Skipping drawing exclude days."
1936
+ );
1937
+ return;
1938
+ }
1939
+ const z = r.db.getDateFormat(), h = [];
1940
+ let f = null, M = $dayjs(D);
1941
+ for (; M.valueOf() <= o; )
1942
+ r.db.isInvalidDate(M, z, m, u) ? f ? f.end = M : f = {
1943
+ start: M,
1944
+ end: M
1945
+ } : f && (h.push(f), f = null), M = M.add(1, "d");
1946
+ P.append("g").selectAll("rect").data(h).enter().append("rect").attr("id", function(Y) {
1947
+ return "exclude-" + Y.start.format("YYYY-MM-DD");
1948
+ }).attr("x", function(Y) {
1949
+ return E(Y.start) + _;
1950
+ }).attr("y", i.gridLineStartPadding).attr("width", function(Y) {
1951
+ const W = Y.end.add(1, "day");
1952
+ return E(W) - E(Y.start);
1953
+ }).attr("height", c - U - i.gridLineStartPadding).attr("transform-origin", function(Y, W) {
1954
+ return (E(Y.start) + _ + 0.5 * (E(Y.end) - E(Y.start))).toString() + "px " + (W * b + 0.5 * c).toString() + "px";
1955
+ }).attr("class", "exclude-range");
1956
+ }
1957
+ function q(b, U, _, w) {
1958
+ let c = Jn(E).tickSize(-w + U + i.gridLineStartPadding).tickFormat(Qt(r.db.getAxisFormat() || i.axisFormat || "%Y-%m-%d"));
1959
+ const m = /^([1-9]\d*)(millisecond|second|minute|hour|day|week|month)$/.exec(
1960
+ r.db.getTickInterval() || i.tickInterval
1961
+ );
1962
+ if (m !== null) {
1963
+ const u = m[1], D = m[2], o = r.db.getWeekday() || i.weekday;
1964
+ switch (D) {
1965
+ case "millisecond":
1966
+ c.ticks(Dt.every(u));
1967
+ break;
1968
+ case "second":
1969
+ c.ticks(ht.every(u));
1970
+ break;
1971
+ case "minute":
1972
+ c.ticks(At.every(u));
1973
+ break;
1974
+ case "hour":
1975
+ c.ticks(It.every(u));
1976
+ break;
1977
+ case "day":
1978
+ c.ticks(yt.every(u));
1979
+ break;
1980
+ case "week":
1981
+ c.ticks(Ve[o].every(u));
1982
+ break;
1983
+ case "month":
1984
+ c.ticks(Lt.every(u));
1985
+ break;
1986
+ }
1987
+ }
1988
+ if (P.append("g").attr("class", "grid").attr("transform", "translate(" + b + ", " + (w - 50) + ")").call(c).selectAll("text").style("text-anchor", "middle").attr("fill", "#000").attr("stroke", "none").attr("font-size", 10).attr("dy", "1em"), r.db.topAxisEnabled() || i.topAxis) {
1989
+ let u = Gn(E).tickSize(-w + U + i.gridLineStartPadding).tickFormat(Qt(r.db.getAxisFormat() || i.axisFormat || "%Y-%m-%d"));
1990
+ if (m !== null) {
1991
+ const D = m[1], o = m[2], z = r.db.getWeekday() || i.weekday;
1992
+ switch (o) {
1993
+ case "millisecond":
1994
+ u.ticks(Dt.every(D));
1995
+ break;
1996
+ case "second":
1997
+ u.ticks(ht.every(D));
1998
+ break;
1999
+ case "minute":
2000
+ u.ticks(At.every(D));
2001
+ break;
2002
+ case "hour":
2003
+ u.ticks(It.every(D));
2004
+ break;
2005
+ case "day":
2006
+ u.ticks(yt.every(D));
2007
+ break;
2008
+ case "week":
2009
+ u.ticks(Ve[z].every(D));
2010
+ break;
2011
+ case "month":
2012
+ u.ticks(Lt.every(D));
2013
+ break;
2014
+ }
2015
+ }
2016
+ P.append("g").attr("class", "grid").attr("transform", "translate(" + b + ", " + U + ")").call(u).selectAll("text").style("text-anchor", "middle").attr("fill", "#000").attr("stroke", "none").attr("font-size", 10);
2017
+ }
2018
+ }
2019
+ function K(b, U) {
2020
+ let _ = 0;
2021
+ const w = Object.keys(T).map((c) => [c, T[c]]);
2022
+ P.append("g").selectAll("text").data(w).enter().append(function(c) {
2023
+ const d = c[0].split(Ln.lineBreakRegex), m = -(d.length - 1) / 2, u = S.createElementNS("http://www.w3.org/2000/svg", "text");
2024
+ u.setAttribute("dy", m + "em");
2025
+ for (const [D, o] of d.entries()) {
2026
+ const z = S.createElementNS("http://www.w3.org/2000/svg", "tspan");
2027
+ z.setAttribute("alignment-baseline", "central"), z.setAttribute("x", "10"), D > 0 && z.setAttribute("dy", "1em"), z.textContent = o, u.appendChild(z);
2028
+ }
2029
+ return u;
2030
+ }).attr("x", 10).attr("y", function(c, d) {
2031
+ if (d > 0)
2032
+ for (let m = 0; m < d; m++)
2033
+ return _ += w[d - 1][1], c[1] * b / 2 + _ * b + U;
2034
+ else
2035
+ return c[1] * b / 2 + U;
2036
+ }).attr("font-size", i.sectionFontSize).attr("class", function(c) {
2037
+ for (const [d, m] of F.entries())
2038
+ if (c[0] === m)
2039
+ return "sectionTitle sectionTitle" + d % i.numberSectionStyles;
2040
+ return "sectionTitle";
2041
+ });
2042
+ }
2043
+ function v(b, U, _, w) {
2044
+ const c = r.db.getTodayMarker();
2045
+ if (c === "off")
2046
+ return;
2047
+ const d = P.append("g").attr("class", "today"), m = /* @__PURE__ */ new Date(), u = d.append("line");
2048
+ u.attr("x1", E(m) + b).attr("x2", E(m) + b).attr("y1", i.titleTopMargin).attr("y2", w - i.titleTopMargin).attr("class", "today"), c !== "" && u.attr("style", c.replace(/,/g, ";"));
2049
+ }
2050
+ function H(b) {
2051
+ const U = {}, _ = [];
2052
+ for (let w = 0, c = b.length; w < c; ++w)
2053
+ Object.prototype.hasOwnProperty.call(U, b[w]) || (U[b[w]] = !0, _.push(b[w]));
2054
+ return _;
2055
+ }
2056
+ }, cs = {
2057
+ setConf: ss,
2058
+ draw: os
2059
+ }, ls = (t) => `
2060
+ .mermaid-main-font {
2061
+ font-family: var(--mermaid-font-family, "trebuchet ms", verdana, arial, sans-serif);
2062
+ }
2063
+
2064
+ .exclude-range {
2065
+ fill: ${t.excludeBkgColor};
2066
+ }
2067
+
2068
+ .section {
2069
+ stroke: none;
2070
+ opacity: 0.2;
2071
+ }
2072
+
2073
+ .section0 {
2074
+ fill: ${t.sectionBkgColor};
2075
+ }
2076
+
2077
+ .section2 {
2078
+ fill: ${t.sectionBkgColor2};
2079
+ }
2080
+
2081
+ .section1,
2082
+ .section3 {
2083
+ fill: ${t.altSectionBkgColor};
2084
+ opacity: 0.2;
2085
+ }
2086
+
2087
+ .sectionTitle0 {
2088
+ fill: ${t.titleColor};
2089
+ }
2090
+
2091
+ .sectionTitle1 {
2092
+ fill: ${t.titleColor};
2093
+ }
2094
+
2095
+ .sectionTitle2 {
2096
+ fill: ${t.titleColor};
2097
+ }
2098
+
2099
+ .sectionTitle3 {
2100
+ fill: ${t.titleColor};
2101
+ }
2102
+
2103
+ .sectionTitle {
2104
+ text-anchor: start;
2105
+ font-family: var(--mermaid-font-family, "trebuchet ms", verdana, arial, sans-serif);
2106
+ }
2107
+
2108
+
2109
+ /* Grid and axis */
2110
+
2111
+ .grid .tick {
2112
+ stroke: ${t.gridColor};
2113
+ opacity: 0.8;
2114
+ shape-rendering: crispEdges;
2115
+ }
2116
+
2117
+ .grid .tick text {
2118
+ font-family: ${t.fontFamily};
2119
+ fill: ${t.textColor};
2120
+ }
2121
+
2122
+ .grid path {
2123
+ stroke-width: 0;
2124
+ }
2125
+
2126
+
2127
+ /* Today line */
2128
+
2129
+ .today {
2130
+ fill: none;
2131
+ stroke: ${t.todayLineColor};
2132
+ stroke-width: 2px;
2133
+ }
2134
+
2135
+
2136
+ /* Task styling */
2137
+
2138
+ /* Default task */
2139
+
2140
+ .task {
2141
+ stroke-width: 2;
2142
+ }
2143
+
2144
+ .taskText {
2145
+ text-anchor: middle;
2146
+ font-family: var(--mermaid-font-family, "trebuchet ms", verdana, arial, sans-serif);
2147
+ }
2148
+
2149
+ .taskTextOutsideRight {
2150
+ fill: ${t.taskTextDarkColor};
2151
+ text-anchor: start;
2152
+ font-family: var(--mermaid-font-family, "trebuchet ms", verdana, arial, sans-serif);
2153
+ }
2154
+
2155
+ .taskTextOutsideLeft {
2156
+ fill: ${t.taskTextDarkColor};
2157
+ text-anchor: end;
2158
+ }
2159
+
2160
+
2161
+ /* Special case clickable */
2162
+
2163
+ .task.clickable {
2164
+ cursor: pointer;
2165
+ }
2166
+
2167
+ .taskText.clickable {
2168
+ cursor: pointer;
2169
+ fill: ${t.taskTextClickableColor} !important;
2170
+ font-weight: bold;
2171
+ }
2172
+
2173
+ .taskTextOutsideLeft.clickable {
2174
+ cursor: pointer;
2175
+ fill: ${t.taskTextClickableColor} !important;
2176
+ font-weight: bold;
2177
+ }
2178
+
2179
+ .taskTextOutsideRight.clickable {
2180
+ cursor: pointer;
2181
+ fill: ${t.taskTextClickableColor} !important;
2182
+ font-weight: bold;
2183
+ }
2184
+
2185
+
2186
+ /* Specific task settings for the sections*/
2187
+
2188
+ .taskText0,
2189
+ .taskText1,
2190
+ .taskText2,
2191
+ .taskText3 {
2192
+ fill: ${t.taskTextColor};
2193
+ }
2194
+
2195
+ .task0,
2196
+ .task1,
2197
+ .task2,
2198
+ .task3 {
2199
+ fill: ${t.taskBkgColor};
2200
+ stroke: ${t.taskBorderColor};
2201
+ }
2202
+
2203
+ .taskTextOutside0,
2204
+ .taskTextOutside2
2205
+ {
2206
+ fill: ${t.taskTextOutsideColor};
2207
+ }
2208
+
2209
+ .taskTextOutside1,
2210
+ .taskTextOutside3 {
2211
+ fill: ${t.taskTextOutsideColor};
2212
+ }
2213
+
2214
+
2215
+ /* Active task */
2216
+
2217
+ .active0,
2218
+ .active1,
2219
+ .active2,
2220
+ .active3 {
2221
+ fill: ${t.activeTaskBkgColor};
2222
+ stroke: ${t.activeTaskBorderColor};
2223
+ }
2224
+
2225
+ .activeText0,
2226
+ .activeText1,
2227
+ .activeText2,
2228
+ .activeText3 {
2229
+ fill: ${t.taskTextDarkColor} !important;
2230
+ }
2231
+
2232
+
2233
+ /* Completed task */
2234
+
2235
+ .done0,
2236
+ .done1,
2237
+ .done2,
2238
+ .done3 {
2239
+ stroke: ${t.doneTaskBorderColor};
2240
+ fill: ${t.doneTaskBkgColor};
2241
+ stroke-width: 2;
2242
+ }
2243
+
2244
+ .doneText0,
2245
+ .doneText1,
2246
+ .doneText2,
2247
+ .doneText3 {
2248
+ fill: ${t.taskTextDarkColor} !important;
2249
+ }
2250
+
2251
+
2252
+ /* Tasks on the critical line */
2253
+
2254
+ .crit0,
2255
+ .crit1,
2256
+ .crit2,
2257
+ .crit3 {
2258
+ stroke: ${t.critBorderColor};
2259
+ fill: ${t.critBkgColor};
2260
+ stroke-width: 2;
2261
+ }
2262
+
2263
+ .activeCrit0,
2264
+ .activeCrit1,
2265
+ .activeCrit2,
2266
+ .activeCrit3 {
2267
+ stroke: ${t.critBorderColor};
2268
+ fill: ${t.activeTaskBkgColor};
2269
+ stroke-width: 2;
2270
+ }
2271
+
2272
+ .doneCrit0,
2273
+ .doneCrit1,
2274
+ .doneCrit2,
2275
+ .doneCrit3 {
2276
+ stroke: ${t.critBorderColor};
2277
+ fill: ${t.doneTaskBkgColor};
2278
+ stroke-width: 2;
2279
+ cursor: pointer;
2280
+ shape-rendering: crispEdges;
2281
+ }
2282
+
2283
+ .milestone {
2284
+ transform: rotate(45deg) scale(0.8,0.8);
2285
+ }
2286
+
2287
+ .milestoneText {
2288
+ font-style: italic;
2289
+ }
2290
+ .doneCritText0,
2291
+ .doneCritText1,
2292
+ .doneCritText2,
2293
+ .doneCritText3 {
2294
+ fill: ${t.taskTextDarkColor} !important;
2295
+ }
2296
+
2297
+ .activeCritText0,
2298
+ .activeCritText1,
2299
+ .activeCritText2,
2300
+ .activeCritText3 {
2301
+ fill: ${t.taskTextDarkColor} !important;
2302
+ }
2303
+
2304
+ .titleText {
2305
+ text-anchor: middle;
2306
+ font-size: 18px;
2307
+ fill: ${t.titleColor || t.textColor};
2308
+ font-family: var(--mermaid-font-family, "trebuchet ms", verdana, arial, sans-serif);
2309
+ }
2310
+ `, us = ls, ms = {
2311
+ parser: wi,
2312
+ db: is,
2313
+ renderer: cs,
2314
+ styles: us
2315
+ };
2316
+ export {
2317
+ ms as diagram
2318
+ };