From b5611c8470f9bc66a67468e8fa725dc6e2400a51 Mon Sep 17 00:00:00 2001 From: Dave Richer Date: Mon, 24 Mar 2025 14:16:25 -0400 Subject: [PATCH] IO-3183-Dependency-Updates-and-maintenance - Cleaning dashboard-grid.component.jsx --- .../components/dashboard-grid/dashboard-grid.component.jsx | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/client/src/components/dashboard-grid/dashboard-grid.component.jsx b/client/src/components/dashboard-grid/dashboard-grid.component.jsx index 70800158a..082e404ac 100644 --- a/client/src/components/dashboard-grid/dashboard-grid.component.jsx +++ b/client/src/components/dashboard-grid/dashboard-grid.component.jsx @@ -59,6 +59,7 @@ export function DashboardGridComponent({ currentUser, bodyshop }) { layout: { ...state, layout, layouts } } }); + if (!isEmpty(result?.errors)) { notification.error({ message: t("dashboard.errors.updatinglayout", { @@ -67,6 +68,7 @@ export function DashboardGridComponent({ currentUser, bodyshop }) { }); } }; + const handleRemoveComponent = (key) => { logImEXEvent("dashboard_remove_component", { name: key }); const idxToRemove = state.items.findIndex((i) => i.i === key); @@ -95,6 +97,7 @@ export function DashboardGridComponent({ currentUser, bodyshop }) { }; const dashboardData = useMemo(() => GenerateDashboardData(data), [data]); + const existingLayoutKeys = state.items.map((i) => i.i); const menuItems = Object.keys(componentList).map((key) => ({ @@ -130,7 +133,6 @@ export function DashboardGridComponent({ currentUser, bodyshop }) { width="100%" layouts={state.layouts} onLayoutChange={handleLayoutChange} - // onBreakpointChange={onBreakpointChange} > {state.items.map((item, index) => { const TheComponent = componentList[item.i].component;