PluginProbe
Elementor Website Builder – more than just a page builder / 3.32.1
Elementor Website Builder – more than just a page builder v3.32.1
4.3.0-beta2 4.3.0-beta1 4.2.4 4.2.3 4.2.2 4.2.1 4.2.0 4.1.5 4.2.0-beta2 4.2.0-dev2 4.2.0-beta1 4.1.4 4.1.3 4.1.2 4.1.1 4.1.0 4.1.0-beta3 4.1.0-dev3 4.0.9 4.1.0-beta2 4.1.0-dev2 4.0.8 4.1.0-beta1 4.1.0-dev1 4.0.7 All 451 releases
elementor / assets / js / admin-feedback.js

admin-feedback.js in Elementor Website Builder – more than just a page builder 3.32.1, at assets/js/admin-feedback.js

136 lines 4.5 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 /*! elementor - v3.32.0 - 16-09-2025 */
2 /******/ (() => { // webpackBootstrap
3 /******/ "use strict";
4 /******/ var __webpack_modules__ = ({
5
6 /***/ "@wordpress/i18n":
7 /*!**************************!*\
8 !*** external "wp.i18n" ***!
9 \**************************/
10 /***/ ((module) => {
11
12 module.exports = wp.i18n;
13
14 /***/ })
15
16 /******/ });
17 /************************************************************************/
18 /******/ // The module cache
19 /******/ var __webpack_module_cache__ = {};
20 /******/
21 /******/ // The require function
22 /******/ function __webpack_require__(moduleId) {
23 /******/ // Check if module is in cache
24 /******/ var cachedModule = __webpack_module_cache__[moduleId];
25 /******/ if (cachedModule !== undefined) {
26 /******/ return cachedModule.exports;
27 /******/ }
28 /******/ // Create a new module (and put it into the cache)
29 /******/ var module = __webpack_module_cache__[moduleId] = {
30 /******/ // no module.id needed
31 /******/ // no module.loaded needed
32 /******/ exports: {}
33 /******/ };
34 /******/
35 /******/ // Execute the module function
36 /******/ __webpack_modules__[moduleId](module, module.exports, __webpack_require__);
37 /******/
38 /******/ // Return the exports of the module
39 /******/ return module.exports;
40 /******/ }
41 /******/
42 /************************************************************************/
43 // This entry needs to be wrapped in an IIFE because it needs to be isolated against other modules in the chunk.
44 (() => {
45 /*!************************************************!*\
46 !*** ../assets/dev/js/admin/admin-feedback.js ***!
47 \************************************************/
48 /* provided dependency */ var __ = __webpack_require__(/*! @wordpress/i18n */ "@wordpress/i18n")["__"];
49
50
51 (function ($) {
52 'use strict';
53
54 var ElementorAdminDialogApp = {
55 cacheElements: function cacheElements() {
56 this.cache = {
57 $deactivateLink: $('#the-list').find('[data-slug="elementor"] span.deactivate a'),
58 $dialogHeader: $('#elementor-deactivate-feedback-dialog-header'),
59 $dialogForm: $('#elementor-deactivate-feedback-dialog-form')
60 };
61 },
62 bindEvents: function bindEvents() {
63 var self = this;
64 self.cache.$deactivateLink.on('click', function (event) {
65 event.preventDefault();
66 self.getModal().show();
67 });
68 },
69 deactivate: function deactivate() {
70 location.href = this.cache.$deactivateLink.attr('href');
71 },
72 initModal: function initModal() {
73 var self = this,
74 modal;
75 self.getModal = function () {
76 if (!modal) {
77 modal = elementorCommon.dialogsManager.createWidget('lightbox', {
78 id: 'elementor-deactivate-feedback-modal',
79 headerMessage: self.cache.$dialogHeader,
80 message: self.cache.$dialogForm,
81 hide: {
82 onButtonClick: false
83 },
84 position: {
85 my: 'center',
86 at: 'center'
87 },
88 onReady: function onReady() {
89 DialogsManager.getWidgetType('lightbox').prototype.onReady.apply(this, arguments);
90 this.addButton({
91 name: 'submit',
92 text: __('Submit & Deactivate', 'elementor'),
93 callback: self.sendFeedback.bind(self)
94 });
95 this.addButton({
96 name: 'skip',
97 text: __('Skip & Deactivate', 'elementor'),
98 callback: function callback() {
99 self.deactivate();
100 }
101 });
102 },
103 onShow: function onShow() {
104 var $dialogModal = $('#elementor-deactivate-feedback-modal'),
105 radioSelector = '.elementor-deactivate-feedback-dialog-input';
106 $dialogModal.find(radioSelector).on('change', function () {
107 $dialogModal.attr('data-feedback-selected', $(this).val());
108 });
109 $dialogModal.find(radioSelector + ':checked').trigger('change');
110 }
111 });
112 }
113 return modal;
114 };
115 },
116 sendFeedback: function sendFeedback() {
117 var self = this,
118 formData = self.cache.$dialogForm.serialize();
119 self.getModal().getElements('submit').text('').addClass('elementor-loading');
120 $.post(ajaxurl, formData, this.deactivate.bind(this));
121 },
122 init: function init() {
123 this.initModal();
124 this.cacheElements();
125 this.bindEvents();
126 }
127 };
128 $(function () {
129 ElementorAdminDialogApp.init();
130 });
131 })(jQuery);
132 })();
133
134 /******/ })()
135 ;
136 //# sourceMappingURL=admin-feedback.js.map