🔖chore: Change the display style of request count, TPM, and RPM in the LogsTable

This commit is contained in:
Apple\Apple
2025-05-26 00:45:31 +08:00
parent 072ac1b3c8
commit 96709dd9f3

View File

@@ -1135,70 +1135,45 @@ const LogsTable = () => {
title={ title={
<div className="flex flex-col w-full"> <div className="flex flex-col w-full">
<Spin spinning={loadingStat}> <Spin spinning={loadingStat}>
<div className="grid grid-cols-1 md:grid-cols-3 gap-4"> <Space>
<Card <Tag
shadows='hover' color='blue'
className="bg-yellow-50 border-0 !rounded-2xl w-full" size='large'
headerLine={false}
>
<div className="flex items-center">
<Avatar
className="mr-3"
size="medium"
color="blue"
>
<IconCoinMoneyStroked />
</Avatar>
<div>
<div className="text-sm text-gray-500">{t('消耗额度')}</div>
<div className="text-xl font-semibold">{renderQuota(stat.quota)}</div>
</div>
</div>
</Card>
<Card
shadows='hover'
className="bg-cyan-50 border-0 !rounded-2xl w-full"
headerLine={false}
>
<div className="flex items-center">
<Avatar
className="mr-3"
size="medium"
color="pink"
>
<IconPulse />
</Avatar>
<div>
<div className="text-sm text-gray-500">RPM</div>
<div className="text-xl font-semibold">{stat.rpm || 0}</div>
</div>
</div>
</Card>
<Card
shadows='hover'
className="bg-violet-50 border-0 !rounded-2xl w-full"
headerLine={false}
>
<div className="flex items-center">
<Avatar
className="mr-3 shadow-md"
size="medium"
color="white"
style={{ style={{
boxShadow: 'var(--semi-shadow-elevated)' padding: 15,
borderRadius: '8px',
fontWeight: 500,
boxShadow: '0 2px 8px rgba(0, 0, 0, 0.1)',
}} }}
> >
<IconTypograph /> {t('消耗额度')}: {renderQuota(stat.quota)}
</Avatar> </Tag>
<div> <Tag
<div className="text-sm text-gray-500">TPM</div> color='pink'
<div className="text-xl font-semibold">{stat.tpm || 0}</div> size='large'
</div> style={{
</div> padding: 15,
</Card> borderRadius: '8px',
</div> fontWeight: 500,
boxShadow: '0 2px 8px rgba(0, 0, 0, 0.1)',
}}
>
RPM: {stat.rpm}
</Tag>
<Tag
color='white'
size='large'
style={{
padding: 15,
border: 'none',
boxShadow: '0 2px 8px rgba(0, 0, 0, 0.1)',
borderRadius: '8px',
fontWeight: 500,
}}
>
TPM: {stat.tpm}
</Tag>
</Space>
</Spin> </Spin>
<Divider margin="12px" /> <Divider margin="12px" />