@ironsource/shared-ui 2.1.8 → 2.1.9-test.1
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/ButtonDropdownTrigger.vue_vue_type_style_index_0_scoped_76c74f58_lang.css +1 -0
- package/Chart.vue_vue_type_style_index_0_scoped_ea1e5c3e_lang.css +1 -0
- package/ChartHeader.vue_vue_type_style_index_0_scoped_4c37736e_lang.css +1 -0
- package/ChartLegend.vue_vue_type_style_index_0_scoped_c0f71a49_lang.css +1 -0
- package/ChipDropdownTrigger.vue_vue_type_style_index_0_scoped_49bd7193_lang.css +1 -0
- package/DataGrid.vue_vue_type_style_index_0_scoped_0cd8af73_lang.css +1 -0
- package/DefaultDropdownTrigger.vue_vue_type_style_index_0_scoped_9fa84b26_lang.css +1 -0
- package/DropdownV4.vue_vue_type_style_index_0_scoped_360883b1_lang.css +1 -0
- package/DropdownV4.vue_vue_type_style_index_1_lang.css +1 -1
- package/MultipleDataGrid.vue_vue_type_style_index_0_scoped_020a9896_lang.css +1 -0
- package/OptionV4.vue_vue_type_style_index_0_scoped_058de532_lang.css +1 -0
- package/PopoverV4.vue_vue_type_style_index_0_scoped_74bbce13_lang.css +1 -0
- package/RadioButtonV4.vue_vue_type_style_index_0_scoped_05c7bca2_lang.css +1 -0
- package/SettingsHeader.vue_vue_type_style_index_0_scoped_9b6cd9d9_lang.css +1 -0
- package/ToggleButtonGroupAB.vue_vue_type_style_index_0_scoped_9d9e51c0_lang.css +1 -0
- package/Typography.vue_vue_type_style_index_0_scoped_992962bc_lang.css +1 -0
- package/components/alert/Alert.vue2.js +3 -2
- package/components/autocomplete/Autocomplete.vue.d.ts +1 -1
- package/components/autocomplete/index.d.ts +20 -20
- package/components/button/v4/ToggleButtonGroupAB.vue.d.ts +65 -0
- package/components/button/v4/ToggleButtonGroupAB.vue.js +7 -0
- package/components/button/v4/ToggleButtonGroupAB.vue2.js +95 -0
- package/components/button/v4/index.d.ts +170 -1
- package/components/button/v4/index.js +10 -3
- package/components/chart/Chart.vue.d.ts +5 -0
- package/components/chart/Chart.vue.js +4 -4
- package/components/chart/Chart.vue2.js +51 -49
- package/components/chart/ChartHeader.vue.d.ts +5 -0
- package/components/chart/ChartHeader.vue.js +2 -2
- package/components/chart/ChartHeader.vue2.js +35 -22
- package/components/chart/ChartLegend.vue.js +3 -3
- package/components/chart/ChartLegend.vue2.js +35 -28
- package/components/chart/SettingsHeader.vue.js +3 -3
- package/components/chart/SettingsHeader.vue2.js +33 -26
- package/components/chart/index.d.ts +20 -1
- package/components/dateRange/v4/CalendarMonthV4.vue2.js +9 -8
- package/components/dateRange/v4/DateRangeV4.vue2.js +21 -20
- package/components/dialog/v3/Dialog.vue.d.ts +1 -1
- package/components/dialog/v3/index.d.ts +5 -5
- package/components/dialog/v4/DialogV4.vue.d.ts +1 -1
- package/components/dialog/v4/DialogV4.vue2.js +6 -5
- package/components/dialog/v4/index.d.ts +5 -5
- package/components/dropdown/v3/Dropdown.vue.d.ts +2 -2
- package/components/dropdown/v3/index.d.ts +51 -51
- package/components/dropdown/v4/ButtonDropdownTrigger.vue.d.ts +17 -11
- package/components/dropdown/v4/ButtonDropdownTrigger.vue.js +3 -3
- package/components/dropdown/v4/ButtonDropdownTrigger.vue2.js +17 -9
- package/components/dropdown/v4/ChipDropdownTrigger.vue.d.ts +5 -0
- package/components/dropdown/v4/ChipDropdownTrigger.vue.js +2 -2
- package/components/dropdown/v4/ChipDropdownTrigger.vue2.js +23 -22
- package/components/dropdown/v4/DefaultDropdownTrigger.vue.d.ts +11 -0
- package/components/dropdown/v4/DefaultDropdownTrigger.vue.js +2 -2
- package/components/dropdown/v4/DefaultDropdownTrigger.vue2.js +59 -45
- package/components/dropdown/v4/DropdownV4.vue.d.ts +8 -2
- package/components/dropdown/v4/DropdownV4.vue.js +3 -3
- package/components/dropdown/v4/DropdownV4.vue2.js +121 -109
- package/components/dropdown/v4/IconButtonDropdownTrigger.vue2.js +4 -3
- package/components/dropdown/v4/OptionV4.vue.d.ts +6 -0
- package/components/dropdown/v4/OptionV4.vue.js +3 -3
- package/components/dropdown/v4/OptionV4.vue2.js +83 -70
- package/components/dropdown/v4/index.d.ts +157 -65
- package/components/emptyState/v4/EmptyStateV4.vue2.js +13 -12
- package/components/forms/FormCard.vue2.js +13 -12
- package/components/includeExclude/index.d.ts +56 -56
- package/components/input/v3/Input.vue.d.ts +1 -1
- package/components/input/v3/index.d.ts +32 -32
- package/components/input/v4/TextField.vue.d.ts +1 -1
- package/components/input/v4/index.d.ts +20 -20
- package/components/menu/Menu.vue.d.ts +1 -1
- package/components/menu/index.d.ts +20 -20
- package/components/multibar/MultiBar.vue.d.ts +1 -1
- package/components/multibar/MultiBar.vue2.js +3 -2
- package/components/multibar/index.d.ts +9 -9
- package/components/popover/v3/Popover.vue.d.ts +1 -1
- package/components/popover/v3/index.d.ts +20 -20
- package/components/popover/v4/PopoverV4.vue.d.ts +7 -3
- package/components/popover/v4/PopoverV4.vue.js +3 -3
- package/components/popover/v4/PopoverV4.vue2.js +23 -20
- package/components/popover/v4/index.d.ts +36 -24
- package/components/radioButton/v3/RadioButton.vue.d.ts +1 -1
- package/components/radioButton/v3/RadioGroup.vue.d.ts +1 -1
- package/components/radioButton/v3/index.d.ts +6 -6
- package/components/radioButton/v4/RadioButtonV4.vue.d.ts +6 -1
- package/components/radioButton/v4/RadioButtonV4.vue.js +2 -2
- package/components/radioButton/v4/RadioButtonV4.vue2.js +59 -46
- package/components/radioButton/v4/RadioGroupV4.vue.d.ts +1 -1
- package/components/radioButton/v4/index.d.ts +26 -7
- package/components/snackbar/v4/SnackbarV4.vue2.js +7 -6
- package/components/sortableList/SortableItem.vue.d.ts +1 -1
- package/components/switch/v3/index.d.ts +16 -16
- package/components/switch/v4/SwitchV4.vue2.js +6 -5
- package/components/switch/v4/index.d.ts +8 -8
- package/components/table/v4/DataGrid.vue.d.ts +5 -0
- package/components/table/v4/DataGrid.vue.js +4 -4
- package/components/table/v4/DataGrid.vue2.js +45 -44
- package/components/table/v4/ExpandRowToggle.vue2.js +6 -5
- package/components/table/v4/MultipleDataGrid.vue.d.ts +23 -2
- package/components/table/v4/MultipleDataGrid.vue.js +5 -5
- package/components/table/v4/MultipleDataGrid.vue2.js +82 -73
- package/components/table/v4/index.d.ts +98 -2
- package/components/textArea/v4/TextAreaV4.vue.d.ts +1 -1
- package/components/textArea/v4/index.d.ts +9 -9
- package/components/toggle/v3/index.d.ts +8 -8
- package/components/toggle/v4/index.d.ts +16 -16
- package/components/typography/v4/Typography.vue.js +2 -2
- package/components/typography/v4/Typography.vue2.js +1 -1
- package/consts/configs.d.ts +1 -0
- package/consts/configs.js +4 -0
- package/index.d.ts +1392 -471
- package/index.js +1 -1
- package/mocks/options.d.ts +4 -0
- package/package.json +2 -2
- package/testids/index.d.ts +8 -1
- package/testids/index.js +14 -13
- package/utils/testIds.d.ts +1 -1
- package/utils/testIds.js +6 -6
- package/ButtonDropdownTrigger.vue_vue_type_style_index_0_scoped_23e22560_lang.css +0 -1
- package/Chart.vue_vue_type_style_index_0_scoped_df85e0af_lang.css +0 -1
- package/ChartHeader.vue_vue_type_style_index_0_scoped_2e3de9c5_lang.css +0 -1
- package/ChartLegend.vue_vue_type_style_index_0_scoped_efc608f9_lang.css +0 -1
- package/ChipDropdownTrigger.vue_vue_type_style_index_0_scoped_a8fdae89_lang.css +0 -1
- package/DataGrid.vue_vue_type_style_index_0_scoped_d27e1304_lang.css +0 -1
- package/DefaultDropdownTrigger.vue_vue_type_style_index_0_scoped_fd7a490e_lang.css +0 -1
- package/DropdownV4.vue_vue_type_style_index_0_scoped_62a620ee_lang.css +0 -1
- package/MultipleDataGrid.vue_vue_type_style_index_0_scoped_cfedf78b_lang.css +0 -1
- package/OptionV4.vue_vue_type_style_index_0_scoped_77509f61_lang.css +0 -1
- package/PopoverV4.vue_vue_type_style_index_0_scoped_c54cd089_lang.css +0 -1
- package/RadioButtonV4.vue_vue_type_style_index_0_scoped_cb3a12c6_lang.css +0 -1
- package/SettingsHeader.vue_vue_type_style_index_0_scoped_1791e4fe_lang.css +0 -1
- package/Typography.vue_vue_type_style_index_0_scoped_b00956b7_lang.css +0 -1
|
@@ -1,28 +1,32 @@
|
|
|
1
|
-
import "../../../OptionV4.
|
|
1
|
+
import "../../../OptionV4.vue_vue_type_style_index_0_scoped_058de532_lang.css"; import { defineComponent as N, ref as b, watch as P, computed as V, openBlock as n, createBlock as T, unref as o, withCtx as m, createElementVNode as s, normalizeClass as f, createCommentVNode as i, createElementBlock as a, renderSlot as d, createVNode as c, toDisplayString as k, createTextVNode as x, withModifiers as w } from "vue";
|
|
2
2
|
import "../../typography/Heading.vue.js";
|
|
3
|
-
import
|
|
4
|
-
import
|
|
3
|
+
import L from "../../typography/Text.vue.js";
|
|
4
|
+
import A from "../../checkbox/v4/CheckboxV4.vue.js";
|
|
5
5
|
import y from "../../icon/v4/IconV4.vue.js";
|
|
6
6
|
import "../../icon/v4/IconFlag.vue.js";
|
|
7
|
-
import { NOOP as
|
|
8
|
-
import { optionCommon as
|
|
9
|
-
import
|
|
7
|
+
import { NOOP as D } from "@vue/shared";
|
|
8
|
+
import { optionCommon as F } from "../common/Option.common.js";
|
|
9
|
+
import I from "../../typography/v4/Typography.vue.js";
|
|
10
10
|
import R from "../../tooltip/v4/TooltipV4.vue.js";
|
|
11
|
-
import { isElementTruncated as
|
|
12
|
-
import { promiseTimeout as
|
|
11
|
+
import { isElementTruncated as j } from "../../../utils/text.js";
|
|
12
|
+
import { promiseTimeout as H } from "@vueuse/core";
|
|
13
|
+
import { SHARED_ASSETS_CDN_DOMAIN as U } from "../../../consts/configs.js";
|
|
13
14
|
const q = {
|
|
14
15
|
key: 1,
|
|
15
16
|
class: "image"
|
|
16
|
-
},
|
|
17
|
+
}, G = ["src"], J = {
|
|
17
18
|
key: 2,
|
|
19
|
+
class: "flag"
|
|
20
|
+
}, Q = ["src"], W = {
|
|
21
|
+
key: 3,
|
|
18
22
|
class: "start-icon"
|
|
19
|
-
},
|
|
23
|
+
}, X = { class: "main-text" }, Y = {
|
|
20
24
|
key: 0,
|
|
21
25
|
class: "caption-text"
|
|
22
|
-
},
|
|
23
|
-
key:
|
|
26
|
+
}, Z = {
|
|
27
|
+
key: 4,
|
|
24
28
|
class: "end-icon"
|
|
25
|
-
},
|
|
29
|
+
}, _ = ["onClick"], ee = { key: 0 }, ye = /* @__PURE__ */ N({
|
|
26
30
|
__name: "OptionV4",
|
|
27
31
|
props: {
|
|
28
32
|
option: { default: null },
|
|
@@ -44,131 +48,140 @@ const q = {
|
|
|
44
48
|
stopOptionClickEventPropagation: { type: Boolean, default: !1 },
|
|
45
49
|
optionTwoLinesVariant: { default: void 0 },
|
|
46
50
|
optionTwoLinesKey: { default: void 0 },
|
|
47
|
-
treeChildShown: { type: Boolean, default: !1 }
|
|
51
|
+
treeChildShown: { type: Boolean, default: !1 },
|
|
52
|
+
optionFlagKey: { default: null }
|
|
48
53
|
},
|
|
49
54
|
emits: ["toggleTreeCollapse"],
|
|
50
|
-
setup(e, { emit:
|
|
51
|
-
const
|
|
52
|
-
|
|
53
|
-
},
|
|
54
|
-
|
|
55
|
-
await
|
|
55
|
+
setup(e, { emit: $ }) {
|
|
56
|
+
const l = e, { selected: p, isMulti: g, id: O, onClick: B, api: v } = F(l), S = (t) => {
|
|
57
|
+
l.stopOptionClickEventPropagation && t.stopPropagation(), l.disabled ? D() : B(t);
|
|
58
|
+
}, r = b(null), h = b(!1);
|
|
59
|
+
P([() => l.treeChildShown, r], async () => {
|
|
60
|
+
await H(100), h.value = r.value && j(r.value);
|
|
56
61
|
});
|
|
57
|
-
const
|
|
58
|
-
|
|
59
|
-
};
|
|
60
|
-
return (t,
|
|
61
|
-
text:
|
|
62
|
-
"test-id":
|
|
62
|
+
const E = (t) => t && typeof t == "object" && "optionTooltipText" in t ? t.optionTooltipText : h.value ? t[l.nameKey] : "", z = (t) => t && typeof t == "object" && "optionTooltipTestId" in t ? t.optionTooltipTestId : null, M = () => {
|
|
63
|
+
$("toggleTreeCollapse", l.option);
|
|
64
|
+
}, C = V(() => l.optionFlagKey ? `${U}/assets/flags/v4/${l.option[l.optionFlagKey]?.toLowerCase()}.svg` : null);
|
|
65
|
+
return (t, u) => (n(), T(o(R), {
|
|
66
|
+
text: E(e.option),
|
|
67
|
+
"test-id": z(e.option),
|
|
63
68
|
placement: e.toolTipPlacement,
|
|
64
69
|
class: "tooltip-option"
|
|
65
70
|
}, {
|
|
66
|
-
default:
|
|
71
|
+
default: m(() => [
|
|
67
72
|
s("div", {
|
|
68
73
|
ref: "el",
|
|
69
|
-
class:
|
|
74
|
+
class: f(["item-container", {
|
|
70
75
|
"item-container--disabled": e.disabled,
|
|
71
76
|
"item-container--active": e.nameKey ? !1 : e.active,
|
|
72
77
|
"item-container--selected": o(p),
|
|
73
|
-
"item-container--multi": o(
|
|
78
|
+
"item-container--multi": o(g)
|
|
74
79
|
}])
|
|
75
80
|
}, [
|
|
76
81
|
s("div", {
|
|
77
|
-
class:
|
|
78
|
-
"item--multi": o(
|
|
82
|
+
class: f(["item", {
|
|
83
|
+
"item--multi": o(g),
|
|
79
84
|
"item--with-icon": t.$slots["icon-start"] || t.$slots.image
|
|
80
85
|
}])
|
|
81
86
|
}, [
|
|
82
|
-
o(
|
|
87
|
+
o(g) ? (n(), T(o(A), {
|
|
83
88
|
key: 0,
|
|
84
|
-
id: o(
|
|
89
|
+
id: o(O).toString(),
|
|
85
90
|
tabindex: "-1",
|
|
86
91
|
class: "checkbox",
|
|
87
92
|
"is-checked": o(p),
|
|
88
93
|
"is-indeterminate": e.isIndeterminate,
|
|
89
|
-
onClick:
|
|
90
|
-
}, null, 8, ["id", "is-checked", "is-indeterminate"])) :
|
|
91
|
-
t.$slots.image || e.imageKey ? (
|
|
92
|
-
|
|
93
|
-
e.imageKey ? (
|
|
94
|
+
onClick: u[0] || (u[0] = (K) => S(K))
|
|
95
|
+
}, null, 8, ["id", "is-checked", "is-indeterminate"])) : i("", !0),
|
|
96
|
+
t.$slots.image || e.imageKey ? (n(), a("div", q, [
|
|
97
|
+
d(t.$slots, "image", {}, () => [
|
|
98
|
+
e.imageKey ? (n(), a("img", {
|
|
94
99
|
key: 0,
|
|
95
100
|
src: e.option[e.imageKey]
|
|
96
|
-
}, null, 8,
|
|
101
|
+
}, null, 8, G)) : i("", !0)
|
|
102
|
+
], !0)
|
|
103
|
+
])) : i("", !0),
|
|
104
|
+
t.$slots.flag || e.optionFlagKey ? (n(), a("div", J, [
|
|
105
|
+
d(t.$slots, "flag", {}, () => [
|
|
106
|
+
o(C) ? (n(), a("img", {
|
|
107
|
+
key: 0,
|
|
108
|
+
src: o(C)
|
|
109
|
+
}, null, 8, Q)) : i("", !0)
|
|
97
110
|
], !0)
|
|
98
|
-
])) :
|
|
99
|
-
t.$slots["icon-start"] || e.iconKey ? (
|
|
100
|
-
|
|
111
|
+
])) : i("", !0),
|
|
112
|
+
t.$slots["icon-start"] || e.iconKey ? (n(), a("div", W, [
|
|
113
|
+
d(t.$slots, "icon-start", {}, () => [
|
|
101
114
|
c(o(y), {
|
|
102
115
|
type: e.iconType,
|
|
103
116
|
name: e.option[e.iconKey],
|
|
104
117
|
size: e.iconType === "regular" ? "20px" : "16px"
|
|
105
118
|
}, null, 8, ["type", "name", "size"])
|
|
106
119
|
], !0)
|
|
107
|
-
])) :
|
|
120
|
+
])) : i("", !0),
|
|
108
121
|
s("div", {
|
|
109
122
|
ref_key: "textContainerRef",
|
|
110
|
-
ref:
|
|
123
|
+
ref: r,
|
|
111
124
|
class: "text-container"
|
|
112
125
|
}, [
|
|
113
|
-
c(o(
|
|
126
|
+
c(o(I), {
|
|
114
127
|
class: "option-text",
|
|
115
128
|
variant: "body2"
|
|
116
129
|
}, {
|
|
117
|
-
default:
|
|
118
|
-
|
|
130
|
+
default: m(() => [
|
|
131
|
+
d(t.$slots, "default", {}, () => [
|
|
119
132
|
s("div", {
|
|
120
|
-
class:
|
|
133
|
+
class: f(`option-content-${e.optionTwoLinesVariant || "horizontal"}`)
|
|
121
134
|
}, [
|
|
122
|
-
s("div",
|
|
123
|
-
e.optionTwoLinesKey ? (
|
|
124
|
-
c(o(
|
|
125
|
-
default:
|
|
126
|
-
|
|
135
|
+
s("div", X, k(e.option[e.nameKey]), 1),
|
|
136
|
+
e.optionTwoLinesKey ? (n(), a("div", Y, [
|
|
137
|
+
c(o(I), { variant: "caption" }, {
|
|
138
|
+
default: m(() => [
|
|
139
|
+
x(k(e.option[e.optionTwoLinesKey]), 1)
|
|
127
140
|
]),
|
|
128
141
|
_: 1
|
|
129
142
|
})
|
|
130
|
-
])) :
|
|
143
|
+
])) : i("", !0)
|
|
131
144
|
], 2)
|
|
132
145
|
], !0)
|
|
133
146
|
]),
|
|
134
147
|
_: 3
|
|
135
148
|
}),
|
|
136
|
-
e.subtitle ? (
|
|
149
|
+
e.subtitle ? (n(), T(o(L), {
|
|
137
150
|
key: 0,
|
|
138
151
|
class: "subtitle",
|
|
139
152
|
size: "xs"
|
|
140
153
|
}, {
|
|
141
|
-
default:
|
|
142
|
-
|
|
154
|
+
default: m(() => [
|
|
155
|
+
x(k(e.subtitle), 1)
|
|
143
156
|
]),
|
|
144
157
|
_: 1
|
|
145
|
-
})) :
|
|
158
|
+
})) : i("", !0)
|
|
146
159
|
], 512),
|
|
147
|
-
t.$slots["icon-end"] || e.endIconKey && e.option[e.endIconKey] ? (
|
|
148
|
-
|
|
160
|
+
t.$slots["icon-end"] || e.endIconKey && e.option[e.endIconKey] ? (n(), a("div", Z, [
|
|
161
|
+
d(t.$slots, "icon-end", {}, () => [
|
|
149
162
|
c(o(y), {
|
|
150
163
|
type: e.endIconType,
|
|
151
164
|
name: e.option[e.endIconKey],
|
|
152
165
|
size: e.endIconType === "regular" || e.endIconType === "ab-test" ? "20px" : "16px"
|
|
153
166
|
}, null, 8, ["type", "name", "size"])
|
|
154
167
|
], !0)
|
|
155
|
-
])) :
|
|
156
|
-
e.treeMainOption ? (
|
|
157
|
-
key:
|
|
168
|
+
])) : i("", !0),
|
|
169
|
+
e.treeMainOption ? (n(), a("div", {
|
|
170
|
+
key: 5,
|
|
158
171
|
class: "tree-main-arrow-wrapper",
|
|
159
|
-
onClick:
|
|
172
|
+
onClick: w(M, ["stop"])
|
|
160
173
|
}, [
|
|
161
174
|
c(o(y), {
|
|
162
175
|
name: "caret-down",
|
|
163
176
|
size: "16px",
|
|
164
|
-
class:
|
|
177
|
+
class: f(`app-trigger--icon ${e.treeMainOptionExpanded && "expanded"}`)
|
|
165
178
|
}, null, 8, ["class"])
|
|
166
|
-
], 8,
|
|
179
|
+
], 8, _)) : i("", !0)
|
|
167
180
|
], 2),
|
|
168
|
-
o(v).clearable && o(p) ? (
|
|
181
|
+
o(v).clearable && o(p) ? (n(), a("div", ee, [
|
|
169
182
|
s("button", {
|
|
170
183
|
class: "clear-button",
|
|
171
|
-
onClick:
|
|
184
|
+
onClick: u[1] || (u[1] = w((K) => o(v).clearSelection(), ["prevent", "stop"]))
|
|
172
185
|
}, [
|
|
173
186
|
c(o(y), {
|
|
174
187
|
name: "close",
|
|
@@ -176,7 +189,7 @@ const q = {
|
|
|
176
189
|
height: "8"
|
|
177
190
|
})
|
|
178
191
|
])
|
|
179
|
-
])) :
|
|
192
|
+
])) : i("", !0)
|
|
180
193
|
], 2)
|
|
181
194
|
]),
|
|
182
195
|
_: 3
|
|
@@ -184,5 +197,5 @@ const q = {
|
|
|
184
197
|
}
|
|
185
198
|
});
|
|
186
199
|
export {
|
|
187
|
-
|
|
200
|
+
ye as default
|
|
188
201
|
};
|