// let params = new URLSearchParams(window.location.href),
// checkparams = params.get('tpae_user_review');
const { __ } = wp.i18n;
// if( checkparams ) {
document.addEventListener("DOMContentLoaded", function () {
var reviewContentCon = document.querySelector('.tpae-update-popup-container');
const updateReviewContent = () => {
let review_container = `
`;
reviewContentCon.innerHTML = review_container;
};
jQuery(document).on('click', '.toplevel_page_theplus_welcome_page .tpae-update-popup-container .tp-update-popup-inner .theplus-i-cross', function(e) {
e.preventDefault();
jQuery('.tpae-update-popup-container').hide();
var menuItem = document.querySelector('#toplevel_page_theplus_welcome_page');
if (menuItem) {
menuItem.classList.remove('tpae-admin-notice-active');
}
jQuery.ajax({
url: ajaxurl,
type: 'POST',
data: {
action: 'tpae_update_popup_dismiss',
security: tpaeUpdatePopup.nonce,
type: 'tpae_update_popup_close',
},
success: function(response) {
jQuery('.tpae-update-popup-container').hide();
var menuItem = document.querySelector('#toplevel_page_theplus_welcome_page');
if (menuItem) {
menuItem.classList.remove('tpae-admin-notice-active');
}
}
});
});
const hash = window.location.href;
if( hash.includes('theplus_welcome_page') ) {
updateReviewContent();
}
});
// }