mirror of
https://github.com/apache/skywalking-booster-ui.git
synced 2025-10-14 11:21:29 +00:00
feat: menus support for multiple languages (#299)
This commit is contained in:
@@ -168,12 +168,14 @@ export const appStore = defineStore({
|
||||
const t = `${d.title.replace(/\s+/g, "-")}`;
|
||||
d.name = `${t}-${index}`;
|
||||
d.path = `/${t}`;
|
||||
d.descKey = `${d.i18nKey}_desc`;
|
||||
if (d.subItems && d.subItems.length) {
|
||||
d.hasGroup = true;
|
||||
d.subItems = d.subItems.map((item: SubItem, sub: number) => {
|
||||
const id = `${item.title.replace(/\s+/g, "-")}`;
|
||||
item.name = `${id}-${index}${sub}`;
|
||||
item.path = `/${t}/${id}`;
|
||||
item.descKey = `${item.i18nKey}_desc`;
|
||||
return item;
|
||||
});
|
||||
}
|
||||
|
Reference in New Issue
Block a user