(()=>{"use strict";var e={n:t=>{var n=t&&t.__esModule?()=>t.default:()=>t;return e.d(n,{a:n}),n},d:(t,n)=>{for(var r in n)e.o(n,r)&&!e.o(t,r)&&Object.defineProperty(t,r,{enumerable:!0,get:n[r]})},o:(e,t)=>Object.prototype.hasOwnProperty.call(e,t)};const t=jQuery;var n=e.n(t);const r=wp.hooks;function o(e){return o="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},o(e)}function i(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,(i=r.key,a=void 0,a=function(e,t){if("object"!==o(e)||null===e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t||"default");if("object"!==o(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(i,"string"),"symbol"===o(a)?a:String(a)),r)}var i,a}var a=function(){function e(){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.productImages=n()(".product_images"),this.events(),this.hooks()}var t,o,a;return t=e,(o=[{key:"hooks",value:function(){(0,r.addFilter)("rank_math_content","rank-math-pro",this.getContent.bind(this),11),(0,r.addFilter)("rankMath_analysis_contentLength","rank-math-pro",this.changeFilteredText.bind(this),11),(0,r.addFilter)("rankMath_analysis_contentLength_boundaries","rank-math-pro",this.contentBoundaries.bind(this),11),(0,r.addAction)("rank_math_data_changed","rank-math-pro",this.refreshResults.bind(this))}},{key:"getContent",value:function(e){return this.productImages.length?(this.productImages.find("li").each((function(){void 0!==n()(this).find("img")[0]&&(e+=n()(this).find("img")[0].outerHTML)})),e):e}},{key:"events",value:function(){this.productImages.length&&this.productImages.on("DOMSubtreeModified",(function(){rankMathEditor.refresh("content")}))}},{key:"changeFilteredText",value:function(e){return e.failed=e.failed.replace("600","200"),e.emptyContent=e.emptyContent.replace("600-2500","200"),e}},{key:"contentBoundaries",value:function(){return{recommended:{boundary:200,score:8},belowRecommended:{boundary:150,score:5},medium:{boundary:120,score:4},belowMedium:{boundary:100,score:3},low:{boundary:80,score:2}}}},{key:"refreshResults",value:function(e){"schemas"===e&&rankMathEditor.refresh("content")}}])&&i(t.prototype,o),a&&i(t,a),Object.defineProperty(t,"prototype",{writable:!1}),e}();n()((function(){new a}))})();