CoreFiles by mySites.guru
iframe-height.es6.js21 lines, 787 bytes, from Joomla_4.0.0-alpha8-Alpha-Full_Package.zip
Raw History Compare with 4.0.0-alpha7
md5
920a8015204908e4db7aefc9104e43b1
sha1
44028a6c3a73d7f3de0b7f18d815170a75c2fcf5
sha256
2fa020e9d68b677d73196f218d09582a36fc700b6ae38c8644f65a0edaab12df
/**
* 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 - 2019 Open Source Matters, Inc. All rights reserved.
 * @license     GNU General Public License version 2 or later; see LICENSE.txt
 */
((window, document) => {
  window.iFrameHeight = iframe => {
    const doc = 'contentDocument' in iframe ? iframe.contentDocument : iframe.contentWindow.document;
    const 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-alpha8 to 4.0.0-alpha12. See them all, or every version of this file.