Skip to content
This repository has been archived by the owner on Aug 11, 2020. It is now read-only.

🐛[BUG] enabling menu localization and disabling localization for one menu item breaks the layout #499

Open
bravoeguizabal opened this issue Jun 8, 2020 · 1 comment

Comments

@bravoeguizabal
Copy link

🐛 bug 描述 [详细地描述 bug,让大家都能理解]

If you enable menu localization and you leave one menu item as locale independent then when you try to run the app it throws and error that breaks the layout and prevents from displaying it.

📷 复现步骤 [清晰描述复现步骤,让别人也能看到问题]

  1. Set in defaultSettings.ts -> menu: { locale: true },
  2. Set any menu entry in config.ts -> routes: [ {
    name: 'welcome',
    locale: false,
    icon: 'home',
    path: '/Welcome',
    component: './Welcome',
    },
    ]
  3. Open in a browser http://localhost:8000

🏞 期望结果 [描述你原本期望看到的结果]

The menu should always display the configured entry with the default message e.g. route.name

💻 复现代码 [提供可复现的代码,仓库,或线上示例]

© 版本信息

  • Ant Design Pro v5
  • umi 3.23
  • 浏览器环境 Firefox 77
  • 开发环境 win10 1904

🚑 其他信息 [如截图等其他信息可以贴在这里]

@chenshuai2144
Copy link
Collaborator

give a pr?

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants