Less iframe related logging

This commit is contained in:
Scott Idem
2024-11-20 15:24:30 -05:00
parent 6b60c14159
commit f6378c1a23

View File

@@ -94,8 +94,10 @@ if (browser && iframe == 'true') {
$: if ($ae_loc.iframe_height && $ae_loc.iframe_height_modal_body) {
console.log('getting new dimensions for iframe:', $ae_loc.iframe_height, $ae_loc.iframe_height_modal_body);
$: if ($ae_loc.iframe && $ae_loc.iframe_height && $ae_loc.iframe_height_modal_body) {
if (log_lvl > 1) {
console.log('Getting new dimensions for iframe with modal:', $ae_loc.iframe_height, $ae_loc.iframe_height_modal_body);
}
let iframe_height = 0;
@@ -115,13 +117,14 @@ $: if ($ae_loc.iframe_height && $ae_loc.iframe_height_modal_body) {
// iframe_height = iframe_height + 50; // Just in case
}
console.log(`Suggested new iframe_height: ${iframe_height}`);
if (log_lvl > 1) {
console.log(`Suggested new iframe_height with modal: ${iframe_height}`);
}
window.parent.postMessage({'iframe_height': iframe_height}, "*"); // This should be in pixels
} else if ($ae_loc.iframe_height) {
console.log('setting new iframe_height:', $ae_loc.iframe_height);
// let iframe_height = $ae_loc.iframe_height;
} else if ($ae_loc.iframe && $ae_loc.iframe_height) {
if (log_lvl > 1) {
console.log('Suggested new iframe_height:', $ae_loc.iframe_height);
}
window.parent.postMessage({'iframe_height': $ae_loc.iframe_height}, "*"); // This should be in pixels
}