mirror of
https://github.com/pure-admin/vue-pure-admin.git
synced 2025-11-03 13:44:47 +08:00
perf: 隐藏标签页功能优化
This commit is contained in:
@@ -1,6 +1,5 @@
|
||||
<script setup lang="ts">
|
||||
import { split } from "lodash-es";
|
||||
import { nextTick } from "vue";
|
||||
import panel from "../panel/index.vue";
|
||||
import { useRouter } from "vue-router";
|
||||
import { emitter } from "/@/utils/mitt";
|
||||
@@ -52,11 +51,7 @@ if (settings.tagsVal === null) {
|
||||
localOperate("tagsVal", false, "set");
|
||||
settings.tagsVal = false;
|
||||
}
|
||||
nextTick(() => {
|
||||
window.document
|
||||
.querySelector(".app-main")
|
||||
?.setAttribute("data-show-tag", settings.tagsVal);
|
||||
});
|
||||
window.document.body.setAttribute("data-show-tag", settings.tagsVal);
|
||||
|
||||
function toggleClass(flag: boolean, clsName: string, target?: HTMLElement) {
|
||||
const targetEl = target || document.body;
|
||||
|
||||
Reference in New Issue
Block a user