Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions report/src/components/Navbar.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -140,6 +140,9 @@ const Navbar = ({ urlPrefix }: ProvidedProps) => {
</Link>
</div>
</div>
{!isLoadTestsRoute && isLoading && (
<div className="animate-pulse bg-slate-200 rounded-md h-8 w-48" />
)}
{!isLoadTestsRoute && !isLoading && !!allBenchmarkRuns?.runs.length && (
<div>
<Select
Expand Down
12 changes: 10 additions & 2 deletions report/src/pages/RunComparison.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -72,8 +72,16 @@ function RunComparison() {
});
}, [dataPerFile, selection.data]);

if (!benchmarkRuns || isLoadingBenchmarkRuns) {
return <div>Loading...</div>;
if (isLoadingBenchmarkRuns) {
return (
<div className="flex flex-col w-full min-h-screen">
<Navbar urlPrefix="/run-comparison" />
<div className="flex flex-col w-full flex-grow p-8 gap-4">
<div className="animate-pulse bg-slate-200 rounded h-6 w-48" />
<div className="animate-pulse bg-slate-100 rounded h-64 w-full" />
</div>
</div>
);
}

return (
Expand Down
12 changes: 10 additions & 2 deletions report/src/pages/RunIndex.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -177,8 +177,16 @@ const RunIndex = () => {
};
}, [allBenchmarkRuns, benchmarkRunId]);

if (!benchmarkRuns || isLoadingBenchmarkRuns) {
return <div>Loading...</div>;
if (isLoadingBenchmarkRuns) {
return (
<div className="flex flex-col w-full min-h-screen">
<Navbar />
<div className="flex flex-col w-full flex-grow p-8 gap-4">
<div className="animate-pulse bg-slate-200 rounded h-6 w-48" />
<div className="animate-pulse bg-slate-100 rounded h-64 w-full" />
</div>
</div>
);
}

return <RunIndexInner benchmarkRuns={benchmarkRuns} />;
Expand Down
Loading