Merge pull request #3012 from Raven24/oembed-fixes
small fixes for oembed in posts [ci skip]
This commit is contained in:
commit
e0c71e13de
2 changed files with 6 additions and 5 deletions
|
|
@ -3,7 +3,7 @@ app.views.Content = app.views.StreamObject.extend({
|
|||
events: {
|
||||
"click .oembed .thumb": "showOembedContent"
|
||||
},
|
||||
|
||||
|
||||
presenter : function(){
|
||||
return _.extend(this.defaultPresenter(), {
|
||||
text : app.helpers.textFormatter(this.model),
|
||||
|
|
@ -37,10 +37,10 @@ app.views.Content = app.views.StreamObject.extend({
|
|||
|
||||
showOembedContent: function() {
|
||||
var oembed = $(this.el).find(".oembed");
|
||||
var embedHTML = $( this.embedHTML() );
|
||||
var paramSeparator = ( /\\?/.test(embedHTML.attr("href")) ) ? "&" : "?";
|
||||
embedHTML.attr("src", embedHTML.attr("src") + paramSeparator + "autoplay=1");
|
||||
oembed.html( embedHTML );
|
||||
var insertHTML = $( this.embedHTML() );
|
||||
var paramSeparator = ( /\?/.test(insertHTML.attr("src")) ) ? "&" : "?";
|
||||
insertHTML.attr("src", insertHTML.attr("src") + paramSeparator + "autoplay=1");
|
||||
oembed.html( insertHTML );
|
||||
}
|
||||
});
|
||||
|
||||
|
|
|
|||
|
|
@ -1830,6 +1830,7 @@ ul#press_logos
|
|||
.collapsible
|
||||
.oembed
|
||||
:background url('/images/ajax-loader2.gif') no-repeat center center
|
||||
:display inline-block
|
||||
|
||||
.thumb
|
||||
:position relative
|
||||
|
|
|
|||
Loading…
Reference in a new issue