@dexteel/mesf-core 7.9.0 → 7.10.0
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/.release-please-manifest.json +1 -1
- package/CHANGELOG.md +7 -0
- package/dist/index.esm.js +415 -223
- package/dist/index.esm.js.map +1 -1
- package/package.json +2 -2
package/dist/index.esm.js
CHANGED
|
@@ -59,7 +59,7 @@ import { DateTimePicker as DateTimePicker$1 } from '@mui/x-date-pickers/DateTime
|
|
|
59
59
|
import ClearAllIcon from '@mui/icons-material/ClearAll';
|
|
60
60
|
import ExpandMoreIcon from '@mui/icons-material/ExpandMore';
|
|
61
61
|
import axios from 'axios';
|
|
62
|
-
import { Group as Group$1, Panel, Separator } from 'react-resizable-panels';
|
|
62
|
+
import { Group as Group$1, Panel, Separator, useDefaultLayout } from 'react-resizable-panels';
|
|
63
63
|
import { LocalizationProvider as LocalizationProvider$1 } from '@mui/x-date-pickers/LocalizationProvider';
|
|
64
64
|
import InsertChartIcon from '@mui/icons-material/InsertChart';
|
|
65
65
|
import ReactECharts from 'echarts-for-react';
|
|
@@ -21047,6 +21047,8 @@ var Filters$3 = function (_a) {
|
|
|
21047
21047
|
};
|
|
21048
21048
|
|
|
21049
21049
|
var moment$a = getMomentTz();
|
|
21050
|
+
// Default layout matching original Grid md:5 / md:7 ratio (41.67% / 58.33%)
|
|
21051
|
+
var DEFAULT_LAYOUT$3 = { left: 42, right: 58 };
|
|
21050
21052
|
var Logbook$3 = function () {
|
|
21051
21053
|
var entry = useLogbookSettings().entry;
|
|
21052
21054
|
var defaultAreaId = useUserContext().state.defaultAreaId;
|
|
@@ -21076,10 +21078,17 @@ var Logbook$3 = function () {
|
|
|
21076
21078
|
var _f = useState(null), selectedRowData = _f[0], setSelectedRowData = _f[1];
|
|
21077
21079
|
var _g = useState(false), showRemoveDialog = _g[0], setShowRemoveDialog = _g[1];
|
|
21078
21080
|
var _h = useContextMenuMESF(), registerConfig = _h.registerConfig, showContextMenu = _h.showContextMenu;
|
|
21079
|
-
|
|
21081
|
+
// Resizable panels layout persistence
|
|
21082
|
+
var _j = useDefaultLayout({
|
|
21083
|
+
id: "logbook-entry-v2",
|
|
21084
|
+
storage: localStorage,
|
|
21085
|
+
}), savedLayout = _j.defaultLayout, onLayoutChange = _j.onLayoutChange;
|
|
21086
|
+
// Use saved layout or default to avoid flash on initial render
|
|
21087
|
+
var resolvedLayout = savedLayout !== null && savedLayout !== void 0 ? savedLayout : DEFAULT_LAYOUT$3;
|
|
21088
|
+
var _k = useEntries$1({
|
|
21080
21089
|
shiftId: shiftInfo === null || shiftInfo === void 0 ? void 0 : shiftInfo.CurrentShiftId,
|
|
21081
21090
|
assetId: withAssetFilter ? assetId : undefined,
|
|
21082
|
-
}), rows =
|
|
21091
|
+
}), rows = _k.data, isLoading = _k.isLoading, e = _k.error, isError = _k.isError, refetch = _k.refetch;
|
|
21083
21092
|
var columnDefs = useTableData$3({
|
|
21084
21093
|
showContextMenu: showContextMenu,
|
|
21085
21094
|
allowAttachments: allowAttachments,
|
|
@@ -21276,21 +21285,29 @@ var Logbook$3 = function () {
|
|
|
21276
21285
|
}); })();
|
|
21277
21286
|
}
|
|
21278
21287
|
}, []);
|
|
21279
|
-
return (React__default.createElement(
|
|
21280
|
-
|
|
21281
|
-
|
|
21282
|
-
|
|
21283
|
-
|
|
21284
|
-
|
|
21285
|
-
|
|
21286
|
-
|
|
21287
|
-
|
|
21288
|
-
|
|
21289
|
-
|
|
21290
|
-
|
|
21291
|
-
|
|
21288
|
+
return (React__default.createElement(Box, { sx: {
|
|
21289
|
+
width: "100%",
|
|
21290
|
+
height: "calc(100vh - 130px)",
|
|
21291
|
+
display: "flex",
|
|
21292
|
+
flexDirection: "column",
|
|
21293
|
+
} },
|
|
21294
|
+
React__default.createElement(Box, { sx: { mb: 2 } },
|
|
21295
|
+
React__default.createElement(Typography$1, { variant: "h5", style: {
|
|
21296
|
+
fontWeight: 600,
|
|
21297
|
+
userSelect: "none",
|
|
21298
|
+
} }, "LOGBOOK")),
|
|
21299
|
+
React__default.createElement(Group$1, { id: "logbook-entry-group", orientation: "horizontal", defaultLayout: resolvedLayout, onLayoutChange: onLayoutChange, style: { flex: 1, width: "100%" } },
|
|
21300
|
+
React__default.createElement(Panel, { id: "left", defaultSize: 42, minSize: 25, style: { paddingBottom: 5 } },
|
|
21301
|
+
React__default.createElement(Box, { sx: {
|
|
21302
|
+
display: "flex",
|
|
21303
|
+
flexDirection: "column",
|
|
21304
|
+
gap: 1,
|
|
21305
|
+
height: "100%",
|
|
21306
|
+
pr: 1,
|
|
21307
|
+
} },
|
|
21308
|
+
React__default.createElement(Filters$3, { withAssetFilter: withAssetFilter, filterAssets: filterAssets, quickFilter: quickFilter, onQuickFilterChange: onQuickFilterChange, assetId: assetId, setAssetId: setAssetId }),
|
|
21292
21309
|
React__default.createElement(Paper, { elevation: 1, style: {
|
|
21293
|
-
|
|
21310
|
+
flex: 1,
|
|
21294
21311
|
width: "100%",
|
|
21295
21312
|
} },
|
|
21296
21313
|
React__default.createElement(AgGridReact, { loading: isLoading, rowData: rows, columnDefs: columnDefs, defaultColDef: defaultColDef, rowHeight: 38, headerHeight: 42, loadingOverlayComponent: CenteredLazyLoading, animateRows: true, getContextMenuItems: getContextMenuItems, onRowClicked: rowClicked, onCellKeyDown: onCellKeyDown, onGridReady: function (params) { return (gridApiRef.current = params.api); }, getRowId: function (params) { return "".concat(params.data.EntryId); }, gridOptions: {
|
|
@@ -21319,80 +21336,111 @@ var Logbook$3 = function () {
|
|
|
21319
21336
|
],
|
|
21320
21337
|
},
|
|
21321
21338
|
} })))),
|
|
21322
|
-
React__default.createElement(
|
|
21323
|
-
|
|
21324
|
-
|
|
21325
|
-
|
|
21326
|
-
|
|
21327
|
-
|
|
21328
|
-
|
|
21329
|
-
|
|
21330
|
-
|
|
21331
|
-
|
|
21332
|
-
|
|
21333
|
-
|
|
21334
|
-
|
|
21335
|
-
|
|
21336
|
-
|
|
21337
|
-
|
|
21338
|
-
|
|
21339
|
-
|
|
21340
|
-
|
|
21341
|
-
|
|
21342
|
-
|
|
21343
|
-
|
|
21344
|
-
|
|
21345
|
-
|
|
21346
|
-
|
|
21347
|
-
|
|
21348
|
-
|
|
21349
|
-
|
|
21350
|
-
|
|
21351
|
-
|
|
21352
|
-
|
|
21353
|
-
|
|
21354
|
-
|
|
21355
|
-
|
|
21356
|
-
|
|
21357
|
-
|
|
21358
|
-
|
|
21359
|
-
|
|
21360
|
-
|
|
21361
|
-
|
|
21362
|
-
var _a, _b, _c;
|
|
21363
|
-
return __generator(this, function (_d) {
|
|
21364
|
-
switch (_d.label) {
|
|
21365
|
-
case 0: return [4 /*yield*/, refetch()];
|
|
21366
|
-
case 1:
|
|
21367
|
-
_d.sent();
|
|
21368
|
-
retryRowNode = (_a = gridApiRef.current) === null || _a === void 0 ? void 0 : _a.getRowNode(entryId.toString());
|
|
21369
|
-
if (retryRowNode) {
|
|
21370
|
-
(_b = gridApiRef.current) === null || _b === void 0 ? void 0 : _b.ensureNodeVisible(retryRowNode);
|
|
21371
|
-
retryRowNode.setSelected(true);
|
|
21372
|
-
setSelectedRowData(retryRowNode.data);
|
|
21373
|
-
}
|
|
21374
|
-
else {
|
|
21375
|
-
setShow("");
|
|
21376
|
-
setSelectedRowData(null);
|
|
21377
|
-
(_c = gridApiRef.current) === null || _c === void 0 ? void 0 : _c.deselectAll();
|
|
21378
|
-
}
|
|
21379
|
-
return [2 /*return*/];
|
|
21380
|
-
}
|
|
21381
|
-
});
|
|
21382
|
-
}); }, 500);
|
|
21383
|
-
}
|
|
21384
|
-
}, 200);
|
|
21385
|
-
return [3 /*break*/, 3];
|
|
21386
|
-
case 2:
|
|
21387
|
-
setShow("");
|
|
21388
|
-
setSelectedRowData(null);
|
|
21389
|
-
(_a = gridApiRef.current) === null || _a === void 0 ? void 0 : _a.deselectAll();
|
|
21390
|
-
navigate("".concat(routeLogbookEntry$1, "/").concat(shiftId || (shiftInfo === null || shiftInfo === void 0 ? void 0 : shiftInfo.CurrentShiftId)));
|
|
21391
|
-
_b.label = 3;
|
|
21392
|
-
case 3: return [2 /*return*/];
|
|
21339
|
+
React__default.createElement(Separator, { style: {
|
|
21340
|
+
display: "flex",
|
|
21341
|
+
alignItems: "center",
|
|
21342
|
+
justifyContent: "center",
|
|
21343
|
+
cursor: "col-resize",
|
|
21344
|
+
} },
|
|
21345
|
+
React__default.createElement(Box, { sx: {
|
|
21346
|
+
width: 8,
|
|
21347
|
+
height: 48,
|
|
21348
|
+
borderRadius: 1,
|
|
21349
|
+
backgroundColor: "#e0e0e0",
|
|
21350
|
+
display: "flex",
|
|
21351
|
+
flexDirection: "column",
|
|
21352
|
+
alignItems: "center",
|
|
21353
|
+
justifyContent: "center",
|
|
21354
|
+
gap: "3px",
|
|
21355
|
+
transition: "background-color 0.2s",
|
|
21356
|
+
"&:hover": {
|
|
21357
|
+
backgroundColor: "primary.main",
|
|
21358
|
+
"& .grip-dot": {
|
|
21359
|
+
backgroundColor: "#fff",
|
|
21360
|
+
},
|
|
21361
|
+
},
|
|
21362
|
+
} }, __spreadArray([], Array(5), true).map(function (_, i) { return (React__default.createElement(Box, { key: i, className: "grip-dot", sx: {
|
|
21363
|
+
width: 4,
|
|
21364
|
+
height: 4,
|
|
21365
|
+
borderRadius: "50%",
|
|
21366
|
+
backgroundColor: "#9e9e9e",
|
|
21367
|
+
transition: "background-color 0.2s",
|
|
21368
|
+
} })); }))),
|
|
21369
|
+
React__default.createElement(Panel, { id: "right", defaultSize: 58, minSize: 30, style: { paddingBottom: 5 } },
|
|
21370
|
+
React__default.createElement(Box, { sx: { pl: 1, height: "100%" } },
|
|
21371
|
+
React__default.createElement(EntryViewer$3, { entry: selectedRowData, show: show, onChangeShow: function () {
|
|
21372
|
+
var newShow = show === "view" ? "edit" : "view";
|
|
21373
|
+
setShow(newShow);
|
|
21374
|
+
if (entryId && entryId !== "new") {
|
|
21375
|
+
var targetUrl = newShow === "edit"
|
|
21376
|
+
? "/logbook/entry/".concat(shiftId || (shiftInfo === null || shiftInfo === void 0 ? void 0 : shiftInfo.CurrentShiftId), "?entryId=").concat(entryId, "&action=edit")
|
|
21377
|
+
: "/logbook/entry/".concat(shiftId || (shiftInfo === null || shiftInfo === void 0 ? void 0 : shiftInfo.CurrentShiftId), "?entryId=").concat(entryId, "&action=view");
|
|
21378
|
+
navigate(targetUrl);
|
|
21393
21379
|
}
|
|
21394
|
-
})
|
|
21395
|
-
|
|
21380
|
+
}, preselectedAssetId: assetId, withAssetFilter: withAssetFilter, canEditAsset: canEditAsset, canEditShift: canEditShift, filterAssets: filterAssets, allowAttachments: allowAttachments, shiftsRange: shiftsRange, onHide: function (entryId, shouldStayInEditMode) { return __awaiter(void 0, void 0, void 0, function () {
|
|
21381
|
+
var targetUrl;
|
|
21382
|
+
var _a;
|
|
21383
|
+
return __generator(this, function (_b) {
|
|
21384
|
+
switch (_b.label) {
|
|
21385
|
+
case 0:
|
|
21386
|
+
if (!entryId) return [3 /*break*/, 2];
|
|
21387
|
+
// First refetch to ensure we have the latest data
|
|
21388
|
+
return [4 /*yield*/, refetch()];
|
|
21389
|
+
case 1:
|
|
21390
|
+
// First refetch to ensure we have the latest data
|
|
21391
|
+
_b.sent();
|
|
21392
|
+
targetUrl = shouldStayInEditMode
|
|
21393
|
+
? "/logbook/entry/".concat(shiftId || (shiftInfo === null || shiftInfo === void 0 ? void 0 : shiftInfo.CurrentShiftId), "?entryId=").concat(entryId, "&action=edit")
|
|
21394
|
+
: "/logbook/entry/".concat(shiftId || (shiftInfo === null || shiftInfo === void 0 ? void 0 : shiftInfo.CurrentShiftId), "?entryId=").concat(entryId, "&action=view");
|
|
21395
|
+
navigate(targetUrl);
|
|
21396
|
+
setShow(shouldStayInEditMode ? "edit" : "view");
|
|
21397
|
+
// Additional delay to allow navigation and state updates to complete
|
|
21398
|
+
setTimeout(function () {
|
|
21399
|
+
var _a, _b;
|
|
21400
|
+
var rowNode = (_a = gridApiRef.current) === null || _a === void 0 ? void 0 : _a.getRowNode(entryId.toString());
|
|
21401
|
+
if (rowNode) {
|
|
21402
|
+
(_b = gridApiRef.current) === null || _b === void 0 ? void 0 : _b.ensureNodeVisible(rowNode);
|
|
21403
|
+
rowNode.setSelected(true);
|
|
21404
|
+
setSelectedRowData(rowNode.data);
|
|
21405
|
+
}
|
|
21406
|
+
else {
|
|
21407
|
+
// If still not found, try one more refetch
|
|
21408
|
+
setTimeout(function () { return __awaiter(void 0, void 0, void 0, function () {
|
|
21409
|
+
var retryRowNode;
|
|
21410
|
+
var _a, _b, _c;
|
|
21411
|
+
return __generator(this, function (_d) {
|
|
21412
|
+
switch (_d.label) {
|
|
21413
|
+
case 0: return [4 /*yield*/, refetch()];
|
|
21414
|
+
case 1:
|
|
21415
|
+
_d.sent();
|
|
21416
|
+
retryRowNode = (_a = gridApiRef.current) === null || _a === void 0 ? void 0 : _a.getRowNode(entryId.toString());
|
|
21417
|
+
if (retryRowNode) {
|
|
21418
|
+
(_b = gridApiRef.current) === null || _b === void 0 ? void 0 : _b.ensureNodeVisible(retryRowNode);
|
|
21419
|
+
retryRowNode.setSelected(true);
|
|
21420
|
+
setSelectedRowData(retryRowNode.data);
|
|
21421
|
+
}
|
|
21422
|
+
else {
|
|
21423
|
+
setShow("");
|
|
21424
|
+
setSelectedRowData(null);
|
|
21425
|
+
(_c = gridApiRef.current) === null || _c === void 0 ? void 0 : _c.deselectAll();
|
|
21426
|
+
}
|
|
21427
|
+
return [2 /*return*/];
|
|
21428
|
+
}
|
|
21429
|
+
});
|
|
21430
|
+
}); }, 500);
|
|
21431
|
+
}
|
|
21432
|
+
}, 200);
|
|
21433
|
+
return [3 /*break*/, 3];
|
|
21434
|
+
case 2:
|
|
21435
|
+
setShow("");
|
|
21436
|
+
setSelectedRowData(null);
|
|
21437
|
+
(_a = gridApiRef.current) === null || _a === void 0 ? void 0 : _a.deselectAll();
|
|
21438
|
+
navigate("".concat(routeLogbookEntry$1, "/").concat(shiftId || (shiftInfo === null || shiftInfo === void 0 ? void 0 : shiftInfo.CurrentShiftId)));
|
|
21439
|
+
_b.label = 3;
|
|
21440
|
+
case 3: return [2 /*return*/];
|
|
21441
|
+
}
|
|
21442
|
+
});
|
|
21443
|
+
}); } })))),
|
|
21396
21444
|
React__default.createElement(RemoveEntryDialog$1, { entry: selectedRowData, show: showRemoveDialog, onHide: function (shouldUpdate) {
|
|
21397
21445
|
if (shouldUpdate) {
|
|
21398
21446
|
refetch();
|
|
@@ -21712,6 +21760,8 @@ var Filters$2 = function (_a) {
|
|
|
21712
21760
|
};
|
|
21713
21761
|
|
|
21714
21762
|
var moment$7 = getMomentTz();
|
|
21763
|
+
// Default layout matching original Grid md:5 / md:7 ratio (41.67% / 58.33%)
|
|
21764
|
+
var DEFAULT_LAYOUT$2 = { left: 42, right: 58 };
|
|
21715
21765
|
var Logbook$2 = function () {
|
|
21716
21766
|
var report = useLogbookSettings().report;
|
|
21717
21767
|
var defaultAreaId = useUserContext().state.defaultAreaId;
|
|
@@ -21778,6 +21828,13 @@ var Logbook$2 = function () {
|
|
|
21778
21828
|
showShiftCrew: showShiftCrew,
|
|
21779
21829
|
}).columnDefs;
|
|
21780
21830
|
var defaultColDef = useGridDefinitions$1({}).defaultColDef;
|
|
21831
|
+
// Resizable panels layout persistence
|
|
21832
|
+
var _j = useDefaultLayout({
|
|
21833
|
+
id: "logbook-report-v2",
|
|
21834
|
+
storage: localStorage,
|
|
21835
|
+
}), savedLayout = _j.defaultLayout, onLayoutChange = _j.onLayoutChange;
|
|
21836
|
+
// Use saved layout or default to avoid flash on initial render
|
|
21837
|
+
var resolvedLayout = savedLayout !== null && savedLayout !== void 0 ? savedLayout : DEFAULT_LAYOUT$2;
|
|
21781
21838
|
var onQuickFilterChange = function (text) {
|
|
21782
21839
|
var _a;
|
|
21783
21840
|
setQuickFilter(text);
|
|
@@ -21898,17 +21955,26 @@ var Logbook$2 = function () {
|
|
|
21898
21955
|
}); })();
|
|
21899
21956
|
}
|
|
21900
21957
|
}, [shiftPeriod.StartShiftId, shiftPeriod.EndShiftId]);
|
|
21901
|
-
return (React__default.createElement(
|
|
21902
|
-
|
|
21903
|
-
|
|
21904
|
-
|
|
21905
|
-
|
|
21906
|
-
|
|
21907
|
-
|
|
21908
|
-
|
|
21909
|
-
|
|
21910
|
-
|
|
21911
|
-
|
|
21958
|
+
return (React__default.createElement(Box, { sx: {
|
|
21959
|
+
width: "100%",
|
|
21960
|
+
height: "calc(100vh - 130px)",
|
|
21961
|
+
display: "flex",
|
|
21962
|
+
flexDirection: "column",
|
|
21963
|
+
} },
|
|
21964
|
+
React__default.createElement(Box, { sx: { mb: 2 } },
|
|
21965
|
+
React__default.createElement(Typography$1, { variant: "h5", style: {
|
|
21966
|
+
fontWeight: 600,
|
|
21967
|
+
userSelect: "none",
|
|
21968
|
+
} }, "LOGBOOK REPORT")),
|
|
21969
|
+
React__default.createElement(Group$1, { id: "logbook-report-group", orientation: "horizontal", defaultLayout: resolvedLayout, onLayoutChange: onLayoutChange, style: { flex: 1, width: "100%" } },
|
|
21970
|
+
React__default.createElement(Panel, { id: "left", defaultSize: 42, minSize: 25, style: { paddingBottom: 5 } },
|
|
21971
|
+
React__default.createElement(Box, { sx: {
|
|
21972
|
+
display: "flex",
|
|
21973
|
+
flexDirection: "column",
|
|
21974
|
+
gap: 1,
|
|
21975
|
+
height: "100%",
|
|
21976
|
+
pr: 1,
|
|
21977
|
+
} },
|
|
21912
21978
|
React__default.createElement(Filters$2, { withAssetFilter: withAssetFilter, filterAssets: filterAssets, quickFilter: quickFilter, onQuickFilterChange: onQuickFilterChange, assetId: assetId, setAssetId: function (value) { return setAssetId(value); }, shiftPeriod: shiftPeriod, onChangeShiftPeriod: function (value, period) {
|
|
21913
21979
|
setShiftPeriod(value);
|
|
21914
21980
|
updateUrl({
|
|
@@ -21917,10 +21983,9 @@ var Logbook$2 = function () {
|
|
|
21917
21983
|
period: period,
|
|
21918
21984
|
entryId: searchParams.get("entryId"),
|
|
21919
21985
|
});
|
|
21920
|
-
}, actualPeriod: searchParams.get("period") })
|
|
21921
|
-
React__default.createElement(Grid2, { size: { xs: 12 } },
|
|
21986
|
+
}, actualPeriod: searchParams.get("period") }),
|
|
21922
21987
|
React__default.createElement(Paper, { elevation: 1, style: {
|
|
21923
|
-
|
|
21988
|
+
flex: 1,
|
|
21924
21989
|
width: "100%",
|
|
21925
21990
|
} },
|
|
21926
21991
|
React__default.createElement(AgGridReact, { loading: isLoading, rowData: rows, columnDefs: columnDefs, defaultColDef: defaultColDef, rowHeight: 38, headerHeight: 42, loadingOverlayComponent: CenteredLazyLoading, animateRows: true, onRowClicked: rowClicked, onCellKeyDown: onCellKeyDown, onGridReady: function (params) { return (gridApiRef.current = params.api); }, getRowId: function (params) { return "".concat(params.data.EntryId); }, gridOptions: {
|
|
@@ -21946,14 +22011,45 @@ var Logbook$2 = function () {
|
|
|
21946
22011
|
],
|
|
21947
22012
|
},
|
|
21948
22013
|
} })))),
|
|
21949
|
-
React__default.createElement(
|
|
21950
|
-
|
|
21951
|
-
|
|
21952
|
-
|
|
21953
|
-
|
|
21954
|
-
|
|
21955
|
-
|
|
21956
|
-
|
|
22014
|
+
React__default.createElement(Separator, { style: {
|
|
22015
|
+
display: "flex",
|
|
22016
|
+
alignItems: "center",
|
|
22017
|
+
justifyContent: "center",
|
|
22018
|
+
cursor: "col-resize",
|
|
22019
|
+
} },
|
|
22020
|
+
React__default.createElement(Box, { sx: {
|
|
22021
|
+
width: 8,
|
|
22022
|
+
height: 48,
|
|
22023
|
+
borderRadius: 1,
|
|
22024
|
+
backgroundColor: "#e0e0e0",
|
|
22025
|
+
display: "flex",
|
|
22026
|
+
flexDirection: "column",
|
|
22027
|
+
alignItems: "center",
|
|
22028
|
+
justifyContent: "center",
|
|
22029
|
+
gap: "3px",
|
|
22030
|
+
transition: "background-color 0.2s",
|
|
22031
|
+
"&:hover": {
|
|
22032
|
+
backgroundColor: "primary.main",
|
|
22033
|
+
"& .grip-dot": {
|
|
22034
|
+
backgroundColor: "#fff",
|
|
22035
|
+
},
|
|
22036
|
+
},
|
|
22037
|
+
} }, __spreadArray([], Array(5), true).map(function (_, i) { return (React__default.createElement(Box, { key: i, className: "grip-dot", sx: {
|
|
22038
|
+
width: 4,
|
|
22039
|
+
height: 4,
|
|
22040
|
+
borderRadius: "50%",
|
|
22041
|
+
backgroundColor: "#9e9e9e",
|
|
22042
|
+
transition: "background-color 0.2s",
|
|
22043
|
+
} })); }))),
|
|
22044
|
+
React__default.createElement(Panel, { id: "right", defaultSize: 58, minSize: 30, style: { paddingBottom: 5 } },
|
|
22045
|
+
React__default.createElement(Box, { sx: { pl: 1, height: "100%" } },
|
|
22046
|
+
React__default.createElement(EntryViewer$2, { entry: selectedRowData, show: show, onChangeShow: function () { return setShow(show === "view" ? "edit" : "view"); }, onHide: function () {
|
|
22047
|
+
var _a;
|
|
22048
|
+
setShow("");
|
|
22049
|
+
setSelectedRowData(null);
|
|
22050
|
+
(_a = gridApiRef.current) === null || _a === void 0 ? void 0 : _a.deselectAll();
|
|
22051
|
+
updateUrl({ entryId: null });
|
|
22052
|
+
}, filterAssets: filterAssets, showAsset: showAsset, showAttachments: showAttachments })))),
|
|
21957
22053
|
React__default.createElement(ErrorModal, { error: error, onHide: function () { return setError(""); } })));
|
|
21958
22054
|
};
|
|
21959
22055
|
|
|
@@ -23670,6 +23766,8 @@ var Filters$1 = function (_a) {
|
|
|
23670
23766
|
};
|
|
23671
23767
|
|
|
23672
23768
|
var moment$3 = getMomentTz();
|
|
23769
|
+
// Default layout matching original Grid md:5 / md:7 ratio (41.67% / 58.33%)
|
|
23770
|
+
var DEFAULT_LAYOUT$1 = { left: 42, right: 58 };
|
|
23673
23771
|
var Logbook$1 = function () {
|
|
23674
23772
|
var entry = useLogbookSettings().entry;
|
|
23675
23773
|
var allowAttachments = entry.allowAttachments;
|
|
@@ -23698,10 +23796,17 @@ var Logbook$1 = function () {
|
|
|
23698
23796
|
var _f = useState(null), selectedRowData = _f[0], setSelectedRowData = _f[1];
|
|
23699
23797
|
var _g = useState(false), showRemoveDialog = _g[0], setShowRemoveDialog = _g[1];
|
|
23700
23798
|
var _h = useContextMenuMESF(), registerConfig = _h.registerConfig, showContextMenu = _h.showContextMenu;
|
|
23701
|
-
|
|
23799
|
+
// Resizable panels layout persistence
|
|
23800
|
+
var _j = useDefaultLayout({
|
|
23801
|
+
id: "section-logbook-entry-v2",
|
|
23802
|
+
storage: localStorage,
|
|
23803
|
+
}), savedLayout = _j.defaultLayout, onLayoutChange = _j.onLayoutChange;
|
|
23804
|
+
// Use saved layout or default to avoid flash on initial render
|
|
23805
|
+
var resolvedLayout = savedLayout !== null && savedLayout !== void 0 ? savedLayout : DEFAULT_LAYOUT$1;
|
|
23806
|
+
var _k = useEntries({
|
|
23702
23807
|
shiftId: shiftInfo === null || shiftInfo === void 0 ? void 0 : shiftInfo.CurrentShiftId,
|
|
23703
23808
|
sectionIds: filterSections.map(function (s) { return s.SectionId; }),
|
|
23704
|
-
}), rows =
|
|
23809
|
+
}), rows = _k.data, isLoading = _k.isLoading, e = _k.error, isError = _k.isError, refetch = _k.refetch;
|
|
23705
23810
|
var columnDefs = useTableData$1({
|
|
23706
23811
|
showContextMenu: showContextMenu,
|
|
23707
23812
|
allowAttachments: allowAttachments,
|
|
@@ -23888,21 +23993,29 @@ var Logbook$1 = function () {
|
|
|
23888
23993
|
}); })();
|
|
23889
23994
|
}
|
|
23890
23995
|
}, []);
|
|
23891
|
-
return (React__default.createElement(
|
|
23892
|
-
|
|
23893
|
-
|
|
23894
|
-
|
|
23895
|
-
|
|
23896
|
-
|
|
23897
|
-
|
|
23898
|
-
|
|
23899
|
-
|
|
23900
|
-
|
|
23901
|
-
|
|
23902
|
-
|
|
23903
|
-
|
|
23996
|
+
return (React__default.createElement(Box, { sx: {
|
|
23997
|
+
width: "100%",
|
|
23998
|
+
height: "calc(100vh - 130px)",
|
|
23999
|
+
display: "flex",
|
|
24000
|
+
flexDirection: "column",
|
|
24001
|
+
} },
|
|
24002
|
+
React__default.createElement(Box, { sx: { mb: 2 } },
|
|
24003
|
+
React__default.createElement(Typography$1, { variant: "h5", style: {
|
|
24004
|
+
fontWeight: 600,
|
|
24005
|
+
userSelect: "none",
|
|
24006
|
+
} }, "LOGBOOK")),
|
|
24007
|
+
React__default.createElement(Group$1, { id: "section-logbook-entry-group", orientation: "horizontal", defaultLayout: resolvedLayout, onLayoutChange: onLayoutChange, style: { flex: 1, width: "100%" } },
|
|
24008
|
+
React__default.createElement(Panel, { id: "left", defaultSize: 42, minSize: 25, style: { paddingBottom: 5 } },
|
|
24009
|
+
React__default.createElement(Box, { sx: {
|
|
24010
|
+
display: "flex",
|
|
24011
|
+
flexDirection: "column",
|
|
24012
|
+
gap: 1,
|
|
24013
|
+
height: "100%",
|
|
24014
|
+
pr: 1,
|
|
24015
|
+
} },
|
|
24016
|
+
React__default.createElement(Filters$1, { quickFilter: quickFilter, onQuickFilterChange: onQuickFilterChange, selectedSections: filterSections, onSectionsChange: setFilterSections }),
|
|
23904
24017
|
React__default.createElement(Paper, { elevation: 1, style: {
|
|
23905
|
-
|
|
24018
|
+
flex: 1,
|
|
23906
24019
|
width: "100%",
|
|
23907
24020
|
} },
|
|
23908
24021
|
React__default.createElement(AgGridReact, { loading: isLoading, rowData: rows, columnDefs: columnDefs, defaultColDef: defaultColDef, rowHeight: 38, headerHeight: 42, loadingOverlayComponent: CenteredLazyLoading, animateRows: true, getContextMenuItems: getContextMenuItems, onRowClicked: rowClicked, onCellKeyDown: onCellKeyDown, onGridReady: function (params) { return (gridApiRef.current = params.api); }, getRowId: function (params) { return "".concat(params.data.EntryId); }, gridOptions: {
|
|
@@ -23931,80 +24044,111 @@ var Logbook$1 = function () {
|
|
|
23931
24044
|
],
|
|
23932
24045
|
},
|
|
23933
24046
|
} })))),
|
|
23934
|
-
React__default.createElement(
|
|
23935
|
-
|
|
23936
|
-
|
|
23937
|
-
|
|
23938
|
-
|
|
23939
|
-
|
|
23940
|
-
|
|
23941
|
-
|
|
23942
|
-
|
|
23943
|
-
|
|
23944
|
-
|
|
23945
|
-
|
|
23946
|
-
|
|
23947
|
-
|
|
23948
|
-
|
|
23949
|
-
|
|
23950
|
-
|
|
23951
|
-
|
|
23952
|
-
|
|
23953
|
-
|
|
23954
|
-
|
|
23955
|
-
|
|
23956
|
-
|
|
23957
|
-
|
|
23958
|
-
|
|
23959
|
-
|
|
23960
|
-
|
|
23961
|
-
|
|
23962
|
-
|
|
23963
|
-
|
|
23964
|
-
|
|
23965
|
-
|
|
23966
|
-
|
|
23967
|
-
|
|
23968
|
-
|
|
23969
|
-
|
|
23970
|
-
|
|
23971
|
-
|
|
23972
|
-
|
|
23973
|
-
|
|
23974
|
-
var _a, _b, _c;
|
|
23975
|
-
return __generator(this, function (_d) {
|
|
23976
|
-
switch (_d.label) {
|
|
23977
|
-
case 0: return [4 /*yield*/, refetch()];
|
|
23978
|
-
case 1:
|
|
23979
|
-
_d.sent();
|
|
23980
|
-
retryRowNode = (_a = gridApiRef.current) === null || _a === void 0 ? void 0 : _a.getRowNode(entryId.toString());
|
|
23981
|
-
if (retryRowNode) {
|
|
23982
|
-
(_b = gridApiRef.current) === null || _b === void 0 ? void 0 : _b.ensureNodeVisible(retryRowNode);
|
|
23983
|
-
retryRowNode.setSelected(true);
|
|
23984
|
-
setSelectedRowData(retryRowNode.data);
|
|
23985
|
-
}
|
|
23986
|
-
else {
|
|
23987
|
-
setShow("");
|
|
23988
|
-
setSelectedRowData(null);
|
|
23989
|
-
(_c = gridApiRef.current) === null || _c === void 0 ? void 0 : _c.deselectAll();
|
|
23990
|
-
}
|
|
23991
|
-
return [2 /*return*/];
|
|
23992
|
-
}
|
|
23993
|
-
});
|
|
23994
|
-
}); }, 500);
|
|
23995
|
-
}
|
|
23996
|
-
}, 200);
|
|
23997
|
-
return [3 /*break*/, 3];
|
|
23998
|
-
case 2:
|
|
23999
|
-
setShow("");
|
|
24000
|
-
setSelectedRowData(null);
|
|
24001
|
-
(_a = gridApiRef.current) === null || _a === void 0 ? void 0 : _a.deselectAll();
|
|
24002
|
-
navigate("".concat(routeLogbookEntry, "/").concat(shiftId || (shiftInfo === null || shiftInfo === void 0 ? void 0 : shiftInfo.CurrentShiftId)));
|
|
24003
|
-
_b.label = 3;
|
|
24004
|
-
case 3: return [2 /*return*/];
|
|
24047
|
+
React__default.createElement(Separator, { style: {
|
|
24048
|
+
display: "flex",
|
|
24049
|
+
alignItems: "center",
|
|
24050
|
+
justifyContent: "center",
|
|
24051
|
+
cursor: "col-resize",
|
|
24052
|
+
} },
|
|
24053
|
+
React__default.createElement(Box, { sx: {
|
|
24054
|
+
width: 8,
|
|
24055
|
+
height: 48,
|
|
24056
|
+
borderRadius: 1,
|
|
24057
|
+
backgroundColor: "#e0e0e0",
|
|
24058
|
+
display: "flex",
|
|
24059
|
+
flexDirection: "column",
|
|
24060
|
+
alignItems: "center",
|
|
24061
|
+
justifyContent: "center",
|
|
24062
|
+
gap: "3px",
|
|
24063
|
+
transition: "background-color 0.2s",
|
|
24064
|
+
"&:hover": {
|
|
24065
|
+
backgroundColor: "primary.main",
|
|
24066
|
+
"& .grip-dot": {
|
|
24067
|
+
backgroundColor: "#fff",
|
|
24068
|
+
},
|
|
24069
|
+
},
|
|
24070
|
+
} }, __spreadArray([], Array(5), true).map(function (_, i) { return (React__default.createElement(Box, { key: i, className: "grip-dot", sx: {
|
|
24071
|
+
width: 4,
|
|
24072
|
+
height: 4,
|
|
24073
|
+
borderRadius: "50%",
|
|
24074
|
+
backgroundColor: "#9e9e9e",
|
|
24075
|
+
transition: "background-color 0.2s",
|
|
24076
|
+
} })); }))),
|
|
24077
|
+
React__default.createElement(Panel, { id: "right", defaultSize: 58, minSize: 30, style: { paddingBottom: 5 } },
|
|
24078
|
+
React__default.createElement(Box, { sx: { pl: 1, height: "100%" } },
|
|
24079
|
+
React__default.createElement(EntryViewer$1, { entry: selectedRowData, show: show, onChangeShow: function () {
|
|
24080
|
+
var newShow = show === "view" ? "edit" : "view";
|
|
24081
|
+
setShow(newShow);
|
|
24082
|
+
if (entryId && entryId !== "new") {
|
|
24083
|
+
var targetUrl = newShow === "edit"
|
|
24084
|
+
? "/logbook/entry/".concat(shiftId || (shiftInfo === null || shiftInfo === void 0 ? void 0 : shiftInfo.CurrentShiftId), "?entryId=").concat(entryId, "&action=edit")
|
|
24085
|
+
: "/logbook/entry/".concat(shiftId || (shiftInfo === null || shiftInfo === void 0 ? void 0 : shiftInfo.CurrentShiftId), "?entryId=").concat(entryId, "&action=view");
|
|
24086
|
+
navigate(targetUrl);
|
|
24005
24087
|
}
|
|
24006
|
-
})
|
|
24007
|
-
|
|
24088
|
+
}, canEditShift: canEditShift, allowAttachments: allowAttachments, shiftsRange: shiftsRange, withAssetFilter: withAssetFilter, canEditAsset: canEditAsset, filterAssets: filterAssets, onHide: function (entryId, shouldStayInEditMode) { return __awaiter(void 0, void 0, void 0, function () {
|
|
24089
|
+
var targetUrl;
|
|
24090
|
+
var _a;
|
|
24091
|
+
return __generator(this, function (_b) {
|
|
24092
|
+
switch (_b.label) {
|
|
24093
|
+
case 0:
|
|
24094
|
+
if (!entryId) return [3 /*break*/, 2];
|
|
24095
|
+
// First refetch to ensure we have the latest data
|
|
24096
|
+
return [4 /*yield*/, refetch()];
|
|
24097
|
+
case 1:
|
|
24098
|
+
// First refetch to ensure we have the latest data
|
|
24099
|
+
_b.sent();
|
|
24100
|
+
targetUrl = shouldStayInEditMode
|
|
24101
|
+
? "/logbook/entry/".concat(shiftId || (shiftInfo === null || shiftInfo === void 0 ? void 0 : shiftInfo.CurrentShiftId), "?entryId=").concat(entryId, "&action=edit")
|
|
24102
|
+
: "/logbook/entry/".concat(shiftId || (shiftInfo === null || shiftInfo === void 0 ? void 0 : shiftInfo.CurrentShiftId), "?entryId=").concat(entryId, "&action=view");
|
|
24103
|
+
navigate(targetUrl);
|
|
24104
|
+
setShow(shouldStayInEditMode ? "edit" : "view");
|
|
24105
|
+
// Additional delay to allow navigation and state updates to complete
|
|
24106
|
+
setTimeout(function () {
|
|
24107
|
+
var _a, _b;
|
|
24108
|
+
var rowNode = (_a = gridApiRef.current) === null || _a === void 0 ? void 0 : _a.getRowNode(entryId.toString());
|
|
24109
|
+
if (rowNode) {
|
|
24110
|
+
(_b = gridApiRef.current) === null || _b === void 0 ? void 0 : _b.ensureNodeVisible(rowNode);
|
|
24111
|
+
rowNode.setSelected(true);
|
|
24112
|
+
setSelectedRowData(rowNode.data);
|
|
24113
|
+
}
|
|
24114
|
+
else {
|
|
24115
|
+
// If still not found, try one more refetch
|
|
24116
|
+
setTimeout(function () { return __awaiter(void 0, void 0, void 0, function () {
|
|
24117
|
+
var retryRowNode;
|
|
24118
|
+
var _a, _b, _c;
|
|
24119
|
+
return __generator(this, function (_d) {
|
|
24120
|
+
switch (_d.label) {
|
|
24121
|
+
case 0: return [4 /*yield*/, refetch()];
|
|
24122
|
+
case 1:
|
|
24123
|
+
_d.sent();
|
|
24124
|
+
retryRowNode = (_a = gridApiRef.current) === null || _a === void 0 ? void 0 : _a.getRowNode(entryId.toString());
|
|
24125
|
+
if (retryRowNode) {
|
|
24126
|
+
(_b = gridApiRef.current) === null || _b === void 0 ? void 0 : _b.ensureNodeVisible(retryRowNode);
|
|
24127
|
+
retryRowNode.setSelected(true);
|
|
24128
|
+
setSelectedRowData(retryRowNode.data);
|
|
24129
|
+
}
|
|
24130
|
+
else {
|
|
24131
|
+
setShow("");
|
|
24132
|
+
setSelectedRowData(null);
|
|
24133
|
+
(_c = gridApiRef.current) === null || _c === void 0 ? void 0 : _c.deselectAll();
|
|
24134
|
+
}
|
|
24135
|
+
return [2 /*return*/];
|
|
24136
|
+
}
|
|
24137
|
+
});
|
|
24138
|
+
}); }, 500);
|
|
24139
|
+
}
|
|
24140
|
+
}, 200);
|
|
24141
|
+
return [3 /*break*/, 3];
|
|
24142
|
+
case 2:
|
|
24143
|
+
setShow("");
|
|
24144
|
+
setSelectedRowData(null);
|
|
24145
|
+
(_a = gridApiRef.current) === null || _a === void 0 ? void 0 : _a.deselectAll();
|
|
24146
|
+
navigate("".concat(routeLogbookEntry, "/").concat(shiftId || (shiftInfo === null || shiftInfo === void 0 ? void 0 : shiftInfo.CurrentShiftId)));
|
|
24147
|
+
_b.label = 3;
|
|
24148
|
+
case 3: return [2 /*return*/];
|
|
24149
|
+
}
|
|
24150
|
+
});
|
|
24151
|
+
}); } })))),
|
|
24008
24152
|
React__default.createElement(RemoveEntryDialog, { entry: selectedRowData, show: showRemoveDialog, onHide: function (shouldUpdate) {
|
|
24009
24153
|
if (shouldUpdate) {
|
|
24010
24154
|
refetch();
|
|
@@ -24300,6 +24444,8 @@ var Filters = function (_a) {
|
|
|
24300
24444
|
};
|
|
24301
24445
|
|
|
24302
24446
|
var moment = getMomentTz();
|
|
24447
|
+
// Default layout matching original Grid md:5 / md:7 ratio (41.67% / 58.33%)
|
|
24448
|
+
var DEFAULT_LAYOUT = { left: 42, right: 58 };
|
|
24303
24449
|
var Logbook = function () {
|
|
24304
24450
|
var report = useLogbookSettings().report;
|
|
24305
24451
|
var showAttachments = report.showAttachments;
|
|
@@ -24364,6 +24510,13 @@ var Logbook = function () {
|
|
|
24364
24510
|
showShiftCrew: showShiftCrew,
|
|
24365
24511
|
}).columnDefs;
|
|
24366
24512
|
var defaultColDef = useGridDefinitions({}).defaultColDef;
|
|
24513
|
+
// Resizable panels layout persistence
|
|
24514
|
+
var _j = useDefaultLayout({
|
|
24515
|
+
id: "section-logbook-report-v2",
|
|
24516
|
+
storage: localStorage,
|
|
24517
|
+
}), savedLayout = _j.defaultLayout, onLayoutChange = _j.onLayoutChange;
|
|
24518
|
+
// Use saved layout or default to avoid flash on initial render
|
|
24519
|
+
var resolvedLayout = savedLayout !== null && savedLayout !== void 0 ? savedLayout : DEFAULT_LAYOUT;
|
|
24367
24520
|
var onQuickFilterChange = function (text) {
|
|
24368
24521
|
var _a;
|
|
24369
24522
|
setQuickFilter(text);
|
|
@@ -24477,17 +24630,26 @@ var Logbook = function () {
|
|
|
24477
24630
|
}); })();
|
|
24478
24631
|
}
|
|
24479
24632
|
}, [shiftPeriod.StartShiftId, shiftPeriod.EndShiftId]);
|
|
24480
|
-
return (React__default.createElement(
|
|
24481
|
-
|
|
24482
|
-
|
|
24483
|
-
|
|
24484
|
-
|
|
24485
|
-
|
|
24486
|
-
|
|
24487
|
-
|
|
24488
|
-
|
|
24489
|
-
|
|
24490
|
-
|
|
24633
|
+
return (React__default.createElement(Box, { sx: {
|
|
24634
|
+
width: "100%",
|
|
24635
|
+
height: "calc(100vh - 130px)",
|
|
24636
|
+
display: "flex",
|
|
24637
|
+
flexDirection: "column",
|
|
24638
|
+
} },
|
|
24639
|
+
React__default.createElement(Box, { sx: { mb: 2 } },
|
|
24640
|
+
React__default.createElement(Typography$1, { variant: "h5", style: {
|
|
24641
|
+
fontWeight: 600,
|
|
24642
|
+
userSelect: "none",
|
|
24643
|
+
} }, "LOGBOOK REPORT")),
|
|
24644
|
+
React__default.createElement(Group$1, { id: "section-logbook-report-group", orientation: "horizontal", defaultLayout: resolvedLayout, onLayoutChange: onLayoutChange, style: { flex: 1, width: "100%" } },
|
|
24645
|
+
React__default.createElement(Panel, { id: "left", defaultSize: 42, minSize: 25, style: { paddingBottom: 5 } },
|
|
24646
|
+
React__default.createElement(Box, { sx: {
|
|
24647
|
+
display: "flex",
|
|
24648
|
+
flexDirection: "column",
|
|
24649
|
+
gap: 1,
|
|
24650
|
+
height: "100%",
|
|
24651
|
+
pr: 1,
|
|
24652
|
+
} },
|
|
24491
24653
|
React__default.createElement(Filters, { quickFilter: quickFilter, onQuickFilterChange: onQuickFilterChange, shiftPeriod: shiftPeriod, onChangeShiftPeriod: function (value, period) {
|
|
24492
24654
|
setShiftPeriod(value);
|
|
24493
24655
|
updateUrl({
|
|
@@ -24496,10 +24658,9 @@ var Logbook = function () {
|
|
|
24496
24658
|
period: period,
|
|
24497
24659
|
entryId: searchParams.get("entryId"),
|
|
24498
24660
|
});
|
|
24499
|
-
}, actualPeriod: searchParams.get("period"), selectedSections: filterSections, onSectionsChange: setFilterSections })
|
|
24500
|
-
React__default.createElement(Grid2, { size: { xs: 12 } },
|
|
24661
|
+
}, actualPeriod: searchParams.get("period"), selectedSections: filterSections, onSectionsChange: setFilterSections }),
|
|
24501
24662
|
React__default.createElement(Paper, { elevation: 1, style: {
|
|
24502
|
-
|
|
24663
|
+
flex: 1,
|
|
24503
24664
|
width: "100%",
|
|
24504
24665
|
} },
|
|
24505
24666
|
React__default.createElement(AgGridReact, { loading: isLoading, rowData: rows, columnDefs: columnDefs, defaultColDef: defaultColDef, rowHeight: 38, headerHeight: 42, loadingOverlayComponent: CenteredLazyLoading, animateRows: true, onRowClicked: rowClicked, onCellKeyDown: onCellKeyDown, onGridReady: function (params) { return (gridApiRef.current = params.api); }, getRowId: function (params) { return "".concat(params.data.EntryId); }, gridOptions: {
|
|
@@ -24525,14 +24686,45 @@ var Logbook = function () {
|
|
|
24525
24686
|
],
|
|
24526
24687
|
},
|
|
24527
24688
|
} })))),
|
|
24528
|
-
React__default.createElement(
|
|
24529
|
-
|
|
24530
|
-
|
|
24531
|
-
|
|
24532
|
-
|
|
24533
|
-
|
|
24534
|
-
|
|
24535
|
-
|
|
24689
|
+
React__default.createElement(Separator, { style: {
|
|
24690
|
+
display: "flex",
|
|
24691
|
+
alignItems: "center",
|
|
24692
|
+
justifyContent: "center",
|
|
24693
|
+
cursor: "col-resize",
|
|
24694
|
+
} },
|
|
24695
|
+
React__default.createElement(Box, { sx: {
|
|
24696
|
+
width: 8,
|
|
24697
|
+
height: 48,
|
|
24698
|
+
borderRadius: 1,
|
|
24699
|
+
backgroundColor: "#e0e0e0",
|
|
24700
|
+
display: "flex",
|
|
24701
|
+
flexDirection: "column",
|
|
24702
|
+
alignItems: "center",
|
|
24703
|
+
justifyContent: "center",
|
|
24704
|
+
gap: "3px",
|
|
24705
|
+
transition: "background-color 0.2s",
|
|
24706
|
+
"&:hover": {
|
|
24707
|
+
backgroundColor: "primary.main",
|
|
24708
|
+
"& .grip-dot": {
|
|
24709
|
+
backgroundColor: "#fff",
|
|
24710
|
+
},
|
|
24711
|
+
},
|
|
24712
|
+
} }, __spreadArray([], Array(5), true).map(function (_, i) { return (React__default.createElement(Box, { key: i, className: "grip-dot", sx: {
|
|
24713
|
+
width: 4,
|
|
24714
|
+
height: 4,
|
|
24715
|
+
borderRadius: "50%",
|
|
24716
|
+
backgroundColor: "#9e9e9e",
|
|
24717
|
+
transition: "background-color 0.2s",
|
|
24718
|
+
} })); }))),
|
|
24719
|
+
React__default.createElement(Panel, { id: "right", defaultSize: 58, minSize: 30, style: { paddingBottom: 5 } },
|
|
24720
|
+
React__default.createElement(Box, { sx: { pl: 1, height: "100%" } },
|
|
24721
|
+
React__default.createElement(EntryViewer, { entry: selectedRowData, show: show, onChangeShow: function () { return setShow(show === "view" ? "edit" : "view"); }, onHide: function () {
|
|
24722
|
+
var _a;
|
|
24723
|
+
setShow("");
|
|
24724
|
+
setSelectedRowData(null);
|
|
24725
|
+
(_a = gridApiRef.current) === null || _a === void 0 ? void 0 : _a.deselectAll();
|
|
24726
|
+
updateUrl({ entryId: null });
|
|
24727
|
+
}, showAsset: showAsset, showAttachments: showAttachments, showSection: true })))),
|
|
24536
24728
|
React__default.createElement(ErrorModal, { error: error, onHide: function () { return setError(""); } })));
|
|
24537
24729
|
};
|
|
24538
24730
|
|