CoreFiles by mySites.guru
iframe-height.js21 lines, 797 bytes, from Joomla_4.0.0-beta4-Beta-Full_Package.zip
Raw History Compare with 4.0.0-beta3
md5
71415b68d47909cbd08e70d6bd080985
sha1
cb1f610079b0142ad80e03df806d69685ea0b6a6
sha256
282375042d2230d3b20e99722ad79ebad3f7350cd2dd4f7d191f6a47abd5174c
/**
* PLEASE DO NOT MODIFY THIS FILE. WORK ON THE ES6 VERSION.
* OTHERWISE YOUR CHANGES WILL BE REPLACED ON THE NEXT BUILD.
**/

/**
 * @copyright   Copyright (C) 2005 - 2020 Open Source Matters, Inc. All rights reserved.
 * @license     GNU General Public License version 2 or later; see LICENSE.txt
 */
(function (window, document) {
  window.iFrameHeight = function (iframe) {
    var doc = 'contentDocument' in iframe ? iframe.contentDocument : iframe.contentWindow.document;
    var height = parseInt(doc.body.scrollHeight, 10);

    if (!document.all) {
      iframe.style.height = "".concat(parseInt(height, 10) + 60, "px");
    } else if (document.all && iframe.id) {
      document.all[iframe.id].style.height = "".concat(parseInt(height, 10) + 20, "px");
    }
  };
})(window, document);

The same content is in 5 releases, Joomla 4.0.0-beta to 4.0.0-beta5. See them all, or every version of this file.