The jQuery UI Effects library normally does not depend on jQuery UI core. Therefore, it's possible for code in Drupal to load that library on a page where jQuery UI core is not being explicitly used.
However, the CDNs used by jQuery Update lump them all together in the same file. And the jQuery Update module associates this file with the jQuery UI core entry in hook_library() alone (and removes all the individual JS files defined in hook_library()). Therefore, if someone does drupal_add_library('system', 'effects') without also doing drupal_add_library('system', 'ui'), jQuery Update will prevent the Effects library from being loaded, and the JavaScript will break.
An example from Hierarchical Select module: #1536230: Animations conflicting with jQuery Update module
| Comment | File | Size | Author |
|---|---|---|---|
| #2 | jquery-update-effects-cdn-1801388-2.patch | 705 bytes | David_Rothstein |
| #1 | jquery-update-effects-cdn-1801388-1.patch | 704 bytes | David_Rothstein |
Comments
Comment #1
David_Rothstein commentedSome additional refactoring might be a good idea here (since the jQuery Update code for the CDN is written in general to assume dependencies that don't necessarily exist, not just for this specific case)... but here is a simple patch that fixes the bug with the Effects library directly.
Comment #2
David_Rothstein commentedUpdated the patch to apply to the latest 7.x-2.x code.
Comment #3
a.knutson commented#2 works for me! Thanks for sharing David.
Comment #4
killua99 commentedAlso for me . When it's going to be pushed into the dev or stable branch ??
Comment #5
deanflory commentedpatching file jquery_update.module
Hunk #1 succeeded at 390 (offset 57 lines).
This is with jquery_update 7.x-2.x-dev 2013-Sep-30
FYI, to users of the back_to_top module, it won't work at this time with this jquery_update #2 patch above applied.
Comment #6
ericduran commentedGreat find.
This is now fixed. Proper commit credit given to @David_Rothstein.
--
http://drupalcode.org/project/jquery_update.git/commit/e33325b