mirror of
https://github.com/umami-software/umami.git
synced 2026-02-04 04:37:11 +01:00
Updated languageNames export.
This commit is contained in:
parent
99559c2b35
commit
356e953304
2 changed files with 2 additions and 2 deletions
|
|
@ -28,7 +28,7 @@ export function useLanguageNames(locale) {
|
|||
}
|
||||
}, [locale]);
|
||||
|
||||
return list;
|
||||
return { languageNames: list };
|
||||
}
|
||||
|
||||
export default useLanguageNames;
|
||||
|
|
|
|||
|
|
@ -10,7 +10,7 @@ export function LanguagesTable({
|
|||
}: { onDataLoad: (data: any) => void } & MetricsTableProps) {
|
||||
const { formatMessage, labels } = useMessages();
|
||||
const { locale } = useLocale();
|
||||
const languageNames = useLanguageNames(locale);
|
||||
const { languageNames } = useLanguageNames(locale);
|
||||
|
||||
const renderLabel = ({ x }) => {
|
||||
return languageNames[x?.split('-')[0]] ?? x;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue