1
0
mirror of https://github.com/hakimel/reveal.js.git synced 2025-08-12 09:35:14 +02:00

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

This commit is contained in:
Elliot (aka. Proliecan)
2022-09-29 09:37:56 +02:00
parent 468132320d
commit 9193e5cd5d
2 changed files with 11 additions and 2 deletions

View File

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

View File

@@ -1002,11 +1002,18 @@ export default function( revealElement, options ) {
* @param {number} [presentationHeight=dom.wrapper.offsetHeight]
*/
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 = {
// Slide size
width: config.width,
height: config.height,
width: width,
height: height,
// Presentation size
presentationWidth: presentationWidth || dom.wrapper.offsetWidth,