-
-
Notifications
You must be signed in to change notification settings - Fork 5.5k
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
Implement Debouncing for Approve Button Clicks in Gitea Pull Requests #25096
Labels
topic/ui-interaction
Change the process how users use Gitea instead of the visual appearance
Comments
lunny
added
topic/ui-interaction
Change the process how users use Gitea instead of the visual appearance
and removed
type/bug
labels
Jun 6, 2023
I think to improve this, we might first change the |
Many related issues like #20402 AJAX is the answer to the problem. |
This was referenced Jun 13, 2023
Closed
lunny
pushed a commit
that referenced
this issue
Jun 14, 2023
Co-author: @wxiaoguang Close #25096 The way to fix it in this PR is to change form submit to fetch using formData, and add flags to avoid post repeatedly. Should be able to apply to more forms that have the same issue after this PR. In the demo below, 'approve' is clicked several times, and then 'comment' is clicked several time after 'request changes' clicked. After: https://github.com/go-gitea/gitea/assets/17645053/beabeb1d-fe66-4b76-b048-4f022b4e83a0 Update: screenshots from /devtest > ![image](https://user-images.githubusercontent.com/2114189/245680011-ee4231e0-a53d-4c2a-a9c2-71ccd98005cc.png) > > ![image](https://user-images.githubusercontent.com/2114189/245680057-9215d348-63d8-406d-8828-17e171163aaa.png) > > ![image](https://user-images.githubusercontent.com/2114189/245680148-89d7b3d1-d7b6-442f-b69e-eadaee112482.png) --------- Co-authored-by: wxiaoguang <[email protected]>
Thanks! @lunny |
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Description
I have discovered that Gitea lacks debouncing functionality for the approve button, which can result in repeated approvals if users click quickly before the website responds. Additionally, this can lead to multiple webhook calls being triggered.
To solve this issue, I suggest implementing a debounce mechanism in Gitea. Debouncing would effectively merge and handle multiple rapid approve actions performed by a user during a single interaction.
Here is a screenshot illustrating the problem:
I kindly request the Gitea development team to consider adding this feature to enhance the user experience and prevent unintended repeated approvals.
Thank you for your attention to this matter, and I appreciate your efforts in continually improving Gitea.
Gitea Version
1.19.3
Can you reproduce the bug on the Gitea demo site?
No
Log Gist
No response
Screenshots
No response
Git Version
No response
Operating System
No response
How are you running Gitea?
Self-hosted in docker container
Database
None
The text was updated successfully, but these errors were encountered: