Comparing version 1.2.2 to 1.3.0
@@ -1,1 +0,1 @@ | ||
(function(e,t){'object'==typeof exports&&'undefined'!=typeof module?module.exports=t():'function'==typeof define&&define.amd?define(t):e.tippy=t()})(this,function(){'use strict';function t(e){Ce.forEach(function(t){var o=t.popper,i=t.tippyInstance,n=t.settings,r=n.appendTo,s=n.hideOnClick,a=n.trigger;if(r.contains(o)){var p=!0===s||-1!==a.indexOf('focus'),l=!e||o!==e.popper;p&&l&&i.hide(o)}})}function o(t,o){var i=Element.prototype.closest||function(t){for(var o=this;o;){if(e.call(o,t))return o;o=o.parentElement}};return i.call(t,o)}function n(e,t){return Array.prototype.find?e.find(t):e.filter(t)[0]}function r(){var i=function(){Pe.touch=!0,Pe.iOS()&&document.body.classList.add('tippy-touch'),Pe.dynamicInputDetection&&window.performance&&document.addEventListener('mousemove',r)},r=function(){var e;return function(){var t=performance.now();20>t-e&&(Pe.touch=!1,document.removeEventListener('mousemove',r),!Pe.iOS()&&document.body.classList.remove('tippy-touch')),e=t}}();document.addEventListener('click',function(e){if(!(e.target instanceof Element))return t();var i=o(e.target,De.TOOLTIPPED_EL),r=o(e.target,De.POPPER);if(r){var s=n(Ce,function(e){return e.popper===r}),a=s.settings.interactive;if(a)return}if(i){var p=n(Ce,function(e){return e.el===i}),l=p.settings,d=l.hideOnClick,c=l.multiple,f=l.trigger;if(!c&&Pe.touch||!c&&-1!==f.indexOf('click'))return t(p);if(!0!==d||-1!==f.indexOf('click'))return}o(e.target,De.CONTROLLER)||!document.querySelector(De.POPPER)||t()}),document.addEventListener('touchstart',i),window.addEventListener('blur',function(){var t=document,o=t.activeElement;o&&o.blur&&e.call(o,De.TOOLTIPPED_EL)&&o.blur()}),!Pe.SUPPORTS_TOUCH&&(0<navigator.maxTouchPoints||0<navigator.msMaxTouchPoints)&&document.addEventListener('pointerdown',i)}function s(){return!s.done&&(s.done=!0,r(),!0)}function a(e){window.requestAnimationFrame(function(){setTimeout(e,0)})}function p(e){for(var t=[!1,'webkit'],o=e.charAt(0).toUpperCase()+e.slice(1),n=0;n<t.length;n++){var i=t[n],r=i?''+i+o:e;if('undefined'!=typeof window.document.body.style[r])return r}return null}function l(e,t){return Array.prototype.findIndex?e.findIndex(t):e.indexOf(n(e,t))}function d(e){var t=e.getAttribute('title');t&&e.setAttribute('data-original-title',t),e.removeAttribute('title')}function c(e){var t=e.getBoundingClientRect();return 0<=t.top&&0<=t.left&&t.bottom<=(window.innerHeight||document.documentElement.clientHeight)&&t.right<=(window.innerWidth||document.documentElement.clientWidth)}function f(e,t){t?window.getComputedStyle(t)[p('transform')]:window.getComputedStyle(e).opacity}function m(e,t){e.forEach(function(e){e&&t(e.classList)})}function h(e){return{tooltip:e.querySelector(De.TOOLTIP),circle:e.querySelector(De.CIRCLE),content:e.querySelector(De.CONTENT)}}function u(t,o){t.forEach(function(t){if(t){var i=e.call(t,De.CONTENT),n=i?ke(o/1.3):o;t.style[p('transitionDuration')]=n+'ms'}})}function g(e){return'visible'===e.style.visibility}function b(){}function v(e){return e.replace(/-.+/,'')}function y(t){var e,o,i=this,r=n(Ce,function(e){return e.el===i}),s=r.popper,a=r.settings.offset,l=v(s.getAttribute('x-placement')),d=ke(s.offsetWidth/2),c=ke(s.offsetHeight/2),f=5,m=document.documentElement.offsetWidth||document.body.offsetWidth,h=t.pageX,u=t.pageY;'top'===l?(e=h-d+a,o=u-2.25*c):'left'===l?(e=h-2*d-10,o=u-c+a):'right'===l?(e=h+c,o=u-c+a):'bottom'===l?(e=h-d+a,o=u+c/1.5):void 0;('top'===l||'bottom'===l)&&(h+f+d+a>m&&(e=m-f-2*d),0>h-f-d+a&&(e=f)),s.style[p('transform')]='translate3d('+e+'px, '+o+'px, 0)'}function E(e){return e instanceof Element?[e]:Array.isArray(e)?e:[].slice.call(document.querySelectorAll(e))}function w(e,t,o){if(!t)return o();var i=h(e.popper),n=i.tooltip,r=!1,s=function(t){t.target!==n||r||(r=!0,o())};n.addEventListener('webkitTransitionEnd',s),n.addEventListener('transitionend',s),clearTimeout(e._transitionendTimeout),e._transitionendTimeout=setTimeout(function(){r||o()},t)}function O(e){return e&&'[object Function]'==={}.toString.call(e)}function L(e,t){if(1!==e.nodeType)return[];var o=window.getComputedStyle(e,null);return t?o[t]:o}function T(e){return'HTML'===e.nodeName?e:e.parentNode||e.host}function x(e){if(!e||-1!==['HTML','BODY','#document'].indexOf(e.nodeName))return window.document.body;var t=L(e),o=t.overflow,i=t.overflowX,n=t.overflowY;return /(auto|scroll)/.test(o+n+i)?e:x(T(e))}function S(e){var t=e&&e.offsetParent,o=t&&t.nodeName;return o&&'BODY'!==o&&'HTML'!==o?-1!==['TD','TABLE'].indexOf(t.nodeName)&&'static'===L(t,'position')?S(t):t:window.document.documentElement}function A(e){var t=e.nodeName;return'BODY'!==t&&('HTML'===t||S(e.firstElementChild)===e)}function k(e){return null===e.parentNode?e:k(e.parentNode)}function P(e,t){if(!e||!e.nodeType||!t||!t.nodeType)return window.document.documentElement;var o=e.compareDocumentPosition(t)&Node.DOCUMENT_POSITION_FOLLOWING,i=o?e:t,n=o?t:e,r=document.createRange();r.setStart(i,0),r.setEnd(n,0);var s=r.commonAncestorContainer;if(e!==s&&t!==s||i.contains(n))return A(s)?s:S(s);var a=k(e);return a.host?P(a.host,t):P(e,k(t).host)}function C(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:'top',o='top'===t?'scrollTop':'scrollLeft',i=e.nodeName;if('BODY'===i||'HTML'===i){var n=window.document.documentElement,r=window.document.scrollingElement||n;return r[o]}return e[o]}function D(e,t){var o=2<arguments.length&&void 0!==arguments[2]&&arguments[2],i=C(t,'top'),n=C(t,'left'),r=o?-1:1;return e.top+=i*r,e.bottom+=i*r,e.left+=n*r,e.right+=n*r,e}function I(e,t){var o='x'===t?'Left':'Top',i='Left'==o?'Right':'Bottom';return+e['border'+o+'Width'].split('px')[0]+ +e['border'+i+'Width'].split('px')[0]}function H(e,t,o,i,n){return Ae(t['offset'+e],n?t['scroll'+e]:0,o['client'+e],o['offset'+e],n?o['scroll'+e]:0,ze()?o['offset'+e]+i['margin'+('Height'===e?'Top':'Left')]+i['margin'+('Height'===e?'Bottom':'Right')]:0)}function R(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:!0,t=window.document.body,o=window.document.documentElement,i=ze()&&window.getComputedStyle(o);return{height:H('Height',t,o,i,e),width:H('Width',t,o,i,e)}}function N(e){return Ge({},e,{right:e.left+e.width,bottom:e.top+e.height})}function M(e){var t={};if(ze())try{t=e.getBoundingClientRect();var o=C(e,'top'),i=C(e,'left');t.top+=o,t.left+=i,t.bottom+=o,t.right+=i}catch(e){}else t=e.getBoundingClientRect();var n={left:t.left,top:t.top,width:t.right-t.left,height:t.bottom-t.top},r='HTML'===e.nodeName?R():{},s=r.width||e.clientWidth||n.right-n.left,a=r.height||e.clientHeight||n.bottom-n.top,p=e.offsetWidth-s,l=e.offsetHeight-a;if(p||l){var d=L(e);p-=I(d,'x'),l-=I(d,'y'),n.width-=p,n.height-=l}return N(n)}function B(e,t){var o=ze(),i='HTML'===t.nodeName,n=M(e),r=M(t),s=x(e),a=L(t),p=+a.borderTopWidth.split('px')[0],l=+a.borderLeftWidth.split('px')[0],d=N({top:n.top-r.top-p,left:n.left-r.left-l,width:n.width,height:n.height});if(d.marginTop=0,d.marginLeft=0,!o&&i){var c=+a.marginTop.split('px')[0],f=+a.marginLeft.split('px')[0];d.top-=p-c,d.bottom-=p-c,d.left-=l-f,d.right-=l-f,d.marginTop=c,d.marginLeft=f}return(o?t.contains(s):t===s&&'BODY'!==s.nodeName)&&(d=D(d,t)),d}function W(e){var t=window.document.documentElement,o=B(e,t),i=Ae(t.clientWidth,window.innerWidth||0),n=Ae(t.clientHeight,window.innerHeight||0),r=C(t),s=C(t,'left'),a={top:r-o.top+o.marginTop,left:s-o.left+o.marginLeft,width:i,height:n};return N(a)}function U(e){var t=e.nodeName;return'BODY'===t||'HTML'===t?!1:'fixed'===L(e,'position')||U(T(e))}function _(e,t,o,i){var n={top:0,left:0},r=P(e,t);if('viewport'===i)n=W(r);else{var s;'scrollParent'===i?(s=x(T(e)),'BODY'===s.nodeName&&(s=window.document.documentElement)):'window'===i?s=window.document.documentElement:s=i;var a=B(s,r);if('HTML'===s.nodeName&&!U(r)){var p=R(!1),l=p.height,d=p.width;n.top+=a.top-a.marginTop,n.bottom=l+a.top,n.left+=a.left-a.marginLeft,n.right=d+a.left}else n=a}return n.left+=o,n.top+=o,n.right-=o,n.bottom-=o,n}function F(e){var t=e.width,o=e.height;return t*o}function q(e,t,o,i,n){var r=5<arguments.length&&void 0!==arguments[5]?arguments[5]:0;if(-1===e.indexOf('auto'))return e;var s=_(o,i,r,n),a={top:{width:s.width,height:t.top-s.top},right:{width:s.right-t.right,height:s.height},bottom:{width:s.width,height:s.bottom-t.bottom},left:{width:t.left-s.left,height:s.height}},p=Object.keys(a).map(function(e){return Ge({key:e},a[e],{area:F(a[e])})}).sort(function(e,t){return t.area-e.area}),l=p.filter(function(e){var t=e.width,i=e.height;return t>=o.clientWidth&&i>=o.clientHeight}),d=0<l.length?l[0].key:p[0].key,c=e.split('-')[1];return d+(c?'-'+c:'')}function z(e,t,o){var i=P(t,o);return B(o,i)}function Y(e){var t=window.getComputedStyle(e),o=parseFloat(t.marginTop)+parseFloat(t.marginBottom),i=parseFloat(t.marginLeft)+parseFloat(t.marginRight),n={width:e.offsetWidth+i,height:e.offsetHeight+o};return n}function j(e){var t={left:'right',right:'left',bottom:'top',top:'bottom'};return e.replace(/left|right|bottom|top/g,function(e){return t[e]})}function K(e,t,o){o=o.split('-')[0];var i=Y(e),n={width:i.width,height:i.height},r=-1!==['right','left'].indexOf(o),s=r?'top':'left',a=r?'left':'top',p=r?'height':'width',l=r?'width':'height';return n[s]=t[s]+t[p]/2-i[p]/2,n[a]=o===a?t[a]-i[l]:t[j(a)],n}function G(e,t){return Array.prototype.find?e.find(t):e.filter(t)[0]}function X(e,t,o){if(Array.prototype.findIndex)return e.findIndex(function(e){return e[t]===o});var i=G(e,function(e){return e[t]===o});return e.indexOf(i)}function V(e,t,o){var i=void 0===o?e:e.slice(0,X(e,'name',o));return i.forEach(function(e){e.function&&console.warn('`modifier.function` is deprecated, use `modifier.fn`!');var o=e.function||e.fn;e.enabled&&O(o)&&(t.offsets.popper=N(t.offsets.popper),t.offsets.reference=N(t.offsets.reference),t=o(t,e))}),t}function Q(){if(!this.state.isDestroyed){var e={instance:this,styles:{},arrowStyles:{},attributes:{},flipped:!1,offsets:{}};e.offsets.reference=z(this.state,this.popper,this.reference),e.placement=q(this.options.placement,e.offsets.reference,this.popper,this.reference,this.options.modifiers.flip.boundariesElement,this.options.modifiers.flip.padding),e.originalPlacement=e.placement,e.offsets.popper=K(this.popper,e.offsets.reference,e.placement),e.offsets.popper.position='absolute',e=V(this.modifiers,e),this.state.isCreated?this.options.onUpdate(e):(this.state.isCreated=!0,this.options.onCreate(e))}}function J(e,t){return e.some(function(e){var o=e.name,i=e.enabled;return i&&o===t})}function Z(e){for(var t=[!1,'ms','Webkit','Moz','O'],o=e.charAt(0).toUpperCase()+e.slice(1),n=0;n<t.length-1;n++){var i=t[n],r=i?''+i+o:e;if('undefined'!=typeof window.document.body.style[r])return r}return null}function $(){return this.state.isDestroyed=!0,J(this.modifiers,'applyStyle')&&(this.popper.removeAttribute('x-placement'),this.popper.style.left='',this.popper.style.position='',this.popper.style.top='',this.popper.style[Z('transform')]=''),this.disableEventListeners(),this.options.removeOnDestroy&&this.popper.parentNode.removeChild(this.popper),this}function ee(e,t,o,i){var n='BODY'===e.nodeName,r=n?window:e;r.addEventListener(t,o,{passive:!0}),n||ee(x(r.parentNode),t,o,i),i.push(r)}function te(e,t,o,i){o.updateBound=i,window.addEventListener('resize',o.updateBound,{passive:!0});var n=x(e);return ee(n,'scroll',o.updateBound,o.scrollParents),o.scrollElement=n,o.eventsEnabled=!0,o}function oe(){this.state.eventsEnabled||(this.state=te(this.reference,this.options,this.state,this.scheduleUpdate))}function ie(e,t){return window.removeEventListener('resize',t.updateBound),t.scrollParents.forEach(function(e){e.removeEventListener('scroll',t.updateBound)}),t.updateBound=null,t.scrollParents=[],t.scrollElement=null,t.eventsEnabled=!1,t}function ne(){this.state.eventsEnabled&&(window.cancelAnimationFrame(this.scheduleUpdate),this.state=ie(this.reference,this.state))}function re(e){return''!==e&&!isNaN(parseFloat(e))&&isFinite(e)}function se(e,t){Object.keys(t).forEach(function(o){var i='';-1!==['width','height','top','right','bottom','left'].indexOf(o)&&re(t[o])&&(i='px'),e.style[o]=t[o]+i})}function ae(e,t){Object.keys(t).forEach(function(o){var i=t[o];!1===i?e.removeAttribute(o):e.setAttribute(o,t[o])})}function pe(e,t,o){var i=G(e,function(e){var o=e.name;return o===t}),n=!!i&&e.some(function(e){return e.name===o&&e.enabled&&e.order<i.order});if(!n){var r='`'+t+'`';console.warn('`'+o+'`'+' modifier is required by '+r+' modifier in order to work, be sure to include it before '+r+'!')}return n}function le(e){return'end'===e?'start':'start'===e?'end':e}function de(e){var t=1<arguments.length&&void 0!==arguments[1]&&arguments[1],o=Ve.indexOf(e),i=Ve.slice(o+1).concat(Ve.slice(0,o));return t?i.reverse():i}function ce(e,t,o,i){var n=e.match(/((?:\-|\+)?\d*\.?\d*)(.*)/),r=+n[1],s=n[2];if(!r)return e;if(0===s.indexOf('%')){var a;switch(s){case'%p':a=o;break;case'%':case'%r':default:a=i;}var p=N(a);return p[t]/100*r}if('vh'===s||'vw'===s){var l;return l='vh'===s?Ae(document.documentElement.clientHeight,window.innerHeight||0):Ae(document.documentElement.clientWidth,window.innerWidth||0),l/100*r}return r}function fe(e,t,o,i){var n=[0,0],r=-1!==['right','left'].indexOf(i),s=e.split(/(\+|\-)/).map(function(e){return e.trim()}),a=s.indexOf(G(s,function(e){return-1!==e.search(/,|\s/)}));s[a]&&-1===s[a].indexOf(',')&&console.warn('Offsets separated by white space(s) are deprecated, use a comma (,) instead.');var p=/\s*,\s*|\s+/,l=-1===a?[s]:[s.slice(0,a).concat([s[a].split(p)[0]]),[s[a].split(p)[1],s.slice(a+1)]];return l=l.map(function(e,i){var n=(1===i?!r:r)?'height':'width',s=!1;return e.reduce(function(e,t){return''===e[e.length-1]&&-1!==['+','-'].indexOf(t)?(e[e.length-1]=t,s=!0,e):s?(e[e.length-1]+=t,s=!1,e):e.concat(t)},[]).map(function(e){return ce(e,n,t,o)})}),l.forEach(function(e,t){e.forEach(function(o,i){re(o)&&(n[t]+=o*('-'===e[i-1]?-1:1))})}),n}function me(e){return-(e-Ie.distance)+'px'}function he(e){var t=e.el,o=e.popper,i=e.settings,n=i.position,r=i.popperOptions,s=i.offset,l=i.distance,d=i.flipDuration,c=h(o),f=c.tooltip,m=et({placement:n},r||{},{modifiers:et({},r?r.modifiers:{},{flip:et({padding:l+5},r&&r.modifiers?r.modifiers.flip:{}),offset:et({offset:s},r&&r.modifiers?r.modifiers.offset:{})}),onUpdate:function(){var e=f.style;e.top='',e.bottom='',e.left='',e.right='',e[v(o.getAttribute('x-placement'))]=me(l)}});if(window.MutationObserver){var u=o.style,g=new MutationObserver(function(){u[p('transitionDuration')]='0ms',e.popperInstance.update(),a(function(){u[p('transitionDuration')]=d+'ms'})});g.observe(o,{childList:!0,subtree:!0,characterData:!0}),e._mutationObserver=g}return new Je(t,o,m)}function ue(e){var t=e.el,o=e.popper,i=e.settings,n=i.appendTo,r=i.followCursor;n.contains(o)||(n.appendChild(o),e.popperInstance?(e.popperInstance.update(),(!r||Pe.touch)&&e.popperInstance.enableEventListeners()):e.popperInstance=he(e),r&&!Pe.touch&&(t.addEventListener('mousemove',y),e.popperInstance.disableEventListeners()))}function ge(e){var t=e.popper,o=e.popperInstance,i=e.settings.stickyDuration,n=function(){return t.style[p('transitionDuration')]=i+'ms'},r=function(){return t.style[p('transitionDuration')]=''};a(function e(){o&&o.scheduleUpdate(),n(),g(t)?window.requestAnimationFrame(e):r()})}function be(e,t){var o=He.reduce(function(o,i){var n=e.getAttribute('data-'+i.toLowerCase())||t[i];return'false'===n&&(n=!1),'true'===n&&(n=!0),isFinite(n)&&!isNaN(parseFloat(n))&&(n=parseFloat(n)),'string'==typeof n&&'['===n.trim().charAt(0)&&(n=JSON.parse(n)),o[i]=n,o},{});return et({},t,o)}function ye(e,t,o){var i=o.position,n=o.distance,r=o.arrow,s=o.animateFill,a=o.inertia,p=o.animation,l=o.arrowSize,d=o.size,c=o.theme,f=o.html,m=o.zIndex,h=o.interactive,u=document.createElement('div');u.setAttribute('class','tippy-popper'),u.setAttribute('role','tooltip'),u.setAttribute('aria-hidden','true'),u.setAttribute('id','tippy-tooltip-'+e),u.style.zIndex=m;var g=document.createElement('div');if(g.setAttribute('class','tippy-tooltip tippy-tooltip--'+d+' leave'),g.setAttribute('data-animation',p),c.split(' ').forEach(function(e){g.classList.add(e+'-theme')}),r){var b=document.createElement('div');b.setAttribute('class','arrow-'+l),b.setAttribute('x-arrow',''),g.appendChild(b)}if(s){g.setAttribute('data-animatefill','');var y=document.createElement('div');y.setAttribute('class','leave'),y.setAttribute('x-circle',''),g.appendChild(y)}a&&g.setAttribute('data-inertia',''),h&&g.setAttribute('data-interactive','');var E=document.createElement('div');if(E.setAttribute('class','tippy-tooltip-content'),f){var w;f instanceof Element?(E.appendChild(f),w='#'+f.id||'tippy-html-template'):(E.innerHTML=document.getElementById(f.replace('#','')).innerHTML,w=f),u.classList.add('html-template'),h&&u.setAttribute('tabindex','-1'),g.setAttribute('data-template-id',w)}else E.innerHTML=t;return g.style[v(i)]=me(n),g.appendChild(E),u.appendChild(g),u}function ve(e,t,o,i){var n=[];return'manual'===e?n:(t.addEventListener(e,o.handleTrigger),n.push({event:e,handler:o.handleTrigger}),'mouseenter'===e&&(Pe.SUPPORTS_TOUCH&&i&&(t.addEventListener('touchstart',o.handleTrigger),n.push({event:'touchstart',handler:o.handleTrigger}),t.addEventListener('touchend',o.handleMouseleave),n.push({event:'touchend',handler:o.handleMouseleave})),t.addEventListener('mouseleave',o.handleMouseleave),n.push({event:'mouseleave',handler:o.handleMouseleave})),'focus'===e&&(t.addEventListener('blur',o.handleBlur),n.push({event:'blur',handler:o.handleBlur})),n)}function Ee(e,t,o){if(!t.getAttribute('x-placement'))return!0;var i=e.clientX,n=e.clientY,r=o.interactiveBorder,s=o.distance,a=t.getBoundingClientRect(),p=v(t.getAttribute('x-placement')),l=r+s,d={top:a.top-n>r,bottom:n-a.bottom>r,left:a.left-i>r,right:i-a.right>r};return'top'===p?d.top=a.top-n>l:'bottom'===p?d.bottom=n-a.bottom>l:'left'===p?d.left=a.left-i>l:'right'===p?d.right=i-a.right>l:void 0,d.top||d.bottom||d.left||d.right}function we(e,t,i){var n,r,s=this,a=i.position,p=i.delay,l=i.duration,d=i.interactive,c=i.interactiveBorder,f=i.distance,m=i.hideOnClick,h=i.trigger,u=i.touchHold,b=i.touchWait,y=function(){clearTimeout(n),clearTimeout(r)},v=function(){if(y(),!g(t)){var e=Array.isArray(p)?p[0]:p;p?n=setTimeout(function(){return s.show(t)},e):s.show(t)}},E=function(e){return s.callbacks.wait?s.callbacks.wait.call(t,v,e):v()},w=function(){y();var e=Array.isArray(p)?p[1]:p;p?r=setTimeout(function(){return s.hide(t)},e):s.hide(t)};return{handleTrigger:function(o){var i='mouseenter'===o.type&&Pe.SUPPORTS_TOUCH&&Pe.touch;if(!(i&&u)){var n='click'===o.type;n&&g(t)&&'persistent'!==m?w():E(o),i&&Pe.iOS()&&e.click&&e.click()}},handleMouseleave:function(n){if(!('mouseleave'===n.type&&Pe.SUPPORTS_TOUCH&&Pe.touch&&u)){if(d){var r=function n(r){var s=function(){document.body.removeEventListener('mouseleave',w),document.removeEventListener('mousemove',n),w()},a=o(r.target,De.TOOLTIPPED_EL),p=o(r.target,De.POPPER)===t,l=-1!==h.indexOf('click');return a&&a!==e?s():void(p||a===e||l||Ee(r,t,i)&&s())};return document.body.addEventListener('mouseleave',w),void document.addEventListener('mousemove',r)}w()}},handleBlur:function(e){!e.relatedTarget||Pe.touch||o(e.relatedTarget,De.POPPER)||w()}}}function Oe(e){return e.arrow&&(e.animateFill=!1),e.appendTo&&'function'==typeof e.appendTo&&(e.appendTo=e.appendTo()),e}function Le(e){var t=this;return e.reduce(function(e,o){var i=tt,n=Oe(t.settings.performance?t.settings:be(o,t.settings)),r=n.html,s=n.trigger,a=n.touchHold,p=o.getAttribute('title');if(!p&&!r)return e;o.setAttribute('data-tooltipped',''),o.setAttribute('aria-describedby','tippy-tooltip-'+i),d(o);var l=ye(i,p,n),c=we.call(t,o,l,n),f=[];return s.trim().split(' ').forEach(function(e){return f=f.concat(ve(e,o,c,a))}),e.push({id:i,el:o,popper:l,settings:n,listeners:f,tippyInstance:t}),tt++,e},[])}function Te(e,t){return new ot(e,t)}var xe=Math.min,Se=Math.floor,Ae=Math.max,ke=Math.round,Pe={};'undefined'!=typeof window&&(Pe.SUPPORTED='requestAnimationFrame'in window,Pe.SUPPORTS_TOUCH='ontouchstart'in window,Pe.touch=!1,Pe.dynamicInputDetection=!0,Pe.iOS=function(){return /iPhone|iPad|iPod/.test(navigator.userAgent)&&!window.MSStream});for(var Ce=[],De={POPPER:'.tippy-popper',TOOLTIP:'.tippy-tooltip',CONTENT:'.tippy-tooltip-content',CIRCLE:'[x-circle]',ARROW:'[x-arrow]',TOOLTIPPED_EL:'[data-tooltipped]',CONTROLLER:'[data-tippy-controller]'},Ie={html:!1,position:'top',animation:'shift',animateFill:!0,arrow:!1,arrowSize:'regular',delay:0,trigger:'mouseenter focus',duration:350,interactive:!1,interactiveBorder:2,theme:'dark',size:'regular',distance:10,offset:0,hideOnClick:!0,multiple:!1,followCursor:!1,inertia:!1,flipDuration:350,sticky:!1,stickyDuration:200,appendTo:function(){return document.body},zIndex:9999,touchHold:!1,performance:!1,dynamicTitle:!1,popperOptions:{}},He=Pe.SUPPORTED&&Object.keys(Ie),Re=Element.prototype,e=Re.matches||Re.matchesSelector||Re.webkitMatchesSelector||Re.mozMatchesSelector||Re.msMatchesSelector||function(e){for(var t=(this.document||this.ownerDocument).querySelectorAll(e),o=t.length;0<=--o&&t.item(o)!==this;);return-1<o},Ne=['native code','[object MutationObserverConstructor]'],Me=function(e){return Ne.some(function(t){return-1<(e||'').toString().indexOf(t)})},Be='undefined'!=typeof window,We=['Edge','Trident','Firefox'],Ue=0,_e=0;_e<We.length;_e+=1)if(Be&&0<=navigator.userAgent.indexOf(We[_e])){Ue=1;break}var i,Fe=Be&&Me(window.MutationObserver),qe=Fe?function(e){var t=!1,o=0,i=document.createElement('span'),n=new MutationObserver(function(){e(),t=!1});return n.observe(i,{attributes:!0}),function(){t||(t=!0,i.setAttribute('x-index',o),++o)}}:function(e){var t=!1;return function(){t||(t=!0,setTimeout(function(){t=!1,e()},Ue))}},ze=function(){return void 0==i&&(i=-1!==navigator.appVersion.indexOf('MSIE 10')),i},Ye=function(e,t){if(!(e instanceof t))throw new TypeError('Cannot call a class as a function')},je=function(){function e(e,t){for(var o,n=0;n<t.length;n++)o=t[n],o.enumerable=o.enumerable||!1,o.configurable=!0,'value'in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}return function(t,o,i){return o&&e(t.prototype,o),i&&e(t,i),t}}(),Ke=function(e,t,o){return t in e?Object.defineProperty(e,t,{value:o,enumerable:!0,configurable:!0,writable:!0}):e[t]=o,e},Ge=Object.assign||function(e){for(var t,o=1;o<arguments.length;o++)for(var i in t=arguments[o],t)Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e},Xe=['auto-start','auto','auto-end','top-start','top','top-end','right-start','right','right-end','bottom-end','bottom','bottom-start','left-end','left','left-start'],Ve=Xe.slice(3),Qe={FLIP:'flip',CLOCKWISE:'clockwise',COUNTERCLOCKWISE:'counterclockwise'},Je=function(){function e(t,o){var i=this,n=2<arguments.length&&void 0!==arguments[2]?arguments[2]:{};Ye(this,e),this.scheduleUpdate=function(){return requestAnimationFrame(i.update)},this.update=qe(this.update.bind(this)),this.options=Ge({},e.Defaults,n),this.state={isDestroyed:!1,isCreated:!1,scrollParents:[]},this.reference=t.jquery?t[0]:t,this.popper=o.jquery?o[0]:o,this.options.modifiers={},Object.keys(Ge({},e.Defaults.modifiers,n.modifiers)).forEach(function(t){i.options.modifiers[t]=Ge({},e.Defaults.modifiers[t]||{},n.modifiers?n.modifiers[t]:{})}),this.modifiers=Object.keys(this.options.modifiers).map(function(e){return Ge({name:e},i.options.modifiers[e])}).sort(function(e,t){return e.order-t.order}),this.modifiers.forEach(function(e){e.enabled&&O(e.onLoad)&&e.onLoad(i.reference,i.popper,i.options,e,i.state)}),this.update();var r=this.options.eventsEnabled;r&&this.enableEventListeners(),this.state.eventsEnabled=r}return je(e,[{key:'update',value:function(){return Q.call(this)}},{key:'destroy',value:function(){return $.call(this)}},{key:'enableEventListeners',value:function(){return oe.call(this)}},{key:'disableEventListeners',value:function(){return ne.call(this)}}]),e}();Je.Utils=('undefined'==typeof window?global:window).PopperUtils,Je.placements=Xe,Je.Defaults={placement:'bottom',eventsEnabled:!0,removeOnDestroy:!1,onCreate:function(){},onUpdate:function(){},modifiers:{shift:{order:100,enabled:!0,fn:function(e){var t=e.placement,o=t.split('-')[0],i=t.split('-')[1];if(i){var n=e.offsets,r=n.reference,s=n.popper,a=-1!==['bottom','top'].indexOf(o),p=a?'left':'top',l=a?'width':'height',d={start:Ke({},p,r[p]),end:Ke({},p,r[p]+r[l]-s[l])};e.offsets.popper=Ge({},s,d[i])}return e}},offset:{order:200,enabled:!0,fn:function(e,t){var o,i=t.offset,n=e.placement,r=e.offsets,s=r.popper,a=r.reference,p=n.split('-')[0];return o=re(+i)?[+i,0]:fe(i,s,a,p),'left'===p?(s.top+=o[0],s.left-=o[1]):'right'===p?(s.top+=o[0],s.left+=o[1]):'top'===p?(s.left+=o[0],s.top-=o[1]):'bottom'===p&&(s.left+=o[0],s.top+=o[1]),e.popper=s,e},offset:0},preventOverflow:{order:300,enabled:!0,fn:function(e,t){var o=t.boundariesElement||S(e.instance.popper);e.instance.reference===o&&(o=S(o));var i=_(e.instance.popper,e.instance.reference,t.padding,o);t.boundaries=i;var n=t.priority,r=e.offsets.popper,s={primary:function(e){var o=r[e];return r[e]<i[e]&&!t.escapeWithReference&&(o=Ae(r[e],i[e])),Ke({},e,o)},secondary:function(e){var o='right'===e?'left':'top',n=r[o];return r[e]>i[e]&&!t.escapeWithReference&&(n=xe(r[o],i[e]-('right'===e?r.width:r.height))),Ke({},o,n)}};return n.forEach(function(e){var t=-1===['left','top'].indexOf(e)?'secondary':'primary';r=Ge({},r,s[t](e))}),e.offsets.popper=r,e},priority:['left','right','top','bottom'],padding:5,boundariesElement:'scrollParent'},keepTogether:{order:400,enabled:!0,fn:function(e){var t=e.offsets,o=t.popper,i=t.reference,n=e.placement.split('-')[0],r=Se,s=-1!==['top','bottom'].indexOf(n),a=s?'right':'bottom',p=s?'left':'top',l=s?'width':'height';return o[a]<r(i[p])&&(e.offsets.popper[p]=r(i[p])-o[l]),o[p]>r(i[a])&&(e.offsets.popper[p]=r(i[a])),e}},arrow:{order:500,enabled:!0,fn:function(e,t){if(!pe(e.instance.modifiers,'arrow','keepTogether'))return e;var o=t.element;if('string'==typeof o){if(o=e.instance.popper.querySelector(o),!o)return e;}else if(!e.instance.popper.contains(o))return console.warn('WARNING: `arrow.element` must be child of its popper element!'),e;var i=e.placement.split('-')[0],n=e.offsets,r=n.popper,s=n.reference,a=-1!==['left','right'].indexOf(i),p=a?'height':'width',l=a?'Top':'Left',d=l.toLowerCase(),c=a?'left':'top',f=a?'bottom':'right',m=Y(o)[p];s[f]-m<r[d]&&(e.offsets.popper[d]-=r[d]-(s[f]-m)),s[d]+m>r[f]&&(e.offsets.popper[d]+=s[d]+m-r[f]);var h=s[d]+s[p]/2-m/2,u=L(e.instance.popper,'margin'+l).replace('px',''),g=h-N(e.offsets.popper)[d]-u;return g=Ae(xe(r[p]-m,g),0),e.arrowElement=o,e.offsets.arrow={},e.offsets.arrow[d]=ke(g),e.offsets.arrow[c]='',e},element:'[x-arrow]'},flip:{order:600,enabled:!0,fn:function(e,t){if(J(e.instance.modifiers,'inner'))return e;if(e.flipped&&e.placement===e.originalPlacement)return e;var o=_(e.instance.popper,e.instance.reference,t.padding,t.boundariesElement),i=e.placement.split('-')[0],n=j(i),r=e.placement.split('-')[1]||'',s=[];switch(t.behavior){case Qe.FLIP:s=[i,n];break;case Qe.CLOCKWISE:s=de(i);break;case Qe.COUNTERCLOCKWISE:s=de(i,!0);break;default:s=t.behavior;}return s.forEach(function(a,p){if(i!==a||s.length===p+1)return e;i=e.placement.split('-')[0],n=j(i);var l=e.offsets.popper,d=e.offsets.reference,c=Se,f='left'===i&&c(l.right)>c(d.left)||'right'===i&&c(l.left)<c(d.right)||'top'===i&&c(l.bottom)>c(d.top)||'bottom'===i&&c(l.top)<c(d.bottom),m=c(l.left)<c(o.left),h=c(l.right)>c(o.right),u=c(l.top)<c(o.top),g=c(l.bottom)>c(o.bottom),b='left'===i&&m||'right'===i&&h||'top'===i&&u||'bottom'===i&&g,y=-1!==['top','bottom'].indexOf(i),v=!!t.flipVariations&&(y&&'start'===r&&m||y&&'end'===r&&h||!y&&'start'===r&&u||!y&&'end'===r&&g);(f||b||v)&&(e.flipped=!0,(f||b)&&(i=s[p+1]),v&&(r=le(r)),e.placement=i+(r?'-'+r:''),e.offsets.popper=Ge({},e.offsets.popper,K(e.instance.popper,e.offsets.reference,e.placement)),e=V(e.instance.modifiers,e,'flip'))}),e},behavior:'flip',padding:5,boundariesElement:'viewport'},inner:{order:700,enabled:!1,fn:function(e){var t=e.placement,o=t.split('-')[0],i=e.offsets,n=i.popper,r=i.reference,s=-1!==['left','right'].indexOf(o),a=-1===['top','left'].indexOf(o);return n[s?'left':'top']=r[o]-(a?n[s?'width':'height']:0),e.placement=j(t),e.offsets.popper=N(n),e}},hide:{order:800,enabled:!0,fn:function(e){if(!pe(e.instance.modifiers,'hide','preventOverflow'))return e;var t=e.offsets.reference,o=G(e.instance.modifiers,function(e){return'preventOverflow'===e.name}).boundaries;if(t.bottom<o.top||t.left>o.right||t.top>o.bottom||t.right<o.left){if(!0===e.hide)return e;e.hide=!0,e.attributes['x-out-of-boundaries']=''}else{if(!1===e.hide)return e;e.hide=!1,e.attributes['x-out-of-boundaries']=!1}return e}},computeStyle:{order:850,enabled:!0,fn:function(e,t){var o=t.x,i=t.y,n=e.offsets.popper,r=G(e.instance.modifiers,function(e){return'applyStyle'===e.name}).gpuAcceleration;void 0!==r&&console.warn('WARNING: `gpuAcceleration` option moved to `computeStyle` modifier and will not be supported in future versions of Popper.js!');var s,a,p=void 0===r?t.gpuAcceleration:r,l=S(e.instance.popper),d=M(l),c={position:n.position},f={left:Se(n.left),top:Se(n.top),bottom:Se(n.bottom),right:Se(n.right)},m='bottom'===o?'top':'bottom',h='right'===i?'left':'right',u=Z('transform');if(a='bottom'==m?-d.height+f.bottom:f.top,s='right'==h?-d.width+f.right:f.left,p&&u)c[u]='translate3d('+s+'px, '+a+'px, 0)',c[m]=0,c[h]=0,c.willChange='transform';else{var g='bottom'==m?-1:1,b='right'==h?-1:1;c[m]=a*g,c[h]=s*b,c.willChange=m+', '+h}var y={"x-placement":e.placement};return e.attributes=Ge({},y,e.attributes),e.styles=Ge({},c,e.styles),e.arrowStyles=Ge({},e.offsets.arrow,e.arrowStyles),e},gpuAcceleration:!0,x:'bottom',y:'right'},applyStyle:{order:900,enabled:!0,fn:function(e){return se(e.instance.popper,e.styles),ae(e.instance.popper,e.attributes),e.arrowElement&&Object.keys(e.arrowStyles).length&&se(e.arrowElement,e.arrowStyles),e},onLoad:function(e,t,o,i,n){var r=z(n,t,e),s=q(o.placement,r,t,e,o.modifiers.flip.boundariesElement,o.modifiers.flip.padding);return t.setAttribute('x-placement',s),se(t,{position:'absolute'}),o},gpuAcceleration:void 0}}};var Ze=function(e,t){if(!(e instanceof t))throw new TypeError('Cannot call a class as a function')},$e=function(){function e(e,t){for(var o,n=0;n<t.length;n++)o=t[n],o.enumerable=o.enumerable||!1,o.configurable=!0,'value'in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}return function(t,o,i){return o&&e(t.prototype,o),i&&e(t,i),t}}(),et=Object.assign||function(e){for(var t,o=1;o<arguments.length;o++)for(var i in t=arguments[o],t)Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e},tt=1,ot=function(){function e(t){var o=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{};Ze(this,e),Pe.SUPPORTED&&(s(),this.state={destroyed:!1},this.selector=t,this.settings=et({},Ie,o),(o.show||o.shown||o.hide||o.hidden)&&console.warn('Callbacks without the `on` prefix are deprecated (with the exception of `wait`). Use onShow, onShown, onHide, and onHidden instead.'),this.callbacks={wait:o.wait,show:o.onShow||o.show||b,shown:o.onShown||o.shown||b,hide:o.onHide||o.hide||b,hidden:o.onHidden||o.hidden||b},this.store=Le.call(this,E(t)),Ce.push.apply(Ce,this.store))}return $e(e,[{key:'getPopperElement',value:function(e){try{return n(this.store,function(t){return t.el===e}).popper}catch(t){console.error('[getPopperElement]: Element passed as the argument does not exist in the instance')}}},{key:'getReferenceElement',value:function(e){try{return n(this.store,function(t){return t.popper===e}).el}catch(t){console.error('[getReferenceElement]: Popper passed as the argument does not exist in the instance')}}},{key:'getReferenceData',value:function(e){return n(this.store,function(t){return t.el===e||t.popper===e})}},{key:'show',value:function(e,t){var o=this;if(!this.state.destroyed){var i=n(this.store,function(t){return t.popper===e}),r=h(e),s=r.tooltip,p=r.circle,l=r.content;if(!document.body.contains(i.el))return void this.destroy(e);this.callbacks.show.call(e);var c=i.el,b=i.settings,y=b.appendTo,v=b.sticky,E=b.interactive,O=b.followCursor,L=b.flipDuration,T=b.duration,x=b.dynamicTitle;if(x){var S=c.getAttribute('title');S&&(l.innerHTML=S,d(c))}var A=void 0===t?Array.isArray(T)?T[0]:T:t;u([e,s,p],0),ue(i),e.style.visibility='visible',e.setAttribute('aria-hidden','false'),a(function(){g(e)&&((!O||Pe.touch)&&(i.popperInstance.update(),u([e],L)),u([s,p],A),p&&(l.style.opacity=1),E&&c.classList.add('active'),v&&ge(i),f(s,p),m([s,p],function(e){e.contains('tippy-notransition')&&e.remove('tippy-notransition'),e.remove('leave'),e.add('enter')}),w(i,A,function(){!g(e)||i._onShownFired||(E&&e.focus(),s.classList.add('tippy-notransition'),i._onShownFired=!0,o.callbacks.shown.call(e))}))})}}},{key:'hide',value:function(e,t){var o=this;if(!this.state.destroyed){this.callbacks.hide.call(e);var i=n(this.store,function(t){return t.popper===e}),r=h(e),s=r.tooltip,a=r.circle,p=r.content,l=i.el,d=i.settings,f=d.appendTo,b=d.sticky,v=d.interactive,E=d.followCursor,O=d.html,L=d.trigger,T=d.duration,x=void 0===t?Array.isArray(T)?T[1]:T:t;i._onShownFired=!1,v&&l.classList.remove('active'),e.style.visibility='hidden',e.setAttribute('aria-hidden','true'),u([s,a,a?p:null],x),a&&(p.style.opacity=0),m([s,a],function(e){e.contains('tippy-tooltip')&&e.remove('tippy-notransition'),e.remove('enter'),e.add('leave')}),O&&-1!==L.indexOf('click')&&c(l)&&l.focus(),w(i,x,function(){g(e)||!f.contains(e)||'1'===getComputedStyle(s).opacity||(l.removeEventListener('mousemove',y),i.popperInstance.disableEventListeners(),f.removeChild(e),o.callbacks.hidden.call(e))})}}},{key:'update',value:function(e){if(!this.state.destroyed){var t=n(this.store,function(t){return t.popper===e}),o=h(e),i=o.content,r=t.el,s=t.settings.html;return s instanceof Element?void console.warn('Aborted: update() should not be used if `html` is a DOM element'):void(i.innerHTML=s?document.getElementById(s.replace('#','')).innerHTML:r.getAttribute('title')||r.getAttribute('data-original-title'),!s&&d(r))}}},{key:'destroy',value:function(e,t){var o=this;if(!this.state.destroyed){var i=n(this.store,function(t){return t.popper===e}),r=i.el,s=i.popperInstance,a=i.listeners,p=i._mutationObserver;g(e)&&this.hide(e,0),a.forEach(function(e){return r.removeEventListener(e.event,e.handler)}),r.setAttribute('title',r.getAttribute('data-original-title')),r.removeAttribute('data-original-title'),r.removeAttribute('data-tooltipped'),r.removeAttribute('aria-describedby'),s&&s.destroy(),p&&p.disconnect(),Ce.splice(l(Ce,function(t){return t.popper===e}),1),(void 0===t||t)&&(this.store=Ce.filter(function(e){return e.tippyInstance===o}))}}},{key:'destroyAll',value:function(){var e=this;if(!this.state.destroyed){var t=this.store.length;this.store.forEach(function(o,i){var n=o.popper;e.destroy(n,i===t-1)}),this.store=null,this.state.destroyed=!0}}}]),e}();return Te.Browser=Pe,Te.Defaults=Ie,Te.disableDynamicInputDetection=function(){return Pe.dynamicInputDetection=!1},Te.enableDynamicInputDetection=function(){return Pe.dynamicInputDetection=!0},Te}); | ||
(function(e,t){'object'==typeof exports&&'undefined'!=typeof module?module.exports=t():'function'==typeof define&&define.amd?define(t):e.tippy=t()})(this,function(){'use strict';function t(e){Ce.forEach(function(t){var o=t.popper,i=t.tippyInstance,n=t.settings,r=n.appendTo,s=n.hideOnClick,a=n.trigger;if(r.contains(o)){var p=!0===s||-1!==a.indexOf('focus'),l=!e||o!==e.popper;p&&l&&i.hide(o)}})}function o(t,o){var i=Element.prototype.closest||function(t){for(var o=this;o;){if(e.call(o,t))return o;o=o.parentElement}};return i.call(t,o)}function n(e,t){return Array.prototype.find?e.find(t):e.filter(t)[0]}function r(){var i=function(){Pe.touch=!0,Pe.iOS()&&document.body.classList.add('tippy-touch'),Pe.dynamicInputDetection&&window.performance&&document.addEventListener('mousemove',r)},r=function(){var e;return function(){var t=performance.now();20>t-e&&(Pe.touch=!1,document.removeEventListener('mousemove',r),!Pe.iOS()&&document.body.classList.remove('tippy-touch')),e=t}}();document.addEventListener('click',function(e){if(!(e.target instanceof Element))return t();var i=o(e.target,De.TOOLTIPPED_EL),r=o(e.target,De.POPPER);if(r){var s=n(Ce,function(e){return e.popper===r}),a=s.settings.interactive;if(a)return}if(i){var p=n(Ce,function(e){return e.el===i}),l=p.settings,d=l.hideOnClick,c=l.multiple,f=l.trigger;if(!c&&Pe.touch||!c&&-1!==f.indexOf('click'))return t(p);if(!0!==d||-1!==f.indexOf('click'))return}o(e.target,De.CONTROLLER)||!document.querySelector(De.POPPER)||t()}),document.addEventListener('touchstart',i),window.addEventListener('blur',function(){var t=document,o=t.activeElement;o&&o.blur&&e.call(o,De.TOOLTIPPED_EL)&&o.blur()}),!Pe.SUPPORTS_TOUCH&&(0<navigator.maxTouchPoints||0<navigator.msMaxTouchPoints)&&document.addEventListener('pointerdown',i)}function s(){return!s.done&&(s.done=!0,r(),!0)}function a(e){window.requestAnimationFrame(function(){setTimeout(e,0)})}function p(e){for(var t=[!1,'webkit'],o=e.charAt(0).toUpperCase()+e.slice(1),n=0;n<t.length;n++){var i=t[n],r=i?''+i+o:e;if('undefined'!=typeof window.document.body.style[r])return r}return null}function l(e,t){return Array.prototype.findIndex?e.findIndex(t):e.indexOf(n(e,t))}function d(e){var t=e.getAttribute('title');t&&e.setAttribute('data-original-title',t),e.removeAttribute('title')}function c(e){var t=e.getBoundingClientRect();return 0<=t.top&&0<=t.left&&t.bottom<=(window.innerHeight||document.documentElement.clientHeight)&&t.right<=(window.innerWidth||document.documentElement.clientWidth)}function f(e,t){t?window.getComputedStyle(t)[p('transform')]:window.getComputedStyle(e).opacity}function m(e,t){e.forEach(function(e){e&&t(e.classList)})}function h(e){return{tooltip:e.querySelector(De.TOOLTIP),circle:e.querySelector(De.CIRCLE),content:e.querySelector(De.CONTENT)}}function u(t,o){t.forEach(function(t){if(t){var i=e.call(t,De.CONTENT),n=i?ke(o/1.3):o;t.style[p('transitionDuration')]=n+'ms'}})}function g(e){return'visible'===e.style.visibility}function b(){}function v(e){return e.replace(/-.+/,'')}function y(t){var e,o,i=this,r=n(Ce,function(e){return e.el===i}),s=r.popper,a=r.settings.offset,l=v(s.getAttribute('x-placement')),d=ke(s.offsetWidth/2),c=ke(s.offsetHeight/2),f=5,m=document.documentElement.offsetWidth||document.body.offsetWidth,h=t.pageX,u=t.pageY;'top'===l?(e=h-d+a,o=u-2.25*c):'left'===l?(e=h-2*d-10,o=u-c+a):'right'===l?(e=h+c,o=u-c+a):'bottom'===l?(e=h-d+a,o=u+c/1.5):void 0;('top'===l||'bottom'===l)&&(h+f+d+a>m&&(e=m-f-2*d),0>h-f-d+a&&(e=f)),s.style[p('transform')]='translate3d('+e+'px, '+o+'px, 0)'}function E(e){return e instanceof Element?[e]:Array.isArray(e)?e:'NodeList'===e.constructor.name?[].slice.call(e):[].slice.call(document.querySelectorAll(e))}function w(e,t,o){if(!t)return o();var i=h(e.popper),n=i.tooltip,r=!1,s=function(t){t.target!==n||r||(r=!0,o())};n.addEventListener('webkitTransitionEnd',s),n.addEventListener('transitionend',s),clearTimeout(e._transitionendTimeout),e._transitionendTimeout=setTimeout(function(){r||o()},t)}function O(e){return e&&'[object Function]'==={}.toString.call(e)}function L(e,t){if(1!==e.nodeType)return[];var o=window.getComputedStyle(e,null);return t?o[t]:o}function T(e){return'HTML'===e.nodeName?e:e.parentNode||e.host}function x(e){if(!e||-1!==['HTML','BODY','#document'].indexOf(e.nodeName))return window.document.body;var t=L(e),o=t.overflow,i=t.overflowX,n=t.overflowY;return /(auto|scroll)/.test(o+n+i)?e:x(T(e))}function S(e){var t=e&&e.offsetParent,o=t&&t.nodeName;return o&&'BODY'!==o&&'HTML'!==o?-1!==['TD','TABLE'].indexOf(t.nodeName)&&'static'===L(t,'position')?S(t):t:window.document.documentElement}function A(e){var t=e.nodeName;return'BODY'!==t&&('HTML'===t||S(e.firstElementChild)===e)}function k(e){return null===e.parentNode?e:k(e.parentNode)}function P(e,t){if(!e||!e.nodeType||!t||!t.nodeType)return window.document.documentElement;var o=e.compareDocumentPosition(t)&Node.DOCUMENT_POSITION_FOLLOWING,i=o?e:t,n=o?t:e,r=document.createRange();r.setStart(i,0),r.setEnd(n,0);var s=r.commonAncestorContainer;if(e!==s&&t!==s||i.contains(n))return A(s)?s:S(s);var a=k(e);return a.host?P(a.host,t):P(e,k(t).host)}function C(e){var t=1<arguments.length&&void 0!==arguments[1]?arguments[1]:'top',o='top'===t?'scrollTop':'scrollLeft',i=e.nodeName;if('BODY'===i||'HTML'===i){var n=window.document.documentElement,r=window.document.scrollingElement||n;return r[o]}return e[o]}function D(e,t){var o=2<arguments.length&&void 0!==arguments[2]&&arguments[2],i=C(t,'top'),n=C(t,'left'),r=o?-1:1;return e.top+=i*r,e.bottom+=i*r,e.left+=n*r,e.right+=n*r,e}function I(e,t){var o='x'===t?'Left':'Top',i='Left'==o?'Right':'Bottom';return+e['border'+o+'Width'].split('px')[0]+ +e['border'+i+'Width'].split('px')[0]}function H(e,t,o,i,n){return Ae(t['offset'+e],n?t['scroll'+e]:0,o['client'+e],o['offset'+e],n?o['scroll'+e]:0,Ye()?o['offset'+e]+i['margin'+('Height'===e?'Top':'Left')]+i['margin'+('Height'===e?'Bottom':'Right')]:0)}function R(){var e=0<arguments.length&&void 0!==arguments[0]?arguments[0]:!0,t=window.document.body,o=window.document.documentElement,i=Ye()&&window.getComputedStyle(o);return{height:H('Height',t,o,i,e),width:H('Width',t,o,i,e)}}function N(e){return Xe({},e,{right:e.left+e.width,bottom:e.top+e.height})}function M(e){var t={};if(Ye())try{t=e.getBoundingClientRect();var o=C(e,'top'),i=C(e,'left');t.top+=o,t.left+=i,t.bottom+=o,t.right+=i}catch(e){}else t=e.getBoundingClientRect();var n={left:t.left,top:t.top,width:t.right-t.left,height:t.bottom-t.top},r='HTML'===e.nodeName?R():{},s=r.width||e.clientWidth||n.right-n.left,a=r.height||e.clientHeight||n.bottom-n.top,p=e.offsetWidth-s,l=e.offsetHeight-a;if(p||l){var d=L(e);p-=I(d,'x'),l-=I(d,'y'),n.width-=p,n.height-=l}return N(n)}function B(e,t){var o=Ye(),i='HTML'===t.nodeName,n=M(e),r=M(t),s=x(e),a=L(t),p=+a.borderTopWidth.split('px')[0],l=+a.borderLeftWidth.split('px')[0],d=N({top:n.top-r.top-p,left:n.left-r.left-l,width:n.width,height:n.height});if(d.marginTop=0,d.marginLeft=0,!o&&i){var c=+a.marginTop.split('px')[0],f=+a.marginLeft.split('px')[0];d.top-=p-c,d.bottom-=p-c,d.left-=l-f,d.right-=l-f,d.marginTop=c,d.marginLeft=f}return(o?t.contains(s):t===s&&'BODY'!==s.nodeName)&&(d=D(d,t)),d}function W(e){var t=window.document.documentElement,o=B(e,t),i=Ae(t.clientWidth,window.innerWidth||0),n=Ae(t.clientHeight,window.innerHeight||0),r=C(t),s=C(t,'left'),a={top:r-o.top+o.marginTop,left:s-o.left+o.marginLeft,width:i,height:n};return N(a)}function U(e){var t=e.nodeName;return'BODY'===t||'HTML'===t?!1:'fixed'===L(e,'position')||U(T(e))}function _(e,t,o,i){var n={top:0,left:0},r=P(e,t);if('viewport'===i)n=W(r);else{var s;'scrollParent'===i?(s=x(T(e)),'BODY'===s.nodeName&&(s=window.document.documentElement)):'window'===i?s=window.document.documentElement:s=i;var a=B(s,r);if('HTML'===s.nodeName&&!U(r)){var p=R(!1),l=p.height,d=p.width;n.top+=a.top-a.marginTop,n.bottom=l+a.top,n.left+=a.left-a.marginLeft,n.right=d+a.left}else n=a}return n.left+=o,n.top+=o,n.right-=o,n.bottom-=o,n}function F(e){var t=e.width,o=e.height;return t*o}function q(e,t,o,i,n){var r=5<arguments.length&&void 0!==arguments[5]?arguments[5]:0;if(-1===e.indexOf('auto'))return e;var s=_(o,i,r,n),a={top:{width:s.width,height:t.top-s.top},right:{width:s.right-t.right,height:s.height},bottom:{width:s.width,height:s.bottom-t.bottom},left:{width:t.left-s.left,height:s.height}},p=Object.keys(a).map(function(e){return Xe({key:e},a[e],{area:F(a[e])})}).sort(function(e,t){return t.area-e.area}),l=p.filter(function(e){var t=e.width,i=e.height;return t>=o.clientWidth&&i>=o.clientHeight}),d=0<l.length?l[0].key:p[0].key,c=e.split('-')[1];return d+(c?'-'+c:'')}function z(e,t,o){var i=P(t,o);return B(o,i)}function Y(e){var t=window.getComputedStyle(e),o=parseFloat(t.marginTop)+parseFloat(t.marginBottom),i=parseFloat(t.marginLeft)+parseFloat(t.marginRight),n={width:e.offsetWidth+i,height:e.offsetHeight+o};return n}function j(e){var t={left:'right',right:'left',bottom:'top',top:'bottom'};return e.replace(/left|right|bottom|top/g,function(e){return t[e]})}function K(e,t,o){o=o.split('-')[0];var i=Y(e),n={width:i.width,height:i.height},r=-1!==['right','left'].indexOf(o),s=r?'top':'left',a=r?'left':'top',p=r?'height':'width',l=r?'width':'height';return n[s]=t[s]+t[p]/2-i[p]/2,n[a]=o===a?t[a]-i[l]:t[j(a)],n}function G(e,t){return Array.prototype.find?e.find(t):e.filter(t)[0]}function X(e,t,o){if(Array.prototype.findIndex)return e.findIndex(function(e){return e[t]===o});var i=G(e,function(e){return e[t]===o});return e.indexOf(i)}function V(e,t,o){var i=void 0===o?e:e.slice(0,X(e,'name',o));return i.forEach(function(e){e.function&&console.warn('`modifier.function` is deprecated, use `modifier.fn`!');var o=e.function||e.fn;e.enabled&&O(o)&&(t.offsets.popper=N(t.offsets.popper),t.offsets.reference=N(t.offsets.reference),t=o(t,e))}),t}function Q(){if(!this.state.isDestroyed){var e={instance:this,styles:{},arrowStyles:{},attributes:{},flipped:!1,offsets:{}};e.offsets.reference=z(this.state,this.popper,this.reference),e.placement=q(this.options.placement,e.offsets.reference,this.popper,this.reference,this.options.modifiers.flip.boundariesElement,this.options.modifiers.flip.padding),e.originalPlacement=e.placement,e.offsets.popper=K(this.popper,e.offsets.reference,e.placement),e.offsets.popper.position='absolute',e=V(this.modifiers,e),this.state.isCreated?this.options.onUpdate(e):(this.state.isCreated=!0,this.options.onCreate(e))}}function J(e,t){return e.some(function(e){var o=e.name,i=e.enabled;return i&&o===t})}function Z(e){for(var t=[!1,'ms','Webkit','Moz','O'],o=e.charAt(0).toUpperCase()+e.slice(1),n=0;n<t.length-1;n++){var i=t[n],r=i?''+i+o:e;if('undefined'!=typeof window.document.body.style[r])return r}return null}function $(){return this.state.isDestroyed=!0,J(this.modifiers,'applyStyle')&&(this.popper.removeAttribute('x-placement'),this.popper.style.left='',this.popper.style.position='',this.popper.style.top='',this.popper.style[Z('transform')]=''),this.disableEventListeners(),this.options.removeOnDestroy&&this.popper.parentNode.removeChild(this.popper),this}function ee(e,t,o,i){var n='BODY'===e.nodeName,r=n?window:e;r.addEventListener(t,o,{passive:!0}),n||ee(x(r.parentNode),t,o,i),i.push(r)}function te(e,t,o,i){o.updateBound=i,window.addEventListener('resize',o.updateBound,{passive:!0});var n=x(e);return ee(n,'scroll',o.updateBound,o.scrollParents),o.scrollElement=n,o.eventsEnabled=!0,o}function oe(){this.state.eventsEnabled||(this.state=te(this.reference,this.options,this.state,this.scheduleUpdate))}function ie(e,t){return window.removeEventListener('resize',t.updateBound),t.scrollParents.forEach(function(e){e.removeEventListener('scroll',t.updateBound)}),t.updateBound=null,t.scrollParents=[],t.scrollElement=null,t.eventsEnabled=!1,t}function ne(){this.state.eventsEnabled&&(window.cancelAnimationFrame(this.scheduleUpdate),this.state=ie(this.reference,this.state))}function re(e){return''!==e&&!isNaN(parseFloat(e))&&isFinite(e)}function se(e,t){Object.keys(t).forEach(function(o){var i='';-1!==['width','height','top','right','bottom','left'].indexOf(o)&&re(t[o])&&(i='px'),e.style[o]=t[o]+i})}function ae(e,t){Object.keys(t).forEach(function(o){var i=t[o];!1===i?e.removeAttribute(o):e.setAttribute(o,t[o])})}function pe(e,t,o){var i=G(e,function(e){var o=e.name;return o===t}),n=!!i&&e.some(function(e){return e.name===o&&e.enabled&&e.order<i.order});if(!n){var r='`'+t+'`';console.warn('`'+o+'`'+' modifier is required by '+r+' modifier in order to work, be sure to include it before '+r+'!')}return n}function le(e){return'end'===e?'start':'start'===e?'end':e}function de(e){var t=1<arguments.length&&void 0!==arguments[1]&&arguments[1],o=Qe.indexOf(e),i=Qe.slice(o+1).concat(Qe.slice(0,o));return t?i.reverse():i}function ce(e,t,o,i){var n=e.match(/((?:\-|\+)?\d*\.?\d*)(.*)/),r=+n[1],s=n[2];if(!r)return e;if(0===s.indexOf('%')){var a;switch(s){case'%p':a=o;break;case'%':case'%r':default:a=i;}var p=N(a);return p[t]/100*r}if('vh'===s||'vw'===s){var l;return l='vh'===s?Ae(document.documentElement.clientHeight,window.innerHeight||0):Ae(document.documentElement.clientWidth,window.innerWidth||0),l/100*r}return r}function fe(e,t,o,i){var n=[0,0],r=-1!==['right','left'].indexOf(i),s=e.split(/(\+|\-)/).map(function(e){return e.trim()}),a=s.indexOf(G(s,function(e){return-1!==e.search(/,|\s/)}));s[a]&&-1===s[a].indexOf(',')&&console.warn('Offsets separated by white space(s) are deprecated, use a comma (,) instead.');var p=/\s*,\s*|\s+/,l=-1===a?[s]:[s.slice(0,a).concat([s[a].split(p)[0]]),[s[a].split(p)[1],s.slice(a+1)]];return l=l.map(function(e,i){var n=(1===i?!r:r)?'height':'width',s=!1;return e.reduce(function(e,t){return''===e[e.length-1]&&-1!==['+','-'].indexOf(t)?(e[e.length-1]=t,s=!0,e):s?(e[e.length-1]+=t,s=!1,e):e.concat(t)},[]).map(function(e){return ce(e,n,t,o)})}),l.forEach(function(e,t){e.forEach(function(o,i){re(o)&&(n[t]+=o*('-'===e[i-1]?-1:1))})}),n}function me(e){return-(e-Ie.distance)+'px'}function he(e){var t=e.el,o=e.popper,i=e.settings,n=i.position,r=i.popperOptions,s=i.offset,l=i.distance,d=i.flipDuration,c=h(o),f=c.tooltip,m=tt({placement:n},r||{},{modifiers:tt({},r?r.modifiers:{},{flip:tt({padding:l+5},r&&r.modifiers?r.modifiers.flip:{}),offset:tt({offset:s},r&&r.modifiers?r.modifiers.offset:{})}),onUpdate:function(){var e=f.style;e.top='',e.bottom='',e.left='',e.right='',e[v(o.getAttribute('x-placement'))]=me(l)}});if(window.MutationObserver){var u=o.style,g=new MutationObserver(function(){u[p('transitionDuration')]='0ms',e.popperInstance.update(),a(function(){u[p('transitionDuration')]=d+'ms'})});g.observe(o,{childList:!0,subtree:!0,characterData:!0}),e._mutationObservers.push(g)}return new Ze(t,o,m)}function ue(e){var t=e.el,o=e.popper,i=e.settings,n=i.appendTo,r=i.followCursor;n.contains(o)||(n.appendChild(o),e.popperInstance?(e.popperInstance.update(),(!r||Pe.touch)&&e.popperInstance.enableEventListeners()):e.popperInstance=he(e),r&&!Pe.touch&&(t.addEventListener('mousemove',y),e.popperInstance.disableEventListeners()))}function ge(e){var t=e.popper,o=e.popperInstance,i=e.settings.stickyDuration,n=function(){return t.style[p('transitionDuration')]=i+'ms'},r=function(){return t.style[p('transitionDuration')]=''};a(function e(){o&&o.scheduleUpdate(),n(),g(t)?window.requestAnimationFrame(e):r()})}function be(e,t){var o=He.reduce(function(o,i){var n=e.getAttribute('data-'+i.toLowerCase())||t[i];return'false'===n&&(n=!1),'true'===n&&(n=!0),isFinite(n)&&!isNaN(parseFloat(n))&&(n=parseFloat(n)),'string'==typeof n&&'['===n.trim().charAt(0)&&(n=JSON.parse(n)),o[i]=n,o},{});return tt({},t,o)}function ye(e,t,o){var i=o.position,n=o.distance,r=o.arrow,s=o.animateFill,a=o.inertia,p=o.animation,l=o.arrowSize,d=o.size,c=o.theme,f=o.html,m=o.zIndex,h=o.interactive,u=document.createElement('div');u.setAttribute('class','tippy-popper'),u.setAttribute('role','tooltip'),u.setAttribute('aria-hidden','true'),u.setAttribute('id','tippy-tooltip-'+e),u.style.zIndex=m;var g=document.createElement('div');if(g.setAttribute('class','tippy-tooltip tippy-tooltip--'+d+' leave'),g.setAttribute('data-animation',p),c.split(' ').forEach(function(e){g.classList.add(e+'-theme')}),r){var b=document.createElement('div');b.setAttribute('class','arrow-'+l),b.setAttribute('x-arrow',''),g.appendChild(b)}if(s){g.setAttribute('data-animatefill','');var y=document.createElement('div');y.setAttribute('class','leave'),y.setAttribute('x-circle',''),g.appendChild(y)}a&&g.setAttribute('data-inertia',''),h&&g.setAttribute('data-interactive','');var E=document.createElement('div');if(E.setAttribute('class','tippy-tooltip-content'),f){var w;f instanceof Element?(E.appendChild(f),w='#'+f.id||'tippy-html-template'):(E.innerHTML=document.getElementById(f.replace('#','')).innerHTML,w=f),u.classList.add('html-template'),h&&u.setAttribute('tabindex','-1'),g.setAttribute('data-template-id',w)}else E.innerHTML=t;return g.style[v(i)]=me(n),g.appendChild(E),u.appendChild(g),u}function ve(e,t,o,i){var n=[];return'manual'===e?n:(t.addEventListener(e,o.handleTrigger),n.push({event:e,handler:o.handleTrigger}),'mouseenter'===e&&(Pe.SUPPORTS_TOUCH&&i&&(t.addEventListener('touchstart',o.handleTrigger),n.push({event:'touchstart',handler:o.handleTrigger}),t.addEventListener('touchend',o.handleMouseleave),n.push({event:'touchend',handler:o.handleMouseleave})),t.addEventListener('mouseleave',o.handleMouseleave),n.push({event:'mouseleave',handler:o.handleMouseleave})),'focus'===e&&(t.addEventListener('blur',o.handleBlur),n.push({event:'blur',handler:o.handleBlur})),n)}function Ee(e,t,o){if(!t.getAttribute('x-placement'))return!0;var i=e.clientX,n=e.clientY,r=o.interactiveBorder,s=o.distance,a=t.getBoundingClientRect(),p=v(t.getAttribute('x-placement')),l=r+s,d={top:a.top-n>r,bottom:n-a.bottom>r,left:a.left-i>r,right:i-a.right>r};return'top'===p?d.top=a.top-n>l:'bottom'===p?d.bottom=n-a.bottom>l:'left'===p?d.left=a.left-i>l:'right'===p?d.right=i-a.right>l:void 0,d.top||d.bottom||d.left||d.right}function we(e,t,i){var n,r,s=this,a=i.position,p=i.delay,l=i.duration,d=i.interactive,c=i.interactiveBorder,f=i.distance,m=i.hideOnClick,h=i.trigger,u=i.touchHold,b=i.touchWait,y=function(){clearTimeout(n),clearTimeout(r)},v=function(){if(y(),!g(t)){var e=Array.isArray(p)?p[0]:p;p?n=setTimeout(function(){return s.show(t)},e):s.show(t)}},E=function(e){return s.callbacks.wait?s.callbacks.wait.call(t,v,e):v()},w=function(){y();var e=Array.isArray(p)?p[1]:p;p?r=setTimeout(function(){return s.hide(t)},e):s.hide(t)};return{handleTrigger:function(o){var i='mouseenter'===o.type&&Pe.SUPPORTS_TOUCH&&Pe.touch;if(!(i&&u)){var n='click'===o.type;n&&g(t)&&'persistent'!==m?w():E(o),i&&Pe.iOS()&&e.click&&e.click()}},handleMouseleave:function(n){if(!('mouseleave'===n.type&&Pe.SUPPORTS_TOUCH&&Pe.touch&&u)){if(d){var r=function n(r){var s=function(){document.body.removeEventListener('mouseleave',w),document.removeEventListener('mousemove',n),w()},a=o(r.target,De.TOOLTIPPED_EL),p=o(r.target,De.POPPER)===t,l=-1!==h.indexOf('click');return a&&a!==e?s():void(p||a===e||l||Ee(r,t,i)&&s())};return document.body.addEventListener('mouseleave',w),void document.addEventListener('mousemove',r)}w()}},handleBlur:function(e){!e.relatedTarget||Pe.touch||o(e.relatedTarget,De.POPPER)||w()}}}function Oe(e){return e.arrow&&(e.animateFill=!1),e.appendTo&&'function'==typeof e.appendTo&&(e.appendTo=e.appendTo()),e}function Le(e){var t=this;return e.reduce(function(e,o){var i=ot,n=tt({},Oe(t.settings.performance?t.settings:be(o,t.settings)));'function'==typeof n.html&&(n.html=n.html(o));var r=n.html,s=n.trigger,a=n.touchHold,p=n.dynamicTitle,l=o.getAttribute('title');if(!l&&!r)return e;o.setAttribute('data-tooltipped',''),o.setAttribute('aria-describedby','tippy-tooltip-'+i),d(o);var c=ye(i,l,n),f=we.call(t,o,c,n),m=[];s.trim().split(' ').forEach(function(e){return m=m.concat(ve(e,o,f,a))});var u;if(p&&window.MutationObserver){var g=h(c),b=g.content;u=new MutationObserver(function(){var e=o.getAttribute('title');e&&(b.innerHTML=e,d(o))}),u.observe(o,{attributes:!0})}return e.push({id:i,el:o,popper:c,settings:n,listeners:m,tippyInstance:t,_mutationObservers:[u]}),ot++,e},[])}function Te(e,t){return new it(e,t)}var xe=Math.min,Se=Math.floor,Ae=Math.max,ke=Math.round,Pe={};'undefined'!=typeof window&&(Pe.SUPPORTED='requestAnimationFrame'in window,Pe.SUPPORTS_TOUCH='ontouchstart'in window,Pe.touch=!1,Pe.dynamicInputDetection=!0,Pe.iOS=function(){return /iPhone|iPad|iPod/.test(navigator.userAgent)&&!window.MSStream});var Ce=[],De={POPPER:'.tippy-popper',TOOLTIP:'.tippy-tooltip',CONTENT:'.tippy-tooltip-content',CIRCLE:'[x-circle]',ARROW:'[x-arrow]',TOOLTIPPED_EL:'[data-tooltipped]',CONTROLLER:'[data-tippy-controller]'},Ie={html:!1,position:'top',animation:'shift',animateFill:!0,arrow:!1,arrowSize:'regular',delay:0,trigger:'mouseenter focus',duration:350,interactive:!1,interactiveBorder:2,theme:'dark',size:'regular',distance:10,offset:0,hideOnClick:!0,multiple:!1,followCursor:!1,inertia:!1,flipDuration:350,sticky:!1,stickyDuration:200,appendTo:function(){return document.body},zIndex:9999,touchHold:!1,performance:!1,dynamicTitle:!1,popperOptions:{}},He=Pe.SUPPORTED&&Object.keys(Ie),Re={};if('undefined'!=typeof Element){var Ne=Element.prototype;Re=Ne.matches||Ne.matchesSelector||Ne.webkitMatchesSelector||Ne.mozMatchesSelector||Ne.msMatchesSelector||function(e){for(var t=(this.document||this.ownerDocument).querySelectorAll(e),o=t.length;0<=--o&&t.item(o)!==this;);return-1<o}}for(var e=Re,Me=['native code','[object MutationObserverConstructor]'],Be=function(e){return Me.some(function(t){return-1<(e||'').toString().indexOf(t)})},We='undefined'!=typeof window,Ue=['Edge','Trident','Firefox'],_e=0,Fe=0;Fe<Ue.length;Fe+=1)if(We&&0<=navigator.userAgent.indexOf(Ue[Fe])){_e=1;break}var i,qe=We&&Be(window.MutationObserver),ze=qe?function(e){var t=!1,o=0,i=document.createElement('span'),n=new MutationObserver(function(){e(),t=!1});return n.observe(i,{attributes:!0}),function(){t||(t=!0,i.setAttribute('x-index',o),++o)}}:function(e){var t=!1;return function(){t||(t=!0,setTimeout(function(){t=!1,e()},_e))}},Ye=function(){return void 0==i&&(i=-1!==navigator.appVersion.indexOf('MSIE 10')),i},je=function(e,t){if(!(e instanceof t))throw new TypeError('Cannot call a class as a function')},Ke=function(){function e(e,t){for(var o,n=0;n<t.length;n++)o=t[n],o.enumerable=o.enumerable||!1,o.configurable=!0,'value'in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}return function(t,o,i){return o&&e(t.prototype,o),i&&e(t,i),t}}(),Ge=function(e,t,o){return t in e?Object.defineProperty(e,t,{value:o,enumerable:!0,configurable:!0,writable:!0}):e[t]=o,e},Xe=Object.assign||function(e){for(var t,o=1;o<arguments.length;o++)for(var i in t=arguments[o],t)Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e},Ve=['auto-start','auto','auto-end','top-start','top','top-end','right-start','right','right-end','bottom-end','bottom','bottom-start','left-end','left','left-start'],Qe=Ve.slice(3),Je={FLIP:'flip',CLOCKWISE:'clockwise',COUNTERCLOCKWISE:'counterclockwise'},Ze=function(){function e(t,o){var i=this,n=2<arguments.length&&void 0!==arguments[2]?arguments[2]:{};je(this,e),this.scheduleUpdate=function(){return requestAnimationFrame(i.update)},this.update=ze(this.update.bind(this)),this.options=Xe({},e.Defaults,n),this.state={isDestroyed:!1,isCreated:!1,scrollParents:[]},this.reference=t.jquery?t[0]:t,this.popper=o.jquery?o[0]:o,this.options.modifiers={},Object.keys(Xe({},e.Defaults.modifiers,n.modifiers)).forEach(function(t){i.options.modifiers[t]=Xe({},e.Defaults.modifiers[t]||{},n.modifiers?n.modifiers[t]:{})}),this.modifiers=Object.keys(this.options.modifiers).map(function(e){return Xe({name:e},i.options.modifiers[e])}).sort(function(e,t){return e.order-t.order}),this.modifiers.forEach(function(e){e.enabled&&O(e.onLoad)&&e.onLoad(i.reference,i.popper,i.options,e,i.state)}),this.update();var r=this.options.eventsEnabled;r&&this.enableEventListeners(),this.state.eventsEnabled=r}return Ke(e,[{key:'update',value:function(){return Q.call(this)}},{key:'destroy',value:function(){return $.call(this)}},{key:'enableEventListeners',value:function(){return oe.call(this)}},{key:'disableEventListeners',value:function(){return ne.call(this)}}]),e}();Ze.Utils=('undefined'==typeof window?global:window).PopperUtils,Ze.placements=Ve,Ze.Defaults={placement:'bottom',eventsEnabled:!0,removeOnDestroy:!1,onCreate:function(){},onUpdate:function(){},modifiers:{shift:{order:100,enabled:!0,fn:function(e){var t=e.placement,o=t.split('-')[0],i=t.split('-')[1];if(i){var n=e.offsets,r=n.reference,s=n.popper,a=-1!==['bottom','top'].indexOf(o),p=a?'left':'top',l=a?'width':'height',d={start:Ge({},p,r[p]),end:Ge({},p,r[p]+r[l]-s[l])};e.offsets.popper=Xe({},s,d[i])}return e}},offset:{order:200,enabled:!0,fn:function(e,t){var o,i=t.offset,n=e.placement,r=e.offsets,s=r.popper,a=r.reference,p=n.split('-')[0];return o=re(+i)?[+i,0]:fe(i,s,a,p),'left'===p?(s.top+=o[0],s.left-=o[1]):'right'===p?(s.top+=o[0],s.left+=o[1]):'top'===p?(s.left+=o[0],s.top-=o[1]):'bottom'===p&&(s.left+=o[0],s.top+=o[1]),e.popper=s,e},offset:0},preventOverflow:{order:300,enabled:!0,fn:function(e,t){var o=t.boundariesElement||S(e.instance.popper);e.instance.reference===o&&(o=S(o));var i=_(e.instance.popper,e.instance.reference,t.padding,o);t.boundaries=i;var n=t.priority,r=e.offsets.popper,s={primary:function(e){var o=r[e];return r[e]<i[e]&&!t.escapeWithReference&&(o=Ae(r[e],i[e])),Ge({},e,o)},secondary:function(e){var o='right'===e?'left':'top',n=r[o];return r[e]>i[e]&&!t.escapeWithReference&&(n=xe(r[o],i[e]-('right'===e?r.width:r.height))),Ge({},o,n)}};return n.forEach(function(e){var t=-1===['left','top'].indexOf(e)?'secondary':'primary';r=Xe({},r,s[t](e))}),e.offsets.popper=r,e},priority:['left','right','top','bottom'],padding:5,boundariesElement:'scrollParent'},keepTogether:{order:400,enabled:!0,fn:function(e){var t=e.offsets,o=t.popper,i=t.reference,n=e.placement.split('-')[0],r=Se,s=-1!==['top','bottom'].indexOf(n),a=s?'right':'bottom',p=s?'left':'top',l=s?'width':'height';return o[a]<r(i[p])&&(e.offsets.popper[p]=r(i[p])-o[l]),o[p]>r(i[a])&&(e.offsets.popper[p]=r(i[a])),e}},arrow:{order:500,enabled:!0,fn:function(e,t){if(!pe(e.instance.modifiers,'arrow','keepTogether'))return e;var o=t.element;if('string'==typeof o){if(o=e.instance.popper.querySelector(o),!o)return e;}else if(!e.instance.popper.contains(o))return console.warn('WARNING: `arrow.element` must be child of its popper element!'),e;var i=e.placement.split('-')[0],n=e.offsets,r=n.popper,s=n.reference,a=-1!==['left','right'].indexOf(i),p=a?'height':'width',l=a?'Top':'Left',d=l.toLowerCase(),c=a?'left':'top',f=a?'bottom':'right',m=Y(o)[p];s[f]-m<r[d]&&(e.offsets.popper[d]-=r[d]-(s[f]-m)),s[d]+m>r[f]&&(e.offsets.popper[d]+=s[d]+m-r[f]);var h=s[d]+s[p]/2-m/2,u=L(e.instance.popper,'margin'+l).replace('px',''),g=h-N(e.offsets.popper)[d]-u;return g=Ae(xe(r[p]-m,g),0),e.arrowElement=o,e.offsets.arrow={},e.offsets.arrow[d]=ke(g),e.offsets.arrow[c]='',e},element:'[x-arrow]'},flip:{order:600,enabled:!0,fn:function(e,t){if(J(e.instance.modifiers,'inner'))return e;if(e.flipped&&e.placement===e.originalPlacement)return e;var o=_(e.instance.popper,e.instance.reference,t.padding,t.boundariesElement),i=e.placement.split('-')[0],n=j(i),r=e.placement.split('-')[1]||'',s=[];switch(t.behavior){case Je.FLIP:s=[i,n];break;case Je.CLOCKWISE:s=de(i);break;case Je.COUNTERCLOCKWISE:s=de(i,!0);break;default:s=t.behavior;}return s.forEach(function(a,p){if(i!==a||s.length===p+1)return e;i=e.placement.split('-')[0],n=j(i);var l=e.offsets.popper,d=e.offsets.reference,c=Se,f='left'===i&&c(l.right)>c(d.left)||'right'===i&&c(l.left)<c(d.right)||'top'===i&&c(l.bottom)>c(d.top)||'bottom'===i&&c(l.top)<c(d.bottom),m=c(l.left)<c(o.left),h=c(l.right)>c(o.right),u=c(l.top)<c(o.top),g=c(l.bottom)>c(o.bottom),b='left'===i&&m||'right'===i&&h||'top'===i&&u||'bottom'===i&&g,y=-1!==['top','bottom'].indexOf(i),v=!!t.flipVariations&&(y&&'start'===r&&m||y&&'end'===r&&h||!y&&'start'===r&&u||!y&&'end'===r&&g);(f||b||v)&&(e.flipped=!0,(f||b)&&(i=s[p+1]),v&&(r=le(r)),e.placement=i+(r?'-'+r:''),e.offsets.popper=Xe({},e.offsets.popper,K(e.instance.popper,e.offsets.reference,e.placement)),e=V(e.instance.modifiers,e,'flip'))}),e},behavior:'flip',padding:5,boundariesElement:'viewport'},inner:{order:700,enabled:!1,fn:function(e){var t=e.placement,o=t.split('-')[0],i=e.offsets,n=i.popper,r=i.reference,s=-1!==['left','right'].indexOf(o),a=-1===['top','left'].indexOf(o);return n[s?'left':'top']=r[o]-(a?n[s?'width':'height']:0),e.placement=j(t),e.offsets.popper=N(n),e}},hide:{order:800,enabled:!0,fn:function(e){if(!pe(e.instance.modifiers,'hide','preventOverflow'))return e;var t=e.offsets.reference,o=G(e.instance.modifiers,function(e){return'preventOverflow'===e.name}).boundaries;if(t.bottom<o.top||t.left>o.right||t.top>o.bottom||t.right<o.left){if(!0===e.hide)return e;e.hide=!0,e.attributes['x-out-of-boundaries']=''}else{if(!1===e.hide)return e;e.hide=!1,e.attributes['x-out-of-boundaries']=!1}return e}},computeStyle:{order:850,enabled:!0,fn:function(e,t){var o=t.x,i=t.y,n=e.offsets.popper,r=G(e.instance.modifiers,function(e){return'applyStyle'===e.name}).gpuAcceleration;void 0!==r&&console.warn('WARNING: `gpuAcceleration` option moved to `computeStyle` modifier and will not be supported in future versions of Popper.js!');var s,a,p=void 0===r?t.gpuAcceleration:r,l=S(e.instance.popper),d=M(l),c={position:n.position},f={left:Se(n.left),top:Se(n.top),bottom:Se(n.bottom),right:Se(n.right)},m='bottom'===o?'top':'bottom',h='right'===i?'left':'right',u=Z('transform');if(a='bottom'==m?-d.height+f.bottom:f.top,s='right'==h?-d.width+f.right:f.left,p&&u)c[u]='translate3d('+s+'px, '+a+'px, 0)',c[m]=0,c[h]=0,c.willChange='transform';else{var g='bottom'==m?-1:1,b='right'==h?-1:1;c[m]=a*g,c[h]=s*b,c.willChange=m+', '+h}var y={"x-placement":e.placement};return e.attributes=Xe({},y,e.attributes),e.styles=Xe({},c,e.styles),e.arrowStyles=Xe({},e.offsets.arrow,e.arrowStyles),e},gpuAcceleration:!0,x:'bottom',y:'right'},applyStyle:{order:900,enabled:!0,fn:function(e){return se(e.instance.popper,e.styles),ae(e.instance.popper,e.attributes),e.arrowElement&&Object.keys(e.arrowStyles).length&&se(e.arrowElement,e.arrowStyles),e},onLoad:function(e,t,o,i,n){var r=z(n,t,e),s=q(o.placement,r,t,e,o.modifiers.flip.boundariesElement,o.modifiers.flip.padding);return t.setAttribute('x-placement',s),se(t,{position:'absolute'}),o},gpuAcceleration:void 0}}};var $e=function(e,t){if(!(e instanceof t))throw new TypeError('Cannot call a class as a function')},et=function(){function e(e,t){for(var o,n=0;n<t.length;n++)o=t[n],o.enumerable=o.enumerable||!1,o.configurable=!0,'value'in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}return function(t,o,i){return o&&e(t.prototype,o),i&&e(t,i),t}}(),tt=Object.assign||function(e){for(var t,o=1;o<arguments.length;o++)for(var i in t=arguments[o],t)Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e},ot=1,it=function(){function e(t){var o=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{};$e(this,e),Pe.SUPPORTED&&(s(),this.state={destroyed:!1},this.selector=t,this.settings=tt({},Ie,o),(o.show||o.shown||o.hide||o.hidden)&&console.warn('Callbacks without the `on` prefix are deprecated (with the exception of `wait`). Use onShow, onShown, onHide, and onHidden instead.'),this.callbacks={wait:o.wait,show:o.onShow||o.show||b,shown:o.onShown||o.shown||b,hide:o.onHide||o.hide||b,hidden:o.onHidden||o.hidden||b},this.store=Le.call(this,E(t)),Ce.push.apply(Ce,this.store))}return et(e,[{key:'getPopperElement',value:function(e){try{return n(this.store,function(t){return t.el===e}).popper}catch(t){console.error('[getPopperElement]: Element passed as the argument does not exist in the instance')}}},{key:'getReferenceElement',value:function(e){try{return n(this.store,function(t){return t.popper===e}).el}catch(t){console.error('[getReferenceElement]: Popper passed as the argument does not exist in the instance')}}},{key:'getReferenceData',value:function(e){return n(this.store,function(t){return t.el===e||t.popper===e})}},{key:'show',value:function(e,t){var o=this;if(!this.state.destroyed){var i=n(this.store,function(t){return t.popper===e}),r=h(e),s=r.tooltip,p=r.circle,l=r.content;if(!document.body.contains(i.el))return void this.destroy(e);this.callbacks.show.call(e);var d=i.el,c=i.settings,b=c.appendTo,y=c.sticky,v=c.interactive,E=c.followCursor,O=c.flipDuration,L=c.duration,T=void 0===t?Array.isArray(L)?L[0]:L:t;u([e,s,p],0),ue(i),e.style.visibility='visible',e.setAttribute('aria-hidden','false'),a(function(){g(e)&&((!E||Pe.touch)&&(i.popperInstance.update(),u([e],O)),u([s,p],T),p&&(l.style.opacity=1),v&&d.classList.add('active'),y&&ge(i),f(s,p),m([s,p],function(e){e.contains('tippy-notransition')&&e.remove('tippy-notransition'),e.remove('leave'),e.add('enter')}),w(i,T,function(){!g(e)||i._onShownFired||(v&&e.focus(),s.classList.add('tippy-notransition'),i._onShownFired=!0,o.callbacks.shown.call(e))}))})}}},{key:'hide',value:function(e,t){var o=this;if(!this.state.destroyed){this.callbacks.hide.call(e);var i=n(this.store,function(t){return t.popper===e}),r=h(e),s=r.tooltip,a=r.circle,p=r.content,l=i.el,d=i.settings,f=d.appendTo,b=d.sticky,v=d.interactive,E=d.followCursor,O=d.html,L=d.trigger,T=d.duration,x=void 0===t?Array.isArray(T)?T[1]:T:t;i._onShownFired=!1,v&&l.classList.remove('active'),e.style.visibility='hidden',e.setAttribute('aria-hidden','true'),u([s,a,a?p:null],x),a&&(p.style.opacity=0),m([s,a],function(e){e.contains('tippy-tooltip')&&e.remove('tippy-notransition'),e.remove('enter'),e.add('leave')}),O&&-1!==L.indexOf('click')&&c(l)&&l.focus(),w(i,x,function(){g(e)||!f.contains(e)||'1'===getComputedStyle(s).opacity||(l.removeEventListener('mousemove',y),i.popperInstance.disableEventListeners(),f.removeChild(e),o.callbacks.hidden.call(e))})}}},{key:'update',value:function(e){if(!this.state.destroyed){var t=n(this.store,function(t){return t.popper===e}),o=h(e),i=o.content,r=t.el,s=t.settings.html;return s instanceof Element?void console.warn('Aborted: update() should not be used if `html` is a DOM element'):void(i.innerHTML=s?document.getElementById(s.replace('#','')).innerHTML:r.getAttribute('title')||r.getAttribute('data-original-title'),!s&&d(r))}}},{key:'destroy',value:function(e,t){var o=this;if(!this.state.destroyed){var i=n(this.store,function(t){return t.popper===e}),r=i.el,s=i.popperInstance,a=i.listeners,p=i._mutationObservers;g(e)&&this.hide(e,0),a.forEach(function(e){return r.removeEventListener(e.event,e.handler)}),r.setAttribute('title',r.getAttribute('data-original-title')),r.removeAttribute('data-original-title'),r.removeAttribute('data-tooltipped'),r.removeAttribute('aria-describedby'),s&&s.destroy(),p.forEach(function(e){e&&e.disconnect()}),Ce.splice(l(Ce,function(t){return t.popper===e}),1),(void 0===t||t)&&(this.store=Ce.filter(function(e){return e.tippyInstance===o}))}}},{key:'destroyAll',value:function(){var e=this;if(!this.state.destroyed){var t=this.store.length;this.store.forEach(function(o,i){var n=o.popper;e.destroy(n,i===t-1)}),this.store=null,this.state.destroyed=!0}}}]),e}();return Te.Browser=Pe,Te.Defaults=Ie,Te.disableDynamicInputDetection=function(){return Pe.dynamicInputDetection=!1},Te.enableDynamicInputDetection=function(){return Pe.dynamicInputDetection=!0},Te}); |
@@ -1,1 +0,1 @@ | ||
(function(a,b){'object'==typeof exports&&'undefined'!=typeof module?module.exports=b(require('popper.js')):'function'==typeof define&&define.amd?define(['popper.js'],b):a.tippy=b(a.Popper)})(this,function(a){'use strict';function b(a){K.forEach(function(b){var c=b.popper,d=b.tippyInstance,e=b.settings,f=e.appendTo,g=e.hideOnClick,h=e.trigger;if(f.contains(c)){var i=!0===g||-1!==h.indexOf('focus'),j=!a||c!==a.popper;i&&j&&d.hide(c)}})}function c(a,b){var c=Element.prototype.closest||function(a){for(var b=this;b;){if(e.call(b,a))return b;b=b.parentElement}};return c.call(a,b)}function d(a,b){return Array.prototype.find?a.find(b):a.filter(b)[0]}function f(){var a=function(){J.touch=!0,J.iOS()&&document.body.classList.add('tippy-touch'),J.dynamicInputDetection&&window.performance&&document.addEventListener('mousemove',f)},f=function(){var a;return function(){var b=performance.now();20>b-a&&(J.touch=!1,document.removeEventListener('mousemove',f),!J.iOS()&&document.body.classList.remove('tippy-touch')),a=b}}();document.addEventListener('click',function(a){if(!(a.target instanceof Element))return b();var e=c(a.target,L.TOOLTIPPED_EL),f=c(a.target,L.POPPER);if(f){var g=d(K,function(a){return a.popper===f}),h=g.settings.interactive;if(h)return}if(e){var i=d(K,function(a){return a.el===e}),j=i.settings,k=j.hideOnClick,l=j.multiple,m=j.trigger;if(!l&&J.touch||!l&&-1!==m.indexOf('click'))return b(i);if(!0!==k||-1!==m.indexOf('click'))return}c(a.target,L.CONTROLLER)||!document.querySelector(L.POPPER)||b()}),document.addEventListener('touchstart',a),window.addEventListener('blur',function(){var a=document,b=a.activeElement;b&&b.blur&&e.call(b,L.TOOLTIPPED_EL)&&b.blur()}),!J.SUPPORTS_TOUCH&&(0<navigator.maxTouchPoints||0<navigator.msMaxTouchPoints)&&document.addEventListener('pointerdown',a)}function g(){return!g.done&&(g.done=!0,f(),!0)}function h(a){window.requestAnimationFrame(function(){setTimeout(a,0)})}function i(a){for(var b=[!1,'webkit'],c=a.charAt(0).toUpperCase()+a.slice(1),d=0;d<b.length;d++){var e=b[d],f=e?''+e+c:a;if('undefined'!=typeof window.document.body.style[f])return f}return null}function j(a,b){return Array.prototype.findIndex?a.findIndex(b):a.indexOf(d(a,b))}function k(a){var b=a.getAttribute('title');b&&a.setAttribute('data-original-title',b),a.removeAttribute('title')}function l(a){var b=a.getBoundingClientRect();return 0<=b.top&&0<=b.left&&b.bottom<=(window.innerHeight||document.documentElement.clientHeight)&&b.right<=(window.innerWidth||document.documentElement.clientWidth)}function m(a,b){b?window.getComputedStyle(b)[i('transform')]:window.getComputedStyle(a).opacity}function n(a,b){a.forEach(function(a){a&&b(a.classList)})}function o(a){return{tooltip:a.querySelector(L.TOOLTIP),circle:a.querySelector(L.CIRCLE),content:a.querySelector(L.CONTENT)}}function p(a,b){a.forEach(function(a){if(a){var c=e.call(a,L.CONTENT),d=c?I(b/1.3):b;a.style[i('transitionDuration')]=d+'ms'}})}function q(a){return'visible'===a.style.visibility}function r(){}function s(a){return a.replace(/-.+/,'')}function t(a){var b,c,e=this,f=d(K,function(a){return a.el===e}),g=f.popper,h=f.settings.offset,j=s(g.getAttribute('x-placement')),k=I(g.offsetWidth/2),l=I(g.offsetHeight/2),m=5,n=document.documentElement.offsetWidth||document.body.offsetWidth,o=a.pageX,p=a.pageY;'top'===j?(b=o-k+h,c=p-2.25*l):'left'===j?(b=o-2*k-10,c=p-l+h):'right'===j?(b=o+l,c=p-l+h):'bottom'===j?(b=o-k+h,c=p+l/1.5):void 0;('top'===j||'bottom'===j)&&(o+m+k+h>n&&(b=n-m-2*k),0>o-m-k+h&&(b=m)),g.style[i('transform')]='translate3d('+b+'px, '+c+'px, 0)'}function u(a){return a instanceof Element?[a]:Array.isArray(a)?a:[].slice.call(document.querySelectorAll(a))}function v(a,b,c){if(!b)return c();var d=o(a.popper),f=d.tooltip,g=!1,e=function(a){a.target!==f||g||(g=!0,c())};f.addEventListener('webkitTransitionEnd',e),f.addEventListener('transitionend',e),clearTimeout(a._transitionendTimeout),a._transitionendTimeout=setTimeout(function(){g||c()},b)}function w(a){return-(a-M.distance)+'px'}function x(b){var c=b.el,d=b.popper,e=b.settings,f=e.position,g=e.popperOptions,j=e.offset,k=e.distance,l=e.flipDuration,m=o(d),n=m.tooltip,p=R({placement:f},g||{},{modifiers:R({},g?g.modifiers:{},{flip:R({padding:k+5},g&&g.modifiers?g.modifiers.flip:{}),offset:R({offset:j},g&&g.modifiers?g.modifiers.offset:{})}),onUpdate:function(){var a=n.style;a.top='',a.bottom='',a.left='',a.right='',a[s(d.getAttribute('x-placement'))]=w(k)}});if(window.MutationObserver){var q=d.style,r=new MutationObserver(function(){q[i('transitionDuration')]='0ms',b.popperInstance.update(),h(function(){q[i('transitionDuration')]=l+'ms'})});r.observe(d,{childList:!0,subtree:!0,characterData:!0}),b._mutationObserver=r}return new a(c,d,p)}function y(a){var b=a.el,c=a.popper,d=a.settings,e=d.appendTo,f=d.followCursor;e.contains(c)||(e.appendChild(c),a.popperInstance?(a.popperInstance.update(),(!f||J.touch)&&a.popperInstance.enableEventListeners()):a.popperInstance=x(a),f&&!J.touch&&(b.addEventListener('mousemove',t),a.popperInstance.disableEventListeners()))}function z(a){var b=a.popper,c=a.popperInstance,d=a.settings.stickyDuration,e=function(){return b.style[i('transitionDuration')]=d+'ms'},f=function(){return b.style[i('transitionDuration')]=''};h(function a(){c&&c.scheduleUpdate(),e(),q(b)?window.requestAnimationFrame(a):f()})}function A(a,b){var c=N.reduce(function(c,d){var e=a.getAttribute('data-'+d.toLowerCase())||b[d];return'false'===e&&(e=!1),'true'===e&&(e=!0),isFinite(e)&&!isNaN(parseFloat(e))&&(e=parseFloat(e)),'string'==typeof e&&'['===e.trim().charAt(0)&&(e=JSON.parse(e)),c[d]=e,c},{});return R({},b,c)}function B(a,b,c){var d=c.position,e=c.distance,f=c.arrow,g=c.animateFill,h=c.inertia,i=c.animation,j=c.arrowSize,k=c.size,l=c.theme,m=c.html,n=c.zIndex,o=c.interactive,p=document.createElement('div');p.setAttribute('class','tippy-popper'),p.setAttribute('role','tooltip'),p.setAttribute('aria-hidden','true'),p.setAttribute('id','tippy-tooltip-'+a),p.style.zIndex=n;var q=document.createElement('div');if(q.setAttribute('class','tippy-tooltip tippy-tooltip--'+k+' leave'),q.setAttribute('data-animation',i),l.split(' ').forEach(function(a){q.classList.add(a+'-theme')}),f){var r=document.createElement('div');r.setAttribute('class','arrow-'+j),r.setAttribute('x-arrow',''),q.appendChild(r)}if(g){q.setAttribute('data-animatefill','');var t=document.createElement('div');t.setAttribute('class','leave'),t.setAttribute('x-circle',''),q.appendChild(t)}h&&q.setAttribute('data-inertia',''),o&&q.setAttribute('data-interactive','');var u=document.createElement('div');if(u.setAttribute('class','tippy-tooltip-content'),m){var v;m instanceof Element?(u.appendChild(m),v='#'+m.id||'tippy-html-template'):(u.innerHTML=document.getElementById(m.replace('#','')).innerHTML,v=m),p.classList.add('html-template'),o&&p.setAttribute('tabindex','-1'),q.setAttribute('data-template-id',v)}else u.innerHTML=b;return q.style[s(d)]=w(e),q.appendChild(u),p.appendChild(q),p}function C(a,b,c,d){var e=[];return'manual'===a?e:(b.addEventListener(a,c.handleTrigger),e.push({event:a,handler:c.handleTrigger}),'mouseenter'===a&&(J.SUPPORTS_TOUCH&&d&&(b.addEventListener('touchstart',c.handleTrigger),e.push({event:'touchstart',handler:c.handleTrigger}),b.addEventListener('touchend',c.handleMouseleave),e.push({event:'touchend',handler:c.handleMouseleave})),b.addEventListener('mouseleave',c.handleMouseleave),e.push({event:'mouseleave',handler:c.handleMouseleave})),'focus'===a&&(b.addEventListener('blur',c.handleBlur),e.push({event:'blur',handler:c.handleBlur})),e)}function D(a,b,c){if(!b.getAttribute('x-placement'))return!0;var d=a.clientX,e=a.clientY,f=c.interactiveBorder,g=c.distance,h=b.getBoundingClientRect(),i=s(b.getAttribute('x-placement')),j=f+g,k={top:h.top-e>f,bottom:e-h.bottom>f,left:h.left-d>f,right:d-h.right>f};return'top'===i?k.top=h.top-e>j:'bottom'===i?k.bottom=e-h.bottom>j:'left'===i?k.left=h.left-d>j:'right'===i?k.right=d-h.right>j:void 0,k.top||k.bottom||k.left||k.right}function E(a,b,d){var e,f,g=this,h=d.position,i=d.delay,j=d.duration,k=d.interactive,l=d.interactiveBorder,m=d.distance,n=d.hideOnClick,o=d.trigger,p=d.touchHold,r=d.touchWait,s=function(){clearTimeout(e),clearTimeout(f)},t=function(){if(s(),!q(b)){var a=Array.isArray(i)?i[0]:i;i?e=setTimeout(function(){return g.show(b)},a):g.show(b)}},u=function(a){return g.callbacks.wait?g.callbacks.wait.call(b,t,a):t()},v=function(){s();var a=Array.isArray(i)?i[1]:i;i?f=setTimeout(function(){return g.hide(b)},a):g.hide(b)};return{handleTrigger:function(c){var d='mouseenter'===c.type&&J.SUPPORTS_TOUCH&&J.touch;if(!(d&&p)){var e='click'===c.type;e&&q(b)&&'persistent'!==n?v():u(c),d&&J.iOS()&&a.click&&a.click()}},handleMouseleave:function(e){if(!('mouseleave'===e.type&&J.SUPPORTS_TOUCH&&J.touch&&p)){if(k){var f=function e(f){var g=function(){document.body.removeEventListener('mouseleave',v),document.removeEventListener('mousemove',e),v()},h=c(f.target,L.TOOLTIPPED_EL),i=c(f.target,L.POPPER)===b,j=-1!==o.indexOf('click');return h&&h!==a?g():void(i||h===a||j||D(f,b,d)&&g())};return document.body.addEventListener('mouseleave',v),void document.addEventListener('mousemove',f)}v()}},handleBlur:function(a){!a.relatedTarget||J.touch||c(a.relatedTarget,L.POPPER)||v()}}}function F(a){return a.arrow&&(a.animateFill=!1),a.appendTo&&'function'==typeof a.appendTo&&(a.appendTo=a.appendTo()),a}function G(a){var b=this;return a.reduce(function(c,a){var d=S,e=F(b.settings.performance?b.settings:A(a,b.settings)),f=e.html,g=e.trigger,h=e.touchHold,i=a.getAttribute('title');if(!i&&!f)return c;a.setAttribute('data-tooltipped',''),a.setAttribute('aria-describedby','tippy-tooltip-'+d),k(a);var j=B(d,i,e),l=E.call(b,a,j,e),m=[];return g.trim().split(' ').forEach(function(b){return m=m.concat(C(b,a,l,h))}),c.push({id:d,el:a,popper:j,settings:e,listeners:m,tippyInstance:b}),S++,c},[])}function H(a,b){return new T(a,b)}var I=Math.round;a=a&&a.hasOwnProperty('default')?a['default']:a;var J={};'undefined'!=typeof window&&(J.SUPPORTED='requestAnimationFrame'in window,J.SUPPORTS_TOUCH='ontouchstart'in window,J.touch=!1,J.dynamicInputDetection=!0,J.iOS=function(){return /iPhone|iPad|iPod/.test(navigator.userAgent)&&!window.MSStream});var K=[],L={POPPER:'.tippy-popper',TOOLTIP:'.tippy-tooltip',CONTENT:'.tippy-tooltip-content',CIRCLE:'[x-circle]',ARROW:'[x-arrow]',TOOLTIPPED_EL:'[data-tooltipped]',CONTROLLER:'[data-tippy-controller]'},M={html:!1,position:'top',animation:'shift',animateFill:!0,arrow:!1,arrowSize:'regular',delay:0,trigger:'mouseenter focus',duration:350,interactive:!1,interactiveBorder:2,theme:'dark',size:'regular',distance:10,offset:0,hideOnClick:!0,multiple:!1,followCursor:!1,inertia:!1,flipDuration:350,sticky:!1,stickyDuration:200,appendTo:function(){return document.body},zIndex:9999,touchHold:!1,performance:!1,dynamicTitle:!1,popperOptions:{}},N=J.SUPPORTED&&Object.keys(M),O=Element.prototype,e=O.matches||O.matchesSelector||O.webkitMatchesSelector||O.mozMatchesSelector||O.msMatchesSelector||function(a){for(var b=(this.document||this.ownerDocument).querySelectorAll(a),c=b.length;0<=--c&&b.item(c)!==this;);return-1<c},P=function(a,b){if(!(a instanceof b))throw new TypeError('Cannot call a class as a function')},Q=function(){function a(a,b){for(var c,d=0;d<b.length;d++)c=b[d],c.enumerable=c.enumerable||!1,c.configurable=!0,'value'in c&&(c.writable=!0),Object.defineProperty(a,c.key,c)}return function(b,c,d){return c&&a(b.prototype,c),d&&a(b,d),b}}(),R=Object.assign||function(a){for(var b,c=1;c<arguments.length;c++)for(var d in b=arguments[c],b)Object.prototype.hasOwnProperty.call(b,d)&&(a[d]=b[d]);return a},S=1,T=function(){function a(b){var c=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{};P(this,a),J.SUPPORTED&&(g(),this.state={destroyed:!1},this.selector=b,this.settings=R({},M,c),(c.show||c.shown||c.hide||c.hidden)&&console.warn('Callbacks without the `on` prefix are deprecated (with the exception of `wait`). Use onShow, onShown, onHide, and onHidden instead.'),this.callbacks={wait:c.wait,show:c.onShow||c.show||r,shown:c.onShown||c.shown||r,hide:c.onHide||c.hide||r,hidden:c.onHidden||c.hidden||r},this.store=G.call(this,u(b)),K.push.apply(K,this.store))}return Q(a,[{key:'getPopperElement',value:function(a){try{return d(this.store,function(b){return b.el===a}).popper}catch(a){console.error('[getPopperElement]: Element passed as the argument does not exist in the instance')}}},{key:'getReferenceElement',value:function(a){try{return d(this.store,function(b){return b.popper===a}).el}catch(a){console.error('[getReferenceElement]: Popper passed as the argument does not exist in the instance')}}},{key:'getReferenceData',value:function(a){return d(this.store,function(b){return b.el===a||b.popper===a})}},{key:'show',value:function(a,b){var c=this;if(!this.state.destroyed){var e=d(this.store,function(b){return b.popper===a}),f=o(a),g=f.tooltip,i=f.circle,j=f.content;if(!document.body.contains(e.el))return void this.destroy(a);this.callbacks.show.call(a);var l=e.el,r=e.settings,s=r.appendTo,t=r.sticky,u=r.interactive,w=r.followCursor,x=r.flipDuration,A=r.duration,B=r.dynamicTitle;if(B){var C=l.getAttribute('title');C&&(j.innerHTML=C,k(l))}var D=void 0===b?Array.isArray(A)?A[0]:A:b;p([a,g,i],0),y(e),a.style.visibility='visible',a.setAttribute('aria-hidden','false'),h(function(){q(a)&&((!w||J.touch)&&(e.popperInstance.update(),p([a],x)),p([g,i],D),i&&(j.style.opacity=1),u&&l.classList.add('active'),t&&z(e),m(g,i),n([g,i],function(a){a.contains('tippy-notransition')&&a.remove('tippy-notransition'),a.remove('leave'),a.add('enter')}),v(e,D,function(){!q(a)||e._onShownFired||(u&&a.focus(),g.classList.add('tippy-notransition'),e._onShownFired=!0,c.callbacks.shown.call(a))}))})}}},{key:'hide',value:function(a,b){var c=this;if(!this.state.destroyed){this.callbacks.hide.call(a);var e=d(this.store,function(b){return b.popper===a}),f=o(a),g=f.tooltip,h=f.circle,i=f.content,j=e.el,k=e.settings,m=k.appendTo,r=k.sticky,s=k.interactive,u=k.followCursor,w=k.html,x=k.trigger,y=k.duration,z=void 0===b?Array.isArray(y)?y[1]:y:b;e._onShownFired=!1,s&&j.classList.remove('active'),a.style.visibility='hidden',a.setAttribute('aria-hidden','true'),p([g,h,h?i:null],z),h&&(i.style.opacity=0),n([g,h],function(a){a.contains('tippy-tooltip')&&a.remove('tippy-notransition'),a.remove('enter'),a.add('leave')}),w&&-1!==x.indexOf('click')&&l(j)&&j.focus(),v(e,z,function(){q(a)||!m.contains(a)||'1'===getComputedStyle(g).opacity||(j.removeEventListener('mousemove',t),e.popperInstance.disableEventListeners(),m.removeChild(a),c.callbacks.hidden.call(a))})}}},{key:'update',value:function(a){if(!this.state.destroyed){var b=d(this.store,function(b){return b.popper===a}),c=o(a),e=c.content,f=b.el,g=b.settings.html;return g instanceof Element?void console.warn('Aborted: update() should not be used if `html` is a DOM element'):void(e.innerHTML=g?document.getElementById(g.replace('#','')).innerHTML:f.getAttribute('title')||f.getAttribute('data-original-title'),!g&&k(f))}}},{key:'destroy',value:function(a,b){var c=this;if(!this.state.destroyed){var e=d(this.store,function(b){return b.popper===a}),f=e.el,g=e.popperInstance,h=e.listeners,i=e._mutationObserver;q(a)&&this.hide(a,0),h.forEach(function(a){return f.removeEventListener(a.event,a.handler)}),f.setAttribute('title',f.getAttribute('data-original-title')),f.removeAttribute('data-original-title'),f.removeAttribute('data-tooltipped'),f.removeAttribute('aria-describedby'),g&&g.destroy(),i&&i.disconnect(),K.splice(j(K,function(b){return b.popper===a}),1),(void 0===b||b)&&(this.store=K.filter(function(a){return a.tippyInstance===c}))}}},{key:'destroyAll',value:function(){var a=this;if(!this.state.destroyed){var b=this.store.length;this.store.forEach(function(c,d){var e=c.popper;a.destroy(e,d===b-1)}),this.store=null,this.state.destroyed=!0}}}]),a}();return H.Browser=J,H.Defaults=M,H.disableDynamicInputDetection=function(){return J.dynamicInputDetection=!1},H.enableDynamicInputDetection=function(){return J.dynamicInputDetection=!0},H}); | ||
(function(a,b){'object'==typeof exports&&'undefined'!=typeof module?module.exports=b(require('popper.js')):'function'==typeof define&&define.amd?define(['popper.js'],b):a.tippy=b(a.Popper)})(this,function(a){'use strict';function b(a){K.forEach(function(b){var c=b.popper,d=b.tippyInstance,e=b.settings,f=e.appendTo,g=e.hideOnClick,h=e.trigger;if(f.contains(c)){var i=!0===g||-1!==h.indexOf('focus'),j=!a||c!==a.popper;i&&j&&d.hide(c)}})}function c(a,b){var c=Element.prototype.closest||function(a){for(var b=this;b;){if(e.call(b,a))return b;b=b.parentElement}};return c.call(a,b)}function d(a,b){return Array.prototype.find?a.find(b):a.filter(b)[0]}function f(){var a=function(){J.touch=!0,J.iOS()&&document.body.classList.add('tippy-touch'),J.dynamicInputDetection&&window.performance&&document.addEventListener('mousemove',f)},f=function(){var a;return function(){var b=performance.now();20>b-a&&(J.touch=!1,document.removeEventListener('mousemove',f),!J.iOS()&&document.body.classList.remove('tippy-touch')),a=b}}();document.addEventListener('click',function(a){if(!(a.target instanceof Element))return b();var e=c(a.target,L.TOOLTIPPED_EL),f=c(a.target,L.POPPER);if(f){var g=d(K,function(a){return a.popper===f}),h=g.settings.interactive;if(h)return}if(e){var i=d(K,function(a){return a.el===e}),j=i.settings,k=j.hideOnClick,l=j.multiple,m=j.trigger;if(!l&&J.touch||!l&&-1!==m.indexOf('click'))return b(i);if(!0!==k||-1!==m.indexOf('click'))return}c(a.target,L.CONTROLLER)||!document.querySelector(L.POPPER)||b()}),document.addEventListener('touchstart',a),window.addEventListener('blur',function(){var a=document,b=a.activeElement;b&&b.blur&&e.call(b,L.TOOLTIPPED_EL)&&b.blur()}),!J.SUPPORTS_TOUCH&&(0<navigator.maxTouchPoints||0<navigator.msMaxTouchPoints)&&document.addEventListener('pointerdown',a)}function g(){return!g.done&&(g.done=!0,f(),!0)}function h(a){window.requestAnimationFrame(function(){setTimeout(a,0)})}function i(a){for(var b=[!1,'webkit'],c=a.charAt(0).toUpperCase()+a.slice(1),d=0;d<b.length;d++){var e=b[d],f=e?''+e+c:a;if('undefined'!=typeof window.document.body.style[f])return f}return null}function j(a,b){return Array.prototype.findIndex?a.findIndex(b):a.indexOf(d(a,b))}function k(a){var b=a.getAttribute('title');b&&a.setAttribute('data-original-title',b),a.removeAttribute('title')}function l(a){var b=a.getBoundingClientRect();return 0<=b.top&&0<=b.left&&b.bottom<=(window.innerHeight||document.documentElement.clientHeight)&&b.right<=(window.innerWidth||document.documentElement.clientWidth)}function m(a,b){b?window.getComputedStyle(b)[i('transform')]:window.getComputedStyle(a).opacity}function n(a,b){a.forEach(function(a){a&&b(a.classList)})}function o(a){return{tooltip:a.querySelector(L.TOOLTIP),circle:a.querySelector(L.CIRCLE),content:a.querySelector(L.CONTENT)}}function p(a,b){a.forEach(function(a){if(a){var c=e.call(a,L.CONTENT),d=c?I(b/1.3):b;a.style[i('transitionDuration')]=d+'ms'}})}function q(a){return'visible'===a.style.visibility}function r(){}function s(a){return a.replace(/-.+/,'')}function t(a){var b,c,e=this,f=d(K,function(a){return a.el===e}),g=f.popper,h=f.settings.offset,j=s(g.getAttribute('x-placement')),k=I(g.offsetWidth/2),l=I(g.offsetHeight/2),m=5,n=document.documentElement.offsetWidth||document.body.offsetWidth,o=a.pageX,p=a.pageY;'top'===j?(b=o-k+h,c=p-2.25*l):'left'===j?(b=o-2*k-10,c=p-l+h):'right'===j?(b=o+l,c=p-l+h):'bottom'===j?(b=o-k+h,c=p+l/1.5):void 0;('top'===j||'bottom'===j)&&(o+m+k+h>n&&(b=n-m-2*k),0>o-m-k+h&&(b=m)),g.style[i('transform')]='translate3d('+b+'px, '+c+'px, 0)'}function u(a){return a instanceof Element?[a]:Array.isArray(a)?a:'NodeList'===a.constructor.name?[].slice.call(a):[].slice.call(document.querySelectorAll(a))}function v(a,b,c){if(!b)return c();var d=o(a.popper),f=d.tooltip,g=!1,e=function(a){a.target!==f||g||(g=!0,c())};f.addEventListener('webkitTransitionEnd',e),f.addEventListener('transitionend',e),clearTimeout(a._transitionendTimeout),a._transitionendTimeout=setTimeout(function(){g||c()},b)}function w(a){return-(a-M.distance)+'px'}function x(b){var c=b.el,d=b.popper,e=b.settings,f=e.position,g=e.popperOptions,j=e.offset,k=e.distance,l=e.flipDuration,m=o(d),n=m.tooltip,p=S({placement:f},g||{},{modifiers:S({},g?g.modifiers:{},{flip:S({padding:k+5},g&&g.modifiers?g.modifiers.flip:{}),offset:S({offset:j},g&&g.modifiers?g.modifiers.offset:{})}),onUpdate:function(){var a=n.style;a.top='',a.bottom='',a.left='',a.right='',a[s(d.getAttribute('x-placement'))]=w(k)}});if(window.MutationObserver){var q=d.style,r=new MutationObserver(function(){q[i('transitionDuration')]='0ms',b.popperInstance.update(),h(function(){q[i('transitionDuration')]=l+'ms'})});r.observe(d,{childList:!0,subtree:!0,characterData:!0}),b._mutationObservers.push(r)}return new a(c,d,p)}function y(a){var b=a.el,c=a.popper,d=a.settings,e=d.appendTo,f=d.followCursor;e.contains(c)||(e.appendChild(c),a.popperInstance?(a.popperInstance.update(),(!f||J.touch)&&a.popperInstance.enableEventListeners()):a.popperInstance=x(a),f&&!J.touch&&(b.addEventListener('mousemove',t),a.popperInstance.disableEventListeners()))}function z(a){var b=a.popper,c=a.popperInstance,d=a.settings.stickyDuration,e=function(){return b.style[i('transitionDuration')]=d+'ms'},f=function(){return b.style[i('transitionDuration')]=''};h(function a(){c&&c.scheduleUpdate(),e(),q(b)?window.requestAnimationFrame(a):f()})}function A(a,b){var c=N.reduce(function(c,d){var e=a.getAttribute('data-'+d.toLowerCase())||b[d];return'false'===e&&(e=!1),'true'===e&&(e=!0),isFinite(e)&&!isNaN(parseFloat(e))&&(e=parseFloat(e)),'string'==typeof e&&'['===e.trim().charAt(0)&&(e=JSON.parse(e)),c[d]=e,c},{});return S({},b,c)}function B(a,b,c){var d=c.position,e=c.distance,f=c.arrow,g=c.animateFill,h=c.inertia,i=c.animation,j=c.arrowSize,k=c.size,l=c.theme,m=c.html,n=c.zIndex,o=c.interactive,p=document.createElement('div');p.setAttribute('class','tippy-popper'),p.setAttribute('role','tooltip'),p.setAttribute('aria-hidden','true'),p.setAttribute('id','tippy-tooltip-'+a),p.style.zIndex=n;var q=document.createElement('div');if(q.setAttribute('class','tippy-tooltip tippy-tooltip--'+k+' leave'),q.setAttribute('data-animation',i),l.split(' ').forEach(function(a){q.classList.add(a+'-theme')}),f){var r=document.createElement('div');r.setAttribute('class','arrow-'+j),r.setAttribute('x-arrow',''),q.appendChild(r)}if(g){q.setAttribute('data-animatefill','');var t=document.createElement('div');t.setAttribute('class','leave'),t.setAttribute('x-circle',''),q.appendChild(t)}h&&q.setAttribute('data-inertia',''),o&&q.setAttribute('data-interactive','');var u=document.createElement('div');if(u.setAttribute('class','tippy-tooltip-content'),m){var v;m instanceof Element?(u.appendChild(m),v='#'+m.id||'tippy-html-template'):(u.innerHTML=document.getElementById(m.replace('#','')).innerHTML,v=m),p.classList.add('html-template'),o&&p.setAttribute('tabindex','-1'),q.setAttribute('data-template-id',v)}else u.innerHTML=b;return q.style[s(d)]=w(e),q.appendChild(u),p.appendChild(q),p}function C(a,b,c,d){var e=[];return'manual'===a?e:(b.addEventListener(a,c.handleTrigger),e.push({event:a,handler:c.handleTrigger}),'mouseenter'===a&&(J.SUPPORTS_TOUCH&&d&&(b.addEventListener('touchstart',c.handleTrigger),e.push({event:'touchstart',handler:c.handleTrigger}),b.addEventListener('touchend',c.handleMouseleave),e.push({event:'touchend',handler:c.handleMouseleave})),b.addEventListener('mouseleave',c.handleMouseleave),e.push({event:'mouseleave',handler:c.handleMouseleave})),'focus'===a&&(b.addEventListener('blur',c.handleBlur),e.push({event:'blur',handler:c.handleBlur})),e)}function D(a,b,c){if(!b.getAttribute('x-placement'))return!0;var d=a.clientX,e=a.clientY,f=c.interactiveBorder,g=c.distance,h=b.getBoundingClientRect(),i=s(b.getAttribute('x-placement')),j=f+g,k={top:h.top-e>f,bottom:e-h.bottom>f,left:h.left-d>f,right:d-h.right>f};return'top'===i?k.top=h.top-e>j:'bottom'===i?k.bottom=e-h.bottom>j:'left'===i?k.left=h.left-d>j:'right'===i?k.right=d-h.right>j:void 0,k.top||k.bottom||k.left||k.right}function E(a,b,d){var e,f,g=this,h=d.position,i=d.delay,j=d.duration,k=d.interactive,l=d.interactiveBorder,m=d.distance,n=d.hideOnClick,o=d.trigger,p=d.touchHold,r=d.touchWait,s=function(){clearTimeout(e),clearTimeout(f)},t=function(){if(s(),!q(b)){var a=Array.isArray(i)?i[0]:i;i?e=setTimeout(function(){return g.show(b)},a):g.show(b)}},u=function(a){return g.callbacks.wait?g.callbacks.wait.call(b,t,a):t()},v=function(){s();var a=Array.isArray(i)?i[1]:i;i?f=setTimeout(function(){return g.hide(b)},a):g.hide(b)};return{handleTrigger:function(c){var d='mouseenter'===c.type&&J.SUPPORTS_TOUCH&&J.touch;if(!(d&&p)){var e='click'===c.type;e&&q(b)&&'persistent'!==n?v():u(c),d&&J.iOS()&&a.click&&a.click()}},handleMouseleave:function(e){if(!('mouseleave'===e.type&&J.SUPPORTS_TOUCH&&J.touch&&p)){if(k){var f=function e(f){var g=function(){document.body.removeEventListener('mouseleave',v),document.removeEventListener('mousemove',e),v()},h=c(f.target,L.TOOLTIPPED_EL),i=c(f.target,L.POPPER)===b,j=-1!==o.indexOf('click');return h&&h!==a?g():void(i||h===a||j||D(f,b,d)&&g())};return document.body.addEventListener('mouseleave',v),void document.addEventListener('mousemove',f)}v()}},handleBlur:function(a){!a.relatedTarget||J.touch||c(a.relatedTarget,L.POPPER)||v()}}}function F(a){return a.arrow&&(a.animateFill=!1),a.appendTo&&'function'==typeof a.appendTo&&(a.appendTo=a.appendTo()),a}function G(a){var b=this;return a.reduce(function(a,c){var d=T,e=S({},F(b.settings.performance?b.settings:A(c,b.settings)));'function'==typeof e.html&&(e.html=e.html(c));var f=e.html,g=e.trigger,h=e.touchHold,i=e.dynamicTitle,j=c.getAttribute('title');if(!j&&!f)return a;c.setAttribute('data-tooltipped',''),c.setAttribute('aria-describedby','tippy-tooltip-'+d),k(c);var l=B(d,j,e),m=E.call(b,c,l,e),n=[];g.trim().split(' ').forEach(function(a){return n=n.concat(C(a,c,m,h))});var p;if(i&&window.MutationObserver){var q=o(l),r=q.content;p=new MutationObserver(function(){var a=c.getAttribute('title');a&&(r.innerHTML=a,k(c))}),p.observe(c,{attributes:!0})}return a.push({id:d,el:c,popper:l,settings:e,listeners:n,tippyInstance:b,_mutationObservers:[p]}),T++,a},[])}function H(a,b){return new U(a,b)}var I=Math.round;a=a&&a.hasOwnProperty('default')?a['default']:a;var J={};'undefined'!=typeof window&&(J.SUPPORTED='requestAnimationFrame'in window,J.SUPPORTS_TOUCH='ontouchstart'in window,J.touch=!1,J.dynamicInputDetection=!0,J.iOS=function(){return /iPhone|iPad|iPod/.test(navigator.userAgent)&&!window.MSStream});var K=[],L={POPPER:'.tippy-popper',TOOLTIP:'.tippy-tooltip',CONTENT:'.tippy-tooltip-content',CIRCLE:'[x-circle]',ARROW:'[x-arrow]',TOOLTIPPED_EL:'[data-tooltipped]',CONTROLLER:'[data-tippy-controller]'},M={html:!1,position:'top',animation:'shift',animateFill:!0,arrow:!1,arrowSize:'regular',delay:0,trigger:'mouseenter focus',duration:350,interactive:!1,interactiveBorder:2,theme:'dark',size:'regular',distance:10,offset:0,hideOnClick:!0,multiple:!1,followCursor:!1,inertia:!1,flipDuration:350,sticky:!1,stickyDuration:200,appendTo:function(){return document.body},zIndex:9999,touchHold:!1,performance:!1,dynamicTitle:!1,popperOptions:{}},N=J.SUPPORTED&&Object.keys(M),O={};if('undefined'!=typeof Element){var P=Element.prototype;O=P.matches||P.matchesSelector||P.webkitMatchesSelector||P.mozMatchesSelector||P.msMatchesSelector||function(a){for(var b=(this.document||this.ownerDocument).querySelectorAll(a),c=b.length;0<=--c&&b.item(c)!==this;);return-1<c}}var e=O,Q=function(a,b){if(!(a instanceof b))throw new TypeError('Cannot call a class as a function')},R=function(){function a(a,b){for(var c,d=0;d<b.length;d++)c=b[d],c.enumerable=c.enumerable||!1,c.configurable=!0,'value'in c&&(c.writable=!0),Object.defineProperty(a,c.key,c)}return function(b,c,d){return c&&a(b.prototype,c),d&&a(b,d),b}}(),S=Object.assign||function(a){for(var b,c=1;c<arguments.length;c++)for(var d in b=arguments[c],b)Object.prototype.hasOwnProperty.call(b,d)&&(a[d]=b[d]);return a},T=1,U=function(){function a(b){var c=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{};Q(this,a),J.SUPPORTED&&(g(),this.state={destroyed:!1},this.selector=b,this.settings=S({},M,c),(c.show||c.shown||c.hide||c.hidden)&&console.warn('Callbacks without the `on` prefix are deprecated (with the exception of `wait`). Use onShow, onShown, onHide, and onHidden instead.'),this.callbacks={wait:c.wait,show:c.onShow||c.show||r,shown:c.onShown||c.shown||r,hide:c.onHide||c.hide||r,hidden:c.onHidden||c.hidden||r},this.store=G.call(this,u(b)),K.push.apply(K,this.store))}return R(a,[{key:'getPopperElement',value:function(a){try{return d(this.store,function(b){return b.el===a}).popper}catch(a){console.error('[getPopperElement]: Element passed as the argument does not exist in the instance')}}},{key:'getReferenceElement',value:function(a){try{return d(this.store,function(b){return b.popper===a}).el}catch(a){console.error('[getReferenceElement]: Popper passed as the argument does not exist in the instance')}}},{key:'getReferenceData',value:function(a){return d(this.store,function(b){return b.el===a||b.popper===a})}},{key:'show',value:function(a,b){var c=this;if(!this.state.destroyed){var e=d(this.store,function(b){return b.popper===a}),f=o(a),g=f.tooltip,i=f.circle,j=f.content;if(!document.body.contains(e.el))return void this.destroy(a);this.callbacks.show.call(a);var k=e.el,l=e.settings,r=l.appendTo,s=l.sticky,t=l.interactive,u=l.followCursor,w=l.flipDuration,x=l.duration,A=void 0===b?Array.isArray(x)?x[0]:x:b;p([a,g,i],0),y(e),a.style.visibility='visible',a.setAttribute('aria-hidden','false'),h(function(){q(a)&&((!u||J.touch)&&(e.popperInstance.update(),p([a],w)),p([g,i],A),i&&(j.style.opacity=1),t&&k.classList.add('active'),s&&z(e),m(g,i),n([g,i],function(a){a.contains('tippy-notransition')&&a.remove('tippy-notransition'),a.remove('leave'),a.add('enter')}),v(e,A,function(){!q(a)||e._onShownFired||(t&&a.focus(),g.classList.add('tippy-notransition'),e._onShownFired=!0,c.callbacks.shown.call(a))}))})}}},{key:'hide',value:function(a,b){var c=this;if(!this.state.destroyed){this.callbacks.hide.call(a);var e=d(this.store,function(b){return b.popper===a}),f=o(a),g=f.tooltip,h=f.circle,i=f.content,j=e.el,k=e.settings,m=k.appendTo,r=k.sticky,s=k.interactive,u=k.followCursor,w=k.html,x=k.trigger,y=k.duration,z=void 0===b?Array.isArray(y)?y[1]:y:b;e._onShownFired=!1,s&&j.classList.remove('active'),a.style.visibility='hidden',a.setAttribute('aria-hidden','true'),p([g,h,h?i:null],z),h&&(i.style.opacity=0),n([g,h],function(a){a.contains('tippy-tooltip')&&a.remove('tippy-notransition'),a.remove('enter'),a.add('leave')}),w&&-1!==x.indexOf('click')&&l(j)&&j.focus(),v(e,z,function(){q(a)||!m.contains(a)||'1'===getComputedStyle(g).opacity||(j.removeEventListener('mousemove',t),e.popperInstance.disableEventListeners(),m.removeChild(a),c.callbacks.hidden.call(a))})}}},{key:'update',value:function(a){if(!this.state.destroyed){var b=d(this.store,function(b){return b.popper===a}),c=o(a),e=c.content,f=b.el,g=b.settings.html;return g instanceof Element?void console.warn('Aborted: update() should not be used if `html` is a DOM element'):void(e.innerHTML=g?document.getElementById(g.replace('#','')).innerHTML:f.getAttribute('title')||f.getAttribute('data-original-title'),!g&&k(f))}}},{key:'destroy',value:function(a,b){var c=this;if(!this.state.destroyed){var e=d(this.store,function(b){return b.popper===a}),f=e.el,g=e.popperInstance,h=e.listeners,i=e._mutationObservers;q(a)&&this.hide(a,0),h.forEach(function(a){return f.removeEventListener(a.event,a.handler)}),f.setAttribute('title',f.getAttribute('data-original-title')),f.removeAttribute('data-original-title'),f.removeAttribute('data-tooltipped'),f.removeAttribute('aria-describedby'),g&&g.destroy(),i.forEach(function(a){a&&a.disconnect()}),K.splice(j(K,function(b){return b.popper===a}),1),(void 0===b||b)&&(this.store=K.filter(function(a){return a.tippyInstance===c}))}}},{key:'destroyAll',value:function(){var a=this;if(!this.state.destroyed){var b=this.store.length;this.store.forEach(function(c,d){var e=c.popper;a.destroy(e,d===b-1)}),this.store=null,this.state.destroyed=!0}}}]),a}();return H.Browser=J,H.Defaults=M,H.disableDynamicInputDetection=function(){return J.dynamicInputDetection=!1},H.enableDynamicInputDetection=function(){return J.dynamicInputDetection=!0},H}); |
{ | ||
"name": "tippy.js", | ||
"version": "1.2.2", | ||
"version": "1.3.0", | ||
"description": "Vanilla JS Tooltip Library", | ||
@@ -5,0 +5,0 @@ "main": "dist/tippy.js", |
@@ -7,3 +7,3 @@ import { Browser, Selectors, Store } from './globals' | ||
import find from '../utils/find' | ||
import { matches } from '../utils/matches' | ||
import matches from '../utils/matches' | ||
@@ -10,0 +10,0 @@ /** |
@@ -74,3 +74,3 @@ import Popper from 'popper.js' | ||
data._mutationObserver = observer | ||
data._mutationObservers.push(observer) | ||
} | ||
@@ -77,0 +77,0 @@ |
@@ -7,3 +7,4 @@ import getIndividualSettings from './getIndividualSettings' | ||
import removeTitle from '../utils/removeTitle' | ||
import removeTitle from '../utils/removeTitle' | ||
import getInnerElements from '../utils/getInnerElements' | ||
@@ -20,15 +21,22 @@ import { Store } from './globals' | ||
export default function createTooltips(els) { | ||
return els.reduce((a, el) => { | ||
return els.reduce((acc, el) => { | ||
const id = idCounter | ||
const settings = evaluateSettings( | ||
const settings = Object.assign({}, evaluateSettings( | ||
this.settings.performance | ||
? this.settings | ||
: getIndividualSettings(el, this.settings) | ||
) | ||
)) | ||
const { html, trigger, touchHold } = settings | ||
if (typeof settings.html === 'function') settings.html = settings.html(el) | ||
const { | ||
html, | ||
trigger, | ||
touchHold, | ||
dynamicTitle | ||
} = settings | ||
const title = el.getAttribute('title') | ||
if (!title && !html) return a | ||
if (!title && !html) return acc | ||
@@ -45,6 +53,26 @@ el.setAttribute('data-tooltipped', '') | ||
trigger.trim().split(' ').forEach(event => | ||
listeners = listeners.concat(createTrigger(event, el, handlers, touchHold)) | ||
listeners = listeners.concat( | ||
createTrigger(event, el, handlers, touchHold) | ||
) | ||
) | ||
a.push({ | ||
// Add a mutation observer to observe the reference element for `title` | ||
// attribute changes, then automatically update tooltip content | ||
let observer | ||
if (dynamicTitle && window.MutationObserver) { | ||
const { content } = getInnerElements(popper) | ||
observer = new MutationObserver(() => { | ||
const title = el.getAttribute('title') | ||
if (title) { | ||
content.innerHTML = title | ||
removeTitle(el) | ||
} | ||
}) | ||
observer.observe(el, { attributes: true }) | ||
} | ||
acc.push({ | ||
id, | ||
@@ -55,3 +83,4 @@ el, | ||
listeners, | ||
tippyInstance: this | ||
tippyInstance: this, | ||
_mutationObservers: [observer] | ||
}) | ||
@@ -61,4 +90,4 @@ | ||
return a | ||
return acc | ||
}, []) | ||
} |
@@ -15,3 +15,7 @@ /** | ||
if (selector.constructor.name === 'NodeList') { | ||
return [].slice.call(selector) | ||
} | ||
return [].slice.call(document.querySelectorAll(selector)) | ||
} |
@@ -131,15 +131,6 @@ import { | ||
flipDuration, | ||
duration, | ||
dynamicTitle | ||
duration | ||
} | ||
} = data | ||
if (dynamicTitle) { | ||
const title = el.getAttribute('title') | ||
if (title) { | ||
content.innerHTML = title | ||
removeTitle(el) | ||
} | ||
} | ||
const _duration = customDuration !== undefined | ||
@@ -160,3 +151,3 @@ ? customDuration | ||
if (!isVisible(popper)) return | ||
// Sometimes the arrow will not be in the correct position, force another update | ||
@@ -315,3 +306,3 @@ if (!followCursor || Browser.touch) { | ||
listeners, | ||
_mutationObserver | ||
_mutationObservers | ||
} = data | ||
@@ -335,4 +326,7 @@ | ||
popperInstance && popperInstance.destroy() | ||
_mutationObserver && _mutationObserver.disconnect() | ||
_mutationObservers.forEach(observer => { | ||
observer && observer.disconnect() | ||
}) | ||
// Remove from store | ||
@@ -339,0 +333,0 @@ Store.splice(findIndex(Store, data => data.popper === popper), 1) |
import { Selectors } from '../core/globals' | ||
import prefix from './prefix' | ||
import { matches } from './matches' | ||
import matches from './matches' | ||
@@ -5,0 +5,0 @@ /** |
@@ -1,2 +0,2 @@ | ||
import { matches } from './matches' | ||
import matches from './matches' | ||
@@ -3,0 +3,0 @@ /** |
@@ -1,9 +0,12 @@ | ||
const e = Element.prototype | ||
export const matches = | ||
e.matches || | ||
e.matchesSelector || | ||
e.webkitMatchesSelector || | ||
e.mozMatchesSelector || | ||
e.msMatchesSelector || | ||
function(s) { | ||
let matches = {} | ||
if (typeof Element !== 'undefined') { | ||
const e = Element.prototype | ||
matches = | ||
e.matches || | ||
e.matchesSelector || | ||
e.webkitMatchesSelector || | ||
e.mozMatchesSelector || | ||
e.msMatchesSelector || | ||
function(s) { | ||
var matches = (this.document || this.ownerDocument).querySelectorAll(s), | ||
@@ -13,2 +16,5 @@ i = matches.length; | ||
return i > -1; | ||
} | ||
} | ||
} | ||
export default matches |
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
412390
9308