Problem/Motivation
Drupal has 2 types of ajax progress indicators: throbber and fullscreen. When the progress is of type throbber the ajax loader is triggered (for example after clicking on an ajax link), the ajax loader is displayed properly, but when the event gets fired a second time (if the user clicks again on an ajax link without reloading the page) the ajax loader is not displayed again.
This is happen even when the setting "Always show loader as overlay (fullscreen)" is enabled. In the other hand, fullscreen progress like views works as expected and the ajax loader is displayed across multiple requests.
Steps to reproduce
- Place a link with the class "use-ajax" anywhere on the page.
- Click on the ajax link.
- The ajax loader is displayed.
- After the ajax response, the ajax loader disappear as expected.
- Click again on the ajax link.
- The ajax loader is not displayed.
Proposed resolution
I'm not sure if it's the right solution, but returning always false on the method progressIsSet() when the progress type is throbber will fix the issue.
Remaining tasks
- patch
- review
- test
User interface changes
- None
API changes
- None
Data model changes
- None
Issue fork ajax_loader-3423380
Show commands
Start within a Git clone of the project using the version control instructions.
Or, if you do not have SSH keys set up on git.drupalcode.org:
Comments
Comment #3
akalam commentedI've created a MR with a fix. Not sure if it's the optimal solution but it works.
Comment #4
mvogel commentedThanks, @akalam,
yes, this #3331491 MR introduced this bug, but fixes another bug. So maybe we have to roll back this change because it triggers more bugs than it fixes.
Comment #5
mvogel commentedI tested it, and it seems promising. Maybe we can get some feedback from the persons involved in the linked issue.
Comment #6
evilargest commentedI tested the changes from the MR and they do resolve the issue I've faced, thanks guys. Cheers!
Comment #8
mvogel commentedThanks all, I committed it and will create a new release
Comment #9
mvogel commentedComment #10
akalam commentedThanks for reviewing and applying the fix!