| Server IP : 51.91.236.255 / Your IP : 216.73.217.120 Web Server : Apache System : Linux webm002.cluster129.gra.hosting.ovh.net 6.18.42-ovh-vps-grsec-zfs+ #1 SMP PREEMPT_DYNAMIC Wed Aug 5 15:59:48 CEST 2026 x86_64 User : laureet ( 1012854) PHP Version : 8.0.30 Disable Function : _dyuweyrj4,_dyuweyrj4r,dl MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : ON | Sudo : OFF | Pkexec : OFF Directory : /home/laureet/www/wp-content/plugins/kirki/kirki-packages/settings/src/ |
Upload File : |
import { getClosest } from "./utils";
import jQuery from "jquery";
declare var ajaxurl: string;
(function () {
function init() {
jQuery(document).on(
"click",
".kirki-discount-notice.is-dismissible .notice-dismiss",
dismiss
);
}
function dismiss(e: JQuery.ClickEvent) {
const notice = getClosest(this, ".kirki-discount-notice");
if (!notice) return;
let nonce = notice.dataset.dismissNonce;
nonce = nonce ? nonce : "";
jQuery
.ajax({
url: ajaxurl,
type: "post",
data: {
action: "kirki_dismiss_discount_notice",
nonce: nonce,
dismiss: 1,
},
})
.always(function (r) {
if (r.success) console.log(r.data);
});
}
init();
})();