Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Icons in horizontal menu children do not respond to being clicked #823

Closed
spenserblack opened this issue Aug 9, 2021 · 2 comments
Closed
Assignees
Labels
bug Something isn't working

Comments

@spenserblack
Copy link
Contributor

TuSimple/naive-ui version (版本)

2.16.2

Vue version (Vue 版本)

3.1.5

Browser and its version (浏览器及其版本)

Chromium(Version 92.0.4515.131 (Official Build) snap (64-bit))

System and its version (系统及其版本)

Ubuntu 20.04.2 LTS

Node version (Node 版本)

16.6.1

Reappearance link (重现链接)

https://github.com/spenserblack/n-menu-router-issue-example

Reappearance steps (重现步骤)

  1. Switch mode to horizontal
  2. Expand collapsed submenu
  3. Click icon
  4. See menu option is highlighted, but route does not change

Expected results (期望的结果)

Same behavior as vertical mode. If icon is clicked, it should act like label is clicked.

Actual results (实际的结果)

Only label properly responds to being clicked in horizontal mode.

Remarks (补充说明)

@github-actions github-actions bot added the untriaged need to sort label Aug 9, 2021
@Volankey Volankey added bug Something isn't working and removed untriaged need to sort labels Aug 10, 2021
@Volankey
Copy link
Collaborator

In fact, if you click precisely to the <a/>, it can switch the route.
In vertical mode, you can click on other areas to switch routing because we wrote the following css code:
image
<a /> has &::before, it covers the entire menu-item. But in horizontal there not have it.

Do we need to add such css to the dropdown of the menu? @07akioni

@07akioni
Copy link
Collaborator

@Volankey Add it to n-dropdown

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

4 participants