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

Escape key handlers should stop event propagation #2973

Closed
ademenev opened this issue May 19, 2022 · 1 comment
Closed

Escape key handlers should stop event propagation #2973

ademenev opened this issue May 19, 2022 · 1 comment
Labels

Comments

@ademenev
Copy link

TuSimple/naive-ui version (版本)

2.29.0

Vue version (Vue 版本)

3.2.34

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

Chrome/101.0.4951.64

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

MacOS (10.15.7)

Node version (Node 版本)

Reappearance link (重现链接)

https://codesandbox.io/s/admiring-lumiere-m7cq89

Reappearance steps (重现步骤)

Open the modal, then click any of the inputs, so the input popup is open, then press Escape key

Expected results (期望的结果)

The popup open by the input is closed, modal stays open

Actual results (实际的结果)

Modal closes

Remarks (补充说明)

@github-actions github-actions bot added the untriaged need to sort label May 19, 2022
@XieZongChen XieZongChen added consideration-needed and removed untriaged need to sort labels May 20, 2022
@07akioni
Copy link
Collaborator

I think we should handle the problem. However solution maybe complex.

We need to save esc event in a weak set, then check it in modal event handler.

@07akioni 07akioni added the feature request New feature or request label May 29, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants