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

fix: visibility feature for new chat #662

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

EliecerC
Copy link

@EliecerC EliecerC commented Dec 27, 2024

Currently trying to set public for a not yet created chat doesn't work.

This change allows users to set and manage the visibility of their new chats.

  • Updated chat route to include visibility parameter in POST request.
  • Modified Chat component to handle visibility state from cache.
  • Enhanced useChatVisibility hook to manage chat visibility and update accordingly.
  • Adjusted saveChat function to store visibility in the database.

- Updated chat route to include visibility parameter in POST request.
- Modified Chat component to handle visibility state from cache.
- Enhanced useChatVisibility hook to manage chat visibility and update accordingly.
- Adjusted saveChat function to store visibility in the database.

This change allows users to set and manage the visibility of their chats.
Copy link

vercel bot commented Dec 27, 2024

@EliecerC is attempting to deploy a commit to the Vercel Team on Vercel.

A member of the Team first needs to authorize it.

- Changed condition in useChatVisibility hook to check for absence of chat before mutating visibility state.
- Ensures that visibility updates are only triggered when there is no active chat, improving the handling of chat visibility.
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.

1 participant