Learning AMP: Disabling AMP-IMG Lightbox — AMPire.city

Originally published at https://ampire.city

What Will I Learn?

Requirements:

The Issue

Disable Auto-Lightbox on AMP-IMG

<amp-img data-amp-auto-lightbox-disable 
src="/img/ampire.city.svg"
height="3"
width="4"
layout="responsive"
alt="amp-img with disabled auto-lightbox">
</amp-img>

Disable Auto-Lightbox on Multiple AMP-IMG

<section data-amp-auto-lightbox-disable>
<amp-img>...</amp-img>
<amp-img>...</amp-img>
<amp-img>...</amp-img>
</section>

Disable Auto-Lightbox on Whole Website

<body data-amp-auto-lightbox-disable>
<!-- All AMP-IMGs will have auto-lightbox disabled -->
</body>

Need Help?

Useful links:

Travel Blogger, Web Designer & AMP Developer | Travel & History Journal: https://www.ctdots.eu | AMP Development & Web Design Tutorials: https://ampire.city

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store