@ironsource/shared-ui 2.2.0-rc.48 → 2.2.0-rc.50
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/ChipDropdownTrigger.vue_vue_type_style_index_0_scoped_38354f10_lang.css +1 -0
- package/DataGridMenu.vue_vue_type_style_index_0_scoped_ddfaf207_lang.css +1 -0
- package/DateRangeV4.vue_vue_type_style_index_0_scoped_f8826716_lang.css +1 -0
- package/DropdownV4.vue_vue_type_style_index_0_scoped_526bf0a1_lang.css +1 -0
- package/FieldLabel.vue_vue_type_style_index_0_scoped_921d4087_lang.css +1 -0
- package/HelpText.vue_vue_type_style_index_0_scoped_641c2356_lang.css +1 -0
- package/IconButtonDropdownTrigger.vue_vue_type_style_index_0_scoped_99e51ecc_lang.css +1 -0
- package/InlineCopy.vue_vue_type_style_index_0_scoped_9fa1921a_lang.css +1 -0
- package/Link.vue_vue_type_style_index_0_scoped_fe0e7f6f_lang.css +1 -0
- package/OptionV4.vue_vue_type_style_index_0_scoped_771e1980_lang.css +1 -0
- package/README.md +2 -2
- package/SearchV4.vue_vue_type_style_index_0_scoped_d6c42f4b_lang.css +1 -0
- package/TabsV4.vue_vue_type_style_index_0_scoped_f9433b11_lang.css +1 -0
- package/TextField.vue_vue_type_style_index_0_scoped_28fab783_lang.css +1 -0
- package/ToggleV4.vue_vue_type_style_index_0_scoped_a4aa32fb_lang.css +1 -0
- package/TooltipV4.vue_vue_type_style_index_0_scoped_a8aebfee_lang.css +1 -0
- package/components/autocomplete/index.d.ts +16 -16
- package/components/columnPicker/ColumnPicker.vue.d.ts +1 -1
- package/components/columnPicker/index.d.ts +20 -20
- package/components/dateRange/v4/DateRangeV4.vue.js +2 -2
- package/components/dateRange/v4/DateRangeV4.vue2.js +27 -28
- package/components/dropdown/common/Dropdown.common.js +274 -351
- package/components/dropdown/v3/Dropdown.vue.d.ts +5 -5
- package/components/dropdown/v3/index.d.ts +77 -77
- package/components/dropdown/v4/ChipDropdownTrigger.vue.js +3 -3
- package/components/dropdown/v4/ChipDropdownTrigger.vue2.js +32 -38
- package/components/dropdown/v4/ConditionalDropdown.vue.d.ts +1 -1
- package/components/dropdown/v4/DropdownV4.vue.d.ts +41 -50
- package/components/dropdown/v4/DropdownV4.vue.js +2 -2
- package/components/dropdown/v4/DropdownV4.vue2.js +216 -237
- package/components/dropdown/v4/IconButtonDropdownTrigger.vue.d.ts +0 -5
- package/components/dropdown/v4/IconButtonDropdownTrigger.vue.js +3 -3
- package/components/dropdown/v4/IconButtonDropdownTrigger.vue2.js +9 -12
- package/components/dropdown/v4/OptionV4.vue.js +3 -3
- package/components/dropdown/v4/OptionV4.vue2.js +12 -12
- package/components/dropdown/v4/TreeDropdown.vue.d.ts +1 -1
- package/components/dropdown/v4/index.d.ts +2102 -2130
- package/components/helpText/HelpText.vue.js +3 -3
- package/components/helpText/HelpText.vue2.js +10 -11
- package/components/includeExclude/IncludeExclude.vue.d.ts +2 -2
- package/components/includeExclude/IncludeExcludeDragDrop.vue.d.ts +2 -2
- package/components/includeExclude/index.d.ts +54 -54
- package/components/inlineCopy/InlineCopy.vue.d.ts +0 -5
- package/components/inlineCopy/InlineCopy.vue.js +3 -3
- package/components/inlineCopy/InlineCopy.vue2.js +53 -54
- package/components/inlineCopy/index.d.ts +0 -9
- package/components/input/v4/TextField.vue.d.ts +0 -5
- package/components/input/v4/TextField.vue.js +2 -2
- package/components/input/v4/TextField.vue2.js +19 -22
- package/components/input/v4/index.d.ts +1 -20
- package/components/link/Link.vue.js +5 -5
- package/components/link/Link.vue2.js +21 -30
- package/components/search/v4/SearchV4.vue.d.ts +0 -5
- package/components/search/v4/SearchV4.vue.js +5 -5
- package/components/search/v4/SearchV4.vue2.js +18 -23
- package/components/search/v4/index.d.ts +0 -9
- package/components/shared/FieldLabel.vue.js +3 -3
- package/components/shared/FieldLabel.vue2.js +8 -9
- package/components/table/v4/DataGridMenu.vue.d.ts +0 -5
- package/components/table/v4/DataGridMenu.vue.js +5 -5
- package/components/table/v4/DataGridMenu.vue2.js +22 -28
- package/components/table/v4/index.d.ts +0 -9
- package/components/tabs/v4/TabsV4.vue.d.ts +0 -5
- package/components/tabs/v4/TabsV4.vue.js +3 -3
- package/components/tabs/v4/TabsV4.vue2.js +43 -74
- package/components/tabs/v4/index.d.ts +1 -20
- package/components/toggle/v4/ToggleV4.vue.d.ts +0 -5
- package/components/toggle/v4/ToggleV4.vue.js +3 -3
- package/components/toggle/v4/ToggleV4.vue2.js +41 -50
- package/components/toggle/v4/index.d.ts +1 -20
- package/components/tooltip/v4/TooltipV4.vue.d.ts +1 -14
- package/components/tooltip/v4/TooltipV4.vue.js +2 -2
- package/components/tooltip/v4/TooltipV4.vue2.js +63 -85
- package/components/tooltip/v4/index.d.ts +4 -51
- package/index.d.ts +2404 -2722
- package/index.js +1 -1
- package/package.json +1 -5
- package/ChipDropdownTrigger.vue_vue_type_style_index_0_scoped_5a645cc9_lang.css +0 -1
- package/DataGridMenu.vue_vue_type_style_index_0_scoped_b7e65177_lang.css +0 -1
- package/DateRangeV4.vue_vue_type_style_index_0_scoped_bb44cdf8_lang.css +0 -1
- package/DropdownV4.vue_vue_type_style_index_0_scoped_f44f2402_lang.css +0 -1
- package/FieldLabel.vue_vue_type_style_index_0_scoped_960ea8b1_lang.css +0 -1
- package/HelpText.vue_vue_type_style_index_0_scoped_b5caf7cd_lang.css +0 -1
- package/IconButtonDropdownTrigger.vue_vue_type_style_index_0_scoped_2a5345ef_lang.css +0 -1
- package/InlineCopy.vue_vue_type_style_index_0_scoped_8cb01c9d_lang.css +0 -1
- package/Link.vue_vue_type_style_index_0_scoped_c4345b08_lang.css +0 -1
- package/OptionV4.vue_vue_type_style_index_0_scoped_d48a9318_lang.css +0 -1
- package/SearchV4.vue_vue_type_style_index_0_scoped_e1a33934_lang.css +0 -1
- package/TabsV4.vue_vue_type_style_index_0_scoped_9747c9da_lang.css +0 -1
- package/TextField.vue_vue_type_style_index_0_scoped_f4275491_lang.css +0 -1
- package/ToggleV4.vue_vue_type_style_index_0_scoped_fbbae882_lang.css +0 -1
- package/TooltipV4.vue_vue_type_style_index_0_scoped_22e25f74_lang.css +0 -1
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import "../../../DataGridMenu.
|
|
2
|
-
import
|
|
1
|
+
import "../../../DataGridMenu.vue_vue_type_style_index_0_scoped_ddfaf207_lang.css"; import { defineComponent as u, onBeforeUnmount as f, openBlock as x, createBlock as w, unref as o, withCtx as r, createVNode as c, createSlots as I, createTextVNode as v, toDisplayString as M } from "vue";
|
|
2
|
+
import g from "../../dropdown/v4/DropdownV4.vue.js";
|
|
3
3
|
import "../../dropdown/v4/DefaultDropdownTrigger.vue.js";
|
|
4
4
|
import "../../dropdown/v4/IconButtonDropdownTrigger.vue.js";
|
|
5
5
|
import "../../dropdown/v4/ChipDropdownTrigger.vue.js";
|
|
@@ -7,53 +7,47 @@ import "../../dropdown/v4/AppDropdownTrigger.vue.js";
|
|
|
7
7
|
import "../../dropdown/v4/ButtonDropdownTrigger.vue.js";
|
|
8
8
|
import "../../dropdown/v4/ButtonFilterDropdownTrigger.vue.js";
|
|
9
9
|
import "../../dropdown/v4/TreeDropdown.vue.js";
|
|
10
|
-
import
|
|
10
|
+
import C from "../../dropdown/v4/OptionV4.vue.js";
|
|
11
11
|
import "../../dropdown/v4/ConditionalDropdown.vue.js";
|
|
12
|
-
import
|
|
12
|
+
import k from "../../icon/v4/IconV4.vue.js";
|
|
13
13
|
import "../../icon/v4/IconFlag.vue.js";
|
|
14
|
-
import { useTableContext as
|
|
15
|
-
const
|
|
14
|
+
import { useTableContext as y } from "../common/TableContext.js";
|
|
15
|
+
const h = /* @__PURE__ */ u({
|
|
16
16
|
__name: "DataGridMenu",
|
|
17
17
|
props: {
|
|
18
18
|
menuItems: { default: () => [] },
|
|
19
19
|
rowIndex: { default: null },
|
|
20
|
-
placement: { default: "left-start" }
|
|
21
|
-
ariaLabel: { default: "More options" }
|
|
20
|
+
placement: { default: "left-start" }
|
|
22
21
|
},
|
|
23
22
|
emits: ["selected"],
|
|
24
23
|
setup(t, { emit: d }) {
|
|
25
|
-
const
|
|
26
|
-
|
|
27
|
-
},
|
|
28
|
-
|
|
24
|
+
const n = t, i = y("DataGridMenu"), a = (s) => s.text, p = () => {
|
|
25
|
+
n.rowIndex && i.setActiveMenuRow(n.rowIndex);
|
|
26
|
+
}, m = () => {
|
|
27
|
+
n.rowIndex && i.setActiveMenuRow(null);
|
|
29
28
|
};
|
|
30
|
-
return
|
|
29
|
+
return f(m), (s, l) => (x(), w(o(g), {
|
|
31
30
|
class: "data-grid-menu",
|
|
32
31
|
options: t.menuItems,
|
|
33
|
-
"display-value":
|
|
34
|
-
"aria-label": t.ariaLabel,
|
|
32
|
+
"display-value": a,
|
|
35
33
|
"predefined-trigger": "icon-button",
|
|
36
34
|
placement: t.placement,
|
|
37
35
|
skidding: -4,
|
|
38
|
-
"onUpdate:selected":
|
|
36
|
+
"onUpdate:selected": l[0] || (l[0] = (e) => d("selected", e)),
|
|
39
37
|
onOpened: p,
|
|
40
|
-
onClosed:
|
|
38
|
+
onClosed: m
|
|
41
39
|
}, {
|
|
42
|
-
default: r(({ option: e
|
|
43
|
-
c(
|
|
44
|
-
option: e,
|
|
45
|
-
active: u,
|
|
46
|
-
"selected-prop": f
|
|
47
|
-
}, I({
|
|
40
|
+
default: r(({ option: e }) => [
|
|
41
|
+
c(o(C), { option: e }, I({
|
|
48
42
|
default: r(() => [
|
|
49
|
-
|
|
43
|
+
v(" " + M(a(e)), 1)
|
|
50
44
|
]),
|
|
51
45
|
_: 2
|
|
52
46
|
}, [
|
|
53
47
|
e.icon ? {
|
|
54
48
|
name: "icon-start",
|
|
55
49
|
fn: r(() => [
|
|
56
|
-
c(
|
|
50
|
+
c(o(k), {
|
|
57
51
|
class: "menu-icon",
|
|
58
52
|
name: e.icon,
|
|
59
53
|
size: "20px"
|
|
@@ -61,12 +55,12 @@ const q = /* @__PURE__ */ x({
|
|
|
61
55
|
]),
|
|
62
56
|
key: "0"
|
|
63
57
|
} : void 0
|
|
64
|
-
]), 1032, ["option"
|
|
58
|
+
]), 1032, ["option"])
|
|
65
59
|
]),
|
|
66
60
|
_: 1
|
|
67
|
-
}, 8, ["options", "
|
|
61
|
+
}, 8, ["options", "placement"]));
|
|
68
62
|
}
|
|
69
63
|
});
|
|
70
64
|
export {
|
|
71
|
-
|
|
65
|
+
h as default
|
|
72
66
|
};
|
|
@@ -9,10 +9,6 @@ declare const DataGridTypes: () => (import("vue").DefineComponent<{
|
|
|
9
9
|
type: import("vue").PropType<import("floating-vue").Placement>;
|
|
10
10
|
default: string;
|
|
11
11
|
};
|
|
12
|
-
ariaLabel: {
|
|
13
|
-
type: import("vue").PropType<string>;
|
|
14
|
-
default: string;
|
|
15
|
-
};
|
|
16
12
|
rowIndex: {
|
|
17
13
|
type: import("vue").PropType<number>;
|
|
18
14
|
default: any;
|
|
@@ -29,10 +25,6 @@ declare const DataGridTypes: () => (import("vue").DefineComponent<{
|
|
|
29
25
|
type: import("vue").PropType<import("floating-vue").Placement>;
|
|
30
26
|
default: string;
|
|
31
27
|
};
|
|
32
|
-
ariaLabel: {
|
|
33
|
-
type: import("vue").PropType<string>;
|
|
34
|
-
default: string;
|
|
35
|
-
};
|
|
36
28
|
rowIndex: {
|
|
37
29
|
type: import("vue").PropType<number>;
|
|
38
30
|
default: any;
|
|
@@ -46,7 +38,6 @@ declare const DataGridTypes: () => (import("vue").DefineComponent<{
|
|
|
46
38
|
onSelected?: (option: unknown) => any;
|
|
47
39
|
}, {
|
|
48
40
|
placement: import("floating-vue").Placement;
|
|
49
|
-
ariaLabel: string;
|
|
50
41
|
rowIndex: number;
|
|
51
42
|
menuItems: import("../common/Table.types").MenuItem[];
|
|
52
43
|
}> | import("vue").DefineComponent<{
|
|
@@ -4,12 +4,10 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<__
|
|
|
4
4
|
selectedTab: string | number;
|
|
5
5
|
variant?: "page" | "card";
|
|
6
6
|
testId?: string;
|
|
7
|
-
ariaLabel?: string;
|
|
8
7
|
}>, {
|
|
9
8
|
tabsList: () => any[];
|
|
10
9
|
variant: string;
|
|
11
10
|
testId: string;
|
|
12
|
-
ariaLabel: any;
|
|
13
11
|
}>, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
14
12
|
"update:selectedTab": (tabId: string | number) => void;
|
|
15
13
|
}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<{
|
|
@@ -17,18 +15,15 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<__
|
|
|
17
15
|
selectedTab: string | number;
|
|
18
16
|
variant?: "page" | "card";
|
|
19
17
|
testId?: string;
|
|
20
|
-
ariaLabel?: string;
|
|
21
18
|
}>, {
|
|
22
19
|
tabsList: () => any[];
|
|
23
20
|
variant: string;
|
|
24
21
|
testId: string;
|
|
25
|
-
ariaLabel: any;
|
|
26
22
|
}>>> & {
|
|
27
23
|
"onUpdate:selectedTab"?: (tabId: string | number) => any;
|
|
28
24
|
}, {
|
|
29
25
|
testId: string;
|
|
30
26
|
variant: "page" | "card";
|
|
31
|
-
ariaLabel: string;
|
|
32
27
|
tabsList: Tab[];
|
|
33
28
|
}>, {
|
|
34
29
|
"tab-icon"?(_: {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import o from "./TabsV4.vue2.js";
|
|
2
2
|
/* empty css */import _ from "../../../_virtual/_plugin-vue_export-helper.js";
|
|
3
|
-
// import "../../../TabsV4.
|
|
4
|
-
const
|
|
3
|
+
// import "../../../TabsV4.vue_vue_type_style_index_0_scoped_f9433b11_lang.css"; //*');
|
|
4
|
+
const p = /* @__PURE__ */ _(o, [["__scopeId", "data-v-f9433b11"]]);
|
|
5
5
|
export {
|
|
6
|
-
|
|
6
|
+
p as default
|
|
7
7
|
};
|
|
@@ -1,103 +1,72 @@
|
|
|
1
|
-
import "../../../TabsV4.
|
|
2
|
-
import
|
|
3
|
-
import { TabsTestIdModifiers as
|
|
4
|
-
import { tabsCommon as
|
|
5
|
-
import { useTestIdAttrs as
|
|
6
|
-
const
|
|
1
|
+
import "../../../TabsV4.vue_vue_type_style_index_0_scoped_f9433b11_lang.css"; import { defineComponent as x, useCssVars as y, ref as l, watch as C, nextTick as $, openBlock as o, createElementBlock as c, mergeProps as w, unref as s, Fragment as A, renderList as S, normalizeClass as g, renderSlot as V, createBlock as B, withCtx as M, createTextVNode as N, toDisplayString as R, createCommentVNode as _, pushScopeId as E, popScopeId as P, createElementVNode as W } from "vue";
|
|
2
|
+
import H from "../../typography/v4/Typography.vue.js";
|
|
3
|
+
import { TabsTestIdModifiers as m } from "../../../testids/index.js";
|
|
4
|
+
import { tabsCommon as z } from "../common/tabsCommon.js";
|
|
5
|
+
import { useTestIdAttrs as D } from "../../../utils/testIds.js";
|
|
6
|
+
const F = (t) => (E("data-v-f9433b11"), t = t(), P(), t), U = ["data-testid", "onClick", "onMouseover"], j = /* @__PURE__ */ F(() => /* @__PURE__ */ W("div", { class: "tabs-border-line" }, null, -1)), Q = /* @__PURE__ */ x({
|
|
7
7
|
__name: "TabsV4",
|
|
8
8
|
props: {
|
|
9
9
|
tabsList: { default: () => [] },
|
|
10
10
|
selectedTab: null,
|
|
11
11
|
variant: { default: "card" },
|
|
12
|
-
testId: { default: "" }
|
|
13
|
-
ariaLabel: { default: void 0 }
|
|
12
|
+
testId: { default: "" }
|
|
14
13
|
},
|
|
15
14
|
emits: ["update:selectedTab"],
|
|
16
|
-
setup(
|
|
17
|
-
const
|
|
18
|
-
|
|
19
|
-
"
|
|
20
|
-
"
|
|
15
|
+
setup(t, { emit: p }) {
|
|
16
|
+
const r = t;
|
|
17
|
+
y((a) => ({
|
|
18
|
+
"167b065e": v.value,
|
|
19
|
+
"8cfadb62": b.value
|
|
21
20
|
}));
|
|
22
|
-
const { skipUnwrap:
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
() => a.tabsList.findIndex((t) => !t.disabled)
|
|
26
|
-
), S = (t, i) => t.disabled ? -1 : C.value ? l(t) ? 0 : -1 : i === E.value ? 0 : -1, $ = (t) => {
|
|
27
|
-
x(() => {
|
|
28
|
-
f.value?.children?.[t]?.focus();
|
|
29
|
-
});
|
|
30
|
-
}, R = (t, i) => {
|
|
31
|
-
const { key: e } = t;
|
|
32
|
-
if (e === "Enter" || e === " " || e === "Spacebar") {
|
|
33
|
-
t.preventDefault(), a.tabsList[i]?.disabled || b(a.tabsList[i]);
|
|
34
|
-
return;
|
|
35
|
-
}
|
|
36
|
-
if (!["ArrowRight", "ArrowLeft", "Home", "End"].includes(e))
|
|
37
|
-
return;
|
|
38
|
-
t.preventDefault();
|
|
39
|
-
const s = a.tabsList.map((u, V) => u.disabled ? -1 : V).filter((u) => u !== -1);
|
|
40
|
-
if (!s.length)
|
|
41
|
-
return;
|
|
42
|
-
const o = s.indexOf(i);
|
|
43
|
-
let d = i;
|
|
44
|
-
e === "ArrowRight" ? d = s[(o + 1) % s.length] : e === "ArrowLeft" ? d = s[(o - 1 + s.length) % s.length] : e === "Home" ? d = s[0] : e === "End" && (d = s[s.length - 1]), b(a.tabsList[d]), $(d);
|
|
45
|
-
}, h = m(), T = m();
|
|
46
|
-
return M(
|
|
47
|
-
[() => a.variant, () => a.selectedTab, () => a.tabsList],
|
|
21
|
+
const { skipUnwrap: T, selectTab: I, setHover: L, clearHover: u, getSelectedTabIndex: k } = z(r, p), f = l(null), h = D(r.testId, m), i = (a) => a.id === r.selectedTab, b = l(), v = l();
|
|
22
|
+
return C(
|
|
23
|
+
[() => r.variant, () => r.selectedTab, () => r.tabsList],
|
|
48
24
|
async () => {
|
|
49
|
-
const
|
|
50
|
-
if (
|
|
25
|
+
const a = k();
|
|
26
|
+
if (a === -1)
|
|
51
27
|
return;
|
|
52
|
-
await
|
|
53
|
-
const e = Array.from(f.value?.children || []).at(
|
|
54
|
-
|
|
28
|
+
await $();
|
|
29
|
+
const e = Array.from(f.value?.children || []).at(a);
|
|
30
|
+
b.value = e?.clientWidth + "px", v.value = e?.offsetLeft + "px";
|
|
55
31
|
},
|
|
56
32
|
{ immediate: !0 }
|
|
57
|
-
), (
|
|
33
|
+
), (a, n) => (o(), c("ul", w({
|
|
58
34
|
ref_key: "tabsListRef",
|
|
59
35
|
ref: f,
|
|
60
|
-
class: ["tabs-list", [`tabs-list--${
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
}, n(A)[n(p).WRAPPER]), [
|
|
64
|
-
(c(!0), v(_, null, D(r.tabsList, (e, s) => (c(), v("li", {
|
|
36
|
+
class: ["tabs-list", [`tabs-list--${t.variant}`]]
|
|
37
|
+
}, s(h)[s(m).WRAPPER]), [
|
|
38
|
+
(o(!0), c(A, null, S(t.tabsList, (e) => (o(), c("li", {
|
|
65
39
|
ref_for: !0,
|
|
66
|
-
ref:
|
|
40
|
+
ref: s(T).tabsNewList,
|
|
67
41
|
key: e.id,
|
|
68
|
-
class:
|
|
42
|
+
class: g(["tab-item", {
|
|
69
43
|
"tab-item--disabled": e.disabled,
|
|
70
|
-
"tab-item--active":
|
|
44
|
+
"tab-item--active": i(e)
|
|
71
45
|
}]),
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
onClick: (o) => n(b)(e),
|
|
78
|
-
onKeydown: (o) => R(o, s),
|
|
79
|
-
onMouseover: (o) => n(y)(e),
|
|
80
|
-
onMouseleave: i[0] || (i[0] = //@ts-ignore
|
|
81
|
-
(...o) => n(L) && n(L)(...o))
|
|
46
|
+
"data-testid": t.testId ? `${t.testId}-${s(m).TAB}-${e.id}` : void 0,
|
|
47
|
+
onClick: (d) => s(I)(e),
|
|
48
|
+
onMouseover: (d) => s(L)(e),
|
|
49
|
+
onMouseleave: n[0] || (n[0] = //@ts-ignore
|
|
50
|
+
(...d) => s(u) && s(u)(...d))
|
|
82
51
|
}, [
|
|
83
|
-
|
|
52
|
+
V(a.$slots, "tab-icon", {
|
|
84
53
|
tab: e,
|
|
85
|
-
active:
|
|
54
|
+
active: i(e)
|
|
86
55
|
}, void 0, !0),
|
|
87
|
-
e.name ? (
|
|
56
|
+
e.name ? (o(), B(s(H), {
|
|
88
57
|
key: 0,
|
|
89
|
-
variant:
|
|
58
|
+
variant: i(e) ? "tabLabel2" : "tabLabel1"
|
|
90
59
|
}, {
|
|
91
|
-
default:
|
|
92
|
-
|
|
60
|
+
default: M(() => [
|
|
61
|
+
N(R(e.name), 1)
|
|
93
62
|
]),
|
|
94
63
|
_: 2
|
|
95
|
-
}, 1032, ["variant"])) :
|
|
96
|
-
], 42,
|
|
97
|
-
|
|
98
|
-
], 16
|
|
64
|
+
}, 1032, ["variant"])) : _("", !0)
|
|
65
|
+
], 42, U))), 128)),
|
|
66
|
+
j
|
|
67
|
+
], 16));
|
|
99
68
|
}
|
|
100
69
|
});
|
|
101
70
|
export {
|
|
102
|
-
|
|
71
|
+
Q as default
|
|
103
72
|
};
|
|
@@ -5,7 +5,6 @@ declare const TabsTypes: () => ({
|
|
|
5
5
|
$props: Partial<{
|
|
6
6
|
testId: string;
|
|
7
7
|
variant: "page" | "card";
|
|
8
|
-
ariaLabel: string;
|
|
9
8
|
tabsList: import("../common/Tabs.types").Tab[];
|
|
10
9
|
}> & Omit<Readonly<import("vue").ExtractPropTypes<{
|
|
11
10
|
testId: {
|
|
@@ -16,10 +15,6 @@ declare const TabsTypes: () => ({
|
|
|
16
15
|
type: import("vue").PropType<"page" | "card">;
|
|
17
16
|
default: string;
|
|
18
17
|
};
|
|
19
|
-
ariaLabel: {
|
|
20
|
-
type: import("vue").PropType<string>;
|
|
21
|
-
default: any;
|
|
22
|
-
};
|
|
23
18
|
tabsList: {
|
|
24
19
|
type: import("vue").PropType<import("../common/Tabs.types").Tab[]>;
|
|
25
20
|
required: true;
|
|
@@ -31,7 +26,7 @@ declare const TabsTypes: () => ({
|
|
|
31
26
|
};
|
|
32
27
|
}>> & {
|
|
33
28
|
"onUpdate:selectedTab"?: (tabId: string | number) => any;
|
|
34
|
-
} & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, "testId" | "variant" | "
|
|
29
|
+
} & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, "testId" | "variant" | "tabsList">;
|
|
35
30
|
$attrs: {
|
|
36
31
|
[x: string]: unknown;
|
|
37
32
|
};
|
|
@@ -54,10 +49,6 @@ declare const TabsTypes: () => ({
|
|
|
54
49
|
type: import("vue").PropType<"page" | "card">;
|
|
55
50
|
default: string;
|
|
56
51
|
};
|
|
57
|
-
ariaLabel: {
|
|
58
|
-
type: import("vue").PropType<string>;
|
|
59
|
-
default: any;
|
|
60
|
-
};
|
|
61
52
|
tabsList: {
|
|
62
53
|
type: import("vue").PropType<import("../common/Tabs.types").Tab[]>;
|
|
63
54
|
required: true;
|
|
@@ -74,7 +65,6 @@ declare const TabsTypes: () => ({
|
|
|
74
65
|
}, string, {
|
|
75
66
|
testId: string;
|
|
76
67
|
variant: "page" | "card";
|
|
77
|
-
ariaLabel: string;
|
|
78
68
|
tabsList: import("../common/Tabs.types").Tab[];
|
|
79
69
|
}, {}, string> & {
|
|
80
70
|
beforeCreate?: (() => void) | (() => void)[];
|
|
@@ -105,10 +95,6 @@ declare const TabsTypes: () => ({
|
|
|
105
95
|
type: import("vue").PropType<"page" | "card">;
|
|
106
96
|
default: string;
|
|
107
97
|
};
|
|
108
|
-
ariaLabel: {
|
|
109
|
-
type: import("vue").PropType<string>;
|
|
110
|
-
default: any;
|
|
111
|
-
};
|
|
112
98
|
tabsList: {
|
|
113
99
|
type: import("vue").PropType<import("../common/Tabs.types").Tab[]>;
|
|
114
100
|
required: true;
|
|
@@ -133,10 +119,6 @@ declare const TabsTypes: () => ({
|
|
|
133
119
|
type: import("vue").PropType<"page" | "card">;
|
|
134
120
|
default: string;
|
|
135
121
|
};
|
|
136
|
-
ariaLabel: {
|
|
137
|
-
type: import("vue").PropType<string>;
|
|
138
|
-
default: any;
|
|
139
|
-
};
|
|
140
122
|
tabsList: {
|
|
141
123
|
type: import("vue").PropType<import("../common/Tabs.types").Tab[]>;
|
|
142
124
|
required: true;
|
|
@@ -153,7 +135,6 @@ declare const TabsTypes: () => ({
|
|
|
153
135
|
}, string, {
|
|
154
136
|
testId: string;
|
|
155
137
|
variant: "page" | "card";
|
|
156
|
-
ariaLabel: string;
|
|
157
138
|
tabsList: import("../common/Tabs.types").Tab[];
|
|
158
139
|
}, {}, string> & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps & (new () => {
|
|
159
140
|
$slots: {
|
|
@@ -12,10 +12,8 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<__
|
|
|
12
12
|
color?: "primary" | "test";
|
|
13
13
|
size?: "small" | "medium";
|
|
14
14
|
testId?: string;
|
|
15
|
-
ariaLabel?: string;
|
|
16
15
|
}>, {
|
|
17
16
|
text: any;
|
|
18
|
-
ariaLabel: any;
|
|
19
17
|
activeText: any;
|
|
20
18
|
inactiveText: any;
|
|
21
19
|
hoverHelpText: string;
|
|
@@ -43,10 +41,8 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<__
|
|
|
43
41
|
color?: "primary" | "test";
|
|
44
42
|
size?: "small" | "medium";
|
|
45
43
|
testId?: string;
|
|
46
|
-
ariaLabel?: string;
|
|
47
44
|
}>, {
|
|
48
45
|
text: any;
|
|
49
|
-
ariaLabel: any;
|
|
50
46
|
activeText: any;
|
|
51
47
|
inactiveText: any;
|
|
52
48
|
hoverHelpText: string;
|
|
@@ -66,7 +62,6 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<__
|
|
|
66
62
|
color: "primary" | "test";
|
|
67
63
|
size: "small" | "medium";
|
|
68
64
|
isLoading: boolean;
|
|
69
|
-
ariaLabel: string;
|
|
70
65
|
hoverHelpText: string;
|
|
71
66
|
hoverHelpTextPlacement: "top" | "auto" | "auto-start" | "auto-end" | "top-start" | "top-end" | "right" | "right-start" | "right-end" | "bottom" | "bottom-start" | "bottom-end" | "left" | "left-start" | "left-end";
|
|
72
67
|
feedbackText: string;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import o from "./ToggleV4.vue2.js";
|
|
2
2
|
/* empty css */import e from "../../../_virtual/_plugin-vue_export-helper.js";
|
|
3
|
-
// import "../../../ToggleV4.
|
|
4
|
-
const
|
|
3
|
+
// import "../../../ToggleV4.vue_vue_type_style_index_0_scoped_a4aa32fb_lang.css"; //*');
|
|
4
|
+
const t = /* @__PURE__ */ e(o, [["__scopeId", "data-v-a4aa32fb"]]);
|
|
5
5
|
export {
|
|
6
|
-
|
|
6
|
+
t as default
|
|
7
7
|
};
|
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import "../../../ToggleV4.
|
|
1
|
+
import "../../../ToggleV4.vue_vue_type_style_index_0_scoped_a4aa32fb_lang.css"; import { defineComponent as k, computed as h, openBlock as i, createElementBlock as m, normalizeClass as f, createElementVNode as r, mergeProps as d, unref as t, createCommentVNode as l, renderSlot as g, createBlock as u, withCtx as v, createTextVNode as b, toDisplayString as y, createVNode as V } from "vue";
|
|
2
2
|
import E from "../../typography/v4/Typography.vue.js";
|
|
3
|
-
import { ToggleTestIdModifiers as
|
|
4
|
-
import
|
|
5
|
-
import { useTestIdAttrs as
|
|
6
|
-
import
|
|
3
|
+
import { ToggleTestIdModifiers as a } from "../../../testids/index.js";
|
|
4
|
+
import B from "../../shared/FieldHelpText.vue.js";
|
|
5
|
+
import { useTestIdAttrs as H } from "../../../utils/testIds.js";
|
|
6
|
+
import I from "../../icon/v4/IconV4.vue.js";
|
|
7
7
|
import "../../icon/v4/IconFlag.vue.js";
|
|
8
|
-
import
|
|
9
|
-
const
|
|
8
|
+
import D from "../../tooltip/v4/TooltipV4.vue.js";
|
|
9
|
+
const L = { class: "toggle-head" }, P = ["disabled", "checked"], O = /* @__PURE__ */ k({
|
|
10
10
|
__name: "ToggleV4",
|
|
11
11
|
props: {
|
|
12
12
|
modelValue: { type: Boolean },
|
|
@@ -21,66 +21,57 @@ const D = ["aria-checked", "aria-label", "disabled"], P = { class: "toggle-head"
|
|
|
21
21
|
isLoading: { type: Boolean, default: !1 },
|
|
22
22
|
color: { default: "primary" },
|
|
23
23
|
size: { default: "small" },
|
|
24
|
-
testId: { default: "" }
|
|
25
|
-
ariaLabel: { default: void 0 }
|
|
24
|
+
testId: { default: "" }
|
|
26
25
|
},
|
|
27
26
|
emits: ["update:modelValue"],
|
|
28
|
-
setup(e, { emit:
|
|
29
|
-
const
|
|
30
|
-
|
|
31
|
-
}, o =
|
|
32
|
-
return (n,
|
|
27
|
+
setup(e, { emit: x }) {
|
|
28
|
+
const c = e, T = () => {
|
|
29
|
+
s.value || x("update:modelValue", !c.modelValue);
|
|
30
|
+
}, o = H(c.testId, a), s = h(() => c.isDisabled || c.isLoading);
|
|
31
|
+
return (n, $) => (i(), m("div", {
|
|
33
32
|
class: f(["toggle", [`toggle--color-${e.color}`, `toggle--size-${e.size}`]])
|
|
34
33
|
}, [
|
|
35
|
-
r("div",
|
|
36
|
-
r("
|
|
37
|
-
type: "button",
|
|
34
|
+
r("div", d({ class: "toggle-wrap" }, t(o)[t(a).WRAPPER]), [
|
|
35
|
+
r("div", d({
|
|
38
36
|
class: ["toggle-body", {
|
|
39
37
|
"toggle-active": e.modelValue,
|
|
40
|
-
"toggle-disabled": t(
|
|
41
|
-
}]
|
|
42
|
-
|
|
43
|
-
"
|
|
44
|
-
|
|
45
|
-
disabled: t(i)
|
|
46
|
-
}, t(o)[t(l).BODY], { onClick: b }), [
|
|
47
|
-
r("div", P, [
|
|
48
|
-
e.isLoading ? (d(), m("span", {
|
|
38
|
+
"toggle-disabled": t(s)
|
|
39
|
+
}]
|
|
40
|
+
}, t(o)[t(a).BODY], { onClick: T }), [
|
|
41
|
+
r("div", L, [
|
|
42
|
+
e.isLoading ? (i(), m("span", {
|
|
49
43
|
key: 0,
|
|
50
44
|
class: f(["loader", { "loader-active": e.modelValue }])
|
|
51
|
-
}, null, 2)) :
|
|
45
|
+
}, null, 2)) : l("", !0)
|
|
52
46
|
])
|
|
53
|
-
], 16
|
|
54
|
-
r("input",
|
|
47
|
+
], 16),
|
|
48
|
+
r("input", d({
|
|
55
49
|
type: "checkbox",
|
|
56
50
|
class: "toggle-checkbox",
|
|
57
|
-
|
|
58
|
-
"aria-hidden": "true",
|
|
59
|
-
disabled: t(i),
|
|
51
|
+
disabled: t(s),
|
|
60
52
|
checked: e.modelValue
|
|
61
|
-
}, t(o)[t(
|
|
62
|
-
n.$slots["icon-left"] ? g(n.$slots, "icon-left", { key: 0 }, void 0, !0) :
|
|
63
|
-
e.text || e.activeText || e.inactiveText ? (
|
|
53
|
+
}, t(o)[t(a).FIELD]), null, 16, P),
|
|
54
|
+
n.$slots["icon-left"] ? g(n.$slots, "icon-left", { key: 0 }, void 0, !0) : l("", !0),
|
|
55
|
+
e.text || e.activeText || e.inactiveText ? (i(), u(t(E), d({
|
|
64
56
|
key: 1,
|
|
65
57
|
variant: "body1",
|
|
66
58
|
"is-truncated": "",
|
|
67
|
-
class: ["toggle-text", { "toggle-disabled-text": t(
|
|
68
|
-
}, t(o)[t(
|
|
69
|
-
default:
|
|
70
|
-
|
|
59
|
+
class: ["toggle-text", { "toggle-disabled-text": t(s) }]
|
|
60
|
+
}, t(o)[t(a).TEXT]), {
|
|
61
|
+
default: v(() => [
|
|
62
|
+
b(y(e.text ?? (e.modelValue ? e.activeText : e.inactiveText)), 1)
|
|
71
63
|
]),
|
|
72
64
|
_: 1
|
|
73
|
-
}, 16, ["class"])) :
|
|
74
|
-
n.$slots["icon-right"] ? g(n.$slots, "icon-right", { key: 2 }, void 0, !0) :
|
|
75
|
-
e.hoverHelpText ? (
|
|
65
|
+
}, 16, ["class"])) : l("", !0),
|
|
66
|
+
n.$slots["icon-right"] ? g(n.$slots, "icon-right", { key: 2 }, void 0, !0) : l("", !0),
|
|
67
|
+
e.hoverHelpText ? (i(), u(t(D), {
|
|
76
68
|
key: 3,
|
|
77
69
|
triggers: ["hover"],
|
|
78
70
|
text: e.hoverHelpText,
|
|
79
|
-
placement: e.hoverHelpTextPlacement
|
|
80
|
-
focusable: ""
|
|
71
|
+
placement: e.hoverHelpTextPlacement
|
|
81
72
|
}, {
|
|
82
|
-
default:
|
|
83
|
-
V(t(
|
|
73
|
+
default: v(() => [
|
|
74
|
+
V(t(I), {
|
|
84
75
|
class: "info-icon",
|
|
85
76
|
name: "question",
|
|
86
77
|
type: "fill",
|
|
@@ -88,18 +79,18 @@ const D = ["aria-checked", "aria-label", "disabled"], P = { class: "toggle-head"
|
|
|
88
79
|
})
|
|
89
80
|
]),
|
|
90
81
|
_: 1
|
|
91
|
-
}, 8, ["text", "placement"])) :
|
|
82
|
+
}, 8, ["text", "placement"])) : l("", !0)
|
|
92
83
|
], 16),
|
|
93
|
-
e.feedbackText ? (
|
|
84
|
+
e.feedbackText ? (i(), u(B, d({
|
|
94
85
|
key: 0,
|
|
95
86
|
class: "feedback-text",
|
|
96
87
|
text: e.feedbackText,
|
|
97
88
|
variant: e.feedbackVariant,
|
|
98
89
|
"show-icon": !1
|
|
99
|
-
}, t(o)[t(
|
|
90
|
+
}, t(o)[t(a).HELPER_TEXT]), null, 16, ["text", "variant"])) : l("", !0)
|
|
100
91
|
], 2));
|
|
101
92
|
}
|
|
102
93
|
});
|
|
103
94
|
export {
|
|
104
|
-
|
|
95
|
+
O as default
|
|
105
96
|
};
|