(()=>{"use strict";var n={n:t=>{var a=t&&t.__esModule?()=>t.default:()=>t;return n.d(a,{a}),a},d:(t,a)=>{for(var e in a)n.o(a,e)&&!n.o(t,e)&&Object.defineProperty(t,e,{enumerable:!0,get:a[e]})},o:(n,t)=>Object.prototype.hasOwnProperty.call(n,t)};const t=jQuery;var a=n.n(t);function e(n){return e="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(n){return typeof n}:function(n){return n&&"function"==typeof Symbol&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},e(n)}a()((function(){if("undefined"!=typeof inlineEditPost){var n=a()("#rank-math-seo-filter"),t=a()("#rank-math-schema-filter");n.length&&n.on("change",(function(){t.addClass("hidden"),"schema_type"===a()(this).val()&&t.removeClass("hidden")})).trigger("change");var r=function(n){var t=n.find(".cat-checklist").not(".rank-math-robots-checklist").find("input");n.find("#rank_math_primary_term option").each((function(n,e){var r=a()(e),i=r.val();if("0"===i)return!0;t.filter('[value="'+i+'"]').prop("checked")?r.prop("hidden",!1):r.prop("hidden",!0)})),t.filter(":checked").length?n.find(".inline-edit-rank-math-primary-term").removeClass("hidden"):n.find(".inline-edit-rank-math-primary-term").addClass("hidden"),1===t.filter(":checked").length&&n.find("#rank_math_primary_term").val(t.filter(":checked").val()),t.off().on("change",(function(e){var r=a()(e.target),i=r.val();r.prop("checked")?n.find("#rank_math_primary_term").find('option[value="'+i+'"]').prop("hidden",!1):(n.find("#rank_math_primary_term").val()===i&&n.find("#rank_math_primary_term").val("0"),n.find("#rank_math_primary_term").find("option[value="+i+"]").prop("hidden",!0)),t.filter(":checked").length?n.find(".inline-edit-rank-math-primary-term").removeClass("hidden"):n.find(".inline-edit-rank-math-primary-term").addClass("hidden"),1===t.filter(":checked").length&&n.find("#rank_math_primary_term").val(t.filter(":checked").val())}))},i=inlineEditPost.edit;inlineEditPost.edit=function(n){i.apply(this,arguments);var t=0;if("object"===e(n)&&(t=parseInt(this.getId(n))),0!==t){var o=a()("#edit-"+t),d=a()("#post-"+t);o.find("#rank_math_title").val(d.find(".rank-math-title-value").val()),o.find("#rank_math_description").val(d.find(".rank-math-description-value").val());var l=d.find(".rank-math-robots-meta-value").val(),c=l?JSON.parse(l):[];o.find(".rank_math_robots input").prop("checked",!1),a().each(c,(function(n,t){o.find("#rank_math_robots_"+t+"_input").prop("checked",!0)})),o.find("#rank_math_robots_index_input, #rank_math_robots_noindex_input").on("click",(function(){var n="rank_math_robots_noindex_input"===this.id;if(this.checked){var t="#rank_math_robots_"+(n?"":"no")+"index_input";o.find(t).prop("checked",!1)}})),o.find("#rank_math_focus_keyword").val(a().trim(d.find(".rank-math-focus-keywords-value").val())),o.find("#rank_math_canonical_url").val(d.find(".rank-math-canonical-url-value").val()),o.find("#rank_math_canonical_url").attr("placeholder",d.find(".rank-math-canonical-placeholder-value").val()),r(o),o.find("#rank_math_primary_term").val(d.find(".rank-math-primary-term-value").val())}};var o=inlineEditPost.setBulk;inlineEditPost.setBulk=function(){o.apply(this,arguments);var n=a()("tr.bulk-edit-row");r(n),n.find(".rank-math-robots-checklist input").prop("checked",!1)};var d=function(n,t){a()(n).on("click",(function(){var n=a()(t).val();return"rank_math_bulk_schema_none"!==n&&"rank_math_bulk_schema_default"!==n||confirm(rankMath.confirmSchemaDelete)}))};d("#doaction","#bulk-action-selector-top"),d("#doaction2","#bulk-action-selector-bottom")}}))})();