constrain gif backgrounds (with modifications) (#176)
* constrain gif backgrounds. fixes #159 * nit: move background-* styles to AutoplayVideo.html
This commit is contained in:
parent
8d5690d63d
commit
ebcade8035
|
@ -1,7 +1,7 @@
|
||||||
<video
|
<video
|
||||||
class="{{className || ''}}"
|
class="autoplay-video {{className || ''}}"
|
||||||
aria-label="{{ariaLabel || ''}}"
|
aria-label="{{ariaLabel || ''}}"
|
||||||
style="background: url({{poster}});"
|
style="background-image: url({{poster}});"
|
||||||
:poster
|
:poster
|
||||||
:width
|
:width
|
||||||
:height
|
:height
|
||||||
|
@ -11,4 +11,11 @@
|
||||||
loop
|
loop
|
||||||
webkit-playsinline
|
webkit-playsinline
|
||||||
playsinline
|
playsinline
|
||||||
/>
|
/>
|
||||||
|
<style>
|
||||||
|
.autoplay-video {
|
||||||
|
background-repeat: no-repeat;
|
||||||
|
background-position: center;
|
||||||
|
background-size: contain;
|
||||||
|
}
|
||||||
|
</style>
|
Loading…
Reference in New Issue