@optifye/dashboard-core 6.12.41 → 6.12.43
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 +22 -2
- package/dist/index.d.ts +22 -2
- package/dist/index.js +195 -34
- package/dist/index.mjs +195 -35
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -14926,12 +14926,14 @@ var logDebug = (...args) => {
|
|
|
14926
14926
|
if (!DEBUG_DASHBOARD_LOGS) return;
|
|
14927
14927
|
console.log(...args);
|
|
14928
14928
|
};
|
|
14929
|
-
var buildMetricsScopeKey = (lineId, lineIds, blueComparisonLineIds) => {
|
|
14929
|
+
var buildMetricsScopeKey = (lineId, lineIds, blueComparisonLineIds, selectorLineIds) => {
|
|
14930
14930
|
const normalizedLineIds = Array.from(new Set((lineIds || []).filter(Boolean))).sort();
|
|
14931
14931
|
const normalizedBlueComparisonLineIds = Array.from(new Set((blueComparisonLineIds || []).filter(Boolean))).sort();
|
|
14932
|
+
const normalizedSelectorLineIds = Array.from(new Set((selectorLineIds || []).filter(Boolean))).sort();
|
|
14932
14933
|
const lineKey = normalizedLineIds.length > 0 ? normalizedLineIds.join(",") : lineId;
|
|
14933
14934
|
const comparisonKey = normalizedBlueComparisonLineIds.length > 0 ? normalizedBlueComparisonLineIds.join(",") : lineKey;
|
|
14934
|
-
|
|
14935
|
+
const selectorKey = normalizedSelectorLineIds.length > 0 ? normalizedSelectorLineIds.join(",") : "";
|
|
14936
|
+
return `${lineId}|${lineKey}|blue:${comparisonKey}|selector:${selectorKey}`;
|
|
14935
14937
|
};
|
|
14936
14938
|
var parseEfficiencyLegend = (legend) => {
|
|
14937
14939
|
if (!legend) return null;
|
|
@@ -14954,6 +14956,7 @@ var useDashboardMetrics = ({
|
|
|
14954
14956
|
lineId,
|
|
14955
14957
|
lineIds,
|
|
14956
14958
|
blueComparisonLineIds,
|
|
14959
|
+
selectorLineIds,
|
|
14957
14960
|
userAccessibleLineIds,
|
|
14958
14961
|
enabled = true
|
|
14959
14962
|
}) => {
|
|
@@ -14980,6 +14983,10 @@ var useDashboardMetrics = ({
|
|
|
14980
14983
|
() => Array.from(new Set((blueComparisonLineIds || []).filter(Boolean))),
|
|
14981
14984
|
[blueComparisonLineIds]
|
|
14982
14985
|
);
|
|
14986
|
+
const normalizedSelectorLineIds = React147.useMemo(
|
|
14987
|
+
() => Array.from(new Set((selectorLineIds || []).filter(Boolean))),
|
|
14988
|
+
[selectorLineIds]
|
|
14989
|
+
);
|
|
14983
14990
|
const { shiftConfig: staticShiftConfig } = useDashboardConfig();
|
|
14984
14991
|
const {
|
|
14985
14992
|
shiftConfigMap: multiLineShiftConfigMap,
|
|
@@ -15015,9 +15022,9 @@ var useDashboardMetrics = ({
|
|
|
15015
15022
|
const configuredLineMetricsTable = databaseConfig?.tables?.lineMetrics ?? "line_metrics";
|
|
15016
15023
|
const schema = databaseConfig?.schema ?? "public";
|
|
15017
15024
|
const supabase = useSupabase();
|
|
15018
|
-
const [metrics2, setMetrics] = React147.useState({ workspaceMetrics: [], lineMetrics: [] });
|
|
15025
|
+
const [metrics2, setMetrics] = React147.useState({ workspaceMetrics: [], lineMetrics: [], selectorLineMetrics: [] });
|
|
15019
15026
|
const [metricsLineId, setMetricsLineId] = React147.useState(lineId ?? null);
|
|
15020
|
-
const [metricsScopeKey, setMetricsScopeKey] = React147.useState(() => buildMetricsScopeKey(lineId, lineIds, blueComparisonLineIds));
|
|
15027
|
+
const [metricsScopeKey, setMetricsScopeKey] = React147.useState(() => buildMetricsScopeKey(lineId, lineIds, blueComparisonLineIds, selectorLineIds));
|
|
15021
15028
|
const [isLoading, setIsLoading] = React147.useState(true);
|
|
15022
15029
|
const [error, setError] = React147.useState(null);
|
|
15023
15030
|
const lineIdRef = React147.useRef(lineId);
|
|
@@ -15036,6 +15043,7 @@ var useDashboardMetrics = ({
|
|
|
15036
15043
|
const configuredLineIdsRef = React147.useRef(configuredLineIds);
|
|
15037
15044
|
const userAccessibleLineIdsRef = React147.useRef(userAccessibleLineIds);
|
|
15038
15045
|
const explicitLineIdsRef = React147.useRef(lineIds);
|
|
15046
|
+
const selectorLineIdsRef = React147.useRef(selectorLineIds);
|
|
15039
15047
|
React147.useEffect(() => {
|
|
15040
15048
|
onLineMetricsUpdateRef.current = onLineMetricsUpdate;
|
|
15041
15049
|
}, [onLineMetricsUpdate]);
|
|
@@ -15054,6 +15062,9 @@ var useDashboardMetrics = ({
|
|
|
15054
15062
|
React147.useEffect(() => {
|
|
15055
15063
|
explicitLineIdsRef.current = lineIds;
|
|
15056
15064
|
}, [lineIds]);
|
|
15065
|
+
React147.useEffect(() => {
|
|
15066
|
+
selectorLineIdsRef.current = selectorLineIds;
|
|
15067
|
+
}, [selectorLineIds]);
|
|
15057
15068
|
const companySpecificMetricsTable = React147.useMemo(
|
|
15058
15069
|
() => getCompanyMetricsTableName(entityConfig.companyId, "performance_metrics"),
|
|
15059
15070
|
[entityConfig.companyId]
|
|
@@ -15062,9 +15073,10 @@ var useDashboardMetrics = ({
|
|
|
15062
15073
|
() => buildMetricsScopeKey(
|
|
15063
15074
|
lineId,
|
|
15064
15075
|
isFactoryView ? targetFactoryLineIds : void 0,
|
|
15065
|
-
normalizedBlueComparisonLineIds.length ? normalizedBlueComparisonLineIds : void 0
|
|
15076
|
+
normalizedBlueComparisonLineIds.length ? normalizedBlueComparisonLineIds : void 0,
|
|
15077
|
+
normalizedSelectorLineIds.length ? normalizedSelectorLineIds : void 0
|
|
15066
15078
|
),
|
|
15067
|
-
[isFactoryView, lineId, targetFactoryLineIds, normalizedBlueComparisonLineIds]
|
|
15079
|
+
[isFactoryView, lineId, targetFactoryLineIds, normalizedBlueComparisonLineIds, normalizedSelectorLineIds]
|
|
15068
15080
|
);
|
|
15069
15081
|
React147.useEffect(() => {
|
|
15070
15082
|
lineIdRef.current = lineId;
|
|
@@ -15096,13 +15108,15 @@ var useDashboardMetrics = ({
|
|
|
15096
15108
|
const targetLineIdsKey = targetLineIds.slice().sort().join(",");
|
|
15097
15109
|
const effectiveBlueComparisonLineIds = normalizedBlueComparisonLineIds.length ? normalizedBlueComparisonLineIds : targetLineIds;
|
|
15098
15110
|
const blueComparisonLineIdsKey = effectiveBlueComparisonLineIds.slice().sort().join(",");
|
|
15111
|
+
const selectorLineIdsKey = normalizedSelectorLineIds.slice().sort().join(",");
|
|
15099
15112
|
const usesShiftGroups = isFactory && shiftGroups.length > 0;
|
|
15100
15113
|
const singleShiftDetails = usesShiftGroups ? null : shiftConfig ? getCurrentShift(defaultTimezone, shiftConfig) : shiftGroups.length === 1 ? { date: shiftGroups[0].date, shiftId: shiftGroups[0].shiftId } : getCurrentShift(defaultTimezone, staticShiftConfig);
|
|
15101
|
-
const fetchKey = usesShiftGroups ? `factory|${companyId || "unknown"}|${shiftGroupsKey}|blue:${blueComparisonLineIdsKey}` : isFactory ? `factory|${companyId || "unknown"}|${singleShiftDetails?.date}|${singleShiftDetails?.shiftId}|${targetLineIdsKey}|blue:${blueComparisonLineIdsKey}` : `${currentLineIdToUse}|${companyId || "unknown"}|${singleShiftDetails?.date}|${singleShiftDetails?.shiftId}|blue:${blueComparisonLineIdsKey}`;
|
|
15114
|
+
const fetchKey = usesShiftGroups ? `factory|${companyId || "unknown"}|${shiftGroupsKey}|blue:${blueComparisonLineIdsKey}|selector:${selectorLineIdsKey}` : isFactory ? `factory|${companyId || "unknown"}|${singleShiftDetails?.date}|${singleShiftDetails?.shiftId}|${targetLineIdsKey}|blue:${blueComparisonLineIdsKey}|selector:${selectorLineIdsKey}` : `${currentLineIdToUse}|${companyId || "unknown"}|${singleShiftDetails?.date}|${singleShiftDetails?.shiftId}|blue:${blueComparisonLineIdsKey}|selector:${selectorLineIdsKey}`;
|
|
15102
15115
|
const responseScopeKey = buildMetricsScopeKey(
|
|
15103
15116
|
currentLineIdToUse,
|
|
15104
15117
|
isFactory ? targetLineIds : void 0,
|
|
15105
|
-
normalizedBlueComparisonLineIds.length ? normalizedBlueComparisonLineIds : void 0
|
|
15118
|
+
normalizedBlueComparisonLineIds.length ? normalizedBlueComparisonLineIds : void 0,
|
|
15119
|
+
normalizedSelectorLineIds.length ? normalizedSelectorLineIds : void 0
|
|
15106
15120
|
);
|
|
15107
15121
|
logDebug("[useDashboardMetrics] Fetch key details:", {
|
|
15108
15122
|
isFactory,
|
|
@@ -15134,6 +15148,7 @@ var useDashboardMetrics = ({
|
|
|
15134
15148
|
workspaceMetrics: [],
|
|
15135
15149
|
blueComparisonWorkspaceMetrics: [],
|
|
15136
15150
|
lineMetrics: [],
|
|
15151
|
+
selectorLineMetrics: [],
|
|
15137
15152
|
metadata: void 0,
|
|
15138
15153
|
efficiencyLegend: DEFAULT_EFFICIENCY_LEGEND
|
|
15139
15154
|
});
|
|
@@ -15145,6 +15160,7 @@ var useDashboardMetrics = ({
|
|
|
15145
15160
|
let allWorkspaceMetrics = [];
|
|
15146
15161
|
let allBlueComparisonWorkspaceMetrics = [];
|
|
15147
15162
|
let allLineMetrics = [];
|
|
15163
|
+
let allSelectorLineMetrics = [];
|
|
15148
15164
|
let hasFlowBuffers = false;
|
|
15149
15165
|
let idleTimeVlmByLine = {};
|
|
15150
15166
|
let efficiencyLegend;
|
|
@@ -15154,7 +15170,8 @@ var useDashboardMetrics = ({
|
|
|
15154
15170
|
const buildMetricsEndpoint = (params) => {
|
|
15155
15171
|
const lineIdsParam = isFactory ? `line_ids=${params.groupLineIds.join(",")}` : `line_id=${params.groupLineIds[0]}`;
|
|
15156
15172
|
const blueComparisonParam = effectiveBlueComparisonLineIds.length ? `&blue_comparison_line_ids=${effectiveBlueComparisonLineIds.join(",")}` : "";
|
|
15157
|
-
|
|
15173
|
+
const selectorParam = normalizedSelectorLineIds.length ? `&selector_line_ids=${encodeURIComponent(normalizedSelectorLineIds.join(","))}` : "";
|
|
15174
|
+
return `/api/dashboard/metrics?${lineIdsParam}${blueComparisonParam}${selectorParam}&date=${params.date}&shift_id=${params.shiftId}&company_id=${companyId}${forceParam}${qaGreenStreakParams}`;
|
|
15158
15175
|
};
|
|
15159
15176
|
if (usesShiftGroups) {
|
|
15160
15177
|
logDebug("[useDashboardMetrics] Factory view shift groups fetch:", {
|
|
@@ -15210,6 +15227,9 @@ var useDashboardMetrics = ({
|
|
|
15210
15227
|
if (result.line_metrics) {
|
|
15211
15228
|
allLineMetrics.push(...result.line_metrics);
|
|
15212
15229
|
}
|
|
15230
|
+
if (result.selector_line_metrics) {
|
|
15231
|
+
allSelectorLineMetrics.push(...result.selector_line_metrics);
|
|
15232
|
+
}
|
|
15213
15233
|
});
|
|
15214
15234
|
if (allBlueComparisonWorkspaceMetrics.length === 0) {
|
|
15215
15235
|
allBlueComparisonWorkspaceMetrics = allWorkspaceMetrics;
|
|
@@ -15253,6 +15273,7 @@ var useDashboardMetrics = ({
|
|
|
15253
15273
|
allWorkspaceMetrics = backendData.workspace_metrics || [];
|
|
15254
15274
|
allBlueComparisonWorkspaceMetrics = backendData.blue_comparison_workspace_metrics || allWorkspaceMetrics;
|
|
15255
15275
|
allLineMetrics = backendData.line_metrics || [];
|
|
15276
|
+
allSelectorLineMetrics = backendData.selector_line_metrics || [];
|
|
15256
15277
|
hasFlowBuffers = Boolean(backendData?.metadata?.has_flow_buffers);
|
|
15257
15278
|
if (backendData?.metadata?.idle_time_vlm_by_line && typeof backendData.metadata.idle_time_vlm_by_line === "object") {
|
|
15258
15279
|
idleTimeVlmByLine = backendData.metadata.idle_time_vlm_by_line;
|
|
@@ -15284,6 +15305,7 @@ var useDashboardMetrics = ({
|
|
|
15284
15305
|
workspaceMetrics: transformedWorkspaceData,
|
|
15285
15306
|
blueComparisonWorkspaceMetrics: transformedBlueComparisonWorkspaceData.length ? transformedBlueComparisonWorkspaceData : transformedWorkspaceData,
|
|
15286
15307
|
lineMetrics: allLineMetrics || [],
|
|
15308
|
+
selectorLineMetrics: allSelectorLineMetrics || [],
|
|
15287
15309
|
metadata: { hasFlowBuffers, idleTimeVlmByLine },
|
|
15288
15310
|
efficiencyLegend: efficiencyLegend ?? DEFAULT_EFFICIENCY_LEGEND
|
|
15289
15311
|
};
|
|
@@ -15354,6 +15376,7 @@ var useDashboardMetrics = ({
|
|
|
15354
15376
|
configuredLineIds,
|
|
15355
15377
|
targetFactoryLineIds,
|
|
15356
15378
|
normalizedBlueComparisonLineIds,
|
|
15379
|
+
normalizedSelectorLineIds,
|
|
15357
15380
|
isFactoryView,
|
|
15358
15381
|
multiLineShiftConfigMap,
|
|
15359
15382
|
staticShiftConfig,
|
|
@@ -15470,7 +15493,8 @@ var useDashboardMetrics = ({
|
|
|
15470
15493
|
const isFactory = lineId === (entityConfig.factoryViewId || "factory");
|
|
15471
15494
|
if (isFactory && shiftGroups.length === 0) return null;
|
|
15472
15495
|
const shiftGroupsKeyPart = isFactory ? shiftGroups.map((g) => `${g.date}-${g.shiftId}-${g.lineIds.join("_")}`).join("|") : operationalShiftKey;
|
|
15473
|
-
|
|
15496
|
+
const selectorLineIdsKeyPart = (selectorLineIds || []).filter(Boolean).slice().sort().join(",");
|
|
15497
|
+
return `${lineId}|${entityConfig.companyId}|${shiftGroupsKeyPart}|selector:${selectorLineIdsKeyPart}`;
|
|
15474
15498
|
}, [
|
|
15475
15499
|
enabled,
|
|
15476
15500
|
supabase,
|
|
@@ -15480,7 +15504,8 @@ var useDashboardMetrics = ({
|
|
|
15480
15504
|
shiftLoading,
|
|
15481
15505
|
isTimezoneLoading,
|
|
15482
15506
|
shiftGroups,
|
|
15483
|
-
operationalShiftKey
|
|
15507
|
+
operationalShiftKey,
|
|
15508
|
+
selectorLineIds
|
|
15484
15509
|
]);
|
|
15485
15510
|
React147.useEffect(() => {
|
|
15486
15511
|
const currentLineIdToUse = lineIdRef.current;
|
|
@@ -15517,7 +15542,7 @@ var useDashboardMetrics = ({
|
|
|
15517
15542
|
});
|
|
15518
15543
|
const targetFactoryLineIdsForSubscriptions = explicitLineIdsRef.current !== void 0 ? explicitLineIdsRef.current : currentUserAccessibleLineIds !== void 0 ? currentUserAccessibleLineIds : currentConfiguredLineIds;
|
|
15519
15544
|
const targetFactoryLineIdSet = new Set(
|
|
15520
|
-
|
|
15545
|
+
[...targetFactoryLineIdsForSubscriptions || [], ...selectorLineIdsRef.current || []].filter(Boolean)
|
|
15521
15546
|
);
|
|
15522
15547
|
currentShiftGroups.forEach((group, index) => {
|
|
15523
15548
|
const groupLineIds = group.lineIds.filter(
|
|
@@ -15687,7 +15712,10 @@ var useDashboardMetrics = ({
|
|
|
15687
15712
|
const currentShiftDetails = shiftConfig ? getCurrentShift(defaultTimezone, shiftConfig) : getCurrentShift(defaultTimezone, staticShiftConfig);
|
|
15688
15713
|
const operationalDateForSubscription = currentShiftDetails.date;
|
|
15689
15714
|
const targetLineIds = isFactory ? explicitLineIdsRef.current || currentUserAccessibleLineIds || currentConfiguredLineIds : [currentLineIdToUse];
|
|
15690
|
-
const filteredLineIds =
|
|
15715
|
+
const filteredLineIds = Array.from(/* @__PURE__ */ new Set([
|
|
15716
|
+
...targetLineIds,
|
|
15717
|
+
...selectorLineIdsRef.current || []
|
|
15718
|
+
])).filter((id3) => id3 && id3 !== factoryViewIdentifier);
|
|
15691
15719
|
if (filteredLineIds.length === 0) {
|
|
15692
15720
|
logDebug("[useDashboardMetrics] Realtime setup skipped: no line IDs after filtering", {
|
|
15693
15721
|
targetLineIds,
|
|
@@ -15794,11 +15822,12 @@ var useDashboardMetrics = ({
|
|
|
15794
15822
|
const isCurrentScopeResolved = metricsScopeKey === requestedScopeKey;
|
|
15795
15823
|
const hasLastGoodMetrics = metrics2.workspaceMetrics.length > 0 || metrics2.lineMetrics.length > 0;
|
|
15796
15824
|
const canReuseLastGoodMetrics = hasLastGoodMetrics && !isCurrentScopeResolved && (isLoading || !!error);
|
|
15797
|
-
const safeMetrics = isCurrentScopeResolved || canReuseLastGoodMetrics ? metrics2 : { workspaceMetrics: [], blueComparisonWorkspaceMetrics: [], lineMetrics: [], metadata: void 0, efficiencyLegend: DEFAULT_EFFICIENCY_LEGEND };
|
|
15825
|
+
const safeMetrics = isCurrentScopeResolved || canReuseLastGoodMetrics ? metrics2 : { workspaceMetrics: [], blueComparisonWorkspaceMetrics: [], lineMetrics: [], selectorLineMetrics: [], metadata: void 0, efficiencyLegend: DEFAULT_EFFICIENCY_LEGEND };
|
|
15798
15826
|
return {
|
|
15799
15827
|
workspaceMetrics: safeMetrics?.workspaceMetrics || [],
|
|
15800
15828
|
blueComparisonWorkspaceMetrics: safeMetrics?.blueComparisonWorkspaceMetrics || safeMetrics?.workspaceMetrics || [],
|
|
15801
15829
|
lineMetrics: safeMetrics?.lineMetrics || [],
|
|
15830
|
+
selectorLineMetrics: safeMetrics?.selectorLineMetrics || [],
|
|
15802
15831
|
efficiencyLegend: safeMetrics?.efficiencyLegend || DEFAULT_EFFICIENCY_LEGEND,
|
|
15803
15832
|
metadata: safeMetrics?.metadata,
|
|
15804
15833
|
isLoading: enabled ? isLoading || !isCurrentScopeResolved && !canReuseLastGoodMetrics : false,
|
|
@@ -20143,6 +20172,77 @@ var useWorkspaceHourSummary = () => {
|
|
|
20143
20172
|
reset
|
|
20144
20173
|
};
|
|
20145
20174
|
};
|
|
20175
|
+
function useCompanyWorkspaceHourAiSummaryEnabled(companyId) {
|
|
20176
|
+
const { user, loading } = useAuth();
|
|
20177
|
+
const supabase = useSupabase();
|
|
20178
|
+
const company = user?.company || user?.properties?.company;
|
|
20179
|
+
const authCompanyId = company?.id || (typeof user?.company_id === "string" ? user.company_id : void 0) || (typeof user?.properties?.company_id === "string" ? user.properties.company_id : void 0);
|
|
20180
|
+
const targetCompanyId = companyId || authCompanyId || null;
|
|
20181
|
+
const authExplicitValue = company?.features?.workspace_hour_ai_summary;
|
|
20182
|
+
const canUseAuthCompanyFlag = Boolean(
|
|
20183
|
+
targetCompanyId && authCompanyId && targetCompanyId === authCompanyId
|
|
20184
|
+
);
|
|
20185
|
+
const [remoteFlag, setRemoteFlag] = React147.useState(null);
|
|
20186
|
+
React147.useEffect(() => {
|
|
20187
|
+
if (loading || !targetCompanyId || canUseAuthCompanyFlag) {
|
|
20188
|
+
setRemoteFlag(null);
|
|
20189
|
+
return;
|
|
20190
|
+
}
|
|
20191
|
+
let cancelled = false;
|
|
20192
|
+
setRemoteFlag(null);
|
|
20193
|
+
fetchBackendJson(
|
|
20194
|
+
supabase,
|
|
20195
|
+
`/api/dashboard/company-features?company_id=${encodeURIComponent(targetCompanyId)}`,
|
|
20196
|
+
{
|
|
20197
|
+
timeoutMs: 1e4,
|
|
20198
|
+
retries: 0,
|
|
20199
|
+
sentry: {
|
|
20200
|
+
surface: "workspace_hour_ai_summary_feature_flag",
|
|
20201
|
+
route: "/api/dashboard/company-features"
|
|
20202
|
+
}
|
|
20203
|
+
}
|
|
20204
|
+
).then((response) => {
|
|
20205
|
+
if (cancelled) return;
|
|
20206
|
+
setRemoteFlag({
|
|
20207
|
+
companyId: targetCompanyId,
|
|
20208
|
+
enabled: response.features?.workspace_hour_ai_summary === true
|
|
20209
|
+
});
|
|
20210
|
+
}).catch(() => {
|
|
20211
|
+
if (cancelled) return;
|
|
20212
|
+
setRemoteFlag({
|
|
20213
|
+
companyId: targetCompanyId,
|
|
20214
|
+
enabled: false
|
|
20215
|
+
});
|
|
20216
|
+
});
|
|
20217
|
+
return () => {
|
|
20218
|
+
cancelled = true;
|
|
20219
|
+
};
|
|
20220
|
+
}, [canUseAuthCompanyFlag, loading, supabase, targetCompanyId]);
|
|
20221
|
+
return React147.useMemo(() => {
|
|
20222
|
+
if (!targetCompanyId) {
|
|
20223
|
+
return {
|
|
20224
|
+
isWorkspaceHourAiSummaryEnabled: false,
|
|
20225
|
+
isResolved: !loading
|
|
20226
|
+
};
|
|
20227
|
+
}
|
|
20228
|
+
if (canUseAuthCompanyFlag) {
|
|
20229
|
+
return {
|
|
20230
|
+
isWorkspaceHourAiSummaryEnabled: authExplicitValue === true,
|
|
20231
|
+
isResolved: !loading || typeof authExplicitValue === "boolean"
|
|
20232
|
+
};
|
|
20233
|
+
}
|
|
20234
|
+
if (remoteFlag?.companyId === targetCompanyId) {
|
|
20235
|
+
return {
|
|
20236
|
+
isWorkspaceHourAiSummaryEnabled: remoteFlag.enabled,
|
|
20237
|
+
isResolved: true
|
|
20238
|
+
};
|
|
20239
|
+
}
|
|
20240
|
+
return {
|
|
20241
|
+
isWorkspaceHourAiSummaryEnabled: false,
|
|
20242
|
+
isResolved: false
|
|
20243
|
+
};
|
|
20244
|
+
}, [authExplicitValue, canUseAuthCompanyFlag, loading, remoteFlag, targetCompanyId]);
|
|
20245
|
+
}
|
|
20146
20246
|
var MAX_RETRIES = 10;
|
|
20147
20247
|
var RETRY_DELAY = 500;
|
|
20148
20248
|
function useNavigation(customNavigate) {
|
|
@@ -65610,6 +65710,7 @@ var createEmptyState = () => ({
|
|
|
65610
65710
|
workspaceMetrics: [],
|
|
65611
65711
|
blueComparisonWorkspaceMetrics: [],
|
|
65612
65712
|
lineMetrics: [],
|
|
65713
|
+
selectorLineMetrics: [],
|
|
65613
65714
|
kpiTrend: null,
|
|
65614
65715
|
activeBreaks: [],
|
|
65615
65716
|
videoStreamsByWorkspaceId: {},
|
|
@@ -65623,7 +65724,7 @@ var normalizeMetadata = (metadata) => ({
|
|
|
65623
65724
|
cacheStatus: metadata?.cache_status,
|
|
65624
65725
|
warnings: metadata?.warnings ?? []
|
|
65625
65726
|
});
|
|
65626
|
-
var createResolvedScopeLookup = (resolvedScope, workspaces, blueComparisonWorkspaces) => {
|
|
65727
|
+
var createResolvedScopeLookup = (resolvedScope, workspaces, blueComparisonWorkspaces, selectorLineMetrics) => {
|
|
65627
65728
|
const lookup = /* @__PURE__ */ new Set();
|
|
65628
65729
|
const addEntry = (lineId, date, shiftId) => {
|
|
65629
65730
|
if (!lineId || !date || shiftId === void 0 || shiftId === null) return;
|
|
@@ -65632,11 +65733,13 @@ var createResolvedScopeLookup = (resolvedScope, workspaces, blueComparisonWorksp
|
|
|
65632
65733
|
resolvedScope.forEach((entry) => addEntry(entry.line_id, entry.date, entry.shift_id));
|
|
65633
65734
|
workspaces.forEach((workspace) => addEntry(workspace.line_id, workspace.date, workspace.shift_id));
|
|
65634
65735
|
blueComparisonWorkspaces.forEach((workspace) => addEntry(workspace.line_id, workspace.date, workspace.shift_id));
|
|
65736
|
+
selectorLineMetrics.forEach((lineMetric) => addEntry(lineMetric.line_id, lineMetric.date, lineMetric.shift_id));
|
|
65635
65737
|
return lookup;
|
|
65636
65738
|
};
|
|
65637
65739
|
var useLiveMonitorBootstrap = ({
|
|
65638
65740
|
lineIds,
|
|
65639
65741
|
blueComparisonLineIds,
|
|
65742
|
+
selectorLineIds,
|
|
65640
65743
|
companyId,
|
|
65641
65744
|
enabled = true,
|
|
65642
65745
|
appTimezone,
|
|
@@ -65652,6 +65755,7 @@ var useLiveMonitorBootstrap = ({
|
|
|
65652
65755
|
const effectiveTimezone = appTimezone || "Asia/Kolkata";
|
|
65653
65756
|
const rawLineIdsKey = (lineIds || []).filter(Boolean).join(",");
|
|
65654
65757
|
const rawBlueComparisonLineIdsKey = (blueComparisonLineIds || lineIds || []).filter(Boolean).join(",");
|
|
65758
|
+
const rawSelectorLineIdsKey = (selectorLineIds || []).filter(Boolean).join(",");
|
|
65655
65759
|
const normalizedLineIds = React147.useMemo(
|
|
65656
65760
|
() => Array.from(new Set(rawLineIdsKey ? rawLineIdsKey.split(",") : [])),
|
|
65657
65761
|
[rawLineIdsKey]
|
|
@@ -65660,13 +65764,17 @@ var useLiveMonitorBootstrap = ({
|
|
|
65660
65764
|
() => Array.from(new Set(rawBlueComparisonLineIdsKey ? rawBlueComparisonLineIdsKey.split(",") : [])),
|
|
65661
65765
|
[rawBlueComparisonLineIdsKey]
|
|
65662
65766
|
);
|
|
65767
|
+
const normalizedSelectorLineIds = React147.useMemo(
|
|
65768
|
+
() => Array.from(new Set(rawSelectorLineIdsKey ? rawSelectorLineIdsKey.split(",") : [])),
|
|
65769
|
+
[rawSelectorLineIdsKey]
|
|
65770
|
+
);
|
|
65663
65771
|
const realtimeLineIds = React147.useMemo(
|
|
65664
|
-
() => Array.from(new Set([...normalizedLineIds, ...normalizedBlueComparisonLineIds].filter(Boolean))).sort(),
|
|
65665
|
-
[normalizedLineIds, normalizedBlueComparisonLineIds]
|
|
65772
|
+
() => Array.from(new Set([...normalizedLineIds, ...normalizedBlueComparisonLineIds, ...normalizedSelectorLineIds].filter(Boolean))).sort(),
|
|
65773
|
+
[normalizedLineIds, normalizedBlueComparisonLineIds, normalizedSelectorLineIds]
|
|
65666
65774
|
);
|
|
65667
65775
|
const requestKey = React147.useMemo(
|
|
65668
|
-
() => `${normalizedLineIds.slice().sort().join(",")}|blue:${normalizedBlueComparisonLineIds.slice().sort().join(",")}`,
|
|
65669
|
-
[normalizedLineIds, normalizedBlueComparisonLineIds]
|
|
65776
|
+
() => `${normalizedLineIds.slice().sort().join(",")}|blue:${normalizedBlueComparisonLineIds.slice().sort().join(",")}|selector:${normalizedSelectorLineIds.slice().sort().join(",")}`,
|
|
65777
|
+
[normalizedLineIds, normalizedBlueComparisonLineIds, normalizedSelectorLineIds]
|
|
65670
65778
|
);
|
|
65671
65779
|
const realtimeLineIdsKey = React147.useMemo(() => realtimeLineIds.join(","), [realtimeLineIds]);
|
|
65672
65780
|
const companySpecificMetricsTable = React147.useMemo(
|
|
@@ -65698,6 +65806,9 @@ var useLiveMonitorBootstrap = ({
|
|
|
65698
65806
|
if (normalizedBlueComparisonLineIds.length) {
|
|
65699
65807
|
searchParams.set("blue_comparison_line_ids", normalizedBlueComparisonLineIds.join(","));
|
|
65700
65808
|
}
|
|
65809
|
+
if (normalizedSelectorLineIds.length) {
|
|
65810
|
+
searchParams.set("selector_line_ids", normalizedSelectorLineIds.join(","));
|
|
65811
|
+
}
|
|
65701
65812
|
if (force) {
|
|
65702
65813
|
searchParams.set("force_refresh", "true");
|
|
65703
65814
|
}
|
|
@@ -65731,6 +65842,7 @@ var useLiveMonitorBootstrap = ({
|
|
|
65731
65842
|
company_id: resolvedCompanyId,
|
|
65732
65843
|
line_ids: normalizedLineIds,
|
|
65733
65844
|
blue_comparison_line_ids: normalizedBlueComparisonLineIds,
|
|
65845
|
+
selector_line_ids: normalizedSelectorLineIds,
|
|
65734
65846
|
force_refresh: force,
|
|
65735
65847
|
pathname: typeof window !== "undefined" ? window.location.pathname : "unknown"
|
|
65736
65848
|
}
|
|
@@ -65748,6 +65860,7 @@ var useLiveMonitorBootstrap = ({
|
|
|
65748
65860
|
resolvedCompanyId,
|
|
65749
65861
|
normalizedLineIds,
|
|
65750
65862
|
normalizedBlueComparisonLineIds,
|
|
65863
|
+
normalizedSelectorLineIds,
|
|
65751
65864
|
requestKey
|
|
65752
65865
|
]);
|
|
65753
65866
|
const fetchBootstrapRef = React147.useRef(fetchBootstrap);
|
|
@@ -65859,6 +65972,7 @@ var useLiveMonitorBootstrap = ({
|
|
|
65859
65972
|
workspaceMetrics,
|
|
65860
65973
|
blueComparisonWorkspaceMetrics: blueComparisonWorkspaceMetrics.length ? blueComparisonWorkspaceMetrics : workspaceMetrics,
|
|
65861
65974
|
lineMetrics: rawState.response.line_metrics || [],
|
|
65975
|
+
selectorLineMetrics: rawState.response.selector_line_metrics || [],
|
|
65862
65976
|
kpiTrend: rawState.response.kpi_trend || null,
|
|
65863
65977
|
activeBreaks,
|
|
65864
65978
|
videoStreamsByWorkspaceId,
|
|
@@ -65895,8 +66009,9 @@ var useLiveMonitorBootstrap = ({
|
|
|
65895
66009
|
const realtimeScopeKey = React147.useMemo(() => Array.from(createResolvedScopeLookup(
|
|
65896
66010
|
state.resolvedScope,
|
|
65897
66011
|
state.workspaceMetrics,
|
|
65898
|
-
state.blueComparisonWorkspaceMetrics
|
|
65899
|
-
|
|
66012
|
+
state.blueComparisonWorkspaceMetrics,
|
|
66013
|
+
state.selectorLineMetrics
|
|
66014
|
+
)).sort().join("||"), [state.resolvedScope, state.workspaceMetrics, state.blueComparisonWorkspaceMetrics, state.selectorLineMetrics]);
|
|
65900
66015
|
React147.useEffect(() => {
|
|
65901
66016
|
if (!enabled || !resolvedCompanyId || !realtimeLineIdsKey || !supabase) {
|
|
65902
66017
|
return void 0;
|
|
@@ -66002,6 +66117,7 @@ var useLiveMonitorBootstrap = ({
|
|
|
66002
66117
|
workspaceMetrics: state.workspaceMetrics,
|
|
66003
66118
|
blueComparisonWorkspaceMetrics: state.blueComparisonWorkspaceMetrics,
|
|
66004
66119
|
lineMetrics: state.lineMetrics,
|
|
66120
|
+
selectorLineMetrics: state.selectorLineMetrics,
|
|
66005
66121
|
kpiTrend: state.kpiTrend,
|
|
66006
66122
|
activeBreaks: state.activeBreaks,
|
|
66007
66123
|
videoStreamsByWorkspaceId: state.videoStreamsByWorkspaceId,
|
|
@@ -66516,6 +66632,7 @@ function HomeView({
|
|
|
66516
66632
|
workspaceMetrics: legacyWorkspaceMetrics,
|
|
66517
66633
|
blueComparisonWorkspaceMetrics: legacyMetricsBlueComparisonWorkspaceMetrics,
|
|
66518
66634
|
lineMetrics: legacyLineMetrics,
|
|
66635
|
+
selectorLineMetrics: legacySelectorLineMetrics = [],
|
|
66519
66636
|
efficiencyLegend: legacyEfficiencyLegend,
|
|
66520
66637
|
metadata: legacyMetricsMetadata,
|
|
66521
66638
|
isLoading: legacyMetricsLoading,
|
|
@@ -66526,6 +66643,7 @@ function HomeView({
|
|
|
66526
66643
|
lineId: metricsScopeLineId,
|
|
66527
66644
|
lineIds: selectedLineIds,
|
|
66528
66645
|
blueComparisonLineIds,
|
|
66646
|
+
selectorLineIds: visibleLineIds,
|
|
66529
66647
|
onLineMetricsUpdate: handleLineMetricsUpdate,
|
|
66530
66648
|
userAccessibleLineIds: visibleLineIds,
|
|
66531
66649
|
enabled: shouldEnableMetricsFetch && !isBootstrapMonitorMode
|
|
@@ -66581,6 +66699,7 @@ function HomeView({
|
|
|
66581
66699
|
const bootstrapMonitor = useLiveMonitorBootstrap({
|
|
66582
66700
|
lineIds: selectedLineIds,
|
|
66583
66701
|
blueComparisonLineIds,
|
|
66702
|
+
selectorLineIds: visibleLineIds,
|
|
66584
66703
|
companyId: userCompanyId,
|
|
66585
66704
|
enabled: shouldEnableMetricsFetch && !isLegacyMonitorMode,
|
|
66586
66705
|
appTimezone: timezone,
|
|
@@ -66591,12 +66710,32 @@ function HomeView({
|
|
|
66591
66710
|
const currentWorkspaceMetrics = isBootstrapMonitorMode ? bootstrapMonitor.workspaceMetrics : legacyWorkspaceMetrics;
|
|
66592
66711
|
const currentBlueComparisonWorkspaceMetrics = isBootstrapMonitorMode ? bootstrapMonitor.blueComparisonWorkspaceMetrics : legacyMetricsBlueComparisonWorkspaceMetrics;
|
|
66593
66712
|
const currentLineMetrics = isBootstrapMonitorMode ? bootstrapMonitor.lineMetrics : legacyLineMetrics;
|
|
66713
|
+
const currentSelectorLineMetrics = isBootstrapMonitorMode ? bootstrapMonitor.selectorLineMetrics : legacySelectorLineMetrics;
|
|
66594
66714
|
const currentEfficiencyLegend = isBootstrapMonitorMode ? bootstrapMonitor.efficiencyLegend : legacyEfficiencyLegend;
|
|
66595
66715
|
const currentMetricsMetadata = isBootstrapMonitorMode ? bootstrapMonitor.metadata : legacyMetricsMetadata;
|
|
66596
66716
|
const currentMetricsLoading = isBootstrapMonitorMode ? bootstrapMonitor.isLoading : legacyMetricsLoading;
|
|
66597
66717
|
const currentIsCurrentScopeResolved = isBootstrapMonitorMode ? bootstrapMonitor.isCurrentScopeResolved : legacyIsCurrentScopeResolved;
|
|
66598
66718
|
const currentMetricsError = isBootstrapMonitorMode ? bootstrapMonitor.error : legacyMetricsError;
|
|
66599
66719
|
const currentRefetchMetrics = isBootstrapMonitorMode ? bootstrapMonitor.refetch : refetchLegacyMetrics;
|
|
66720
|
+
const lineSelectorSignalStatusByLine = React147.useMemo(() => {
|
|
66721
|
+
const statusByLine = /* @__PURE__ */ new Map();
|
|
66722
|
+
const legend = currentEfficiencyLegend || DEFAULT_EFFICIENCY_LEGEND;
|
|
66723
|
+
const addRows = (rows) => {
|
|
66724
|
+
(rows || []).forEach((row) => {
|
|
66725
|
+
const lineId = typeof row?.line_id === "string" ? row.line_id : "";
|
|
66726
|
+
if (!lineId || statusByLine.has(lineId)) {
|
|
66727
|
+
return;
|
|
66728
|
+
}
|
|
66729
|
+
const status = getKpiSignalStatus(row?.line_signal, legend);
|
|
66730
|
+
if (status) {
|
|
66731
|
+
statusByLine.set(lineId, status);
|
|
66732
|
+
}
|
|
66733
|
+
});
|
|
66734
|
+
};
|
|
66735
|
+
addRows(currentSelectorLineMetrics);
|
|
66736
|
+
addRows(currentLineMetrics);
|
|
66737
|
+
return statusByLine;
|
|
66738
|
+
}, [currentEfficiencyLegend, currentLineMetrics, currentSelectorLineMetrics]);
|
|
66600
66739
|
const metricsDisplayNames = React147.useMemo(() => {
|
|
66601
66740
|
const nextDisplayNames = {};
|
|
66602
66741
|
currentWorkspaceMetrics.forEach((workspace) => {
|
|
@@ -67454,6 +67593,8 @@ function HomeView({
|
|
|
67454
67593
|
] }),
|
|
67455
67594
|
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "max-h-56 space-y-0.5 overflow-y-auto pr-1", children: visibleLineIds.map((lineId) => {
|
|
67456
67595
|
const isChecked = pendingSelectedLineIds.includes(lineId);
|
|
67596
|
+
const signalStatus = lineSelectorSignalStatusByLine.get(lineId);
|
|
67597
|
+
const signalDotClass = signalStatus === "stable" ? "bg-green-500" : signalStatus === "warning" ? "bg-yellow-400" : signalStatus === "attention" ? "bg-red-500" : "";
|
|
67457
67598
|
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
67458
67599
|
"label",
|
|
67459
67600
|
{
|
|
@@ -67478,7 +67619,15 @@ function HomeView({
|
|
|
67478
67619
|
}
|
|
67479
67620
|
}
|
|
67480
67621
|
),
|
|
67481
|
-
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "truncate", children: mergedLineNames[lineId] || `Line ${lineId.substring(0, 4)}` })
|
|
67622
|
+
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "min-w-0 flex-1 truncate", children: mergedLineNames[lineId] || `Line ${lineId.substring(0, 4)}` }),
|
|
67623
|
+
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "flex h-2.5 w-2.5 flex-shrink-0 items-center justify-center", children: signalStatus ? /* @__PURE__ */ jsxRuntime.jsx(
|
|
67624
|
+
"span",
|
|
67625
|
+
{
|
|
67626
|
+
"data-testid": `line-selector-signal-dot-${lineId}`,
|
|
67627
|
+
className: `h-2 w-2 rounded-full ${signalDotClass}`,
|
|
67628
|
+
"aria-hidden": "true"
|
|
67629
|
+
}
|
|
67630
|
+
) : null })
|
|
67482
67631
|
]
|
|
67483
67632
|
},
|
|
67484
67633
|
lineId
|
|
@@ -67507,6 +67656,7 @@ function HomeView({
|
|
|
67507
67656
|
mergedLineNames,
|
|
67508
67657
|
selectedLineIds,
|
|
67509
67658
|
pendingSelectedLineIds,
|
|
67659
|
+
lineSelectorSignalStatusByLine,
|
|
67510
67660
|
visibleLineIds,
|
|
67511
67661
|
updateSelectedLineIds,
|
|
67512
67662
|
isAllLinesSelection
|
|
@@ -80131,8 +80281,18 @@ var WorkspaceDetailView = ({
|
|
|
80131
80281
|
const monitoringMode = workspace?.monitoring_mode ?? "output";
|
|
80132
80282
|
const isUptimeMode = monitoringMode === "uptime";
|
|
80133
80283
|
const idleTimeVlmEnabled = isIdleTimeVlmEnabled(resolvedLineId);
|
|
80134
|
-
const showHourSummaryPanel = Boolean(selectedHour && !isUptimeMode);
|
|
80135
80284
|
const hourSummaryCompanyId = workspace?.company_id || dashboardConfig?.entityConfig?.companyId || null;
|
|
80285
|
+
const {
|
|
80286
|
+
isWorkspaceHourAiSummaryEnabled,
|
|
80287
|
+
isResolved: isWorkspaceHourAiSummaryResolved
|
|
80288
|
+
} = useCompanyWorkspaceHourAiSummaryEnabled(hourSummaryCompanyId);
|
|
80289
|
+
const showHourSummaryPanel = Boolean(selectedHour && !isUptimeMode && isWorkspaceHourAiSummaryEnabled);
|
|
80290
|
+
React147.useEffect(() => {
|
|
80291
|
+
if (isWorkspaceHourAiSummaryResolved && !isWorkspaceHourAiSummaryEnabled) {
|
|
80292
|
+
setSelectedHour(null);
|
|
80293
|
+
setAiSummaryHour(null);
|
|
80294
|
+
}
|
|
80295
|
+
}, [isWorkspaceHourAiSummaryEnabled, isWorkspaceHourAiSummaryResolved]);
|
|
80136
80296
|
const hourSummaryDate = workspace?.date || date || calculatedOperationalDate || null;
|
|
80137
80297
|
const hourSummaryShiftId = workspace?.shift_id ?? parsedShiftId ?? null;
|
|
80138
80298
|
React147.useEffect(() => {
|
|
@@ -81051,8 +81211,8 @@ var WorkspaceDetailView = ({
|
|
|
81051
81211
|
showIdleTime: showChartIdleTime,
|
|
81052
81212
|
idleTimeData: hourlyIdleMinutes,
|
|
81053
81213
|
idleTimeSlots: hourlyIdleSlots,
|
|
81054
|
-
selectedHourIndex: selectedHour?.source === "cycle" ? selectedHour.hourIndex : null,
|
|
81055
|
-
onHourClick: handleCycleHourSelect
|
|
81214
|
+
selectedHourIndex: isWorkspaceHourAiSummaryEnabled && selectedHour?.source === "cycle" ? selectedHour.hourIndex : null,
|
|
81215
|
+
onHourClick: isWorkspaceHourAiSummaryEnabled ? handleCycleHourSelect : void 0
|
|
81056
81216
|
}
|
|
81057
81217
|
) : null : /* @__PURE__ */ jsxRuntime.jsx(
|
|
81058
81218
|
HourlyOutputChart2,
|
|
@@ -81071,10 +81231,10 @@ var WorkspaceDetailView = ({
|
|
|
81071
81231
|
timezone: effectiveCycleTimeTimezone,
|
|
81072
81232
|
skuSegments: isSkuAware ? skuSegments : void 0,
|
|
81073
81233
|
activeSkuId,
|
|
81074
|
-
selectedHourIndex: selectedHour?.source === "output" ? selectedHour.hourIndex : aiSummaryHour?.hourIndex ?? null,
|
|
81075
|
-
onHourClick: handleOutputHourSelect,
|
|
81234
|
+
selectedHourIndex: isWorkspaceHourAiSummaryEnabled ? selectedHour?.source === "output" ? selectedHour.hourIndex : aiSummaryHour?.hourIndex ?? null : null,
|
|
81235
|
+
onHourClick: isWorkspaceHourAiSummaryEnabled ? handleOutputHourSelect : void 0,
|
|
81076
81236
|
onWatchClipsClick: handleWatchClipsFromChart,
|
|
81077
|
-
onAiSummaryClick: handleAiSummaryClick
|
|
81237
|
+
onAiSummaryClick: isWorkspaceHourAiSummaryEnabled ? handleAiSummaryClick : void 0
|
|
81078
81238
|
}
|
|
81079
81239
|
)
|
|
81080
81240
|
}
|
|
@@ -81224,8 +81384,8 @@ var WorkspaceDetailView = ({
|
|
|
81224
81384
|
showIdleTime: showChartIdleTime,
|
|
81225
81385
|
idleTimeData: hourlyIdleMinutes,
|
|
81226
81386
|
idleTimeSlots: hourlyIdleSlots,
|
|
81227
|
-
selectedHourIndex: selectedHour?.source === "cycle" ? selectedHour.hourIndex : null,
|
|
81228
|
-
onHourClick: handleCycleHourSelect
|
|
81387
|
+
selectedHourIndex: isWorkspaceHourAiSummaryEnabled && selectedHour?.source === "cycle" ? selectedHour.hourIndex : null,
|
|
81388
|
+
onHourClick: isWorkspaceHourAiSummaryEnabled ? handleCycleHourSelect : void 0
|
|
81229
81389
|
}
|
|
81230
81390
|
) : null : /* @__PURE__ */ jsxRuntime.jsx(
|
|
81231
81391
|
HourlyOutputChart2,
|
|
@@ -81244,10 +81404,10 @@ var WorkspaceDetailView = ({
|
|
|
81244
81404
|
timezone: effectiveCycleTimeTimezone,
|
|
81245
81405
|
skuSegments: isSkuAware ? skuSegments : void 0,
|
|
81246
81406
|
activeSkuId,
|
|
81247
|
-
selectedHourIndex: selectedHour?.source === "output" ? selectedHour.hourIndex : aiSummaryHour?.hourIndex ?? null,
|
|
81248
|
-
onHourClick: handleOutputHourSelect,
|
|
81407
|
+
selectedHourIndex: isWorkspaceHourAiSummaryEnabled ? selectedHour?.source === "output" ? selectedHour.hourIndex : aiSummaryHour?.hourIndex ?? null : null,
|
|
81408
|
+
onHourClick: isWorkspaceHourAiSummaryEnabled ? handleOutputHourSelect : void 0,
|
|
81249
81409
|
onWatchClipsClick: handleWatchClipsFromChart,
|
|
81250
|
-
onAiSummaryClick: handleAiSummaryClick
|
|
81410
|
+
onAiSummaryClick: isWorkspaceHourAiSummaryEnabled ? handleAiSummaryClick : void 0
|
|
81251
81411
|
}
|
|
81252
81412
|
) })
|
|
81253
81413
|
]
|
|
@@ -81401,7 +81561,7 @@ var WorkspaceDetailView = ({
|
|
|
81401
81561
|
) })
|
|
81402
81562
|
] })
|
|
81403
81563
|
] }),
|
|
81404
|
-
aiSummaryHour && /* @__PURE__ */ jsxRuntime.jsx(
|
|
81564
|
+
isWorkspaceHourAiSummaryEnabled && aiSummaryHour && /* @__PURE__ */ jsxRuntime.jsx(
|
|
81405
81565
|
"div",
|
|
81406
81566
|
{
|
|
81407
81567
|
className: "fixed inset-0 bg-slate-900/40 backdrop-blur-sm flex items-center justify-center p-4 z-[9999]",
|
|
@@ -91224,6 +91384,7 @@ exports.useCompanyClipsCost = useCompanyClipsCost;
|
|
|
91224
91384
|
exports.useCompanyFastSlowClipFiltersEnabled = useCompanyFastSlowClipFiltersEnabled;
|
|
91225
91385
|
exports.useCompanyHasVlmEnabledLine = useCompanyHasVlmEnabledLine;
|
|
91226
91386
|
exports.useCompanyUsersUsage = useCompanyUsersUsage;
|
|
91387
|
+
exports.useCompanyWorkspaceHourAiSummaryEnabled = useCompanyWorkspaceHourAiSummaryEnabled;
|
|
91227
91388
|
exports.useComponentOverride = useComponentOverride;
|
|
91228
91389
|
exports.useCustomConfig = useCustomConfig;
|
|
91229
91390
|
exports.useDashboardConfig = useDashboardConfig;
|