From 424a2fc6d5910ed427040ed541dc9610fa69330d Mon Sep 17 00:00:00 2001 From: Henry Winkel Date: Sat, 16 May 2026 14:52:51 +0200 Subject: [PATCH] UI: add job details page and auto-refresh in JobHistory\n\nCo-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- app/components/JobHistory.tsx | 11 ++---- app/routes/jobs/$jobId.tsx | 71 +++++++++++++++++++++++++++++++++++ 2 files changed, 75 insertions(+), 7 deletions(-) create mode 100644 app/routes/jobs/$jobId.tsx diff --git a/app/components/JobHistory.tsx b/app/components/JobHistory.tsx index c27ae2a..342d5c0 100644 --- a/app/components/JobHistory.tsx +++ b/app/components/JobHistory.tsx @@ -1,4 +1,5 @@ import React, { useEffect, useState } from "react"; +import { useNavigate } from "react-router"; interface Props { ticker: string; @@ -29,6 +30,8 @@ export default function JobHistory({ ticker }: Props) { useEffect(() => { fetchJobs(); + const id = setInterval(fetchJobs, 8000); + return () => clearInterval(id); // eslint-disable-next-line react-hooks/exhaustive-deps }, [ticker]); @@ -68,13 +71,7 @@ export default function JobHistory({ ticker }: Props) {
API