mirror of
https://github.com/alibaba/lowcode-engine.git
synced 2026-01-13 01:21:58 +00:00
fix: 🐛 use intl
This commit is contained in:
parent
e3ca0bd6cb
commit
a22e66aaf3
@ -15,7 +15,7 @@ import {
|
||||
upgradePropConfig,
|
||||
upgradeConfigure,
|
||||
} from './upgrade-metadata';
|
||||
import { globalLocale } from '@ali/lowcode-editor-core';
|
||||
import { intl } from '@ali/lowcode-editor-core';
|
||||
import { designer } from '../editor';
|
||||
import { uniqueId } from '@ali/lowcode-utils';
|
||||
|
||||
@ -258,12 +258,8 @@ class Prototype {
|
||||
return this.meta.getMetadata().experimental?.context?.[name];
|
||||
}
|
||||
|
||||
getTitle(currentLocale?: string) {
|
||||
if (isI18nData(this.meta.title)) {
|
||||
const locale = currentLocale || globalLocale.getLocale();
|
||||
return this.meta.title[locale] || this.meta.title;
|
||||
}
|
||||
return this.meta.title;
|
||||
getTitle() {
|
||||
return intl(this.meta.title);
|
||||
}
|
||||
|
||||
getComponentName() {
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user