!function(e,t){"use strict";var i=function(){function e(){return u}function t(e,t,i,a){return"string"==typeof e&&"function"==typeof t&&(i=parseInt(i||10,10),l("actions",e,t,i,a)),f}function i(){var e=Array.prototype.slice.call(arguments),t=e.shift();return"string"==typeof t&&d("actions",t,e),f}function a(e,t){return"string"==typeof e&&r("actions",e,t),f}function n(e,t,i,a){return"string"==typeof e&&"function"==typeof t&&(i=parseInt(i||10,10),l("filters",e,t,i,a)),f}function s(){var e=Array.prototype.slice.call(arguments),t=e.shift();return"string"==typeof t?d("filters",t,e):f}function o(e,t){return"string"==typeof e&&r("filters",e,t),f}function r(e,t,i,a){if(u[e][t])if(i){var n=u[e][t],s;if(a)for(s=n.length;s--;){var o=n[s];o.callback===i&&o.context===a&&n.splice(s,1)}else for(s=n.length;s--;)n[s].callback===i&&n.splice(s,1)}else u[e][t]=[]}function l(e,t,i,a,n){var s={callback:i,priority:a,context:n},o=u[e][t];o?(o.push(s),o=c(o)):o=[s],u[e][t]=o}function c(e){for(var t,i,a,n=1,s=e.length;nt.priority;)e[i]=e[i-1],--i;e[i]=t}return e}function d(e,t,i){var a=u[e][t];if(!a)return"filters"===e&&i[0];var n=0,s=a.length;if("filters"===e)for(;n0},$.fn.outerHTML=function(){return $(this).get(0).outerHTML},acf={l10n:{},o:{},update:function(e,t){this.o[e]=t},get:function(e){return"undefined"!=typeof this.o[e]?this.o[e]:null},_e:function(e,t){t=t||!1;var i=this.l10n[e]||"";return t&&(i=i[t]||""),i},add_action:function(){for(var e=arguments[0].split(" "),t=e.length,i=0;ie.length?Array(1+(t-e.length)).join("0")+e:e};return this.php_js||(this.php_js={}),this.php_js.uniqidSeed||(this.php_js.uniqidSeed=Math.floor(123456789*Math.random())),this.php_js.uniqidSeed++,i=e,i+=a(parseInt((new Date).getTime()/1e3,10),8),i+=a(this.php_js.uniqidSeed,5),t&&(i+=(10*Math.random()).toFixed(8).toString()),i},serialize_form:function(e){var t={},i={};return $selector=e.find("select, textarea, input"),$.each($selector.serializeArray(),function(e,a){"[]"===a.name.slice(-2)&&(a.name=a.name.replace("[]",""),"undefined"==typeof i[a.name]&&(i[a.name]=-1),i[a.name]++,a.name+="["+i[a.name]+"]"),t[a.name]=a.value}),t},serialize:function(e){return this.serialize_form(e)},disable_form:function(e,t){t=t||"",e.find("select, textarea, input").each(function(){acf.disable($(this),t)})},disable:function(e,t){if(t=t||"",e.hasClass("acf-disabled"))return!1;if(t){var i=e.attr("data-disabled"),a=i?i.split(","):[],n=a.indexOf(t);if(n>=0)return!1;a.push(t),i=a.join(","),e.attr("data-disabled",i)}e.prop("disabled",!0)},enable_form:function(e,t){t=t||"",e.find("select, textarea, input").each(function(){acf.enable($(this),t)})},enable:function(e,t){if(t=t||"",e.hasClass("acf-disabled"))return!1;if(t){var i=e.attr("data-disabled"),a=i?i.split(","):[],n=a.indexOf(t);if(n<0)return!1;if(a.splice(n,1),i=a.join(","),e.attr("data-disabled",i),i)return!1}e.prop("disabled",!1)},remove_tr:function(e,t){var i=e.height(),a=e.children().length;e.addClass("acf-remove-element"),setTimeout(function(){e.removeClass("acf-remove-element"),e.html(''),e.children("td").animate({height:0},250,function(){e.remove(),"function"==typeof t&&t()})},250)},remove_el:function(e,t,i){i=i||0,e.css({height:e.height(),width:e.width(),position:"absolute"}),e.wrap('
'),e.animate({opacity:0},250),e.parent(".acf-temp-wrap").animate({height:i},250,function(){$(this).remove(),"function"==typeof t&&t()})},isset:function(){var e=arguments,t=e.length,a=null,n;if(0===t)throw new Error("Empty isset");for(a=e[0],i=1;i #acf-popup"),$popup.exists())return update_popup(e);var t=['
','
','

','
','
',"
",'
',"
"].join("");return $("body").append(t),$("#acf-popup").on("click",".bg, .acf-close-popup",function(e){e.preventDefault(),acf.close_popup()}),this.update_popup(e)},update_popup:function(e){return $popup=$("#acf-popup"),!!$popup.exists()&&(e=$.extend({},{title:"",content:"",width:0,height:0,loading:!1},e),e.title&&$popup.find(".title h3").html(e.title),e.content&&($inner=$popup.find(".inner:first"),$inner.html(e.content),acf.do_action("append",$inner),$inner.attr("style","position: relative;"),e.height=$inner.outerHeight(),$inner.removeAttr("style")),e.width&&$popup.find(".acf-popup-box").css({width:e.width,"margin-left":0-e.width/2}),e.height&&(e.height+=44,$popup.find(".acf-popup-box").css({height:e.height,"margin-top":0-e.height/2})),e.loading?$popup.find(".loading").show():$popup.find(".loading").hide(),$popup)},close_popup:function(){$popup=$("#acf-popup"),$popup.exists()&&$popup.remove()},update_user_setting:function(e,t){$.ajax({url:acf.get("ajaxurl"),dataType:"html",type:"post",data:acf.prepare_for_ajax({action:"acf/update_user_setting",name:e,value:t})})},prepare_for_ajax:function(e){return e.nonce=acf.get("nonce"),e.post_id=acf.get("post_id"),e=acf.apply_filters("prepare_for_ajax",e)},is_ajax_success:function(e){return!(!e||!e.success)},get_ajax_message:function(e){var t={text:"",type:"error"};return e?(e.success&&(t.type="success"),e.data&&e.data.message&&(t.text=e.data.message),e.data&&e.data.error&&(t.text=e.data.error),t):t},is_in_view:function(e){var t=e.offset().top,i=t+e.height();if(t===i)return!1;var a=$(window).scrollTop(),n=a+$(window).height();return i<=n&&t>=a},val:function(e,t){var i=e.val();e.val(t),t!=i&&e.trigger("change")},str_replace:function(e,t,i){return i.split(e).join(t)},str_sanitize:function(e){var t="",a={"æ":"a","å":"a","á":"a","ä":"a","č":"c","ď":"d","è":"e","é":"e","ě":"e","ë":"e","í":"i","ĺ":"l","ľ":"l","ň":"n","ø":"o","ó":"o","ô":"o","ő":"o","ö":"o","ŕ":"r","š":"s","ť":"t","ú":"u","ů":"u","ű":"u","ü":"u","ý":"y","ř":"r","ž":"z"," ":"_","'":"","?":"","/":"","\\":"",".":"",",":"",">":"","<":"",'"':"","[":"","]":"","|":"","{":"","}":"","(":"",")":""};for(e=e.toLowerCase(),i=0;i'),e.append(n))),n.append('"),i==a.value&&e.prop("selectedIndex",t)})},duplicate:function(e){"undefined"!=typeof e.length&&(e={$el:e}),e=acf.parse_args(e,{$el:!1,search:"",replace:"",before:function(e){},after:function(e,t){},append:function(e,t){e.after(t)}});var t=e.$el,i;e.search||(e.search=t.attr("data-id")),e.replace||(e.replace=acf.get_uniqid()),e.before.apply(this,[t]),acf.do_action("before_duplicate",t);var i=t.clone();return i.removeClass("acf-clone"),acf.do_action("remove",i),e.search&&(i.attr("data-id",e.replace),i.find('[id*="'+e.search+'"]').each(function(){$(this).attr("id",$(this).attr("id").replace(e.search,e.replace))}),i.find('[name*="'+e.search+'"]').each(function(){$(this).attr("name",$(this).attr("name").replace(e.search,e.replace))}),i.find('label[for*="'+e.search+'"]').each(function(){$(this).attr("for",$(this).attr("for").replace(e.search,e.replace))})),i.find(".ui-sortable").removeClass("ui-sortable"),acf.do_action("after_duplicate",t,i),e.after.apply(this,[t,i]),e.append.apply(this,[t,i]),setTimeout(function(){acf.do_action("append",i)},1),i},decode:function(e){return $("