Fix breadcrumb on tag edit page

This commit is contained in:
Sam Becker 2024-03-14 13:24:04 -05:00
parent fb393f4fc4
commit e0f18171c0
2 changed files with 9 additions and 7 deletions

View File

@ -45,11 +45,9 @@ function AdminChildPage({
{breadcrumb &&
<>
<span>/</span>
<span className={clsx(isLoading && 'opacity-50')}>
<Badge>
{breadcrumb}
</Badge>
</span>
<Badge dimContent={isLoading}>
{breadcrumb}
</Badge>
</>}
{isLoading &&
<Spinner />}

View File

@ -3,12 +3,14 @@ import { clsx } from 'clsx/lite';
export default function Badge({
children,
type = 'large',
dimContent,
highContrast,
uppercase,
interactive,
}: {
children: React.ReactNode
type?: 'large' | 'small' | 'text-only'
dimContent?: boolean
highContrast?: boolean
uppercase?: boolean
interactive?: boolean
@ -19,7 +21,7 @@ export default function Badge({
return clsx(
'px-1.5 py-[0.3rem] rounded-md',
'bg-gray-100/80 dark:bg-gray-900/80',
'border border-gray-200/60 dark:border-gray-800/75'
'border border-gray-200/60 dark:border-gray-800/75',
);
case 'small':
return clsx(
@ -43,7 +45,9 @@ export default function Badge({
stylesForType(),
uppercase && 'uppercase tracking-wider',
)}>
{children}
<span className={clsx(dimContent && 'opacity-50')}>
{children}
</span>
</span>
);
}