@ironsource/shared-ui 2.1.10-rc.1 → 2.1.10-rc.3
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_49bd7193_lang.css +1 -0
- package/DataGrid.vue_vue_type_style_index_0_scoped_9cab3826_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_899679d0_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_69c40021_lang.css +1 -0
- package/OptionV4.vue_vue_type_style_index_0_scoped_f61be399_lang.css +1 -0
- package/components/dropdown/common/Dropdown.common.d.ts +1 -0
- package/components/dropdown/common/Dropdown.common.js +165 -158
- 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 +12 -0
- package/components/dropdown/v4/DropdownV4.vue.js +3 -3
- package/components/dropdown/v4/DropdownV4.vue2.js +173 -167
- 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 +111 -3
- package/components/table/v4/DataGrid.vue.d.ts +3 -3
- package/components/table/v4/DataGrid.vue.js +4 -4
- package/components/table/v4/DataGrid.vue2.js +42 -42
- package/components/table/v4/MultipleDataGrid.vue.d.ts +18 -2
- package/components/table/v4/MultipleDataGrid.vue.js +4 -4
- package/components/table/v4/MultipleDataGrid.vue2.js +65 -58
- package/components/table/v4/index.d.ts +66 -8
- package/consts/configs.d.ts +1 -0
- package/consts/configs.js +4 -0
- package/index.d.ts +354 -22
- package/index.js +1 -1
- package/package.json +1 -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
|
@@ -6,7 +6,7 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<__
|
|
|
6
6
|
sections?: Section[];
|
|
7
7
|
sort?: Sort;
|
|
8
8
|
selection?: unknown[];
|
|
9
|
-
getRowId?: (row: Row, index: number) =>
|
|
9
|
+
getRowId?: (row: Row, index: number) => string | number;
|
|
10
10
|
selectedMatcher?: (rowId: unknown, selected: unknown) => boolean;
|
|
11
11
|
isSticky?: boolean;
|
|
12
12
|
isStickyHeader?: boolean;
|
|
@@ -73,7 +73,7 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<__
|
|
|
73
73
|
sections?: Section[];
|
|
74
74
|
sort?: Sort;
|
|
75
75
|
selection?: unknown[];
|
|
76
|
-
getRowId?: (row: Row, index: number) =>
|
|
76
|
+
getRowId?: (row: Row, index: number) => string | number;
|
|
77
77
|
selectedMatcher?: (rowId: unknown, selected: unknown) => boolean;
|
|
78
78
|
isSticky?: boolean;
|
|
79
79
|
isStickyHeader?: boolean;
|
|
@@ -151,7 +151,7 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<__
|
|
|
151
151
|
infiniteScrollThreshold: number;
|
|
152
152
|
rowHeight: number | ((index: number) => number);
|
|
153
153
|
defaultScrollPosition: number;
|
|
154
|
-
getRowId: (row: Row, index: number) =>
|
|
154
|
+
getRowId: (row: Row, index: number) => string | number;
|
|
155
155
|
selectedMatcher: (rowId: unknown, selected: unknown) => boolean;
|
|
156
156
|
emptyStateVariant: "error" | "no-access" | "no-results" | "no-data" | "files" | "settings";
|
|
157
157
|
zIndexBase: number;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import o from "./DataGrid.vue2.js";
|
|
2
|
-
/* empty css */import
|
|
3
|
-
// import "../../../DataGrid.
|
|
4
|
-
const
|
|
2
|
+
/* empty css */import _ from "../../../_virtual/_plugin-vue_export-helper.js";
|
|
3
|
+
// import "../../../DataGrid.vue_vue_type_style_index_0_scoped_9cab3826_lang.css"; //*');
|
|
4
|
+
const s = /* @__PURE__ */ _(o, [["__scopeId", "data-v-9cab3826"]]);
|
|
5
5
|
export {
|
|
6
|
-
|
|
6
|
+
s as default
|
|
7
7
|
};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import "../../../DataGrid.
|
|
2
|
-
import
|
|
1
|
+
import "../../../DataGrid.vue_vue_type_style_index_0_scoped_9cab3826_lang.css"; import { defineComponent as de, useCssVars as oe, unref as t, useSlots as ne, computed as v, openBlock as l, createElementBlock as d, createElementVNode as u, normalizeStyle as T, normalizeClass as f, renderSlot as c, createVNode as h, withCtx as w, createTextVNode as E, toDisplayString as I, isRef as ce, createCommentVNode as r, Fragment as B, renderList as A, createBlock as z, mergeProps as re } from "vue";
|
|
2
|
+
import V from "../../typography/v4/Typography.vue.js";
|
|
3
3
|
import ue from "../../skeleton/v4/SkeletonV4.vue.js";
|
|
4
4
|
import he from "../../emptyState/v4/EmptyStateV4.vue.js";
|
|
5
5
|
import K from "../../checkbox/v4/CheckboxV4.vue.js";
|
|
@@ -13,16 +13,16 @@ import { useVModel as ge } from "@vueuse/core";
|
|
|
13
13
|
const ve = ["data-testid"], be = ["data-testid"], $e = ["data-testid"], Re = ["data-testid"], Ce = ["data-testid"], xe = { class: "search-wrapper" }, Te = ["data-testid"], we = ["data-testid"], Ee = {
|
|
14
14
|
key: 0,
|
|
15
15
|
class: "checkbox-cell"
|
|
16
|
-
},
|
|
16
|
+
}, Ie = {
|
|
17
17
|
key: 1,
|
|
18
18
|
class: "expand-toggle-cell"
|
|
19
|
-
},
|
|
19
|
+
}, Be = ["onClick"], Ae = { class: "table-head-container" }, Ve = ["data-testid"], Le = ["onMouseenter", "onClick"], Me = {
|
|
20
20
|
key: 0,
|
|
21
21
|
class: "checkbox-cell"
|
|
22
|
-
},
|
|
22
|
+
}, Pe = {
|
|
23
23
|
key: 1,
|
|
24
24
|
class: "expand-toggle-cell"
|
|
25
|
-
},
|
|
25
|
+
}, pe = {
|
|
26
26
|
key: 2,
|
|
27
27
|
class: "expanded-row"
|
|
28
28
|
}, He = {
|
|
@@ -66,17 +66,17 @@ const ve = ["data-testid"], be = ["data-testid"], $e = ["data-testid"], Re = ["d
|
|
|
66
66
|
setup(s, { expose: m, emit: y }) {
|
|
67
67
|
const i = s;
|
|
68
68
|
oe((a) => ({
|
|
69
|
-
"
|
|
70
|
-
|
|
71
|
-
"
|
|
72
|
-
"
|
|
69
|
+
"1e7437b3": s.zIndexBase,
|
|
70
|
+
"734017e7": t(X),
|
|
71
|
+
"6b65cd20": t(p),
|
|
72
|
+
"4bca76a8": t(J)
|
|
73
73
|
}));
|
|
74
74
|
const b = ne(), U = (a) => i.rowCustomClassKey && i.rows[a] ? i.rows[a][i.rowCustomClassKey] : "", {
|
|
75
|
-
list:
|
|
75
|
+
list: P,
|
|
76
76
|
containerProps: G,
|
|
77
77
|
wrapperProps: Y,
|
|
78
78
|
activeRow: $,
|
|
79
|
-
gridColumnTemplate:
|
|
79
|
+
gridColumnTemplate: p,
|
|
80
80
|
toggleSortOrder: Q,
|
|
81
81
|
columnsStickyPositions: H,
|
|
82
82
|
hasSearchSlot: W,
|
|
@@ -87,11 +87,11 @@ const ve = ["data-testid"], be = ["data-testid"], $e = ["data-testid"], Re = ["d
|
|
|
87
87
|
toggleExpandRow: q,
|
|
88
88
|
cssRowHeight: J,
|
|
89
89
|
cssExpandGridCol: X,
|
|
90
|
-
isRowExpanded:
|
|
90
|
+
isRowExpanded: L,
|
|
91
91
|
hasCheckboxes: O,
|
|
92
92
|
activeMenuRow: Z,
|
|
93
93
|
scrollTo: _
|
|
94
|
-
} = ye(i, y), D = v(() => !!b.footer), g = ge(i, "search", y), ee = v(() => i.selection.length || 0),
|
|
94
|
+
} = ye(i, y), D = v(() => !!b.footer), g = ge(i, "search", y), ee = v(() => i.selection.length || 0), M = v(() => {
|
|
95
95
|
const a = i.rows.map((o, e) => i.getRowId(o, e));
|
|
96
96
|
return !!a.length && a.every((o) => C(o));
|
|
97
97
|
}), C = (a) => i.selection.findIndex((o) => i.selectedMatcher(a, o)) !== -1, te = (a) => {
|
|
@@ -101,7 +101,7 @@ const ve = ["data-testid"], be = ["data-testid"], $e = ["data-testid"], Re = ["d
|
|
|
101
101
|
)
|
|
102
102
|
), y("selectRow", !1)) : (x([...i.selection, a]), y("selectRow", !0));
|
|
103
103
|
}, se = () => {
|
|
104
|
-
if (
|
|
104
|
+
if (M.value)
|
|
105
105
|
x([]), y("selectAll", !1);
|
|
106
106
|
else {
|
|
107
107
|
const a = i.rows.map((o, e) => i.getRowId(o, e)).filter((o) => !C(o));
|
|
@@ -141,9 +141,9 @@ const ve = ["data-testid"], be = ["data-testid"], $e = ["data-testid"], Re = ["d
|
|
|
141
141
|
"data-testid": `${s.testId}-${t(S).TITLE}`
|
|
142
142
|
}, [
|
|
143
143
|
c(a.$slots, "title", {}, () => [
|
|
144
|
-
h(t(
|
|
144
|
+
h(t(V), { variant: "h3" }, {
|
|
145
145
|
default: w(() => [
|
|
146
|
-
E(
|
|
146
|
+
E(I(s.title), 1)
|
|
147
147
|
]),
|
|
148
148
|
_: 1
|
|
149
149
|
})
|
|
@@ -181,7 +181,7 @@ const ve = ["data-testid"], be = ["data-testid"], $e = ["data-testid"], Re = ["d
|
|
|
181
181
|
class: "sections",
|
|
182
182
|
"data-testid": `${s.testId}-${t(S).SECTIONS}`
|
|
183
183
|
}, [
|
|
184
|
-
(l(!0), d(
|
|
184
|
+
(l(!0), d(B, null, A(s.sections, (e) => (l(), d("div", {
|
|
185
185
|
key: e.id,
|
|
186
186
|
class: f(["section-container", { sticky: e.isSticky }])
|
|
187
187
|
}, [
|
|
@@ -190,9 +190,9 @@ const ve = ["data-testid"], be = ["data-testid"], $e = ["data-testid"], Re = ["d
|
|
|
190
190
|
style: T({ width: e.width + "px" }),
|
|
191
191
|
class: f({ section: !0 })
|
|
192
192
|
}, [
|
|
193
|
-
h(t(
|
|
193
|
+
h(t(V), { variant: "body2" }, {
|
|
194
194
|
default: w(() => [
|
|
195
|
-
E(
|
|
195
|
+
E(I(e.title), 1)
|
|
196
196
|
]),
|
|
197
197
|
_: 2
|
|
198
198
|
}, 1024)
|
|
@@ -205,14 +205,14 @@ const ve = ["data-testid"], be = ["data-testid"], $e = ["data-testid"], Re = ["d
|
|
|
205
205
|
c(a.$slots, "select-all-checkbox", {}, () => [
|
|
206
206
|
h(t(K), {
|
|
207
207
|
disabled: s.isLoading,
|
|
208
|
-
"is-checked": t(
|
|
209
|
-
"is-indeterminate": !t(
|
|
208
|
+
"is-checked": t(M),
|
|
209
|
+
"is-indeterminate": !t(M) && t(ee) > 0,
|
|
210
210
|
"onUpdate:isChecked": se
|
|
211
211
|
}, null, 8, ["disabled", "is-checked", "is-indeterminate"])
|
|
212
212
|
])
|
|
213
213
|
])) : r("", !0),
|
|
214
|
-
t(R) ? (l(), d("th",
|
|
215
|
-
(l(!0), d(
|
|
214
|
+
t(R) ? (l(), d("th", Ie)) : r("", !0),
|
|
215
|
+
(l(!0), d(B, null, A(s.columns, (e) => (l(), d("th", {
|
|
216
216
|
key: e.id,
|
|
217
217
|
class: f({
|
|
218
218
|
sticky: e.isSticky,
|
|
@@ -225,11 +225,11 @@ const ve = ["data-testid"], be = ["data-testid"], $e = ["data-testid"], Re = ["d
|
|
|
225
225
|
style: T(e.isSticky ? t(H)[e.id] : null),
|
|
226
226
|
onClick: (k) => e.isSortable ? t(Q)(e) : null
|
|
227
227
|
}, [
|
|
228
|
-
u("div",
|
|
228
|
+
u("div", Ae, [
|
|
229
229
|
c(a.$slots, `header-${e.id}`, { column: e }, () => [
|
|
230
|
-
h(t(
|
|
230
|
+
h(t(V), { variant: "tableLabel" }, {
|
|
231
231
|
default: w(() => [
|
|
232
|
-
E(
|
|
232
|
+
E(I(e.title), 1)
|
|
233
233
|
]),
|
|
234
234
|
_: 2
|
|
235
235
|
}, 1024)
|
|
@@ -244,40 +244,40 @@ const ve = ["data-testid"], be = ["data-testid"], $e = ["data-testid"], Re = ["d
|
|
|
244
244
|
"sort-order": s.sort.sortOrder
|
|
245
245
|
}, null, 8, ["sort-order"])) : r("", !0)
|
|
246
246
|
])
|
|
247
|
-
], 14,
|
|
247
|
+
], 14, Be))), 128))
|
|
248
248
|
])
|
|
249
249
|
], 2),
|
|
250
250
|
u("tbody", null, [
|
|
251
|
-
t(
|
|
251
|
+
t(P).length > 0 ? (l(), d("div", re({
|
|
252
252
|
key: 0,
|
|
253
253
|
class: "table-body-wrapper",
|
|
254
254
|
"data-testid": `${s.testId}-${t(S).BODY_WRAPPER}`
|
|
255
255
|
}, t(Y)), [
|
|
256
|
-
(l(!0), d(
|
|
257
|
-
key: e.index,
|
|
256
|
+
(l(!0), d(B, null, A(t(P), (e) => (l(), d("tr", {
|
|
257
|
+
key: s.getRowId(e.data, e.index),
|
|
258
258
|
class: f(["table-row", {
|
|
259
259
|
loading: s.isLoading || s.isLoading && !e.data || t(F).includes(e.index),
|
|
260
260
|
active: t($) === e.index,
|
|
261
261
|
activeMenu: t(Z) === e.index,
|
|
262
|
-
expanded: t(R) && t(
|
|
262
|
+
expanded: t(R) && t(L)(e.index),
|
|
263
263
|
[U(e.index)]: !0
|
|
264
264
|
}]),
|
|
265
265
|
onMouseenter: (k) => $.value = e.index,
|
|
266
266
|
onClick: (k) => y("clickRow", e.index)
|
|
267
267
|
}, [
|
|
268
|
-
t(O) ? (l(), d("td",
|
|
268
|
+
t(O) ? (l(), d("td", Me, [
|
|
269
269
|
h(t(K), {
|
|
270
270
|
"is-checked": C(s.getRowId(e.data, e.index)),
|
|
271
271
|
"onUpdate:isChecked": (k) => te(s.getRowId(e.data, e.index))
|
|
272
272
|
}, null, 8, ["is-checked", "onUpdate:isChecked"])
|
|
273
273
|
])) : r("", !0),
|
|
274
|
-
t(R) ? (l(), d("td",
|
|
274
|
+
t(R) ? (l(), d("td", Pe, [
|
|
275
275
|
h(ke, {
|
|
276
|
-
expanded: t(
|
|
276
|
+
expanded: t(L)(e.index),
|
|
277
277
|
onClick: (k) => t(q)(e.index, k)
|
|
278
278
|
}, null, 8, ["expanded", "onClick"])
|
|
279
279
|
])) : r("", !0),
|
|
280
|
-
(l(!0), d(
|
|
280
|
+
(l(!0), d(B, null, A(s.columns, (k, n) => (l(), d("td", {
|
|
281
281
|
key: n,
|
|
282
282
|
class: f({
|
|
283
283
|
sticky: s.columns[n].isSticky,
|
|
@@ -301,9 +301,9 @@ const ve = ["data-testid"], be = ["data-testid"], $e = ["data-testid"], Re = ["d
|
|
|
301
301
|
row: e,
|
|
302
302
|
rowIndex: e.index
|
|
303
303
|
}, () => [
|
|
304
|
-
h(t(
|
|
304
|
+
h(t(V), { variant: "body1" }, {
|
|
305
305
|
default: w(() => [
|
|
306
|
-
E(
|
|
306
|
+
E(I(e.data[n]), 1)
|
|
307
307
|
]),
|
|
308
308
|
_: 2
|
|
309
309
|
}, 1024)
|
|
@@ -312,10 +312,10 @@ const ve = ["data-testid"], be = ["data-testid"], $e = ["data-testid"], Re = ["d
|
|
|
312
312
|
h(t(ue), { round: "" })
|
|
313
313
|
])
|
|
314
314
|
], 6))), 128)),
|
|
315
|
-
t(R) && t(
|
|
315
|
+
t(R) && t(L)(e.index) ? (l(), d("div", pe, [
|
|
316
316
|
c(a.$slots, "expanded", {
|
|
317
317
|
row: e,
|
|
318
|
-
gridColumnTemplate: t(
|
|
318
|
+
gridColumnTemplate: t(p)
|
|
319
319
|
})
|
|
320
320
|
])) : r("", !0),
|
|
321
321
|
ae(e.index) ? (l(), d("div", He, [
|
|
@@ -324,8 +324,8 @@ const ve = ["data-testid"], be = ["data-testid"], $e = ["data-testid"], Re = ["d
|
|
|
324
324
|
rowIndex: e.index
|
|
325
325
|
})
|
|
326
326
|
])) : r("", !0)
|
|
327
|
-
], 42,
|
|
328
|
-
], 16,
|
|
327
|
+
], 42, Le))), 128))
|
|
328
|
+
], 16, Ve)) : (l(), d("div", Ne, [
|
|
329
329
|
c(a.$slots, "empty-state", {}, () => [
|
|
330
330
|
h(t(he), {
|
|
331
331
|
class: "empty-state",
|
|
@@ -1,8 +1,9 @@
|
|
|
1
1
|
import { Column } from '@/components/table/v4';
|
|
2
|
-
import { SaveRowEvent, TableSettings } from '@is-ssp/table/common/Table.types';
|
|
2
|
+
import { Row, SaveRowEvent, TableSettings } from '@is-ssp/table/common/Table.types';
|
|
3
3
|
declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<{
|
|
4
4
|
tablesSettings: TableSettings[];
|
|
5
5
|
loadingAndEmptyStatesColumns: Column[];
|
|
6
|
+
getRowId?: (row: Row, index: number) => string | number;
|
|
6
7
|
isSticky?: boolean;
|
|
7
8
|
isLoading?: boolean;
|
|
8
9
|
emptyStateVariant?: "error" | "no-access" | "no-results" | "no-data" | "files" | "settings";
|
|
@@ -18,10 +19,13 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<__
|
|
|
18
19
|
displayingText?: string;
|
|
19
20
|
outOfText?: string;
|
|
20
21
|
totalText?: string;
|
|
22
|
+
rowCustomClassKey?: string;
|
|
23
|
+
rowDataKey?: string;
|
|
21
24
|
testId?: string;
|
|
22
25
|
}>, {
|
|
23
26
|
tablesSettings: () => any[];
|
|
24
27
|
loadingAndEmptyStatesColumns: () => any[];
|
|
28
|
+
getRowId: (row: any, index: any) => any;
|
|
25
29
|
isSticky: boolean;
|
|
26
30
|
isLoading: boolean;
|
|
27
31
|
emptyStateVariant: any;
|
|
@@ -37,6 +41,8 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<__
|
|
|
37
41
|
displayingText: string;
|
|
38
42
|
outOfText: string;
|
|
39
43
|
totalText: string;
|
|
44
|
+
rowCustomClassKey: string;
|
|
45
|
+
rowDataKey: string;
|
|
40
46
|
testId: string;
|
|
41
47
|
}>, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
42
48
|
"update:search": (query: string) => void;
|
|
@@ -49,6 +55,7 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<__
|
|
|
49
55
|
}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<{
|
|
50
56
|
tablesSettings: TableSettings[];
|
|
51
57
|
loadingAndEmptyStatesColumns: Column[];
|
|
58
|
+
getRowId?: (row: Row, index: number) => string | number;
|
|
52
59
|
isSticky?: boolean;
|
|
53
60
|
isLoading?: boolean;
|
|
54
61
|
emptyStateVariant?: "error" | "no-access" | "no-results" | "no-data" | "files" | "settings";
|
|
@@ -64,10 +71,13 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<__
|
|
|
64
71
|
displayingText?: string;
|
|
65
72
|
outOfText?: string;
|
|
66
73
|
totalText?: string;
|
|
74
|
+
rowCustomClassKey?: string;
|
|
75
|
+
rowDataKey?: string;
|
|
67
76
|
testId?: string;
|
|
68
77
|
}>, {
|
|
69
78
|
tablesSettings: () => any[];
|
|
70
79
|
loadingAndEmptyStatesColumns: () => any[];
|
|
80
|
+
getRowId: (row: any, index: any) => any;
|
|
71
81
|
isSticky: boolean;
|
|
72
82
|
isLoading: boolean;
|
|
73
83
|
emptyStateVariant: any;
|
|
@@ -83,6 +93,8 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<__
|
|
|
83
93
|
displayingText: string;
|
|
84
94
|
outOfText: string;
|
|
85
95
|
totalText: string;
|
|
96
|
+
rowCustomClassKey: string;
|
|
97
|
+
rowDataKey: string;
|
|
86
98
|
testId: string;
|
|
87
99
|
}>>> & {
|
|
88
100
|
"onUpdate:search"?: (query: string) => any;
|
|
@@ -103,8 +115,11 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<__
|
|
|
103
115
|
emptyStateTitle: string;
|
|
104
116
|
isSticky: boolean;
|
|
105
117
|
emptyStateSubtitle: string;
|
|
118
|
+
getRowId: (row: Row, index: number) => string | number;
|
|
106
119
|
emptyStateVariant: "error" | "no-access" | "no-results" | "no-data" | "files" | "settings";
|
|
107
120
|
zIndexBase: number;
|
|
121
|
+
rowCustomClassKey: string;
|
|
122
|
+
rowDataKey: string;
|
|
108
123
|
totalCount: number;
|
|
109
124
|
displayingText: string;
|
|
110
125
|
outOfText: string;
|
|
@@ -126,8 +141,9 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<__
|
|
|
126
141
|
search?(_: {}): any;
|
|
127
142
|
"table-header-actions"?(_: {}): any;
|
|
128
143
|
"floating-row"?(_: {
|
|
129
|
-
row: import("@vueuse/core").UseVirtualListItem<
|
|
144
|
+
row: import("@vueuse/core").UseVirtualListItem<Row>;
|
|
130
145
|
rowIndex: number;
|
|
146
|
+
tableIndex: number;
|
|
131
147
|
}): any;
|
|
132
148
|
"empty-state"?(_: {}): any;
|
|
133
149
|
}>;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import
|
|
2
|
-
/* empty css */import
|
|
3
|
-
// import "../../../MultipleDataGrid.
|
|
4
|
-
const s = /* @__PURE__ */ o
|
|
1
|
+
import o from "./MultipleDataGrid.vue2.js";
|
|
2
|
+
/* empty css */import t from "../../../_virtual/_plugin-vue_export-helper.js";
|
|
3
|
+
// import "../../../MultipleDataGrid.vue_vue_type_style_index_0_scoped_69c40021_lang.css"; //*');
|
|
4
|
+
const s = /* @__PURE__ */ t(o, [["__scopeId", "data-v-69c40021"]]);
|
|
5
5
|
export {
|
|
6
6
|
s as default
|
|
7
7
|
};
|
|
@@ -1,19 +1,20 @@
|
|
|
1
|
-
import "../../../MultipleDataGrid.
|
|
1
|
+
import "../../../MultipleDataGrid.vue_vue_type_style_index_0_scoped_69c40021_lang.css"; import { defineComponent as A, useCssVars as H, useSlots as O, computed as G, openBlock as n, createElementBlock as c, createElementVNode as C, normalizeClass as K, unref as s, renderSlot as d, createBlock as k, createCommentVNode as f, createVNode as M, isRef as $, Fragment as P, renderList as w, createSlots as b, withCtx as y } from "vue";
|
|
2
2
|
import I from "./DataGrid.vue.js";
|
|
3
3
|
import "./DataGridMenu.vue.js";
|
|
4
4
|
import F from "./DataGridRowsCounter.vue.js";
|
|
5
5
|
import "./MultipleDataGrid.vue.js";
|
|
6
|
-
import
|
|
7
|
-
import { useVModel as
|
|
8
|
-
import { TableTestIdModifiers as
|
|
9
|
-
const
|
|
6
|
+
import U from "../../search/v4/SearchV4.vue.js";
|
|
7
|
+
import { useVModel as Q } from "@vueuse/core";
|
|
8
|
+
import { TableTestIdModifiers as g } from "../../../testids/index.js";
|
|
9
|
+
const j = ["data-testid"], q = ["data-testid"], J = ["data-testid"], W = ["data-testid"], X = {
|
|
10
10
|
key: 0,
|
|
11
11
|
class: "tables-container"
|
|
12
|
-
}, st = /* @__PURE__ */
|
|
12
|
+
}, st = /* @__PURE__ */ A({
|
|
13
13
|
__name: "MultipleDataGrid",
|
|
14
14
|
props: {
|
|
15
15
|
tablesSettings: { default: () => [] },
|
|
16
16
|
loadingAndEmptyStatesColumns: { default: () => [] },
|
|
17
|
+
getRowId: { type: Function, default: (t, i) => i },
|
|
17
18
|
isSticky: { type: Boolean, default: !0 },
|
|
18
19
|
isLoading: { type: Boolean, default: !1 },
|
|
19
20
|
emptyStateVariant: { default: null },
|
|
@@ -29,33 +30,35 @@ const p = ["data-testid"], q = ["data-testid"], J = ["data-testid"], K = ["data-
|
|
|
29
30
|
displayingText: { default: "Displaying" },
|
|
30
31
|
outOfText: { default: "out of" },
|
|
31
32
|
totalText: { default: "total rows" },
|
|
33
|
+
rowCustomClassKey: { default: "" },
|
|
34
|
+
rowDataKey: { default: "" },
|
|
32
35
|
testId: { default: "" }
|
|
33
36
|
},
|
|
34
37
|
emits: ["update:search", "onScroll", "onClearSearch", "clickRow", "saveRow"],
|
|
35
|
-
setup(t, { emit:
|
|
36
|
-
const
|
|
38
|
+
setup(t, { emit: i }) {
|
|
39
|
+
const h = t;
|
|
37
40
|
H((e) => ({
|
|
38
|
-
"
|
|
41
|
+
"306dba92": t.zIndexBase
|
|
39
42
|
}));
|
|
40
43
|
const R = O(), T = G(
|
|
41
|
-
() =>
|
|
42
|
-
),
|
|
43
|
-
|
|
44
|
-
}, E = () =>
|
|
45
|
-
return (e, l) => (n(),
|
|
44
|
+
() => h.isLoading || !h.tablesSettings.flatMap((e) => e.rows).length
|
|
45
|
+
), r = Q(h, "search", i), m = (e) => `header-${e.id}`, v = (e) => `cell-${e.id}`, x = (e) => {
|
|
46
|
+
i("onScroll", e.target.scrollTop);
|
|
47
|
+
}, E = () => i("onClearSearch"), V = (e, l) => i("clickRow", e, l), B = ({ value: e, rowIndex: l, cellIndex: a, confirm: u }, o) => i("saveRow", { value: e, tableIndex: o, rowIndex: l, cellIndex: a, confirm: u });
|
|
48
|
+
return (e, l) => (n(), c("div", {
|
|
46
49
|
class: "multi-table-container",
|
|
47
50
|
onScrollPassive: x
|
|
48
51
|
}, [
|
|
49
|
-
|
|
50
|
-
class:
|
|
51
|
-
"data-testid": `${t.testId}-${s(
|
|
52
|
+
C("div", {
|
|
53
|
+
class: K(["table-header-container", { sticky: t.isSticky }]),
|
|
54
|
+
"data-testid": `${t.testId}-${s(g).HEADER}`
|
|
52
55
|
}, [
|
|
53
|
-
|
|
56
|
+
C("div", {
|
|
54
57
|
class: "rows-counter-container",
|
|
55
|
-
"data-testid": `${t.testId}-${s(
|
|
58
|
+
"data-testid": `${t.testId}-${s(g).TITLE}`
|
|
56
59
|
}, [
|
|
57
60
|
d(e.$slots, "title", {}, () => [
|
|
58
|
-
t.isLoading ?
|
|
61
|
+
t.isLoading ? f("", !0) : (n(), k(s(F), {
|
|
59
62
|
key: 0,
|
|
60
63
|
count: t.count,
|
|
61
64
|
"total-count": t.totalCount,
|
|
@@ -66,32 +69,32 @@ const p = ["data-testid"], q = ["data-testid"], J = ["data-testid"], K = ["data-
|
|
|
66
69
|
}, null, 8, ["count", "total-count", "total-text", "displaying-text", "out-of-text", "test-id"]))
|
|
67
70
|
], !0)
|
|
68
71
|
], 8, q),
|
|
69
|
-
|
|
72
|
+
C("div", {
|
|
70
73
|
class: "table-header-right",
|
|
71
|
-
"data-testid": `${t.testId}-${s(
|
|
74
|
+
"data-testid": `${t.testId}-${s(g).HEADER_RIGHT}`
|
|
72
75
|
}, [
|
|
73
76
|
t.showSearch ? d(e.$slots, "search", { key: 0 }, () => [
|
|
74
|
-
|
|
75
|
-
modelValue: s(
|
|
76
|
-
"onUpdate:modelValue": l[0] || (l[0] = (a) => $(
|
|
77
|
+
M(s(U), {
|
|
78
|
+
modelValue: s(r),
|
|
79
|
+
"onUpdate:modelValue": l[0] || (l[0] = (a) => $(r) ? r.value = a : null),
|
|
77
80
|
placeholder: t.searchPlaceholder,
|
|
78
81
|
"test-id": t.testId,
|
|
79
82
|
onOnClear: E
|
|
80
83
|
}, null, 8, ["modelValue", "placeholder", "test-id"])
|
|
81
|
-
], !0) :
|
|
82
|
-
s(R)["table-header-actions"] ? (n(),
|
|
84
|
+
], !0) : f("", !0),
|
|
85
|
+
s(R)["table-header-actions"] ? (n(), c("div", {
|
|
83
86
|
key: 1,
|
|
84
87
|
class: "table-header-actions",
|
|
85
|
-
"data-testid": `${t.testId}-${s(
|
|
88
|
+
"data-testid": `${t.testId}-${s(g).ACTIONS}`
|
|
86
89
|
}, [
|
|
87
90
|
d(e.$slots, "table-header-actions", {}, void 0, !0)
|
|
88
|
-
], 8,
|
|
91
|
+
], 8, W)) : f("", !0)
|
|
89
92
|
], 8, J)
|
|
90
|
-
], 10,
|
|
91
|
-
s(T) ? (n(),
|
|
93
|
+
], 10, j),
|
|
94
|
+
s(T) ? (n(), k(s(I), {
|
|
92
95
|
key: 1,
|
|
93
|
-
search: s(
|
|
94
|
-
"onUpdate:search": l[1] || (l[1] = (a) => $(
|
|
96
|
+
search: s(r),
|
|
97
|
+
"onUpdate:search": l[1] || (l[1] = (a) => $(r) ? r.value = a : null),
|
|
95
98
|
rows: [],
|
|
96
99
|
columns: t.loadingAndEmptyStatesColumns,
|
|
97
100
|
"is-loading": t.isLoading,
|
|
@@ -101,23 +104,23 @@ const p = ["data-testid"], q = ["data-testid"], J = ["data-testid"], K = ["data-
|
|
|
101
104
|
"empty-state-subtitle": t.emptyStateSubtitle,
|
|
102
105
|
"test-id": t.testId
|
|
103
106
|
}, b({
|
|
104
|
-
"empty-state":
|
|
107
|
+
"empty-state": y(() => [
|
|
105
108
|
d(e.$slots, "empty-state", {}, void 0, !0)
|
|
106
109
|
]),
|
|
107
110
|
_: 2
|
|
108
111
|
}, [
|
|
109
|
-
|
|
112
|
+
w(t.loadingAndEmptyStatesColumns, (a) => ({
|
|
110
113
|
name: m(a),
|
|
111
|
-
fn:
|
|
114
|
+
fn: y(() => [
|
|
112
115
|
d(e.$slots, `${m(a)}`, { column: a }, void 0, !0)
|
|
113
116
|
])
|
|
114
117
|
}))
|
|
115
|
-
]), 1032, ["search", "columns", "is-loading", "loading-row-count", "empty-state-variant", "empty-state-title", "empty-state-subtitle", "test-id"])) : (n(),
|
|
116
|
-
(n(!0),
|
|
118
|
+
]), 1032, ["search", "columns", "is-loading", "loading-row-count", "empty-state-variant", "empty-state-title", "empty-state-subtitle", "test-id"])) : (n(), c("div", X, [
|
|
119
|
+
(n(!0), c(P, null, w(t.tablesSettings, (a, u) => (n(), c("div", {
|
|
117
120
|
key: a.testId,
|
|
118
121
|
class: "table-wrapper"
|
|
119
122
|
}, [
|
|
120
|
-
a.rows.length ? (n(),
|
|
123
|
+
a.rows.length ? (n(), k(s(I), {
|
|
121
124
|
key: 0,
|
|
122
125
|
sections: a.sections,
|
|
123
126
|
columns: a.columns,
|
|
@@ -125,43 +128,47 @@ const p = ["data-testid"], q = ["data-testid"], J = ["data-testid"], K = ["data-
|
|
|
125
128
|
"row-height": a.rowHeight,
|
|
126
129
|
"is-sticky": t.isSticky,
|
|
127
130
|
"z-index-base": t.zIndexBase,
|
|
131
|
+
"get-row-id": t.getRowId,
|
|
132
|
+
"row-custom-class-key": t.rowCustomClassKey,
|
|
133
|
+
"row-data-key": t.rowDataKey,
|
|
128
134
|
"test-id": a.testId,
|
|
129
|
-
onClickRow: (o) => V(o,
|
|
130
|
-
onSaveRow: (o) => B(o,
|
|
135
|
+
onClickRow: (o) => V(o, u),
|
|
136
|
+
onSaveRow: (o) => B(o, u)
|
|
131
137
|
}, b({
|
|
132
|
-
"floating-row":
|
|
138
|
+
"floating-row": y(({ row: o, rowIndex: S }) => [
|
|
133
139
|
d(e.$slots, "floating-row", {
|
|
134
140
|
row: o,
|
|
135
|
-
rowIndex:
|
|
141
|
+
rowIndex: S,
|
|
142
|
+
tableIndex: u
|
|
136
143
|
}, void 0, !0)
|
|
137
144
|
]),
|
|
138
145
|
_: 2
|
|
139
146
|
}, [
|
|
140
|
-
|
|
147
|
+
w(a.columns, (o) => ({
|
|
141
148
|
name: m(o),
|
|
142
|
-
fn:
|
|
149
|
+
fn: y(() => [
|
|
143
150
|
d(e.$slots, `${m(o)}`, { column: o }, void 0, !0)
|
|
144
151
|
])
|
|
145
152
|
})),
|
|
146
|
-
|
|
147
|
-
name:
|
|
148
|
-
fn:
|
|
149
|
-
cell:
|
|
153
|
+
w(a.columns, (o) => ({
|
|
154
|
+
name: v(o),
|
|
155
|
+
fn: y(({
|
|
156
|
+
cell: S,
|
|
150
157
|
rowIndex: L,
|
|
151
|
-
isLoading:
|
|
152
|
-
cellIndex:
|
|
153
|
-
row:
|
|
158
|
+
isLoading: D,
|
|
159
|
+
cellIndex: N,
|
|
160
|
+
row: z
|
|
154
161
|
}) => [
|
|
155
|
-
d(e.$slots, `${
|
|
156
|
-
cell:
|
|
157
|
-
isLoading:
|
|
158
|
-
cellIndex:
|
|
159
|
-
row:
|
|
162
|
+
d(e.$slots, `${v(o)}`, {
|
|
163
|
+
cell: S,
|
|
164
|
+
isLoading: D,
|
|
165
|
+
cellIndex: N,
|
|
166
|
+
row: z,
|
|
160
167
|
rowIndex: L
|
|
161
168
|
}, void 0, !0)
|
|
162
169
|
])
|
|
163
170
|
}))
|
|
164
|
-
]), 1032, ["sections", "columns", "rows", "row-height", "is-sticky", "z-index-base", "test-id", "onClickRow", "onSaveRow"])) :
|
|
171
|
+
]), 1032, ["sections", "columns", "rows", "row-height", "is-sticky", "z-index-base", "get-row-id", "row-custom-class-key", "row-data-key", "test-id", "onClickRow", "onSaveRow"])) : f("", !0)
|
|
165
172
|
]))), 128))
|
|
166
173
|
]))
|
|
167
174
|
], 32));
|