Don't hardcode height for videos - this was a workaround for MediaElement internals causing problems. Responsive videos now work properly and don't cause extra whitespace.

Fixes MediaElement by hand in the interim: https://github.com/johndyer/mediaelement/pull/1337
Video playlists were completely broken by this.

Fixes #30078.



git-svn-id: https://develop.svn.wordpress.org/trunk@30082 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Scott Taylor
2014-10-29 00:46:15 +00:00
parent acbf0229cf
commit e6bbbb3db9
3 changed files with 7 additions and 6 deletions
+2 -5
View File
@@ -1855,14 +1855,11 @@ function wp_video_shortcode( $attr, $content = '' ) {
}
$html .= '</video>';
$width_rule = $height_rule = '';
$width_rule = '';
if ( ! empty( $atts['width'] ) ) {
$width_rule = sprintf( 'width: %dpx; ', $atts['width'] );
}
if ( ! empty( $atts['height'] ) ) {
$height_rule = sprintf( 'height: %dpx; ', $atts['height'] );
}
$output = sprintf( '<div style="%s%s" class="wp-video">%s</div>', $width_rule, $height_rule, $html );
$output = sprintf( '<div style="%s" class="wp-video">%s</div>', $width_rule, $html );
/**
* Filter the output of the video shortcode.