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 delete element confirm dialog #2023

Merged
merged 3 commits into from
Feb 15, 2021

Conversation

tvdeyen
Copy link
Member

@tvdeyen tvdeyen commented Feb 13, 2021

What is this pull request for?

Fixes the order of operations. Actually wait until the confirm dialog has been loaded and the user confirmed deleting the element before destroying it.

Also makes sure that the "Please wait" overlay always gets closed after the confirm dialog closes.

Checklist

  • I have followed Pull Request guidelines
  • I have added a detailed description into each commit message
  • I have added tests to cover this change

We do not need the prefix. Its implied.
Do not rely on a potential redirect to remove the waiting animation.
Removing data-remote and data-method
prevents from Rails click handler being attached.

The confirm dialog already makes an ajax request to delete.
@tvdeyen tvdeyen added this to the 6.0 milestone Feb 13, 2021
@tvdeyen tvdeyen merged commit 84c9d30 into AlchemyCMS:main Feb 15, 2021
@tvdeyen tvdeyen deleted the fix-delete-element-confirm branch February 15, 2021 10:43
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