fix-percentage (#8684)

Following previous release, a suggestion was noticed by @martmull . Here
is a suggested fix.

Before :

![image](https://github.com/user-attachments/assets/10a55daa-8c90-42fc-8d1b-e28fc03f1948)

After :
<img width="611" alt="Screenshot 2024-11-22 at 14 56 07"
src="https://github.com/user-attachments/assets/67298633-4513-41a4-90aa-5e2366d3cd88">

---------

Co-authored-by: guillim <guillaume@twenty.com>
This commit is contained in:
Guillim
2024-11-22 15:20:37 +01:00
committed by GitHub
parent f44e2935df
commit cb5a0c1cc6

View File

@ -69,7 +69,7 @@ export const SettingsDataModelFieldNumberForm = ({
<SettingsOptionCardContentCounter
Icon={IconDecimal}
title="Number of decimals"
description={`Example: ${(1000).toFixed(count)}`}
description={`Example: ${(type === 'percentage' ? 99 : 1000).toFixed(count)} ${type === 'percentage' ? '%' : ''}`}
value={count}
onChange={(value) => onChange({ type: type, decimals: value })}
disabled={disabled}