mirror of
https://github.com/alibaba/lowcode-engine.git
synced 2026-03-07 02:47:12 +00:00
fix: intl
This commit is contained in:
parent
6b91535740
commit
8a061ab847
@ -49,13 +49,14 @@ class AliGlobalLocale {
|
|||||||
}
|
}
|
||||||
} else if (g_config) {
|
} else if (g_config) {
|
||||||
if (g_config.locale) {
|
if (g_config.locale) {
|
||||||
return languageMap[g_config.locale] || (g_config.locale || '').replace('_', '-');
|
return languageMap[g_config.locale] || g_config.locale.replace('_', '-');
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
let locale: string = '';
|
let locale: string = '';
|
||||||
if (navigator.language) {
|
if (navigator.language) {
|
||||||
locale = (navigator.language as string).replace('_', '-');
|
const lang = (navigator.language as string);
|
||||||
|
return languageMap[lang] || lang.replace('_', '-');
|
||||||
}
|
}
|
||||||
|
|
||||||
// IE10 及更低版本使用 browserLanguage
|
// IE10 及更低版本使用 browserLanguage
|
||||||
|
|||||||
@ -1,12 +1,12 @@
|
|||||||
import Pane from './views/pane';
|
import Pane from './views/pane';
|
||||||
import { IconOutline } from './icons/outline';
|
import { IconOutline } from './icons/outline';
|
||||||
import { intl } from './locale';
|
import { intlNode } from './locale';
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
name: 'outline-pane',
|
name: 'outline-pane',
|
||||||
props: {
|
props: {
|
||||||
icon: IconOutline,
|
icon: IconOutline,
|
||||||
description: intl('Outline Tree'),
|
description: intlNode('Outline Tree'),
|
||||||
},
|
},
|
||||||
content: Pane,
|
content: Pane,
|
||||||
};
|
};
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user