From 87bd3c7e1132854b7abe3148d1f34b266806b4ae Mon Sep 17 00:00:00 2001 From: Tom Arild Jakobsen Date: Thu, 11 May 2017 17:09:44 +0200 Subject: [PATCH] Resize h5p container instead of body by default. HFP-574 --- js/h5p-confirmation-dialog.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/js/h5p-confirmation-dialog.js b/js/h5p-confirmation-dialog.js index 22ca96c..a6dd998 100644 --- a/js/h5p-confirmation-dialog.js +++ b/js/h5p-confirmation-dialog.js @@ -352,7 +352,8 @@ H5P.ConfirmationDialog = (function (EventDispatcher) { * @param {number|null} minHeight */ this.setViewPortMinimumHeight = function(minHeight) { - document.body.style.minHeight = (typeof minHeight === 'number') ? (minHeight + 'px') : minHeight; + var container = document.querySelector('.h5p-container') || document.body; + container.style.minHeight = (typeof minHeight === 'number') ? (minHeight + 'px') : minHeight; }; }