@ironsource/shared-ui 2.1.12-test.77 → 2.1.12-test.79
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/ChartPlane.vue_vue_type_style_index_0_scoped_c6aaec38_lang.css +1 -0
- package/DropdownV4.vue_vue_type_style_index_0_scoped_1f7f7f9c_lang.css +1 -0
- package/components/chart/ChartPlane.vue.js +5 -5
- package/components/chart/ChartPlane.vue2.js +95 -90
- package/components/chart/utils/utils.d.ts +1 -1
- package/components/chart/utils/utils.js +10 -10
- package/components/dropdown/v4/DropdownV4.vue.d.ts +5 -0
- package/components/dropdown/v4/DropdownV4.vue.js +3 -3
- package/components/dropdown/v4/DropdownV4.vue2.js +41 -39
- package/components/dropdown/v4/dropdownStoryArgs.d.ts +8 -0
- package/components/dropdown/v4/index.d.ts +20 -1
- package/components/includeExclude/IncludeExclude.vue.d.ts +1 -1
- package/components/includeExclude/IncludeExcludeDragDrop.vue.d.ts +1 -1
- package/components/includeExclude/index.d.ts +40 -40
- package/index.d.ts +40 -2
- package/index.js +1 -1
- package/package.json +1 -1
- package/ChartPlane.vue_vue_type_style_index_0_scoped_a4130027_lang.css +0 -1
- package/DropdownV4.vue_vue_type_style_index_0_scoped_92ead583_lang.css +0 -1
|
@@ -0,0 +1 @@
|
|
|
1
|
+
.chart-plane-container[data-v-c6aaec38]{--headerHeight: var(--1b72bc70);width:100%;height:var(--e61db09a);position:relative}.header-wrapper[data-v-c6aaec38]{position:absolute;width:100%;height:var(--headerHeight);top:0;z-index:1}.chart-plane[data-v-c6aaec38]{padding-top:var(--headerHeight);height:100%}.chart[data-v-c6aaec38]{width:100%;height:100%;position:relative}.chart__canvas[data-v-c6aaec38]{width:100%;height:100%}.chart__tooltip[data-v-c6aaec38]{position:absolute;pointer-events:none;transition:all .1s ease;min-width:214px;max-width:270px;z-index:1}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
.v-enter-active[data-v-1f7f7f9c],.v-leave-active[data-v-1f7f7f9c]{transition:opacity .25s ease}ol[data-v-1f7f7f9c],ul[data-v-1f7f7f9c],menu[data-v-1f7f7f9c]{list-style:none;margin:0;padding:0}.dropdown.full-width[data-v-1f7f7f9c],.dropdown.full-width .button__container[data-v-1f7f7f9c]{width:100%}.dropdown-list-wrapper[data-v-1f7f7f9c]{display:flex;flex-direction:column;padding:.5rem .5rem .25rem}.dropdown-list-wrapper--multi[data-v-1f7f7f9c]{padding:.5rem}.list-container--multi[data-v-1f7f7f9c]{margin-bottom:0}.inline-search .inline-search-wrapper[data-v-1f7f7f9c]{display:flex;gap:4px;padding-bottom:.25rem}.inline-search .inline-search-wrapper .search-container[data-v-1f7f7f9c]{width:100%}.inline-search .list-container[data-v-1f7f7f9c]{padding-top:0}.no-result-container[data-v-1f7f7f9c]{height:100%;display:flex;align-items:center;padding:.375rem .5rem;color:var(--text-disabled)}.no-result[data-v-1f7f7f9c]{color:var(--text-disabled);padding-left:.5rem}.list[data-v-1f7f7f9c]{outline:none;display:flex;flex-direction:column;width:100%;min-height:2rem}.list--multi[data-v-1f7f7f9c]{margin-bottom:.5rem;border-bottom-left-radius:0;border-bottom-right-radius:0}.list--with-conditions[data-v-1f7f7f9c]{min-height:0;margin-bottom:0}.image-slot[data-v-1f7f7f9c]{margin-right:.5rem}.actions-wrapper[data-v-1f7f7f9c]{display:flex;width:100%;padding:.5rem .5rem .5rem .125rem;padding-bottom:0;border-top:1px solid var(--common-divider);justify-content:space-between;margin-top:.25rem}.apply-button[data-v-1f7f7f9c]{margin-left:.5rem}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import
|
|
2
|
-
/* empty css */import
|
|
3
|
-
// import "../../ChartPlane.
|
|
4
|
-
const
|
|
1
|
+
import e from "./ChartPlane.vue2.js";
|
|
2
|
+
/* empty css */import o from "../../_virtual/_plugin-vue_export-helper.js";
|
|
3
|
+
// import "../../ChartPlane.vue_vue_type_style_index_0_scoped_c6aaec38_lang.css"; //*');
|
|
4
|
+
const c = /* @__PURE__ */ o(e, [["__scopeId", "data-v-c6aaec38"]]);
|
|
5
5
|
export {
|
|
6
|
-
|
|
6
|
+
c as default
|
|
7
7
|
};
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import "../../ChartPlane.
|
|
2
|
-
import { Chart as
|
|
1
|
+
import "../../ChartPlane.vue_vue_type_style_index_0_scoped_c6aaec38_lang.css"; import { defineComponent as re, useCssVars as ie, unref as s, computed as l, ref as A, onMounted as ne, watch as C, nextTick as se, openBlock as f, createElementBlock as L, createVNode as ue, isRef as ce, createSlots as de, withCtx as pe, renderSlot as fe, createCommentVNode as E, createElementVNode as R, normalizeStyle as he, createBlock as B } from "vue";
|
|
2
|
+
import { Chart as F, ArcElement as ve, LineElement as me, BarElement as ye, PointElement as Te, LineController as Ce, BarController as be, PieController as ge, ScatterController as xe, CategoryScale as ke, LinearScale as Se, Filler as Ae, Tooltip as Le } from "chart.js";
|
|
3
3
|
import { HoverVerticalLine as Ee } from "./plugins/HoverVerticalLine.js";
|
|
4
4
|
import { prepareTickLabel as Re, formatValue as Be, calcStepSize as De } from "./utils/utils.js";
|
|
5
|
-
import { DEFAULT_TICK_COUNT as Oe, TOTALS_HELPER_KEY as
|
|
6
|
-
import { ChartType as u, DateInterval as Fe, TooltipOrder as
|
|
5
|
+
import { DEFAULT_TICK_COUNT as Oe, TOTALS_HELPER_KEY as K, BASE_COLOR_KEY as M, CHART_PADDING as Ie, POINT_BORDER_COLOR as He, TICK_LABEL_COLOR as U, TICK_LABEL_FONT as z, TICKS_EXTRA_PADDING as Pe, GRID_LINE_COLOR as Y, HEADER_HEIGHT as Ve, COMPACT_HEADER_HEIGHT as Ne, HOVER_AREA_TRANSPARENCY as we, HOVER_TRANSPARENCY as b } from "./consts.js";
|
|
6
|
+
import { ChartType as u, DateInterval as Fe, TooltipOrder as _, TrendDirection as Ke } from "./types.js";
|
|
7
7
|
import { useTooltipPosition as Me } from "./composables/useTooltipPosition.js";
|
|
8
8
|
import Ue from "./ChartTooltip.vue.js";
|
|
9
9
|
import { hexColorToRgba as h } from "../../utils/color.js";
|
|
@@ -13,7 +13,7 @@ import { useMemoize as _e, useVModel as Ge } from "@vueuse/core";
|
|
|
13
13
|
import $e from "../emptyState/v4/EmptyStateV4.vue.js";
|
|
14
14
|
import We from "./ChartLoader.vue.js";
|
|
15
15
|
import { DEFAULT_CHART_COLOR as Ze } from "./colorPalette.js";
|
|
16
|
-
import { TotalType as
|
|
16
|
+
import { TotalType as G, calculateTotal as Xe } from "../../utils/totals.js";
|
|
17
17
|
import { isNullOrUndefined as je } from "../../utils/utils.js";
|
|
18
18
|
import { storeOriginalDatasetColors as qe, restoreOriginalDatasetColors as Je } from "./utils/highlightUtils.js";
|
|
19
19
|
const Qe = { class: "chart-plane-container" }, et = {
|
|
@@ -49,9 +49,9 @@ const Qe = { class: "chart-plane-container" }, et = {
|
|
|
49
49
|
height: { default: "100%" },
|
|
50
50
|
compactHeader: { type: Boolean, default: !1 },
|
|
51
51
|
tooltipRespectsTopEdge: { type: Boolean, default: !0 },
|
|
52
|
-
tooltipTotalType: { default:
|
|
52
|
+
tooltipTotalType: { default: G.Total },
|
|
53
53
|
tooltipTotalCalcFn: { type: Function, default: Xe },
|
|
54
|
-
tooltipOrder: { default:
|
|
54
|
+
tooltipOrder: { default: _.Legend },
|
|
55
55
|
trendValue: { default: null },
|
|
56
56
|
trendDirection: { default: Ke.UP },
|
|
57
57
|
trendTooltip: { default: null },
|
|
@@ -61,16 +61,16 @@ const Qe = { class: "chart-plane-container" }, et = {
|
|
|
61
61
|
valuePrefix: { default: "" }
|
|
62
62
|
},
|
|
63
63
|
emits: ["update:chartType"],
|
|
64
|
-
setup(o, { emit:
|
|
64
|
+
setup(o, { emit: $ }) {
|
|
65
65
|
const e = o;
|
|
66
66
|
ie((t) => ({
|
|
67
|
-
"
|
|
68
|
-
|
|
67
|
+
"1b72bc70": s(ee),
|
|
68
|
+
e61db09a: o.height
|
|
69
69
|
}));
|
|
70
|
-
const
|
|
71
|
-
|
|
72
|
-
me,
|
|
70
|
+
const W = _e(Re);
|
|
71
|
+
F.register(
|
|
73
72
|
ve,
|
|
73
|
+
me,
|
|
74
74
|
ye,
|
|
75
75
|
Te,
|
|
76
76
|
Ce,
|
|
@@ -83,44 +83,45 @@ const Qe = { class: "chart-plane-container" }, et = {
|
|
|
83
83
|
Le,
|
|
84
84
|
Ee
|
|
85
85
|
);
|
|
86
|
-
const
|
|
86
|
+
const g = Ge(e, "chartType", $), Z = l(
|
|
87
87
|
() => e.withAnimation ? "" : "none"
|
|
88
|
-
),
|
|
88
|
+
), v = A(null);
|
|
89
89
|
let n = null;
|
|
90
|
-
const
|
|
91
|
-
|
|
92
|
-
},
|
|
93
|
-
n && (n.data.datasets =
|
|
90
|
+
const D = l(() => e.empty || e.dataSets.length === 0), d = l(() => !e.loading && !D.value), x = () => {
|
|
91
|
+
v.value && (n && n.destroy(), n = new F(v.value, P.value));
|
|
92
|
+
}, X = () => {
|
|
93
|
+
n && (n.data.datasets = H.value, n.options = P.value.options, n.update(Z.value));
|
|
94
94
|
};
|
|
95
|
-
ne(
|
|
96
|
-
t && (await se(),
|
|
97
|
-
}),
|
|
95
|
+
ne(x), C(() => e.chartType, x), C(d, async (t) => {
|
|
96
|
+
t && (await se(), x());
|
|
97
|
+
}), C(
|
|
98
98
|
[
|
|
99
99
|
() => e.visibleIds,
|
|
100
100
|
() => e.dataSets,
|
|
101
101
|
() => e.valuePrefix,
|
|
102
|
-
() => e.valueSuffix
|
|
102
|
+
() => e.valueSuffix,
|
|
103
|
+
() => T.value
|
|
103
104
|
],
|
|
104
|
-
|
|
105
|
+
X
|
|
105
106
|
);
|
|
106
|
-
const p = l(() => e.totalsChart),
|
|
107
|
+
const p = l(() => e.totalsChart), m = l(
|
|
107
108
|
() => e.chartType === u.StackedLine || e.chartType === u.StackedBar || p.value
|
|
108
|
-
),
|
|
109
|
+
), k = l(
|
|
109
110
|
() => e.chartType === u.Line || e.chartType === u.StackedLine
|
|
110
|
-
),
|
|
111
|
+
), O = l(() => p.value && !e.parsing.xAxisKey ? { ...e.parsing, xAxisKey: K } : e.parsing), j = l(() => p.value ? e.dataSets.map((t) => ({
|
|
111
112
|
...t,
|
|
112
113
|
data: t.data.map((i) => ({
|
|
113
114
|
...i,
|
|
114
|
-
[
|
|
115
|
+
[K]: t.label
|
|
115
116
|
}))
|
|
116
117
|
})) : e.dataSets), y = l(
|
|
117
|
-
() =>
|
|
118
|
-
),
|
|
118
|
+
() => j.value.filter((t) => e.visibleIds.includes(t.id))
|
|
119
|
+
), q = (t) => e.colorsMap[t] || Ze, I = l(
|
|
119
120
|
() => y.value.length && y.value.every(
|
|
120
121
|
(t) => t.data.length === 1
|
|
121
122
|
)
|
|
122
|
-
),
|
|
123
|
-
const a =
|
|
123
|
+
), H = l(() => y.value.map((t, i) => {
|
|
124
|
+
const a = q(t.id), r = m.value ? i !== 0 ? "-1" : "start" : void 0;
|
|
124
125
|
return {
|
|
125
126
|
...t,
|
|
126
127
|
fill: r,
|
|
@@ -136,20 +137,20 @@ const Qe = { class: "chart-plane-container" }, et = {
|
|
|
136
137
|
// draw a bit outside the chart area
|
|
137
138
|
icon: t.icon || null,
|
|
138
139
|
iconType: t.iconType || "branded",
|
|
139
|
-
[
|
|
140
|
+
[M]: a
|
|
140
141
|
// store base color for later use
|
|
141
142
|
};
|
|
142
|
-
})),
|
|
143
|
-
() => e.tooltipTotalType ===
|
|
144
|
-
),
|
|
143
|
+
})), J = l(
|
|
144
|
+
() => e.tooltipTotalType === G.Total ? "Total" : "Mean"
|
|
145
|
+
), P = l(() => ({
|
|
145
146
|
type: e.chartType == u.Bar || e.chartType === u.StackedBar ? "bar" : "line",
|
|
146
147
|
// Chart Data
|
|
147
148
|
data: {
|
|
148
|
-
datasets:
|
|
149
|
+
datasets: H.value
|
|
149
150
|
},
|
|
150
151
|
// Chart Options
|
|
151
152
|
options: {
|
|
152
|
-
parsing:
|
|
153
|
+
parsing: O.value,
|
|
153
154
|
interaction: {
|
|
154
155
|
intersect: !1,
|
|
155
156
|
mode: p.value ? "point" : "index",
|
|
@@ -159,7 +160,7 @@ const Qe = { class: "chart-plane-container" }, et = {
|
|
|
159
160
|
plugins: {
|
|
160
161
|
legend: { display: !1 },
|
|
161
162
|
title: { display: !1 },
|
|
162
|
-
hoverVerticalLine:
|
|
163
|
+
hoverVerticalLine: k.value,
|
|
163
164
|
// tooltip
|
|
164
165
|
tooltip: {
|
|
165
166
|
enabled: !1,
|
|
@@ -173,11 +174,11 @@ const Qe = { class: "chart-plane-container" }, et = {
|
|
|
173
174
|
i,
|
|
174
175
|
e.tooltipTotalType
|
|
175
176
|
);
|
|
176
|
-
return [
|
|
177
|
+
return [J.value, String(a)];
|
|
177
178
|
}
|
|
178
179
|
},
|
|
179
180
|
itemSort: (t, i) => {
|
|
180
|
-
if (e.tooltipOrder ===
|
|
181
|
+
if (e.tooltipOrder === _.YAxis) {
|
|
181
182
|
const a = t.parsed.y || 0, r = i.parsed.y || 0;
|
|
182
183
|
return a === r ? 0 : a > r ? -1 : 1;
|
|
183
184
|
}
|
|
@@ -198,7 +199,7 @@ const Qe = { class: "chart-plane-container" }, et = {
|
|
|
198
199
|
tension: 0.3
|
|
199
200
|
},
|
|
200
201
|
point: {
|
|
201
|
-
radius:
|
|
202
|
+
radius: I.value ? 3 : 1,
|
|
202
203
|
hitRadius: 8,
|
|
203
204
|
borderWidth: 0,
|
|
204
205
|
hoverRadius: 4,
|
|
@@ -213,21 +214,21 @@ const Qe = { class: "chart-plane-container" }, et = {
|
|
|
213
214
|
// Horizontal Axis (X)
|
|
214
215
|
x: {
|
|
215
216
|
beginAtZero: !0,
|
|
216
|
-
offset: !
|
|
217
|
+
offset: !k.value || I.value,
|
|
217
218
|
border: { display: !1 },
|
|
218
|
-
stacked:
|
|
219
|
+
stacked: m.value,
|
|
219
220
|
// stack on top of each other
|
|
220
221
|
// ticks
|
|
221
222
|
ticks: {
|
|
222
|
-
color:
|
|
223
|
-
font:
|
|
223
|
+
color: U,
|
|
224
|
+
font: z,
|
|
224
225
|
padding: 4,
|
|
225
226
|
maxRotation: 0,
|
|
226
227
|
autoSkip: !e.truncateTickLabels,
|
|
227
228
|
autoSkipPadding: 8,
|
|
228
229
|
callback: function(t, i, a) {
|
|
229
|
-
const r = this.getLabelForValue(t), oe =
|
|
230
|
-
return
|
|
230
|
+
const r = this.getLabelForValue(t), oe = k.value && !p.value ? a.length - 1 : a.length, le = this.chart.scales?.x?.width / oe - Pe;
|
|
231
|
+
return W({
|
|
231
232
|
label: r,
|
|
232
233
|
format: e.xAxisFormat,
|
|
233
234
|
availableSpace: le,
|
|
@@ -237,7 +238,7 @@ const Qe = { class: "chart-plane-container" }, et = {
|
|
|
237
238
|
},
|
|
238
239
|
// grid lines
|
|
239
240
|
grid: {
|
|
240
|
-
color:
|
|
241
|
+
color: Y,
|
|
241
242
|
drawOnChartArea: !1,
|
|
242
243
|
drawTicks: !0,
|
|
243
244
|
drawBorder: !1,
|
|
@@ -249,46 +250,50 @@ const Qe = { class: "chart-plane-container" }, et = {
|
|
|
249
250
|
beginAtZero: !0,
|
|
250
251
|
border: { display: !1 },
|
|
251
252
|
// hide left borderline
|
|
252
|
-
stacked:
|
|
253
|
+
stacked: m.value,
|
|
253
254
|
// stack on top of each other
|
|
254
255
|
// ticks
|
|
255
256
|
ticks: {
|
|
256
|
-
color:
|
|
257
|
-
font:
|
|
257
|
+
color: U,
|
|
258
|
+
font: z,
|
|
258
259
|
padding: 8,
|
|
259
|
-
stepSize:
|
|
260
|
-
min:
|
|
261
|
-
max:
|
|
262
|
-
callback: (t) => e.valuePrefix + Be(t, e.yAxisFormat) + e.valueSuffix
|
|
260
|
+
stepSize: T.value,
|
|
261
|
+
min: S.value,
|
|
262
|
+
max: T.value * e.tickCount,
|
|
263
|
+
callback: (t) => e.valuePrefix + Be(t, e.yAxisFormat, T.value < 1) + e.valueSuffix
|
|
263
264
|
},
|
|
264
265
|
// grid lines
|
|
265
266
|
grid: {
|
|
266
|
-
color:
|
|
267
|
+
color: Y,
|
|
267
268
|
drawOnChartArea: !0,
|
|
268
269
|
drawTicks: !1
|
|
269
270
|
}
|
|
270
271
|
}
|
|
271
272
|
}
|
|
272
273
|
}
|
|
273
|
-
})),
|
|
274
|
-
|
|
275
|
-
|
|
274
|
+
})), V = A(null), c = A(null), { position: N } = Me(
|
|
275
|
+
v,
|
|
276
|
+
V,
|
|
276
277
|
c,
|
|
277
278
|
e.tooltipRespectsTopEdge
|
|
278
|
-
),
|
|
279
|
-
left: `${
|
|
280
|
-
top: `${
|
|
279
|
+
), Q = l(() => ({
|
|
280
|
+
left: `${N.value.left}px`,
|
|
281
|
+
top: `${N.value.top}px`,
|
|
281
282
|
opacity: c.value?.opacity || 0
|
|
282
|
-
})), { minValue:
|
|
283
|
-
parsingConfig:
|
|
283
|
+
})), { minValue: S, maxValue: w } = ze({
|
|
284
|
+
parsingConfig: O.value,
|
|
284
285
|
dataSets: y,
|
|
285
|
-
isStacked:
|
|
286
|
-
}),
|
|
287
|
-
() => De(
|
|
286
|
+
isStacked: m
|
|
287
|
+
}), T = l(
|
|
288
|
+
() => De(
|
|
289
|
+
isNaN(S.value) ? 0 : S.value,
|
|
290
|
+
isNaN(w.value) ? 0 : w.value,
|
|
291
|
+
e.tickCount
|
|
292
|
+
)
|
|
288
293
|
), ee = l(
|
|
289
|
-
() => (e.compactHeader ?
|
|
294
|
+
() => (e.compactHeader ? Ne : Ve) + "px"
|
|
290
295
|
);
|
|
291
|
-
|
|
296
|
+
C(
|
|
292
297
|
() => e.highlightedId,
|
|
293
298
|
(t) => {
|
|
294
299
|
n && (je(t) ? ae() : te(t), n.update());
|
|
@@ -297,20 +302,20 @@ const Qe = { class: "chart-plane-container" }, et = {
|
|
|
297
302
|
const te = (t) => {
|
|
298
303
|
(n?.data.datasets || []).forEach((a) => {
|
|
299
304
|
qe(a);
|
|
300
|
-
const r = a[
|
|
305
|
+
const r = a[M];
|
|
301
306
|
a.id === t ? e.chartType === u.StackedLine && (a.backgroundColor = h(
|
|
302
307
|
r,
|
|
303
|
-
|
|
304
|
-
)) : (a.backgroundColor = h(r,
|
|
308
|
+
we
|
|
309
|
+
)) : (a.backgroundColor = h(r, b), a.borderColor = h(r, b), a.pointBackgroundColor = h(r, b), a.pointHoverBorderColor = h(r, b));
|
|
305
310
|
});
|
|
306
311
|
}, ae = () => {
|
|
307
312
|
(n?.data.datasets || []).forEach(Je);
|
|
308
313
|
};
|
|
309
|
-
return (t, i) => (f(),
|
|
310
|
-
s(d) || o.keepSubheaderVisible ? (f(),
|
|
314
|
+
return (t, i) => (f(), L("div", Qe, [
|
|
315
|
+
s(d) || o.keepSubheaderVisible ? (f(), L("div", et, [
|
|
311
316
|
ue(Ye, {
|
|
312
|
-
"chart-type": s(
|
|
313
|
-
"onUpdate:chart-type": i[0] || (i[0] = (a) => ce(
|
|
317
|
+
"chart-type": s(g),
|
|
318
|
+
"onUpdate:chart-type": i[0] || (i[0] = (a) => ce(g) ? g.value = a : null),
|
|
314
319
|
"type-switcher": s(d) ? o.typeSwitcher : !1,
|
|
315
320
|
header: s(d) ? o.header : null,
|
|
316
321
|
subheader: o.subheader,
|
|
@@ -328,21 +333,21 @@ const Qe = { class: "chart-plane-container" }, et = {
|
|
|
328
333
|
key: "0"
|
|
329
334
|
} : void 0
|
|
330
335
|
]), 1032, ["chart-type", "type-switcher", "header", "subheader", "subheader-tooltip", "trend-tooltip", "compact", "trend-value", "trend-direction"])
|
|
331
|
-
])) :
|
|
332
|
-
s(d) ? (f(),
|
|
333
|
-
|
|
334
|
-
|
|
336
|
+
])) : E("", !0),
|
|
337
|
+
s(d) ? (f(), L("section", tt, [
|
|
338
|
+
R("div", at, [
|
|
339
|
+
R("canvas", {
|
|
335
340
|
ref_key: "chartRef",
|
|
336
|
-
ref:
|
|
341
|
+
ref: v,
|
|
337
342
|
class: "chart__canvas"
|
|
338
343
|
}, null, 512),
|
|
339
|
-
|
|
344
|
+
R("div", {
|
|
340
345
|
ref_key: "tooltipRef",
|
|
341
|
-
ref:
|
|
346
|
+
ref: V,
|
|
342
347
|
class: "chart__tooltip",
|
|
343
|
-
style: he(s(
|
|
348
|
+
style: he(s(Q))
|
|
344
349
|
}, [
|
|
345
|
-
c.value ? (f(),
|
|
350
|
+
c.value ? (f(), B(Ue, {
|
|
346
351
|
key: 0,
|
|
347
352
|
"totals-chart": s(p),
|
|
348
353
|
title: String(c.value.title),
|
|
@@ -354,20 +359,20 @@ const Qe = { class: "chart-plane-container" }, et = {
|
|
|
354
359
|
"total-value": Number(c.value.footer?.[1]),
|
|
355
360
|
"value-suffix": o.valueSuffix,
|
|
356
361
|
"value-prefix": o.valuePrefix
|
|
357
|
-
}, null, 8, ["totals-chart", "title", "data-points", "x-axis-format", "y-axis-format", "x-axis-date-interval", "total-label", "total-value", "value-suffix", "value-prefix"])) :
|
|
362
|
+
}, null, 8, ["totals-chart", "title", "data-points", "x-axis-format", "y-axis-format", "x-axis-date-interval", "total-label", "total-value", "value-suffix", "value-prefix"])) : E("", !0)
|
|
358
363
|
], 4)
|
|
359
364
|
])
|
|
360
|
-
])) : o.loading ? (f(),
|
|
365
|
+
])) : o.loading ? (f(), B(We, {
|
|
361
366
|
key: 2,
|
|
362
367
|
class: "chart-loading"
|
|
363
|
-
})) : s(
|
|
368
|
+
})) : s(D) ? (f(), B(s($e), {
|
|
364
369
|
key: 3,
|
|
365
370
|
class: "chart-empty",
|
|
366
371
|
variant: null,
|
|
367
372
|
title: o.noDataTitle,
|
|
368
373
|
subtitle: o.noDataSubtitle,
|
|
369
374
|
"icon-name": o.noDataIcon
|
|
370
|
-
}, null, 8, ["title", "subtitle", "icon-name"])) :
|
|
375
|
+
}, null, 8, ["title", "subtitle", "icon-name"])) : E("", !0)
|
|
371
376
|
]));
|
|
372
377
|
}
|
|
373
378
|
});
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import { PrepareTicksLabelArgs, ValueFormat } from '@/components/chart/types';
|
|
2
2
|
export declare const calcStepSize: (min: number, max: number, tickCount: number) => number;
|
|
3
|
-
export declare const formatValue: (value: number | string | Date, valueFormat: ValueFormat) => string;
|
|
3
|
+
export declare const formatValue: (value: number | string | Date, valueFormat: ValueFormat, formatLowDigits?: boolean) => string;
|
|
4
4
|
export declare const prepareTickLabel: ({ label, format, availableSpace, truncate, }: PrepareTicksLabelArgs) => string | string[];
|
|
@@ -1,27 +1,27 @@
|
|
|
1
|
-
import { format as
|
|
1
|
+
import { format as m } from "date-fns";
|
|
2
2
|
import { TICK_LABEL_FONT as c } from "../consts.js";
|
|
3
|
-
import { nFormatter as
|
|
4
|
-
import { truncateTextToFit as
|
|
3
|
+
import { nFormatter as p } from "../../../utils/formatNumbers.js";
|
|
4
|
+
import { truncateTextToFit as d } from "../../../utils/text.js";
|
|
5
5
|
import { REGEX_LINEBREAK as i } from "../../../consts/regex.js";
|
|
6
6
|
const g = (r, t, e) => {
|
|
7
7
|
if (e === 0)
|
|
8
8
|
return 0;
|
|
9
|
-
const n = t - r,
|
|
9
|
+
const n = Math.max(t - r, 1), f = n / e, o = n > 1 ? f * 0.4 : 0;
|
|
10
10
|
return (n + o) / e;
|
|
11
|
-
},
|
|
11
|
+
}, E = (r, t, e = !1) => t === "day" ? m(new Date(r), "EEEE") : t === "number" ? p(r, e) : t === "date" ? m(new Date(r), "MMM dd") : t === "dateLong" ? m(new Date(r), "MMM dd, yyyy") : String(r), w = ({
|
|
12
12
|
label: r,
|
|
13
13
|
format: t,
|
|
14
14
|
availableSpace: e,
|
|
15
15
|
truncate: n = !1
|
|
16
16
|
}) => {
|
|
17
|
-
const
|
|
18
|
-
const
|
|
19
|
-
return n && e > 0 ?
|
|
17
|
+
const f = i.test(r), o = (a) => {
|
|
18
|
+
const s = E(a, t);
|
|
19
|
+
return n && e > 0 ? d(s, c, e) : s;
|
|
20
20
|
};
|
|
21
|
-
return
|
|
21
|
+
return f ? r.split(i).map(o) : o(r);
|
|
22
22
|
};
|
|
23
23
|
export {
|
|
24
24
|
g as calcStepSize,
|
|
25
|
-
|
|
25
|
+
E as formatValue,
|
|
26
26
|
w as prepareTickLabel
|
|
27
27
|
};
|
|
@@ -13,6 +13,7 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<__
|
|
|
13
13
|
isOpen?: boolean;
|
|
14
14
|
options: unknown[];
|
|
15
15
|
showSelectAll?: boolean;
|
|
16
|
+
showClearAll?: boolean;
|
|
16
17
|
defaultOpen?: boolean;
|
|
17
18
|
keepOpen?: boolean;
|
|
18
19
|
autoSize?: boolean;
|
|
@@ -94,6 +95,7 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<__
|
|
|
94
95
|
disableKeyboardEvents: boolean;
|
|
95
96
|
testId: string;
|
|
96
97
|
showSelectAll: boolean;
|
|
98
|
+
showClearAll: boolean;
|
|
97
99
|
dynamicFilterMode: boolean;
|
|
98
100
|
minSelections: number;
|
|
99
101
|
maxSelections: any;
|
|
@@ -159,6 +161,7 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<__
|
|
|
159
161
|
isOpen?: boolean;
|
|
160
162
|
options: unknown[];
|
|
161
163
|
showSelectAll?: boolean;
|
|
164
|
+
showClearAll?: boolean;
|
|
162
165
|
defaultOpen?: boolean;
|
|
163
166
|
keepOpen?: boolean;
|
|
164
167
|
autoSize?: boolean;
|
|
@@ -240,6 +243,7 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<__
|
|
|
240
243
|
disableKeyboardEvents: boolean;
|
|
241
244
|
testId: string;
|
|
242
245
|
showSelectAll: boolean;
|
|
246
|
+
showClearAll: boolean;
|
|
243
247
|
dynamicFilterMode: boolean;
|
|
244
248
|
minSelections: number;
|
|
245
249
|
maxSelections: any;
|
|
@@ -307,6 +311,7 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<__
|
|
|
307
311
|
multi: boolean;
|
|
308
312
|
infiniteLoading: boolean;
|
|
309
313
|
showSelectAll: boolean;
|
|
314
|
+
showClearAll: boolean;
|
|
310
315
|
defaultOpen: boolean;
|
|
311
316
|
keepOpen: boolean;
|
|
312
317
|
autoSize: boolean;
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import o from "./DropdownV4.vue2.js";
|
|
2
|
-
/* empty css *//* empty css */import
|
|
3
|
-
// import "../../../DropdownV4.
|
|
2
|
+
/* empty css *//* empty css */import _ from "../../../_virtual/_plugin-vue_export-helper.js";
|
|
3
|
+
// import "../../../DropdownV4.vue_vue_type_style_index_0_scoped_1f7f7f9c_lang.css"; //*');
|
|
4
4
|
// import "../../../DropdownV4.vue_vue_type_style_index_1_lang.css"; //');
|
|
5
|
-
const r = /* @__PURE__ */
|
|
5
|
+
const r = /* @__PURE__ */ _(o, [["__scopeId", "data-v-1f7f7f9c"]]);
|
|
6
6
|
export {
|
|
7
7
|
r as default
|
|
8
8
|
};
|