From 941b86b6c390bf91eeb6b47f12ff8bf830e28b0a Mon Sep 17 00:00:00 2001 From: Hakim El Hattab Date: Wed, 18 Jan 2017 10:43:29 +0100 Subject: works with video, defaults to (same as for images) --- css/reveal.css | 8 +++++++- css/reveal.scss | 4 ++++ 2 files changed, 11 insertions(+), 1 deletion(-) (limited to 'css') diff --git a/css/reveal.css b/css/reveal.css index 430dcde..18bb25c 100644 --- a/css/reveal.css +++ b/css/reveal.css @@ -865,7 +865,13 @@ body { max-width: none; max-height: none; top: 0; - left: 0; } + left: 0; + -o-object-fit: cover; + object-fit: cover; } + +.reveal .slide-background[data-background-size="contain"] video { + -o-object-fit: contain; + object-fit: contain; } /* Immediate transition style */ .reveal[data-background-transition=none] > .backgrounds .slide-background, diff --git a/css/reveal.scss b/css/reveal.scss index 22fb3fe..68ff56f 100644 --- a/css/reveal.scss +++ b/css/reveal.scss @@ -898,7 +898,11 @@ body { max-height: none; top: 0; left: 0; + object-fit: cover; } + .reveal .slide-background[data-background-size="contain"] video { + object-fit: contain; + } /* Immediate transition style */ .reveal[data-background-transition=none]>.backgrounds .slide-background, -- cgit v1.2.3