Skip to content

Commit

Permalink
This commit closes issue BenjaminVanRyseghem#665
Browse files Browse the repository at this point in the history
  • Loading branch information
pooriyasafaei committed Jan 14, 2023
1 parent cac2055 commit 97ae162
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/formatting.js
Original file line number Diff line number Diff line change
Expand Up @@ -331,9 +331,9 @@ function formatCurrency(instance, providedFormat, state) {

if (position === "prefix") {
if (instance._value < 0 && options.negative === "sign") {
output = `-${space}${symbol}${output.slice(1)}`;
output = `${symbol}${space}-${output.slice(1)}`;
} else if (instance._value > 0 && options.forceSign) {
output = `+${space}${symbol}${output.slice(1)}`;
output = `${symbol}${space}+${output.slice(1)}`;
} else {
output = symbol + space + output;
}
Expand Down

0 comments on commit 97ae162

Please sign in to comment.