@talismn/util 0.3.2 → 0.4.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -188,9 +188,10 @@ const formatPrice = (price, currency, compact) => {
|
|
188
188
|
style: "currency",
|
189
189
|
currency,
|
190
190
|
currencyDisplay: currency === "usd" ? "narrowSymbol" : "symbol",
|
191
|
+
minimumSignificantDigits: 3,
|
191
192
|
maximumSignificantDigits: compact ? price < 1 ? 3 : 4 : undefined,
|
192
193
|
roundingPriority: compact ? "auto" : "morePrecision",
|
193
|
-
notation: compact
|
194
|
+
notation: compact ? "compact" : "standard"
|
194
195
|
}).format(price);
|
195
196
|
};
|
196
197
|
|
@@ -188,9 +188,10 @@ const formatPrice = (price, currency, compact) => {
|
|
188
188
|
style: "currency",
|
189
189
|
currency,
|
190
190
|
currencyDisplay: currency === "usd" ? "narrowSymbol" : "symbol",
|
191
|
+
minimumSignificantDigits: 3,
|
191
192
|
maximumSignificantDigits: compact ? price < 1 ? 3 : 4 : undefined,
|
192
193
|
roundingPriority: compact ? "auto" : "morePrecision",
|
193
|
-
notation: compact
|
194
|
+
notation: compact ? "compact" : "standard"
|
194
195
|
}).format(price);
|
195
196
|
};
|
196
197
|
|
package/dist/talismn-util.esm.js
CHANGED
@@ -182,9 +182,10 @@ const formatPrice = (price, currency, compact) => {
|
|
182
182
|
style: "currency",
|
183
183
|
currency,
|
184
184
|
currencyDisplay: currency === "usd" ? "narrowSymbol" : "symbol",
|
185
|
+
minimumSignificantDigits: 3,
|
185
186
|
maximumSignificantDigits: compact ? price < 1 ? 3 : 4 : undefined,
|
186
187
|
roundingPriority: compact ? "auto" : "morePrecision",
|
187
|
-
notation: compact
|
188
|
+
notation: compact ? "compact" : "standard"
|
188
189
|
}).format(price);
|
189
190
|
};
|
190
191
|
|