Impove Intl formatting (#5372)
* Improve Intl formatting * Additional fixes * Fixed formatters were not updated on locale change * Fixed formatNumber was not updated on locale change * Additional formatting and fixes after merge * Run prepr:frontend * Remove `'` in icon map * Run `pnpm install` * fix: lint + import * Additional fixes --------- Co-authored-by: Calum H. <calum@modrinth.com> Co-authored-by: Calum H. (IMB11) <contact@cal.engineer>
This commit is contained in:
@@ -616,7 +616,7 @@
|
||||
<p v-if="lowestPrice" class="m-0 text-sm">
|
||||
{{
|
||||
formatMessage(messages.startingAtPrice, {
|
||||
price: formatPrice(locale, lowestPrice, selectedCurrency, true),
|
||||
price: formatPrice(lowestPrice, selectedCurrency, true),
|
||||
})
|
||||
}}
|
||||
</p>
|
||||
@@ -644,10 +644,10 @@ import {
|
||||
injectNotificationManager,
|
||||
IntlFormatted,
|
||||
ModrinthServersPurchaseModal,
|
||||
useFormatPrice,
|
||||
useVIntl,
|
||||
} from '@modrinth/ui'
|
||||
import { monthsInInterval } from '@modrinth/ui/src/utils/billing.ts'
|
||||
import { formatPrice } from '@modrinth/utils'
|
||||
import { computed } from 'vue'
|
||||
|
||||
import { useBaseFetch } from '@/composables/fetch.js'
|
||||
@@ -678,7 +678,8 @@ if (affiliateCode.value) {
|
||||
}
|
||||
|
||||
const { addNotification } = injectNotificationManager()
|
||||
const { locale, formatMessage } = useVIntl()
|
||||
const { formatMessage } = useVIntl()
|
||||
const formatPrice = useFormatPrice()
|
||||
const flags = useFeatureFlags()
|
||||
|
||||
const messages = defineMessages({
|
||||
|
||||
Reference in New Issue
Block a user