When editing/viewing the details of a [video] shortcode that has Vimeo as its source, and Froogaloop has not already been lazy-loaded, check the details of the state's model for the video src, instead of the HTML element.
See #29267. Built from https://develop.svn.wordpress.org/trunk@31625 git-svn-id: http://core.svn.wordpress.org/trunk@31606 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
@@ -820,7 +820,7 @@ MediaDetails = AttachmentDisplay.extend({
|
||||
return;
|
||||
}
|
||||
|
||||
if ( this.media.src.indexOf( 'vimeo' ) > -1 && ! ( 'Froogaloop' in window ) ) {
|
||||
if ( this.model.get( 'src' ).indexOf( 'vimeo' ) > -1 && ! ( 'Froogaloop' in window ) ) {
|
||||
baseSettings = wp.media.mixin.mejsSettings;
|
||||
this.scriptXhr = $.getScript( baseSettings.pluginPath + 'froogaloop.min.js', _.bind( this.loadPlayer, this ) );
|
||||
} else {
|
||||
|
||||
2
wp-includes/js/media/audio-video.min.js
vendored
2
wp-includes/js/media/audio-video.min.js
vendored
File diff suppressed because one or more lines are too long
@@ -93,7 +93,7 @@ MediaDetails = AttachmentDisplay.extend({
|
||||
return;
|
||||
}
|
||||
|
||||
if ( this.media.src.indexOf( 'vimeo' ) > -1 && ! ( 'Froogaloop' in window ) ) {
|
||||
if ( this.model.get( 'src' ).indexOf( 'vimeo' ) > -1 && ! ( 'Froogaloop' in window ) ) {
|
||||
baseSettings = wp.media.mixin.mejsSettings;
|
||||
this.scriptXhr = $.getScript( baseSettings.pluginPath + 'froogaloop.min.js', _.bind( this.loadPlayer, this ) );
|
||||
} else {
|
||||
|
||||
Reference in New Issue
Block a user