CNCEC_APP/uni_modules/uview-pro/libs/config/config.ts

37 lines
885 B
TypeScript
Raw Permalink Normal View History

2026-03-25 14:54:15 +08:00
/**
*
*/
import { reactive } from 'vue';
import { version } from '../../package.json';
import type { DarkMode } from '../../types/global';
export interface AppConfig {
/** 版本号 */
v: string;
/** 版本号(冗余字段) */
version: string;
/** 主题名称列表 */
type: string[];
/** 默认主题名称 */
defaultTheme: string;
/** 默认暗黑主题 */
defaultDarkMode: DarkMode;
/** 默认语言 */
defaultLocale: string;
}
export const config = reactive<AppConfig>({
v: version,
version: version,
// 主题名称
type: ['primary', 'success', 'info', 'error', 'warning'],
// 默认为官方主题名称
defaultTheme: 'uviewpro',
// 默认为亮色模式
defaultDarkMode: 'light',
// 默认为中文
defaultLocale: 'zh-CN'
});
export default config;