mirror of
https://github.com/pure-admin/vue-pure-admin.git
synced 2025-06-06 00:18:51 +08:00
fix: update
This commit is contained in:
parent
b45a10b98f
commit
af01d80db2
@ -82,7 +82,7 @@
|
|||||||
"@vue/compiler-sfc": "^3.2.21",
|
"@vue/compiler-sfc": "^3.2.21",
|
||||||
"@vue/eslint-config-prettier": "6.0.0",
|
"@vue/eslint-config-prettier": "6.0.0",
|
||||||
"@vue/eslint-config-typescript": "7.0.0",
|
"@vue/eslint-config-typescript": "7.0.0",
|
||||||
"@zougt/vite-plugin-theme-preprocessor": "^1.3.8",
|
"@zougt/vite-plugin-theme-preprocessor": "^1.3.10",
|
||||||
"autoprefixer": "10.2.4",
|
"autoprefixer": "10.2.4",
|
||||||
"babel-plugin-transform-remove-console": "6.9.4",
|
"babel-plugin-transform-remove-console": "6.9.4",
|
||||||
"chalk": "2.4.2",
|
"chalk": "2.4.2",
|
||||||
|
8
pnpm-lock.yaml
generated
8
pnpm-lock.yaml
generated
@ -20,7 +20,7 @@ specifiers:
|
|||||||
"@vue/eslint-config-typescript": 7.0.0
|
"@vue/eslint-config-typescript": 7.0.0
|
||||||
"@vueuse/core": ^6.7.1
|
"@vueuse/core": ^6.7.1
|
||||||
"@vueuse/motion": ^2.0.0-beta.4
|
"@vueuse/motion": ^2.0.0-beta.4
|
||||||
"@zougt/vite-plugin-theme-preprocessor": ^1.3.8
|
"@zougt/vite-plugin-theme-preprocessor": ^1.3.10
|
||||||
animate.css: ^4.1.1
|
animate.css: ^4.1.1
|
||||||
autoprefixer: 10.2.4
|
autoprefixer: 10.2.4
|
||||||
await-to-js: ^3.0.0
|
await-to-js: ^3.0.0
|
||||||
@ -137,7 +137,7 @@ devDependencies:
|
|||||||
"@vue/compiler-sfc": 3.2.21
|
"@vue/compiler-sfc": 3.2.21
|
||||||
"@vue/eslint-config-prettier": 6.0.0_82e4252401b0cc5be86f7c2133946f49
|
"@vue/eslint-config-prettier": 6.0.0_82e4252401b0cc5be86f7c2133946f49
|
||||||
"@vue/eslint-config-typescript": 7.0.0_e03d82996bd4a66fb128f33523d782ea
|
"@vue/eslint-config-typescript": 7.0.0_e03d82996bd4a66fb128f33523d782ea
|
||||||
"@zougt/vite-plugin-theme-preprocessor": 1.3.8_sass@1.43.4
|
"@zougt/vite-plugin-theme-preprocessor": 1.3.10_sass@1.43.4
|
||||||
autoprefixer: 10.2.4_postcss@8.2.6
|
autoprefixer: 10.2.4_postcss@8.2.6
|
||||||
babel-plugin-transform-remove-console: 6.9.4
|
babel-plugin-transform-remove-console: 6.9.4
|
||||||
chalk: 2.4.2
|
chalk: 2.4.2
|
||||||
@ -1540,10 +1540,10 @@ packages:
|
|||||||
sass: 1.43.4
|
sass: 1.43.4
|
||||||
dev: true
|
dev: true
|
||||||
|
|
||||||
/@zougt/vite-plugin-theme-preprocessor/1.3.8_sass@1.43.4:
|
/@zougt/vite-plugin-theme-preprocessor/1.3.10_sass@1.43.4:
|
||||||
resolution:
|
resolution:
|
||||||
{
|
{
|
||||||
integrity: sha512-2fOaxWgg5Sxs3yiwzGH8DROSMtyCYCbf3B4F63aazayyoyPbVEnJG/f4whkYCFtzaJLiUEmlg3ABpcw9dwz/BA==
|
integrity: sha512-HHSTUYBv3quM8yRv57RJoDWqSm9cn9njCFk3ziSY+MALr7WT2uD5AmSnH9QBMVIU5jRcyPiuF3zDKbh8bifI+A==
|
||||||
}
|
}
|
||||||
engines: { node: ">= 12.0.0" }
|
engines: { node: ">= 12.0.0" }
|
||||||
dependencies:
|
dependencies:
|
||||||
|
@ -17,7 +17,7 @@ import { debounce } from "/@/utils/debounce";
|
|||||||
import { themeColorsType } from "../../types";
|
import { themeColorsType } from "../../types";
|
||||||
import { useAppStoreHook } from "/@/store/modules/app";
|
import { useAppStoreHook } from "/@/store/modules/app";
|
||||||
import { storageLocal, storageSession } from "/@/utils/storage";
|
import { storageLocal, storageSession } from "/@/utils/storage";
|
||||||
import { addClassNameToHtmlTag } from "@zougt/vite-plugin-theme-preprocessor/dist/browser-utils";
|
import { toggleTheme } from "@zougt/vite-plugin-theme-preprocessor/dist/browser-utils";
|
||||||
|
|
||||||
const router = useRouter();
|
const router = useRouter();
|
||||||
const { isSelect } = useCssModule();
|
const { isSelect } = useCssModule();
|
||||||
@ -62,7 +62,7 @@ let layoutTheme =
|
|||||||
if (unref(layoutTheme)) {
|
if (unref(layoutTheme)) {
|
||||||
let layout = unref(layoutTheme).layout;
|
let layout = unref(layoutTheme).layout;
|
||||||
let theme = unref(layoutTheme).theme;
|
let theme = unref(layoutTheme).theme;
|
||||||
addClassNameToHtmlTag({
|
toggleTheme({
|
||||||
scopeName: `layout-theme-${theme}`
|
scopeName: `layout-theme-${theme}`
|
||||||
});
|
});
|
||||||
window.document.body.setAttribute("layout", layout);
|
window.document.body.setAttribute("layout", layout);
|
||||||
@ -200,7 +200,7 @@ function setLayoutModel(layout: string) {
|
|||||||
// 设置导航主题色
|
// 设置导航主题色
|
||||||
function setLayoutThemeColor(theme: string) {
|
function setLayoutThemeColor(theme: string) {
|
||||||
layoutTheme.value.theme = theme;
|
layoutTheme.value.theme = theme;
|
||||||
addClassNameToHtmlTag({
|
toggleTheme({
|
||||||
scopeName: `layout-theme-${theme}`
|
scopeName: `layout-theme-${theme}`
|
||||||
});
|
});
|
||||||
instance.layout = { layout: useAppStoreHook().layout, theme };
|
instance.layout = { layout: useAppStoreHook().layout, theme };
|
||||||
|
@ -110,10 +110,7 @@ export default ({ command, mode }: ConfigEnv): UserConfigExport => {
|
|||||||
// 在生产模式是否抽取独立的主题css文件,extract为true以下属性有效
|
// 在生产模式是否抽取独立的主题css文件,extract为true以下属性有效
|
||||||
extract: true,
|
extract: true,
|
||||||
// 独立主题css文件的输出路径,默认取 viteConfig.build.assetsDir 相对于 (viteConfig.build.outDir)
|
// 独立主题css文件的输出路径,默认取 viteConfig.build.assetsDir 相对于 (viteConfig.build.outDir)
|
||||||
outputDir:
|
outputDir: "",
|
||||||
process.env.NODE_ENV === "production"
|
|
||||||
? "/manages/assets/"
|
|
||||||
: VITE_PUBLIC_PATH,
|
|
||||||
// 会选取defaultScopeName对应的主题css文件在html添加link
|
// 会选取defaultScopeName对应的主题css文件在html添加link
|
||||||
themeLinkTagId: "head",
|
themeLinkTagId: "head",
|
||||||
// "head"||"head-prepend" || "body" ||"body-prepend"
|
// "head"||"head-prepend" || "body" ||"body-prepend"
|
||||||
|
Loading…
x
Reference in New Issue
Block a user