open-sauced / app

🍕 Insights into your entire open source ecosystem.
https://pizza.new
Apache License 2.0
412 stars 221 forks source link

Feature: clicking on share chat takes a lot of time #3615

Closed a0m0rajab closed 3 months ago

a0m0rajab commented 3 months ago

Suggested solution

when clicking on the share chat it takes a bit of time to load the share buttons (mostly cause it creates the chat link in the backend) it would be great to have a loading state their or something to let the user wait, I think this would not be needed if the threads feature was added since it would just copy the link.

https://github.com/open-sauced/app/issues/3527

github-actions[bot] commented 3 months ago

Thanks for the issue, our team will look into it as soon as possible! If you would like to work on this issue, please wait for us to decide if it's ready. The issue will be ready to work on once we remove the "needs triage" label.

To claim an issue that does not have the "needs triage" label, please leave a comment that says ".take". If you have any questions, please comment on this issue.

For full info on how to contribute, please check out our contributors guide.

jpmcb commented 3 months ago

A loading state would be ideal - it does have to go round trip through to the backend to generate the short link. We have some existing design elements that could help here too!

a0m0rajab commented 3 months ago

@jpmcb thanks for the comment

The related code:

https://github.com/open-sauced/app/blob/50c5d1111775d3aafd989fb48478dac304b553a0/components/StarSearch/StarSearchChat.tsx#L623-L666

The loading state should be added at the beginning of the async function and changed when the link is generated.

This could be a good first issue.

ashudevcodes commented 3 months ago

Hey @nickytonline, I am working on this feature to add a loading state to the share chat button. I have implemented the solution, but I'm having an issue. When I click the share button, it fails to fetch the share link and gives a "bad request" or "failed to create a share link" error. However, fetching stream chats or AI-generated chats works fine. I'll attach a video showing the problem and an image of the network fetch error that happens when it tries to fetch the share link. Tell me what I can do to resolve this issue

https://github.com/open-sauced/app/assets/105356967/9ef01d32-98b1-45d7-9438-ad3870c6d10e

image image

nickytonline commented 3 months ago

Hi @ashudevcodes. Thanks for your interest in the issue, but it's already assigned to me and i astray have a fix for this.

Feel free to look at other issues that are not assigned to someone.

open-sauced[bot] commented 3 months ago

:tada: This issue has been resolved in version 2.39.0-beta.8 :tada:

The release is available on GitHub release

Your semantic-release bot :package::rocket:

open-sauced[bot] commented 3 months ago

:tada: This issue has been resolved in version 2.39.0 :tada:

The release is available on GitHub release

Your semantic-release bot :package::rocket: