refactor(project): re-adjust the overall folder

This commit is contained in:
vince
2024-07-23 00:03:59 +08:00
parent a1a566cb2f
commit 14538f7ed5
281 changed files with 1365 additions and 1659 deletions

View File

@@ -0,0 +1,32 @@
import type { SupportedLanguagesType } from '@vben-core/typings';
type ImportLocaleFn = () => Promise<{ default: Record<string, string> }>;
type LoadMessageFn = (
lang: SupportedLanguagesType,
) => Promise<Record<string, string>>;
interface LocaleSetupOptions {
/**
* Default language
* @default zh-CN
*/
defaultLocale?: SupportedLanguagesType;
/**
* Load message function
* @param lang
* @returns
*/
loadMessages?: LoadMessageFn;
/**
* Whether to warn when the key is not found
*/
missingWarn?: boolean;
}
export type {
ImportLocaleFn,
LoadMessageFn,
LocaleSetupOptions,
SupportedLanguagesType,
};