Commit 9e283ab1 by CaIon

馃帹 fix(logs): remove hardcoded font-mono to support global theme font inheritance

- Remove explicit 'font-mono' and custom size classes from model and token
  badges in usage logs.
- Allow model name and token badges to naturally inherit the active theme's
  font family (Sans or Serif) and text size from the parent container.
- Restore visual consistency and proportion across all table badge components.
parent a8b7c92e
......@@ -357,7 +357,7 @@ export function useCommonLogsColumns(isAdmin: boolean): ColumnDef<UsageLog>[] {
)}
</div>
{log.channel_name && (
<span className='text-muted-foreground/70 truncate text-[11px]'>
<span className='text-muted-foreground/70 truncate !text-xs [font-family:var(--font-body)]'>
{channelName}
</span>
)}
......@@ -491,7 +491,7 @@ export function useCommonLogsColumns(isAdmin: boolean): ColumnDef<UsageLog>[] {
copyText={sensitiveVisible ? tokenName : undefined}
size='sm'
showDot={false}
className='border-border/60 bg-muted/30 text-foreground max-w-full overflow-hidden rounded-md border h-6 px-2 py-0.5 gap-1.5 font-mono'
className='border-border/60 bg-muted/30 text-foreground max-w-full overflow-hidden rounded-md border h-6 px-2 py-0.5 gap-1.5'
/>
</TooltipTrigger>
{sensitiveVisible && tokenName.length > 16 && (
......@@ -502,7 +502,7 @@ export function useCommonLogsColumns(isAdmin: boolean): ColumnDef<UsageLog>[] {
</Tooltip>
</TooltipProvider>
{metaParts.length > 0 && (
<span className='text-muted-foreground/60 truncate text-[11px]'>
<span className='text-muted-foreground/60 truncate !text-xs [font-family:var(--font-body)]'>
{metaParts.join(' 路 ')}
</span>
)}
......@@ -598,13 +598,13 @@ export function useCommonLogsColumns(isAdmin: boolean): ColumnDef<UsageLog>[] {
/>
))}
</div>
<div className='flex items-center gap-1 text-[11px]'>
<span className='text-muted-foreground/60'>
<div className='flex items-center gap-1 !text-xs leading-none [font-family:var(--font-body)]'>
<span className='text-muted-foreground/60 !text-xs leading-none [font-family:var(--font-body)]'>
{log.is_stream ? t('Stream') : t('Non-stream')}
{tokensPerSecond != null && (
<>
{' 路 '}
<span className='font-mono tabular-nums'>
<span className='tabular-nums'>
{Math.round(tokensPerSecond)}
</span>
{' t/s'}
......
......@@ -101,7 +101,7 @@ function ModelBadgeContent(props: ModelBadgeProps) {
showDot={!provider}
autoColor={provider ? undefined : props.modelName}
className={cn(
'border-border/60 bg-muted/30 h-auto min-h-6 px-2 py-0.5 gap-1.5 rounded-md border font-mono whitespace-normal break-all',
'border-border/60 bg-muted/30 h-auto min-h-6 px-2 py-0.5 gap-1.5 rounded-md border whitespace-normal break-all',
provider && 'text-foreground',
props.className
)}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment