@optifye/dashboard-core 4.3.6 → 4.3.8

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
@@ -782,6 +782,7 @@ interface ISTTimerProps {
782
782
  interface LeaderboardDetailViewProps {
783
783
  /**
784
784
  * Selected line ID to display the leaderboard for
785
+ * Pass 'factory' for factory view to show both lines
785
786
  */
786
787
  lineId: string;
787
788
  /**
@@ -903,7 +904,7 @@ interface BottleneckVideoData {
903
904
  timestamp: string;
904
905
  severity: 'low' | 'medium' | 'high';
905
906
  description: string;
906
- type: 'bottleneck' | 'low_value' | 'best_cycle_time' | 'worst_cycle_time' | 'missing_quality_check';
907
+ type: 'bottleneck' | 'low_value' | 'best_cycle_time' | 'worst_cycle_time' | 'missing_quality_check' | 'cycle_completions';
907
908
  originalUri: string;
908
909
  cycle_time_seconds?: number;
909
910
  creation_timestamp?: string;
@@ -959,7 +960,7 @@ interface VideoMetadata {
959
960
  creation_timestamp?: string;
960
961
  [key: string]: any;
961
962
  }
962
- type VideoType = 'bottleneck' | 'low_value' | 'best_cycle_time' | 'worst_cycle_time' | 'missing_quality_check';
963
+ type VideoType = 'bottleneck' | 'low_value' | 'best_cycle_time' | 'worst_cycle_time' | 'missing_quality_check' | 'cycle_completions';
963
964
  type VideoSeverity = 'low' | 'medium' | 'high';
964
965
 
965
966
  interface ChatThread {
@@ -1163,11 +1164,15 @@ declare const useMetrics: <T extends Metric>(tableName: string, options?: {
1163
1164
  * metrics automatically when changes occur. Fallback logic is included to fetch the most
1164
1165
  * recent available data if no metrics are found for the exact current/specified period.
1165
1166
  *
1167
+ * IMPORTANT: This hook now supports line_id-aware workspace lookups to differentiate
1168
+ * workspaces with the same name across different lines.
1169
+ *
1166
1170
  * @param {string} workspaceId - The unique identifier of the workspace to fetch metrics for.
1167
1171
  * @param {string} [date] - Optional. An ISO date string (YYYY-MM-DD) to fetch metrics for a specific date,
1168
1172
  * overriding the current operational date.
1169
1173
  * @param {number} [shiftId] - Optional. The ID of the shift to fetch metrics for, overriding the current shift.
1170
1174
  * Requires `dateOverride` to also be provided if used.
1175
+ * @param {string} [lineId] - Optional. The line ID to filter by for workspace disambiguation.
1171
1176
  *
1172
1177
  * @returns {object} An object containing:
1173
1178
  * @returns {WorkspaceDetailedMetrics | null} metrics - The detailed metrics for the workspace, or null if not loaded/found.
@@ -1176,14 +1181,14 @@ declare const useMetrics: <T extends Metric>(tableName: string, options?: {
1176
1181
  * @returns {() => Promise<void>} refetch - A function to manually trigger a refetch of the metrics.
1177
1182
  *
1178
1183
  * @example
1179
- * const { metrics, isLoading, error } = useWorkspaceDetailedMetrics('ws-123');
1184
+ * const { metrics, isLoading, error } = useWorkspaceDetailedMetrics('ws-123', undefined, undefined, 'line1');
1180
1185
  * if (isLoading) return <p>Loading detailed metrics...</p>;
1181
1186
  * if (error) return <p>Error: {error.message}</p>;
1182
1187
  * if (metrics) {
1183
1188
  * // Render workspace details using metrics object
1184
1189
  * }
1185
1190
  */
1186
- declare const useWorkspaceDetailedMetrics: (workspaceId: string, date?: string, shiftId?: number) => {
1191
+ declare const useWorkspaceDetailedMetrics: (workspaceId: string, date?: string, shiftId?: number, lineId?: string) => {
1187
1192
  metrics: WorkspaceDetailedMetrics | null;
1188
1193
  isLoading: boolean;
1189
1194
  error: MetricsError | null;
@@ -2181,7 +2186,29 @@ declare const actionService: {
2181
2186
  type ActionService = typeof actionService;
2182
2187
 
2183
2188
  declare const dashboardService: {
2189
+ /**
2190
+ * Helper method to filter workspaces by line_id for disambiguation
2191
+ * @param workspaces - Array of workspace metrics
2192
+ * @param lineId - Line ID to filter by
2193
+ * @returns Filtered workspace metrics
2194
+ */
2195
+ filterWorkspacesByLineId(workspaces: WorkspaceMetrics[], lineId: string): WorkspaceMetrics[];
2196
+ /**
2197
+ * Helper method to get workspace by composite key (line_id + workspace_name)
2198
+ * @param workspaces - Array of workspace metrics
2199
+ * @param workspaceName - Workspace name to search for
2200
+ * @param lineId - Line ID to filter by
2201
+ * @returns Matching workspace or undefined
2202
+ */
2203
+ getWorkspaceByLineIdAndName(workspaces: WorkspaceMetrics[], workspaceName: string, lineId: string): WorkspaceMetrics | undefined;
2184
2204
  getLineInfo(lineIdInput: string): Promise<LineInfo>;
2205
+ /**
2206
+ * Get workspace data with line_id-aware filtering
2207
+ * @param lineIdInput - Specific line ID to filter by, or factory view ID
2208
+ * @param dateProp - Date to query (optional)
2209
+ * @param shiftProp - Shift ID to query (optional)
2210
+ * @returns Array of workspace metrics with line_id context
2211
+ */
2185
2212
  getWorkspacesData(lineIdInput?: string, dateProp?: string, shiftProp?: number): Promise<WorkspaceMetrics[]>;
2186
2213
  getWorkspaceDetailedMetrics(workspaceUuid: string, dateProp?: string, shiftIdProp?: number): Promise<WorkspaceDetailedMetrics | null>;
2187
2214
  calculateKPIs(lineInfo: LineInfo): DashboardKPIs;
@@ -2352,10 +2379,11 @@ declare const resetCoreMixpanel: () => void;
2352
2379
  * through SSE for the AI's response generation.
2353
2380
  *
2354
2381
  * Event flow:
2355
- * 1. POST message to /api/chat endpoint
2356
- * 2. Receive SSE stream with events: thread, message, reasoning, complete, error
2382
+ * 1. POST message to /api/v2/chat endpoint
2383
+ * 2. Receive SSE stream with events: thread, message, tool_call, tool_result, complete, error
2357
2384
  * 3. AI response is streamed in chunks via 'message' events
2358
- * 4. Once complete, the full conversation is persisted in Supabase
2385
+ * 4. Tool calls and results are visible in real-time
2386
+ * 5. Once complete, the full conversation is persisted in Supabase
2359
2387
  */
2360
2388
  declare class SSEChatClient {
2361
2389
  private controllers;
@@ -2369,7 +2397,9 @@ declare class SSEChatClient {
2369
2397
  onThreadCreated?: (threadId: string) => void;
2370
2398
  onMessage?: (text: string) => void;
2371
2399
  onReasoning?: (text: string) => void;
2372
- onComplete?: (messageId: number) => void;
2400
+ onToolCall?: (tools: any[]) => void;
2401
+ onToolResult?: (results: any[]) => void;
2402
+ onComplete?: (messageId: number, metrics?: any) => void;
2373
2403
  onError?: (error: string) => void;
2374
2404
  }): Promise<void>;
2375
2405
  private handleSSEStream;
@@ -2576,12 +2606,27 @@ interface WorkspaceUrlMapping {
2576
2606
  urlName: string;
2577
2607
  workspaceId: string;
2578
2608
  workspaceName: string;
2609
+ lineId?: string;
2579
2610
  }
2580
- declare const toUrlFriendlyName: (workspaceName: string | undefined) => string;
2581
- declare const fromUrlFriendlyName: (urlName: string) => string;
2611
+ declare const toUrlFriendlyName: (workspaceName: string | undefined, lineId?: string) => string;
2612
+ declare const fromUrlFriendlyName: (urlName: string) => {
2613
+ workspaceName: string;
2614
+ lineId?: string;
2615
+ };
2582
2616
  declare const storeWorkspaceMapping: (mapping: WorkspaceUrlMapping) => void;
2583
- declare const getWorkspaceFromUrl: (urlName: string) => WorkspaceUrlMapping | null;
2617
+ declare const getWorkspaceFromUrl: (urlName: string, lineId?: string) => WorkspaceUrlMapping | null;
2584
2618
  declare const getStoredWorkspaceMappings: () => Record<string, WorkspaceUrlMapping>;
2619
+ /**
2620
+ * Get all workspace mappings for a specific line
2621
+ * @param lineId - The line ID to filter by
2622
+ * @returns Object with workspace mappings for the specified line
2623
+ */
2624
+ declare const getWorkspaceMappingsForLine: (lineId: string) => Record<string, WorkspaceUrlMapping>;
2625
+ /**
2626
+ * Clear workspace mappings for a specific line
2627
+ * @param lineId - The line ID to clear mappings for
2628
+ */
2629
+ declare const clearWorkspaceMappingsForLine: (lineId: string) => void;
2585
2630
 
2586
2631
  /**
2587
2632
  * Pre-initialize workspace display names for a specific line
@@ -2596,14 +2641,17 @@ declare const forceRefreshWorkspaceDisplayNames: (lineId?: string) => Promise<vo
2596
2641
  /**
2597
2642
  * Gets workspace display name synchronously
2598
2643
  * If not initialized, triggers lazy initialization and returns workspace ID
2644
+ * Now supports line_id context for workspace disambiguation
2599
2645
  */
2600
2646
  declare const getWorkspaceDisplayName: (workspaceId: string, lineId?: string) => string;
2601
2647
  /**
2602
2648
  * Short version of workspace display name (synchronous version for backward compatibility)
2649
+ * Now supports line_id context for workspace disambiguation
2603
2650
  */
2604
2651
  declare const getShortWorkspaceDisplayName: (workspaceId: string, lineId?: string) => string;
2605
2652
  /**
2606
2653
  * Async version that ensures data is loaded from Supabase
2654
+ * Now supports line_id context for workspace disambiguation
2607
2655
  */
2608
2656
  declare const getWorkspaceDisplayNameAsync: (workspaceId: string, companyId?: string, lineId?: string) => Promise<string>;
2609
2657
  /**
@@ -3465,7 +3513,7 @@ interface BottlenecksContentProps {
3465
3513
  /**
3466
3514
  * Filter type for bottleneck clips - expanded for new video types
3467
3515
  */
3468
- type BottleneckFilterType = 'all' | 'high' | 'medium' | 'low' | 'low_value' | 'sop_deviations' | 'best_cycle_time' | 'worst_cycle_time' | 'long_cycle_time';
3516
+ type BottleneckFilterType = 'all' | 'high' | 'medium' | 'low' | 'low_value' | 'sop_deviations' | 'best_cycle_time' | 'worst_cycle_time' | 'long_cycle_time' | 'cycle_completions';
3469
3517
  /**
3470
3518
  * Clip counts for each type/severity - updated for new video types
3471
3519
  */
@@ -3478,6 +3526,8 @@ interface ClipCounts {
3478
3526
  sopDeviations: number;
3479
3527
  bestCycleTimes: number;
3480
3528
  worstCycleTimes: number;
3529
+ longCycleTimes: number;
3530
+ cycleCompletions: number;
3481
3531
  total: number;
3482
3532
  }
3483
3533
 
@@ -3561,9 +3611,41 @@ interface VideoGridViewProps {
3561
3611
  defaultHlsUrl?: string;
3562
3612
  workspaceHlsUrls?: Record<string, string>;
3563
3613
  };
3614
+ targetLineId?: string;
3564
3615
  }
3565
3616
  /**
3566
3617
  * VideoGridView component - Simplified version using enterprise-grade HLS streaming
3618
+ *
3619
+ * This component now supports line_id-based workspace filtering and HLS URL mapping.
3620
+ *
3621
+ * Configuration Requirements:
3622
+ * - entityConfig.defaultLineId: Primary line UUID (e.g., '98a2287e-8d55-4020-b00d-b9940437e3e1')
3623
+ * - entityConfig.secondaryLineId: Secondary line UUID (e.g., 'd93997bb-ecac-4478-a4a6-008d536b724c')
3624
+ *
3625
+ * HLS URL Mapping:
3626
+ * - Line-specific URLs use format: 'lineId_workspaceName' (e.g., '98a2287e-8d55-4020-b00d-b9940437e3e1_WS1')
3627
+ * - Falls back to workspace name only if line-specific URL not found
3628
+ *
3629
+ * Usage Examples:
3630
+ * ```typescript
3631
+ * // Filter by specific line UUID
3632
+ * <VideoGridView
3633
+ * workspaces={workspaces}
3634
+ * targetLineId="98a2287e-8d55-4020-b00d-b9940437e3e1"
3635
+ * videoSources={{
3636
+ * workspaceHlsUrls: {
3637
+ * '98a2287e-8d55-4020-b00d-b9940437e3e1_WS1': 'https://line1-hls.optifye.ai/cam1/index.m3u8',
3638
+ * 'd93997bb-ecac-4478-a4a6-008d536b724c_WS1': 'https://line2-hls.optifye.ai/cam1/index.m3u8'
3639
+ * }
3640
+ * }}
3641
+ * />
3642
+ *
3643
+ * // Use configured line selection (1 = defaultLineId, 2 = secondaryLineId)
3644
+ * <VideoGridView
3645
+ * workspaces={workspaces}
3646
+ * selectedLine={1}
3647
+ * />
3648
+ * ```
3567
3649
  */
3568
3650
  declare const VideoGridView: React__default.FC<VideoGridViewProps>;
3569
3651
 
@@ -4523,4 +4605,4 @@ interface ThreadSidebarProps {
4523
4605
  }
4524
4606
  declare const ThreadSidebar: React__default.FC<ThreadSidebarProps>;
4525
4607
 
4526
- export { ACTION_NAMES, AIAgentView, type Action, type ActionName, type ActionService, type ActionThreshold, type ActiveBreak, type AnalyticsConfig, AuthCallback, type AuthCallbackProps, AuthCallbackView, type AuthCallbackViewProps, type AuthConfig, AuthProvider, type AuthUser, AuthenticatedFactoryView, AuthenticatedHelpView, AuthenticatedHomeView, AuthenticatedTargetsView, BarChart, type BarChartDataItem, type BarChartProps, type BarProps, BaseHistoryCalendar, type BaseHistoryCalendarProps, type BaseLineMetric, type BasePerformanceMetric, type BottleneckFilterType, type BottleneckVideo, type BottleneckVideoData, BottlenecksContent, type BottlenecksContentProps, type BreadcrumbItem, type Break, BreakNotificationPopup, type BreakNotificationPopupProps, type BreakRowProps, Card, CardContent, CardDescription, CardFooter, CardHeader, CardTitle, type ChatMessage, type ChatThread, type ClipCounts, type ComponentOverride, type CoreComponents, type CurrentShiftResult, CycleTimeChart, type CycleTimeChartProps, CycleTimeOverTimeChart, type CycleTimeOverTimeChartProps, DEFAULT_ANALYTICS_CONFIG, DEFAULT_AUTH_CONFIG, DEFAULT_CONFIG, DEFAULT_DATABASE_CONFIG, DEFAULT_DATE_TIME_CONFIG, DEFAULT_ENDPOINTS_CONFIG, DEFAULT_ENTITY_CONFIG, DEFAULT_SHIFT_CONFIG, DEFAULT_THEME_CONFIG, DEFAULT_VIDEO_CONFIG, DEFAULT_WORKSPACE_CONFIG, DEFAULT_WORKSPACE_POSITIONS, type DashboardConfig, DashboardHeader, type DashboardKPIs, DashboardLayout, type DashboardLayoutProps, DashboardOverridesProvider, DashboardProvider, type DashboardService, type DatabaseConfig, DateDisplay, type DateTimeConfig, DateTimeDisplay, type DateTimeDisplayProps, type DayHistoryData, type DaySummaryData, DebugAuth, DebugAuthView, EmptyStateMessage, type EmptyStateMessageProps, type EndpointsConfig, type EntityConfig, type FactoryOverviewData, FactoryView, type FactoryViewProps, type FormatNumberOptions, GaugeChart, type GaugeChartProps, GridComponentsPlaceholder, Header, type HeaderProps, HelpView, type HelpViewProps, type HistoryCalendarProps, HomeView, type HookOverride, HourlyOutputChart, type HourlyOutputChartProps, type HourlyPerformance, type ISTDateProps, ISTTimer, type ISTTimerProps, KPICard, type KPICardProps, KPIDetailView, type KPIDetailViewProps, KPIGrid, type KPIGridProps, KPIHeader, type KPIHeaderProps, KPISection, type KPITrend, KPIsOverviewView, type KPIsOverviewViewProps, LINE_1_UUID, LargeOutputProgressChart, type LargeOutputProgressChartProps, LeaderboardDetailView, type LeaderboardDetailViewProps, type LeaderboardEntry, Legend, LineChart, type LineChartDataItem, type LineChartProps, type LineDetails, type LineDisplayData, LineHistoryCalendar, type LineHistoryCalendarProps, type LineInfo, type LineMetrics, LineMonthlyHistory, type LineMonthlyHistoryProps, type LineMonthlyMetric, LineMonthlyPdfGenerator, type LineMonthlyPdfGeneratorProps, type LineNavigationParams, LinePdfExportButton, type LinePdfExportButtonProps, LinePdfGenerator, type LinePdfGeneratorProps, type LineProps, type LineShiftConfig, type LineSnapshot, type LineThreshold, LineWhatsAppShareButton, type LineWhatsAppShareProps, LiveTimer, LoadingOverlay, LoadingPage, LoadingSpinner, LoginPage, type LoginPageProps, LoginView, type LoginViewProps, MainLayout, type MainLayoutProps, type Metric, MetricCard, type MetricCardProps$1 as MetricCardProps, type MetricsError, type NavItem, type NavItemTrackingEvent, NoWorkspaceData, type OperatorData, type OperatorInfo, OptifyeAgentClient, type OptifyeAgentContext, type OptifyeAgentRequest, type OptifyeAgentResponse, OutputProgressChart, type OutputProgressChartProps, type OverridesMap, type OverviewLineMetric, type OverviewWorkspaceMetric, PageHeader, type PageHeaderProps, type PageOverride, PieChart, type PieChartProps, type PoorPerformingWorkspace, type ProfileMenuItem, ProfileView, type QualityMetric, type QualityOverview, type QualityService, type RateLimitOptions, type RateLimitResult, type RealtimeService, RegistryProvider, type RoutePath, type S3ClipsAPIParams, type S3Config, type S3ListObjectsParams, S3Service, type S3ServiceConfig, SOPComplianceChart, type SOPComplianceChartProps, SSEChatClient, type SSEEvent, Select, SelectContent, SelectGroup, SelectItem, SelectLabel, SelectScrollDownButton, SelectScrollUpButton, SelectSeparator, SelectTrigger, SelectValue, type ShiftConfig, type ShiftConfiguration, type ShiftConfigurationRecord, type ShiftData$2 as ShiftData, ShiftDisplay, type ShiftHistoryData, type ShiftHoursMap, type ShiftPanelProps, type ShiftSummaryData, type ShiftTime, ShiftsView, type ShiftsViewProps, SideNavBar, type SideNavBarProps, type SimpleLine, SingleVideoStream, type SingleVideoStreamProps, Skeleton, SlackAPI, type StreamProxyConfig, type SupabaseClient, SupabaseProvider, type Target, TargetWorkspaceGrid, type TargetWorkspaceGridProps, TargetsView, type TargetsViewProps, type ThemeColorValue, type ThemeConfig, ThreadSidebar, TimeDisplay, TimePickerDropdown, type TrackingEventProperties, type TrendDirection, type UnderperformingWorkspace, type UnderperformingWorkspaces, type UseActiveBreaksResult, type UseDashboardMetricsProps, type UseFactoryOverviewOptions, type UseFormatNumberResult, type UseMessagesResult, type UseRealtimeLineMetricsProps, type UseTargetsOptions, type UseThreadsResult, type UseWorkspaceOperatorsOptions, type UserProfileConfig, VideoCard, type VideoConfig, type VideoCroppingConfig, type VideoCroppingRect, VideoGridView, type VideoMetadata, VideoPreloader, type VideoSeverity, type VideoSummary, type VideoType, WORKSPACE_POSITIONS, type WhatsAppSendResult, WhatsAppShareButton, type WhatsAppShareButtonProps, type WhatsappService, type Workspace, type WorkspaceActionUpdate, WorkspaceCard, type WorkspaceCardProps, type WorkspaceConfig, WrappedComponent as WorkspaceDetailView, type WorkspaceDetailedMetrics, WorkspaceDisplayNameExample, WorkspaceGrid, WorkspaceGridItem, type WorkspaceGridItemProps, WorkspaceHistoryCalendar, WorkspaceMetricCards, type WorkspaceMetricCardsProps, type WorkspaceMetrics, WorkspaceMonthlyDataFetcher, type WorkspaceMonthlyDataFetcherProps, type WorkspaceMonthlyMetric, WorkspaceMonthlyPdfGenerator, type WorkspaceMonthlyPdfGeneratorProps, type WorkspaceNavigationParams, WorkspacePdfExportButton, type WorkspacePdfExportButtonProps, WorkspacePdfGenerator, type WorkspacePdfGeneratorProps, type WorkspacePosition, type WorkspaceQualityData, type WorkspaceUrlMapping, WorkspaceWhatsAppShareButton, type WorkspaceWhatsAppShareProps, actionService, apiUtils, authCoreService, authOTPService, authRateLimitService, checkRateLimit, clearAllRateLimits, clearRateLimit, clearS3VideoCache, clearS3VideoFromCache, clearWorkspaceDisplayNamesCache, cn, createStreamProxyHandler, createSupabaseClient, createThrottledReload, dashboardService, deleteThread, forceRefreshWorkspaceDisplayNames, formatDateInZone, formatDateTimeInZone, formatISTDate, formatIdleTime, formatTimeInZone, fromUrlFriendlyName, getAllThreadMessages, getAllWorkspaceDisplayNamesAsync, getAnonClient, getCameraNumber, getCompanyMetricsTableName, getConfigurableShortWorkspaceDisplayName, getConfigurableWorkspaceDisplayName, getCurrentShift, getCurrentTimeInZone, getDashboardHeaderTimeInZone, getDaysDifferenceInZone, getDefaultCameraStreamUrl, getDefaultTabForWorkspace, getManufacturingInsights, getMetricsTablePrefix, getOperationalDate, getS3SignedUrl, getS3VideoSrc, getShortWorkspaceDisplayName, getShortWorkspaceDisplayNameAsync, getStoredWorkspaceMappings, getThreadMessages, getUserThreads, getUserThreadsPaginated, getWorkspaceDisplayName, getWorkspaceDisplayNameAsync, getWorkspaceDisplayNamesMap, getWorkspaceFromUrl, getWorkspaceNavigationParams, identifyCoreUser, initializeCoreMixpanel, isTransitionPeriod, isValidLineInfoPayload, isValidWorkspaceDetailedMetricsPayload, isValidWorkspaceMetricsPayload, isWorkspaceDisplayNamesLoaded, isWorkspaceDisplayNamesLoading, mergeWithDefaultConfig, optifyeAgentClient, preInitializeWorkspaceDisplayNames, preloadS3Video, preloadS3VideoUrl, preloadS3VideosUrl, preloadVideoUrl, preloadVideosUrl, qualityService, realtimeService, refreshWorkspaceDisplayNames, resetCoreMixpanel, s3VideoPreloader, storeWorkspaceMapping, streamProxyConfig, throttledReloadDashboard, toUrlFriendlyName, trackCoreEvent, trackCorePageView, updateThreadTitle, useActiveBreaks, useAnalyticsConfig, useAuth, useAuthConfig, useComponentOverride, useCustomConfig, useDashboardConfig, useDashboardMetrics, useDatabaseConfig, useDateFormatter, useDateTimeConfig, useEndpointsConfig, useEntityConfig, useFactoryOverviewMetrics, useFeatureFlags, useFormatNumber, useHistoricWorkspaceMetrics, useHlsStream, useHlsStreamWithCropping, useHookOverride, useLeaderboardMetrics, useLineDetailedMetrics, useLineKPIs, useLineMetrics, useLineWorkspaceMetrics, useMessages, useMetrics, useNavigation, useOverrides, usePageOverride, useRealtimeLineMetrics, useRegistry, useShiftConfig, useShifts, useSupabase, useSupabaseClient, useTargets, useTheme, useThemeConfig, useThreads, useVideoConfig, useWorkspaceConfig, useWorkspaceDetailedMetrics, useWorkspaceDisplayName, useWorkspaceDisplayNames, useWorkspaceDisplayNamesMap, useWorkspaceMetrics, useWorkspaceNavigation, useWorkspaceOperators, videoPreloader, whatsappService, withAuth, withRegistry, workspaceService };
4608
+ export { ACTION_NAMES, AIAgentView, type Action, type ActionName, type ActionService, type ActionThreshold, type ActiveBreak, type AnalyticsConfig, AuthCallback, type AuthCallbackProps, AuthCallbackView, type AuthCallbackViewProps, type AuthConfig, AuthProvider, type AuthUser, AuthenticatedFactoryView, AuthenticatedHelpView, AuthenticatedHomeView, AuthenticatedTargetsView, BarChart, type BarChartDataItem, type BarChartProps, type BarProps, BaseHistoryCalendar, type BaseHistoryCalendarProps, type BaseLineMetric, type BasePerformanceMetric, type BottleneckFilterType, type BottleneckVideo, type BottleneckVideoData, BottlenecksContent, type BottlenecksContentProps, type BreadcrumbItem, type Break, BreakNotificationPopup, type BreakNotificationPopupProps, type BreakRowProps, Card, CardContent, CardDescription, CardFooter, CardHeader, CardTitle, type ChatMessage, type ChatThread, type ClipCounts, type ComponentOverride, type CoreComponents, type CurrentShiftResult, CycleTimeChart, type CycleTimeChartProps, CycleTimeOverTimeChart, type CycleTimeOverTimeChartProps, DEFAULT_ANALYTICS_CONFIG, DEFAULT_AUTH_CONFIG, DEFAULT_CONFIG, DEFAULT_DATABASE_CONFIG, DEFAULT_DATE_TIME_CONFIG, DEFAULT_ENDPOINTS_CONFIG, DEFAULT_ENTITY_CONFIG, DEFAULT_SHIFT_CONFIG, DEFAULT_THEME_CONFIG, DEFAULT_VIDEO_CONFIG, DEFAULT_WORKSPACE_CONFIG, DEFAULT_WORKSPACE_POSITIONS, type DashboardConfig, DashboardHeader, type DashboardKPIs, DashboardLayout, type DashboardLayoutProps, DashboardOverridesProvider, DashboardProvider, type DashboardService, type DatabaseConfig, DateDisplay, type DateTimeConfig, DateTimeDisplay, type DateTimeDisplayProps, type DayHistoryData, type DaySummaryData, DebugAuth, DebugAuthView, EmptyStateMessage, type EmptyStateMessageProps, type EndpointsConfig, type EntityConfig, type FactoryOverviewData, FactoryView, type FactoryViewProps, type FormatNumberOptions, GaugeChart, type GaugeChartProps, GridComponentsPlaceholder, Header, type HeaderProps, HelpView, type HelpViewProps, type HistoryCalendarProps, HomeView, type HookOverride, HourlyOutputChart, type HourlyOutputChartProps, type HourlyPerformance, type ISTDateProps, ISTTimer, type ISTTimerProps, KPICard, type KPICardProps, KPIDetailView, type KPIDetailViewProps, KPIGrid, type KPIGridProps, KPIHeader, type KPIHeaderProps, KPISection, type KPITrend, KPIsOverviewView, type KPIsOverviewViewProps, LINE_1_UUID, LargeOutputProgressChart, type LargeOutputProgressChartProps, LeaderboardDetailView, type LeaderboardDetailViewProps, type LeaderboardEntry, Legend, LineChart, type LineChartDataItem, type LineChartProps, type LineDetails, type LineDisplayData, LineHistoryCalendar, type LineHistoryCalendarProps, type LineInfo, type LineMetrics, LineMonthlyHistory, type LineMonthlyHistoryProps, type LineMonthlyMetric, LineMonthlyPdfGenerator, type LineMonthlyPdfGeneratorProps, type LineNavigationParams, LinePdfExportButton, type LinePdfExportButtonProps, LinePdfGenerator, type LinePdfGeneratorProps, type LineProps, type LineShiftConfig, type LineSnapshot, type LineThreshold, LineWhatsAppShareButton, type LineWhatsAppShareProps, LiveTimer, LoadingOverlay, LoadingPage, LoadingSpinner, LoginPage, type LoginPageProps, LoginView, type LoginViewProps, MainLayout, type MainLayoutProps, type Metric, MetricCard, type MetricCardProps$1 as MetricCardProps, type MetricsError, type NavItem, type NavItemTrackingEvent, NoWorkspaceData, type OperatorData, type OperatorInfo, OptifyeAgentClient, type OptifyeAgentContext, type OptifyeAgentRequest, type OptifyeAgentResponse, OutputProgressChart, type OutputProgressChartProps, type OverridesMap, type OverviewLineMetric, type OverviewWorkspaceMetric, PageHeader, type PageHeaderProps, type PageOverride, PieChart, type PieChartProps, type PoorPerformingWorkspace, type ProfileMenuItem, ProfileView, type QualityMetric, type QualityOverview, type QualityService, type RateLimitOptions, type RateLimitResult, type RealtimeService, RegistryProvider, type RoutePath, type S3ClipsAPIParams, type S3Config, type S3ListObjectsParams, S3Service, type S3ServiceConfig, SOPComplianceChart, type SOPComplianceChartProps, SSEChatClient, type SSEEvent, Select, SelectContent, SelectGroup, SelectItem, SelectLabel, SelectScrollDownButton, SelectScrollUpButton, SelectSeparator, SelectTrigger, SelectValue, type ShiftConfig, type ShiftConfiguration, type ShiftConfigurationRecord, type ShiftData$2 as ShiftData, ShiftDisplay, type ShiftHistoryData, type ShiftHoursMap, type ShiftPanelProps, type ShiftSummaryData, type ShiftTime, ShiftsView, type ShiftsViewProps, SideNavBar, type SideNavBarProps, type SimpleLine, SingleVideoStream, type SingleVideoStreamProps, Skeleton, SlackAPI, type StreamProxyConfig, type SupabaseClient, SupabaseProvider, type Target, TargetWorkspaceGrid, type TargetWorkspaceGridProps, TargetsView, type TargetsViewProps, type ThemeColorValue, type ThemeConfig, ThreadSidebar, TimeDisplay, TimePickerDropdown, type TrackingEventProperties, type TrendDirection, type UnderperformingWorkspace, type UnderperformingWorkspaces, type UseActiveBreaksResult, type UseDashboardMetricsProps, type UseFactoryOverviewOptions, type UseFormatNumberResult, type UseMessagesResult, type UseRealtimeLineMetricsProps, type UseTargetsOptions, type UseThreadsResult, type UseWorkspaceOperatorsOptions, type UserProfileConfig, VideoCard, type VideoConfig, type VideoCroppingConfig, type VideoCroppingRect, VideoGridView, type VideoMetadata, VideoPreloader, type VideoSeverity, type VideoSummary, type VideoType, WORKSPACE_POSITIONS, type WhatsAppSendResult, WhatsAppShareButton, type WhatsAppShareButtonProps, type WhatsappService, type Workspace, type WorkspaceActionUpdate, WorkspaceCard, type WorkspaceCardProps, type WorkspaceConfig, WrappedComponent as WorkspaceDetailView, type WorkspaceDetailedMetrics, WorkspaceDisplayNameExample, WorkspaceGrid, WorkspaceGridItem, type WorkspaceGridItemProps, WorkspaceHistoryCalendar, WorkspaceMetricCards, type WorkspaceMetricCardsProps, type WorkspaceMetrics, WorkspaceMonthlyDataFetcher, type WorkspaceMonthlyDataFetcherProps, type WorkspaceMonthlyMetric, WorkspaceMonthlyPdfGenerator, type WorkspaceMonthlyPdfGeneratorProps, type WorkspaceNavigationParams, WorkspacePdfExportButton, type WorkspacePdfExportButtonProps, WorkspacePdfGenerator, type WorkspacePdfGeneratorProps, type WorkspacePosition, type WorkspaceQualityData, type WorkspaceUrlMapping, WorkspaceWhatsAppShareButton, type WorkspaceWhatsAppShareProps, actionService, apiUtils, authCoreService, authOTPService, authRateLimitService, checkRateLimit, clearAllRateLimits, clearRateLimit, clearS3VideoCache, clearS3VideoFromCache, clearWorkspaceDisplayNamesCache, clearWorkspaceMappingsForLine, cn, createStreamProxyHandler, createSupabaseClient, createThrottledReload, dashboardService, deleteThread, forceRefreshWorkspaceDisplayNames, formatDateInZone, formatDateTimeInZone, formatISTDate, formatIdleTime, formatTimeInZone, fromUrlFriendlyName, getAllThreadMessages, getAllWorkspaceDisplayNamesAsync, getAnonClient, getCameraNumber, getCompanyMetricsTableName, getConfigurableShortWorkspaceDisplayName, getConfigurableWorkspaceDisplayName, getCurrentShift, getCurrentTimeInZone, getDashboardHeaderTimeInZone, getDaysDifferenceInZone, getDefaultCameraStreamUrl, getDefaultTabForWorkspace, getManufacturingInsights, getMetricsTablePrefix, getOperationalDate, getS3SignedUrl, getS3VideoSrc, getShortWorkspaceDisplayName, getShortWorkspaceDisplayNameAsync, getStoredWorkspaceMappings, getThreadMessages, getUserThreads, getUserThreadsPaginated, getWorkspaceDisplayName, getWorkspaceDisplayNameAsync, getWorkspaceDisplayNamesMap, getWorkspaceFromUrl, getWorkspaceMappingsForLine, getWorkspaceNavigationParams, identifyCoreUser, initializeCoreMixpanel, isTransitionPeriod, isValidLineInfoPayload, isValidWorkspaceDetailedMetricsPayload, isValidWorkspaceMetricsPayload, isWorkspaceDisplayNamesLoaded, isWorkspaceDisplayNamesLoading, mergeWithDefaultConfig, optifyeAgentClient, preInitializeWorkspaceDisplayNames, preloadS3Video, preloadS3VideoUrl, preloadS3VideosUrl, preloadVideoUrl, preloadVideosUrl, qualityService, realtimeService, refreshWorkspaceDisplayNames, resetCoreMixpanel, s3VideoPreloader, storeWorkspaceMapping, streamProxyConfig, throttledReloadDashboard, toUrlFriendlyName, trackCoreEvent, trackCorePageView, updateThreadTitle, useActiveBreaks, useAnalyticsConfig, useAuth, useAuthConfig, useComponentOverride, useCustomConfig, useDashboardConfig, useDashboardMetrics, useDatabaseConfig, useDateFormatter, useDateTimeConfig, useEndpointsConfig, useEntityConfig, useFactoryOverviewMetrics, useFeatureFlags, useFormatNumber, useHistoricWorkspaceMetrics, useHlsStream, useHlsStreamWithCropping, useHookOverride, useLeaderboardMetrics, useLineDetailedMetrics, useLineKPIs, useLineMetrics, useLineWorkspaceMetrics, useMessages, useMetrics, useNavigation, useOverrides, usePageOverride, useRealtimeLineMetrics, useRegistry, useShiftConfig, useShifts, useSupabase, useSupabaseClient, useTargets, useTheme, useThemeConfig, useThreads, useVideoConfig, useWorkspaceConfig, useWorkspaceDetailedMetrics, useWorkspaceDisplayName, useWorkspaceDisplayNames, useWorkspaceDisplayNamesMap, useWorkspaceMetrics, useWorkspaceNavigation, useWorkspaceOperators, videoPreloader, whatsappService, withAuth, withRegistry, workspaceService };
package/dist/index.d.ts CHANGED
@@ -782,6 +782,7 @@ interface ISTTimerProps {
782
782
  interface LeaderboardDetailViewProps {
783
783
  /**
784
784
  * Selected line ID to display the leaderboard for
785
+ * Pass 'factory' for factory view to show both lines
785
786
  */
786
787
  lineId: string;
787
788
  /**
@@ -903,7 +904,7 @@ interface BottleneckVideoData {
903
904
  timestamp: string;
904
905
  severity: 'low' | 'medium' | 'high';
905
906
  description: string;
906
- type: 'bottleneck' | 'low_value' | 'best_cycle_time' | 'worst_cycle_time' | 'missing_quality_check';
907
+ type: 'bottleneck' | 'low_value' | 'best_cycle_time' | 'worst_cycle_time' | 'missing_quality_check' | 'cycle_completions';
907
908
  originalUri: string;
908
909
  cycle_time_seconds?: number;
909
910
  creation_timestamp?: string;
@@ -959,7 +960,7 @@ interface VideoMetadata {
959
960
  creation_timestamp?: string;
960
961
  [key: string]: any;
961
962
  }
962
- type VideoType = 'bottleneck' | 'low_value' | 'best_cycle_time' | 'worst_cycle_time' | 'missing_quality_check';
963
+ type VideoType = 'bottleneck' | 'low_value' | 'best_cycle_time' | 'worst_cycle_time' | 'missing_quality_check' | 'cycle_completions';
963
964
  type VideoSeverity = 'low' | 'medium' | 'high';
964
965
 
965
966
  interface ChatThread {
@@ -1163,11 +1164,15 @@ declare const useMetrics: <T extends Metric>(tableName: string, options?: {
1163
1164
  * metrics automatically when changes occur. Fallback logic is included to fetch the most
1164
1165
  * recent available data if no metrics are found for the exact current/specified period.
1165
1166
  *
1167
+ * IMPORTANT: This hook now supports line_id-aware workspace lookups to differentiate
1168
+ * workspaces with the same name across different lines.
1169
+ *
1166
1170
  * @param {string} workspaceId - The unique identifier of the workspace to fetch metrics for.
1167
1171
  * @param {string} [date] - Optional. An ISO date string (YYYY-MM-DD) to fetch metrics for a specific date,
1168
1172
  * overriding the current operational date.
1169
1173
  * @param {number} [shiftId] - Optional. The ID of the shift to fetch metrics for, overriding the current shift.
1170
1174
  * Requires `dateOverride` to also be provided if used.
1175
+ * @param {string} [lineId] - Optional. The line ID to filter by for workspace disambiguation.
1171
1176
  *
1172
1177
  * @returns {object} An object containing:
1173
1178
  * @returns {WorkspaceDetailedMetrics | null} metrics - The detailed metrics for the workspace, or null if not loaded/found.
@@ -1176,14 +1181,14 @@ declare const useMetrics: <T extends Metric>(tableName: string, options?: {
1176
1181
  * @returns {() => Promise<void>} refetch - A function to manually trigger a refetch of the metrics.
1177
1182
  *
1178
1183
  * @example
1179
- * const { metrics, isLoading, error } = useWorkspaceDetailedMetrics('ws-123');
1184
+ * const { metrics, isLoading, error } = useWorkspaceDetailedMetrics('ws-123', undefined, undefined, 'line1');
1180
1185
  * if (isLoading) return <p>Loading detailed metrics...</p>;
1181
1186
  * if (error) return <p>Error: {error.message}</p>;
1182
1187
  * if (metrics) {
1183
1188
  * // Render workspace details using metrics object
1184
1189
  * }
1185
1190
  */
1186
- declare const useWorkspaceDetailedMetrics: (workspaceId: string, date?: string, shiftId?: number) => {
1191
+ declare const useWorkspaceDetailedMetrics: (workspaceId: string, date?: string, shiftId?: number, lineId?: string) => {
1187
1192
  metrics: WorkspaceDetailedMetrics | null;
1188
1193
  isLoading: boolean;
1189
1194
  error: MetricsError | null;
@@ -2181,7 +2186,29 @@ declare const actionService: {
2181
2186
  type ActionService = typeof actionService;
2182
2187
 
2183
2188
  declare const dashboardService: {
2189
+ /**
2190
+ * Helper method to filter workspaces by line_id for disambiguation
2191
+ * @param workspaces - Array of workspace metrics
2192
+ * @param lineId - Line ID to filter by
2193
+ * @returns Filtered workspace metrics
2194
+ */
2195
+ filterWorkspacesByLineId(workspaces: WorkspaceMetrics[], lineId: string): WorkspaceMetrics[];
2196
+ /**
2197
+ * Helper method to get workspace by composite key (line_id + workspace_name)
2198
+ * @param workspaces - Array of workspace metrics
2199
+ * @param workspaceName - Workspace name to search for
2200
+ * @param lineId - Line ID to filter by
2201
+ * @returns Matching workspace or undefined
2202
+ */
2203
+ getWorkspaceByLineIdAndName(workspaces: WorkspaceMetrics[], workspaceName: string, lineId: string): WorkspaceMetrics | undefined;
2184
2204
  getLineInfo(lineIdInput: string): Promise<LineInfo>;
2205
+ /**
2206
+ * Get workspace data with line_id-aware filtering
2207
+ * @param lineIdInput - Specific line ID to filter by, or factory view ID
2208
+ * @param dateProp - Date to query (optional)
2209
+ * @param shiftProp - Shift ID to query (optional)
2210
+ * @returns Array of workspace metrics with line_id context
2211
+ */
2185
2212
  getWorkspacesData(lineIdInput?: string, dateProp?: string, shiftProp?: number): Promise<WorkspaceMetrics[]>;
2186
2213
  getWorkspaceDetailedMetrics(workspaceUuid: string, dateProp?: string, shiftIdProp?: number): Promise<WorkspaceDetailedMetrics | null>;
2187
2214
  calculateKPIs(lineInfo: LineInfo): DashboardKPIs;
@@ -2352,10 +2379,11 @@ declare const resetCoreMixpanel: () => void;
2352
2379
  * through SSE for the AI's response generation.
2353
2380
  *
2354
2381
  * Event flow:
2355
- * 1. POST message to /api/chat endpoint
2356
- * 2. Receive SSE stream with events: thread, message, reasoning, complete, error
2382
+ * 1. POST message to /api/v2/chat endpoint
2383
+ * 2. Receive SSE stream with events: thread, message, tool_call, tool_result, complete, error
2357
2384
  * 3. AI response is streamed in chunks via 'message' events
2358
- * 4. Once complete, the full conversation is persisted in Supabase
2385
+ * 4. Tool calls and results are visible in real-time
2386
+ * 5. Once complete, the full conversation is persisted in Supabase
2359
2387
  */
2360
2388
  declare class SSEChatClient {
2361
2389
  private controllers;
@@ -2369,7 +2397,9 @@ declare class SSEChatClient {
2369
2397
  onThreadCreated?: (threadId: string) => void;
2370
2398
  onMessage?: (text: string) => void;
2371
2399
  onReasoning?: (text: string) => void;
2372
- onComplete?: (messageId: number) => void;
2400
+ onToolCall?: (tools: any[]) => void;
2401
+ onToolResult?: (results: any[]) => void;
2402
+ onComplete?: (messageId: number, metrics?: any) => void;
2373
2403
  onError?: (error: string) => void;
2374
2404
  }): Promise<void>;
2375
2405
  private handleSSEStream;
@@ -2576,12 +2606,27 @@ interface WorkspaceUrlMapping {
2576
2606
  urlName: string;
2577
2607
  workspaceId: string;
2578
2608
  workspaceName: string;
2609
+ lineId?: string;
2579
2610
  }
2580
- declare const toUrlFriendlyName: (workspaceName: string | undefined) => string;
2581
- declare const fromUrlFriendlyName: (urlName: string) => string;
2611
+ declare const toUrlFriendlyName: (workspaceName: string | undefined, lineId?: string) => string;
2612
+ declare const fromUrlFriendlyName: (urlName: string) => {
2613
+ workspaceName: string;
2614
+ lineId?: string;
2615
+ };
2582
2616
  declare const storeWorkspaceMapping: (mapping: WorkspaceUrlMapping) => void;
2583
- declare const getWorkspaceFromUrl: (urlName: string) => WorkspaceUrlMapping | null;
2617
+ declare const getWorkspaceFromUrl: (urlName: string, lineId?: string) => WorkspaceUrlMapping | null;
2584
2618
  declare const getStoredWorkspaceMappings: () => Record<string, WorkspaceUrlMapping>;
2619
+ /**
2620
+ * Get all workspace mappings for a specific line
2621
+ * @param lineId - The line ID to filter by
2622
+ * @returns Object with workspace mappings for the specified line
2623
+ */
2624
+ declare const getWorkspaceMappingsForLine: (lineId: string) => Record<string, WorkspaceUrlMapping>;
2625
+ /**
2626
+ * Clear workspace mappings for a specific line
2627
+ * @param lineId - The line ID to clear mappings for
2628
+ */
2629
+ declare const clearWorkspaceMappingsForLine: (lineId: string) => void;
2585
2630
 
2586
2631
  /**
2587
2632
  * Pre-initialize workspace display names for a specific line
@@ -2596,14 +2641,17 @@ declare const forceRefreshWorkspaceDisplayNames: (lineId?: string) => Promise<vo
2596
2641
  /**
2597
2642
  * Gets workspace display name synchronously
2598
2643
  * If not initialized, triggers lazy initialization and returns workspace ID
2644
+ * Now supports line_id context for workspace disambiguation
2599
2645
  */
2600
2646
  declare const getWorkspaceDisplayName: (workspaceId: string, lineId?: string) => string;
2601
2647
  /**
2602
2648
  * Short version of workspace display name (synchronous version for backward compatibility)
2649
+ * Now supports line_id context for workspace disambiguation
2603
2650
  */
2604
2651
  declare const getShortWorkspaceDisplayName: (workspaceId: string, lineId?: string) => string;
2605
2652
  /**
2606
2653
  * Async version that ensures data is loaded from Supabase
2654
+ * Now supports line_id context for workspace disambiguation
2607
2655
  */
2608
2656
  declare const getWorkspaceDisplayNameAsync: (workspaceId: string, companyId?: string, lineId?: string) => Promise<string>;
2609
2657
  /**
@@ -3465,7 +3513,7 @@ interface BottlenecksContentProps {
3465
3513
  /**
3466
3514
  * Filter type for bottleneck clips - expanded for new video types
3467
3515
  */
3468
- type BottleneckFilterType = 'all' | 'high' | 'medium' | 'low' | 'low_value' | 'sop_deviations' | 'best_cycle_time' | 'worst_cycle_time' | 'long_cycle_time';
3516
+ type BottleneckFilterType = 'all' | 'high' | 'medium' | 'low' | 'low_value' | 'sop_deviations' | 'best_cycle_time' | 'worst_cycle_time' | 'long_cycle_time' | 'cycle_completions';
3469
3517
  /**
3470
3518
  * Clip counts for each type/severity - updated for new video types
3471
3519
  */
@@ -3478,6 +3526,8 @@ interface ClipCounts {
3478
3526
  sopDeviations: number;
3479
3527
  bestCycleTimes: number;
3480
3528
  worstCycleTimes: number;
3529
+ longCycleTimes: number;
3530
+ cycleCompletions: number;
3481
3531
  total: number;
3482
3532
  }
3483
3533
 
@@ -3561,9 +3611,41 @@ interface VideoGridViewProps {
3561
3611
  defaultHlsUrl?: string;
3562
3612
  workspaceHlsUrls?: Record<string, string>;
3563
3613
  };
3614
+ targetLineId?: string;
3564
3615
  }
3565
3616
  /**
3566
3617
  * VideoGridView component - Simplified version using enterprise-grade HLS streaming
3618
+ *
3619
+ * This component now supports line_id-based workspace filtering and HLS URL mapping.
3620
+ *
3621
+ * Configuration Requirements:
3622
+ * - entityConfig.defaultLineId: Primary line UUID (e.g., '98a2287e-8d55-4020-b00d-b9940437e3e1')
3623
+ * - entityConfig.secondaryLineId: Secondary line UUID (e.g., 'd93997bb-ecac-4478-a4a6-008d536b724c')
3624
+ *
3625
+ * HLS URL Mapping:
3626
+ * - Line-specific URLs use format: 'lineId_workspaceName' (e.g., '98a2287e-8d55-4020-b00d-b9940437e3e1_WS1')
3627
+ * - Falls back to workspace name only if line-specific URL not found
3628
+ *
3629
+ * Usage Examples:
3630
+ * ```typescript
3631
+ * // Filter by specific line UUID
3632
+ * <VideoGridView
3633
+ * workspaces={workspaces}
3634
+ * targetLineId="98a2287e-8d55-4020-b00d-b9940437e3e1"
3635
+ * videoSources={{
3636
+ * workspaceHlsUrls: {
3637
+ * '98a2287e-8d55-4020-b00d-b9940437e3e1_WS1': 'https://line1-hls.optifye.ai/cam1/index.m3u8',
3638
+ * 'd93997bb-ecac-4478-a4a6-008d536b724c_WS1': 'https://line2-hls.optifye.ai/cam1/index.m3u8'
3639
+ * }
3640
+ * }}
3641
+ * />
3642
+ *
3643
+ * // Use configured line selection (1 = defaultLineId, 2 = secondaryLineId)
3644
+ * <VideoGridView
3645
+ * workspaces={workspaces}
3646
+ * selectedLine={1}
3647
+ * />
3648
+ * ```
3567
3649
  */
3568
3650
  declare const VideoGridView: React__default.FC<VideoGridViewProps>;
3569
3651
 
@@ -4523,4 +4605,4 @@ interface ThreadSidebarProps {
4523
4605
  }
4524
4606
  declare const ThreadSidebar: React__default.FC<ThreadSidebarProps>;
4525
4607
 
4526
- export { ACTION_NAMES, AIAgentView, type Action, type ActionName, type ActionService, type ActionThreshold, type ActiveBreak, type AnalyticsConfig, AuthCallback, type AuthCallbackProps, AuthCallbackView, type AuthCallbackViewProps, type AuthConfig, AuthProvider, type AuthUser, AuthenticatedFactoryView, AuthenticatedHelpView, AuthenticatedHomeView, AuthenticatedTargetsView, BarChart, type BarChartDataItem, type BarChartProps, type BarProps, BaseHistoryCalendar, type BaseHistoryCalendarProps, type BaseLineMetric, type BasePerformanceMetric, type BottleneckFilterType, type BottleneckVideo, type BottleneckVideoData, BottlenecksContent, type BottlenecksContentProps, type BreadcrumbItem, type Break, BreakNotificationPopup, type BreakNotificationPopupProps, type BreakRowProps, Card, CardContent, CardDescription, CardFooter, CardHeader, CardTitle, type ChatMessage, type ChatThread, type ClipCounts, type ComponentOverride, type CoreComponents, type CurrentShiftResult, CycleTimeChart, type CycleTimeChartProps, CycleTimeOverTimeChart, type CycleTimeOverTimeChartProps, DEFAULT_ANALYTICS_CONFIG, DEFAULT_AUTH_CONFIG, DEFAULT_CONFIG, DEFAULT_DATABASE_CONFIG, DEFAULT_DATE_TIME_CONFIG, DEFAULT_ENDPOINTS_CONFIG, DEFAULT_ENTITY_CONFIG, DEFAULT_SHIFT_CONFIG, DEFAULT_THEME_CONFIG, DEFAULT_VIDEO_CONFIG, DEFAULT_WORKSPACE_CONFIG, DEFAULT_WORKSPACE_POSITIONS, type DashboardConfig, DashboardHeader, type DashboardKPIs, DashboardLayout, type DashboardLayoutProps, DashboardOverridesProvider, DashboardProvider, type DashboardService, type DatabaseConfig, DateDisplay, type DateTimeConfig, DateTimeDisplay, type DateTimeDisplayProps, type DayHistoryData, type DaySummaryData, DebugAuth, DebugAuthView, EmptyStateMessage, type EmptyStateMessageProps, type EndpointsConfig, type EntityConfig, type FactoryOverviewData, FactoryView, type FactoryViewProps, type FormatNumberOptions, GaugeChart, type GaugeChartProps, GridComponentsPlaceholder, Header, type HeaderProps, HelpView, type HelpViewProps, type HistoryCalendarProps, HomeView, type HookOverride, HourlyOutputChart, type HourlyOutputChartProps, type HourlyPerformance, type ISTDateProps, ISTTimer, type ISTTimerProps, KPICard, type KPICardProps, KPIDetailView, type KPIDetailViewProps, KPIGrid, type KPIGridProps, KPIHeader, type KPIHeaderProps, KPISection, type KPITrend, KPIsOverviewView, type KPIsOverviewViewProps, LINE_1_UUID, LargeOutputProgressChart, type LargeOutputProgressChartProps, LeaderboardDetailView, type LeaderboardDetailViewProps, type LeaderboardEntry, Legend, LineChart, type LineChartDataItem, type LineChartProps, type LineDetails, type LineDisplayData, LineHistoryCalendar, type LineHistoryCalendarProps, type LineInfo, type LineMetrics, LineMonthlyHistory, type LineMonthlyHistoryProps, type LineMonthlyMetric, LineMonthlyPdfGenerator, type LineMonthlyPdfGeneratorProps, type LineNavigationParams, LinePdfExportButton, type LinePdfExportButtonProps, LinePdfGenerator, type LinePdfGeneratorProps, type LineProps, type LineShiftConfig, type LineSnapshot, type LineThreshold, LineWhatsAppShareButton, type LineWhatsAppShareProps, LiveTimer, LoadingOverlay, LoadingPage, LoadingSpinner, LoginPage, type LoginPageProps, LoginView, type LoginViewProps, MainLayout, type MainLayoutProps, type Metric, MetricCard, type MetricCardProps$1 as MetricCardProps, type MetricsError, type NavItem, type NavItemTrackingEvent, NoWorkspaceData, type OperatorData, type OperatorInfo, OptifyeAgentClient, type OptifyeAgentContext, type OptifyeAgentRequest, type OptifyeAgentResponse, OutputProgressChart, type OutputProgressChartProps, type OverridesMap, type OverviewLineMetric, type OverviewWorkspaceMetric, PageHeader, type PageHeaderProps, type PageOverride, PieChart, type PieChartProps, type PoorPerformingWorkspace, type ProfileMenuItem, ProfileView, type QualityMetric, type QualityOverview, type QualityService, type RateLimitOptions, type RateLimitResult, type RealtimeService, RegistryProvider, type RoutePath, type S3ClipsAPIParams, type S3Config, type S3ListObjectsParams, S3Service, type S3ServiceConfig, SOPComplianceChart, type SOPComplianceChartProps, SSEChatClient, type SSEEvent, Select, SelectContent, SelectGroup, SelectItem, SelectLabel, SelectScrollDownButton, SelectScrollUpButton, SelectSeparator, SelectTrigger, SelectValue, type ShiftConfig, type ShiftConfiguration, type ShiftConfigurationRecord, type ShiftData$2 as ShiftData, ShiftDisplay, type ShiftHistoryData, type ShiftHoursMap, type ShiftPanelProps, type ShiftSummaryData, type ShiftTime, ShiftsView, type ShiftsViewProps, SideNavBar, type SideNavBarProps, type SimpleLine, SingleVideoStream, type SingleVideoStreamProps, Skeleton, SlackAPI, type StreamProxyConfig, type SupabaseClient, SupabaseProvider, type Target, TargetWorkspaceGrid, type TargetWorkspaceGridProps, TargetsView, type TargetsViewProps, type ThemeColorValue, type ThemeConfig, ThreadSidebar, TimeDisplay, TimePickerDropdown, type TrackingEventProperties, type TrendDirection, type UnderperformingWorkspace, type UnderperformingWorkspaces, type UseActiveBreaksResult, type UseDashboardMetricsProps, type UseFactoryOverviewOptions, type UseFormatNumberResult, type UseMessagesResult, type UseRealtimeLineMetricsProps, type UseTargetsOptions, type UseThreadsResult, type UseWorkspaceOperatorsOptions, type UserProfileConfig, VideoCard, type VideoConfig, type VideoCroppingConfig, type VideoCroppingRect, VideoGridView, type VideoMetadata, VideoPreloader, type VideoSeverity, type VideoSummary, type VideoType, WORKSPACE_POSITIONS, type WhatsAppSendResult, WhatsAppShareButton, type WhatsAppShareButtonProps, type WhatsappService, type Workspace, type WorkspaceActionUpdate, WorkspaceCard, type WorkspaceCardProps, type WorkspaceConfig, WrappedComponent as WorkspaceDetailView, type WorkspaceDetailedMetrics, WorkspaceDisplayNameExample, WorkspaceGrid, WorkspaceGridItem, type WorkspaceGridItemProps, WorkspaceHistoryCalendar, WorkspaceMetricCards, type WorkspaceMetricCardsProps, type WorkspaceMetrics, WorkspaceMonthlyDataFetcher, type WorkspaceMonthlyDataFetcherProps, type WorkspaceMonthlyMetric, WorkspaceMonthlyPdfGenerator, type WorkspaceMonthlyPdfGeneratorProps, type WorkspaceNavigationParams, WorkspacePdfExportButton, type WorkspacePdfExportButtonProps, WorkspacePdfGenerator, type WorkspacePdfGeneratorProps, type WorkspacePosition, type WorkspaceQualityData, type WorkspaceUrlMapping, WorkspaceWhatsAppShareButton, type WorkspaceWhatsAppShareProps, actionService, apiUtils, authCoreService, authOTPService, authRateLimitService, checkRateLimit, clearAllRateLimits, clearRateLimit, clearS3VideoCache, clearS3VideoFromCache, clearWorkspaceDisplayNamesCache, cn, createStreamProxyHandler, createSupabaseClient, createThrottledReload, dashboardService, deleteThread, forceRefreshWorkspaceDisplayNames, formatDateInZone, formatDateTimeInZone, formatISTDate, formatIdleTime, formatTimeInZone, fromUrlFriendlyName, getAllThreadMessages, getAllWorkspaceDisplayNamesAsync, getAnonClient, getCameraNumber, getCompanyMetricsTableName, getConfigurableShortWorkspaceDisplayName, getConfigurableWorkspaceDisplayName, getCurrentShift, getCurrentTimeInZone, getDashboardHeaderTimeInZone, getDaysDifferenceInZone, getDefaultCameraStreamUrl, getDefaultTabForWorkspace, getManufacturingInsights, getMetricsTablePrefix, getOperationalDate, getS3SignedUrl, getS3VideoSrc, getShortWorkspaceDisplayName, getShortWorkspaceDisplayNameAsync, getStoredWorkspaceMappings, getThreadMessages, getUserThreads, getUserThreadsPaginated, getWorkspaceDisplayName, getWorkspaceDisplayNameAsync, getWorkspaceDisplayNamesMap, getWorkspaceFromUrl, getWorkspaceNavigationParams, identifyCoreUser, initializeCoreMixpanel, isTransitionPeriod, isValidLineInfoPayload, isValidWorkspaceDetailedMetricsPayload, isValidWorkspaceMetricsPayload, isWorkspaceDisplayNamesLoaded, isWorkspaceDisplayNamesLoading, mergeWithDefaultConfig, optifyeAgentClient, preInitializeWorkspaceDisplayNames, preloadS3Video, preloadS3VideoUrl, preloadS3VideosUrl, preloadVideoUrl, preloadVideosUrl, qualityService, realtimeService, refreshWorkspaceDisplayNames, resetCoreMixpanel, s3VideoPreloader, storeWorkspaceMapping, streamProxyConfig, throttledReloadDashboard, toUrlFriendlyName, trackCoreEvent, trackCorePageView, updateThreadTitle, useActiveBreaks, useAnalyticsConfig, useAuth, useAuthConfig, useComponentOverride, useCustomConfig, useDashboardConfig, useDashboardMetrics, useDatabaseConfig, useDateFormatter, useDateTimeConfig, useEndpointsConfig, useEntityConfig, useFactoryOverviewMetrics, useFeatureFlags, useFormatNumber, useHistoricWorkspaceMetrics, useHlsStream, useHlsStreamWithCropping, useHookOverride, useLeaderboardMetrics, useLineDetailedMetrics, useLineKPIs, useLineMetrics, useLineWorkspaceMetrics, useMessages, useMetrics, useNavigation, useOverrides, usePageOverride, useRealtimeLineMetrics, useRegistry, useShiftConfig, useShifts, useSupabase, useSupabaseClient, useTargets, useTheme, useThemeConfig, useThreads, useVideoConfig, useWorkspaceConfig, useWorkspaceDetailedMetrics, useWorkspaceDisplayName, useWorkspaceDisplayNames, useWorkspaceDisplayNamesMap, useWorkspaceMetrics, useWorkspaceNavigation, useWorkspaceOperators, videoPreloader, whatsappService, withAuth, withRegistry, workspaceService };
4608
+ export { ACTION_NAMES, AIAgentView, type Action, type ActionName, type ActionService, type ActionThreshold, type ActiveBreak, type AnalyticsConfig, AuthCallback, type AuthCallbackProps, AuthCallbackView, type AuthCallbackViewProps, type AuthConfig, AuthProvider, type AuthUser, AuthenticatedFactoryView, AuthenticatedHelpView, AuthenticatedHomeView, AuthenticatedTargetsView, BarChart, type BarChartDataItem, type BarChartProps, type BarProps, BaseHistoryCalendar, type BaseHistoryCalendarProps, type BaseLineMetric, type BasePerformanceMetric, type BottleneckFilterType, type BottleneckVideo, type BottleneckVideoData, BottlenecksContent, type BottlenecksContentProps, type BreadcrumbItem, type Break, BreakNotificationPopup, type BreakNotificationPopupProps, type BreakRowProps, Card, CardContent, CardDescription, CardFooter, CardHeader, CardTitle, type ChatMessage, type ChatThread, type ClipCounts, type ComponentOverride, type CoreComponents, type CurrentShiftResult, CycleTimeChart, type CycleTimeChartProps, CycleTimeOverTimeChart, type CycleTimeOverTimeChartProps, DEFAULT_ANALYTICS_CONFIG, DEFAULT_AUTH_CONFIG, DEFAULT_CONFIG, DEFAULT_DATABASE_CONFIG, DEFAULT_DATE_TIME_CONFIG, DEFAULT_ENDPOINTS_CONFIG, DEFAULT_ENTITY_CONFIG, DEFAULT_SHIFT_CONFIG, DEFAULT_THEME_CONFIG, DEFAULT_VIDEO_CONFIG, DEFAULT_WORKSPACE_CONFIG, DEFAULT_WORKSPACE_POSITIONS, type DashboardConfig, DashboardHeader, type DashboardKPIs, DashboardLayout, type DashboardLayoutProps, DashboardOverridesProvider, DashboardProvider, type DashboardService, type DatabaseConfig, DateDisplay, type DateTimeConfig, DateTimeDisplay, type DateTimeDisplayProps, type DayHistoryData, type DaySummaryData, DebugAuth, DebugAuthView, EmptyStateMessage, type EmptyStateMessageProps, type EndpointsConfig, type EntityConfig, type FactoryOverviewData, FactoryView, type FactoryViewProps, type FormatNumberOptions, GaugeChart, type GaugeChartProps, GridComponentsPlaceholder, Header, type HeaderProps, HelpView, type HelpViewProps, type HistoryCalendarProps, HomeView, type HookOverride, HourlyOutputChart, type HourlyOutputChartProps, type HourlyPerformance, type ISTDateProps, ISTTimer, type ISTTimerProps, KPICard, type KPICardProps, KPIDetailView, type KPIDetailViewProps, KPIGrid, type KPIGridProps, KPIHeader, type KPIHeaderProps, KPISection, type KPITrend, KPIsOverviewView, type KPIsOverviewViewProps, LINE_1_UUID, LargeOutputProgressChart, type LargeOutputProgressChartProps, LeaderboardDetailView, type LeaderboardDetailViewProps, type LeaderboardEntry, Legend, LineChart, type LineChartDataItem, type LineChartProps, type LineDetails, type LineDisplayData, LineHistoryCalendar, type LineHistoryCalendarProps, type LineInfo, type LineMetrics, LineMonthlyHistory, type LineMonthlyHistoryProps, type LineMonthlyMetric, LineMonthlyPdfGenerator, type LineMonthlyPdfGeneratorProps, type LineNavigationParams, LinePdfExportButton, type LinePdfExportButtonProps, LinePdfGenerator, type LinePdfGeneratorProps, type LineProps, type LineShiftConfig, type LineSnapshot, type LineThreshold, LineWhatsAppShareButton, type LineWhatsAppShareProps, LiveTimer, LoadingOverlay, LoadingPage, LoadingSpinner, LoginPage, type LoginPageProps, LoginView, type LoginViewProps, MainLayout, type MainLayoutProps, type Metric, MetricCard, type MetricCardProps$1 as MetricCardProps, type MetricsError, type NavItem, type NavItemTrackingEvent, NoWorkspaceData, type OperatorData, type OperatorInfo, OptifyeAgentClient, type OptifyeAgentContext, type OptifyeAgentRequest, type OptifyeAgentResponse, OutputProgressChart, type OutputProgressChartProps, type OverridesMap, type OverviewLineMetric, type OverviewWorkspaceMetric, PageHeader, type PageHeaderProps, type PageOverride, PieChart, type PieChartProps, type PoorPerformingWorkspace, type ProfileMenuItem, ProfileView, type QualityMetric, type QualityOverview, type QualityService, type RateLimitOptions, type RateLimitResult, type RealtimeService, RegistryProvider, type RoutePath, type S3ClipsAPIParams, type S3Config, type S3ListObjectsParams, S3Service, type S3ServiceConfig, SOPComplianceChart, type SOPComplianceChartProps, SSEChatClient, type SSEEvent, Select, SelectContent, SelectGroup, SelectItem, SelectLabel, SelectScrollDownButton, SelectScrollUpButton, SelectSeparator, SelectTrigger, SelectValue, type ShiftConfig, type ShiftConfiguration, type ShiftConfigurationRecord, type ShiftData$2 as ShiftData, ShiftDisplay, type ShiftHistoryData, type ShiftHoursMap, type ShiftPanelProps, type ShiftSummaryData, type ShiftTime, ShiftsView, type ShiftsViewProps, SideNavBar, type SideNavBarProps, type SimpleLine, SingleVideoStream, type SingleVideoStreamProps, Skeleton, SlackAPI, type StreamProxyConfig, type SupabaseClient, SupabaseProvider, type Target, TargetWorkspaceGrid, type TargetWorkspaceGridProps, TargetsView, type TargetsViewProps, type ThemeColorValue, type ThemeConfig, ThreadSidebar, TimeDisplay, TimePickerDropdown, type TrackingEventProperties, type TrendDirection, type UnderperformingWorkspace, type UnderperformingWorkspaces, type UseActiveBreaksResult, type UseDashboardMetricsProps, type UseFactoryOverviewOptions, type UseFormatNumberResult, type UseMessagesResult, type UseRealtimeLineMetricsProps, type UseTargetsOptions, type UseThreadsResult, type UseWorkspaceOperatorsOptions, type UserProfileConfig, VideoCard, type VideoConfig, type VideoCroppingConfig, type VideoCroppingRect, VideoGridView, type VideoMetadata, VideoPreloader, type VideoSeverity, type VideoSummary, type VideoType, WORKSPACE_POSITIONS, type WhatsAppSendResult, WhatsAppShareButton, type WhatsAppShareButtonProps, type WhatsappService, type Workspace, type WorkspaceActionUpdate, WorkspaceCard, type WorkspaceCardProps, type WorkspaceConfig, WrappedComponent as WorkspaceDetailView, type WorkspaceDetailedMetrics, WorkspaceDisplayNameExample, WorkspaceGrid, WorkspaceGridItem, type WorkspaceGridItemProps, WorkspaceHistoryCalendar, WorkspaceMetricCards, type WorkspaceMetricCardsProps, type WorkspaceMetrics, WorkspaceMonthlyDataFetcher, type WorkspaceMonthlyDataFetcherProps, type WorkspaceMonthlyMetric, WorkspaceMonthlyPdfGenerator, type WorkspaceMonthlyPdfGeneratorProps, type WorkspaceNavigationParams, WorkspacePdfExportButton, type WorkspacePdfExportButtonProps, WorkspacePdfGenerator, type WorkspacePdfGeneratorProps, type WorkspacePosition, type WorkspaceQualityData, type WorkspaceUrlMapping, WorkspaceWhatsAppShareButton, type WorkspaceWhatsAppShareProps, actionService, apiUtils, authCoreService, authOTPService, authRateLimitService, checkRateLimit, clearAllRateLimits, clearRateLimit, clearS3VideoCache, clearS3VideoFromCache, clearWorkspaceDisplayNamesCache, clearWorkspaceMappingsForLine, cn, createStreamProxyHandler, createSupabaseClient, createThrottledReload, dashboardService, deleteThread, forceRefreshWorkspaceDisplayNames, formatDateInZone, formatDateTimeInZone, formatISTDate, formatIdleTime, formatTimeInZone, fromUrlFriendlyName, getAllThreadMessages, getAllWorkspaceDisplayNamesAsync, getAnonClient, getCameraNumber, getCompanyMetricsTableName, getConfigurableShortWorkspaceDisplayName, getConfigurableWorkspaceDisplayName, getCurrentShift, getCurrentTimeInZone, getDashboardHeaderTimeInZone, getDaysDifferenceInZone, getDefaultCameraStreamUrl, getDefaultTabForWorkspace, getManufacturingInsights, getMetricsTablePrefix, getOperationalDate, getS3SignedUrl, getS3VideoSrc, getShortWorkspaceDisplayName, getShortWorkspaceDisplayNameAsync, getStoredWorkspaceMappings, getThreadMessages, getUserThreads, getUserThreadsPaginated, getWorkspaceDisplayName, getWorkspaceDisplayNameAsync, getWorkspaceDisplayNamesMap, getWorkspaceFromUrl, getWorkspaceMappingsForLine, getWorkspaceNavigationParams, identifyCoreUser, initializeCoreMixpanel, isTransitionPeriod, isValidLineInfoPayload, isValidWorkspaceDetailedMetricsPayload, isValidWorkspaceMetricsPayload, isWorkspaceDisplayNamesLoaded, isWorkspaceDisplayNamesLoading, mergeWithDefaultConfig, optifyeAgentClient, preInitializeWorkspaceDisplayNames, preloadS3Video, preloadS3VideoUrl, preloadS3VideosUrl, preloadVideoUrl, preloadVideosUrl, qualityService, realtimeService, refreshWorkspaceDisplayNames, resetCoreMixpanel, s3VideoPreloader, storeWorkspaceMapping, streamProxyConfig, throttledReloadDashboard, toUrlFriendlyName, trackCoreEvent, trackCorePageView, updateThreadTitle, useActiveBreaks, useAnalyticsConfig, useAuth, useAuthConfig, useComponentOverride, useCustomConfig, useDashboardConfig, useDashboardMetrics, useDatabaseConfig, useDateFormatter, useDateTimeConfig, useEndpointsConfig, useEntityConfig, useFactoryOverviewMetrics, useFeatureFlags, useFormatNumber, useHistoricWorkspaceMetrics, useHlsStream, useHlsStreamWithCropping, useHookOverride, useLeaderboardMetrics, useLineDetailedMetrics, useLineKPIs, useLineMetrics, useLineWorkspaceMetrics, useMessages, useMetrics, useNavigation, useOverrides, usePageOverride, useRealtimeLineMetrics, useRegistry, useShiftConfig, useShifts, useSupabase, useSupabaseClient, useTargets, useTheme, useThemeConfig, useThreads, useVideoConfig, useWorkspaceConfig, useWorkspaceDetailedMetrics, useWorkspaceDisplayName, useWorkspaceDisplayNames, useWorkspaceDisplayNamesMap, useWorkspaceMetrics, useWorkspaceNavigation, useWorkspaceOperators, videoPreloader, whatsappService, withAuth, withRegistry, workspaceService };