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

Command Menu Fails to Close on First 'Escape' Click; Requires Second Click for Closure #1032

Closed
4 of 6 tasks
deepgolani4 opened this issue Mar 17, 2024 · 3 comments
Closed
4 of 6 tasks
Assignees
Labels
apps: web Issues related to the webapp status: assigned Issue has been assigned type: bug Something isn't working

Comments

@deepgolani4
Copy link
Contributor

deepgolani4 commented Mar 17, 2024

Issue Description And Repro steps

Open the Command menu with ⌘+K.

When clicking "Escape" for the first time.
Screenshot 2024-03-17 at 8 04 18 PM

Clicking "Escape" a second time closes the command menu.

Expected Behavior

The command menu should close upon the first press of the "Escape" key.

Operating System [e.g., Windows 10]

MAC OS 17.1

Browser [e.g., Chrome, Firefox]

Arc (Chromium based browser)

Version [e.g., 2.0.1]

1.33.0

Please check the boxes that apply to this issue report.

  • I have searched the existing issues to make sure this is not a duplicate.
  • I have provided steps to reproduce the issue.
  • I have included relevant environment information.
  • I have included any relevant screenshots.
  • I understand that this is a voluntary contribution and that there is no guarantee of resolution.
  • I want to work on creating a PR for this issue if approved
@deepgolani4 deepgolani4 added the type: bug Something isn't working label Mar 17, 2024
@github-actions github-actions bot added the status: triage Scope to be determined label Mar 17, 2024
Copy link

Thank you for opening your first issue and for being a part of the open signing revolution!

One of our team members will review it and get back to you as soon as it possible 💚

Meanwhile, please feel free to hop into our community in Discord

Copy link
Collaborator

Mythie commented Mar 18, 2024

Looks like this is due to two command windows opening instead of the one which is weird. Happy to have you work on it!

@Mythie Mythie added status: assigned Issue has been assigned and removed status: triage Scope to be determined labels Mar 18, 2024
@deepgolani4 deepgolani4 removed their assignment Mar 18, 2024
@deepgolani4
Copy link
Contributor Author

@Mythie, I accidentally unassigned this task from myself.
Could you please assign it back to me?
Thank you

@dguyen dguyen added the apps: web Issues related to the webapp label Mar 22, 2024
dguyen added a commit that referenced this issue Apr 16, 2024
## Description
Currently, when the command menu is opened using the Command+K hotkey,
two modals are getting rendered.
This is because the modals are mounted in two components: header and
desktop-nav. Upon triggering the hotkey, both modals are rendered.

## Related Issue
#1032 

## Changes Made
The changes I made are in the desktop nav component. If the desktop nav
receives the command menu state value and the state setter function, it
will trigger only that. If not, it will trigger the state setter that is
defined in the desktop nav. This way, we are preventing the modal from
mounting two times.

## Testing Performed
- Tested behaviour of command menu in the portal
- Tested on browsers chrome, arc, safari, chrome, firefox

## Checklist
- [x] I have tested these changes locally and they work as expected.
- [ ] I have added/updated tests that prove the effectiveness of these
changes.
- [ ] I have updated the documentation to reflect these changes, if
applicable.
- [x] I have followed the project's coding style guidelines.
- [ ] I have addressed the code review feedback from the previous
submission, if applicable.



<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## Summary by CodeRabbit

- **New Features**
- Enhanced the navigation experience by integrating command menu state
management directly within the `DesktopNav` component, allowing for
smoother interactions and control.
- **Refactor**
- Simplified the handling of the command menu by removing the
`CommandMenu` component and managing its functionality within
`DesktopNav`.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->

---------

Co-authored-by: David Nguyen <davidngu28@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
apps: web Issues related to the webapp status: assigned Issue has been assigned type: bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants