From 58dc6b7c3654f2c4383e608763ba84f3e0ea4221 Mon Sep 17 00:00:00 2001 From: Hakim El Hattab Date: Tue, 16 May 2017 09:43:16 +0200 Subject: adjust controls layout when there are no vertical or horizontal slides in the deck --- css/reveal.css | 237 ++++++++++++++++++++++---------------------------------- css/reveal.scss | 116 ++++++++++++++------------- 2 files changed, 153 insertions(+), 200 deletions(-) (limited to 'css') diff --git a/css/reveal.css b/css/reveal.css index 32faedb..051f079 100644 --- a/css/reveal.css +++ b/css/reveal.css @@ -53,8 +53,7 @@ body { .reveal .slides section .fragment { opacity: 0; visibility: hidden; - -webkit-transition: all .2s ease; - transition: all .2s ease; } + transition: all .2s ease; } .reveal .slides section .fragment.visible { opacity: 1; visibility: inherit; } @@ -192,18 +191,18 @@ body { .reveal .controls { display: none; position: absolute; - top: 0; - right: 0; - bottom: 0; - left: 0; + top: auto; + bottom: 12px; + right: 12px; + left: auto; z-index: 1; color: #fff; pointer-events: none; } .reveal .controls button { position: absolute; padding: 0; - width: 52px; - height: 52px; + width: 46px; + height: 46px; background-color: transparent; border: 0; outline: 0; @@ -211,8 +210,7 @@ body { color: currentColor; -webkit-transform: scale(0.9999); transform: scale(0.9999); - -webkit-transition: all 0.2s ease; - transition: all 0.2s ease; + transition: all 0.2s ease; z-index: 2; pointer-events: auto; visibility: hidden; @@ -225,51 +223,50 @@ body { position: absolute; top: 0; left: 0; - width: 31px; + width: 32px; height: 6px; border-radius: 3px; background-color: currentColor; - -webkit-transition: all 0.15s ease, background-color 0.8s ease; - transition: all 0.15s ease, background-color 0.8s ease; + transition: all 0.15s ease, background-color 0.8s ease; -webkit-transform-origin: 3px 50%; transform-origin: 3px 50%; will-change: transform; } .reveal .controls button:before { - -webkit-transform: translateX(10.5px) translateY(23px) rotate(44deg); - transform: translateX(10.5px) translateY(23px) rotate(44deg); } + -webkit-transform: translateX(7px) translateY(20px) rotate(44deg); + transform: translateX(7px) translateY(20px) rotate(44deg); } .reveal .controls button:after { - -webkit-transform: translateX(10.5px) translateY(23px) rotate(-44deg); - transform: translateX(10.5px) translateY(23px) rotate(-44deg); } + -webkit-transform: translateX(7px) translateY(20px) rotate(-44deg); + transform: translateX(7px) translateY(20px) rotate(-44deg); } .reveal .controls button:hover:before { - -webkit-transform: translateX(10.5px) translateY(23px) rotate(40deg); - transform: translateX(10.5px) translateY(23px) rotate(40deg); } + -webkit-transform: translateX(7px) translateY(20px) rotate(40deg); + transform: translateX(7px) translateY(20px) rotate(40deg); } .reveal .controls button:hover:after { - -webkit-transform: translateX(10.5px) translateY(23px) rotate(-40deg); - transform: translateX(10.5px) translateY(23px) rotate(-40deg); } + -webkit-transform: translateX(7px) translateY(20px) rotate(-40deg); + transform: translateX(7px) translateY(20px) rotate(-40deg); } .reveal .controls button:active:before { - -webkit-transform: translateX(10.5px) translateY(23px) rotate(36deg); - transform: translateX(10.5px) translateY(23px) rotate(36deg); } + -webkit-transform: translateX(7px) translateY(20px) rotate(36deg); + transform: translateX(7px) translateY(20px) rotate(36deg); } .reveal .controls button:active:after { - -webkit-transform: translateX(10.5px) translateY(23px) rotate(-36deg); - transform: translateX(10.5px) translateY(23px) rotate(-36deg); } + -webkit-transform: translateX(7px) translateY(20px) rotate(-36deg); + transform: translateX(7px) translateY(20px) rotate(-36deg); } .reveal .controls .navigate-left { - top: 50%; - left: 8px; + right: 82px; + bottom: 18px; -webkit-transform: translateY(-50%); transform: translateY(-50%); } .reveal .controls .navigate-right { - top: 50%; - right: 8px; + right: 0; + bottom: 18px; -webkit-transform: translateY(-50%) rotate(180deg); transform: translateY(-50%) rotate(180deg); } .reveal .controls .navigate-up { - top: 8px; - left: 50%; + right: 18px; + bottom: 82px; -webkit-transform: translateX(-50%) rotate(90deg); transform: translateX(-50%) rotate(90deg); } .reveal .controls .navigate-down { - bottom: 8px; - left: 50%; + right: 18px; + bottom: 0; -webkit-transform: translateX(-50%) rotate(-90deg); transform: translateX(-50%) rotate(-90deg); } .reveal .controls[data-controls-back-arrows="faded"] .navigate-left.enabled, @@ -291,61 +288,38 @@ body { .reveal .controls .enabled:hover, .reveal .controls .enabled.fragmented:hover { opacity: 1; } - .reveal .controls[data-controls-layout="bottom-right"] { - top: auto; - bottom: 12px; - right: 12px; - left: auto; - -webkit-transform: scale(0.85); - transform: scale(0.85); - -webkit-transform-origin: 100% 100%; - transform-origin: 100% 100%; } - .reveal .controls[data-controls-layout="bottom-right"] .navigate-left, - .reveal .controls[data-controls-layout="bottom-right"] .navigate-right, - .reveal .controls[data-controls-layout="bottom-right"] .navigate-up, - .reveal .controls[data-controls-layout="bottom-right"] .navigate-down { - top: auto; - left: auto; } - .reveal .controls[data-controls-layout="bottom-right"] .navigate-left { - right: 92px; - bottom: 20px; } - .reveal .controls[data-controls-layout="bottom-right"] .navigate-right { - right: 0; - bottom: 20px; } - .reveal .controls[data-controls-layout="bottom-right"] .navigate-up { - right: 20px; - bottom: 92px; } - .reveal .controls[data-controls-layout="bottom-right"] .navigate-down { - right: 20px; - bottom: 0; } - @media screen and (max-width: 500px) { - .reveal .controls { - top: auto; - bottom: 12px; - right: 12px; - left: auto; - -webkit-transform: scale(0.85); - transform: scale(0.85); - -webkit-transform-origin: 100% 100%; - transform-origin: 100% 100%; } - .reveal .controls .navigate-left, - .reveal .controls .navigate-right, - .reveal .controls .navigate-up, - .reveal .controls .navigate-down { - top: auto; - left: auto; } - .reveal .controls .navigate-left { - right: 92px; - bottom: 20px; } - .reveal .controls .navigate-right { + @media screen and (min-width: 500px) { + .reveal .controls[data-controls-layout="edges"] { + top: 0; right: 0; - bottom: 20px; } - .reveal .controls .navigate-up { - right: 20px; - bottom: 92px; } - .reveal .controls .navigate-down { - right: 20px; - bottom: 0; } } + bottom: 0; + left: 0; } + .reveal .controls[data-controls-layout="edges"] .navigate-left, + .reveal .controls[data-controls-layout="edges"] .navigate-right, + .reveal .controls[data-controls-layout="edges"] .navigate-up, + .reveal .controls[data-controls-layout="edges"] .navigate-down { + bottom: auto; + right: auto; } + .reveal .controls[data-controls-layout="edges"] .navigate-left { + top: 50%; + left: 8px; } + .reveal .controls[data-controls-layout="edges"] .navigate-right { + top: 50%; + right: 8px; } + .reveal .controls[data-controls-layout="edges"] .navigate-up { + top: 8px; + left: 50%; } + .reveal .controls[data-controls-layout="edges"] .navigate-down { + bottom: 8px; + left: 50%; } } + +.reveal:not(.has-vertical-slides) .controls .navigate-left, +.reveal:not(.has-vertical-slides) .controls .navigate-right { + bottom: 0; } + +.reveal:not(.has-horizontal-slides) .controls .navigate-up, +.reveal:not(.has-horizontal-slides) .controls .navigate-down { + right: 0; } .reveal.has-dark-background .controls button:after, .reveal.has-dark-background .controls button:before { @@ -381,8 +355,7 @@ body { height: 100%; width: 0px; background-color: #000; - -webkit-transition: width 800ms cubic-bezier(0.26, 0.86, 0.44, 0.985); - transition: width 800ms cubic-bezier(0.26, 0.86, 0.44, 0.985); } + transition: width 800ms cubic-bezier(0.26, 0.86, 0.44, 0.985); } /********************************************* * SLIDE NUMBER @@ -445,26 +418,22 @@ body { z-index: 10; -webkit-transform-style: flat; transform-style: flat; - -webkit-transition: -webkit-transform-origin 800ms cubic-bezier(0.26, 0.86, 0.44, 0.985), -webkit-transform 800ms cubic-bezier(0.26, 0.86, 0.44, 0.985), visibility 800ms cubic-bezier(0.26, 0.86, 0.44, 0.985), opacity 800ms cubic-bezier(0.26, 0.86, 0.44, 0.985); - transition: transform-origin 800ms cubic-bezier(0.26, 0.86, 0.44, 0.985), transform 800ms cubic-bezier(0.26, 0.86, 0.44, 0.985), visibility 800ms cubic-bezier(0.26, 0.86, 0.44, 0.985), opacity 800ms cubic-bezier(0.26, 0.86, 0.44, 0.985); } + transition: -webkit-transform-origin 800ms cubic-bezier(0.26, 0.86, 0.44, 0.985), -webkit-transform 800ms cubic-bezier(0.26, 0.86, 0.44, 0.985), visibility 800ms cubic-bezier(0.26, 0.86, 0.44, 0.985), opacity 800ms cubic-bezier(0.26, 0.86, 0.44, 0.985); + transition: transform-origin 800ms cubic-bezier(0.26, 0.86, 0.44, 0.985), transform 800ms cubic-bezier(0.26, 0.86, 0.44, 0.985), visibility 800ms cubic-bezier(0.26, 0.86, 0.44, 0.985), opacity 800ms cubic-bezier(0.26, 0.86, 0.44, 0.985); } /* Global transition speed settings */ .reveal[data-transition-speed="fast"] .slides section { - -webkit-transition-duration: 400ms; - transition-duration: 400ms; } + transition-duration: 400ms; } .reveal[data-transition-speed="slow"] .slides section { - -webkit-transition-duration: 1200ms; - transition-duration: 1200ms; } + transition-duration: 1200ms; } /* Slide-specific transition speed overrides */ .reveal .slides section[data-transition-speed="fast"] { - -webkit-transition-duration: 400ms; - transition-duration: 400ms; } + transition-duration: 400ms; } .reveal .slides section[data-transition-speed="slow"] { - -webkit-transition-duration: 1200ms; - transition-duration: 1200ms; } + transition-duration: 1200ms; } .reveal .slides > section.stack { padding-top: 0; @@ -666,8 +635,7 @@ body { *********************************************/ .reveal .slides section[data-transition=zoom], .reveal.zoom .slides section:not([data-transition]) { - -webkit-transition-timing-function: ease; - transition-timing-function: ease; } + transition-timing-function: ease; } .reveal .slides > section[data-transition=zoom].past, .reveal .slides > section[data-transition~=zoom-out].past, @@ -859,13 +827,11 @@ body { .reveal.fade .slides > section > section:not([data-transition]) { -webkit-transform: none; transform: none; - -webkit-transition: opacity 0.5s; - transition: opacity 0.5s; } + transition: opacity 0.5s; } .reveal.fade.overview .slides section, .reveal.fade.overview .slides > section > section { - -webkit-transition: none; - transition: none; } + transition: none; } /********************************************* * NO TRANSITION @@ -874,8 +840,7 @@ body { .reveal.none .slides section:not([data-transition]) { -webkit-transform: none; transform: none; - -webkit-transition: none; - transition: none; } + transition: none; } /********************************************* * PAUSED MODE @@ -890,8 +855,7 @@ body { visibility: hidden; opacity: 0; z-index: 100; - -webkit-transition: all 1s ease; - transition: all 1s ease; } + transition: all 1s ease; } .reveal.paused .pause-overlay { visibility: visible; @@ -933,8 +897,7 @@ body { .reveal .no-transition, .reveal .no-transition * { - -webkit-transition: none !important; - transition: none !important; } + transition: none !important; } /********************************************* * PER-SLIDE BACKGROUNDS @@ -960,8 +923,7 @@ body { background-position: 50% 50%; background-repeat: no-repeat; background-size: cover; - -webkit-transition: all 800ms cubic-bezier(0.26, 0.86, 0.44, 0.985); - transition: all 800ms cubic-bezier(0.26, 0.86, 0.44, 0.985); } + transition: all 800ms cubic-bezier(0.26, 0.86, 0.44, 0.985); } .reveal .slide-background.stack { display: block; } @@ -994,8 +956,7 @@ body { /* Immediate transition style */ .reveal[data-background-transition=none] > .backgrounds .slide-background, .reveal > .backgrounds .slide-background[data-background-transition=none] { - -webkit-transition: none; - transition: none; } + transition: none; } /* Slide */ .reveal[data-background-transition=slide] > .backgrounds .slide-background, @@ -1077,8 +1038,7 @@ body { /* Zoom */ .reveal[data-background-transition=zoom] > .backgrounds .slide-background, .reveal > .backgrounds .slide-background[data-background-transition=zoom] { - -webkit-transition-timing-function: ease; - transition-timing-function: ease; } + transition-timing-function: ease; } .reveal[data-background-transition=zoom] > .backgrounds .slide-background.past, .reveal > .backgrounds .slide-background.past[data-background-transition=zoom] { @@ -1110,12 +1070,10 @@ body { /* Global transition speed settings */ .reveal[data-transition-speed="fast"] > .backgrounds .slide-background { - -webkit-transition-duration: 400ms; - transition-duration: 400ms; } + transition-duration: 400ms; } .reveal[data-transition-speed="slow"] > .backgrounds .slide-background { - -webkit-transition-duration: 1200ms; - transition-duration: 1200ms; } + transition-duration: 1200ms; } /********************************************* * OVERVIEW @@ -1141,8 +1099,7 @@ body { outline-offset: 10px; } .reveal.overview .slides section .fragment { opacity: 1; - -webkit-transition: none; - transition: none; } + transition: none; } .reveal.overview .slides section:after, .reveal.overview .slides section:before { display: none !important; } @@ -1166,13 +1123,11 @@ body { .reveal.overview .slides section, .reveal.overview-deactivating .slides section { - -webkit-transition: none; - transition: none; } + transition: none; } .reveal.overview .backgrounds .slide-background, .reveal.overview-deactivating .backgrounds .slide-background { - -webkit-transition: none; - transition: none; } + transition: none; } /********************************************* * RTL SUPPORT @@ -1202,17 +1157,14 @@ body { * PARALLAX BACKGROUND *********************************************/ .reveal.has-parallax-background .backgrounds { - -webkit-transition: all 0.8s ease; - transition: all 0.8s ease; } + transition: all 0.8s ease; } /* Global transition speed settings */ .reveal.has-parallax-background[data-transition-speed="fast"] .backgrounds { - -webkit-transition-duration: 400ms; - transition-duration: 400ms; } + transition-duration: 400ms; } .reveal.has-parallax-background[data-transition-speed="slow"] .backgrounds { - -webkit-transition-duration: 1200ms; - transition-duration: 1200ms; } + transition-duration: 1200ms; } /********************************************* * LINK PREVIEW OVERLAY @@ -1227,8 +1179,7 @@ body { background: rgba(0, 0, 0, 0.9); opacity: 0; visibility: hidden; - -webkit-transition: all 0.3s ease; - transition: all 0.3s ease; } + transition: all 0.3s ease; } .reveal .overlay.visible { opacity: 1; @@ -1246,8 +1197,7 @@ body { background-image: url(data:image/gif;base64,R0lGODlhIAAgAPMAAJmZmf%2F%2F%2F6%2Bvr8nJybW1tcDAwOjo6Nvb26ioqKOjo7Ozs%2FLy8vz8%2FAAAAAAAAAAAACH%2FC05FVFNDQVBFMi4wAwEAAAAh%2FhpDcmVhdGVkIHdpdGggYWpheGxvYWQuaW5mbwAh%2BQQJCgAAACwAAAAAIAAgAAAE5xDISWlhperN52JLhSSdRgwVo1ICQZRUsiwHpTJT4iowNS8vyW2icCF6k8HMMBkCEDskxTBDAZwuAkkqIfxIQyhBQBFvAQSDITM5VDW6XNE4KagNh6Bgwe60smQUB3d4Rz1ZBApnFASDd0hihh12BkE9kjAJVlycXIg7CQIFA6SlnJ87paqbSKiKoqusnbMdmDC2tXQlkUhziYtyWTxIfy6BE8WJt5YJvpJivxNaGmLHT0VnOgSYf0dZXS7APdpB309RnHOG5gDqXGLDaC457D1zZ%2FV%2FnmOM82XiHRLYKhKP1oZmADdEAAAh%2BQQJCgAAACwAAAAAIAAgAAAE6hDISWlZpOrNp1lGNRSdRpDUolIGw5RUYhhHukqFu8DsrEyqnWThGvAmhVlteBvojpTDDBUEIFwMFBRAmBkSgOrBFZogCASwBDEY%2FCZSg7GSE0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At7gHiRpFaLNrrq8HNgAJA70AWxQIH1%2BvsYMDAzZQPC9VCNkDWUhGkuE5PxJNwiUK4UfLzOlD4WvzAHaoG9nxPi5d%2BjYUqfAhhykOFwJWiAAAIfkECQoAAAAsAAAAACAAIAAABPAQyElpUqnqzaciSoVkXVUMFaFSwlpOCcMYlErAavhOMnNLNo8KsZsMZItJEIDIFSkLGQoQTNhIsFehRww2CQLKF0tYGKYSg%2BygsZIuNqJksKgbfgIGepNo2cIUB3V1B3IvNiBYNQaDSTtfhhx0CwVPI0UJe0%2Bbm4g5VgcGoqOcnjmjqDSdnhgEoamcsZuXO1aWQy8KAwOAuTYYGwi7w5h%2BKr0SJ8MFihpNbx%2B4Erq7BYBuzsdiH1jCAzoSfl0rVirNbRXlBBlLX%2BBP0XJLAPGzTkAuAOqb0WT5AH7OcdCm5B8TgRwSRKIHQtaLCwg1RAAAOwAAAAAAAAAAAA%3D%3D); visibility: visible; opacity: 0.6; - -webkit-transition: all 0.3s ease; - transition: all 0.3s ease; } + transition: all 0.3s ease; } .reveal .overlay header { position: absolute; @@ -1288,7 +1238,6 @@ body { .reveal .overlay .viewport { position: absolute; display: -webkit-box; - display: -webkit-flex; display: -ms-flexbox; display: flex; top: 40px; @@ -1304,8 +1253,7 @@ body { border: 0; opacity: 0; visibility: hidden; - -webkit-transition: all 0.3s ease; - transition: all 0.3s ease; } + transition: all 0.3s ease; } .reveal .overlay.overlay-preview.loaded .viewport iframe { opacity: 1; @@ -1322,8 +1270,7 @@ body { .reveal .overlay.overlay-preview .x-frame-error { opacity: 0; - -webkit-transition: opacity 0.3s ease 0.3s; - transition: opacity 0.3s ease 0.3s; } + transition: opacity 0.3s ease 0.3s; } .reveal .overlay.overlay-preview.loaded .x-frame-error { opacity: 1; } @@ -1373,8 +1320,7 @@ body { bottom: 20px; z-index: 30; cursor: pointer; - -webkit-transition: all 400ms ease; - transition: all 400ms ease; } + transition: all 400ms ease; } .reveal.overview .playback { opacity: 0; @@ -1402,8 +1348,7 @@ body { position: relative; padding: 0 2px; pointer-events: none; - -webkit-transition: all 400ms ease; - transition: all 400ms ease; + transition: all 400ms ease; -webkit-transform-origin: 50% 0%; transform-origin: 50% 0%; -webkit-transform-style: preserve-3d; diff --git a/css/reveal.scss b/css/reveal.scss index 41d5744..8785d4a 100644 --- a/css/reveal.scss +++ b/css/reveal.scss @@ -236,13 +236,14 @@ body { *********************************************/ .reveal .controls { - $size: 52px; - $length: floor($size * 0.6); - $spacing: 8px; + $size: 46px; + $length: floor($size * 0.7); $thickness: 6px; $angle: 44deg; $angleHover: 40deg; $angleActive: 36deg; + $spacing: 12px; + $innerSpacing: 18px; @mixin arrowTransform( $angle ) { &:before { @@ -256,10 +257,10 @@ body { display: none; position: absolute; - top: 0; - right: 0; - bottom: 0; - left: 0; + top: auto; + bottom: $spacing; + right: $spacing; + left: auto; z-index: 1; color: #fff; pointer-events: none; @@ -315,26 +316,26 @@ body { } .navigate-left { - top: 50%; - left: $spacing; + right: $size + $innerSpacing*2; + bottom: $innerSpacing; transform: translateY(-50%); } .navigate-right { - top: 50%; - right: $spacing; + right: 0; + bottom: $innerSpacing; transform: translateY(-50%) rotate( 180deg ); } .navigate-up { - top: $spacing; - left: 50%; + right: $innerSpacing; + bottom: $size + $innerSpacing*2; transform: translateX(-50%) rotate( 90deg ); } .navigate-down { - bottom: $spacing; - left: 50%; + right: $innerSpacing; + bottom: 0; transform: translateX(-50%) rotate( -90deg ); } @@ -376,52 +377,59 @@ body { opacity: 1; } - @mixin bottom-right-controls() { - $spacing: 12px; - $innerSpacing: 20px; + @media screen and (min-width: 500px) { - & { - top: auto; - bottom: $spacing; - right: $spacing; - left: auto; - transform: scale(0.85); - transform-origin: 100% 100%; - } + $spacing: 8px; - .navigate-left, - .navigate-right, - .navigate-up, - .navigate-down { - top: auto; - left: auto; - } + &[data-controls-layout="edges"] { + & { + top: 0; + right: 0; + bottom: 0; + left: 0; + } - .navigate-left { - right: $size + $innerSpacing*2; - bottom: $innerSpacing; - } - .navigate-right { - right: 0; - bottom: $innerSpacing; - } - .navigate-up { - right: $innerSpacing; - bottom: $size + $innerSpacing*2; - } - .navigate-down { - right: $innerSpacing; - bottom: 0; + .navigate-left, + .navigate-right, + .navigate-up, + .navigate-down { + bottom: auto; + right: auto; + } + + .navigate-left { + top: 50%; + left: $spacing; + } + + .navigate-right { + top: 50%; + right: $spacing; + } + + .navigate-up { + top: $spacing; + left: 50%; + } + + .navigate-down { + bottom: $spacing; + left: 50%; + } } - } - &[data-controls-layout="bottom-right"] { - @include bottom-right-controls() } +} - @media screen and (max-width: 500px) { - @include bottom-right-controls() - } +// Adjust the layout when there are no vertical slides +.reveal:not(.has-vertical-slides) .controls .navigate-left, +.reveal:not(.has-vertical-slides) .controls .navigate-right { + bottom: 0; +} + +.reveal:not(.has-horizontal-slides) .controls .navigate-up, +.reveal:not(.has-horizontal-slides) .controls .navigate-down { + right: 0; } .reveal.has-dark-background .controls button:after, -- cgit v1.2.3