添加 unix 纯净版模式

This commit is contained in:
icssoa 2025-08-11 16:32:41 +08:00
parent 83360678c2
commit 798ecc7304
6 changed files with 20 additions and 1 deletions

View File

@ -31,4 +31,5 @@ export declare const config: {
rpxRatio: number;
darkTextClass: string;
};
clean: boolean;
};

View File

@ -56,6 +56,7 @@
rpxRatio: 2,
darkTextClass: "dark:text-surface-50",
},
clean: false,
};
// 根目录
@ -2407,6 +2408,12 @@ if (typeof window !== 'undefined') {
config.type = options.type;
// 请求地址
config.reqUrl = getProxyTarget(options.proxy);
// 是否纯净版
config.clean = options.clean;
if (config.clean) {
// 默认设置为测试地址
config.reqUrl = "https://show.cool-admin.com/api";
}
// 是否开启名称标签
config.nameTag = options.nameTag ?? true;
// svg

View File

@ -1,6 +1,6 @@
{
"name": "@cool-vue/vite-plugin",
"version": "8.2.5",
"version": "8.2.6",
"description": "cool-admin、cool-uni builder",
"types": "./dist/index.d.ts",
"main": "/dist/index.js",

View File

@ -53,4 +53,5 @@ export const config = {
rpxRatio: 2,
darkTextClass: "dark:text-surface-50",
},
clean: false,
};

View File

@ -14,6 +14,14 @@ export function cool(options: Config.Options) {
// 请求地址
config.reqUrl = getProxyTarget(options.proxy);
// 是否纯净版
config.clean = options.clean;
if (config.clean) {
// 默认设置为测试地址
config.reqUrl = "https://show.cool-admin.com/api";
}
// 是否开启名称标签
config.nameTag = options.nameTag ?? true;

View File

@ -119,5 +119,7 @@ export declare namespace Config {
// 暗黑模式文本类名
darkTextClass?: string;
};
// 是否纯净版
clean: boolean;
}
}