From 673f88f6a7cd8eb53e1666c4224db9ba42ae69e2 Mon Sep 17 00:00:00 2001 From: Tsu-ba-me Date: Fri, 25 Nov 2022 17:51:03 -0500 Subject: [PATCH] fix(striker-ui): default refresh to 10s in JobSummary --- striker-ui/components/JobSummary.tsx | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/striker-ui/components/JobSummary.tsx b/striker-ui/components/JobSummary.tsx index d81abc2e..b6158e4e 100644 --- a/striker-ui/components/JobSummary.tsx +++ b/striker-ui/components/JobSummary.tsx @@ -23,6 +23,7 @@ type AnvilJobs = { type JobSummaryOptionalPropsWithDefault = { openInitially?: boolean; + refreshInterval?: number; }; type JobSummaryOptionalPropsWithoutDefault = { @@ -44,6 +45,7 @@ const JOB_SUMMARY_DEFAULT_PROPS: Required & JobSummaryOptionalPropsWithoutDefault = { onFetchSuccessAppend: undefined, openInitially: false, + refreshInterval: 10000, }; const JobSummary = forwardRef( @@ -51,6 +53,7 @@ const JobSummary = forwardRef( { onFetchSuccessAppend, openInitially = JOB_SUMMARY_DEFAULT_PROPS.openInitially, + refreshInterval = JOB_SUMMARY_DEFAULT_PROPS.refreshInterval, }, ref, ) => { @@ -74,6 +77,7 @@ const JobSummary = forwardRef( onFetchSuccessAppend?.call(null, rawAnvilJobs); }, + refreshInterval, }); useImperativeHandle(