MediaWiki:Mobile.js
Note: After publishing, you may have to bypass your browser's cache to see the changes.
- Firefox / Safari: Hold Shift while clicking Reload, or press either Ctrl-F5 or Ctrl-R (⌘-R on a Mac)
- Google Chrome: Press Ctrl-Shift-R (⌘-Shift-R on a Mac)
- Internet Explorer / Edge: Hold Ctrl while clicking Refresh, or press Ctrl-F5
- Opera: Press Ctrl-F5.
/* Mobile specific JavaScript */ function toggleGallery(link){var gallery=link.closest('.expandable-gallery');var fullGallery=gallery.querySelector('.gallery-full');if(fullGallery.style.display==='none'||fullGallery.style.display===''){fullGallery.style.display='block';link.textContent='[Collapse Gallery]';lazyLoadImages(fullGallery);}else{fullGallery.style.display='none';link.textContent='[Expand Gallery]';}} function lazyLoadImages(container){var images=container.querySelectorAll('img[data-src]');images.forEach(function(img){img.src=img.getAttribute('data-src');img.removeAttribute('data-src');});} document.addEventListener("DOMContentLoaded",function(){var galleries=document.querySelectorAll('.expandable-gallery .gallery-full img');galleries.forEach(function(img){img.setAttribute('data-src',img.src);img.removeAttribute('src');});});