Файловый менеджер - Редактировать - /home/freeclou/optimyar/wp-content/plugins/elementor-extras/assets/lib/hotips/hotips.min.js
Назад
!function(t,o,e,s){t.hotips=function(s,i){var n={scope:null,id:null,position:"top",arrowPositionH:"center",arrowPositionV:"center",fixed:!1,trigger:{desktop:"mouseenter",tablet:"click_target",mobile:"click_target"},hide:{desktop:"mouseleave",tablet:"click_out",mobile:"click_out"},delayIn:0,delayOut:0,speed:.2,content:!1,source:!1,responsive:{disable:!1,breakpoints:{mobile:0,tablet:768,desktop:1025}},class:null},p=this;p.opts={};var a=null,l=null,r=null,c=t(s),d=null,h=!1,u=!1,f=null,g=null,m=0,w=0,v=-20;p.init=function(){null===i.delayIn&&(i.delayIn=n.delayIn),null===i.delayOut&&(i.delayOut=n.delayOut),p.opts=t.extend({},n,i),p._construct()},p._construct=function(){p.opts.scope?(a=p.opts.scope,r=p.opts.scope):(a=t(o),r=t(e)),p.canShow()&&(p.setTriggers(),c.data("hotips-position")&&(p.opts.position=c.data("hotips-position")),c.data("hotips-arrow-position-h")&&(p.opts.arrowPositionH=c.data("hotips-arrow-position-h")),c.data("hotips-arrow-position-v")&&(p.opts.arrowPositionV=c.data("hotips-arrow-position-v")),l=t('<div class="hotip-tooltip"></div>'),p.opts.id&&l.attr("data-target-id",p.opts.id),p.setup(),p.events())},p.addClasses=function(){var t="",o=c.attr("data-hotips-class"),e=p.opts.classes;o?t+=o:e&&(o+=e),l.addClass(t)},p.setup=function(){p.setContent()&&p.position()},p.setContent=function(){var o=null;if(c.attr("data-hotips-content")){if(o=r.find(c.attr("data-hotips-content")),!o.length||""===t.trim(o.html()))return!1;var e=o.html();d=t("<span>"+e+"</span>").addClass("ee-tooltip__content")}else if(p.opts.source){if("string"==typeof p.opts.source?o=r.find(p.opts.source):"object"==typeof p.opts.source&&(o=p.opts.source),!o.length||""===t.trim(o.html()))return!1;var e=o.html();d=t("<span>"+e+"</span>").addClass("ee-tooltip__content")}else{if(!p.opts.content)return!1;d=p.opts.content}return!0},p.events=function(){d&&(t(o).on("resize",p.onResize),c.on("hotip.show",p.show),c.on("hotip.hide",p.hide),p.setTriggerEvents())},p.setTriggers=function(){p.isMobile()?(f=p.opts.trigger.mobile,g=p.opts.hide.mobile):p.isTablet()?(f=p.opts.trigger.tablet,g=p.opts.hide.tablet):(f=p.opts.trigger.desktop,g=p.opts.hide.desktop)},p.setTriggerEvents=function(){p.isDesktop()?p.setDesktopTriggerEvents():p.setMobileTriggerEvents()},p.setDesktopTriggerEvents=function(){"mouseenter"===f||"hover"===f?c.on("mouseenter",p.show):"click_target"===f?c.on("click",p.show):"load"===f?t(p.show):c.on("mouseenter",p.show),"mouseleave"===g?c.on("mouseleave",p.hide):"click_out"===g?r.on("mouseup",p.clickOutside):"click_any"===g?(r.on("mouseup",p.hide),c.off("click",p.show).on("click",p.toggle)):"click_target"!==f&&"click_target"===g?c.on("click",p.hide):"click_target"===f&&"click_target"===g?c.off("click",p.show).on("click",p.toggle):c.on("mouseleave",p.hide)},p.setMobileTriggerEvents=function(){"mouseenter"===f||"hover"===f?c.on("mouseenter",p.show):"click_target"===f?c.on("touchstart",p.show):"load"===f?t(p.show):c.on("mouseenter",p.show),"mouseleave"===g?c.on("mouseleave",p.hide):"click_out"===g?r.on("mouseup",p.clickOutside):"click_any"===g?c.off("touchstart",p.show).on("touchstart",p.toggle).on("mouseleave",p.hide):"click_target"!==f&&"click_target"===g?c.on("touchstart",p.hide):"click_target"===f&&"click_target"===g?c.off("touchstart",p.show).on("touchstart",p.toggle):c.on("mouseleave",p.hide)},p.removeTriggerEvents=function(){c.off("mouseenter",p.show),c.off("touchstart",p.show),c.off("mouseleave",p.hide),c.off("click",p.show),c.off("touchstart",p.show),c.off("click",p.hide),c.off("touchstart",p.hide),c.off("click",p.toggle),c.off("touchstart",p.toggle),r.off("mouseup",p.clickOutside),r.off("touchstart",p.clickOutside)},p.clickOutside=function(t){var o=!c.is(t.target)&&0===c.has(t.target).length,e=!l.is(t.target)&&0===l.has(t.target).length;o&&e&&p.hide()},p.getPosition=function(){a.width()<l.outerWidth()&&l.css("max-width",a.width()),p.opts.position||(p.opts.position="bottom");var e=p.opts.position,s="left"===e||"right"===e?p.opts.arrowPositionV:p.opts.arrowPositionH,i=p.opts.fixed?0:t(o).scrollTop(),n=l.get(0).getBoundingClientRect(),r=c.get(0).getBoundingClientRect(),d=p.opts.fixed?n.width:l.outerWidth(),h=p.opts.fixed?n.height:l.outerHeight(),u=p.opts.fixed?r.top:c.offset().top,f=p.opts.fixed?r.left:c.offset().left,g=p.opts.fixed?r.width:c.outerWidth(),k=p.opts.fixed?r.height:c.outerHeight();"bottom"===p.opts.position?(w=u+k+10,m=f+g/2-d/2,v=20):"top"===p.opts.position?(w=u-h-10,m=f+g/2-d/2,v=-20):"left"===p.opts.position?(w=u+k/2-h/2,m=f-d-10,v=-20):"right"===p.opts.position&&(w=u+k/2-h/2,m=f+g+10,v=20),"top"!==p.opts.position&&"bottom"!==p.opts.position||("right"===p.opts.arrowPositionH?m=f+g-d:"left"===p.opts.arrowPositionH&&(m=f)),"left"!==p.opts.position&&"right"!==p.opts.position||("bottom"===p.opts.arrowPositionV?w=u+k-h:"top"===p.opts.arrowPositionV&&(w=u));var b=w-i,y=m,T=t(o).width()-(m+d),_=t(o).height()+i-(w+h);return b<0&&("left"===p.opts.position||"right"===p.opts.position?(w=u,s="top"):(w=u+k+10,e="bottom",v=20)),_<0&&("left"===p.opts.position||"right"===p.opts.position?(w=u+k-h,s="bottom"):(w=u-h-10,e="top",v=-20)),y<0&&("left"===p.opts.position?(m=f+g+10,e="right",v=20):(m=f,s="left")),T<0&&("right"===p.opts.position?(m=f-d-10,e="left",v=-20):(s="right",m="top"===p.opts.position||"bottom"===p.opts.position?f+g-d:f+g)),{top:w,left:m,to:e,at:s}},p.onResize=function(){p.removeTriggerEvents(),p.setTriggers(),p.setTriggerEvents(),p.position()},p.position=function(){var t=p.getPosition();l.css({position:p.opts.fixed?"fixed":"absolute",top:t.top,left:t.left});var o=t.at?"at--"+t.at:"",e=t.to?"to--"+t.to:"";l.removeClass("to--top to--bottom to--right to--left at--left at--right at--top at--bottom"),l.addClass(e+" "+o)},p.canShow=function(){return("tablet"!==p.opts.responsive.disable||!p.isTablet()&&!p.isMobile())&&("mobile"!==p.opts.responsive.disable||!p.isMobile())},p.toggle=function(t){h?p.hide(t):p.show(t)},p.show=function(o){!0!==h&&d&&(h=!0,p.addClasses(),l.empty().append(d),r.find("body").append(l),l.css({position:"fixed",left:-99999,top:-99999}),void 0!==t.fn._resize&&p.opts.scope&&l._resize(function(){p.onResize()}),p.position(),TweenMax.killTweensOf(l),"top"===p.opts.position?TweenMax.fromTo(l,p.opts.speed,{top:w+v,autoAlpha:0},{delay:p.opts.delayIn,top:w,autoAlpha:1,onComplete:function(){h=!0}}):"right"===p.opts.position?TweenMax.fromTo(l,p.opts.speed,{left:m+v,autoAlpha:0},{delay:p.opts.delayIn,left:m,autoAlpha:1,onComplete:function(){h=!0}}):"bottom"===p.opts.position?TweenMax.fromTo(l,p.opts.speed,{top:w+v,autoAlpha:0},{delay:p.opts.delayIn,top:w,autoAlpha:1,onComplete:function(){h=!0}}):"left"===p.opts.position&&TweenMax.fromTo(l,p.opts.speed,{left:m+v,autoAlpha:0},{delay:p.opts.delayIn,left:m,autoAlpha:1,onComplete:function(){h=!0}}),"click_any"===p.opts.hide&&"click_target"===p.opts.trigger&&c.on("click",p.show))},p.hide=function(t){TweenMax.killTweensOf(l),"top"===p.opts.position?TweenMax.to(l,p.opts.speed,{top:w+v,autoAlpha:0,delay:p.opts.delayOut,onComplete:function(){l.remove(),h=!1}}):"right"===p.opts.position?TweenMax.to(l,p.opts.speed,{left:m+v,autoAlpha:0,delay:p.opts.delayOut,onComplete:function(){l.remove(),h=!1}}):"bottom"===p.opts.position?TweenMax.to(l,p.opts.speed,{top:w+v,autoAlpha:0,delay:p.opts.delayOut,onComplete:function(){l.remove(),h=!1}}):"left"===p.opts.position&&TweenMax.to(l,p.opts.speed,{left:m+v,autoAlpha:0,delay:p.opts.delayOut,onComplete:function(){l.remove(),h=!1}})},p.isMobile=function(){return a.width()<p.opts.responsive.breakpoints.tablet},p.isTablet=function(){return a.width()>=p.opts.responsive.breakpoints.tablet&&a.width()<p.opts.responsive.breakpoints.desktop},p.isDesktop=function(){return a.width()>=p.opts.responsive.breakpoints.desktop},p.destroy=function(){p.hide(),a.off("resize",p.onResize),p.removeTriggerEvents(),u=!0},p.init()},t.fn.hotips=function(o){return this.each(function(){if(t.fn.hotips.destroy=function(){void 0!==typeof e&&(t(this).data("hotips").destroy(),t(this).removeData("hotips"))},void 0!==typeof t(this).data("hotips")){var e=new t.hotips(this,o);t(this).data("hotips",e)}})}}(jQuery,window,document);
| ver. 1.4 |
Github
|
.
| PHP 8.1.33 | Генерация страницы: 0.01 |
proxy
|
phpinfo
|
Настройка