diff --git a/css/glowingbear.css b/css/glowingbear.css index d171615..cf54fed 100644 --- a/css/glowingbear.css +++ b/css/glowingbear.css @@ -309,6 +309,10 @@ div.embed img.embed { max-width: 100%; } +video.embed { + max-width: 100%; +} + div.colourbox { display: inline-block; border-radius: 3px; diff --git a/js/plugins.js b/js/plugins.js index b282d13..8a84758 100644 --- a/js/plugins.js +++ b/js/plugins.js @@ -267,6 +267,15 @@ plugins.factory('userPlugins', function() { } }); + /* + * mp4 video Preview + */ + var videoPlugin = new UrlPlugin('video', function(url) { + if (url.match(/\.(mp4|webm|ogv)\b/i)) { + return ''; + } + }); + /* * Cloud Music Embedded Players */ @@ -382,7 +391,7 @@ plugins.factory('userPlugins', function() { }); return { - plugins: [youtubePlugin, dailymotionPlugin, allocinePlugin, imagePlugin, spotifyPlugin, cloudmusicPlugin, googlemapPlugin, asciinemaPlugin, yrPlugin, gistPlugin, tweetPlugin, vinePlugin] + plugins: [youtubePlugin, dailymotionPlugin, allocinePlugin, imagePlugin, videoPlugin, spotifyPlugin, cloudmusicPlugin, googlemapPlugin, asciinemaPlugin, yrPlugin, gistPlugin, tweetPlugin, vinePlugin] };