feat(i18n): improve ai chat and settings localization

This commit is contained in:
poyrazavsever
2026-07-21 12:49:25 +03:00
parent 702856d942
commit fcc6f2078a
12 changed files with 521 additions and 374 deletions
+5 -3
View File
@@ -53,12 +53,14 @@ export const sidebarData: SidebarNavGroup[] = [
},
];
export function localizeSidebarData(t: (key: string) => string): SidebarNavGroup[] {
export function localizeSidebarData(t: (key: string) => string) {
return sidebarData.map((group) => ({
...group,
titleKey: group.titleKey,
title: t(group.titleKey),
items: group.items.map((item) => ({
...item,
titleKey: item.titleKey,
href: item.href,
icon: item.icon,
title: t(item.titleKey),
})),
}));