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

Prevent clicking submit twice #913

Closed
cjquines opened this issue Jul 16, 2022 · 5 comments · Fixed by #993
Closed

Prevent clicking submit twice #913

cjquines opened this issue Jul 16, 2022 · 5 comments · Fixed by #993
Labels
bug client (Javascript) client code and CSS needs-contributor Someone needs to implement this. Help wanted!
Milestone

Comments

@cjquines
Copy link

In the following logic, we clear the comment text or close the box only after the API call succeeds. But if the API call takes a few seconds, then excited users might press "submit" multiple times. Maybe disable clicking the "submit" button as soon as it's clicked the first time?

https://github.com/posativ/isso/blob/10e5a90df94d8f1b710f5b1d9a22172fb84e8978/isso/js/app/isso.js#L109-L122

@ix5 ix5 added needs-contributor Someone needs to implement this. Help wanted! client (Javascript) client code and CSS bug labels Jul 18, 2022
@ix5 ix5 added this to the 0.13 milestone Jul 18, 2022
@ix5
Copy link
Member

ix5 commented Jul 19, 2022

You'd have to keep track of when to re-enable the button (e.g. editing). But in general, your suggestion is a good idea.

@akshatakulkarni25
Copy link

hey @ix5 can i work on this issue

@ix5
Copy link
Member

ix5 commented Feb 21, 2023

hey @ix5 can i work on this issue

Great, go for it!

@ix5 ix5 modified the milestones: 0.13, 0.14 Jan 22, 2024
pkvach added a commit to pkvach/isso that referenced this issue Feb 22, 2024
…ponse

Disable the submit button in Postbox to prevent double posting upon click. Enable the button after receiving a response from the API endpoint.

Fixes isso-comments#913
pkvach added a commit to pkvach/isso that referenced this issue Mar 20, 2024
…ponse

Disable the submit button in Postbox to prevent double posting upon click. Enable the button after receiving a response from the API endpoint.

Fixes isso-comments#913
pkvach added a commit to pkvach/isso that referenced this issue Mar 30, 2024
…ponse

Disable the submit button in Postbox to prevent double posting upon click. Enable the button after receiving a response from the API endpoint.

Fixes isso-comments#913
pkvach added a commit to pkvach/isso that referenced this issue Mar 30, 2024
…ponse

Disable the submit button in Postbox to prevent double posting upon click. Enable the button after receiving a response from the API endpoint.

Fixes isso-comments#913
pkvach added a commit to pkvach/isso that referenced this issue Mar 30, 2024
…ponse

Disable the submit button in Postbox to prevent double posting upon click. Enable the button after receiving a response from the API endpoint.

Fixes isso-comments#913
pkvach added a commit to pkvach/isso that referenced this issue Mar 31, 2024
…ponse

Disable the submit button in Postbox to prevent double posting upon click. Enable the button after receiving a response from the API endpoint.

Fixes isso-comments#913
pkvach added a commit to pkvach/isso that referenced this issue Mar 31, 2024
…ponse

Disable the submit button in Postbox to prevent double posting upon click. Enable the button after receiving a response from the API endpoint.

Fixes isso-comments#913
pkvach added a commit to pkvach/isso that referenced this issue Apr 14, 2024
…ponse

Disable the submit button in Postbox to prevent double posting upon click. Enable the button after receiving a response from the API endpoint.

Fixes isso-comments#913
pkvach added a commit to pkvach/isso that referenced this issue Apr 19, 2024
…ponse

Disable the submit button in Postbox to prevent double posting upon click. Enable the button after receiving a response from the API endpoint.

Fixes isso-comments#913
pkvach added a commit to pkvach/isso that referenced this issue Apr 19, 2024
…ponse

Disable the submit button in Postbox to prevent double posting upon click. Enable the button after receiving a response from the API endpoint.

Fixes isso-comments#913
@ix5 ix5 modified the milestones: 0.14, 0.13.1 May 9, 2024
pkvach added a commit to pkvach/isso that referenced this issue May 10, 2024
…ponse

Disable the submit button in Postbox to prevent double posting upon click. Enable the button after receiving a response from the API endpoint.

Fixes isso-comments#913
pkvach added a commit to pkvach/isso that referenced this issue May 11, 2024
…ponse

Disable the submit button in Postbox to prevent double posting upon click. Enable the button after receiving a response from the API endpoint.

Fixes isso-comments#913
pkvach added a commit to pkvach/isso that referenced this issue May 11, 2024
…ponse

Disable the submit button in Postbox to prevent double posting upon click. Enable the button after receiving a response from the API endpoint.

Fixes isso-comments#913
pkvach added a commit to pkvach/isso that referenced this issue May 14, 2024
…ponse

Disable the submit button in Postbox to prevent double posting upon click. Enable the button after receiving a response from the API endpoint.

Fixes isso-comments#913
pkvach added a commit to pkvach/isso that referenced this issue May 14, 2024
…ponse

Disable the submit button in Postbox to prevent double posting upon click. Enable the button after receiving a response from the API endpoint.

Fixes isso-comments#913
pkvach added a commit to pkvach/isso that referenced this issue May 14, 2024
…ponse

Disable the submit button in Postbox to prevent double posting upon click. Enable the button after receiving a response from the API endpoint.

Fixes isso-comments#913
@ix5 ix5 closed this as completed in #993 May 17, 2024
@cjquines
Copy link
Author

thanks for fixing this @pkvach !

@pkvach
Copy link
Contributor

pkvach commented May 18, 2024

thanks for fixing this @pkvach !

Thanks, glad to help.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug client (Javascript) client code and CSS needs-contributor Someone needs to implement this. Help wanted!
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants