1
0
mirror of https://github.com/fumiama/paper-manager.git synced 2026-06-09 18:30:23 +08:00

add frontend/vben from vben-admin-thin

This commit is contained in:
源文雨
2023-03-10 17:18:32 +08:00
parent 30cd57ef76
commit 2a0fdeae31
469 changed files with 42028 additions and 0 deletions

View File

@@ -0,0 +1,11 @@
const docEle = document.documentElement
export function toggleClass(flag: boolean, clsName: string, target?: HTMLElement) {
const targetEl = target || document.body
let { className } = targetEl
className = className.replace(clsName, '')
targetEl.className = flag ? `${className} ${clsName} ` : className
}
export function setCssVar(prop: string, val: any, dom = docEle) {
dom.style.setProperty(prop, val)
}