@optifye/dashboard-core 6.9.4 → 6.9.6

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.d.mts CHANGED
@@ -6245,6 +6245,7 @@ interface WorkspaceGridProps {
6245
6245
  workspaceHlsUrls?: Record<string, string>;
6246
6246
  mp4VideoMapping?: Record<string, string>;
6247
6247
  };
6248
+ displayNames?: Record<string, string>;
6248
6249
  onWorkspaceHover?: (workspaceId: string) => void;
6249
6250
  onWorkspaceHoverEnd?: (workspaceId: string) => void;
6250
6251
  }
@@ -6302,6 +6303,7 @@ interface VideoGridViewProps {
6302
6303
  defaultHlsUrl?: string;
6303
6304
  workspaceHlsUrls?: Record<string, string>;
6304
6305
  };
6306
+ displayNames?: Record<string, string>;
6305
6307
  onWorkspaceHover?: (workspaceId: string) => void;
6306
6308
  onWorkspaceHoverEnd?: (workspaceId: string) => void;
6307
6309
  }
@@ -6313,6 +6315,7 @@ declare const VideoGridView: React__default.FC<VideoGridViewProps>;
6313
6315
  interface MapGridViewProps {
6314
6316
  workspaces: WorkspaceMetrics[];
6315
6317
  className?: string;
6318
+ displayNames?: Record<string, string>;
6316
6319
  onWorkspaceHover?: (workspaceId: string) => void;
6317
6320
  onWorkspaceHoverEnd?: (workspaceId: string) => void;
6318
6321
  }
@@ -6334,6 +6337,7 @@ interface VideoCardProps {
6334
6337
  useRAF?: boolean;
6335
6338
  className?: string;
6336
6339
  compact?: boolean;
6340
+ displayName?: string;
6337
6341
  onMouseEnter?: () => void;
6338
6342
  onMouseLeave?: () => void;
6339
6343
  }
package/dist/index.d.ts CHANGED
@@ -6245,6 +6245,7 @@ interface WorkspaceGridProps {
6245
6245
  workspaceHlsUrls?: Record<string, string>;
6246
6246
  mp4VideoMapping?: Record<string, string>;
6247
6247
  };
6248
+ displayNames?: Record<string, string>;
6248
6249
  onWorkspaceHover?: (workspaceId: string) => void;
6249
6250
  onWorkspaceHoverEnd?: (workspaceId: string) => void;
6250
6251
  }
@@ -6302,6 +6303,7 @@ interface VideoGridViewProps {
6302
6303
  defaultHlsUrl?: string;
6303
6304
  workspaceHlsUrls?: Record<string, string>;
6304
6305
  };
6306
+ displayNames?: Record<string, string>;
6305
6307
  onWorkspaceHover?: (workspaceId: string) => void;
6306
6308
  onWorkspaceHoverEnd?: (workspaceId: string) => void;
6307
6309
  }
@@ -6313,6 +6315,7 @@ declare const VideoGridView: React__default.FC<VideoGridViewProps>;
6313
6315
  interface MapGridViewProps {
6314
6316
  workspaces: WorkspaceMetrics[];
6315
6317
  className?: string;
6318
+ displayNames?: Record<string, string>;
6316
6319
  onWorkspaceHover?: (workspaceId: string) => void;
6317
6320
  onWorkspaceHoverEnd?: (workspaceId: string) => void;
6318
6321
  }
@@ -6334,6 +6337,7 @@ interface VideoCardProps {
6334
6337
  useRAF?: boolean;
6335
6338
  className?: string;
6336
6339
  compact?: boolean;
6340
+ displayName?: string;
6337
6341
  onMouseEnter?: () => void;
6338
6342
  onMouseLeave?: () => void;
6339
6343
  }
package/dist/index.js CHANGED
@@ -9603,8 +9603,13 @@ var getAllWorkspaceDisplayNamesAsync = async (companyId, lineId) => {
9603
9603
  return { ...runtimeWorkspaceDisplayNames[lineId] };
9604
9604
  }
9605
9605
  const allNames = {};
9606
- Object.values(runtimeWorkspaceDisplayNames).forEach((lineNames) => {
9607
- Object.assign(allNames, lineNames);
9606
+ Object.entries(runtimeWorkspaceDisplayNames).forEach(([lineId2, lineNames]) => {
9607
+ Object.entries(lineNames).forEach(([workspaceId, displayName]) => {
9608
+ allNames[`${lineId2}_${workspaceId}`] = displayName;
9609
+ if (!allNames[workspaceId]) {
9610
+ allNames[workspaceId] = displayName;
9611
+ }
9612
+ });
9608
9613
  });
9609
9614
  return allNames;
9610
9615
  };
@@ -24362,6 +24367,7 @@ var VideoCard = React23__namespace.default.memo(({
24362
24367
  useRAF = true,
24363
24368
  className = "",
24364
24369
  compact = false,
24370
+ displayName,
24365
24371
  onMouseEnter,
24366
24372
  onMouseLeave
24367
24373
  }) => {
@@ -24383,7 +24389,7 @@ var VideoCard = React23__namespace.default.memo(({
24383
24389
  onFatalError: onFatalError ?? (() => throttledReloadDashboard())
24384
24390
  });
24385
24391
  }
24386
- const displayName = getWorkspaceDisplayName(workspace.workspace_name, workspace.line_id);
24392
+ const workspaceDisplayName = displayName || getWorkspaceDisplayName(workspace.workspace_name, workspace.line_id);
24387
24393
  const getEfficiencyOverlayColor = (efficiency) => {
24388
24394
  if (efficiency >= 80) {
24389
24395
  return "bg-[#00D654]/25";
@@ -24476,7 +24482,7 @@ var VideoCard = React23__namespace.default.memo(({
24476
24482
  /* @__PURE__ */ jsxRuntime.jsxs("div", { className: `absolute bottom-0 left-0 right-0 bg-black bg-opacity-60 p-1.5 sm:${compact ? "p-1" : "p-1.5"} flex justify-between items-center z-10`, children: [
24477
24483
  /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-1.5", children: [
24478
24484
  /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Camera, { size: compact ? 10 : 12, className: "text-white" }),
24479
- /* @__PURE__ */ jsxRuntime.jsx("p", { className: `text-white text-[11px] sm:${compact ? "text-[10px]" : "text-xs"} font-medium tracking-wide`, children: displayName })
24485
+ /* @__PURE__ */ jsxRuntime.jsx("p", { className: `text-white text-[11px] sm:${compact ? "text-[10px]" : "text-xs"} font-medium tracking-wide`, children: workspaceDisplayName })
24480
24486
  ] }),
24481
24487
  /* @__PURE__ */ jsxRuntime.jsxs("div", { className: `flex items-center ${compact ? "gap-1" : "gap-1.5"}`, children: [
24482
24488
  trendInfo && /* @__PURE__ */ jsxRuntime.jsx(
@@ -24513,6 +24519,7 @@ var VideoGridView = React23__namespace.default.memo(({
24513
24519
  selectedLine,
24514
24520
  className = "",
24515
24521
  videoSources = {},
24522
+ displayNames = {},
24516
24523
  onWorkspaceHover,
24517
24524
  onWorkspaceHoverEnd
24518
24525
  }) => {
@@ -24727,6 +24734,11 @@ var VideoGridView = React23__namespace.default.memo(({
24727
24734
  isVeryLowEfficiency,
24728
24735
  cropping: workspaceCropping,
24729
24736
  canvasFps: canvasConfig?.fps,
24737
+ displayName: (
24738
+ // Create line-aware lookup key: lineId_workspaceName
24739
+ // This ensures correct mapping when multiple lines have same workspace names
24740
+ displayNames[`${workspace.line_id}_${workspace.workspace_name}`] || displayNames[workspace.workspace_name] || getWorkspaceDisplayName(workspace.workspace_name, workspace.line_id)
24741
+ ),
24730
24742
  useRAF: canvasConfig?.useRAF,
24731
24743
  compact: !selectedLine,
24732
24744
  onMouseEnter: onWorkspaceHover ? () => onWorkspaceHover(workspaceId) : void 0,
@@ -24744,6 +24756,7 @@ VideoGridView.displayName = "VideoGridView";
24744
24756
  var MapGridView = React23__namespace.default.memo(({
24745
24757
  workspaces,
24746
24758
  className = "",
24759
+ displayNames = {},
24747
24760
  onWorkspaceHover,
24748
24761
  onWorkspaceHoverEnd
24749
24762
  }) => {
@@ -24774,10 +24787,10 @@ var MapGridView = React23__namespace.default.memo(({
24774
24787
  efficiency: workspace.efficiency,
24775
24788
  action_count: workspace.action_count
24776
24789
  });
24777
- const displayName = getWorkspaceDisplayName(workspace.workspace_name, workspace.line_id);
24790
+ const displayName = displayNames[`${workspace.line_id}_${workspace.workspace_name}`] || displayNames[workspace.workspace_name] || getWorkspaceDisplayName(workspace.workspace_name, workspace.line_id);
24778
24791
  const navParams = getWorkspaceNavigationParams(workspaceId, displayName, workspace.line_id);
24779
24792
  router$1.push(`/workspace/${workspaceId}${navParams}`);
24780
- }, [router$1]);
24793
+ }, [router$1, displayNames]);
24781
24794
  const activePositions = React23.useMemo(() => {
24782
24795
  return workspacePositions.filter((pos) => {
24783
24796
  const wsKey = pos.id.toUpperCase();
@@ -24803,7 +24816,7 @@ var MapGridView = React23__namespace.default.memo(({
24803
24816
  if (!workspace) return null;
24804
24817
  const workspaceId = workspace.workspace_uuid || workspace.workspace_name;
24805
24818
  getPerformanceColor(workspace.efficiency);
24806
- const displayName = getWorkspaceDisplayName(workspace.workspace_name, workspace.line_id);
24819
+ const workspaceDisplayName = displayNames[`${workspace.line_id}_${workspace.workspace_name}`] || displayNames[workspace.workspace_name] || getWorkspaceDisplayName(workspace.workspace_name, workspace.line_id);
24807
24820
  return /* @__PURE__ */ jsxRuntime.jsx(
24808
24821
  motion.div,
24809
24822
  {
@@ -24829,7 +24842,7 @@ var MapGridView = React23__namespace.default.memo(({
24829
24842
  ${position.size === "conveyor" ? "w-32 h-24" : position.size === "large" ? "w-40 h-32" : "w-36 h-28"}
24830
24843
  `,
24831
24844
  children: [
24832
- /* @__PURE__ */ jsxRuntime.jsx("div", { className: "absolute top-0 left-0 right-0 px-2 py-1.5 border-b border-gray-200", children: /* @__PURE__ */ jsxRuntime.jsx("div", { className: "text-xs font-bold text-gray-800 truncate text-center leading-tight", children: displayName }) }),
24845
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: "absolute top-0 left-0 right-0 px-2 py-1.5 border-b border-gray-200", children: /* @__PURE__ */ jsxRuntime.jsx("div", { className: "text-xs font-bold text-gray-800 truncate text-center leading-tight", children: workspaceDisplayName }) }),
24833
24846
  /* @__PURE__ */ jsxRuntime.jsx("div", { className: "absolute bottom-0 left-0 right-0 px-2 py-2", children: /* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex flex-col items-center", children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "text-2xl font-bold text-gray-900", children: [
24834
24847
  Math.round(workspace.efficiency),
24835
24848
  "%"
@@ -34857,6 +34870,7 @@ var WorkspaceGrid = React23__namespace.default.memo(({
34857
34870
  line2Uuid = "line-2",
34858
34871
  className = "",
34859
34872
  videoSources = {},
34873
+ displayNames = {},
34860
34874
  onWorkspaceHover,
34861
34875
  onWorkspaceHoverEnd
34862
34876
  }) => {
@@ -34922,6 +34936,7 @@ var WorkspaceGrid = React23__namespace.default.memo(({
34922
34936
  {
34923
34937
  workspaces,
34924
34938
  videoSources,
34939
+ displayNames,
34925
34940
  onWorkspaceHover,
34926
34941
  onWorkspaceHoverEnd
34927
34942
  }
@@ -34940,6 +34955,7 @@ var WorkspaceGrid = React23__namespace.default.memo(({
34940
34955
  MapGridViewComponent,
34941
34956
  {
34942
34957
  workspaces,
34958
+ displayNames,
34943
34959
  onWorkspaceHover,
34944
34960
  onWorkspaceHoverEnd
34945
34961
  }
@@ -41530,11 +41546,12 @@ function HomeView({
41530
41546
  };
41531
41547
  initDisplayNames();
41532
41548
  }, [selectedLineId, factoryViewId, allLineIds]);
41549
+ const displayNameLineId = selectedLineId === factoryViewId ? void 0 : selectedLineId;
41533
41550
  const {
41534
41551
  displayNames: workspaceDisplayNames,
41535
41552
  loading: displayNamesLoading,
41536
41553
  error: displayNamesError
41537
- } = useWorkspaceDisplayNames(void 0, selectedLineId);
41554
+ } = useWorkspaceDisplayNames(displayNameLineId, void 0);
41538
41555
  React23.useCallback(() => {
41539
41556
  console.log("Refetching KPIs after line metrics update");
41540
41557
  }, []);
@@ -41898,7 +41915,7 @@ function HomeView({
41898
41915
  /* @__PURE__ */ jsxRuntime.jsx(SelectContent, { className: "z-50 bg-white shadow-lg border border-gray-200 rounded-md text-xs sm:text-sm", children: availableLineIds.map((id3) => /* @__PURE__ */ jsxRuntime.jsx(SelectItem, { value: id3, children: lineNames[id3] || (id3 === factoryViewId ? "All Lines" : `Line ${id3.substring(0, 4)}`) }, id3)) })
41899
41916
  ] });
41900
41917
  }, [availableLineIds, handleLineChange, selectedLineId, lineNames, factoryViewId, allLineIds.length]);
41901
- const isInitialLoading = !isHydrated || !displayNamesInitialized && displayNamesLoading;
41918
+ const isInitialLoading = !isHydrated || displayNamesLoading || !displayNamesInitialized;
41902
41919
  const isDataLoading = metricsLoading || kpisLoading;
41903
41920
  if (isInitialLoading) {
41904
41921
  return /* @__PURE__ */ jsxRuntime.jsx(LoadingPageCmp, { message: "Loading Dashboard..." });
@@ -41943,6 +41960,7 @@ function HomeView({
41943
41960
  lineNames,
41944
41961
  factoryView: factoryViewId,
41945
41962
  videoSources,
41963
+ displayNames: workspaceDisplayNames,
41946
41964
  className: "h-full",
41947
41965
  onWorkspaceHover: handleWorkspaceHover,
41948
41966
  onWorkspaceHoverEnd: handleWorkspaceHoverEnd
@@ -41970,6 +41988,7 @@ function HomeView({
41970
41988
  lineNames,
41971
41989
  factoryView: factoryViewId,
41972
41990
  videoSources,
41991
+ displayNames: workspaceDisplayNames,
41973
41992
  className: "h-full",
41974
41993
  onWorkspaceHover: handleWorkspaceHover,
41975
41994
  onWorkspaceHoverEnd: handleWorkspaceHoverEnd
package/dist/index.mjs CHANGED
@@ -9573,8 +9573,13 @@ var getAllWorkspaceDisplayNamesAsync = async (companyId, lineId) => {
9573
9573
  return { ...runtimeWorkspaceDisplayNames[lineId] };
9574
9574
  }
9575
9575
  const allNames = {};
9576
- Object.values(runtimeWorkspaceDisplayNames).forEach((lineNames) => {
9577
- Object.assign(allNames, lineNames);
9576
+ Object.entries(runtimeWorkspaceDisplayNames).forEach(([lineId2, lineNames]) => {
9577
+ Object.entries(lineNames).forEach(([workspaceId, displayName]) => {
9578
+ allNames[`${lineId2}_${workspaceId}`] = displayName;
9579
+ if (!allNames[workspaceId]) {
9580
+ allNames[workspaceId] = displayName;
9581
+ }
9582
+ });
9578
9583
  });
9579
9584
  return allNames;
9580
9585
  };
@@ -24332,6 +24337,7 @@ var VideoCard = React23__default.memo(({
24332
24337
  useRAF = true,
24333
24338
  className = "",
24334
24339
  compact = false,
24340
+ displayName,
24335
24341
  onMouseEnter,
24336
24342
  onMouseLeave
24337
24343
  }) => {
@@ -24353,7 +24359,7 @@ var VideoCard = React23__default.memo(({
24353
24359
  onFatalError: onFatalError ?? (() => throttledReloadDashboard())
24354
24360
  });
24355
24361
  }
24356
- const displayName = getWorkspaceDisplayName(workspace.workspace_name, workspace.line_id);
24362
+ const workspaceDisplayName = displayName || getWorkspaceDisplayName(workspace.workspace_name, workspace.line_id);
24357
24363
  const getEfficiencyOverlayColor = (efficiency) => {
24358
24364
  if (efficiency >= 80) {
24359
24365
  return "bg-[#00D654]/25";
@@ -24446,7 +24452,7 @@ var VideoCard = React23__default.memo(({
24446
24452
  /* @__PURE__ */ jsxs("div", { className: `absolute bottom-0 left-0 right-0 bg-black bg-opacity-60 p-1.5 sm:${compact ? "p-1" : "p-1.5"} flex justify-between items-center z-10`, children: [
24447
24453
  /* @__PURE__ */ jsxs("div", { className: "flex items-center gap-1.5", children: [
24448
24454
  /* @__PURE__ */ jsx(Camera, { size: compact ? 10 : 12, className: "text-white" }),
24449
- /* @__PURE__ */ jsx("p", { className: `text-white text-[11px] sm:${compact ? "text-[10px]" : "text-xs"} font-medium tracking-wide`, children: displayName })
24455
+ /* @__PURE__ */ jsx("p", { className: `text-white text-[11px] sm:${compact ? "text-[10px]" : "text-xs"} font-medium tracking-wide`, children: workspaceDisplayName })
24450
24456
  ] }),
24451
24457
  /* @__PURE__ */ jsxs("div", { className: `flex items-center ${compact ? "gap-1" : "gap-1.5"}`, children: [
24452
24458
  trendInfo && /* @__PURE__ */ jsx(
@@ -24483,6 +24489,7 @@ var VideoGridView = React23__default.memo(({
24483
24489
  selectedLine,
24484
24490
  className = "",
24485
24491
  videoSources = {},
24492
+ displayNames = {},
24486
24493
  onWorkspaceHover,
24487
24494
  onWorkspaceHoverEnd
24488
24495
  }) => {
@@ -24697,6 +24704,11 @@ var VideoGridView = React23__default.memo(({
24697
24704
  isVeryLowEfficiency,
24698
24705
  cropping: workspaceCropping,
24699
24706
  canvasFps: canvasConfig?.fps,
24707
+ displayName: (
24708
+ // Create line-aware lookup key: lineId_workspaceName
24709
+ // This ensures correct mapping when multiple lines have same workspace names
24710
+ displayNames[`${workspace.line_id}_${workspace.workspace_name}`] || displayNames[workspace.workspace_name] || getWorkspaceDisplayName(workspace.workspace_name, workspace.line_id)
24711
+ ),
24700
24712
  useRAF: canvasConfig?.useRAF,
24701
24713
  compact: !selectedLine,
24702
24714
  onMouseEnter: onWorkspaceHover ? () => onWorkspaceHover(workspaceId) : void 0,
@@ -24714,6 +24726,7 @@ VideoGridView.displayName = "VideoGridView";
24714
24726
  var MapGridView = React23__default.memo(({
24715
24727
  workspaces,
24716
24728
  className = "",
24729
+ displayNames = {},
24717
24730
  onWorkspaceHover,
24718
24731
  onWorkspaceHoverEnd
24719
24732
  }) => {
@@ -24744,10 +24757,10 @@ var MapGridView = React23__default.memo(({
24744
24757
  efficiency: workspace.efficiency,
24745
24758
  action_count: workspace.action_count
24746
24759
  });
24747
- const displayName = getWorkspaceDisplayName(workspace.workspace_name, workspace.line_id);
24760
+ const displayName = displayNames[`${workspace.line_id}_${workspace.workspace_name}`] || displayNames[workspace.workspace_name] || getWorkspaceDisplayName(workspace.workspace_name, workspace.line_id);
24748
24761
  const navParams = getWorkspaceNavigationParams(workspaceId, displayName, workspace.line_id);
24749
24762
  router.push(`/workspace/${workspaceId}${navParams}`);
24750
- }, [router]);
24763
+ }, [router, displayNames]);
24751
24764
  const activePositions = useMemo(() => {
24752
24765
  return workspacePositions.filter((pos) => {
24753
24766
  const wsKey = pos.id.toUpperCase();
@@ -24773,7 +24786,7 @@ var MapGridView = React23__default.memo(({
24773
24786
  if (!workspace) return null;
24774
24787
  const workspaceId = workspace.workspace_uuid || workspace.workspace_name;
24775
24788
  getPerformanceColor(workspace.efficiency);
24776
- const displayName = getWorkspaceDisplayName(workspace.workspace_name, workspace.line_id);
24789
+ const workspaceDisplayName = displayNames[`${workspace.line_id}_${workspace.workspace_name}`] || displayNames[workspace.workspace_name] || getWorkspaceDisplayName(workspace.workspace_name, workspace.line_id);
24777
24790
  return /* @__PURE__ */ jsx(
24778
24791
  motion.div,
24779
24792
  {
@@ -24799,7 +24812,7 @@ var MapGridView = React23__default.memo(({
24799
24812
  ${position.size === "conveyor" ? "w-32 h-24" : position.size === "large" ? "w-40 h-32" : "w-36 h-28"}
24800
24813
  `,
24801
24814
  children: [
24802
- /* @__PURE__ */ jsx("div", { className: "absolute top-0 left-0 right-0 px-2 py-1.5 border-b border-gray-200", children: /* @__PURE__ */ jsx("div", { className: "text-xs font-bold text-gray-800 truncate text-center leading-tight", children: displayName }) }),
24815
+ /* @__PURE__ */ jsx("div", { className: "absolute top-0 left-0 right-0 px-2 py-1.5 border-b border-gray-200", children: /* @__PURE__ */ jsx("div", { className: "text-xs font-bold text-gray-800 truncate text-center leading-tight", children: workspaceDisplayName }) }),
24803
24816
  /* @__PURE__ */ jsx("div", { className: "absolute bottom-0 left-0 right-0 px-2 py-2", children: /* @__PURE__ */ jsx("div", { className: "flex flex-col items-center", children: /* @__PURE__ */ jsxs("div", { className: "text-2xl font-bold text-gray-900", children: [
24804
24817
  Math.round(workspace.efficiency),
24805
24818
  "%"
@@ -34827,6 +34840,7 @@ var WorkspaceGrid = React23__default.memo(({
34827
34840
  line2Uuid = "line-2",
34828
34841
  className = "",
34829
34842
  videoSources = {},
34843
+ displayNames = {},
34830
34844
  onWorkspaceHover,
34831
34845
  onWorkspaceHoverEnd
34832
34846
  }) => {
@@ -34892,6 +34906,7 @@ var WorkspaceGrid = React23__default.memo(({
34892
34906
  {
34893
34907
  workspaces,
34894
34908
  videoSources,
34909
+ displayNames,
34895
34910
  onWorkspaceHover,
34896
34911
  onWorkspaceHoverEnd
34897
34912
  }
@@ -34910,6 +34925,7 @@ var WorkspaceGrid = React23__default.memo(({
34910
34925
  MapGridViewComponent,
34911
34926
  {
34912
34927
  workspaces,
34928
+ displayNames,
34913
34929
  onWorkspaceHover,
34914
34930
  onWorkspaceHoverEnd
34915
34931
  }
@@ -41500,11 +41516,12 @@ function HomeView({
41500
41516
  };
41501
41517
  initDisplayNames();
41502
41518
  }, [selectedLineId, factoryViewId, allLineIds]);
41519
+ const displayNameLineId = selectedLineId === factoryViewId ? void 0 : selectedLineId;
41503
41520
  const {
41504
41521
  displayNames: workspaceDisplayNames,
41505
41522
  loading: displayNamesLoading,
41506
41523
  error: displayNamesError
41507
- } = useWorkspaceDisplayNames(void 0, selectedLineId);
41524
+ } = useWorkspaceDisplayNames(displayNameLineId, void 0);
41508
41525
  useCallback(() => {
41509
41526
  console.log("Refetching KPIs after line metrics update");
41510
41527
  }, []);
@@ -41868,7 +41885,7 @@ function HomeView({
41868
41885
  /* @__PURE__ */ jsx(SelectContent, { className: "z-50 bg-white shadow-lg border border-gray-200 rounded-md text-xs sm:text-sm", children: availableLineIds.map((id3) => /* @__PURE__ */ jsx(SelectItem, { value: id3, children: lineNames[id3] || (id3 === factoryViewId ? "All Lines" : `Line ${id3.substring(0, 4)}`) }, id3)) })
41869
41886
  ] });
41870
41887
  }, [availableLineIds, handleLineChange, selectedLineId, lineNames, factoryViewId, allLineIds.length]);
41871
- const isInitialLoading = !isHydrated || !displayNamesInitialized && displayNamesLoading;
41888
+ const isInitialLoading = !isHydrated || displayNamesLoading || !displayNamesInitialized;
41872
41889
  const isDataLoading = metricsLoading || kpisLoading;
41873
41890
  if (isInitialLoading) {
41874
41891
  return /* @__PURE__ */ jsx(LoadingPageCmp, { message: "Loading Dashboard..." });
@@ -41913,6 +41930,7 @@ function HomeView({
41913
41930
  lineNames,
41914
41931
  factoryView: factoryViewId,
41915
41932
  videoSources,
41933
+ displayNames: workspaceDisplayNames,
41916
41934
  className: "h-full",
41917
41935
  onWorkspaceHover: handleWorkspaceHover,
41918
41936
  onWorkspaceHoverEnd: handleWorkspaceHoverEnd
@@ -41940,6 +41958,7 @@ function HomeView({
41940
41958
  lineNames,
41941
41959
  factoryView: factoryViewId,
41942
41960
  videoSources,
41961
+ displayNames: workspaceDisplayNames,
41943
41962
  className: "h-full",
41944
41963
  onWorkspaceHover: handleWorkspaceHover,
41945
41964
  onWorkspaceHoverEnd: handleWorkspaceHoverEnd
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@optifye/dashboard-core",
3
- "version": "6.9.4",
3
+ "version": "6.9.6",
4
4
  "description": "Reusable UI & logic for Optifye dashboard",
5
5
  "main": "dist/index.js",
6
6
  "module": "dist/index.mjs",