/******/ (function(modules) { // webpackBootstrap
/******/ 	// The module cache
/******/ 	var installedModules = {};
/******/
/******/ 	// The require function
/******/ 	function __webpack_require__(moduleId) {
/******/
/******/ 		// Check if module is in cache
/******/ 		if(installedModules[moduleId]) {
/******/ 			return installedModules[moduleId].exports;
/******/ 		}
/******/ 		// Create a new module (and put it into the cache)
/******/ 		var module = installedModules[moduleId] = {
/******/ 			i: moduleId,
/******/ 			l: false,
/******/ 			exports: {}
/******/ 		};
/******/
/******/ 		// Execute the module function
/******/ 		modules[moduleId].call(module.exports, module, module.exports, __webpack_require__);
/******/
/******/ 		// Flag the module as loaded
/******/ 		module.l = true;
/******/
/******/ 		// Return the exports of the module
/******/ 		return module.exports;
/******/ 	}
/******/
/******/
/******/ 	// expose the modules object (__webpack_modules__)
/******/ 	__webpack_require__.m = modules;
/******/
/******/ 	// expose the module cache
/******/ 	__webpack_require__.c = installedModules;
/******/
/******/ 	// define getter function for harmony exports
/******/ 	__webpack_require__.d = function(exports, name, getter) {
/******/ 		if(!__webpack_require__.o(exports, name)) {
/******/ 			Object.defineProperty(exports, name, { enumerable: true, get: getter });
/******/ 		}
/******/ 	};
/******/
/******/ 	// define __esModule on exports
/******/ 	__webpack_require__.r = function(exports) {
/******/ 		if(typeof Symbol !== 'undefined' && Symbol.toStringTag) {
/******/ 			Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
/******/ 		}
/******/ 		Object.defineProperty(exports, '__esModule', { value: true });
/******/ 	};
/******/
/******/ 	// create a fake namespace object
/******/ 	// mode & 1: value is a module id, require it
/******/ 	// mode & 2: merge all properties of value into the ns
/******/ 	// mode & 4: return value when already ns object
/******/ 	// mode & 8|1: behave like require
/******/ 	__webpack_require__.t = function(value, mode) {
/******/ 		if(mode & 1) value = __webpack_require__(value);
/******/ 		if(mode & 8) return value;
/******/ 		if((mode & 4) && typeof value === 'object' && value && value.__esModule) return value;
/******/ 		var ns = Object.create(null);
/******/ 		__webpack_require__.r(ns);
/******/ 		Object.defineProperty(ns, 'default', { enumerable: true, value: value });
/******/ 		if(mode & 2 && typeof value != 'string') for(var key in value) __webpack_require__.d(ns, key, function(key) { return value[key]; }.bind(null, key));
/******/ 		return ns;
/******/ 	};
/******/
/******/ 	// getDefaultExport function for compatibility with non-harmony modules
/******/ 	__webpack_require__.n = function(module) {
/******/ 		var getter = module && module.__esModule ?
/******/ 			function getDefault() { return module['default']; } :
/******/ 			function getModuleExports() { return module; };
/******/ 		__webpack_require__.d(getter, 'a', getter);
/******/ 		return getter;
/******/ 	};
/******/
/******/ 	// Object.prototype.hasOwnProperty.call
/******/ 	__webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };
/******/
/******/ 	// __webpack_public_path__
/******/ 	__webpack_require__.p = "";
/******/
/******/
/******/ 	// Load entry module and return exports
/******/ 	return __webpack_require__(__webpack_require__.s = "./src/js/edit/custom-cursor.js");
/******/ })
/************************************************************************/
/******/ ({

/***/ "./src/js/edit/custom-cursor.js":
/*!**************************************!*\
  !*** ./src/js/edit/custom-cursor.js ***!
  \**************************************/
/*! no static exports found */
/***/ (function(module, exports) {

eval("function _regenerator() { /*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/babel/babel/blob/main/packages/babel-helpers/LICENSE */ var e, t, r = \"function\" == typeof Symbol ? Symbol : {}, n = r.iterator || \"@@iterator\", o = r.toStringTag || \"@@toStringTag\"; function i(r, n, o, i) { var c = n && n.prototype instanceof Generator ? n : Generator, u = Object.create(c.prototype); return _regeneratorDefine2(u, \"_invoke\", function (r, n, o) { var i, c, u, f = 0, p = o || [], y = !1, G = { p: 0, n: 0, v: e, a: d, f: d.bind(e, 4), d: function d(t, r) { return i = t, c = 0, u = e, G.n = r, a; } }; function d(r, n) { for (c = r, u = n, t = 0; !y && f && !o && t < p.length; t++) { var o, i = p[t], d = G.p, l = i[2]; r > 3 ? (o = l === n) && (u = i[(c = i[4]) ? 5 : (c = 3, 3)], i[4] = i[5] = e) : i[0] <= d && ((o = r < 2 && d < i[1]) ? (c = 0, G.v = n, G.n = i[1]) : d < l && (o = r < 3 || i[0] > n || n > l) && (i[4] = r, i[5] = n, G.n = l, c = 0)); } if (o || r > 1) return a; throw y = !0, n; } return function (o, p, l) { if (f > 1) throw TypeError(\"Generator is already running\"); for (y && 1 === p && d(p, l), c = p, u = l; (t = c < 2 ? e : u) || !y;) { i || (c ? c < 3 ? (c > 1 && (G.n = -1), d(c, u)) : G.n = u : G.v = u); try { if (f = 2, i) { if (c || (o = \"next\"), t = i[o]) { if (!(t = t.call(i, u))) throw TypeError(\"iterator result is not an object\"); if (!t.done) return t; u = t.value, c < 2 && (c = 0); } else 1 === c && (t = i[\"return\"]) && t.call(i), c < 2 && (u = TypeError(\"The iterator does not provide a '\" + o + \"' method\"), c = 1); i = e; } else if ((t = (y = G.n < 0) ? u : r.call(n, G)) !== a) break; } catch (t) { i = e, c = 1, u = t; } finally { f = 1; } } return { value: t, done: y }; }; }(r, o, i), !0), u; } var a = {}; function Generator() {} function GeneratorFunction() {} function GeneratorFunctionPrototype() {} t = Object.getPrototypeOf; var c = [][n] ? t(t([][n]())) : (_regeneratorDefine2(t = {}, n, function () { return this; }), t), u = GeneratorFunctionPrototype.prototype = Generator.prototype = Object.create(c); function f(e) { return Object.setPrototypeOf ? Object.setPrototypeOf(e, GeneratorFunctionPrototype) : (e.__proto__ = GeneratorFunctionPrototype, _regeneratorDefine2(e, o, \"GeneratorFunction\")), e.prototype = Object.create(u), e; } return GeneratorFunction.prototype = GeneratorFunctionPrototype, _regeneratorDefine2(u, \"constructor\", GeneratorFunctionPrototype), _regeneratorDefine2(GeneratorFunctionPrototype, \"constructor\", GeneratorFunction), GeneratorFunction.displayName = \"GeneratorFunction\", _regeneratorDefine2(GeneratorFunctionPrototype, o, \"GeneratorFunction\"), _regeneratorDefine2(u), _regeneratorDefine2(u, o, \"Generator\"), _regeneratorDefine2(u, n, function () { return this; }), _regeneratorDefine2(u, \"toString\", function () { return \"[object Generator]\"; }), (_regenerator = function _regenerator() { return { w: i, m: f }; })(); }\nfunction _regeneratorDefine2(e, r, n, t) { var i = Object.defineProperty; try { i({}, \"\", {}); } catch (e) { i = 0; } _regeneratorDefine2 = function _regeneratorDefine(e, r, n, t) { function o(r, n) { _regeneratorDefine2(e, r, function (e) { return this._invoke(r, n, e); }); } r ? i ? i(e, r, { value: n, enumerable: !t, configurable: !t, writable: !t }) : e[r] = n : (o(\"next\", 0), o(\"throw\", 1), o(\"return\", 2)); }, _regeneratorDefine2(e, r, n, t); }\nfunction asyncGeneratorStep(n, t, e, r, o, a, c) { try { var i = n[a](c), u = i.value; } catch (n) { return void e(n); } i.done ? t(u) : Promise.resolve(u).then(r, o); }\nfunction _asyncToGenerator(n) { return function () { var t = this, e = arguments; return new Promise(function (r, o) { var a = n.apply(t, e); function _next(n) { asyncGeneratorStep(a, r, o, _next, _throw, \"next\", n); } function _throw(n) { asyncGeneratorStep(a, r, o, _next, _throw, \"throw\", n); } _next(void 0); }); }; }\nvar CustomCursorHandler = function CustomCursorHandler($scope, $) {\n  function handleCircleCursor(model, element) {\n    var _model$attributes, _model$attributes2, _settings$eael_custom, _settings$eael_custom2, _settings$eael_custom3, _settings$eael_custom4, _settings$eael_custom5, _settings$eael_custom6, _settings$eael_custom7, _settings$eael_custom8, _settings$eael_custom9, _settings$eael_custom0, _settings$eael_custom1, _settings$eael_custom10, _settings$eael_custom11, _ref, _settings$eael_custom12, _ref2, _settings$eael_custom13, _settings$eael_custom14, _settings$eael_custom15, _ref3, _settings$eael_custom16, _ref4, _settings$eael_custom17, _settings$eael_custom18, _settings$eael_custom19, _ref5, _settings$eael_custom20, _settings$eael_custom21, _settings$eael_custom22, _ref6, _settings$eael_custom23, _ref7, _settings$eael_custom24, _settings$eael_custom25, _settings$eael_custom26, _ref8, _settings$eael_custom27, _settings$eael_custom28, _settings$eael_custom29;\n    var state = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : '';\n    var settings = model === null || model === void 0 || (_model$attributes = model.attributes) === null || _model$attributes === void 0 || (_model$attributes = _model$attributes.settings) === null || _model$attributes === void 0 ? void 0 : _model$attributes.attributes;\n    var elementId = model === null || model === void 0 || (_model$attributes2 = model.attributes) === null || _model$attributes2 === void 0 ? void 0 : _model$attributes2.id;\n\n    // Store all cursor settings for both normal and pointer states\n    var allCursorSettings = {\n      // Normal state settings\n      circle_type: (_settings$eael_custom = settings === null || settings === void 0 ? void 0 : settings['eael_custom_cursor_circle_type']) !== null && _settings$eael_custom !== void 0 ? _settings$eael_custom : 'solid',\n      circle_thickness: (_settings$eael_custom2 = settings === null || settings === void 0 || (_settings$eael_custom3 = settings['eael_custom_cursor_circle_thickness']) === null || _settings$eael_custom3 === void 0 ? void 0 : _settings$eael_custom3.size) !== null && _settings$eael_custom2 !== void 0 ? _settings$eael_custom2 : 2,\n      circle_color: (_settings$eael_custom4 = settings === null || settings === void 0 ? void 0 : settings['eael_custom_cursor_circle_color']) !== null && _settings$eael_custom4 !== void 0 ? _settings$eael_custom4 : '#9121fc',\n      circle_size: (_settings$eael_custom5 = settings === null || settings === void 0 || (_settings$eael_custom6 = settings['eael_custom_cursor_circle_size']) === null || _settings$eael_custom6 === void 0 ? void 0 : _settings$eael_custom6.size) !== null && _settings$eael_custom5 !== void 0 ? _settings$eael_custom5 : 20,\n      circle_radius: (_settings$eael_custom7 = settings === null || settings === void 0 || (_settings$eael_custom8 = settings['eael_custom_cursor_circle_radius']) === null || _settings$eael_custom8 === void 0 ? void 0 : _settings$eael_custom8.size) !== null && _settings$eael_custom7 !== void 0 ? _settings$eael_custom7 : 50,\n      dot_show: 'yes' === (settings === null || settings === void 0 ? void 0 : settings['eael_custom_cursor_circle_dot_show']) ? true : false,\n      dot_color: (_settings$eael_custom9 = settings === null || settings === void 0 ? void 0 : settings['eael_custom_cursor_circle_dot_color']) !== null && _settings$eael_custom9 !== void 0 ? _settings$eael_custom9 : '#fff',\n      dot_size: (_settings$eael_custom0 = settings === null || settings === void 0 || (_settings$eael_custom1 = settings['eael_custom_cursor_circle_dot_size']) === null || _settings$eael_custom1 === void 0 ? void 0 : _settings$eael_custom1.size) !== null && _settings$eael_custom0 !== void 0 ? _settings$eael_custom0 : 8,\n      dot_radius: (_settings$eael_custom10 = settings === null || settings === void 0 || (_settings$eael_custom11 = settings['eael_custom_cursor_circle_dot_radius']) === null || _settings$eael_custom11 === void 0 ? void 0 : _settings$eael_custom11.size) !== null && _settings$eael_custom10 !== void 0 ? _settings$eael_custom10 : 8,\n      // Pointer state settings\n      circle_type_pointer: (_ref = (_settings$eael_custom12 = settings === null || settings === void 0 ? void 0 : settings['eael_custom_cursor_circle_type_pointer']) !== null && _settings$eael_custom12 !== void 0 ? _settings$eael_custom12 : settings === null || settings === void 0 ? void 0 : settings['eael_custom_cursor_circle_type']) !== null && _ref !== void 0 ? _ref : 'solid',\n      circle_thickness_pointer: (_ref2 = (_settings$eael_custom13 = settings === null || settings === void 0 || (_settings$eael_custom14 = settings['eael_custom_cursor_circle_thickness_pointer']) === null || _settings$eael_custom14 === void 0 ? void 0 : _settings$eael_custom14.size) !== null && _settings$eael_custom13 !== void 0 ? _settings$eael_custom13 : settings === null || settings === void 0 || (_settings$eael_custom15 = settings['eael_custom_cursor_circle_thickness']) === null || _settings$eael_custom15 === void 0 ? void 0 : _settings$eael_custom15.size) !== null && _ref2 !== void 0 ? _ref2 : 2,\n      circle_color_pointer: (_ref3 = (_settings$eael_custom16 = settings === null || settings === void 0 ? void 0 : settings['eael_custom_cursor_circle_color_pointer']) !== null && _settings$eael_custom16 !== void 0 ? _settings$eael_custom16 : settings === null || settings === void 0 ? void 0 : settings['eael_custom_cursor_circle_color']) !== null && _ref3 !== void 0 ? _ref3 : '#9121fc',\n      circle_size_pointer: (_ref4 = (_settings$eael_custom17 = settings === null || settings === void 0 || (_settings$eael_custom18 = settings['eael_custom_cursor_circle_size_pointer']) === null || _settings$eael_custom18 === void 0 ? void 0 : _settings$eael_custom18.size) !== null && _settings$eael_custom17 !== void 0 ? _settings$eael_custom17 : settings === null || settings === void 0 || (_settings$eael_custom19 = settings['eael_custom_cursor_circle_size']) === null || _settings$eael_custom19 === void 0 ? void 0 : _settings$eael_custom19.size) !== null && _ref4 !== void 0 ? _ref4 : 20,\n      circle_radius_pointer: (_ref5 = (_settings$eael_custom20 = settings === null || settings === void 0 || (_settings$eael_custom21 = settings['eael_custom_cursor_circle_radius_pointer']) === null || _settings$eael_custom21 === void 0 ? void 0 : _settings$eael_custom21.size) !== null && _settings$eael_custom20 !== void 0 ? _settings$eael_custom20 : settings === null || settings === void 0 || (_settings$eael_custom22 = settings['eael_custom_cursor_circle_radius']) === null || _settings$eael_custom22 === void 0 ? void 0 : _settings$eael_custom22.size) !== null && _ref5 !== void 0 ? _ref5 : 50,\n      dot_show_pointer: 'yes' === (settings === null || settings === void 0 ? void 0 : settings['eael_custom_cursor_circle_dot_show_pointer']) ? true : (settings === null || settings === void 0 ? void 0 : settings['eael_custom_cursor_circle_dot_show_pointer']) === undefined ? 'yes' === (settings === null || settings === void 0 ? void 0 : settings['eael_custom_cursor_circle_dot_show']) ? true : false : false,\n      dot_color_pointer: (_ref6 = (_settings$eael_custom23 = settings === null || settings === void 0 ? void 0 : settings['eael_custom_cursor_circle_dot_color_pointer']) !== null && _settings$eael_custom23 !== void 0 ? _settings$eael_custom23 : settings === null || settings === void 0 ? void 0 : settings['eael_custom_cursor_circle_dot_color']) !== null && _ref6 !== void 0 ? _ref6 : '#fff',\n      dot_size_pointer: (_ref7 = (_settings$eael_custom24 = settings === null || settings === void 0 || (_settings$eael_custom25 = settings['eael_custom_cursor_circle_dot_size_pointer']) === null || _settings$eael_custom25 === void 0 ? void 0 : _settings$eael_custom25.size) !== null && _settings$eael_custom24 !== void 0 ? _settings$eael_custom24 : settings === null || settings === void 0 || (_settings$eael_custom26 = settings['eael_custom_cursor_circle_dot_size']) === null || _settings$eael_custom26 === void 0 ? void 0 : _settings$eael_custom26.size) !== null && _ref7 !== void 0 ? _ref7 : 8,\n      dot_radius_pointer: (_ref8 = (_settings$eael_custom27 = settings === null || settings === void 0 || (_settings$eael_custom28 = settings['eael_custom_cursor_circle_dot_radius_pointer']) === null || _settings$eael_custom28 === void 0 ? void 0 : _settings$eael_custom28.size) !== null && _settings$eael_custom27 !== void 0 ? _settings$eael_custom27 : settings === null || settings === void 0 || (_settings$eael_custom29 = settings['eael_custom_cursor_circle_dot_radius']) === null || _settings$eael_custom29 === void 0 ? void 0 : _settings$eael_custom29.size) !== null && _ref8 !== void 0 ? _ref8 : 8\n    };\n\n    // Get current state settings based on state parameter\n    var currentState = state === '_pointer' ? 'pointer' : 'normal';\n    var cursorSettings = {\n      circle_type: currentState === 'pointer' ? allCursorSettings.circle_type_pointer : allCursorSettings.circle_type,\n      circle_thickness: currentState === 'pointer' ? allCursorSettings.circle_thickness_pointer : allCursorSettings.circle_thickness,\n      circle_color: currentState === 'pointer' ? allCursorSettings.circle_color_pointer : allCursorSettings.circle_color,\n      circle_size: currentState === 'pointer' ? allCursorSettings.circle_size_pointer : allCursorSettings.circle_size,\n      circle_radius: currentState === 'pointer' ? allCursorSettings.circle_radius_pointer : allCursorSettings.circle_radius,\n      dot_show: currentState === 'pointer' ? allCursorSettings.dot_show_pointer : allCursorSettings.dot_show,\n      dot_color: currentState === 'pointer' ? allCursorSettings.dot_color_pointer : allCursorSettings.dot_color,\n      dot_size: currentState === 'pointer' ? allCursorSettings.dot_size_pointer : allCursorSettings.dot_size,\n      dot_radius: currentState === 'pointer' ? allCursorSettings.dot_radius_pointer : allCursorSettings.dot_radius\n    };\n    var dotHtml = '';\n    if (cursorSettings !== null && cursorSettings !== void 0 && cursorSettings.dot_show) {\n      dotHtml = '<div id=\"eael-cursor-dot-' + elementId + '\"></div>';\n    }\n    var cursorHtml = '<div id=\"eael-cursor-' + elementId + '\">' + dotHtml + '</div>';\n    if (!element.find('#eael-cursor-' + elementId).length) {\n      element.append(DOMPurify.sanitize(cursorHtml));\n    }\n\n    // Create cursor elements\n    var $cursor = element.find('#eael-cursor-' + elementId);\n\n    // Add smooth transitions for state changes\n    $cursor.css({\n      width: (cursorSettings === null || cursorSettings === void 0 ? void 0 : cursorSettings.circle_size) + 'px',\n      height: (cursorSettings === null || cursorSettings === void 0 ? void 0 : cursorSettings.circle_size) + 'px',\n      border: (cursorSettings === null || cursorSettings === void 0 ? void 0 : cursorSettings.circle_thickness) + 'px ' + (cursorSettings === null || cursorSettings === void 0 ? void 0 : cursorSettings.circle_type) + ' ' + (cursorSettings === null || cursorSettings === void 0 ? void 0 : cursorSettings.circle_color),\n      borderRadius: (cursorSettings === null || cursorSettings === void 0 ? void 0 : cursorSettings.circle_radius) + '%',\n      position: 'fixed',\n      transform: 'translate(-50%, -50%)',\n      pointerEvents: 'none',\n      zIndex: '9999999',\n      top: 0,\n      left: 0,\n      display: 'none',\n      transition: 'width 200ms ease-out, height 200ms ease-out, border 200ms ease-out, border-radius 200ms ease-out, opacity 200ms ease-out'\n    });\n    if (cursorSettings !== null && cursorSettings !== void 0 && cursorSettings.dot_show) {\n      var $dot = element.find('#eael-cursor-dot-' + elementId);\n      $dot.css({\n        width: (cursorSettings === null || cursorSettings === void 0 ? void 0 : cursorSettings.dot_size) + 'px',\n        height: (cursorSettings === null || cursorSettings === void 0 ? void 0 : cursorSettings.dot_size) + 'px',\n        background: cursorSettings === null || cursorSettings === void 0 ? void 0 : cursorSettings.dot_color,\n        borderRadius: (cursorSettings === null || cursorSettings === void 0 ? void 0 : cursorSettings.dot_radius) + '%',\n        position: 'absolute',\n        top: '50%',\n        left: '50%',\n        transform: 'translate(-50%, -50%)',\n        transition: 'width 200ms ease-out, height 200ms ease-out, background 200ms ease-out, border-radius 200ms ease-out'\n      });\n    }\n    var isInArea = false;\n    var isPointerState = false;\n\n    // Default pointer selectors for detecting hover state changes\n    var defaultPointerSelectors = ['a', 'button', 'input[type=\"button\"]', 'input[type=\"submit\"]', 'input[type=\"reset\"]', '[role=\"button\"]', '.btn', '.button', 'select', 'textarea', 'input[type=\"text\"]', 'input[type=\"email\"]', 'input[type=\"password\"]', 'input[type=\"search\"]', 'input[type=\"url\"]', 'input[type=\"tel\"]', 'input[type=\"number\"]', '[contenteditable]', '[tabindex]:not([tabindex=\"-1\"])'];\n\n    // Function to apply cursor styles based on current state\n    function applyCursorStyles() {\n      var isPointer = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : false;\n      var size = isPointer ? allCursorSettings.circle_size_pointer : allCursorSettings.circle_size;\n      var thickness = isPointer ? allCursorSettings.circle_thickness_pointer : allCursorSettings.circle_thickness;\n      var type = isPointer ? allCursorSettings.circle_type_pointer : allCursorSettings.circle_type;\n      var color = isPointer ? allCursorSettings.circle_color_pointer : allCursorSettings.circle_color;\n      var radius = isPointer ? allCursorSettings.circle_radius_pointer : allCursorSettings.circle_radius;\n      var dotShow = isPointer ? allCursorSettings.dot_show_pointer : allCursorSettings.dot_show;\n\n      // Apply cursor styles with direct CSS for instant visual feedback\n      $cursor[0].style.width = size + 'px';\n      $cursor[0].style.height = size + 'px';\n      $cursor[0].style.border = thickness + 'px ' + type + ' ' + color;\n      $cursor[0].style.borderRadius = radius + '%';\n\n      // Apply dot styles if enabled\n      if (dotShow) {\n        var _$dot = element.find('#eael-cursor-dot-' + elementId);\n        if (_$dot.length) {\n          var dotSize = isPointer ? allCursorSettings.dot_size_pointer : allCursorSettings.dot_size;\n          var dotColor = isPointer ? allCursorSettings.dot_color_pointer : allCursorSettings.dot_color;\n          var dotRadius = isPointer ? allCursorSettings.dot_radius_pointer : allCursorSettings.dot_radius;\n          _$dot[0].style.width = dotSize + 'px';\n          _$dot[0].style.height = dotSize + 'px';\n          _$dot[0].style.backgroundColor = dotColor;\n          _$dot[0].style.borderRadius = dotRadius + '%';\n        }\n      }\n    }\n    element.on('mouseenter', function () {\n      if (!window['eael_cursor_type_' + element.data('id')] || 'circle' !== window['eael_cursor_type_' + element.data('id')]) {\n        return;\n      }\n      $cursor.show();\n      isInArea = true;\n    }).on('mouseleave', function () {\n      $cursor.hide();\n      isInArea = false;\n      isPointerState = false;\n      applyCursorStyles(false);\n    }).on('mousemove', function (e) {\n      if (!isInArea) return;\n\n      // Use clientX/Y for viewport-relative positioning and update cursor position instantly\n      var mouseX = e.clientX;\n      var mouseY = e.clientY;\n\n      // Update cursor position directly using CSS transform with translate3d for instantaneous tracking\n      $cursor[0].style.transform = \"translate3d(\".concat(mouseX, \"px, \").concat(mouseY, \"px, 0) translate(-50%, -50%)\");\n\n      // Check if hovering over pointer elements to determine state\n      var target = e.target;\n      var isOverPointerElement = defaultPointerSelectors.some(function (selector) {\n        try {\n          return target.matches(selector) || target.closest(selector);\n        } catch (err) {\n          return false;\n        }\n      });\n\n      // Update cursor state if changed - render appearance based on current state\n      if (isOverPointerElement !== isPointerState) {\n        isPointerState = isOverPointerElement;\n        applyCursorStyles(isPointerState);\n      }\n\n      // Control cursor visibility based on cursor type configuration to prevent double cursors\n      // This logic matches the frontend implementation to ensure consistent behavior\n      if ('circle' !== (settings === null || settings === void 0 ? void 0 : settings['eael_custom_cursor_type_pointer'])) {\n        if (isPointerState) {\n          $cursor.hide();\n        } else {\n          $cursor.show();\n        }\n      } else if ('circle' !== (settings === null || settings === void 0 ? void 0 : settings['eael_custom_cursor_type'])) {\n        if (isPointerState) {\n          $cursor.show();\n        } else {\n          $cursor.hide();\n        }\n      } else {\n        $cursor.show();\n      }\n    });\n    return 'none';\n  }\n  function handleIconCursor(_x, _x2) {\n    return _handleIconCursor.apply(this, arguments);\n  }\n  function _handleIconCursor() {\n    _handleIconCursor = _asyncToGenerator(/*#__PURE__*/_regenerator().m(function _callee(settings, element) {\n      var _settings, _iconSettings$icon;\n      var suffix,\n        iconSettings,\n        svghtml,\n        _iconSettings$icon2,\n        _args = arguments,\n        _t,\n        _t2;\n      return _regenerator().w(function (_context) {\n        while (1) switch (_context.n) {\n          case 0:\n            suffix = _args.length > 2 && _args[2] !== undefined ? _args[2] : '';\n            iconSettings = {\n              icon: settings === null || settings === void 0 ? void 0 : settings['eael_custom_cursor_icon' + suffix],\n              color: settings === null || settings === void 0 ? void 0 : settings['eael_custom_cursor_icon_color' + suffix],\n              size: settings === null || settings === void 0 || (_settings = settings['eael_custom_cursor_icon_size' + suffix]) === null || _settings === void 0 ? void 0 : _settings.size,\n              svgPath: settings === null || settings === void 0 ? void 0 : settings.eael_icon_to_svg_path\n            };\n            svghtml = '';\n            if (!('svg' === (iconSettings === null || iconSettings === void 0 || (_iconSettings$icon = iconSettings.icon) === null || _iconSettings$icon === void 0 ? void 0 : _iconSettings$icon.library))) {\n              _context.n = 1;\n              break;\n            }\n            svghtml = iconSettings === null || iconSettings === void 0 || (_iconSettings$icon2 = iconSettings.icon) === null || _iconSettings$icon2 === void 0 || (_iconSettings$icon2 = _iconSettings$icon2.value) === null || _iconSettings$icon2 === void 0 ? void 0 : _iconSettings$icon2.url;\n            _context.n = 3;\n            break;\n          case 1:\n            _t = btoa;\n            _context.n = 2;\n            return get_svg_by_icon(iconSettings);\n          case 2:\n            _t2 = _t(_context.v);\n            svghtml = 'data:image/svg+xml;base64,' + _t2;\n          case 3:\n            if (svghtml) {\n              _context.n = 4;\n              break;\n            }\n            return _context.a(2, '');\n          case 4:\n            return _context.a(2, 'url(\"' + svghtml + '\") 0 0, auto;');\n        }\n      }, _callee);\n    }));\n    return _handleIconCursor.apply(this, arguments);\n  }\n  function adjustItemAndColors(itemCount, assignedColors) {\n    // Get colors from settings\n    var colors = assignedColors === null || assignedColors === void 0 ? void 0 : assignedColors.map(function (color) {\n      return color.trim().replace(/['\"]/g, '');\n    }).filter(function (color) {\n      return color !== '';\n    });\n\n    // Assign colors based on count relationship\n    var trailColors = [];\n    var colorCount = colors.length;\n    if (colorCount > 0) {\n      // Assign colors to each trail segment using modulo for overflow\n      for (var i = 0; i < itemCount; i++) {\n        trailColors.push(colors[i % colorCount]);\n      }\n    }\n    return trailColors;\n  }\n  function initFollowingDotsTrail(model, element) {\n    var _model$attributes3, _model$attributes4, _settings$eael_cursor, _settings$eael_cursor2, _settings$eael_cursor3, _settings$eael_cursor4, _settings$eael_cursor5;\n    var settings = model === null || model === void 0 || (_model$attributes3 = model.attributes) === null || _model$attributes3 === void 0 || (_model$attributes3 = _model$attributes3.settings) === null || _model$attributes3 === void 0 ? void 0 : _model$attributes3.attributes;\n    var elementId = model === null || model === void 0 || (_model$attributes4 = model.attributes) === null || _model$attributes4 === void 0 ? void 0 : _model$attributes4.id;\n    var trailCount = (settings === null || settings === void 0 ? void 0 : settings.eael_cursor_trail_count) || 12;\n    var trailSize = (settings === null || settings === void 0 || (_settings$eael_cursor = settings.eael_cursor_trail_size) === null || _settings$eael_cursor === void 0 ? void 0 : _settings$eael_cursor.size) || 10;\n    var trailOpacity = (settings === null || settings === void 0 || (_settings$eael_cursor2 = settings.eael_cursor_trail_opacity) === null || _settings$eael_cursor2 === void 0 ? void 0 : _settings$eael_cursor2.size) || 5;\n    trailOpacity = trailOpacity / 10;\n    var trailRadius = (settings === null || settings === void 0 || (_settings$eael_cursor3 = settings.eael_cursor_trail_radius) === null || _settings$eael_cursor3 === void 0 ? void 0 : _settings$eael_cursor3.size) || 50;\n    var trailSpeed = ((settings === null || settings === void 0 || (_settings$eael_cursor4 = settings.eael_cursor_trail_speed) === null || _settings$eael_cursor4 === void 0 ? void 0 : _settings$eael_cursor4.size) || 8) / 100;\n    var trailColors = [];\n    if ('single' === (settings === null || settings === void 0 ? void 0 : settings.eael_cursor_trail_color_type) && settings !== null && settings !== void 0 && settings.eael_cursor_trail_color) {\n      trailColors = [settings === null || settings === void 0 ? void 0 : settings.eael_cursor_trail_color];\n    } else {\n      for (var i = 1; i <= trailCount; i++) {\n        if (settings !== null && settings !== void 0 && settings['eael_cursor_trail_color_' + i]) {\n          trailColors.push(settings['eael_cursor_trail_color_' + i]);\n        }\n      }\n    }\n    if (trailColors.length < 1) {\n      trailColors = ['#9121fc'];\n    }\n    trailColors = adjustItemAndColors(trailCount, trailColors);\n    var dots = [];\n    var mouse = {\n      x: 0,\n      y: 0\n    };\n    if (!element.find('#eael-trails-' + elementId).length) {\n      $('<div>', {\n        id: 'eael-trails-' + elementId,\n        css: {\n          position: 'absolute',\n          top: 0,\n          left: 0,\n          width: '100%',\n          height: '100%',\n          pointerEvents: 'none',\n          zIndex: 99999,\n          display: 'none'\n        }\n      }).appendTo(element.css('position', 'relative'));\n    }\n    var $trailContainer = element.find('#eael-trails-' + elementId);\n    // Create trail dots\n    for (var _i = 0; _i < trailCount; _i++) {\n      if (!element.find('#eael-trail-' + elementId + '-' + _i).length) {\n        var $dot = $('<div>', {\n          id: 'eael-trail-' + elementId + '-' + _i,\n          css: {\n            width: trailSize + 'px',\n            height: trailSize + 'px',\n            background: trailColors[_i],\n            opacity: trailOpacity,\n            borderRadius: trailRadius + '%',\n            position: 'absolute',\n            pointerEvents: 'none',\n            zIndex: 99999\n          }\n        }).appendTo($trailContainer);\n        dots.push({\n          $el: $dot,\n          x: 0,\n          y: 0\n        });\n      }\n    }\n    var idleTimer = null;\n    var hideOnIdle = settings === null || settings === void 0 ? void 0 : settings.eael_cursor_trail_hide_on_idle;\n    var idleTimeout = (settings === null || settings === void 0 || (_settings$eael_cursor5 = settings.eael_cursor_trail_idle_timeout) === null || _settings$eael_cursor5 === void 0 ? void 0 : _settings$eael_cursor5.size) * 1000 || 3000; // 3 seconds of inactivity\n\n    function resetIdleTimer() {\n      clearTimeout(idleTimer);\n      $trailContainer.show();\n      idleTimer = setTimeout(function () {\n        if ('yes' === hideOnIdle) {\n          $trailContainer.fadeOut('slow');\n        }\n      }, idleTimeout);\n    }\n    element.on('mousemove', function (e) {\n      var offset = element.offset();\n      mouse.x = e.pageX - offset.left;\n      mouse.y = e.pageY - offset.top;\n      $trailContainer.show();\n      resetIdleTimer();\n    }).on('mouseenter', function () {\n      $trailContainer.show();\n      resetIdleTimer();\n    }).on('mouseleave', function () {\n      clearTimeout(idleTimer);\n      $trailContainer.fadeOut('slow');\n    });\n    function animate() {\n      var x = mouse.x,\n        y = mouse.y;\n      dots.forEach(function (dot, i) {\n        var next = dots[i - 1] || {\n          x: x,\n          y: y\n        };\n        dot.x += (next.x - dot.x) * trailSpeed;\n        dot.y += (next.y - dot.y) * trailSpeed;\n        dot.$el.css('transform', \"translate(\".concat(dot.x, \"px, \").concat(dot.y, \"px)\"));\n      });\n      requestAnimationFrame(animate);\n    }\n    animate();\n  }\n  function initialize90sCursorTrail(element, options, type, settings) {\n    var cursorTrail = false;\n    var inactivityTimer = null;\n    var hideOnIdle = settings === null || settings === void 0 ? void 0 : settings.eael_cursor_trail_hide_on_idle;\n    var idleTimeout = settings === null || settings === void 0 ? void 0 : settings.eael_cursor_trail_idle_timeout;\n    var inactivityTimeout = idleTimeout * 1000 || 3000; // 3 seconds of inactivity before destroying\n\n    function resetInactivityTimer() {\n      clearTimeout(inactivityTimer);\n      inactivityTimer = setTimeout(function () {\n        if ('yes' === hideOnIdle) {\n          if (cursorTrail) {\n            element.find(' > canvas').fadeOut('slow', function () {\n              if (typeof cursorTrail.destroy === 'function') {\n                var _cursorTrail;\n                (_cursorTrail = cursorTrail) === null || _cursorTrail === void 0 || _cursorTrail.destroy();\n              }\n              cursorTrail = false;\n            });\n          }\n        }\n      }, inactivityTimeout);\n    }\n    element.on('mouseenter mousemove', function () {\n      if (!window['eael_cursor_trail_' + element.data('id')]) {\n        return;\n      }\n      if (type !== (settings === null || settings === void 0 ? void 0 : settings.eael_cursor_trail_effect)) {\n        return;\n      }\n      if (!cursorTrail) {\n        cursorTrail = new eaelCursorEffects[type](options);\n      }\n\n      // Remove all canvas elements except the last one\n      var canvasElements = element.find('>canvas');\n      if (canvasElements.length > 1) {\n        canvasElements.not(':last').remove();\n      }\n      resetInactivityTimer();\n    }).on('mouseleave', function () {\n      clearTimeout(inactivityTimer);\n      if (cursorTrail) {\n        element.find(' > canvas').fadeOut('slow', function () {\n          if (typeof cursorTrail.destroy === 'function') {\n            var _cursorTrail2;\n            (_cursorTrail2 = cursorTrail) === null || _cursorTrail2 === void 0 || _cursorTrail2.destroy();\n          }\n          cursorTrail = false;\n        });\n      }\n    });\n  }\n  function initSmokyGhostCursor(model) {\n    var _model$attributes5, _model$attributes6, _settings$eael_cursor6, _settings$eael_cursor8;\n    var settings = model === null || model === void 0 || (_model$attributes5 = model.attributes) === null || _model$attributes5 === void 0 || (_model$attributes5 = _model$attributes5.settings) === null || _model$attributes5 === void 0 ? void 0 : _model$attributes5.attributes;\n    var target = \".elementor-element-\".concat(model === null || model === void 0 || (_model$attributes6 = model.attributes) === null || _model$attributes6 === void 0 ? void 0 : _model$attributes6.id);\n    var element = $(target);\n    var options = {};\n    if (settings !== null && settings !== void 0 && (_settings$eael_cursor6 = settings.eael_cursor_trail_ghost_size) !== null && _settings$eael_cursor6 !== void 0 && _settings$eael_cursor6.size) {\n      var _settings$eael_cursor7;\n      options.size = (settings === null || settings === void 0 || (_settings$eael_cursor7 = settings.eael_cursor_trail_ghost_size) === null || _settings$eael_cursor7 === void 0 ? void 0 : _settings$eael_cursor7.size) / 100;\n    }\n    if (settings !== null && settings !== void 0 && settings.eael_cursor_trail_ghost_color) {\n      options.mainColor = settings === null || settings === void 0 ? void 0 : settings.eael_cursor_trail_ghost_color;\n    }\n    var ghostTrail = false;\n    var inactivityTimer = null;\n    var hideOnIdle = settings === null || settings === void 0 ? void 0 : settings.eael_cursor_trail_hide_on_idle;\n    var idleTimeout = settings === null || settings === void 0 || (_settings$eael_cursor8 = settings.eael_cursor_trail_idle_timeout) === null || _settings$eael_cursor8 === void 0 ? void 0 : _settings$eael_cursor8.size;\n    var inactivityTimeout = idleTimeout * 1000 || 3000; // 3 seconds of inactivity before pausing\n\n    function resetInactivityTimer() {\n      clearTimeout(inactivityTimer);\n      inactivityTimer = setTimeout(function () {\n        if ('yes' === hideOnIdle) {\n          if (ghostTrail) {\n            element.find(' > canvas').fadeOut('slow', function () {\n              if (typeof ghostTrail.destroy === 'function') {\n                ghostTrail.destroy();\n              }\n              ghostTrail = false;\n            });\n          }\n        }\n      }, inactivityTimeout);\n    }\n    element.on('mouseenter mousemove', function () {\n      if (!window['eael_cursor_trail_' + element.data('id')]) {\n        return;\n      }\n      if ('phantomsmoke' !== (settings === null || settings === void 0 ? void 0 : settings.eael_cursor_trail_effect)) {\n        return;\n      }\n      if (!ghostTrail) {\n        ghostTrail = new SmokyGhostTrail(target, options);\n      } else {\n        ghostTrail.start();\n      }\n      var canvasElements = element.find('>canvas');\n      if (canvasElements.length > 1) {\n        canvasElements.not(':last').remove();\n      }\n      resetInactivityTimer();\n    }).on('mouseleave', function () {\n      clearTimeout(inactivityTimer);\n      if (ghostTrail) {\n        element.find(' > canvas').fadeOut('slow', function () {\n          if (typeof ghostTrail.destroy === 'function') {\n            var _ghostTrail;\n            (_ghostTrail = ghostTrail) === null || _ghostTrail === void 0 || _ghostTrail.destroy();\n          }\n          ghostTrail = false;\n        });\n      }\n    });\n  }\n  function initspiritecho(model) {\n    var _model$attributes7, _model$attributes8, _settings$eael_cursor9, _settings$eael_cursor1;\n    var settings = model === null || model === void 0 || (_model$attributes7 = model.attributes) === null || _model$attributes7 === void 0 || (_model$attributes7 = _model$attributes7.settings) === null || _model$attributes7 === void 0 ? void 0 : _model$attributes7.attributes;\n    var target = \".elementor-element-\".concat(model === null || model === void 0 || (_model$attributes8 = model.attributes) === null || _model$attributes8 === void 0 ? void 0 : _model$attributes8.id);\n    var element = $(target);\n    var options = {};\n\n    // Map Elementor settings to GhostCursorTrail options\n    if (settings !== null && settings !== void 0 && (_settings$eael_cursor9 = settings.eael_cursor_ghost_following_size) !== null && _settings$eael_cursor9 !== void 0 && _settings$eael_cursor9.size) {\n      var _settings$eael_cursor0;\n      options.scale = (settings === null || settings === void 0 || (_settings$eael_cursor0 = settings.eael_cursor_ghost_following_size) === null || _settings$eael_cursor0 === void 0 ? void 0 : _settings$eael_cursor0.size) / 10;\n    }\n    if (settings !== null && settings !== void 0 && settings.eael_cursor_ghost_following_color) {\n      options.ghostColor = settings === null || settings === void 0 ? void 0 : settings.eael_cursor_ghost_following_color;\n    }\n    if (settings !== null && settings !== void 0 && settings.eael_cursor_ghost_following_eye_color) {\n      options.eyeColor = settings === null || settings === void 0 ? void 0 : settings.eael_cursor_ghost_following_eye_color;\n    }\n    if (settings !== null && settings !== void 0 && settings.eael_cursor_ghost_following_appearance) {\n      options.appearanceMode = settings === null || settings === void 0 ? void 0 : settings.eael_cursor_ghost_following_appearance;\n    }\n\n    // Set container to the element\n    options.container = element[0];\n    var ghostTrail = false;\n    var inactivityTimer = null;\n    var hideOnIdle = settings === null || settings === void 0 ? void 0 : settings.eael_cursor_trail_hide_on_idle;\n    var idleTimeout = settings === null || settings === void 0 || (_settings$eael_cursor1 = settings.eael_cursor_trail_idle_timeout) === null || _settings$eael_cursor1 === void 0 ? void 0 : _settings$eael_cursor1.size;\n    var inactivityTimeout = idleTimeout * 1000 || 3000; // 3 seconds of inactivity before pausing\n\n    function resetInactivityTimer() {\n      clearTimeout(inactivityTimer);\n      inactivityTimer = setTimeout(function () {\n        if ('yes' === hideOnIdle) {\n          if (ghostTrail) {\n            element.find(' > .ghost-cursor-trail, > .ghost-cursor-trail-svg').fadeOut('slow', function () {\n              if (typeof ghostTrail.destroy === 'function') {\n                ghostTrail.destroy();\n              }\n              ghostTrail = false;\n            });\n          }\n        }\n      }, inactivityTimeout);\n    }\n    element.on('mouseenter mousemove', function () {\n      if (!window['eael_cursor_trail_' + element.data('id')]) {\n        return;\n      }\n      if ('spiritecho' !== (settings === null || settings === void 0 ? void 0 : settings.eael_cursor_trail_effect)) {\n        return;\n      }\n      if (!ghostTrail) {\n        ghostTrail = new GhostCursorTrail(options);\n        ghostTrail.start();\n      } else {\n        ghostTrail.start();\n      }\n\n      // Remove all ghost elements except the last one\n      var ghostElements = element.find('.ghost-cursor-trail');\n      var ghostSvgElements = element.find('.ghost-cursor-trail-svg');\n      if (ghostElements.length > 1) {\n        ghostElements.not(':last').remove();\n      }\n      if (ghostSvgElements.length > 1) {\n        ghostSvgElements.not(':last').remove();\n      }\n      resetInactivityTimer();\n    }).on('mouseleave', function () {\n      clearTimeout(inactivityTimer);\n      if (ghostTrail) {\n        element.find(' > .ghost-cursor-trail, > .ghost-cursor-trail-svg').fadeOut('slow', function () {\n          if (typeof ghostTrail.destroy === 'function') {\n            ghostTrail.destroy();\n          }\n          ghostTrail = false;\n        });\n      }\n    });\n  }\n  function initfrostsparkles(model, element) {\n    var _model$attributes9;\n    var settings = model === null || model === void 0 || (_model$attributes9 = model.attributes) === null || _model$attributes9 === void 0 || (_model$attributes9 = _model$attributes9.settings) === null || _model$attributes9 === void 0 ? void 0 : _model$attributes9.attributes;\n    var trailEmojis = settings !== null && settings !== void 0 && settings.eael_cursor_snowflake_emojis ? settings.eael_cursor_snowflake_emojis.split(',').filter(function (emoji) {\n      return emoji !== '';\n    }) : ['❄️'];\n    var windyEffect = (settings === null || settings === void 0 ? void 0 : settings.eael_cursor_snowflake_windy_effect) || false;\n    var options = {\n      element: element[0],\n      emojis: trailEmojis,\n      windy: windyEffect\n    };\n    initialize90sCursorTrail(element, options, 'frostsparkles', settings);\n  }\n  function inittrailparticles(model, element) {\n    var _model$attributes0;\n    var settings = model === null || model === void 0 || (_model$attributes0 = model.attributes) === null || _model$attributes0 === void 0 || (_model$attributes0 = _model$attributes0.settings) === null || _model$attributes0 === void 0 ? void 0 : _model$attributes0.attributes;\n    var ponterParticles = false;\n    element.on('mouseenter mousemove', function () {\n      if (!window['eael_cursor_trail_' + element.data('id')]) {\n        return;\n      }\n      if ('trailparticles' !== (settings === null || settings === void 0 ? void 0 : settings.eael_cursor_trail_effect)) {\n        return;\n      }\n      if (!ponterParticles) {\n        ponterParticles = new PointerParticles(element[0]);\n        ponterParticles.start();\n      } else {\n        ponterParticles.start();\n      }\n      var canvasElements = element.find('>canvas');\n      if (canvasElements.length > 1) {\n        canvasElements.not(':last').remove();\n      }\n    }).on('mouseleave', function () {\n      if (ponterParticles) {\n        element.find(' > canvas').fadeOut('slow', function () {\n          var _ponterParticles;\n          (_ponterParticles = ponterParticles) === null || _ponterParticles === void 0 || _ponterParticles.destroy();\n          ponterParticles = false;\n        });\n      }\n    });\n  }\n  function initinktrail(model, element) {\n    var _model$attributes1, _model$attributes10;\n    var settings = model === null || model === void 0 || (_model$attributes1 = model.attributes) === null || _model$attributes1 === void 0 || (_model$attributes1 = _model$attributes1.settings) === null || _model$attributes1 === void 0 ? void 0 : _model$attributes1.attributes;\n    var options = {\n      container: '.elementor-element-' + (model === null || model === void 0 || (_model$attributes10 = model.attributes) === null || _model$attributes10 === void 0 ? void 0 : _model$attributes10.id)\n    };\n    if (settings !== null && settings !== void 0 && settings.eael_cursor_ink_line_color) {\n      options.color = settings === null || settings === void 0 ? void 0 : settings.eael_cursor_ink_line_color;\n    }\n    var inktrail = false;\n    element.on('mouseenter mousemove', function () {\n      if (!window['eael_cursor_trail_' + element.data('id')]) {\n        return;\n      }\n      if ('inktrail' !== (settings === null || settings === void 0 ? void 0 : settings.eael_cursor_trail_effect)) {\n        return;\n      }\n      if (!inktrail) {\n        inktrail = eaelInkLine(options);\n        inktrail.start();\n      }\n      var canvasElements = element.find('>canvas');\n      if (canvasElements.length > 1) {\n        canvasElements.not(':last').remove();\n      }\n    }).on('mouseleave', function () {\n      if (inktrail) {\n        element.find(' > canvas').fadeOut('slow', function () {\n          if (typeof inktrail.destroy === 'function') {\n            var _inktrail;\n            (_inktrail = inktrail) === null || _inktrail === void 0 || _inktrail.destroy();\n          }\n          inktrail = false;\n        });\n      }\n    });\n  }\n  function initGlowingBoxes(model, element) {\n    var _model$attributes11, _model$attributes12, _model$attributes13, _settings$eael_cursor10, _settings$eael_cursor12, _settings$eael_cursor14, _settings$eael_cursor16, _settings$eael_cursor18, _settings$eael_cursor20;\n    var settings = model === null || model === void 0 || (_model$attributes11 = model.attributes) === null || _model$attributes11 === void 0 || (_model$attributes11 = _model$attributes11.settings) === null || _model$attributes11 === void 0 ? void 0 : _model$attributes11.attributes;\n    var id = 'eael-glowing-boxes-' + (model === null || model === void 0 || (_model$attributes12 = model.attributes) === null || _model$attributes12 === void 0 ? void 0 : _model$attributes12.id);\n    var options = {\n      container: '.elementor-element-' + (model === null || model === void 0 || (_model$attributes13 = model.attributes) === null || _model$attributes13 === void 0 ? void 0 : _model$attributes13.id),\n      id: id\n    };\n    if (settings !== null && settings !== void 0 && (_settings$eael_cursor10 = settings.eael_cursor_glowing_boxes_opacity) !== null && _settings$eael_cursor10 !== void 0 && _settings$eael_cursor10.size) {\n      var _settings$eael_cursor11;\n      options.opacity = (settings === null || settings === void 0 || (_settings$eael_cursor11 = settings.eael_cursor_glowing_boxes_opacity) === null || _settings$eael_cursor11 === void 0 ? void 0 : _settings$eael_cursor11.size) / 10;\n    }\n    if (settings !== null && settings !== void 0 && (_settings$eael_cursor12 = settings.eael_cursor_glowing_boxes_size) !== null && _settings$eael_cursor12 !== void 0 && _settings$eael_cursor12.size) {\n      var _settings$eael_cursor13;\n      options.size = settings === null || settings === void 0 || (_settings$eael_cursor13 = settings.eael_cursor_glowing_boxes_size) === null || _settings$eael_cursor13 === void 0 ? void 0 : _settings$eael_cursor13.size;\n    }\n    if (settings !== null && settings !== void 0 && (_settings$eael_cursor14 = settings.eael_cursor_glowing_boxes_border_radius) !== null && _settings$eael_cursor14 !== void 0 && _settings$eael_cursor14.size) {\n      var _settings$eael_cursor15;\n      options.borderRadius = (settings === null || settings === void 0 || (_settings$eael_cursor15 = settings.eael_cursor_glowing_boxes_border_radius) === null || _settings$eael_cursor15 === void 0 ? void 0 : _settings$eael_cursor15.size) + 'px';\n    }\n    if (settings !== null && settings !== void 0 && (_settings$eael_cursor16 = settings.eael_cursor_glowing_boxes_trail_length) !== null && _settings$eael_cursor16 !== void 0 && _settings$eael_cursor16.size) {\n      var _settings$eael_cursor17;\n      options.trailLength = settings === null || settings === void 0 || (_settings$eael_cursor17 = settings.eael_cursor_glowing_boxes_trail_length) === null || _settings$eael_cursor17 === void 0 ? void 0 : _settings$eael_cursor17.size;\n    }\n    if (settings !== null && settings !== void 0 && (_settings$eael_cursor18 = settings.eael_cursor_glowing_boxes_interval) !== null && _settings$eael_cursor18 !== void 0 && _settings$eael_cursor18.size) {\n      var _settings$eael_cursor19;\n      options.interval = settings === null || settings === void 0 || (_settings$eael_cursor19 = settings.eael_cursor_glowing_boxes_interval) === null || _settings$eael_cursor19 === void 0 ? void 0 : _settings$eael_cursor19.size;\n    }\n    if (settings !== null && settings !== void 0 && (_settings$eael_cursor20 = settings.eael_cursor_glowing_boxes_hue_speed) !== null && _settings$eael_cursor20 !== void 0 && _settings$eael_cursor20.size) {\n      var _settings$eael_cursor21;\n      options.hueSpeed = settings === null || settings === void 0 || (_settings$eael_cursor21 = settings.eael_cursor_glowing_boxes_hue_speed) === null || _settings$eael_cursor21 === void 0 ? void 0 : _settings$eael_cursor21.size;\n    }\n    var glowingBoxes = false;\n    element.on('mouseenter mousemove', function () {\n      if ('glowingBoxes' !== (settings === null || settings === void 0 ? void 0 : settings.eael_cursor_trail_effect)) {\n        return;\n      }\n      if (!glowingBoxes) {\n        glowingBoxes = new eaelGlowingBoxes(options);\n        glowingBoxes.init();\n      }\n      var canvasElements = element.find('.' + id);\n      if (canvasElements.length > 1) {\n        canvasElements.not(':last').remove();\n      }\n    }).on('mouseleave', function () {\n      if (glowingBoxes) {\n        element.find(' > .' + id).fadeOut('slow', function () {\n          if (typeof glowingBoxes.destroy === 'function') {\n            glowingBoxes.destroy();\n          }\n          glowingBoxes = false;\n        });\n      }\n    });\n  }\n  function initColorBalls(model, element) {\n    var _model$attributes14, _model$attributes15, _model$attributes16;\n    var settings = model === null || model === void 0 || (_model$attributes14 = model.attributes) === null || _model$attributes14 === void 0 || (_model$attributes14 = _model$attributes14.settings) === null || _model$attributes14 === void 0 ? void 0 : _model$attributes14.attributes;\n    var id = 'eael-color-balls-' + (model === null || model === void 0 || (_model$attributes15 = model.attributes) === null || _model$attributes15 === void 0 ? void 0 : _model$attributes15.id);\n    var options = {\n      container: '.elementor-element-' + (model === null || model === void 0 || (_model$attributes16 = model.attributes) === null || _model$attributes16 === void 0 ? void 0 : _model$attributes16.id),\n      id: id\n    };\n    var colors = [];\n    for (var i = 1; i <= 7; i++) {\n      if (settings !== null && settings !== void 0 && settings['eael_cursor_color_balls_color_' + i] && (settings === null || settings === void 0 ? void 0 : settings['eael_cursor_color_balls_color_' + i]) !== '') {\n        colors.push(settings['eael_cursor_color_balls_color_' + i]);\n      }\n    }\n    colors = colors.filter(function (color) {\n      return color.trim() !== '';\n    });\n    if (colors.length > 0) {\n      options.colors = colors;\n    }\n    var colorBalls = false;\n    element.on('mouseenter mousemove', function () {\n      if ('colorBalls' !== (settings === null || settings === void 0 ? void 0 : settings.eael_cursor_trail_effect)) {\n        return;\n      }\n      if (!colorBalls) {\n        colorBalls = eaelColorBalls(options);\n      }\n      var canvasElements = element.find('.' + id);\n      if (canvasElements.length > 1) {\n        canvasElements.not(':last').remove();\n      }\n    }).on('mouseleave', function () {\n      if (colorBalls) {\n        element.find(' > .' + id).fadeOut('slow', function () {\n          if (typeof colorBalls.destroy === 'function') {\n            colorBalls.destroy();\n          }\n          colorBalls = false;\n        });\n      }\n    });\n  }\n  function get_svg_by_icon(_x3) {\n    return _get_svg_by_icon.apply(this, arguments);\n  }\n  function _get_svg_by_icon() {\n    _get_svg_by_icon = _asyncToGenerator(/*#__PURE__*/_regenerator().m(function _callee2(settings) {\n      var _settings$icon, _settings$icon2, _icon$value, _icon$library, _icon$value2;\n      var icon, iconName, library, iClass, response, svgObject, iconData, viewBox, svgHtml, color, _t3;\n      return _regenerator().w(function (_context2) {\n        while (1) switch (_context2.p = _context2.n) {\n          case 0:\n            if (!(!(settings !== null && settings !== void 0 && settings.icon) || !(settings !== null && settings !== void 0 && (_settings$icon = settings.icon) !== null && _settings$icon !== void 0 && _settings$icon.value) || !(settings !== null && settings !== void 0 && (_settings$icon2 = settings.icon) !== null && _settings$icon2 !== void 0 && _settings$icon2.library))) {\n              _context2.n = 1;\n              break;\n            }\n            return _context2.a(2, false);\n          case 1:\n            icon = settings === null || settings === void 0 ? void 0 : settings.icon;\n            iconName = icon === null || icon === void 0 || (_icon$value = icon.value) === null || _icon$value === void 0 ? void 0 : _icon$value.replace(/(fas fa\\-|fab fa\\-|far fa\\-)/, '');\n            library = icon === null || icon === void 0 || (_icon$library = icon.library) === null || _icon$library === void 0 ? void 0 : _icon$library.replace('fa-', '');\n            iClass = icon === null || icon === void 0 || (_icon$value2 = icon.value) === null || _icon$value2 === void 0 ? void 0 : _icon$value2.replace(/\\s+/g, '-');\n            _context2.p = 2;\n            _context2.n = 3;\n            return fetch(settings.svgPath + library + '.json');\n          case 3:\n            response = _context2.v;\n            _context2.n = 4;\n            return response.json();\n          case 4:\n            svgObject = _context2.v;\n            if (!(!svgObject.icons || !svgObject.icons[iconName])) {\n              _context2.n = 5;\n              break;\n            }\n            return _context2.a(2, false);\n          case 5:\n            iconData = svgObject.icons[iconName];\n            viewBox = \"0 0 \".concat(iconData[0], \" \").concat(iconData[1]);\n            svgHtml = '<svg ';\n            color = '';\n            if (settings !== null && settings !== void 0 && settings.color) {\n              color = settings === null || settings === void 0 ? void 0 : settings.color;\n            }\n            if (settings !== null && settings !== void 0 && settings.size) {\n              svgHtml += \"width=\\\"\".concat(settings === null || settings === void 0 ? void 0 : settings.size, \"\\\" \");\n              svgHtml += \"height=\\\"\".concat(settings === null || settings === void 0 ? void 0 : settings.size, \"\\\" \");\n            }\n            svgHtml += \"class=\\\"svg-inline--\".concat(iClass, \" eael-svg-icon\\\" aria-hidden=\\\"true\\\" data-icon=\\\"\").concat(iconName, \"\\\" role=\\\"img\\\" xmlns=\\\"http://www.w3.org/2000/svg\\\" viewBox=\\\"\").concat(viewBox, \"\\\">\");\n            svgHtml += \"<path fill=\\\"\".concat(color, \"\\\" d=\\\"\").concat(iconData[4], \"\\\"></path>\");\n            svgHtml += \"</svg>\";\n            return _context2.a(2, svgHtml);\n          case 6:\n            _context2.p = 6;\n            _t3 = _context2.v;\n            console.error('Error loading cursor icon JSON:', _t3);\n            return _context2.a(2, false);\n        }\n      }, _callee2, null, [[2, 6]]);\n    }));\n    return _get_svg_by_icon.apply(this, arguments);\n  }\n  function renderCustomCursor(_x4) {\n    return _renderCustomCursor.apply(this, arguments);\n  }\n  function _renderCustomCursor() {\n    _renderCustomCursor = _asyncToGenerator(/*#__PURE__*/_regenerator().m(function _callee3(model) {\n      var _model$attributes17, _model$attributes18;\n      var settings, elementId, element, cursor, cursor_css, _settings$eael_custom30, pointer_cursor, _settings$eael_custom31;\n      return _regenerator().w(function (_context3) {\n        while (1) switch (_context3.n) {\n          case 0:\n            settings = model === null || model === void 0 || (_model$attributes17 = model.attributes) === null || _model$attributes17 === void 0 || (_model$attributes17 = _model$attributes17.settings) === null || _model$attributes17 === void 0 ? void 0 : _model$attributes17.attributes;\n            elementId = model === null || model === void 0 || (_model$attributes18 = model.attributes) === null || _model$attributes18 === void 0 ? void 0 : _model$attributes18.id, element = $(\".elementor-element-\".concat(elementId));\n            window['eael_cursor_trail_' + elementId] = 'yes' === (settings === null || settings === void 0 ? void 0 : settings.eael_cursor_trail_show);\n            window['eael_cursor_type_' + elementId] = 'yes' === (settings === null || settings === void 0 ? void 0 : settings.eael_enable_custom_cursor) ? settings === null || settings === void 0 ? void 0 : settings.eael_custom_cursor_type : false;\n            if (!('yes' === (settings === null || settings === void 0 ? void 0 : settings.eael_enable_custom_cursor))) {\n              _context3.n = 9;\n              break;\n            }\n            cursor = '';\n            cursor_css = '';\n            if (!('image' === (settings === null || settings === void 0 ? void 0 : settings.eael_custom_cursor_type))) {\n              _context3.n = 1;\n              break;\n            }\n            cursor = 'url(\"' + (settings === null || settings === void 0 || (_settings$eael_custom30 = settings.eael_custom_cursor_image) === null || _settings$eael_custom30 === void 0 ? void 0 : _settings$eael_custom30.url) + '\") 0 0, auto';\n            _context3.n = 4;\n            break;\n          case 1:\n            if (!('icon' === (settings === null || settings === void 0 ? void 0 : settings.eael_custom_cursor_type))) {\n              _context3.n = 3;\n              break;\n            }\n            _context3.n = 2;\n            return handleIconCursor(settings, element);\n          case 2:\n            cursor = _context3.v;\n            _context3.n = 4;\n            break;\n          case 3:\n            if ('svg_code' === (settings === null || settings === void 0 ? void 0 : settings.eael_custom_cursor_type)) {\n              cursor = 'url(\"data:image/svg+xml;base64,' + btoa(settings === null || settings === void 0 ? void 0 : settings.eael_custom_cursor_svg_code) + '\") 0 0, auto';\n            } else if ('regular' === (settings === null || settings === void 0 ? void 0 : settings.eael_custom_cursor_type) && settings !== null && settings !== void 0 && settings.eael_custom_cursor_regular) {\n              cursor = settings === null || settings === void 0 ? void 0 : settings.eael_custom_cursor_regular;\n            } else if ('circle' === (settings === null || settings === void 0 ? void 0 : settings.eael_custom_cursor_type)) {\n              cursor = handleCircleCursor(model, element);\n            }\n          case 4:\n            if (cursor) {\n              cursor_css += '.elementor-element-' + elementId + '{ cursor: ' + cursor + '; }';\n            }\n            pointer_cursor = '';\n            if (!('yes' === (settings === null || settings === void 0 ? void 0 : settings.eael_enable_pointer_cursor))) {\n              _context3.n = 8;\n              break;\n            }\n            if (!('image' === (settings === null || settings === void 0 ? void 0 : settings.eael_custom_cursor_type_pointer))) {\n              _context3.n = 5;\n              break;\n            }\n            pointer_cursor = 'url(\"' + (settings === null || settings === void 0 || (_settings$eael_custom31 = settings.eael_custom_cursor_image_pointer) === null || _settings$eael_custom31 === void 0 ? void 0 : _settings$eael_custom31.url) + '\") 0 0, auto';\n            _context3.n = 8;\n            break;\n          case 5:\n            if (!('icon' === (settings === null || settings === void 0 ? void 0 : settings.eael_custom_cursor_type_pointer))) {\n              _context3.n = 7;\n              break;\n            }\n            _context3.n = 6;\n            return handleIconCursor(settings, element, '_pointer');\n          case 6:\n            pointer_cursor = _context3.v;\n            _context3.n = 8;\n            break;\n          case 7:\n            if ('svg_code' === (settings === null || settings === void 0 ? void 0 : settings.eael_custom_cursor_type_pointer)) {\n              pointer_cursor = 'url(\"data:image/svg+xml;base64,' + btoa(settings === null || settings === void 0 ? void 0 : settings.eael_custom_cursor_svg_code_pointer) + '\") 0 0, auto';\n            } else if ('regular' === (settings === null || settings === void 0 ? void 0 : settings.eael_custom_cursor_type_pointer) && settings !== null && settings !== void 0 && settings.eael_custom_cursor_regular_pointer) {\n              pointer_cursor = settings === null || settings === void 0 ? void 0 : settings.eael_custom_cursor_regular_pointer;\n            } else if ('circle' === (settings === null || settings === void 0 ? void 0 : settings.eael_custom_cursor_type_pointer)) {\n              pointer_cursor = handleCircleCursor(model, element, '_pointer');\n            }\n          case 8:\n            if (pointer_cursor) {\n              cursor_css += '.elementor-element-' + elementId + ' ' + (settings === null || settings === void 0 ? void 0 : settings.eael_pointer_selectors.join(', .elementor-element-' + elementId + ' ')) + '{ cursor: ' + pointer_cursor + '; }';\n            }\n            if (element.find('#eael-cursor-style-' + elementId).length) {\n              element.find('#eael-cursor-style-' + elementId).remove();\n            }\n            if (cursor_css) {\n              element.append('<style id=\"eael-cursor-style-' + elementId + '\">' + DOMPurify.sanitize(cursor_css) + '</style>');\n            }\n          case 9:\n            if ('yes' === (settings === null || settings === void 0 ? void 0 : settings.eael_cursor_trail_show)) {\n              if ('following_dots' === (settings === null || settings === void 0 ? void 0 : settings.eael_cursor_trail_effect)) {\n                initFollowingDotsTrail(model, element);\n              } else if ('phantomsmoke' === (settings === null || settings === void 0 ? void 0 : settings.eael_cursor_trail_effect)) {\n                initSmokyGhostCursor(model, element);\n              } else if ('spiritecho' === (settings === null || settings === void 0 ? void 0 : settings.eael_cursor_trail_effect)) {\n                initspiritecho(model);\n              } else if ('frostsparkles' === (settings === null || settings === void 0 ? void 0 : settings.eael_cursor_trail_effect)) {\n                initfrostsparkles(model, element);\n              } else if ('trailparticles' === (settings === null || settings === void 0 ? void 0 : settings.eael_cursor_trail_effect)) {\n                inittrailparticles(model, element);\n              } else if ('inktrail' === (settings === null || settings === void 0 ? void 0 : settings.eael_cursor_trail_effect)) {\n                initinktrail(model, element);\n              } else if ('glowingBoxes' === (settings === null || settings === void 0 ? void 0 : settings.eael_cursor_trail_effect)) {\n                initGlowingBoxes(model, element);\n              } else if ('colorBalls' === (settings === null || settings === void 0 ? void 0 : settings.eael_cursor_trail_effect)) {\n                initColorBalls(model, element);\n              }\n            }\n          case 10:\n            return _context3.a(2);\n        }\n      }, _callee3);\n    }));\n    return _renderCustomCursor.apply(this, arguments);\n  }\n  function getHoverEffectSettingsVal(models) {\n    $.each(models, function (i, model) {\n      renderCustomCursor(model);\n      if (model.attributes.elType !== 'widget') {\n        getHoverEffectSettingsVal(model.attributes.elements.models);\n      }\n    });\n  }\n  getHoverEffectSettingsVal(window.elementor.elements.models);\n};\njQuery(window).on(\"elementor/frontend/init\", function () {\n  if (eael.elementStatusCheck('eaelCustomCursor')) {\n    return false;\n  }\n  elementorFrontend.hooks.addAction(\"frontend/element_ready/widget\", CustomCursorHandler);\n});\neael.hooks.addAction(\"editMode.init\", \"ea\", function () {\n  elementor.channels.editor.on(\"eael:custom_cursor:apply_changes\", function () {\n    elementor.saver.update.apply().then(function () {\n      elementor.reloadPreview();\n    });\n  });\n  elementor.settings.page.addChangeCallback(\"eael_enable_custom_cursor\", function (newValue) {\n    if ('yes' !== newValue) {\n      elementor.saver.update.apply().then(function () {\n        elementor.reloadPreview();\n      });\n    }\n  });\n  elementor.settings.page.addChangeCallback(\"eael_cursor_trail_show\", function (newValue) {\n    if ('yes' !== newValue) {\n      elementor.saver.update.apply().then(function () {\n        elementor.reloadPreview();\n      });\n    }\n  });\n});\n\n//# sourceURL=webpack:///./src/js/edit/custom-cursor.js?");

/***/ })

/******/ });