@teipublisher/pb-components 3.4.1 → 3.5.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +7 -0
- package/dist/pb-components-bundle.js +11 -3
- package/dist/pb-elements.json +27 -1
- package/package.json +1 -1
- package/pb-elements.json +27 -1
- package/src/pb-highlight.js +36 -10
package/CHANGELOG.md
CHANGED
|
@@ -1,3 +1,10 @@
|
|
|
1
|
+
# [3.5.0](https://github.com/eeditiones/tei-publisher-components/compare/v3.4.1...v3.5.0) (2026-06-08)
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
### Features
|
|
5
|
+
|
|
6
|
+
* **pb-highlight:** optionally listen on click rather than mouseenter and scroll target into view if clicked ([07bdcb4](https://github.com/eeditiones/tei-publisher-components/commit/07bdcb4207d9f8d85102a0e2085a1e0b43226c62))
|
|
7
|
+
|
|
1
8
|
## [3.4.1](https://github.com/eeditiones/tei-publisher-components/compare/v3.4.0...v3.4.1) (2026-06-05)
|
|
2
9
|
|
|
3
10
|
|
|
@@ -501,7 +501,7 @@ const K=e`
|
|
|
501
501
|
border-color: #999;
|
|
502
502
|
color: #999;
|
|
503
503
|
}
|
|
504
|
-
`}}customElements.define("pb-demo-snippet",it);class nt{static subscribe(t,e,i,n=!1){const r=nt._getChannels(e),o=document.addEventListener(t,t=>{i&&t.detail&&t.detail.key&&r.includes(t.detail.key)&&i(t,o)},{once:n})}static subscribeOnce(t,e=null){const i=nt._getChannels(e);return new Promise(e=>{document.addEventListener(t,t=>{t.detail&&t.detail.key&&i.includes(t.detail.key)&&e(t)},{once:!0})})}static _getChannels(t){return null!==t&&t.length?Array.isArray(t)?t:[t]:[R]}static emit(t,e=null,i=null){const n=i||{};n.key=e||R;const r=new CustomEvent(t,{detail:n});document.dispatchEvent(r)}static ifReady(t){return Array.isArray(t)||(t=[t]),new Promise(e=>{const i=t.length;if(0===i)return void e();let n=i;t.forEach(t=>{if(t._isReady)return n-=1,void(0===n&&e());const i=t.addEventListener("pb-ready",()=>{n-=1,0===n&&(t.removeEventListener("pb-ready",i),e())})})})}}window.pbEvents||(window.pbEvents=nt);const rt="3.4.1";class ot extends I{static get properties(){return Object.assign({version:{type:String,reflect:!0}},super.properties)}constructor(){super(),this.version=rt}connectedCallback(){if(super.connectedCallback(),!this.version){const t=H("../package.json");fetch(t).then(t=>t.json()).then(t=>{this.version=t.version})}}render(){return T`<span>${this.version?this.version:"unknown"}</span>`}createRenderRoot(){return this}}customElements.define("pb-version",ot);var st="top",at="bottom",lt="right",ct="left",ht="auto",dt=[st,at,lt,ct],pt="start",ut="end",gt="clippingParents",ft="viewport",mt="popper",vt="reference",bt=dt.reduce((function(t,e){return t.concat([e+"-"+pt,e+"-"+ut])}),[]),yt=[].concat(dt,[ht]).reduce((function(t,e){return t.concat([e,e+"-"+pt,e+"-"+ut])}),[]),_t=["beforeRead","read","afterRead","beforeMain","main","afterMain","beforeWrite","write","afterWrite"];function wt(t){return t?(t.nodeName||"").toLowerCase():null}function xt(t){if(null==t)return window;if("[object Window]"!==t.toString()){var e=t.ownerDocument;return e&&e.defaultView||window}return t}function kt(t){return t instanceof xt(t).Element||t instanceof Element}function At(t){return t instanceof xt(t).HTMLElement||t instanceof HTMLElement}function St(t){return"undefined"!=typeof ShadowRoot&&(t instanceof xt(t).ShadowRoot||t instanceof ShadowRoot)}function zt(t){var e=t.state;Object.keys(e.elements).forEach((function(t){var i=e.styles[t]||{},n=e.attributes[t]||{},r=e.elements[t];At(r)&&wt(r)&&(Object.assign(r.style,i),Object.keys(n).forEach((function(t){var e=n[t];!1===e?r.removeAttribute(t):r.setAttribute(t,!0===e?"":e)})))}))}function Ct(t){var e=t.state,i={popper:{position:e.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};return Object.assign(e.elements.popper.style,i.popper),e.styles=i,e.elements.arrow&&Object.assign(e.elements.arrow.style,i.arrow),function(){Object.keys(e.elements).forEach((function(t){var n=e.elements[t],r=e.attributes[t]||{},o=Object.keys(e.styles.hasOwnProperty(t)?e.styles[t]:i[t]).reduce((function(t,e){return t[e]="",t}),{});At(n)&&wt(n)&&(Object.assign(n.style,o),Object.keys(r).forEach((function(t){n.removeAttribute(t)})))}))}}var Et={name:"applyStyles",enabled:!0,phase:"write",fn:zt,effect:Ct,requires:["computeStyles"]};function Lt(t){return t.split("-")[0]}var Mt=Math.max,Tt=Math.min,Ot=Math.round;function $t(){var t=navigator.userAgentData;return null!=t&&t.brands&&Array.isArray(t.brands)?t.brands.map((function(t){return t.brand+"/"+t.version})).join(" "):navigator.userAgent}function Ht(){return!/^((?!chrome|android).)*safari/i.test($t())}function It(t,e,i){void 0===e&&(e=!1),void 0===i&&(i=!1);var n=t.getBoundingClientRect(),r=1,o=1;e&&At(t)&&(r=t.offsetWidth>0&&Ot(n.width)/t.offsetWidth||1,o=t.offsetHeight>0&&Ot(n.height)/t.offsetHeight||1);var s=(kt(t)?xt(t):window).visualViewport,a=!Ht()&&i,l=(n.left+(a&&s?s.offsetLeft:0))/r,c=(n.top+(a&&s?s.offsetTop:0))/o,h=n.width/r,d=n.height/o;return{width:h,height:d,top:c,right:l+h,bottom:c+d,left:l,x:l,y:c}}function Rt(t){var e=It(t),i=t.offsetWidth,n=t.offsetHeight;return Math.abs(e.width-i)<=1&&(i=e.width),Math.abs(e.height-n)<=1&&(n=e.height),{x:t.offsetLeft,y:t.offsetTop,width:i,height:n}}function Pt(t,e){var i=e.getRootNode&&e.getRootNode();if(t.contains(e))return!0;if(i&&St(i)){var n=e;do{if(n&&t.isSameNode(n))return!0;n=n.parentNode||n.host}while(n)}return!1}function Vt(t){return xt(t).getComputedStyle(t)}function Ft(t){return["table","td","th"].indexOf(wt(t))>=0}function Nt(t){return((kt(t)?t.ownerDocument:t.document)||window.document).documentElement}function Dt(t){return"html"===wt(t)?t:t.assignedSlot||t.parentNode||(St(t)?t.host:null)||Nt(t)}function jt(t){return At(t)&&"fixed"!==Vt(t).position?t.offsetParent:null}function Bt(t){var e=/firefox/i.test($t());if(/Trident/i.test($t())&&At(t)&&"fixed"===Vt(t).position)return null;var i=Dt(t);for(St(i)&&(i=i.host);At(i)&&["html","body"].indexOf(wt(i))<0;){var n=Vt(i);if("none"!==n.transform||"none"!==n.perspective||"paint"===n.contain||-1!==["transform","perspective"].indexOf(n.willChange)||e&&"filter"===n.willChange||e&&n.filter&&"none"!==n.filter)return i;i=i.parentNode}return null}function qt(t){for(var e=xt(t),i=jt(t);i&&Ft(i)&&"static"===Vt(i).position;)i=jt(i);return i&&("html"===wt(i)||"body"===wt(i)&&"static"===Vt(i).position)?e:i||Bt(t)||e}function Ut(t){return["top","bottom"].indexOf(t)>=0?"x":"y"}function Wt(t,e,i){return Mt(t,Tt(e,i))}function Yt(t,e,i){var n=Wt(t,e,i);return n>i?i:n}function Gt(){return{top:0,right:0,bottom:0,left:0}}function Zt(t){return Object.assign({},Gt(),t)}function Kt(t,e){return e.reduce((function(e,i){return e[i]=t,e}),{})}var Qt=function(t,e){return Zt("number"!=typeof(t="function"==typeof t?t(Object.assign({},e.rects,{placement:e.placement})):t)?t:Kt(t,dt))};function Jt(t){var e,i=t.state,n=t.name,r=t.options,o=i.elements.arrow,s=i.modifiersData.popperOffsets,a=Lt(i.placement),l=Ut(a),c=[ct,lt].indexOf(a)>=0?"height":"width";if(o&&s){var h=Qt(r.padding,i),d=Rt(o),p="y"===l?st:ct,u="y"===l?at:lt,g=i.rects.reference[c]+i.rects.reference[l]-s[l]-i.rects.popper[c],f=s[l]-i.rects.reference[l],m=qt(o),v=m?"y"===l?m.clientHeight||0:m.clientWidth||0:0,b=g/2-f/2,y=h[p],_=v-d[c]-h[u],w=v/2-d[c]/2+b,x=Wt(y,w,_),k=l;i.modifiersData[n]=((e={})[k]=x,e.centerOffset=x-w,e)}}function Xt(t){var e=t.state,i=t.options.element,n=void 0===i?"[data-popper-arrow]":i;null!=n&&("string"!=typeof n||(n=e.elements.popper.querySelector(n)))&&Pt(e.elements.popper,n)&&(e.elements.arrow=n)}function te(t){return t.split("-")[1]}var ee={top:"auto",right:"auto",bottom:"auto",left:"auto"};function ie(t,e){var i=t.x,n=t.y,r=e.devicePixelRatio||1;return{x:Ot(i*r)/r||0,y:Ot(n*r)/r||0}}function ne(t){var e,i=t.popper,n=t.popperRect,r=t.placement,o=t.variation,s=t.offsets,a=t.position,l=t.gpuAcceleration,c=t.adaptive,h=t.roundOffsets,d=t.isFixed,p=s.x,u=void 0===p?0:p,g=s.y,f=void 0===g?0:g,m="function"==typeof h?h({x:u,y:f}):{x:u,y:f};u=m.x,f=m.y;var v=s.hasOwnProperty("x"),b=s.hasOwnProperty("y"),y=ct,_=st,w=window;if(c){var x=qt(i),k="clientHeight",A="clientWidth";if(x===xt(i)&&"static"!==Vt(x=Nt(i)).position&&"absolute"===a&&(k="scrollHeight",A="scrollWidth"),x=x,r===st||(r===ct||r===lt)&&o===ut)_=at,f-=(d&&x===w&&w.visualViewport?w.visualViewport.height:x[k])-n.height,f*=l?1:-1;if(r===ct||(r===st||r===at)&&o===ut)y=lt,u-=(d&&x===w&&w.visualViewport?w.visualViewport.width:x[A])-n.width,u*=l?1:-1}var S,z=Object.assign({position:a},c&&ee),C=!0===h?ie({x:u,y:f},xt(i)):{x:u,y:f};return u=C.x,f=C.y,l?Object.assign({},z,((S={})[_]=b?"0":"",S[y]=v?"0":"",S.transform=(w.devicePixelRatio||1)<=1?"translate("+u+"px, "+f+"px)":"translate3d("+u+"px, "+f+"px, 0)",S)):Object.assign({},z,((e={})[_]=b?f+"px":"",e[y]=v?u+"px":"",e.transform="",e))}function re(t){var e=t.state,i=t.options,n=i.gpuAcceleration,r=void 0===n||n,o=i.adaptive,s=void 0===o||o,a=i.roundOffsets,l=void 0===a||a,c={placement:Lt(e.placement),variation:te(e.placement),popper:e.elements.popper,popperRect:e.rects.popper,gpuAcceleration:r,isFixed:"fixed"===e.options.strategy};null!=e.modifiersData.popperOffsets&&(e.styles.popper=Object.assign({},e.styles.popper,ne(Object.assign({},c,{offsets:e.modifiersData.popperOffsets,position:e.options.strategy,adaptive:s,roundOffsets:l})))),null!=e.modifiersData.arrow&&(e.styles.arrow=Object.assign({},e.styles.arrow,ne(Object.assign({},c,{offsets:e.modifiersData.arrow,position:"absolute",adaptive:!1,roundOffsets:l})))),e.attributes.popper=Object.assign({},e.attributes.popper,{"data-popper-placement":e.placement})}var oe={passive:!0};function se(t){var e=t.state,i=t.instance,n=t.options,r=n.scroll,o=void 0===r||r,s=n.resize,a=void 0===s||s,l=xt(e.elements.popper),c=[].concat(e.scrollParents.reference,e.scrollParents.popper);return o&&c.forEach((function(t){t.addEventListener("scroll",i.update,oe)})),a&&l.addEventListener("resize",i.update,oe),function(){o&&c.forEach((function(t){t.removeEventListener("scroll",i.update,oe)})),a&&l.removeEventListener("resize",i.update,oe)}}var ae={left:"right",right:"left",bottom:"top",top:"bottom"};function le(t){return t.replace(/left|right|bottom|top/g,(function(t){return ae[t]}))}var ce={start:"end",end:"start"};function he(t){return t.replace(/start|end/g,(function(t){return ce[t]}))}function de(t){var e=xt(t);return{scrollLeft:e.pageXOffset,scrollTop:e.pageYOffset}}function pe(t){return It(Nt(t)).left+de(t).scrollLeft}function ue(t,e){var i=xt(t),n=Nt(t),r=i.visualViewport,o=n.clientWidth,s=n.clientHeight,a=0,l=0;if(r){o=r.width,s=r.height;var c=Ht();(c||!c&&"fixed"===e)&&(a=r.offsetLeft,l=r.offsetTop)}return{width:o,height:s,x:a+pe(t),y:l}}function ge(t){var e,i=Nt(t),n=de(t),r=null==(e=t.ownerDocument)?void 0:e.body,o=Mt(i.scrollWidth,i.clientWidth,r?r.scrollWidth:0,r?r.clientWidth:0),s=Mt(i.scrollHeight,i.clientHeight,r?r.scrollHeight:0,r?r.clientHeight:0),a=-n.scrollLeft+pe(t),l=-n.scrollTop;return"rtl"===Vt(r||i).direction&&(a+=Mt(i.clientWidth,r?r.clientWidth:0)-o),{width:o,height:s,x:a,y:l}}function fe(t){var e=Vt(t),i=e.overflow,n=e.overflowX,r=e.overflowY;return/auto|scroll|overlay|hidden/.test(i+r+n)}function me(t){return["html","body","#document"].indexOf(wt(t))>=0?t.ownerDocument.body:At(t)&&fe(t)?t:me(Dt(t))}function ve(t,e){var i;void 0===e&&(e=[]);var n=me(t),r=n===(null==(i=t.ownerDocument)?void 0:i.body),o=xt(n),s=r?[o].concat(o.visualViewport||[],fe(n)?n:[]):n,a=e.concat(s);return r?a:a.concat(ve(Dt(s)))}function be(t){return Object.assign({},t,{left:t.x,top:t.y,right:t.x+t.width,bottom:t.y+t.height})}function ye(t,e){var i=It(t,!1,"fixed"===e);return i.top=i.top+t.clientTop,i.left=i.left+t.clientLeft,i.bottom=i.top+t.clientHeight,i.right=i.left+t.clientWidth,i.width=t.clientWidth,i.height=t.clientHeight,i.x=i.left,i.y=i.top,i}function _e(t,e,i){return e===ft?be(ue(t,i)):kt(e)?ye(e,i):be(ge(Nt(t)))}function we(t){var e=ve(Dt(t)),i=["absolute","fixed"].indexOf(Vt(t).position)>=0&&At(t)?qt(t):t;return kt(i)?e.filter((function(t){return kt(t)&&Pt(t,i)&&"body"!==wt(t)})):[]}function xe(t,e,i,n){var r="clippingParents"===e?we(t):[].concat(e),o=[].concat(r,[i]),s=o[0],a=o.reduce((function(e,i){var r=_e(t,i,n);return e.top=Mt(r.top,e.top),e.right=Tt(r.right,e.right),e.bottom=Tt(r.bottom,e.bottom),e.left=Mt(r.left,e.left),e}),_e(t,s,n));return a.width=a.right-a.left,a.height=a.bottom-a.top,a.x=a.left,a.y=a.top,a}function ke(t){var e,i=t.reference,n=t.element,r=t.placement,o=r?Lt(r):null,s=r?te(r):null,a=i.x+i.width/2-n.width/2,l=i.y+i.height/2-n.height/2;switch(o){case st:e={x:a,y:i.y-n.height};break;case at:e={x:a,y:i.y+i.height};break;case lt:e={x:i.x+i.width,y:l};break;case ct:e={x:i.x-n.width,y:l};break;default:e={x:i.x,y:i.y}}var c=o?Ut(o):null;if(null!=c){var h="y"===c?"height":"width";switch(s){case pt:e[c]=e[c]-(i[h]/2-n[h]/2);break;case ut:e[c]=e[c]+(i[h]/2-n[h]/2)}}return e}function Ae(t,e){void 0===e&&(e={});var i=e,n=i.placement,r=void 0===n?t.placement:n,o=i.strategy,s=void 0===o?t.strategy:o,a=i.boundary,l=void 0===a?gt:a,c=i.rootBoundary,h=void 0===c?ft:c,d=i.elementContext,p=void 0===d?mt:d,u=i.altBoundary,g=void 0!==u&&u,f=i.padding,m=void 0===f?0:f,v=Zt("number"!=typeof m?m:Kt(m,dt)),b=p===mt?vt:mt,y=t.rects.popper,_=t.elements[g?b:p],w=xe(kt(_)?_:_.contextElement||Nt(t.elements.popper),l,h,s),x=It(t.elements.reference),k=ke({reference:x,element:y,strategy:"absolute",placement:r}),A=be(Object.assign({},y,k)),S=p===mt?A:x,z={top:w.top-S.top+v.top,bottom:S.bottom-w.bottom+v.bottom,left:w.left-S.left+v.left,right:S.right-w.right+v.right},C=t.modifiersData.offset;if(p===mt&&C){var E=C[r];Object.keys(z).forEach((function(t){var e=[lt,at].indexOf(t)>=0?1:-1,i=[st,at].indexOf(t)>=0?"y":"x";z[t]+=E[i]*e}))}return z}function Se(t,e){void 0===e&&(e={});var i=e,n=i.placement,r=i.boundary,o=i.rootBoundary,s=i.padding,a=i.flipVariations,l=i.allowedAutoPlacements,c=void 0===l?yt:l,h=te(n),d=h?a?bt:bt.filter((function(t){return te(t)===h})):dt,p=d.filter((function(t){return c.indexOf(t)>=0}));0===p.length&&(p=d);var u=p.reduce((function(e,i){return e[i]=Ae(t,{placement:i,boundary:r,rootBoundary:o,padding:s})[Lt(i)],e}),{});return Object.keys(u).sort((function(t,e){return u[t]-u[e]}))}function ze(t){if(Lt(t)===ht)return[];var e=le(t);return[he(t),e,he(e)]}function Ce(t){var e=t.state,i=t.options,n=t.name;if(!e.modifiersData[n]._skip){for(var r=i.mainAxis,o=void 0===r||r,s=i.altAxis,a=void 0===s||s,l=i.fallbackPlacements,c=i.padding,h=i.boundary,d=i.rootBoundary,p=i.altBoundary,u=i.flipVariations,g=void 0===u||u,f=i.allowedAutoPlacements,m=e.options.placement,v=Lt(m),b=l||(v===m||!g?[le(m)]:ze(m)),y=[m].concat(b).reduce((function(t,i){return t.concat(Lt(i)===ht?Se(e,{placement:i,boundary:h,rootBoundary:d,padding:c,flipVariations:g,allowedAutoPlacements:f}):i)}),[]),_=e.rects.reference,w=e.rects.popper,x=new Map,k=!0,A=y[0],S=0;S<y.length;S++){var z=y[S],C=Lt(z),E=te(z)===pt,L=[st,at].indexOf(C)>=0,M=L?"width":"height",T=Ae(e,{placement:z,boundary:h,rootBoundary:d,altBoundary:p,padding:c}),O=L?E?lt:ct:E?at:st;_[M]>w[M]&&(O=le(O));var $=le(O),H=[];if(o&&H.push(T[C]<=0),a&&H.push(T[O]<=0,T[$]<=0),H.every((function(t){return t}))){A=z,k=!1;break}x.set(z,H)}if(k)for(var I=function(t){var e=y.find((function(e){var i=x.get(e);if(i)return i.slice(0,t).every((function(t){return t}))}));if(e)return A=e,"break"},R=g?3:1;R>0;R--){if("break"===I(R))break}e.placement!==A&&(e.modifiersData[n]._skip=!0,e.placement=A,e.reset=!0)}}function Ee(t,e,i){return void 0===i&&(i={x:0,y:0}),{top:t.top-e.height-i.y,right:t.right-e.width+i.x,bottom:t.bottom-e.height+i.y,left:t.left-e.width-i.x}}function Le(t){return[st,lt,at,ct].some((function(e){return t[e]>=0}))}function Me(t){var e=t.state,i=t.name,n=e.rects.reference,r=e.rects.popper,o=e.modifiersData.preventOverflow,s=Ae(e,{elementContext:"reference"}),a=Ae(e,{altBoundary:!0}),l=Ee(s,n),c=Ee(a,r,o),h=Le(l),d=Le(c);e.modifiersData[i]={referenceClippingOffsets:l,popperEscapeOffsets:c,isReferenceHidden:h,hasPopperEscaped:d},e.attributes.popper=Object.assign({},e.attributes.popper,{"data-popper-reference-hidden":h,"data-popper-escaped":d})}function Te(t,e,i){var n=Lt(t),r=[ct,st].indexOf(n)>=0?-1:1,o="function"==typeof i?i(Object.assign({},e,{placement:t})):i,s=o[0],a=o[1];return s=s||0,a=(a||0)*r,[ct,lt].indexOf(n)>=0?{x:a,y:s}:{x:s,y:a}}function Oe(t){var e=t.state,i=t.options,n=t.name,r=i.offset,o=void 0===r?[0,0]:r,s=yt.reduce((function(t,i){return t[i]=Te(i,e.rects,o),t}),{}),a=s[e.placement],l=a.x,c=a.y;null!=e.modifiersData.popperOffsets&&(e.modifiersData.popperOffsets.x+=l,e.modifiersData.popperOffsets.y+=c),e.modifiersData[n]=s}function $e(t){var e=t.state,i=t.name;e.modifiersData[i]=ke({reference:e.rects.reference,element:e.rects.popper,strategy:"absolute",placement:e.placement})}function He(t){return"x"===t?"y":"x"}function Ie(t){var e=t.state,i=t.options,n=t.name,r=i.mainAxis,o=void 0===r||r,s=i.altAxis,a=void 0!==s&&s,l=i.boundary,c=i.rootBoundary,h=i.altBoundary,d=i.padding,p=i.tether,u=void 0===p||p,g=i.tetherOffset,f=void 0===g?0:g,m=Ae(e,{boundary:l,rootBoundary:c,padding:d,altBoundary:h}),v=Lt(e.placement),b=te(e.placement),y=!b,_=Ut(v),w=He(_),x=e.modifiersData.popperOffsets,k=e.rects.reference,A=e.rects.popper,S="function"==typeof f?f(Object.assign({},e.rects,{placement:e.placement})):f,z="number"==typeof S?{mainAxis:S,altAxis:S}:Object.assign({mainAxis:0,altAxis:0},S),C=e.modifiersData.offset?e.modifiersData.offset[e.placement]:null,E={x:0,y:0};if(x){if(o){var L,M="y"===_?st:ct,T="y"===_?at:lt,O="y"===_?"height":"width",$=x[_],H=$+m[M],I=$-m[T],R=u?-A[O]/2:0,P=b===pt?k[O]:A[O],V=b===pt?-A[O]:-k[O],F=e.elements.arrow,N=u&&F?Rt(F):{width:0,height:0},D=e.modifiersData["arrow#persistent"]?e.modifiersData["arrow#persistent"].padding:Gt(),j=D[M],B=D[T],q=Wt(0,k[O],N[O]),U=y?k[O]/2-R-q-j-z.mainAxis:P-q-j-z.mainAxis,W=y?-k[O]/2+R+q+B+z.mainAxis:V+q+B+z.mainAxis,Y=e.elements.arrow&&qt(e.elements.arrow),G=Y?"y"===_?Y.clientTop||0:Y.clientLeft||0:0,Z=null!=(L=null==C?void 0:C[_])?L:0,K=$+W-Z,Q=Wt(u?Tt(H,$+U-Z-G):H,$,u?Mt(I,K):I);x[_]=Q,E[_]=Q-$}if(a){var J,X="x"===_?st:ct,tt="x"===_?at:lt,et=x[w],it="y"===w?"height":"width",nt=et+m[X],rt=et-m[tt],ot=-1!==[st,ct].indexOf(v),ht=null!=(J=null==C?void 0:C[w])?J:0,dt=ot?nt:et-k[it]-A[it]-ht+z.altAxis,ut=ot?et+k[it]+A[it]-ht-z.altAxis:rt,gt=u&&ot?Yt(dt,et,ut):Wt(u?dt:nt,et,u?ut:rt);x[w]=gt,E[w]=gt-et}e.modifiersData[n]=E}}function Re(t){return{scrollLeft:t.scrollLeft,scrollTop:t.scrollTop}}function Pe(t){return t!==xt(t)&&At(t)?Re(t):de(t)}function Ve(t){var e=t.getBoundingClientRect(),i=Ot(e.width)/t.offsetWidth||1,n=Ot(e.height)/t.offsetHeight||1;return 1!==i||1!==n}function Fe(t,e,i){void 0===i&&(i=!1);var n=At(e),r=At(e)&&Ve(e),o=Nt(e),s=It(t,r,i),a={scrollLeft:0,scrollTop:0},l={x:0,y:0};return(n||!n&&!i)&&(("body"!==wt(e)||fe(o))&&(a=Pe(e)),At(e)?((l=It(e,!0)).x+=e.clientLeft,l.y+=e.clientTop):o&&(l.x=pe(o))),{x:s.left+a.scrollLeft-l.x,y:s.top+a.scrollTop-l.y,width:s.width,height:s.height}}function Ne(t){var e=new Map,i=new Set,n=[];function r(t){i.add(t.name),[].concat(t.requires||[],t.requiresIfExists||[]).forEach((function(t){if(!i.has(t)){var n=e.get(t);n&&r(n)}})),n.push(t)}return t.forEach((function(t){e.set(t.name,t)})),t.forEach((function(t){i.has(t.name)||r(t)})),n}function De(t){var e=Ne(t);return _t.reduce((function(t,i){return t.concat(e.filter((function(t){return t.phase===i})))}),[])}function je(t){var e;return function(){return e||(e=new Promise((function(i){Promise.resolve().then((function(){e=void 0,i(t())}))}))),e}}function Be(t){var e=t.reduce((function(t,e){var i=t[e.name];return t[e.name]=i?Object.assign({},i,e,{options:Object.assign({},i.options,e.options),data:Object.assign({},i.data,e.data)}):e,t}),{});return Object.keys(e).map((function(t){return e[t]}))}var qe={placement:"bottom",modifiers:[],strategy:"absolute"};function Ue(){for(var t=arguments.length,e=new Array(t),i=0;i<t;i++)e[i]=arguments[i];return!e.some((function(t){return!(t&&"function"==typeof t.getBoundingClientRect)}))}function We(t){void 0===t&&(t={});var e=t,i=e.defaultModifiers,n=void 0===i?[]:i,r=e.defaultOptions,o=void 0===r?qe:r;return function(t,e,i){void 0===i&&(i=o);var r={placement:"bottom",orderedModifiers:[],options:Object.assign({},qe,o),modifiersData:{},elements:{reference:t,popper:e},attributes:{},styles:{}},s=[],a=!1,l={state:r,setOptions:function(i){var s="function"==typeof i?i(r.options):i;h(),r.options=Object.assign({},o,r.options,s),r.scrollParents={reference:kt(t)?ve(t):t.contextElement?ve(t.contextElement):[],popper:ve(e)};var a=De(Be([].concat(n,r.options.modifiers)));return r.orderedModifiers=a.filter((function(t){return t.enabled})),c(),l.update()},forceUpdate:function(){if(!a){var t=r.elements,e=t.reference,i=t.popper;if(Ue(e,i)){r.rects={reference:Fe(e,qt(i),"fixed"===r.options.strategy),popper:Rt(i)},r.reset=!1,r.placement=r.options.placement,r.orderedModifiers.forEach((function(t){return r.modifiersData[t.name]=Object.assign({},t.data)}));for(var n=0;n<r.orderedModifiers.length;n++)if(!0!==r.reset){var o=r.orderedModifiers[n],s=o.fn,c=o.options,h=void 0===c?{}:c,d=o.name;"function"==typeof s&&(r=s({state:r,options:h,name:d,instance:l})||r)}else r.reset=!1,n=-1}}},update:je((function(){return new Promise((function(t){l.forceUpdate(),t(r)}))})),destroy:function(){h(),a=!0}};if(!Ue(t,e))return l;function c(){r.orderedModifiers.forEach((function(t){var e=t.name,i=t.options,n=void 0===i?{}:i,o=t.effect;if("function"==typeof o){var a=o({state:r,name:e,instance:l,options:n}),c=function(){};s.push(a||c)}}))}function h(){s.forEach((function(t){return t()})),s=[]}return l.setOptions(i).then((function(t){!a&&i.onFirstUpdate&&i.onFirstUpdate(t)})),l}}var Ye=We({defaultModifiers:[{name:"eventListeners",enabled:!0,phase:"write",fn:function(){},effect:se,data:{}},{name:"popperOffsets",enabled:!0,phase:"read",fn:$e,data:{}},{name:"computeStyles",enabled:!0,phase:"beforeWrite",fn:re,data:{}},Et,{name:"offset",enabled:!0,phase:"main",requires:["popperOffsets"],fn:Oe},{name:"flip",enabled:!0,phase:"main",fn:Ce,requiresIfExists:["offset"],data:{_skip:!1}},{name:"preventOverflow",enabled:!0,phase:"main",fn:Ie,requiresIfExists:["offset"]},{name:"arrow",enabled:!0,phase:"main",fn:Jt,effect:Xt,requires:["popperOffsets"],requiresIfExists:["preventOverflow"]},{name:"hide",enabled:!0,phase:"main",requiresIfExists:["preventOverflow"],fn:Me}]}),Ge="tippy-box",Ze="tippy-content",Ke="tippy-backdrop",Qe="tippy-arrow",Je="tippy-svg-arrow",Xe={passive:!0,capture:!0},ti=function(){return document.body};function ei(t,e,i){if(Array.isArray(t)){var n=t[e];return null==n?Array.isArray(i)?i[e]:i:n}return t}function ii(t,e){var i={}.toString.call(t);return 0===i.indexOf("[object")&&i.indexOf(e+"]")>-1}function ni(t,e){return"function"==typeof t?t.apply(void 0,e):t}function ri(t,e){return 0===e?t:function(n){clearTimeout(i),i=setTimeout((function(){t(n)}),e)};var i}function oi(t){return t.split(/\s+/).filter(Boolean)}function si(t){return[].concat(t)}function ai(t,e){-1===t.indexOf(e)&&t.push(e)}function li(t){return t.filter((function(e,i){return t.indexOf(e)===i}))}function ci(t){return t.split("-")[0]}function hi(t){return[].slice.call(t)}function di(t){return Object.keys(t).reduce((function(e,i){return void 0!==t[i]&&(e[i]=t[i]),e}),{})}function pi(){return document.createElement("div")}function ui(t){return["Element","Fragment"].some((function(e){return ii(t,e)}))}function gi(t){return ii(t,"NodeList")}function fi(t){return ii(t,"MouseEvent")}function mi(t){return!(!t||!t._tippy||t._tippy.reference!==t)}function vi(t){return ui(t)?[t]:gi(t)?hi(t):Array.isArray(t)?t:hi(document.querySelectorAll(t))}function bi(t,e){t.forEach((function(t){t&&(t.style.transitionDuration=e+"ms")}))}function yi(t,e){t.forEach((function(t){t&&t.setAttribute("data-state",e)}))}function _i(t){var e,i=si(t)[0];return null!=i&&null!=(e=i.ownerDocument)&&e.body?i.ownerDocument:document}function wi(t,e){var i=e.clientX,n=e.clientY;return t.every((function(t){var e=t.popperRect,r=t.popperState,o=t.props.interactiveBorder,s=ci(r.placement),a=r.modifiersData.offset;if(!a)return!0;var l="bottom"===s?a.top.y:0,c="top"===s?a.bottom.y:0,h="right"===s?a.left.x:0,d="left"===s?a.right.x:0,p=e.top-n+l>o,u=n-e.bottom-c>o,g=e.left-i+h>o,f=i-e.right-d>o;return p||u||g||f}))}function xi(t,e,i){var n=e+"EventListener";["transitionend","webkitTransitionEnd"].forEach((function(e){t[n](e,i)}))}function ki(t,e){for(var i=e;i;){var n;if(t.contains(i))return!0;i=null==i.getRootNode||null==(n=i.getRootNode())?void 0:n.host}return!1}var Ai={isTouch:!1},Si=0;function zi(){Ai.isTouch||(Ai.isTouch=!0,window.performance&&document.addEventListener("mousemove",Ci))}function Ci(){var t=performance.now();t-Si<20&&(Ai.isTouch=!1,document.removeEventListener("mousemove",Ci)),Si=t}function Ei(){var t=document.activeElement;if(mi(t)){var e=t._tippy;t.blur&&!e.state.isVisible&&t.blur()}}function Li(){document.addEventListener("touchstart",zi,Xe),window.addEventListener("blur",Ei)}var Mi=!!("undefined"!=typeof window&&"undefined"!=typeof document)&&!!window.msCrypto,Ti={animateFill:!1,followCursor:!1,inlinePositioning:!1,sticky:!1},Oi={allowHTML:!1,animation:"fade",arrow:!0,content:"",inertia:!1,maxWidth:350,role:"tooltip",theme:"",zIndex:9999},$i=Object.assign({appendTo:ti,aria:{content:"auto",expanded:"auto"},delay:0,duration:[300,250],getReferenceClientRect:null,hideOnClick:!0,ignoreAttributes:!1,interactive:!1,interactiveBorder:2,interactiveDebounce:0,moveTransition:"",offset:[0,10],onAfterUpdate:function(){},onBeforeUpdate:function(){},onCreate:function(){},onDestroy:function(){},onHidden:function(){},onHide:function(){},onMount:function(){},onShow:function(){},onShown:function(){},onTrigger:function(){},onUntrigger:function(){},onClickOutside:function(){},placement:"top",plugins:[],popperOptions:{},render:null,showOnCreate:!1,touch:!0,trigger:"mouseenter focus",triggerTarget:null},Ti,Oi),Hi=Object.keys($i),Ii=function(t){Object.keys(t).forEach((function(e){$i[e]=t[e]}))};function Ri(t){var e=(t.plugins||[]).reduce((function(e,i){var n,r=i.name,o=i.defaultValue;r&&(e[r]=void 0!==t[r]?t[r]:null!=(n=$i[r])?n:o);return e}),{});return Object.assign({},t,e)}function Pi(t,e){return(e?Object.keys(Ri(Object.assign({},$i,{plugins:e}))):Hi).reduce((function(e,i){var n=(t.getAttribute("data-tippy-"+i)||"").trim();if(!n)return e;if("content"===i)e[i]=n;else try{e[i]=JSON.parse(n)}catch(t){e[i]=n}return e}),{})}function Vi(t,e){var i=Object.assign({},e,{content:ni(e.content,[t])},e.ignoreAttributes?{}:Pi(t,e.plugins));return i.aria=Object.assign({},$i.aria,i.aria),i.aria={expanded:"auto"===i.aria.expanded?e.interactive:i.aria.expanded,content:"auto"===i.aria.content?e.interactive?null:"describedby":i.aria.content},i}var Fi=function(){return"innerHTML"};function Ni(t,e){t[Fi()]=e}function Di(t){var e=pi();return!0===t?e.className=Qe:(e.className=Je,ui(t)?e.appendChild(t):Ni(e,t)),e}function ji(t,e){ui(e.content)?(Ni(t,""),t.appendChild(e.content)):"function"!=typeof e.content&&(e.allowHTML?Ni(t,e.content):t.textContent=e.content)}function Bi(t){var e=t.firstElementChild,i=hi(e.children);return{box:e,content:i.find((function(t){return t.classList.contains(Ze)})),arrow:i.find((function(t){return t.classList.contains(Qe)||t.classList.contains(Je)})),backdrop:i.find((function(t){return t.classList.contains(Ke)}))}}function qi(t){var e=pi(),i=pi();i.className=Ge,i.setAttribute("data-state","hidden"),i.setAttribute("tabindex","-1");var n=pi();function r(i,n){var r=Bi(e),o=r.box,s=r.content,a=r.arrow;n.theme?o.setAttribute("data-theme",n.theme):o.removeAttribute("data-theme"),"string"==typeof n.animation?o.setAttribute("data-animation",n.animation):o.removeAttribute("data-animation"),n.inertia?o.setAttribute("data-inertia",""):o.removeAttribute("data-inertia"),o.style.maxWidth="number"==typeof n.maxWidth?n.maxWidth+"px":n.maxWidth,n.role?o.setAttribute("role",n.role):o.removeAttribute("role"),i.content===n.content&&i.allowHTML===n.allowHTML||ji(s,t.props),n.arrow?a?i.arrow!==n.arrow&&(o.removeChild(a),o.appendChild(Di(n.arrow))):o.appendChild(Di(n.arrow)):a&&o.removeChild(a)}return n.className=Ze,n.setAttribute("data-state","hidden"),ji(n,t.props),e.appendChild(i),i.appendChild(n),r(t.props,t.props),{popper:e,onUpdate:r}}qi.$$tippy=!0;var Ui=1,Wi=[],Yi=[];function Gi(t,e){var i,n,r,o,s,a,l,c=Vi(t,Object.assign({},$i,Ri(di(e)))),h=!1,d=!1,p=!1,u=!1,g=[],f=ri(K,c.interactiveDebounce),m=Ui++,v=null,b=li(c.plugins),y={isEnabled:!0,isVisible:!1,isDestroyed:!1,isMounted:!1,isShown:!1},_={id:m,reference:t,popper:pi(),popperInstance:v,props:c,state:y,plugins:b,clearDelayTimeouts:lt,setProps:ct,setContent:ht,show:dt,hide:pt,hideWithInteractivity:ut,enable:st,disable:at,unmount:gt,destroy:ft};if(!c.render)return _;var w=c.render(_),x=w.popper,k=w.onUpdate;x.setAttribute("data-tippy-root",""),x.id="tippy-"+_.id,_.popper=x,t._tippy=_,x._tippy=_;var A=b.map((function(t){return t.fn(_)})),S=t.hasAttribute("aria-expanded");return Y(),R(),$(),H("onCreate",[_]),c.showOnCreate&&rt(),x.addEventListener("mouseenter",(function(){_.props.interactive&&_.state.isVisible&&_.clearDelayTimeouts()})),x.addEventListener("mouseleave",(function(){_.props.interactive&&_.props.trigger.indexOf("mouseenter")>=0&&M().addEventListener("mousemove",f)})),_;function z(){var t=_.props.touch;return Array.isArray(t)?t:[t,0]}function C(){return"hold"===z()[0]}function E(){var t;return!(null==(t=_.props.render)||!t.$$tippy)}function L(){return l||t}function M(){var t=L().parentNode;return t?_i(t):document}function T(){return Bi(x)}function O(t){return _.state.isMounted&&!_.state.isVisible||Ai.isTouch||o&&"focus"===o.type?0:ei(_.props.delay,t?0:1,$i.delay)}function $(t){void 0===t&&(t=!1),x.style.pointerEvents=_.props.interactive&&!t?"":"none",x.style.zIndex=""+_.props.zIndex}function H(t,e,i){var n;(void 0===i&&(i=!0),A.forEach((function(i){i[t]&&i[t].apply(i,e)})),i)&&(n=_.props)[t].apply(n,e)}function I(){var e=_.props.aria;if(e.content){var i="aria-"+e.content,n=x.id;si(_.props.triggerTarget||t).forEach((function(t){var e=t.getAttribute(i);if(_.state.isVisible)t.setAttribute(i,e?e+" "+n:n);else{var r=e&&e.replace(n,"").trim();r?t.setAttribute(i,r):t.removeAttribute(i)}}))}}function R(){!S&&_.props.aria.expanded&&si(_.props.triggerTarget||t).forEach((function(t){_.props.interactive?t.setAttribute("aria-expanded",_.state.isVisible&&t===L()?"true":"false"):t.removeAttribute("aria-expanded")}))}function P(){M().removeEventListener("mousemove",f),Wi=Wi.filter((function(t){return t!==f}))}function V(e){if(!Ai.isTouch||!p&&"mousedown"!==e.type){var i=e.composedPath&&e.composedPath()[0]||e.target;if(!_.props.interactive||!ki(x,i)){if(si(_.props.triggerTarget||t).some((function(t){return ki(t,i)}))){if(Ai.isTouch)return;if(_.state.isVisible&&_.props.trigger.indexOf("click")>=0)return}else H("onClickOutside",[_,e]);!0===_.props.hideOnClick&&(_.clearDelayTimeouts(),_.hide(),d=!0,setTimeout((function(){d=!1})),_.state.isMounted||j())}}}function F(){p=!0}function N(){p=!1}function D(){var t=M();t.addEventListener("mousedown",V,!0),t.addEventListener("touchend",V,Xe),t.addEventListener("touchstart",N,Xe),t.addEventListener("touchmove",F,Xe)}function j(){var t=M();t.removeEventListener("mousedown",V,!0),t.removeEventListener("touchend",V,Xe),t.removeEventListener("touchstart",N,Xe),t.removeEventListener("touchmove",F,Xe)}function B(t,e){U(t,(function(){!_.state.isVisible&&x.parentNode&&x.parentNode.contains(x)&&e()}))}function q(t,e){U(t,e)}function U(t,e){var i=T().box;function n(t){t.target===i&&(xi(i,"remove",n),e())}if(0===t)return e();xi(i,"remove",s),xi(i,"add",n),s=n}function W(e,i,n){void 0===n&&(n=!1),si(_.props.triggerTarget||t).forEach((function(t){t.addEventListener(e,i,n),g.push({node:t,eventType:e,handler:i,options:n})}))}function Y(){C()&&(W("touchstart",Z,{passive:!0}),W("touchend",Q,{passive:!0})),oi(_.props.trigger).forEach((function(t){if("manual"!==t)switch(W(t,Z),t){case"mouseenter":W("mouseleave",Q);break;case"focus":W(Mi?"focusout":"blur",J);break;case"focusin":W("focusout",J)}}))}function G(){g.forEach((function(t){var e=t.node,i=t.eventType,n=t.handler,r=t.options;e.removeEventListener(i,n,r)})),g=[]}function Z(t){var e,i=!1;if(_.state.isEnabled&&!X(t)&&!d){var n="focus"===(null==(e=o)?void 0:e.type);o=t,l=t.currentTarget,R(),!_.state.isVisible&&fi(t)&&Wi.forEach((function(e){return e(t)})),"click"===t.type&&(_.props.trigger.indexOf("mouseenter")<0||h)&&!1!==_.props.hideOnClick&&_.state.isVisible?i=!0:rt(t),"click"===t.type&&(h=!i),i&&!n&&ot(t)}}function K(t){var e=t.target,i=L().contains(e)||x.contains(e);"mousemove"===t.type&&i||wi(nt().concat(x).map((function(t){var e,i=null==(e=t._tippy.popperInstance)?void 0:e.state;return i?{popperRect:t.getBoundingClientRect(),popperState:i,props:c}:null})).filter(Boolean),t)&&(P(),ot(t))}function Q(t){X(t)||_.props.trigger.indexOf("click")>=0&&h||(_.props.interactive?_.hideWithInteractivity(t):ot(t))}function J(t){_.props.trigger.indexOf("focusin")<0&&t.target!==L()||_.props.interactive&&t.relatedTarget&&x.contains(t.relatedTarget)||ot(t)}function X(t){return!!Ai.isTouch&&C()!==t.type.indexOf("touch")>=0}function tt(){et();var e=_.props,i=e.popperOptions,n=e.placement,r=e.offset,o=e.getReferenceClientRect,s=e.moveTransition,l=E()?Bi(x).arrow:null,c=o?{getBoundingClientRect:o,contextElement:o.contextElement||L()}:t,h=[{name:"offset",options:{offset:r}},{name:"preventOverflow",options:{padding:{top:2,bottom:2,left:5,right:5}}},{name:"flip",options:{padding:5}},{name:"computeStyles",options:{adaptive:!s}},{name:"$$tippy",enabled:!0,phase:"beforeWrite",requires:["computeStyles"],fn:function(t){var e=t.state;if(E()){var i=T().box;["placement","reference-hidden","escaped"].forEach((function(t){"placement"===t?i.setAttribute("data-placement",e.placement):e.attributes.popper["data-popper-"+t]?i.setAttribute("data-"+t,""):i.removeAttribute("data-"+t)})),e.attributes.popper={}}}}];E()&&l&&h.push({name:"arrow",options:{element:l,padding:3}}),h.push.apply(h,(null==i?void 0:i.modifiers)||[]),_.popperInstance=Ye(c,x,Object.assign({},i,{placement:n,onFirstUpdate:a,modifiers:h}))}function et(){_.popperInstance&&(_.popperInstance.destroy(),_.popperInstance=null)}function it(){var t,e=_.props.appendTo,i=L();(t=_.props.interactive&&e===ti||"parent"===e?i.parentNode:ni(e,[i])).contains(x)||t.appendChild(x),_.state.isMounted=!0,tt()}function nt(){return hi(x.querySelectorAll("[data-tippy-root]"))}function rt(t){_.clearDelayTimeouts(),t&&H("onTrigger",[_,t]),D();var e=O(!0),n=z(),r=n[0],o=n[1];Ai.isTouch&&"hold"===r&&o&&(e=o),e?i=setTimeout((function(){_.show()}),e):_.show()}function ot(t){if(_.clearDelayTimeouts(),H("onUntrigger",[_,t]),_.state.isVisible){if(!(_.props.trigger.indexOf("mouseenter")>=0&&_.props.trigger.indexOf("click")>=0&&["mouseleave","mousemove"].indexOf(t.type)>=0&&h)){var e=O(!1);e?n=setTimeout((function(){_.state.isVisible&&_.hide()}),e):r=requestAnimationFrame((function(){_.hide()}))}}else j()}function st(){_.state.isEnabled=!0}function at(){_.hide(),_.state.isEnabled=!1}function lt(){clearTimeout(i),clearTimeout(n),cancelAnimationFrame(r)}function ct(e){if(!_.state.isDestroyed){H("onBeforeUpdate",[_,e]),G();var i=_.props,n=Vi(t,Object.assign({},i,di(e),{ignoreAttributes:!0}));_.props=n,Y(),i.interactiveDebounce!==n.interactiveDebounce&&(P(),f=ri(K,n.interactiveDebounce)),i.triggerTarget&&!n.triggerTarget?si(i.triggerTarget).forEach((function(t){t.removeAttribute("aria-expanded")})):n.triggerTarget&&t.removeAttribute("aria-expanded"),R(),$(),k&&k(i,n),_.popperInstance&&(tt(),nt().forEach((function(t){requestAnimationFrame(t._tippy.popperInstance.forceUpdate)}))),H("onAfterUpdate",[_,e])}}function ht(t){_.setProps({content:t})}function dt(){var t=_.state.isVisible,e=_.state.isDestroyed,i=!_.state.isEnabled,n=Ai.isTouch&&!_.props.touch,r=ei(_.props.duration,0,$i.duration);if(!(t||e||i||n||L().hasAttribute("disabled")||(H("onShow",[_],!1),!1===_.props.onShow(_)))){if(_.state.isVisible=!0,E()&&(x.style.visibility="visible"),$(),D(),_.state.isMounted||(x.style.transition="none"),E()){var o=T();bi([o.box,o.content],0)}a=function(){var t;if(_.state.isVisible&&!u){if(u=!0,x.offsetHeight,x.style.transition=_.props.moveTransition,E()&&_.props.animation){var e=T(),i=e.box,n=e.content;bi([i,n],r),yi([i,n],"visible")}I(),R(),ai(Yi,_),null==(t=_.popperInstance)||t.forceUpdate(),H("onMount",[_]),_.props.animation&&E()&&q(r,(function(){_.state.isShown=!0,H("onShown",[_])}))}},it()}}function pt(){var t=!_.state.isVisible,e=_.state.isDestroyed,i=!_.state.isEnabled,n=ei(_.props.duration,1,$i.duration);if(!(t||e||i)&&(H("onHide",[_],!1),!1!==_.props.onHide(_))){if(_.state.isVisible=!1,_.state.isShown=!1,u=!1,h=!1,E()&&(x.style.visibility="hidden"),P(),j(),$(!0),E()){var r=T(),o=r.box,s=r.content;_.props.animation&&(bi([o,s],n),yi([o,s],"hidden"))}I(),R(),_.props.animation?E()&&B(n,_.unmount):_.unmount()}}function ut(t){M().addEventListener("mousemove",f),ai(Wi,f),f(t)}function gt(){_.state.isVisible&&_.hide(),_.state.isMounted&&(et(),nt().forEach((function(t){t._tippy.unmount()})),x.parentNode&&x.parentNode.removeChild(x),Yi=Yi.filter((function(t){return t!==_})),_.state.isMounted=!1,H("onHidden",[_]))}function ft(){_.state.isDestroyed||(_.clearDelayTimeouts(),_.unmount(),G(),delete t._tippy,_.state.isDestroyed=!0,H("onDestroy",[_]))}}function Zi(t,e){void 0===e&&(e={});var i=$i.plugins.concat(e.plugins||[]);Li();var n=Object.assign({},e,{plugins:i}),r=vi(t).reduce((function(t,e){var i=e&&Gi(e,n);return i&&t.push(i),t}),[]);return ui(t)?r[0]:r}function Ki(t){return t.replace(/(?:^\w|[A-Z]|\b\w)/g,(t,e)=>0==+t?"":0===e?t.toLowerCase():t.toUpperCase()).replace("-","")}Zi.defaultProps=$i,Zi.setDefaultProps=Ii,Zi.currentInput=Ai,Object.assign({},Et,{effect:function(t){var e=t.state,i={popper:{position:e.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};Object.assign(e.elements.popper.style,i.popper),e.styles=i,e.elements.arrow&&Object.assign(e.elements.arrow.style,i.arrow)}}),Zi.setDefaultProps({render:qi});const Qi='\n .tippy-box[data-animation=fade][data-state=hidden] {\n opacity: 0\n }\n\n .tippy-iOS {\n cursor: pointer!important;\n -webkit-tap-highlight-color: transparent\n }\n\n [data-tippy-root] {\n max-width: calc(100vw - 10px)\n }\n\n .tippy-box {\n position: relative;\n background-color: #333;\n color: #fff;\n border-radius: 4px;\n font-size: clamp(\n calc(var(--pb-popover-font-size, 1rem) * var(--pb-min-zoom, 0.5)), \n calc(var(--pb-popover-font-size, 1rem) * var(--pb-zoom-factor)), \n calc(var(--pb-popover-font-size, 1rem) * var(--pb-max-zoom, 3.0))\n );\n line-height: calc(var(--pb-popover-line-height, 1.5) * var(--pb-zoom-factor));\n\n text-align: left;\n font-style: normal;\n font-weight: normal;\n outline: 0;\n transition-property: transform, visibility, opacity;\n }\n\n .tippy-box[data-placement^=top]>.tippy-arrow {\n bottom: 0\n }\n\n .tippy-box[data-placement^=top]>.tippy-arrow:before {\n bottom: -7px;\n left: 0;\n border-width: 8px 8px 0;\n border-top-color: initial;\n transform-origin: center top\n }\n\n .tippy-box[data-placement^=bottom]>.tippy-arrow {\n top: 0\n }\n\n .tippy-box[data-placement^=bottom]>.tippy-arrow:before {\n top: -7px;\n left: 0;\n border-width: 0 8px 8px;\n border-bottom-color: initial;\n transform-origin: center bottom\n }\n\n .tippy-box[data-placement^=left]>.tippy-arrow {\n right: 0\n }\n\n .tippy-box[data-placement^=left]>.tippy-arrow:before {\n border-width: 8px 0 8px 8px;\n border-left-color: initial;\n right: -7px;\n transform-origin: center left\n }\n\n .tippy-box[data-placement^=right]>.tippy-arrow {\n left: 0\n }\n\n .tippy-box[data-placement^=right]>.tippy-arrow:before {\n left: -7px;\n border-width: 8px 8px 8px 0;\n border-right-color: initial;\n transform-origin: center right\n }\n\n .tippy-box[data-inertia][data-state=visible] {\n transition-timing-function: cubic-bezier(.54, 1.5, .38, 1.11)\n }\n\n .tippy-arrow {\n width: 16px;\n height: 16px;\n color: #333\n }\n\n .tippy-arrow:before {\n content: "";\n position: absolute;\n border-color: transparent;\n border-style: solid\n }\n\n .tippy-content {\n position: relative;\n padding: 5px 9px;\n z-index: 1;\n overflow: auto;\n max-height: var(--pb-popover-max-height, calc(100vh - 60px));\n min-height: var(--pb-popover-min-height, auto);\n max-width: var(--pb-popover-max-width, auto);\n min-width: var(--pb-popover-min-width, auto);\n color: var(--pb-popover-color);\n }\n',Ji='\n .tippy-box[data-theme~=light-border] {\n background-color: #fff;\n background-clip: padding-box;\n border: 1px solid rgba(0, 8, 16, .15);\n color: #333;\n box-shadow: 0 4px 14px -2px rgba(0, 8, 16, .08)\n }\n\n .tippy-box[data-theme~=light-border]>.tippy-backdrop {\n background-color: #fff\n }\n\n .tippy-box[data-theme~=light-border]>.tippy-arrow:after, .tippy-box[data-theme~=light-border]>.tippy-svg-arrow:after {\n content: "";\n position: absolute;\n z-index: -1\n }\n\n .tippy-box[data-theme~=light-border]>.tippy-arrow:after {\n border-color: transparent;\n border-style: solid\n }\n\n .tippy-box[data-theme~=light-border][data-placement^=top]>.tippy-arrow:before {\n border-top-color: #fff\n }\n\n .tippy-box[data-theme~=light-border][data-placement^=top]>.tippy-arrow:after {\n border-top-color: rgba(0, 8, 16, .2);\n border-width: 7px 7px 0;\n top: 17px;\n left: 1px\n }\n\n .tippy-box[data-theme~=light-border][data-placement^=top]>.tippy-svg-arrow>svg {\n top: 16px\n }\n\n .tippy-box[data-theme~=light-border][data-placement^=top]>.tippy-svg-arrow:after {\n top: 17px\n }\n\n .tippy-box[data-theme~=light-border][data-placement^=bottom]>.tippy-arrow:before {\n border-bottom-color: #fff;\n bottom: 16px\n }\n\n .tippy-box[data-theme~=light-border][data-placement^=bottom]>.tippy-arrow:after {\n border-bottom-color: rgba(0, 8, 16, .2);\n border-width: 0 7px 7px;\n bottom: 17px;\n left: 1px\n }\n\n .tippy-box[data-theme~=light-border][data-placement^=bottom]>.tippy-svg-arrow>svg {\n bottom: 16px\n }\n\n .tippy-box[data-theme~=light-border][data-placement^=bottom]>.tippy-svg-arrow:after {\n bottom: 17px\n }\n\n .tippy-box[data-theme~=light-border][data-placement^=left]>.tippy-arrow:before {\n border-left-color: #fff\n }\n\n .tippy-box[data-theme~=light-border][data-placement^=left]>.tippy-arrow:after {\n border-left-color: rgba(0, 8, 16, .2);\n border-width: 7px 0 7px 7px;\n left: 17px;\n top: 1px\n }\n\n .tippy-box[data-theme~=light-border][data-placement^=left]>.tippy-svg-arrow>svg {\n left: 11px\n }\n\n .tippy-box[data-theme~=light-border][data-placement^=left]>.tippy-svg-arrow:after {\n left: 12px\n }\n\n .tippy-box[data-theme~=light-border][data-placement^=right]>.tippy-arrow:before {\n border-right-color: #fff;\n right: 16px\n }\n\n .tippy-box[data-theme~=light-border][data-placement^=right]>.tippy-arrow:after {\n border-width: 7px 7px 7px 0;\n right: 17px;\n top: 1px;\n border-right-color: rgba(0, 8, 16, .2)\n }\n\n .tippy-box[data-theme~=light-border][data-placement^=right]>.tippy-svg-arrow>svg {\n right: 11px\n }\n\n .tippy-box[data-theme~=light-border][data-placement^=right]>.tippy-svg-arrow:after {\n right: 12px\n }\n\n .tippy-box[data-theme~=light-border]>.tippy-svg-arrow {\n fill: #fff\n }\n\n .tippy-box[data-theme~=light-border]>.tippy-svg-arrow:after {\n background-image: url(data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMTYiIGhlaWdodD0iNiIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj48cGF0aCBkPSJNMCA2czEuNzk2LS4wMTMgNC42Ny0zLjYxNUM1Ljg1MS45IDYuOTMuMDA2IDggMGMxLjA3LS4wMDYgMi4xNDguODg3IDMuMzQzIDIuMzg1QzE0LjIzMyA2LjAwNSAxNiA2IDE2IDZIMHoiIGZpbGw9InJnYmEoMCwgOCwgMTYsIDAuMikiLz48L3N2Zz4=);\n background-size: 16px 6px;\n width: 16px;\n height: 6px\n }\n',Xi="\n .tippy-box[data-theme~=light] {\n color: #26323d;\n box-shadow: 0 0 20px 4px rgba(154, 161, 177, .15), 0 4px 80px -8px rgba(36, 40, 47, .25), 0 4px 4px -2px rgba(91, 94, 105, .15);\n background-color: #fff\n }\n\n .tippy-box[data-theme~=light][data-placement^=top]>.tippy-arrow:before {\n border-top-color: #fff\n }\n\n .tippy-box[data-theme~=light][data-placement^=bottom]>.tippy-arrow:before {\n border-bottom-color: #fff\n }\n\n .tippy-box[data-theme~=light][data-placement^=left]>.tippy-arrow:before {\n border-left-color: #fff\n }\n\n .tippy-box[data-theme~=light][data-placement^=right]>.tippy-arrow:before {\n border-right-color: #fff\n }\n\n .tippy-box[data-theme~=light]>.tippy-backdrop {\n background-color: #fff\n }\n\n .tippy-box[data-theme~=light]>.tippy-svg-arrow {\n fill: #fff\n }",tn="\n .tippy-box[data-theme~=material] {\n background-color: #505355;\n font-weight: 600\n }\n\n .tippy-box[data-theme~=material][data-placement^=top]>.tippy-arrow:before {\n border-top-color: #505355\n }\n\n .tippy-box[data-theme~=material][data-placement^=bottom]>.tippy-arrow:before {\n border-bottom-color: #505355\n }\n\n .tippy-box[data-theme~=material][data-placement^=left]>.tippy-arrow:before {\n border-left-color: #505355\n }\n\n .tippy-box[data-theme~=material][data-placement^=right]>.tippy-arrow:before {\n border-right-color: #505355\n }\n\n .tippy-box[data-theme~=material]>.tippy-backdrop {\n background-color: #505355\n }\n\n .tippy-box[data-theme~=material]>.tippy-svg-arrow {\n fill: #505355\n }\n",en="\n .tippy-box[data-theme~=translucent] {\n background-color: rgba(0, 0, 0, .7)\n }\n\n .tippy-box[data-theme~=translucent]>.tippy-arrow {\n width: 14px;\n height: 14px\n }\n\n .tippy-box[data-theme~=translucent][data-placement^=top]>.tippy-arrow:before {\n border-width: 7px 7px 0;\n border-top-color: rgba(0, 0, 0, .7)\n }\n\n .tippy-box[data-theme~=translucent][data-placement^=bottom]>.tippy-arrow:before {\n border-width: 0 7px 7px;\n border-bottom-color: rgba(0, 0, 0, .7)\n }\n\n .tippy-box[data-theme~=translucent][data-placement^=left]>.tippy-arrow:before {\n border-width: 7px 0 7px 7px;\n border-left-color: rgba(0, 0, 0, .7)\n }\n\n .tippy-box[data-theme~=translucent][data-placement^=right]>.tippy-arrow:before {\n border-width: 7px 7px 7px 0;\n border-right-color: rgba(0, 0, 0, .7)\n }\n\n .tippy-box[data-theme~=translucent]>.tippy-backdrop {\n background-color: rgba(0, 0, 0, .7)\n }\n\n .tippy-box[data-theme~=translucent]>.tippy-svg-arrow {\n fill: rgba(0, 0, 0, .7)\n }\n";var nn=Object.freeze({__proto__:null,camelize:Ki,base:Qi,lightBorder:Ji,light:Xi,material:tn,translucent:en});function rn(t,e,i){if(!t.querySelector("#pb-popover-"+e)){const n=t.nodeType===Node.DOCUMENT_NODE?document.head:t;console.log("Loading tippy styles for theme %s into %o",e,n);const r=document.createElement("style");r.type="text/css",r.id="pb-popover-"+e,r.innerHTML=i,n.appendChild(r)}}function on(t,e){if(rn(t,"base",Qi),e&&"none"!==e){const i=Ki(e),n=nn[i];n&&rn(t,i,n)}}class sn extends(P(I)){static get properties(){return Object.assign(Object.assign({},super.properties),{},{for:{type:String},theme:{type:String},placement:{type:String},fallbackPlacement:{type:String,attribute:"fallback-placement"},persistent:{type:Boolean},trigger:{type:String},touch:{type:String},popupClass:{type:String,attribute:"popup-class"},remote:{type:String},stopPropagation:{type:Boolean,attribute:"stop-propagation"}})}constructor(){super(),this.persistent=!1,this.trigger=null,this.for=null,this.theme=null,this.placement=null,this.touch=null,this.fallbackPlacement=null,this.popupClass=null,this.stopPropagation=!1,this._tippy=null,this._content=null}render(){return this.for?T`<div class="hidden"><slot></slot></div>`:T`<span id="link" part="trigger" class="${this.persistent?"persistent":""}"
|
|
504
|
+
`}}customElements.define("pb-demo-snippet",it);class nt{static subscribe(t,e,i,n=!1){const r=nt._getChannels(e),o=document.addEventListener(t,t=>{i&&t.detail&&t.detail.key&&r.includes(t.detail.key)&&i(t,o)},{once:n})}static subscribeOnce(t,e=null){const i=nt._getChannels(e);return new Promise(e=>{document.addEventListener(t,t=>{t.detail&&t.detail.key&&i.includes(t.detail.key)&&e(t)},{once:!0})})}static _getChannels(t){return null!==t&&t.length?Array.isArray(t)?t:[t]:[R]}static emit(t,e=null,i=null){const n=i||{};n.key=e||R;const r=new CustomEvent(t,{detail:n});document.dispatchEvent(r)}static ifReady(t){return Array.isArray(t)||(t=[t]),new Promise(e=>{const i=t.length;if(0===i)return void e();let n=i;t.forEach(t=>{if(t._isReady)return n-=1,void(0===n&&e());const i=t.addEventListener("pb-ready",()=>{n-=1,0===n&&(t.removeEventListener("pb-ready",i),e())})})})}}window.pbEvents||(window.pbEvents=nt);const rt="3.5.0";class ot extends I{static get properties(){return Object.assign({version:{type:String,reflect:!0}},super.properties)}constructor(){super(),this.version=rt}connectedCallback(){if(super.connectedCallback(),!this.version){const t=H("../package.json");fetch(t).then(t=>t.json()).then(t=>{this.version=t.version})}}render(){return T`<span>${this.version?this.version:"unknown"}</span>`}createRenderRoot(){return this}}customElements.define("pb-version",ot);var st="top",at="bottom",lt="right",ct="left",ht="auto",dt=[st,at,lt,ct],pt="start",ut="end",gt="clippingParents",ft="viewport",mt="popper",vt="reference",bt=dt.reduce((function(t,e){return t.concat([e+"-"+pt,e+"-"+ut])}),[]),yt=[].concat(dt,[ht]).reduce((function(t,e){return t.concat([e,e+"-"+pt,e+"-"+ut])}),[]),_t=["beforeRead","read","afterRead","beforeMain","main","afterMain","beforeWrite","write","afterWrite"];function wt(t){return t?(t.nodeName||"").toLowerCase():null}function xt(t){if(null==t)return window;if("[object Window]"!==t.toString()){var e=t.ownerDocument;return e&&e.defaultView||window}return t}function kt(t){return t instanceof xt(t).Element||t instanceof Element}function At(t){return t instanceof xt(t).HTMLElement||t instanceof HTMLElement}function St(t){return"undefined"!=typeof ShadowRoot&&(t instanceof xt(t).ShadowRoot||t instanceof ShadowRoot)}function zt(t){var e=t.state;Object.keys(e.elements).forEach((function(t){var i=e.styles[t]||{},n=e.attributes[t]||{},r=e.elements[t];At(r)&&wt(r)&&(Object.assign(r.style,i),Object.keys(n).forEach((function(t){var e=n[t];!1===e?r.removeAttribute(t):r.setAttribute(t,!0===e?"":e)})))}))}function Ct(t){var e=t.state,i={popper:{position:e.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};return Object.assign(e.elements.popper.style,i.popper),e.styles=i,e.elements.arrow&&Object.assign(e.elements.arrow.style,i.arrow),function(){Object.keys(e.elements).forEach((function(t){var n=e.elements[t],r=e.attributes[t]||{},o=Object.keys(e.styles.hasOwnProperty(t)?e.styles[t]:i[t]).reduce((function(t,e){return t[e]="",t}),{});At(n)&&wt(n)&&(Object.assign(n.style,o),Object.keys(r).forEach((function(t){n.removeAttribute(t)})))}))}}var Et={name:"applyStyles",enabled:!0,phase:"write",fn:zt,effect:Ct,requires:["computeStyles"]};function Lt(t){return t.split("-")[0]}var Mt=Math.max,Tt=Math.min,Ot=Math.round;function $t(){var t=navigator.userAgentData;return null!=t&&t.brands&&Array.isArray(t.brands)?t.brands.map((function(t){return t.brand+"/"+t.version})).join(" "):navigator.userAgent}function Ht(){return!/^((?!chrome|android).)*safari/i.test($t())}function It(t,e,i){void 0===e&&(e=!1),void 0===i&&(i=!1);var n=t.getBoundingClientRect(),r=1,o=1;e&&At(t)&&(r=t.offsetWidth>0&&Ot(n.width)/t.offsetWidth||1,o=t.offsetHeight>0&&Ot(n.height)/t.offsetHeight||1);var s=(kt(t)?xt(t):window).visualViewport,a=!Ht()&&i,l=(n.left+(a&&s?s.offsetLeft:0))/r,c=(n.top+(a&&s?s.offsetTop:0))/o,h=n.width/r,d=n.height/o;return{width:h,height:d,top:c,right:l+h,bottom:c+d,left:l,x:l,y:c}}function Rt(t){var e=It(t),i=t.offsetWidth,n=t.offsetHeight;return Math.abs(e.width-i)<=1&&(i=e.width),Math.abs(e.height-n)<=1&&(n=e.height),{x:t.offsetLeft,y:t.offsetTop,width:i,height:n}}function Pt(t,e){var i=e.getRootNode&&e.getRootNode();if(t.contains(e))return!0;if(i&&St(i)){var n=e;do{if(n&&t.isSameNode(n))return!0;n=n.parentNode||n.host}while(n)}return!1}function Vt(t){return xt(t).getComputedStyle(t)}function Ft(t){return["table","td","th"].indexOf(wt(t))>=0}function Nt(t){return((kt(t)?t.ownerDocument:t.document)||window.document).documentElement}function Dt(t){return"html"===wt(t)?t:t.assignedSlot||t.parentNode||(St(t)?t.host:null)||Nt(t)}function jt(t){return At(t)&&"fixed"!==Vt(t).position?t.offsetParent:null}function Bt(t){var e=/firefox/i.test($t());if(/Trident/i.test($t())&&At(t)&&"fixed"===Vt(t).position)return null;var i=Dt(t);for(St(i)&&(i=i.host);At(i)&&["html","body"].indexOf(wt(i))<0;){var n=Vt(i);if("none"!==n.transform||"none"!==n.perspective||"paint"===n.contain||-1!==["transform","perspective"].indexOf(n.willChange)||e&&"filter"===n.willChange||e&&n.filter&&"none"!==n.filter)return i;i=i.parentNode}return null}function qt(t){for(var e=xt(t),i=jt(t);i&&Ft(i)&&"static"===Vt(i).position;)i=jt(i);return i&&("html"===wt(i)||"body"===wt(i)&&"static"===Vt(i).position)?e:i||Bt(t)||e}function Ut(t){return["top","bottom"].indexOf(t)>=0?"x":"y"}function Wt(t,e,i){return Mt(t,Tt(e,i))}function Yt(t,e,i){var n=Wt(t,e,i);return n>i?i:n}function Gt(){return{top:0,right:0,bottom:0,left:0}}function Zt(t){return Object.assign({},Gt(),t)}function Kt(t,e){return e.reduce((function(e,i){return e[i]=t,e}),{})}var Qt=function(t,e){return Zt("number"!=typeof(t="function"==typeof t?t(Object.assign({},e.rects,{placement:e.placement})):t)?t:Kt(t,dt))};function Jt(t){var e,i=t.state,n=t.name,r=t.options,o=i.elements.arrow,s=i.modifiersData.popperOffsets,a=Lt(i.placement),l=Ut(a),c=[ct,lt].indexOf(a)>=0?"height":"width";if(o&&s){var h=Qt(r.padding,i),d=Rt(o),p="y"===l?st:ct,u="y"===l?at:lt,g=i.rects.reference[c]+i.rects.reference[l]-s[l]-i.rects.popper[c],f=s[l]-i.rects.reference[l],m=qt(o),v=m?"y"===l?m.clientHeight||0:m.clientWidth||0:0,b=g/2-f/2,y=h[p],_=v-d[c]-h[u],w=v/2-d[c]/2+b,x=Wt(y,w,_),k=l;i.modifiersData[n]=((e={})[k]=x,e.centerOffset=x-w,e)}}function Xt(t){var e=t.state,i=t.options.element,n=void 0===i?"[data-popper-arrow]":i;null!=n&&("string"!=typeof n||(n=e.elements.popper.querySelector(n)))&&Pt(e.elements.popper,n)&&(e.elements.arrow=n)}function te(t){return t.split("-")[1]}var ee={top:"auto",right:"auto",bottom:"auto",left:"auto"};function ie(t,e){var i=t.x,n=t.y,r=e.devicePixelRatio||1;return{x:Ot(i*r)/r||0,y:Ot(n*r)/r||0}}function ne(t){var e,i=t.popper,n=t.popperRect,r=t.placement,o=t.variation,s=t.offsets,a=t.position,l=t.gpuAcceleration,c=t.adaptive,h=t.roundOffsets,d=t.isFixed,p=s.x,u=void 0===p?0:p,g=s.y,f=void 0===g?0:g,m="function"==typeof h?h({x:u,y:f}):{x:u,y:f};u=m.x,f=m.y;var v=s.hasOwnProperty("x"),b=s.hasOwnProperty("y"),y=ct,_=st,w=window;if(c){var x=qt(i),k="clientHeight",A="clientWidth";if(x===xt(i)&&"static"!==Vt(x=Nt(i)).position&&"absolute"===a&&(k="scrollHeight",A="scrollWidth"),x=x,r===st||(r===ct||r===lt)&&o===ut)_=at,f-=(d&&x===w&&w.visualViewport?w.visualViewport.height:x[k])-n.height,f*=l?1:-1;if(r===ct||(r===st||r===at)&&o===ut)y=lt,u-=(d&&x===w&&w.visualViewport?w.visualViewport.width:x[A])-n.width,u*=l?1:-1}var S,z=Object.assign({position:a},c&&ee),C=!0===h?ie({x:u,y:f},xt(i)):{x:u,y:f};return u=C.x,f=C.y,l?Object.assign({},z,((S={})[_]=b?"0":"",S[y]=v?"0":"",S.transform=(w.devicePixelRatio||1)<=1?"translate("+u+"px, "+f+"px)":"translate3d("+u+"px, "+f+"px, 0)",S)):Object.assign({},z,((e={})[_]=b?f+"px":"",e[y]=v?u+"px":"",e.transform="",e))}function re(t){var e=t.state,i=t.options,n=i.gpuAcceleration,r=void 0===n||n,o=i.adaptive,s=void 0===o||o,a=i.roundOffsets,l=void 0===a||a,c={placement:Lt(e.placement),variation:te(e.placement),popper:e.elements.popper,popperRect:e.rects.popper,gpuAcceleration:r,isFixed:"fixed"===e.options.strategy};null!=e.modifiersData.popperOffsets&&(e.styles.popper=Object.assign({},e.styles.popper,ne(Object.assign({},c,{offsets:e.modifiersData.popperOffsets,position:e.options.strategy,adaptive:s,roundOffsets:l})))),null!=e.modifiersData.arrow&&(e.styles.arrow=Object.assign({},e.styles.arrow,ne(Object.assign({},c,{offsets:e.modifiersData.arrow,position:"absolute",adaptive:!1,roundOffsets:l})))),e.attributes.popper=Object.assign({},e.attributes.popper,{"data-popper-placement":e.placement})}var oe={passive:!0};function se(t){var e=t.state,i=t.instance,n=t.options,r=n.scroll,o=void 0===r||r,s=n.resize,a=void 0===s||s,l=xt(e.elements.popper),c=[].concat(e.scrollParents.reference,e.scrollParents.popper);return o&&c.forEach((function(t){t.addEventListener("scroll",i.update,oe)})),a&&l.addEventListener("resize",i.update,oe),function(){o&&c.forEach((function(t){t.removeEventListener("scroll",i.update,oe)})),a&&l.removeEventListener("resize",i.update,oe)}}var ae={left:"right",right:"left",bottom:"top",top:"bottom"};function le(t){return t.replace(/left|right|bottom|top/g,(function(t){return ae[t]}))}var ce={start:"end",end:"start"};function he(t){return t.replace(/start|end/g,(function(t){return ce[t]}))}function de(t){var e=xt(t);return{scrollLeft:e.pageXOffset,scrollTop:e.pageYOffset}}function pe(t){return It(Nt(t)).left+de(t).scrollLeft}function ue(t,e){var i=xt(t),n=Nt(t),r=i.visualViewport,o=n.clientWidth,s=n.clientHeight,a=0,l=0;if(r){o=r.width,s=r.height;var c=Ht();(c||!c&&"fixed"===e)&&(a=r.offsetLeft,l=r.offsetTop)}return{width:o,height:s,x:a+pe(t),y:l}}function ge(t){var e,i=Nt(t),n=de(t),r=null==(e=t.ownerDocument)?void 0:e.body,o=Mt(i.scrollWidth,i.clientWidth,r?r.scrollWidth:0,r?r.clientWidth:0),s=Mt(i.scrollHeight,i.clientHeight,r?r.scrollHeight:0,r?r.clientHeight:0),a=-n.scrollLeft+pe(t),l=-n.scrollTop;return"rtl"===Vt(r||i).direction&&(a+=Mt(i.clientWidth,r?r.clientWidth:0)-o),{width:o,height:s,x:a,y:l}}function fe(t){var e=Vt(t),i=e.overflow,n=e.overflowX,r=e.overflowY;return/auto|scroll|overlay|hidden/.test(i+r+n)}function me(t){return["html","body","#document"].indexOf(wt(t))>=0?t.ownerDocument.body:At(t)&&fe(t)?t:me(Dt(t))}function ve(t,e){var i;void 0===e&&(e=[]);var n=me(t),r=n===(null==(i=t.ownerDocument)?void 0:i.body),o=xt(n),s=r?[o].concat(o.visualViewport||[],fe(n)?n:[]):n,a=e.concat(s);return r?a:a.concat(ve(Dt(s)))}function be(t){return Object.assign({},t,{left:t.x,top:t.y,right:t.x+t.width,bottom:t.y+t.height})}function ye(t,e){var i=It(t,!1,"fixed"===e);return i.top=i.top+t.clientTop,i.left=i.left+t.clientLeft,i.bottom=i.top+t.clientHeight,i.right=i.left+t.clientWidth,i.width=t.clientWidth,i.height=t.clientHeight,i.x=i.left,i.y=i.top,i}function _e(t,e,i){return e===ft?be(ue(t,i)):kt(e)?ye(e,i):be(ge(Nt(t)))}function we(t){var e=ve(Dt(t)),i=["absolute","fixed"].indexOf(Vt(t).position)>=0&&At(t)?qt(t):t;return kt(i)?e.filter((function(t){return kt(t)&&Pt(t,i)&&"body"!==wt(t)})):[]}function xe(t,e,i,n){var r="clippingParents"===e?we(t):[].concat(e),o=[].concat(r,[i]),s=o[0],a=o.reduce((function(e,i){var r=_e(t,i,n);return e.top=Mt(r.top,e.top),e.right=Tt(r.right,e.right),e.bottom=Tt(r.bottom,e.bottom),e.left=Mt(r.left,e.left),e}),_e(t,s,n));return a.width=a.right-a.left,a.height=a.bottom-a.top,a.x=a.left,a.y=a.top,a}function ke(t){var e,i=t.reference,n=t.element,r=t.placement,o=r?Lt(r):null,s=r?te(r):null,a=i.x+i.width/2-n.width/2,l=i.y+i.height/2-n.height/2;switch(o){case st:e={x:a,y:i.y-n.height};break;case at:e={x:a,y:i.y+i.height};break;case lt:e={x:i.x+i.width,y:l};break;case ct:e={x:i.x-n.width,y:l};break;default:e={x:i.x,y:i.y}}var c=o?Ut(o):null;if(null!=c){var h="y"===c?"height":"width";switch(s){case pt:e[c]=e[c]-(i[h]/2-n[h]/2);break;case ut:e[c]=e[c]+(i[h]/2-n[h]/2)}}return e}function Ae(t,e){void 0===e&&(e={});var i=e,n=i.placement,r=void 0===n?t.placement:n,o=i.strategy,s=void 0===o?t.strategy:o,a=i.boundary,l=void 0===a?gt:a,c=i.rootBoundary,h=void 0===c?ft:c,d=i.elementContext,p=void 0===d?mt:d,u=i.altBoundary,g=void 0!==u&&u,f=i.padding,m=void 0===f?0:f,v=Zt("number"!=typeof m?m:Kt(m,dt)),b=p===mt?vt:mt,y=t.rects.popper,_=t.elements[g?b:p],w=xe(kt(_)?_:_.contextElement||Nt(t.elements.popper),l,h,s),x=It(t.elements.reference),k=ke({reference:x,element:y,strategy:"absolute",placement:r}),A=be(Object.assign({},y,k)),S=p===mt?A:x,z={top:w.top-S.top+v.top,bottom:S.bottom-w.bottom+v.bottom,left:w.left-S.left+v.left,right:S.right-w.right+v.right},C=t.modifiersData.offset;if(p===mt&&C){var E=C[r];Object.keys(z).forEach((function(t){var e=[lt,at].indexOf(t)>=0?1:-1,i=[st,at].indexOf(t)>=0?"y":"x";z[t]+=E[i]*e}))}return z}function Se(t,e){void 0===e&&(e={});var i=e,n=i.placement,r=i.boundary,o=i.rootBoundary,s=i.padding,a=i.flipVariations,l=i.allowedAutoPlacements,c=void 0===l?yt:l,h=te(n),d=h?a?bt:bt.filter((function(t){return te(t)===h})):dt,p=d.filter((function(t){return c.indexOf(t)>=0}));0===p.length&&(p=d);var u=p.reduce((function(e,i){return e[i]=Ae(t,{placement:i,boundary:r,rootBoundary:o,padding:s})[Lt(i)],e}),{});return Object.keys(u).sort((function(t,e){return u[t]-u[e]}))}function ze(t){if(Lt(t)===ht)return[];var e=le(t);return[he(t),e,he(e)]}function Ce(t){var e=t.state,i=t.options,n=t.name;if(!e.modifiersData[n]._skip){for(var r=i.mainAxis,o=void 0===r||r,s=i.altAxis,a=void 0===s||s,l=i.fallbackPlacements,c=i.padding,h=i.boundary,d=i.rootBoundary,p=i.altBoundary,u=i.flipVariations,g=void 0===u||u,f=i.allowedAutoPlacements,m=e.options.placement,v=Lt(m),b=l||(v===m||!g?[le(m)]:ze(m)),y=[m].concat(b).reduce((function(t,i){return t.concat(Lt(i)===ht?Se(e,{placement:i,boundary:h,rootBoundary:d,padding:c,flipVariations:g,allowedAutoPlacements:f}):i)}),[]),_=e.rects.reference,w=e.rects.popper,x=new Map,k=!0,A=y[0],S=0;S<y.length;S++){var z=y[S],C=Lt(z),E=te(z)===pt,L=[st,at].indexOf(C)>=0,M=L?"width":"height",T=Ae(e,{placement:z,boundary:h,rootBoundary:d,altBoundary:p,padding:c}),O=L?E?lt:ct:E?at:st;_[M]>w[M]&&(O=le(O));var $=le(O),H=[];if(o&&H.push(T[C]<=0),a&&H.push(T[O]<=0,T[$]<=0),H.every((function(t){return t}))){A=z,k=!1;break}x.set(z,H)}if(k)for(var I=function(t){var e=y.find((function(e){var i=x.get(e);if(i)return i.slice(0,t).every((function(t){return t}))}));if(e)return A=e,"break"},R=g?3:1;R>0;R--){if("break"===I(R))break}e.placement!==A&&(e.modifiersData[n]._skip=!0,e.placement=A,e.reset=!0)}}function Ee(t,e,i){return void 0===i&&(i={x:0,y:0}),{top:t.top-e.height-i.y,right:t.right-e.width+i.x,bottom:t.bottom-e.height+i.y,left:t.left-e.width-i.x}}function Le(t){return[st,lt,at,ct].some((function(e){return t[e]>=0}))}function Me(t){var e=t.state,i=t.name,n=e.rects.reference,r=e.rects.popper,o=e.modifiersData.preventOverflow,s=Ae(e,{elementContext:"reference"}),a=Ae(e,{altBoundary:!0}),l=Ee(s,n),c=Ee(a,r,o),h=Le(l),d=Le(c);e.modifiersData[i]={referenceClippingOffsets:l,popperEscapeOffsets:c,isReferenceHidden:h,hasPopperEscaped:d},e.attributes.popper=Object.assign({},e.attributes.popper,{"data-popper-reference-hidden":h,"data-popper-escaped":d})}function Te(t,e,i){var n=Lt(t),r=[ct,st].indexOf(n)>=0?-1:1,o="function"==typeof i?i(Object.assign({},e,{placement:t})):i,s=o[0],a=o[1];return s=s||0,a=(a||0)*r,[ct,lt].indexOf(n)>=0?{x:a,y:s}:{x:s,y:a}}function Oe(t){var e=t.state,i=t.options,n=t.name,r=i.offset,o=void 0===r?[0,0]:r,s=yt.reduce((function(t,i){return t[i]=Te(i,e.rects,o),t}),{}),a=s[e.placement],l=a.x,c=a.y;null!=e.modifiersData.popperOffsets&&(e.modifiersData.popperOffsets.x+=l,e.modifiersData.popperOffsets.y+=c),e.modifiersData[n]=s}function $e(t){var e=t.state,i=t.name;e.modifiersData[i]=ke({reference:e.rects.reference,element:e.rects.popper,strategy:"absolute",placement:e.placement})}function He(t){return"x"===t?"y":"x"}function Ie(t){var e=t.state,i=t.options,n=t.name,r=i.mainAxis,o=void 0===r||r,s=i.altAxis,a=void 0!==s&&s,l=i.boundary,c=i.rootBoundary,h=i.altBoundary,d=i.padding,p=i.tether,u=void 0===p||p,g=i.tetherOffset,f=void 0===g?0:g,m=Ae(e,{boundary:l,rootBoundary:c,padding:d,altBoundary:h}),v=Lt(e.placement),b=te(e.placement),y=!b,_=Ut(v),w=He(_),x=e.modifiersData.popperOffsets,k=e.rects.reference,A=e.rects.popper,S="function"==typeof f?f(Object.assign({},e.rects,{placement:e.placement})):f,z="number"==typeof S?{mainAxis:S,altAxis:S}:Object.assign({mainAxis:0,altAxis:0},S),C=e.modifiersData.offset?e.modifiersData.offset[e.placement]:null,E={x:0,y:0};if(x){if(o){var L,M="y"===_?st:ct,T="y"===_?at:lt,O="y"===_?"height":"width",$=x[_],H=$+m[M],I=$-m[T],R=u?-A[O]/2:0,P=b===pt?k[O]:A[O],V=b===pt?-A[O]:-k[O],F=e.elements.arrow,N=u&&F?Rt(F):{width:0,height:0},D=e.modifiersData["arrow#persistent"]?e.modifiersData["arrow#persistent"].padding:Gt(),j=D[M],B=D[T],q=Wt(0,k[O],N[O]),U=y?k[O]/2-R-q-j-z.mainAxis:P-q-j-z.mainAxis,W=y?-k[O]/2+R+q+B+z.mainAxis:V+q+B+z.mainAxis,Y=e.elements.arrow&&qt(e.elements.arrow),G=Y?"y"===_?Y.clientTop||0:Y.clientLeft||0:0,Z=null!=(L=null==C?void 0:C[_])?L:0,K=$+W-Z,Q=Wt(u?Tt(H,$+U-Z-G):H,$,u?Mt(I,K):I);x[_]=Q,E[_]=Q-$}if(a){var J,X="x"===_?st:ct,tt="x"===_?at:lt,et=x[w],it="y"===w?"height":"width",nt=et+m[X],rt=et-m[tt],ot=-1!==[st,ct].indexOf(v),ht=null!=(J=null==C?void 0:C[w])?J:0,dt=ot?nt:et-k[it]-A[it]-ht+z.altAxis,ut=ot?et+k[it]+A[it]-ht-z.altAxis:rt,gt=u&&ot?Yt(dt,et,ut):Wt(u?dt:nt,et,u?ut:rt);x[w]=gt,E[w]=gt-et}e.modifiersData[n]=E}}function Re(t){return{scrollLeft:t.scrollLeft,scrollTop:t.scrollTop}}function Pe(t){return t!==xt(t)&&At(t)?Re(t):de(t)}function Ve(t){var e=t.getBoundingClientRect(),i=Ot(e.width)/t.offsetWidth||1,n=Ot(e.height)/t.offsetHeight||1;return 1!==i||1!==n}function Fe(t,e,i){void 0===i&&(i=!1);var n=At(e),r=At(e)&&Ve(e),o=Nt(e),s=It(t,r,i),a={scrollLeft:0,scrollTop:0},l={x:0,y:0};return(n||!n&&!i)&&(("body"!==wt(e)||fe(o))&&(a=Pe(e)),At(e)?((l=It(e,!0)).x+=e.clientLeft,l.y+=e.clientTop):o&&(l.x=pe(o))),{x:s.left+a.scrollLeft-l.x,y:s.top+a.scrollTop-l.y,width:s.width,height:s.height}}function Ne(t){var e=new Map,i=new Set,n=[];function r(t){i.add(t.name),[].concat(t.requires||[],t.requiresIfExists||[]).forEach((function(t){if(!i.has(t)){var n=e.get(t);n&&r(n)}})),n.push(t)}return t.forEach((function(t){e.set(t.name,t)})),t.forEach((function(t){i.has(t.name)||r(t)})),n}function De(t){var e=Ne(t);return _t.reduce((function(t,i){return t.concat(e.filter((function(t){return t.phase===i})))}),[])}function je(t){var e;return function(){return e||(e=new Promise((function(i){Promise.resolve().then((function(){e=void 0,i(t())}))}))),e}}function Be(t){var e=t.reduce((function(t,e){var i=t[e.name];return t[e.name]=i?Object.assign({},i,e,{options:Object.assign({},i.options,e.options),data:Object.assign({},i.data,e.data)}):e,t}),{});return Object.keys(e).map((function(t){return e[t]}))}var qe={placement:"bottom",modifiers:[],strategy:"absolute"};function Ue(){for(var t=arguments.length,e=new Array(t),i=0;i<t;i++)e[i]=arguments[i];return!e.some((function(t){return!(t&&"function"==typeof t.getBoundingClientRect)}))}function We(t){void 0===t&&(t={});var e=t,i=e.defaultModifiers,n=void 0===i?[]:i,r=e.defaultOptions,o=void 0===r?qe:r;return function(t,e,i){void 0===i&&(i=o);var r={placement:"bottom",orderedModifiers:[],options:Object.assign({},qe,o),modifiersData:{},elements:{reference:t,popper:e},attributes:{},styles:{}},s=[],a=!1,l={state:r,setOptions:function(i){var s="function"==typeof i?i(r.options):i;h(),r.options=Object.assign({},o,r.options,s),r.scrollParents={reference:kt(t)?ve(t):t.contextElement?ve(t.contextElement):[],popper:ve(e)};var a=De(Be([].concat(n,r.options.modifiers)));return r.orderedModifiers=a.filter((function(t){return t.enabled})),c(),l.update()},forceUpdate:function(){if(!a){var t=r.elements,e=t.reference,i=t.popper;if(Ue(e,i)){r.rects={reference:Fe(e,qt(i),"fixed"===r.options.strategy),popper:Rt(i)},r.reset=!1,r.placement=r.options.placement,r.orderedModifiers.forEach((function(t){return r.modifiersData[t.name]=Object.assign({},t.data)}));for(var n=0;n<r.orderedModifiers.length;n++)if(!0!==r.reset){var o=r.orderedModifiers[n],s=o.fn,c=o.options,h=void 0===c?{}:c,d=o.name;"function"==typeof s&&(r=s({state:r,options:h,name:d,instance:l})||r)}else r.reset=!1,n=-1}}},update:je((function(){return new Promise((function(t){l.forceUpdate(),t(r)}))})),destroy:function(){h(),a=!0}};if(!Ue(t,e))return l;function c(){r.orderedModifiers.forEach((function(t){var e=t.name,i=t.options,n=void 0===i?{}:i,o=t.effect;if("function"==typeof o){var a=o({state:r,name:e,instance:l,options:n}),c=function(){};s.push(a||c)}}))}function h(){s.forEach((function(t){return t()})),s=[]}return l.setOptions(i).then((function(t){!a&&i.onFirstUpdate&&i.onFirstUpdate(t)})),l}}var Ye=We({defaultModifiers:[{name:"eventListeners",enabled:!0,phase:"write",fn:function(){},effect:se,data:{}},{name:"popperOffsets",enabled:!0,phase:"read",fn:$e,data:{}},{name:"computeStyles",enabled:!0,phase:"beforeWrite",fn:re,data:{}},Et,{name:"offset",enabled:!0,phase:"main",requires:["popperOffsets"],fn:Oe},{name:"flip",enabled:!0,phase:"main",fn:Ce,requiresIfExists:["offset"],data:{_skip:!1}},{name:"preventOverflow",enabled:!0,phase:"main",fn:Ie,requiresIfExists:["offset"]},{name:"arrow",enabled:!0,phase:"main",fn:Jt,effect:Xt,requires:["popperOffsets"],requiresIfExists:["preventOverflow"]},{name:"hide",enabled:!0,phase:"main",requiresIfExists:["preventOverflow"],fn:Me}]}),Ge="tippy-box",Ze="tippy-content",Ke="tippy-backdrop",Qe="tippy-arrow",Je="tippy-svg-arrow",Xe={passive:!0,capture:!0},ti=function(){return document.body};function ei(t,e,i){if(Array.isArray(t)){var n=t[e];return null==n?Array.isArray(i)?i[e]:i:n}return t}function ii(t,e){var i={}.toString.call(t);return 0===i.indexOf("[object")&&i.indexOf(e+"]")>-1}function ni(t,e){return"function"==typeof t?t.apply(void 0,e):t}function ri(t,e){return 0===e?t:function(n){clearTimeout(i),i=setTimeout((function(){t(n)}),e)};var i}function oi(t){return t.split(/\s+/).filter(Boolean)}function si(t){return[].concat(t)}function ai(t,e){-1===t.indexOf(e)&&t.push(e)}function li(t){return t.filter((function(e,i){return t.indexOf(e)===i}))}function ci(t){return t.split("-")[0]}function hi(t){return[].slice.call(t)}function di(t){return Object.keys(t).reduce((function(e,i){return void 0!==t[i]&&(e[i]=t[i]),e}),{})}function pi(){return document.createElement("div")}function ui(t){return["Element","Fragment"].some((function(e){return ii(t,e)}))}function gi(t){return ii(t,"NodeList")}function fi(t){return ii(t,"MouseEvent")}function mi(t){return!(!t||!t._tippy||t._tippy.reference!==t)}function vi(t){return ui(t)?[t]:gi(t)?hi(t):Array.isArray(t)?t:hi(document.querySelectorAll(t))}function bi(t,e){t.forEach((function(t){t&&(t.style.transitionDuration=e+"ms")}))}function yi(t,e){t.forEach((function(t){t&&t.setAttribute("data-state",e)}))}function _i(t){var e,i=si(t)[0];return null!=i&&null!=(e=i.ownerDocument)&&e.body?i.ownerDocument:document}function wi(t,e){var i=e.clientX,n=e.clientY;return t.every((function(t){var e=t.popperRect,r=t.popperState,o=t.props.interactiveBorder,s=ci(r.placement),a=r.modifiersData.offset;if(!a)return!0;var l="bottom"===s?a.top.y:0,c="top"===s?a.bottom.y:0,h="right"===s?a.left.x:0,d="left"===s?a.right.x:0,p=e.top-n+l>o,u=n-e.bottom-c>o,g=e.left-i+h>o,f=i-e.right-d>o;return p||u||g||f}))}function xi(t,e,i){var n=e+"EventListener";["transitionend","webkitTransitionEnd"].forEach((function(e){t[n](e,i)}))}function ki(t,e){for(var i=e;i;){var n;if(t.contains(i))return!0;i=null==i.getRootNode||null==(n=i.getRootNode())?void 0:n.host}return!1}var Ai={isTouch:!1},Si=0;function zi(){Ai.isTouch||(Ai.isTouch=!0,window.performance&&document.addEventListener("mousemove",Ci))}function Ci(){var t=performance.now();t-Si<20&&(Ai.isTouch=!1,document.removeEventListener("mousemove",Ci)),Si=t}function Ei(){var t=document.activeElement;if(mi(t)){var e=t._tippy;t.blur&&!e.state.isVisible&&t.blur()}}function Li(){document.addEventListener("touchstart",zi,Xe),window.addEventListener("blur",Ei)}var Mi=!!("undefined"!=typeof window&&"undefined"!=typeof document)&&!!window.msCrypto,Ti={animateFill:!1,followCursor:!1,inlinePositioning:!1,sticky:!1},Oi={allowHTML:!1,animation:"fade",arrow:!0,content:"",inertia:!1,maxWidth:350,role:"tooltip",theme:"",zIndex:9999},$i=Object.assign({appendTo:ti,aria:{content:"auto",expanded:"auto"},delay:0,duration:[300,250],getReferenceClientRect:null,hideOnClick:!0,ignoreAttributes:!1,interactive:!1,interactiveBorder:2,interactiveDebounce:0,moveTransition:"",offset:[0,10],onAfterUpdate:function(){},onBeforeUpdate:function(){},onCreate:function(){},onDestroy:function(){},onHidden:function(){},onHide:function(){},onMount:function(){},onShow:function(){},onShown:function(){},onTrigger:function(){},onUntrigger:function(){},onClickOutside:function(){},placement:"top",plugins:[],popperOptions:{},render:null,showOnCreate:!1,touch:!0,trigger:"mouseenter focus",triggerTarget:null},Ti,Oi),Hi=Object.keys($i),Ii=function(t){Object.keys(t).forEach((function(e){$i[e]=t[e]}))};function Ri(t){var e=(t.plugins||[]).reduce((function(e,i){var n,r=i.name,o=i.defaultValue;r&&(e[r]=void 0!==t[r]?t[r]:null!=(n=$i[r])?n:o);return e}),{});return Object.assign({},t,e)}function Pi(t,e){return(e?Object.keys(Ri(Object.assign({},$i,{plugins:e}))):Hi).reduce((function(e,i){var n=(t.getAttribute("data-tippy-"+i)||"").trim();if(!n)return e;if("content"===i)e[i]=n;else try{e[i]=JSON.parse(n)}catch(t){e[i]=n}return e}),{})}function Vi(t,e){var i=Object.assign({},e,{content:ni(e.content,[t])},e.ignoreAttributes?{}:Pi(t,e.plugins));return i.aria=Object.assign({},$i.aria,i.aria),i.aria={expanded:"auto"===i.aria.expanded?e.interactive:i.aria.expanded,content:"auto"===i.aria.content?e.interactive?null:"describedby":i.aria.content},i}var Fi=function(){return"innerHTML"};function Ni(t,e){t[Fi()]=e}function Di(t){var e=pi();return!0===t?e.className=Qe:(e.className=Je,ui(t)?e.appendChild(t):Ni(e,t)),e}function ji(t,e){ui(e.content)?(Ni(t,""),t.appendChild(e.content)):"function"!=typeof e.content&&(e.allowHTML?Ni(t,e.content):t.textContent=e.content)}function Bi(t){var e=t.firstElementChild,i=hi(e.children);return{box:e,content:i.find((function(t){return t.classList.contains(Ze)})),arrow:i.find((function(t){return t.classList.contains(Qe)||t.classList.contains(Je)})),backdrop:i.find((function(t){return t.classList.contains(Ke)}))}}function qi(t){var e=pi(),i=pi();i.className=Ge,i.setAttribute("data-state","hidden"),i.setAttribute("tabindex","-1");var n=pi();function r(i,n){var r=Bi(e),o=r.box,s=r.content,a=r.arrow;n.theme?o.setAttribute("data-theme",n.theme):o.removeAttribute("data-theme"),"string"==typeof n.animation?o.setAttribute("data-animation",n.animation):o.removeAttribute("data-animation"),n.inertia?o.setAttribute("data-inertia",""):o.removeAttribute("data-inertia"),o.style.maxWidth="number"==typeof n.maxWidth?n.maxWidth+"px":n.maxWidth,n.role?o.setAttribute("role",n.role):o.removeAttribute("role"),i.content===n.content&&i.allowHTML===n.allowHTML||ji(s,t.props),n.arrow?a?i.arrow!==n.arrow&&(o.removeChild(a),o.appendChild(Di(n.arrow))):o.appendChild(Di(n.arrow)):a&&o.removeChild(a)}return n.className=Ze,n.setAttribute("data-state","hidden"),ji(n,t.props),e.appendChild(i),i.appendChild(n),r(t.props,t.props),{popper:e,onUpdate:r}}qi.$$tippy=!0;var Ui=1,Wi=[],Yi=[];function Gi(t,e){var i,n,r,o,s,a,l,c=Vi(t,Object.assign({},$i,Ri(di(e)))),h=!1,d=!1,p=!1,u=!1,g=[],f=ri(K,c.interactiveDebounce),m=Ui++,v=null,b=li(c.plugins),y={isEnabled:!0,isVisible:!1,isDestroyed:!1,isMounted:!1,isShown:!1},_={id:m,reference:t,popper:pi(),popperInstance:v,props:c,state:y,plugins:b,clearDelayTimeouts:lt,setProps:ct,setContent:ht,show:dt,hide:pt,hideWithInteractivity:ut,enable:st,disable:at,unmount:gt,destroy:ft};if(!c.render)return _;var w=c.render(_),x=w.popper,k=w.onUpdate;x.setAttribute("data-tippy-root",""),x.id="tippy-"+_.id,_.popper=x,t._tippy=_,x._tippy=_;var A=b.map((function(t){return t.fn(_)})),S=t.hasAttribute("aria-expanded");return Y(),R(),$(),H("onCreate",[_]),c.showOnCreate&&rt(),x.addEventListener("mouseenter",(function(){_.props.interactive&&_.state.isVisible&&_.clearDelayTimeouts()})),x.addEventListener("mouseleave",(function(){_.props.interactive&&_.props.trigger.indexOf("mouseenter")>=0&&M().addEventListener("mousemove",f)})),_;function z(){var t=_.props.touch;return Array.isArray(t)?t:[t,0]}function C(){return"hold"===z()[0]}function E(){var t;return!(null==(t=_.props.render)||!t.$$tippy)}function L(){return l||t}function M(){var t=L().parentNode;return t?_i(t):document}function T(){return Bi(x)}function O(t){return _.state.isMounted&&!_.state.isVisible||Ai.isTouch||o&&"focus"===o.type?0:ei(_.props.delay,t?0:1,$i.delay)}function $(t){void 0===t&&(t=!1),x.style.pointerEvents=_.props.interactive&&!t?"":"none",x.style.zIndex=""+_.props.zIndex}function H(t,e,i){var n;(void 0===i&&(i=!0),A.forEach((function(i){i[t]&&i[t].apply(i,e)})),i)&&(n=_.props)[t].apply(n,e)}function I(){var e=_.props.aria;if(e.content){var i="aria-"+e.content,n=x.id;si(_.props.triggerTarget||t).forEach((function(t){var e=t.getAttribute(i);if(_.state.isVisible)t.setAttribute(i,e?e+" "+n:n);else{var r=e&&e.replace(n,"").trim();r?t.setAttribute(i,r):t.removeAttribute(i)}}))}}function R(){!S&&_.props.aria.expanded&&si(_.props.triggerTarget||t).forEach((function(t){_.props.interactive?t.setAttribute("aria-expanded",_.state.isVisible&&t===L()?"true":"false"):t.removeAttribute("aria-expanded")}))}function P(){M().removeEventListener("mousemove",f),Wi=Wi.filter((function(t){return t!==f}))}function V(e){if(!Ai.isTouch||!p&&"mousedown"!==e.type){var i=e.composedPath&&e.composedPath()[0]||e.target;if(!_.props.interactive||!ki(x,i)){if(si(_.props.triggerTarget||t).some((function(t){return ki(t,i)}))){if(Ai.isTouch)return;if(_.state.isVisible&&_.props.trigger.indexOf("click")>=0)return}else H("onClickOutside",[_,e]);!0===_.props.hideOnClick&&(_.clearDelayTimeouts(),_.hide(),d=!0,setTimeout((function(){d=!1})),_.state.isMounted||j())}}}function F(){p=!0}function N(){p=!1}function D(){var t=M();t.addEventListener("mousedown",V,!0),t.addEventListener("touchend",V,Xe),t.addEventListener("touchstart",N,Xe),t.addEventListener("touchmove",F,Xe)}function j(){var t=M();t.removeEventListener("mousedown",V,!0),t.removeEventListener("touchend",V,Xe),t.removeEventListener("touchstart",N,Xe),t.removeEventListener("touchmove",F,Xe)}function B(t,e){U(t,(function(){!_.state.isVisible&&x.parentNode&&x.parentNode.contains(x)&&e()}))}function q(t,e){U(t,e)}function U(t,e){var i=T().box;function n(t){t.target===i&&(xi(i,"remove",n),e())}if(0===t)return e();xi(i,"remove",s),xi(i,"add",n),s=n}function W(e,i,n){void 0===n&&(n=!1),si(_.props.triggerTarget||t).forEach((function(t){t.addEventListener(e,i,n),g.push({node:t,eventType:e,handler:i,options:n})}))}function Y(){C()&&(W("touchstart",Z,{passive:!0}),W("touchend",Q,{passive:!0})),oi(_.props.trigger).forEach((function(t){if("manual"!==t)switch(W(t,Z),t){case"mouseenter":W("mouseleave",Q);break;case"focus":W(Mi?"focusout":"blur",J);break;case"focusin":W("focusout",J)}}))}function G(){g.forEach((function(t){var e=t.node,i=t.eventType,n=t.handler,r=t.options;e.removeEventListener(i,n,r)})),g=[]}function Z(t){var e,i=!1;if(_.state.isEnabled&&!X(t)&&!d){var n="focus"===(null==(e=o)?void 0:e.type);o=t,l=t.currentTarget,R(),!_.state.isVisible&&fi(t)&&Wi.forEach((function(e){return e(t)})),"click"===t.type&&(_.props.trigger.indexOf("mouseenter")<0||h)&&!1!==_.props.hideOnClick&&_.state.isVisible?i=!0:rt(t),"click"===t.type&&(h=!i),i&&!n&&ot(t)}}function K(t){var e=t.target,i=L().contains(e)||x.contains(e);"mousemove"===t.type&&i||wi(nt().concat(x).map((function(t){var e,i=null==(e=t._tippy.popperInstance)?void 0:e.state;return i?{popperRect:t.getBoundingClientRect(),popperState:i,props:c}:null})).filter(Boolean),t)&&(P(),ot(t))}function Q(t){X(t)||_.props.trigger.indexOf("click")>=0&&h||(_.props.interactive?_.hideWithInteractivity(t):ot(t))}function J(t){_.props.trigger.indexOf("focusin")<0&&t.target!==L()||_.props.interactive&&t.relatedTarget&&x.contains(t.relatedTarget)||ot(t)}function X(t){return!!Ai.isTouch&&C()!==t.type.indexOf("touch")>=0}function tt(){et();var e=_.props,i=e.popperOptions,n=e.placement,r=e.offset,o=e.getReferenceClientRect,s=e.moveTransition,l=E()?Bi(x).arrow:null,c=o?{getBoundingClientRect:o,contextElement:o.contextElement||L()}:t,h=[{name:"offset",options:{offset:r}},{name:"preventOverflow",options:{padding:{top:2,bottom:2,left:5,right:5}}},{name:"flip",options:{padding:5}},{name:"computeStyles",options:{adaptive:!s}},{name:"$$tippy",enabled:!0,phase:"beforeWrite",requires:["computeStyles"],fn:function(t){var e=t.state;if(E()){var i=T().box;["placement","reference-hidden","escaped"].forEach((function(t){"placement"===t?i.setAttribute("data-placement",e.placement):e.attributes.popper["data-popper-"+t]?i.setAttribute("data-"+t,""):i.removeAttribute("data-"+t)})),e.attributes.popper={}}}}];E()&&l&&h.push({name:"arrow",options:{element:l,padding:3}}),h.push.apply(h,(null==i?void 0:i.modifiers)||[]),_.popperInstance=Ye(c,x,Object.assign({},i,{placement:n,onFirstUpdate:a,modifiers:h}))}function et(){_.popperInstance&&(_.popperInstance.destroy(),_.popperInstance=null)}function it(){var t,e=_.props.appendTo,i=L();(t=_.props.interactive&&e===ti||"parent"===e?i.parentNode:ni(e,[i])).contains(x)||t.appendChild(x),_.state.isMounted=!0,tt()}function nt(){return hi(x.querySelectorAll("[data-tippy-root]"))}function rt(t){_.clearDelayTimeouts(),t&&H("onTrigger",[_,t]),D();var e=O(!0),n=z(),r=n[0],o=n[1];Ai.isTouch&&"hold"===r&&o&&(e=o),e?i=setTimeout((function(){_.show()}),e):_.show()}function ot(t){if(_.clearDelayTimeouts(),H("onUntrigger",[_,t]),_.state.isVisible){if(!(_.props.trigger.indexOf("mouseenter")>=0&&_.props.trigger.indexOf("click")>=0&&["mouseleave","mousemove"].indexOf(t.type)>=0&&h)){var e=O(!1);e?n=setTimeout((function(){_.state.isVisible&&_.hide()}),e):r=requestAnimationFrame((function(){_.hide()}))}}else j()}function st(){_.state.isEnabled=!0}function at(){_.hide(),_.state.isEnabled=!1}function lt(){clearTimeout(i),clearTimeout(n),cancelAnimationFrame(r)}function ct(e){if(!_.state.isDestroyed){H("onBeforeUpdate",[_,e]),G();var i=_.props,n=Vi(t,Object.assign({},i,di(e),{ignoreAttributes:!0}));_.props=n,Y(),i.interactiveDebounce!==n.interactiveDebounce&&(P(),f=ri(K,n.interactiveDebounce)),i.triggerTarget&&!n.triggerTarget?si(i.triggerTarget).forEach((function(t){t.removeAttribute("aria-expanded")})):n.triggerTarget&&t.removeAttribute("aria-expanded"),R(),$(),k&&k(i,n),_.popperInstance&&(tt(),nt().forEach((function(t){requestAnimationFrame(t._tippy.popperInstance.forceUpdate)}))),H("onAfterUpdate",[_,e])}}function ht(t){_.setProps({content:t})}function dt(){var t=_.state.isVisible,e=_.state.isDestroyed,i=!_.state.isEnabled,n=Ai.isTouch&&!_.props.touch,r=ei(_.props.duration,0,$i.duration);if(!(t||e||i||n||L().hasAttribute("disabled")||(H("onShow",[_],!1),!1===_.props.onShow(_)))){if(_.state.isVisible=!0,E()&&(x.style.visibility="visible"),$(),D(),_.state.isMounted||(x.style.transition="none"),E()){var o=T();bi([o.box,o.content],0)}a=function(){var t;if(_.state.isVisible&&!u){if(u=!0,x.offsetHeight,x.style.transition=_.props.moveTransition,E()&&_.props.animation){var e=T(),i=e.box,n=e.content;bi([i,n],r),yi([i,n],"visible")}I(),R(),ai(Yi,_),null==(t=_.popperInstance)||t.forceUpdate(),H("onMount",[_]),_.props.animation&&E()&&q(r,(function(){_.state.isShown=!0,H("onShown",[_])}))}},it()}}function pt(){var t=!_.state.isVisible,e=_.state.isDestroyed,i=!_.state.isEnabled,n=ei(_.props.duration,1,$i.duration);if(!(t||e||i)&&(H("onHide",[_],!1),!1!==_.props.onHide(_))){if(_.state.isVisible=!1,_.state.isShown=!1,u=!1,h=!1,E()&&(x.style.visibility="hidden"),P(),j(),$(!0),E()){var r=T(),o=r.box,s=r.content;_.props.animation&&(bi([o,s],n),yi([o,s],"hidden"))}I(),R(),_.props.animation?E()&&B(n,_.unmount):_.unmount()}}function ut(t){M().addEventListener("mousemove",f),ai(Wi,f),f(t)}function gt(){_.state.isVisible&&_.hide(),_.state.isMounted&&(et(),nt().forEach((function(t){t._tippy.unmount()})),x.parentNode&&x.parentNode.removeChild(x),Yi=Yi.filter((function(t){return t!==_})),_.state.isMounted=!1,H("onHidden",[_]))}function ft(){_.state.isDestroyed||(_.clearDelayTimeouts(),_.unmount(),G(),delete t._tippy,_.state.isDestroyed=!0,H("onDestroy",[_]))}}function Zi(t,e){void 0===e&&(e={});var i=$i.plugins.concat(e.plugins||[]);Li();var n=Object.assign({},e,{plugins:i}),r=vi(t).reduce((function(t,e){var i=e&&Gi(e,n);return i&&t.push(i),t}),[]);return ui(t)?r[0]:r}function Ki(t){return t.replace(/(?:^\w|[A-Z]|\b\w)/g,(t,e)=>0==+t?"":0===e?t.toLowerCase():t.toUpperCase()).replace("-","")}Zi.defaultProps=$i,Zi.setDefaultProps=Ii,Zi.currentInput=Ai,Object.assign({},Et,{effect:function(t){var e=t.state,i={popper:{position:e.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};Object.assign(e.elements.popper.style,i.popper),e.styles=i,e.elements.arrow&&Object.assign(e.elements.arrow.style,i.arrow)}}),Zi.setDefaultProps({render:qi});const Qi='\n .tippy-box[data-animation=fade][data-state=hidden] {\n opacity: 0\n }\n\n .tippy-iOS {\n cursor: pointer!important;\n -webkit-tap-highlight-color: transparent\n }\n\n [data-tippy-root] {\n max-width: calc(100vw - 10px)\n }\n\n .tippy-box {\n position: relative;\n background-color: #333;\n color: #fff;\n border-radius: 4px;\n font-size: clamp(\n calc(var(--pb-popover-font-size, 1rem) * var(--pb-min-zoom, 0.5)), \n calc(var(--pb-popover-font-size, 1rem) * var(--pb-zoom-factor)), \n calc(var(--pb-popover-font-size, 1rem) * var(--pb-max-zoom, 3.0))\n );\n line-height: calc(var(--pb-popover-line-height, 1.5) * var(--pb-zoom-factor));\n\n text-align: left;\n font-style: normal;\n font-weight: normal;\n outline: 0;\n transition-property: transform, visibility, opacity;\n }\n\n .tippy-box[data-placement^=top]>.tippy-arrow {\n bottom: 0\n }\n\n .tippy-box[data-placement^=top]>.tippy-arrow:before {\n bottom: -7px;\n left: 0;\n border-width: 8px 8px 0;\n border-top-color: initial;\n transform-origin: center top\n }\n\n .tippy-box[data-placement^=bottom]>.tippy-arrow {\n top: 0\n }\n\n .tippy-box[data-placement^=bottom]>.tippy-arrow:before {\n top: -7px;\n left: 0;\n border-width: 0 8px 8px;\n border-bottom-color: initial;\n transform-origin: center bottom\n }\n\n .tippy-box[data-placement^=left]>.tippy-arrow {\n right: 0\n }\n\n .tippy-box[data-placement^=left]>.tippy-arrow:before {\n border-width: 8px 0 8px 8px;\n border-left-color: initial;\n right: -7px;\n transform-origin: center left\n }\n\n .tippy-box[data-placement^=right]>.tippy-arrow {\n left: 0\n }\n\n .tippy-box[data-placement^=right]>.tippy-arrow:before {\n left: -7px;\n border-width: 8px 8px 8px 0;\n border-right-color: initial;\n transform-origin: center right\n }\n\n .tippy-box[data-inertia][data-state=visible] {\n transition-timing-function: cubic-bezier(.54, 1.5, .38, 1.11)\n }\n\n .tippy-arrow {\n width: 16px;\n height: 16px;\n color: #333\n }\n\n .tippy-arrow:before {\n content: "";\n position: absolute;\n border-color: transparent;\n border-style: solid\n }\n\n .tippy-content {\n position: relative;\n padding: 5px 9px;\n z-index: 1;\n overflow: auto;\n max-height: var(--pb-popover-max-height, calc(100vh - 60px));\n min-height: var(--pb-popover-min-height, auto);\n max-width: var(--pb-popover-max-width, auto);\n min-width: var(--pb-popover-min-width, auto);\n color: var(--pb-popover-color);\n }\n',Ji='\n .tippy-box[data-theme~=light-border] {\n background-color: #fff;\n background-clip: padding-box;\n border: 1px solid rgba(0, 8, 16, .15);\n color: #333;\n box-shadow: 0 4px 14px -2px rgba(0, 8, 16, .08)\n }\n\n .tippy-box[data-theme~=light-border]>.tippy-backdrop {\n background-color: #fff\n }\n\n .tippy-box[data-theme~=light-border]>.tippy-arrow:after, .tippy-box[data-theme~=light-border]>.tippy-svg-arrow:after {\n content: "";\n position: absolute;\n z-index: -1\n }\n\n .tippy-box[data-theme~=light-border]>.tippy-arrow:after {\n border-color: transparent;\n border-style: solid\n }\n\n .tippy-box[data-theme~=light-border][data-placement^=top]>.tippy-arrow:before {\n border-top-color: #fff\n }\n\n .tippy-box[data-theme~=light-border][data-placement^=top]>.tippy-arrow:after {\n border-top-color: rgba(0, 8, 16, .2);\n border-width: 7px 7px 0;\n top: 17px;\n left: 1px\n }\n\n .tippy-box[data-theme~=light-border][data-placement^=top]>.tippy-svg-arrow>svg {\n top: 16px\n }\n\n .tippy-box[data-theme~=light-border][data-placement^=top]>.tippy-svg-arrow:after {\n top: 17px\n }\n\n .tippy-box[data-theme~=light-border][data-placement^=bottom]>.tippy-arrow:before {\n border-bottom-color: #fff;\n bottom: 16px\n }\n\n .tippy-box[data-theme~=light-border][data-placement^=bottom]>.tippy-arrow:after {\n border-bottom-color: rgba(0, 8, 16, .2);\n border-width: 0 7px 7px;\n bottom: 17px;\n left: 1px\n }\n\n .tippy-box[data-theme~=light-border][data-placement^=bottom]>.tippy-svg-arrow>svg {\n bottom: 16px\n }\n\n .tippy-box[data-theme~=light-border][data-placement^=bottom]>.tippy-svg-arrow:after {\n bottom: 17px\n }\n\n .tippy-box[data-theme~=light-border][data-placement^=left]>.tippy-arrow:before {\n border-left-color: #fff\n }\n\n .tippy-box[data-theme~=light-border][data-placement^=left]>.tippy-arrow:after {\n border-left-color: rgba(0, 8, 16, .2);\n border-width: 7px 0 7px 7px;\n left: 17px;\n top: 1px\n }\n\n .tippy-box[data-theme~=light-border][data-placement^=left]>.tippy-svg-arrow>svg {\n left: 11px\n }\n\n .tippy-box[data-theme~=light-border][data-placement^=left]>.tippy-svg-arrow:after {\n left: 12px\n }\n\n .tippy-box[data-theme~=light-border][data-placement^=right]>.tippy-arrow:before {\n border-right-color: #fff;\n right: 16px\n }\n\n .tippy-box[data-theme~=light-border][data-placement^=right]>.tippy-arrow:after {\n border-width: 7px 7px 7px 0;\n right: 17px;\n top: 1px;\n border-right-color: rgba(0, 8, 16, .2)\n }\n\n .tippy-box[data-theme~=light-border][data-placement^=right]>.tippy-svg-arrow>svg {\n right: 11px\n }\n\n .tippy-box[data-theme~=light-border][data-placement^=right]>.tippy-svg-arrow:after {\n right: 12px\n }\n\n .tippy-box[data-theme~=light-border]>.tippy-svg-arrow {\n fill: #fff\n }\n\n .tippy-box[data-theme~=light-border]>.tippy-svg-arrow:after {\n background-image: url(data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMTYiIGhlaWdodD0iNiIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj48cGF0aCBkPSJNMCA2czEuNzk2LS4wMTMgNC42Ny0zLjYxNUM1Ljg1MS45IDYuOTMuMDA2IDggMGMxLjA3LS4wMDYgMi4xNDguODg3IDMuMzQzIDIuMzg1QzE0LjIzMyA2LjAwNSAxNiA2IDE2IDZIMHoiIGZpbGw9InJnYmEoMCwgOCwgMTYsIDAuMikiLz48L3N2Zz4=);\n background-size: 16px 6px;\n width: 16px;\n height: 6px\n }\n',Xi="\n .tippy-box[data-theme~=light] {\n color: #26323d;\n box-shadow: 0 0 20px 4px rgba(154, 161, 177, .15), 0 4px 80px -8px rgba(36, 40, 47, .25), 0 4px 4px -2px rgba(91, 94, 105, .15);\n background-color: #fff\n }\n\n .tippy-box[data-theme~=light][data-placement^=top]>.tippy-arrow:before {\n border-top-color: #fff\n }\n\n .tippy-box[data-theme~=light][data-placement^=bottom]>.tippy-arrow:before {\n border-bottom-color: #fff\n }\n\n .tippy-box[data-theme~=light][data-placement^=left]>.tippy-arrow:before {\n border-left-color: #fff\n }\n\n .tippy-box[data-theme~=light][data-placement^=right]>.tippy-arrow:before {\n border-right-color: #fff\n }\n\n .tippy-box[data-theme~=light]>.tippy-backdrop {\n background-color: #fff\n }\n\n .tippy-box[data-theme~=light]>.tippy-svg-arrow {\n fill: #fff\n }",tn="\n .tippy-box[data-theme~=material] {\n background-color: #505355;\n font-weight: 600\n }\n\n .tippy-box[data-theme~=material][data-placement^=top]>.tippy-arrow:before {\n border-top-color: #505355\n }\n\n .tippy-box[data-theme~=material][data-placement^=bottom]>.tippy-arrow:before {\n border-bottom-color: #505355\n }\n\n .tippy-box[data-theme~=material][data-placement^=left]>.tippy-arrow:before {\n border-left-color: #505355\n }\n\n .tippy-box[data-theme~=material][data-placement^=right]>.tippy-arrow:before {\n border-right-color: #505355\n }\n\n .tippy-box[data-theme~=material]>.tippy-backdrop {\n background-color: #505355\n }\n\n .tippy-box[data-theme~=material]>.tippy-svg-arrow {\n fill: #505355\n }\n",en="\n .tippy-box[data-theme~=translucent] {\n background-color: rgba(0, 0, 0, .7)\n }\n\n .tippy-box[data-theme~=translucent]>.tippy-arrow {\n width: 14px;\n height: 14px\n }\n\n .tippy-box[data-theme~=translucent][data-placement^=top]>.tippy-arrow:before {\n border-width: 7px 7px 0;\n border-top-color: rgba(0, 0, 0, .7)\n }\n\n .tippy-box[data-theme~=translucent][data-placement^=bottom]>.tippy-arrow:before {\n border-width: 0 7px 7px;\n border-bottom-color: rgba(0, 0, 0, .7)\n }\n\n .tippy-box[data-theme~=translucent][data-placement^=left]>.tippy-arrow:before {\n border-width: 7px 0 7px 7px;\n border-left-color: rgba(0, 0, 0, .7)\n }\n\n .tippy-box[data-theme~=translucent][data-placement^=right]>.tippy-arrow:before {\n border-width: 7px 7px 7px 0;\n border-right-color: rgba(0, 0, 0, .7)\n }\n\n .tippy-box[data-theme~=translucent]>.tippy-backdrop {\n background-color: rgba(0, 0, 0, .7)\n }\n\n .tippy-box[data-theme~=translucent]>.tippy-svg-arrow {\n fill: rgba(0, 0, 0, .7)\n }\n";var nn=Object.freeze({__proto__:null,camelize:Ki,base:Qi,lightBorder:Ji,light:Xi,material:tn,translucent:en});function rn(t,e,i){if(!t.querySelector("#pb-popover-"+e)){const n=t.nodeType===Node.DOCUMENT_NODE?document.head:t;console.log("Loading tippy styles for theme %s into %o",e,n);const r=document.createElement("style");r.type="text/css",r.id="pb-popover-"+e,r.innerHTML=i,n.appendChild(r)}}function on(t,e){if(rn(t,"base",Qi),e&&"none"!==e){const i=Ki(e),n=nn[i];n&&rn(t,i,n)}}class sn extends(P(I)){static get properties(){return Object.assign(Object.assign({},super.properties),{},{for:{type:String},theme:{type:String},placement:{type:String},fallbackPlacement:{type:String,attribute:"fallback-placement"},persistent:{type:Boolean},trigger:{type:String},touch:{type:String},popupClass:{type:String,attribute:"popup-class"},remote:{type:String},stopPropagation:{type:Boolean,attribute:"stop-propagation"}})}constructor(){super(),this.persistent=!1,this.trigger=null,this.for=null,this.theme=null,this.placement=null,this.touch=null,this.fallbackPlacement=null,this.popupClass=null,this.stopPropagation=!1,this._tippy=null,this._content=null}render(){return this.for?T`<div class="hidden"><slot></slot></div>`:T`<span id="link" part="trigger" class="${this.persistent?"persistent":""}"
|
|
505
505
|
><slot name="default"><slot></slot></slot></span
|
|
506
506
|
><span class="hidden"><slot name="alternate"></slot></span>`}disconnectedCallback(){super.disconnectedCallback(),this._tippy&&this._tippy.destroy(),this._observer&&this._observer.disconnect()}_checkCSSProperties(){if(this.theme||"none"===this.theme||(this.theme=M(this,"--pb-popover-theme","none")),this.placement||(this.placement=M(this,"--pb-popover-placement","auto")),this.fallbackPlacement||(this.fallbackPlacement=M(this,"--pb-popover-fallback-placement",null)),this.persistent||(this.persistent=M(this,"--pb-popover-persistent",!1)),this.trigger||(this.trigger=M(this,"--pb-popover-trigger",null)),!this.touch){const t=M(this,"--pb-popover-touch","hold");this.touch="true"===t||t}}_injectStyles(){this._checkCSSProperties(),on(this.getRootNode(),this.theme)}_getContent(){if(this._content)return this._content;const t=this._getSlot();if(t){const e=document.createElement("div");return t.assignedNodes().forEach(t=>{e.appendChild(t.content?t.content.cloneNode(!0):t.cloneNode(!0))}),this._content=e,e}return null}_getSlot(){return this.for?this.shadowRoot.querySelector("slot"):this.shadowRoot.querySelector("[name=alternate]")}_registerMutationObserver(){const t=this._getSlot();this._observer=new MutationObserver(()=>{this.alternate=this._getContent(),console.log("alternate changed"),this.emitTo("pb-popover-changed",this.alternate)}),this._observer.observe(this,{subtree:!0,childList:!0,characterData:!0}),t&&t.assignedNodes().forEach(t=>{this._observer.observe(t.content?t.content:t,{subtree:!0,childList:!0,characterData:!0})})}get alternate(){return this._getContent()}set alternate(t){this._content=t,this._tippy&&this._tippy.setContent(this._content)}command(t,e){"disable"===t&&(this.disabled=e,this._tippy&&(e?this._tippy.disable():this._tippy.enable()))}firstUpdated(){super.firstUpdated(),this._injectStyles(),this._registerMutationObserver(),this.trigger||(this.trigger=this.persistent?"click":"mouseenter");const t=this.getRootNode();let e;if(this.for?(e=t.getElementById(this.for),e||console.error("<pb-popover> target element %s not found",this.for)):e=this.shadowRoot.getElementById("link"),e){const i={allowHTML:!0,appendTo:t.nodeType===Node.DOCUMENT_NODE?document.body:t,placement:this.placement,interactive:!0,ignoreAttributes:!0,boundary:"viewport",maxWidth:"none",touch:this.touch,hideOnClick:!1,trigger:this.trigger};if(this.stopPropagation&&(i.onTrigger=(t,e)=>{e.stopPropagation()}),this.persistent&&(i.onClickOutside=(t,e)=>{t.hideWithInteractivity(e)}),this.theme&&"none"!==this.theme&&(i.theme=this.theme),this.fallbackPlacement){const t=this.fallbackPlacement.split(" ");i.popperOptions={modifiers:[{name:"flip",options:{fallbackPlacements:t}}]}}this.popupClass&&(i.onCreate=t=>{t.popper.classList.add(this.popupClass)}),i.onShow=t=>{this.remote?this._loadRemoteContent():t.setContent(this._getContent()),this.emitTo("pb-popover-show",{source:this,popup:t})},this._tippy=Zi(e,i)}}_loadRemoteContent(){const t=this.toAbsoluteURL(this.remote);fetch(t,{method:"GET",mode:"cors",credentials:"same-origin"}).then(t=>t.text()).then(t=>{this.alternate=t}).catch(t=>{console.error("<pb-popover> Error retrieving remote content: %o",t)})}static get styles(){return[O`
|
|
507
507
|
:host {
|
|
@@ -524,7 +524,11 @@ const K=e`
|
|
|
524
524
|
#link.persistent {
|
|
525
525
|
cursor: pointer;
|
|
526
526
|
}
|
|
527
|
-
`]}}customElements.define("pb-popover",sn);class an extends(P(I)){static get properties(){return Object.assign(Object.assign({},super.properties),{},{key:{type:String},duration:{type:Number},scroll:{type:Boolean},highlightSelf:{type:Boolean,attribute:"highlight-self"},_className:{type:String}})}constructor(){super(),this.key=null,this.duration=0,this.scroll=!1,this.highlightSelf=!1,this._className="highlight-off"}connectedCallback(){super.connectedCallback(),this.subscribeTo("pb-highlight-on",this._highlightOn.bind(this)),this.subscribeTo("pb-highlight-off",this._highlightOff.bind(this))}command(t,e){super.command(t,e),this.disabled&&(this._className="highlight-off")}
|
|
527
|
+
`]}}customElements.define("pb-popover",sn);class an extends(P(I)){static get properties(){return Object.assign(Object.assign({},super.properties),{},{key:{type:String},duration:{type:Number},scroll:{type:Boolean},highlightSelf:{type:Boolean,attribute:"highlight-self"},trigger:{type:String},_className:{type:String}})}constructor(){super(),this.key=null,this.duration=0,this.scroll=!1,this.highlightSelf=!1,this.trigger="mouseenter",this._className="highlight-off"}_getTriggers(){return(this.trigger||"mouseenter").trim().split(/\s+/)}_isClickable(){return this._getTriggers().includes("click")}connectedCallback(){super.connectedCallback(),this.subscribeTo("pb-highlight-on",this._highlightOn.bind(this)),this.subscribeTo("pb-highlight-off",this._highlightOff.bind(this))}command(t,e){super.command(t,e),this.disabled&&(this._className="highlight-off")}_triggerHighlight(){this.emitTo("pb-highlight-off",{source:this}),this.highlightSelf&&this._highlightOn({detail:{id:this.key}}),this.emitTo("pb-highlight-on",{id:this.key,source:this,scroll:this.scroll||this._isClickable()})}render(){if(this.disabled)return T`<slot></slot>`;const t=this._getTriggers();return T`<span
|
|
528
|
+
id="content"
|
|
529
|
+
class="${this._className}${this._isClickable()?" clickable":""}"
|
|
530
|
+
@mouseenter="${t.includes("mouseenter")?this._triggerHighlight:null}"
|
|
531
|
+
@click="${t.includes("click")?this._triggerHighlight:null}"
|
|
528
532
|
><slot></slot
|
|
529
533
|
></span>`}static get styles(){return O`
|
|
530
534
|
:host {
|
|
@@ -555,7 +559,11 @@ const K=e`
|
|
|
555
559
|
.highlight-off {
|
|
556
560
|
background-color: inherit;
|
|
557
561
|
}
|
|
558
|
-
`}_highlightOn(t){t.detail.source!=this&&t.detail.id===this.key&&(this._className="highlight-on",t.detail.scroll&&0==this.disabled&&this.scrollIntoView({block:"center",behaviour:"smooth"}),this.duration>0&&setTimeout(()=>{this._className="highlight-off"},this.duration))}_highlightOff(t){t.detail.source!=this&&(this._className="highlight-off")}}function ln(t){for(var e=[],i=0;i<t.length;){var n=t[i];if("*"!==n&&"+"!==n&&"?"!==n)if("\\"!==n)if("{"!==n)if("}"!==n)if(":"!==n)if("("!==n)e.push({type:"CHAR",index:i,value:t[i++]});else{var r=1,o="";if("?"===t[a=i+1])throw new TypeError('Pattern cannot start with "?" at '.concat(a));for(;a<t.length;)if("\\"!==t[a]){if(")"===t[a]){if(0===--r){a++;break}}else if("("===t[a]&&(r++,"?"!==t[a+1]))throw new TypeError("Capturing groups are not allowed at ".concat(a));o+=t[a++]}else o+=t[a++]+t[a++];if(r)throw new TypeError("Unbalanced pattern at ".concat(i));if(!o)throw new TypeError("Missing pattern at ".concat(i));e.push({type:"PATTERN",index:i,value:o}),i=a}else{for(var s="",a=i+1;a<t.length;){var l=t.charCodeAt(a);if(!(l>=48&&l<=57||l>=65&&l<=90||l>=97&&l<=122||95===l))break;s+=t[a++]}if(!s)throw new TypeError("Missing parameter name at ".concat(i));e.push({type:"NAME",index:i,value:s}),i=a}else e.push({type:"CLOSE",index:i,value:t[i++]});else e.push({type:"OPEN",index:i,value:t[i++]});else e.push({type:"ESCAPED_CHAR",index:i++,value:t[i++]});else e.push({type:"MODIFIER",index:i,value:t[i++]})}return e.push({type:"END",index:i,value:""}),e}function cn(t,e){void 0===e&&(e={});for(var i=ln(t),n=e.prefixes,r=void 0===n?"./":n,o=e.delimiter,s=void 0===o?"/#?":o,a=[],l=0,c=0,h="",d=function(t){if(c<i.length&&i[c].type===t)return i[c++].value},p=function(t){var e=d(t);if(void 0!==e)return e;var n=i[c],r=n.type,o=n.index;throw new TypeError("Unexpected ".concat(r," at ").concat(o,", expected ").concat(t))},u=function(){for(var t,e="";t=d("CHAR")||d("ESCAPED_CHAR");)e+=t;return e},g=function(t){for(var e=0,i=s;e<i.length;e++){var n=i[e];if(t.indexOf(n)>-1)return!0}return!1},f=function(t){var e=a[a.length-1],i=t||(e&&"string"==typeof e?e:"");if(e&&!i)throw new TypeError('Must have text between two parameters, missing text after "'.concat(e.name,'"'));return!i||g(i)?"[^".concat(gn(s),"]+?"):"(?:(?!".concat(gn(i),")[^").concat(gn(s),"])+?")};c<i.length;){var m=d("CHAR"),v=d("NAME"),b=d("PATTERN");if(v||b){var y=m||"";-1===r.indexOf(y)&&(h+=y,y=""),h&&(a.push(h),h=""),a.push({name:v||l++,prefix:y,suffix:"",pattern:b||f(y),modifier:d("MODIFIER")||""})}else{var _=m||d("ESCAPED_CHAR");if(_)h+=_;else if(h&&(a.push(h),h=""),d("OPEN")){y=u();var w=d("NAME")||"",x=d("PATTERN")||"",k=u();p("CLOSE"),a.push({name:w||(x?l++:""),pattern:w&&!x?f(y):x,prefix:y,suffix:k,modifier:d("MODIFIER")||""})}else p("END")}}return a}function hn(t,e){return dn(cn(t,e),e)}function dn(t,e){void 0===e&&(e={});var i=fn(e),n=e.encode,r=void 0===n?function(t){return t}:n,o=e.validate,s=void 0===o||o,a=t.map((function(t){if("object"==typeof t)return new RegExp("^(?:".concat(t.pattern,")$"),i)}));return function(e){for(var i="",n=0;n<t.length;n++){var o=t[n];if("string"!=typeof o){var l=e?e[o.name]:void 0,c="?"===o.modifier||"*"===o.modifier,h="*"===o.modifier||"+"===o.modifier;if(Array.isArray(l)){if(!h)throw new TypeError('Expected "'.concat(o.name,'" to not repeat, but got an array'));if(0===l.length){if(c)continue;throw new TypeError('Expected "'.concat(o.name,'" to not be empty'))}for(var d=0;d<l.length;d++){var p=r(l[d],o);if(s&&!a[n].test(p))throw new TypeError('Expected all "'.concat(o.name,'" to match "').concat(o.pattern,'", but got "').concat(p,'"'));i+=o.prefix+p+o.suffix}}else if("string"!=typeof l&&"number"!=typeof l){if(!c){var u=h?"an array":"a string";throw new TypeError('Expected "'.concat(o.name,'" to be ').concat(u))}}else{p=r(String(l),o);if(s&&!a[n].test(p))throw new TypeError('Expected "'.concat(o.name,'" to match "').concat(o.pattern,'", but got "').concat(p,'"'));i+=o.prefix+p+o.suffix}}else i+=o}return i}}function pn(t,e){var i=[];return un(_n(t,i,e),i,e)}function un(t,e,i){void 0===i&&(i={});var n=i.decode,r=void 0===n?function(t){return t}:n;return function(i){var n=t.exec(i);if(!n)return!1;for(var o=n[0],s=n.index,a=Object.create(null),l=function(t){if(void 0===n[t])return"continue";var i=e[t-1];"*"===i.modifier||"+"===i.modifier?a[i.name]=n[t].split(i.prefix+i.suffix).map((function(t){return r(t,i)})):a[i.name]=r(n[t],i)},c=1;c<n.length;c++)l(c);return{path:o,index:s,params:a}}}function gn(t){return t.replace(/([.+*?=^!:${}()[\]|/\\])/g,"\\$1")}function fn(t){return t&&t.sensitive?"":"i"}function mn(t,e){if(!e)return t;for(var i=/\((?:\?<(.*?)>)?(?!\?)/g,n=0,r=i.exec(t.source);r;)e.push({name:r[1]||n++,prefix:"",suffix:"",modifier:"",pattern:""}),r=i.exec(t.source);return t}function vn(t,e,i){var n=t.map((function(t){return _n(t,e,i).source}));return new RegExp("(?:".concat(n.join("|"),")"),fn(i))}function bn(t,e,i){return yn(cn(t,i),e,i)}function yn(t,e,i){void 0===i&&(i={});for(var n=i.strict,r=void 0!==n&&n,o=i.start,s=void 0===o||o,a=i.end,l=void 0===a||a,c=i.encode,h=void 0===c?function(t){return t}:c,d=i.delimiter,p=void 0===d?"/#?":d,u=i.endsWith,g="[".concat(gn(void 0===u?"":u),"]|$"),f="[".concat(gn(p),"]"),m=s?"^":"",v=0,b=t;v<b.length;v++){var y=b[v];if("string"==typeof y)m+=gn(h(y));else{var _=gn(h(y.prefix)),w=gn(h(y.suffix));if(y.pattern)if(e&&e.push(y),_||w)if("+"===y.modifier||"*"===y.modifier){var x="*"===y.modifier?"?":"";m+="(?:".concat(_,"((?:").concat(y.pattern,")(?:").concat(w).concat(_,"(?:").concat(y.pattern,"))*)").concat(w,")").concat(x)}else m+="(?:".concat(_,"(").concat(y.pattern,")").concat(w,")").concat(y.modifier);else{if("+"===y.modifier||"*"===y.modifier)throw new TypeError('Can not repeat "'.concat(y.name,'" without a prefix and suffix'));m+="(".concat(y.pattern,")").concat(y.modifier)}else m+="(?:".concat(_).concat(w,")").concat(y.modifier)}}if(l)r||(m+="".concat(f,"?")),m+=i.endsWith?"(?=".concat(g,")"):"$";else{var k=t[t.length-1],A="string"==typeof k?f.indexOf(k[k.length-1])>-1:void 0===k;r||(m+="(?:".concat(f,"(?=").concat(g,"))?")),A||(m+="(?=".concat(f,"|").concat(g,")"))}return new RegExp(m,fn(i))}function _n(t,e,i){return t instanceof RegExp?mn(t,e):Array.isArray(t)?vn(t,e,i):bn(t,e,i)}function wn(...t){t[0]="%c<registry>%c "+t[0],t.splice(1,0,"font-weight: bold; color: #99FF33;","color: inherit; font-weight: normal"),console.log.apply(null,t)}customElements.define("pb-highlight",an);class xn{constructor(){this.rootPath="",this.usePath=!1,this.state={},this.channelStates={},this.hash=null,this.idHash=!0,this._listeners=[],this.urlPattern=null,this.urlIgnore=new Set,this.pathParams=new Set,this.currentUser=null}configure(t=!0,e=!1,i="",n,r){if(this.rootPath=i,this.usePath=t,this.idHash=e,this.urlPattern=n,r&&r.split(/\s*,\s*/).forEach(t=>this.urlIgnore.add(t)),this.urlPattern){const t=[];_n(this.urlPattern,t),t.forEach(t=>this.pathParams.add(t.name)),this._decodePath=pn(this.urlPattern),this._encodePath=hn(this.urlPattern)}const o=this._stateFromURL();o?this.state=o:console.error("<registry> failed to parse URL: %s using template %s",window.location,this.urlTemplate),window.history.replaceState(null,""),window.addEventListener("popstate",t=>{if(t.state){try{this.channelStates=JSON.parse(t.state)}catch(t){return void console.error("<registry> error restoring state: %s",t.toString())}this.state=this._stateFromURL(),wn("popstate: %o",this.channelStates),this._listeners.forEach(t=>{t.callback(this.getState(t.component))}),nt.emit("pb-popstate",null,this.channelStates)}})}subscribe(t,e){this._listeners.push({component:t,callback:e})}_stateFromURL(){const t={};this.hash=window.location.hash,this.idHash&&this.hash.length>0&&!/^#\d+\./.test(this.hash)&&(t.id=this.hash.substring(1));const e=window.location.pathname.replace(new RegExp(`^${this.rootPath}/?`),"");if(this.urlPattern){const i=this._decodePath(e);Object.assign(t,i.params),wn("decoded path %s using template %s: %o",e,this.urlPattern,t)}else this.usePath&&(t.path=e);const i=new URLSearchParams(window.location.search);return i.forEach((e,n)=>{if(this.urlPattern&&this.pathParams.has(n)||this.usePath&&"path"===n)return void console.warn("Found path parameter in query, but usePath is set to true. The path parameter will be ignored.");if(n in t)return;const r=i.getAll(n);1===r.length?t[n]=e:t[n]=r}),t}getState(t){const e=V(t)[0],i=this.channelStates[e];return i||(this.channelStates[e]={},this.channelStates[e])}setState(t,e){const i=V(t)[0];this.channelStates[i]=Object.assign(this.channelStates[i],e)}clearParametersMatching(t,e){const{state:i}=this;for(const t of Object.keys(i))e.test(t)&&(i[t]=null)}get(t,e){if(!this.state)return;return t.split(".").reduce((t,e)=>{if(t[e])return t[e]},this.state)||e}set(t,e){if(!t.contains("."))return void(this.state[t]=e);const i=t.split("."),n=i.pop();i.reduce((t,e)=>(t[e]||(t[e]={}),t[e]),this.state)[n]=e}commit(t,e,i=!1){this._commit(t,e,i,!1)}replace(t,e,i=!1){this._commit(t,e,i,!0)}_commit(t,e,i,n){this.state=i?e:Object.assign(Object.assign({},this.state),e);const r=this.urlFromState();V(t).forEach(t=>{i||!this.channelStates[t]?this.channelStates[t]=e:Object.assign(this.channelStates[t],e)});const o=this.toJSON();n?(window.history.replaceState(o,"",r),wn("replace %s: %o %d",r.toString(),this.channelStates,window.history.length)):(window.history.pushState(o,"",r),wn("commit %s: %o %d",r.toString(),this.channelStates,window.history.length))}urlFromState(){const t=new URL(window.location.href);function e(e,i){if(null===e)t.searchParams.delete(i);else if(Array.isArray(e)){const n=Array.from(e);t.searchParams.set(i,n.pop()),n.forEach(e=>t.searchParams.append(i,e))}else t.searchParams.set(i,e)}for(const[t,i]of Object.entries(this.state))if(this.urlPattern){const n=t.replace(/^(?:user\.)?(.*)$/,"$1");this.pathParams.has(n)||this.urlIgnore.has(n)||e(i,n)}else"path"===t&&this.usePath||"id"===t&&this.idHash||this.urlIgnore.has(t)||e(i,t);if(this.state.path&&this.state.path.length>0)if(this.urlPattern){const e={};for(const[t,i]of Object.entries(this.state))this.pathParams.has(t)&&""===i?e[t]=null:e[t]=i;const i=this._encodePath(e);t.pathname=`${this.rootPath}/${i}`}else this.usePath&&(t.pathname=`${this.rootPath}/${this.state.path}`);return this.state.id&&!this.urlPattern&&(t.hash="#"+this.state.id),t}toJSON(){return JSON.stringify(this.channelStates)}}const kn=new xn;window.pbRegistry||(window.pbRegistry=kn);class An extends(P(I)){static get properties(){return Object.assign(Object.assign({},super.properties),{},{xmlId:{type:String,attribute:"xml-id"},nodeId:{type:String,attribute:"node-id",reflect:!0},hash:{type:String,reflect:!0},xpath:{type:String,reflect:!0},path:{type:String},odd:{type:String},view:{type:String},params:{type:Object},history:{type:Boolean}})}constructor(){super(),this.history=!0,this.params=null}connectedCallback(){super.connectedCallback(),this._id=this.nodeId,this.subscribeTo("pb-visible",t=>{if(this.nodeId){const[e,i]=t.detail.data.split(/\s*,\s*/);this.nodeId!==e||this.hash&&this.hash!==i?this.classList.remove("active"):(this.classList.add("active"),this.scrollIntoView({block:"nearest"}),this.dispatchEvent(new CustomEvent("pb-collapse-open",{composed:!0,bubbles:!0})))}}),this._content=this.innerHTML}render(){return T`<a href="#" @click="${this._onClick}">${W(this._content)}</a>`}createRenderRoot(){return this}_onClick(t){t.preventDefault();const e={id:null,root:null};this.xmlId?e.id=this.xmlId:this.nodeId&&(e.root=this.nodeId),this.path&&(e.path=this.path),this.odd&&(e.odd=this.odd),this.hash&&(e.hash=this.hash),this.view&&(e.view=this.view),this.xpath&&(e.xpath=this.xpath),this.params&&Object.assign(e,this.params),this.history&&kn.commit(this,e),this.emitTo("pb-refresh",e)}}customElements.define("pb-link",An);class Sn extends(P(I)){static get properties(){return Object.assign(Object.assign({},super.properties),{},{facs:{type:String},coordinates:{type:Array},label:{type:String},order:{type:Number},trigger:{type:String},emitOnLoad:{type:Boolean,attribute:"emit-on-load"}})}constructor(){super(),this.trigger="mouseover",this.label="",this.order=Number.POSITIVE_INFINITY,this.waitFor="pb-facsimile,pb-image-strip,pb-tify",this.default=""}connectedCallback(){super.connectedCallback(),this.wait(()=>{this.emitTo("pb-load-facsimile",{url:this.getImage(),order:this.getOrder(),element:this})})}getImage(){return this.facs}getLabel(){return this.label}getOrder(){return this.order}firstUpdated(){this.shadowRoot.querySelector("a").addEventListener(this.trigger,this._linkListener.bind(this)),this.emitOnLoad&&this.wait(()=>{this._trigger()})}render(){return T`<a href="javascript:;"><slot>${this.default}</slot></a>`}static get styles(){return O`
|
|
562
|
+
|
|
563
|
+
.clickable {
|
|
564
|
+
cursor: pointer;
|
|
565
|
+
}
|
|
566
|
+
`}_highlightOn(t){t.detail.source!=this&&t.detail.id===this.key&&(this._className="highlight-on",t.detail.scroll&&0==this.disabled&&this.scrollIntoView({block:"center",behavior:"smooth"}),this.duration>0&&setTimeout(()=>{this._className="highlight-off"},this.duration))}_highlightOff(t){t.detail.source!=this&&(this._className="highlight-off")}}function ln(t){for(var e=[],i=0;i<t.length;){var n=t[i];if("*"!==n&&"+"!==n&&"?"!==n)if("\\"!==n)if("{"!==n)if("}"!==n)if(":"!==n)if("("!==n)e.push({type:"CHAR",index:i,value:t[i++]});else{var r=1,o="";if("?"===t[a=i+1])throw new TypeError('Pattern cannot start with "?" at '.concat(a));for(;a<t.length;)if("\\"!==t[a]){if(")"===t[a]){if(0===--r){a++;break}}else if("("===t[a]&&(r++,"?"!==t[a+1]))throw new TypeError("Capturing groups are not allowed at ".concat(a));o+=t[a++]}else o+=t[a++]+t[a++];if(r)throw new TypeError("Unbalanced pattern at ".concat(i));if(!o)throw new TypeError("Missing pattern at ".concat(i));e.push({type:"PATTERN",index:i,value:o}),i=a}else{for(var s="",a=i+1;a<t.length;){var l=t.charCodeAt(a);if(!(l>=48&&l<=57||l>=65&&l<=90||l>=97&&l<=122||95===l))break;s+=t[a++]}if(!s)throw new TypeError("Missing parameter name at ".concat(i));e.push({type:"NAME",index:i,value:s}),i=a}else e.push({type:"CLOSE",index:i,value:t[i++]});else e.push({type:"OPEN",index:i,value:t[i++]});else e.push({type:"ESCAPED_CHAR",index:i++,value:t[i++]});else e.push({type:"MODIFIER",index:i,value:t[i++]})}return e.push({type:"END",index:i,value:""}),e}function cn(t,e){void 0===e&&(e={});for(var i=ln(t),n=e.prefixes,r=void 0===n?"./":n,o=e.delimiter,s=void 0===o?"/#?":o,a=[],l=0,c=0,h="",d=function(t){if(c<i.length&&i[c].type===t)return i[c++].value},p=function(t){var e=d(t);if(void 0!==e)return e;var n=i[c],r=n.type,o=n.index;throw new TypeError("Unexpected ".concat(r," at ").concat(o,", expected ").concat(t))},u=function(){for(var t,e="";t=d("CHAR")||d("ESCAPED_CHAR");)e+=t;return e},g=function(t){for(var e=0,i=s;e<i.length;e++){var n=i[e];if(t.indexOf(n)>-1)return!0}return!1},f=function(t){var e=a[a.length-1],i=t||(e&&"string"==typeof e?e:"");if(e&&!i)throw new TypeError('Must have text between two parameters, missing text after "'.concat(e.name,'"'));return!i||g(i)?"[^".concat(gn(s),"]+?"):"(?:(?!".concat(gn(i),")[^").concat(gn(s),"])+?")};c<i.length;){var m=d("CHAR"),v=d("NAME"),b=d("PATTERN");if(v||b){var y=m||"";-1===r.indexOf(y)&&(h+=y,y=""),h&&(a.push(h),h=""),a.push({name:v||l++,prefix:y,suffix:"",pattern:b||f(y),modifier:d("MODIFIER")||""})}else{var _=m||d("ESCAPED_CHAR");if(_)h+=_;else if(h&&(a.push(h),h=""),d("OPEN")){y=u();var w=d("NAME")||"",x=d("PATTERN")||"",k=u();p("CLOSE"),a.push({name:w||(x?l++:""),pattern:w&&!x?f(y):x,prefix:y,suffix:k,modifier:d("MODIFIER")||""})}else p("END")}}return a}function hn(t,e){return dn(cn(t,e),e)}function dn(t,e){void 0===e&&(e={});var i=fn(e),n=e.encode,r=void 0===n?function(t){return t}:n,o=e.validate,s=void 0===o||o,a=t.map((function(t){if("object"==typeof t)return new RegExp("^(?:".concat(t.pattern,")$"),i)}));return function(e){for(var i="",n=0;n<t.length;n++){var o=t[n];if("string"!=typeof o){var l=e?e[o.name]:void 0,c="?"===o.modifier||"*"===o.modifier,h="*"===o.modifier||"+"===o.modifier;if(Array.isArray(l)){if(!h)throw new TypeError('Expected "'.concat(o.name,'" to not repeat, but got an array'));if(0===l.length){if(c)continue;throw new TypeError('Expected "'.concat(o.name,'" to not be empty'))}for(var d=0;d<l.length;d++){var p=r(l[d],o);if(s&&!a[n].test(p))throw new TypeError('Expected all "'.concat(o.name,'" to match "').concat(o.pattern,'", but got "').concat(p,'"'));i+=o.prefix+p+o.suffix}}else if("string"!=typeof l&&"number"!=typeof l){if(!c){var u=h?"an array":"a string";throw new TypeError('Expected "'.concat(o.name,'" to be ').concat(u))}}else{p=r(String(l),o);if(s&&!a[n].test(p))throw new TypeError('Expected "'.concat(o.name,'" to match "').concat(o.pattern,'", but got "').concat(p,'"'));i+=o.prefix+p+o.suffix}}else i+=o}return i}}function pn(t,e){var i=[];return un(_n(t,i,e),i,e)}function un(t,e,i){void 0===i&&(i={});var n=i.decode,r=void 0===n?function(t){return t}:n;return function(i){var n=t.exec(i);if(!n)return!1;for(var o=n[0],s=n.index,a=Object.create(null),l=function(t){if(void 0===n[t])return"continue";var i=e[t-1];"*"===i.modifier||"+"===i.modifier?a[i.name]=n[t].split(i.prefix+i.suffix).map((function(t){return r(t,i)})):a[i.name]=r(n[t],i)},c=1;c<n.length;c++)l(c);return{path:o,index:s,params:a}}}function gn(t){return t.replace(/([.+*?=^!:${}()[\]|/\\])/g,"\\$1")}function fn(t){return t&&t.sensitive?"":"i"}function mn(t,e){if(!e)return t;for(var i=/\((?:\?<(.*?)>)?(?!\?)/g,n=0,r=i.exec(t.source);r;)e.push({name:r[1]||n++,prefix:"",suffix:"",modifier:"",pattern:""}),r=i.exec(t.source);return t}function vn(t,e,i){var n=t.map((function(t){return _n(t,e,i).source}));return new RegExp("(?:".concat(n.join("|"),")"),fn(i))}function bn(t,e,i){return yn(cn(t,i),e,i)}function yn(t,e,i){void 0===i&&(i={});for(var n=i.strict,r=void 0!==n&&n,o=i.start,s=void 0===o||o,a=i.end,l=void 0===a||a,c=i.encode,h=void 0===c?function(t){return t}:c,d=i.delimiter,p=void 0===d?"/#?":d,u=i.endsWith,g="[".concat(gn(void 0===u?"":u),"]|$"),f="[".concat(gn(p),"]"),m=s?"^":"",v=0,b=t;v<b.length;v++){var y=b[v];if("string"==typeof y)m+=gn(h(y));else{var _=gn(h(y.prefix)),w=gn(h(y.suffix));if(y.pattern)if(e&&e.push(y),_||w)if("+"===y.modifier||"*"===y.modifier){var x="*"===y.modifier?"?":"";m+="(?:".concat(_,"((?:").concat(y.pattern,")(?:").concat(w).concat(_,"(?:").concat(y.pattern,"))*)").concat(w,")").concat(x)}else m+="(?:".concat(_,"(").concat(y.pattern,")").concat(w,")").concat(y.modifier);else{if("+"===y.modifier||"*"===y.modifier)throw new TypeError('Can not repeat "'.concat(y.name,'" without a prefix and suffix'));m+="(".concat(y.pattern,")").concat(y.modifier)}else m+="(?:".concat(_).concat(w,")").concat(y.modifier)}}if(l)r||(m+="".concat(f,"?")),m+=i.endsWith?"(?=".concat(g,")"):"$";else{var k=t[t.length-1],A="string"==typeof k?f.indexOf(k[k.length-1])>-1:void 0===k;r||(m+="(?:".concat(f,"(?=").concat(g,"))?")),A||(m+="(?=".concat(f,"|").concat(g,")"))}return new RegExp(m,fn(i))}function _n(t,e,i){return t instanceof RegExp?mn(t,e):Array.isArray(t)?vn(t,e,i):bn(t,e,i)}function wn(...t){t[0]="%c<registry>%c "+t[0],t.splice(1,0,"font-weight: bold; color: #99FF33;","color: inherit; font-weight: normal"),console.log.apply(null,t)}customElements.define("pb-highlight",an);class xn{constructor(){this.rootPath="",this.usePath=!1,this.state={},this.channelStates={},this.hash=null,this.idHash=!0,this._listeners=[],this.urlPattern=null,this.urlIgnore=new Set,this.pathParams=new Set,this.currentUser=null}configure(t=!0,e=!1,i="",n,r){if(this.rootPath=i,this.usePath=t,this.idHash=e,this.urlPattern=n,r&&r.split(/\s*,\s*/).forEach(t=>this.urlIgnore.add(t)),this.urlPattern){const t=[];_n(this.urlPattern,t),t.forEach(t=>this.pathParams.add(t.name)),this._decodePath=pn(this.urlPattern),this._encodePath=hn(this.urlPattern)}const o=this._stateFromURL();o?this.state=o:console.error("<registry> failed to parse URL: %s using template %s",window.location,this.urlTemplate),window.history.replaceState(null,""),window.addEventListener("popstate",t=>{if(t.state){try{this.channelStates=JSON.parse(t.state)}catch(t){return void console.error("<registry> error restoring state: %s",t.toString())}this.state=this._stateFromURL(),wn("popstate: %o",this.channelStates),this._listeners.forEach(t=>{t.callback(this.getState(t.component))}),nt.emit("pb-popstate",null,this.channelStates)}})}subscribe(t,e){this._listeners.push({component:t,callback:e})}_stateFromURL(){const t={};this.hash=window.location.hash,this.idHash&&this.hash.length>0&&!/^#\d+\./.test(this.hash)&&(t.id=this.hash.substring(1));const e=window.location.pathname.replace(new RegExp(`^${this.rootPath}/?`),"");if(this.urlPattern){const i=this._decodePath(e);Object.assign(t,i.params),wn("decoded path %s using template %s: %o",e,this.urlPattern,t)}else this.usePath&&(t.path=e);const i=new URLSearchParams(window.location.search);return i.forEach((e,n)=>{if(this.urlPattern&&this.pathParams.has(n)||this.usePath&&"path"===n)return void console.warn("Found path parameter in query, but usePath is set to true. The path parameter will be ignored.");if(n in t)return;const r=i.getAll(n);1===r.length?t[n]=e:t[n]=r}),t}getState(t){const e=V(t)[0],i=this.channelStates[e];return i||(this.channelStates[e]={},this.channelStates[e])}setState(t,e){const i=V(t)[0];this.channelStates[i]=Object.assign(this.channelStates[i],e)}clearParametersMatching(t,e){const{state:i}=this;for(const t of Object.keys(i))e.test(t)&&(i[t]=null)}get(t,e){if(!this.state)return;return t.split(".").reduce((t,e)=>{if(t[e])return t[e]},this.state)||e}set(t,e){if(!t.contains("."))return void(this.state[t]=e);const i=t.split("."),n=i.pop();i.reduce((t,e)=>(t[e]||(t[e]={}),t[e]),this.state)[n]=e}commit(t,e,i=!1){this._commit(t,e,i,!1)}replace(t,e,i=!1){this._commit(t,e,i,!0)}_commit(t,e,i,n){this.state=i?e:Object.assign(Object.assign({},this.state),e);const r=this.urlFromState();V(t).forEach(t=>{i||!this.channelStates[t]?this.channelStates[t]=e:Object.assign(this.channelStates[t],e)});const o=this.toJSON();n?(window.history.replaceState(o,"",r),wn("replace %s: %o %d",r.toString(),this.channelStates,window.history.length)):(window.history.pushState(o,"",r),wn("commit %s: %o %d",r.toString(),this.channelStates,window.history.length))}urlFromState(){const t=new URL(window.location.href);function e(e,i){if(null===e)t.searchParams.delete(i);else if(Array.isArray(e)){const n=Array.from(e);t.searchParams.set(i,n.pop()),n.forEach(e=>t.searchParams.append(i,e))}else t.searchParams.set(i,e)}for(const[t,i]of Object.entries(this.state))if(this.urlPattern){const n=t.replace(/^(?:user\.)?(.*)$/,"$1");this.pathParams.has(n)||this.urlIgnore.has(n)||e(i,n)}else"path"===t&&this.usePath||"id"===t&&this.idHash||this.urlIgnore.has(t)||e(i,t);if(this.state.path&&this.state.path.length>0)if(this.urlPattern){const e={};for(const[t,i]of Object.entries(this.state))this.pathParams.has(t)&&""===i?e[t]=null:e[t]=i;const i=this._encodePath(e);t.pathname=`${this.rootPath}/${i}`}else this.usePath&&(t.pathname=`${this.rootPath}/${this.state.path}`);return this.state.id&&!this.urlPattern&&(t.hash="#"+this.state.id),t}toJSON(){return JSON.stringify(this.channelStates)}}const kn=new xn;window.pbRegistry||(window.pbRegistry=kn);class An extends(P(I)){static get properties(){return Object.assign(Object.assign({},super.properties),{},{xmlId:{type:String,attribute:"xml-id"},nodeId:{type:String,attribute:"node-id",reflect:!0},hash:{type:String,reflect:!0},xpath:{type:String,reflect:!0},path:{type:String},odd:{type:String},view:{type:String},params:{type:Object},history:{type:Boolean}})}constructor(){super(),this.history=!0,this.params=null}connectedCallback(){super.connectedCallback(),this._id=this.nodeId,this.subscribeTo("pb-visible",t=>{if(this.nodeId){const[e,i]=t.detail.data.split(/\s*,\s*/);this.nodeId!==e||this.hash&&this.hash!==i?this.classList.remove("active"):(this.classList.add("active"),this.scrollIntoView({block:"nearest"}),this.dispatchEvent(new CustomEvent("pb-collapse-open",{composed:!0,bubbles:!0})))}}),this._content=this.innerHTML}render(){return T`<a href="#" @click="${this._onClick}">${W(this._content)}</a>`}createRenderRoot(){return this}_onClick(t){t.preventDefault();const e={id:null,root:null};this.xmlId?e.id=this.xmlId:this.nodeId&&(e.root=this.nodeId),this.path&&(e.path=this.path),this.odd&&(e.odd=this.odd),this.hash&&(e.hash=this.hash),this.view&&(e.view=this.view),this.xpath&&(e.xpath=this.xpath),this.params&&Object.assign(e,this.params),this.history&&kn.commit(this,e),this.emitTo("pb-refresh",e)}}customElements.define("pb-link",An);class Sn extends(P(I)){static get properties(){return Object.assign(Object.assign({},super.properties),{},{facs:{type:String},coordinates:{type:Array},label:{type:String},order:{type:Number},trigger:{type:String},emitOnLoad:{type:Boolean,attribute:"emit-on-load"}})}constructor(){super(),this.trigger="mouseover",this.label="",this.order=Number.POSITIVE_INFINITY,this.waitFor="pb-facsimile,pb-image-strip,pb-tify",this.default=""}connectedCallback(){super.connectedCallback(),this.wait(()=>{this.emitTo("pb-load-facsimile",{url:this.getImage(),order:this.getOrder(),element:this})})}getImage(){return this.facs}getLabel(){return this.label}getOrder(){return this.order}firstUpdated(){this.shadowRoot.querySelector("a").addEventListener(this.trigger,this._linkListener.bind(this)),this.emitOnLoad&&this.wait(()=>{this._trigger()})}render(){return T`<a href="javascript:;"><slot>${this.default}</slot></a>`}static get styles(){return O`
|
|
559
567
|
:host {
|
|
560
568
|
}
|
|
561
569
|
|
package/dist/pb-elements.json
CHANGED
|
@@ -4743,6 +4743,12 @@
|
|
|
4743
4743
|
"type": "boolean",
|
|
4744
4744
|
"default": "false"
|
|
4745
4745
|
},
|
|
4746
|
+
{
|
|
4747
|
+
"name": "trigger",
|
|
4748
|
+
"description": "Defines one or more actions (space separated) which should cause\nthe highlight to show. Default is `mouseenter`. If `click` is among the triggers, matching elements scroll into view.",
|
|
4749
|
+
"type": "\"click\" | \"mouseenter\"",
|
|
4750
|
+
"default": "\"mouseenter\""
|
|
4751
|
+
},
|
|
4746
4752
|
{
|
|
4747
4753
|
"name": "subscribe",
|
|
4748
4754
|
"description": "The name of the channel to subscribe to. Only events on a channel corresponding\nto this property are listened to.",
|
|
@@ -4842,6 +4848,13 @@
|
|
|
4842
4848
|
"type": "boolean",
|
|
4843
4849
|
"default": "false"
|
|
4844
4850
|
},
|
|
4851
|
+
{
|
|
4852
|
+
"name": "trigger",
|
|
4853
|
+
"attribute": "trigger",
|
|
4854
|
+
"description": "Defines one or more actions (space separated) which should cause\nthe highlight to show. Default is `mouseenter`. If `click` is among the triggers, matching elements scroll into view.",
|
|
4855
|
+
"type": "\"click\" | \"mouseenter\"",
|
|
4856
|
+
"default": "\"mouseenter\""
|
|
4857
|
+
},
|
|
4845
4858
|
{
|
|
4846
4859
|
"name": "subscribe",
|
|
4847
4860
|
"attribute": "subscribe",
|
|
@@ -5185,7 +5198,7 @@
|
|
|
5185
5198
|
{
|
|
5186
5199
|
"name": "pb-highlight",
|
|
5187
5200
|
"path": "./src/pb-highlight.js",
|
|
5188
|
-
"description": "Link elements to each other:
|
|
5201
|
+
"description": "Link elements to each other: when a trigger action occurs on one element,\nthe others are highlighted by changing their background color. Which elements\nare linked is determined by the `key` property: elements with the same key\nare linked. The trigger action is configured via the `trigger` property and\nsends a `pb-highlight-on` event. Other elements with the same key react to this event.\n\n`pb-highlight` should be output for relevant elements via ODD processing model.",
|
|
5189
5202
|
"attributes": [
|
|
5190
5203
|
{
|
|
5191
5204
|
"name": "key",
|
|
@@ -5209,6 +5222,12 @@
|
|
|
5209
5222
|
"type": "boolean",
|
|
5210
5223
|
"default": "false"
|
|
5211
5224
|
},
|
|
5225
|
+
{
|
|
5226
|
+
"name": "trigger",
|
|
5227
|
+
"description": "Defines one or more actions (space separated) which should cause\nthe highlight to show. Default is `mouseenter`. If `click` is among the triggers, matching elements scroll into view.",
|
|
5228
|
+
"type": "\"click\" | \"mouseenter\"",
|
|
5229
|
+
"default": "\"mouseenter\""
|
|
5230
|
+
},
|
|
5212
5231
|
{
|
|
5213
5232
|
"name": "subscribe",
|
|
5214
5233
|
"description": "The name of the channel to subscribe to. Only events on a channel corresponding\nto this property are listened to.",
|
|
@@ -5268,6 +5287,13 @@
|
|
|
5268
5287
|
"type": "boolean",
|
|
5269
5288
|
"default": "false"
|
|
5270
5289
|
},
|
|
5290
|
+
{
|
|
5291
|
+
"name": "trigger",
|
|
5292
|
+
"attribute": "trigger",
|
|
5293
|
+
"description": "Defines one or more actions (space separated) which should cause\nthe highlight to show. Default is `mouseenter`. If `click` is among the triggers, matching elements scroll into view.",
|
|
5294
|
+
"type": "\"click\" | \"mouseenter\"",
|
|
5295
|
+
"default": "\"mouseenter\""
|
|
5296
|
+
},
|
|
5271
5297
|
{
|
|
5272
5298
|
"name": "subscribe",
|
|
5273
5299
|
"attribute": "subscribe",
|
package/package.json
CHANGED
package/pb-elements.json
CHANGED
|
@@ -4743,6 +4743,12 @@
|
|
|
4743
4743
|
"type": "boolean",
|
|
4744
4744
|
"default": "false"
|
|
4745
4745
|
},
|
|
4746
|
+
{
|
|
4747
|
+
"name": "trigger",
|
|
4748
|
+
"description": "Defines one or more actions (space separated) which should cause\nthe highlight to show. Default is `mouseenter`. If `click` is among the triggers, matching elements scroll into view.",
|
|
4749
|
+
"type": "\"click\" | \"mouseenter\"",
|
|
4750
|
+
"default": "\"mouseenter\""
|
|
4751
|
+
},
|
|
4746
4752
|
{
|
|
4747
4753
|
"name": "subscribe",
|
|
4748
4754
|
"description": "The name of the channel to subscribe to. Only events on a channel corresponding\nto this property are listened to.",
|
|
@@ -4842,6 +4848,13 @@
|
|
|
4842
4848
|
"type": "boolean",
|
|
4843
4849
|
"default": "false"
|
|
4844
4850
|
},
|
|
4851
|
+
{
|
|
4852
|
+
"name": "trigger",
|
|
4853
|
+
"attribute": "trigger",
|
|
4854
|
+
"description": "Defines one or more actions (space separated) which should cause\nthe highlight to show. Default is `mouseenter`. If `click` is among the triggers, matching elements scroll into view.",
|
|
4855
|
+
"type": "\"click\" | \"mouseenter\"",
|
|
4856
|
+
"default": "\"mouseenter\""
|
|
4857
|
+
},
|
|
4845
4858
|
{
|
|
4846
4859
|
"name": "subscribe",
|
|
4847
4860
|
"attribute": "subscribe",
|
|
@@ -5185,7 +5198,7 @@
|
|
|
5185
5198
|
{
|
|
5186
5199
|
"name": "pb-highlight",
|
|
5187
5200
|
"path": "./src/pb-highlight.js",
|
|
5188
|
-
"description": "Link elements to each other:
|
|
5201
|
+
"description": "Link elements to each other: when a trigger action occurs on one element,\nthe others are highlighted by changing their background color. Which elements\nare linked is determined by the `key` property: elements with the same key\nare linked. The trigger action is configured via the `trigger` property and\nsends a `pb-highlight-on` event. Other elements with the same key react to this event.\n\n`pb-highlight` should be output for relevant elements via ODD processing model.",
|
|
5189
5202
|
"attributes": [
|
|
5190
5203
|
{
|
|
5191
5204
|
"name": "key",
|
|
@@ -5209,6 +5222,12 @@
|
|
|
5209
5222
|
"type": "boolean",
|
|
5210
5223
|
"default": "false"
|
|
5211
5224
|
},
|
|
5225
|
+
{
|
|
5226
|
+
"name": "trigger",
|
|
5227
|
+
"description": "Defines one or more actions (space separated) which should cause\nthe highlight to show. Default is `mouseenter`. If `click` is among the triggers, matching elements scroll into view.",
|
|
5228
|
+
"type": "\"click\" | \"mouseenter\"",
|
|
5229
|
+
"default": "\"mouseenter\""
|
|
5230
|
+
},
|
|
5212
5231
|
{
|
|
5213
5232
|
"name": "subscribe",
|
|
5214
5233
|
"description": "The name of the channel to subscribe to. Only events on a channel corresponding\nto this property are listened to.",
|
|
@@ -5268,6 +5287,13 @@
|
|
|
5268
5287
|
"type": "boolean",
|
|
5269
5288
|
"default": "false"
|
|
5270
5289
|
},
|
|
5290
|
+
{
|
|
5291
|
+
"name": "trigger",
|
|
5292
|
+
"attribute": "trigger",
|
|
5293
|
+
"description": "Defines one or more actions (space separated) which should cause\nthe highlight to show. Default is `mouseenter`. If `click` is among the triggers, matching elements scroll into view.",
|
|
5294
|
+
"type": "\"click\" | \"mouseenter\"",
|
|
5295
|
+
"default": "\"mouseenter\""
|
|
5296
|
+
},
|
|
5271
5297
|
{
|
|
5272
5298
|
"name": "subscribe",
|
|
5273
5299
|
"attribute": "subscribe",
|
package/src/pb-highlight.js
CHANGED
|
@@ -2,11 +2,11 @@ import { LitElement, html, css } from 'lit-element';
|
|
|
2
2
|
import { pbMixin } from './pb-mixin';
|
|
3
3
|
|
|
4
4
|
/**
|
|
5
|
-
* Link elements to each other:
|
|
5
|
+
* Link elements to each other: when a trigger action occurs on one element,
|
|
6
6
|
* the others are highlighted by changing their background color. Which elements
|
|
7
7
|
* are linked is determined by the `key` property: elements with the same key
|
|
8
|
-
* are linked.
|
|
9
|
-
* a `pb-highlight` event. Other elements with the same key react to this event.
|
|
8
|
+
* are linked. The trigger action is configured via the `trigger` property and
|
|
9
|
+
* sends a `pb-highlight-on` event. Other elements with the same key react to this event.
|
|
10
10
|
*
|
|
11
11
|
* `pb-highlight` should be output for relevant elements via ODD processing model.
|
|
12
12
|
*
|
|
@@ -17,6 +17,8 @@ import { pbMixin } from './pb-mixin';
|
|
|
17
17
|
* @fires pb-highlight-on - Fires highlight event with a key passed to which other pb-highlight elements with the same key will react
|
|
18
18
|
* @fires pb-highlight-off - When received, triggers removal of a highlight that might have been on for this element before
|
|
19
19
|
* @fires pb-highlight-on - When received, switches the highlight on if the same key was received as the current element has
|
|
20
|
+
* @prop {"click" | "mouseenter"} trigger - Defines one or more actions (space separated) which should cause
|
|
21
|
+
* the highlight to show. Default is `mouseenter`. If `click` is among the triggers, matching elements scroll into view.
|
|
20
22
|
* @cssprop --pb-highlight-color - Background color to highlight an element
|
|
21
23
|
*/
|
|
22
24
|
export class PbHighlight extends pbMixin(LitElement) {
|
|
@@ -46,6 +48,12 @@ export class PbHighlight extends pbMixin(LitElement) {
|
|
|
46
48
|
type: Boolean,
|
|
47
49
|
attribute: 'highlight-self',
|
|
48
50
|
},
|
|
51
|
+
/**
|
|
52
|
+
* Defines one or more actions (space separated) which should cause the highlight to show.
|
|
53
|
+
*/
|
|
54
|
+
trigger: {
|
|
55
|
+
type: String,
|
|
56
|
+
},
|
|
49
57
|
_className: {
|
|
50
58
|
type: String,
|
|
51
59
|
},
|
|
@@ -58,9 +66,18 @@ export class PbHighlight extends pbMixin(LitElement) {
|
|
|
58
66
|
this.duration = 0;
|
|
59
67
|
this.scroll = false;
|
|
60
68
|
this.highlightSelf = false;
|
|
69
|
+
this.trigger = 'mouseenter';
|
|
61
70
|
this._className = 'highlight-off';
|
|
62
71
|
}
|
|
63
72
|
|
|
73
|
+
_getTriggers() {
|
|
74
|
+
return (this.trigger || 'mouseenter').trim().split(/\s+/);
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
_isClickable() {
|
|
78
|
+
return this._getTriggers().includes('click');
|
|
79
|
+
}
|
|
80
|
+
|
|
64
81
|
connectedCallback() {
|
|
65
82
|
super.connectedCallback();
|
|
66
83
|
this.subscribeTo('pb-highlight-on', this._highlightOn.bind(this));
|
|
@@ -74,7 +91,7 @@ export class PbHighlight extends pbMixin(LitElement) {
|
|
|
74
91
|
}
|
|
75
92
|
}
|
|
76
93
|
|
|
77
|
-
|
|
94
|
+
_triggerHighlight() {
|
|
78
95
|
this.emitTo('pb-highlight-off', {
|
|
79
96
|
source: this,
|
|
80
97
|
});
|
|
@@ -84,7 +101,7 @@ export class PbHighlight extends pbMixin(LitElement) {
|
|
|
84
101
|
this.emitTo('pb-highlight-on', {
|
|
85
102
|
id: this.key,
|
|
86
103
|
source: this,
|
|
87
|
-
scroll: this.scroll,
|
|
104
|
+
scroll: this.scroll || this._isClickable(),
|
|
88
105
|
});
|
|
89
106
|
}
|
|
90
107
|
|
|
@@ -92,7 +109,12 @@ export class PbHighlight extends pbMixin(LitElement) {
|
|
|
92
109
|
if (this.disabled) {
|
|
93
110
|
return html`<slot></slot>`;
|
|
94
111
|
}
|
|
95
|
-
|
|
112
|
+
const triggers = this._getTriggers();
|
|
113
|
+
return html`<span
|
|
114
|
+
id="content"
|
|
115
|
+
class="${this._className}${this._isClickable() ? ' clickable' : ''}"
|
|
116
|
+
@mouseenter="${triggers.includes('mouseenter') ? this._triggerHighlight : null}"
|
|
117
|
+
@click="${triggers.includes('click') ? this._triggerHighlight : null}"
|
|
96
118
|
><slot></slot
|
|
97
119
|
></span>`;
|
|
98
120
|
}
|
|
@@ -127,6 +149,10 @@ export class PbHighlight extends pbMixin(LitElement) {
|
|
|
127
149
|
.highlight-off {
|
|
128
150
|
background-color: inherit;
|
|
129
151
|
}
|
|
152
|
+
|
|
153
|
+
.clickable {
|
|
154
|
+
cursor: pointer;
|
|
155
|
+
}
|
|
130
156
|
`;
|
|
131
157
|
}
|
|
132
158
|
|
|
@@ -134,7 +160,7 @@ export class PbHighlight extends pbMixin(LitElement) {
|
|
|
134
160
|
if (ev.detail.source != this && ev.detail.id === this.key) {
|
|
135
161
|
this._className = 'highlight-on';
|
|
136
162
|
if (ev.detail.scroll && this.disabled == false) {
|
|
137
|
-
this.scrollIntoView({ block: 'center',
|
|
163
|
+
this.scrollIntoView({ block: 'center', behavior: 'smooth' });
|
|
138
164
|
}
|
|
139
165
|
if (this.duration > 0) {
|
|
140
166
|
setTimeout(() => {
|
|
@@ -151,16 +177,16 @@ export class PbHighlight extends pbMixin(LitElement) {
|
|
|
151
177
|
}
|
|
152
178
|
|
|
153
179
|
/**
|
|
154
|
-
* Fired
|
|
180
|
+
* Fired when a trigger action occurs on the element
|
|
155
181
|
*
|
|
156
182
|
* @event pb-highlight-on
|
|
157
183
|
* @param {String} id key
|
|
158
184
|
* @param {Object} source this element
|
|
159
|
-
* @param {
|
|
185
|
+
* @param {Boolean} scroll should target scroll to highlighted position
|
|
160
186
|
*/
|
|
161
187
|
|
|
162
188
|
/**
|
|
163
|
-
* Fired
|
|
189
|
+
* Fired before a new highlight is applied
|
|
164
190
|
*
|
|
165
191
|
* @event pb-highlight-off
|
|
166
192
|
* @param {Object} source this element
|