fix: expired date calc error

This commit is contained in:
NFish 2025-03-21 10:59:58 +08:00
parent 4a51a72c1d
commit bbc5ec8301
1 changed files with 1 additions and 1 deletions

View File

@ -13,7 +13,7 @@ const LicenseNav = () => {
if (systemFeatures.license?.status === LicenseStatus.EXPIRING) {
const expiredAt = systemFeatures.license?.expired_at
const count = dayjs(expiredAt).diff(dayjs(), 'days')
const count = dayjs(expiredAt).diff(dayjs(), 'day')
return <div className='px-2 py-1 mr-4 rounded-full bg-util-colors-orange-orange-50 border-util-colors-orange-orange-100 system-xs-medium text-util-colors-orange-orange-600'>
{count <= 1 && <span>{t('common.license.expiring', { count })}</span>}
{count > 1 && <span>{t('common.license.expiring_plural', { count })}</span>}