polish: composite breadcrumb keys; pause run-log polling when tab hidden (P3-58, P3-59)

This commit is contained in:
ZacharyZhang-NY committed 2026-04-16 23:11:25 -04:00
1 parent 96ab72472c
commit a7ad4e5a8b
2 files changed
+5 -3

No files matched your search

+4 -2
View File
@@ -149,7 +149,8 @@ export function RunCenter({
useEffect(() => {
if (!selectedRun || !isActiveStatus(selectedRun.status)) return;
let cancelled = false;
const intervalId = window.setInterval(async () => {
const tick = async () => {
if (document.visibilityState === "hidden") return;
const latest = await window.agentCompany.getRunLogChunk({
companyId: selectedRun.companyId,
runId: selectedRun.id,
@@ -166,7 +167,8 @@ export function RunCenter({
loading: false,
error: null,
});
}, 2500);
};
const intervalId = window.setInterval(tick, 2500);
return () => {
cancelled = true;
@@ -259,7 +259,7 @@ export function SkillDetail({
{/* File path bar */}
<div className="mb-3 flex items-center gap-1 text-[12px] text-muted-foreground">
{selectedSkillFilePath.split("/").map((segment, i, arr) => (
<span key={i} className="flex items-center gap-1">
<span key={`${segment}-${i}`} className="flex items-center gap-1">
{i > 0 ? <span className="opacity-40">/</span> : null}
<span className={i === arr.length - 1 ? "font-medium text-foreground" : ""}>
{segment}