Skip to content

Commit

Permalink
Set cap on embedded video height
Browse files Browse the repository at this point in the history
  • Loading branch information
amits97 committed Oct 18, 2023
1 parent 67f9789 commit 0a1c340
Show file tree
Hide file tree
Showing 3 changed files with 23 additions and 20 deletions.
4 changes: 2 additions & 2 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "naadan-chords",
"version": "0.78.5",
"version": "0.78.6",
"homepage": "https://www.naadanchords.com/",
"private": true,
"dependencies": {
Expand Down
37 changes: 20 additions & 17 deletions src/components/YouTubeEmbed.css
Original file line number Diff line number Diff line change
@@ -1,28 +1,31 @@
.YouTubeEmbed video, .YouTubeEmbed embed, .YouTubeEmbed iframe, .YouTubeEmbed object {
.YouTubeEmbed video,
.YouTubeEmbed embed,
.YouTubeEmbed iframe,
.YouTubeEmbed object {
max-width: 100%;
}

.YouTubeEmbed .video-wrapper {
width: 1280px;
max-width: 100%;
margin-bottom: 2em;
width: 1280px;
max-width: 100%;
margin-bottom: 2em;
max-height: 1070px;
}

.YouTubeEmbed .video-container {
position: relative;
padding-bottom: 56.25%;
padding-top: 30px;
height: 0;
overflow: hidden;
position: relative;
padding-bottom: 56.25%;
padding-top: 30px;
height: 0;
overflow: hidden;
}

.YouTubeEmbed .video-container iframe,
.YouTubeEmbed .video-container object,
.YouTubeEmbed .video-container iframe,
.YouTubeEmbed .video-container object,
.YouTubeEmbed .video-container embed {
position: absolute;
top: 0;
left: 0;
width: 100%;
height: 100%;
position: absolute;
top: 0;
left: 0;
width: 100%;
height: 100%;
}

0 comments on commit 0a1c340

Please sign in to comment.