Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save aligator28/9e2d1d500aa9852da3fe953f8b90b4c6 to your computer and use it in GitHub Desktop.
Save aligator28/9e2d1d500aa9852da3fe953f8b90b4c6 to your computer and use it in GitHub Desktop.
контейнер для непропорционального контента
.main-block__video {
position: relative;
width: 100%;
height: 0;
padding-bottom: calc(100% / 1.78); // Just proportions of video 16:9 (You can use 100% and You shoud divide width on 1.78 (40% / 1.78 = 22.47%)
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment