translation for nodes

This commit is contained in:
codetypes committed 2024-04-19 13:20:46 +08:00
1 parent 1e614a6c18
commit 0ff92fe429
4 files changed
+5 -2

No files matched your search

+2 -2
View File
@@ -445,7 +445,7 @@ export const useWorkspace = create<WorkspaceStore>((set, get) => ({
const workspace = get();
const nodeDefData = readJson(`${workspace.workdir}/node-config.b3-setting`) as NodeDef[];
const nodeTree: NodeTreeType = {
title: "NODES",
title: i18n.t("nodeDefinition"),
children: [],
style: {
fontWeight: "bold",
@@ -455,7 +455,7 @@ export const useWorkspace = create<WorkspaceStore>((set, get) => ({
const nodeDefs: Map<string, NodeDef> = new Map();
for (const v of nodeDefData) {
nodeDefs.set(v.name, v);
let catalog: NodeTreeType | undefined = nodeTree.children?.find((nt) => nt.title === v.type);
let catalog = nodeTree.children?.find((nt) => nt.title === v.type);
if (!catalog) {
catalog = {
title: v.type,