overview-components 1.0.92 → 1.0.95

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 (117) hide show
  1. package/dist/_virtual/FileSaver.min.js +4 -0
  2. package/dist/_virtual/___vite-browser-external.js +6 -0
  3. package/dist/_virtual/__vite-browser-external.js +4 -0
  4. package/dist/_virtual/_commonjs-dynamic-modules.js +6 -0
  5. package/dist/_virtual/_commonjsHelpers.js +28 -0
  6. package/dist/_virtual/index.js +4 -0
  7. package/dist/_virtual/lodash.js +4 -0
  8. package/dist/_virtual/pdf.js +4 -0
  9. package/dist/_virtual/react.production.js +4 -0
  10. package/dist/assets/generated/locales/de.js +73 -0
  11. package/dist/assets/generated/locales/en.js +73 -0
  12. package/dist/assets/generated/locales/fr.js +73 -0
  13. package/dist/assets/generated/locales/hr.js +73 -0
  14. package/dist/assets/generated/locales/it.js +73 -0
  15. package/dist/assets/generated/locales/pl.js +73 -0
  16. package/dist/assets/generated/locales/ro.js +73 -0
  17. package/dist/assets/generated/locales/sk.js +73 -0
  18. package/dist/assets/generated/locales/sr.js +73 -0
  19. package/dist/components/lit-attachments-tab.js +519 -0
  20. package/dist/components/lit-badge.js +100 -0
  21. package/dist/components/lit-case-variables-tab.js +727 -0
  22. package/dist/components/lit-chart.js +395 -0
  23. package/dist/components/lit-data-grid-tanstack.js +1733 -0
  24. package/dist/components/lit-filter-modal.js +312 -0
  25. package/dist/components/lit-multiselect-item.js +530 -0
  26. package/dist/components/lit-section-tab.js +133 -0
  27. package/dist/components/lit-tabs-overview.js +304 -0
  28. package/dist/components/react-wrappers/attachments-tab.js +14 -0
  29. package/dist/components/react-wrappers/badge.js +14 -0
  30. package/dist/components/react-wrappers/button.js +14 -0
  31. package/dist/components/react-wrappers/case-variables-tab.js +14 -0
  32. package/dist/components/react-wrappers/chart.js +14 -0
  33. package/dist/components/react-wrappers/data-grid-tanstack.js +14 -0
  34. package/dist/components/react-wrappers/filter-modal.js +14 -0
  35. package/dist/components/react-wrappers/progress-bar.js +14 -0
  36. package/dist/components/react-wrappers/section-tab.js +14 -0
  37. package/dist/components/react-wrappers/tabs-overview.js +14 -0
  38. package/dist/index.js +42 -0
  39. package/dist/libs/xlsx.mini.min.js +10 -0
  40. package/dist/node_modules/@floating-ui/core/dist/floating-ui.core.js +432 -0
  41. package/dist/node_modules/@floating-ui/dom/dist/floating-ui.dom.js +306 -0
  42. package/dist/node_modules/@floating-ui/utils/dist/floating-ui.utils.dom.js +127 -0
  43. package/dist/node_modules/@floating-ui/utils/dist/floating-ui.utils.js +127 -0
  44. package/dist/node_modules/@kurkle/color/dist/color.esm.js +448 -0
  45. package/dist/node_modules/@lit/localize/init/install.js +11 -0
  46. package/dist/node_modules/@lit/localize/init/runtime.js +42 -0
  47. package/dist/node_modules/@lit/localize/internal/default-msg.js +10 -0
  48. package/dist/node_modules/@lit/localize/internal/deferred.js +21 -0
  49. package/dist/node_modules/@lit/localize/internal/fnv1a64.js +17 -0
  50. package/dist/node_modules/@lit/localize/internal/id-generation.js +14 -0
  51. package/dist/node_modules/@lit/localize/internal/locale-status-event.js +9 -0
  52. package/dist/node_modules/@lit/localize/internal/runtime-msg.js +42 -0
  53. package/dist/node_modules/@lit/localize/internal/str-tag.js +15 -0
  54. package/dist/node_modules/@lit/react/create-component.js +35 -0
  55. package/dist/node_modules/@lit/reactive-element/css-tag.js +50 -0
  56. package/dist/node_modules/@lit/reactive-element/decorators/base.js +9 -0
  57. package/dist/node_modules/@lit/reactive-element/decorators/custom-element.js +13 -0
  58. package/dist/node_modules/@lit/reactive-element/decorators/property.js +37 -0
  59. package/dist/node_modules/@lit/reactive-element/decorators/query.js +20 -0
  60. package/dist/node_modules/@lit/reactive-element/decorators/state.js +12 -0
  61. package/dist/node_modules/@lit/reactive-element/reactive-element.js +250 -0
  62. package/dist/node_modules/@tanstack/lit-table/build/lib/index.js +104 -0
  63. package/dist/node_modules/@tanstack/lit-virtual/dist/esm/index.js +40 -0
  64. package/dist/node_modules/@tanstack/table-core/build/lib/index.js +1956 -0
  65. package/dist/node_modules/@tanstack/virtual-core/dist/esm/index.js +490 -0
  66. package/dist/node_modules/@tanstack/virtual-core/dist/esm/utils.js +52 -0
  67. package/dist/node_modules/chart.js/dist/chart.js +7122 -0
  68. package/dist/node_modules/chart.js/dist/chunks/helpers.segment.js +1691 -0
  69. package/dist/node_modules/file-saver/dist/FileSaver.min.js +74 -0
  70. package/dist/node_modules/lit-element/lit-element.js +51 -0
  71. package/dist/node_modules/lit-html/async-directive.js +69 -0
  72. package/dist/node_modules/lit-html/directive-helpers.js +45 -0
  73. package/dist/node_modules/lit-html/directive.js +27 -0
  74. package/dist/node_modules/lit-html/directives/ref.js +42 -0
  75. package/dist/node_modules/lit-html/directives/repeat.js +61 -0
  76. package/dist/node_modules/lit-html/directives/style-map.js +36 -0
  77. package/dist/node_modules/lit-html/directives/unsafe-html.js +27 -0
  78. package/dist/node_modules/lit-html/lit-html.js +243 -0
  79. package/dist/node_modules/lodash/lodash.js +3678 -0
  80. package/dist/node_modules/luxon/src/datetime.js +1793 -0
  81. package/dist/node_modules/luxon/src/duration.js +723 -0
  82. package/dist/node_modules/luxon/src/errors.js +40 -0
  83. package/dist/node_modules/luxon/src/impl/conversions.js +92 -0
  84. package/dist/node_modules/luxon/src/impl/diff.js +36 -0
  85. package/dist/node_modules/luxon/src/impl/digits.js +74 -0
  86. package/dist/node_modules/luxon/src/impl/english.js +138 -0
  87. package/dist/node_modules/luxon/src/impl/formats.js +150 -0
  88. package/dist/node_modules/luxon/src/impl/formatter.js +245 -0
  89. package/dist/node_modules/luxon/src/impl/invalid.js +11 -0
  90. package/dist/node_modules/luxon/src/impl/locale.js +282 -0
  91. package/dist/node_modules/luxon/src/impl/regexParser.js +202 -0
  92. package/dist/node_modules/luxon/src/impl/tokenParser.js +329 -0
  93. package/dist/node_modules/luxon/src/impl/util.js +206 -0
  94. package/dist/node_modules/luxon/src/impl/zoneUtil.js +19 -0
  95. package/dist/node_modules/luxon/src/info.js +180 -0
  96. package/dist/node_modules/luxon/src/interval.js +466 -0
  97. package/dist/node_modules/luxon/src/settings.js +150 -0
  98. package/dist/node_modules/luxon/src/zone.js +88 -0
  99. package/dist/node_modules/luxon/src/zones/IANAZone.js +178 -0
  100. package/dist/node_modules/luxon/src/zones/fixedOffsetZone.js +125 -0
  101. package/dist/node_modules/luxon/src/zones/invalidZone.js +41 -0
  102. package/dist/node_modules/luxon/src/zones/systemZone.js +47 -0
  103. package/dist/node_modules/pdfjs-dist/build/pdf.js +10310 -0
  104. package/dist/node_modules/react/cjs/react.production.js +417 -0
  105. package/dist/node_modules/react/index.js +10 -0
  106. package/dist/node_modules/sortablejs/modular/sortable.esm.js +1261 -0
  107. package/dist/shared/lit-button.js +142 -0
  108. package/dist/shared/lit-progress-bar.js +83 -0
  109. package/dist/shared/simple-tooltip.js +174 -0
  110. package/dist/shared/styles/button-shared-styles.js +205 -0
  111. package/dist/utils/currency.js +13 -0
  112. package/dist/utils/custom-filters.js +50 -0
  113. package/dist/utils/date.js +15 -0
  114. package/dist/utils/getOperatorByType.js +52 -0
  115. package/dist/utils/localization.js +30 -0
  116. package/dist/vite.svg +1 -0
  117. package/package.json +76 -74
@@ -0,0 +1,395 @@
1
+ import { customElement as w } from "../node_modules/@lit/reactive-element/decorators/custom-element.js";
2
+ import { property as b } from "../node_modules/@lit/reactive-element/decorators/property.js";
3
+ import "../node_modules/@lit/reactive-element/reactive-element.js";
4
+ import { html as y } from "../node_modules/lit-html/lit-html.js";
5
+ import { LitElement as v } from "../node_modules/lit-element/lit-element.js";
6
+ import { Chart as p, registerables as x } from "../node_modules/chart.js/dist/chart.js";
7
+ import { css as D } from "../node_modules/@lit/reactive-element/css-tag.js";
8
+ var k = Object.defineProperty, S = Object.getOwnPropertyDescriptor, u = (a, r, n, e) => {
9
+ for (var t = e > 1 ? void 0 : e ? S(r, n) : r, o = a.length - 1, s; o >= 0; o--)
10
+ (s = a[o]) && (t = (e ? s(r, n, t) : s(t)) || t);
11
+ return e && t && k(r, n, t), t;
12
+ };
13
+ p.register(...x);
14
+ let c = class extends v {
15
+ constructor() {
16
+ super(...arguments), this.type = "bar", this.data = { labels: [], datasets: [], title: "" }, this.isLoading = !1, this.chart = null;
17
+ }
18
+ updated(a) {
19
+ (a.has("type") || a.has("data")) && this.renderChart();
20
+ }
21
+ generateColors(a) {
22
+ return Array.from(
23
+ { length: a },
24
+ () => `rgba(${Math.floor(Math.random() * 255)}, ${Math.floor(Math.random() * 255)}, ${Math.floor(Math.random() * 255)}, 0.6)`
25
+ );
26
+ }
27
+ renderChart() {
28
+ var r;
29
+ const a = (r = this.shadowRoot) == null ? void 0 : r.querySelector("canvas");
30
+ a && (this.type === "bar" || this.type === "line" ? this.renderBarAndLineChart(a) : this.type === "bubble" ? this.renderBubbleChart(a) : this.type === "pie" || this.type === "doughnut" ? this.renderPieAndDoughnutChart(a) : this.type === "gantt" && this.renderGanttChart(a));
31
+ }
32
+ renderGanttChart(a) {
33
+ var m;
34
+ this.chart && this.chart.destroy();
35
+ const r = this.generateColors(((m = this.data.datasets[0]) == null ? void 0 : m.data.length) || 0), n = this.data.datasets.map((l, i) => ({
36
+ label: l.label || `Dataset ${i + 1}`,
37
+ data: l.data.map((d) => {
38
+ const h = new Date(d.x[0]), f = new Date(d.x[1]);
39
+ return {
40
+ x: [
41
+ isNaN(h.getTime()) ? Date.now() : h.getTime(),
42
+ isNaN(f.getTime()) ? Date.now() : f.getTime()
43
+ ],
44
+ y: d.y
45
+ };
46
+ }),
47
+ backgroundColor: r,
48
+ borderColor: r,
49
+ borderWidth: 1,
50
+ barThickness: 16,
51
+ borderRadius: 4,
52
+ borderSkipped: !1
53
+ })), e = this.data.datasets.flatMap(
54
+ (l) => l.data.flatMap((i) => {
55
+ var d, h;
56
+ return [
57
+ new Date((d = i == null ? void 0 : i.x) == null ? void 0 : d[0]).getTime(),
58
+ new Date((h = i == null ? void 0 : i.x) == null ? void 0 : h[1]).getTime()
59
+ ];
60
+ })
61
+ ), t = Math.min(...e), o = Math.max(...e), C = (o - t) / 20;
62
+ this.chart = new p(a, {
63
+ type: "bar",
64
+ data: {
65
+ datasets: n
66
+ },
67
+ options: {
68
+ indexAxis: "y",
69
+ responsive: !0,
70
+ maintainAspectRatio: !1,
71
+ scales: {
72
+ x: {
73
+ type: "linear",
74
+ ticks: {
75
+ stepSize: C,
76
+ // 30 dní v milisekundách
77
+ autoSkip: !1,
78
+ callback: (l) => new Date(l).toLocaleDateString("sk-SK", {
79
+ day: "2-digit",
80
+ month: "2-digit",
81
+ year: "numeric"
82
+ })
83
+ },
84
+ min: t,
85
+ max: o
86
+ },
87
+ y: {
88
+ type: "category"
89
+ }
90
+ },
91
+ plugins: {
92
+ tooltip: {
93
+ callbacks: {
94
+ label: function(l) {
95
+ const i = new Date(l.raw.x[0]).toLocaleDateString(
96
+ "sk-SK",
97
+ {
98
+ day: "2-digit",
99
+ month: "2-digit",
100
+ year: "numeric"
101
+ }
102
+ ), d = new Date(l.raw.x[1]).toLocaleDateString("sk-SK", {
103
+ day: "2-digit",
104
+ month: "2-digit",
105
+ year: "numeric"
106
+ });
107
+ return `  Začiatok: ${i}, Koniec: ${d}`;
108
+ }
109
+ },
110
+ bodyFont: {
111
+ size: 13,
112
+ weight: 400
113
+ },
114
+ displayColors: !0,
115
+ usePointStyle: !0,
116
+ backgroundColor: "black",
117
+ cornerRadius: 8
118
+ },
119
+ legend: {
120
+ display: !1
121
+ },
122
+ title: {
123
+ display: !0,
124
+ text: this.data.title,
125
+ // Text, ktorý sa zobrazí nad grafom
126
+ font: {
127
+ size: 17,
128
+ weight: 500
129
+ },
130
+ color: "var(--text-primary, #111827)",
131
+ padding: {
132
+ top: 10,
133
+ bottom: 20
134
+ }
135
+ }
136
+ },
137
+ onHover: (l, i) => {
138
+ var h;
139
+ const d = (h = l.native) == null ? void 0 : h.target;
140
+ d.style.cursor = i.length ? "pointer" : "default";
141
+ }
142
+ }
143
+ });
144
+ }
145
+ renderPieAndDoughnutChart(a) {
146
+ var e;
147
+ this.chart && this.chart.destroy();
148
+ const r = this.generateColors(((e = this.data.datasets[0]) == null ? void 0 : e.data.length) || 0), n = this.data.datasets.map((t) => ({
149
+ ...t,
150
+ backgroundColor: r,
151
+ borderColor: r,
152
+ borderWidth: 2,
153
+ pointBorderWidth: 2
154
+ }));
155
+ this.chart = new p(a, {
156
+ type: this.type,
157
+ data: {
158
+ labels: this.data.labels,
159
+ datasets: n
160
+ },
161
+ options: {
162
+ responsive: !0,
163
+ maintainAspectRatio: !1,
164
+ plugins: {
165
+ legend: {
166
+ position: "top",
167
+ labels: {
168
+ usePointStyle: !0,
169
+ pointStyle: "circle",
170
+ font: {
171
+ size: 13,
172
+ weight: 500
173
+ }
174
+ }
175
+ },
176
+ tooltip: {
177
+ callbacks: {
178
+ title: () => "",
179
+ label: (t) => (t.raw, `  ${t.label}: ${t.raw}`)
180
+ },
181
+ bodyFont: {
182
+ size: 13,
183
+ weight: 400
184
+ },
185
+ displayColors: !0,
186
+ usePointStyle: !0,
187
+ // Použitie kruhového symbolu
188
+ xAlign: "center",
189
+ yAlign: "bottom",
190
+ padding: 16,
191
+ backgroundColor: "black",
192
+ cornerRadius: 8
193
+ },
194
+ title: {
195
+ display: !0,
196
+ text: this.data.title,
197
+ // Text, ktorý sa zobrazí nad grafom
198
+ font: {
199
+ size: 17,
200
+ weight: 500
201
+ },
202
+ color: "var(--text-primary, #111827)",
203
+ padding: {
204
+ top: 10,
205
+ bottom: 20
206
+ }
207
+ }
208
+ },
209
+ ...this.type === "doughnut" && {
210
+ cutout: "70%"
211
+ },
212
+ onHover: (t, o) => {
213
+ var g;
214
+ const s = (g = t.native) == null ? void 0 : g.target;
215
+ o.length ? s.style.cursor = "pointer" : s.style.cursor = "default";
216
+ }
217
+ }
218
+ });
219
+ }
220
+ renderBubbleChart(a) {
221
+ this.chart && this.chart.destroy();
222
+ const r = this.generateColors(this.data.datasets.length), n = this.data.datasets.map((e, t) => ({
223
+ ...e,
224
+ backgroundColor: r[t],
225
+ borderColor: r[t],
226
+ borderWidth: 1,
227
+ hoverRadius: 10,
228
+ pointBorderWidth: 2
229
+ }));
230
+ this.chart = new p(a, {
231
+ type: "bubble",
232
+ data: { datasets: n },
233
+ options: {
234
+ responsive: !0,
235
+ scales: {
236
+ x: { beginAtZero: !0 },
237
+ y: { beginAtZero: !0 }
238
+ },
239
+ plugins: {
240
+ legend: {
241
+ position: "top",
242
+ labels: {
243
+ usePointStyle: !0,
244
+ // Použitie kruhového symbolu
245
+ pointStyle: "circle"
246
+ // Špecifický tvar pre symbol v legende
247
+ }
248
+ },
249
+ tooltip: {
250
+ callbacks: {
251
+ label: (e) => {
252
+ const t = e.raw;
253
+ return `  x: ${t.x}, y: ${t.y}, r: ${t.r}`;
254
+ }
255
+ },
256
+ bodyFont: {
257
+ size: 13,
258
+ weight: 400
259
+ },
260
+ displayColors: !0,
261
+ usePointStyle: !0,
262
+ // Použitie kruhového symbolu
263
+ xAlign: "center",
264
+ yAlign: "bottom",
265
+ padding: 16,
266
+ backgroundColor: "black",
267
+ cornerRadius: 8
268
+ },
269
+ title: {
270
+ display: !0,
271
+ text: this.data.title,
272
+ // Text, ktorý sa zobrazí nad grafom
273
+ font: {
274
+ size: 17,
275
+ weight: 500
276
+ },
277
+ color: "var(--text-primary, #111827)",
278
+ padding: {
279
+ top: 10,
280
+ bottom: 20
281
+ }
282
+ }
283
+ },
284
+ onHover: (e, t) => {
285
+ var s;
286
+ const o = (s = e.native) == null ? void 0 : s.target;
287
+ t.length ? o.style.cursor = "pointer" : o.style.cursor = "default";
288
+ }
289
+ }
290
+ });
291
+ }
292
+ renderBarAndLineChart(a) {
293
+ this.chart && this.chart.destroy();
294
+ const r = this.generateColors(this.data.datasets.length), n = this.data.datasets.map((e, t) => ({
295
+ ...e,
296
+ backgroundColor: r[t],
297
+ borderColor: r[t],
298
+ borderWidth: 2,
299
+ ...this.type === "bar" ? { borderRadius: 4 } : {},
300
+ ...this.type === "line" ? {
301
+ pointStyle: "circle",
302
+ pointRadius: 3,
303
+ pointBorderWidth: 2,
304
+ pointBorderColor: r[t]
305
+ } : {}
306
+ }));
307
+ this.chart = new p(a, {
308
+ type: this.type,
309
+ data: {
310
+ labels: this.data.labels,
311
+ datasets: n
312
+ },
313
+ options: {
314
+ responsive: !0,
315
+ maintainAspectRatio: !1,
316
+ plugins: {
317
+ legend: {
318
+ position: "top",
319
+ labels: {
320
+ usePointStyle: !0,
321
+ // Použitie kruhového symbolu
322
+ pointStyle: "circle"
323
+ // Špecifický tvar pre symbol v legende
324
+ }
325
+ },
326
+ tooltip: {
327
+ callbacks: {
328
+ title: () => "",
329
+ label: (e) => (e.raw, `  ${e.label}: ${e.raw}`)
330
+ },
331
+ bodyFont: {
332
+ size: 13,
333
+ weight: 400
334
+ },
335
+ displayColors: !0,
336
+ usePointStyle: !0,
337
+ // Použitie kruhového symbolu
338
+ xAlign: "center",
339
+ yAlign: "bottom",
340
+ padding: 16,
341
+ backgroundColor: "black",
342
+ cornerRadius: 8
343
+ },
344
+ title: {
345
+ display: !0,
346
+ text: this.data.title,
347
+ // Text, ktorý sa zobrazí nad grafom
348
+ font: {
349
+ size: 17,
350
+ weight: 500
351
+ },
352
+ color: "var(--text-primary, #111827)",
353
+ padding: {
354
+ top: 10,
355
+ bottom: 20
356
+ }
357
+ }
358
+ },
359
+ onHover: (e, t) => {
360
+ var s;
361
+ const o = (s = e.native) == null ? void 0 : s.target;
362
+ t.length ? o.style.cursor = "pointer" : o.style.cursor = "default";
363
+ }
364
+ }
365
+ });
366
+ }
367
+ render() {
368
+ return y`${this.isLoading ? y`<lit-loader></lit-loader>` : y`<canvas></canvas>`}`;
369
+ }
370
+ };
371
+ c.styles = [
372
+ D`
373
+ canvas {
374
+ width: 100%;
375
+ height: 100%;
376
+ font-family: 'Inter', sans-serif;
377
+ margin: 0 auto;
378
+ }
379
+ `
380
+ ];
381
+ u([
382
+ b({ type: String })
383
+ ], c.prototype, "type", 2);
384
+ u([
385
+ b({ type: Array })
386
+ ], c.prototype, "data", 2);
387
+ u([
388
+ b({ type: Boolean })
389
+ ], c.prototype, "isLoading", 2);
390
+ c = u([
391
+ w("lit-chart")
392
+ ], c);
393
+ export {
394
+ c as LitChart
395
+ };