fix: update billing button disabled style

This commit is contained in:
NFish 2025-01-23 14:44:26 +08:00
parent c2671c16a8
commit 5d4e517397
2 changed files with 9 additions and 5 deletions

View File

@ -50,16 +50,19 @@ const style = {
icon: <ArCube1 className='text-text-primary size-7' />, icon: <ArCube1 className='text-text-primary size-7' />,
description: 'text-util-colors-gray-gray-600', description: 'text-util-colors-gray-gray-600',
btnStyle: 'bg-components-button-secondary-bg hover:bg-components-button-secondary-bg-hover border-[0.5px] border-components-button-secondary-border text-text-primary', btnStyle: 'bg-components-button-secondary-bg hover:bg-components-button-secondary-bg-hover border-[0.5px] border-components-button-secondary-border text-text-primary',
btnDisabledStyle: 'bg-components-button-secondary-bg-disabled hover:bg-components-button-secondary-bg-disabled border-components-button-secondary-border-disabled text-components-button-secondary-text-disabled',
}, },
[Plan.professional]: { [Plan.professional]: {
icon: <Keyframe className='text-util-colors-blue-brand-blue-brand-600 size-7' />, icon: <Keyframe className='text-util-colors-blue-brand-blue-brand-600 size-7' />,
description: 'text-util-colors-blue-brand-blue-brand-600', description: 'text-util-colors-blue-brand-blue-brand-600',
btnStyle: 'bg-components-button-primary-bg hover:bg-components-button-primary-bg-hover border border-components-button-primary-border text-components-button-primary-text', btnStyle: 'bg-components-button-primary-bg hover:bg-components-button-primary-bg-hover border border-components-button-primary-border text-components-button-primary-text',
btnDisabledStyle: 'bg-components-button-primary-bg-disabled hover:bg-components-button-primary-bg-disabled border-components-button-primary-border-disabled text-components-button-primary-text-disabled',
}, },
[Plan.team]: { [Plan.team]: {
icon: <Group2 className='text-util-colors-indigo-indigo-600 size-7' />, icon: <Group2 className='text-util-colors-indigo-indigo-600 size-7' />,
description: 'text-util-colors-indigo-indigo-600', description: 'text-util-colors-indigo-indigo-600',
btnStyle: 'bg-components-button-indigo-bg hover:bg-components-button-indigo-bg-hover border border-components-button-primary-border text-components-button-primary-text', btnStyle: 'bg-components-button-indigo-bg hover:bg-components-button-indigo-bg-hover border border-components-button-primary-border text-components-button-primary-text',
btnDisabledStyle: 'bg-components-button-indigo-bg-disabled hover:bg-components-button-indigo-bg-disabled border-components-button-indigo-border-disabled text-components-button-primary-text-disabled',
}, },
} }
const PlanItem: FC<Props> = ({ const PlanItem: FC<Props> = ({
@ -156,7 +159,8 @@ const PlanItem: FC<Props> = ({
<div <div
className={cn('flex py-3 px-5 rounded-full justify-center items-center h-[42px]', className={cn('flex py-3 px-5 rounded-full justify-center items-center h-[42px]',
style[plan].btnStyle, style[plan].btnStyle,
isPlanDisabled ? 'cursor-not-allowed' : 'cursor-pointer ')} isPlanDisabled && style[plan].btnDisabledStyle,
isPlanDisabled ? 'cursor-not-allowed' : 'cursor-pointer')}
onClick={handleGetPayUrl} onClick={handleGetPayUrl}
> >
{btnText} {btnText}

View File

@ -43,16 +43,16 @@ const translation = {
contactSales: '联系销售', contactSales: '联系销售',
talkToSales: '联系销售', talkToSales: '联系销售',
modelProviders: '支持 OpenAI/Anthropic/Llama2/Azure OpenAI/Hugging Face/Replicate', modelProviders: '支持 OpenAI/Anthropic/Llama2/Azure OpenAI/Hugging Face/Replicate',
teamWorkspace: '{{count}} 个团队空间', teamWorkspace: '{{count,number}} 个团队空间',
teamMember_one: '{{count}} 名团队成员', teamMember_one: '{{count,number}} 名团队成员',
teamMember_other: '{{count}} 名团队成员', teamMember_other: '{{count,number}} 名团队成员',
annotationQuota: '标注回复数', annotationQuota: '标注回复数',
buildApps: '{{count, number}} 个应用程序', buildApps: '{{count, number}} 个应用程序',
documents: '{{count, number}} 个知识库文档上传配额', documents: '{{count, number}} 个知识库文档上传配额',
documentsTooltip: '从知识库的数据源导入的文档数量配额。', documentsTooltip: '从知识库的数据源导入的文档数量配额。',
vectorSpace: '{{size}} 知识库数据存储空间', vectorSpace: '{{size}} 知识库数据存储空间',
vectorSpaceTooltip: '采用高质量索引模式的文档会消耗知识数据存储资源。当知识数据存储达到限制时,将不会上传新文档。', vectorSpaceTooltip: '采用高质量索引模式的文档会消耗知识数据存储资源。当知识数据存储达到限制时,将不会上传新文档。',
documentsRequestQuota: '{{count}}/分钟 知识库请求频率限制', documentsRequestQuota: '{{count,number}}/分钟 知识库请求频率限制',
documentsRequestQuotaTooltip: '指每分钟内一个空间在知识库中可执行的操作总数包括数据集的创建、删除、更新文档的上传、修改、归档以及知识库查询等用于评估知识库请求的性能。例如Sandbox 用户在 1 分钟内连续执行 10 次命中测试,其工作区将在接下来的 1 分钟内无法继续执行以下操作:数据集的创建、删除、更新,文档的上传、修改等操作。', documentsRequestQuotaTooltip: '指每分钟内一个空间在知识库中可执行的操作总数包括数据集的创建、删除、更新文档的上传、修改、归档以及知识库查询等用于评估知识库请求的性能。例如Sandbox 用户在 1 分钟内连续执行 10 次命中测试,其工作区将在接下来的 1 分钟内无法继续执行以下操作:数据集的创建、删除、更新,文档的上传、修改等操作。',
documentProcessingPriority: '文档处理', documentProcessingPriority: '文档处理',
priority: { priority: {