This repository has been archived on 2026-01-08. You can view files and clone it. You cannot open issues or pull requests or push a commit.
Files
plyr/src/less/components/embed.less
T
2017-11-14 17:27:40 +01:00

36 lines
894 B
Plaintext

// --------------------------------------------------------------
// Embedded players
// YouTube, Vimeo, etc
// --------------------------------------------------------------
.plyr__video-embed {
// Default to 16:9 ratio but this is set by JavaScript based on config
@padding: ((100 / 16) * 9);
@height: 200;
@offset: unit((@height - @padding) / (@height / 50), ~'%');
padding-bottom: unit(@padding, ~'%');
height: 0;
iframe {
position: absolute;
top: 0;
left: 0;
width: 100%;
height: 100%;
border: 0;
user-select: none;
}
// Vimeo hack
> div {
position: relative;
padding-bottom: unit(@height, ~'%');
transform: translateY(-@offset);
}
}
// To allow mouse events to be captured if full support
.plyr--full-ui .plyr__video-embed iframe {
pointer-events: none;
}