vimeovimeo-apivimeo-player

How to stretch a video in vimeo?


How to make an object-fit: cover; as in css. The video is cropped on the sides. How to fix it ? I want to put it in the background of website.

iframe code : <iframe src="https://player.vimeo.com/video/767578091?background=1&muted=1&autoplay=1&dnt=1" width="100%" height="100%" frameborder="0" allow="autoplay; encrypted-media;" allowfullscreen></iframe> enter image description here

I read this guide, but it only helped to make it a background. https://vimeo.zendesk.com/hc/en-us/articles/115011183028-Embedding-background-and-chromeless-videos


Solution

  • You can follow this article here about the embed options : https://github.com/vimeo/player.js#embed-options

    On of the options you have is :

    responsive false Resize according to the parent element (experimental)

    Can you try that and update us,