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

feat: add page exit confirmation for active chats (#452) #742

Closed

Conversation

tasosbeast
Copy link
Contributor

@tasosbeast tasosbeast commented Jan 31, 2025

Fixes Issue #452

**My PR closes #452 **

👨‍💻 Changes proposed(What did you do ?)

Added a warning dialog to alert users before they attempt to close the tab with an active chat.
Implemented the handleBeforeUnload function to handle the beforeunload event, displaying a warning message.
Used the useEffect hook to add the beforeunload event listener when the component mounts and to clean it up when the component unmounts.

✔️ Check List (Check all the applicable boxes)

  • My code follows the code style of this project.
  • This PR does not contain plagiarized content.
  • The title and description of the PR is clear and explains the approach.

Note to reviewers

📷 Screenshots

Copy link

vercel bot commented Jan 31, 2025

@tasosbeast is attempting to deploy a commit to the dunsin's projects Team on Vercel.

A member of the Team first needs to authorize it.

@Dun-sin
Copy link
Owner

Dun-sin commented Feb 3, 2025

@tasosbeast can you show a screenrecording from your end that this works

@Dun-sin
Copy link
Owner

Dun-sin commented Feb 11, 2025

Hi @tasosbeast the time assigned to this Issue is over, your PR is now closed. Thanks for trying to contribute, you're free to ask to work on other issues, if you can meet up with the time assigned.

@Dun-sin Dun-sin closed this Feb 11, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[FEATURE] send warning dialog when users want to close the tab
2 participants