@ironsource/shared-ui 2.1.12-rc.31 → 2.1.12-rc.33
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/Chart.vue_vue_type_style_index_0_scoped_3da25a36_lang.css +1 -0
- package/ChartHeaderTrend.vue_vue_type_style_index_0_scoped_2f916aeb_lang.css +1 -0
- package/ChartPlane.vue_vue_type_style_index_0_scoped_f871962e_lang.css +1 -0
- package/DataGrid.vue_vue_type_style_index_0_scoped_36ec94a7_lang.css +1 -0
- package/DataGridHeader.vue_vue_type_style_index_0_scoped_840e700c_lang.css +1 -0
- package/DataGridRowsCounter.vue_vue_type_style_index_0_scoped_e38c881a_lang.css +1 -0
- package/MultipleDataGrid.vue_vue_type_style_index_0_scoped_3caa1d7b_lang.css +1 -0
- package/RadioButton.vue_vue_type_style_index_0_scoped_dac25b9f_lang.css +1 -0
- package/TooltipHeader.vue_vue_type_style_index_0_scoped_5160f12d_lang.css +1 -0
- package/components/chart/Chart.vue.d.ts +10 -0
- package/components/chart/Chart.vue.js +2 -2
- package/components/chart/Chart.vue2.js +29 -25
- package/components/chart/ChartHeaderTrend.vue.js +2 -2
- package/components/chart/ChartHeaderTrend.vue2.js +34 -33
- package/components/chart/ChartPlane.vue.d.ts +10 -0
- package/components/chart/ChartPlane.vue.js +4 -4
- package/components/chart/ChartPlane.vue2.js +158 -147
- package/components/chart/ChartStoryArgs.d.ts +12 -0
- package/components/chart/TooltipHeader.vue.js +2 -2
- package/components/chart/TooltipHeader.vue2.js +21 -20
- package/components/chart/consts.d.ts +4 -0
- package/components/chart/consts.js +30 -26
- package/components/chart/index.d.ts +39 -1
- package/components/chart/mockData.d.ts +15 -0
- package/components/chart/types.d.ts +2 -1
- package/components/chart/types.js +5 -5
- package/components/chart/utils/utils.js +14 -13
- package/components/dateRange/common/DateRange.common.js +60 -60
- package/components/radioButton/v3/RadioButton.vue.d.ts +5 -0
- package/components/radioButton/v3/RadioButton.vue.js +3 -3
- package/components/radioButton/v3/RadioButton.vue2.js +42 -39
- package/components/radioButton/v3/index.d.ts +20 -1
- package/components/table/v4/DataGrid.vue.d.ts +4 -4
- package/components/table/v4/DataGrid.vue.js +3 -3
- package/components/table/v4/DataGrid.vue2.js +237 -245
- package/components/table/v4/DataGridHeader.vue.d.ts +85 -0
- package/components/table/v4/DataGridHeader.vue.js +7 -0
- package/components/table/v4/DataGridHeader.vue2.js +82 -0
- package/components/table/v4/DataGridRowsCounter.vue.js +3 -3
- package/components/table/v4/DataGridRowsCounter.vue2.js +12 -12
- package/components/table/v4/MultipleDataGrid.vue.d.ts +6 -5
- package/components/table/v4/MultipleDataGrid.vue.js +2 -2
- package/components/table/v4/MultipleDataGrid.vue2.js +91 -90
- package/components/table/v4/index.d.ts +552 -305
- package/components/table/v4/index.js +7 -4
- package/components/table/v4/storyUtils.d.ts +8 -0
- package/index.d.ts +1578 -1085
- package/index.js +1 -1
- package/package.json +1 -1
- package/utils/date.d.ts +1 -0
- package/utils/date.js +9 -0
- package/utils/formatNumbers.d.ts +1 -1
- package/utils/formatNumbers.js +38 -21
- package/Chart.vue_vue_type_style_index_0_scoped_fa533a3d_lang.css +0 -1
- package/ChartHeaderTrend.vue_vue_type_style_index_0_scoped_db8a902c_lang.css +0 -1
- package/ChartPlane.vue_vue_type_style_index_0_scoped_4f67d41d_lang.css +0 -1
- package/DataGrid.vue_vue_type_style_index_0_scoped_8e8df067_lang.css +0 -1
- package/DataGridRowsCounter.vue_vue_type_style_index_0_scoped_ef699ec5_lang.css +0 -1
- package/MultipleDataGrid.vue_vue_type_style_index_0_scoped_020a9896_lang.css +0 -1
- package/RadioButton.vue_vue_type_style_index_0_scoped_3c6b715c_lang.css +0 -1
- package/TooltipHeader.vue_vue_type_style_index_0_scoped_3b15c693_lang.css +0 -1
|
@@ -1,47 +1,51 @@
|
|
|
1
1
|
import { ChartType as _ } from "./types.js";
|
|
2
|
-
const
|
|
2
|
+
const T = "#fcfcfc", t = "#E4E4E4", n = "#646464", A = {
|
|
3
3
|
size: 12,
|
|
4
4
|
weight: 400,
|
|
5
5
|
family: "Inter"
|
|
6
|
-
},
|
|
6
|
+
}, o = 4, R = 1, N = 5, O = [
|
|
7
7
|
{ id: _.Line, name: "Line" },
|
|
8
8
|
{ id: _.StackedLine, name: "Stack" },
|
|
9
9
|
{ id: _.Bar, name: "Bar" }
|
|
10
|
-
],
|
|
10
|
+
], c = 76, L = 43, s = 312, I = 187, C = "__TOTALS_HELPER_KEY__", D = "___BASE_COLOR__", e = "Bidding", P = "ironSource", S = "UnityAds", i = "Meta", H = "Google", K = "Mintegral", B = "AppLovin", M = "InMobi", a = "DT Exchange", G = "Pangle", r = "Liftoff Monetize", F = 10, W = 70, Y = 10, f = 70, d = 40, g = [4, 4], U = {
|
|
11
11
|
left: 18,
|
|
12
12
|
right: 18,
|
|
13
13
|
top: 18,
|
|
14
14
|
bottom: 11
|
|
15
|
-
},
|
|
15
|
+
}, m = 6, p = "dateLong";
|
|
16
16
|
export {
|
|
17
17
|
D as BASE_COLOR_KEY,
|
|
18
|
-
|
|
19
|
-
f as
|
|
18
|
+
e as BIDDING_PREFIX,
|
|
19
|
+
f as CHART_ITEM_TRANSPARENCY,
|
|
20
|
+
U as CHART_PADDING,
|
|
20
21
|
L as COMPACT_HEADER_HEIGHT,
|
|
21
22
|
s as DEFAULT_CHART_PLANE_HEIGHT,
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
23
|
+
N as DEFAULT_MAX_VISIBLE,
|
|
24
|
+
R as DEFAULT_MIN_VISIBLE,
|
|
25
|
+
o as DEFAULT_TICK_COUNT,
|
|
26
|
+
O as DROPDOWN_TYPE_OPTIONS,
|
|
27
|
+
t as GRID_LINE_COLOR,
|
|
28
|
+
c as HEADER_HEIGHT,
|
|
28
29
|
W as HOVER_AREA_TRANSPARENCY,
|
|
29
30
|
F as HOVER_TRANSPARENCY,
|
|
30
|
-
|
|
31
|
+
d as INCOMPLETE_DATA_BAR_TRANSPARENCY,
|
|
32
|
+
g as LINE_DASH_STYLE,
|
|
33
|
+
p as LONG_DATE_FORMAT,
|
|
31
34
|
I as MIN_PLANE_HEIGHT,
|
|
32
35
|
H as NETWORK_AD_MOB,
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
36
|
+
B as NETWORK_APPLOVIN,
|
|
37
|
+
a as NETWORK_DT_EXCHANGE,
|
|
38
|
+
i as NETWORK_FACEBOOK_META,
|
|
39
|
+
M as NETWORK_INMOBI,
|
|
40
|
+
P as NETWORK_IRON_SOURCE,
|
|
38
41
|
r as NETWORK_LIFTOFF,
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
42
|
+
K as NETWORK_MINTEGRAL,
|
|
43
|
+
G as NETWORK_PANGLE,
|
|
44
|
+
S as NETWORK_UNITY_ADS,
|
|
45
|
+
T as POINT_BORDER_COLOR,
|
|
46
|
+
Y as STACKED_LINE_TRANSPARENCY,
|
|
47
|
+
m as TICKS_EXTRA_PADDING,
|
|
48
|
+
n as TICK_LABEL_COLOR,
|
|
49
|
+
A as TICK_LABEL_FONT,
|
|
50
|
+
C as TOTALS_HELPER_KEY
|
|
47
51
|
};
|
|
@@ -41,6 +41,8 @@ declare const ChartTypes: () => ({
|
|
|
41
41
|
tooltipTotalType: import("../../utils/totals").TotalType;
|
|
42
42
|
tooltipTotalCalcFn: (values: number[], totalType: import("../../utils/totals").TotalType) => number;
|
|
43
43
|
tooltipOrder: TooltipOrder;
|
|
44
|
+
indicateIncompleteData: boolean;
|
|
45
|
+
tooltipExcludeTotalItem: boolean;
|
|
44
46
|
fullHeight: boolean;
|
|
45
47
|
fullHeightBottomSpacing: number;
|
|
46
48
|
withSettingsHeader: boolean;
|
|
@@ -200,6 +202,14 @@ declare const ChartTypes: () => ({
|
|
|
200
202
|
type: import("vue").PropType<TooltipOrder>;
|
|
201
203
|
default: TooltipOrder;
|
|
202
204
|
};
|
|
205
|
+
indicateIncompleteData: {
|
|
206
|
+
type: import("vue").PropType<boolean>;
|
|
207
|
+
default: boolean;
|
|
208
|
+
};
|
|
209
|
+
tooltipExcludeTotalItem: {
|
|
210
|
+
type: import("vue").PropType<boolean>;
|
|
211
|
+
default: boolean;
|
|
212
|
+
};
|
|
203
213
|
fullHeight: {
|
|
204
214
|
type: import("vue").PropType<boolean>;
|
|
205
215
|
default: boolean;
|
|
@@ -224,7 +234,7 @@ declare const ChartTypes: () => ({
|
|
|
224
234
|
"onUpdate:visibleIds"?: (visibleIds: unknown[]) => any;
|
|
225
235
|
"onUpdate:sortSelected"?: (sortOption: unknown) => any;
|
|
226
236
|
"onUpdate:chartType"?: (chartType: ChartType) => any;
|
|
227
|
-
} & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, "header" | "loading" | "visibleIds" | "minVisible" | "maxVisible" | "maxLimitTooltipText" | "sortSelected" | "sortOptions" | "sortOptionNameKey" | "chartType" | "hideLegend" | "xAxisFormat" | "xAxisDateInterval" | "totalsChart" | "parsing" | "yAxisFormat" | "valueSuffix" | "valuePrefix" | "trendTooltip" | "subheader" | "subheaderTooltip" | "trendValue" | "trendDirection" | "noteText" | "dataSets" | "tickCount" | "truncateTickLabels" | "keepSubheaderVisible" | "empty" | "noDataIcon" | "noDataTitle" | "noDataSubtitle" | "withAnimation" | "tooltipTotalType" | "tooltipTotalCalcFn" | "tooltipOrder" | "fullHeight" | "fullHeightBottomSpacing" | "withSettingsHeader" | "extraCharts" | "colorVariant">;
|
|
237
|
+
} & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, "header" | "loading" | "visibleIds" | "minVisible" | "maxVisible" | "maxLimitTooltipText" | "sortSelected" | "sortOptions" | "sortOptionNameKey" | "chartType" | "hideLegend" | "xAxisFormat" | "xAxisDateInterval" | "totalsChart" | "parsing" | "yAxisFormat" | "valueSuffix" | "valuePrefix" | "trendTooltip" | "subheader" | "subheaderTooltip" | "trendValue" | "trendDirection" | "noteText" | "dataSets" | "tickCount" | "truncateTickLabels" | "keepSubheaderVisible" | "empty" | "noDataIcon" | "noDataTitle" | "noDataSubtitle" | "withAnimation" | "tooltipTotalType" | "tooltipTotalCalcFn" | "tooltipOrder" | "indicateIncompleteData" | "tooltipExcludeTotalItem" | "fullHeight" | "fullHeightBottomSpacing" | "withSettingsHeader" | "extraCharts" | "colorVariant">;
|
|
228
238
|
$attrs: {
|
|
229
239
|
[x: string]: unknown;
|
|
230
240
|
};
|
|
@@ -392,6 +402,14 @@ declare const ChartTypes: () => ({
|
|
|
392
402
|
type: import("vue").PropType<TooltipOrder>;
|
|
393
403
|
default: TooltipOrder;
|
|
394
404
|
};
|
|
405
|
+
indicateIncompleteData: {
|
|
406
|
+
type: import("vue").PropType<boolean>;
|
|
407
|
+
default: boolean;
|
|
408
|
+
};
|
|
409
|
+
tooltipExcludeTotalItem: {
|
|
410
|
+
type: import("vue").PropType<boolean>;
|
|
411
|
+
default: boolean;
|
|
412
|
+
};
|
|
395
413
|
fullHeight: {
|
|
396
414
|
type: import("vue").PropType<boolean>;
|
|
397
415
|
default: boolean;
|
|
@@ -457,6 +475,8 @@ declare const ChartTypes: () => ({
|
|
|
457
475
|
tooltipTotalType: import("../../utils/totals").TotalType;
|
|
458
476
|
tooltipTotalCalcFn: (values: number[], totalType: import("../../utils/totals").TotalType) => number;
|
|
459
477
|
tooltipOrder: TooltipOrder;
|
|
478
|
+
indicateIncompleteData: boolean;
|
|
479
|
+
tooltipExcludeTotalItem: boolean;
|
|
460
480
|
fullHeight: boolean;
|
|
461
481
|
fullHeightBottomSpacing: number;
|
|
462
482
|
withSettingsHeader: boolean;
|
|
@@ -636,6 +656,14 @@ declare const ChartTypes: () => ({
|
|
|
636
656
|
type: import("vue").PropType<TooltipOrder>;
|
|
637
657
|
default: TooltipOrder;
|
|
638
658
|
};
|
|
659
|
+
indicateIncompleteData: {
|
|
660
|
+
type: import("vue").PropType<boolean>;
|
|
661
|
+
default: boolean;
|
|
662
|
+
};
|
|
663
|
+
tooltipExcludeTotalItem: {
|
|
664
|
+
type: import("vue").PropType<boolean>;
|
|
665
|
+
default: boolean;
|
|
666
|
+
};
|
|
639
667
|
fullHeight: {
|
|
640
668
|
type: import("vue").PropType<boolean>;
|
|
641
669
|
default: boolean;
|
|
@@ -818,6 +846,14 @@ declare const ChartTypes: () => ({
|
|
|
818
846
|
type: import("vue").PropType<TooltipOrder>;
|
|
819
847
|
default: TooltipOrder;
|
|
820
848
|
};
|
|
849
|
+
indicateIncompleteData: {
|
|
850
|
+
type: import("vue").PropType<boolean>;
|
|
851
|
+
default: boolean;
|
|
852
|
+
};
|
|
853
|
+
tooltipExcludeTotalItem: {
|
|
854
|
+
type: import("vue").PropType<boolean>;
|
|
855
|
+
default: boolean;
|
|
856
|
+
};
|
|
821
857
|
fullHeight: {
|
|
822
858
|
type: import("vue").PropType<boolean>;
|
|
823
859
|
default: boolean;
|
|
@@ -883,6 +919,8 @@ declare const ChartTypes: () => ({
|
|
|
883
919
|
tooltipTotalType: import("../../utils/totals").TotalType;
|
|
884
920
|
tooltipTotalCalcFn: (values: number[], totalType: import("../../utils/totals").TotalType) => number;
|
|
885
921
|
tooltipOrder: TooltipOrder;
|
|
922
|
+
indicateIncompleteData: boolean;
|
|
923
|
+
tooltipExcludeTotalItem: boolean;
|
|
886
924
|
fullHeight: boolean;
|
|
887
925
|
fullHeightBottomSpacing: number;
|
|
888
926
|
withSettingsHeader: boolean;
|
|
@@ -38,6 +38,7 @@ export declare const MULTIPLE_DATASETS_DATE: ({
|
|
|
38
38
|
id: number;
|
|
39
39
|
label: string;
|
|
40
40
|
caption: string;
|
|
41
|
+
isTotal: boolean;
|
|
41
42
|
icon: string;
|
|
42
43
|
data: {
|
|
43
44
|
date: string;
|
|
@@ -58,6 +59,20 @@ export declare const MULTIPLE_DATASETS_DATE: ({
|
|
|
58
59
|
value2: number;
|
|
59
60
|
value3: number;
|
|
60
61
|
}[];
|
|
62
|
+
isTotal?: undefined;
|
|
63
|
+
} | {
|
|
64
|
+
id: number;
|
|
65
|
+
label: string;
|
|
66
|
+
caption: string;
|
|
67
|
+
icon: string;
|
|
68
|
+
data: {
|
|
69
|
+
date: string;
|
|
70
|
+
value: number;
|
|
71
|
+
value2: number;
|
|
72
|
+
value3: number;
|
|
73
|
+
}[];
|
|
74
|
+
isTotal?: undefined;
|
|
75
|
+
iconType?: undefined;
|
|
61
76
|
})[];
|
|
62
77
|
export declare const MULTIPLE_DATASETS_SINGLE_DATE: {
|
|
63
78
|
id: number;
|
|
@@ -24,6 +24,7 @@ export type ChartDataSet = {
|
|
|
24
24
|
iconType?: IconTypes;
|
|
25
25
|
countryFlag?: string;
|
|
26
26
|
image?: string;
|
|
27
|
+
isTotal?: boolean;
|
|
27
28
|
};
|
|
28
29
|
export type ChartParsingConfig = {
|
|
29
30
|
xAxisKey: string;
|
|
@@ -84,6 +85,6 @@ export declare enum TooltipOrder {
|
|
|
84
85
|
export declare enum TrendDirection {
|
|
85
86
|
UP = "up",
|
|
86
87
|
DOWN = "down",
|
|
87
|
-
NEUTRAL = "
|
|
88
|
+
NEUTRAL = "neutral"
|
|
88
89
|
}
|
|
89
90
|
export type ColorVariant = 'default' | 'mediation';
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
var
|
|
1
|
+
var L = /* @__PURE__ */ ((e) => (e.Line = "line", e.Bar = "bar", e.StackedLine = "stackedLine", e.StackedBar = "stackedBar", e))(L || {}), a = /* @__PURE__ */ ((e) => (e.DAILY = "daily", e.WEEKLY = "weekly", e.MONTHLY = "monthly", e))(a || {}), n = /* @__PURE__ */ ((e) => (e.Legend = "legend", e.YAxis = "yAxis", e))(n || {}), r = /* @__PURE__ */ ((e) => (e.UP = "up", e.DOWN = "down", e.NEUTRAL = "neutral", e))(r || {});
|
|
2
2
|
export {
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
3
|
+
L as ChartType,
|
|
4
|
+
a as DateInterval,
|
|
5
|
+
n as TooltipOrder,
|
|
6
|
+
r as TrendDirection
|
|
7
7
|
};
|
|
@@ -1,21 +1,22 @@
|
|
|
1
|
+
import { getUTCDate as n } from "../../../utils/date.js";
|
|
1
2
|
import { format as e } from "date-fns";
|
|
2
|
-
import { TICK_LABEL_FONT as
|
|
3
|
-
import { nFormatter as
|
|
4
|
-
import { truncateTextToFit as
|
|
5
|
-
import { REGEX_LINEBREAK as
|
|
6
|
-
const
|
|
3
|
+
import { TICK_LABEL_FONT as E } from "../consts.js";
|
|
4
|
+
import { nFormatter as c } from "../../../utils/formatNumbers.js";
|
|
5
|
+
import { truncateTextToFit as T } from "../../../utils/text.js";
|
|
6
|
+
import { REGEX_LINEBREAK as i } from "../../../consts/regex.js";
|
|
7
|
+
const u = (r, t, o = !1) => t === "day" ? e(n(r), "EEEE") : t === "number" ? c(r, o) : t === "date" ? e(n(r), "MMM dd") : t === "dateLong" ? e(n(r), "MMM dd, yyyy") : String(r), _ = ({
|
|
7
8
|
label: r,
|
|
8
9
|
format: t,
|
|
9
|
-
availableSpace:
|
|
10
|
-
truncate:
|
|
10
|
+
availableSpace: o,
|
|
11
|
+
truncate: s = !1
|
|
11
12
|
}) => {
|
|
12
|
-
const
|
|
13
|
-
const
|
|
14
|
-
return
|
|
13
|
+
const p = i.test(r), f = (d) => {
|
|
14
|
+
const m = u(d, t);
|
|
15
|
+
return s && o > 0 ? T(m, E, o) : m;
|
|
15
16
|
};
|
|
16
|
-
return
|
|
17
|
+
return p ? r.split(i).map(f) : f(r);
|
|
17
18
|
};
|
|
18
19
|
export {
|
|
19
|
-
|
|
20
|
-
|
|
20
|
+
u as formatValue,
|
|
21
|
+
_ as prepareTickLabel
|
|
21
22
|
};
|
|
@@ -3,13 +3,13 @@ import { useToggle as fe } from "../../../composables/useToggle.js";
|
|
|
3
3
|
import { ref as r, computed as b, onMounted as de, onBeforeMount as ce, onUnmounted as ve, watch as Q } from "vue";
|
|
4
4
|
import { min as me, addDays as ge, format as X } from "date-fns";
|
|
5
5
|
import { presetsList as he, formatError as De, mandatoryValuesError as Me, navigatePrev as Z, navigateNext as V } from "./consts.common.js";
|
|
6
|
-
import
|
|
6
|
+
import d from "./DateServices.common.js";
|
|
7
7
|
const pe = (o, y) => {
|
|
8
|
-
const N = r(null),
|
|
8
|
+
const N = r(null), c = r({ started: !1, date: null }), x = r(!1), _ = 2, T = r({ from: null, to: null }), u = r({}), g = r([]), k = r(null), i = r({}), p = r({}), E = r(!1), w = r(null), s = r(null), j = r("left"), P = r(null), O = r(null), C = r([]), K = r(null), [D] = fe({ initialValue: !1 }), q = r(null);
|
|
9
9
|
ie(q, () => {
|
|
10
10
|
D.value = !1;
|
|
11
11
|
});
|
|
12
|
-
const
|
|
12
|
+
const U = (e, t) => {
|
|
13
13
|
const a = {
|
|
14
14
|
weeks: [],
|
|
15
15
|
days: {},
|
|
@@ -17,20 +17,20 @@ const pe = (o, y) => {
|
|
|
17
17
|
year: t
|
|
18
18
|
};
|
|
19
19
|
let n, l;
|
|
20
|
-
const
|
|
21
|
-
let
|
|
22
|
-
const f =
|
|
20
|
+
const v = new Date(t, e, 1).getDay();
|
|
21
|
+
let m = 1;
|
|
22
|
+
const f = d.getCurrentTimeUTC();
|
|
23
23
|
f.setHours(0, 0, 0, 0);
|
|
24
|
-
const ue =
|
|
24
|
+
const ue = d.daysInMonth(e, t);
|
|
25
25
|
for (let I = 0; I < 6; I++) {
|
|
26
26
|
l = [];
|
|
27
27
|
for (let H = 0; H < 7; H++)
|
|
28
|
-
n = {}, I === 0 &&
|
|
28
|
+
n = {}, I === 0 && v > 0 && H < v && (n.value = 0), m > ue && (n.value = 0), !n.value && n.value !== 0 && (n.value = m, m += 1, a.days[n.value] = n, n.date = new Date(t, e, n.value), f < n.date ? n.isFuture = !0 : n.date.getTime() === f.getTime() && (n.isToday = !0, o.includeToday || (n.disabled = !0))), l.push(n);
|
|
29
29
|
a.weeks.push(l);
|
|
30
30
|
}
|
|
31
31
|
return a;
|
|
32
|
-
},
|
|
33
|
-
let e =
|
|
32
|
+
}, S = () => {
|
|
33
|
+
let e = d.getCurrentTimeUTC();
|
|
34
34
|
if (s.value && s.value.toEnd ? e = s.value.toEnd : o.range && o.range.to && (e = o.range.to), !u.value[`${e.getFullYear().toString()}_${e.getMonth().toString()}`]) {
|
|
35
35
|
u.value = {}, g.value = [];
|
|
36
36
|
for (let t = 0; t < _; t++) {
|
|
@@ -38,7 +38,7 @@ const pe = (o, y) => {
|
|
|
38
38
|
a.setDate(1), a.setMonth(e.getMonth() - t);
|
|
39
39
|
const n = `${a.getFullYear().toString()}_${a.getMonth().toString()}`;
|
|
40
40
|
u.value[n] = {
|
|
41
|
-
parsedMonth:
|
|
41
|
+
parsedMonth: U(
|
|
42
42
|
a.getMonth(),
|
|
43
43
|
a.getFullYear()
|
|
44
44
|
),
|
|
@@ -49,28 +49,28 @@ const pe = (o, y) => {
|
|
|
49
49
|
}, z = (e, t) => {
|
|
50
50
|
w.value = e;
|
|
51
51
|
let a = e;
|
|
52
|
-
e === "date" && (a = o.datePresetList),
|
|
52
|
+
e === "date" && (a = o.datePresetList), C.value = he[a], t && (s.value = {
|
|
53
53
|
fromStart: null,
|
|
54
54
|
fromEnd: null,
|
|
55
55
|
toStart: null,
|
|
56
56
|
toEnd: null
|
|
57
|
-
},
|
|
57
|
+
}, T.value.from = "", T.value.to = "", c.value = { started: !1, date: null }, i.value = "custom"), y("rangeTypeChanged", w.value);
|
|
58
58
|
}, ee = (e) => {
|
|
59
|
-
i.value = e.id, M(k.value[e.id].dates()),
|
|
59
|
+
i.value = e.id, M(k.value[e.id].dates()), S();
|
|
60
60
|
}, M = (e, t = !1) => {
|
|
61
61
|
let a = e;
|
|
62
|
-
return !e.from && !e.to && e.preset ? a = k.value[e.preset]?.dates() : (!e || !e.from && !e.to) && (a = k.value[
|
|
62
|
+
return !e.from && !e.to && e.preset ? a = k.value[e.preset]?.dates() : (!e || !e.from && !e.to) && (a = k.value[C.value[0]]), o.maxDaysInRange && (K.value = t ? ge(a.from, o.maxDaysInRange) : null), E.value = !1, !a.from || !a.to || !(a.from instanceof Date) || !(a.to instanceof Date) ? (O.value = De, E.value = !0, !1) : a.from > a.to ? (O.value = `"From" date can't be bigger than "To" date`, E.value = !0, !1) : (s.value = R(a), T.value.from = X(
|
|
63
63
|
s.value.fromStart,
|
|
64
64
|
o.dateFormat
|
|
65
|
-
),
|
|
65
|
+
), T.value.to = X(s.value.toEnd, o.dateFormat), !0);
|
|
66
66
|
}, F = () => {
|
|
67
|
-
i.value === "custom" ? P.value =
|
|
67
|
+
i.value === "custom" ? P.value = d.getDateRangeString(s.value) : P.value = J.value, y("currentDateChanged", P.value);
|
|
68
68
|
}, te = () => {
|
|
69
69
|
if (s.value.fromStart == null || s.value.toEnd == null) {
|
|
70
|
-
|
|
70
|
+
E.value = !0, O.value = Me;
|
|
71
71
|
return;
|
|
72
72
|
}
|
|
73
|
-
const e =
|
|
73
|
+
const e = d.getCurrentTimeUTC();
|
|
74
74
|
s.value.toEnd > e && (s.value.toEnd = e), F(), p.value = i.value, y("rangeChanged", {
|
|
75
75
|
from: s.value.fromStart,
|
|
76
76
|
to: s.value.toEnd,
|
|
@@ -79,29 +79,29 @@ const pe = (o, y) => {
|
|
|
79
79
|
}, ae = (e, t) => e ? Z : t ? V : null, ne = (e) => {
|
|
80
80
|
let t = null, a = null;
|
|
81
81
|
const n = _ - 1;
|
|
82
|
-
let l = "", h = null,
|
|
82
|
+
let l = "", h = null, v = null;
|
|
83
83
|
switch (e) {
|
|
84
84
|
case V:
|
|
85
|
-
Object.keys(u.value).forEach((
|
|
86
|
-
const f = u.value[
|
|
85
|
+
Object.keys(u.value).forEach((m) => {
|
|
86
|
+
const f = u.value[m];
|
|
87
87
|
f.order === 0 && (h = f), f.order === n ? (g.value.splice(
|
|
88
|
-
g.value.indexOf(
|
|
88
|
+
g.value.indexOf(m),
|
|
89
89
|
1
|
|
90
|
-
), delete u.value[
|
|
90
|
+
), delete u.value[m]) : f.order += 1;
|
|
91
91
|
}), t = h.parsedMonth.month + 1, a = h.parsedMonth.year, t > 11 && (t = 0, a += 1), l = `${a.toString()}_${t.toString()}`, u.value[l] = {
|
|
92
|
-
parsedMonth:
|
|
92
|
+
parsedMonth: U(t, a),
|
|
93
93
|
order: 0
|
|
94
94
|
}, g.value.push(l);
|
|
95
95
|
break;
|
|
96
96
|
case Z:
|
|
97
|
-
Object.keys(u.value).forEach((
|
|
98
|
-
const f = u.value[
|
|
99
|
-
f.order === n && (
|
|
100
|
-
g.value.indexOf(
|
|
97
|
+
Object.keys(u.value).forEach((m) => {
|
|
98
|
+
const f = u.value[m];
|
|
99
|
+
f.order === n && (v = f), f.order === 0 ? (g.value.splice(
|
|
100
|
+
g.value.indexOf(m),
|
|
101
101
|
1
|
|
102
|
-
), delete u.value[
|
|
103
|
-
}), t =
|
|
104
|
-
parsedMonth:
|
|
102
|
+
), delete u.value[m]) : f.order -= 1;
|
|
103
|
+
}), t = v.parsedMonth.month - 1, a = v.parsedMonth.year, t < 0 && (t = 11, a -= 1), l = `${a.toString()}_${t.toString()}`, u.value[l] = {
|
|
104
|
+
parsedMonth: U(t, a),
|
|
105
105
|
order: n
|
|
106
106
|
}, g.value.unshift(l);
|
|
107
107
|
break;
|
|
@@ -111,10 +111,10 @@ const pe = (o, y) => {
|
|
|
111
111
|
switch (w.value) {
|
|
112
112
|
case "week":
|
|
113
113
|
t = {
|
|
114
|
-
fromStart:
|
|
115
|
-
fromEnd:
|
|
116
|
-
toStart:
|
|
117
|
-
toEnd:
|
|
114
|
+
fromStart: d.getFirstDayOfWeek(e.from),
|
|
115
|
+
fromEnd: d.getLastDayOfWeek(e.from),
|
|
116
|
+
toStart: d.getFirstDayOfWeek(e.to),
|
|
117
|
+
toEnd: d.getLastDayOfWeek(e.to)
|
|
118
118
|
};
|
|
119
119
|
break;
|
|
120
120
|
case "month":
|
|
@@ -124,13 +124,13 @@ const pe = (o, y) => {
|
|
|
124
124
|
e.from.getMonth(),
|
|
125
125
|
1
|
|
126
126
|
),
|
|
127
|
-
fromEnd:
|
|
127
|
+
fromEnd: d.getLastDayOfMonth(e.from),
|
|
128
128
|
toStart: new Date(
|
|
129
129
|
e.to.getFullYear(),
|
|
130
130
|
e.to.getMonth(),
|
|
131
131
|
1
|
|
132
132
|
),
|
|
133
|
-
toEnd:
|
|
133
|
+
toEnd: d.getLastDayOfMonth(e.to)
|
|
134
134
|
};
|
|
135
135
|
break;
|
|
136
136
|
case "date":
|
|
@@ -144,10 +144,10 @@ const pe = (o, y) => {
|
|
|
144
144
|
break;
|
|
145
145
|
}
|
|
146
146
|
return t;
|
|
147
|
-
},
|
|
147
|
+
}, L = (e, t) => e.getUTCFullYear() === t.getUTCFullYear() && e.getUTCMonth() === t.getUTCMonth() && e.getUTCDate() === t.getUTCDate(), $ = (e) => {
|
|
148
148
|
let t = !1;
|
|
149
149
|
if (!e.from && !e.to && e.preset) {
|
|
150
|
-
const l =
|
|
150
|
+
const l = C.value.find(
|
|
151
151
|
(h) => h.id === e.preset
|
|
152
152
|
);
|
|
153
153
|
i.value = l.id, t = !0;
|
|
@@ -157,15 +157,15 @@ const pe = (o, y) => {
|
|
|
157
157
|
to: new Date(e.to)
|
|
158
158
|
};
|
|
159
159
|
a.from.setHours(0, 0, 0, 0), a.to.setHours(0, 0, 0, 0);
|
|
160
|
-
const n =
|
|
160
|
+
const n = C.value.map((l) => l.id);
|
|
161
161
|
if (Object.keys(k.value).forEach((l) => {
|
|
162
162
|
const h = k.value[l];
|
|
163
163
|
if (l !== "custom" && !t && n.indexOf(l) !== -1) {
|
|
164
|
-
const
|
|
165
|
-
|
|
164
|
+
const v = h.dates();
|
|
165
|
+
v.from.setHours(0, 0, 0, 0), v.to.setHours(0, 0, 0, 0), L(v.from, a.from) && L(v.to, a.to) && (i.value = l, t = !0);
|
|
166
166
|
}
|
|
167
167
|
}), t) {
|
|
168
|
-
const l =
|
|
168
|
+
const l = C.value.find(
|
|
169
169
|
(h) => h.id === i.value
|
|
170
170
|
);
|
|
171
171
|
y("dateRangePresetNameChanged", l.name);
|
|
@@ -173,24 +173,24 @@ const pe = (o, y) => {
|
|
|
173
173
|
y("dateRangePresetNameChanged", null), i.value = "custom";
|
|
174
174
|
p.value = i.value;
|
|
175
175
|
}, A = (e, t, a) => {
|
|
176
|
-
if (!
|
|
177
|
-
i.value = "custom",
|
|
178
|
-
{ from:
|
|
176
|
+
if (!c.value.started)
|
|
177
|
+
i.value = "custom", c.value.started = !0, c.value.date = new Date(a, t, e.value), M(
|
|
178
|
+
{ from: c.value.date, to: c.value.date },
|
|
179
179
|
!0
|
|
180
180
|
);
|
|
181
181
|
else {
|
|
182
|
-
const n = new Date(a, t, e.value), l =
|
|
183
|
-
|
|
182
|
+
const n = new Date(a, t, e.value), l = c.value.date;
|
|
183
|
+
c.value.started = !1, c.value.date = null, n < l ? A(e, t, a) : M({ from: l, to: n });
|
|
184
184
|
}
|
|
185
185
|
}, B = () => {
|
|
186
186
|
const e = N.value.offsetLeft;
|
|
187
187
|
return window.innerWidth - e > 930 ? "left" : "right";
|
|
188
188
|
}, W = (e = !0) => {
|
|
189
|
-
D.value = !D.value, D.value ? (j.value = B(), M(o.range),
|
|
189
|
+
D.value = !D.value, D.value ? (j.value = B(), M(o.range), S(), y("opened")) : (M(o.range), S(), i.value = p.value, e && y("dismissed"));
|
|
190
190
|
}, G = () => {
|
|
191
191
|
D.value && W();
|
|
192
192
|
}, le = () => {
|
|
193
|
-
k.value =
|
|
193
|
+
k.value = d.getPresetsFunctions(o.includeToday), k.value.custom = {
|
|
194
194
|
dates: () => o.range
|
|
195
195
|
};
|
|
196
196
|
}, oe = b(() => (g.value || []).reduce((e, t) => {
|
|
@@ -199,7 +199,7 @@ const pe = (o, y) => {
|
|
|
199
199
|
).length;
|
|
200
200
|
return e && !n;
|
|
201
201
|
}, !0)), Y = () => {
|
|
202
|
-
o.range && (x.value = !0, z(o.initialType || o.types[0]), le(), $(o.range), M(o.range),
|
|
202
|
+
o.range && (x.value = !0, z(o.initialType || o.types[0]), le(), $(o.range), M(o.range), S(), F());
|
|
203
203
|
};
|
|
204
204
|
de(() => {
|
|
205
205
|
Y();
|
|
@@ -216,10 +216,10 @@ const pe = (o, y) => {
|
|
|
216
216
|
e && e !== t && (x.value ? ($(e), M(e), F()) : Y());
|
|
217
217
|
}
|
|
218
218
|
), Q(D, (e) => {
|
|
219
|
-
e || (
|
|
219
|
+
e || (c.value.started = !1);
|
|
220
220
|
});
|
|
221
221
|
const J = b(() => {
|
|
222
|
-
const e =
|
|
222
|
+
const e = C.value.find(
|
|
223
223
|
(t) => t.id === i.value
|
|
224
224
|
);
|
|
225
225
|
return e ? e.name : "";
|
|
@@ -233,21 +233,21 @@ const pe = (o, y) => {
|
|
|
233
233
|
getMaxAllowedDate: se,
|
|
234
234
|
selectedPresetName: J,
|
|
235
235
|
selectedPreset: i,
|
|
236
|
-
displayError:
|
|
236
|
+
displayError: E,
|
|
237
237
|
rangeType: w,
|
|
238
238
|
selectedRange: s,
|
|
239
239
|
placement: j,
|
|
240
240
|
currentDate: P,
|
|
241
241
|
error: O,
|
|
242
|
-
presets:
|
|
242
|
+
presets: C,
|
|
243
243
|
isOpen: D,
|
|
244
244
|
popup: q,
|
|
245
|
-
selectionStart:
|
|
245
|
+
selectionStart: c,
|
|
246
246
|
initialized: x,
|
|
247
|
-
textDates:
|
|
247
|
+
textDates: T,
|
|
248
248
|
currentMonths: u,
|
|
249
249
|
displayedMonthsKeys: g,
|
|
250
|
-
initMonths:
|
|
250
|
+
initMonths: S,
|
|
251
251
|
changeType: z,
|
|
252
252
|
presetChanged: ee,
|
|
253
253
|
initRange: M,
|
|
@@ -256,7 +256,7 @@ const pe = (o, y) => {
|
|
|
256
256
|
getNavigation: ae,
|
|
257
257
|
navigationCallback: ne,
|
|
258
258
|
getSelectedRangeByType: R,
|
|
259
|
-
compareDates:
|
|
259
|
+
compareDates: L,
|
|
260
260
|
determinePreset: $,
|
|
261
261
|
selectionChanged: A,
|
|
262
262
|
checkPlacement: B,
|
|
@@ -5,6 +5,7 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<__
|
|
|
5
5
|
errorText?: string;
|
|
6
6
|
modelValue?: string;
|
|
7
7
|
testId?: string;
|
|
8
|
+
disabledButton?: boolean;
|
|
8
9
|
}>, {
|
|
9
10
|
label: string;
|
|
10
11
|
name: string;
|
|
@@ -12,6 +13,7 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<__
|
|
|
12
13
|
errorText: string;
|
|
13
14
|
modelValue: any;
|
|
14
15
|
testId: string;
|
|
16
|
+
disabledButton: boolean;
|
|
15
17
|
}>, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
16
18
|
"update:modelValue": (...args: any[]) => void;
|
|
17
19
|
change: (...args: any[]) => void;
|
|
@@ -22,6 +24,7 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<__
|
|
|
22
24
|
errorText?: string;
|
|
23
25
|
modelValue?: string;
|
|
24
26
|
testId?: string;
|
|
27
|
+
disabledButton?: boolean;
|
|
25
28
|
}>, {
|
|
26
29
|
label: string;
|
|
27
30
|
name: string;
|
|
@@ -29,6 +32,7 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<__
|
|
|
29
32
|
errorText: string;
|
|
30
33
|
modelValue: any;
|
|
31
34
|
testId: string;
|
|
35
|
+
disabledButton: boolean;
|
|
32
36
|
}>>> & {
|
|
33
37
|
onChange?: (...args: any[]) => any;
|
|
34
38
|
"onUpdate:modelValue"?: (...args: any[]) => any;
|
|
@@ -39,6 +43,7 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<__
|
|
|
39
43
|
modelValue: string;
|
|
40
44
|
helperText: string;
|
|
41
45
|
errorText: string;
|
|
46
|
+
disabledButton: boolean;
|
|
42
47
|
}>, {
|
|
43
48
|
default?(_: {}): any;
|
|
44
49
|
}>;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import o from "./RadioButton.vue2.js";
|
|
2
2
|
/* empty css */import t from "../../../_virtual/_plugin-vue_export-helper.js";
|
|
3
|
-
// import "../../../RadioButton.
|
|
4
|
-
const
|
|
3
|
+
// import "../../../RadioButton.vue_vue_type_style_index_0_scoped_dac25b9f_lang.css"; //*');
|
|
4
|
+
const a = /* @__PURE__ */ t(o, [["__scopeId", "data-v-dac25b9f"]]);
|
|
5
5
|
export {
|
|
6
|
-
|
|
6
|
+
a as default
|
|
7
7
|
};
|