@ironsource/shared-ui 2.1.12-rc.13 → 2.1.12-rc.14
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/ButtonV4.vue_vue_type_style_index_0_scoped_d7948c77_lang.css +1 -0
- package/Chart.vue_vue_type_style_index_0_scoped_de950ffe_lang.css +1 -0
- package/ChartHeader.vue_vue_type_style_index_0_scoped_1ff0e54f_lang.css +1 -0
- package/ChartHeaderTrend.vue_vue_type_style_index_0_scoped_21ce0774_lang.css +1 -0
- package/ChartPlane.vue_vue_type_style_index_0_scoped_ae87f435_lang.css +1 -0
- package/DialogV4.vue_vue_type_style_index_0_scoped_eb226e31_lang.css +1 -0
- package/FieldLabel.vue_vue_type_style_index_0_scoped_921d4087_lang.css +1 -0
- package/FormRow.vue_vue_type_style_index_0_scoped_2d5a3057_lang.css +1 -0
- package/SettingsHeader.vue_vue_type_style_index_0_scoped_01f78cd7_lang.css +1 -0
- package/Tooltip.vue_vue_type_style_index_0_scoped_20630944_lang.css +1 -0
- package/TooltipV4.vue_vue_type_style_index_0_scoped_bcb40ed4_lang.css +1 -0
- package/components/appIcon/index.d.ts +3 -3
- package/components/banner/Banner.vue.d.ts +3 -3
- package/components/banner/index.d.ts +7 -7
- package/components/button/common/consts.d.ts +1 -0
- package/components/button/v3/Button.vue.d.ts +3 -3
- package/components/button/v3/ButtonBase.vue.d.ts +3 -3
- package/components/button/v3/IconButton.vue.d.ts +3 -3
- package/components/button/v3/index.d.ts +14 -14
- package/components/button/v4/ButtonV4.vue.d.ts +4 -3
- package/components/button/v4/ButtonV4.vue.js +3 -3
- package/components/button/v4/ButtonV4.vue2.js +1 -1
- package/components/chart/Chart.vue.d.ts +36 -0
- package/components/chart/Chart.vue.js +5 -5
- package/components/chart/Chart.vue2.js +89 -74
- package/components/chart/ChartHeader.vue.d.ts +24 -0
- package/components/chart/ChartHeader.vue.js +3 -3
- package/components/chart/ChartHeader.vue2.js +70 -50
- package/components/chart/ChartHeaderTrend.vue.d.ts +13 -0
- package/components/chart/ChartHeaderTrend.vue.js +2 -2
- package/components/chart/ChartHeaderTrend.vue2.js +80 -18
- package/components/chart/ChartPlane.vue.d.ts +35 -2
- package/components/chart/ChartPlane.vue.js +4 -4
- package/components/chart/ChartPlane.vue2.js +115 -103
- package/components/chart/SettingsHeader.vue.d.ts +1 -0
- package/components/chart/SettingsHeader.vue.js +3 -3
- package/components/chart/SettingsHeader.vue2.js +17 -16
- package/components/chart/index.d.ts +106 -1
- package/components/checkbox/v3/Checkbox.vue.d.ts +3 -3
- package/components/checkbox/v3/index.d.ts +7 -7
- package/components/dialog/v4/DialogV4.vue.d.ts +4 -3
- package/components/dialog/v4/DialogV4.vue.js +4 -4
- package/components/dialog/v4/DialogV4.vue2.js +1 -1
- package/components/dialog/v4/index.d.ts +7 -7
- package/components/forms/FormRow.vue.d.ts +9 -2
- package/components/forms/FormRow.vue.js +3 -3
- package/components/forms/FormRow.vue2.js +25 -14
- package/components/forms/index.d.ts +25 -5
- package/components/search/v3/index.d.ts +3 -3
- package/components/shared/FieldLabel.vue.d.ts +19 -7
- package/components/shared/FieldLabel.vue.js +3 -3
- package/components/shared/FieldLabel.vue2.js +50 -37
- package/components/tabs/v3/Tabs.vue.d.ts +3 -3
- package/components/tabs/v3/index.d.ts +7 -7
- package/components/tooltip/common/Tooltip.types.d.ts +1 -0
- package/components/tooltip/v3/Tooltip.vue.d.ts +4 -4
- package/components/tooltip/v3/Tooltip.vue.js +2 -2
- package/components/tooltip/v3/Tooltip.vue2.js +1 -1
- package/components/tooltip/v3/index.d.ts +7 -7
- package/components/tooltip/v4/TooltipV4.vue.d.ts +4 -4
- package/components/tooltip/v4/TooltipV4.vue.js +2 -2
- package/components/tooltip/v4/TooltipV4.vue2.js +1 -1
- package/components/tooltip/v4/index.d.ts +7 -7
- package/components/typography/Text.vue.d.ts +3 -3
- package/components/typography/index.d.ts +7 -7
- package/composables/useFormValidation.d.ts +1 -0
- package/composables/useFormValidation.js +29 -26
- package/index.d.ts +35 -35
- package/index.js +1 -1
- package/package.json +1 -1
- package/utils/totals.d.ts +5 -0
- package/utils/totals.js +9 -0
- package/ButtonV4.vue_vue_type_style_index_0_scoped_bdfce3aa_lang.css +0 -1
- package/Chart.vue_vue_type_style_index_0_scoped_a0b89669_lang.css +0 -1
- package/ChartHeader.vue_vue_type_style_index_0_scoped_32001725_lang.css +0 -1
- package/ChartHeaderTrend.vue_vue_type_style_index_0_scoped_e4c673e7_lang.css +0 -1
- package/ChartPlane.vue_vue_type_style_index_0_scoped_0f3a67d5_lang.css +0 -1
- package/DialogV4.vue_vue_type_style_index_0_scoped_37da643b_lang.css +0 -1
- package/FieldLabel.vue_vue_type_style_index_0_scoped_96ee1c98_lang.css +0 -1
- package/FormRow.vue_vue_type_style_index_0_scoped_fc3897fd_lang.css +0 -1
- package/SettingsHeader.vue_vue_type_style_index_0_scoped_0875167b_lang.css +0 -1
- package/Tooltip.vue_vue_type_style_index_0_scoped_9020a179_lang.css +0 -1
- package/TooltipV4.vue_vue_type_style_index_0_scoped_66eab856_lang.css +0 -1
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { ChartDataSet, ChartParsingConfig, ChartType, ValueFormat } from './types';
|
|
2
|
+
import { TotalType } from '@/utils/totals';
|
|
2
3
|
declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<{
|
|
3
4
|
dataSets: ChartDataSet[];
|
|
4
5
|
visibleIds: unknown[];
|
|
@@ -10,10 +11,21 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<__
|
|
|
10
11
|
loading?: boolean;
|
|
11
12
|
withAnimation?: boolean;
|
|
12
13
|
totalsChart?: boolean;
|
|
14
|
+
tooltipTotalType?: TotalType;
|
|
15
|
+
tooltipTotalCalcFn?: (values: number[], totalType: TotalType) => number;
|
|
13
16
|
header?: string;
|
|
14
17
|
subheader?: string;
|
|
18
|
+
subheaderTooltip?: {
|
|
19
|
+
header?: string;
|
|
20
|
+
text?: string;
|
|
21
|
+
};
|
|
15
22
|
trendValue?: string | number;
|
|
16
23
|
trendDirection?: "up" | "down";
|
|
24
|
+
trendTooltip?: {
|
|
25
|
+
header?: string;
|
|
26
|
+
rangeCurrent?: string;
|
|
27
|
+
rangePrevious?: string;
|
|
28
|
+
};
|
|
17
29
|
noDataIcon?: string;
|
|
18
30
|
noDataTitle?: string;
|
|
19
31
|
noDataSubtitle?: string;
|
|
@@ -38,10 +50,14 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<__
|
|
|
38
50
|
loading: boolean;
|
|
39
51
|
withAnimation: boolean;
|
|
40
52
|
totalsChart: boolean;
|
|
53
|
+
tooltipTotalType: TotalType;
|
|
54
|
+
tooltipTotalCalcFn: (values: number[], totalType: TotalType) => number;
|
|
41
55
|
header: string;
|
|
42
56
|
subheader: string;
|
|
57
|
+
subheaderTooltip: any;
|
|
43
58
|
trendValue: any;
|
|
44
59
|
trendDirection: string;
|
|
60
|
+
trendTooltip: any;
|
|
45
61
|
noDataIcon: string;
|
|
46
62
|
noDataTitle: string;
|
|
47
63
|
noDataSubtitle: string;
|
|
@@ -70,10 +86,21 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<__
|
|
|
70
86
|
loading?: boolean;
|
|
71
87
|
withAnimation?: boolean;
|
|
72
88
|
totalsChart?: boolean;
|
|
89
|
+
tooltipTotalType?: TotalType;
|
|
90
|
+
tooltipTotalCalcFn?: (values: number[], totalType: TotalType) => number;
|
|
73
91
|
header?: string;
|
|
74
92
|
subheader?: string;
|
|
93
|
+
subheaderTooltip?: {
|
|
94
|
+
header?: string;
|
|
95
|
+
text?: string;
|
|
96
|
+
};
|
|
75
97
|
trendValue?: string | number;
|
|
76
98
|
trendDirection?: "up" | "down";
|
|
99
|
+
trendTooltip?: {
|
|
100
|
+
header?: string;
|
|
101
|
+
rangeCurrent?: string;
|
|
102
|
+
rangePrevious?: string;
|
|
103
|
+
};
|
|
77
104
|
noDataIcon?: string;
|
|
78
105
|
noDataTitle?: string;
|
|
79
106
|
noDataSubtitle?: string;
|
|
@@ -98,10 +125,14 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<__
|
|
|
98
125
|
loading: boolean;
|
|
99
126
|
withAnimation: boolean;
|
|
100
127
|
totalsChart: boolean;
|
|
128
|
+
tooltipTotalType: TotalType;
|
|
129
|
+
tooltipTotalCalcFn: (values: number[], totalType: TotalType) => number;
|
|
101
130
|
header: string;
|
|
102
131
|
subheader: string;
|
|
132
|
+
subheaderTooltip: any;
|
|
103
133
|
trendValue: any;
|
|
104
134
|
trendDirection: string;
|
|
135
|
+
trendTooltip: any;
|
|
105
136
|
noDataIcon: string;
|
|
106
137
|
noDataTitle: string;
|
|
107
138
|
noDataSubtitle: string;
|
|
@@ -135,7 +166,9 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<__
|
|
|
135
166
|
yAxisFormat: ValueFormat;
|
|
136
167
|
parsing: ChartParsingConfig;
|
|
137
168
|
dataSets: ChartDataSet[];
|
|
169
|
+
trendTooltip: any;
|
|
138
170
|
subheader: string;
|
|
171
|
+
subheaderTooltip: any;
|
|
139
172
|
trendValue: string | number;
|
|
140
173
|
trendDirection: "up" | "down";
|
|
141
174
|
tickCount: number;
|
|
@@ -143,11 +176,14 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<__
|
|
|
143
176
|
noDataTitle: string;
|
|
144
177
|
noDataSubtitle: string;
|
|
145
178
|
withAnimation: boolean;
|
|
179
|
+
tooltipTotalType: TotalType;
|
|
180
|
+
tooltipTotalCalcFn: (values: number[], totalType: TotalType) => number;
|
|
146
181
|
totalsChart: boolean;
|
|
147
182
|
fullHeight: boolean;
|
|
148
183
|
withSettingsHeader: boolean;
|
|
149
184
|
extraCharts: Record<string, unknown>[];
|
|
150
185
|
}>, {
|
|
186
|
+
"before-chart-type"?(_: {}): any;
|
|
151
187
|
metric?(_: {}): any;
|
|
152
188
|
breakdowns?(_: {}): any;
|
|
153
189
|
"subheader-tooltip"?(_: {}): any;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import
|
|
2
|
-
/* empty css */import
|
|
3
|
-
// import "../../Chart.
|
|
4
|
-
const
|
|
1
|
+
import e from "./Chart.vue2.js";
|
|
2
|
+
/* empty css */import o from "../../_virtual/_plugin-vue_export-helper.js";
|
|
3
|
+
// import "../../Chart.vue_vue_type_style_index_0_scoped_de950ffe_lang.css"; //*');
|
|
4
|
+
const p = /* @__PURE__ */ o(e, [["__scopeId", "data-v-de950ffe"]]);
|
|
5
5
|
export {
|
|
6
|
-
|
|
6
|
+
p as default
|
|
7
7
|
};
|
|
@@ -1,21 +1,22 @@
|
|
|
1
|
-
import "../../Chart.
|
|
2
|
-
import { useVModel as
|
|
3
|
-
import
|
|
4
|
-
import
|
|
5
|
-
import
|
|
6
|
-
import { useColorsMap as
|
|
7
|
-
import { DEFAULT_TICK_COUNT as K, DEFAULT_MIN_VISIBLE as
|
|
8
|
-
import { ChartType as
|
|
9
|
-
import { useChartHeight as
|
|
10
|
-
|
|
1
|
+
import "../../Chart.vue_vue_type_style_index_0_scoped_de950ffe_lang.css"; import { defineComponent as E, computed as n, openBlock as s, createElementBlock as m, Fragment as S, createBlock as x, unref as a, isRef as f, withCtx as d, renderSlot as u, createCommentVNode as I, createElementVNode as D, mergeProps as y, normalizeClass as N, createVNode as F, createSlots as U, renderList as M } from "vue";
|
|
2
|
+
import { useVModel as L } from "@vueuse/core";
|
|
3
|
+
import P from "./ChartLegend.vue.js";
|
|
4
|
+
import O from "./SettingsHeader.vue.js";
|
|
5
|
+
import k from "./ChartPlane.vue.js";
|
|
6
|
+
import { useColorsMap as $ } from "./composables/useColorsMap.js";
|
|
7
|
+
import { DEFAULT_TICK_COUNT as K, DEFAULT_MIN_VISIBLE as z, DEFAULT_MAX_VISIBLE as R } from "./consts.js";
|
|
8
|
+
import { ChartType as X } from "./types.js";
|
|
9
|
+
import { useChartHeight as j } from "./composables/useChartHeight.js";
|
|
10
|
+
import { TotalType as q, calculateTotal as G } from "../../utils/totals.js";
|
|
11
|
+
const J = {
|
|
11
12
|
key: 0,
|
|
12
13
|
class: "chart-sidebar"
|
|
13
|
-
},
|
|
14
|
+
}, it = /* @__PURE__ */ E({
|
|
14
15
|
__name: "Chart",
|
|
15
16
|
props: {
|
|
16
17
|
dataSets: { default: () => [] },
|
|
17
18
|
visibleIds: { default: () => [] },
|
|
18
|
-
chartType: { default:
|
|
19
|
+
chartType: { default: X.Line },
|
|
19
20
|
parsing: { default: void 0 },
|
|
20
21
|
xAxisFormat: { default: "string" },
|
|
21
22
|
yAxisFormat: { default: "number" },
|
|
@@ -23,16 +24,20 @@ const j = {
|
|
|
23
24
|
loading: { type: Boolean, default: !1 },
|
|
24
25
|
withAnimation: { type: Boolean, default: !0 },
|
|
25
26
|
totalsChart: { type: Boolean, default: !1 },
|
|
27
|
+
tooltipTotalType: { default: q.Total },
|
|
28
|
+
tooltipTotalCalcFn: { type: Function, default: G },
|
|
26
29
|
header: { default: "" },
|
|
27
30
|
subheader: { default: "" },
|
|
31
|
+
subheaderTooltip: { default: null },
|
|
28
32
|
trendValue: { default: null },
|
|
29
33
|
trendDirection: { default: "up" },
|
|
34
|
+
trendTooltip: { default: null },
|
|
30
35
|
noDataIcon: { default: "file-search" },
|
|
31
36
|
noDataTitle: { default: "No data to display" },
|
|
32
37
|
noDataSubtitle: { default: "Search again with different filters" },
|
|
33
38
|
hideLegend: { type: Boolean, default: !1 },
|
|
34
|
-
minVisible: { default:
|
|
35
|
-
maxVisible: { default:
|
|
39
|
+
minVisible: { default: z },
|
|
40
|
+
maxVisible: { default: R },
|
|
36
41
|
maxLimitTooltipText: { default: "" },
|
|
37
42
|
sortSelected: { default: null },
|
|
38
43
|
sortOptions: { default: () => [] },
|
|
@@ -42,54 +47,61 @@ const j = {
|
|
|
42
47
|
extraCharts: { default: () => [] }
|
|
43
48
|
},
|
|
44
49
|
emits: ["update:chartType", "update:visibleIds", "update:sortSelected"],
|
|
45
|
-
setup(o, { emit:
|
|
46
|
-
const
|
|
47
|
-
dataSets:
|
|
48
|
-
visibleIds:
|
|
49
|
-
parsing:
|
|
50
|
-
xAxisFormat:
|
|
51
|
-
yAxisFormat:
|
|
52
|
-
tickCount:
|
|
53
|
-
header:
|
|
54
|
-
subheader:
|
|
55
|
-
loading:
|
|
56
|
-
noDataIcon:
|
|
57
|
-
noDataTitle:
|
|
58
|
-
noDataSubtitle:
|
|
59
|
-
withAnimation:
|
|
60
|
-
typeSwitcher: !
|
|
50
|
+
setup(o, { emit: p }) {
|
|
51
|
+
const t = o, r = L(t, "chartType", p), c = L(t, "sortSelected", p), T = n(() => ({
|
|
52
|
+
dataSets: t.dataSets,
|
|
53
|
+
visibleIds: t.visibleIds,
|
|
54
|
+
parsing: t.parsing,
|
|
55
|
+
xAxisFormat: t.xAxisFormat,
|
|
56
|
+
yAxisFormat: t.yAxisFormat,
|
|
57
|
+
tickCount: t.tickCount,
|
|
58
|
+
header: t.header,
|
|
59
|
+
subheader: t.subheader,
|
|
60
|
+
loading: t.loading,
|
|
61
|
+
noDataIcon: t.noDataIcon,
|
|
62
|
+
noDataTitle: t.noDataTitle,
|
|
63
|
+
noDataSubtitle: t.noDataSubtitle,
|
|
64
|
+
withAnimation: t.withAnimation,
|
|
65
|
+
typeSwitcher: !t.withSettingsHeader,
|
|
61
66
|
height: H.value,
|
|
62
|
-
compactHeader:
|
|
63
|
-
trendValue:
|
|
64
|
-
trendDirection:
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
67
|
+
compactHeader: C.value > 1,
|
|
68
|
+
trendValue: t.trendValue,
|
|
69
|
+
trendDirection: t.trendDirection,
|
|
70
|
+
trendTooltip: t.trendTooltip,
|
|
71
|
+
totalsChart: t.totalsChart,
|
|
72
|
+
subheaderTooltip: t.subheaderTooltip,
|
|
73
|
+
colorsMap: h.value,
|
|
74
|
+
tooltipTotalType: t.tooltipTotalType,
|
|
75
|
+
tooltipTotalCalcFn: t.tooltipTotalCalcFn
|
|
76
|
+
})), w = n(() => t.dataSets), b = n(() => t.visibleIds), g = n(() => t.extraCharts.length), C = n(() => 1 + g.value), A = (e) => e === g.value - 1, { colorsMap: h } = $({
|
|
77
|
+
dataSets: w,
|
|
69
78
|
visibleIds: b
|
|
70
|
-
}),
|
|
71
|
-
id:
|
|
72
|
-
label:
|
|
73
|
-
caption:
|
|
74
|
-
color:
|
|
75
|
-
icon:
|
|
76
|
-
iconType:
|
|
77
|
-
}))), { containerProps: V, eachPlaneHeight: H } =
|
|
78
|
-
chartPlanesCount:
|
|
79
|
-
useFullHeight:
|
|
79
|
+
}), B = n(() => t.dataSets.map((e) => ({
|
|
80
|
+
id: e.id,
|
|
81
|
+
label: e.label,
|
|
82
|
+
caption: e.caption || null,
|
|
83
|
+
color: h.value[e.id] || null,
|
|
84
|
+
icon: e.icon || null,
|
|
85
|
+
iconType: e.iconType || "branded"
|
|
86
|
+
}))), { containerProps: V, eachPlaneHeight: H } = j({
|
|
87
|
+
chartPlanesCount: C,
|
|
88
|
+
useFullHeight: t.fullHeight
|
|
80
89
|
});
|
|
81
|
-
return (
|
|
82
|
-
o.withSettingsHeader ? (s(),
|
|
90
|
+
return (e, i) => (s(), m(S, null, [
|
|
91
|
+
o.withSettingsHeader ? (s(), x(O, {
|
|
83
92
|
key: 0,
|
|
84
93
|
"chart-type": a(r),
|
|
85
|
-
"onUpdate:chart-type": i[0] || (i[0] = (l) =>
|
|
94
|
+
"onUpdate:chart-type": i[0] || (i[0] = (l) => f(r) ? r.value = l : null),
|
|
86
95
|
"hide-legend": o.hideLegend
|
|
87
96
|
}, {
|
|
88
|
-
|
|
89
|
-
|
|
97
|
+
"before-chart-type": d(() => [
|
|
98
|
+
u(e.$slots, "before-chart-type", {}, void 0, !0)
|
|
90
99
|
]),
|
|
91
|
-
|
|
92
|
-
|
|
100
|
+
metric: d(() => [
|
|
101
|
+
u(e.$slots, "metric", {}, void 0, !0)
|
|
102
|
+
]),
|
|
103
|
+
breakdowns: d(() => [
|
|
104
|
+
u(e.$slots, "breakdowns", {}, void 0, !0)
|
|
93
105
|
]),
|
|
94
106
|
_: 3
|
|
95
107
|
}, 8, ["chart-type", "hide-legend"])) : I("", !0),
|
|
@@ -97,35 +109,38 @@ const j = {
|
|
|
97
109
|
D("section", {
|
|
98
110
|
class: N(["chart-planes", [{ "with-legend": !o.hideLegend }]])
|
|
99
111
|
}, [
|
|
100
|
-
|
|
112
|
+
F(k, y({
|
|
101
113
|
"chart-type": a(r),
|
|
102
|
-
"onUpdate:chart-type": i[1] || (i[1] = (l) =>
|
|
103
|
-
}, a(
|
|
104
|
-
"subheader-tooltip"
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
114
|
+
"onUpdate:chart-type": i[1] || (i[1] = (l) => f(r) ? r.value = l : null)
|
|
115
|
+
}, a(T)), U({ _: 2 }, [
|
|
116
|
+
e.$slots["subheader-tooltip"] ? {
|
|
117
|
+
name: "subheader-tooltip",
|
|
118
|
+
fn: d(() => [
|
|
119
|
+
u(e.$slots, "subheader-tooltip", {}, void 0, !0)
|
|
120
|
+
]),
|
|
121
|
+
key: "0"
|
|
122
|
+
} : void 0
|
|
123
|
+
]), 1040, ["chart-type"]),
|
|
124
|
+
(s(!0), m(S, null, M(o.extraCharts, (l, v) => (s(), x(k, y({
|
|
125
|
+
key: v,
|
|
111
126
|
class: "extra-chart-plane"
|
|
112
|
-
}, { ...a(
|
|
127
|
+
}, { ...a(T), ...l }, {
|
|
113
128
|
"chart-type": a(r),
|
|
114
|
-
"colors-map": a(
|
|
129
|
+
"colors-map": a(h),
|
|
115
130
|
"type-switcher": !1,
|
|
116
|
-
"tooltip-respects-top-edge": !
|
|
131
|
+
"tooltip-respects-top-edge": !A(v)
|
|
117
132
|
}), null, 16, ["chart-type", "colors-map", "tooltip-respects-top-edge"]))), 128))
|
|
118
133
|
], 2),
|
|
119
|
-
o.hideLegend ? I("", !0) : (s(),
|
|
120
|
-
|
|
121
|
-
"sort-selected": a(
|
|
122
|
-
"onUpdate:sort-selected": i[2] || (i[2] = (l) =>
|
|
123
|
-
items: a(
|
|
134
|
+
o.hideLegend ? I("", !0) : (s(), m("section", J, [
|
|
135
|
+
F(P, {
|
|
136
|
+
"sort-selected": a(c),
|
|
137
|
+
"onUpdate:sort-selected": i[2] || (i[2] = (l) => f(c) ? c.value = l : null),
|
|
138
|
+
items: a(B),
|
|
124
139
|
"visible-ids": a(b),
|
|
125
140
|
"max-limit-tooltip-text": o.maxLimitTooltipText,
|
|
126
141
|
"sort-options": o.sortOptions,
|
|
127
142
|
"sort-option-name-key": o.sortOptionNameKey,
|
|
128
|
-
"onUpdate:visibleIds": i[3] || (i[3] = (l) =>
|
|
143
|
+
"onUpdate:visibleIds": i[3] || (i[3] = (l) => p("update:visibleIds", l))
|
|
129
144
|
}, null, 8, ["sort-selected", "items", "visible-ids", "max-limit-tooltip-text", "sort-options", "sort-option-name-key"])
|
|
130
145
|
]))
|
|
131
146
|
], 16)
|
|
@@ -133,5 +148,5 @@ const j = {
|
|
|
133
148
|
}
|
|
134
149
|
});
|
|
135
150
|
export {
|
|
136
|
-
|
|
151
|
+
it as default
|
|
137
152
|
};
|
|
@@ -4,6 +4,15 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<__
|
|
|
4
4
|
typeSwitcher: boolean;
|
|
5
5
|
header?: string;
|
|
6
6
|
subheader?: string;
|
|
7
|
+
subheaderTooltip?: {
|
|
8
|
+
header?: string;
|
|
9
|
+
text?: string;
|
|
10
|
+
};
|
|
11
|
+
trendTooltip?: {
|
|
12
|
+
header?: string;
|
|
13
|
+
rangeCurrent?: string;
|
|
14
|
+
rangePrevious?: string;
|
|
15
|
+
};
|
|
7
16
|
compact: boolean;
|
|
8
17
|
trendValue?: string | number;
|
|
9
18
|
trendDirection?: "up" | "down";
|
|
@@ -12,6 +21,8 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<__
|
|
|
12
21
|
typeSwitcher: boolean;
|
|
13
22
|
header: string;
|
|
14
23
|
subheader: string;
|
|
24
|
+
subheaderTooltip: any;
|
|
25
|
+
trendTooltip: any;
|
|
15
26
|
compact: boolean;
|
|
16
27
|
trendValue: any;
|
|
17
28
|
trendDirection: string;
|
|
@@ -22,6 +33,15 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<__
|
|
|
22
33
|
typeSwitcher: boolean;
|
|
23
34
|
header?: string;
|
|
24
35
|
subheader?: string;
|
|
36
|
+
subheaderTooltip?: {
|
|
37
|
+
header?: string;
|
|
38
|
+
text?: string;
|
|
39
|
+
};
|
|
40
|
+
trendTooltip?: {
|
|
41
|
+
header?: string;
|
|
42
|
+
rangeCurrent?: string;
|
|
43
|
+
rangePrevious?: string;
|
|
44
|
+
};
|
|
25
45
|
compact: boolean;
|
|
26
46
|
trendValue?: string | number;
|
|
27
47
|
trendDirection?: "up" | "down";
|
|
@@ -30,6 +50,8 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<__
|
|
|
30
50
|
typeSwitcher: boolean;
|
|
31
51
|
header: string;
|
|
32
52
|
subheader: string;
|
|
53
|
+
subheaderTooltip: any;
|
|
54
|
+
trendTooltip: any;
|
|
33
55
|
compact: boolean;
|
|
34
56
|
trendValue: any;
|
|
35
57
|
trendDirection: string;
|
|
@@ -39,8 +61,10 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<__
|
|
|
39
61
|
header: string;
|
|
40
62
|
compact: boolean;
|
|
41
63
|
chartType: ChartType;
|
|
64
|
+
trendTooltip: any;
|
|
42
65
|
typeSwitcher: boolean;
|
|
43
66
|
subheader: string;
|
|
67
|
+
subheaderTooltip: any;
|
|
44
68
|
trendValue: string | number;
|
|
45
69
|
trendDirection: "up" | "down";
|
|
46
70
|
}>, {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import e from "./ChartHeader.vue2.js";
|
|
2
2
|
/* empty css */import o from "../../_virtual/_plugin-vue_export-helper.js";
|
|
3
|
-
// import "../../ChartHeader.
|
|
4
|
-
const
|
|
3
|
+
// import "../../ChartHeader.vue_vue_type_style_index_0_scoped_1ff0e54f_lang.css"; //*');
|
|
4
|
+
const f = /* @__PURE__ */ o(e, [["__scopeId", "data-v-1ff0e54f"]]);
|
|
5
5
|
export {
|
|
6
|
-
|
|
6
|
+
f as default
|
|
7
7
|
};
|
|
@@ -1,53 +1,81 @@
|
|
|
1
|
-
import "../../ChartHeader.
|
|
2
|
-
import
|
|
3
|
-
import
|
|
4
|
-
import { ChartType as
|
|
5
|
-
import
|
|
6
|
-
import
|
|
7
|
-
const
|
|
1
|
+
import "../../ChartHeader.vue_vue_type_style_index_0_scoped_1ff0e54f_lang.css"; import { defineComponent as B, useSlots as g, computed as m, openBlock as r, createElementBlock as N, normalizeClass as D, createElementVNode as n, createVNode as f, unref as t, withCtx as o, renderSlot as L, createBlock as d, createTextVNode as u, toDisplayString as c, createCommentVNode as i, normalizeProps as v, mergeProps as V, isRef as P } from "vue";
|
|
2
|
+
import s from "../typography/v4/Typography.vue.js";
|
|
3
|
+
import z from "../switch/v4/SwitchV4.vue.js";
|
|
4
|
+
import { ChartType as h } from "./types.js";
|
|
5
|
+
import E from "../tooltip/v4/TooltipV4.vue.js";
|
|
6
|
+
import k from "./ChartHeaderTrend.vue.js";
|
|
7
|
+
const H = { class: "header-texts" }, O = { class: "header-row" }, R = { class: "subheader-tooltip" }, U = { class: "header-row" }, I = /* @__PURE__ */ B({
|
|
8
8
|
__name: "ChartHeader",
|
|
9
9
|
props: {
|
|
10
|
-
chartType: { default:
|
|
10
|
+
chartType: { default: h.Line },
|
|
11
11
|
typeSwitcher: { type: Boolean, default: !0 },
|
|
12
12
|
header: { default: "" },
|
|
13
13
|
subheader: { default: "" },
|
|
14
|
+
subheaderTooltip: { default: null },
|
|
15
|
+
trendTooltip: { default: null },
|
|
14
16
|
compact: { type: Boolean, default: !1 },
|
|
15
17
|
trendValue: { default: null },
|
|
16
18
|
trendDirection: { default: "up" }
|
|
17
19
|
},
|
|
18
20
|
emits: ["update:chartType"],
|
|
19
|
-
setup(e, { emit:
|
|
20
|
-
const
|
|
21
|
-
{ id:
|
|
22
|
-
{ id:
|
|
23
|
-
{ id:
|
|
24
|
-
],
|
|
21
|
+
setup(e, { emit: x }) {
|
|
22
|
+
const a = e, S = g(), T = [
|
|
23
|
+
{ id: h.Line, icon: "chart-line-up" },
|
|
24
|
+
{ id: h.Bar, icon: "chart-bar" },
|
|
25
|
+
{ id: h.StackedLine, icon: "chart-line" }
|
|
26
|
+
], p = m({
|
|
25
27
|
get() {
|
|
26
|
-
return
|
|
28
|
+
return T.find(({ id: l }) => l === a.chartType);
|
|
27
29
|
},
|
|
28
|
-
set(
|
|
29
|
-
|
|
30
|
+
set(l) {
|
|
31
|
+
x("update:chartType", l.id);
|
|
30
32
|
}
|
|
31
|
-
})
|
|
32
|
-
|
|
33
|
-
|
|
33
|
+
}), C = m(() => S["subheader-tooltip"] || a.subheaderTooltip?.text || a.subheaderTooltip?.header), y = m(() => ({
|
|
34
|
+
value: a.trendValue,
|
|
35
|
+
direction: a.trendDirection,
|
|
36
|
+
trendTooltip: a.trendTooltip
|
|
37
|
+
}));
|
|
38
|
+
return (l, b) => (r(), N("div", {
|
|
39
|
+
class: D(["chart-header", { "chart-header--compact": e.compact }])
|
|
34
40
|
}, [
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
41
|
+
n("div", H, [
|
|
42
|
+
n("div", O, [
|
|
43
|
+
f(t(E), {
|
|
38
44
|
placement: "right",
|
|
39
|
-
disabled: !t
|
|
45
|
+
disabled: !t(C)
|
|
40
46
|
}, {
|
|
41
|
-
tooltip:
|
|
42
|
-
|
|
47
|
+
tooltip: o(() => [
|
|
48
|
+
L(l.$slots, "subheader-tooltip", {}, () => [
|
|
49
|
+
n("div", R, [
|
|
50
|
+
e.subheaderTooltip?.header ? (r(), d(t(s), {
|
|
51
|
+
key: 0,
|
|
52
|
+
variant: "h5"
|
|
53
|
+
}, {
|
|
54
|
+
default: o(() => [
|
|
55
|
+
u(c(e.subheaderTooltip.header), 1)
|
|
56
|
+
]),
|
|
57
|
+
_: 1
|
|
58
|
+
})) : i("", !0),
|
|
59
|
+
e.subheaderTooltip?.text ? (r(), d(t(s), {
|
|
60
|
+
key: 1,
|
|
61
|
+
variant: "body2",
|
|
62
|
+
class: "subheader-tooltip__text"
|
|
63
|
+
}, {
|
|
64
|
+
default: o(() => [
|
|
65
|
+
u(c(e.subheaderTooltip.text), 1)
|
|
66
|
+
]),
|
|
67
|
+
_: 1
|
|
68
|
+
})) : i("", !0)
|
|
69
|
+
])
|
|
70
|
+
], !0)
|
|
43
71
|
]),
|
|
44
|
-
default:
|
|
45
|
-
|
|
72
|
+
default: o(() => [
|
|
73
|
+
f(t(s), {
|
|
46
74
|
class: "subheader",
|
|
47
75
|
variant: "h5"
|
|
48
76
|
}, {
|
|
49
|
-
default:
|
|
50
|
-
|
|
77
|
+
default: o(() => [
|
|
78
|
+
u(c(e.subheader + (e.compact ? ":" : "")), 1)
|
|
51
79
|
]),
|
|
52
80
|
_: 1
|
|
53
81
|
})
|
|
@@ -55,37 +83,29 @@ const D = { class: "header-texts" }, N = { class: "header-row" }, L = { class: "
|
|
|
55
83
|
_: 3
|
|
56
84
|
}, 8, ["disabled"])
|
|
57
85
|
]),
|
|
58
|
-
|
|
59
|
-
|
|
86
|
+
n("div", U, [
|
|
87
|
+
f(t(s), {
|
|
60
88
|
class: "header-text",
|
|
61
89
|
variant: e.compact ? "h5" : "chart2"
|
|
62
90
|
}, {
|
|
63
|
-
default:
|
|
64
|
-
|
|
91
|
+
default: o(() => [
|
|
92
|
+
u(c(e.header), 1)
|
|
65
93
|
]),
|
|
66
94
|
_: 1
|
|
67
95
|
}, 8, ["variant"]),
|
|
68
|
-
!e.compact && e.trendValue !== null ? (r(),
|
|
69
|
-
key: 0,
|
|
70
|
-
value: e.trendValue,
|
|
71
|
-
direction: e.trendDirection
|
|
72
|
-
}, null, 8, ["value", "direction"])) : u("", !0)
|
|
96
|
+
!e.compact && e.trendValue !== null ? (r(), d(k, v(V({ key: 0 }, t(y))), null, 16)) : i("", !0)
|
|
73
97
|
]),
|
|
74
|
-
e.compact && e.trendValue !== null ? (r(),
|
|
75
|
-
key: 0,
|
|
76
|
-
value: e.trendValue,
|
|
77
|
-
direction: e.trendDirection
|
|
78
|
-
}, null, 8, ["value", "direction"])) : u("", !0)
|
|
98
|
+
e.compact && e.trendValue !== null ? (r(), d(k, v(V({ key: 0 }, t(y))), null, 16)) : i("", !0)
|
|
79
99
|
]),
|
|
80
|
-
e.typeSwitcher ? (r(),
|
|
100
|
+
e.typeSwitcher ? (r(), d(t(z), {
|
|
81
101
|
key: 0,
|
|
82
|
-
modelValue:
|
|
83
|
-
"onUpdate:modelValue":
|
|
84
|
-
options:
|
|
85
|
-
}, null, 8, ["modelValue"])) :
|
|
102
|
+
modelValue: t(p),
|
|
103
|
+
"onUpdate:modelValue": b[0] || (b[0] = (w) => P(p) ? p.value = w : null),
|
|
104
|
+
options: T
|
|
105
|
+
}, null, 8, ["modelValue"])) : i("", !0)
|
|
86
106
|
], 2));
|
|
87
107
|
}
|
|
88
108
|
});
|
|
89
109
|
export {
|
|
90
|
-
|
|
110
|
+
I as default
|
|
91
111
|
};
|
|
@@ -1,18 +1,31 @@
|
|
|
1
1
|
declare const _default: import("vue").DefineComponent<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<{
|
|
2
2
|
value?: number | string;
|
|
3
3
|
direction?: 'up' | 'down';
|
|
4
|
+
trendTooltip?: {
|
|
5
|
+
header?: string;
|
|
6
|
+
rangeCurrent?: string;
|
|
7
|
+
rangePrevious?: string;
|
|
8
|
+
};
|
|
4
9
|
}>, {
|
|
5
10
|
value: any;
|
|
6
11
|
direction: string;
|
|
12
|
+
trendTooltip: any;
|
|
7
13
|
}>, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<{
|
|
8
14
|
value?: number | string;
|
|
9
15
|
direction?: 'up' | 'down';
|
|
16
|
+
trendTooltip?: {
|
|
17
|
+
header?: string;
|
|
18
|
+
rangeCurrent?: string;
|
|
19
|
+
rangePrevious?: string;
|
|
20
|
+
};
|
|
10
21
|
}>, {
|
|
11
22
|
value: any;
|
|
12
23
|
direction: string;
|
|
24
|
+
trendTooltip: any;
|
|
13
25
|
}>>>, {
|
|
14
26
|
value: number | string;
|
|
15
27
|
direction: 'up' | 'down';
|
|
28
|
+
trendTooltip: any;
|
|
16
29
|
}>;
|
|
17
30
|
export default _default;
|
|
18
31
|
type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import e from "./ChartHeaderTrend.vue2.js";
|
|
2
2
|
/* empty css */import o from "../../_virtual/_plugin-vue_export-helper.js";
|
|
3
|
-
// import "../../ChartHeaderTrend.
|
|
4
|
-
const s = /* @__PURE__ */ o(e, [["__scopeId", "data-v-
|
|
3
|
+
// import "../../ChartHeaderTrend.vue_vue_type_style_index_0_scoped_21ce0774_lang.css"; //*');
|
|
4
|
+
const s = /* @__PURE__ */ o(e, [["__scopeId", "data-v-21ce0774"]]);
|
|
5
5
|
export {
|
|
6
6
|
s as default
|
|
7
7
|
};
|