Skip to content

Commit

Permalink
Fix Amount default format
Browse files Browse the repository at this point in the history
bpierre committed Jan 30, 2025
1 parent f2eed7b commit b9f6181
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions frontend/app/src/comps/Amount/Amount.tsx
Original file line number Diff line number Diff line change
@@ -26,8 +26,12 @@ export function Amount({
if (percentage && !suffix) {
suffix = "%";
}
if (percentage && !format) {
format = "pct2z";
if (format === undefined) {
if (percentage) {
format = "pct2z";
} else {
format = "2z";
}
}

const showFallback = value === null || value === undefined;

0 comments on commit b9f6181

Please sign in to comment.