From f695c142f129639eb9e0bdd7bb69bd9ebf34afef Mon Sep 17 00:00:00 2001 From: Chris Scott <99081550+chriswritescode-dev@users.noreply.github.com> Date: Fri, 2 Oct 2026 00:04:13 -0400 Subject: [PATCH] fix(schedules): use real row buttons and correct run timestamps - replace row-level keyboard handlers with buttons and aria-labels - keep the active run resolvable when filtered out of the list - show run startedAt consistently and ignore the unread shortcut with modifiers --- .../src/components/schedules/PromptsTab.tsx | 20 ++++++++------- .../components/schedules/RunHistoryTab.tsx | 2 +- .../schedules/ScheduleJobsTable.tsx | 24 +++++++++--------- .../schedules/ScheduleRunDrawer.tsx | 9 +++---- .../schedules/ScheduleRunsTable.tsx | 25 ++++++++++--------- frontend/src/pages/GlobalSchedules.tsx | 2 +- 6 files changed, 41 insertions(+), 41 deletions(-) diff --git a/frontend/src/components/schedules/PromptsTab.tsx b/frontend/src/components/schedules/PromptsTab.tsx index 89a8d7e4..5819562c 100644 --- a/frontend/src/components/schedules/PromptsTab.tsx +++ b/frontend/src/components/schedules/PromptsTab.tsx @@ -145,20 +145,22 @@ export function PromptsTab({ promptDialog, templateId, onNew, onEdit, onDelete, {visibleTemplates.map((template) => (
|
- {job.name}
+
{job.description && {job.description}}
{mobileDetail}
diff --git a/frontend/src/components/schedules/ScheduleRunDrawer.tsx b/frontend/src/components/schedules/ScheduleRunDrawer.tsx
index 05bc6116..cafc4127 100644
--- a/frontend/src/components/schedules/ScheduleRunDrawer.tsx
+++ b/frontend/src/components/schedules/ScheduleRunDrawer.tsx
@@ -42,7 +42,6 @@ export function ScheduleRunDrawer({
const title = run ? getRunTitle(run) : 'Run'
const repoName = run ? getRunRepoName(run) : null
const branch = activeRun ? formatRunBranch(activeRun) : null
- const startedAt = activeRun ? activeRun.finishedAt ?? activeRun.startedAt : null
const meta = activeRun ? (
@@ -51,11 +50,9 @@ export function ScheduleRunDrawer({
{getRunStatusLabel(activeRun.status)}
{repoName && {repoName}}
- {startedAt !== null && (
-
- {activeRun.status === 'running' ? 'Running' : formatDistanceToNow(startedAt, { addSuffix: true })}
-
- )}
+
+ {activeRun.status === 'running' ? 'Running' : formatDistanceToNow(activeRun.startedAt, { addSuffix: true })}
+
{formatRunDuration(activeRun)}
{branch && {branch}}
diff --git a/frontend/src/components/schedules/ScheduleRunsTable.tsx b/frontend/src/components/schedules/ScheduleRunsTable.tsx
index 78771fc7..9495c38f 100644
--- a/frontend/src/components/schedules/ScheduleRunsTable.tsx
+++ b/frontend/src/components/schedules/ScheduleRunsTable.tsx
@@ -65,21 +65,12 @@ export function ScheduleRunsTable({
{runs.map((run) => {
const isUnread = run.viewedAt === null && (run.status === 'completed' || run.status === 'failed')
const isSelected = selectedRunId === run.id
- const startedAt = run.finishedAt ?? run.startedAt
const repoName = getRunRepoName(run)
return (
@@ -91,7 +82,17 @@ export function ScheduleRunsTable({
|
|
- {getRunTitle(run)}
+
{isUnread && (
NEW
)}
@@ -110,8 +111,8 @@ export function ScheduleRunsTable({
)}
{run.triggerSource} |
-
- {run.status === 'running' ? 'Running' : formatDistanceToNow(startedAt, { addSuffix: true })}
+
+ {run.status === 'running' ? 'Running' : formatDistanceToNow(run.startedAt, { addSuffix: true })}
|
{formatRunDuration(run)} |
diff --git a/frontend/src/pages/GlobalSchedules.tsx b/frontend/src/pages/GlobalSchedules.tsx
index e6fdd966..1d778dd0 100644
--- a/frontend/src/pages/GlobalSchedules.tsx
+++ b/frontend/src/pages/GlobalSchedules.tsx
@@ -102,7 +102,7 @@ export function GlobalSchedules() {
useEffect(() => {
if (scheduleTab !== 'runs' && runId === null) return
const handleKeyDown = (event: KeyboardEvent) => {
- if (event.key !== 'u') return
+ if (event.key !== 'u' || event.metaKey || event.ctrlKey || event.altKey) return
const target = event.target as HTMLElement | null
if (target && (target.tagName === 'INPUT' || target.tagName === 'TEXTAREA' || target.isContentEditable)) return
event.preventDefault()
|