From 3e3ec01c6381b072b829a65fef8aff7da1d991eb Mon Sep 17 00:00:00 2001 From: "David A. Kennedy" Date: Tue, 17 Oct 2017 22:49:17 +0000 Subject: [PATCH] Twenty Seventeen: Fix double bottom-margins below embeds Corrects an issue where both the containing paragraph and embed had bottom margins, causing unwanted extra space. Props westonruter. Fixes #42118. git-svn-id: https://develop.svn.wordpress.org/trunk@41888 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-content/themes/twentyseventeen/style.css | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/src/wp-content/themes/twentyseventeen/style.css b/src/wp-content/themes/twentyseventeen/style.css index 7936adb07e..9a82c945e1 100644 --- a/src/wp-content/themes/twentyseventeen/style.css +++ b/src/wp-content/themes/twentyseventeen/style.css @@ -2820,6 +2820,14 @@ object { max-width: 100%; } +/* Remove bottom on embeds that wrapped in paragraphs via wpautop. */ + +p > embed:only-child, +p > iframe:only-child, +p > object:only-child { + margin-bottom: 0; +} + .wp-caption, .gallery-caption { color: #666;