Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 17 additions & 3 deletions examples/responsive.amp.html
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,8 @@

figure {
margin: 0;
max-width: 100%;
overflow: hidden;
}

figcaption {
Expand Down Expand Up @@ -142,6 +144,14 @@

amp-img {
background-color: #f4f4f4;
max-width: 100%;
height: auto;
}

.content-container {
padding: 15px;
max-width: 100%;
overflow-x: hidden;
}
</style>
<script async custom-element="amp-ad" src="https://cdn.ampproject.org/v0/amp-ad-0.1.js"></script>
Expand All @@ -161,10 +171,14 @@
<amp-img
src="img/[email protected]"
srcset="img/[email protected] 1x, img/[email protected] 2x"
layout="responsive" width="360" placeholder
heights="(min-width:1420px) 20%, (min-width:1320px) 25%, (min-width:1000px) 40%, (min-width:760px) 85%, (min-width:500px) 100%, 120%"
layout="responsive"
width="360"
height="216"
placeholder
alt="Curabitur convallis, urna quis pulvinar feugiat, purus diam posuere turpis, sit amet tincidunt purus justo et mi."
height="216" on="tap:headline-img-lightbox" role="img" tabindex="0">
on="tap:headline-img-lightbox"
role="img"
tabindex="0">
</amp-img>
</figure>

Expand Down