Improve UI
This commit is contained in:
@@ -27,7 +27,15 @@ export const CURRENCY_CONFIG = {
|
||||
},
|
||||
} as const;
|
||||
|
||||
type CurrencyCode = keyof typeof CURRENCY_CONFIG;
|
||||
export type CurrencyCode = keyof typeof CURRENCY_CONFIG;
|
||||
|
||||
// Default currency for the application (Euro)
|
||||
export const DEFAULT_CURRENCY: CurrencyCode = 'EUR';
|
||||
|
||||
// Get currency symbol
|
||||
export const getCurrencySymbol = (currencyCode: CurrencyCode = DEFAULT_CURRENCY): string => {
|
||||
return CURRENCY_CONFIG[currencyCode]?.symbol || '€';
|
||||
};
|
||||
|
||||
// Format currency amount
|
||||
export const formatCurrency = (
|
||||
|
||||
Reference in New Issue
Block a user