!function(s){"use strict";wp.customize.controlConstructor.gdlr_core_fontslider=wp.customize.Control.extend({ready:function(){var o=this;this.container.find(".gdlr-core-customizer-fontslider").each(function(){var e=s(this),t=s('<div class="gdlr-core-customizer-fontslider-appearance" ></div>'),i=s(this).attr("data-min-value")?parseInt(s(this).attr("data-min-value")):6,n=s(this).attr("data-max-value")?parseInt(s(this).attr("data-max-value")):120,a=s(this).attr("data-suffix")?s(this).attr("data-suffix"):"px",r=e.val()?e.val():0;"none"==a&&(a=""),t.insertBefore(s(this)),t.slider({range:"min",min:i,max:n,value:parseInt(r),slide:function(t,i){e.val(i.value+a),o.setting.set(i.value+a)}}),e.val(parseInt(r)+a),s(this).on("input change",function(){t.slider("value",parseInt(e.val()))})})}}),s(document).ready(function(){s("body").on("change","input[data-input-type]",function(){var t=s(this).val().match(/^-?\d+/g),i="";"pixel"==s(this).attr("data-input-type")&&(i="px"),void 0!==t&&null!=t&&s(this).val(parseInt(t[0])+i)}),s("body").on("keydown","input[data-input-type]",function(t){var i=t.keyCode?t.keyCode:t.which;if(40==i||38==i){var e=s(this).val(),n=e.match(/^\d+/g),a="";"pixel"==s(this).attr("data-input-type")&&(a=0<e.length&&"%"==e.charAt(e.length-1)?"%":"px"),void 0!==n&&null!=n&&(40==i?s(this).val(parseInt(n[0])-1+a):38==i&&s(this).val(parseInt(n[0])+1+a))}}),"undefined"!=typeof gdlr_core_customizer_controls&&s.each(gdlr_core_customizer_controls,function(t,r){var o=s("#sub-accordion-section-"+t.trim());for(var i in o.length||(o=s("#accordion-section-"+t.trim()).children(".accordion-section-content")),r){var e=!0;for(var n in r[i]){var a=o.find('[data-customize-setting-link*="['+n+']"]'),c="";c=a.is('input[type="checkbox"]')?a.is(":checked")?"enable":"disable":a.is('input[type="radio"]')?a.filter(":checked").val():a.val(),e=e&&(c==r[i][n]||r[i][n].constructor===Array&&-1!=r[i][n].indexOf(c))}e?o.children("#customize-control-"+i).css("display","block"):o.children("#customize-control-"+i).css("display","none")}o.bind("change",'select, input[type="checkbox"], input[type="radio"]',function(){for(var t in r){var i=!0;for(var e in r[t]){var n=o.find('[data-customize-setting-link*="['+e+']"]'),a="";a=n.is('input[type="checkbox"]')?n.is(":checked")?"enable":"disable":n.is('input[type="radio"]')?n.filter(":checked").val():n.val(),i=i&&(a==r[t][e]||r[t][e].constructor===Array&&-1!=r[t][e].indexOf(a))}i?o.children("#customize-control-"+t).slideDown(200):o.children("#customize-control-"+t).slideUp(200)}})})})}(jQuery);