Is there detailed documentation on amp-video-container? I am trying to understand how I can use amp-video-container in amp-story to ensure my video is not cut off and viewable in full.
https://ampbyexample.com/advanced/video_carousels_with_amp-carousel/
<div>
<div class="amp-video-container">
<amp-reach-player class="amp-video"
data-embed-id="default"
layout="responsive"
width="560"
height="315">
</amp-reach-player>
</div>
</div>
Also, do I need to include this script tag when using amp-video-container?
<script async custom-element="amp-carousel" src="https://cdn.ampproject.org/v0/amp-carousel-0.1.js"></script>
If you want the full video to be shown, you can use CSS:
amp-video video {
object-fit: contain;
}
In the code snippet you've provided, there is nothing special about amp-video-container
; it is simply a CSS class name. You do not need any additional scripts to use this CSS, and this is unrelated to amp-carousel
.