@ironsource/shared-ui 2.1.12-rc.25 → 2.1.12-rc.27

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 (93) hide show
  1. package/ButtonDropdownTrigger.vue_vue_type_style_index_0_scoped_adb49e50_lang.css +1 -0
  2. package/ButtonV4.vue_vue_type_style_index_0_scoped_852be7ec_lang.css +1 -0
  3. package/Chart.vue_vue_type_style_index_0_scoped_e8f25a03_lang.css +1 -0
  4. package/ChartHeader.vue_vue_type_style_index_0_scoped_af520313_lang.css +1 -0
  5. package/ChartHeaderTrend.vue_vue_type_style_index_0_scoped_db8a902c_lang.css +1 -0
  6. package/ChartLegend.vue_vue_type_style_index_0_scoped_6103d8bd_lang.css +1 -0
  7. package/ChartPlane.vue_vue_type_style_index_0_scoped_4f67d41d_lang.css +1 -0
  8. package/ChartTooltip.vue_vue_type_style_index_0_scoped_3315b68f_lang.css +1 -0
  9. package/ConditionalDropdown.vue_vue_type_style_index_0_scoped_f5204c04_lang.css +1 -0
  10. package/DataGrid.vue_vue_type_style_index_0_scoped_b21a79b1_lang.css +1 -0
  11. package/DropdownV4.vue_vue_type_style_index_0_scoped_55dd36a7_lang.css +1 -0
  12. package/Link.vue_vue_type_style_index_0_scoped_ad98fe7b_lang.css +1 -0
  13. package/OptionV4.vue_vue_type_style_index_0_scoped_0287cebf_lang.css +1 -0
  14. package/SwitchV4.vue_vue_type_style_index_0_scoped_cd6621a7_lang.css +1 -0
  15. package/components/button/v4/ButtonV4.vue.d.ts +1 -0
  16. package/components/button/v4/ButtonV4.vue.js +3 -3
  17. package/components/button/v4/ButtonV4.vue2.js +28 -27
  18. package/components/chart/Chart.vue.d.ts +6 -1
  19. package/components/chart/Chart.vue.js +3 -3
  20. package/components/chart/Chart.vue2.js +6 -4
  21. package/components/chart/ChartHeader.vue.d.ts +5 -0
  22. package/components/chart/ChartHeader.vue.js +2 -2
  23. package/components/chart/ChartHeader.vue2.js +43 -35
  24. package/components/chart/ChartHeaderTrend.vue.js +3 -3
  25. package/components/chart/ChartHeaderTrend.vue2.js +17 -17
  26. package/components/chart/ChartLegend.vue.js +3 -3
  27. package/components/chart/ChartLegend.vue2.js +1 -1
  28. package/components/chart/ChartPlane.vue.d.ts +6 -1
  29. package/components/chart/ChartPlane.vue.js +5 -5
  30. package/components/chart/ChartPlane.vue2.js +140 -138
  31. package/components/chart/ChartTooltip.vue.js +2 -2
  32. package/components/chart/ChartTooltip.vue2.js +5 -5
  33. package/components/chart/index.d.ts +43 -24
  34. package/components/chart/utils/utils.d.ts +1 -2
  35. package/components/chart/utils/utils.js +13 -19
  36. package/components/dateRange/common/DateRange.common.js +81 -75
  37. package/components/dateRange/common/DateServices.common.d.ts +1 -1
  38. package/components/dateRange/common/DateServices.common.js +1 -0
  39. package/components/dropdown/common/Dropdown.common.js +82 -78
  40. package/components/dropdown/v4/ButtonDropdownTrigger.vue.d.ts +1 -0
  41. package/components/dropdown/v4/ButtonDropdownTrigger.vue.js +3 -3
  42. package/components/dropdown/v4/ButtonDropdownTrigger.vue2.js +16 -13
  43. package/components/dropdown/v4/ConditionalDropdown.vue.d.ts +17 -9
  44. package/components/dropdown/v4/ConditionalDropdown.vue.js +4 -4
  45. package/components/dropdown/v4/ConditionalDropdown.vue2.js +142 -123
  46. package/components/dropdown/v4/DropdownV4.vue.d.ts +10 -0
  47. package/components/dropdown/v4/DropdownV4.vue.js +4 -4
  48. package/components/dropdown/v4/DropdownV4.vue2.js +174 -163
  49. package/components/dropdown/v4/OptionV4.vue.d.ts +10 -5
  50. package/components/dropdown/v4/OptionV4.vue.js +4 -4
  51. package/components/dropdown/v4/OptionV4.vue2.js +106 -99
  52. package/components/dropdown/v4/dropdownStoryArgs.d.ts +8 -0
  53. package/components/dropdown/v4/index.d.ts +510 -127
  54. package/components/includeExclude/IncludeExclude.vue.d.ts +1 -1
  55. package/components/includeExclude/IncludeExcludeDragDrop.vue.d.ts +1 -1
  56. package/components/includeExclude/index.d.ts +40 -40
  57. package/components/link/Link.vue.d.ts +70 -0
  58. package/components/link/Link.vue.js +7 -0
  59. package/components/link/Link.vue2.js +43 -0
  60. package/components/link/index.d.ts +201 -0
  61. package/components/link/index.js +6 -0
  62. package/components/switch/v4/SwitchV4.vue.d.ts +11 -0
  63. package/components/switch/v4/SwitchV4.vue.js +2 -2
  64. package/components/switch/v4/SwitchV4.vue2.js +39 -26
  65. package/components/switch/v4/index.d.ts +18 -0
  66. package/components/table/v4/DataGrid.vue.d.ts +2 -0
  67. package/components/table/v4/DataGrid.vue.js +3 -3
  68. package/components/table/v4/DataGrid.vue2.js +111 -110
  69. package/components/table/v4/index.d.ts +2 -0
  70. package/composables/useDateService.d.ts +7 -0
  71. package/composables/useDateService.js +10 -0
  72. package/index.d.ts +1120 -310
  73. package/index.js +111 -105
  74. package/mocks/apps.d.ts +1 -0
  75. package/mocks/optionsWithIcons.d.ts +2 -0
  76. package/package.json +9 -1
  77. package/testids/index.d.ts +4 -0
  78. package/testids/index.js +31 -30
  79. package/ButtonDropdownTrigger.vue_vue_type_style_index_0_scoped_0123c361_lang.css +0 -1
  80. package/ButtonV4.vue_vue_type_style_index_0_scoped_d7948c77_lang.css +0 -1
  81. package/Chart.vue_vue_type_style_index_0_scoped_03771fa3_lang.css +0 -1
  82. package/ChartHeader.vue_vue_type_style_index_0_scoped_da34b108_lang.css +0 -1
  83. package/ChartHeaderTrend.vue_vue_type_style_index_0_scoped_ebc0c582_lang.css +0 -1
  84. package/ChartLegend.vue_vue_type_style_index_0_scoped_fd9e4ea2_lang.css +0 -1
  85. package/ChartPlane.vue_vue_type_style_index_0_scoped_903fc6ae_lang.css +0 -1
  86. package/ChartTooltip.vue_vue_type_style_index_0_scoped_e53c6287_lang.css +0 -1
  87. package/ConditionalDropdown.vue_vue_type_style_index_0_scoped_cce87267_lang.css +0 -1
  88. package/DataGrid.vue_vue_type_style_index_0_scoped_5b72e35a_lang.css +0 -1
  89. package/DropdownV4.vue_vue_type_style_index_0_scoped_92ead583_lang.css +0 -1
  90. package/OptionV4.vue_vue_type_style_index_0_scoped_3dc741c1_lang.css +0 -1
  91. package/SwitchV4.vue_vue_type_style_index_0_scoped_fa120cf6_lang.css +0 -1
  92. package/components/chart/composables/useChartValues.d.ts +0 -12
  93. package/components/chart/composables/useChartValues.js +0 -32
@@ -1,4 +1,4 @@
1
- import "../../ChartLegend.vue_vue_type_style_index_0_scoped_fd9e4ea2_lang.css"; import { defineComponent as F, ref as H, computed as v, openBlock as s, createElementBlock as u, createElementVNode as r, createVNode as c, unref as o, createBlock as g, isRef as R, createCommentVNode as x, mergeProps as T, withCtx as p, createTextVNode as I, Fragment as $, renderList as z, normalizeClass as K, withModifiers as q, toDisplayString as V } from "vue";
1
+ import "../../ChartLegend.vue_vue_type_style_index_0_scoped_6103d8bd_lang.css"; import { defineComponent as F, ref as H, computed as v, openBlock as s, createElementBlock as u, createElementVNode as r, createVNode as c, unref as o, createBlock as g, isRef as R, createCommentVNode as x, mergeProps as T, withCtx as p, createTextVNode as I, Fragment as $, renderList as z, normalizeClass as K, withModifiers as q, toDisplayString as V } from "vue";
2
2
  import { useVModel as C, useVirtualList as G } from "@vueuse/core";
3
3
  import k from "../typography/v4/Typography.vue.js";
4
4
  import X from "../checkbox/v4/CheckboxV4.vue.js";
@@ -27,6 +27,7 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<__
27
27
  typeSwitcher?: boolean;
28
28
  height?: string;
29
29
  compactHeader?: boolean;
30
+ noteText?: string;
30
31
  tooltipRespectsTopEdge?: boolean;
31
32
  tooltipTotalType?: TotalType;
32
33
  tooltipTotalCalcFn?: (values: number[], totalType: TotalType) => number;
@@ -66,6 +67,7 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<__
66
67
  typeSwitcher: boolean;
67
68
  height: string;
68
69
  compactHeader: boolean;
70
+ noteText: string;
69
71
  tooltipRespectsTopEdge: boolean;
70
72
  tooltipTotalType: TotalType;
71
73
  tooltipTotalCalcFn: (values: number[], totalType: TotalType) => number;
@@ -106,6 +108,7 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<__
106
108
  typeSwitcher?: boolean;
107
109
  height?: string;
108
110
  compactHeader?: boolean;
111
+ noteText?: string;
109
112
  tooltipRespectsTopEdge?: boolean;
110
113
  tooltipTotalType?: TotalType;
111
114
  tooltipTotalCalcFn?: (values: number[], totalType: TotalType) => number;
@@ -145,6 +148,7 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<__
145
148
  typeSwitcher: boolean;
146
149
  height: string;
147
150
  compactHeader: boolean;
151
+ noteText: string;
148
152
  tooltipRespectsTopEdge: boolean;
149
153
  tooltipTotalType: TotalType;
150
154
  tooltipTotalCalcFn: (values: number[], totalType: TotalType) => number;
@@ -172,13 +176,14 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<__
172
176
  yAxisFormat: ValueFormat;
173
177
  valueSuffix: string;
174
178
  valuePrefix: string;
175
- dataSets: ChartDataSet[];
176
179
  trendTooltip: any;
177
180
  subheader: string;
178
181
  subheaderTooltip: any;
179
182
  typeSwitcher: boolean;
180
183
  trendValue: string | number;
181
184
  trendDirection: TrendDirection;
185
+ noteText: string;
186
+ dataSets: ChartDataSet[];
182
187
  tickCount: number;
183
188
  truncateTickLabels: boolean;
184
189
  keepSubheaderVisible: boolean;
@@ -1,7 +1,7 @@
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_903fc6ae_lang.css"; //*');
4
- const s = /* @__PURE__ */ o(e, [["__scopeId", "data-v-903fc6ae"]]);
1
+ import o from "./ChartPlane.vue2.js";
2
+ /* empty css */import e from "../../_virtual/_plugin-vue_export-helper.js";
3
+ // import "../../ChartPlane.vue_vue_type_style_index_0_scoped_4f67d41d_lang.css"; //*');
4
+ const a = /* @__PURE__ */ e(o, [["__scopeId", "data-v-4f67d41d"]]);
5
5
  export {
6
- s as default
6
+ a as default
7
7
  };
@@ -1,28 +1,27 @@
1
- import "../../ChartPlane.vue_vue_type_style_index_0_scoped_903fc6ae_lang.css"; import { defineComponent as re, useCssVars as ie, unref as s, computed as l, ref as k, onMounted as ne, watch as T, nextTick as se, openBlock as f, createElementBlock as S, createVNode as ue, isRef as ce, createSlots as de, withCtx as pe, renderSlot as fe, createCommentVNode as A, createElementVNode as L, normalizeStyle as he, createBlock as E } from "vue";
2
- import { Chart as N, ArcElement as me, LineElement as ve, 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
- import { HoverVerticalLine as Ee } from "./plugins/HoverVerticalLine.js";
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 F, BASE_COLOR_KEY as K, CHART_PADDING as Ie, POINT_BORDER_COLOR as He, TICK_LABEL_COLOR as M, TICK_LABEL_FONT as U, TICKS_EXTRA_PADDING as Ve, GRID_LINE_COLOR as z, HEADER_HEIGHT as we, COMPACT_HEADER_HEIGHT as Pe, HOVER_AREA_TRANSPARENCY as Ne, HOVER_TRANSPARENCY as C } from "./consts.js";
6
- import { ChartType as u, DateInterval as Fe, TooltipOrder as Y, TrendDirection as Ke } from "./types.js";
7
- import { useTooltipPosition as Me } from "./composables/useTooltipPosition.js";
8
- import Ue from "./ChartTooltip.vue.js";
1
+ import "../../ChartPlane.vue_vue_type_style_index_0_scoped_4f67d41d_lang.css"; import { defineComponent as ae, useCssVars as oe, unref as s, computed as l, ref as k, onMounted as le, watch as v, nextTick as re, openBlock as p, createElementBlock as A, createVNode as ie, isRef as ne, createSlots as se, withCtx as ue, renderSlot as de, createCommentVNode as S, createElementVNode as L, normalizeStyle as ce, createBlock as E } from "vue";
2
+ import { Chart as P, ArcElement as fe, LineElement as pe, BarElement as he, PointElement as me, LineController as ve, BarController as ye, PieController as Te, ScatterController as Ce, CategoryScale as be, LinearScale as ge, Filler as xe, Tooltip as ke } from "chart.js";
3
+ import { HoverVerticalLine as Ae } from "./plugins/HoverVerticalLine.js";
4
+ import { prepareTickLabel as Se, formatValue as Le } from "./utils/utils.js";
5
+ import { DEFAULT_TICK_COUNT as Ee, TOTALS_HELPER_KEY as w, BASE_COLOR_KEY as V, CHART_PADDING as Re, POINT_BORDER_COLOR as Be, TICK_LABEL_COLOR as N, TICK_LABEL_FONT as F, TICKS_EXTRA_PADDING as De, GRID_LINE_COLOR as K, HEADER_HEIGHT as Oe, COMPACT_HEADER_HEIGHT as Ie, HOVER_AREA_TRANSPARENCY as He, HOVER_TRANSPARENCY as y } from "./consts.js";
6
+ import { ChartType as u, DateInterval as Pe, TooltipOrder as M, TrendDirection as we } from "./types.js";
7
+ import { useTooltipPosition as Ve } from "./composables/useTooltipPosition.js";
8
+ import Ne from "./ChartTooltip.vue.js";
9
9
  import { hexColorToRgba as h } from "../../utils/color.js";
10
- import { useChartValues as ze } from "./composables/useChartValues.js";
11
- import Ye from "./ChartHeader.vue.js";
12
- import { useMemoize as _e, useVModel as Ge } from "@vueuse/core";
13
- import $e from "../emptyState/v4/EmptyStateV4.vue.js";
14
- import We from "./ChartLoader.vue.js";
15
- import { DEFAULT_CHART_COLOR as Ze } from "./colorPalette.js";
16
- import { TotalType as _, calculateTotal as Xe } from "../../utils/totals.js";
17
- import { isNullOrUndefined as je } from "../../utils/utils.js";
18
- import { storeOriginalDatasetColors as qe, restoreOriginalDatasetColors as Je } from "./utils/highlightUtils.js";
19
- const Qe = { class: "chart-plane-container" }, et = {
10
+ import Fe from "./ChartHeader.vue.js";
11
+ import { useMemoize as Ke, useVModel as Me } from "@vueuse/core";
12
+ import Ue from "../emptyState/v4/EmptyStateV4.vue.js";
13
+ import Ye from "./ChartLoader.vue.js";
14
+ import { DEFAULT_CHART_COLOR as Ge } from "./colorPalette.js";
15
+ import { TotalType as U, calculateTotal as _e } from "../../utils/totals.js";
16
+ import { isNullOrUndefined as $e } from "../../utils/utils.js";
17
+ import { storeOriginalDatasetColors as ze, restoreOriginalDatasetColors as We } from "./utils/highlightUtils.js";
18
+ const Ze = { class: "chart-plane-container" }, Xe = {
20
19
  key: 0,
21
20
  class: "header-wrapper"
22
- }, tt = {
21
+ }, je = {
23
22
  key: 1,
24
23
  class: "chart-plane"
25
- }, at = { class: "chart" }, gt = /* @__PURE__ */ re({
24
+ }, qe = { class: "chart" }, mt = /* @__PURE__ */ ae({
26
25
  __name: "ChartPlane",
27
26
  props: {
28
27
  dataSets: { default: () => [] },
@@ -32,8 +31,8 @@ const Qe = { class: "chart-plane-container" }, et = {
32
31
  parsing: { default: void 0 },
33
32
  xAxisFormat: { default: "string" },
34
33
  yAxisFormat: { default: "number" },
35
- xAxisDateInterval: { default: Fe.DAILY },
36
- tickCount: { default: Oe },
34
+ xAxisDateInterval: { default: Pe.DAILY },
35
+ tickCount: { default: Ee },
37
36
  truncateTickLabels: { type: Boolean, default: !1 },
38
37
  header: { default: "" },
39
38
  subheader: { default: "" },
@@ -48,12 +47,13 @@ const Qe = { class: "chart-plane-container" }, et = {
48
47
  typeSwitcher: { type: Boolean, default: !0 },
49
48
  height: { default: "100%" },
50
49
  compactHeader: { type: Boolean, default: !1 },
50
+ noteText: { default: "" },
51
51
  tooltipRespectsTopEdge: { type: Boolean, default: !0 },
52
- tooltipTotalType: { default: _.Total },
53
- tooltipTotalCalcFn: { type: Function, default: Xe },
54
- tooltipOrder: { default: Y.Legend },
52
+ tooltipTotalType: { default: U.Total },
53
+ tooltipTotalCalcFn: { type: Function, default: _e },
54
+ tooltipOrder: { default: M.Legend },
55
55
  trendValue: { default: null },
56
- trendDirection: { default: Ke.UP },
56
+ trendDirection: { default: we.UP },
57
57
  trendTooltip: { default: null },
58
58
  totalsChart: { type: Boolean, default: !1 },
59
59
  colorsMap: { default: () => ({}) },
@@ -61,14 +61,17 @@ const Qe = { class: "chart-plane-container" }, et = {
61
61
  valuePrefix: { default: "" }
62
62
  },
63
63
  emits: ["update:chartType"],
64
- setup(o, { emit: G }) {
64
+ setup(o, { emit: Y }) {
65
65
  const e = o;
66
- ie((t) => ({
67
- d271311a: s(ee),
68
- "6c5bc85e": o.height
66
+ oe((t) => ({
67
+ "11153e48": s(q),
68
+ 30644433: o.height
69
69
  }));
70
- const $ = _e(Re);
71
- N.register(
70
+ const G = Ke(Se);
71
+ P.register(
72
+ fe,
73
+ pe,
74
+ he,
72
75
  me,
73
76
  ve,
74
77
  ye,
@@ -78,41 +81,46 @@ const Qe = { class: "chart-plane-container" }, et = {
78
81
  ge,
79
82
  xe,
80
83
  ke,
81
- Se,
82
- Ae,
83
- Le,
84
- Ee
84
+ Ae
85
85
  );
86
- const b = Ge(e, "chartType", G), W = l(
86
+ const T = Me(e, "chartType", Y), _ = l(
87
87
  () => e.withAnimation ? "" : "none"
88
88
  ), m = k(null);
89
89
  let n = null;
90
- const R = l(() => e.empty || e.dataSets.length === 0), d = l(() => !e.loading && !R.value), g = () => {
91
- m.value && (n && n.destroy(), n = new N(m.value, I.value));
92
- }, Z = () => {
93
- n && (n.data.datasets = O.value, n.options = I.value.options, n.update(W.value));
90
+ const R = l(() => e.empty || e.dataSets.length === 0), c = l(() => !e.loading && !R.value), C = () => {
91
+ m.value && (n && n.destroy(), n = new P(m.value, O.value));
92
+ }, $ = () => {
93
+ n && (n.data.datasets = D.value, n.options = O.value.options, n.update(_.value));
94
94
  };
95
- ne(g), T(() => e.chartType, g), T(d, async (t) => {
96
- t && (await se(), g());
97
- }), T([() => e.visibleIds, () => e.dataSets], Z);
98
- const p = l(() => e.totalsChart), v = l(
99
- () => e.chartType === u.StackedLine || e.chartType === u.StackedBar || p.value
100
- ), x = l(
95
+ le(C), v(() => e.chartType, C), v(c, async (t) => {
96
+ t && (await re(), C());
97
+ }), v(
98
+ [
99
+ () => e.visibleIds,
100
+ () => e.dataSets,
101
+ () => e.valuePrefix,
102
+ () => e.valueSuffix
103
+ ],
104
+ $
105
+ );
106
+ const f = l(() => e.totalsChart), b = l(
107
+ () => e.chartType === u.StackedLine || e.chartType === u.StackedBar || f.value
108
+ ), g = l(
101
109
  () => e.chartType === u.Line || e.chartType === u.StackedLine
102
- ), B = l(() => p.value && !e.parsing.xAxisKey ? { ...e.parsing, xAxisKey: F } : e.parsing), X = l(() => p.value ? e.dataSets.map((t) => ({
110
+ ), z = l(() => f.value && !e.parsing.xAxisKey ? { ...e.parsing, xAxisKey: w } : e.parsing), W = l(() => f.value ? e.dataSets.map((t) => ({
103
111
  ...t,
104
112
  data: t.data.map((i) => ({
105
113
  ...i,
106
- [F]: t.label
114
+ [w]: t.label
107
115
  }))
108
- })) : e.dataSets), y = l(
109
- () => X.value.filter((t) => e.visibleIds.includes(t.id))
110
- ), j = (t) => e.colorsMap[t] || Ze, D = l(
111
- () => y.value.length && y.value.every(
116
+ })) : e.dataSets), x = l(
117
+ () => W.value.filter((t) => e.visibleIds.includes(t.id))
118
+ ), Z = (t) => e.colorsMap[t] || Ge, B = l(
119
+ () => x.value.length && x.value.every(
112
120
  (t) => t.data.length === 1
113
121
  )
114
- ), O = l(() => y.value.map((t, i) => {
115
- const a = j(t.id), r = v.value ? i !== 0 ? "-1" : "start" : void 0;
122
+ ), D = l(() => x.value.map((t, i) => {
123
+ const a = Z(t.id), r = b.value ? i !== 0 ? "-1" : "start" : void 0;
116
124
  return {
117
125
  ...t,
118
126
  fill: r,
@@ -128,36 +136,36 @@ const Qe = { class: "chart-plane-container" }, et = {
128
136
  // draw a bit outside the chart area
129
137
  icon: t.icon || null,
130
138
  iconType: t.iconType || "branded",
131
- [K]: a
139
+ [V]: a
132
140
  // store base color for later use
133
141
  };
134
- })), q = l(
135
- () => e.tooltipTotalType === _.Total ? "Total" : "Mean"
136
- ), I = l(() => ({
142
+ })), X = l(
143
+ () => e.tooltipTotalType === U.Total ? "Total" : "Mean"
144
+ ), O = l(() => ({
137
145
  type: e.chartType == u.Bar || e.chartType === u.StackedBar ? "bar" : "line",
138
146
  // Chart Data
139
147
  data: {
140
- datasets: O.value
148
+ datasets: D.value
141
149
  },
142
150
  // Chart Options
143
151
  options: {
144
- parsing: B.value,
152
+ parsing: z.value,
145
153
  interaction: {
146
154
  intersect: !1,
147
- mode: p.value ? "point" : "index",
155
+ mode: f.value ? "point" : "index",
148
156
  axis: "x"
149
157
  },
150
158
  // plugins
151
159
  plugins: {
152
160
  legend: { display: !1 },
153
161
  title: { display: !1 },
154
- hoverVerticalLine: x.value,
162
+ hoverVerticalLine: g.value,
155
163
  // tooltip
156
164
  tooltip: {
157
165
  enabled: !1,
158
166
  position: "average",
159
167
  external: ({ tooltip: t }) => {
160
- c.value = { ...t };
168
+ d.value = { ...t };
161
169
  },
162
170
  callbacks: {
163
171
  footer: (t) => {
@@ -165,11 +173,11 @@ const Qe = { class: "chart-plane-container" }, et = {
165
173
  i,
166
174
  e.tooltipTotalType
167
175
  );
168
- return [q.value, String(a)];
176
+ return [X.value, String(a)];
169
177
  }
170
178
  },
171
179
  itemSort: (t, i) => {
172
- if (e.tooltipOrder === Y.YAxis) {
180
+ if (e.tooltipOrder === M.YAxis) {
173
181
  const a = t.parsed.y || 0, r = i.parsed.y || 0;
174
182
  return a === r ? 0 : a > r ? -1 : 1;
175
183
  }
@@ -181,7 +189,7 @@ const Qe = { class: "chart-plane-container" }, et = {
181
189
  responsive: !0,
182
190
  maintainAspectRatio: !1,
183
191
  layout: {
184
- padding: Ie
192
+ padding: Re
185
193
  },
186
194
  // basic styles
187
195
  elements: {
@@ -190,12 +198,12 @@ const Qe = { class: "chart-plane-container" }, et = {
190
198
  tension: 0.3
191
199
  },
192
200
  point: {
193
- radius: D.value ? 3 : 1,
201
+ radius: B.value ? 3 : 1,
194
202
  hitRadius: 8,
195
203
  borderWidth: 0,
196
204
  hoverRadius: 4,
197
205
  hoverBorderWidth: 2,
198
- pointHoverBackgroundColor: He
206
+ pointHoverBackgroundColor: Be
199
207
  },
200
208
  bar: {
201
209
  borderRadius: 4
@@ -205,31 +213,31 @@ const Qe = { class: "chart-plane-container" }, et = {
205
213
  // Horizontal Axis (X)
206
214
  x: {
207
215
  beginAtZero: !0,
208
- offset: !x.value || D.value,
216
+ offset: !g.value || B.value,
209
217
  border: { display: !1 },
210
- stacked: v.value,
218
+ stacked: b.value,
211
219
  // stack on top of each other
212
220
  // ticks
213
221
  ticks: {
214
- color: M,
215
- font: U,
222
+ color: N,
223
+ font: F,
216
224
  padding: 4,
217
225
  maxRotation: 0,
218
226
  autoSkip: !e.truncateTickLabels,
219
227
  autoSkipPadding: 8,
220
228
  callback: function(t, i, a) {
221
- const r = this.getLabelForValue(t), oe = x.value && !p.value ? a.length - 1 : a.length, le = this.chart.scales?.x?.width / oe - Ve;
222
- return $({
229
+ const r = this.getLabelForValue(t), ee = g.value && !f.value ? a.length - 1 : a.length, te = this.chart.scales?.x?.width / ee - De;
230
+ return G({
223
231
  label: r,
224
232
  format: e.xAxisFormat,
225
- availableSpace: le,
233
+ availableSpace: te,
226
234
  truncate: e.truncateTickLabels
227
235
  });
228
236
  }
229
237
  },
230
238
  // grid lines
231
239
  grid: {
232
- color: z,
240
+ color: K,
233
241
  drawOnChartArea: !1,
234
242
  drawTicks: !0,
235
243
  drawBorder: !1,
@@ -241,88 +249,82 @@ const Qe = { class: "chart-plane-container" }, et = {
241
249
  beginAtZero: !0,
242
250
  border: { display: !1 },
243
251
  // hide left borderline
244
- stacked: v.value,
252
+ stacked: b.value,
245
253
  // stack on top of each other
246
254
  // ticks
247
255
  ticks: {
248
- color: M,
249
- font: U,
256
+ color: N,
257
+ font: F,
258
+ count: e.tickCount + 1,
250
259
  padding: 8,
251
- stepSize: P.value,
252
- min: w.value,
253
- max: P.value * e.tickCount,
254
- callback: (t) => Be(t, e.yAxisFormat)
260
+ min: 0,
261
+ callback: (t) => e.valuePrefix + Le(t, e.yAxisFormat) + e.valueSuffix
255
262
  },
256
263
  // grid lines
257
264
  grid: {
258
- color: z,
265
+ color: K,
259
266
  drawOnChartArea: !0,
260
267
  drawTicks: !1
261
268
  }
262
269
  }
263
270
  }
264
271
  }
265
- })), H = k(null), c = k(null), { position: V } = Me(
272
+ })), I = k(null), d = k(null), { position: H } = Ve(
266
273
  m,
267
- H,
268
- c,
274
+ I,
275
+ d,
269
276
  e.tooltipRespectsTopEdge
270
- ), J = l(() => ({
271
- left: `${V.value.left}px`,
272
- top: `${V.value.top}px`,
273
- opacity: c.value?.opacity || 0
274
- })), { minValue: w, maxValue: Q } = ze({
275
- parsingConfig: B.value,
276
- dataSets: y,
277
- isStacked: v
278
- }), P = l(
279
- () => De(w.value, Q.value, e.tickCount)
280
- ), ee = l(
281
- () => (e.compactHeader ? Pe : we) + "px"
277
+ ), j = l(() => ({
278
+ left: `${H.value.left}px`,
279
+ top: `${H.value.top}px`,
280
+ opacity: d.value?.opacity || 0
281
+ })), q = l(
282
+ () => (e.compactHeader ? Ie : Oe) + "px"
282
283
  );
283
- T(
284
+ v(
284
285
  () => e.highlightedId,
285
286
  (t) => {
286
- n && (je(t) ? ae() : te(t), n.update());
287
+ n && ($e(t) ? Q() : J(t), n.update());
287
288
  }
288
289
  );
289
- const te = (t) => {
290
+ const J = (t) => {
290
291
  (n?.data.datasets || []).forEach((a) => {
291
- qe(a);
292
- const r = a[K];
292
+ ze(a);
293
+ const r = a[V];
293
294
  a.id === t ? e.chartType === u.StackedLine && (a.backgroundColor = h(
294
295
  r,
295
- Ne
296
- )) : (a.backgroundColor = h(r, C), a.borderColor = h(r, C), a.pointBackgroundColor = h(r, C), a.pointHoverBorderColor = h(r, C));
296
+ He
297
+ )) : (a.backgroundColor = h(r, y), a.borderColor = h(r, y), a.pointBackgroundColor = h(r, y), a.pointHoverBorderColor = h(r, y));
297
298
  });
298
- }, ae = () => {
299
- (n?.data.datasets || []).forEach(Je);
299
+ }, Q = () => {
300
+ (n?.data.datasets || []).forEach(We);
300
301
  };
301
- return (t, i) => (f(), S("div", Qe, [
302
- s(d) || o.keepSubheaderVisible ? (f(), S("div", et, [
303
- ue(Ye, {
304
- "chart-type": s(b),
305
- "onUpdate:chart-type": i[0] || (i[0] = (a) => ce(b) ? b.value = a : null),
306
- "type-switcher": s(d) ? o.typeSwitcher : !1,
307
- header: s(d) ? o.header : null,
302
+ return (t, i) => (p(), A("div", Ze, [
303
+ s(c) || o.keepSubheaderVisible ? (p(), A("div", Xe, [
304
+ ie(Fe, {
305
+ "chart-type": s(T),
306
+ "onUpdate:chart-type": i[0] || (i[0] = (a) => ne(T) ? T.value = a : null),
307
+ "type-switcher": s(c) ? o.typeSwitcher : !1,
308
+ header: s(c) ? o.header : null,
308
309
  subheader: o.subheader,
309
310
  "subheader-tooltip": o.subheaderTooltip,
310
311
  "trend-tooltip": o.trendTooltip,
311
312
  compact: o.compactHeader,
312
- "trend-value": s(d) ? o.trendValue : null,
313
- "trend-direction": o.trendDirection
314
- }, de({ _: 2 }, [
313
+ "trend-value": s(c) ? o.trendValue : null,
314
+ "trend-direction": o.trendDirection,
315
+ "note-text": o.noteText
316
+ }, se({ _: 2 }, [
315
317
  t.$slots["subheader-tooltip"] ? {
316
318
  name: "subheader-tooltip",
317
- fn: pe(() => [
318
- fe(t.$slots, "subheader-tooltip", {}, void 0, !0)
319
+ fn: ue(() => [
320
+ de(t.$slots, "subheader-tooltip", {}, void 0, !0)
319
321
  ]),
320
322
  key: "0"
321
323
  } : void 0
322
- ]), 1032, ["chart-type", "type-switcher", "header", "subheader", "subheader-tooltip", "trend-tooltip", "compact", "trend-value", "trend-direction"])
323
- ])) : A("", !0),
324
- s(d) ? (f(), S("section", tt, [
325
- L("div", at, [
324
+ ]), 1032, ["chart-type", "type-switcher", "header", "subheader", "subheader-tooltip", "trend-tooltip", "compact", "trend-value", "trend-direction", "note-text"])
325
+ ])) : S("", !0),
326
+ s(c) ? (p(), A("section", je, [
327
+ L("div", qe, [
326
328
  L("canvas", {
327
329
  ref_key: "chartRef",
328
330
  ref: m,
@@ -330,39 +332,39 @@ const Qe = { class: "chart-plane-container" }, et = {
330
332
  }, null, 512),
331
333
  L("div", {
332
334
  ref_key: "tooltipRef",
333
- ref: H,
335
+ ref: I,
334
336
  class: "chart__tooltip",
335
- style: he(s(J))
337
+ style: ce(s(j))
336
338
  }, [
337
- c.value ? (f(), E(Ue, {
339
+ d.value ? (p(), E(Ne, {
338
340
  key: 0,
339
- "totals-chart": s(p),
340
- title: String(c.value.title),
341
- "data-points": c.value.dataPoints,
341
+ "totals-chart": s(f),
342
+ title: String(d.value.title),
343
+ "data-points": d.value.dataPoints,
342
344
  "x-axis-format": o.xAxisFormat,
343
345
  "y-axis-format": o.yAxisFormat,
344
346
  "x-axis-date-interval": o.xAxisDateInterval,
345
- "total-label": c.value.footer?.[0],
346
- "total-value": Number(c.value.footer?.[1]),
347
+ "total-label": d.value.footer?.[0],
348
+ "total-value": Number(d.value.footer?.[1]),
347
349
  "value-suffix": o.valueSuffix,
348
350
  "value-prefix": o.valuePrefix
349
- }, 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"])) : A("", !0)
351
+ }, 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"])) : S("", !0)
350
352
  ], 4)
351
353
  ])
352
- ])) : o.loading ? (f(), E(We, {
354
+ ])) : o.loading ? (p(), E(Ye, {
353
355
  key: 2,
354
356
  class: "chart-loading"
355
- })) : s(R) ? (f(), E(s($e), {
357
+ })) : s(R) ? (p(), E(s(Ue), {
356
358
  key: 3,
357
359
  class: "chart-empty",
358
360
  variant: null,
359
361
  title: o.noDataTitle,
360
362
  subtitle: o.noDataSubtitle,
361
363
  "icon-name": o.noDataIcon
362
- }, null, 8, ["title", "subtitle", "icon-name"])) : A("", !0)
364
+ }, null, 8, ["title", "subtitle", "icon-name"])) : S("", !0)
363
365
  ]));
364
366
  }
365
367
  });
366
368
  export {
367
- gt as default
369
+ mt as default
368
370
  };
@@ -1,7 +1,7 @@
1
1
  import o from "./ChartTooltip.vue2.js";
2
2
  /* empty css */import t from "../../_virtual/_plugin-vue_export-helper.js";
3
- // import "../../ChartTooltip.vue_vue_type_style_index_0_scoped_e53c6287_lang.css"; //*');
4
- const s = /* @__PURE__ */ t(o, [["__scopeId", "data-v-e53c6287"]]);
3
+ // import "../../ChartTooltip.vue_vue_type_style_index_0_scoped_3315b68f_lang.css"; //*');
4
+ const s = /* @__PURE__ */ t(o, [["__scopeId", "data-v-3315b68f"]]);
5
5
  export {
6
6
  s as default
7
7
  };
@@ -1,4 +1,4 @@
1
- import "../../ChartTooltip.vue_vue_type_style_index_0_scoped_e53c6287_lang.css"; import { defineComponent as m, openBlock as a, createElementBlock as o, createBlock as c, createCommentVNode as r, Fragment as y, renderList as v, createElementVNode as f, normalizeStyle as h, unref as l, createVNode as i, withCtx as n, createTextVNode as s, toDisplayString as u } from "vue";
1
+ import "../../ChartTooltip.vue_vue_type_style_index_0_scoped_3315b68f_lang.css"; import { defineComponent as m, openBlock as a, createElementBlock as o, createBlock as c, createCommentVNode as r, Fragment as y, renderList as v, createElementVNode as f, normalizeStyle as h, unref as l, createVNode as i, withCtx as n, createTextVNode as u, toDisplayString as s } from "vue";
2
2
  import d from "../typography/v4/Typography.vue.js";
3
3
  import b from "../icon/v4/IconV4.vue.js";
4
4
  import "../icon/v4/IconFlag.vue.js";
@@ -59,14 +59,14 @@ const C = { class: "chart-tooltip" }, g = {
59
59
  "is-truncated": ""
60
60
  }, {
61
61
  default: n(() => [
62
- s(u(e.dataset.label), 1)
62
+ u(s(e.dataset.label), 1)
63
63
  ]),
64
64
  _: 2
65
65
  }, 1024)
66
66
  ]),
67
67
  i(l(d), { variant: "body2" }, {
68
68
  default: n(() => [
69
- s(u(t.valuePrefix + l(x)(e.parsed.y, t.yAxisFormat) + t.valueSuffix), 1)
69
+ u(s(t.valuePrefix + l(x)(e.parsed.y, t.yAxisFormat, !0) + t.valueSuffix), 1)
70
70
  ]),
71
71
  _: 2
72
72
  }, 1024)
@@ -78,13 +78,13 @@ const C = { class: "chart-tooltip" }, g = {
78
78
  class: "flex-grow"
79
79
  }, {
80
80
  default: n(() => [
81
- s(u(t.totalLabel), 1)
81
+ u(s(t.totalLabel), 1)
82
82
  ]),
83
83
  _: 1
84
84
  }),
85
85
  i(l(d), { variant: "body2" }, {
86
86
  default: n(() => [
87
- s(u(t.valuePrefix + l(x)(t.totalValue, t.yAxisFormat) + t.valueSuffix), 1)
87
+ u(s(t.valuePrefix + l(x)(t.totalValue, t.yAxisFormat, !0) + t.valueSuffix), 1)
88
88
  ]),
89
89
  _: 1
90
90
  })