Skip to content

Commit

Permalink
Stop YouTube embeds overflowing content
Browse files Browse the repository at this point in the history
  • Loading branch information
adamwoodnz committed Jan 15, 2024
1 parent dd5f98d commit 83844d1
Showing 1 changed file with 15 additions and 0 deletions.
15 changes: 15 additions & 0 deletions source/wp-content/themes/wporg-developer-2023/src/style/style.scss
Original file line number Diff line number Diff line change
Expand Up @@ -677,3 +677,18 @@ pre {
}
}
}

.embed-youtube {
position: relative;
max-width: 100%;
// Maintain aspect ratio.
padding-top: 56.25%;

.youtube-player {
position: absolute;
height: 100%;
width: 100%;
top: 0;
left: 0;
}
}

0 comments on commit 83844d1

Please sign in to comment.