You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
29 lines
483 B
29 lines
483 B
5 years ago
|
import defaultLocale from '../locale/default';
|
||
7 years ago
|
|
||
4 years ago
|
export interface ModalLocale {
|
||
|
okText: string;
|
||
|
cancelText: string;
|
||
|
justOkText: string;
|
||
|
}
|
||
7 years ago
|
|
||
|
let runtimeLocale = {
|
||
|
...defaultLocale.Modal,
|
||
6 years ago
|
};
|
||
7 years ago
|
|
||
4 years ago
|
export function changeConfirmLocale(newLocale?: any) {
|
||
7 years ago
|
if (newLocale) {
|
||
|
runtimeLocale = {
|
||
|
...runtimeLocale,
|
||
|
...newLocale,
|
||
6 years ago
|
};
|
||
7 years ago
|
} else {
|
||
|
runtimeLocale = {
|
||
|
...defaultLocale.Modal,
|
||
6 years ago
|
};
|
||
7 years ago
|
}
|
||
|
}
|
||
|
|
||
6 years ago
|
export function getConfirmLocale() {
|
||
|
return runtimeLocale;
|
||
7 years ago
|
}
|