다국어 화면에서 수정기능 구현
This commit is contained in:
@@ -58,6 +58,47 @@ export const ScreenMultiLangProvider: React.FC<ScreenMultiLangProviderProps> = (
|
||||
}
|
||||
});
|
||||
}
|
||||
// 분할패널 좌측/우측 제목 langKey 수집
|
||||
const config = (comp as any).componentConfig;
|
||||
if (config?.leftPanel?.langKey) {
|
||||
keys.push(config.leftPanel.langKey);
|
||||
}
|
||||
if (config?.rightPanel?.langKey) {
|
||||
keys.push(config.rightPanel.langKey);
|
||||
}
|
||||
// 분할패널 좌측/우측 컬럼 langKey 수집
|
||||
if (config?.leftPanel?.columns) {
|
||||
config.leftPanel.columns.forEach((col: any) => {
|
||||
if (col.langKey) {
|
||||
keys.push(col.langKey);
|
||||
}
|
||||
});
|
||||
}
|
||||
if (config?.rightPanel?.columns) {
|
||||
config.rightPanel.columns.forEach((col: any) => {
|
||||
if (col.langKey) {
|
||||
keys.push(col.langKey);
|
||||
}
|
||||
});
|
||||
}
|
||||
// 추가 탭 langKey 수집
|
||||
if (config?.additionalTabs) {
|
||||
config.additionalTabs.forEach((tab: any) => {
|
||||
if (tab.langKey) {
|
||||
keys.push(tab.langKey);
|
||||
}
|
||||
if (tab.titleLangKey) {
|
||||
keys.push(tab.titleLangKey);
|
||||
}
|
||||
if (tab.columns) {
|
||||
tab.columns.forEach((col: any) => {
|
||||
if (col.langKey) {
|
||||
keys.push(col.langKey);
|
||||
}
|
||||
});
|
||||
}
|
||||
});
|
||||
}
|
||||
// 자식 컴포넌트 재귀 처리
|
||||
if ((comp as any).children) {
|
||||
collectLangKeys((comp as any).children);
|
||||
|
||||
Reference in New Issue
Block a user