PATH:
home
/
letacommog
/
renovation-antibes
/
wp-content
/
plugins
/
elementor-extras
/
assets
/
lib
/
hotips
!function(t,o,e,i){t.hotips=function(i,s){var n={scope:null,position:"top",trigger:null,delayIn:0,delayOut:0,class:null},p=this;p.opts={};var l=null,a=null,u=null,f=t(i),h=null,d=!1,r=0,c=0,g=-20;p.init=function(){null===s.delayIn&&(s.delayIn=n.delayIn),null===s.delayOut&&(s.delayOut=n.delayOut),p.opts=t.extend({},n,s),p._construct()},p._construct=function(){p.opts.scope?(l=p.opts.scope,u=p.opts.scope):(l=t(o),u=t(e)),""!==f.data("hotips-position")&&(p.opts.position=f.data("hotips-position")),a=t('<div class="hotip-tooltip"></div>');var i=u.find(f.attr("data-hotips-content"));if(!i.length||i.is(":empty"))return!1;h=i.html(),p.setup(),p.events()},p.addClasses=function(){var t="",o=f.attr("data-hotips-class"),e=p.opts.classes;o?t+=o:e&&(o+=e),a.addClass(t)},p.setup=function(){p.update()},p.events=function(){t(o).resize(p.update),p.opts.trigger&&"hover"!==p.opts.trigger?"click"===p.opts.trigger&&(f.on("click",p.show),u.on("mouseup",function(t){a.is(t.target)||0!==a.has(t.target).length||p.hide()})):(f.on("mouseenter",p.show),f.on("mouseleave",p.hide))},p.update=function(){l.width()<1.5*f.outerWidth()&&a.css("max-width",l.width()/2);var e=p.opts.position,i="";"bottom"===p.opts.position?(c=f.offset().top+f.outerHeight()+10,r=f.offset().left+f.outerWidth()/2-a.outerWidth()/2,g=20):"top"===p.opts.position?(c=f.offset().top-a.outerHeight()-10,r=f.offset().left+f.outerWidth()/2-a.outerWidth()/2,g=-20):"left"===p.opts.position?(c=f.offset().top+f.outerHeight()/2-a.outerHeight()/2,r=f.offset().left-a.outerWidth()-10,g=-20):"right"===p.opts.position&&(c=f.offset().top+f.outerHeight()/2-a.outerHeight()/2,r=f.offset().left+f.outerWidth()+10,g=20);var s=c-t(o).scrollTop(),n=r,u=t(o).width()-(r+a.outerWidth()),h=t(o).height()+t(o).scrollTop()-(c+a.outerHeight());s<0&&("left"===p.opts.position||"right"===p.opts.position?(c=f.offset().top,i="top"):(c=f.offset().top+f.outerHeight()+10,e="bottom",g=20)),h<0&&("left"===p.opts.position||"right"===p.opts.position?(c=f.offset().top+f.outerHeight()-a.outerHeight(),i="bottom"):(c=f.offset().top-a.outerHeight()-10,e="top",g=-20)),n<0&&("left"===p.opts.position?(r=f.offset().left+f.outerWidth()+10,e="right",g=20):(r=f.offset().left,i="left")),u<0&&("right"===p.opts.position?(r=f.offset().left-a.outerWidth()-10,e="left",g=-20):(i="right",r="top"===p.opts.position||"bottom"===p.opts.position?f.offset().left+f.outerWidth()-a.outerWidth():f.offset().left+f.outerWidth())),a.css({top:c,left:r}),a.removeClass("to--top to--bottom to--right to--left at--left at--right at--top at--bottom"),a.addClass("to--"+e),a.addClass("at--"+i)},p.destroy=function(){p.hide(),l.unbind(p.update()),f.unbind("mouseleave",p.hide),a.unbind("click",p.hide),p.opts.trigger&&"hover"!==p.opts.trigger?"click"===p.opts.trigger&&f.unbind("click",p.show):f.unbind("mouseenter",p.show)},p.show=function(){!0!==d&&(p.addClasses(),a.html(h),u.find("body").append(a),p.update(),TweenMax.killTweensOf(a),"top"===p.opts.position?TweenMax.fromTo(a,.2,{top:c+g,autoAlpha:0},{delay:p.opts.delayIn,top:c,autoAlpha:1,onComplete:function(){d=!0}}):"right"===p.opts.position?TweenMax.fromTo(a,.2,{left:r+g,autoAlpha:0},{delay:p.opts.delayIn,left:r,autoAlpha:1,onComplete:function(){d=!0}}):"bottom"===p.opts.position?TweenMax.fromTo(a,.2,{top:c+g,autoAlpha:0},{delay:p.opts.delayIn,top:c,autoAlpha:1,onComplete:function(){d=!0}}):"left"===p.opts.position&&TweenMax.fromTo(a,.2,{left:r+g,autoAlpha:0},{delay:p.opts.delayIn,left:r,autoAlpha:1,onComplete:function(){d=!0}}))},p.hide=function(){TweenMax.killTweensOf(a),"top"===p.opts.position?TweenMax.to(a,.2,{top:c+g,autoAlpha:0,delay:p.opts.delayOut,onComplete:function(){a.remove(),d=!1}}):"right"===p.opts.position?TweenMax.to(a,.2,{left:r+g,autoAlpha:0,delay:p.opts.delayOut,onComplete:function(){a.remove(),d=!1}}):"bottom"===p.opts.position?TweenMax.to(a,.2,{top:c+g,autoAlpha:0,delay:p.opts.delayOut,onComplete:function(){a.remove(),d=!1}}):"left"===p.opts.position&&TweenMax.to(a,.2,{left:r+g,autoAlpha:0,delay:p.opts.delayOut,onComplete:function(){a.remove(),d=!1}})},p.init()},t.fn.hotips=function(o){return this.each(function(){if(t.fn.hotips.destroy=function(){void 0!==e&&(t(this).data("hotips").destroy(),t(this).removeData("hotips"))},void 0===t(this).data("hotips")){var e=new t.hotips(this,o);t(this).data("hotips",e)}})}}(jQuery,window,document);
[+]
..
[-] hotips.min.js
[edit]
[-] hotips.js
[edit]