Skip to content

Commit

Permalink
fix(ui): Fixes V1 Run detail unnecessary reloading. Fixes #10590 (#11214
Browse files Browse the repository at this point in the history
)

Signed-off-by: Jack Quinn <[email protected]>
  • Loading branch information
quinnovator authored Sep 16, 2024
1 parent 1a4849a commit eee095e
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 5 deletions.
5 changes: 5 additions & 0 deletions frontend/src/pages/RunDetails.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -101,6 +101,7 @@ interface SelectedNodeDetails {

// exported only for testing
export interface RunDetailsInternalProps {
isLoading?: boolean;
runId?: string;
gkeMetadata: GkeMetadata;
}
Expand Down Expand Up @@ -237,6 +238,10 @@ class RunDetails extends Page<RunDetailsInternalProps, RunDetailsState> {
}

public render(): JSX.Element {
if (this.props.isLoading) {
return <div>Currently loading run information</div>;
}

const {
allArtifactConfigs,
allowCustomVisualizations,
Expand Down
6 changes: 1 addition & 5 deletions frontend/src/pages/RunDetailsRouter.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -70,9 +70,5 @@ export default function RunDetailsRouter(props: RunDetailsProps) {
}
}

if (runIsFetching || templateStrIsFetching) {
return <div>Currently loading run information</div>;
}

return <EnhancedRunDetails {...props} />;
return <EnhancedRunDetails {...props} isLoading={runIsFetching || templateStrIsFetching} />;
}

0 comments on commit eee095e

Please sign in to comment.