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

refactor: tab closing logic and add close tab hotkey #3319

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

Pragadesh-45
Copy link
Contributor

fixes: #3264

Description

This PR implements the logic for a Ctrl+W or Cmd+W hotkey to close a request tab from the RequestTab component. This enhancement includes a modal prompt to save changes before closing, improving the overall user experience. I removed the Ctrl+W hotkey functionality from the hotkeys provider and refactored the handleCloseClick method to reuse existing code.

Contribution Checklist:

  • The pull request only addresses one issue or adds one feature.
  • The pull request does not introduce any breaking changes
  • I have added screenshots or gifs to help explain the change if applicable.
  • I have read the contribution guidelines.
  • Create an issue and link to the pull request.

Before:

20241017-0756-03.7511875.mp4

After:

Uploading 20241017-0757-23.3456865.mp4…

@Pragadesh-45 Pragadesh-45 marked this pull request as ready for review October 17, 2024 10:20
@rsilvr
Copy link
Contributor

rsilvr commented Oct 23, 2024

@Pragadesh-45 I think I went a little bit further adding the prompt for all closing actions in the tab context menu in this PR. I could incorporate the hot key functionality there if you think it is worth it

@Pragadesh-45
Copy link
Contributor Author

@rsilvr Yes, yes! Eventually, we can add the hotkeys for closing a tab and closing all tabs. Let me take a look at your PR

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

Successfully merging this pull request may close these issues.

Command + W closes tab without prompt
2 participants