Skip to content

🐛 [BUG] 侧面菜单折叠不起作用 #11421

Open
@mxchinegod

Description

🐛 bug 描述

两个独立的项目,升级到 UMI4 后主菜单折叠按钮不起作用

📷 复现步骤 | Recurrence steps

可以在移动版本上测试,将浏览器窗口缩小以便于查看

🏞 期望结果 | Expected results

菜单通过单击折叠按钮打开和关闭

💻 复现代码 | Recurrence code

// defaultSettings.ts

import { ProLayoutProps } from '@ant-design/pro-components';

/**
 * @name
 */
const Settings: ProLayoutProps & {
  pwa?: boolean;
  logo?: string;
} = {
  navTheme: 'realDark',
  // 拂晓蓝
  colorPrimary: '#1890ff',
  layout: "side",
  pageTitleRender: false,
  fixedHeader: false,
  fixSiderbar: true,
  // menu: { defaultOpenAll: true },
  // collapsedButtonRender: true,
  pwa: true,
  logo: "/logo.png",
  token: {},
  splitMenus: false,
  colorWeak: false,
  title: 'Prism',
  collapsed: true,
  iconfontUrl: '',
};

export default Settings;

© 版本信息

    "@ant-design/pro-components": "^2.7.16",
    "@ant-design/pro-layout": "^7.22.0",

🚑 其他信息

这发生在两个不同的项目上,所以我一定做错了什么或者版本有错误

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions