@reportportal/ui-kit 0.0.1-alpha.102 → 0.0.1-alpha.104
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/dist/attachedFile.js +1 -1
- package/dist/{arrowUp-4a5caee7.js → chevronDownDropdown-66f5b1af.js} +4 -3
- package/dist/common/utils/index.d.ts +1 -0
- package/dist/common/utils/isString.d.ts +1 -0
- package/dist/components/fileDropArea/attachedFilesList/attachedFilesList.d.ts +1 -0
- package/dist/components/fileDropArea/hooks/useFileProcessing.d.ts +2 -2
- package/dist/components/fileDropArea/types.d.ts +1 -0
- package/dist/components/fileDropArea/utils/getValidationErrorMessage.d.ts +1 -1
- package/dist/components/table/constants.d.ts +3 -0
- package/dist/components/table/hooks/index.d.ts +4 -0
- package/dist/components/table/hooks/useColumnWidths.d.ts +8 -0
- package/dist/components/table/hooks/useTableColumns.d.ts +13 -0
- package/dist/components/table/hooks/useTableExpansion.d.ts +15 -0
- package/dist/components/table/hooks/useTableHover.d.ts +10 -0
- package/dist/components/table/types.d.ts +14 -2
- package/dist/components/table/utils.d.ts +7 -1
- package/dist/fileDropArea.js +160 -155
- package/dist/icons.js +37 -37
- package/dist/index-803576c3.js +110 -0
- package/dist/index.js +38 -38
- package/dist/style.css +1 -1
- package/dist/table-0ca84375.js +476 -0
- package/dist/table.js +2 -2
- package/package.json +1 -1
- package/dist/index-e27a72a8.js +0 -99
- package/dist/table-920fdad9.js +0 -142
package/dist/table-920fdad9.js
DELETED
|
@@ -1,142 +0,0 @@
|
|
|
1
|
-
import { jsxs as o, jsx as a } from "react/jsx-runtime";
|
|
2
|
-
import { useState as N, useMemo as K } from "react";
|
|
3
|
-
import { c as O } from "./bind-06a7ff84.js";
|
|
4
|
-
import { a as g, S as P } from "./arrowUp-4a5caee7.js";
|
|
5
|
-
import { C as w } from "./checkbox-ed6cc375.js";
|
|
6
|
-
const Q = "_table_1qo1m_1", V = "_label_1qo1m_96", W = {
|
|
7
|
-
table: Q,
|
|
8
|
-
"table-header": "_table-header_1qo1m_9",
|
|
9
|
-
"table-row": "_table-row_1qo1m_17",
|
|
10
|
-
"table-row-content": "_table-row-content_1qo1m_23",
|
|
11
|
-
"size-small": "_size-small_1qo1m_33",
|
|
12
|
-
"size-large": "_size-large_1qo1m_36",
|
|
13
|
-
"table-body": "_table-body_1qo1m_40",
|
|
14
|
-
"table-header-cell": "_table-header-cell_1qo1m_47",
|
|
15
|
-
"table-cell": "_table-cell_1qo1m_48",
|
|
16
|
-
"action-menu-cell": "_action-menu-cell_1qo1m_53",
|
|
17
|
-
"checkbox-cell": "_checkbox-cell_1qo1m_65",
|
|
18
|
-
"primary-cell": "_primary-cell_1qo1m_79",
|
|
19
|
-
label: V,
|
|
20
|
-
"sortable-cell": "_sortable-cell_1qo1m_100",
|
|
21
|
-
"align-right": "_align-right_1qo1m_103",
|
|
22
|
-
"align-center": "_align-center_1qo1m_109"
|
|
23
|
-
}, S = "asc", X = (t) => t.toLowerCase() === S, Y = (t) => t.map((r) => r.key), l = O.bind(W), ae = ({
|
|
24
|
-
data: t,
|
|
25
|
-
primaryColumn: r,
|
|
26
|
-
fixedColumns: i,
|
|
27
|
-
renderRowActions: h,
|
|
28
|
-
className: f = "",
|
|
29
|
-
rowClassName: x = "",
|
|
30
|
-
headerClassName: z = "",
|
|
31
|
-
selectable: b = !1,
|
|
32
|
-
selectedRowIds: s = [],
|
|
33
|
-
sortingDirection: y = S,
|
|
34
|
-
sortingColumn: n = r,
|
|
35
|
-
sortableColumns: _ = Y([r, ...i]),
|
|
36
|
-
onChangeSorting: M = () => {
|
|
37
|
-
},
|
|
38
|
-
onToggleRowSelection: u = () => {
|
|
39
|
-
},
|
|
40
|
-
onToggleAllRowsSelection: A = () => {
|
|
41
|
-
}
|
|
42
|
-
}) => {
|
|
43
|
-
const [L, k] = N(null), [E, v] = N(null), m = K(() => [{ ...r, primary: !0 }, ...i], [r, i]), j = (e) => {
|
|
44
|
-
_.includes(e) && M({ key: e, direction: y });
|
|
45
|
-
}, p = (e) => ({
|
|
46
|
-
width: e.width,
|
|
47
|
-
textAlign: e.align
|
|
48
|
-
}), C = (e) => {
|
|
49
|
-
k(e);
|
|
50
|
-
}, H = () => {
|
|
51
|
-
k(null);
|
|
52
|
-
}, T = (e) => {
|
|
53
|
-
v(e);
|
|
54
|
-
}, $ = () => {
|
|
55
|
-
v(null);
|
|
56
|
-
}, D = (e) => {
|
|
57
|
-
u(e);
|
|
58
|
-
}, U = () => {
|
|
59
|
-
A();
|
|
60
|
-
}, B = t.every((e) => s.includes(e.id)), F = t.some((e) => s.includes(e.id)), q = (s == null ? void 0 : s.length) > 0, G = (e) => {
|
|
61
|
-
var c;
|
|
62
|
-
return `size-${((c = e.rowConfigs) == null ? void 0 : c.size) ?? "default"}`;
|
|
63
|
-
}, J = (e) => {
|
|
64
|
-
if (_.includes(e))
|
|
65
|
-
return (n == null ? void 0 : n.key) === e ? X(y) ? /* @__PURE__ */ a(g, {}) : /* @__PURE__ */ a(P, {}) : /* @__PURE__ */ a(g, {});
|
|
66
|
-
};
|
|
67
|
-
return /* @__PURE__ */ o("div", { className: l("table", f), children: [
|
|
68
|
-
/* @__PURE__ */ o("div", { className: l("table-header", z), children: [
|
|
69
|
-
b && /* @__PURE__ */ a("div", { className: l("table-header-cell", "checkbox-cell"), children: q && /* @__PURE__ */ a(
|
|
70
|
-
w,
|
|
71
|
-
{
|
|
72
|
-
value: B,
|
|
73
|
-
partiallyChecked: F,
|
|
74
|
-
onChange: U,
|
|
75
|
-
className: l("checkbox-cell")
|
|
76
|
-
}
|
|
77
|
-
) }),
|
|
78
|
-
m.map((e) => /* @__PURE__ */ a(
|
|
79
|
-
"button",
|
|
80
|
-
{
|
|
81
|
-
className: l("table-header-cell", {
|
|
82
|
-
[`align-${e.align}`]: "align" in e,
|
|
83
|
-
"primary-cell": "primary" in e && e.primary,
|
|
84
|
-
"sortable-cell": _.includes(e.key)
|
|
85
|
-
}),
|
|
86
|
-
style: p(e),
|
|
87
|
-
children: /* @__PURE__ */ o(
|
|
88
|
-
"div",
|
|
89
|
-
{
|
|
90
|
-
className: l("label"),
|
|
91
|
-
onClick: () => j(e.key),
|
|
92
|
-
onMouseEnter: () => C(e.key),
|
|
93
|
-
onMouseLeave: H,
|
|
94
|
-
children: [
|
|
95
|
-
/* @__PURE__ */ a("span", { children: e.header }),
|
|
96
|
-
(L === e.key || (n == null ? void 0 : n.key) === e.key) && J(e.key)
|
|
97
|
-
]
|
|
98
|
-
}
|
|
99
|
-
)
|
|
100
|
-
},
|
|
101
|
-
e.key
|
|
102
|
-
)),
|
|
103
|
-
h && /* @__PURE__ */ a("div", { className: l("table-header-cell", "action-menu-cell") })
|
|
104
|
-
] }),
|
|
105
|
-
/* @__PURE__ */ a("div", { className: l("table-body"), children: t.map((e, d) => /* @__PURE__ */ o(
|
|
106
|
-
"div",
|
|
107
|
-
{
|
|
108
|
-
className: l("table-row", G(e), x),
|
|
109
|
-
onMouseEnter: () => T(d),
|
|
110
|
-
onMouseLeave: $,
|
|
111
|
-
children: [
|
|
112
|
-
b && /* @__PURE__ */ a("div", { className: l("table-cell", "checkbox-cell"), children: (q || E === d) && /* @__PURE__ */ a(
|
|
113
|
-
w,
|
|
114
|
-
{
|
|
115
|
-
value: s.includes(e.id),
|
|
116
|
-
onChange: () => D(e.id),
|
|
117
|
-
className: l("checkbox-cell")
|
|
118
|
-
}
|
|
119
|
-
) }),
|
|
120
|
-
/* @__PURE__ */ o("div", { className: l("table-row-content"), children: [
|
|
121
|
-
m.map((c) => /* @__PURE__ */ a(
|
|
122
|
-
"div",
|
|
123
|
-
{
|
|
124
|
-
className: l("table-cell", {
|
|
125
|
-
"primary-cell": "primary" in c && c.primary
|
|
126
|
-
}),
|
|
127
|
-
style: p(c),
|
|
128
|
-
children: e[c.key].component || e[c.key].content || e[c.key]
|
|
129
|
-
},
|
|
130
|
-
c.key
|
|
131
|
-
)),
|
|
132
|
-
h && /* @__PURE__ */ a("div", { className: l("table-cell", "action-menu-cell"), children: h(e.metaData) })
|
|
133
|
-
] })
|
|
134
|
-
]
|
|
135
|
-
},
|
|
136
|
-
e.id
|
|
137
|
-
)) })
|
|
138
|
-
] });
|
|
139
|
-
};
|
|
140
|
-
export {
|
|
141
|
-
ae as T
|
|
142
|
-
};
|