(function(){aws.safeSpacesComp={init:function(){$(document).ready(function(){function n(){$.ajax({url:"https://safespaces.azurewebsites.net/Home/IsAlive",success:function(){t()},error:function(){}})}function t(){var n=$("[data-launch-safespace]").data("targetElement"),t=document.getElementById(n);$.ajax({url:"https://safespaces.azurewebsites.net/",success:function(n){i(n,t)}})}function i(n,t){var i=document.createElement("iframe");i.setAttribute("id","safe-space-iframe");t.appendChild(i);t.style.overflow="hidden";i.setAttribute("style","height:100%;width:100%;position:fixed;top:0;bottom:0;left:0;right:0;background-color:rgba(0,0,0,0.26);z-index:99990000");i.contentWindow.document.open();i.contentWindow.document.write(n);i.contentWindow.document.close();i.focus()}function r(){var n=document.getElementById("safe-space-iframe");n&&(n.parentNode.style.overflow="",n.parentNode.removeChild(n))}$(document).on("click","[data-launch-safespace]",function(t){t.stopPropagation();n(this);$("#safe-space").keyup(function(n){n.stopPropagation();n.keyCode==27&&r()})})})}};aws.safeSpacesComp.init()})()