UNPKG

@fairfox/adorn

Version:

Powerfully performant keyword matching and annotation for the DOM

13 lines (10 loc) 37.3 kB
/* Copyright 2022 Alexander Jeffcott Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */ var er=Object.create;var Pe=Object.defineProperty;var tr=Object.getOwnPropertyDescriptor;var rr=Object.getOwnPropertyNames,st=Object.getOwnPropertySymbols,nr=Object.getPrototypeOf,pt=Object.prototype.hasOwnProperty,or=Object.prototype.propertyIsEnumerable;var ct=(t,e,r)=>e in t?Pe(t,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[e]=r,lt=(t,e)=>{for(var r in e||(e={}))pt.call(e,r)&&ct(t,r,e[r]);if(st)for(var r of st(e))or.call(e,r)&&ct(t,r,e[r]);return t};var ft=(t,e)=>()=>(e||t((e={exports:{}}).exports,e),e.exports);var ir=(t,e,r,n)=>{if(e&&typeof e=="object"||typeof e=="function")for(let o of rr(e))!pt.call(t,o)&&o!==r&&Pe(t,o,{get:()=>e[o],enumerable:!(n=tr(e,o))||n.enumerable});return t};var ut=(t,e,r)=>(r=t!=null?er(nr(t)):{},ir(e||!t||!t.__esModule?Pe(r,"default",{value:t,enumerable:!0}):r,t));var bt=ft((Dn,wt)=>{var gt="Expected a function",ht=NaN,sr="[object Symbol]",cr=/^\s+|\s+$/g,pr=/^[-+]0x[0-9a-f]+$/i,lr=/^0b[01]+$/i,fr=/^0o[0-7]+$/i,ur=parseInt,dr=typeof global=="object"&&global&&global.Object===Object&&global,vr=typeof self=="object"&&self&&self.Object===Object&&self,hr=dr||vr||Function("return this")(),mr=Object.prototype,gr=mr.toString,wr=Math.max,br=Math.min,je=function(){return hr.Date.now()};function yr(t,e,r){var n,o,i,s,a,c,l=0,p=!1,u=!1,w=!0;if(typeof t!="function")throw new TypeError(gt);e=mt(e)||0,Ee(r)&&(p=!!r.leading,u="maxWait"in r,i=u?wr(mt(r.maxWait)||0,e):i,w="trailing"in r?!!r.trailing:w);function d(f){var h=n,E=o;return n=o=void 0,l=f,s=t.apply(E,h),s}function y(f){return l=f,a=setTimeout(x,e),p?d(f):s}function v(f){var h=f-c,E=f-l,T=e-h;return u?br(T,i-E):T}function g(f){var h=f-c,E=f-l;return c===void 0||h>=e||h<0||u&&E>=i}function x(){var f=je();if(g(f))return C(f);a=setTimeout(x,v(f))}function C(f){return a=void 0,w&&n?d(f):(n=o=void 0,s)}function S(){a!==void 0&&clearTimeout(a),l=0,n=c=o=a=void 0}function m(){return a===void 0?s:C(je())}function b(){var f=je(),h=g(f);if(n=arguments,o=this,c=f,h){if(a===void 0)return y(c);if(u)return a=setTimeout(x,e),d(c)}return a===void 0&&(a=setTimeout(x,e)),s}return b.cancel=S,b.flush=m,b}function xr(t,e,r){var n=!0,o=!0;if(typeof t!="function")throw new TypeError(gt);return Ee(r)&&(n="leading"in r?!!r.leading:n,o="trailing"in r?!!r.trailing:o),yr(t,e,{leading:n,maxWait:e,trailing:o})}function Ee(t){var e=typeof t;return!!t&&(e=="object"||e=="function")}function Er(t){return!!t&&typeof t=="object"}function Or(t){return typeof t=="symbol"||Er(t)&&gr.call(t)==sr}function mt(t){if(typeof t=="number")return t;if(Or(t))return ht;if(Ee(t)){var e=typeof t.valueOf=="function"?t.valueOf():t;t=Ee(e)?e+"":e}if(typeof t!="string")return t===0?t:+t;t=t.replace(cr,"");var r=lr.test(t);return r||fr.test(t)?ur(t.slice(2),r?2:8):pr.test(t)?ht:+t}wt.exports=xr});var Xt=ft(M=>{"use strict";Object.defineProperty(M,"__esModule",{value:!0});function F(t){if(t==null)return window;if(t.toString()!=="[object Window]"){var e=t.ownerDocument;return e&&e.defaultView||window}return t}function G(t){var e=F(t).Element;return t instanceof e||t instanceof Element}function k(t){var e=F(t).HTMLElement;return t instanceof e||t instanceof HTMLElement}function Fe(t){if(typeof ShadowRoot>"u")return!1;var e=F(t).ShadowRoot;return t instanceof e||t instanceof ShadowRoot}var U=Math.max,Se=Math.min,Q=Math.round;function Z(t,e){e===void 0&&(e=!1);var r=t.getBoundingClientRect(),n=1,o=1;if(k(t)&&e){var i=t.offsetHeight,s=t.offsetWidth;s>0&&(n=Q(r.width)/s||1),i>0&&(o=Q(r.height)/i||1)}return{width:r.width/n,height:r.height/o,top:r.top/o,right:r.right/n,bottom:r.bottom/o,left:r.left/n,x:r.left/n,y:r.top/o}}function He(t){var e=F(t),r=e.pageXOffset,n=e.pageYOffset;return{scrollLeft:r,scrollTop:n}}function Ar(t){return{scrollLeft:t.scrollLeft,scrollTop:t.scrollTop}}function Mr(t){return t===F(t)||!k(t)?He(t):Ar(t)}function H(t){return t?(t.nodeName||"").toLowerCase():null}function q(t){return((G(t)?t.ownerDocument:t.document)||window.document).documentElement}function Ve(t){return Z(q(t)).left+He(t).scrollLeft}function B(t){return F(t).getComputedStyle(t)}function _e(t){var e=B(t),r=e.overflow,n=e.overflowX,o=e.overflowY;return/auto|scroll|overlay|hidden/.test(r+o+n)}function Nr(t){var e=t.getBoundingClientRect(),r=Q(e.width)/t.offsetWidth||1,n=Q(e.height)/t.offsetHeight||1;return r!==1||n!==1}function Ir(t,e,r){r===void 0&&(r=!1);var n=k(e),o=k(e)&&Nr(e),i=q(e),s=Z(t,o),a={scrollLeft:0,scrollTop:0},c={x:0,y:0};return(n||!n&&!r)&&((H(e)!=="body"||_e(i))&&(a=Mr(e)),k(e)?(c=Z(e,!0),c.x+=e.clientLeft,c.y+=e.clientTop):i&&(c.x=Ve(i))),{x:s.left+a.scrollLeft-c.x,y:s.top+a.scrollTop-c.y,width:s.width,height:s.height}}function qe(t){var e=Z(t),r=t.offsetWidth,n=t.offsetHeight;return Math.abs(e.width-r)<=1&&(r=e.width),Math.abs(e.height-n)<=1&&(n=e.height),{x:t.offsetLeft,y:t.offsetTop,width:r,height:n}}function Te(t){return H(t)==="html"?t:t.assignedSlot||t.parentNode||(Fe(t)?t.host:null)||q(t)}function Lt(t){return["html","body","#document"].indexOf(H(t))>=0?t.ownerDocument.body:k(t)&&_e(t)?t:Lt(Te(t))}function pe(t,e){var r;e===void 0&&(e=[]);var n=Lt(t),o=n===((r=t.ownerDocument)==null?void 0:r.body),i=F(n),s=o?[i].concat(i.visualViewport||[],_e(n)?n:[]):n,a=e.concat(s);return o?a:a.concat(pe(Te(s)))}function Rr(t){return["table","td","th"].indexOf(H(t))>=0}function xt(t){return!k(t)||B(t).position==="fixed"?null:t.offsetParent}function Lr(t){var e=navigator.userAgent.toLowerCase().indexOf("firefox")!==-1,r=navigator.userAgent.indexOf("Trident")!==-1;if(r&&k(t)){var n=B(t);if(n.position==="fixed")return null}var o=Te(t);for(Fe(o)&&(o=o.host);k(o)&&["html","body"].indexOf(H(o))<0;){var i=B(o);if(i.transform!=="none"||i.perspective!=="none"||i.contain==="paint"||["transform","perspective"].indexOf(i.willChange)!==-1||e&&i.willChange==="filter"||e&&i.filter&&i.filter!=="none")return o;o=o.parentNode}return null}function ue(t){for(var e=F(t),r=xt(t);r&&Rr(r)&&B(r).position==="static";)r=xt(r);return r&&(H(r)==="html"||H(r)==="body"&&B(r).position==="static")?e:r||Lr(t)||e}var I="top",D="bottom",j="right",R="left",Ae="auto",de=[I,D,j,R],ee="start",fe="end",Pr="clippingParents",Pt="viewport",ce="popper",kr="reference",Et=de.reduce(function(t,e){return t.concat([e+"-"+ee,e+"-"+fe])},[]),kt=[].concat(de,[Ae]).reduce(function(t,e){return t.concat([e,e+"-"+ee,e+"-"+fe])},[]),Dr="beforeRead",jr="read",$r="afterRead",Wr="beforeMain",Br="main",Fr="afterMain",Hr="beforeWrite",Vr="write",_r="afterWrite",We=[Dr,jr,$r,Wr,Br,Fr,Hr,Vr,_r];function qr(t){var e=new Map,r=new Set,n=[];t.forEach(function(i){e.set(i.name,i)});function o(i){r.add(i.name);var s=[].concat(i.requires||[],i.requiresIfExists||[]);s.forEach(function(a){if(!r.has(a)){var c=e.get(a);c&&o(c)}}),n.push(i)}return t.forEach(function(i){r.has(i.name)||o(i)}),n}function Kr(t){var e=qr(t);return We.reduce(function(r,n){return r.concat(e.filter(function(o){return o.phase===n}))},[])}function Xr(t){var e;return function(){return e||(e=new Promise(function(r){Promise.resolve().then(function(){e=void 0,r(t())})})),e}}function _(t){for(var e=arguments.length,r=new Array(e>1?e-1:0),n=1;n<e;n++)r[n-1]=arguments[n];return[].concat(r).reduce(function(o,i){return o.replace(/%s/,i)},t)}var J='Popper: modifier "%s" provided an invalid %s property, expected %s but got %s',Yr='Popper: modifier "%s" requires "%s", but "%s" modifier is not available',Ot=["name","enabled","phase","fn","effect","requires","options"];function Jr(t){t.forEach(function(e){[].concat(Object.keys(e),Ot).filter(function(r,n,o){return o.indexOf(r)===n}).forEach(function(r){switch(r){case"name":typeof e.name!="string"&&console.error(_(J,String(e.name),'"name"','"string"','"'+String(e.name)+'"'));break;case"enabled":typeof e.enabled!="boolean"&&console.error(_(J,e.name,'"enabled"','"boolean"','"'+String(e.enabled)+'"'));break;case"phase":We.indexOf(e.phase)<0&&console.error(_(J,e.name,'"phase"',"either "+We.join(", "),'"'+String(e.phase)+'"'));break;case"fn":typeof e.fn!="function"&&console.error(_(J,e.name,'"fn"','"function"','"'+String(e.fn)+'"'));break;case"effect":e.effect!=null&&typeof e.effect!="function"&&console.error(_(J,e.name,'"effect"','"function"','"'+String(e.fn)+'"'));break;case"requires":e.requires!=null&&!Array.isArray(e.requires)&&console.error(_(J,e.name,'"requires"','"array"','"'+String(e.requires)+'"'));break;case"requiresIfExists":Array.isArray(e.requiresIfExists)||console.error(_(J,e.name,'"requiresIfExists"','"array"','"'+String(e.requiresIfExists)+'"'));break;case"options":case"data":break;default:console.error('PopperJS: an invalid property has been provided to the "'+e.name+'" modifier, valid properties are '+Ot.map(function(n){return'"'+n+'"'}).join(", ")+'; but "'+r+'" was provided.')}e.requires&&e.requires.forEach(function(n){t.find(function(o){return o.name===n})==null&&console.error(_(Yr,String(e.name),n,n))})})})}function Ur(t,e){var r=new Set;return t.filter(function(n){var o=e(n);if(!r.has(o))return r.add(o),!0})}function W(t){return t.split("-")[0]}function zr(t){var e=t.reduce(function(r,n){var o=r[n.name];return r[n.name]=o?Object.assign({},o,n,{options:Object.assign({},o.options,n.options),data:Object.assign({},o.data,n.data)}):n,r},{});return Object.keys(e).map(function(r){return e[r]})}function Gr(t){var e=F(t),r=q(t),n=e.visualViewport,o=r.clientWidth,i=r.clientHeight,s=0,a=0;return n&&(o=n.width,i=n.height,/^((?!chrome|android).)*safari/i.test(navigator.userAgent)||(s=n.offsetLeft,a=n.offsetTop)),{width:o,height:i,x:s+Ve(t),y:a}}function Qr(t){var e,r=q(t),n=He(t),o=(e=t.ownerDocument)==null?void 0:e.body,i=U(r.scrollWidth,r.clientWidth,o?o.scrollWidth:0,o?o.clientWidth:0),s=U(r.scrollHeight,r.clientHeight,o?o.scrollHeight:0,o?o.clientHeight:0),a=-n.scrollLeft+Ve(t),c=-n.scrollTop;return B(o||r).direction==="rtl"&&(a+=U(r.clientWidth,o?o.clientWidth:0)-i),{width:i,height:s,x:a,y:c}}function Dt(t,e){var r=e.getRootNode&&e.getRootNode();if(t.contains(e))return!0;if(r&&Fe(r)){var n=e;do{if(n&&t.isSameNode(n))return!0;n=n.parentNode||n.host}while(n)}return!1}function Be(t){return Object.assign({},t,{left:t.x,top:t.y,right:t.x+t.width,bottom:t.y+t.height})}function Zr(t){var e=Z(t);return e.top=e.top+t.clientTop,e.left=e.left+t.clientLeft,e.bottom=e.top+t.clientHeight,e.right=e.left+t.clientWidth,e.width=t.clientWidth,e.height=t.clientHeight,e.x=e.left,e.y=e.top,e}function Ct(t,e){return e===Pt?Be(Gr(t)):G(e)?Zr(e):Be(Qr(q(t)))}function en(t){var e=pe(Te(t)),r=["absolute","fixed"].indexOf(B(t).position)>=0,n=r&&k(t)?ue(t):t;return G(n)?e.filter(function(o){return G(o)&&Dt(o,n)&&H(o)!=="body"}):[]}function tn(t,e,r){var n=e==="clippingParents"?en(t):[].concat(e),o=[].concat(n,[r]),i=o[0],s=o.reduce(function(a,c){var l=Ct(t,c);return a.top=U(l.top,a.top),a.right=Se(l.right,a.right),a.bottom=Se(l.bottom,a.bottom),a.left=U(l.left,a.left),a},Ct(t,i));return s.width=s.right-s.left,s.height=s.bottom-s.top,s.x=s.left,s.y=s.top,s}function te(t){return t.split("-")[1]}function Ke(t){return["top","bottom"].indexOf(t)>=0?"x":"y"}function jt(t){var e=t.reference,r=t.element,n=t.placement,o=n?W(n):null,i=n?te(n):null,s=e.x+e.width/2-r.width/2,a=e.y+e.height/2-r.height/2,c;switch(o){case I:c={x:s,y:e.y-r.height};break;case D:c={x:s,y:e.y+e.height};break;case j:c={x:e.x+e.width,y:a};break;case R:c={x:e.x-r.width,y:a};break;default:c={x:e.x,y:e.y}}var l=o?Ke(o):null;if(l!=null){var p=l==="y"?"height":"width";switch(i){case ee:c[l]=c[l]-(e[p]/2-r[p]/2);break;case fe:c[l]=c[l]+(e[p]/2-r[p]/2);break}}return c}function $t(){return{top:0,right:0,bottom:0,left:0}}function Wt(t){return Object.assign({},$t(),t)}function Bt(t,e){return e.reduce(function(r,n){return r[n]=t,r},{})}function re(t,e){e===void 0&&(e={});var r=e,n=r.placement,o=n===void 0?t.placement:n,i=r.boundary,s=i===void 0?Pr:i,a=r.rootBoundary,c=a===void 0?Pt:a,l=r.elementContext,p=l===void 0?ce:l,u=r.altBoundary,w=u===void 0?!1:u,d=r.padding,y=d===void 0?0:d,v=Wt(typeof y!="number"?y:Bt(y,de)),g=p===ce?kr:ce,x=t.rects.popper,C=t.elements[w?g:p],S=tn(G(C)?C:C.contextElement||q(t.elements.popper),s,c),m=Z(t.elements.reference),b=jt({reference:m,element:x,strategy:"absolute",placement:o}),f=Be(Object.assign({},x,b)),h=p===ce?f:m,E={top:S.top-h.top+v.top,bottom:h.bottom-S.bottom+v.bottom,left:S.left-h.left+v.left,right:h.right-S.right+v.right},T=t.modifiersData.offset;if(p===ce&&T){var A=T[o];Object.keys(E).forEach(function(O){var N=[j,D].indexOf(O)>=0?1:-1,L=[I,D].indexOf(O)>=0?"y":"x";E[O]+=A[L]*N})}return E}var St="Popper: Invalid reference or popper argument provided. They must be either a DOM element or virtual element.",rn="Popper: An infinite loop in the modifiers cycle has been detected! The cycle has been interrupted to prevent a browser crash.",Tt={placement:"bottom",modifiers:[],strategy:"absolute"};function At(){for(var t=arguments.length,e=new Array(t),r=0;r<t;r++)e[r]=arguments[r];return!e.some(function(n){return!(n&&typeof n.getBoundingClientRect=="function")})}function Xe(t){t===void 0&&(t={});var e=t,r=e.defaultModifiers,n=r===void 0?[]:r,o=e.defaultOptions,i=o===void 0?Tt:o;return function(a,c,l){l===void 0&&(l=i);var p={placement:"bottom",orderedModifiers:[],options:Object.assign({},Tt,i),modifiersData:{},elements:{reference:a,popper:c},attributes:{},styles:{}},u=[],w=!1,d={state:p,setOptions:function(x){var C=typeof x=="function"?x(p.options):x;v(),p.options=Object.assign({},i,p.options,C),p.scrollParents={reference:G(a)?pe(a):a.contextElement?pe(a.contextElement):[],popper:pe(c)};var S=Kr(zr([].concat(n,p.options.modifiers)));if(p.orderedModifiers=S.filter(function(O){return O.enabled}),process.env.NODE_ENV!=="production"){var m=Ur([].concat(S,p.options.modifiers),function(O){var N=O.name;return N});if(Jr(m),W(p.options.placement)===Ae){var b=p.orderedModifiers.find(function(O){var N=O.name;return N==="flip"});b||console.error(['Popper: "auto" placements require the "flip" modifier be',"present and enabled to work."].join(" "))}var f=B(c),h=f.marginTop,E=f.marginRight,T=f.marginBottom,A=f.marginLeft;[h,E,T,A].some(function(O){return parseFloat(O)})&&console.warn(['Popper: CSS "margin" styles cannot be used to apply padding',"between the popper and its reference element or boundary.","To replicate margin, use the `offset` modifier, as well as","the `padding` option in the `preventOverflow` and `flip`","modifiers."].join(" "))}return y(),d.update()},forceUpdate:function(){if(!w){var x=p.elements,C=x.reference,S=x.popper;if(!At(C,S)){process.env.NODE_ENV!=="production"&&console.error(St);return}p.rects={reference:Ir(C,ue(S),p.options.strategy==="fixed"),popper:qe(S)},p.reset=!1,p.placement=p.options.placement,p.orderedModifiers.forEach(function(O){return p.modifiersData[O.name]=Object.assign({},O.data)});for(var m=0,b=0;b<p.orderedModifiers.length;b++){if(process.env.NODE_ENV!=="production"&&(m+=1,m>100)){console.error(rn);break}if(p.reset===!0){p.reset=!1,b=-1;continue}var f=p.orderedModifiers[b],h=f.fn,E=f.options,T=E===void 0?{}:E,A=f.name;typeof h=="function"&&(p=h({state:p,options:T,name:A,instance:d})||p)}}},update:Xr(function(){return new Promise(function(g){d.forceUpdate(),g(p)})}),destroy:function(){v(),w=!0}};if(!At(a,c))return process.env.NODE_ENV!=="production"&&console.error(St),d;d.setOptions(l).then(function(g){!w&&l.onFirstUpdate&&l.onFirstUpdate(g)});function y(){p.orderedModifiers.forEach(function(g){var x=g.name,C=g.options,S=C===void 0?{}:C,m=g.effect;if(typeof m=="function"){var b=m({state:p,name:x,instance:d,options:S}),f=function(){};u.push(b||f)}})}function v(){u.forEach(function(g){return g()}),u=[]}return d}}var Oe={passive:!0};function nn(t){var e=t.state,r=t.instance,n=t.options,o=n.scroll,i=o===void 0?!0:o,s=n.resize,a=s===void 0?!0:s,c=F(e.elements.popper),l=[].concat(e.scrollParents.reference,e.scrollParents.popper);return i&&l.forEach(function(p){p.addEventListener("scroll",r.update,Oe)}),a&&c.addEventListener("resize",r.update,Oe),function(){i&&l.forEach(function(p){p.removeEventListener("scroll",r.update,Oe)}),a&&c.removeEventListener("resize",r.update,Oe)}}var Ye={name:"eventListeners",enabled:!0,phase:"write",fn:function(){},effect:nn,data:{}};function on(t){var e=t.state,r=t.name;e.modifiersData[r]=jt({reference:e.rects.reference,element:e.rects.popper,strategy:"absolute",placement:e.placement})}var Je={name:"popperOffsets",enabled:!0,phase:"read",fn:on,data:{}},an={top:"auto",right:"auto",bottom:"auto",left:"auto"};function sn(t){var e=t.x,r=t.y,n=window,o=n.devicePixelRatio||1;return{x:Q(e*o)/o||0,y:Q(r*o)/o||0}}function Mt(t){var e,r=t.popper,n=t.popperRect,o=t.placement,i=t.variation,s=t.offsets,a=t.position,c=t.gpuAcceleration,l=t.adaptive,p=t.roundOffsets,u=t.isFixed,w=s.x,d=w===void 0?0:w,y=s.y,v=y===void 0?0:y,g=typeof p=="function"?p({x:d,y:v}):{x:d,y:v};d=g.x,v=g.y;var x=s.hasOwnProperty("x"),C=s.hasOwnProperty("y"),S=R,m=I,b=window;if(l){var f=ue(r),h="clientHeight",E="clientWidth";if(f===F(r)&&(f=q(r),B(f).position!=="static"&&a==="absolute"&&(h="scrollHeight",E="scrollWidth")),f=f,o===I||(o===R||o===j)&&i===fe){m=D;var T=u&&f===b&&b.visualViewport?b.visualViewport.height:f[h];v-=T-n.height,v*=c?1:-1}if(o===R||(o===I||o===D)&&i===fe){S=j;var A=u&&f===b&&b.visualViewport?b.visualViewport.width:f[E];d-=A-n.width,d*=c?1:-1}}var O=Object.assign({position:a},l&&an),N=p===!0?sn({x:d,y:v}):{x:d,y:v};if(d=N.x,v=N.y,c){var L;return Object.assign({},O,(L={},L[m]=C?"0":"",L[S]=x?"0":"",L.transform=(b.devicePixelRatio||1)<=1?"translate("+d+"px, "+v+"px)":"translate3d("+d+"px, "+v+"px, 0)",L))}return Object.assign({},O,(e={},e[m]=C?v+"px":"",e[S]=x?d+"px":"",e.transform="",e))}function cn(t){var e=t.state,r=t.options,n=r.gpuAcceleration,o=n===void 0?!0:n,i=r.adaptive,s=i===void 0?!0:i,a=r.roundOffsets,c=a===void 0?!0:a;if(process.env.NODE_ENV!=="production"){var l=B(e.elements.popper).transitionProperty||"";s&&["transform","top","right","bottom","left"].some(function(u){return l.indexOf(u)>=0})&&console.warn(["Popper: Detected CSS transitions on at least one of the following",'CSS properties: "transform", "top", "right", "bottom", "left".',` `,'Disable the "computeStyles" modifier\'s `adaptive` option to allow',"for smooth transitions, or remove these properties from the CSS","transition declaration on the popper element if only transitioning","opacity or background-color for example.",` `,"We recommend using the popper element as a wrapper around an inner","element that can have any CSS property transitioned for animations."].join(" "))}var p={placement:W(e.placement),variation:te(e.placement),popper:e.elements.popper,popperRect:e.rects.popper,gpuAcceleration:o,isFixed:e.options.strategy==="fixed"};e.modifiersData.popperOffsets!=null&&(e.styles.popper=Object.assign({},e.styles.popper,Mt(Object.assign({},p,{offsets:e.modifiersData.popperOffsets,position:e.options.strategy,adaptive:s,roundOffsets:c})))),e.modifiersData.arrow!=null&&(e.styles.arrow=Object.assign({},e.styles.arrow,Mt(Object.assign({},p,{offsets:e.modifiersData.arrow,position:"absolute",adaptive:!1,roundOffsets:c})))),e.attributes.popper=Object.assign({},e.attributes.popper,{"data-popper-placement":e.placement})}var Ue={name:"computeStyles",enabled:!0,phase:"beforeWrite",fn:cn,data:{}};function pn(t){var e=t.state;Object.keys(e.elements).forEach(function(r){var n=e.styles[r]||{},o=e.attributes[r]||{},i=e.elements[r];!k(i)||!H(i)||(Object.assign(i.style,n),Object.keys(o).forEach(function(s){var a=o[s];a===!1?i.removeAttribute(s):i.setAttribute(s,a===!0?"":a)}))})}function ln(t){var e=t.state,r={popper:{position:e.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};return Object.assign(e.elements.popper.style,r.popper),e.styles=r,e.elements.arrow&&Object.assign(e.elements.arrow.style,r.arrow),function(){Object.keys(e.elements).forEach(function(n){var o=e.elements[n],i=e.attributes[n]||{},s=Object.keys(e.styles.hasOwnProperty(n)?e.styles[n]:r[n]),a=s.reduce(function(c,l){return c[l]="",c},{});!k(o)||!H(o)||(Object.assign(o.style,a),Object.keys(i).forEach(function(c){o.removeAttribute(c)}))})}}var ze={name:"applyStyles",enabled:!0,phase:"write",fn:pn,effect:ln,requires:["computeStyles"]};function fn(t,e,r){var n=W(t),o=[R,I].indexOf(n)>=0?-1:1,i=typeof r=="function"?r(Object.assign({},e,{placement:t})):r,s=i[0],a=i[1];return s=s||0,a=(a||0)*o,[R,j].indexOf(n)>=0?{x:a,y:s}:{x:s,y:a}}function un(t){var e=t.state,r=t.options,n=t.name,o=r.offset,i=o===void 0?[0,0]:o,s=kt.reduce(function(p,u){return p[u]=fn(u,e.rects,i),p},{}),a=s[e.placement],c=a.x,l=a.y;e.modifiersData.popperOffsets!=null&&(e.modifiersData.popperOffsets.x+=c,e.modifiersData.popperOffsets.y+=l),e.modifiersData[n]=s}var Ft={name:"offset",enabled:!0,phase:"main",requires:["popperOffsets"],fn:un},dn={left:"right",right:"left",bottom:"top",top:"bottom"};function Ce(t){return t.replace(/left|right|bottom|top/g,function(e){return dn[e]})}var vn={start:"end",end:"start"};function Nt(t){return t.replace(/start|end/g,function(e){return vn[e]})}function hn(t,e){e===void 0&&(e={});var r=e,n=r.placement,o=r.boundary,i=r.rootBoundary,s=r.padding,a=r.flipVariations,c=r.allowedAutoPlacements,l=c===void 0?kt:c,p=te(n),u=p?a?Et:Et.filter(function(y){return te(y)===p}):de,w=u.filter(function(y){return l.indexOf(y)>=0});w.length===0&&(w=u,process.env.NODE_ENV!=="production"&&console.error(["Popper: The `allowedAutoPlacements` option did not allow any","placements. Ensure the `placement` option matches the variation","of the allowed placements.",'For example, "auto" cannot be used to allow "bottom-start".','Use "auto-start" instead.'].join(" ")));var d=w.reduce(function(y,v){return y[v]=re(t,{placement:v,boundary:o,rootBoundary:i,padding:s})[W(v)],y},{});return Object.keys(d).sort(function(y,v){return d[y]-d[v]})}function mn(t){if(W(t)===Ae)return[];var e=Ce(t);return[Nt(t),e,Nt(e)]}function gn(t){var e=t.state,r=t.options,n=t.name;if(!e.modifiersData[n]._skip){for(var o=r.mainAxis,i=o===void 0?!0:o,s=r.altAxis,a=s===void 0?!0:s,c=r.fallbackPlacements,l=r.padding,p=r.boundary,u=r.rootBoundary,w=r.altBoundary,d=r.flipVariations,y=d===void 0?!0:d,v=r.allowedAutoPlacements,g=e.options.placement,x=W(g),C=x===g,S=c||(C||!y?[Ce(g)]:mn(g)),m=[g].concat(S).reduce(function(z,V){return z.concat(W(V)===Ae?hn(e,{placement:V,boundary:p,rootBoundary:u,padding:l,flipVariations:y,allowedAutoPlacements:v}):V)},[]),b=e.rects.reference,f=e.rects.popper,h=new Map,E=!0,T=m[0],A=0;A<m.length;A++){var O=m[A],N=W(O),L=te(O)===ee,ne=[I,D].indexOf(N)>=0,oe=ne?"width":"height",P=re(e,{placement:O,boundary:p,rootBoundary:u,altBoundary:w,padding:l}),$=ne?L?j:R:L?D:I;b[oe]>f[oe]&&($=Ce($));var he=Ce($),K=[];if(i&&K.push(P[N]<=0),a&&K.push(P[$]<=0,P[he]<=0),K.every(function(z){return z})){T=O,E=!1;break}h.set(O,K)}if(E)for(var me=y?3:1,Ne=function(V){var ae=m.find(function(we){var X=h.get(we);if(X)return X.slice(0,V).every(function(Ie){return Ie})});if(ae)return T=ae,"break"},ie=me;ie>0;ie--){var ge=Ne(ie);if(ge==="break")break}e.placement!==T&&(e.modifiersData[n]._skip=!0,e.placement=T,e.reset=!0)}}var Ht={name:"flip",enabled:!0,phase:"main",fn:gn,requiresIfExists:["offset"],data:{_skip:!1}};function wn(t){return t==="x"?"y":"x"}function le(t,e,r){return U(t,Se(e,r))}function bn(t,e,r){var n=le(t,e,r);return n>r?r:n}function yn(t){var e=t.state,r=t.options,n=t.name,o=r.mainAxis,i=o===void 0?!0:o,s=r.altAxis,a=s===void 0?!1:s,c=r.boundary,l=r.rootBoundary,p=r.altBoundary,u=r.padding,w=r.tether,d=w===void 0?!0:w,y=r.tetherOffset,v=y===void 0?0:y,g=re(e,{boundary:c,rootBoundary:l,padding:u,altBoundary:p}),x=W(e.placement),C=te(e.placement),S=!C,m=Ke(x),b=wn(m),f=e.modifiersData.popperOffsets,h=e.rects.reference,E=e.rects.popper,T=typeof v=="function"?v(Object.assign({},e.rects,{placement:e.placement})):v,A=typeof T=="number"?{mainAxis:T,altAxis:T}:Object.assign({mainAxis:0,altAxis:0},T),O=e.modifiersData.offset?e.modifiersData.offset[e.placement]:null,N={x:0,y:0};if(!!f){if(i){var L,ne=m==="y"?I:R,oe=m==="y"?D:j,P=m==="y"?"height":"width",$=f[m],he=$+g[ne],K=$-g[oe],me=d?-E[P]/2:0,Ne=C===ee?h[P]:E[P],ie=C===ee?-E[P]:-h[P],ge=e.elements.arrow,z=d&&ge?qe(ge):{width:0,height:0},V=e.modifiersData["arrow#persistent"]?e.modifiersData["arrow#persistent"].padding:$t(),ae=V[ne],we=V[oe],X=le(0,h[P],z[P]),Ie=S?h[P]/2-me-X-ae-A.mainAxis:Ne-X-ae-A.mainAxis,Jt=S?-h[P]/2+me+X+we+A.mainAxis:ie+X+we+A.mainAxis,Re=e.elements.arrow&&ue(e.elements.arrow),Ut=Re?m==="y"?Re.clientTop||0:Re.clientLeft||0:0,Qe=(L=O==null?void 0:O[m])!=null?L:0,zt=$+Ie-Qe-Ut,Gt=$+Jt-Qe,Ze=le(d?Se(he,zt):he,$,d?U(K,Gt):K);f[m]=Ze,N[m]=Ze-$}if(a){var et,Qt=m==="x"?I:R,Zt=m==="x"?D:j,Y=f[b],be=b==="y"?"height":"width",tt=Y+g[Qt],rt=Y-g[Zt],Le=[I,R].indexOf(x)!==-1,nt=(et=O==null?void 0:O[b])!=null?et:0,ot=Le?tt:Y-h[be]-E[be]-nt+A.altAxis,it=Le?Y+h[be]+E[be]-nt-A.altAxis:rt,at=d&&Le?bn(ot,Y,it):le(d?ot:tt,Y,d?it:rt);f[b]=at,N[b]=at-Y}e.modifiersData[n]=N}}var Vt={name:"preventOverflow",enabled:!0,phase:"main",fn:yn,requiresIfExists:["offset"]},xn=function(e,r){return e=typeof e=="function"?e(Object.assign({},r.rects,{placement:r.placement})):e,Wt(typeof e!="number"?e:Bt(e,de))};function En(t){var e,r=t.state,n=t.name,o=t.options,i=r.elements.arrow,s=r.modifiersData.popperOffsets,a=W(r.placement),c=Ke(a),l=[R,j].indexOf(a)>=0,p=l?"height":"width";if(!(!i||!s)){var u=xn(o.padding,r),w=qe(i),d=c==="y"?I:R,y=c==="y"?D:j,v=r.rects.reference[p]+r.rects.reference[c]-s[c]-r.rects.popper[p],g=s[c]-r.rects.reference[c],x=ue(i),C=x?c==="y"?x.clientHeight||0:x.clientWidth||0:0,S=v/2-g/2,m=u[d],b=C-w[p]-u[y],f=C/2-w[p]/2+S,h=le(m,f,b),E=c;r.modifiersData[n]=(e={},e[E]=h,e.centerOffset=h-f,e)}}function On(t){var e=t.state,r=t.options,n=r.element,o=n===void 0?"[data-popper-arrow]":n;if(o!=null&&!(typeof o=="string"&&(o=e.elements.popper.querySelector(o),!o))){if(process.env.NODE_ENV!=="production"&&(k(o)||console.error(['Popper: "arrow" element must be an HTMLElement (not an SVGElement).',"To use an SVG arrow, wrap it in an HTMLElement that will be used as","the arrow."].join(" "))),!Dt(e.elements.popper,o)){process.env.NODE_ENV!=="production"&&console.error(['Popper: "arrow" modifier\'s `element` must be a child of the popper',"element."].join(" "));return}e.elements.arrow=o}}var _t={name:"arrow",enabled:!0,phase:"main",fn:En,effect:On,requires:["popperOffsets"],requiresIfExists:["preventOverflow"]};function It(t,e,r){return r===void 0&&(r={x:0,y:0}),{top:t.top-e.height-r.y,right:t.right-e.width+r.x,bottom:t.bottom-e.height+r.y,left:t.left-e.width-r.x}}function Rt(t){return[I,j,D,R].some(function(e){return t[e]>=0})}function Cn(t){var e=t.state,r=t.name,n=e.rects.reference,o=e.rects.popper,i=e.modifiersData.preventOverflow,s=re(e,{elementContext:"reference"}),a=re(e,{altBoundary:!0}),c=It(s,n),l=It(a,o,i),p=Rt(c),u=Rt(l);e.modifiersData[r]={referenceClippingOffsets:c,popperEscapeOffsets:l,isReferenceHidden:p,hasPopperEscaped:u},e.attributes.popper=Object.assign({},e.attributes.popper,{"data-popper-reference-hidden":p,"data-popper-escaped":u})}var qt={name:"hide",enabled:!0,phase:"main",requiresIfExists:["preventOverflow"],fn:Cn},Sn=[Ye,Je,Ue,ze],Tn=Xe({defaultModifiers:Sn}),Kt=[Ye,Je,Ue,ze,Ft,Ht,Vt,_t,qt],An=Xe({defaultModifiers:Kt});M.applyStyles=ze;M.arrow=_t;M.computeStyles=Ue;M.createPopper=An;M.createPopperLite=Tn;M.defaultModifiers=Kt;M.detectOverflow=re;M.eventListeners=Ye;M.flip=Ht;M.hide=qt;M.offset=Ft;M.popperGenerator=Xe;M.popperOffsets=Je;M.preventOverflow=Vt});var ye=(t,e,r)=>{let n=[];for(let o=t;o<=e;o++)n.push(r?String.fromCharCode(o):o.toString());return n},dt=()=>new Set([...ye(0,9,!1),...ye(65,90,!0),...ye(97,122,!0),"_"]),vt=()=>new Set(ye(9,13,!0)),ar=(t,e)=>e instanceof Map?Array.from(e.entries()):e;var ke=(t,e)=>JSON.stringify(t,ar,e?2:0),se=t=>Array.from(new Set(t)),xe=(t,e)=>e.filter((r,n)=>r!==t[n]);var De=class{_kw;wordChars;skipChars;trieCI;trieCS;opts;constructor(e,r,n){if(this._kw="_kw_",this.wordChars=dt(),this.skipChars=vt(),this.trieCI=new Map,this.trieCS=new Map,this.areKwListMapsValid(e,r),this.addKws(e,!1),this.addKws(r,!0),this.opts=lt({tag:"span",getAttrs:o=>[["data-match-id",o]],shouldSkipChars:!0},n),typeof window<"u"&&window.customElements&&n.element!==void 0&&!window.customElements.get(n.tag)){if(Array.isArray(n.elementMethods)&&n.elementMethods.length){let{element:o}=n;n.elementMethods.forEach(([i,s])=>o.prototype[i]=s)}window.customElements.define(n.tag,n.element)}}getDetails(){return{trieAsString:`CI ===> ${ke(this.trieCI)} || CS ===> ${ke(this.trieCS)}`}}addKw(e,r,n){let o=n?this.trieCS:this.trieCI;r.split("").forEach(i=>{if(n)o.get(i)||o.set(i,new Map),o=o.get(i);else{let s=i.toLowerCase(),a=i.toUpperCase(),c=o.get(s);c||o.set(s,new Map),c=o.get(s),o.get(a)||o.set(a,c),o=c}}),o.set(this._kw,e)}areKwListMapsValid=(e,r)=>{if(e===null&&r===null)throw new Error("please provide a case-sensitive and/or case-insensitive kw map");let n=[];r!==null&&r.forEach(p=>p.forEach(u=>n.push(u)));let o=se(n);if(o.length!==n.length)throw new Error(`case-sensitive map contains duplicates => ${JSON.stringify(xe(o,n))}`);let i=[];e!==null&&e.forEach(p=>p.forEach(u=>i.push(u.toLowerCase())));let s=se(i);if(s.length!==i.length)throw new Error(`lower-cased case-insensitive map contains duplicates => ${JSON.stringify(xe(s,i))}`);let a=n.map(p=>p.toLowerCase()),c=[...se(a),...i],l=se(c);if(l.length!==c.length)throw new Error(`merged lower-cased case-insensitive list and deduped lower-cased case-sensitive map contains duplicates => ${JSON.stringify(xe(l,c))}`);return!0};addKws(e,r){e!==null&&e.forEach((n,o)=>{n.forEach(i=>this.addKw(o,i,r))})}getMatchIndexes(e){let r=[],n=e.length,o=i=>{let s=i?this.trieCS:this.trieCI,a=["",-1,-1],c=!1;for(let l=0;l<=n;l++){let p=e[l],u=e[l-1],w=e[l+1],d=!this.wordChars.has(p),y=!this.wordChars.has(u),v=!this.wordChars.has(w);if(c=s.has(p),!(this.opts.shouldSkipChars&&this.skipChars.has(p))){if(!c){a[0]&&a[1]>=0&&a[2]>=0&&d&&r.push(a),s=i?this.trieCS:this.trieCI,a=["",-1,-1],s.has(p)&&(l=l-1);continue}a[1]<0&&y&&(a[1]=l),s=s.get(p),s.has(this._kw)&&v&&(a=[s.get(this._kw),a[1],l])}}};return this.trieCI!==null&&o(!1),this.trieCS!==null&&o(!0),r.sort((i,s)=>i[1]-s[1])}extractMatchIds(e){let r=this.getMatchIndexes(e).map(n=>n[0]);return Array.from(new Set(r))}extractDirtyMatches(e){let r=this.getMatchIndexes(e).map(n=>[n[0],e.slice(n[1],n[2]+1)]);return new Map(r)}replaceKws(e){let r=0,n="";return this.getMatchIndexes(e).forEach(o=>{n=n+e.slice(r,o[1])+o[0],r=o[2]+1}),n+e.slice(r)}wrapKwsWithHtml(e){let r=this.getMatchIndexes(e);if(!r.length)return e;let n=0,o="";return r.forEach(i=>{var a,c;let s=((c=(a=this.opts).getAttrs)==null?void 0:c.call(a,i[0]).reduce((l,p,u)=>`${l}${u>0?" ":""}${p[0]}="${p[1]}"`,""))||"";o=`${o}${e.slice(n,i[1])}<${this.opts.tag} ${s}>${e.slice(i[1],i[2]+1)}</${this.opts.tag}>`,n=i[2]+1}),o+e.slice(n)}};var yt=ut(bt(),1),Cr=(t,e)=>100*Math.abs((t-e)/((t+e)/2)),$e=class{baseElement;range;ownerDocument;ignoreNodeNames;nodeReg=/(head|script|style|meta|noscript|input|img|svg|cite|button|path|defs)/i;textNodes;constructor(e,r){this.baseElement=e,this.ownerDocument=this.baseElement.ownerDocument||document,this.range=this.ownerDocument.createRange(),this.textNodes=[],this.ignoreNodeNames=r||[]}getIsTextNodeInViewport=e=>{this.range.selectNode(e);let r=this.range.getBoundingClientRect(),n=window.visualViewport,o=r.top,i=r.bottom,s=r.left,a=r.right,c=r.width>0&&r.height>0,l=i<=0,p=o>=n.height,u=s<=0,w=a>=n.width;return c&&(!l&&!p&&!u&&!w)};walkerFilter=e=>{var r,n;return this.nodeReg.test(((r=e.parentElement)==null?void 0:r.tagName)||"")||this.ignoreNodeNames.includes(((n=e.parentElement)==null?void 0:n.tagName)||"")||!e.textContent||e.textContent.trim().length<3||!this.getIsTextNodeInViewport(e)?NodeFilter.FILTER_REJECT:NodeFilter.FILTER_ACCEPT};watchScroll=e=>{let r=window.scrollY,n=(0,yt.default)(()=>{let o=r;r=window.scrollY,Cr(o,r)>.5&&window.requestAnimationFrame(s=>{window.cancelAnimationFrame(s),e(this.walk(document.body))})},500);return document.addEventListener("scroll",n,!0),n};watchDOM=e=>{let r=(i,s)=>{var a,c;for(let l of i)if(l.type==="childList"&&l.addedNodes[0]){let p=l.addedNodes[0];if(p.parentElement===null||this.nodeReg.test(((a=p.parentElement)==null?void 0:a.tagName)||"")||this.ignoreNodeNames.includes(((c=p.parentElement)==null?void 0:c.tagName)||""))return;let u=this.walk(p.parentElement);u.length>0&&e(u)}},n=new MutationObserver(r),o={attributes:!0,attributeFilter:["style"],childList:!0,characterData:!0,subtree:!0};return n==null||n.observe(document.body,o),n};endWatchDOM(e){e==null||e.disconnect()}endWatchScroll(e){document.removeEventListener("scroll",e)}walk=e=>{let r=e||document.body;this.textNodes=[];let n=this.ownerDocument.createTreeWalker(r,NodeFilter.SHOW_TEXT,this.walkerFilter.bind(this));for(;n.nextNode();)this.textNodes.push(n.currentNode);return this.textNodes}};var Sr=(t,e)=>{let r=document.createRange(),n=o=>{let i=o.textContent||"";e.getMatchIndexes(i).reverse().forEach(a=>{var l,p;let c=document.createElement(e.opts.tag);Array.isArray(e.opts.elementMethods)&&e.opts.elementMethods.forEach(([u,w])=>c[u]=w),(p=(l=e.opts).getAttrs)==null||p.call(l,a[0]).forEach(([u,w])=>c.setAttribute(u,w)),r.setStart(o,a[1]),r.setEnd(o,a[2]+1),r.surroundContents(c)})};t.forEach(n)},Tr=(t,e)=>{Sr(t,e)};var Me=ut(Xt(),1),Mn="content-card",ve="data-content-id",Nn="annotation_tooltip_opened",Yt="#content-card-arrow";function In(t){return{placement:Me.auto,modifiers:[{name:"eventListeners",enabled:!0},{name:"offset",enabled:!0,options:{offset:[0,8]}},{name:"arrow",options:{element:t}},{name:"flip",enabled:!0,options:{allowedAutoPlacements:["top","bottom"],rootBoundary:"viewport"}},{name:"preventOverflow",enabled:!0,options:{boundariesElement:"viewport"}}]}}var Ge=class extends HTMLElement{track;popperInstance;arrow;target;content;static get observedAttributes(){return[ve]}get contentId(){return this.getAttribute(ve)}constructor(){var r,n;super(),this.attachShadow({mode:"open"}),this.open=this.open.bind(this),this.close=this.close.bind(this),this.track=o=>console.log("Track method placeholder",o),this.popperInstance=null,this.content=document.querySelector(Mn),this.arrow=(n=(r=this.content)==null?void 0:r.shadowRoot)==null?void 0:n.querySelector(Yt),this.target=document.createElement("span");let e=new CSSStyleSheet;e.insertRule(':host-context([data-annotation-variant="underline"]) > span { border-bottom: solid 1px #0aa6b8}'),e.insertRule(':host-context([data-annotation-variant="none"]) > span {border-bottom: initial;pointer-events: none;}'),this.shadowRoot.adoptedStyleSheets=[e]}connectedCallback(){this.render()}attributeChangedCallback(e,r,n){r!==n&&this.render()}render(){this.shadowRoot!==null&&(!this.childNodes[0]||this.childNodes[0].textContent!==null&&(this.target.innerText=this.childNodes[0].textContent,this.shadowRoot.appendChild(this.target),this.target.addEventListener("mouseover",e=>{var r,n;e.stopPropagation(),this.open(),(r=this.content)==null||r.addEventListener("mouseover",o=>{var i;o.stopPropagation(),(i=this.content)==null||i.setAttribute("show-popper","")},{once:!0}),(n=this.content)==null||n.addEventListener("mouseleave",o=>{var i;o.stopPropagation(),(i=this.content)==null||i.removeAttribute("show-popper"),this.close()},{once:!0})}),this.target.addEventListener("mouseleave",e=>{var r;e.stopPropagation(),(r=this.content)==null||r.removeAttribute("show-popper"),this.close()})))}open(){var e,r;if(!!this.content){if(this.popperInstance!==null&&(this.popperInstance.destroy(),this.popperInstance=null),this.content.setAttribute(ve,this.contentId),this.content.getAttribute(ve)!==this.contentId){this.open();return}if(this.arrow=(r=(e=this.content)==null?void 0:e.shadowRoot)==null?void 0:r.querySelector(Yt),!this.arrow){this.open();return}this.popperInstance=(0,Me.createPopper)(this.target,this.content,In(this.arrow)),this.popperInstance.forceUpdate(),this.content.setAttribute("show-popper",""),this.track([Nn,{contentId:this.contentId||""}])}}close(){setTimeout(()=>{this.content!==null&&!this.content.hasAttribute("show-popper")&&(this.content.removeAttribute(ve),this.popperInstance!==null&&(this.popperInstance.destroy(),this.popperInstance=null))},50)}};export{De as Match,$e as TextNodesFromDOM,Ge as Tip,Tr as annotateDOM}; //# sourceMappingURL=index.js.map