wujingjing
2025-02-24 a61bd8abfb6bedacccbc1f1cdb01e4f433e58fd7
src/layout/index.vue
@@ -9,6 +9,7 @@
import { Local } from '/@/utils/storage';
import mittBus from '/@/utils/mitt';
import { PingLogin } from '/@/api/system';
import { MOBILE_MIN_WIDTH } from '../constants';
// 引入组件
const layouts: any = {
@@ -26,7 +27,7 @@
const onLayoutResize = () => {
   if (!Local.get('oldLayout')) Local.set('oldLayout', themeConfig.value.layout);
   const clientWidth = document.body.clientWidth;
   if (clientWidth < 1000) {
   if (clientWidth < MOBILE_MIN_WIDTH) {
      themeConfig.value.isCollapse = false;
      mittBus.emit('layoutMobileResize', {
         layout: 'defaults',