Skip to content
This repository was archived by the owner on Sep 13, 2023. It is now read-only.

Commit e623bc4

Browse files
committed
fix(docs): responsive youtube video demo
1 parent 2b25fc7 commit e623bc4

File tree

3 files changed

+20
-3
lines changed

3 files changed

+20
-3
lines changed

docs/_includes/demo.html

+3-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
<section id="contact" class="contact bg-primary">
22
<div class="container">
33
<h2 class="section-heading">Demo</h2>
4-
<iframe width="560" height="315" src="https://www.youtube.com/embed/lfWRwwmX9Q8" frameborder="0" allow="autoplay; encrypted-media" allowfullscreen></iframe>
4+
<div class="responsive-yt">
5+
<iframe width="560" height="315" src="https://www.youtube.com/embed/lfWRwwmX9Q8" title="YouTube video player" frameborder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share" allowfullscreen></iframe>
6+
</div>
57
</div>
68
</section>

docs/_includes/head.html

+17
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,23 @@
2828

2929
<link rel="icon" href="img/favicon.ico" />
3030

31+
<style>
32+
.responsive-yt {
33+
overflow:hidden;
34+
padding-bottom:56.25%;
35+
position:relative;
36+
height:0;
37+
}
38+
39+
.responsive-yt iframe {
40+
left:0;
41+
top:0;
42+
height:100%;
43+
width:100%;
44+
position:absolute;
45+
}
46+
</style>
47+
3148
<!-- HTML5 Shim and Respond.js IE8 support of HTML5 elements and media queries -->
3249
<!-- WARNING: Respond.js doesn't work if you view the page via file:// -->
3350
<!--[if lt IE 9]>

docs/_sass/_base.scss

-2
Original file line numberDiff line numberDiff line change
@@ -662,5 +662,3 @@ body {
662662
}
663663
}
664664
}
665-
666-

0 commit comments

Comments
 (0)