@stenajs-webui/grid 20.6.3 → 20.6.5
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/index.es.js +27 -25
- package/dist/index.es.js.map +1 -1
- package/dist/index.js +2 -2
- package/dist/index.js.map +1 -1
- package/package.json +9 -9
package/dist/index.es.js
CHANGED
|
@@ -18,9 +18,11 @@ import { useDispatch as dr, useSelector as Ke } from "react-redux";
|
|
|
18
18
|
import { createSortOrderActions as hr, createSelectedIdsActions as Qe, createEntityActions as mr, createSortOrderReducerInitialState as fr, createSelectedIdsReducerInitialState as Xe, reducerIdGate as ke, createSortOrderReducer as pr, createSelectedIdsReducer as Je, createEntityReducer as vr, reducerIdGateAction as ne } from "@stenajs-webui/redux";
|
|
19
19
|
import { combineReducers as gr } from "redux";
|
|
20
20
|
import { LoadingScreen as wr, ErrorScreen as yr } from "@stenajs-webui/panels";
|
|
21
|
-
import
|
|
21
|
+
import Cr from "lodash/compact";
|
|
22
|
+
import br from "lodash/lowerCase";
|
|
23
|
+
import xr from "lodash/upperFirst";
|
|
22
24
|
import kr from "@emotion/styled";
|
|
23
|
-
const gt = G.createContext({}),
|
|
25
|
+
const gt = G.createContext({}), as = ({
|
|
24
26
|
children: e,
|
|
25
27
|
numCols: t,
|
|
26
28
|
numRows: r,
|
|
@@ -100,7 +102,7 @@ const gt = G.createContext({}), ns = ({
|
|
|
100
102
|
indent: n,
|
|
101
103
|
...o
|
|
102
104
|
}
|
|
103
|
-
), Pr = "var(--lhds-color-ui-300)", Ir = "var(--lhds-color-blue-500)", yt = "var(--lhds-color-blue-50)", Or = "var(--lhds-color-blue-100)", ve = `1px solid ${Pr}`, Dr = "1px solid transparent", Ae = "var(--swui-expand-highlight-border-width) solid transparent", Ct = `var(--swui-expand-highlight-border-width) solid ${Ir}`, Fe = "40px", He = "40px", bt = "40px",
|
|
105
|
+
), Pr = "var(--lhds-color-ui-300)", Ir = "var(--lhds-color-blue-500)", yt = "var(--lhds-color-blue-50)", Or = "var(--lhds-color-blue-100)", ve = `1px solid ${Pr}`, Dr = "1px solid transparent", Ae = "var(--swui-expand-highlight-border-width) solid transparent", Ct = `var(--swui-expand-highlight-border-width) solid ${Ir}`, Fe = "40px", He = "40px", bt = "40px", ss = (e) => /* @__PURE__ */ s(
|
|
104
106
|
Tr,
|
|
105
107
|
{
|
|
106
108
|
width: bt,
|
|
@@ -236,24 +238,24 @@ const gt = G.createContext({}), ns = ({
|
|
|
236
238
|
}
|
|
237
239
|
);
|
|
238
240
|
}
|
|
239
|
-
),
|
|
241
|
+
), is = (e) => /* @__PURE__ */ s(
|
|
240
242
|
Ye,
|
|
241
243
|
{
|
|
242
244
|
width: bt,
|
|
243
245
|
justifyContent: "center",
|
|
244
246
|
...e
|
|
245
247
|
}
|
|
246
|
-
),
|
|
248
|
+
), cs = ({
|
|
247
249
|
label: e,
|
|
248
250
|
flex: t,
|
|
249
251
|
width: r,
|
|
250
252
|
indent: n = 1,
|
|
251
253
|
height: o = He
|
|
252
|
-
}) => /* @__PURE__ */ s(Ye, { width: r, flex: t, height: o, children: /* @__PURE__ */ s(de, { indent: n, spacing: !0, children: /* @__PURE__ */ s(Z, { variant: "bold", children: e }) }) }),
|
|
254
|
+
}) => /* @__PURE__ */ s(Ye, { width: r, flex: t, height: o, children: /* @__PURE__ */ s(de, { indent: n, spacing: !0, children: /* @__PURE__ */ s(Z, { variant: "bold", children: e }) }) }), ls = G.memo(
|
|
253
255
|
({ style: e, height: t = He, ...r }) => /* @__PURE__ */ s(O, { style: e, height: t, ...r })
|
|
254
256
|
), Mr = "_tableRow_1cphw_1", Rr = {
|
|
255
257
|
tableRow: Mr
|
|
256
|
-
},
|
|
258
|
+
}, us = ({
|
|
257
259
|
hideBorderTop: e,
|
|
258
260
|
height: t = He,
|
|
259
261
|
className: r,
|
|
@@ -546,7 +548,7 @@ const gt = G.createContext({}), ns = ({
|
|
|
546
548
|
stopEditingAndRevert: l,
|
|
547
549
|
stopEditingAndMove: u
|
|
548
550
|
};
|
|
549
|
-
},
|
|
551
|
+
}, ds = function({
|
|
550
552
|
allowedInputType: t,
|
|
551
553
|
value: r = "",
|
|
552
554
|
entityId: n,
|
|
@@ -1250,7 +1252,7 @@ const gt = G.createContext({}), ns = ({
|
|
|
1250
1252
|
}, ot = (e, t) => {
|
|
1251
1253
|
const { background: r, backgroundResolver: n } = e ?? {};
|
|
1252
1254
|
return Ft(n, t, r);
|
|
1253
|
-
}, Yn = (e) => e == null ? "" : e instanceof Date ? e.toISOString() : typeof e == "object" ? JSON.stringify(e) : String(e), zn = (e) => br(
|
|
1255
|
+
}, Yn = (e) => e == null ? "" : e instanceof Date ? e.toISOString() : typeof e == "object" ? JSON.stringify(e) : String(e), zn = (e) => xr(br(e)), qn = "_standardTableCell_1xzcm_1", _n = {
|
|
1254
1256
|
standardTableCell: qn
|
|
1255
1257
|
}, jn = G.memo(
|
|
1256
1258
|
function({
|
|
@@ -2052,7 +2054,7 @@ const gt = G.createContext({}), ns = ({
|
|
|
2052
2054
|
l && /* @__PURE__ */ s("th", { style: D, children: /* @__PURE__ */ s(O, { indent: l }) }),
|
|
2053
2055
|
/* @__PURE__ */ s("th", { style: D })
|
|
2054
2056
|
] });
|
|
2055
|
-
}),
|
|
2057
|
+
}), hs = function({
|
|
2056
2058
|
tableContext: t,
|
|
2057
2059
|
config: r,
|
|
2058
2060
|
columnOrder: n,
|
|
@@ -2199,7 +2201,7 @@ const gt = G.createContext({}), ns = ({
|
|
|
2199
2201
|
selectAllOnMount: !i,
|
|
2200
2202
|
onMove: l
|
|
2201
2203
|
}
|
|
2202
|
-
) : /* @__PURE__ */ s(L, { children: /* @__PURE__ */ s(Z, { color: "var(--swui-primary-action-color)", size: e, children: t }) }),
|
|
2204
|
+
) : /* @__PURE__ */ s(L, { children: /* @__PURE__ */ s(Z, { color: "var(--swui-primary-action-color)", size: e, children: t }) }), ms = (e, t, r) => ({
|
|
2203
2205
|
label: n,
|
|
2204
2206
|
item: o,
|
|
2205
2207
|
gridCell: {
|
|
@@ -3666,7 +3668,7 @@ const La = () => [
|
|
|
3666
3668
|
numPassengers: 655,
|
|
3667
3669
|
departure: E(/* @__PURE__ */ new Date(), 5)
|
|
3668
3670
|
}
|
|
3669
|
-
], lt = (e, t, r) => e.map((n) => n.id === t ? { ...n, ...r } : n),
|
|
3671
|
+
], lt = (e, t, r) => e.map((n) => n.id === t ? { ...n, ...r } : n), fs = {
|
|
3670
3672
|
keyResolver: (e) => e.id,
|
|
3671
3673
|
showHeaderCheckbox: !0,
|
|
3672
3674
|
showRowCheckbox: !0,
|
|
@@ -3705,7 +3707,7 @@ const La = () => [
|
|
|
3705
3707
|
})
|
|
3706
3708
|
},
|
|
3707
3709
|
columnOrder: ["id", "active", "name", "ship", "numPassengers", "departure"]
|
|
3708
|
-
},
|
|
3710
|
+
}, ps = La(), vs = (e) => {
|
|
3709
3711
|
const [t, r] = Se(e), n = P(
|
|
3710
3712
|
(a, i) => {
|
|
3711
3713
|
r(
|
|
@@ -3733,13 +3735,13 @@ const La = () => [
|
|
|
3733
3735
|
};
|
|
3734
3736
|
export {
|
|
3735
3737
|
wt as CrudStatusIndicator,
|
|
3736
|
-
|
|
3738
|
+
ds as EditableTextCellWithCrudAndModified,
|
|
3737
3739
|
gt as GridHooksContext,
|
|
3738
|
-
|
|
3740
|
+
as as GridHooksTable,
|
|
3739
3741
|
Sr as ModifiedField,
|
|
3740
|
-
|
|
3741
|
-
|
|
3742
|
-
|
|
3742
|
+
ss as SmallTableCell,
|
|
3743
|
+
is as SmallTableHead,
|
|
3744
|
+
hs as StandardTable,
|
|
3743
3745
|
It as StandardTableActionsContext,
|
|
3744
3746
|
Xn as StandardTableCell,
|
|
3745
3747
|
jn as StandardTableCellUi,
|
|
@@ -3752,13 +3754,13 @@ export {
|
|
|
3752
3754
|
Pt as StandardTableStateContext,
|
|
3753
3755
|
Tt as StandardTableTableIdContext,
|
|
3754
3756
|
Tr as TableCell,
|
|
3755
|
-
|
|
3757
|
+
cs as TableColumnGroupHead,
|
|
3756
3758
|
Ye as TableHeadItem,
|
|
3757
|
-
|
|
3758
|
-
|
|
3759
|
+
ls as TableHeadRow,
|
|
3760
|
+
us as TableRow,
|
|
3759
3761
|
Kn as TextCell,
|
|
3760
3762
|
ce as createColumnConfig,
|
|
3761
|
-
|
|
3763
|
+
ms as createEditableTextCellWithStatus,
|
|
3762
3764
|
Ut as createGroupConfigAndIdsForRows,
|
|
3763
3765
|
Zr as createInternalStandardTableActions,
|
|
3764
3766
|
La as createItemsMocks,
|
|
@@ -3772,11 +3774,11 @@ export {
|
|
|
3772
3774
|
zn as formatColumnIdToHeaderCellLabel,
|
|
3773
3775
|
Yn as formatValueLabel,
|
|
3774
3776
|
Be as hasIndicatorContent,
|
|
3775
|
-
|
|
3777
|
+
ps as mockedItems,
|
|
3776
3778
|
Wn as multitypeComparator,
|
|
3777
3779
|
lt as setListItemFields,
|
|
3778
3780
|
bt as smallTableRowWidth,
|
|
3779
|
-
|
|
3781
|
+
fs as standardTableConfigForStories,
|
|
3780
3782
|
yt as tableBackgroundColorExpanded,
|
|
3781
3783
|
Or as tableBackgroundHoverColorExpanded,
|
|
3782
3784
|
ve as tableBorder,
|
|
@@ -3795,7 +3797,7 @@ export {
|
|
|
3795
3797
|
Qr as useGridNavigation,
|
|
3796
3798
|
xt as useGridNavigationOptionsFromContext,
|
|
3797
3799
|
cn as useLastColumnConfig,
|
|
3798
|
-
|
|
3800
|
+
vs as useListState,
|
|
3799
3801
|
Pn as useLocalStateTableContext,
|
|
3800
3802
|
Gr as useRevertableValue,
|
|
3801
3803
|
Bn as useRowCheckbox,
|