()
| 674 | } |
| 675 | |
| 676 | export function useFormatterLocales(): { |
| 677 | formatterLocale: SupportedLocale |
| 678 | formatterLocalCurrency: SupportedLocalCurrency |
| 679 | } { |
| 680 | const currencyConversionEnabled = useCurrencyConversionFlagEnabled() |
| 681 | const activeLocale = useActiveLocale() |
| 682 | const activeLocalCurrency = useActiveLocalCurrency() |
| 683 | |
| 684 | if (currencyConversionEnabled) { |
| 685 | return { |
| 686 | formatterLocale: activeLocale, |
| 687 | formatterLocalCurrency: activeLocalCurrency, |
| 688 | } |
| 689 | } |
| 690 | |
| 691 | return { |
| 692 | formatterLocale: DEFAULT_LOCALE, |
| 693 | formatterLocalCurrency: DEFAULT_LOCAL_CURRENCY, |
| 694 | } |
| 695 | } |
| 696 | |
| 697 | function handleFallbackCurrency( |
| 698 | selectedCurrency: SupportedLocalCurrency, |
no test coverage detected
searching dependent graphs…