Fix overview spacing for disabled auto layout (#3291)

* Fix overlap in overview when config.disableLayout === true

* run gulp js
after commit 9193e5cd5d6d1aa234803b753c6d032b801a8221

---------

Co-authored-by: Hakim El Hattab <hakim.elhattab@gmail.com>
This commit is contained in:
Elliot" Constantin H 2023-02-22 04:01:21 +01:00 committed by GitHub
parent 7de6ccb65b
commit dcae8a4dc9
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 13 additions and 4 deletions

View File

@ -471,6 +471,8 @@ Reveal.on( 'customevent', function() {
center: true, center: true,
hash: true, hash: true,
// disableLayout: true,
// Learn about plugins: https://revealjs.com/plugins/ // Learn about plugins: https://revealjs.com/plugins/
plugins: [ RevealZoom, RevealNotes, RevealSearch, RevealMarkdown, RevealHighlight ] plugins: [ RevealZoom, RevealNotes, RevealSearch, RevealMarkdown, RevealHighlight ]
}); });

View File

@ -1006,11 +1006,18 @@ export default function( revealElement, options ) {
* @param {number} [presentationHeight=dom.wrapper.offsetHeight] * @param {number} [presentationHeight=dom.wrapper.offsetHeight]
*/ */
function getComputedSlideSize( presentationWidth, presentationHeight ) { function getComputedSlideSize( presentationWidth, presentationHeight ) {
let width = config.width;
let height = config.height;
if (config.disableLayout) {
width = dom.slides.offsetWidth;
height = dom.slides.offsetHeight;
}
const size = { const size = {
// Slide size // Slide size
width: config.width, width: width,
height: config.height, height: height,
// Presentation size // Presentation size
presentationWidth: presentationWidth || dom.wrapper.offsetWidth, presentationWidth: presentationWidth || dom.wrapper.offsetWidth,