Файловый менеджер - Редактировать - /home/kunzqhe/www/wp-content/themes/themify-ultra/themify/themify-icon-picker/assets/themify.font-icons-select.min.js
Ðазад
'use strict';var Themify_Icons={}; (function(a){const n={};Themify_Icons={target:"",ajaxurl:tfIconPicker.ajaxurl,top:a(window.top.document),loader:null,init(){const c=Themify_Icons;c.top.on("click",".themify_fa_toggle",function(b){b.preventDefault();b.stopPropagation();b=a(this);c.target=b.attr("data-target")?a(b.attr("data-target"),c.top):b.prev();c.showLightbox(c.target.val())}).on("click","#themify_lightbox_fa .lightbox_container a:not(.external-link)",function(b){b.preventDefault();b.stopPropagation();c.setIcon(a(this).data("icon"))}).on("click", "#themify_lightbox_overlay, #themify_lightbox_fa .close_lightbox",function(b){b.preventDefault();b.stopPropagation();c.closeLightbox()}).on("change",".tf-icon-group-select input",function(b){b=a(this);const d=b.val();a("#themify_lightbox_fa .tf-font-group",c.top).hide().filter('[data-group="'+d+'"]').show();"fontawesome"===d&&"true"!==b.attr("data-icons")&&a(this).attr("data-icons",!0);c.getByCategory()});c.Category();c.Search()},getByCategory(c){const b=this,d=a("#themify_lightbox_fa",b.top),e=d.find(".tf-icon-group-select input:checked").val(); n[e]?(c&&c(),b.Loader("spinhide")):(b.Loader("show"),n[e]=!0,a.ajax({url:b.ajaxurl,data:{action:"tf_icon_get_by_type",type:e},type:"POST",success:function(a){var g=b.top[0],f=g.createElement("div");f.innerHTML=a;var h=f.getElementsByClassName("tf_icons_groups"),k=f.querySelector("#tf_svg");f=g.getElementById("tf_svg");if(0<h.length){for(a=h.length-1;-1<a;--a){var l=d[0].querySelector("#"+h[a].id+" .row");l&&(l.innerHTML=h[a].innerHTML)}if(k){if(f){a=f.getElementsByTagName("symbol");h={};for(l=a.length- 1;-1<l;--l)h[a[l].id]=!0;k=k.getElementsByTagName("symbol");g=g.createDocumentFragment();for(a=k.length-1;-1<a;--a)h[k[a].id]||g.appendChild(k[a]);f.firstChild.appendChild(g)}else g.appendChild(k);if(window.top!=window.self)if(g=document.getElementById("tf_svg")){k={};h=document.createDocumentFragment();a=g.getElementsByTagName("symbol");f=f.getElementsByTagName("symbol");for(l=a.length-1;-1<l;--l)k[a[l].id]=!0;for(a=f.length-1;-1<a;--a)k[f[a].id]||h.appendChild(f[a].cloneNode(!0));g.firstChild.appendChild(h)}else document.appendChild(f.cloneNode(!0))}}else if(f= d[0].querySelector('.tf-font-group[data-group="'+e+'"]'))f.innerHTML=a;c&&c();b.Loader("spinhide")}}))},showLightbox(c){const b=this;b.Loader("show");b.loadIconsList(function(){b.getByCategory(function(){const d=b.top.scrollTop()+80,e=a("#themify_lightbox_fa",b.top),m=a("#themify_lightbox_overlay",b.top);c&&a("a",e).removeClass("selected").filter('[data-icon="'+c+'"]').addClass("selected");0===m.length&&a("body",b.top).hasClass("themify_builder_active")&&a("body",b.top).append(m);if(0<e.find("a.selected").length){const a= e.find("a.selected").closest(".tf-font-group").data("group");e.find('.tf-icon-group-select input[value="'+a+'"]').click()}else e.find(".tf-icon-group-select input:first").click();a("#themify-search-icon-input",e).val("").trigger("keyup");a(".themify-lightbox-icon".$lightbox).find(".selected").trigger("click");m.show();e.css("top",b.top.height()).show().animate({top:d},600)})})},loadIconsList(c){const b=this;if(0<a("#themify_lightbox_fa",b.top).length)c();else{let d=!1,e=!1;window.top.Themify.LoadCss(tfIconPicker.url+ "styles.css",null,null,null,function(){d=!0;!0===e&&c()});a.ajax({url:b.ajaxurl,data:{action:"tf_icon_picker_lightbox"},type:"POST",success:function(m){a("body",b.top).append(m);e=!0;!0===d&&c()}})}},setIcon(c){Themify_Icons.target.val(c).trigger("change");"undefined"!==typeof Themify&&Themify.triggerEvent(Themify_Icons.target[0],"change");let b=a(".fa:not(.icon-close)",Themify_Icons.target.parent().parent());0>=b.length&&(b=a(".font-icon-preview i",Themify_Icons.target.parent().parent()));0<b.length&& a.ajax({url:Themify_Icons.ajaxurl,data:{action:"tf_get_icon",tf_icon:c},success:function(a){b.removeClass().addClass(a)}});Themify_Icons.closeLightbox()},closeLightbox(){a("#themify_lightbox_fa",Themify_Icons.top).animate({top:Themify_Icons.top.height()},400,function(){a("#themify_lightbox_overlay",Themify_Icons.top).hide();a(this).hide()})},Category(){const c=this;c.top.on("click",".themify-lightbox-icon li",function(b){b.preventDefault();b.stopPropagation();b=a(this).hasClass("selected");a(this).closest(".themify-lightbox-icon").find(".selected").removeClass("selected"); if(b)a(this).closest(".lightbox_container").find("section").fadeIn("fast",function(){a("#themify-search-icon-input",c.top).trigger("keyup")});else{b=a(this).data("id");const d=a("#"+b,c.top);a(this).addClass("selected");0<d.length&&a(this).closest(".lightbox_container").find("section").not("#"+b).fadeOut("fast",function(){d.fadeIn("normal")})}c.getByCategory()})},Search(){a.expr[":"].contains=a.expr.createPseudo(function(c){return function(b){return 0<=a(b).text().toUpperCase().indexOf(c.toUpperCase())}}); Themify_Icons.top.on("keyup","#themify-search-icon-input",function(){var c=a.trim(a(this).val()),b=a("#themify_lightbox_fa",Themify_Icons.top).find(".tf-font-group a"),d=a("#themify_lightbox_fa",Themify_Icons.top).find("section");c?(d.hide(),b.hide().filter(":contains("+c.toUpperCase()+")").show().each(function(){a(this).closest("section").show()})):(d.show(),b.show())})},Loader(c){"undefined"!==typeof ThemifyBuilderCommon?ThemifyBuilderCommon.showLoader(c):(null===this.loader&&(this.loader=a(".tb_alert", this.top)),0>=this.loader.length||("show"===c?this.loader.addClass("busy").fadeIn(800):"spinhide"===c&&this.loader.removeClass("busy").fadeOut(800)))}};Themify_Icons.init()})(jQuery);
| ver. 1.4 |
Github
|
.
| PHP 7.4.33 | Ð“ÐµÐ½ÐµÑ€Ð°Ñ†Ð¸Ñ Ñтраницы: 0 |
proxy
|
phpinfo
|
ÐаÑтройка