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