mirror of
https://github.com/graphql-hive/console
synced 2026-05-23 17:18:23 +00:00
fix: loading spinner positions (#5262)
This commit is contained in:
parent
4c63ca8bb2
commit
0a1860bed2
6 changed files with 18 additions and 17 deletions
|
|
@ -55,7 +55,7 @@ export function IndexPage() {
|
|||
return (
|
||||
<>
|
||||
<Meta title="Welcome" />
|
||||
<div className="flex size-full flex-row items-center justify-center">
|
||||
<div className="flex size-full h-[100vh] flex-row items-center justify-center">
|
||||
<HiveLogo animated={false} className="size-16 animate-pulse" />
|
||||
</div>
|
||||
</>
|
||||
|
|
|
|||
|
|
@ -1049,9 +1049,9 @@ const ActiveSchemaCheck = (props: {
|
|||
if (query.fetching || query.stale) {
|
||||
return (
|
||||
<div className="flex h-fit flex-1 items-center justify-center self-center">
|
||||
<div className="flex flex-col items-center">
|
||||
<Spinner className="size-12" />
|
||||
<div className="mt-3">Loading Schema Check...</div>
|
||||
<div className="flex flex-col items-center text-sm text-gray-500">
|
||||
<Spinner className="mb-3 size-8" />
|
||||
Loading Schema Check...
|
||||
</div>
|
||||
</div>
|
||||
);
|
||||
|
|
|
|||
|
|
@ -213,7 +213,7 @@ function ExplorerPageContent(props: {
|
|||
)}
|
||||
</div>
|
||||
</div>
|
||||
{!query.fetching && (
|
||||
{!query.fetching && !query.stale && (
|
||||
<>
|
||||
{latestValidSchemaVersion?.explorer && latestSchemaVersion ? (
|
||||
<>
|
||||
|
|
|
|||
|
|
@ -583,14 +583,15 @@ function ActiveSchemaVersion(props: {
|
|||
|
||||
const { error } = query;
|
||||
|
||||
const isLoading = query.fetching;
|
||||
const isLoading = query.fetching || query.stale;
|
||||
const schemaVersion = query?.data?.target?.schemaVersion;
|
||||
const projectType = query?.data?.project?.type;
|
||||
|
||||
if (isLoading || !schemaVersion || !projectType) {
|
||||
return (
|
||||
<div className="flex size-full items-center justify-center">
|
||||
<Spinner />
|
||||
<div className="flex size-full flex-col items-center justify-center self-center text-sm text-gray-500">
|
||||
<Spinner className="mb-3 size-8" />
|
||||
Loading schema version...
|
||||
</div>
|
||||
);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1103,7 +1103,7 @@ function LaboratoryPageContent(props: {
|
|||
`}</style>
|
||||
</Helmet>
|
||||
|
||||
{!query.fetching && (
|
||||
{!query.fetching && !query.stale && (
|
||||
<div
|
||||
className={clsx(
|
||||
'grow',
|
||||
|
|
|
|||
|
|
@ -1069,26 +1069,26 @@ const subPages = [
|
|||
key: 'general',
|
||||
title: 'General',
|
||||
},
|
||||
{
|
||||
key: 'cdn',
|
||||
title: 'CDN Tokens',
|
||||
},
|
||||
{
|
||||
key: 'registry-token',
|
||||
title: 'Registry Tokens',
|
||||
},
|
||||
{
|
||||
key: 'cdn',
|
||||
title: 'CDN Tokens',
|
||||
},
|
||||
{
|
||||
key: 'breaking-changes',
|
||||
title: 'Breaking Changes',
|
||||
},
|
||||
{
|
||||
key: 'base-schema',
|
||||
title: 'Base Schema',
|
||||
},
|
||||
{
|
||||
key: 'schema-contracts',
|
||||
title: 'Schema Contracts',
|
||||
},
|
||||
{
|
||||
key: 'base-schema',
|
||||
title: 'Base Schema',
|
||||
},
|
||||
] as const;
|
||||
|
||||
type SubPage = (typeof subPages)[number]['key'];
|
||||
|
|
|
|||
Loading…
Reference in a new issue