fix: keep spacing in currency formatting

This commit is contained in:
xenticore
2025-04-16 20:57:28 -04:00
parent 90ddc075df
commit 21fcb57969

View File

@@ -35,7 +35,7 @@ export function createPriceRow(qualityName: string, data: ItemPriceData, keyPric
try { try {
const realPrice = convertUSD(realPriceUSD, currency, rates) const realPrice = convertUSD(realPriceUSD, currency, rates)
const currencyFormatter = new Intl.NumberFormat(locale, { style: "currency", currency: currency }) const currencyFormatter = new Intl.NumberFormat(locale, { style: "currency", currency: currency })
realPriceString = currencyFormatter.format(realPrice).replace(/\s+/g, '') realPriceString = currencyFormatter.format(realPrice)
} catch (e) { } catch (e) {
logError(`Failed to convert USD ${realPriceUSD} to ${currency}`, e) logError(`Failed to convert USD ${realPriceUSD} to ${currency}`, e)
} }