Visualizer

document.addEventListener("DOMContentLoaded", function() { const params = new URLSearchParams(window.location.search); const srcParam = params.get("config_id"); // gets 1, 2, 3 const iframe = document.getElementById("imagine-configurator"); let src_url = "https://trimlite.imagine.io/configurator/4"; if (srcParam) { src_url = "https://trimlite.imagine.io/configurator/" + srcParam; } //dynamic email const parentOrigin = window.location.origin; // 4. Create the new src URL with the query parameter src_url = `${src_url}?parentOrigin=${encodeURIComponent(parentOrigin)}`; // 5. Find the iframe and set its src iframe.src = src_url; window.addEventListener('message', (event) => { console.log('Message received from iframe:', event.data); switch(event.data.type){ case "sendEmailList": const messageData = { label: 'emailList', value:{email:"[email protected]", clientName:"BHIDoors"} }; iframe.contentWindow.postMessage(messageData, "*"); break; } }); });

Due to the imminent threat of Hurricane Helene to Florida’s west coast and the Tampa Bay area, BHI will be suspending business operations for Thursday, September 26th, 2024. We are actively monitoring the situation but intend to reopen Friday, September 27th, 2024.”