I assume the intended functionality of the creative example is to enable the user to toggle between the overlay and survey ad types, then click 'initialize the creative' and 'Start ad playback' to switch between SIMID creatives. If this is the case, it think modifying the line of code below may enable this functionality.. I'm not certain if this is the correct place to make this change, but I thought I'd mention it here.
createSimidIframe_() {
// const playerDiv = document.getElementById('ad_video_div'); // This element seems to be where the frame should go; Putting it here also allows you to toggle between 'overlay' and 'survey' ad types then initiating and starting the ad without having to reload the page.
const playerDiv = document.getElementById('player_div'); // current element
const simidIframe = document.createElement('iframe');
simidIframe.style.display = 'none';
// The target of the player to send messages to is the newly
// created iframe.
playerDiv.appendChild(simidIframe);
// Set up css to overlay the SIMID iframe over the video creative.
simidIframe.classList.add('simid_creative');
// Set the iframe creative, this should be an html creative.
...
return simidIframe;
}
I assume the intended functionality of the creative example is to enable the user to toggle between the overlay and survey ad types, then click 'initialize the creative' and 'Start ad playback' to switch between SIMID creatives. If this is the case, it think modifying the line of code below may enable this functionality.. I'm not certain if this is the correct place to make this change, but I thought I'd mention it here.