Difference between revisions of "MediaWiki:Common.js"
From Project: Gorgon Wiki
Gorgonzola (talk | contribs) (Adding code for the Spoiler template) |
(No difference)
|
Revision as of 11:32, 23 September 2014
/* Any JavaScript here will be loaded for all users on every page load. */ // Gorgonzola: See my comments in page discussion (trying to minimize page bloat here). $('.spoilers-button').toggle(function() { $(this).parents('.spoilers').find('.spoilers-body').show(); $(this).children('.spoilers-show').hide(); $(this).children('.spoilers-hide').show(); }, function() { $(this).parents('.spoilers').find('.spoilers-body').hide(); $(this).children('.spoilers-show').show(); $(this).children('.spoilers-hide').hide(); });