@ironsource/shared-ui 2.2.0-test.15 → 2.2.0-test.16

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.
@@ -0,0 +1 @@
1
+ .chart-container[data-v-fc33022b]{border:1px solid var(--common-divider);background:var(--background-paper);display:flex;border-radius:0 0 6px 6px;width:100%;overflow:hidden;height:100%}.chart-planes[data-v-fc33022b]{width:100%;height:100%;overflow-y:auto}.chart-planes.with-legend[data-v-fc33022b]{width:calc(100% - 221px)}.chart-planes .extra-chart-plane[data-v-fc33022b]{border-top:1px solid var(--common-divider)}.chart-sidebar[data-v-fc33022b]{border-left:1px solid var(--common-divider)}
@@ -50,7 +50,6 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<__
50
50
  sortOptionNameKey?: string;
51
51
  fullHeight?: boolean;
52
52
  fullHeightBottomSpacing?: number;
53
- height?: string;
54
53
  withSettingsHeader?: boolean;
55
54
  extraCharts?: Record<string, unknown>[];
56
55
  colorVariant?: ColorVariant;
@@ -97,7 +96,6 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<__
97
96
  sortOptionNameKey: string;
98
97
  fullHeight: boolean;
99
98
  fullHeightBottomSpacing: number;
100
- height: any;
101
99
  withSettingsHeader: boolean;
102
100
  extraCharts: () => any[];
103
101
  colorVariant: string;
@@ -155,7 +153,6 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<__
155
153
  sortOptionNameKey?: string;
156
154
  fullHeight?: boolean;
157
155
  fullHeightBottomSpacing?: number;
158
- height?: string;
159
156
  withSettingsHeader?: boolean;
160
157
  extraCharts?: Record<string, unknown>[];
161
158
  colorVariant?: ColorVariant;
@@ -202,7 +199,6 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<__
202
199
  sortOptionNameKey: string;
203
200
  fullHeight: boolean;
204
201
  fullHeightBottomSpacing: number;
205
- height: any;
206
202
  withSettingsHeader: boolean;
207
203
  extraCharts: () => any[];
208
204
  colorVariant: string;
@@ -213,7 +209,6 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<__
213
209
  }, {
214
210
  header: string;
215
211
  testId: string;
216
- height: string;
217
212
  loading: boolean;
218
213
  visibleIds: unknown[];
219
214
  minVisible: number;
@@ -1,7 +1,7 @@
1
1
  import o from "./Chart.vue2.js";
2
2
  /* empty css */import _ from "../../_virtual/_plugin-vue_export-helper.js";
3
- // import "../../Chart.vue_vue_type_style_index_0_scoped_a7fb79c8_lang.css"; //*');
4
- const a = /* @__PURE__ */ _(o, [["__scopeId", "data-v-a7fb79c8"]]);
3
+ // import "../../Chart.vue_vue_type_style_index_0_scoped_fc33022b_lang.css"; //*');
4
+ const c = /* @__PURE__ */ _(o, [["__scopeId", "data-v-fc33022b"]]);
5
5
  export {
6
- a as default
6
+ c as default
7
7
  };
@@ -1,38 +1,38 @@
1
- import "../../Chart.vue_vue_type_style_index_0_scoped_a7fb79c8_lang.css"; import { defineComponent as P, ref as U, computed as n, openBlock as d, createElementBlock as T, Fragment as C, createBlock as D, unref as e, isRef as y, withCtx as s, renderSlot as u, createCommentVNode as A, createElementVNode as L, mergeProps as b, normalizeClass as M, createVNode as k, createSlots as R, renderList as K } from "vue";
1
+ import "../../Chart.vue_vue_type_style_index_0_scoped_fc33022b_lang.css"; import { defineComponent as P, ref as U, computed as d, openBlock as n, createElementBlock as b, Fragment as S, createBlock as D, unref as l, isRef as y, withCtx as s, renderSlot as u, createCommentVNode as A, createElementVNode as L, mergeProps as g, normalizeClass as $, createVNode as k, createSlots as M, renderList as R } from "vue";
2
2
  import { useVModel as B } from "@vueuse/core";
3
- import X from "./ChartLegend.vue.js";
4
- import z from "./SettingsHeader.vue.js";
3
+ import K from "./ChartLegend.vue.js";
4
+ import X from "./SettingsHeader.vue.js";
5
5
  import V from "./ChartPlane.vue.js";
6
- import { useColorsMap as G } from "./composables/useColorsMap.js";
7
- import { DEFAULT_TICK_COUNT as Y, DEFAULT_MIN_VISIBLE as j, DEFAULT_MAX_VISIBLE as q } from "./consts.js";
8
- import { ChartType as J, DateInterval as Q, TooltipOrder as W, TrendDirection as Z } from "./types.js";
9
- import { useChartHeight as _ } from "./composables/useChartHeight.js";
10
- import { TotalType as tt, calculateTotal as et } from "../../utils/totals.js";
11
- import { useTestIdAttrs as at } from "../../utils/testIds.js";
6
+ import { useColorsMap as z } from "./composables/useColorsMap.js";
7
+ import { DEFAULT_TICK_COUNT as G, DEFAULT_MIN_VISIBLE as Y, DEFAULT_MAX_VISIBLE as j } from "./consts.js";
8
+ import { ChartType as q, DateInterval as J, TooltipOrder as Q, TrendDirection as W } from "./types.js";
9
+ import { useChartHeight as Z } from "./composables/useChartHeight.js";
10
+ import { TotalType as _, calculateTotal as tt } from "../../utils/totals.js";
11
+ import { useTestIdAttrs as et } from "../../utils/testIds.js";
12
12
  import { ChartTestIdModifiers as p } from "../../testids/index.js";
13
- const lt = {
13
+ const at = {
14
14
  key: 0,
15
15
  class: "chart-sidebar"
16
- }, gt = /* @__PURE__ */ P({
16
+ }, mt = /* @__PURE__ */ P({
17
17
  __name: "Chart",
18
18
  props: {
19
19
  dataSets: { default: () => [] },
20
20
  visibleIds: { default: () => [] },
21
- chartType: { default: J.Line },
21
+ chartType: { default: q.Line },
22
22
  parsing: { default: void 0 },
23
23
  xAxisFormat: { default: "string" },
24
24
  yAxisFormat: { default: "number" },
25
- xAxisDateInterval: { default: Q.DAILY },
26
- tickCount: { default: Y },
25
+ xAxisDateInterval: { default: J.DAILY },
26
+ tickCount: { default: G },
27
27
  truncateTickLabels: { type: Boolean, default: !1 },
28
28
  loading: { type: Boolean, default: !1 },
29
29
  empty: { type: Boolean, default: !1 },
30
30
  withAnimation: { type: Boolean, default: !0 },
31
31
  totalsChart: { type: Boolean, default: !1 },
32
- tooltipTotalType: { default: tt.Total },
32
+ tooltipTotalType: { default: _.Total },
33
33
  headerTooltip: { default: null },
34
- tooltipTotalCalcFn: { type: Function, default: et },
35
- tooltipOrder: { default: W.Legend },
34
+ tooltipTotalCalcFn: { type: Function, default: tt },
35
+ tooltipOrder: { default: Q.Legend },
36
36
  valueSuffix: { default: "" },
37
37
  valuePrefix: { default: "" },
38
38
  indicateIncompleteData: { type: Boolean, default: !1 },
@@ -43,29 +43,28 @@ const lt = {
43
43
  subheaderTooltip: { default: null },
44
44
  keepSubheaderVisible: { type: Boolean, default: !1 },
45
45
  trendValue: { default: null },
46
- trendDirection: { default: Z.UP },
46
+ trendDirection: { default: W.UP },
47
47
  trendTooltip: { default: null },
48
48
  noteText: { default: "" },
49
49
  noDataIcon: { default: "file-search" },
50
50
  noDataTitle: { default: "No data to display" },
51
51
  noDataSubtitle: { default: "Search again with different filters" },
52
52
  hideLegend: { type: Boolean, default: !1 },
53
- minVisible: { default: j },
54
- maxVisible: { default: q },
53
+ minVisible: { default: Y },
54
+ maxVisible: { default: j },
55
55
  maxLimitTooltipText: { default: "" },
56
56
  sortSelected: { default: null },
57
57
  sortOptions: { default: () => [] },
58
58
  sortOptionNameKey: { default: "" },
59
59
  fullHeight: { type: Boolean, default: !1 },
60
60
  fullHeightBottomSpacing: { default: 50 },
61
- height: { default: void 0 },
62
61
  withSettingsHeader: { type: Boolean, default: !0 },
63
62
  extraCharts: { default: () => [] },
64
63
  colorVariant: { default: "default" }
65
64
  },
66
65
  emits: ["update:chartType", "update:visibleIds", "update:sortSelected"],
67
- setup(a, { emit: h }) {
68
- const t = a, r = B(t, "chartType", h), c = B(t, "sortSelected", h), f = U(null), v = n(() => ({
66
+ setup(e, { emit: c }) {
67
+ const t = e, r = B(t, "chartType", c), f = B(t, "sortSelected", c), h = U(null), v = d(() => ({
69
68
  dataSets: t.dataSets,
70
69
  visibleIds: t.visibleIds,
71
70
  parsing: t.parsing,
@@ -85,7 +84,7 @@ const lt = {
85
84
  withAnimation: t.withAnimation,
86
85
  typeSwitcher: !t.withSettingsHeader,
87
86
  height: N.value,
88
- compactHeader: S.value > 1,
87
+ compactHeader: C.value > 1,
89
88
  trendValue: t.trendValue,
90
89
  trendDirection: t.trendDirection,
91
90
  trendTooltip: t.trendTooltip,
@@ -96,95 +95,93 @@ const lt = {
96
95
  tooltipTotalType: t.tooltipTotalType,
97
96
  tooltipTotalCalcFn: t.tooltipTotalCalcFn,
98
97
  tooltipOrder: t.tooltipOrder,
99
- highlightedId: f.value,
98
+ highlightedId: h.value,
100
99
  valueSuffix: t.valueSuffix,
101
100
  valuePrefix: t.valuePrefix,
102
101
  indicateIncompleteData: t.indicateIncompleteData,
103
102
  tooltipExcludeTotalItem: t.tooltipExcludeTotalItem,
104
103
  headerTooltip: t.headerTooltip,
105
104
  testId: t.testId
106
- })), E = n(() => t.dataSets), x = n(() => t.visibleIds), I = n(() => t.extraCharts.length), S = n(() => 1 + I.value), F = (l) => l === I.value - 1, { colorsMap: m } = G({
105
+ })), E = d(() => t.dataSets), I = d(() => t.visibleIds), x = d(() => t.extraCharts.length), C = d(() => 1 + x.value), F = (a) => a === x.value - 1, { colorsMap: m } = z({
107
106
  dataSets: E,
108
- visibleIds: x,
107
+ visibleIds: I,
109
108
  variant: t.colorVariant
110
- }), H = n(() => t.dataSets.map((l) => ({
111
- id: l.id,
112
- label: l.label,
113
- caption: l.caption || null,
114
- color: m.value[l.id] || null,
115
- icon: l.icon || null,
116
- iconType: l.iconType || "branded"
117
- }))), { containerProps: w, eachPlaneHeight: N } = _({
118
- chartPlanesCount: S,
109
+ }), w = d(() => t.dataSets.map((a) => ({
110
+ id: a.id,
111
+ label: a.label,
112
+ caption: a.caption || null,
113
+ color: m.value[a.id] || null,
114
+ icon: a.icon || null,
115
+ iconType: a.iconType || "branded"
116
+ }))), { containerProps: H, eachPlaneHeight: N } = Z({
117
+ chartPlanesCount: C,
119
118
  useFullHeight: t.fullHeight,
120
119
  bottomSpacing: t.fullHeightBottomSpacing
121
- }), $ = at(t.testId, p), O = n(() => t.height ? t.withSettingsHeader ? {
122
- height: `calc(${t.height} - var(--settings-header-height, 60px))`
123
- } : { height: t.height } : {});
124
- return (l, i) => (d(), T(C, null, [
125
- a.withSettingsHeader ? (d(), D(z, {
120
+ }), O = et(t.testId, p);
121
+ return (a, i) => (n(), b(S, null, [
122
+ e.withSettingsHeader ? (n(), D(X, {
126
123
  key: 0,
127
- "chart-type": e(r),
124
+ "chart-type": l(r),
128
125
  "onUpdate:chart-type": i[0] || (i[0] = (o) => y(r) ? r.value = o : null),
129
- "hide-legend": a.hideLegend,
130
- "test-id": a.testId
126
+ "hide-legend": e.hideLegend,
127
+ "test-id": e.testId
131
128
  }, {
132
129
  "before-chart-type": s(() => [
133
- u(l.$slots, "before-chart-type", {}, void 0, !0)
130
+ u(a.$slots, "before-chart-type", {}, void 0, !0)
134
131
  ]),
135
132
  metric: s(() => [
136
- u(l.$slots, "metric", {}, void 0, !0)
133
+ u(a.$slots, "metric", {}, void 0, !0)
137
134
  ]),
138
135
  breakdowns: s(() => [
139
- u(l.$slots, "breakdowns", {}, void 0, !0)
136
+ u(a.$slots, "breakdowns", {}, void 0, !0)
140
137
  ]),
141
138
  _: 3
142
139
  }, 8, ["chart-type", "hide-legend", "test-id"])) : A("", !0),
143
- L("div", b({ class: "chart-container" }, {
144
- ...e(w),
145
- ...e($)[e(p).CONTAINER]
146
- }, { style: e(O) }), [
140
+ L("div", g({ class: "chart-container" }, {
141
+ ...l(H),
142
+ ...l(O)[l(p).CONTAINER]
143
+ }), [
147
144
  L("section", {
148
- class: M(["chart-planes", [{ "with-legend": !a.hideLegend }]])
145
+ class: $(["chart-planes", [{ "with-legend": !e.hideLegend }]])
149
146
  }, [
150
- k(V, b({
151
- "chart-type": e(r),
147
+ k(V, g({
148
+ "chart-type": l(r),
152
149
  "onUpdate:chart-type": i[1] || (i[1] = (o) => y(r) ? r.value = o : null)
153
- }, e(v)), R({ _: 2 }, [
154
- l.$slots["subheader-tooltip"] ? {
150
+ }, l(v)), M({ _: 2 }, [
151
+ a.$slots["subheader-tooltip"] ? {
155
152
  name: "subheader-tooltip",
156
153
  fn: s(() => [
157
- u(l.$slots, "subheader-tooltip", {}, void 0, !0)
154
+ u(a.$slots, "subheader-tooltip", {}, void 0, !0)
158
155
  ]),
159
156
  key: "0"
160
157
  } : void 0
161
158
  ]), 1040, ["chart-type"]),
162
- (d(!0), T(C, null, K(a.extraCharts, (o, g) => (d(), D(V, b({
163
- key: g,
159
+ (n(!0), b(S, null, R(e.extraCharts, (o, T) => (n(), D(V, g({
160
+ key: T,
164
161
  class: "extra-chart-plane"
165
- }, { ...e(v), ...o }, {
166
- "chart-type": e(r),
167
- "colors-map": e(m),
162
+ }, { ...l(v), ...o }, {
163
+ "chart-type": l(r),
164
+ "colors-map": l(m),
168
165
  "type-switcher": !1,
169
- "tooltip-respects-top-edge": !F(g),
170
- "test-id": `${a.testId}-${e(p).EXTRA_CHART}-${g}`
166
+ "tooltip-respects-top-edge": !F(T),
167
+ "test-id": `${e.testId}-${l(p).EXTRA_CHART}-${T}`
171
168
  }), null, 16, ["chart-type", "colors-map", "tooltip-respects-top-edge", "test-id"]))), 128))
172
169
  ], 2),
173
- a.hideLegend ? A("", !0) : (d(), T("section", lt, [
174
- k(X, {
175
- "sort-selected": e(c),
176
- "onUpdate:sort-selected": i[2] || (i[2] = (o) => y(c) ? c.value = o : null),
177
- "highlighted-id": f.value,
178
- "onUpdate:highlighted-id": i[3] || (i[3] = (o) => f.value = o),
179
- items: e(H),
180
- "visible-ids": e(x),
181
- "max-limit-tooltip-text": a.maxLimitTooltipText,
182
- "sort-options": a.sortOptions,
183
- "sort-option-name-key": a.sortOptionNameKey,
184
- "min-visible": a.minVisible,
185
- "max-visible": a.maxVisible,
186
- "test-id": `${a.testId}-${e(p).LEGEND}`,
187
- "onUpdate:visibleIds": i[4] || (i[4] = (o) => h("update:visibleIds", o))
170
+ e.hideLegend ? A("", !0) : (n(), b("section", at, [
171
+ k(K, {
172
+ "sort-selected": l(f),
173
+ "onUpdate:sort-selected": i[2] || (i[2] = (o) => y(f) ? f.value = o : null),
174
+ "highlighted-id": h.value,
175
+ "onUpdate:highlighted-id": i[3] || (i[3] = (o) => h.value = o),
176
+ items: l(w),
177
+ "visible-ids": l(I),
178
+ "max-limit-tooltip-text": e.maxLimitTooltipText,
179
+ "sort-options": e.sortOptions,
180
+ "sort-option-name-key": e.sortOptionNameKey,
181
+ "min-visible": e.minVisible,
182
+ "max-visible": e.maxVisible,
183
+ "test-id": `${e.testId}-${l(p).LEGEND}`,
184
+ "onUpdate:visibleIds": i[4] || (i[4] = (o) => c("update:visibleIds", o))
188
185
  }, null, 8, ["sort-selected", "highlighted-id", "items", "visible-ids", "max-limit-tooltip-text", "sort-options", "sort-option-name-key", "min-visible", "max-visible", "test-id"])
189
186
  ]))
190
187
  ], 16)
@@ -192,5 +189,5 @@ const lt = {
192
189
  }
193
190
  });
194
191
  export {
195
- gt as default
192
+ mt as default
196
193
  };
@@ -7,7 +7,6 @@ declare const ChartTypes: () => ({
7
7
  $props: Partial<{
8
8
  header: string;
9
9
  testId: string;
10
- height: string;
11
10
  loading: boolean;
12
11
  visibleIds: unknown[];
13
12
  minVisible: number;
@@ -60,10 +59,6 @@ declare const ChartTypes: () => ({
60
59
  type: import("vue").PropType<string>;
61
60
  default: string;
62
61
  };
63
- height: {
64
- type: import("vue").PropType<string>;
65
- default: any;
66
- };
67
62
  loading: {
68
63
  type: import("vue").PropType<boolean>;
69
64
  default: boolean;
@@ -249,7 +244,7 @@ declare const ChartTypes: () => ({
249
244
  "onUpdate:visibleIds"?: (visibleIds: unknown[]) => any;
250
245
  "onUpdate:sortSelected"?: (sortOption: unknown) => any;
251
246
  "onUpdate:chartType"?: (chartType: ChartType) => any;
252
- } & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, "header" | "testId" | "height" | "loading" | "visibleIds" | "minVisible" | "maxVisible" | "maxLimitTooltipText" | "sortSelected" | "sortOptions" | "sortOptionNameKey" | "chartType" | "hideLegend" | "xAxisFormat" | "xAxisDateInterval" | "totalsChart" | "parsing" | "yAxisFormat" | "valueSuffix" | "valuePrefix" | "trendTooltip" | "subheader" | "subheaderTooltip" | "headerTooltip" | "trendValue" | "trendDirection" | "noteText" | "dataSets" | "tickCount" | "truncateTickLabels" | "keepSubheaderVisible" | "empty" | "noDataIcon" | "noDataTitle" | "noDataSubtitle" | "withAnimation" | "tooltipTotalType" | "tooltipTotalCalcFn" | "tooltipOrder" | "indicateIncompleteData" | "tooltipExcludeTotalItem" | "fullHeight" | "fullHeightBottomSpacing" | "withSettingsHeader" | "extraCharts" | "colorVariant">;
247
+ } & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, "header" | "testId" | "loading" | "visibleIds" | "minVisible" | "maxVisible" | "maxLimitTooltipText" | "sortSelected" | "sortOptions" | "sortOptionNameKey" | "chartType" | "hideLegend" | "xAxisFormat" | "xAxisDateInterval" | "totalsChart" | "parsing" | "yAxisFormat" | "valueSuffix" | "valuePrefix" | "trendTooltip" | "subheader" | "subheaderTooltip" | "headerTooltip" | "trendValue" | "trendDirection" | "noteText" | "dataSets" | "tickCount" | "truncateTickLabels" | "keepSubheaderVisible" | "empty" | "noDataIcon" | "noDataTitle" | "noDataSubtitle" | "withAnimation" | "tooltipTotalType" | "tooltipTotalCalcFn" | "tooltipOrder" | "indicateIncompleteData" | "tooltipExcludeTotalItem" | "fullHeight" | "fullHeightBottomSpacing" | "withSettingsHeader" | "extraCharts" | "colorVariant">;
253
248
  $attrs: {
254
249
  [x: string]: unknown;
255
250
  };
@@ -272,10 +267,6 @@ declare const ChartTypes: () => ({
272
267
  type: import("vue").PropType<string>;
273
268
  default: string;
274
269
  };
275
- height: {
276
- type: import("vue").PropType<string>;
277
- default: any;
278
- };
279
270
  loading: {
280
271
  type: import("vue").PropType<boolean>;
281
272
  default: boolean;
@@ -468,7 +459,6 @@ declare const ChartTypes: () => ({
468
459
  }, string, {
469
460
  header: string;
470
461
  testId: string;
471
- height: string;
472
462
  loading: boolean;
473
463
  visibleIds: unknown[];
474
464
  minVisible: number;
@@ -541,10 +531,6 @@ declare const ChartTypes: () => ({
541
531
  type: import("vue").PropType<string>;
542
532
  default: string;
543
533
  };
544
- height: {
545
- type: import("vue").PropType<string>;
546
- default: any;
547
- };
548
534
  loading: {
549
535
  type: import("vue").PropType<boolean>;
550
536
  default: boolean;
@@ -743,10 +729,6 @@ declare const ChartTypes: () => ({
743
729
  type: import("vue").PropType<string>;
744
730
  default: string;
745
731
  };
746
- height: {
747
- type: import("vue").PropType<string>;
748
- default: any;
749
- };
750
732
  loading: {
751
733
  type: import("vue").PropType<boolean>;
752
734
  default: boolean;
@@ -939,7 +921,6 @@ declare const ChartTypes: () => ({
939
921
  }, string, {
940
922
  header: string;
941
923
  testId: string;
942
- height: string;
943
924
  loading: boolean;
944
925
  visibleIds: unknown[];
945
926
  minVisible: number;
package/index.js CHANGED
@@ -1,4 +1,4 @@
1
- import './Menu.vue_vue_type_style_index_0_scoped_eb057818_lang.css';
1
+ import './IncludeExcludeChipFilter.vue_vue_type_style_index_0_scoped_198d2d73_lang.css';
2
2
  import { AppTriggerTypes as eo } from "./components/appTrigger/index.js";
3
3
  import { AutocompleteDropdownTypes as mo } from "./components/autocompleteDropdown/index.js";
4
4
  import { MenuItemTypes as ao } from "./components/menuItem/index.js";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ironsource/shared-ui",
3
- "version": "2.2.0-test.15",
3
+ "version": "2.2.0-test.16",
4
4
  "engines": {
5
5
  "npm": ">=7.0.0",
6
6
  "node": ">=16.0.0"
@@ -1 +0,0 @@
1
- .chart-container[data-v-a7fb79c8]{border:1px solid var(--common-divider);background:var(--background-paper);display:flex;border-radius:0 0 6px 6px;width:100%}.chart-planes[data-v-a7fb79c8]{width:100%;height:100%;overflow-y:auto}.chart-planes.with-legend[data-v-a7fb79c8]{width:calc(100% - 221px)}.chart-planes .extra-chart-plane[data-v-a7fb79c8]{border-top:1px solid var(--common-divider)}.chart-sidebar[data-v-a7fb79c8]{border-left:1px solid var(--common-divider)}