A platform for community discussion. Free, open, simple.
FIX: Enforce a fixed height on generic oneboxed videos
David Taylorfe20cb4b56e1
diff --git a/Gemfile b/Gemfileindex 88d2c4f81ae..7184bbc61fe 100644--- a/Gemfile+++ b/Gemfile@@ -36,7 +36,7 @@ gem 'redis-namespace'gem 'active_model_serializers', '~> 0.8.3'-gem 'onebox', '1.8.73'+gem 'onebox', '1.8.74'gem 'http_accept_language', '~>2.0.5', require: falsediff --git a/Gemfile.lock b/Gemfile.lockindex 88e2d49cea1..9ecacd4a270 100644--- a/Gemfile.lock+++ b/Gemfile.lock@@ -258,7 +258,7 @@ GEMomniauth-twitter (1.4.0)omniauth-oauth (~> 1.1)rack- onebox (1.8.73)+ onebox (1.8.74)htmlentities (~> 4.3)moneta (~> 1.0)multi_json (~> 1.11)@@ -512,7 +512,7 @@ DEPENDENCIESomniauth-oauth2omniauth-openidomniauth-twitter- onebox (= 1.8.73)+ onebox (= 1.8.74)openid-redis-storepgpry-navdiff --git a/app/assets/stylesheets/common/base/onebox.scss b/app/assets/stylesheets/common/base/onebox.scssindex 6832098e44a..2a9eaa8c15e 100644--- a/app/assets/stylesheets/common/base/onebox.scss+++ b/app/assets/stylesheets/common/base/onebox.scss@@ -565,3 +565,16 @@ aside.onebox.stackexchange .onebox-body {.onebox.google-photos-album {@extend .imgur-album;}++// Force oneboxed videos to 16:9 aspect ratio+.onebox.video-onebox {+ position: relative;+ padding: 0 0 56.25% 0;+ width: 100%;++ video {+ position: absolute;+ width: 100%;+ height: 100%;+ }+}