!function(){"use strict";var e=window.wp.i18n;document.querySelector("#customize-theme-controls").addEventListener("click",async function(t){if(t.target.matches("#ehp-begin-setup")){t.preventDefault();try{if(window.ehp_customizer.redirectTo)return void(window.location.href=window.ehp_customizer.redirectTo);const e={_wpnonce:window.ehp_customizer.nonce,slug:"hello-plus"},t=await wp.ajax.post("hello_biz_install_hp",e);if(!t.activateUrl)throw new Error(t.errorMessage);window.location.href=t.activateUrl}catch(t){alert((0,e.__)("Something went wrong. Please try again later. You can also contact our support at: wordpress.org/plugins/hello-plus","hello-biz"))}}})}();