presenter 0.8.8 → 0.9.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/dist/export/powerpoint-renderer/objects/renderSpotlight.d.ts +3 -0
- package/dist/export/powerpoint-renderer/types/PowerPointObjectRenderer.d.ts +2 -0
- package/dist/export.js +46 -46
- package/dist/export.js.map +1 -1
- package/dist/export.mjs +909 -772
- package/dist/export.mjs.map +1 -1
- package/dist/index.d.ts +2 -0
- package/dist/objects/Spotlight.d.ts +19 -0
- package/dist/presenter.js +2 -2
- package/dist/presenter.js.map +1 -1
- package/dist/presenter.mjs +1517 -1237
- package/dist/presenter.mjs.map +1 -1
- package/dist/renderer/browser-canvas/BrowserCanvasRenderer.d.ts +1 -0
- package/dist/renderer/browser-canvas/objects/renderSpotlight.d.ts +3 -0
- package/dist/renderer/browser-canvas/types/BrowserCanvasObjectRenderer.d.ts +3 -0
- package/dist/renderer/browser-canvas/utils/getSizeFromTextMetrics.d.ts +5 -1
- package/dist/renderer/browser-canvas/utils/variables/createVariableControlsElement.d.ts +6 -0
- package/dist/renderer/browser-canvas/utils/variables/mountVariableControls.d.ts +6 -0
- package/dist/types/ObjectType.d.ts +1 -0
- package/dist/types/Variable.d.ts +19 -0
- package/dist/utils/objects/spotlight/getSpotlightCutout.d.ts +8 -0
- package/dist/utils/objects/spotlight/getSpotlightPath.d.ts +10 -0
- package/dist/utils/storage/variableStorage.d.ts +2 -0
- package/package.json +1 -1
package/dist/presenter.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
(function(k,X){typeof exports=="object"&&typeof module<"u"?X(exports):typeof define=="function"&&define.amd?define(["exports"],X):(k=typeof globalThis<"u"?globalThis:k||self,X(k.Presenter={}))})(this,(function(k){"use strict";var a2=Object.defineProperty;var h2=(k,X,At)=>X in k?a2(k,X,{enumerable:!0,configurable:!0,writable:!0,value:At}):k[X]=At;var O=(k,X,At)=>h2(k,typeof X!="symbol"?X+"":X,At);var Mt,Lt,Tt,Ct,Pt;const X={ANIMATE:"Animate",PAUSE:"Pause",UPDATE:"Update"};function At(n){return n*n*n}function v0(n){return--n*n*n+1}function w0(n){return((n*=2)<=1?n*n*n:(n-=2)*n*n+2)/2}var Ht=1.70158;(function n(e){e=+e;function t(o){return(o=+o)*o*(e*(o-1)+o)}return t.overshoot=n,t})(Ht),(function n(e){e=+e;function t(o){return--o*o*((o+1)*e+o)+1}return t.overshoot=n,t})(Ht);var m0=(function n(e){e=+e;function t(o){return((o*=2)<1?o*o*((e+1)*o-e):(o-=2)*o*((e+1)*o+e)+2)/2}return t.overshoot=n,t})(Ht);const Ft={LINEAR:n=>n,CUBIC:w0,CUBIC_IN:At,CUBIC_OUT:v0,BACK_IN_OUT:m0.overshoot(.8)},b0=Ft.LINEAR;function Rt(n,e,t={}){return{type:X.ANIMATE,object:n,props:e,delay:0,duration:1e3,easing:b0,block:!1,interpolators:null,isKey:!1,shortcut:null,...typeof t=="number"?{duration:t}:t}}function A0(n,e={}){return Rt(n,{opacity:1},{duration:500,easing:Ft.CUBIC,...typeof e=="number"?{duration:e}:e})}function M0(n,e={}){return Rt(n,{opacity:0},{duration:500,easing:Ft.CUBIC,...typeof e=="number"?{duration:e}:e})}function Ut(n,e,t={}){return{type:X.UPDATE,isKey:!1,object:n,props:e,shortcut:null,...t}}function L0(n){return Ut(n,{opacity:0})}function T0(n){return Ut(n,{opacity:1})}const et={TOP_LEFT:"TopLeft",TOP:"Top",TOP_RIGHT:"TopRight",LEFT:"Left",CENTER:"Center",RIGHT:"Right",BOTTOM_LEFT:"BottomLeft",BOTTOM:"Bottom",BOTTOM_RIGHT:"BottomRight"},ot=et.TOP_LEFT;function V(n,e=0,t=0,o=1){if(typeof n=="string"){const i=n.replace("#",""),a=parseInt(i,16);return isNaN(a)?(console.warn("Invalid hex color format:",n),J):i.length===6?{red:a>>16&255,green:a>>8&255,blue:a&255,alpha:1}:i.length===8?{red:a>>24&255,green:a>>16&255,blue:a>>8&255,alpha:(a&255)/255}:(console.warn("Invalid hex color format:",n),J)}else if(typeof n=="number")return{red:n,green:e??0,blue:t??0,alpha:o??1};return{red:0,green:0,blue:0,alpha:1,...n}}V.BLACK=V(0,0,0),V.BLUE=V(0,0,255),V.GREEN=V(0,255,0),V.RED=V(255,0,0),V.TRANSPARENT=V(0,0,0,0),V.WHITE=V(255,255,255);const J={red:0,green:0,blue:0,alpha:1};function $t(n=null){return{content:null,setup:null,anchor:et.TOP_LEFT,height:0,width:0,x:0,y:0,...n}}function we(n,e=null){return n.alpha*(e??1)}function St(n,e=null){const{red:t,green:o,blue:i}=n,a=t<<16|o<<8|i,s=Math.round(we(n,e)*255);return`#${a.toString(16).padStart(6,"0")}${s!==255?s.toString(16).padStart(2,"0"):""}`}function C0(n=null){const{url:e="https://wikipedia.org/",backgroundColor:t=V.TRANSPARENT,strokeColor:o=J,strokeWidth:i=0,pointerEvents:a="auto",scale:s=1,anchor:r=ot,height:h=1e3,width:c=1e3,x:u=0,y:d=0}=n||{},l=document.createElement("iframe");l.src=e,l.style.backgroundColor=St(t),l.style.border=i>0?`${i}px solid ${St(o)}`:"none",l.style.pointerEvents=a;const f=(100/s).toFixed(3)+"%";return l.style.height=i===0?f:`calc(${f} - ${i*2}px)`,l.style.width=i===0?f:`calc(${f} - ${i*2}px)`,l.style.transform=`scale(${s})`,l.style.transformOrigin="top left",$t({content:l,anchor:r,height:h,width:c,x:u,y:d})}const dt={LEFT:"left",CENTER:"center",RIGHT:"right"},P0=dt.LEFT;function st(n,e){throw new Error("Unexpected value: "+n)}function S0(n=null){const{alignment:e=dt.LEFT,scale:t=1,anchor:o=ot,height:i=1e3,width:a=1e3,x:s=0,y:r=0}=n||{};function h(c){const u=document.createElement("video");switch(u.autoplay=!0,u.style.transform=`scale(${t})`,e){case dt.LEFT:u.style.transformOrigin="top left";break;case dt.CENTER:u.style.transformOrigin="top center";break;case dt.RIGHT:u.style.transformOrigin="top right";break;default:st(e)}c.appendChild(u);const d={video:{displaySurface:"window"},audio:!1};return navigator.mediaDevices.getDisplayMedia(d).then(l=>{const f=l.getVideoTracks()[0];f!==void 0&&(f.onended=function(){u.style.display="none"}),u.srcObject=l,u.play()}).catch(l=>{console.error("Could not start screen capture -",l)}),()=>{u.srcObject.getTracks().forEach(f=>f.stop()),u.style.display="none",u.srcObject=null}}return $t({content:null,setup:h,anchor:o,height:i,width:a,x:s,y:r})}const H={ARROW:"Arrow",CIRCLE:"Circle",GROUP:"Group",IMAGE:"Image",LINE:"Line",MASK:"Mask",PATH:"Path",POLYGON:"Polygon",RECTANGLE:"Rectangle",SLIDE_OBJECT:"SlideObject",SVG:"SVG",TEXT:"Text"};function nt(n){return{objectType:H.SLIDE_OBJECT,opacity:1,...n}}function E0(n=null){const{arrowheadSize:e,width:t=10,...o}=n||{},i=e??t*4;return nt({objectType:H.ARROW,arrowheadSize:i,color:J,drawn:1,endX:100,endY:100,isArrowheadDoubled:!1,isArrowheadFilled:!1,isDrawnFromCenter:!1,startX:0,startY:0,width:t,...o})}const I0=50;function k0(n=null){return nt({objectType:H.CIRCLE,anchor:ot,strokeColor:J,strokeWidth:0,drawn:1,fillColor:J,radius:I0,x:0,y:0,...n})}function Wt(n,e=null){return nt({objectType:H.GROUP,anchor:ot,height:0,objects:n,previewColor:null,rotateOriginPreviewSize:0,rotateOriginX:0,rotateOriginY:0,rotation:0,skewOriginPreviewSize:0,skewOriginX:0,skewOriginY:0,skewX:0,skewY:0,scale:1,scaleX:1,scaleY:1,width:0,x:0,y:0,...e})}function O0(n){const{anchor:e=ot,cols:t=1,rows:o=1,gapX:i=0,gapY:a=0,groupProps:s={},width:r=0,height:h=0,x:c=0,y:u=0,objects:d=()=>null}=n,l=[],f=[];let v=0,x=0;for(let T=0;T<o;T++){const S=[];v=0;let P=0;for(let E=0;E<t;E++){const L=d(T,E),I=typeof r=="function"?r(T,E):r,B=typeof h=="function"?h(T,E):h;S.push(L),L!=null&&f.push(Wt([L],{x:v,y:x})),v+=I+i,P=Math.max(P,B)}l.push(S),x+=P+a}return{grid:Wt(f,{x:c,y:u,height:x-a,width:v-i,anchor:e,...s}),objects:l}}function _0(n=null){return nt({objectType:H.IMAGE,anchor:ot,cornerRadius:0,height:100,imageId:"",smooth:!0,width:100,x:0,y:0,...n})}function N0(n=null){return nt({objectType:H.LINE,color:J,drawn:1,endX:100,endY:100,isDrawnFromCenter:!1,isRounded:!1,startX:0,startY:0,width:10,...n})}function F0(n,e=null){return nt({objectType:H.MASK,anchor:ot,height:100,objects:n,preview:!1,width:100,x:0,y:0,...e})}var R0=Object.defineProperty,_=(n,e)=>R0(n,"name",{value:e,configurable:!0}),Et={a:7,c:6,h:1,l:2,m:2,q:4,s:4,t:2,v:1,z:0},B0=/([astvzqmhlc])([^astvzqmhlc]*)/gi,D0=/-?[0-9]*\.?[0-9]+(?:e[-+]?\d+)?/gi,q0=_(n=>{const e=(n&&n.length>0?n:"M0,0").match(B0);if(!e)throw new Error(`No path elements found in string ${n}`);return e.reduce((t,o)=>{let i=o.charAt(0),a=i.toLowerCase(),s=z0(o.substring(1));if(a==="m"&&s.length>2&&(t.push([i,...s.splice(0,2)]),a="l",i=i==="m"?"l":"L"),a.toLowerCase()==="a"&&(s.length===5||s.length===6)){const r=o.substring(1).trim().split(" ");s=[Number(r[0]),Number(r[1]),Number(r[2]),Number(r[3].charAt(0)),Number(r[3].charAt(1)),Number(r[3].substring(2)),Number(r[4])]}for(;s.length>=0;){if(s.length===Et[a]){t.push([i,...s.splice(0,Et[a])]);break}if(s.length<Et[a])throw new Error(`Malformed path data: "${i}" must have ${Et[a]} elements and has ${s.length}: ${o}`);t.push([i,...s.splice(0,Et[a])])}return t},[])},"default"),z0=_(n=>{const e=n.match(D0);return e?e.map(Number):[]},"parseValues"),rt=(Mt=class{constructor(e,t,o,i){O(this,"x0");O(this,"x1");O(this,"y0");O(this,"y1");O(this,"getTotalLength",_(()=>Math.sqrt(Math.pow(this.x0-this.x1,2)+Math.pow(this.y0-this.y1,2)),"getTotalLength"));O(this,"getPointAtLength",_(e=>{let t=e/Math.sqrt(Math.pow(this.x0-this.x1,2)+Math.pow(this.y0-this.y1,2));t=Number.isNaN(t)?1:t;const o=(this.x1-this.x0)*t,i=(this.y1-this.y0)*t;return{x:this.x0+o,y:this.y0+i}},"getPointAtLength"));O(this,"getTangentAtLength",_(e=>{const t=Math.sqrt((this.x1-this.x0)*(this.x1-this.x0)+(this.y1-this.y0)*(this.y1-this.y0));return{x:(this.x1-this.x0)/t,y:(this.y1-this.y0)/t}},"getTangentAtLength"));O(this,"getPropertiesAtLength",_(e=>{const t=this.getPointAtLength(e),o=this.getTangentAtLength(e);return{x:t.x,y:t.y,tangentX:o.x,tangentY:o.y}},"getPropertiesAtLength"));this.x0=e,this.x1=t,this.y0=o,this.y1=i}},_(Mt,"LinearPosition"),Mt),me=(Lt=class{constructor(e,t,o,i,a,s,r,h,c){O(this,"x0");O(this,"y0");O(this,"rx");O(this,"ry");O(this,"xAxisRotate");O(this,"LargeArcFlag");O(this,"SweepFlag");O(this,"x1");O(this,"y1");O(this,"length");O(this,"getTotalLength",_(()=>this.length,"getTotalLength"));O(this,"getPointAtLength",_(e=>{e<0?e=0:e>this.length&&(e=this.length);const t=be({x:this.x0,y:this.y0},this.rx,this.ry,this.xAxisRotate,this.LargeArcFlag,this.SweepFlag,{x:this.x1,y:this.y1},e/this.length);return{x:t.x,y:t.y}},"getPointAtLength"));O(this,"getTangentAtLength",_(e=>{e<0?e=0:e>this.length&&(e=this.length);const t=.05,o=this.getPointAtLength(e);let i;e<0?e=0:e>this.length&&(e=this.length),i=e<this.length-t?this.getPointAtLength(e+t):this.getPointAtLength(e-t);const a=i.x-o.x,s=i.y-o.y,r=Math.sqrt(a*a+s*s);return e<this.length-t?{x:-a/r,y:-s/r}:{x:a/r,y:s/r}},"getTangentAtLength"));O(this,"getPropertiesAtLength",_(e=>{const t=this.getTangentAtLength(e),o=this.getPointAtLength(e);return{x:o.x,y:o.y,tangentX:t.x,tangentY:t.y}},"getPropertiesAtLength"));this.x0=e,this.y0=t,this.rx=o,this.ry=i,this.xAxisRotate=a,this.LargeArcFlag=s,this.SweepFlag=r,this.x1=h,this.y1=c;const u=j0(300,function(d){return be({x:e,y:t},o,i,a,s,r,{x:h,y:c},d)});this.length=u.arcLength}},_(Lt,"Arc"),Lt),be=_((n,e,t,o,i,a,s,r)=>{e=Math.abs(e),t=Math.abs(t),o=H0(o,360);const h=U0(o);if(n.x===s.x&&n.y===s.y)return{x:n.x,y:n.y,ellipticalArcAngle:0};if(e===0||t===0)return{x:0,y:0,ellipticalArcAngle:0};const c=(n.x-s.x)/2,u=(n.y-s.y)/2,d={x:Math.cos(h)*c+Math.sin(h)*u,y:-Math.sin(h)*c+Math.cos(h)*u},l=Math.pow(d.x,2)/Math.pow(e,2)+Math.pow(d.y,2)/Math.pow(t,2);l>1&&(e=Math.sqrt(l)*e,t=Math.sqrt(l)*t);let f=(Math.pow(e,2)*Math.pow(t,2)-Math.pow(e,2)*Math.pow(d.y,2)-Math.pow(t,2)*Math.pow(d.x,2))/(Math.pow(e,2)*Math.pow(d.y,2)+Math.pow(t,2)*Math.pow(d.x,2));f=f<0?0:f;const v=(i!==a?1:-1)*Math.sqrt(f),x=v*(e*d.y/t),M=v*(-t*d.x/e),T={x:Math.cos(h)*x-Math.sin(h)*M+(n.x+s.x)/2,y:Math.sin(h)*x+Math.cos(h)*M+(n.y+s.y)/2},S={x:(d.x-x)/e,y:(d.y-M)/t},P=Me({x:1,y:0},S);let E=Me(S,{x:(-d.x-x)/e,y:(-d.y-M)/t});!a&&E>0?E-=2*Math.PI:a&&E<0&&(E+=2*Math.PI),E%=2*Math.PI;const L=P+E*r,I=e*Math.cos(L),B=t*Math.sin(L);return{x:Math.cos(h)*I-Math.sin(h)*B+T.x,y:Math.sin(h)*I+Math.cos(h)*B+T.y,ellipticalArcStartAngle:P,ellipticalArcEndAngle:P+E,ellipticalArcAngle:L,ellipticalArcCenter:T,resultantRx:e,resultantRy:t}},"pointOnEllipticalArc"),j0=_((n,e)=>{n=n??500;let t=0;const o=[],i=[];let a,s=e(0);for(let r=0;r<n;r++){const h=$0(r*(1/n),0,1);a=e(h),t+=Ae(s,a),i.push([s,a]),o.push({t:h,arcLength:t}),s=a}return a=e(1),i.push([s,a]),t+=Ae(s,a),o.push({t:1,arcLength:t}),{arcLength:t,arcLengthMap:o,approximationLines:i}},"approximateArcLengthOfCurve"),H0=_((n,e)=>(n%e+e)%e,"mod"),U0=_(n=>n*(Math.PI/180),"toRadians"),Ae=_((n,e)=>Math.sqrt(Math.pow(e.x-n.x,2)+Math.pow(e.y-n.y,2)),"distance"),$0=_((n,e,t)=>Math.min(Math.max(n,e),t),"clamp"),Me=_((n,e)=>{const t=n.x*e.x+n.y*e.y,o=Math.sqrt((Math.pow(n.x,2)+Math.pow(n.y,2))*(Math.pow(e.x,2)+Math.pow(e.y,2)));return(n.x*e.y-n.y*e.x<0?-1:1)*Math.acos(t/o)},"angleBetween"),W0=[[],[],[-.5773502691896257,.5773502691896258],[0,-.7745966692414833,.7745966692414833],[-.33998104358485626,.33998104358485626,-.8611363115940526,.8611363115940526],[0,-.5384693101056831,.5384693101056831,-.906179845938664,.906179845938664],[.6612093864662645,-.6612093864662645,-.2386191860831969,.2386191860831969,-.932469514203152,.932469514203152],[0,.4058451513773972,-.4058451513773972,-.7415311855993945,.7415311855993945,-.9491079123427585,.9491079123427585],[-.1834346424956498,.1834346424956498,-.525532409916329,.525532409916329,-.7966664774136267,.7966664774136267,-.9602898564975363,.9602898564975363],[0,-.8360311073266358,.8360311073266358,-.9681602395076261,.9681602395076261,-.3242534234038089,.3242534234038089,-.6133714327005904,.6133714327005904],[-.14887433898163122,.14887433898163122,-.4333953941292472,.4333953941292472,-.6794095682990244,.6794095682990244,-.8650633666889845,.8650633666889845,-.9739065285171717,.9739065285171717],[0,-.26954315595234496,.26954315595234496,-.5190961292068118,.5190961292068118,-.7301520055740494,.7301520055740494,-.8870625997680953,.8870625997680953,-.978228658146057,.978228658146057],[-.1252334085114689,.1252334085114689,-.3678314989981802,.3678314989981802,-.5873179542866175,.5873179542866175,-.7699026741943047,.7699026741943047,-.9041172563704749,.9041172563704749,-.9815606342467192,.9815606342467192],[0,-.2304583159551348,.2304583159551348,-.44849275103644687,.44849275103644687,-.6423493394403402,.6423493394403402,-.8015780907333099,.8015780907333099,-.9175983992229779,.9175983992229779,-.9841830547185881,.9841830547185881],[-.10805494870734367,.10805494870734367,-.31911236892788974,.31911236892788974,-.5152486363581541,.5152486363581541,-.6872929048116855,.6872929048116855,-.827201315069765,.827201315069765,-.9284348836635735,.9284348836635735,-.9862838086968123,.9862838086968123],[0,-.20119409399743451,.20119409399743451,-.3941513470775634,.3941513470775634,-.5709721726085388,.5709721726085388,-.7244177313601701,.7244177313601701,-.8482065834104272,.8482065834104272,-.937273392400706,.937273392400706,-.9879925180204854,.9879925180204854],[-.09501250983763744,.09501250983763744,-.2816035507792589,.2816035507792589,-.45801677765722737,.45801677765722737,-.6178762444026438,.6178762444026438,-.755404408355003,.755404408355003,-.8656312023878318,.8656312023878318,-.9445750230732326,.9445750230732326,-.9894009349916499,.9894009349916499],[0,-.17848418149584785,.17848418149584785,-.3512317634538763,.3512317634538763,-.5126905370864769,.5126905370864769,-.6576711592166907,.6576711592166907,-.7815140038968014,.7815140038968014,-.8802391537269859,.8802391537269859,-.9506755217687678,.9506755217687678,-.9905754753144174,.9905754753144174],[-.0847750130417353,.0847750130417353,-.2518862256915055,.2518862256915055,-.41175116146284263,.41175116146284263,-.5597708310739475,.5597708310739475,-.6916870430603532,.6916870430603532,-.8037049589725231,.8037049589725231,-.8926024664975557,.8926024664975557,-.9558239495713977,.9558239495713977,-.9915651684209309,.9915651684209309],[0,-.16035864564022537,.16035864564022537,-.31656409996362983,.31656409996362983,-.46457074137596094,.46457074137596094,-.600545304661681,.600545304661681,-.7209661773352294,.7209661773352294,-.8227146565371428,.8227146565371428,-.9031559036148179,.9031559036148179,-.96020815213483,.96020815213483,-.9924068438435844,.9924068438435844],[-.07652652113349734,.07652652113349734,-.22778585114164507,.22778585114164507,-.37370608871541955,.37370608871541955,-.5108670019508271,.5108670019508271,-.636053680726515,.636053680726515,-.7463319064601508,.7463319064601508,-.8391169718222188,.8391169718222188,-.912234428251326,.912234428251326,-.9639719272779138,.9639719272779138,-.9931285991850949,.9931285991850949],[0,-.1455618541608951,.1455618541608951,-.2880213168024011,.2880213168024011,-.4243421202074388,.4243421202074388,-.5516188358872198,.5516188358872198,-.6671388041974123,.6671388041974123,-.7684399634756779,.7684399634756779,-.8533633645833173,.8533633645833173,-.9200993341504008,.9200993341504008,-.9672268385663063,.9672268385663063,-.9937521706203895,.9937521706203895],[-.06973927331972223,.06973927331972223,-.20786042668822127,.20786042668822127,-.34193582089208424,.34193582089208424,-.469355837986757,.469355837986757,-.5876404035069116,.5876404035069116,-.6944872631866827,.6944872631866827,-.7878168059792081,.7878168059792081,-.8658125777203002,.8658125777203002,-.926956772187174,.926956772187174,-.9700604978354287,.9700604978354287,-.9942945854823992,.9942945854823992],[0,-.1332568242984661,.1332568242984661,-.26413568097034495,.26413568097034495,-.3903010380302908,.3903010380302908,-.5095014778460075,.5095014778460075,-.6196098757636461,.6196098757636461,-.7186613631319502,.7186613631319502,-.8048884016188399,.8048884016188399,-.8767523582704416,.8767523582704416,-.9329710868260161,.9329710868260161,-.9725424712181152,.9725424712181152,-.9947693349975522,.9947693349975522],[-.06405689286260563,.06405689286260563,-.1911188674736163,.1911188674736163,-.3150426796961634,.3150426796961634,-.4337935076260451,.4337935076260451,-.5454214713888396,.5454214713888396,-.6480936519369755,.6480936519369755,-.7401241915785544,.7401241915785544,-.820001985973903,.820001985973903,-.8864155270044011,.8864155270044011,-.9382745520027328,.9382745520027328,-.9747285559713095,.9747285559713095,-.9951872199970213,.9951872199970213]],Y0=[[],[],[1,1],[.8888888888888888,.5555555555555556,.5555555555555556],[.6521451548625461,.6521451548625461,.34785484513745385,.34785484513745385],[.5688888888888889,.47862867049936647,.47862867049936647,.23692688505618908,.23692688505618908],[.3607615730481386,.3607615730481386,.46791393457269104,.46791393457269104,.17132449237917036,.17132449237917036],[.4179591836734694,.3818300505051189,.3818300505051189,.27970539148927664,.27970539148927664,.1294849661688697,.1294849661688697],[.362683783378362,.362683783378362,.31370664587788727,.31370664587788727,.22238103445337448,.22238103445337448,.10122853629037626,.10122853629037626],[.3302393550012598,.1806481606948574,.1806481606948574,.08127438836157441,.08127438836157441,.31234707704000286,.31234707704000286,.26061069640293544,.26061069640293544],[.29552422471475287,.29552422471475287,.26926671930999635,.26926671930999635,.21908636251598204,.21908636251598204,.1494513491505806,.1494513491505806,.06667134430868814,.06667134430868814],[.2729250867779006,.26280454451024665,.26280454451024665,.23319376459199048,.23319376459199048,.18629021092773426,.18629021092773426,.1255803694649046,.1255803694649046,.05566856711617366,.05566856711617366],[.24914704581340277,.24914704581340277,.2334925365383548,.2334925365383548,.20316742672306592,.20316742672306592,.16007832854334622,.16007832854334622,.10693932599531843,.10693932599531843,.04717533638651183,.04717533638651183],[.2325515532308739,.22628318026289723,.22628318026289723,.2078160475368885,.2078160475368885,.17814598076194574,.17814598076194574,.13887351021978725,.13887351021978725,.09212149983772845,.09212149983772845,.04048400476531588,.04048400476531588],[.2152638534631578,.2152638534631578,.2051984637212956,.2051984637212956,.18553839747793782,.18553839747793782,.15720316715819355,.15720316715819355,.12151857068790319,.12151857068790319,.08015808715976021,.08015808715976021,.03511946033175186,.03511946033175186],[.2025782419255613,.19843148532711158,.19843148532711158,.1861610000155622,.1861610000155622,.16626920581699392,.16626920581699392,.13957067792615432,.13957067792615432,.10715922046717194,.10715922046717194,.07036604748810812,.07036604748810812,.03075324199611727,.03075324199611727],[.1894506104550685,.1894506104550685,.18260341504492358,.18260341504492358,.16915651939500254,.16915651939500254,.14959598881657674,.14959598881657674,.12462897125553388,.12462897125553388,.09515851168249279,.09515851168249279,.062253523938647894,.062253523938647894,.027152459411754096,.027152459411754096],[.17944647035620653,.17656270536699264,.17656270536699264,.16800410215645004,.16800410215645004,.15404576107681028,.15404576107681028,.13513636846852548,.13513636846852548,.11188384719340397,.11188384719340397,.08503614831717918,.08503614831717918,.0554595293739872,.0554595293739872,.02414830286854793,.02414830286854793],[.1691423829631436,.1691423829631436,.16427648374583273,.16427648374583273,.15468467512626524,.15468467512626524,.14064291467065065,.14064291467065065,.12255520671147846,.12255520671147846,.10094204410628717,.10094204410628717,.07642573025488905,.07642573025488905,.0497145488949698,.0497145488949698,.02161601352648331,.02161601352648331],[.1610544498487837,.15896884339395434,.15896884339395434,.15276604206585967,.15276604206585967,.1426067021736066,.1426067021736066,.12875396253933621,.12875396253933621,.11156664554733399,.11156664554733399,.09149002162245,.09149002162245,.06904454273764123,.06904454273764123,.0448142267656996,.0448142267656996,.019461788229726478,.019461788229726478],[.15275338713072584,.15275338713072584,.14917298647260374,.14917298647260374,.14209610931838204,.14209610931838204,.13168863844917664,.13168863844917664,.11819453196151841,.11819453196151841,.10193011981724044,.10193011981724044,.08327674157670475,.08327674157670475,.06267204833410907,.06267204833410907,.04060142980038694,.04060142980038694,.017614007139152118,.017614007139152118],[.14608113364969041,.14452440398997005,.14452440398997005,.13988739479107315,.13988739479107315,.13226893863333747,.13226893863333747,.12183141605372853,.12183141605372853,.10879729916714838,.10879729916714838,.09344442345603386,.09344442345603386,.0761001136283793,.0761001136283793,.057134425426857205,.057134425426857205,.036953789770852494,.036953789770852494,.016017228257774335,.016017228257774335],[.13925187285563198,.13925187285563198,.13654149834601517,.13654149834601517,.13117350478706238,.13117350478706238,.12325237681051242,.12325237681051242,.11293229608053922,.11293229608053922,.10041414444288096,.10041414444288096,.08594160621706773,.08594160621706773,.06979646842452049,.06979646842452049,.052293335152683286,.052293335152683286,.03377490158481415,.03377490158481415,.0146279952982722,.0146279952982722],[.13365457218610619,.1324620394046966,.1324620394046966,.12890572218808216,.12890572218808216,.12304908430672953,.12304908430672953,.11499664022241136,.11499664022241136,.10489209146454141,.10489209146454141,.09291576606003515,.09291576606003515,.07928141177671895,.07928141177671895,.06423242140852585,.06423242140852585,.04803767173108467,.04803767173108467,.030988005856979445,.030988005856979445,.013411859487141771,.013411859487141771],[.12793819534675216,.12793819534675216,.1258374563468283,.1258374563468283,.12167047292780339,.12167047292780339,.1155056680537256,.1155056680537256,.10744427011596563,.10744427011596563,.09761865210411388,.09761865210411388,.08619016153195327,.08619016153195327,.0733464814110803,.0733464814110803,.05929858491543678,.05929858491543678,.04427743881741981,.04427743881741981,.028531388628933663,.028531388628933663,.0123412297999872,.0123412297999872]],G0=[[1],[1,1],[1,2,1],[1,3,3,1]],X0=_((n,e,t)=>({x:(1-t)*(1-t)*(1-t)*n[0]+3*(1-t)*(1-t)*t*n[1]+3*(1-t)*t*t*n[2]+t*t*t*n[3],y:(1-t)*(1-t)*(1-t)*e[0]+3*(1-t)*(1-t)*t*e[1]+3*(1-t)*t*t*e[2]+t*t*t*e[3]}),"cubicPoint"),K0=_((n,e,t)=>Le([3*(n[1]-n[0]),3*(n[2]-n[1]),3*(n[3]-n[2])],[3*(e[1]-e[0]),3*(e[2]-e[1]),3*(e[3]-e[2])],t),"cubicDerivative"),V0=_((n,e,t)=>{let o,i;const a=t/2;o=0;for(let s=0;s<20;s++)i=a*W0[20][s]+a,o+=Y0[20][s]*Te(n,e,i);return a*o},"getCubicArcLength"),Le=_((n,e,t)=>({x:(1-t)*(1-t)*n[0]+2*(1-t)*t*n[1]+t*t*n[2],y:(1-t)*(1-t)*e[0]+2*(1-t)*t*e[1]+t*t*e[2]}),"quadraticPoint"),Z0=_((n,e,t)=>{t===void 0&&(t=1);const o=n[0]-2*n[1]+n[2],i=e[0]-2*e[1]+e[2],a=2*n[1]-2*n[0],s=2*e[1]-2*e[0],r=4*(o*o+i*i),h=4*(o*a+i*s),c=a*a+s*s;if(r===0)return t*Math.sqrt(Math.pow(n[2]-n[0],2)+Math.pow(e[2]-e[0],2));const u=h/(2*r),d=t+u,l=c/r-u*u,f=d*d+l>0?Math.sqrt(d*d+l):0,v=u*u+l>0?Math.sqrt(u*u+l):0,x=u+Math.sqrt(u*u+l)!==0&&(d+f)/(u+v)!==0?l*Math.log(Math.abs((d+f)/(u+v))):0;return Math.sqrt(r)/2*(d*f-u*v+x)},"getQuadraticArcLength"),Q0=_((n,e,t)=>({x:2*(1-t)*(n[1]-n[0])+2*t*(n[2]-n[1]),y:2*(1-t)*(e[1]-e[0])+2*t*(e[2]-e[1])}),"quadraticDerivative");function Te(n,e,t){const o=Yt(1,t,n),i=Yt(1,t,e),a=o*o+i*i;return Math.sqrt(a)}_(Te,"BFunc");var Yt=_((n,e,t)=>{const o=t.length-1;let i,a;if(o===0)return 0;if(n===0){a=0;for(let s=0;s<=o;s++)a+=G0[o][s]*Math.pow(1-e,o-s)*Math.pow(e,s)*t[s];return a}i=new Array(o);for(let s=0;s<o;s++)i[s]=o*(t[s+1]-t[s]);return Yt(n-1,e,i)},"getDerivative"),Gt=_((n,e,t)=>{let o=1,i=n/e,a=(n-t(i))/e,s=0;for(;o>.001;){const r=t(i+a),h=Math.abs(n-r)/e;if(h<o)o=h,i+=a;else{const c=t(i-a),u=Math.abs(n-c)/e;u<o?(o=u,i-=a):a/=2}if(s++,s>500)break}return i},"t2length"),ft=(Tt=class{constructor(e,t,o,i,a,s,r,h){O(this,"a");O(this,"b");O(this,"c");O(this,"d");O(this,"length");O(this,"getArcLength");O(this,"getPoint");O(this,"getDerivative");O(this,"getTotalLength",_(()=>this.length,"getTotalLength"));O(this,"getPointAtLength",_(e=>{const t=[this.a.x,this.b.x,this.c.x,this.d.x],o=[this.a.y,this.b.y,this.c.y,this.d.y],i=Gt(e,this.length,a=>this.getArcLength(t,o,a));return this.getPoint(t,o,i)},"getPointAtLength"));O(this,"getTangentAtLength",_(e=>{const t=[this.a.x,this.b.x,this.c.x,this.d.x],o=[this.a.y,this.b.y,this.c.y,this.d.y],i=Gt(e,this.length,h=>this.getArcLength(t,o,h)),a=this.getDerivative(t,o,i),s=Math.sqrt(a.x*a.x+a.y*a.y);let r;return r=s>0?{x:a.x/s,y:a.y/s}:{x:0,y:0},r},"getTangentAtLength"));O(this,"getPropertiesAtLength",_(e=>{const t=[this.a.x,this.b.x,this.c.x,this.d.x],o=[this.a.y,this.b.y,this.c.y,this.d.y],i=Gt(e,this.length,c=>this.getArcLength(t,o,c)),a=this.getDerivative(t,o,i),s=Math.sqrt(a.x*a.x+a.y*a.y);let r;r=s>0?{x:a.x/s,y:a.y/s}:{x:0,y:0};const h=this.getPoint(t,o,i);return{x:h.x,y:h.y,tangentX:r.x,tangentY:r.y}},"getPropertiesAtLength"));O(this,"getC",_(()=>this.c,"getC"));O(this,"getD",_(()=>this.d,"getD"));this.a={x:e,y:t},this.b={x:o,y:i},this.c={x:a,y:s},r!==void 0&&h!==void 0?(this.getArcLength=V0,this.getPoint=X0,this.getDerivative=K0,this.d={x:r,y:h}):(this.getArcLength=Z0,this.getPoint=Le,this.getDerivative=Q0,this.d={x:0,y:0}),this.length=this.getArcLength([this.a.x,this.b.x,this.c.x,this.d.x],[this.a.y,this.b.y,this.c.y,this.d.y],1)}},_(Tt,"Bezier"),Tt),J0=(Ct=class{constructor(e){O(this,"length",0);O(this,"partial_lengths",[]);O(this,"functions",[]);O(this,"initial_point",null);O(this,"getPartAtLength",_(e=>{e<0?e=0:e>this.length&&(e=this.length);let t=this.partial_lengths.length-1;for(;this.partial_lengths[t]>=e&&t>0;)t--;return t++,{fraction:e-this.partial_lengths[t-1],i:t}},"getPartAtLength"));O(this,"getTotalLength",_(()=>this.length,"getTotalLength"));O(this,"getPointAtLength",_(e=>{const t=this.getPartAtLength(e),o=this.functions[t.i];if(o)return o.getPointAtLength(t.fraction);if(this.initial_point)return this.initial_point;throw new Error("Wrong function at this part.")},"getPointAtLength"));O(this,"getTangentAtLength",_(e=>{const t=this.getPartAtLength(e),o=this.functions[t.i];if(o)return o.getTangentAtLength(t.fraction);if(this.initial_point)return{x:0,y:0};throw new Error("Wrong function at this part.")},"getTangentAtLength"));O(this,"getPropertiesAtLength",_(e=>{const t=this.getPartAtLength(e),o=this.functions[t.i];if(o)return o.getPropertiesAtLength(t.fraction);if(this.initial_point)return{x:this.initial_point.x,y:this.initial_point.y,tangentX:0,tangentY:0};throw new Error("Wrong function at this part.")},"getPropertiesAtLength"));O(this,"getParts",_(()=>{const e=[];for(let t=0;t<this.functions.length;t++)if(this.functions[t]!==null){this.functions[t]=this.functions[t];const o={start:this.functions[t].getPointAtLength(0),end:this.functions[t].getPointAtLength(this.partial_lengths[t]-this.partial_lengths[t-1]),length:this.partial_lengths[t]-this.partial_lengths[t-1],getPointAtLength:this.functions[t].getPointAtLength,getTangentAtLength:this.functions[t].getTangentAtLength,getPropertiesAtLength:this.functions[t].getPropertiesAtLength};e.push(o)}return e},"getParts"));const t=Array.isArray(e)?e:q0(e);let o,i=[0,0],a=[0,0],s=[0,0];for(let r=0;r<t.length;r++){if(t[r][0]==="M")i=[t[r][1],t[r][2]],s=[i[0],i[1]],this.functions.push(null),r===0&&(this.initial_point={x:t[r][1],y:t[r][2]});else if(t[r][0]==="m")i=[t[r][1]+i[0],t[r][2]+i[1]],s=[i[0],i[1]],this.functions.push(null);else if(t[r][0]==="L")this.length+=Math.sqrt(Math.pow(i[0]-t[r][1],2)+Math.pow(i[1]-t[r][2],2)),this.functions.push(new rt(i[0],t[r][1],i[1],t[r][2])),i=[t[r][1],t[r][2]];else if(t[r][0]==="l")this.length+=Math.sqrt(Math.pow(t[r][1],2)+Math.pow(t[r][2],2)),this.functions.push(new rt(i[0],t[r][1]+i[0],i[1],t[r][2]+i[1])),i=[t[r][1]+i[0],t[r][2]+i[1]];else if(t[r][0]==="H")this.length+=Math.abs(i[0]-t[r][1]),this.functions.push(new rt(i[0],t[r][1],i[1],i[1])),i[0]=t[r][1];else if(t[r][0]==="h")this.length+=Math.abs(t[r][1]),this.functions.push(new rt(i[0],i[0]+t[r][1],i[1],i[1])),i[0]=t[r][1]+i[0];else if(t[r][0]==="V")this.length+=Math.abs(i[1]-t[r][1]),this.functions.push(new rt(i[0],i[0],i[1],t[r][1])),i[1]=t[r][1];else if(t[r][0]==="v")this.length+=Math.abs(t[r][1]),this.functions.push(new rt(i[0],i[0],i[1],i[1]+t[r][1])),i[1]=t[r][1]+i[1];else if(t[r][0]==="z"||t[r][0]==="Z")this.length+=Math.sqrt(Math.pow(s[0]-i[0],2)+Math.pow(s[1]-i[1],2)),this.functions.push(new rt(i[0],s[0],i[1],s[1])),i=[s[0],s[1]];else if(t[r][0]==="C")o=new ft(i[0],i[1],t[r][1],t[r][2],t[r][3],t[r][4],t[r][5],t[r][6]),this.length+=o.getTotalLength(),i=[t[r][5],t[r][6]],this.functions.push(o);else if(t[r][0]==="c")o=new ft(i[0],i[1],i[0]+t[r][1],i[1]+t[r][2],i[0]+t[r][3],i[1]+t[r][4],i[0]+t[r][5],i[1]+t[r][6]),o.getTotalLength()>0?(this.length+=o.getTotalLength(),this.functions.push(o),i=[t[r][5]+i[0],t[r][6]+i[1]]):this.functions.push(new rt(i[0],i[0],i[1],i[1]));else if(t[r][0]==="S"){if(r>0&&["C","c","S","s"].indexOf(t[r-1][0])>-1){if(o){const h=o.getC();o=new ft(i[0],i[1],2*i[0]-h.x,2*i[1]-h.y,t[r][1],t[r][2],t[r][3],t[r][4])}}else o=new ft(i[0],i[1],i[0],i[1],t[r][1],t[r][2],t[r][3],t[r][4]);o&&(this.length+=o.getTotalLength(),i=[t[r][3],t[r][4]],this.functions.push(o))}else if(t[r][0]==="s"){if(r>0&&["C","c","S","s"].indexOf(t[r-1][0])>-1){if(o){const h=o.getC(),c=o.getD();o=new ft(i[0],i[1],i[0]+c.x-h.x,i[1]+c.y-h.y,i[0]+t[r][1],i[1]+t[r][2],i[0]+t[r][3],i[1]+t[r][4])}}else o=new ft(i[0],i[1],i[0],i[1],i[0]+t[r][1],i[1]+t[r][2],i[0]+t[r][3],i[1]+t[r][4]);o&&(this.length+=o.getTotalLength(),i=[t[r][3]+i[0],t[r][4]+i[1]],this.functions.push(o))}else if(t[r][0]==="Q"){if(i[0]===t[r][1]&&i[1]===t[r][2]){const h=new rt(t[r][1],t[r][3],t[r][2],t[r][4]);this.length+=h.getTotalLength(),this.functions.push(h)}else o=new ft(i[0],i[1],t[r][1],t[r][2],t[r][3],t[r][4],void 0,void 0),this.length+=o.getTotalLength(),this.functions.push(o);i=[t[r][3],t[r][4]],a=[t[r][1],t[r][2]]}else if(t[r][0]==="q"){if(t[r][1]!==0||t[r][2]!==0)o=new ft(i[0],i[1],i[0]+t[r][1],i[1]+t[r][2],i[0]+t[r][3],i[1]+t[r][4],void 0,void 0),this.length+=o.getTotalLength(),this.functions.push(o);else{const h=new rt(i[0]+t[r][1],i[0]+t[r][3],i[1]+t[r][2],i[1]+t[r][4]);this.length+=h.getTotalLength(),this.functions.push(h)}a=[i[0]+t[r][1],i[1]+t[r][2]],i=[t[r][3]+i[0],t[r][4]+i[1]]}else if(t[r][0]==="T"){if(r>0&&["Q","q","T","t"].indexOf(t[r-1][0])>-1)o=new ft(i[0],i[1],2*i[0]-a[0],2*i[1]-a[1],t[r][1],t[r][2],void 0,void 0),this.functions.push(o),this.length+=o.getTotalLength();else{const h=new rt(i[0],t[r][1],i[1],t[r][2]);this.functions.push(h),this.length+=h.getTotalLength()}a=[2*i[0]-a[0],2*i[1]-a[1]],i=[t[r][1],t[r][2]]}else if(t[r][0]==="t"){if(r>0&&["Q","q","T","t"].indexOf(t[r-1][0])>-1)o=new ft(i[0],i[1],2*i[0]-a[0],2*i[1]-a[1],i[0]+t[r][1],i[1]+t[r][2],void 0,void 0),this.length+=o.getTotalLength(),this.functions.push(o);else{const h=new rt(i[0],i[0]+t[r][1],i[1],i[1]+t[r][2]);this.length+=h.getTotalLength(),this.functions.push(h)}a=[2*i[0]-a[0],2*i[1]-a[1]],i=[t[r][1]+i[0],t[r][2]+i[1]]}else if(t[r][0]==="A"){const h=new me(i[0],i[1],t[r][1],t[r][2],t[r][3],t[r][4]===1,t[r][5]===1,t[r][6],t[r][7]);this.length+=h.getTotalLength(),i=[t[r][6],t[r][7]],this.functions.push(h)}else if(t[r][0]==="a"){const h=new me(i[0],i[1],t[r][1],t[r][2],t[r][3],t[r][4]===1,t[r][5]===1,i[0]+t[r][6],i[1]+t[r][7]);this.length+=h.getTotalLength(),i=[i[0]+t[r][6],i[1]+t[r][7]],this.functions.push(h)}this.partial_lengths.push(this.length)}}},_(Ct,"SVGPathProperties"),Ct),Xt=(Pt=class{constructor(e){O(this,"inst");O(this,"getTotalLength",_(()=>this.inst.getTotalLength(),"getTotalLength"));O(this,"getPointAtLength",_(e=>this.inst.getPointAtLength(e),"getPointAtLength"));O(this,"getTangentAtLength",_(e=>this.inst.getTangentAtLength(e),"getTangentAtLength"));O(this,"getPropertiesAtLength",_(e=>this.inst.getPropertiesAtLength(e),"getPropertiesAtLength"));O(this,"getParts",_(()=>this.inst.getParts(),"getParts"));if(this.inst=new J0(e),!(this instanceof Xt))return new Xt(e)}},_(Pt,"_svgPathProperties"),Pt);function Ce(n=V.BLACK){return{...n,alpha:0}}function t1(n=null){const{path:e,height:t=100,width:o=100,viewboxHeight:i,viewboxWidth:a,...s}=n??{},r=e??"M 0 0 L 100 100",c=new Xt(r).getTotalLength();return nt({objectType:H.PATH,anchor:ot,strokeColor:J,drawn:1,fillColor:Ce(),isRounded:!1,height:t,path:r,pathLength:c,strokeWidth:4,viewboxHeight:i??t,viewboxWidth:a??o,width:o,x:0,y:0,...s})}function e1(n=null){return nt({objectType:H.POLYGON,strokeColor:J,strokeWidth:0,drawn:1,points:[{x:0,y:0},{x:100,y:0},{x:100,y:100}],fillColor:J,...n})}function n1(n=null){return nt({objectType:H.RECTANGLE,anchor:ot,strokeColor:J,strokeWidth:0,drawn:1,fillColor:J,height:100,cornerRadius:0,width:100,x:0,y:0,...n})}function r1(n=null){return nt({objectType:H.SVG,anchor:ot,height:100,svg:"",width:100,x:0,y:0,...n})}const Pe={NORMAL:"normal",ITALIC:"italic",OBLIQUE:"oblique"},i1=Pe.NORMAL,Se={THIN:100,EXTRA_LIGHT:200,LIGHT:300,NORMAL:400,MEDIUM:500,SEMI_BOLD:600,BOLD:700,EXTRA_BOLD:800,BLACK:900},o1=Se.NORMAL,s1={color:J,fontFamily:"sans-serif",fontSize:100,fontStyle:i1,fontWeight:o1,ligatures:!1,subscript:!1,superscript:!1};function Ee(n){return typeof n=="string"?[[{text:n}]]:n.map(e=>e.map(t=>typeof t=="string"?{text:t}:t))}function Ie(n){return Ee(n).reduce((t,o)=>t+o.reduce((i,a)=>i+a.text.length,0),0)}function ke(n="",e=null){return nt({objectType:H.TEXT,alignment:P0,anchor:ot,length:null,lineSpacing:1,text:n,x:0,y:0,...s1,...e})}ke.writeOn=(n,e={})=>Rt(n,{length:Ie(n.text)},e);const Kt="presenter.navigator.state",bt={open:!1,visibility:{slides:!0,current:!0,next:!0}};function Vt(){return typeof document>"u"?!1:Array.from(document.scripts).some(n=>n.src.includes("/@vite/client"))}function a1(){return Vt()?Zt().open:!1}function h1(){_e({...Zt(),open:!0})}function Oe(){var n;(n=Qt())==null||n.removeItem(Kt)}function Zt(){var n,e,t,o;if(!Vt())return bt;try{const i=(n=Qt())==null?void 0:n.getItem(Kt);if(i==null)return bt;const a=JSON.parse(i);return{open:typeof a.open=="boolean"?a.open:bt.open,visibility:{slides:typeof((e=a.visibility)==null?void 0:e.slides)=="boolean"?a.visibility.slides:bt.visibility.slides,current:typeof((t=a.visibility)==null?void 0:t.current)=="boolean"?a.visibility.current:bt.visibility.current,next:typeof((o=a.visibility)==null?void 0:o.next)=="boolean"?a.visibility.next:bt.visibility.next}}}catch{return bt}}function _e(n){var e;Vt()&&((e=Qt())==null||e.setItem(Kt,JSON.stringify(n)))}function Qt(){try{return window.sessionStorage}catch{return null}}function Ne(n){return n.altKey||n.ctrlKey||n.metaKey||n.shiftKey}function Fe(n){var o,i;if(n===null)return!1;const e=n,t=(o=e.tagName)==null?void 0:o.toLowerCase();return t==="input"||t==="textarea"||t==="select"||t==="button"||e.isContentEditable?!0:(((i=e.closest)==null?void 0:i.call(e,"[contenteditable=''], [contenteditable='true']"))??null)!==null}function l1(n){var o;const{slides:e}=n,t={s:{slideIndex:0,buildIndex:0},c:{slideIndex:null,buildIndex:0},e:{slideIndex:e.length-1,buildIndex:((o=e[e.length-1])==null?void 0:o.animations.length)??0}};for(let i=0;i<e.length;i++){const a=e[i];if(a===void 0)continue;const s=a.shortcut;Jt(t,s,i,0);for(let r=0;r<a.animations.length;r++){const h=a.animations[r];if(h!==void 0)if(Array.isArray(h))for(const c of h)Jt(t,c.shortcut,i,r+1);else Jt(t,h.shortcut,i,r+1)}}return t}function Jt(n,e,t,o){if(e!==null)if(Array.isArray(e))for(const i of e)n[i]={slideIndex:t,buildIndex:o};else n[e]={slideIndex:t,buildIndex:o}}function Re(n,e){const t=n[e];return t!==void 0?t:isNaN(Number(e))?null:{slideIndex:Number(e)-1,buildIndex:0}}function Be(n,e,t,{onNext:o,onPrevious:i,onRenderSlide:a,onShowNavigator:s},{focusOnPointerDown:r=!1,keyEventTarget:h=e,signal:c}={}){t.shortcuts=l1(n);const u=c===void 0?void 0:{signal:c};r&&(e.hasAttribute("tabindex")||(e.tabIndex=-1),e.addEventListener("pointerdown",d=>{Fe(d.target)||e.focus({preventScroll:!0})},u)),e.addEventListener("mousemove",()=>{e.style.cursor="auto"},u),h.addEventListener("keyup",d=>{const l=d;if(Fe(l.target))return;if(l.code==="Escape"){t.textCommand=null;return}if(l.code==="ArrowRight"||l.code==="Space"){o(l.shiftKey);return}if(l.code==="ArrowLeft"){i(l.shiftKey);return}const f=c1(l);if(f!==null){const v=Re(t.shortcuts,f);t.textCommand=null,v!==null&&(l.preventDefault(),a(v.slideIndex,v.buildIndex));return}if(t.textCommand!==null){if(l.code==="Enter"){const v=t.textCommand;t.textCommand=null;const x=Re(t.shortcuts,v);x!==null&&a(x.slideIndex,x.buildIndex);return}else l.code==="Backspace"?t.textCommand=t.textCommand.slice(0,-1):t.textCommand+=l.key;return}if(l.key==="g"){t.textCommand="";return}if(l.key==="`"&&!Ne(l)){s();return}},u)}function c1(n){return!n.altKey||n.ctrlKey||n.metaKey||n.shiftKey?null:n.code.startsWith("Key")&&n.code.length===4?n.code.slice(3).toLowerCase():n.code.startsWith("Digit")&&n.code.length===6?n.code.slice(5):n.code.startsWith("Numpad")&&n.code.length===7?n.code.slice(6):null}let R=null,Bt=null,xt=null;const De="__presenterNavigatorInstanceId";let qe={width:700,height:680,left:20,top:50};function u1({presentation:n,shortcutState:e,onNavigateToSlide:t,onRenderSlide:o,onNext:i,onPrevious:a,forceRefresh:s=!1}){if(R!==null&&!R.closed&&(Dt(R),!s))return R.focus(),Bt;if((R===null||R.closed)&&(R=window.open("","Navigator",p1())),R===null)return console.error("Failed to open navigator window."),null;xt==null||xt();const r=y1(R),h=new AbortController;xt=()=>h.abort();const c=f1(n,t,i,r.isActive);return Bt=c,h1(),R.document.title=n.title,R.document.body.replaceChildren(c.element),Be(n,c.element,e,{onNext:u=>{r.isActive()&&i(u)},onPrevious:u=>{r.isActive()&&a(u)},onRenderSlide:(u,d)=>{r.isActive()&&o(u,d)},onShowNavigator:()=>{r.isActive()&&ee()}},{keyEventTarget:R,signal:h.signal}),R.addEventListener("resize",()=>Dt(R),{signal:h.signal}),R.addEventListener("beforeunload",()=>{Dt(R),Oe()},{signal:h.signal}),R.addEventListener("keyup",u=>{r.isActive()&&(u.key==="Escape"||u.key==="`"&&!Ne(u))&&ee()},{signal:h.signal}),Bt}function f1(n,e,t,o=()=>!0){const i=(R==null?void 0:R.document)??document,a=i.createElement("div");a.style.boxSizing="border-box",a.style.display="grid",a.style.gridTemplateColumns="260px 1fr",a.style.gap="18px",a.style.height="100vh",a.style.overflow="hidden",a.style.padding="18px",a.style.fontFamily='-apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif',a.style.backgroundColor="#f5f6f8",a.style.color="#1f2937",i.body.style.margin="0",i.body.style.overflow="hidden";const s=i.createElement("div");s.style.display="flex",s.style.flexDirection="column",s.style.gap="8px",s.style.minHeight="0",s.style.overflowY="auto",s.style.paddingRight="4px";const r=i.createElement("div");r.style.display="flex",r.style.flexDirection="column",r.style.gap="14px",r.style.minHeight="0",r.style.minWidth="0",r.style.overflow="hidden";const h=i.createElement("div");h.style.display="flex",h.style.gap="14px",h.style.alignItems="center",h.style.flexWrap="wrap",h.style.fontSize="13px",h.style.color="#4b5563";const c=i.createElement("div");c.style.display="flex",c.style.gap="14px",c.style.flex="1 1 auto",c.style.minHeight="0",c.style.minWidth="0",c.style.overflow="hidden";const u=ze("Current",n),d=ze("Next",n),l=Zt();d.container.style.cursor="pointer",d.container.addEventListener("click",()=>{o()&&t()});const f=n.slides.map((E,L)=>{const I=g1(E,L);return I.style.cursor="pointer",I.addEventListener("click",B=>{o()&&(B.shiftKey&&ee(),e(L))}),s.appendChild(I),I}),v=te("Slides",s,l.visibility.slides),x=te("Current",u.container,l.visibility.current),M=te("Next",d.container,l.visibility.next),T=()=>{const E=x.input.checked&&M.input.checked&&P();a.style.gridTemplateColumns=v.input.checked?"260px 1fr":"1fr",c.style.flexDirection=E?"column":"row",u.container.style.flex="1 1 0",d.container.style.flex="1 1 0",requestAnimationFrame(()=>{u.resize(),d.resize()}),_e({...l,open:!0,visibility:{slides:v.input.checked,current:x.input.checked,next:M.input.checked}})};v.input.addEventListener("change",T),x.input.addEventListener("change",T),M.input.addEventListener("change",T),R==null||R.addEventListener("resize",T),h.appendChild(v.element),h.appendChild(x.element),h.appendChild(M.element),c.appendChild(u.container),c.appendChild(d.container),r.appendChild(h),r.appendChild(c),a.appendChild(s),a.appendChild(r);function S(E,L,I,B){o()&&(f.forEach((K,j)=>{const W=j===E;K.style.backgroundColor=W?"#dbeafe":"#ffffff",K.style.borderColor=W?"#60a5fa":"#e5e7eb",K.style.color=W?"#1e3a8a":"#1f2937"}),u.label.textContent=je(n,E,L),d.label.textContent=je(n,I,B),d1(f[E],s),T())}function P(){const E=R;if(E===null)return!1;const L=v.input.checked?278:0,I=E.innerWidth-36-L,B=E.innerHeight-36-h.offsetHeight-14;return I<=0||B<=0?!1:I/B<1.1}return{element:a,currentCanvas:u.canvas,nextCanvas:d.canvas,currentLabel:u.label,nextLabel:d.label,isOpen:()=>R!==null&&!R.closed,update:S}}function g1(n,e){const t=(R==null?void 0:R.document)??document,o=t.createElement("div");o.style.display="flex",o.style.alignItems="center",o.style.gap="10px",o.style.padding="8px 10px",o.style.backgroundColor="#ffffff",o.style.border="1px solid #e5e7eb",o.style.borderRadius="6px",o.style.boxShadow="0 1px 2px rgba(15, 23, 42, 0.06)",o.style.fontSize="14px",o.style.lineHeight="1",o.style.userSelect="none";const i=t.createElement("div");i.textContent=`${e+1}`,i.style.minWidth="24px",i.style.fontWeight="700",i.style.color="#6b7280";const a=t.createElement("div");return a.textContent=n.title.length>0?n.title:`Slide ${e+1}`,a.style.overflow="hidden",a.style.textOverflow="ellipsis",a.style.whiteSpace="nowrap",o.appendChild(i),o.appendChild(a),o}function ze(n,e){var u;const t=(R==null?void 0:R.document)??document,o=t.createElement("div");o.style.display="flex",o.style.alignItems="center",o.style.flexDirection="column",o.style.minHeight="0",o.style.minWidth="0";const i=t.createElement("div");i.textContent=n,i.style.marginBottom="4px",i.style.fontSize="12px",i.style.fontWeight="700",i.style.textAlign="center",i.style.textTransform="uppercase",i.style.color="#6b7280";const a=t.createElement("div");a.style.marginBottom="6px",a.style.fontSize="14px",a.style.fontWeight="600",a.style.textAlign="center";const s=t.createElement("div");s.style.flex="1 1 auto",s.style.display="flex",s.style.alignItems="flex-start",s.style.justifyContent="center",s.style.minHeight="0",s.style.width="100%",s.style.overflow="hidden";const r=t.createElement("canvas");r.style.display="block",r.style.width="0",r.style.height="0";function h(){const d=s.clientWidth,l=s.clientHeight;if(d<=0||l<=0)return;const f=e.size.width/e.size.height,v=Math.min(d,l*f),x=v/f;r.style.width=`${v}px`,r.style.height=`${x}px`}const c=(u=t.defaultView)==null?void 0:u.ResizeObserver;return c!==void 0&&new c(h).observe(s),R==null||R.addEventListener("resize",h),s.appendChild(r),o.appendChild(i),o.appendChild(a),o.appendChild(s),{container:o,label:a,canvas:r,resize:h}}function te(n,e,t){const o=(R==null?void 0:R.document)??document,i=e.style.display||"block",a=o.createElement("label");a.style.display="inline-flex",a.style.alignItems="center",a.style.gap="6px",a.style.userSelect="none";const s=o.createElement("input");return s.type="checkbox",s.checked=t,e.style.display=t?i:"none",s.addEventListener("change",()=>{e.style.display=s.checked?i:"none"}),a.appendChild(s),a.appendChild(o.createTextNode(n)),{element:a,input:s}}function je(n,e,t){if(e===null)return"End of presentation";const o=n.slides[e];return o===void 0?"No slide":`Slide ${e+1} of ${n.slides.length}, Build ${t+1} of ${o.animations.length+1}`}function d1(n,e){if(n===void 0)return;const t=n.offsetTop,o=t+n.offsetHeight,i=e.scrollTop,a=i+e.clientHeight;(t<i||o>a)&&n.scrollIntoView({block:"nearest"})}function ee(){Dt(R),Oe(),xt==null||xt(),R==null||R.close(),R=null,Bt=null,xt=null}function p1(){const{width:n,height:e,left:t,top:o}=qe;return`width=${n},height=${e},left=${t},top=${o}`}function Dt(n){n===null||n.closed||(qe={width:n.outerWidth,height:n.outerHeight,left:n.screenX,top:n.screenY})}function y1(n){var o;const e=typeof((o=globalThis.crypto)==null?void 0:o.randomUUID)=="function"?globalThis.crypto.randomUUID():`${Date.now()}-${Math.random()}`,t=n;return t[De]=e,{isActive:()=>!n.closed&&t[De]===e}}function it(n=null){return{height:0,width:0,...n}}const x1=it({width:0,height:0});function He(n=null){return{backgroundColor:V.WHITE,slides:[],title:"Presentation",size:it({width:3840,height:2160}),resources:{images:{}},...n}}function v1(n){const e=Array.isArray(n)?n:[n];let t=0,o=0;for(const i of e)switch(i.type){case X.PAUSE:t+=i.duration;break;case X.ANIMATE:o=Math.max(o,t+i.delay+i.duration),i.block&&(t+=i.delay+i.duration);break;case X.UPDATE:break;default:st(i)}return o}function ne(n,e=null){const{red:t,green:o,blue:i}=n,a=we(n,e);return`rgba(${t}, ${o}, ${i}, ${a})`}function Ue(n){return n===document.body}function w1(n,e){const t=document.createElement("div");if(t.style.width="100%",t.style.aspectRatio=`${n.size.width} / ${n.size.height}`,t.style.position="relative",Ue(e)){t.style.top="50%",t.style.transform="translateY(-50%)",t.style.marginLeft="auto",t.style.marginRight="auto",t.style.overflowY="clip",document.title=n.title,document.documentElement.style.height="100%",document.body.style.margin="0",document.body.style.height="100%",document.body.style.width="100%",document.body.style.backgroundColor="#000000";const o=n.size.height/n.size.width;$e(t,o),window.matchMedia(`(min-aspect-ratio: ${n.size.width} / ${n.size.height})`).addEventListener("change",()=>$e(t,o))}return t}function $e(n,e){window.innerHeight/window.innerWidth>e?(n.style.width="100%",n.style.height="auto"):(n.style.width="auto",n.style.height="100%")}const We={check:n=>typeof n=="object"&&n!==null&&typeof n.red=="number"&&typeof n.green=="number"&&typeof n.blue=="number"&&typeof n.alpha=="number",interpolate:(n,e,t)=>({red:Math.round(n.red+(e.red-n.red)*t),green:Math.round(n.green+(e.green-n.green)*t),blue:Math.round(n.blue+(e.blue-n.blue)*t),alpha:n.alpha+(e.alpha-n.alpha)*t})},m1={check:n=>!0,interpolate:(n,e)=>e},Ye={check:n=>typeof n=="number",interpolate:(n,e,t)=>n+(e-n)*t},Ge=[Ye,We,m1];function b1(n,e,t,o=null){if(t===0)return n;if(t===1)return{...n,...e};const i=o!=null?[...o,...Ge]:Ge,a={};for(const s in e){const r=n[s],h=e[s];for(const c of i)if(c.check(r,s)&&c.check(h,s)){a[s]=c.interpolate(r,h,t);break}}return{...n,...a}}function Xe(n,e,t=null){if(e===null)return;const o=Array.isArray(e)?e:[e];let i=0;for(const a of o){if(t!==null&&i>t)break;switch(a.type){case X.ANIMATE:{const s=n.get(a.object);if(s===void 0)break;const r=t!==null?t-i:null,h=Math.max(Math.min(r!==null?(r-a.delay)/a.duration:1,1),0);n.set(a.object,{...s,...b1(s,a.props,a.easing(h),a.interpolators)}),a.block&&(i+=a.delay+a.duration);break}case X.UPDATE:{const s=n.get(a.object);if(s===void 0)break;n.set(a.object,{...s,...a.props});break}case X.PAUSE:i+=a.duration;break;default:st(a)}}}function Ke(n){return"objects"in n?n.objects.filter(e=>"objectType"in e):[]}function A1({slide:n,buildIndex:e,buildTime:t}){const o=new Map;function i(s){o.set(s,s);for(const r of Ke(s))i(r)}for(const s of n.objects)i(s);const a=t===null?e:e-1;for(let s=0;s<a;s++){const r=n.animations[s]??null;Xe(o,r)}if(t!==null&&e>0){const s=n.animations[e-1]??null;Xe(o,s,t)}return o}function M1(n){const e={};function t(o){if(o.objectType===H.SVG){const a=o.svg;a!==void 0&&a.length>0&&(e[a]=a)}const i=Ke(o);for(const a of i)t(a)}for(const o of n.slides)for(const i of o.objects)t(i);return e}const vt="presenterState";function L1(n,e){const t=localStorage.getItem(vt);if(t===null)return null;if(e===null)return localStorage.removeItem(vt),null;let o;try{o=JSON.parse(t)}catch(c){return console.error("Failed to parse presentation state from localStorage:",c),localStorage.removeItem(vt),null}const{title:i,timestamp:a}=o;let{slideIndex:s,buildIndex:r}=o;if(typeof i!="string"||typeof s!="number"||typeof r!="number"||typeof a!="number"||i!==n.title||Date.now()-a>1e3*60*e)return localStorage.removeItem(vt),null;s>n.slides.length-1&&(s=n.slides.length-1,r=0);const h=n.slides[s];return h===void 0?(localStorage.removeItem(vt),null):(r>h.animations.length&&(r=h.animations.length),{title:i,slideIndex:s,buildIndex:r})}function T1({title:n,slideIndex:e,buildIndex:t}){localStorage.setItem(vt,JSON.stringify({title:n,slideIndex:e,buildIndex:t,timestamp:Date.now()}))}const Ve=Object.freeze({canvas:null,extrasContainer:null,mountedExtrasCleanups:[],mountedExtrasSlideIndex:null,slideIndex:0,buildIndex:0,currentAnimationId:null,imageById:{},shortcutState:{textCommand:null,shortcuts:{}}}),Q={Browser:"browser",Node:"node"};function C1(n,e){e.context.clearRect(0,0,n.width,n.height)}function P1(n){const e=document.createElement("canvas");return e.setAttribute("width",n.width.toString()),e.setAttribute("height",n.height.toString()),e.style.position="absolute",e.style.width="100%",e}const pt={Browser:"browser",Node:"node"};function S1(n){const e=new Path2D(n);return{type:pt.Browser,path:e}}function E1(n){const{drawn:e,startX:t,startY:o,endX:i,endY:a,arrowheadSize:s,isArrowheadFilled:r,isDrawnFromCenter:h}=n,c={x:t,y:o},u={x:i,y:a},d=Math.atan2(u.y-c.y,u.x-c.x),l={x:c.x+(u.x-c.x)/2,y:c.y+(u.y-c.y)/2},f=u.x-c.x,v=u.y-c.y,M=Math.hypot(f,v)*e,T=Math.cos(d),S=Math.sin(d),P=h?{x:l.x-T*M/2,y:l.y-S*M/2}:c,E=h?{x:l.x+T*M/2,y:l.y+S*M/2}:{x:c.x+T*M,y:c.y+S*M},L=r?Math.PI/6:Math.PI/4.5,I=M<s*2?M/2:s,B={x:E.x-I*Math.cos(d-L),y:E.y-I*Math.sin(d-L)},K={x:E.x-I*Math.cos(d+L),y:E.y-I*Math.sin(d+L)},j={x:P.x+I*Math.cos(d-L),y:P.y+I*Math.sin(d-L)},W={x:P.x+I*Math.cos(d+L),y:P.y+I*Math.sin(d+L)};return{arrowPoints:[P,E],arrowheadPoints:[B,E,K],doubledArrowheadPoints:[j,P,W]}}function wt({ctx:n,color:e,drawn:t=null,isDrawnFromCenter:o=!1,isRounded:i=!1,opacity:a=null,path:s,pathLength:r=null,width:h}){if(!(h===0||t===0)){if(t!==null&&r!==null&&t!==1){const c=r+(i?h:0),u=r*t;o?n.context.setLineDash([0,(c-u)/2,u,(c-u)/2]):n.context.setLineDash([u,c-u])}else n.context.setLineDash([]);if(n.context.lineWidth=h,n.context.strokeStyle=St(e,a),n.context.lineCap=i?"round":"butt",s===void 0){n.context.stroke();return}switch(n.type){case Q.Browser:s.type===pt.Browser?n.context.stroke(s.path):console.warn("Attempted to use Node Path2D in Browser Canvas context");break;case Q.Node:s.type===pt.Node?n.context.stroke(s.path):console.warn("Attempted to use Browser Path2D in Node Canvas context");break;default:st(n)}}}function mt({ctx:n,path:e,color:t,opacity:o=null}){if(n.context.fillStyle=ne(t,o),e===void 0){n.context.fill();return}switch(n.type){case Q.Browser:e.type===pt.Browser?n.context.fill(e.path):console.warn("Attempted to use Node Path2D in Browser Canvas context");break;case Q.Node:e.type===pt.Node?n.context.fill(e.path):console.warn("Attempted to use Browser Path2D in Node Canvas context");break;default:st(n)}}function re(n,e){const t=e(),o=n[0];if(o===void 0)return{path:t,length:0};t.path.moveTo(o.x,o.y);let i=0;for(let a=1;a<n.length;a++){const s=n[a],r=n[a-1];if(s===void 0||r===void 0)continue;const h=s.x-r.x,c=s.y-r.y;i+=Math.hypot(h,c),t.path.lineTo(s.x,s.y)}return{path:t,length:i}}const I1=({ctx:n,object:e,opacity:t,createPath2D:o})=>{const i=e.opacity*t;if(i===0||e.drawn===0)return;const{arrowPoints:a,arrowheadPoints:s,doubledArrowheadPoints:r}=E1(e),{path:h}=re(a,o),{path:c}=re(s,o);if(wt({color:e.color,ctx:n,path:h,opacity:i,width:e.width}),e.isArrowheadFilled&&(c.path.closePath(),mt({ctx:n,path:c,color:e.color,opacity:i})),wt({color:e.color,ctx:n,path:c,opacity:i,width:e.width}),e.isArrowheadDoubled){const{path:u}=re(r,o);e.isArrowheadFilled&&(u.path.closePath(),mt({ctx:n,path:u,color:e.color,opacity:i})),wt({color:e.color,ctx:n,path:u,opacity:i,width:e.width})}};function k1(n,e){const t=n.radius-n.strokeWidth/2;if(t<=0)return;const o=e(),i=-Math.PI/2;return o.path.arc(n.x,n.y,t,i,i+2*Math.PI),o}function O1(n,e){const t=e(),o=-Math.PI/2;t.path.arc(n.x,n.y,n.radius,o,o+2*Math.PI);const i=2*Math.PI*n.radius;return{path:t,length:i}}function Ze(n,e){switch(n.type){case Q.Browser:e.type===pt.Browser?n.context.clip(e.path):console.warn("Attempted to use Node Path2D in Browser Canvas context");break;case Q.Node:e.type===pt.Node?n.context.clip(e.path):console.warn("Attempted to use Browser Path2D in Node Canvas context");break;default:st(n)}}const _1=({ctx:n,object:e,opacity:t,createPath2D:o})=>{const i=e.opacity*t;if(i===0||e.drawn===0&&e.fillColor.alpha===0)return;const{path:a,length:s}=O1(e,o);if(i<1&&e.strokeWidth>0){const r=k1(e,o);r!==void 0&&(n.context.save(),Ze(n,r),mt({ctx:n,path:a,color:e.fillColor,opacity:i}),n.context.restore())}else mt({ctx:n,path:a,color:e.fillColor,opacity:i});wt({color:e.strokeColor,ctx:n,drawn:e.drawn,path:a,pathLength:s,opacity:i,width:e.strokeWidth})};function G(n=null){return{x:0,y:0,...n}}const N1=G();function gt(n=null){return{origin:N1,size:x1,...n}}gt();function yt(n,e,t){const{x:o,y:i}=n,{width:a,height:s}=t;switch(e){case et.TOP_LEFT:return gt({origin:G({x:o,y:i}),size:t});case et.TOP:return gt({origin:G({x:o-a/2,y:i}),size:t});case et.TOP_RIGHT:return gt({origin:G({x:o-a,y:i}),size:t});case et.LEFT:return gt({origin:G({x:o,y:i-s/2}),size:t});case et.CENTER:return gt({origin:G({x:o-a/2,y:i-s/2}),size:t});case et.RIGHT:return gt({origin:G({x:o-a,y:i-s/2}),size:t});case et.BOTTOM_LEFT:return gt({origin:G({x:o,y:i-s}),size:t});case et.BOTTOM:return gt({origin:G({x:o-a/2,y:i-s}),size:t});case et.BOTTOM_RIGHT:return gt({origin:G({x:o-a,y:i-s}),size:t});default:st(e)}}const F1=({ctx:n,object:e,renderObject:t,opacity:o})=>{const i=e.scale*e.scaleX,a=e.scale*e.scaleY,s=yt(G({x:e.x,y:e.y}),e.anchor,it({width:e.width*Math.abs(i),height:e.height*Math.abs(a)})),{rotation:r,rotateOriginX:h,rotateOriginY:c,skewOriginX:u,skewOriginY:d,skewX:l,skewY:f}=e;if(!(i===0||a===0)){n.context.save(),n.context.translate(s.origin.x,s.origin.y),n.context.scale(i,a),n.context.translate(h,c),n.context.rotate(r*Math.PI/180),n.context.translate(-h,-c),n.context.translate(u,d),n.context.transform(1,Math.tan(f*Math.PI/180),Math.tan(l*Math.PI/180),1,0,0),n.context.translate(-u,-d);for(const v of e.objects)t(v,o*e.opacity);e.previewColor!==null&&(n.context.fillStyle=St(e.previewColor),n.context.fillRect(0,0,e.width,e.height)),e.rotateOriginPreviewSize>0&&(n.context.fillStyle="red",n.context.beginPath(),n.context.arc(h,c,e.rotateOriginPreviewSize,0,2*Math.PI),n.context.fill()),e.skewOriginPreviewSize>0&&(n.context.fillStyle="blue",n.context.beginPath(),n.context.arc(u,d,e.skewOriginPreviewSize,0,2*Math.PI),n.context.fill()),n.context.restore()}};function ie(n,e,t,o,i=0){const a=o();a.path.moveTo(n.x+t,n.y),a.path.lineTo(n.x+e.width-t,n.y),a.path.arcTo(n.x+e.width,n.y,n.x+e.width,n.y+t,t),a.path.lineTo(n.x+e.width,n.y+e.height-t),a.path.arcTo(n.x+e.width,n.y+e.height,n.x+e.width-t,n.y+e.height,t),a.path.lineTo(n.x+t,n.y+e.height),a.path.arcTo(n.x,n.y+e.height,n.x,n.y+e.height-t,t),a.path.lineTo(n.x,n.y+t),a.path.arcTo(n.x,n.y,n.x+t,n.y,t),i>0&&a.path.lineTo(n.x+t+i,n.y);const s=2*(e.width+e.height-4*t)+2*Math.PI*t+i;return{path:a,length:s}}const It={Browser:"browser",Node:"node"},R1=({ctx:n,imageById:e,object:t,opacity:o,createPath2D:i})=>{const a=yt(G({x:t.x,y:t.y}),t.anchor,it({width:t.width,height:t.height})),s=e[t.imageId];if(s!==void 0){if(n.context.save(),t.cornerRadius>0){const r=ie(a.origin,a.size,t.cornerRadius,i);switch(n.type){case Q.Browser:r.path.type===pt.Browser?n.context.clip(r.path.path):console.warn("Attempted to use Node Path2D in Browser Canvas context");break;case Q.Node:r.path.type===pt.Node?n.context.clip(r.path.path):console.warn("Attempted to use Browser Path2D in Node Canvas context");break;default:st(n)}}switch(n.context.globalAlpha=o*t.opacity,n.context.imageSmoothingEnabled=t.smooth,n.type){case Q.Browser:s.type===It.Browser?n.context.drawImage(s.image,a.origin.x,a.origin.y,a.size.width,a.size.height):console.warn("Attempted to use Node Image in Browser Canvas context");break;case Q.Node:s.type===It.Node?n.context.drawImage(s.image,a.origin.x,a.origin.y,a.size.width,a.size.height):console.warn("Attempted to use Browser Image in Node Canvas context");break;default:st(n)}n.context.restore()}};function B1(n,e){const t=e();t.path.moveTo(n.startX,n.startY),t.path.lineTo(n.endX,n.endY);const o=Math.hypot(n.endX-n.startX,n.endY-n.startY);return{path:t,length:o}}const D1=({ctx:n,object:e,opacity:t,createPath2D:o})=>{const i=e.opacity*t;if(i===0||e.drawn===0)return;const{path:a,length:s}=B1(e,o);wt({color:e.color,ctx:n,drawn:e.drawn,isDrawnFromCenter:e.isDrawnFromCenter,isRounded:e.isRounded,path:a,pathLength:s,opacity:i,width:e.width})},q1=({ctx:n,object:e,opacity:t,renderObject:o})=>{n.context.save();const i=yt(G({x:e.x,y:e.y}),e.anchor,it({width:e.width,height:e.height}));e.preview&&(n.context.lineWidth=4,n.context.strokeStyle=St(V.RED),n.context.rect(i.origin.x,i.origin.y,i.size.width,i.size.height),n.context.stroke()),n.context.beginPath(),n.context.rect(i.origin.x,i.origin.y,i.size.width,i.size.height),n.context.closePath(),n.context.clip();for(const a of e.objects)o(a,t*e.opacity);n.context.restore()},z1=({ctx:n,object:e,opacity:t,createPath2D:o})=>{const i=e.opacity*t;if(i===0||e.drawn===0&&e.fillColor.alpha===0)return;const{origin:a}=yt(G({x:e.x,y:e.y}),e.anchor,it({width:e.width,height:e.height})),s=o(e.path);n.context.save(),n.context.translate(a.x,a.y),n.context.scale(e.width/e.viewboxWidth,e.height/e.viewboxHeight),mt({ctx:n,path:s,color:e.fillColor,opacity:i}),wt({color:e.strokeColor,ctx:n,drawn:e.drawn,isRounded:e.isRounded,path:s,pathLength:e.pathLength,opacity:i,width:e.strokeWidth}),n.context.restore()};function j1(n,e){const t=e(),o=n.points,i=o[0];if(i===void 0)return{path:t,length:0};t.path.moveTo(i.x,i.y);let a=0,s=i;for(let h=1;h<o.length;h++){const c=o[h];if(c===void 0)continue;t.path.lineTo(c.x,c.y);const u=Math.hypot(c.x-s.x,c.y-s.y);a+=u,s=c}t.path.closePath();const r=Math.hypot(i.x-s.x,i.y-s.y);return a+=r,{path:t,length:a}}const H1=({ctx:n,object:e,opacity:t,createPath2D:o})=>{const i=e.opacity*t;if(i===0||e.drawn===0&&e.fillColor.alpha===0)return;const{path:a,length:s}=j1(e,o);mt({ctx:n,path:a,color:e.fillColor,opacity:i}),wt({color:e.strokeColor,ctx:n,drawn:e.drawn,path:a,pathLength:s,opacity:i,width:e.strokeWidth})};function U1(n,e){const t=n.strokeWidth/2,{origin:o,size:i}=yt(G({x:n.x,y:n.y}),n.anchor,it({width:n.width,height:n.height})),a=i.width-n.strokeWidth,s=i.height-n.strokeWidth;if(a<=0||s<=0)return;const r=G({x:o.x+t,y:o.y+t}),h=it({width:a,height:s}),c=Math.max(0,Math.min(n.cornerRadius-t,Math.min(a,s)/2));if(c>0)return ie(r,h,c,e).path;const u=e();return u.path.moveTo(r.x,r.y),u.path.lineTo(r.x+a,r.y),u.path.lineTo(r.x+a,r.y+s),u.path.lineTo(r.x,r.y+s),u.path.closePath(),u}function $1(n,e){const{origin:t,size:o}=yt(G({x:n.x,y:n.y}),n.anchor,it({width:n.width,height:n.height})),i=Math.max(0,Math.min(n.cornerRadius,Math.min(o.width,o.height)/2)),a=Math.min(n.strokeWidth*2,o.width-i);if(i>0)return ie(t,o,i,e,a);{const s=e();s.path.moveTo(t.x,t.y),s.path.lineTo(t.x+o.width,t.y),s.path.lineTo(t.x+o.width,t.y+o.height),s.path.lineTo(t.x,t.y+o.height),s.path.lineTo(t.x,t.y),s.path.lineTo(t.x+a,t.y);const r=2*(o.width+o.height)+a;return{path:s,length:r}}}const W1=({ctx:n,object:e,opacity:t,createPath2D:o})=>{const i=e.opacity*t;if(i===0||e.drawn===0&&e.fillColor.alpha===0)return;const{path:a,length:s}=$1(e,o);if(i<1&&e.strokeWidth>0){const r=U1(e,o);r!==void 0&&(n.context.save(),Ze(n,r),mt({ctx:n,path:a,color:e.fillColor,opacity:i}),n.context.restore())}else mt({ctx:n,path:a,color:e.fillColor,opacity:i});wt({color:e.strokeColor,ctx:n,drawn:e.drawn,path:a,pathLength:s,opacity:i,width:e.strokeWidth})},Y1=({ctx:n,imageById:e,object:t,opacity:o})=>{const i=t.opacity*o;if(i===0||!t.svg)return;const a=e[t.svg];if(a===void 0)return;const s=yt(G({x:t.x,y:t.y}),t.anchor,it({width:t.width,height:t.height}));switch(n.context.save(),n.context.globalAlpha=i,n.type){case Q.Browser:a.type===It.Browser&&n.context.drawImage(a.image,s.origin.x,s.origin.y,s.size.width,s.size.height);break;case Q.Node:a.type===It.Node&&n.context.drawImage(a.image,s.origin.x,s.origin.y,s.size.width,s.size.height);break;default:st(n)}n.context.restore()};function G1(n){return{color:n.color,fontFamily:n.fontFamily,fontSize:n.fontSize,fontStyle:n.fontStyle,fontWeight:n.fontWeight,ligatures:n.ligatures,subscript:n.subscript,superscript:n.superscript}}function X1(n,e=1){const t=Math.max(...n.map(a=>a.reduce((s,r)=>s+r.width,0)));let o=0,i=0;for(let a=0;a<n.length;a++){const s=n[a];if(s===void 0)continue;const r=Math.max(...s.map(h=>h.height));o+=r+i*(e-1),i=r}return{height:o,width:t}}const K1=.7,V1=.3;function Qe(n){const e=n.superscript,t=n.subscript&&!e;return!e&&!t?{baselineShift:0,fontSize:n.fontSize,isSubscript:!1,isSuperscript:!1}:{baselineShift:n.fontSize*V1*(e?-1:1),fontSize:n.fontSize*K1,isSubscript:t,isSuperscript:e}}function Z1(n){return{width:n.width,height:n.fontBoundingBoxAscent}}function Je(n,e,t=1){const o=Qe(e);n.context.fillStyle=ne(e.color,t),n.context.font=`${e.fontStyle} ${e.fontWeight} ${o.fontSize}px ${e.fontFamily}`,n.type===Q.Browser?n.context.textRendering=e.ligatures?"optimizeLegibility":"optimizeSpeed":n.context.fontVariant=e.ligatures?"common-ligatures":"no-common-ligatures"}function Q1(n,e,t){const o=[];for(const i of n){const a=[];for(const s of i){const{text:r,...h}=s,c={...e,...h};Je(t,c);const u=t.context.measureText(r),d=Z1(u),{baselineShift:l}=Qe(c),f=d.height+Math.max(0,-l),v=Math.max(0,l);a.push({...d,baselineShift:l,bottom:v,height:f+v,top:f})}o.push(a)}return o}const J1=({ctx:n,object:e,opacity:t})=>{const o=e.opacity*t;if(o===0)return;const{length:i}=e,a=Ee(e.text),s=G1(e),r=Q1(a,s,n),h=X1(r,e.lineSpacing),c=yt(G({x:e.x,y:e.y}),e.anchor,h);let u=c.origin.x,d=c.origin.y,l=0,f=0;for(let v=0;v<a.length;v++){const x=a[v],M=r[v];if(x==null||M==null){console.error("Could not determine text units or sizes for line");continue}const T=M.reduce((I,B)=>I+B.width,0),S=M.length===0?f:M.reduce((I,B)=>Math.max(I,B.top),0),P=M.length===0?0:M.reduce((I,B)=>Math.max(I,B.bottom),0),E=S+P;switch(e.alignment){case dt.LEFT:u=c.origin.x;break;case dt.CENTER:u=c.origin.x+(c.size.width-T)/2;break;case dt.RIGHT:u=c.origin.x+(c.size.width-T);break;default:st(e.alignment);break}d+=f*(e.lineSpacing-1);const L=d+S;f=E;for(let I=0;I<x.length&&!(i!==null&&l>=i);I++){const B=x[I],K=M[I];if(B==null||K==null){console.error("Could not determine text unit or size for unit");continue}const{text:j,...W}=B;let lt;if(i!==null&&l+j.length>i){const tt=i-l;lt=j.slice(0,tt)}const ct=lt??j;l+=ct.length;const ut={...s,...W};Je(n,ut,o),n.context.fillText(ct,u,L+K.baselineShift),u+=K.width}d+=E}},tn={[H.ARROW]:I1,[H.CIRCLE]:_1,[H.GROUP]:F1,[H.IMAGE]:R1,[H.LINE]:D1,[H.MASK]:q1,[H.PATH]:z1,[H.POLYGON]:H1,[H.RECTANGLE]:W1,[H.SLIDE_OBJECT]:()=>{},[H.SVG]:Y1,[H.TEXT]:J1};function en(n){const e=document.createElementNS("http://www.w3.org/2000/svg","svg");return e.setAttribute("viewBox",`0 0 ${n.width} ${n.height}`),e.style.backgroundColor="transparent",e.style.position="absolute",e.style.width="100%",e}function nn(n,e){if(n===null)return null;const t=yt(G({x:e.x,y:e.y}),e.anchor,it({width:e.width,height:e.height})),o=document.createElementNS("http://www.w3.org/2000/svg","foreignObject");o.setAttribute("x",t.origin.x.toString()),o.setAttribute("y",t.origin.y.toString()),o.setAttribute("width",e.width.toString()),o.setAttribute("height",e.height.toString());const i=e.content;i!==null&&o.appendChild(i),n.appendChild(o);let a=null;if(e.setup!==null){const s=e.setup(o);s!==void 0&&(a=s)}return()=>{a!==null&&a(),n.removeChild(o)}}async function rn(n){if(Object.keys(n).length===0)return{};const e={},t=i=>new Promise((a,s)=>{const r=new Image;if(r.onload=()=>a(r),r.onerror=c=>s(c),i.includes("</svg>")){const c=i.replace(/<\?xml[^?]*\?>\s*/g,""),u=new Blob([c],{type:"image/svg+xml;charset=utf-8"}),d=URL.createObjectURL(u);r.src=d}else r.src=i}),o=Object.entries(n).map(async([i,a])=>{const s=await t(a);e[i]={type:It.Browser,image:s}});try{await Promise.all(o)}catch(i){console.error("Error loading images:",i)}return e}class on{constructor(e){this.navigator=null;const{objectRenderers:t,scale:o=1,...i}=e;this.props={presentation:He(),element:document.body,objectRenderers:{...tn,...t},cacheDurationMinutes:15,scale:sn(o),...i},this.state={...Ve}}async present(){const{presentation:e,element:t,scale:o}=this.props,i=P1(e.size),a=en(e.size);a.style.transformOrigin="center center",a.style.transform=`scale(${o})`,this.state={...Ve,imageById:await rn({...e.resources.images,...M1(e)}),canvas:i,extrasContainer:a};const s=w1(e,t),r=Ue(t),h=(d,l)=>{this.state.shortcutState.shortcuts.b={slideIndex:this.state.slideIndex,buildIndex:this.state.buildIndex},this.renderSlide(d??this.state.slideIndex,l)},c=(d=!1)=>{r&&(this.navigator=u1({presentation:e,shortcutState:this.state.shortcutState,onNavigateToSlide:l=>this.renderSlide(l),onRenderSlide:h,onNext:l=>this.next(l),onPrevious:l=>this.previous(l),forceRefresh:d}),this.updateNavigator())};Be(e,s,this.state.shortcutState,{onNext:d=>this.next(d),onPrevious:d=>this.previous(d),onRenderSlide:h,onShowNavigator:()=>c()},{focusOnPointerDown:!r,keyEventTarget:r?window:s}),t.replaceChildren(),s.appendChild(i),s.appendChild(a),t.appendChild(s);const u=L1(e,this.props.cacheDurationMinutes);u!==null?this.renderSlide(u.slideIndex,u.buildIndex):this.renderSlide(0),a1()&&c(!0)}renderSlide(e,t=0,o=null){const{presentation:i}=this.props,{canvas:a}=this.state,s=this.state.slideIndex!==e;this.state.slideIndex=e,this.state.buildIndex=t,o===null&&T1({title:i.title,slideIndex:e,buildIndex:t});const r=i.slides[e];if(!(r===void 0||a===null)){if(s||this.state.mountedExtrasCleanups.length===0&&r.extras.length>0){for(const h of this.state.mountedExtrasCleanups)h();this.state.mountedExtrasCleanups=[];for(const h of r.extras){const c=nn(this.state.extrasContainer,h);c!==null&&this.state.mountedExtrasCleanups.push(c)}}this.renderCanvas(a,e,t,o,this.props.scale),o===null&&this.updateNavigator()}}renderCanvas(e,t,o=0,i=null,a=1){const{objectRenderers:s,presentation:r}=this.props,{imageById:h}=this.state;e.width=r.size.width,e.height=r.size.height;const c=e.getContext("2d");if(c===null)return;const u={type:Q.Browser,context:c};C1(e,u);const d=r.slides[t];if(d===void 0)return;const l=A1({slide:d,buildIndex:o,buildTime:i});u.context.fillStyle=ne(r.backgroundColor),u.context.fillRect(0,0,e.width,e.height);function f(x,M){const T=s[x.objectType],S=l.get(x);T===void 0||S===void 0||T({ctx:u,imageById:h,object:S,opacity:M,renderObject:f,createPath2D:S1})}const v=a!==1;v&&(u.context.save(),u.context.translate(e.width*(1-a)/2,e.height*(1-a)/2),u.context.scale(a,a));for(const x of d.objects)f(x,1);v&&u.context.restore()}updateNavigator(){const{navigator:e}=this;if(e===null)return;if(!e.isOpen()){this.navigator=null;return}const{slideIndex:t,buildIndex:o}=this.state,i=this.getNextSlideBuild(t,o);e.update(t,o,i.slideIndex,i.buildIndex),this.renderCanvas(e.currentCanvas,t,o),i.slideIndex===null?this.renderEndCanvas(e.nextCanvas):this.renderCanvas(e.nextCanvas,i.slideIndex,i.buildIndex)}getNextSlideBuild(e,t){const{presentation:o}=this.props,i=o.slides[e];return i===void 0?{slideIndex:e,buildIndex:t}:t<i.animations.length?{slideIndex:e,buildIndex:t+1}:e+1<o.slides.length?{slideIndex:e+1,buildIndex:0}:{slideIndex:null,buildIndex:0}}renderEndCanvas(e){const{presentation:t}=this.props;e.width=t.size.width,e.height=t.size.height;const o=e.getContext("2d");o!==null&&(o.fillStyle="#000000",o.fillRect(0,0,e.width,e.height))}next(e=!1){const{presentation:t}=this.props,{currentAnimationId:o,slideIndex:i,buildIndex:a}=this.state;this.hideCursor(),o!==null&&cancelAnimationFrame(o);const s=t.slides[i];if(s===void 0)return;const r=s.animations[a];if(r!==void 0&&!e){const h=performance.now(),c=v1(r),u=d=>{const l=d-h;l<c?(this.renderSlide(i,a+1,l),this.state.currentAnimationId=requestAnimationFrame(u)):this.renderSlide(i,a+1,null)};this.state.currentAnimationId=requestAnimationFrame(u)}else i+1<t.slides.length&&this.renderSlide(i+1)}previous(e=!1){const{currentAnimationId:t,slideIndex:o,buildIndex:i}=this.state;if(this.hideCursor(),t!==null&&cancelAnimationFrame(t),i>0)e?this.renderSlide(o,0):this.renderSlide(o,i-1);else if(o>0){const a=this.props.presentation.slides[o-1],s=e?0:(a==null?void 0:a.animations.length)??0;this.renderSlide(o-1,s)}else this.renderSlide(0,0)}hasNext(){const{presentation:e}=this.props,{slideIndex:t,buildIndex:o}=this.state,i=e.slides[t];return i===void 0?!1:i.animations[o]!==void 0?!0:t+1<e.slides.length}hasPrevious(){const{slideIndex:e,buildIndex:t}=this.state;return t>0||e>0}hideCursor(){var e,t;this.props.element.style.cursor="none",(t=(e=this.state.canvas)==null?void 0:e.parentElement)==null||t.style.setProperty("cursor","none")}}function sn(n){return n<=0||n>1?(console.warn(`BrowserCanvasRenderer scale must be positive and no greater than 1. Received ${n}; using 1 instead.`),1):n}function an(n=1e3){return{type:X.PAUSE,isKey:!1,duration:n,shortcut:null}}function hn(n=null){return{objects:[],animations:[],extras:[],isAllKey:!1,isEndKey:!0,isStartKey:!1,shortcut:null,title:"",...n}}function ln(n,e={}){return{...e,text:n}}function cn(n=V.BLACK){return{...n,alpha:1}}function un(n){for(var e=-1,t=n.length,o,i=n[t-1],a=0;++e<t;)o=i,i=n[e],a+=o[1]*i[0]-o[0]*i[1];return a/2}function fn(n){for(var e=-1,t=n.length,o=n[t-1],i,a,s=o[0],r=o[1],h=0;++e<t;)i=s,a=r,o=n[e],s=o[0],r=o[1],i-=s,a-=r,h+=Math.sqrt(i*i+a*a);return h}function gn(n){return n&&n.__esModule&&Object.prototype.hasOwnProperty.call(n,"default")?n.default:n}var oe,t0;function dn(){if(t0)return oe;t0=1;var n={a:7,c:6,h:1,l:2,m:2,r:4,q:4,s:4,t:2,v:1,z:0},e=[5760,6158,8192,8193,8194,8195,8196,8197,8198,8199,8200,8201,8202,8239,8287,12288,65279];function t(f){return f===10||f===13||f===8232||f===8233||f===32||f===9||f===11||f===12||f===160||f>=5760&&e.indexOf(f)>=0}function o(f){switch(f|32){case 109:case 122:case 108:case 104:case 118:case 99:case 115:case 113:case 116:case 97:case 114:return!0}return!1}function i(f){return(f|32)===97}function a(f){return f>=48&&f<=57}function s(f){return f>=48&&f<=57||f===43||f===45||f===46}function r(f){this.index=0,this.path=f,this.max=f.length,this.result=[],this.param=0,this.err="",this.segmentStart=0,this.data=[]}function h(f){for(;f.index<f.max&&t(f.path.charCodeAt(f.index));)f.index++}function c(f){var v=f.path.charCodeAt(f.index);if(v===48){f.param=0,f.index++;return}if(v===49){f.param=1,f.index++;return}f.err="SvgPath: arc flag can be 0 or 1 only (at pos "+f.index+")"}function u(f){var v=f.index,x=v,M=f.max,T=!1,S=!1,P=!1,E=!1,L;if(x>=M){f.err="SvgPath: missed param (at pos "+x+")";return}if(L=f.path.charCodeAt(x),(L===43||L===45)&&(x++,L=x<M?f.path.charCodeAt(x):0),!a(L)&&L!==46){f.err="SvgPath: param should start with 0..9 or `.` (at pos "+x+")";return}if(L!==46){if(T=L===48,x++,L=x<M?f.path.charCodeAt(x):0,T&&x<M&&L&&a(L)){f.err="SvgPath: numbers started with `0` such as `09` are illegal (at pos "+v+")";return}for(;x<M&&a(f.path.charCodeAt(x));)x++,S=!0;L=x<M?f.path.charCodeAt(x):0}if(L===46){for(E=!0,x++;a(f.path.charCodeAt(x));)x++,P=!0;L=x<M?f.path.charCodeAt(x):0}if(L===101||L===69){if(E&&!S&&!P){f.err="SvgPath: invalid float exponent (at pos "+x+")";return}if(x++,L=x<M?f.path.charCodeAt(x):0,(L===43||L===45)&&x++,x<M&&a(f.path.charCodeAt(x)))for(;x<M&&a(f.path.charCodeAt(x));)x++;else{f.err="SvgPath: invalid float exponent (at pos "+x+")";return}}f.index=x,f.param=parseFloat(f.path.slice(v,x))+0}function d(f){var v,x;v=f.path[f.segmentStart],x=v.toLowerCase();var M=f.data;if(x==="m"&&M.length>2&&(f.result.push([v,M[0],M[1]]),M=M.slice(2),x="l",v=v==="m"?"l":"L"),x==="r")f.result.push([v].concat(M));else for(;M.length>=n[x]&&(f.result.push([v].concat(M.splice(0,n[x]))),!!n[x]););}function l(f){var v=f.max,x,M,T,S,P;if(f.segmentStart=f.index,x=f.path.charCodeAt(f.index),M=i(x),!o(x)){f.err="SvgPath: bad command "+f.path[f.index]+" (at pos "+f.index+")";return}if(S=n[f.path[f.index].toLowerCase()],f.index++,h(f),f.data=[],!S){d(f);return}for(T=!1;;){for(P=S;P>0;P--){if(M&&(P===3||P===4)?c(f):u(f),f.err.length){d(f);return}f.data.push(f.param),h(f),T=!1,f.index<v&&f.path.charCodeAt(f.index)===44&&(f.index++,h(f),T=!0)}if(!T&&(f.index>=f.max||!s(f.path.charCodeAt(f.index))))break}d(f)}return oe=function(v){var x=new r(v),M=x.max;for(h(x);x.index<M&&!x.err.length;)l(x);return x.result.length&&("mM".indexOf(x.result[0][0])<0?(x.err="SvgPath: string should start with `M` or `m`",x.result=[]):x.result[0][0]="M"),{err:x.err,segments:x.result}},oe}var se,e0;function n0(){if(e0)return se;e0=1;function n(t,o){return[t[0]*o[0]+t[2]*o[1],t[1]*o[0]+t[3]*o[1],t[0]*o[2]+t[2]*o[3],t[1]*o[2]+t[3]*o[3],t[0]*o[4]+t[2]*o[5]+t[4],t[1]*o[4]+t[3]*o[5]+t[5]]}function e(){if(!(this instanceof e))return new e;this.queue=[],this.cache=null}return e.prototype.matrix=function(t){return t[0]===1&&t[1]===0&&t[2]===0&&t[3]===1&&t[4]===0&&t[5]===0?this:(this.cache=null,this.queue.push(t),this)},e.prototype.translate=function(t,o){return(t!==0||o!==0)&&(this.cache=null,this.queue.push([1,0,0,1,t,o])),this},e.prototype.scale=function(t,o){return(t!==1||o!==1)&&(this.cache=null,this.queue.push([t,0,0,o,0,0])),this},e.prototype.rotate=function(t,o,i){var a,s,r;return t!==0&&(this.translate(o,i),a=t*Math.PI/180,s=Math.cos(a),r=Math.sin(a),this.queue.push([s,r,-r,s,0,0]),this.cache=null,this.translate(-o,-i)),this},e.prototype.skewX=function(t){return t!==0&&(this.cache=null,this.queue.push([1,0,Math.tan(t*Math.PI/180),1,0,0])),this},e.prototype.skewY=function(t){return t!==0&&(this.cache=null,this.queue.push([1,Math.tan(t*Math.PI/180),0,1,0,0])),this},e.prototype.toArray=function(){if(this.cache)return this.cache;if(!this.queue.length)return this.cache=[1,0,0,1,0,0],this.cache;if(this.cache=this.queue[0],this.queue.length===1)return this.cache;for(var t=1;t<this.queue.length;t++)this.cache=n(this.cache,this.queue[t]);return this.cache},e.prototype.calc=function(t,o,i){var a;return this.queue.length?(this.cache||(this.cache=this.toArray()),a=this.cache,[t*a[0]+o*a[2]+(i?0:a[4]),t*a[1]+o*a[3]+(i?0:a[5])]):[t,o]},se=e,se}var ae,r0;function pn(){if(r0)return ae;r0=1;var n=n0(),e={matrix:!0,scale:!0,rotate:!0,translate:!0,skewX:!0,skewY:!0},t=/\s*(matrix|translate|scale|rotate|skewX|skewY)\s*\(\s*(.+?)\s*\)[\s,]*/,o=/[\s,]+/;return ae=function(a){var s=new n,r,h;return a.split(t).forEach(function(c){if(c.length){if(typeof e[c]<"u"){r=c;return}switch(h=c.split(o).map(function(u){return+u||0}),r){case"matrix":h.length===6&&s.matrix(h);return;case"scale":h.length===1?s.scale(h[0],h[0]):h.length===2&&s.scale(h[0],h[1]);return;case"rotate":h.length===1?s.rotate(h[0],0,0):h.length===3&&s.rotate(h[0],h[1],h[2]);return;case"translate":h.length===1?s.translate(h[0],0):h.length===2&&s.translate(h[0],h[1]);return;case"skewX":h.length===1&&s.skewX(h[0]);return;case"skewY":h.length===1&&s.skewY(h[0]);return}}}),s},ae}var he,i0;function yn(){if(i0)return he;i0=1;var n=Math.PI*2;function e(i,a,s,r){var h=i*r-a*s<0?-1:1,c=i*s+a*r;return c>1&&(c=1),c<-1&&(c=-1),h*Math.acos(c)}function t(i,a,s,r,h,c,u,d,l,f){var v=f*(i-s)/2+l*(a-r)/2,x=-l*(i-s)/2+f*(a-r)/2,M=u*u,T=d*d,S=v*v,P=x*x,E=M*T-M*P-T*S;E<0&&(E=0),E/=M*P+T*S,E=Math.sqrt(E)*(h===c?-1:1);var L=E*u/d*x,I=E*-d/u*v,B=f*L-l*I+(i+s)/2,K=l*L+f*I+(a+r)/2,j=(v-L)/u,W=(x-I)/d,lt=(-v-L)/u,ct=(-x-I)/d,ut=e(1,0,j,W),tt=e(j,W,lt,ct);return c===0&&tt>0&&(tt-=n),c===1&&tt<0&&(tt+=n),[B,K,ut,tt]}function o(i,a){var s=1.3333333333333333*Math.tan(a/4),r=Math.cos(i),h=Math.sin(i),c=Math.cos(i+a),u=Math.sin(i+a);return[r,h,r-h*s,h+r*s,c+u*s,u-c*s,c,u]}return he=function(a,s,r,h,c,u,d,l,f){var v=Math.sin(f*n/360),x=Math.cos(f*n/360),M=x*(a-r)/2+v*(s-h)/2,T=-v*(a-r)/2+x*(s-h)/2;if(M===0&&T===0)return[];if(d===0||l===0)return[];d=Math.abs(d),l=Math.abs(l);var S=M*M/(d*d)+T*T/(l*l);S>1&&(d*=Math.sqrt(S),l*=Math.sqrt(S));var P=t(a,s,r,h,c,u,d,l,v,x),E=[],L=P[2],I=P[3],B=Math.max(Math.ceil(Math.abs(I)/(n/4)),1);I/=B;for(var K=0;K<B;K++)E.push(o(L,I)),L+=I;return E.map(function(j){for(var W=0;W<j.length;W+=2){var lt=j[W+0],ct=j[W+1];lt*=d,ct*=l;var ut=x*lt-v*ct,tt=v*lt+x*ct;j[W+0]=ut+P[0],j[W+1]=tt+P[1]}return j})},he}var le,o0;function xn(){if(o0)return le;o0=1;var n=1e-10,e=Math.PI/180;function t(o,i,a){if(!(this instanceof t))return new t(o,i,a);this.rx=o,this.ry=i,this.ax=a}return t.prototype.transform=function(o){var i=Math.cos(this.ax*e),a=Math.sin(this.ax*e),s=[this.rx*(o[0]*i+o[2]*a),this.rx*(o[1]*i+o[3]*a),this.ry*(-o[0]*a+o[2]*i),this.ry*(-o[1]*a+o[3]*i)],r=s[0]*s[0]+s[2]*s[2],h=s[1]*s[1]+s[3]*s[3],c=((s[0]-s[3])*(s[0]-s[3])+(s[2]+s[1])*(s[2]+s[1]))*((s[0]+s[3])*(s[0]+s[3])+(s[2]-s[1])*(s[2]-s[1])),u=(r+h)/2;if(c<n*u)return this.rx=this.ry=Math.sqrt(u),this.ax=0,this;var d=s[0]*s[1]+s[2]*s[3];c=Math.sqrt(c);var l=u+c/2,f=u-c/2;return this.ax=Math.abs(d)<n&&Math.abs(l-h)<n?90:Math.atan(Math.abs(d)>Math.abs(l-h)?(l-r)/d:d/(l-h))*180/Math.PI,this.ax>=0?(this.rx=Math.sqrt(l),this.ry=Math.sqrt(f)):(this.ax+=90,this.rx=Math.sqrt(f),this.ry=Math.sqrt(l)),this},t.prototype.isDegenerate=function(){return this.rx<n*this.ry||this.ry<n*this.rx},le=t,le}var ce,s0;function vn(){if(s0)return ce;s0=1;var n=dn(),e=pn(),t=n0(),o=yn(),i=xn();function a(s){if(!(this instanceof a))return new a(s);var r=n(s);this.segments=r.segments,this.err=r.err,this.__stack=[]}return a.from=function(s){if(typeof s=="string")return new a(s);if(s instanceof a){var r=new a("");return r.err=s.err,r.segments=s.segments.map(function(h){return h.slice()}),r.__stack=s.__stack.map(function(h){return t().matrix(h.toArray())}),r}throw new Error("SvgPath.from: invalid param type "+s)},a.prototype.__matrix=function(s){var r=this,h;s.queue.length&&this.iterate(function(c,u,d,l){var f,v,x,M;switch(c[0]){case"v":f=s.calc(0,c[1],!0),v=f[0]===0?["v",f[1]]:["l",f[0],f[1]];break;case"V":f=s.calc(d,c[1],!1),v=f[0]===s.calc(d,l,!1)[0]?["V",f[1]]:["L",f[0],f[1]];break;case"h":f=s.calc(c[1],0,!0),v=f[1]===0?["h",f[0]]:["l",f[0],f[1]];break;case"H":f=s.calc(c[1],l,!1),v=f[1]===s.calc(d,l,!1)[1]?["H",f[0]]:["L",f[0],f[1]];break;case"a":case"A":var T=s.toArray(),S=i(c[1],c[2],c[3]).transform(T);if(T[0]*T[3]-T[1]*T[2]<0&&(c[5]=c[5]?"0":"1"),f=s.calc(c[6],c[7],c[0]==="a"),c[0]==="A"&&c[6]===d&&c[7]===l||c[0]==="a"&&c[6]===0&&c[7]===0){v=[c[0]==="a"?"l":"L",f[0],f[1]];break}S.isDegenerate()?v=[c[0]==="a"?"l":"L",f[0],f[1]]:v=[c[0],S.rx,S.ry,S.ax,c[4],c[5],f[0],f[1]];break;case"m":M=u>0,f=s.calc(c[1],c[2],M),v=["m",f[0],f[1]];break;default:for(x=c[0],v=[x],M=x.toLowerCase()===x,h=1;h<c.length;h+=2)f=s.calc(c[h],c[h+1],M),v.push(f[0],f[1])}r.segments[u]=v},!0)},a.prototype.__evaluateStack=function(){var s,r;if(this.__stack.length){if(this.__stack.length===1){this.__matrix(this.__stack[0]),this.__stack=[];return}for(s=t(),r=this.__stack.length;--r>=0;)s.matrix(this.__stack[r].toArray());this.__matrix(s),this.__stack=[]}},a.prototype.toString=function(){var s="",r="",h=!1;this.__evaluateStack();for(var c=0,u=this.segments.length;c<u;c++){var d=this.segments[c],l=d[0];l!==r||l==="m"||l==="M"?(l==="m"&&r==="z"&&(s+=" "),s+=l,h=!1):h=!0;for(var f=1;f<d.length;f++){var v=d[f];f===1?h&&v>=0&&(s+=" "):v>=0&&(s+=" "),s+=v}r=l}return s},a.prototype.translate=function(s,r){return this.__stack.push(t().translate(s,r||0)),this},a.prototype.scale=function(s,r){return this.__stack.push(t().scale(s,!r&&r!==0?s:r)),this},a.prototype.rotate=function(s,r,h){return this.__stack.push(t().rotate(s,r||0,h||0)),this},a.prototype.skewX=function(s){return this.__stack.push(t().skewX(s)),this},a.prototype.skewY=function(s){return this.__stack.push(t().skewY(s)),this},a.prototype.matrix=function(s){return this.__stack.push(t().matrix(s)),this},a.prototype.transform=function(s){return s.trim()?(this.__stack.push(e(s)),this):this},a.prototype.round=function(s){var r=0,h=0,c=0,u=0,d;return s=s||0,this.__evaluateStack(),this.segments.forEach(function(l){var f=l[0].toLowerCase()===l[0];switch(l[0]){case"H":case"h":f&&(l[1]+=c),c=l[1]-l[1].toFixed(s),l[1]=+l[1].toFixed(s);return;case"V":case"v":f&&(l[1]+=u),u=l[1]-l[1].toFixed(s),l[1]=+l[1].toFixed(s);return;case"Z":case"z":c=r,u=h;return;case"M":case"m":f&&(l[1]+=c,l[2]+=u),c=l[1]-l[1].toFixed(s),u=l[2]-l[2].toFixed(s),r=c,h=u,l[1]=+l[1].toFixed(s),l[2]=+l[2].toFixed(s);return;case"A":case"a":f&&(l[6]+=c,l[7]+=u),c=l[6]-l[6].toFixed(s),u=l[7]-l[7].toFixed(s),l[1]=+l[1].toFixed(s),l[2]=+l[2].toFixed(s),l[3]=+l[3].toFixed(s+2),l[6]=+l[6].toFixed(s),l[7]=+l[7].toFixed(s);return;default:d=l.length,f&&(l[d-2]+=c,l[d-1]+=u),c=l[d-2]-l[d-2].toFixed(s),u=l[d-1]-l[d-1].toFixed(s),l.forEach(function(v,x){x&&(l[x]=+l[x].toFixed(s))});return}}),this},a.prototype.iterate=function(s,r){var h=this.segments,c={},u=!1,d=0,l=0,f=0,v=0,x,M,T;if(r||this.__evaluateStack(),h.forEach(function(S,P){var E=s(S,P,d,l);Array.isArray(E)&&(c[P]=E,u=!0);var L=S[0]===S[0].toLowerCase();switch(S[0]){case"m":case"M":d=S[1]+(L?d:0),l=S[2]+(L?l:0),f=d,v=l;return;case"h":case"H":d=S[1]+(L?d:0);return;case"v":case"V":l=S[1]+(L?l:0);return;case"z":case"Z":d=f,l=v;return;default:d=S[S.length-2]+(L?d:0),l=S[S.length-1]+(L?l:0)}}),!u)return this;for(T=[],x=0;x<h.length;x++)if(typeof c[x]<"u")for(M=0;M<c[x].length;M++)T.push(c[x][M]);else T.push(h[x]);return this.segments=T,this},a.prototype.abs=function(){return this.iterate(function(s,r,h,c){var u=s[0],d=u.toUpperCase(),l;if(u!==d)switch(s[0]=d,u){case"v":s[1]+=c;return;case"a":s[6]+=h,s[7]+=c;return;default:for(l=1;l<s.length;l++)s[l]+=l%2?h:c}},!0),this},a.prototype.rel=function(){return this.iterate(function(s,r,h,c){var u=s[0],d=u.toLowerCase(),l;if(u!==d&&!(r===0&&u==="M"))switch(s[0]=d,u){case"V":s[1]-=c;return;case"A":s[6]-=h,s[7]-=c;return;default:for(l=1;l<s.length;l++)s[l]-=l%2?h:c}},!0),this},a.prototype.unarc=function(){return this.iterate(function(s,r,h,c){var u,d,l,f=[],v=s[0];return v!=="A"&&v!=="a"?null:(v==="a"?(d=h+s[6],l=c+s[7]):(d=s[6],l=s[7]),u=o(h,c,d,l,s[4],s[5],s[1],s[2],s[3]),u.length===0?[[s[0]==="a"?"l":"L",s[6],s[7]]]:(u.forEach(function(x){f.push(["C",x[2],x[3],x[4],x[5],x[6],x[7]])}),f))}),this},a.prototype.unshort=function(){var s=this.segments,r,h,c,u,d;return this.iterate(function(l,f,v,x){var M=l[0],T=M.toUpperCase(),S;f&&(T==="T"?(S=M==="t",c=s[f-1],c[0]==="Q"?(r=c[1]-v,h=c[2]-x):c[0]==="q"?(r=c[1]-c[3],h=c[2]-c[4]):(r=0,h=0),u=-r,d=-h,S||(u+=v,d+=x),s[f]=[S?"q":"Q",u,d,l[1],l[2]]):T==="S"&&(S=M==="s",c=s[f-1],c[0]==="C"?(r=c[3]-v,h=c[4]-x):c[0]==="c"?(r=c[3]-c[5],h=c[4]-c[6]):(r=0,h=0),u=-r,d=-h,S||(u+=v,d+=x),s[f]=[S?"c":"C",u,d,l[1],l[2],l[3],l[4]]))}),this},ce=a,ce}var ue,a0;function wn(){return a0||(a0=1,ue=vn()),ue}var mn=wn();const bn=gn(mn);var fe={a:7,c:6,h:1,l:2,m:2,q:4,s:4,t:2,v:1,z:0},An=/([astvzqmhlc])([^astvzqmhlc]*)/ig;function Mn(n){var e=[];return n.replace(An,function(t,o,i){var a=o.toLowerCase();for(i=Tn(i),a==="m"&&i.length>2&&(e.push([o].concat(i.splice(0,2))),a="l",o=o==="m"?"l":"L");i.length>=0;){if(i.length===fe[a])return i.unshift(o),e.push(i);if(i.length<fe[a])throw new Error("malformed path data");e.push([o].concat(i.splice(0,fe[a])))}}),e}var Ln=/-?[0-9]*\.?[0-9]+(?:e[-+]?\d+)?/ig;function Tn(n){var e=n.match(Ln);return e?e.map(Number):[]}function at(n,e,t,o,i,a,s,r){return new ge(n,e,t,o,i,a,s,r)}function ge(n,e,t,o,i,a,s,r){this.a={x:n,y:e},this.b={x:t,y:o},this.c={x:i,y:a},this.d={x:s,y:r},s!=null&&r!==null&&r!==void 0?(this.getArcLength=Fn,this.getPoint=Sn,this.getDerivative=Pn):(this.getArcLength=En,this.getPoint=h0,this.getDerivative=Cn),this.init()}ge.prototype={constructor:ge,init:function(){this.length=this.getArcLength([this.a.x,this.b.x,this.c.x,this.d.x],[this.a.y,this.b.y,this.c.y,this.d.y])},getTotalLength:function(){return this.length},getPointAtLength:function(n){var e=de(n,this.length,this.getArcLength,[this.a.x,this.b.x,this.c.x,this.d.x],[this.a.y,this.b.y,this.c.y,this.d.y]);return this.getPoint([this.a.x,this.b.x,this.c.x,this.d.x],[this.a.y,this.b.y,this.c.y,this.d.y],e)},getTangentAtLength:function(n){var e=de(n,this.length,this.getArcLength,[this.a.x,this.b.x,this.c.x,this.d.x],[this.a.y,this.b.y,this.c.y,this.d.y]),t=this.getDerivative([this.a.x,this.b.x,this.c.x,this.d.x],[this.a.y,this.b.y,this.c.y,this.d.y],e),o=Math.sqrt(t.x*t.x+t.y*t.y),i;return o>0?i={x:t.x/o,y:t.y/o}:i={x:0,y:0},i},getPropertiesAtLength:function(n){var e=de(n,this.length,this.getArcLength,[this.a.x,this.b.x,this.c.x,this.d.x],[this.a.y,this.b.y,this.c.y,this.d.y]),t=this.getDerivative([this.a.x,this.b.x,this.c.x,this.d.x],[this.a.y,this.b.y,this.c.y,this.d.y],e),o=Math.sqrt(t.x*t.x+t.y*t.y),i;o>0?i={x:t.x/o,y:t.y/o}:i={x:0,y:0};var a=this.getPoint([this.a.x,this.b.x,this.c.x,this.d.x],[this.a.y,this.b.y,this.c.y,this.d.y],e);return{x:a.x,y:a.y,tangentX:i.x,tangentY:i.y}}};function Cn(n,e,t){return{x:(1-t)*2*(n[1]-n[0])+t*2*(n[2]-n[1]),y:(1-t)*2*(e[1]-e[0])+t*2*(e[2]-e[1])}}function Pn(n,e,t){var o=h0([3*(n[1]-n[0]),3*(n[2]-n[1]),3*(n[3]-n[2])],[3*(e[1]-e[0]),3*(e[2]-e[1]),3*(e[3]-e[2])],t);return o}function de(n,e,t,o,i){for(var a=1,s=n/e,r=(n-t(o,i,s))/e;a>.001;){var h=t(o,i,s+r),c=t(o,i,s-r),u=Math.abs(n-h)/e,d=Math.abs(n-c)/e;u<a?(a=u,s+=r):d<a?(a=d,s-=r):r/=2}return s}function h0(n,e,t){var o=(1-t)*(1-t)*n[0]+2*(1-t)*t*n[1]+t*t*n[2],i=(1-t)*(1-t)*e[0]+2*(1-t)*t*e[1]+t*t*e[2];return{x:o,y:i}}function Sn(n,e,t){var o=(1-t)*(1-t)*(1-t)*n[0]+3*(1-t)*(1-t)*t*n[1]+3*(1-t)*t*t*n[2]+t*t*t*n[3],i=(1-t)*(1-t)*(1-t)*e[0]+3*(1-t)*(1-t)*t*e[1]+3*(1-t)*t*t*e[2]+t*t*t*e[3];return{x:o,y:i}}function En(n,e,t){t===void 0&&(t=1);var o=n[0]-2*n[1]+n[2],i=e[0]-2*e[1]+e[2],a=2*n[1]-2*n[0],s=2*e[1]-2*e[0],r=4*(o*o+i*i),h=4*(o*a+i*s),c=a*a+s*s;if(r===0)return t*Math.sqrt(Math.pow(n[2]-n[0],2)+Math.pow(e[2]-e[0],2));var u=h/(2*r),d=c/r,l=t+u,f=d-u*u;return Math.sqrt(r)/2*(l*Math.sqrt(l*l+f)-u*Math.sqrt(u*u+f)+f*Math.log(Math.abs((l+Math.sqrt(l*l+f))/(u+Math.sqrt(u*u+f)))))}var In=[[],[],[-.5773502691896257,.5773502691896257],[0,-.7745966692414834,.7745966692414834],[-.33998104358485626,.33998104358485626,-.8611363115940526,.8611363115940526],[0,-.5384693101056831,.5384693101056831,-.906179845938664,.906179845938664],[.6612093864662645,-.6612093864662645,-.2386191860831969,.2386191860831969,-.932469514203152,.932469514203152],[0,.4058451513773972,-.4058451513773972,-.7415311855993945,.7415311855993945,-.9491079123427585,.9491079123427585],[-.1834346424956498,.1834346424956498,-.525532409916329,.525532409916329,-.7966664774136267,.7966664774136267,-.9602898564975363,.9602898564975363],[0,-.8360311073266358,.8360311073266358,-.9681602395076261,.9681602395076261,-.3242534234038089,.3242534234038089,-.6133714327005904,.6133714327005904],[-.14887433898163122,.14887433898163122,-.4333953941292472,.4333953941292472,-.6794095682990244,.6794095682990244,-.8650633666889845,.8650633666889845,-.9739065285171717,.9739065285171717],[0,-.26954315595234496,.26954315595234496,-.5190961292068118,.5190961292068118,-.7301520055740494,.7301520055740494,-.8870625997680953,.8870625997680953,-.978228658146057,.978228658146057],[-.1252334085114689,.1252334085114689,-.3678314989981802,.3678314989981802,-.5873179542866175,.5873179542866175,-.7699026741943047,.7699026741943047,-.9041172563704749,.9041172563704749,-.9815606342467192,.9815606342467192],[0,-.2304583159551348,.2304583159551348,-.44849275103644687,.44849275103644687,-.6423493394403402,.6423493394403402,-.8015780907333099,.8015780907333099,-.9175983992229779,.9175983992229779,-.9841830547185881,.9841830547185881],[-.10805494870734367,.10805494870734367,-.31911236892788974,.31911236892788974,-.5152486363581541,.5152486363581541,-.6872929048116855,.6872929048116855,-.827201315069765,.827201315069765,-.9284348836635735,.9284348836635735,-.9862838086968123,.9862838086968123],[0,-.20119409399743451,.20119409399743451,-.3941513470775634,.3941513470775634,-.5709721726085388,.5709721726085388,-.7244177313601701,.7244177313601701,-.8482065834104272,.8482065834104272,-.937273392400706,.937273392400706,-.9879925180204854,.9879925180204854],[-.09501250983763744,.09501250983763744,-.2816035507792589,.2816035507792589,-.45801677765722737,.45801677765722737,-.6178762444026438,.6178762444026438,-.755404408355003,.755404408355003,-.8656312023878318,.8656312023878318,-.9445750230732326,.9445750230732326,-.9894009349916499,.9894009349916499],[0,-.17848418149584785,.17848418149584785,-.3512317634538763,.3512317634538763,-.5126905370864769,.5126905370864769,-.6576711592166907,.6576711592166907,-.7815140038968014,.7815140038968014,-.8802391537269859,.8802391537269859,-.9506755217687678,.9506755217687678,-.9905754753144174,.9905754753144174],[-.0847750130417353,.0847750130417353,-.2518862256915055,.2518862256915055,-.41175116146284263,.41175116146284263,-.5597708310739475,.5597708310739475,-.6916870430603532,.6916870430603532,-.8037049589725231,.8037049589725231,-.8926024664975557,.8926024664975557,-.9558239495713977,.9558239495713977,-.9915651684209309,.9915651684209309],[0,-.16035864564022537,.16035864564022537,-.31656409996362983,.31656409996362983,-.46457074137596094,.46457074137596094,-.600545304661681,.600545304661681,-.7209661773352294,.7209661773352294,-.8227146565371428,.8227146565371428,-.9031559036148179,.9031559036148179,-.96020815213483,.96020815213483,-.9924068438435844,.9924068438435844],[-.07652652113349734,.07652652113349734,-.22778585114164507,.22778585114164507,-.37370608871541955,.37370608871541955,-.5108670019508271,.5108670019508271,-.636053680726515,.636053680726515,-.7463319064601508,.7463319064601508,-.8391169718222188,.8391169718222188,-.912234428251326,.912234428251326,-.9639719272779138,.9639719272779138,-.9931285991850949,.9931285991850949],[0,-.1455618541608951,.1455618541608951,-.2880213168024011,.2880213168024011,-.4243421202074388,.4243421202074388,-.5516188358872198,.5516188358872198,-.6671388041974123,.6671388041974123,-.7684399634756779,.7684399634756779,-.8533633645833173,.8533633645833173,-.9200993341504008,.9200993341504008,-.9672268385663063,.9672268385663063,-.9937521706203895,.9937521706203895],[-.06973927331972223,.06973927331972223,-.20786042668822127,.20786042668822127,-.34193582089208424,.34193582089208424,-.469355837986757,.469355837986757,-.5876404035069116,.5876404035069116,-.6944872631866827,.6944872631866827,-.7878168059792081,.7878168059792081,-.8658125777203002,.8658125777203002,-.926956772187174,.926956772187174,-.9700604978354287,.9700604978354287,-.9942945854823992,.9942945854823992],[0,-.1332568242984661,.1332568242984661,-.26413568097034495,.26413568097034495,-.3903010380302908,.3903010380302908,-.5095014778460075,.5095014778460075,-.6196098757636461,.6196098757636461,-.7186613631319502,.7186613631319502,-.8048884016188399,.8048884016188399,-.8767523582704416,.8767523582704416,-.9329710868260161,.9329710868260161,-.9725424712181152,.9725424712181152,-.9947693349975522,.9947693349975522],[-.06405689286260563,.06405689286260563,-.1911188674736163,.1911188674736163,-.3150426796961634,.3150426796961634,-.4337935076260451,.4337935076260451,-.5454214713888396,.5454214713888396,-.6480936519369755,.6480936519369755,-.7401241915785544,.7401241915785544,-.820001985973903,.820001985973903,-.8864155270044011,.8864155270044011,-.9382745520027328,.9382745520027328,-.9747285559713095,.9747285559713095,-.9951872199970213,.9951872199970213]],kn=[[],[],[1,1],[.8888888888888888,.5555555555555556,.5555555555555556],[.6521451548625461,.6521451548625461,.34785484513745385,.34785484513745385],[.5688888888888889,.47862867049936647,.47862867049936647,.23692688505618908,.23692688505618908],[.3607615730481386,.3607615730481386,.46791393457269104,.46791393457269104,.17132449237917036,.17132449237917036],[.4179591836734694,.3818300505051189,.3818300505051189,.27970539148927664,.27970539148927664,.1294849661688697,.1294849661688697],[.362683783378362,.362683783378362,.31370664587788727,.31370664587788727,.22238103445337448,.22238103445337448,.10122853629037626,.10122853629037626],[.3302393550012598,.1806481606948574,.1806481606948574,.08127438836157441,.08127438836157441,.31234707704000286,.31234707704000286,.26061069640293544,.26061069640293544],[.29552422471475287,.29552422471475287,.26926671930999635,.26926671930999635,.21908636251598204,.21908636251598204,.1494513491505806,.1494513491505806,.06667134430868814,.06667134430868814],[.2729250867779006,.26280454451024665,.26280454451024665,.23319376459199048,.23319376459199048,.18629021092773426,.18629021092773426,.1255803694649046,.1255803694649046,.05566856711617366,.05566856711617366],[.24914704581340277,.24914704581340277,.2334925365383548,.2334925365383548,.20316742672306592,.20316742672306592,.16007832854334622,.16007832854334622,.10693932599531843,.10693932599531843,.04717533638651183,.04717533638651183],[.2325515532308739,.22628318026289723,.22628318026289723,.2078160475368885,.2078160475368885,.17814598076194574,.17814598076194574,.13887351021978725,.13887351021978725,.09212149983772845,.09212149983772845,.04048400476531588,.04048400476531588],[.2152638534631578,.2152638534631578,.2051984637212956,.2051984637212956,.18553839747793782,.18553839747793782,.15720316715819355,.15720316715819355,.12151857068790319,.12151857068790319,.08015808715976021,.08015808715976021,.03511946033175186,.03511946033175186],[.2025782419255613,.19843148532711158,.19843148532711158,.1861610000155622,.1861610000155622,.16626920581699392,.16626920581699392,.13957067792615432,.13957067792615432,.10715922046717194,.10715922046717194,.07036604748810812,.07036604748810812,.03075324199611727,.03075324199611727],[.1894506104550685,.1894506104550685,.18260341504492358,.18260341504492358,.16915651939500254,.16915651939500254,.14959598881657674,.14959598881657674,.12462897125553388,.12462897125553388,.09515851168249279,.09515851168249279,.062253523938647894,.062253523938647894,.027152459411754096,.027152459411754096],[.17944647035620653,.17656270536699264,.17656270536699264,.16800410215645004,.16800410215645004,.15404576107681028,.15404576107681028,.13513636846852548,.13513636846852548,.11188384719340397,.11188384719340397,.08503614831717918,.08503614831717918,.0554595293739872,.0554595293739872,.02414830286854793,.02414830286854793],[.1691423829631436,.1691423829631436,.16427648374583273,.16427648374583273,.15468467512626524,.15468467512626524,.14064291467065065,.14064291467065065,.12255520671147846,.12255520671147846,.10094204410628717,.10094204410628717,.07642573025488905,.07642573025488905,.0497145488949698,.0497145488949698,.02161601352648331,.02161601352648331],[.1610544498487837,.15896884339395434,.15896884339395434,.15276604206585967,.15276604206585967,.1426067021736066,.1426067021736066,.12875396253933621,.12875396253933621,.11156664554733399,.11156664554733399,.09149002162245,.09149002162245,.06904454273764123,.06904454273764123,.0448142267656996,.0448142267656996,.019461788229726478,.019461788229726478],[.15275338713072584,.15275338713072584,.14917298647260374,.14917298647260374,.14209610931838204,.14209610931838204,.13168863844917664,.13168863844917664,.11819453196151841,.11819453196151841,.10193011981724044,.10193011981724044,.08327674157670475,.08327674157670475,.06267204833410907,.06267204833410907,.04060142980038694,.04060142980038694,.017614007139152118,.017614007139152118],[.14608113364969041,.14452440398997005,.14452440398997005,.13988739479107315,.13988739479107315,.13226893863333747,.13226893863333747,.12183141605372853,.12183141605372853,.10879729916714838,.10879729916714838,.09344442345603386,.09344442345603386,.0761001136283793,.0761001136283793,.057134425426857205,.057134425426857205,.036953789770852494,.036953789770852494,.016017228257774335,.016017228257774335],[.13925187285563198,.13925187285563198,.13654149834601517,.13654149834601517,.13117350478706238,.13117350478706238,.12325237681051242,.12325237681051242,.11293229608053922,.11293229608053922,.10041414444288096,.10041414444288096,.08594160621706773,.08594160621706773,.06979646842452049,.06979646842452049,.052293335152683286,.052293335152683286,.03377490158481415,.03377490158481415,.0146279952982722,.0146279952982722],[.13365457218610619,.1324620394046966,.1324620394046966,.12890572218808216,.12890572218808216,.12304908430672953,.12304908430672953,.11499664022241136,.11499664022241136,.10489209146454141,.10489209146454141,.09291576606003515,.09291576606003515,.07928141177671895,.07928141177671895,.06423242140852585,.06423242140852585,.04803767173108467,.04803767173108467,.030988005856979445,.030988005856979445,.013411859487141771,.013411859487141771],[.12793819534675216,.12793819534675216,.1258374563468283,.1258374563468283,.12167047292780339,.12167047292780339,.1155056680537256,.1155056680537256,.10744427011596563,.10744427011596563,.09761865210411388,.09761865210411388,.08619016153195327,.08619016153195327,.0733464814110803,.0733464814110803,.05929858491543678,.05929858491543678,.04427743881741981,.04427743881741981,.028531388628933663,.028531388628933663,.0123412297999872,.0123412297999872]],On=[[1],[1,1],[1,2,1],[1,3,3,1]];function _n(n,e){return On[n][e]}function pe(n,e,t){var o=t.length-1,i,a,s;if(o===0)return 0;if(n===0){for(a=0,s=0;s<=o;s++)a+=_n(o,s)*Math.pow(1-e,o-s)*Math.pow(e,s)*t[s];return a}else{for(i=new Array(o),s=0;s<o;s++)i[s]=o*(t[s+1]-t[s]);return pe(n-1,e,i)}}function Nn(n,e,t){var o=pe(1,t,n),i=pe(1,t,e),a=o*o+i*i;return Math.sqrt(a)}function Fn(n,e,t){var o,i,a,s;t===void 0&&(t=1);var r=20;for(o=t/2,i=0,a=0;a<r;a++)s=o*In[r][a]+o,i+=kn[r][a]*Nn(n,e,s);return o*i}var kt=Math.PI*2;function l0(n,e,t,o){var i=n*o-e*t<0?-1:1,a=n*t+e*o;return a>1&&(a=1),a<-1&&(a=-1),i*Math.acos(a)}function Rn(n,e,t,o,i,a,s,r,h,c){var u=c*(n-t)/2+h*(e-o)/2,d=-h*(n-t)/2+c*(e-o)/2,l=s*s,f=r*r,v=u*u,x=d*d,M=l*f-l*x-f*v;M<0&&(M=0),M/=l*x+f*v,M=Math.sqrt(M)*(i===a?-1:1);var T=M*s/r*d,S=M*-r/s*u,P=c*T-h*S+(n+t)/2,E=h*T+c*S+(e+o)/2,L=(u-T)/s,I=(d-S)/r,B=(-u-T)/s,K=(-d-S)/r,j=l0(1,0,L,I),W=l0(L,I,B,K);return a===0&&W>0&&(W-=kt),a===1&&W<0&&(W+=kt),[P,E,j,W]}function Bn(n,e){var t=1.3333333333333333*Math.tan(e/4),o=Math.cos(n),i=Math.sin(n),a=Math.cos(n+e),s=Math.sin(n+e);return[o,i,o-i*t,i+o*t,a+s*t,s-a*t,a,s]}function Dn(n,e,t,o,i,a,s,r,h){var c=Math.sin(i*kt/360),u=Math.cos(i*kt/360),d=u*(n-r)/2+c*(e-h)/2,l=-c*(n-r)/2+u*(e-h)/2;if(d===0&&l===0)return[];if(t===0||o===0)return[];t=Math.abs(t),o=Math.abs(o);var f=d*d/(t*t)+l*l/(o*o);f>1&&(t*=Math.sqrt(f),o*=Math.sqrt(f));var v=Rn(n,e,r,h,a,s,t,o,c,u),x=[],M=v[2],T=v[3],S=Math.max(Math.ceil(Math.abs(T)/(kt/4)),1);T/=S;for(var P=0;P<S;P++)x.push(Bn(M,T)),M+=T;return x.map(function(E){for(var L=0;L<E.length;L+=2){var I=E[L+0],B=E[L+1];I*=t,B*=o;var K=u*I-c*B,j=c*I+u*B;E[L+0]=K+v[0],E[L+1]=j+v[1]}return E})}function c0(n,e,t,o,i,a,s,r,h){return new ye(n,e,t,o,i,a,s,r,h)}function ye(n,e,t,o,i,a,s,r,h){var c=0,u=[],d=[],l=Dn(n,e,t,o,i,a,s,r,h);l.forEach(function(f){var v=new at(f[0],f[1],f[2],f[3],f[4],f[5],f[6],f[7]),x=v.getTotalLength();c+=x,u.push(x),d.push(v)}),this.length=c,this.partialLengths=u,this.curves=d}ye.prototype={constructor:ye,init:function(){},getTotalLength:function(){return this.length},getPointAtLength:function(n){n<0?n=0:n>this.length&&(n=this.length);for(var e=this.partialLengths.length-1;this.partialLengths[e]>=n&&this.partialLengths[e]>0;)e--;e<this.partialLengths.length-1&&e++;for(var t=0,o=0;o<e;o++)t+=this.partialLengths[o];return this.curves[e].getPointAtLength(n-t)},getTangentAtLength:function(n){n<0?n=0:n>this.length&&(n=this.length);for(var e=this.partialLengths.length-1;this.partialLengths[e]>=n&&this.partialLengths[e]>0;)e--;e<this.partialLengths.length-1&&e++;for(var t=0,o=0;o<e;o++)t+=this.partialLengths[o];return this.curves[e].getTangentAtLength(n-t)},getPropertiesAtLength:function(n){var e=this.getTangentAtLength(n),t=this.getPointAtLength(n);return{x:t.x,y:t.y,tangentX:e.x,tangentY:e.y}}};function ht(n,e,t,o){return new Ot(n,e,t,o)}function Ot(n,e,t,o){this.x0=n,this.x1=e,this.y0=t,this.y1=o}Ot.prototype.getTotalLength=function(){return Math.sqrt(Math.pow(this.x0-this.x1,2)+Math.pow(this.y0-this.y1,2))},Ot.prototype.getPointAtLength=function(n){var e=n/Math.sqrt(Math.pow(this.x0-this.x1,2)+Math.pow(this.y0-this.y1,2)),t=(this.x1-this.x0)*e,o=(this.y1-this.y0)*e;return{x:this.x0+t,y:this.y0+o}},Ot.prototype.getTangentAtLength=function(){var n=Math.sqrt((this.x1-this.x0)*(this.x1-this.x0)+(this.y1-this.y0)*(this.y1-this.y0));return{x:(this.x1-this.x0)/n,y:(this.y1-this.y0)/n}},Ot.prototype.getPropertiesAtLength=function(n){var e=this.getPointAtLength(n),t=this.getTangentAtLength();return{x:e.x,y:e.y,tangentX:t.x,tangentY:t.y}};function qn(n){var e=0,t=[],o=[];function i(s){if(!s)return null;for(var r=Mn(s),h=[0,0],c=[0,0],u,d,l=0;l<r.length;l++)r[l][0]==="M"?(h=[r[l][1],r[l][2]],d=[h[0],h[1]],o.push(null)):r[l][0]==="m"?(h=[r[l][1]+h[0],r[l][2]+h[1]],d=[h[0],h[1]],o.push(null)):r[l][0]==="L"?(e=e+Math.sqrt(Math.pow(h[0]-r[l][1],2)+Math.pow(h[1]-r[l][2],2)),o.push(new ht(h[0],r[l][1],h[1],r[l][2])),h=[r[l][1],r[l][2]]):r[l][0]==="l"?(e=e+Math.sqrt(Math.pow(r[l][1],2)+Math.pow(r[l][2],2)),o.push(new ht(h[0],r[l][1]+h[0],h[1],r[l][2]+h[1])),h=[r[l][1]+h[0],r[l][2]+h[1]]):r[l][0]==="H"?(e=e+Math.abs(h[0]-r[l][1]),o.push(new ht(h[0],r[l][1],h[1],h[1])),h[0]=r[l][1]):r[l][0]==="h"?(e=e+Math.abs(r[l][1]),o.push(new ht(h[0],h[0]+r[l][1],h[1],h[1])),h[0]=r[l][1]+h[0]):r[l][0]==="V"?(e=e+Math.abs(h[1]-r[l][1]),o.push(new ht(h[0],h[0],h[1],r[l][1])),h[1]=r[l][1]):r[l][0]==="v"?(e=e+Math.abs(r[l][1]),o.push(new ht(h[0],h[0],h[1],h[1]+r[l][1])),h[1]=r[l][1]+h[1]):r[l][0]==="z"||r[l][0]==="Z"?(e=e+Math.sqrt(Math.pow(d[0]-h[0],2)+Math.pow(d[1]-h[1],2)),o.push(new ht(h[0],d[0],h[1],d[1])),h=[d[0],d[1]]):r[l][0]==="C"?(u=new at(h[0],h[1],r[l][1],r[l][2],r[l][3],r[l][4],r[l][5],r[l][6]),e=e+u.getTotalLength(),h=[r[l][5],r[l][6]],o.push(u)):r[l][0]==="c"?(u=new at(h[0],h[1],h[0]+r[l][1],h[1]+r[l][2],h[0]+r[l][3],h[1]+r[l][4],h[0]+r[l][5],h[1]+r[l][6]),e=e+u.getTotalLength(),h=[r[l][5]+h[0],r[l][6]+h[1]],o.push(u)):r[l][0]==="S"?(l>0&&["C","c","S","s"].indexOf(r[l-1][0])>-1?u=new at(h[0],h[1],2*h[0]-r[l-1][r[l-1].length-4],2*h[1]-r[l-1][r[l-1].length-3],r[l][1],r[l][2],r[l][3],r[l][4]):u=new at(h[0],h[1],h[0],h[1],r[l][1],r[l][2],r[l][3],r[l][4]),e=e+u.getTotalLength(),h=[r[l][3],r[l][4]],o.push(u)):r[l][0]==="s"?(l>0&&["C","c","S","s"].indexOf(r[l-1][0])>-1?u=new at(h[0],h[1],h[0]+u.d.x-u.c.x,h[1]+u.d.y-u.c.y,h[0]+r[l][1],h[1]+r[l][2],h[0]+r[l][3],h[1]+r[l][4]):u=new at(h[0],h[1],h[0],h[1],h[0]+r[l][1],h[1]+r[l][2],h[0]+r[l][3],h[1]+r[l][4]),e=e+u.getTotalLength(),h=[r[l][3]+h[0],r[l][4]+h[1]],o.push(u)):r[l][0]==="Q"?(h[0]!=r[l][1]&&h[1]!=r[l][2]?u=new at(h[0],h[1],r[l][1],r[l][2],r[l][3],r[l][4]):u=new ht(r[l][1],r[l][3],r[l][2],r[l][4]),e=e+u.getTotalLength(),o.push(u),h=[r[l][3],r[l][4]],c=[r[l][1],r[l][2]]):r[l][0]==="q"?(r[l][1]==0&&r[l][2]==0?u=new ht(h[0]+r[l][1],h[0]+r[l][3],h[1]+r[l][2],h[1]+r[l][4]):u=new at(h[0],h[1],h[0]+r[l][1],h[1]+r[l][2],h[0]+r[l][3],h[1]+r[l][4]),e=e+u.getTotalLength(),c=[h[0]+r[l][1],h[1]+r[l][2]],h=[r[l][3]+h[0],r[l][4]+h[1]],o.push(u)):r[l][0]==="T"?(l>0&&["Q","q","T","t"].indexOf(r[l-1][0])>-1?u=new at(h[0],h[1],2*h[0]-c[0],2*h[1]-c[1],r[l][1],r[l][2]):u=new ht(h[0],r[l][1],h[1],r[l][2]),o.push(u),e=e+u.getTotalLength(),c=[2*h[0]-c[0],2*h[1]-c[1]],h=[r[l][1],r[l][2]]):r[l][0]==="t"?(l>0&&["Q","q","T","t"].indexOf(r[l-1][0])>-1?u=new at(h[0],h[1],2*h[0]-c[0],2*h[1]-c[1],h[0]+r[l][1],h[1]+r[l][2]):u=new ht(h[0],h[0]+r[l][1],h[1],h[1]+r[l][2]),e=e+u.getTotalLength(),c=[2*h[0]-c[0],2*h[1]-c[1]],h=[r[l][1]+h[0],r[l][2]+h[0]],o.push(u)):r[l][0]==="A"?(u=new c0(h[0],h[1],r[l][1],r[l][2],r[l][3],r[l][4],r[l][5],r[l][6],r[l][7]),e=e+u.getTotalLength(),h=[r[l][6],r[l][7]],o.push(u)):r[l][0]==="a"&&(u=new c0(h[0],h[1],r[l][1],r[l][2],r[l][3],r[l][4],r[l][5],h[0]+r[l][6],h[1]+r[l][7]),e=e+u.getTotalLength(),h=[h[0]+r[l][6],h[1]+r[l][7]],o.push(u)),t.push(e);return i}i.getTotalLength=function(){return e},i.getPointAtLength=function(s){var r=a(s);return o[r.i].getPointAtLength(r.fraction)},i.getTangentAtLength=function(s){var r=a(s);return o[r.i].getTangentAtLength(r.fraction)},i.getPropertiesAtLength=function(s){var r=a(s);return o[r.i].getPropertiesAtLength(r.fraction)};var a=function(s){s<0?s=0:s>e&&(s=e);for(var r=t.length-1;t[r]>=s&&t[r]>0;)r--;return r++,{fraction:s-t[r-1],i:r}};return i(n)}function qt(n,e){return Math.sqrt((n[0]-e[0])*(n[0]-e[0])+(n[1]-e[1])*(n[1]-e[1]))}function u0(n,e,t){return[n[0]+(e[0]-n[0])*t,n[1]+(e[1]-n[1])*t]}function zn(n,e){return qt(n,e)<1e-9}function jn(n,e,t){let o=n.map((i,a)=>Hn(i,e[a]));return function(i){let a=o.map(s=>s(i));return t?Wn(a):a}}function Hn(n,e){return function(t){return n.map((o,i)=>o+t*(e[i]-o))}}function zt(n){return typeof n=="number"&&isFinite(n)}const xe=`All shapes must be supplied as arrays of [x, y] points or an SVG path string (https://developer.mozilla.org/en-US/docs/Web/SVG/Attribute/d).
|
|
1
|
+
(function(I,Y){typeof exports=="object"&&typeof module<"u"?Y(exports):typeof define=="function"&&define.amd?define(["exports"],Y):(I=typeof globalThis<"u"?globalThis:I||self,Y(I.Presenter={}))})(this,(function(I){"use strict";var Di=Object.defineProperty;var qi=(I,Y,At)=>Y in I?Di(I,Y,{enumerable:!0,configurable:!0,writable:!0,value:At}):I[Y]=At;var O=(I,Y,At)=>qi(I,typeof Y!="symbol"?Y+"":Y,At);var Tt,Mt,Lt,Ct,St;const Y={ANIMATE:"Animate",PAUSE:"Pause",UPDATE:"Update"};function At(n){return n*n*n}function I0(n){return--n*n*n+1}function k0(n){return((n*=2)<=1?n*n*n:(n-=2)*n*n+2)/2}var Ut=1.70158;(function n(e){e=+e;function t(o){return(o=+o)*o*(e*(o-1)+o)}return t.overshoot=n,t})(Ut),(function n(e){e=+e;function t(o){return--o*o*((o+1)*e+o)+1}return t.overshoot=n,t})(Ut);var O0=(function n(e){e=+e;function t(o){return((o*=2)<1?o*o*((e+1)*o-e):(o-=2)*o*((e+1)*o+e)+2)/2}return t.overshoot=n,t})(Ut);const Rt={LINEAR:n=>n,CUBIC:k0,CUBIC_IN:At,CUBIC_OUT:I0,BACK_IN_OUT:O0.overshoot(.8)},_0=Rt.LINEAR;function Bt(n,e,t={}){return{type:Y.ANIMATE,object:n,props:e,delay:0,duration:1e3,easing:_0,block:!1,interpolators:null,isKey:!1,shortcut:null,...typeof t=="number"?{duration:t}:t}}function N0(n,e={}){return Bt(n,{opacity:1},{duration:500,easing:Rt.CUBIC,...typeof e=="number"?{duration:e}:e})}function F0(n,e={}){return Bt(n,{opacity:0},{duration:500,easing:Rt.CUBIC,...typeof e=="number"?{duration:e}:e})}function $t(n,e,t={}){return{type:Y.UPDATE,isKey:!1,object:n,props:e,shortcut:null,...t}}function R0(n){return $t(n,{opacity:0})}function B0(n){return $t(n,{opacity:1})}const it={TOP_LEFT:"TopLeft",TOP:"Top",TOP_RIGHT:"TopRight",LEFT:"Left",CENTER:"Center",RIGHT:"Right",BOTTOM_LEFT:"BottomLeft",BOTTOM:"Bottom",BOTTOM_RIGHT:"BottomRight"},rt=it.TOP_LEFT;function K(n,e=0,t=0,o=1){if(typeof n=="string"){const i=n.replace("#",""),a=parseInt(i,16);return isNaN(a)?(console.warn("Invalid hex color format:",n),tt):i.length===6?{red:a>>16&255,green:a>>8&255,blue:a&255,alpha:1}:i.length===8?{red:a>>24&255,green:a>>16&255,blue:a>>8&255,alpha:(a&255)/255}:(console.warn("Invalid hex color format:",n),tt)}else if(typeof n=="number")return{red:n,green:e??0,blue:t??0,alpha:o??1};return{red:0,green:0,blue:0,alpha:1,...n}}K.BLACK=K(0,0,0),K.BLUE=K(0,0,255),K.GREEN=K(0,255,0),K.RED=K(255,0,0),K.TRANSPARENT=K(0,0,0,0),K.WHITE=K(255,255,255);const tt={red:0,green:0,blue:0,alpha:1};function Wt(n=null){return{content:null,setup:null,anchor:it.TOP_LEFT,height:0,width:0,x:0,y:0,...n}}function Ae(n,e=null){return n.alpha*(e??1)}function Pt(n,e=null){const{red:t,green:o,blue:i}=n,a=t<<16|o<<8|i,s=Math.round(Ae(n,e)*255);return`#${a.toString(16).padStart(6,"0")}${s!==255?s.toString(16).padStart(2,"0"):""}`}function D0(n=null){const{url:e="https://wikipedia.org/",backgroundColor:t=K.TRANSPARENT,strokeColor:o=tt,strokeWidth:i=0,pointerEvents:a="auto",scale:s=1,anchor:r=rt,height:l=1e3,width:c=1e3,x:u=0,y:g=0}=n||{},h=document.createElement("iframe");h.src=e,h.style.backgroundColor=Pt(t),h.style.border=i>0?`${i}px solid ${Pt(o)}`:"none",h.style.pointerEvents=a;const f=(100/s).toFixed(3)+"%";return h.style.height=i===0?f:`calc(${f} - ${i*2}px)`,h.style.width=i===0?f:`calc(${f} - ${i*2}px)`,h.style.transform=`scale(${s})`,h.style.transformOrigin="top left",Wt({content:h,anchor:r,height:l,width:c,x:u,y:g})}const pt={LEFT:"left",CENTER:"center",RIGHT:"right"},q0=pt.LEFT;function st(n,e){throw new Error("Unexpected value: "+n)}function z0(n=null){const{alignment:e=pt.LEFT,scale:t=1,anchor:o=rt,height:i=1e3,width:a=1e3,x:s=0,y:r=0}=n||{};function l(c){const u=document.createElement("video");switch(u.autoplay=!0,u.style.transform=`scale(${t})`,e){case pt.LEFT:u.style.transformOrigin="top left";break;case pt.CENTER:u.style.transformOrigin="top center";break;case pt.RIGHT:u.style.transformOrigin="top right";break;default:st(e)}c.appendChild(u);const g={video:{displaySurface:"window"},audio:!1};return navigator.mediaDevices.getDisplayMedia(g).then(h=>{const f=h.getVideoTracks()[0];f!==void 0&&(f.onended=function(){u.style.display="none"}),u.srcObject=h,u.play()}).catch(h=>{console.error("Could not start screen capture -",h)}),()=>{u.srcObject.getTracks().forEach(f=>f.stop()),u.style.display="none",u.srcObject=null}}return Wt({content:null,setup:l,anchor:o,height:i,width:a,x:s,y:r})}const V={ARROW:"Arrow",CIRCLE:"Circle",GROUP:"Group",IMAGE:"Image",LINE:"Line",MASK:"Mask",PATH:"Path",POLYGON:"Polygon",RECTANGLE:"Rectangle",SLIDE_OBJECT:"SlideObject",SPOTLIGHT:"Spotlight",SVG:"SVG",TEXT:"Text"};function et(n){return{objectType:V.SLIDE_OBJECT,opacity:1,...n}}function V0(n=null){const{arrowheadSize:e,width:t=10,...o}=n||{},i=e??t*4;return et({objectType:V.ARROW,arrowheadSize:i,color:tt,drawn:1,endX:100,endY:100,isArrowheadDoubled:!1,isArrowheadFilled:!1,isDrawnFromCenter:!1,startX:0,startY:0,width:t,...o})}const j0=50;function H0(n=null){return et({objectType:V.CIRCLE,anchor:rt,strokeColor:tt,strokeWidth:0,drawn:1,fillColor:tt,radius:j0,x:0,y:0,...n})}function Gt(n,e=null){return et({objectType:V.GROUP,anchor:rt,height:0,objects:n,previewColor:null,rotateOriginPreviewSize:0,rotateOriginX:0,rotateOriginY:0,rotation:0,skewOriginPreviewSize:0,skewOriginX:0,skewOriginY:0,skewX:0,skewY:0,scale:1,scaleX:1,scaleY:1,width:0,x:0,y:0,...e})}function U0(n){const{anchor:e=rt,cols:t=1,rows:o=1,gapX:i=0,gapY:a=0,groupProps:s={},width:r=0,height:l=0,x:c=0,y:u=0,objects:g=()=>null}=n,h=[],f=[];let v=0,x=0;for(let L=0;L<o;L++){const P=[];v=0;let S=0;for(let E=0;E<t;E++){const M=g(L,E),k=typeof r=="function"?r(L,E):r,B=typeof l=="function"?l(L,E):l;P.push(M),M!=null&&f.push(Gt([M],{x:v,y:x})),v+=k+i,S=Math.max(S,B)}h.push(P),x+=S+a}return{grid:Gt(f,{x:c,y:u,height:x-a,width:v-i,anchor:e,...s}),objects:h}}function $0(n=null){return et({objectType:V.IMAGE,anchor:rt,cornerRadius:0,height:100,imageId:"",smooth:!0,width:100,x:0,y:0,...n})}function W0(n=null){return et({objectType:V.LINE,color:tt,drawn:1,endX:100,endY:100,isDrawnFromCenter:!1,isRounded:!1,startX:0,startY:0,width:10,...n})}function G0(n,e=null){return et({objectType:V.MASK,anchor:rt,height:100,objects:n,preview:!1,width:100,x:0,y:0,...e})}var Y0=Object.defineProperty,_=(n,e)=>Y0(n,"name",{value:e,configurable:!0}),Et={a:7,c:6,h:1,l:2,m:2,q:4,s:4,t:2,v:1,z:0},X0=/([astvzqmhlc])([^astvzqmhlc]*)/gi,K0=/-?[0-9]*\.?[0-9]+(?:e[-+]?\d+)?/gi,Z0=_(n=>{const e=(n&&n.length>0?n:"M0,0").match(X0);if(!e)throw new Error(`No path elements found in string ${n}`);return e.reduce((t,o)=>{let i=o.charAt(0),a=i.toLowerCase(),s=J0(o.substring(1));if(a==="m"&&s.length>2&&(t.push([i,...s.splice(0,2)]),a="l",i=i==="m"?"l":"L"),a.toLowerCase()==="a"&&(s.length===5||s.length===6)){const r=o.substring(1).trim().split(" ");s=[Number(r[0]),Number(r[1]),Number(r[2]),Number(r[3].charAt(0)),Number(r[3].charAt(1)),Number(r[3].substring(2)),Number(r[4])]}for(;s.length>=0;){if(s.length===Et[a]){t.push([i,...s.splice(0,Et[a])]);break}if(s.length<Et[a])throw new Error(`Malformed path data: "${i}" must have ${Et[a]} elements and has ${s.length}: ${o}`);t.push([i,...s.splice(0,Et[a])])}return t},[])},"default"),J0=_(n=>{const e=n.match(K0);return e?e.map(Number):[]},"parseValues"),ot=(Tt=class{constructor(e,t,o,i){O(this,"x0");O(this,"x1");O(this,"y0");O(this,"y1");O(this,"getTotalLength",_(()=>Math.sqrt(Math.pow(this.x0-this.x1,2)+Math.pow(this.y0-this.y1,2)),"getTotalLength"));O(this,"getPointAtLength",_(e=>{let t=e/Math.sqrt(Math.pow(this.x0-this.x1,2)+Math.pow(this.y0-this.y1,2));t=Number.isNaN(t)?1:t;const o=(this.x1-this.x0)*t,i=(this.y1-this.y0)*t;return{x:this.x0+o,y:this.y0+i}},"getPointAtLength"));O(this,"getTangentAtLength",_(e=>{const t=Math.sqrt((this.x1-this.x0)*(this.x1-this.x0)+(this.y1-this.y0)*(this.y1-this.y0));return{x:(this.x1-this.x0)/t,y:(this.y1-this.y0)/t}},"getTangentAtLength"));O(this,"getPropertiesAtLength",_(e=>{const t=this.getPointAtLength(e),o=this.getTangentAtLength(e);return{x:t.x,y:t.y,tangentX:o.x,tangentY:o.y}},"getPropertiesAtLength"));this.x0=e,this.x1=t,this.y0=o,this.y1=i}},_(Tt,"LinearPosition"),Tt),Te=(Mt=class{constructor(e,t,o,i,a,s,r,l,c){O(this,"x0");O(this,"y0");O(this,"rx");O(this,"ry");O(this,"xAxisRotate");O(this,"LargeArcFlag");O(this,"SweepFlag");O(this,"x1");O(this,"y1");O(this,"length");O(this,"getTotalLength",_(()=>this.length,"getTotalLength"));O(this,"getPointAtLength",_(e=>{e<0?e=0:e>this.length&&(e=this.length);const t=Me({x:this.x0,y:this.y0},this.rx,this.ry,this.xAxisRotate,this.LargeArcFlag,this.SweepFlag,{x:this.x1,y:this.y1},e/this.length);return{x:t.x,y:t.y}},"getPointAtLength"));O(this,"getTangentAtLength",_(e=>{e<0?e=0:e>this.length&&(e=this.length);const t=.05,o=this.getPointAtLength(e);let i;e<0?e=0:e>this.length&&(e=this.length),i=e<this.length-t?this.getPointAtLength(e+t):this.getPointAtLength(e-t);const a=i.x-o.x,s=i.y-o.y,r=Math.sqrt(a*a+s*s);return e<this.length-t?{x:-a/r,y:-s/r}:{x:a/r,y:s/r}},"getTangentAtLength"));O(this,"getPropertiesAtLength",_(e=>{const t=this.getTangentAtLength(e),o=this.getPointAtLength(e);return{x:o.x,y:o.y,tangentX:t.x,tangentY:t.y}},"getPropertiesAtLength"));this.x0=e,this.y0=t,this.rx=o,this.ry=i,this.xAxisRotate=a,this.LargeArcFlag=s,this.SweepFlag=r,this.x1=l,this.y1=c;const u=Q0(300,function(g){return Me({x:e,y:t},o,i,a,s,r,{x:l,y:c},g)});this.length=u.arcLength}},_(Mt,"Arc"),Mt),Me=_((n,e,t,o,i,a,s,r)=>{e=Math.abs(e),t=Math.abs(t),o=tn(o,360);const l=en(o);if(n.x===s.x&&n.y===s.y)return{x:n.x,y:n.y,ellipticalArcAngle:0};if(e===0||t===0)return{x:0,y:0,ellipticalArcAngle:0};const c=(n.x-s.x)/2,u=(n.y-s.y)/2,g={x:Math.cos(l)*c+Math.sin(l)*u,y:-Math.sin(l)*c+Math.cos(l)*u},h=Math.pow(g.x,2)/Math.pow(e,2)+Math.pow(g.y,2)/Math.pow(t,2);h>1&&(e=Math.sqrt(h)*e,t=Math.sqrt(h)*t);let f=(Math.pow(e,2)*Math.pow(t,2)-Math.pow(e,2)*Math.pow(g.y,2)-Math.pow(t,2)*Math.pow(g.x,2))/(Math.pow(e,2)*Math.pow(g.y,2)+Math.pow(t,2)*Math.pow(g.x,2));f=f<0?0:f;const v=(i!==a?1:-1)*Math.sqrt(f),x=v*(e*g.y/t),T=v*(-t*g.x/e),L={x:Math.cos(l)*x-Math.sin(l)*T+(n.x+s.x)/2,y:Math.sin(l)*x+Math.cos(l)*T+(n.y+s.y)/2},P={x:(g.x-x)/e,y:(g.y-T)/t},S=Ce({x:1,y:0},P);let E=Ce(P,{x:(-g.x-x)/e,y:(-g.y-T)/t});!a&&E>0?E-=2*Math.PI:a&&E<0&&(E+=2*Math.PI),E%=2*Math.PI;const M=S+E*r,k=e*Math.cos(M),B=t*Math.sin(M);return{x:Math.cos(l)*k-Math.sin(l)*B+L.x,y:Math.sin(l)*k+Math.cos(l)*B+L.y,ellipticalArcStartAngle:S,ellipticalArcEndAngle:S+E,ellipticalArcAngle:M,ellipticalArcCenter:L,resultantRx:e,resultantRy:t}},"pointOnEllipticalArc"),Q0=_((n,e)=>{n=n??500;let t=0;const o=[],i=[];let a,s=e(0);for(let r=0;r<n;r++){const l=nn(r*(1/n),0,1);a=e(l),t+=Le(s,a),i.push([s,a]),o.push({t:l,arcLength:t}),s=a}return a=e(1),i.push([s,a]),t+=Le(s,a),o.push({t:1,arcLength:t}),{arcLength:t,arcLengthMap:o,approximationLines:i}},"approximateArcLengthOfCurve"),tn=_((n,e)=>(n%e+e)%e,"mod"),en=_(n=>n*(Math.PI/180),"toRadians"),Le=_((n,e)=>Math.sqrt(Math.pow(e.x-n.x,2)+Math.pow(e.y-n.y,2)),"distance"),nn=_((n,e,t)=>Math.min(Math.max(n,e),t),"clamp"),Ce=_((n,e)=>{const t=n.x*e.x+n.y*e.y,o=Math.sqrt((Math.pow(n.x,2)+Math.pow(n.y,2))*(Math.pow(e.x,2)+Math.pow(e.y,2)));return(n.x*e.y-n.y*e.x<0?-1:1)*Math.acos(t/o)},"angleBetween"),rn=[[],[],[-.5773502691896257,.5773502691896258],[0,-.7745966692414833,.7745966692414833],[-.33998104358485626,.33998104358485626,-.8611363115940526,.8611363115940526],[0,-.5384693101056831,.5384693101056831,-.906179845938664,.906179845938664],[.6612093864662645,-.6612093864662645,-.2386191860831969,.2386191860831969,-.932469514203152,.932469514203152],[0,.4058451513773972,-.4058451513773972,-.7415311855993945,.7415311855993945,-.9491079123427585,.9491079123427585],[-.1834346424956498,.1834346424956498,-.525532409916329,.525532409916329,-.7966664774136267,.7966664774136267,-.9602898564975363,.9602898564975363],[0,-.8360311073266358,.8360311073266358,-.9681602395076261,.9681602395076261,-.3242534234038089,.3242534234038089,-.6133714327005904,.6133714327005904],[-.14887433898163122,.14887433898163122,-.4333953941292472,.4333953941292472,-.6794095682990244,.6794095682990244,-.8650633666889845,.8650633666889845,-.9739065285171717,.9739065285171717],[0,-.26954315595234496,.26954315595234496,-.5190961292068118,.5190961292068118,-.7301520055740494,.7301520055740494,-.8870625997680953,.8870625997680953,-.978228658146057,.978228658146057],[-.1252334085114689,.1252334085114689,-.3678314989981802,.3678314989981802,-.5873179542866175,.5873179542866175,-.7699026741943047,.7699026741943047,-.9041172563704749,.9041172563704749,-.9815606342467192,.9815606342467192],[0,-.2304583159551348,.2304583159551348,-.44849275103644687,.44849275103644687,-.6423493394403402,.6423493394403402,-.8015780907333099,.8015780907333099,-.9175983992229779,.9175983992229779,-.9841830547185881,.9841830547185881],[-.10805494870734367,.10805494870734367,-.31911236892788974,.31911236892788974,-.5152486363581541,.5152486363581541,-.6872929048116855,.6872929048116855,-.827201315069765,.827201315069765,-.9284348836635735,.9284348836635735,-.9862838086968123,.9862838086968123],[0,-.20119409399743451,.20119409399743451,-.3941513470775634,.3941513470775634,-.5709721726085388,.5709721726085388,-.7244177313601701,.7244177313601701,-.8482065834104272,.8482065834104272,-.937273392400706,.937273392400706,-.9879925180204854,.9879925180204854],[-.09501250983763744,.09501250983763744,-.2816035507792589,.2816035507792589,-.45801677765722737,.45801677765722737,-.6178762444026438,.6178762444026438,-.755404408355003,.755404408355003,-.8656312023878318,.8656312023878318,-.9445750230732326,.9445750230732326,-.9894009349916499,.9894009349916499],[0,-.17848418149584785,.17848418149584785,-.3512317634538763,.3512317634538763,-.5126905370864769,.5126905370864769,-.6576711592166907,.6576711592166907,-.7815140038968014,.7815140038968014,-.8802391537269859,.8802391537269859,-.9506755217687678,.9506755217687678,-.9905754753144174,.9905754753144174],[-.0847750130417353,.0847750130417353,-.2518862256915055,.2518862256915055,-.41175116146284263,.41175116146284263,-.5597708310739475,.5597708310739475,-.6916870430603532,.6916870430603532,-.8037049589725231,.8037049589725231,-.8926024664975557,.8926024664975557,-.9558239495713977,.9558239495713977,-.9915651684209309,.9915651684209309],[0,-.16035864564022537,.16035864564022537,-.31656409996362983,.31656409996362983,-.46457074137596094,.46457074137596094,-.600545304661681,.600545304661681,-.7209661773352294,.7209661773352294,-.8227146565371428,.8227146565371428,-.9031559036148179,.9031559036148179,-.96020815213483,.96020815213483,-.9924068438435844,.9924068438435844],[-.07652652113349734,.07652652113349734,-.22778585114164507,.22778585114164507,-.37370608871541955,.37370608871541955,-.5108670019508271,.5108670019508271,-.636053680726515,.636053680726515,-.7463319064601508,.7463319064601508,-.8391169718222188,.8391169718222188,-.912234428251326,.912234428251326,-.9639719272779138,.9639719272779138,-.9931285991850949,.9931285991850949],[0,-.1455618541608951,.1455618541608951,-.2880213168024011,.2880213168024011,-.4243421202074388,.4243421202074388,-.5516188358872198,.5516188358872198,-.6671388041974123,.6671388041974123,-.7684399634756779,.7684399634756779,-.8533633645833173,.8533633645833173,-.9200993341504008,.9200993341504008,-.9672268385663063,.9672268385663063,-.9937521706203895,.9937521706203895],[-.06973927331972223,.06973927331972223,-.20786042668822127,.20786042668822127,-.34193582089208424,.34193582089208424,-.469355837986757,.469355837986757,-.5876404035069116,.5876404035069116,-.6944872631866827,.6944872631866827,-.7878168059792081,.7878168059792081,-.8658125777203002,.8658125777203002,-.926956772187174,.926956772187174,-.9700604978354287,.9700604978354287,-.9942945854823992,.9942945854823992],[0,-.1332568242984661,.1332568242984661,-.26413568097034495,.26413568097034495,-.3903010380302908,.3903010380302908,-.5095014778460075,.5095014778460075,-.6196098757636461,.6196098757636461,-.7186613631319502,.7186613631319502,-.8048884016188399,.8048884016188399,-.8767523582704416,.8767523582704416,-.9329710868260161,.9329710868260161,-.9725424712181152,.9725424712181152,-.9947693349975522,.9947693349975522],[-.06405689286260563,.06405689286260563,-.1911188674736163,.1911188674736163,-.3150426796961634,.3150426796961634,-.4337935076260451,.4337935076260451,-.5454214713888396,.5454214713888396,-.6480936519369755,.6480936519369755,-.7401241915785544,.7401241915785544,-.820001985973903,.820001985973903,-.8864155270044011,.8864155270044011,-.9382745520027328,.9382745520027328,-.9747285559713095,.9747285559713095,-.9951872199970213,.9951872199970213]],on=[[],[],[1,1],[.8888888888888888,.5555555555555556,.5555555555555556],[.6521451548625461,.6521451548625461,.34785484513745385,.34785484513745385],[.5688888888888889,.47862867049936647,.47862867049936647,.23692688505618908,.23692688505618908],[.3607615730481386,.3607615730481386,.46791393457269104,.46791393457269104,.17132449237917036,.17132449237917036],[.4179591836734694,.3818300505051189,.3818300505051189,.27970539148927664,.27970539148927664,.1294849661688697,.1294849661688697],[.362683783378362,.362683783378362,.31370664587788727,.31370664587788727,.22238103445337448,.22238103445337448,.10122853629037626,.10122853629037626],[.3302393550012598,.1806481606948574,.1806481606948574,.08127438836157441,.08127438836157441,.31234707704000286,.31234707704000286,.26061069640293544,.26061069640293544],[.29552422471475287,.29552422471475287,.26926671930999635,.26926671930999635,.21908636251598204,.21908636251598204,.1494513491505806,.1494513491505806,.06667134430868814,.06667134430868814],[.2729250867779006,.26280454451024665,.26280454451024665,.23319376459199048,.23319376459199048,.18629021092773426,.18629021092773426,.1255803694649046,.1255803694649046,.05566856711617366,.05566856711617366],[.24914704581340277,.24914704581340277,.2334925365383548,.2334925365383548,.20316742672306592,.20316742672306592,.16007832854334622,.16007832854334622,.10693932599531843,.10693932599531843,.04717533638651183,.04717533638651183],[.2325515532308739,.22628318026289723,.22628318026289723,.2078160475368885,.2078160475368885,.17814598076194574,.17814598076194574,.13887351021978725,.13887351021978725,.09212149983772845,.09212149983772845,.04048400476531588,.04048400476531588],[.2152638534631578,.2152638534631578,.2051984637212956,.2051984637212956,.18553839747793782,.18553839747793782,.15720316715819355,.15720316715819355,.12151857068790319,.12151857068790319,.08015808715976021,.08015808715976021,.03511946033175186,.03511946033175186],[.2025782419255613,.19843148532711158,.19843148532711158,.1861610000155622,.1861610000155622,.16626920581699392,.16626920581699392,.13957067792615432,.13957067792615432,.10715922046717194,.10715922046717194,.07036604748810812,.07036604748810812,.03075324199611727,.03075324199611727],[.1894506104550685,.1894506104550685,.18260341504492358,.18260341504492358,.16915651939500254,.16915651939500254,.14959598881657674,.14959598881657674,.12462897125553388,.12462897125553388,.09515851168249279,.09515851168249279,.062253523938647894,.062253523938647894,.027152459411754096,.027152459411754096],[.17944647035620653,.17656270536699264,.17656270536699264,.16800410215645004,.16800410215645004,.15404576107681028,.15404576107681028,.13513636846852548,.13513636846852548,.11188384719340397,.11188384719340397,.08503614831717918,.08503614831717918,.0554595293739872,.0554595293739872,.02414830286854793,.02414830286854793],[.1691423829631436,.1691423829631436,.16427648374583273,.16427648374583273,.15468467512626524,.15468467512626524,.14064291467065065,.14064291467065065,.12255520671147846,.12255520671147846,.10094204410628717,.10094204410628717,.07642573025488905,.07642573025488905,.0497145488949698,.0497145488949698,.02161601352648331,.02161601352648331],[.1610544498487837,.15896884339395434,.15896884339395434,.15276604206585967,.15276604206585967,.1426067021736066,.1426067021736066,.12875396253933621,.12875396253933621,.11156664554733399,.11156664554733399,.09149002162245,.09149002162245,.06904454273764123,.06904454273764123,.0448142267656996,.0448142267656996,.019461788229726478,.019461788229726478],[.15275338713072584,.15275338713072584,.14917298647260374,.14917298647260374,.14209610931838204,.14209610931838204,.13168863844917664,.13168863844917664,.11819453196151841,.11819453196151841,.10193011981724044,.10193011981724044,.08327674157670475,.08327674157670475,.06267204833410907,.06267204833410907,.04060142980038694,.04060142980038694,.017614007139152118,.017614007139152118],[.14608113364969041,.14452440398997005,.14452440398997005,.13988739479107315,.13988739479107315,.13226893863333747,.13226893863333747,.12183141605372853,.12183141605372853,.10879729916714838,.10879729916714838,.09344442345603386,.09344442345603386,.0761001136283793,.0761001136283793,.057134425426857205,.057134425426857205,.036953789770852494,.036953789770852494,.016017228257774335,.016017228257774335],[.13925187285563198,.13925187285563198,.13654149834601517,.13654149834601517,.13117350478706238,.13117350478706238,.12325237681051242,.12325237681051242,.11293229608053922,.11293229608053922,.10041414444288096,.10041414444288096,.08594160621706773,.08594160621706773,.06979646842452049,.06979646842452049,.052293335152683286,.052293335152683286,.03377490158481415,.03377490158481415,.0146279952982722,.0146279952982722],[.13365457218610619,.1324620394046966,.1324620394046966,.12890572218808216,.12890572218808216,.12304908430672953,.12304908430672953,.11499664022241136,.11499664022241136,.10489209146454141,.10489209146454141,.09291576606003515,.09291576606003515,.07928141177671895,.07928141177671895,.06423242140852585,.06423242140852585,.04803767173108467,.04803767173108467,.030988005856979445,.030988005856979445,.013411859487141771,.013411859487141771],[.12793819534675216,.12793819534675216,.1258374563468283,.1258374563468283,.12167047292780339,.12167047292780339,.1155056680537256,.1155056680537256,.10744427011596563,.10744427011596563,.09761865210411388,.09761865210411388,.08619016153195327,.08619016153195327,.0733464814110803,.0733464814110803,.05929858491543678,.05929858491543678,.04427743881741981,.04427743881741981,.028531388628933663,.028531388628933663,.0123412297999872,.0123412297999872]],sn=[[1],[1,1],[1,2,1],[1,3,3,1]],an=_((n,e,t)=>({x:(1-t)*(1-t)*(1-t)*n[0]+3*(1-t)*(1-t)*t*n[1]+3*(1-t)*t*t*n[2]+t*t*t*n[3],y:(1-t)*(1-t)*(1-t)*e[0]+3*(1-t)*(1-t)*t*e[1]+3*(1-t)*t*t*e[2]+t*t*t*e[3]}),"cubicPoint"),ln=_((n,e,t)=>Se([3*(n[1]-n[0]),3*(n[2]-n[1]),3*(n[3]-n[2])],[3*(e[1]-e[0]),3*(e[2]-e[1]),3*(e[3]-e[2])],t),"cubicDerivative"),hn=_((n,e,t)=>{let o,i;const a=t/2;o=0;for(let s=0;s<20;s++)i=a*rn[20][s]+a,o+=on[20][s]*Pe(n,e,i);return a*o},"getCubicArcLength"),Se=_((n,e,t)=>({x:(1-t)*(1-t)*n[0]+2*(1-t)*t*n[1]+t*t*n[2],y:(1-t)*(1-t)*e[0]+2*(1-t)*t*e[1]+t*t*e[2]}),"quadraticPoint"),cn=_((n,e,t)=>{t===void 0&&(t=1);const o=n[0]-2*n[1]+n[2],i=e[0]-2*e[1]+e[2],a=2*n[1]-2*n[0],s=2*e[1]-2*e[0],r=4*(o*o+i*i),l=4*(o*a+i*s),c=a*a+s*s;if(r===0)return t*Math.sqrt(Math.pow(n[2]-n[0],2)+Math.pow(e[2]-e[0],2));const u=l/(2*r),g=t+u,h=c/r-u*u,f=g*g+h>0?Math.sqrt(g*g+h):0,v=u*u+h>0?Math.sqrt(u*u+h):0,x=u+Math.sqrt(u*u+h)!==0&&(g+f)/(u+v)!==0?h*Math.log(Math.abs((g+f)/(u+v))):0;return Math.sqrt(r)/2*(g*f-u*v+x)},"getQuadraticArcLength"),un=_((n,e,t)=>({x:2*(1-t)*(n[1]-n[0])+2*t*(n[2]-n[1]),y:2*(1-t)*(e[1]-e[0])+2*t*(e[2]-e[1])}),"quadraticDerivative");function Pe(n,e,t){const o=Yt(1,t,n),i=Yt(1,t,e),a=o*o+i*i;return Math.sqrt(a)}_(Pe,"BFunc");var Yt=_((n,e,t)=>{const o=t.length-1;let i,a;if(o===0)return 0;if(n===0){a=0;for(let s=0;s<=o;s++)a+=sn[o][s]*Math.pow(1-e,o-s)*Math.pow(e,s)*t[s];return a}i=new Array(o);for(let s=0;s<o;s++)i[s]=o*(t[s+1]-t[s]);return Yt(n-1,e,i)},"getDerivative"),Xt=_((n,e,t)=>{let o=1,i=n/e,a=(n-t(i))/e,s=0;for(;o>.001;){const r=t(i+a),l=Math.abs(n-r)/e;if(l<o)o=l,i+=a;else{const c=t(i-a),u=Math.abs(n-c)/e;u<o?(o=u,i-=a):a/=2}if(s++,s>500)break}return i},"t2length"),ft=(Lt=class{constructor(e,t,o,i,a,s,r,l){O(this,"a");O(this,"b");O(this,"c");O(this,"d");O(this,"length");O(this,"getArcLength");O(this,"getPoint");O(this,"getDerivative");O(this,"getTotalLength",_(()=>this.length,"getTotalLength"));O(this,"getPointAtLength",_(e=>{const t=[this.a.x,this.b.x,this.c.x,this.d.x],o=[this.a.y,this.b.y,this.c.y,this.d.y],i=Xt(e,this.length,a=>this.getArcLength(t,o,a));return this.getPoint(t,o,i)},"getPointAtLength"));O(this,"getTangentAtLength",_(e=>{const t=[this.a.x,this.b.x,this.c.x,this.d.x],o=[this.a.y,this.b.y,this.c.y,this.d.y],i=Xt(e,this.length,l=>this.getArcLength(t,o,l)),a=this.getDerivative(t,o,i),s=Math.sqrt(a.x*a.x+a.y*a.y);let r;return r=s>0?{x:a.x/s,y:a.y/s}:{x:0,y:0},r},"getTangentAtLength"));O(this,"getPropertiesAtLength",_(e=>{const t=[this.a.x,this.b.x,this.c.x,this.d.x],o=[this.a.y,this.b.y,this.c.y,this.d.y],i=Xt(e,this.length,c=>this.getArcLength(t,o,c)),a=this.getDerivative(t,o,i),s=Math.sqrt(a.x*a.x+a.y*a.y);let r;r=s>0?{x:a.x/s,y:a.y/s}:{x:0,y:0};const l=this.getPoint(t,o,i);return{x:l.x,y:l.y,tangentX:r.x,tangentY:r.y}},"getPropertiesAtLength"));O(this,"getC",_(()=>this.c,"getC"));O(this,"getD",_(()=>this.d,"getD"));this.a={x:e,y:t},this.b={x:o,y:i},this.c={x:a,y:s},r!==void 0&&l!==void 0?(this.getArcLength=hn,this.getPoint=an,this.getDerivative=ln,this.d={x:r,y:l}):(this.getArcLength=cn,this.getPoint=Se,this.getDerivative=un,this.d={x:0,y:0}),this.length=this.getArcLength([this.a.x,this.b.x,this.c.x,this.d.x],[this.a.y,this.b.y,this.c.y,this.d.y],1)}},_(Lt,"Bezier"),Lt),fn=(Ct=class{constructor(e){O(this,"length",0);O(this,"partial_lengths",[]);O(this,"functions",[]);O(this,"initial_point",null);O(this,"getPartAtLength",_(e=>{e<0?e=0:e>this.length&&(e=this.length);let t=this.partial_lengths.length-1;for(;this.partial_lengths[t]>=e&&t>0;)t--;return t++,{fraction:e-this.partial_lengths[t-1],i:t}},"getPartAtLength"));O(this,"getTotalLength",_(()=>this.length,"getTotalLength"));O(this,"getPointAtLength",_(e=>{const t=this.getPartAtLength(e),o=this.functions[t.i];if(o)return o.getPointAtLength(t.fraction);if(this.initial_point)return this.initial_point;throw new Error("Wrong function at this part.")},"getPointAtLength"));O(this,"getTangentAtLength",_(e=>{const t=this.getPartAtLength(e),o=this.functions[t.i];if(o)return o.getTangentAtLength(t.fraction);if(this.initial_point)return{x:0,y:0};throw new Error("Wrong function at this part.")},"getTangentAtLength"));O(this,"getPropertiesAtLength",_(e=>{const t=this.getPartAtLength(e),o=this.functions[t.i];if(o)return o.getPropertiesAtLength(t.fraction);if(this.initial_point)return{x:this.initial_point.x,y:this.initial_point.y,tangentX:0,tangentY:0};throw new Error("Wrong function at this part.")},"getPropertiesAtLength"));O(this,"getParts",_(()=>{const e=[];for(let t=0;t<this.functions.length;t++)if(this.functions[t]!==null){this.functions[t]=this.functions[t];const o={start:this.functions[t].getPointAtLength(0),end:this.functions[t].getPointAtLength(this.partial_lengths[t]-this.partial_lengths[t-1]),length:this.partial_lengths[t]-this.partial_lengths[t-1],getPointAtLength:this.functions[t].getPointAtLength,getTangentAtLength:this.functions[t].getTangentAtLength,getPropertiesAtLength:this.functions[t].getPropertiesAtLength};e.push(o)}return e},"getParts"));const t=Array.isArray(e)?e:Z0(e);let o,i=[0,0],a=[0,0],s=[0,0];for(let r=0;r<t.length;r++){if(t[r][0]==="M")i=[t[r][1],t[r][2]],s=[i[0],i[1]],this.functions.push(null),r===0&&(this.initial_point={x:t[r][1],y:t[r][2]});else if(t[r][0]==="m")i=[t[r][1]+i[0],t[r][2]+i[1]],s=[i[0],i[1]],this.functions.push(null);else if(t[r][0]==="L")this.length+=Math.sqrt(Math.pow(i[0]-t[r][1],2)+Math.pow(i[1]-t[r][2],2)),this.functions.push(new ot(i[0],t[r][1],i[1],t[r][2])),i=[t[r][1],t[r][2]];else if(t[r][0]==="l")this.length+=Math.sqrt(Math.pow(t[r][1],2)+Math.pow(t[r][2],2)),this.functions.push(new ot(i[0],t[r][1]+i[0],i[1],t[r][2]+i[1])),i=[t[r][1]+i[0],t[r][2]+i[1]];else if(t[r][0]==="H")this.length+=Math.abs(i[0]-t[r][1]),this.functions.push(new ot(i[0],t[r][1],i[1],i[1])),i[0]=t[r][1];else if(t[r][0]==="h")this.length+=Math.abs(t[r][1]),this.functions.push(new ot(i[0],i[0]+t[r][1],i[1],i[1])),i[0]=t[r][1]+i[0];else if(t[r][0]==="V")this.length+=Math.abs(i[1]-t[r][1]),this.functions.push(new ot(i[0],i[0],i[1],t[r][1])),i[1]=t[r][1];else if(t[r][0]==="v")this.length+=Math.abs(t[r][1]),this.functions.push(new ot(i[0],i[0],i[1],i[1]+t[r][1])),i[1]=t[r][1]+i[1];else if(t[r][0]==="z"||t[r][0]==="Z")this.length+=Math.sqrt(Math.pow(s[0]-i[0],2)+Math.pow(s[1]-i[1],2)),this.functions.push(new ot(i[0],s[0],i[1],s[1])),i=[s[0],s[1]];else if(t[r][0]==="C")o=new ft(i[0],i[1],t[r][1],t[r][2],t[r][3],t[r][4],t[r][5],t[r][6]),this.length+=o.getTotalLength(),i=[t[r][5],t[r][6]],this.functions.push(o);else if(t[r][0]==="c")o=new ft(i[0],i[1],i[0]+t[r][1],i[1]+t[r][2],i[0]+t[r][3],i[1]+t[r][4],i[0]+t[r][5],i[1]+t[r][6]),o.getTotalLength()>0?(this.length+=o.getTotalLength(),this.functions.push(o),i=[t[r][5]+i[0],t[r][6]+i[1]]):this.functions.push(new ot(i[0],i[0],i[1],i[1]));else if(t[r][0]==="S"){if(r>0&&["C","c","S","s"].indexOf(t[r-1][0])>-1){if(o){const l=o.getC();o=new ft(i[0],i[1],2*i[0]-l.x,2*i[1]-l.y,t[r][1],t[r][2],t[r][3],t[r][4])}}else o=new ft(i[0],i[1],i[0],i[1],t[r][1],t[r][2],t[r][3],t[r][4]);o&&(this.length+=o.getTotalLength(),i=[t[r][3],t[r][4]],this.functions.push(o))}else if(t[r][0]==="s"){if(r>0&&["C","c","S","s"].indexOf(t[r-1][0])>-1){if(o){const l=o.getC(),c=o.getD();o=new ft(i[0],i[1],i[0]+c.x-l.x,i[1]+c.y-l.y,i[0]+t[r][1],i[1]+t[r][2],i[0]+t[r][3],i[1]+t[r][4])}}else o=new ft(i[0],i[1],i[0],i[1],i[0]+t[r][1],i[1]+t[r][2],i[0]+t[r][3],i[1]+t[r][4]);o&&(this.length+=o.getTotalLength(),i=[t[r][3]+i[0],t[r][4]+i[1]],this.functions.push(o))}else if(t[r][0]==="Q"){if(i[0]===t[r][1]&&i[1]===t[r][2]){const l=new ot(t[r][1],t[r][3],t[r][2],t[r][4]);this.length+=l.getTotalLength(),this.functions.push(l)}else o=new ft(i[0],i[1],t[r][1],t[r][2],t[r][3],t[r][4],void 0,void 0),this.length+=o.getTotalLength(),this.functions.push(o);i=[t[r][3],t[r][4]],a=[t[r][1],t[r][2]]}else if(t[r][0]==="q"){if(t[r][1]!==0||t[r][2]!==0)o=new ft(i[0],i[1],i[0]+t[r][1],i[1]+t[r][2],i[0]+t[r][3],i[1]+t[r][4],void 0,void 0),this.length+=o.getTotalLength(),this.functions.push(o);else{const l=new ot(i[0]+t[r][1],i[0]+t[r][3],i[1]+t[r][2],i[1]+t[r][4]);this.length+=l.getTotalLength(),this.functions.push(l)}a=[i[0]+t[r][1],i[1]+t[r][2]],i=[t[r][3]+i[0],t[r][4]+i[1]]}else if(t[r][0]==="T"){if(r>0&&["Q","q","T","t"].indexOf(t[r-1][0])>-1)o=new ft(i[0],i[1],2*i[0]-a[0],2*i[1]-a[1],t[r][1],t[r][2],void 0,void 0),this.functions.push(o),this.length+=o.getTotalLength();else{const l=new ot(i[0],t[r][1],i[1],t[r][2]);this.functions.push(l),this.length+=l.getTotalLength()}a=[2*i[0]-a[0],2*i[1]-a[1]],i=[t[r][1],t[r][2]]}else if(t[r][0]==="t"){if(r>0&&["Q","q","T","t"].indexOf(t[r-1][0])>-1)o=new ft(i[0],i[1],2*i[0]-a[0],2*i[1]-a[1],i[0]+t[r][1],i[1]+t[r][2],void 0,void 0),this.length+=o.getTotalLength(),this.functions.push(o);else{const l=new ot(i[0],i[0]+t[r][1],i[1],i[1]+t[r][2]);this.length+=l.getTotalLength(),this.functions.push(l)}a=[2*i[0]-a[0],2*i[1]-a[1]],i=[t[r][1]+i[0],t[r][2]+i[1]]}else if(t[r][0]==="A"){const l=new Te(i[0],i[1],t[r][1],t[r][2],t[r][3],t[r][4]===1,t[r][5]===1,t[r][6],t[r][7]);this.length+=l.getTotalLength(),i=[t[r][6],t[r][7]],this.functions.push(l)}else if(t[r][0]==="a"){const l=new Te(i[0],i[1],t[r][1],t[r][2],t[r][3],t[r][4]===1,t[r][5]===1,i[0]+t[r][6],i[1]+t[r][7]);this.length+=l.getTotalLength(),i=[i[0]+t[r][6],i[1]+t[r][7]],this.functions.push(l)}this.partial_lengths.push(this.length)}}},_(Ct,"SVGPathProperties"),Ct),Kt=(St=class{constructor(e){O(this,"inst");O(this,"getTotalLength",_(()=>this.inst.getTotalLength(),"getTotalLength"));O(this,"getPointAtLength",_(e=>this.inst.getPointAtLength(e),"getPointAtLength"));O(this,"getTangentAtLength",_(e=>this.inst.getTangentAtLength(e),"getTangentAtLength"));O(this,"getPropertiesAtLength",_(e=>this.inst.getPropertiesAtLength(e),"getPropertiesAtLength"));O(this,"getParts",_(()=>this.inst.getParts(),"getParts"));if(this.inst=new fn(e),!(this instanceof Kt))return new Kt(e)}},_(St,"_svgPathProperties"),St);function Ee(n=K.BLACK){return{...n,alpha:0}}function dn(n=null){const{path:e,height:t=100,width:o=100,viewboxHeight:i,viewboxWidth:a,...s}=n??{},r=e??"M 0 0 L 100 100",c=new Kt(r).getTotalLength();return et({objectType:V.PATH,anchor:rt,strokeColor:tt,drawn:1,fillColor:Ee(),isRounded:!1,height:t,path:r,pathLength:c,strokeWidth:4,viewboxHeight:i??t,viewboxWidth:a??o,width:o,x:0,y:0,...s})}function gn(n=null){return et({objectType:V.POLYGON,strokeColor:tt,strokeWidth:0,drawn:1,points:[{x:0,y:0},{x:100,y:0},{x:100,y:100}],fillColor:tt,...n})}function pn(n=null){return et({objectType:V.RECTANGLE,anchor:rt,strokeColor:tt,strokeWidth:0,drawn:1,fillColor:tt,height:100,cornerRadius:0,width:100,x:0,y:0,...n})}function yn(n=null){return et({objectType:V.SPOTLIGHT,anchor:rt,color:K(0,0,0,.8),height:200,cornerRadius:50,width:200,x:0,y:0,...n})}function xn(n=null){return et({objectType:V.SVG,anchor:rt,height:100,svg:"",width:100,x:0,y:0,...n})}const Ie={NORMAL:"normal",ITALIC:"italic",OBLIQUE:"oblique"},vn=Ie.NORMAL,ke={THIN:100,EXTRA_LIGHT:200,LIGHT:300,NORMAL:400,MEDIUM:500,SEMI_BOLD:600,BOLD:700,EXTRA_BOLD:800,BLACK:900},wn=ke.NORMAL,mn={color:tt,fontFamily:"sans-serif",fontSize:100,fontStyle:vn,fontWeight:wn,ligatures:!1,subscript:!1,superscript:!1};function Oe(n){return typeof n=="string"?[[{text:n}]]:n.map(e=>e.map(t=>typeof t=="string"?{text:t}:t))}function _e(n){return Oe(n).reduce((t,o)=>t+o.reduce((i,a)=>i+a.text.length,0),0)}function Ne(n="",e=null){return et({objectType:V.TEXT,alignment:q0,anchor:rt,length:null,lineSpacing:1,text:n,x:0,y:0,...mn,...e})}Ne.writeOn=(n,e={})=>Bt(n,{length:_e(n.text)},e);const Zt="presenter.navigator.state",bt={open:!1,visibility:{slides:!0,current:!0,next:!0}};function Jt(){return typeof document>"u"?!1:Array.from(document.scripts).some(n=>n.src.includes("/@vite/client"))}function bn(){return Jt()?Qt().open:!1}function An(){Re({...Qt(),open:!0})}function Fe(){var n;(n=te())==null||n.removeItem(Zt)}function Qt(){var n,e,t,o;if(!Jt())return bt;try{const i=(n=te())==null?void 0:n.getItem(Zt);if(i==null)return bt;const a=JSON.parse(i);return{open:typeof a.open=="boolean"?a.open:bt.open,visibility:{slides:typeof((e=a.visibility)==null?void 0:e.slides)=="boolean"?a.visibility.slides:bt.visibility.slides,current:typeof((t=a.visibility)==null?void 0:t.current)=="boolean"?a.visibility.current:bt.visibility.current,next:typeof((o=a.visibility)==null?void 0:o.next)=="boolean"?a.visibility.next:bt.visibility.next}}}catch{return bt}}function Re(n){var e;Jt()&&((e=te())==null||e.setItem(Zt,JSON.stringify(n)))}function te(){try{return window.sessionStorage}catch{return null}}function Be(n){return n.altKey||n.ctrlKey||n.metaKey||n.shiftKey}function De(n){var o,i;if(n===null)return!1;const e=n,t=(o=e.tagName)==null?void 0:o.toLowerCase();return t==="input"||t==="textarea"||t==="select"||t==="button"||e.isContentEditable?!0:(((i=e.closest)==null?void 0:i.call(e,"[contenteditable=''], [contenteditable='true']"))??null)!==null}function Tn(n){var o;const{slides:e}=n,t={s:{slideIndex:0,buildIndex:0},c:{slideIndex:null,buildIndex:0},e:{slideIndex:e.length-1,buildIndex:((o=e[e.length-1])==null?void 0:o.animations.length)??0}};for(let i=0;i<e.length;i++){const a=e[i];if(a===void 0)continue;const s=a.shortcut;ee(t,s,i,0);for(let r=0;r<a.animations.length;r++){const l=a.animations[r];if(l!==void 0)if(Array.isArray(l))for(const c of l)ee(t,c.shortcut,i,r+1);else ee(t,l.shortcut,i,r+1)}}return t}function ee(n,e,t,o){if(e!==null)if(Array.isArray(e))for(const i of e)n[i]={slideIndex:t,buildIndex:o};else n[e]={slideIndex:t,buildIndex:o}}function qe(n,e){const t=n[e];return t!==void 0?t:isNaN(Number(e))?null:{slideIndex:Number(e)-1,buildIndex:0}}function ze(n,e,t,{onNext:o,onPrevious:i,onRenderSlide:a,onShowNavigator:s},{focusOnPointerDown:r=!1,keyEventTarget:l=e,signal:c}={}){t.shortcuts=Tn(n);const u=c===void 0?void 0:{signal:c};r&&(e.hasAttribute("tabindex")||(e.tabIndex=-1),e.addEventListener("pointerdown",g=>{De(g.target)||e.focus({preventScroll:!0})},u)),e.addEventListener("mousemove",()=>{e.style.cursor="auto"},u),l.addEventListener("keyup",g=>{const h=g;if(De(h.target))return;if(h.code==="Escape"){t.textCommand=null;return}if(h.code==="ArrowRight"||h.code==="Space"){o(h.shiftKey);return}if(h.code==="ArrowLeft"){i(h.shiftKey);return}const f=Mn(h);if(f!==null){const v=qe(t.shortcuts,f);t.textCommand=null,v!==null&&(h.preventDefault(),a(v.slideIndex,v.buildIndex));return}if(t.textCommand!==null){if(h.code==="Enter"){const v=t.textCommand;t.textCommand=null;const x=qe(t.shortcuts,v);x!==null&&a(x.slideIndex,x.buildIndex);return}else h.code==="Backspace"?t.textCommand=t.textCommand.slice(0,-1):t.textCommand+=h.key;return}if(h.key==="g"){t.textCommand="";return}if(h.key==="`"&&!Be(h)){s();return}},u)}function Mn(n){return!n.altKey||n.ctrlKey||n.metaKey||n.shiftKey?null:n.code.startsWith("Key")&&n.code.length===4?n.code.slice(3).toLowerCase():n.code.startsWith("Digit")&&n.code.length===6?n.code.slice(5):n.code.startsWith("Numpad")&&n.code.length===7?n.code.slice(6):null}let R=null,Dt=null,vt=null;const Ve="__presenterNavigatorInstanceId";let je={width:700,height:680,left:20,top:50};function Ln({presentation:n,shortcutState:e,onNavigateToSlide:t,onRenderSlide:o,onNext:i,onPrevious:a,forceRefresh:s=!1}){if(R!==null&&!R.closed&&(qt(R),!s))return R.focus(),Dt;if((R===null||R.closed)&&(R=window.open("","Navigator",En())),R===null)return console.error("Failed to open navigator window."),null;vt==null||vt();const r=In(R),l=new AbortController;vt=()=>l.abort();const c=Cn(n,t,i,r.isActive);return Dt=c,An(),R.document.title=n.title,R.document.body.replaceChildren(c.element),ze(n,c.element,e,{onNext:u=>{r.isActive()&&i(u)},onPrevious:u=>{r.isActive()&&a(u)},onRenderSlide:(u,g)=>{r.isActive()&&o(u,g)},onShowNavigator:()=>{r.isActive()&&ie()}},{keyEventTarget:R,signal:l.signal}),R.addEventListener("resize",()=>qt(R),{signal:l.signal}),R.addEventListener("beforeunload",()=>{qt(R),Fe()},{signal:l.signal}),R.addEventListener("keyup",u=>{r.isActive()&&(u.key==="Escape"||u.key==="`"&&!Be(u))&&ie()},{signal:l.signal}),Dt}function Cn(n,e,t,o=()=>!0){const i=(R==null?void 0:R.document)??document,a=i.createElement("div");a.style.boxSizing="border-box",a.style.display="grid",a.style.gridTemplateColumns="260px 1fr",a.style.gap="18px",a.style.height="100vh",a.style.overflow="hidden",a.style.padding="18px",a.style.fontFamily='-apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif',a.style.backgroundColor="#f5f6f8",a.style.color="#1f2937",i.body.style.margin="0",i.body.style.overflow="hidden";const s=i.createElement("div");s.style.display="flex",s.style.flexDirection="column",s.style.gap="8px",s.style.minHeight="0",s.style.overflowY="auto",s.style.paddingRight="4px";const r=i.createElement("div");r.style.display="flex",r.style.flexDirection="column",r.style.gap="14px",r.style.minHeight="0",r.style.minWidth="0",r.style.overflow="hidden";const l=i.createElement("div");l.style.display="flex",l.style.gap="14px",l.style.alignItems="center",l.style.flexWrap="wrap",l.style.fontSize="13px",l.style.color="#4b5563";const c=i.createElement("div");c.style.display="flex",c.style.gap="14px",c.style.flex="1 1 auto",c.style.minHeight="0",c.style.minWidth="0",c.style.overflow="hidden";const u=He("Current",n),g=He("Next",n),h=Qt();g.container.style.cursor="pointer",g.container.addEventListener("click",()=>{o()&&t()});const f=n.slides.map((E,M)=>{const k=Sn(E,M);return k.style.cursor="pointer",k.addEventListener("click",B=>{o()&&(B.shiftKey&&ie(),e(M))}),s.appendChild(k),k}),v=ne("Slides",s,h.visibility.slides),x=ne("Current",u.container,h.visibility.current),T=ne("Next",g.container,h.visibility.next),L=()=>{const E=x.input.checked&&T.input.checked&&S();a.style.gridTemplateColumns=v.input.checked?"260px 1fr":"1fr",c.style.flexDirection=E?"column":"row",u.container.style.flex="1 1 0",g.container.style.flex="1 1 0",requestAnimationFrame(()=>{u.resize(),g.resize()}),Re({...h,open:!0,visibility:{slides:v.input.checked,current:x.input.checked,next:T.input.checked}})};v.input.addEventListener("change",L),x.input.addEventListener("change",L),T.input.addEventListener("change",L),R==null||R.addEventListener("resize",L),l.appendChild(v.element),l.appendChild(x.element),l.appendChild(T.element),c.appendChild(u.container),c.appendChild(g.container),r.appendChild(l),r.appendChild(c),a.appendChild(s),a.appendChild(r);function P(E,M,k,B){o()&&(f.forEach((X,j)=>{const W=j===E;X.style.backgroundColor=W?"#dbeafe":"#ffffff",X.style.borderColor=W?"#60a5fa":"#e5e7eb",X.style.color=W?"#1e3a8a":"#1f2937"}),u.label.textContent=Ue(n,E,M),g.label.textContent=Ue(n,k,B),Pn(f[E],s),L())}function S(){const E=R;if(E===null)return!1;const M=v.input.checked?278:0,k=E.innerWidth-36-M,B=E.innerHeight-36-l.offsetHeight-14;return k<=0||B<=0?!1:k/B<1.1}return{element:a,currentCanvas:u.canvas,nextCanvas:g.canvas,currentLabel:u.label,nextLabel:g.label,isOpen:()=>R!==null&&!R.closed,update:P}}function Sn(n,e){const t=(R==null?void 0:R.document)??document,o=t.createElement("div");o.style.display="flex",o.style.alignItems="center",o.style.gap="10px",o.style.padding="8px 10px",o.style.backgroundColor="#ffffff",o.style.border="1px solid #e5e7eb",o.style.borderRadius="6px",o.style.boxShadow="0 1px 2px rgba(15, 23, 42, 0.06)",o.style.fontSize="14px",o.style.lineHeight="1",o.style.userSelect="none";const i=t.createElement("div");i.textContent=`${e+1}`,i.style.minWidth="24px",i.style.fontWeight="700",i.style.color="#6b7280";const a=t.createElement("div");return a.textContent=n.title.length>0?n.title:`Slide ${e+1}`,a.style.overflow="hidden",a.style.textOverflow="ellipsis",a.style.whiteSpace="nowrap",o.appendChild(i),o.appendChild(a),o}function He(n,e){var u;const t=(R==null?void 0:R.document)??document,o=t.createElement("div");o.style.display="flex",o.style.alignItems="center",o.style.flexDirection="column",o.style.minHeight="0",o.style.minWidth="0";const i=t.createElement("div");i.textContent=n,i.style.marginBottom="4px",i.style.fontSize="12px",i.style.fontWeight="700",i.style.textAlign="center",i.style.textTransform="uppercase",i.style.color="#6b7280";const a=t.createElement("div");a.style.marginBottom="6px",a.style.fontSize="14px",a.style.fontWeight="600",a.style.textAlign="center";const s=t.createElement("div");s.style.flex="1 1 auto",s.style.display="flex",s.style.alignItems="flex-start",s.style.justifyContent="center",s.style.minHeight="0",s.style.width="100%",s.style.overflow="hidden";const r=t.createElement("canvas");r.style.display="block",r.style.width="0",r.style.height="0";function l(){const g=s.clientWidth,h=s.clientHeight;if(g<=0||h<=0)return;const f=e.size.width/e.size.height,v=Math.min(g,h*f),x=v/f;r.style.width=`${v}px`,r.style.height=`${x}px`}const c=(u=t.defaultView)==null?void 0:u.ResizeObserver;return c!==void 0&&new c(l).observe(s),R==null||R.addEventListener("resize",l),s.appendChild(r),o.appendChild(i),o.appendChild(a),o.appendChild(s),{container:o,label:a,canvas:r,resize:l}}function ne(n,e,t){const o=(R==null?void 0:R.document)??document,i=e.style.display||"block",a=o.createElement("label");a.style.display="inline-flex",a.style.alignItems="center",a.style.gap="6px",a.style.userSelect="none";const s=o.createElement("input");return s.type="checkbox",s.checked=t,e.style.display=t?i:"none",s.addEventListener("change",()=>{e.style.display=s.checked?i:"none"}),a.appendChild(s),a.appendChild(o.createTextNode(n)),{element:a,input:s}}function Ue(n,e,t){if(e===null)return"End of presentation";const o=n.slides[e];return o===void 0?"No slide":`Slide ${e+1} of ${n.slides.length}, Build ${t+1} of ${o.animations.length+1}`}function Pn(n,e){if(n===void 0)return;const t=n.offsetTop,o=t+n.offsetHeight,i=e.scrollTop,a=i+e.clientHeight;(t<i||o>a)&&n.scrollIntoView({block:"nearest"})}function ie(){qt(R),Fe(),vt==null||vt(),R==null||R.close(),R=null,Dt=null,vt=null}function En(){const{width:n,height:e,left:t,top:o}=je;return`width=${n},height=${e},left=${t},top=${o}`}function qt(n){n===null||n.closed||(je={width:n.outerWidth,height:n.outerHeight,left:n.screenX,top:n.screenY})}function In(n){var o;const e=typeof((o=globalThis.crypto)==null?void 0:o.randomUUID)=="function"?globalThis.crypto.randomUUID():`${Date.now()}-${Math.random()}`,t=n;return t[Ve]=e,{isActive:()=>!n.closed&&t[Ve]===e}}function J(n=null){return{height:0,width:0,...n}}const kn=J({width:0,height:0});function $e(n=null){return{backgroundColor:K.WHITE,slides:[],title:"Presentation",size:J({width:3840,height:2160}),resources:{images:{}},...n}}function On(n){const e=Array.isArray(n)?n:[n];let t=0,o=0;for(const i of e)switch(i.type){case Y.PAUSE:t+=i.duration;break;case Y.ANIMATE:o=Math.max(o,t+i.delay+i.duration),i.block&&(t+=i.delay+i.duration);break;case Y.UPDATE:break;default:st(i)}return o}function re(n,e=null){const{red:t,green:o,blue:i}=n,a=Ae(n,e);return`rgba(${t}, ${o}, ${i}, ${a})`}function We(n){return n===document.body}function _n(n,e){const t=document.createElement("div");if(t.style.width="100%",t.style.aspectRatio=`${n.size.width} / ${n.size.height}`,t.style.position="relative",We(e)){t.style.top="50%",t.style.transform="translateY(-50%)",t.style.marginLeft="auto",t.style.marginRight="auto",t.style.overflowY="clip",document.title=n.title,document.documentElement.style.height="100%",document.body.style.margin="0",document.body.style.height="100%",document.body.style.width="100%",document.body.style.backgroundColor="#000000";const o=n.size.height/n.size.width;Ge(t,o),window.matchMedia(`(min-aspect-ratio: ${n.size.width} / ${n.size.height})`).addEventListener("change",()=>Ge(t,o))}return t}function Ge(n,e){window.innerHeight/window.innerWidth>e?(n.style.width="100%",n.style.height="auto"):(n.style.width="auto",n.style.height="100%")}const Ye={check:n=>typeof n=="object"&&n!==null&&typeof n.red=="number"&&typeof n.green=="number"&&typeof n.blue=="number"&&typeof n.alpha=="number",interpolate:(n,e,t)=>({red:Math.round(n.red+(e.red-n.red)*t),green:Math.round(n.green+(e.green-n.green)*t),blue:Math.round(n.blue+(e.blue-n.blue)*t),alpha:n.alpha+(e.alpha-n.alpha)*t})},Nn={check:n=>!0,interpolate:(n,e)=>e},Xe={check:n=>typeof n=="number",interpolate:(n,e,t)=>n+(e-n)*t},Ke=[Xe,Ye,Nn];function Fn(n,e,t,o=null){if(t===0)return n;if(t===1)return{...n,...e};const i=o!=null?[...o,...Ke]:Ke,a={};for(const s in e){const r=n[s],l=e[s];for(const c of i)if(c.check(r,s)&&c.check(l,s)){a[s]=c.interpolate(r,l,t);break}}return{...n,...a}}function Ze(n,e,t=null){if(e===null)return;const o=Array.isArray(e)?e:[e];let i=0;for(const a of o){if(t!==null&&i>t)break;switch(a.type){case Y.ANIMATE:{const s=n.get(a.object);if(s===void 0)break;const r=t!==null?t-i:null,l=Math.max(Math.min(r!==null?(r-a.delay)/a.duration:1,1),0);n.set(a.object,{...s,...Fn(s,a.props,a.easing(l),a.interpolators)}),a.block&&(i+=a.delay+a.duration);break}case Y.UPDATE:{const s=n.get(a.object);if(s===void 0)break;n.set(a.object,{...s,...a.props});break}case Y.PAUSE:i+=a.duration;break;default:st(a)}}}function Je(n){return"objects"in n?n.objects.filter(e=>"objectType"in e):[]}function Rn({slide:n,buildIndex:e,buildTime:t}){const o=new Map;function i(s){o.set(s,s);for(const r of Je(s))i(r)}for(const s of n.objects)i(s);const a=t===null?e:e-1;for(let s=0;s<a;s++){const r=n.animations[s]??null;Ze(o,r)}if(t!==null&&e>0){const s=n.animations[e-1]??null;Ze(o,s,t)}return o}function Bn(n){const e={};function t(o){if(o.objectType===V.SVG){const a=o.svg;a!==void 0&&a.length>0&&(e[a]=a)}const i=Je(o);for(const a of i)t(a)}for(const o of n.slides)for(const i of o.objects)t(i);return e}const wt="presenterState";function Dn(n,e){const t=localStorage.getItem(wt);if(t===null)return null;if(e===null)return localStorage.removeItem(wt),null;let o;try{o=JSON.parse(t)}catch(c){return console.error("Failed to parse presentation state from localStorage:",c),localStorage.removeItem(wt),null}const{title:i,timestamp:a}=o;let{slideIndex:s,buildIndex:r}=o;if(typeof i!="string"||typeof s!="number"||typeof r!="number"||typeof a!="number"||i!==n.title||Date.now()-a>1e3*60*e)return localStorage.removeItem(wt),null;s>n.slides.length-1&&(s=n.slides.length-1,r=0);const l=n.slides[s];return l===void 0?(localStorage.removeItem(wt),null):(r>l.animations.length&&(r=l.animations.length),{title:i,slideIndex:s,buildIndex:r})}function Qe({title:n,slideIndex:e,buildIndex:t}){localStorage.setItem(wt,JSON.stringify({title:n,slideIndex:e,buildIndex:t,timestamp:Date.now()}))}const t0=Object.freeze({canvas:null,extrasContainer:null,mountedExtrasCleanups:[],slideIndex:0,buildIndex:0,currentAnimationId:null,imageById:{},shortcutState:{textCommand:null,shortcuts:{}}}),Q={Browser:"browser",Node:"node"};function qn(n,e){e.context.clearRect(0,0,n.width,n.height)}function zn(n){const e=document.createElement("canvas");return e.setAttribute("width",n.width.toString()),e.setAttribute("height",n.height.toString()),e.style.position="absolute",e.style.width="100%",e}const yt={Browser:"browser",Node:"node"};function Vn(n){const e=new Path2D(n);return{type:yt.Browser,path:e}}function jn(n){const{drawn:e,startX:t,startY:o,endX:i,endY:a,arrowheadSize:s,isArrowheadFilled:r,isDrawnFromCenter:l}=n,c={x:t,y:o},u={x:i,y:a},g=Math.atan2(u.y-c.y,u.x-c.x),h={x:c.x+(u.x-c.x)/2,y:c.y+(u.y-c.y)/2},f=u.x-c.x,v=u.y-c.y,T=Math.hypot(f,v)*e,L=Math.cos(g),P=Math.sin(g),S=l?{x:h.x-L*T/2,y:h.y-P*T/2}:c,E=l?{x:h.x+L*T/2,y:h.y+P*T/2}:{x:c.x+L*T,y:c.y+P*T},M=r?Math.PI/6:Math.PI/4.5,k=T<s*2?T/2:s,B={x:E.x-k*Math.cos(g-M),y:E.y-k*Math.sin(g-M)},X={x:E.x-k*Math.cos(g+M),y:E.y-k*Math.sin(g+M)},j={x:S.x+k*Math.cos(g-M),y:S.y+k*Math.sin(g-M)},W={x:S.x+k*Math.cos(g+M),y:S.y+k*Math.sin(g+M)};return{arrowPoints:[S,E],arrowheadPoints:[B,E,X],doubledArrowheadPoints:[j,S,W]}}function mt({ctx:n,color:e,drawn:t=null,isDrawnFromCenter:o=!1,isRounded:i=!1,opacity:a=null,path:s,pathLength:r=null,width:l}){if(!(l===0||t===0)){if(t!==null&&r!==null&&t!==1){const c=r+(i?l:0),u=r*t;if(!o)n.context.setLineDash([u,c-u]),n.context.lineDashOffset=0;else{const g=c-u;n.context.setLineDash([u,g]),n.context.lineDashOffset=-g/2}}else n.context.setLineDash([]),n.context.lineDashOffset=0;if(n.context.lineWidth=l,n.context.strokeStyle=Pt(e,a),n.context.lineCap=i?"round":"butt",s===void 0){n.context.stroke();return}switch(n.type){case Q.Browser:s.type===yt.Browser?n.context.stroke(s.path):console.warn("Attempted to use Node Path2D in Browser Canvas context");break;case Q.Node:s.type===yt.Node?n.context.stroke(s.path):console.warn("Attempted to use Browser Path2D in Node Canvas context");break;default:st(n)}}}function xt({ctx:n,path:e,color:t,opacity:o=null}){if(n.context.fillStyle=re(t,o),e===void 0){n.context.fill();return}switch(n.type){case Q.Browser:e.type===yt.Browser?n.context.fill(e.path):console.warn("Attempted to use Node Path2D in Browser Canvas context");break;case Q.Node:e.type===yt.Node?n.context.fill(e.path):console.warn("Attempted to use Browser Path2D in Node Canvas context");break;default:st(n)}}function oe(n,e){const t=e(),o=n[0];if(o===void 0)return{path:t,length:0};t.path.moveTo(o.x,o.y);let i=0;for(let a=1;a<n.length;a++){const s=n[a],r=n[a-1];if(s===void 0||r===void 0)continue;const l=s.x-r.x,c=s.y-r.y;i+=Math.hypot(l,c),t.path.lineTo(s.x,s.y)}return{path:t,length:i}}const Hn=({ctx:n,object:e,opacity:t,createPath2D:o})=>{const i=e.opacity*t;if(i===0||e.drawn===0)return;const{arrowPoints:a,arrowheadPoints:s,doubledArrowheadPoints:r}=jn(e),{path:l}=oe(a,o),{path:c}=oe(s,o);if(mt({color:e.color,ctx:n,path:l,opacity:i,width:e.width}),e.isArrowheadFilled&&(c.path.closePath(),xt({ctx:n,path:c,color:e.color,opacity:i})),mt({color:e.color,ctx:n,path:c,opacity:i,width:e.width}),e.isArrowheadDoubled){const{path:u}=oe(r,o);e.isArrowheadFilled&&(u.path.closePath(),xt({ctx:n,path:u,color:e.color,opacity:i})),mt({color:e.color,ctx:n,path:u,opacity:i,width:e.width})}};function Un(n,e){const t=n.radius-n.strokeWidth/2;if(t<=0)return;const o=e(),i=-Math.PI/2;return o.path.arc(n.x,n.y,t,i,i+2*Math.PI),o}function $n(n,e){const t=e(),o=-Math.PI/2;t.path.arc(n.x,n.y,n.radius,o,o+2*Math.PI);const i=2*Math.PI*n.radius;return{path:t,length:i}}function e0(n,e){switch(n.type){case Q.Browser:e.type===yt.Browser?n.context.clip(e.path):console.warn("Attempted to use Node Path2D in Browser Canvas context");break;case Q.Node:e.type===yt.Node?n.context.clip(e.path):console.warn("Attempted to use Browser Path2D in Node Canvas context");break;default:st(n)}}const Wn=({ctx:n,object:e,opacity:t,createPath2D:o})=>{const i=e.opacity*t;if(i===0||e.drawn===0&&e.fillColor.alpha===0)return;const{path:a,length:s}=$n(e,o);if(i<1&&e.strokeWidth>0){const r=Un(e,o);r!==void 0&&(n.context.save(),e0(n,r),xt({ctx:n,path:a,color:e.fillColor,opacity:i}),n.context.restore())}else xt({ctx:n,path:a,color:e.fillColor,opacity:i});mt({color:e.strokeColor,ctx:n,drawn:e.drawn,path:a,pathLength:s,opacity:i,width:e.strokeWidth})};function $(n=null){return{x:0,y:0,...n}}const Gn=$();function dt(n=null){return{origin:Gn,size:kn,...n}}dt();function gt(n,e,t){const{x:o,y:i}=n,{width:a,height:s}=t;switch(e){case it.TOP_LEFT:return dt({origin:$({x:o,y:i}),size:t});case it.TOP:return dt({origin:$({x:o-a/2,y:i}),size:t});case it.TOP_RIGHT:return dt({origin:$({x:o-a,y:i}),size:t});case it.LEFT:return dt({origin:$({x:o,y:i-s/2}),size:t});case it.CENTER:return dt({origin:$({x:o-a/2,y:i-s/2}),size:t});case it.RIGHT:return dt({origin:$({x:o-a,y:i-s/2}),size:t});case it.BOTTOM_LEFT:return dt({origin:$({x:o,y:i-s}),size:t});case it.BOTTOM:return dt({origin:$({x:o-a/2,y:i-s}),size:t});case it.BOTTOM_RIGHT:return dt({origin:$({x:o-a,y:i-s}),size:t});default:st(e)}}const Yn=({ctx:n,object:e,renderObject:t,opacity:o})=>{const i=e.scale*e.scaleX,a=e.scale*e.scaleY,s=gt($({x:e.x,y:e.y}),e.anchor,J({width:e.width*Math.abs(i),height:e.height*Math.abs(a)})),{rotation:r,rotateOriginX:l,rotateOriginY:c,skewOriginX:u,skewOriginY:g,skewX:h,skewY:f}=e;if(!(i===0||a===0)){n.context.save(),n.context.translate(s.origin.x,s.origin.y),n.context.scale(i,a),n.context.translate(l,c),n.context.rotate(r*Math.PI/180),n.context.translate(-l,-c),n.context.translate(u,g),n.context.transform(1,Math.tan(f*Math.PI/180),Math.tan(h*Math.PI/180),1,0,0),n.context.translate(-u,-g);for(const v of e.objects)t(v,o*e.opacity);e.previewColor!==null&&(n.context.fillStyle=Pt(e.previewColor),n.context.fillRect(0,0,e.width,e.height)),e.rotateOriginPreviewSize>0&&(n.context.fillStyle="red",n.context.beginPath(),n.context.arc(l,c,e.rotateOriginPreviewSize,0,2*Math.PI),n.context.fill()),e.skewOriginPreviewSize>0&&(n.context.fillStyle="blue",n.context.beginPath(),n.context.arc(u,g,e.skewOriginPreviewSize,0,2*Math.PI),n.context.fill()),n.context.restore()}};function se(n,e,t,o,i=0){const a=o();a.path.moveTo(n.x+t,n.y),a.path.lineTo(n.x+e.width-t,n.y),a.path.arcTo(n.x+e.width,n.y,n.x+e.width,n.y+t,t),a.path.lineTo(n.x+e.width,n.y+e.height-t),a.path.arcTo(n.x+e.width,n.y+e.height,n.x+e.width-t,n.y+e.height,t),a.path.lineTo(n.x+t,n.y+e.height),a.path.arcTo(n.x,n.y+e.height,n.x,n.y+e.height-t,t),a.path.lineTo(n.x,n.y+t),a.path.arcTo(n.x,n.y,n.x+t,n.y,t),i>0&&a.path.lineTo(n.x+t+i,n.y);const s=2*(e.width+e.height-4*t)+2*Math.PI*t+i;return{path:a,length:s}}const It={Browser:"browser",Node:"node"},Xn=({ctx:n,imageById:e,object:t,opacity:o,createPath2D:i})=>{const a=gt($({x:t.x,y:t.y}),t.anchor,J({width:t.width,height:t.height})),s=e[t.imageId];if(s!==void 0){if(n.context.save(),t.cornerRadius>0){const r=se(a.origin,a.size,t.cornerRadius,i);switch(n.type){case Q.Browser:r.path.type===yt.Browser?n.context.clip(r.path.path):console.warn("Attempted to use Node Path2D in Browser Canvas context");break;case Q.Node:r.path.type===yt.Node?n.context.clip(r.path.path):console.warn("Attempted to use Browser Path2D in Node Canvas context");break;default:st(n)}}switch(n.context.globalAlpha=o*t.opacity,n.context.imageSmoothingEnabled=t.smooth,n.type){case Q.Browser:s.type===It.Browser?n.context.drawImage(s.image,a.origin.x,a.origin.y,a.size.width,a.size.height):console.warn("Attempted to use Node Image in Browser Canvas context");break;case Q.Node:s.type===It.Node?n.context.drawImage(s.image,a.origin.x,a.origin.y,a.size.width,a.size.height):console.warn("Attempted to use Browser Image in Node Canvas context");break;default:st(n)}n.context.restore()}};function Kn(n,e){const t=e();t.path.moveTo(n.startX,n.startY),t.path.lineTo(n.endX,n.endY);const o=Math.hypot(n.endX-n.startX,n.endY-n.startY);return{path:t,length:o}}const Zn=({ctx:n,object:e,opacity:t,createPath2D:o})=>{const i=e.opacity*t;if(i===0||e.drawn===0)return;const{path:a,length:s}=Kn(e,o);mt({color:e.color,ctx:n,drawn:e.drawn,isDrawnFromCenter:e.isDrawnFromCenter,isRounded:e.isRounded,path:a,pathLength:s,opacity:i,width:e.width})},Jn=({ctx:n,object:e,opacity:t,renderObject:o})=>{n.context.save();const i=gt($({x:e.x,y:e.y}),e.anchor,J({width:e.width,height:e.height}));e.preview&&(n.context.lineWidth=4,n.context.strokeStyle=Pt(K.RED),n.context.rect(i.origin.x,i.origin.y,i.size.width,i.size.height),n.context.stroke()),n.context.beginPath(),n.context.rect(i.origin.x,i.origin.y,i.size.width,i.size.height),n.context.closePath(),n.context.clip();for(const a of e.objects)o(a,t*e.opacity);n.context.restore()},Qn=({ctx:n,object:e,opacity:t,createPath2D:o})=>{const i=e.opacity*t;if(i===0||e.drawn===0&&e.fillColor.alpha===0)return;const{origin:a}=gt($({x:e.x,y:e.y}),e.anchor,J({width:e.width,height:e.height})),s=o(e.path);n.context.save(),n.context.translate(a.x,a.y),n.context.scale(e.width/e.viewboxWidth,e.height/e.viewboxHeight),xt({ctx:n,path:s,color:e.fillColor,opacity:i}),mt({color:e.strokeColor,ctx:n,drawn:e.drawn,isRounded:e.isRounded,path:s,pathLength:e.pathLength,opacity:i,width:e.strokeWidth}),n.context.restore()};function t1(n,e){const t=e(),o=n.points,i=o[0];if(i===void 0)return{path:t,length:0};t.path.moveTo(i.x,i.y);let a=0,s=i;for(let l=1;l<o.length;l++){const c=o[l];if(c===void 0)continue;t.path.lineTo(c.x,c.y);const u=Math.hypot(c.x-s.x,c.y-s.y);a+=u,s=c}t.path.closePath();const r=Math.hypot(i.x-s.x,i.y-s.y);return a+=r,{path:t,length:a}}const e1=({ctx:n,object:e,opacity:t,createPath2D:o})=>{const i=e.opacity*t;if(i===0||e.drawn===0&&e.fillColor.alpha===0)return;const{path:a,length:s}=t1(e,o);xt({ctx:n,path:a,color:e.fillColor,opacity:i}),mt({color:e.strokeColor,ctx:n,drawn:e.drawn,path:a,pathLength:s,opacity:i,width:e.strokeWidth})};function n1(n,e){const t=n.strokeWidth/2,{origin:o,size:i}=gt($({x:n.x,y:n.y}),n.anchor,J({width:n.width,height:n.height})),a=i.width-n.strokeWidth,s=i.height-n.strokeWidth;if(a<=0||s<=0)return;const r=$({x:o.x+t,y:o.y+t}),l=J({width:a,height:s}),c=Math.max(0,Math.min(n.cornerRadius-t,Math.min(a,s)/2));if(c>0)return se(r,l,c,e).path;const u=e();return u.path.moveTo(r.x,r.y),u.path.lineTo(r.x+a,r.y),u.path.lineTo(r.x+a,r.y+s),u.path.lineTo(r.x,r.y+s),u.path.closePath(),u}function i1(n,e){const{origin:t,size:o}=gt($({x:n.x,y:n.y}),n.anchor,J({width:n.width,height:n.height})),i=Math.max(0,Math.min(n.cornerRadius,Math.min(o.width,o.height)/2)),a=Math.min(n.strokeWidth*2,o.width-i);if(i>0)return se(t,o,i,e,a);{const s=e();s.path.moveTo(t.x,t.y),s.path.lineTo(t.x+o.width,t.y),s.path.lineTo(t.x+o.width,t.y+o.height),s.path.lineTo(t.x,t.y+o.height),s.path.lineTo(t.x,t.y),s.path.lineTo(t.x+a,t.y);const r=2*(o.width+o.height)+a;return{path:s,length:r}}}const r1=({ctx:n,object:e,opacity:t,createPath2D:o})=>{const i=e.opacity*t;if(i===0||e.drawn===0&&e.fillColor.alpha===0)return;const{path:a,length:s}=i1(e,o);if(i<1&&e.strokeWidth>0){const r=n1(e,o);r!==void 0&&(n.context.save(),e0(n,r),xt({ctx:n,path:a,color:e.fillColor,opacity:i}),n.context.restore())}else xt({ctx:n,path:a,color:e.fillColor,opacity:i});mt({color:e.strokeColor,ctx:n,drawn:e.drawn,path:a,pathLength:s,opacity:i,width:e.strokeWidth})};function o1(n){const{origin:e,size:t}=gt($({x:n.x,y:n.y}),n.anchor,J({width:n.width,height:n.height}));return{origin:e,size:t,cornerRadius:Math.max(0,Math.min(n.cornerRadius,Math.min(t.width,t.height)/2))}}function s1(n,e,t,o={origin:$({x:0,y:0}),size:e}){const i=t(),{origin:a,size:s,cornerRadius:r}=o1(n),{origin:l,size:c}=o;return i.path.moveTo(l.x,l.y),i.path.lineTo(l.x+c.width,l.y),i.path.lineTo(l.x+c.width,l.y+c.height),i.path.lineTo(l.x,l.y+c.height),i.path.lineTo(l.x,l.y),r===0?(i.path.moveTo(a.x,a.y),i.path.lineTo(a.x,a.y+s.height),i.path.lineTo(a.x+s.width,a.y+s.height),i.path.lineTo(a.x+s.width,a.y),i.path.lineTo(a.x,a.y),i):(i.path.moveTo(a.x+r,a.y),i.path.arcTo(a.x,a.y,a.x,a.y+r,r),i.path.lineTo(a.x,a.y+s.height-r),i.path.arcTo(a.x,a.y+s.height,a.x+r,a.y+s.height,r),i.path.lineTo(a.x+s.width-r,a.y+s.height),i.path.arcTo(a.x+s.width,a.y+s.height,a.x+s.width,a.y+s.height-r,r),i.path.lineTo(a.x+s.width,a.y+r),i.path.arcTo(a.x+s.width,a.y,a.x+s.width-r,a.y,r),i.path.lineTo(a.x+r,a.y),i)}const a1=({createPath2D:n,ctx:e,object:t,opacity:o,renderScale:i,slideSize:a})=>{const s=t.opacity*o;if(s===0||t.color.alpha===0)return;const r=J({width:a.width/i,height:a.height/i}),l=$({x:(a.width-r.width)/2,y:(a.height-r.height)/2}),c=s1(t,a,n,{origin:l,size:r});xt({ctx:e,path:c,color:t.color,opacity:s})},l1=({ctx:n,imageById:e,object:t,opacity:o})=>{const i=t.opacity*o;if(i===0||!t.svg)return;const a=e[t.svg];if(a===void 0)return;const s=gt($({x:t.x,y:t.y}),t.anchor,J({width:t.width,height:t.height}));switch(n.context.save(),n.context.globalAlpha=i,n.type){case Q.Browser:a.type===It.Browser&&n.context.drawImage(a.image,s.origin.x,s.origin.y,s.size.width,s.size.height);break;case Q.Node:a.type===It.Node&&n.context.drawImage(a.image,s.origin.x,s.origin.y,s.size.width,s.size.height);break;default:st(n)}n.context.restore()};function h1(n){return{color:n.color,fontFamily:n.fontFamily,fontSize:n.fontSize,fontStyle:n.fontStyle,fontWeight:n.fontWeight,ligatures:n.ligatures,subscript:n.subscript,superscript:n.superscript}}function c1(n,e=1){const t=Math.max(...n.map(a=>a.reduce((s,r)=>s+r.width,0)));let o=0,i=0;for(let a=0;a<n.length;a++){const s=n[a];if(s===void 0)continue;const r=Math.max(...s.map(l=>l.height));o+=r+i*(e-1),i=r}return{height:o,width:t}}const u1=.7,f1=.3;function n0(n){const e=n.superscript,t=n.subscript&&!e;return!e&&!t?{baselineShift:0,fontSize:n.fontSize,isSubscript:!1,isSuperscript:!1}:{baselineShift:n.fontSize*f1*(e?-1:1),fontSize:n.fontSize*u1,isSubscript:t,isSuperscript:e}}function i0(n,e=0){return n??e}function d1(n){const e=i0(n.fontBoundingBoxAscent,n.actualBoundingBoxAscent),t=i0(n.fontBoundingBoxDescent,n.actualBoundingBoxDescent);return{bottom:t,height:e+t,top:e,width:n.width}}function r0(n,e,t=1){const o=n0(e);n.context.fillStyle=re(e.color,t),n.context.font=`${e.fontStyle} ${e.fontWeight} ${o.fontSize}px ${e.fontFamily}`,n.type===Q.Browser?n.context.textRendering=e.ligatures?"optimizeLegibility":"optimizeSpeed":n.context.fontVariant=e.ligatures?"common-ligatures":"no-common-ligatures"}function g1(n,e,t){const o=[];for(const i of n){const a=[];for(const s of i){const{text:r,...l}=s,c={...e,...l};r0(t,c);const u=t.context.measureText(r),g=d1(u),{baselineShift:h}=n0(c),f=Math.max(0,g.top-h),v=Math.max(0,g.bottom+h);a.push({...g,baselineShift:h,bottom:v,height:f+v,top:f})}o.push(a)}return o}const p1=({ctx:n,object:e,opacity:t})=>{const o=e.opacity*t;if(o===0)return;const{length:i}=e,a=Oe(e.text),s=h1(e),r=g1(a,s,n),l=c1(r,e.lineSpacing),c=gt($({x:e.x,y:e.y}),e.anchor,l);let u=c.origin.x,g=c.origin.y,h=0,f=0;for(let v=0;v<a.length;v++){const x=a[v],T=r[v];if(x==null||T==null){console.error("Could not determine text units or sizes for line");continue}const L=T.reduce((k,B)=>k+B.width,0),P=T.length===0?f:T.reduce((k,B)=>Math.max(k,B.top),0),S=T.length===0?0:T.reduce((k,B)=>Math.max(k,B.bottom),0),E=P+S;switch(e.alignment){case pt.LEFT:u=c.origin.x;break;case pt.CENTER:u=c.origin.x+(c.size.width-L)/2;break;case pt.RIGHT:u=c.origin.x+(c.size.width-L);break;default:st(e.alignment);break}g+=f*(e.lineSpacing-1);const M=g+P;f=E;for(let k=0;k<x.length&&!(i!==null&&h>=i);k++){const B=x[k],X=T[k];if(B==null||X==null){console.error("Could not determine text unit or size for unit");continue}const{text:j,...W}=B;let ht;if(i!==null&&h+j.length>i){const nt=i-h;ht=j.slice(0,nt)}const ct=ht??j;h+=ct.length;const ut={...s,...W};r0(n,ut,o),n.context.fillText(ct,u,M+X.baselineShift),u+=X.width}g+=E}},y1={[V.ARROW]:Hn,[V.CIRCLE]:Wn,[V.GROUP]:Yn,[V.IMAGE]:Xn,[V.LINE]:Zn,[V.MASK]:Jn,[V.PATH]:Qn,[V.POLYGON]:e1,[V.RECTANGLE]:r1,[V.SLIDE_OBJECT]:()=>{},[V.SPOTLIGHT]:a1,[V.SVG]:l1,[V.TEXT]:p1};function x1(n){const e=document.createElementNS("http://www.w3.org/2000/svg","svg");return e.setAttribute("viewBox",`0 0 ${n.width} ${n.height}`),e.style.backgroundColor="transparent",e.style.position="absolute",e.style.width="100%",e}function v1(n,e){if(n===null)return null;const t=gt($({x:e.x,y:e.y}),e.anchor,J({width:e.width,height:e.height})),o=document.createElementNS("http://www.w3.org/2000/svg","foreignObject");o.setAttribute("x",t.origin.x.toString()),o.setAttribute("y",t.origin.y.toString()),o.setAttribute("width",e.width.toString()),o.setAttribute("height",e.height.toString());const i=e.content;i!==null&&o.appendChild(i),n.appendChild(o);let a=null;if(e.setup!==null){const s=e.setup(o);s!==void 0&&(a=s)}return()=>{a!==null&&a(),n.removeChild(o)}}async function w1(n){if(Object.keys(n).length===0)return{};const e={},t=i=>new Promise((a,s)=>{const r=new Image;if(r.onload=()=>a(r),r.onerror=c=>s(c),i.includes("</svg>")){const c=i.replace(/<\?xml[^?]*\?>\s*/g,""),u=new Blob([c],{type:"image/svg+xml;charset=utf-8"}),g=URL.createObjectURL(u);r.src=g}else r.src=i}),o=Object.entries(n).map(async([i,a])=>{const s=await t(a);e[i]={type:It.Browser,image:s}});try{await Promise.all(o)}catch(i){console.error("Error loading images:",i)}return e}const o0="presenterPendingVariables:";function m1(){const n=s0();if(n===null)return{};try{const e=ae(),t=n.getItem(e);if(n.removeItem(e),t===null)return{};const o=JSON.parse(t);if(o.values===void 0||typeof o.values!="object")return{};const i={};for(const[a,s]of Object.entries(o.values))typeof s=="number"&&Number.isFinite(s)&&(i[a]=s);return i}catch(e){return console.error("Failed to parse pending presenter variable state from sessionStorage:",e),n.removeItem(ae()),{}}}function b1(n){const e=s0();e!==null&&e.setItem(ae(),JSON.stringify({values:n}))}function ae(){return typeof window>"u"?o0:`${o0}${window.location.origin}${window.location.pathname}`}function s0(){try{return typeof sessionStorage>"u"?null:sessionStorage}catch{return null}}const A1=0,T1=1,a0=0,M1=.01,zt=new Map;let kt=new Map,l0=!1,h0=1;function L1(n=null){k1();const e=n??{},t=I1(),o=E1(t,e),i=kt.get(o.id);if(i!==void 0){const a=c0(i,o);return kt.set(o.id,a),a}return o.default}function C1(){return Array.from(zt.values())}function S1(n){const e=zt.get(n);return e===void 0?a0:kt.get(e.id)??e.default}function P1(n,e){const t=zt.get(n);if(t===void 0)return e;const o=c0(e,t);return kt.set(t.id,o),o}function E1(n,e){const t=e.min??A1,o=e.max??T1,i=Math.min(t,o),a=Math.max(t,o),s=e.increment!==void 0&&e.increment>0?e.increment:M1,r={id:n,name:e.name??n,min:i,max:a,default:u0(e.default??a0,i,a),increment:s};return zt.set(n,r),r}function I1(){const n=`var${h0}`;return h0+=1,n}function k1(){l0||(kt=new Map(Object.entries(m1())),l0=!0)}function c0(n,e){return u0(n,e.min,e.max)}function u0(n,e,t){return Math.max(e,Math.min(t,n))}function O1({onCommit:n,onPreview:e}){const t=C1();if(t.length===0)return null;const o=document.createElement("div");Object.assign(o.style,{position:"absolute",right:"16px",bottom:"16px",zIndex:"20",display:"flex",flexDirection:"column",gap:"8px",width:"min(360px, calc(100% - 32px))",padding:"10px",boxSizing:"border-box",border:"1px solid rgba(255, 255, 255, 0.18)",borderRadius:"8px",background:"rgba(16, 18, 22, 0.82)",color:"#ffffff",fontFamily:'ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif',fontSize:"12px",lineHeight:"1.25",pointerEvents:"auto",boxShadow:"0 12px 36px rgba(0, 0, 0, 0.28)",backdropFilter:"blur(10px)"});for(const i of t)o.appendChild(_1(i,e,n));return o}function _1(n,e,t){const o=document.createElement("div");o.dataset.presenterVariableId=n.id,o.dataset.presenterVariableName=n.name,Object.assign(o.style,{display:"grid",gridTemplateColumns:"72px minmax(0, 1fr) 74px",alignItems:"center",gap:"8px"});const i=document.createElement("div");i.textContent=n.name,i.title=n.name,Object.assign(i.style,{overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap",color:"rgba(255, 255, 255, 0.86)",fontWeight:"600"});const a=document.createElement("input");a.type="range",a.min=n.min.toString(),a.max=n.max.toString(),a.step=n.increment.toString(),Object.assign(a.style,{width:"100%",minWidth:"0",accentColor:"#8bc7ff"});const s=document.createElement("input");s.type="number",s.min=n.min.toString(),s.max=n.max.toString(),s.step=n.increment.toString(),Object.assign(s.style,{width:"100%",boxSizing:"border-box",border:"1px solid rgba(255, 255, 255, 0.24)",borderRadius:"6px",padding:"4px 6px",background:"rgba(255, 255, 255, 0.1)",color:"#ffffff",font:"inherit"});let r=S1(n.id);const l=g=>{const h=N1(g);a.value=h,s.value=h},c=g=>{Number.isFinite(g)&&(r=e(n.id,g),l(r))},u=g=>{Number.isFinite(g)&&(g!==r&&c(g),t())};return a.addEventListener("input",()=>c(a.valueAsNumber)),a.addEventListener("change",()=>u(a.valueAsNumber)),s.addEventListener("change",()=>u(s.valueAsNumber)),l(r),o.appendChild(i),o.appendChild(a),o.appendChild(s),o}function N1(n){return Number.isInteger(n)?n.toString():parseFloat(n.toFixed(6)).toString()}function F1({container:n,onCommit:e}){const t=O1({onPreview:(o,i)=>{const a=P1(o,i);return b1({[o]:a}),a},onCommit:e});t!==null&&n.appendChild(t)}class R1{constructor(e){this.navigator=null;const{objectRenderers:t,scale:o=1,...i}=e;this.props={presentation:$e(),element:document.body,objectRenderers:{...y1,...t},cacheDurationMinutes:15,scale:B1(o),...i},this.state={...t0}}async present(){const{presentation:e,element:t,scale:o}=this.props;this.hideCursor();const i=zn(e.size),a=x1(e.size);a.style.transformOrigin="center center",a.style.transform=`scale(${o})`,this.state={...t0,imageById:await w1({...e.resources.images,...Bn(e)}),canvas:i,extrasContainer:a};const s=_n(e,t),r=We(t),l=(g,h)=>{this.state.shortcutState.shortcuts.b={slideIndex:this.state.slideIndex,buildIndex:this.state.buildIndex},this.renderSlide(g??this.state.slideIndex,h)},c=(g=!1)=>{r&&(this.navigator=Ln({presentation:e,shortcutState:this.state.shortcutState,onNavigateToSlide:h=>this.renderSlide(h),onRenderSlide:l,onNext:h=>this.next(h),onPrevious:h=>this.previous(h),forceRefresh:g}),this.updateNavigator())};ze(e,s,this.state.shortcutState,{onNext:g=>this.next(g),onPrevious:g=>this.previous(g),onRenderSlide:l,onShowNavigator:()=>c()},{focusOnPointerDown:!r,keyEventTarget:r?window:s}),t.replaceChildren(),s.appendChild(i),s.appendChild(a),F1({container:s,onCommit:()=>this.reloadAfterVariableChange()}),t.appendChild(s);const u=Dn(e,this.props.cacheDurationMinutes);u!==null?this.renderSlide(u.slideIndex,u.buildIndex):this.renderSlide(0),bn()&&c(!0)}reloadAfterVariableChange(){const{presentation:e}=this.props;this.state.currentAnimationId!==null&&(cancelAnimationFrame(this.state.currentAnimationId),this.state.currentAnimationId=null),Qe({title:e.title,slideIndex:this.state.slideIndex,buildIndex:this.state.buildIndex}),window.location.reload()}renderSlide(e,t=0,o=null){const{presentation:i}=this.props,{canvas:a}=this.state,s=this.state.slideIndex!==e;this.state.slideIndex=e,this.state.buildIndex=t,o===null&&Qe({title:i.title,slideIndex:e,buildIndex:t});const r=i.slides[e];if(!(r===void 0||a===null)){if(s||this.state.mountedExtrasCleanups.length===0&&r.extras.length>0){for(const l of this.state.mountedExtrasCleanups)l();this.state.mountedExtrasCleanups=[];for(const l of r.extras){const c=v1(this.state.extrasContainer,l);c!==null&&this.state.mountedExtrasCleanups.push(c)}}this.renderCanvas(a,e,t,o,this.props.scale),o===null&&this.updateNavigator()}}renderCanvas(e,t,o=0,i=null,a=1){const{objectRenderers:s,presentation:r}=this.props,{imageById:l}=this.state;e.width=r.size.width,e.height=r.size.height;const c=e.getContext("2d");if(c===null)return;const u={type:Q.Browser,context:c};qn(e,u);const g=r.slides[t];if(g===void 0)return;const h=Rn({slide:g,buildIndex:o,buildTime:i});u.context.fillStyle=re(r.backgroundColor),u.context.fillRect(0,0,e.width,e.height);function f(x,T){const L=s[x.objectType],P=h.get(x);L===void 0||P===void 0||L({ctx:u,imageById:l,object:P,opacity:T,renderScale:a,renderObject:f,createPath2D:Vn,slideSize:r.size})}const v=a!==1;v&&(u.context.save(),u.context.translate(e.width*(1-a)/2,e.height*(1-a)/2),u.context.scale(a,a));for(const x of g.objects)f(x,1);v&&u.context.restore()}updateNavigator(){const{navigator:e}=this;if(e===null)return;if(!e.isOpen()){this.navigator=null;return}const{slideIndex:t,buildIndex:o}=this.state,i=this.getNextSlideBuild(t,o);e.update(t,o,i.slideIndex,i.buildIndex),this.renderCanvas(e.currentCanvas,t,o),i.slideIndex===null?this.renderEndCanvas(e.nextCanvas):this.renderCanvas(e.nextCanvas,i.slideIndex,i.buildIndex)}getNextSlideBuild(e,t){const{presentation:o}=this.props,i=o.slides[e];return i===void 0?{slideIndex:e,buildIndex:t}:t<i.animations.length?{slideIndex:e,buildIndex:t+1}:e+1<o.slides.length?{slideIndex:e+1,buildIndex:0}:{slideIndex:null,buildIndex:0}}renderEndCanvas(e){const{presentation:t}=this.props;e.width=t.size.width,e.height=t.size.height;const o=e.getContext("2d");o!==null&&(o.fillStyle="#000000",o.fillRect(0,0,e.width,e.height))}next(e=!1){const{presentation:t}=this.props,{currentAnimationId:o,slideIndex:i,buildIndex:a}=this.state;this.hideCursor(),o!==null&&cancelAnimationFrame(o);const s=t.slides[i];if(s===void 0)return;const r=s.animations[a];if(r!==void 0&&!e){const l=performance.now(),c=On(r),u=g=>{const h=g-l;h<c?(this.renderSlide(i,a+1,h),this.state.currentAnimationId=requestAnimationFrame(u)):this.renderSlide(i,a+1,null)};this.state.currentAnimationId=requestAnimationFrame(u)}else i+1<t.slides.length&&this.renderSlide(i+1)}previous(e=!1){const{currentAnimationId:t,slideIndex:o,buildIndex:i}=this.state;if(this.hideCursor(),t!==null&&cancelAnimationFrame(t),i>0)e?this.renderSlide(o,0):this.renderSlide(o,i-1);else if(o>0){const a=this.props.presentation.slides[o-1],s=e?0:(a==null?void 0:a.animations.length)??0;this.renderSlide(o-1,s)}else this.renderSlide(0,0)}hasNext(){const{presentation:e}=this.props,{slideIndex:t,buildIndex:o}=this.state,i=e.slides[t];return i===void 0?!1:i.animations[o]!==void 0?!0:t+1<e.slides.length}hasPrevious(){const{slideIndex:e,buildIndex:t}=this.state;return t>0||e>0}hideCursor(){var e,t;this.props.element.style.cursor="none",(t=(e=this.state.canvas)==null?void 0:e.parentElement)==null||t.style.setProperty("cursor","none")}}function B1(n){return n<=0||n>1?(console.warn(`BrowserCanvasRenderer scale must be positive and no greater than 1. Received ${n}; using 1 instead.`),1):n}function D1(n=1e3){return{type:Y.PAUSE,isKey:!1,duration:n,shortcut:null}}function q1(n=null){return{objects:[],animations:[],extras:[],isAllKey:!1,isEndKey:!0,isStartKey:!1,shortcut:null,title:"",...n}}function z1(n,e={}){return{...e,text:n}}function V1(n=K.BLACK){return{...n,alpha:1}}function j1(n){for(var e=-1,t=n.length,o,i=n[t-1],a=0;++e<t;)o=i,i=n[e],a+=o[1]*i[0]-o[0]*i[1];return a/2}function H1(n){for(var e=-1,t=n.length,o=n[t-1],i,a,s=o[0],r=o[1],l=0;++e<t;)i=s,a=r,o=n[e],s=o[0],r=o[1],i-=s,a-=r,l+=Math.sqrt(i*i+a*a);return l}function U1(n){return n&&n.__esModule&&Object.prototype.hasOwnProperty.call(n,"default")?n.default:n}var le,f0;function $1(){if(f0)return le;f0=1;var n={a:7,c:6,h:1,l:2,m:2,r:4,q:4,s:4,t:2,v:1,z:0},e=[5760,6158,8192,8193,8194,8195,8196,8197,8198,8199,8200,8201,8202,8239,8287,12288,65279];function t(f){return f===10||f===13||f===8232||f===8233||f===32||f===9||f===11||f===12||f===160||f>=5760&&e.indexOf(f)>=0}function o(f){switch(f|32){case 109:case 122:case 108:case 104:case 118:case 99:case 115:case 113:case 116:case 97:case 114:return!0}return!1}function i(f){return(f|32)===97}function a(f){return f>=48&&f<=57}function s(f){return f>=48&&f<=57||f===43||f===45||f===46}function r(f){this.index=0,this.path=f,this.max=f.length,this.result=[],this.param=0,this.err="",this.segmentStart=0,this.data=[]}function l(f){for(;f.index<f.max&&t(f.path.charCodeAt(f.index));)f.index++}function c(f){var v=f.path.charCodeAt(f.index);if(v===48){f.param=0,f.index++;return}if(v===49){f.param=1,f.index++;return}f.err="SvgPath: arc flag can be 0 or 1 only (at pos "+f.index+")"}function u(f){var v=f.index,x=v,T=f.max,L=!1,P=!1,S=!1,E=!1,M;if(x>=T){f.err="SvgPath: missed param (at pos "+x+")";return}if(M=f.path.charCodeAt(x),(M===43||M===45)&&(x++,M=x<T?f.path.charCodeAt(x):0),!a(M)&&M!==46){f.err="SvgPath: param should start with 0..9 or `.` (at pos "+x+")";return}if(M!==46){if(L=M===48,x++,M=x<T?f.path.charCodeAt(x):0,L&&x<T&&M&&a(M)){f.err="SvgPath: numbers started with `0` such as `09` are illegal (at pos "+v+")";return}for(;x<T&&a(f.path.charCodeAt(x));)x++,P=!0;M=x<T?f.path.charCodeAt(x):0}if(M===46){for(E=!0,x++;a(f.path.charCodeAt(x));)x++,S=!0;M=x<T?f.path.charCodeAt(x):0}if(M===101||M===69){if(E&&!P&&!S){f.err="SvgPath: invalid float exponent (at pos "+x+")";return}if(x++,M=x<T?f.path.charCodeAt(x):0,(M===43||M===45)&&x++,x<T&&a(f.path.charCodeAt(x)))for(;x<T&&a(f.path.charCodeAt(x));)x++;else{f.err="SvgPath: invalid float exponent (at pos "+x+")";return}}f.index=x,f.param=parseFloat(f.path.slice(v,x))+0}function g(f){var v,x;v=f.path[f.segmentStart],x=v.toLowerCase();var T=f.data;if(x==="m"&&T.length>2&&(f.result.push([v,T[0],T[1]]),T=T.slice(2),x="l",v=v==="m"?"l":"L"),x==="r")f.result.push([v].concat(T));else for(;T.length>=n[x]&&(f.result.push([v].concat(T.splice(0,n[x]))),!!n[x]););}function h(f){var v=f.max,x,T,L,P,S;if(f.segmentStart=f.index,x=f.path.charCodeAt(f.index),T=i(x),!o(x)){f.err="SvgPath: bad command "+f.path[f.index]+" (at pos "+f.index+")";return}if(P=n[f.path[f.index].toLowerCase()],f.index++,l(f),f.data=[],!P){g(f);return}for(L=!1;;){for(S=P;S>0;S--){if(T&&(S===3||S===4)?c(f):u(f),f.err.length){g(f);return}f.data.push(f.param),l(f),L=!1,f.index<v&&f.path.charCodeAt(f.index)===44&&(f.index++,l(f),L=!0)}if(!L&&(f.index>=f.max||!s(f.path.charCodeAt(f.index))))break}g(f)}return le=function(v){var x=new r(v),T=x.max;for(l(x);x.index<T&&!x.err.length;)h(x);return x.result.length&&("mM".indexOf(x.result[0][0])<0?(x.err="SvgPath: string should start with `M` or `m`",x.result=[]):x.result[0][0]="M"),{err:x.err,segments:x.result}},le}var he,d0;function g0(){if(d0)return he;d0=1;function n(t,o){return[t[0]*o[0]+t[2]*o[1],t[1]*o[0]+t[3]*o[1],t[0]*o[2]+t[2]*o[3],t[1]*o[2]+t[3]*o[3],t[0]*o[4]+t[2]*o[5]+t[4],t[1]*o[4]+t[3]*o[5]+t[5]]}function e(){if(!(this instanceof e))return new e;this.queue=[],this.cache=null}return e.prototype.matrix=function(t){return t[0]===1&&t[1]===0&&t[2]===0&&t[3]===1&&t[4]===0&&t[5]===0?this:(this.cache=null,this.queue.push(t),this)},e.prototype.translate=function(t,o){return(t!==0||o!==0)&&(this.cache=null,this.queue.push([1,0,0,1,t,o])),this},e.prototype.scale=function(t,o){return(t!==1||o!==1)&&(this.cache=null,this.queue.push([t,0,0,o,0,0])),this},e.prototype.rotate=function(t,o,i){var a,s,r;return t!==0&&(this.translate(o,i),a=t*Math.PI/180,s=Math.cos(a),r=Math.sin(a),this.queue.push([s,r,-r,s,0,0]),this.cache=null,this.translate(-o,-i)),this},e.prototype.skewX=function(t){return t!==0&&(this.cache=null,this.queue.push([1,0,Math.tan(t*Math.PI/180),1,0,0])),this},e.prototype.skewY=function(t){return t!==0&&(this.cache=null,this.queue.push([1,Math.tan(t*Math.PI/180),0,1,0,0])),this},e.prototype.toArray=function(){if(this.cache)return this.cache;if(!this.queue.length)return this.cache=[1,0,0,1,0,0],this.cache;if(this.cache=this.queue[0],this.queue.length===1)return this.cache;for(var t=1;t<this.queue.length;t++)this.cache=n(this.cache,this.queue[t]);return this.cache},e.prototype.calc=function(t,o,i){var a;return this.queue.length?(this.cache||(this.cache=this.toArray()),a=this.cache,[t*a[0]+o*a[2]+(i?0:a[4]),t*a[1]+o*a[3]+(i?0:a[5])]):[t,o]},he=e,he}var ce,p0;function W1(){if(p0)return ce;p0=1;var n=g0(),e={matrix:!0,scale:!0,rotate:!0,translate:!0,skewX:!0,skewY:!0},t=/\s*(matrix|translate|scale|rotate|skewX|skewY)\s*\(\s*(.+?)\s*\)[\s,]*/,o=/[\s,]+/;return ce=function(a){var s=new n,r,l;return a.split(t).forEach(function(c){if(c.length){if(typeof e[c]<"u"){r=c;return}switch(l=c.split(o).map(function(u){return+u||0}),r){case"matrix":l.length===6&&s.matrix(l);return;case"scale":l.length===1?s.scale(l[0],l[0]):l.length===2&&s.scale(l[0],l[1]);return;case"rotate":l.length===1?s.rotate(l[0],0,0):l.length===3&&s.rotate(l[0],l[1],l[2]);return;case"translate":l.length===1?s.translate(l[0],0):l.length===2&&s.translate(l[0],l[1]);return;case"skewX":l.length===1&&s.skewX(l[0]);return;case"skewY":l.length===1&&s.skewY(l[0]);return}}}),s},ce}var ue,y0;function G1(){if(y0)return ue;y0=1;var n=Math.PI*2;function e(i,a,s,r){var l=i*r-a*s<0?-1:1,c=i*s+a*r;return c>1&&(c=1),c<-1&&(c=-1),l*Math.acos(c)}function t(i,a,s,r,l,c,u,g,h,f){var v=f*(i-s)/2+h*(a-r)/2,x=-h*(i-s)/2+f*(a-r)/2,T=u*u,L=g*g,P=v*v,S=x*x,E=T*L-T*S-L*P;E<0&&(E=0),E/=T*S+L*P,E=Math.sqrt(E)*(l===c?-1:1);var M=E*u/g*x,k=E*-g/u*v,B=f*M-h*k+(i+s)/2,X=h*M+f*k+(a+r)/2,j=(v-M)/u,W=(x-k)/g,ht=(-v-M)/u,ct=(-x-k)/g,ut=e(1,0,j,W),nt=e(j,W,ht,ct);return c===0&&nt>0&&(nt-=n),c===1&&nt<0&&(nt+=n),[B,X,ut,nt]}function o(i,a){var s=1.3333333333333333*Math.tan(a/4),r=Math.cos(i),l=Math.sin(i),c=Math.cos(i+a),u=Math.sin(i+a);return[r,l,r-l*s,l+r*s,c+u*s,u-c*s,c,u]}return ue=function(a,s,r,l,c,u,g,h,f){var v=Math.sin(f*n/360),x=Math.cos(f*n/360),T=x*(a-r)/2+v*(s-l)/2,L=-v*(a-r)/2+x*(s-l)/2;if(T===0&&L===0)return[];if(g===0||h===0)return[];g=Math.abs(g),h=Math.abs(h);var P=T*T/(g*g)+L*L/(h*h);P>1&&(g*=Math.sqrt(P),h*=Math.sqrt(P));var S=t(a,s,r,l,c,u,g,h,v,x),E=[],M=S[2],k=S[3],B=Math.max(Math.ceil(Math.abs(k)/(n/4)),1);k/=B;for(var X=0;X<B;X++)E.push(o(M,k)),M+=k;return E.map(function(j){for(var W=0;W<j.length;W+=2){var ht=j[W+0],ct=j[W+1];ht*=g,ct*=h;var ut=x*ht-v*ct,nt=v*ht+x*ct;j[W+0]=ut+S[0],j[W+1]=nt+S[1]}return j})},ue}var fe,x0;function Y1(){if(x0)return fe;x0=1;var n=1e-10,e=Math.PI/180;function t(o,i,a){if(!(this instanceof t))return new t(o,i,a);this.rx=o,this.ry=i,this.ax=a}return t.prototype.transform=function(o){var i=Math.cos(this.ax*e),a=Math.sin(this.ax*e),s=[this.rx*(o[0]*i+o[2]*a),this.rx*(o[1]*i+o[3]*a),this.ry*(-o[0]*a+o[2]*i),this.ry*(-o[1]*a+o[3]*i)],r=s[0]*s[0]+s[2]*s[2],l=s[1]*s[1]+s[3]*s[3],c=((s[0]-s[3])*(s[0]-s[3])+(s[2]+s[1])*(s[2]+s[1]))*((s[0]+s[3])*(s[0]+s[3])+(s[2]-s[1])*(s[2]-s[1])),u=(r+l)/2;if(c<n*u)return this.rx=this.ry=Math.sqrt(u),this.ax=0,this;var g=s[0]*s[1]+s[2]*s[3];c=Math.sqrt(c);var h=u+c/2,f=u-c/2;return this.ax=Math.abs(g)<n&&Math.abs(h-l)<n?90:Math.atan(Math.abs(g)>Math.abs(h-l)?(h-r)/g:g/(h-l))*180/Math.PI,this.ax>=0?(this.rx=Math.sqrt(h),this.ry=Math.sqrt(f)):(this.ax+=90,this.rx=Math.sqrt(f),this.ry=Math.sqrt(h)),this},t.prototype.isDegenerate=function(){return this.rx<n*this.ry||this.ry<n*this.rx},fe=t,fe}var de,v0;function X1(){if(v0)return de;v0=1;var n=$1(),e=W1(),t=g0(),o=G1(),i=Y1();function a(s){if(!(this instanceof a))return new a(s);var r=n(s);this.segments=r.segments,this.err=r.err,this.__stack=[]}return a.from=function(s){if(typeof s=="string")return new a(s);if(s instanceof a){var r=new a("");return r.err=s.err,r.segments=s.segments.map(function(l){return l.slice()}),r.__stack=s.__stack.map(function(l){return t().matrix(l.toArray())}),r}throw new Error("SvgPath.from: invalid param type "+s)},a.prototype.__matrix=function(s){var r=this,l;s.queue.length&&this.iterate(function(c,u,g,h){var f,v,x,T;switch(c[0]){case"v":f=s.calc(0,c[1],!0),v=f[0]===0?["v",f[1]]:["l",f[0],f[1]];break;case"V":f=s.calc(g,c[1],!1),v=f[0]===s.calc(g,h,!1)[0]?["V",f[1]]:["L",f[0],f[1]];break;case"h":f=s.calc(c[1],0,!0),v=f[1]===0?["h",f[0]]:["l",f[0],f[1]];break;case"H":f=s.calc(c[1],h,!1),v=f[1]===s.calc(g,h,!1)[1]?["H",f[0]]:["L",f[0],f[1]];break;case"a":case"A":var L=s.toArray(),P=i(c[1],c[2],c[3]).transform(L);if(L[0]*L[3]-L[1]*L[2]<0&&(c[5]=c[5]?"0":"1"),f=s.calc(c[6],c[7],c[0]==="a"),c[0]==="A"&&c[6]===g&&c[7]===h||c[0]==="a"&&c[6]===0&&c[7]===0){v=[c[0]==="a"?"l":"L",f[0],f[1]];break}P.isDegenerate()?v=[c[0]==="a"?"l":"L",f[0],f[1]]:v=[c[0],P.rx,P.ry,P.ax,c[4],c[5],f[0],f[1]];break;case"m":T=u>0,f=s.calc(c[1],c[2],T),v=["m",f[0],f[1]];break;default:for(x=c[0],v=[x],T=x.toLowerCase()===x,l=1;l<c.length;l+=2)f=s.calc(c[l],c[l+1],T),v.push(f[0],f[1])}r.segments[u]=v},!0)},a.prototype.__evaluateStack=function(){var s,r;if(this.__stack.length){if(this.__stack.length===1){this.__matrix(this.__stack[0]),this.__stack=[];return}for(s=t(),r=this.__stack.length;--r>=0;)s.matrix(this.__stack[r].toArray());this.__matrix(s),this.__stack=[]}},a.prototype.toString=function(){var s="",r="",l=!1;this.__evaluateStack();for(var c=0,u=this.segments.length;c<u;c++){var g=this.segments[c],h=g[0];h!==r||h==="m"||h==="M"?(h==="m"&&r==="z"&&(s+=" "),s+=h,l=!1):l=!0;for(var f=1;f<g.length;f++){var v=g[f];f===1?l&&v>=0&&(s+=" "):v>=0&&(s+=" "),s+=v}r=h}return s},a.prototype.translate=function(s,r){return this.__stack.push(t().translate(s,r||0)),this},a.prototype.scale=function(s,r){return this.__stack.push(t().scale(s,!r&&r!==0?s:r)),this},a.prototype.rotate=function(s,r,l){return this.__stack.push(t().rotate(s,r||0,l||0)),this},a.prototype.skewX=function(s){return this.__stack.push(t().skewX(s)),this},a.prototype.skewY=function(s){return this.__stack.push(t().skewY(s)),this},a.prototype.matrix=function(s){return this.__stack.push(t().matrix(s)),this},a.prototype.transform=function(s){return s.trim()?(this.__stack.push(e(s)),this):this},a.prototype.round=function(s){var r=0,l=0,c=0,u=0,g;return s=s||0,this.__evaluateStack(),this.segments.forEach(function(h){var f=h[0].toLowerCase()===h[0];switch(h[0]){case"H":case"h":f&&(h[1]+=c),c=h[1]-h[1].toFixed(s),h[1]=+h[1].toFixed(s);return;case"V":case"v":f&&(h[1]+=u),u=h[1]-h[1].toFixed(s),h[1]=+h[1].toFixed(s);return;case"Z":case"z":c=r,u=l;return;case"M":case"m":f&&(h[1]+=c,h[2]+=u),c=h[1]-h[1].toFixed(s),u=h[2]-h[2].toFixed(s),r=c,l=u,h[1]=+h[1].toFixed(s),h[2]=+h[2].toFixed(s);return;case"A":case"a":f&&(h[6]+=c,h[7]+=u),c=h[6]-h[6].toFixed(s),u=h[7]-h[7].toFixed(s),h[1]=+h[1].toFixed(s),h[2]=+h[2].toFixed(s),h[3]=+h[3].toFixed(s+2),h[6]=+h[6].toFixed(s),h[7]=+h[7].toFixed(s);return;default:g=h.length,f&&(h[g-2]+=c,h[g-1]+=u),c=h[g-2]-h[g-2].toFixed(s),u=h[g-1]-h[g-1].toFixed(s),h.forEach(function(v,x){x&&(h[x]=+h[x].toFixed(s))});return}}),this},a.prototype.iterate=function(s,r){var l=this.segments,c={},u=!1,g=0,h=0,f=0,v=0,x,T,L;if(r||this.__evaluateStack(),l.forEach(function(P,S){var E=s(P,S,g,h);Array.isArray(E)&&(c[S]=E,u=!0);var M=P[0]===P[0].toLowerCase();switch(P[0]){case"m":case"M":g=P[1]+(M?g:0),h=P[2]+(M?h:0),f=g,v=h;return;case"h":case"H":g=P[1]+(M?g:0);return;case"v":case"V":h=P[1]+(M?h:0);return;case"z":case"Z":g=f,h=v;return;default:g=P[P.length-2]+(M?g:0),h=P[P.length-1]+(M?h:0)}}),!u)return this;for(L=[],x=0;x<l.length;x++)if(typeof c[x]<"u")for(T=0;T<c[x].length;T++)L.push(c[x][T]);else L.push(l[x]);return this.segments=L,this},a.prototype.abs=function(){return this.iterate(function(s,r,l,c){var u=s[0],g=u.toUpperCase(),h;if(u!==g)switch(s[0]=g,u){case"v":s[1]+=c;return;case"a":s[6]+=l,s[7]+=c;return;default:for(h=1;h<s.length;h++)s[h]+=h%2?l:c}},!0),this},a.prototype.rel=function(){return this.iterate(function(s,r,l,c){var u=s[0],g=u.toLowerCase(),h;if(u!==g&&!(r===0&&u==="M"))switch(s[0]=g,u){case"V":s[1]-=c;return;case"A":s[6]-=l,s[7]-=c;return;default:for(h=1;h<s.length;h++)s[h]-=h%2?l:c}},!0),this},a.prototype.unarc=function(){return this.iterate(function(s,r,l,c){var u,g,h,f=[],v=s[0];return v!=="A"&&v!=="a"?null:(v==="a"?(g=l+s[6],h=c+s[7]):(g=s[6],h=s[7]),u=o(l,c,g,h,s[4],s[5],s[1],s[2],s[3]),u.length===0?[[s[0]==="a"?"l":"L",s[6],s[7]]]:(u.forEach(function(x){f.push(["C",x[2],x[3],x[4],x[5],x[6],x[7]])}),f))}),this},a.prototype.unshort=function(){var s=this.segments,r,l,c,u,g;return this.iterate(function(h,f,v,x){var T=h[0],L=T.toUpperCase(),P;f&&(L==="T"?(P=T==="t",c=s[f-1],c[0]==="Q"?(r=c[1]-v,l=c[2]-x):c[0]==="q"?(r=c[1]-c[3],l=c[2]-c[4]):(r=0,l=0),u=-r,g=-l,P||(u+=v,g+=x),s[f]=[P?"q":"Q",u,g,h[1],h[2]]):L==="S"&&(P=T==="s",c=s[f-1],c[0]==="C"?(r=c[3]-v,l=c[4]-x):c[0]==="c"?(r=c[3]-c[5],l=c[4]-c[6]):(r=0,l=0),u=-r,g=-l,P||(u+=v,g+=x),s[f]=[P?"c":"C",u,g,h[1],h[2],h[3],h[4]]))}),this},de=a,de}var ge,w0;function K1(){return w0||(w0=1,ge=X1()),ge}var Z1=K1();const J1=U1(Z1);var pe={a:7,c:6,h:1,l:2,m:2,q:4,s:4,t:2,v:1,z:0},Q1=/([astvzqmhlc])([^astvzqmhlc]*)/ig;function ti(n){var e=[];return n.replace(Q1,function(t,o,i){var a=o.toLowerCase();for(i=ni(i),a==="m"&&i.length>2&&(e.push([o].concat(i.splice(0,2))),a="l",o=o==="m"?"l":"L");i.length>=0;){if(i.length===pe[a])return i.unshift(o),e.push(i);if(i.length<pe[a])throw new Error("malformed path data");e.push([o].concat(i.splice(0,pe[a])))}}),e}var ei=/-?[0-9]*\.?[0-9]+(?:e[-+]?\d+)?/ig;function ni(n){var e=n.match(ei);return e?e.map(Number):[]}function at(n,e,t,o,i,a,s,r){return new ye(n,e,t,o,i,a,s,r)}function ye(n,e,t,o,i,a,s,r){this.a={x:n,y:e},this.b={x:t,y:o},this.c={x:i,y:a},this.d={x:s,y:r},s!=null&&r!==null&&r!==void 0?(this.getArcLength=fi,this.getPoint=oi,this.getDerivative=ri):(this.getArcLength=si,this.getPoint=m0,this.getDerivative=ii),this.init()}ye.prototype={constructor:ye,init:function(){this.length=this.getArcLength([this.a.x,this.b.x,this.c.x,this.d.x],[this.a.y,this.b.y,this.c.y,this.d.y])},getTotalLength:function(){return this.length},getPointAtLength:function(n){var e=xe(n,this.length,this.getArcLength,[this.a.x,this.b.x,this.c.x,this.d.x],[this.a.y,this.b.y,this.c.y,this.d.y]);return this.getPoint([this.a.x,this.b.x,this.c.x,this.d.x],[this.a.y,this.b.y,this.c.y,this.d.y],e)},getTangentAtLength:function(n){var e=xe(n,this.length,this.getArcLength,[this.a.x,this.b.x,this.c.x,this.d.x],[this.a.y,this.b.y,this.c.y,this.d.y]),t=this.getDerivative([this.a.x,this.b.x,this.c.x,this.d.x],[this.a.y,this.b.y,this.c.y,this.d.y],e),o=Math.sqrt(t.x*t.x+t.y*t.y),i;return o>0?i={x:t.x/o,y:t.y/o}:i={x:0,y:0},i},getPropertiesAtLength:function(n){var e=xe(n,this.length,this.getArcLength,[this.a.x,this.b.x,this.c.x,this.d.x],[this.a.y,this.b.y,this.c.y,this.d.y]),t=this.getDerivative([this.a.x,this.b.x,this.c.x,this.d.x],[this.a.y,this.b.y,this.c.y,this.d.y],e),o=Math.sqrt(t.x*t.x+t.y*t.y),i;o>0?i={x:t.x/o,y:t.y/o}:i={x:0,y:0};var a=this.getPoint([this.a.x,this.b.x,this.c.x,this.d.x],[this.a.y,this.b.y,this.c.y,this.d.y],e);return{x:a.x,y:a.y,tangentX:i.x,tangentY:i.y}}};function ii(n,e,t){return{x:(1-t)*2*(n[1]-n[0])+t*2*(n[2]-n[1]),y:(1-t)*2*(e[1]-e[0])+t*2*(e[2]-e[1])}}function ri(n,e,t){var o=m0([3*(n[1]-n[0]),3*(n[2]-n[1]),3*(n[3]-n[2])],[3*(e[1]-e[0]),3*(e[2]-e[1]),3*(e[3]-e[2])],t);return o}function xe(n,e,t,o,i){for(var a=1,s=n/e,r=(n-t(o,i,s))/e;a>.001;){var l=t(o,i,s+r),c=t(o,i,s-r),u=Math.abs(n-l)/e,g=Math.abs(n-c)/e;u<a?(a=u,s+=r):g<a?(a=g,s-=r):r/=2}return s}function m0(n,e,t){var o=(1-t)*(1-t)*n[0]+2*(1-t)*t*n[1]+t*t*n[2],i=(1-t)*(1-t)*e[0]+2*(1-t)*t*e[1]+t*t*e[2];return{x:o,y:i}}function oi(n,e,t){var o=(1-t)*(1-t)*(1-t)*n[0]+3*(1-t)*(1-t)*t*n[1]+3*(1-t)*t*t*n[2]+t*t*t*n[3],i=(1-t)*(1-t)*(1-t)*e[0]+3*(1-t)*(1-t)*t*e[1]+3*(1-t)*t*t*e[2]+t*t*t*e[3];return{x:o,y:i}}function si(n,e,t){t===void 0&&(t=1);var o=n[0]-2*n[1]+n[2],i=e[0]-2*e[1]+e[2],a=2*n[1]-2*n[0],s=2*e[1]-2*e[0],r=4*(o*o+i*i),l=4*(o*a+i*s),c=a*a+s*s;if(r===0)return t*Math.sqrt(Math.pow(n[2]-n[0],2)+Math.pow(e[2]-e[0],2));var u=l/(2*r),g=c/r,h=t+u,f=g-u*u;return Math.sqrt(r)/2*(h*Math.sqrt(h*h+f)-u*Math.sqrt(u*u+f)+f*Math.log(Math.abs((h+Math.sqrt(h*h+f))/(u+Math.sqrt(u*u+f)))))}var ai=[[],[],[-.5773502691896257,.5773502691896257],[0,-.7745966692414834,.7745966692414834],[-.33998104358485626,.33998104358485626,-.8611363115940526,.8611363115940526],[0,-.5384693101056831,.5384693101056831,-.906179845938664,.906179845938664],[.6612093864662645,-.6612093864662645,-.2386191860831969,.2386191860831969,-.932469514203152,.932469514203152],[0,.4058451513773972,-.4058451513773972,-.7415311855993945,.7415311855993945,-.9491079123427585,.9491079123427585],[-.1834346424956498,.1834346424956498,-.525532409916329,.525532409916329,-.7966664774136267,.7966664774136267,-.9602898564975363,.9602898564975363],[0,-.8360311073266358,.8360311073266358,-.9681602395076261,.9681602395076261,-.3242534234038089,.3242534234038089,-.6133714327005904,.6133714327005904],[-.14887433898163122,.14887433898163122,-.4333953941292472,.4333953941292472,-.6794095682990244,.6794095682990244,-.8650633666889845,.8650633666889845,-.9739065285171717,.9739065285171717],[0,-.26954315595234496,.26954315595234496,-.5190961292068118,.5190961292068118,-.7301520055740494,.7301520055740494,-.8870625997680953,.8870625997680953,-.978228658146057,.978228658146057],[-.1252334085114689,.1252334085114689,-.3678314989981802,.3678314989981802,-.5873179542866175,.5873179542866175,-.7699026741943047,.7699026741943047,-.9041172563704749,.9041172563704749,-.9815606342467192,.9815606342467192],[0,-.2304583159551348,.2304583159551348,-.44849275103644687,.44849275103644687,-.6423493394403402,.6423493394403402,-.8015780907333099,.8015780907333099,-.9175983992229779,.9175983992229779,-.9841830547185881,.9841830547185881],[-.10805494870734367,.10805494870734367,-.31911236892788974,.31911236892788974,-.5152486363581541,.5152486363581541,-.6872929048116855,.6872929048116855,-.827201315069765,.827201315069765,-.9284348836635735,.9284348836635735,-.9862838086968123,.9862838086968123],[0,-.20119409399743451,.20119409399743451,-.3941513470775634,.3941513470775634,-.5709721726085388,.5709721726085388,-.7244177313601701,.7244177313601701,-.8482065834104272,.8482065834104272,-.937273392400706,.937273392400706,-.9879925180204854,.9879925180204854],[-.09501250983763744,.09501250983763744,-.2816035507792589,.2816035507792589,-.45801677765722737,.45801677765722737,-.6178762444026438,.6178762444026438,-.755404408355003,.755404408355003,-.8656312023878318,.8656312023878318,-.9445750230732326,.9445750230732326,-.9894009349916499,.9894009349916499],[0,-.17848418149584785,.17848418149584785,-.3512317634538763,.3512317634538763,-.5126905370864769,.5126905370864769,-.6576711592166907,.6576711592166907,-.7815140038968014,.7815140038968014,-.8802391537269859,.8802391537269859,-.9506755217687678,.9506755217687678,-.9905754753144174,.9905754753144174],[-.0847750130417353,.0847750130417353,-.2518862256915055,.2518862256915055,-.41175116146284263,.41175116146284263,-.5597708310739475,.5597708310739475,-.6916870430603532,.6916870430603532,-.8037049589725231,.8037049589725231,-.8926024664975557,.8926024664975557,-.9558239495713977,.9558239495713977,-.9915651684209309,.9915651684209309],[0,-.16035864564022537,.16035864564022537,-.31656409996362983,.31656409996362983,-.46457074137596094,.46457074137596094,-.600545304661681,.600545304661681,-.7209661773352294,.7209661773352294,-.8227146565371428,.8227146565371428,-.9031559036148179,.9031559036148179,-.96020815213483,.96020815213483,-.9924068438435844,.9924068438435844],[-.07652652113349734,.07652652113349734,-.22778585114164507,.22778585114164507,-.37370608871541955,.37370608871541955,-.5108670019508271,.5108670019508271,-.636053680726515,.636053680726515,-.7463319064601508,.7463319064601508,-.8391169718222188,.8391169718222188,-.912234428251326,.912234428251326,-.9639719272779138,.9639719272779138,-.9931285991850949,.9931285991850949],[0,-.1455618541608951,.1455618541608951,-.2880213168024011,.2880213168024011,-.4243421202074388,.4243421202074388,-.5516188358872198,.5516188358872198,-.6671388041974123,.6671388041974123,-.7684399634756779,.7684399634756779,-.8533633645833173,.8533633645833173,-.9200993341504008,.9200993341504008,-.9672268385663063,.9672268385663063,-.9937521706203895,.9937521706203895],[-.06973927331972223,.06973927331972223,-.20786042668822127,.20786042668822127,-.34193582089208424,.34193582089208424,-.469355837986757,.469355837986757,-.5876404035069116,.5876404035069116,-.6944872631866827,.6944872631866827,-.7878168059792081,.7878168059792081,-.8658125777203002,.8658125777203002,-.926956772187174,.926956772187174,-.9700604978354287,.9700604978354287,-.9942945854823992,.9942945854823992],[0,-.1332568242984661,.1332568242984661,-.26413568097034495,.26413568097034495,-.3903010380302908,.3903010380302908,-.5095014778460075,.5095014778460075,-.6196098757636461,.6196098757636461,-.7186613631319502,.7186613631319502,-.8048884016188399,.8048884016188399,-.8767523582704416,.8767523582704416,-.9329710868260161,.9329710868260161,-.9725424712181152,.9725424712181152,-.9947693349975522,.9947693349975522],[-.06405689286260563,.06405689286260563,-.1911188674736163,.1911188674736163,-.3150426796961634,.3150426796961634,-.4337935076260451,.4337935076260451,-.5454214713888396,.5454214713888396,-.6480936519369755,.6480936519369755,-.7401241915785544,.7401241915785544,-.820001985973903,.820001985973903,-.8864155270044011,.8864155270044011,-.9382745520027328,.9382745520027328,-.9747285559713095,.9747285559713095,-.9951872199970213,.9951872199970213]],li=[[],[],[1,1],[.8888888888888888,.5555555555555556,.5555555555555556],[.6521451548625461,.6521451548625461,.34785484513745385,.34785484513745385],[.5688888888888889,.47862867049936647,.47862867049936647,.23692688505618908,.23692688505618908],[.3607615730481386,.3607615730481386,.46791393457269104,.46791393457269104,.17132449237917036,.17132449237917036],[.4179591836734694,.3818300505051189,.3818300505051189,.27970539148927664,.27970539148927664,.1294849661688697,.1294849661688697],[.362683783378362,.362683783378362,.31370664587788727,.31370664587788727,.22238103445337448,.22238103445337448,.10122853629037626,.10122853629037626],[.3302393550012598,.1806481606948574,.1806481606948574,.08127438836157441,.08127438836157441,.31234707704000286,.31234707704000286,.26061069640293544,.26061069640293544],[.29552422471475287,.29552422471475287,.26926671930999635,.26926671930999635,.21908636251598204,.21908636251598204,.1494513491505806,.1494513491505806,.06667134430868814,.06667134430868814],[.2729250867779006,.26280454451024665,.26280454451024665,.23319376459199048,.23319376459199048,.18629021092773426,.18629021092773426,.1255803694649046,.1255803694649046,.05566856711617366,.05566856711617366],[.24914704581340277,.24914704581340277,.2334925365383548,.2334925365383548,.20316742672306592,.20316742672306592,.16007832854334622,.16007832854334622,.10693932599531843,.10693932599531843,.04717533638651183,.04717533638651183],[.2325515532308739,.22628318026289723,.22628318026289723,.2078160475368885,.2078160475368885,.17814598076194574,.17814598076194574,.13887351021978725,.13887351021978725,.09212149983772845,.09212149983772845,.04048400476531588,.04048400476531588],[.2152638534631578,.2152638534631578,.2051984637212956,.2051984637212956,.18553839747793782,.18553839747793782,.15720316715819355,.15720316715819355,.12151857068790319,.12151857068790319,.08015808715976021,.08015808715976021,.03511946033175186,.03511946033175186],[.2025782419255613,.19843148532711158,.19843148532711158,.1861610000155622,.1861610000155622,.16626920581699392,.16626920581699392,.13957067792615432,.13957067792615432,.10715922046717194,.10715922046717194,.07036604748810812,.07036604748810812,.03075324199611727,.03075324199611727],[.1894506104550685,.1894506104550685,.18260341504492358,.18260341504492358,.16915651939500254,.16915651939500254,.14959598881657674,.14959598881657674,.12462897125553388,.12462897125553388,.09515851168249279,.09515851168249279,.062253523938647894,.062253523938647894,.027152459411754096,.027152459411754096],[.17944647035620653,.17656270536699264,.17656270536699264,.16800410215645004,.16800410215645004,.15404576107681028,.15404576107681028,.13513636846852548,.13513636846852548,.11188384719340397,.11188384719340397,.08503614831717918,.08503614831717918,.0554595293739872,.0554595293739872,.02414830286854793,.02414830286854793],[.1691423829631436,.1691423829631436,.16427648374583273,.16427648374583273,.15468467512626524,.15468467512626524,.14064291467065065,.14064291467065065,.12255520671147846,.12255520671147846,.10094204410628717,.10094204410628717,.07642573025488905,.07642573025488905,.0497145488949698,.0497145488949698,.02161601352648331,.02161601352648331],[.1610544498487837,.15896884339395434,.15896884339395434,.15276604206585967,.15276604206585967,.1426067021736066,.1426067021736066,.12875396253933621,.12875396253933621,.11156664554733399,.11156664554733399,.09149002162245,.09149002162245,.06904454273764123,.06904454273764123,.0448142267656996,.0448142267656996,.019461788229726478,.019461788229726478],[.15275338713072584,.15275338713072584,.14917298647260374,.14917298647260374,.14209610931838204,.14209610931838204,.13168863844917664,.13168863844917664,.11819453196151841,.11819453196151841,.10193011981724044,.10193011981724044,.08327674157670475,.08327674157670475,.06267204833410907,.06267204833410907,.04060142980038694,.04060142980038694,.017614007139152118,.017614007139152118],[.14608113364969041,.14452440398997005,.14452440398997005,.13988739479107315,.13988739479107315,.13226893863333747,.13226893863333747,.12183141605372853,.12183141605372853,.10879729916714838,.10879729916714838,.09344442345603386,.09344442345603386,.0761001136283793,.0761001136283793,.057134425426857205,.057134425426857205,.036953789770852494,.036953789770852494,.016017228257774335,.016017228257774335],[.13925187285563198,.13925187285563198,.13654149834601517,.13654149834601517,.13117350478706238,.13117350478706238,.12325237681051242,.12325237681051242,.11293229608053922,.11293229608053922,.10041414444288096,.10041414444288096,.08594160621706773,.08594160621706773,.06979646842452049,.06979646842452049,.052293335152683286,.052293335152683286,.03377490158481415,.03377490158481415,.0146279952982722,.0146279952982722],[.13365457218610619,.1324620394046966,.1324620394046966,.12890572218808216,.12890572218808216,.12304908430672953,.12304908430672953,.11499664022241136,.11499664022241136,.10489209146454141,.10489209146454141,.09291576606003515,.09291576606003515,.07928141177671895,.07928141177671895,.06423242140852585,.06423242140852585,.04803767173108467,.04803767173108467,.030988005856979445,.030988005856979445,.013411859487141771,.013411859487141771],[.12793819534675216,.12793819534675216,.1258374563468283,.1258374563468283,.12167047292780339,.12167047292780339,.1155056680537256,.1155056680537256,.10744427011596563,.10744427011596563,.09761865210411388,.09761865210411388,.08619016153195327,.08619016153195327,.0733464814110803,.0733464814110803,.05929858491543678,.05929858491543678,.04427743881741981,.04427743881741981,.028531388628933663,.028531388628933663,.0123412297999872,.0123412297999872]],hi=[[1],[1,1],[1,2,1],[1,3,3,1]];function ci(n,e){return hi[n][e]}function ve(n,e,t){var o=t.length-1,i,a,s;if(o===0)return 0;if(n===0){for(a=0,s=0;s<=o;s++)a+=ci(o,s)*Math.pow(1-e,o-s)*Math.pow(e,s)*t[s];return a}else{for(i=new Array(o),s=0;s<o;s++)i[s]=o*(t[s+1]-t[s]);return ve(n-1,e,i)}}function ui(n,e,t){var o=ve(1,t,n),i=ve(1,t,e),a=o*o+i*i;return Math.sqrt(a)}function fi(n,e,t){var o,i,a,s;t===void 0&&(t=1);var r=20;for(o=t/2,i=0,a=0;a<r;a++)s=o*ai[r][a]+o,i+=li[r][a]*ui(n,e,s);return o*i}var Ot=Math.PI*2;function b0(n,e,t,o){var i=n*o-e*t<0?-1:1,a=n*t+e*o;return a>1&&(a=1),a<-1&&(a=-1),i*Math.acos(a)}function di(n,e,t,o,i,a,s,r,l,c){var u=c*(n-t)/2+l*(e-o)/2,g=-l*(n-t)/2+c*(e-o)/2,h=s*s,f=r*r,v=u*u,x=g*g,T=h*f-h*x-f*v;T<0&&(T=0),T/=h*x+f*v,T=Math.sqrt(T)*(i===a?-1:1);var L=T*s/r*g,P=T*-r/s*u,S=c*L-l*P+(n+t)/2,E=l*L+c*P+(e+o)/2,M=(u-L)/s,k=(g-P)/r,B=(-u-L)/s,X=(-g-P)/r,j=b0(1,0,M,k),W=b0(M,k,B,X);return a===0&&W>0&&(W-=Ot),a===1&&W<0&&(W+=Ot),[S,E,j,W]}function gi(n,e){var t=1.3333333333333333*Math.tan(e/4),o=Math.cos(n),i=Math.sin(n),a=Math.cos(n+e),s=Math.sin(n+e);return[o,i,o-i*t,i+o*t,a+s*t,s-a*t,a,s]}function pi(n,e,t,o,i,a,s,r,l){var c=Math.sin(i*Ot/360),u=Math.cos(i*Ot/360),g=u*(n-r)/2+c*(e-l)/2,h=-c*(n-r)/2+u*(e-l)/2;if(g===0&&h===0)return[];if(t===0||o===0)return[];t=Math.abs(t),o=Math.abs(o);var f=g*g/(t*t)+h*h/(o*o);f>1&&(t*=Math.sqrt(f),o*=Math.sqrt(f));var v=di(n,e,r,l,a,s,t,o,c,u),x=[],T=v[2],L=v[3],P=Math.max(Math.ceil(Math.abs(L)/(Ot/4)),1);L/=P;for(var S=0;S<P;S++)x.push(gi(T,L)),T+=L;return x.map(function(E){for(var M=0;M<E.length;M+=2){var k=E[M+0],B=E[M+1];k*=t,B*=o;var X=u*k-c*B,j=c*k+u*B;E[M+0]=X+v[0],E[M+1]=j+v[1]}return E})}function A0(n,e,t,o,i,a,s,r,l){return new we(n,e,t,o,i,a,s,r,l)}function we(n,e,t,o,i,a,s,r,l){var c=0,u=[],g=[],h=pi(n,e,t,o,i,a,s,r,l);h.forEach(function(f){var v=new at(f[0],f[1],f[2],f[3],f[4],f[5],f[6],f[7]),x=v.getTotalLength();c+=x,u.push(x),g.push(v)}),this.length=c,this.partialLengths=u,this.curves=g}we.prototype={constructor:we,init:function(){},getTotalLength:function(){return this.length},getPointAtLength:function(n){n<0?n=0:n>this.length&&(n=this.length);for(var e=this.partialLengths.length-1;this.partialLengths[e]>=n&&this.partialLengths[e]>0;)e--;e<this.partialLengths.length-1&&e++;for(var t=0,o=0;o<e;o++)t+=this.partialLengths[o];return this.curves[e].getPointAtLength(n-t)},getTangentAtLength:function(n){n<0?n=0:n>this.length&&(n=this.length);for(var e=this.partialLengths.length-1;this.partialLengths[e]>=n&&this.partialLengths[e]>0;)e--;e<this.partialLengths.length-1&&e++;for(var t=0,o=0;o<e;o++)t+=this.partialLengths[o];return this.curves[e].getTangentAtLength(n-t)},getPropertiesAtLength:function(n){var e=this.getTangentAtLength(n),t=this.getPointAtLength(n);return{x:t.x,y:t.y,tangentX:e.x,tangentY:e.y}}};function lt(n,e,t,o){return new _t(n,e,t,o)}function _t(n,e,t,o){this.x0=n,this.x1=e,this.y0=t,this.y1=o}_t.prototype.getTotalLength=function(){return Math.sqrt(Math.pow(this.x0-this.x1,2)+Math.pow(this.y0-this.y1,2))},_t.prototype.getPointAtLength=function(n){var e=n/Math.sqrt(Math.pow(this.x0-this.x1,2)+Math.pow(this.y0-this.y1,2)),t=(this.x1-this.x0)*e,o=(this.y1-this.y0)*e;return{x:this.x0+t,y:this.y0+o}},_t.prototype.getTangentAtLength=function(){var n=Math.sqrt((this.x1-this.x0)*(this.x1-this.x0)+(this.y1-this.y0)*(this.y1-this.y0));return{x:(this.x1-this.x0)/n,y:(this.y1-this.y0)/n}},_t.prototype.getPropertiesAtLength=function(n){var e=this.getPointAtLength(n),t=this.getTangentAtLength();return{x:e.x,y:e.y,tangentX:t.x,tangentY:t.y}};function yi(n){var e=0,t=[],o=[];function i(s){if(!s)return null;for(var r=ti(s),l=[0,0],c=[0,0],u,g,h=0;h<r.length;h++)r[h][0]==="M"?(l=[r[h][1],r[h][2]],g=[l[0],l[1]],o.push(null)):r[h][0]==="m"?(l=[r[h][1]+l[0],r[h][2]+l[1]],g=[l[0],l[1]],o.push(null)):r[h][0]==="L"?(e=e+Math.sqrt(Math.pow(l[0]-r[h][1],2)+Math.pow(l[1]-r[h][2],2)),o.push(new lt(l[0],r[h][1],l[1],r[h][2])),l=[r[h][1],r[h][2]]):r[h][0]==="l"?(e=e+Math.sqrt(Math.pow(r[h][1],2)+Math.pow(r[h][2],2)),o.push(new lt(l[0],r[h][1]+l[0],l[1],r[h][2]+l[1])),l=[r[h][1]+l[0],r[h][2]+l[1]]):r[h][0]==="H"?(e=e+Math.abs(l[0]-r[h][1]),o.push(new lt(l[0],r[h][1],l[1],l[1])),l[0]=r[h][1]):r[h][0]==="h"?(e=e+Math.abs(r[h][1]),o.push(new lt(l[0],l[0]+r[h][1],l[1],l[1])),l[0]=r[h][1]+l[0]):r[h][0]==="V"?(e=e+Math.abs(l[1]-r[h][1]),o.push(new lt(l[0],l[0],l[1],r[h][1])),l[1]=r[h][1]):r[h][0]==="v"?(e=e+Math.abs(r[h][1]),o.push(new lt(l[0],l[0],l[1],l[1]+r[h][1])),l[1]=r[h][1]+l[1]):r[h][0]==="z"||r[h][0]==="Z"?(e=e+Math.sqrt(Math.pow(g[0]-l[0],2)+Math.pow(g[1]-l[1],2)),o.push(new lt(l[0],g[0],l[1],g[1])),l=[g[0],g[1]]):r[h][0]==="C"?(u=new at(l[0],l[1],r[h][1],r[h][2],r[h][3],r[h][4],r[h][5],r[h][6]),e=e+u.getTotalLength(),l=[r[h][5],r[h][6]],o.push(u)):r[h][0]==="c"?(u=new at(l[0],l[1],l[0]+r[h][1],l[1]+r[h][2],l[0]+r[h][3],l[1]+r[h][4],l[0]+r[h][5],l[1]+r[h][6]),e=e+u.getTotalLength(),l=[r[h][5]+l[0],r[h][6]+l[1]],o.push(u)):r[h][0]==="S"?(h>0&&["C","c","S","s"].indexOf(r[h-1][0])>-1?u=new at(l[0],l[1],2*l[0]-r[h-1][r[h-1].length-4],2*l[1]-r[h-1][r[h-1].length-3],r[h][1],r[h][2],r[h][3],r[h][4]):u=new at(l[0],l[1],l[0],l[1],r[h][1],r[h][2],r[h][3],r[h][4]),e=e+u.getTotalLength(),l=[r[h][3],r[h][4]],o.push(u)):r[h][0]==="s"?(h>0&&["C","c","S","s"].indexOf(r[h-1][0])>-1?u=new at(l[0],l[1],l[0]+u.d.x-u.c.x,l[1]+u.d.y-u.c.y,l[0]+r[h][1],l[1]+r[h][2],l[0]+r[h][3],l[1]+r[h][4]):u=new at(l[0],l[1],l[0],l[1],l[0]+r[h][1],l[1]+r[h][2],l[0]+r[h][3],l[1]+r[h][4]),e=e+u.getTotalLength(),l=[r[h][3]+l[0],r[h][4]+l[1]],o.push(u)):r[h][0]==="Q"?(l[0]!=r[h][1]&&l[1]!=r[h][2]?u=new at(l[0],l[1],r[h][1],r[h][2],r[h][3],r[h][4]):u=new lt(r[h][1],r[h][3],r[h][2],r[h][4]),e=e+u.getTotalLength(),o.push(u),l=[r[h][3],r[h][4]],c=[r[h][1],r[h][2]]):r[h][0]==="q"?(r[h][1]==0&&r[h][2]==0?u=new lt(l[0]+r[h][1],l[0]+r[h][3],l[1]+r[h][2],l[1]+r[h][4]):u=new at(l[0],l[1],l[0]+r[h][1],l[1]+r[h][2],l[0]+r[h][3],l[1]+r[h][4]),e=e+u.getTotalLength(),c=[l[0]+r[h][1],l[1]+r[h][2]],l=[r[h][3]+l[0],r[h][4]+l[1]],o.push(u)):r[h][0]==="T"?(h>0&&["Q","q","T","t"].indexOf(r[h-1][0])>-1?u=new at(l[0],l[1],2*l[0]-c[0],2*l[1]-c[1],r[h][1],r[h][2]):u=new lt(l[0],r[h][1],l[1],r[h][2]),o.push(u),e=e+u.getTotalLength(),c=[2*l[0]-c[0],2*l[1]-c[1]],l=[r[h][1],r[h][2]]):r[h][0]==="t"?(h>0&&["Q","q","T","t"].indexOf(r[h-1][0])>-1?u=new at(l[0],l[1],2*l[0]-c[0],2*l[1]-c[1],l[0]+r[h][1],l[1]+r[h][2]):u=new lt(l[0],l[0]+r[h][1],l[1],l[1]+r[h][2]),e=e+u.getTotalLength(),c=[2*l[0]-c[0],2*l[1]-c[1]],l=[r[h][1]+l[0],r[h][2]+l[0]],o.push(u)):r[h][0]==="A"?(u=new A0(l[0],l[1],r[h][1],r[h][2],r[h][3],r[h][4],r[h][5],r[h][6],r[h][7]),e=e+u.getTotalLength(),l=[r[h][6],r[h][7]],o.push(u)):r[h][0]==="a"&&(u=new A0(l[0],l[1],r[h][1],r[h][2],r[h][3],r[h][4],r[h][5],l[0]+r[h][6],l[1]+r[h][7]),e=e+u.getTotalLength(),l=[l[0]+r[h][6],l[1]+r[h][7]],o.push(u)),t.push(e);return i}i.getTotalLength=function(){return e},i.getPointAtLength=function(s){var r=a(s);return o[r.i].getPointAtLength(r.fraction)},i.getTangentAtLength=function(s){var r=a(s);return o[r.i].getTangentAtLength(r.fraction)},i.getPropertiesAtLength=function(s){var r=a(s);return o[r.i].getPropertiesAtLength(r.fraction)};var a=function(s){s<0?s=0:s>e&&(s=e);for(var r=t.length-1;t[r]>=s&&t[r]>0;)r--;return r++,{fraction:s-t[r-1],i:r}};return i(n)}function Vt(n,e){return Math.sqrt((n[0]-e[0])*(n[0]-e[0])+(n[1]-e[1])*(n[1]-e[1]))}function T0(n,e,t){return[n[0]+(e[0]-n[0])*t,n[1]+(e[1]-n[1])*t]}function xi(n,e){return Vt(n,e)<1e-9}function vi(n,e,t){let o=n.map((i,a)=>wi(i,e[a]));return function(i){let a=o.map(s=>s(i));return t?Ai(a):a}}function wi(n,e){return function(t){return n.map((o,i)=>o+t*(e[i]-o))}}function jt(n){return typeof n=="number"&&isFinite(n)}const me=`All shapes must be supplied as arrays of [x, y] points or an SVG path string (https://developer.mozilla.org/en-US/docs/Web/SVG/Attribute/d).
|
|
2
2
|
Example valid ways of supplying a shape would be:
|
|
3
3
|
[[0, 0], [10, 0], [10, 10]]
|
|
4
4
|
"M0,0 L10,0 L10,10Z"
|
|
5
|
-
`;function Un(n){return new bn(n).abs()}function $n(n){return n.toString().split("M").map((e,t)=>(e=e.trim(),t&&e?"M"+e:e)).filter(e=>e)}function Wn(n){return"M"+n.join("L")+"Z"}function Yn(n,e){let t=Un(n);return Gn(t)||Xn(t,e)}function Gn(n){let e=n.segments||[],t=[];if(!e.length||e[0][0]!=="M")return!1;for(let o=0;o<e.length;o++){let[i,a,s]=e[o];if(i==="M"&&o||i==="Z")break;if(i==="M"||i==="L")t.push([a,s]);else if(i==="H")t.push([a,t[t.length-1][1]]);else if(i==="V")t.push([t[t.length-1][0],a]);else return!1}return t.length?{ring:t}:!1}function Xn(n,e){let t=$n(n)[0],o=[],i,a,s=3;if(!t)throw new TypeError(xe);a=Kn(t),i=a.getTotalLength(),e&&zt(e)&&e>0&&(s=Math.max(s,Math.ceil(i/e)));for(let r=0;r<s;r++){let h=a.getPointAtLength(i*r/s);o.push([h.x,h.y])}return{ring:o,skipBisect:!0}}function Kn(n){if(typeof window<"u"&&window&&window.document)try{let e=window.document.createElementNS("http://www.w3.org/2000/svg","path");return e.setAttributeNS(null,"d",n),e}catch{}return qn(n)}function f0(n,e){const t=n.length+e,o=fn(n)/e;let i=0,a=0,s=o/2;for(;n.length<t;){let r=n[i],h=n[(i+1)%n.length],c=qt(r,h);if(s<=a+c){n.splice(i+1,0,c?u0(r,h,(s-a)/c):r.slice(0)),s+=o;continue}a+=c,i++}}function Vn(n,e=1/0){for(let t=0;t<n.length;t++){let o=n[t],i=t===n.length-1?n[0]:n[t+1];for(;qt(o,i)>e;)i=u0(o,i,.5),n.splice(t+1,0,i)}}function g0(n,e){let t,o,i;if(typeof n=="string"){let a=Yn(n,e);n=a.ring,i=a.skipBisect}else if(!Array.isArray(n))throw new TypeError(xe);if(t=n.slice(0),!Zn(t))throw new TypeError(xe);return t.length>1&&zn(t[0],t[t.length-1])&&t.pop(),o=un(t),o>0&&t.reverse(),!i&&e&&zt(e)&&e>0&&Vn(t,e),t}function Zn(n){return n.every(function(e){return Array.isArray(e)&&e.length>=2&&zt(e[0])&&zt(e[1])})}function Qn(n,e){let t=n.length,o=1/0,i,a,s;for(let r=0;r<t;r++)a=0,e.forEach(function(h,c){let u=qt(n[(r+c)%t],h);a+=u*u}),a<o&&(o=a,i=r);i&&(s=n.splice(0,i),n.splice(n.length,0,...s))}function Jn(n,e,{maxSegmentLength:t=10,string:o=!0}={}){let i=g0(n,t),a=g0(e,t),s=t2(i,a,o);return!o||typeof n!="string"&&typeof e!="string"?s:r=>r<1e-4&&typeof n=="string"?n:1-r<1e-4&&typeof e=="string"?e:s(r)}function t2(n,e,t){let o;return o=n.length-e.length,f0(n,o<0?o*-1:0),f0(e,o>0?o:0),Qn(n,e),jn(n,e,t)}var jt={exports:{}},d0;function e2(){if(d0)return jt.exports;d0=1,jt.exports=n,jt.exports.default=n;function n(g,y,p){p=p||2;var w=y&&y.length,m=w?y[0]*p:g.length,b=e(g,0,m,p,!0),A=[];if(!b||b.next===b.prev)return A;var C,F,N,Y,U,D,Z;if(w&&(b=h(g,y,b,p)),g.length>80*p){C=N=g[0],F=Y=g[1];for(var $=p;$<m;$+=p)U=g[$],D=g[$+1],U<C&&(C=U),D<F&&(F=D),U>N&&(N=U),D>Y&&(Y=D);Z=Math.max(N-C,Y-F),Z=Z!==0?32767/Z:0}return o(b,A,p,C,F,Z,0),A}function e(g,y,p,w,m){var b,A;if(m===ve(g,y,p,w)>0)for(b=y;b<p;b+=w)A=ct(b,g[b],g[b+1],A);else for(b=p-w;b>=y;b-=w)A=ct(b,g[b],g[b+1],A);return A&&E(A,A.next)&&(ut(A),A=A.next),A}function t(g,y){if(!g)return g;y||(y=g);var p=g,w;do if(w=!1,!p.steiner&&(E(p,p.next)||P(p.prev,p,p.next)===0)){if(ut(p),p=y=p.prev,p===p.next)break;w=!0}else p=p.next;while(w||p!==y);return y}function o(g,y,p,w,m,b,A){if(g){!A&&b&&f(g,w,m,b);for(var C=g,F,N;g.prev!==g.next;){if(F=g.prev,N=g.next,b?a(g,w,m,b):i(g)){y.push(F.i/p|0),y.push(g.i/p|0),y.push(N.i/p|0),ut(g),g=N.next,C=N.next;continue}if(g=N,g===C){A?A===1?(g=s(t(g),y,p),o(g,y,p,w,m,b,2)):A===2&&r(g,y,p,w,m,b):o(t(g),y,p,w,m,b,1);break}}}}function i(g){var y=g.prev,p=g,w=g.next;if(P(y,p,w)>=0)return!1;for(var m=y.x,b=p.x,A=w.x,C=y.y,F=p.y,N=w.y,Y=m<b?m<A?m:A:b<A?b:A,U=C<F?C<N?C:N:F<N?F:N,D=m>b?m>A?m:A:b>A?b:A,Z=C>F?C>N?C:N:F>N?F:N,$=w.next;$!==y;){if($.x>=Y&&$.x<=D&&$.y>=U&&$.y<=Z&&T(m,C,b,F,A,N,$.x,$.y)&&P($.prev,$,$.next)>=0)return!1;$=$.next}return!0}function a(g,y,p,w){var m=g.prev,b=g,A=g.next;if(P(m,b,A)>=0)return!1;for(var C=m.x,F=b.x,N=A.x,Y=m.y,U=b.y,D=A.y,Z=C<F?C<N?C:N:F<N?F:N,$=Y<U?Y<D?Y:D:U<D?U:D,_t=C>F?C>N?C:N:F>N?F:N,Nt=Y>U?Y>D?Y:D:U>D?U:D,y0=x(Z,$,y,p,w),x0=x(_t,Nt,y,p,w),q=g.prevZ,z=g.nextZ;q&&q.z>=y0&&z&&z.z<=x0;){if(q.x>=Z&&q.x<=_t&&q.y>=$&&q.y<=Nt&&q!==m&&q!==A&&T(C,Y,F,U,N,D,q.x,q.y)&&P(q.prev,q,q.next)>=0||(q=q.prevZ,z.x>=Z&&z.x<=_t&&z.y>=$&&z.y<=Nt&&z!==m&&z!==A&&T(C,Y,F,U,N,D,z.x,z.y)&&P(z.prev,z,z.next)>=0))return!1;z=z.nextZ}for(;q&&q.z>=y0;){if(q.x>=Z&&q.x<=_t&&q.y>=$&&q.y<=Nt&&q!==m&&q!==A&&T(C,Y,F,U,N,D,q.x,q.y)&&P(q.prev,q,q.next)>=0)return!1;q=q.prevZ}for(;z&&z.z<=x0;){if(z.x>=Z&&z.x<=_t&&z.y>=$&&z.y<=Nt&&z!==m&&z!==A&&T(C,Y,F,U,N,D,z.x,z.y)&&P(z.prev,z,z.next)>=0)return!1;z=z.nextZ}return!0}function s(g,y,p){var w=g;do{var m=w.prev,b=w.next.next;!E(m,b)&&L(m,w,w.next,b)&&j(m,b)&&j(b,m)&&(y.push(m.i/p|0),y.push(w.i/p|0),y.push(b.i/p|0),ut(w),ut(w.next),w=g=b),w=w.next}while(w!==g);return t(w)}function r(g,y,p,w,m,b){var A=g;do{for(var C=A.next.next;C!==A.prev;){if(A.i!==C.i&&S(A,C)){var F=lt(A,C);A=t(A,A.next),F=t(F,F.next),o(A,y,p,w,m,b,0),o(F,y,p,w,m,b,0);return}C=C.next}A=A.next}while(A!==g)}function h(g,y,p,w){var m=[],b,A,C,F,N;for(b=0,A=y.length;b<A;b++)C=y[b]*w,F=b<A-1?y[b+1]*w:g.length,N=e(g,C,F,w,!1),N===N.next&&(N.steiner=!0),m.push(M(N));for(m.sort(c),b=0;b<m.length;b++)p=u(m[b],p);return p}function c(g,y){return g.x-y.x}function u(g,y){var p=d(g,y);if(!p)return y;var w=lt(p,g);return t(w,w.next),t(p,p.next)}function d(g,y){var p=y,w=g.x,m=g.y,b=-1/0,A;do{if(m<=p.y&&m>=p.next.y&&p.next.y!==p.y){var C=p.x+(m-p.y)*(p.next.x-p.x)/(p.next.y-p.y);if(C<=w&&C>b&&(b=C,A=p.x<p.next.x?p:p.next,C===w))return A}p=p.next}while(p!==y);if(!A)return null;var F=A,N=A.x,Y=A.y,U=1/0,D;p=A;do w>=p.x&&p.x>=N&&w!==p.x&&T(m<Y?w:b,m,N,Y,m<Y?b:w,m,p.x,p.y)&&(D=Math.abs(m-p.y)/(w-p.x),j(p,g)&&(D<U||D===U&&(p.x>A.x||p.x===A.x&&l(A,p)))&&(A=p,U=D)),p=p.next;while(p!==F);return A}function l(g,y){return P(g.prev,g,y.prev)<0&&P(y.next,g,g.next)<0}function f(g,y,p,w){var m=g;do m.z===0&&(m.z=x(m.x,m.y,y,p,w)),m.prevZ=m.prev,m.nextZ=m.next,m=m.next;while(m!==g);m.prevZ.nextZ=null,m.prevZ=null,v(m)}function v(g){var y,p,w,m,b,A,C,F,N=1;do{for(p=g,g=null,b=null,A=0;p;){for(A++,w=p,C=0,y=0;y<N&&(C++,w=w.nextZ,!!w);y++);for(F=N;C>0||F>0&&w;)C!==0&&(F===0||!w||p.z<=w.z)?(m=p,p=p.nextZ,C--):(m=w,w=w.nextZ,F--),b?b.nextZ=m:g=m,m.prevZ=b,b=m;p=w}b.nextZ=null,N*=2}while(A>1);return g}function x(g,y,p,w,m){return g=(g-p)*m|0,y=(y-w)*m|0,g=(g|g<<8)&16711935,g=(g|g<<4)&252645135,g=(g|g<<2)&858993459,g=(g|g<<1)&1431655765,y=(y|y<<8)&16711935,y=(y|y<<4)&252645135,y=(y|y<<2)&858993459,y=(y|y<<1)&1431655765,g|y<<1}function M(g){var y=g,p=g;do(y.x<p.x||y.x===p.x&&y.y<p.y)&&(p=y),y=y.next;while(y!==g);return p}function T(g,y,p,w,m,b,A,C){return(m-A)*(y-C)>=(g-A)*(b-C)&&(g-A)*(w-C)>=(p-A)*(y-C)&&(p-A)*(b-C)>=(m-A)*(w-C)}function S(g,y){return g.next.i!==y.i&&g.prev.i!==y.i&&!K(g,y)&&(j(g,y)&&j(y,g)&&W(g,y)&&(P(g.prev,g,y.prev)||P(g,y.prev,y))||E(g,y)&&P(g.prev,g,g.next)>0&&P(y.prev,y,y.next)>0)}function P(g,y,p){return(y.y-g.y)*(p.x-y.x)-(y.x-g.x)*(p.y-y.y)}function E(g,y){return g.x===y.x&&g.y===y.y}function L(g,y,p,w){var m=B(P(g,y,p)),b=B(P(g,y,w)),A=B(P(p,w,g)),C=B(P(p,w,y));return!!(m!==b&&A!==C||m===0&&I(g,p,y)||b===0&&I(g,w,y)||A===0&&I(p,g,w)||C===0&&I(p,y,w))}function I(g,y,p){return y.x<=Math.max(g.x,p.x)&&y.x>=Math.min(g.x,p.x)&&y.y<=Math.max(g.y,p.y)&&y.y>=Math.min(g.y,p.y)}function B(g){return g>0?1:g<0?-1:0}function K(g,y){var p=g;do{if(p.i!==g.i&&p.next.i!==g.i&&p.i!==y.i&&p.next.i!==y.i&&L(p,p.next,g,y))return!0;p=p.next}while(p!==g);return!1}function j(g,y){return P(g.prev,g,g.next)<0?P(g,y,g.next)>=0&&P(g,g.prev,y)>=0:P(g,y,g.prev)<0||P(g,g.next,y)<0}function W(g,y){var p=g,w=!1,m=(g.x+y.x)/2,b=(g.y+y.y)/2;do p.y>b!=p.next.y>b&&p.next.y!==p.y&&m<(p.next.x-p.x)*(b-p.y)/(p.next.y-p.y)+p.x&&(w=!w),p=p.next;while(p!==g);return w}function lt(g,y){var p=new tt(g.i,g.x,g.y),w=new tt(y.i,y.x,y.y),m=g.next,b=y.prev;return g.next=y,y.prev=g,p.next=m,m.prev=p,w.next=p,p.prev=w,b.next=w,w.prev=b,w}function ct(g,y,p,w){var m=new tt(g,y,p);return w?(m.next=w.next,m.prev=w,w.next.prev=m,w.next=m):(m.prev=m,m.next=m),m}function ut(g){g.next.prev=g.prev,g.prev.next=g.next,g.prevZ&&(g.prevZ.nextZ=g.nextZ),g.nextZ&&(g.nextZ.prevZ=g.prevZ)}function tt(g,y,p){this.i=g,this.x=y,this.y=p,this.prev=null,this.next=null,this.z=0,this.prevZ=null,this.nextZ=null,this.steiner=!1}n.deviation=function(g,y,p,w){var m=y&&y.length,b=m?y[0]*p:g.length,A=Math.abs(ve(g,0,b,p));if(m)for(var C=0,F=y.length;C<F;C++){var N=y[C]*p,Y=C<F-1?y[C+1]*p:g.length;A-=Math.abs(ve(g,N,Y,p))}var U=0;for(C=0;C<w.length;C+=3){var D=w[C]*p,Z=w[C+1]*p,$=w[C+2]*p;U+=Math.abs((g[D]-g[$])*(g[Z+1]-g[D+1])-(g[D]-g[Z])*(g[$+1]-g[D+1]))}return A===0&&U===0?0:Math.abs((U-A)/A)};function ve(g,y,p,w){for(var m=0,b=y,A=p-w;b<p;b+=w)m+=(g[A]-g[b])*(g[b+1]+g[A+1]),A=b;return m}return n.flatten=function(g){for(var y=g[0][0].length,p={vertices:[],holes:[],dimensions:y},w=0,m=0;m<g.length;m++){for(var b=0;b<g[m].length;b++)for(var A=0;A<y;A++)p.vertices.push(g[m][b][A]);m>0&&(w+=g[m-1].length,p.holes.push(w))}return p},jt.exports}e2();function p0(n,e){return n<e?-1:n>e?1:n>=e?0:NaN}function n2(n){return n.length===1&&(n=r2(n)),{left:function(e,t,o,i){for(o==null&&(o=0),i==null&&(i=e.length);o<i;){var a=o+i>>>1;n(e[a],t)<0?o=a+1:i=a}return o},right:function(e,t,o,i){for(o==null&&(o=0),i==null&&(i=e.length);o<i;){var a=o+i>>>1;n(e[a],t)>0?i=a:o=a+1}return o}}}function r2(n){return function(e,t){return p0(n(e),t)}}n2(p0);function i2(n,e,t=3){const o=Jn(n,e,{maxSegmentLength:t});return{check:i=>typeof i=="string",interpolate:(i,a,s)=>o(s)}}function o2(n){const e=o=>n.width*o,t=o=>n.height*o;return{scaleX:e,scaleY:t,position:(o,i)=>G({x:e(o),y:t(i)})}}function s2(n){const e=[];if(n.isAllKey){for(let t=0;t<=n.animations.length;t++)e.push(t);return e}return n.isStartKey&&e.push(0),n.animations.forEach((t,o)=>{Array.isArray(t)?t.some(i=>i.isKey)&&e.push(o+1):t.isKey&&e.push(o+1)}),n.isEndKey&&e[e.length-1]!==n.animations.length&&e.push(n.animations.length),e}k.Alignment=dt,k.Anchor=et,k.Animate=Rt,k.Arrow=E0,k.BrowserCanvasRenderer=on,k.Circle=k0,k.Color=V,k.Easing=Ft,k.FadeIn=A0,k.FadeOut=M0,k.FontStyle=Pe,k.FontWeight=Se,k.Grid=O0,k.Group=Wt,k.Hide=L0,k.IFrame=C0,k.Image=_0,k.Line=N0,k.Mask=F0,k.ObjectType=H,k.Opaque=cn,k.Path=t1,k.Pause=an,k.Polygon=e1,k.Position=G,k.Presentation=He,k.Rectangle=n1,k.SVG=r1,k.ScreenCapture=S0,k.Show=T0,k.Size=it,k.Slide=hn,k.SlideObject=nt,k.SlideWebExtra=$t,k.Text=ke,k.TextUnit=ln,k.Transparent=Ce,k.Update=Ut,k.getKeySlideBuildIndices=s2,k.getSizingFunctions=o2,k.getSmoothPathInterpolator=i2,k.getTextContentLength=Ie,k.interpolateColor=We,k.interpolateNumber=Ye,Object.defineProperty(k,Symbol.toStringTag,{value:"Module"})}));
|
|
5
|
+
`;function mi(n){return new J1(n).abs()}function bi(n){return n.toString().split("M").map((e,t)=>(e=e.trim(),t&&e?"M"+e:e)).filter(e=>e)}function Ai(n){return"M"+n.join("L")+"Z"}function Ti(n,e){let t=mi(n);return Mi(t)||Li(t,e)}function Mi(n){let e=n.segments||[],t=[];if(!e.length||e[0][0]!=="M")return!1;for(let o=0;o<e.length;o++){let[i,a,s]=e[o];if(i==="M"&&o||i==="Z")break;if(i==="M"||i==="L")t.push([a,s]);else if(i==="H")t.push([a,t[t.length-1][1]]);else if(i==="V")t.push([t[t.length-1][0],a]);else return!1}return t.length?{ring:t}:!1}function Li(n,e){let t=bi(n)[0],o=[],i,a,s=3;if(!t)throw new TypeError(me);a=Ci(t),i=a.getTotalLength(),e&&jt(e)&&e>0&&(s=Math.max(s,Math.ceil(i/e)));for(let r=0;r<s;r++){let l=a.getPointAtLength(i*r/s);o.push([l.x,l.y])}return{ring:o,skipBisect:!0}}function Ci(n){if(typeof window<"u"&&window&&window.document)try{let e=window.document.createElementNS("http://www.w3.org/2000/svg","path");return e.setAttributeNS(null,"d",n),e}catch{}return yi(n)}function M0(n,e){const t=n.length+e,o=H1(n)/e;let i=0,a=0,s=o/2;for(;n.length<t;){let r=n[i],l=n[(i+1)%n.length],c=Vt(r,l);if(s<=a+c){n.splice(i+1,0,c?T0(r,l,(s-a)/c):r.slice(0)),s+=o;continue}a+=c,i++}}function Si(n,e=1/0){for(let t=0;t<n.length;t++){let o=n[t],i=t===n.length-1?n[0]:n[t+1];for(;Vt(o,i)>e;)i=T0(o,i,.5),n.splice(t+1,0,i)}}function L0(n,e){let t,o,i;if(typeof n=="string"){let a=Ti(n,e);n=a.ring,i=a.skipBisect}else if(!Array.isArray(n))throw new TypeError(me);if(t=n.slice(0),!Pi(t))throw new TypeError(me);return t.length>1&&xi(t[0],t[t.length-1])&&t.pop(),o=j1(t),o>0&&t.reverse(),!i&&e&&jt(e)&&e>0&&Si(t,e),t}function Pi(n){return n.every(function(e){return Array.isArray(e)&&e.length>=2&&jt(e[0])&&jt(e[1])})}function Ei(n,e){let t=n.length,o=1/0,i,a,s;for(let r=0;r<t;r++)a=0,e.forEach(function(l,c){let u=Vt(n[(r+c)%t],l);a+=u*u}),a<o&&(o=a,i=r);i&&(s=n.splice(0,i),n.splice(n.length,0,...s))}function Ii(n,e,{maxSegmentLength:t=10,string:o=!0}={}){let i=L0(n,t),a=L0(e,t),s=ki(i,a,o);return!o||typeof n!="string"&&typeof e!="string"?s:r=>r<1e-4&&typeof n=="string"?n:1-r<1e-4&&typeof e=="string"?e:s(r)}function ki(n,e,t){let o;return o=n.length-e.length,M0(n,o<0?o*-1:0),M0(e,o>0?o:0),Ei(n,e),vi(n,e,t)}var Ht={exports:{}},C0;function Oi(){if(C0)return Ht.exports;C0=1,Ht.exports=n,Ht.exports.default=n;function n(d,y,p){p=p||2;var w=y&&y.length,m=w?y[0]*p:d.length,b=e(d,0,m,p,!0),A=[];if(!b||b.next===b.prev)return A;var C,F,N,G,H,D,Z;if(w&&(b=l(d,y,b,p)),d.length>80*p){C=N=d[0],F=G=d[1];for(var U=p;U<m;U+=p)H=d[U],D=d[U+1],H<C&&(C=H),D<F&&(F=D),H>N&&(N=H),D>G&&(G=D);Z=Math.max(N-C,G-F),Z=Z!==0?32767/Z:0}return o(b,A,p,C,F,Z,0),A}function e(d,y,p,w,m){var b,A;if(m===be(d,y,p,w)>0)for(b=y;b<p;b+=w)A=ct(b,d[b],d[b+1],A);else for(b=p-w;b>=y;b-=w)A=ct(b,d[b],d[b+1],A);return A&&E(A,A.next)&&(ut(A),A=A.next),A}function t(d,y){if(!d)return d;y||(y=d);var p=d,w;do if(w=!1,!p.steiner&&(E(p,p.next)||S(p.prev,p,p.next)===0)){if(ut(p),p=y=p.prev,p===p.next)break;w=!0}else p=p.next;while(w||p!==y);return y}function o(d,y,p,w,m,b,A){if(d){!A&&b&&f(d,w,m,b);for(var C=d,F,N;d.prev!==d.next;){if(F=d.prev,N=d.next,b?a(d,w,m,b):i(d)){y.push(F.i/p|0),y.push(d.i/p|0),y.push(N.i/p|0),ut(d),d=N.next,C=N.next;continue}if(d=N,d===C){A?A===1?(d=s(t(d),y,p),o(d,y,p,w,m,b,2)):A===2&&r(d,y,p,w,m,b):o(t(d),y,p,w,m,b,1);break}}}}function i(d){var y=d.prev,p=d,w=d.next;if(S(y,p,w)>=0)return!1;for(var m=y.x,b=p.x,A=w.x,C=y.y,F=p.y,N=w.y,G=m<b?m<A?m:A:b<A?b:A,H=C<F?C<N?C:N:F<N?F:N,D=m>b?m>A?m:A:b>A?b:A,Z=C>F?C>N?C:N:F>N?F:N,U=w.next;U!==y;){if(U.x>=G&&U.x<=D&&U.y>=H&&U.y<=Z&&L(m,C,b,F,A,N,U.x,U.y)&&S(U.prev,U,U.next)>=0)return!1;U=U.next}return!0}function a(d,y,p,w){var m=d.prev,b=d,A=d.next;if(S(m,b,A)>=0)return!1;for(var C=m.x,F=b.x,N=A.x,G=m.y,H=b.y,D=A.y,Z=C<F?C<N?C:N:F<N?F:N,U=G<H?G<D?G:D:H<D?H:D,Nt=C>F?C>N?C:N:F>N?F:N,Ft=G>H?G>D?G:D:H>D?H:D,P0=x(Z,U,y,p,w),E0=x(Nt,Ft,y,p,w),q=d.prevZ,z=d.nextZ;q&&q.z>=P0&&z&&z.z<=E0;){if(q.x>=Z&&q.x<=Nt&&q.y>=U&&q.y<=Ft&&q!==m&&q!==A&&L(C,G,F,H,N,D,q.x,q.y)&&S(q.prev,q,q.next)>=0||(q=q.prevZ,z.x>=Z&&z.x<=Nt&&z.y>=U&&z.y<=Ft&&z!==m&&z!==A&&L(C,G,F,H,N,D,z.x,z.y)&&S(z.prev,z,z.next)>=0))return!1;z=z.nextZ}for(;q&&q.z>=P0;){if(q.x>=Z&&q.x<=Nt&&q.y>=U&&q.y<=Ft&&q!==m&&q!==A&&L(C,G,F,H,N,D,q.x,q.y)&&S(q.prev,q,q.next)>=0)return!1;q=q.prevZ}for(;z&&z.z<=E0;){if(z.x>=Z&&z.x<=Nt&&z.y>=U&&z.y<=Ft&&z!==m&&z!==A&&L(C,G,F,H,N,D,z.x,z.y)&&S(z.prev,z,z.next)>=0)return!1;z=z.nextZ}return!0}function s(d,y,p){var w=d;do{var m=w.prev,b=w.next.next;!E(m,b)&&M(m,w,w.next,b)&&j(m,b)&&j(b,m)&&(y.push(m.i/p|0),y.push(w.i/p|0),y.push(b.i/p|0),ut(w),ut(w.next),w=d=b),w=w.next}while(w!==d);return t(w)}function r(d,y,p,w,m,b){var A=d;do{for(var C=A.next.next;C!==A.prev;){if(A.i!==C.i&&P(A,C)){var F=ht(A,C);A=t(A,A.next),F=t(F,F.next),o(A,y,p,w,m,b,0),o(F,y,p,w,m,b,0);return}C=C.next}A=A.next}while(A!==d)}function l(d,y,p,w){var m=[],b,A,C,F,N;for(b=0,A=y.length;b<A;b++)C=y[b]*w,F=b<A-1?y[b+1]*w:d.length,N=e(d,C,F,w,!1),N===N.next&&(N.steiner=!0),m.push(T(N));for(m.sort(c),b=0;b<m.length;b++)p=u(m[b],p);return p}function c(d,y){return d.x-y.x}function u(d,y){var p=g(d,y);if(!p)return y;var w=ht(p,d);return t(w,w.next),t(p,p.next)}function g(d,y){var p=y,w=d.x,m=d.y,b=-1/0,A;do{if(m<=p.y&&m>=p.next.y&&p.next.y!==p.y){var C=p.x+(m-p.y)*(p.next.x-p.x)/(p.next.y-p.y);if(C<=w&&C>b&&(b=C,A=p.x<p.next.x?p:p.next,C===w))return A}p=p.next}while(p!==y);if(!A)return null;var F=A,N=A.x,G=A.y,H=1/0,D;p=A;do w>=p.x&&p.x>=N&&w!==p.x&&L(m<G?w:b,m,N,G,m<G?b:w,m,p.x,p.y)&&(D=Math.abs(m-p.y)/(w-p.x),j(p,d)&&(D<H||D===H&&(p.x>A.x||p.x===A.x&&h(A,p)))&&(A=p,H=D)),p=p.next;while(p!==F);return A}function h(d,y){return S(d.prev,d,y.prev)<0&&S(y.next,d,d.next)<0}function f(d,y,p,w){var m=d;do m.z===0&&(m.z=x(m.x,m.y,y,p,w)),m.prevZ=m.prev,m.nextZ=m.next,m=m.next;while(m!==d);m.prevZ.nextZ=null,m.prevZ=null,v(m)}function v(d){var y,p,w,m,b,A,C,F,N=1;do{for(p=d,d=null,b=null,A=0;p;){for(A++,w=p,C=0,y=0;y<N&&(C++,w=w.nextZ,!!w);y++);for(F=N;C>0||F>0&&w;)C!==0&&(F===0||!w||p.z<=w.z)?(m=p,p=p.nextZ,C--):(m=w,w=w.nextZ,F--),b?b.nextZ=m:d=m,m.prevZ=b,b=m;p=w}b.nextZ=null,N*=2}while(A>1);return d}function x(d,y,p,w,m){return d=(d-p)*m|0,y=(y-w)*m|0,d=(d|d<<8)&16711935,d=(d|d<<4)&252645135,d=(d|d<<2)&858993459,d=(d|d<<1)&1431655765,y=(y|y<<8)&16711935,y=(y|y<<4)&252645135,y=(y|y<<2)&858993459,y=(y|y<<1)&1431655765,d|y<<1}function T(d){var y=d,p=d;do(y.x<p.x||y.x===p.x&&y.y<p.y)&&(p=y),y=y.next;while(y!==d);return p}function L(d,y,p,w,m,b,A,C){return(m-A)*(y-C)>=(d-A)*(b-C)&&(d-A)*(w-C)>=(p-A)*(y-C)&&(p-A)*(b-C)>=(m-A)*(w-C)}function P(d,y){return d.next.i!==y.i&&d.prev.i!==y.i&&!X(d,y)&&(j(d,y)&&j(y,d)&&W(d,y)&&(S(d.prev,d,y.prev)||S(d,y.prev,y))||E(d,y)&&S(d.prev,d,d.next)>0&&S(y.prev,y,y.next)>0)}function S(d,y,p){return(y.y-d.y)*(p.x-y.x)-(y.x-d.x)*(p.y-y.y)}function E(d,y){return d.x===y.x&&d.y===y.y}function M(d,y,p,w){var m=B(S(d,y,p)),b=B(S(d,y,w)),A=B(S(p,w,d)),C=B(S(p,w,y));return!!(m!==b&&A!==C||m===0&&k(d,p,y)||b===0&&k(d,w,y)||A===0&&k(p,d,w)||C===0&&k(p,y,w))}function k(d,y,p){return y.x<=Math.max(d.x,p.x)&&y.x>=Math.min(d.x,p.x)&&y.y<=Math.max(d.y,p.y)&&y.y>=Math.min(d.y,p.y)}function B(d){return d>0?1:d<0?-1:0}function X(d,y){var p=d;do{if(p.i!==d.i&&p.next.i!==d.i&&p.i!==y.i&&p.next.i!==y.i&&M(p,p.next,d,y))return!0;p=p.next}while(p!==d);return!1}function j(d,y){return S(d.prev,d,d.next)<0?S(d,y,d.next)>=0&&S(d,d.prev,y)>=0:S(d,y,d.prev)<0||S(d,d.next,y)<0}function W(d,y){var p=d,w=!1,m=(d.x+y.x)/2,b=(d.y+y.y)/2;do p.y>b!=p.next.y>b&&p.next.y!==p.y&&m<(p.next.x-p.x)*(b-p.y)/(p.next.y-p.y)+p.x&&(w=!w),p=p.next;while(p!==d);return w}function ht(d,y){var p=new nt(d.i,d.x,d.y),w=new nt(y.i,y.x,y.y),m=d.next,b=y.prev;return d.next=y,y.prev=d,p.next=m,m.prev=p,w.next=p,p.prev=w,b.next=w,w.prev=b,w}function ct(d,y,p,w){var m=new nt(d,y,p);return w?(m.next=w.next,m.prev=w,w.next.prev=m,w.next=m):(m.prev=m,m.next=m),m}function ut(d){d.next.prev=d.prev,d.prev.next=d.next,d.prevZ&&(d.prevZ.nextZ=d.nextZ),d.nextZ&&(d.nextZ.prevZ=d.prevZ)}function nt(d,y,p){this.i=d,this.x=y,this.y=p,this.prev=null,this.next=null,this.z=0,this.prevZ=null,this.nextZ=null,this.steiner=!1}n.deviation=function(d,y,p,w){var m=y&&y.length,b=m?y[0]*p:d.length,A=Math.abs(be(d,0,b,p));if(m)for(var C=0,F=y.length;C<F;C++){var N=y[C]*p,G=C<F-1?y[C+1]*p:d.length;A-=Math.abs(be(d,N,G,p))}var H=0;for(C=0;C<w.length;C+=3){var D=w[C]*p,Z=w[C+1]*p,U=w[C+2]*p;H+=Math.abs((d[D]-d[U])*(d[Z+1]-d[D+1])-(d[D]-d[Z])*(d[U+1]-d[D+1]))}return A===0&&H===0?0:Math.abs((H-A)/A)};function be(d,y,p,w){for(var m=0,b=y,A=p-w;b<p;b+=w)m+=(d[A]-d[b])*(d[b+1]+d[A+1]),A=b;return m}return n.flatten=function(d){for(var y=d[0][0].length,p={vertices:[],holes:[],dimensions:y},w=0,m=0;m<d.length;m++){for(var b=0;b<d[m].length;b++)for(var A=0;A<y;A++)p.vertices.push(d[m][b][A]);m>0&&(w+=d[m-1].length,p.holes.push(w))}return p},Ht.exports}Oi();function S0(n,e){return n<e?-1:n>e?1:n>=e?0:NaN}function _i(n){return n.length===1&&(n=Ni(n)),{left:function(e,t,o,i){for(o==null&&(o=0),i==null&&(i=e.length);o<i;){var a=o+i>>>1;n(e[a],t)<0?o=a+1:i=a}return o},right:function(e,t,o,i){for(o==null&&(o=0),i==null&&(i=e.length);o<i;){var a=o+i>>>1;n(e[a],t)>0?i=a:o=a+1}return o}}}function Ni(n){return function(e,t){return S0(n(e),t)}}_i(S0);function Fi(n,e,t=3){const o=Ii(n,e,{maxSegmentLength:t});return{check:i=>typeof i=="string",interpolate:(i,a,s)=>o(s)}}function Ri(n){const e=o=>n.width*o,t=o=>n.height*o;return{scaleX:e,scaleY:t,position:(o,i)=>$({x:e(o),y:t(i)})}}function Bi(n){const e=[];if(n.isAllKey){for(let t=0;t<=n.animations.length;t++)e.push(t);return e}return n.isStartKey&&e.push(0),n.animations.forEach((t,o)=>{Array.isArray(t)?t.some(i=>i.isKey)&&e.push(o+1):t.isKey&&e.push(o+1)}),n.isEndKey&&e[e.length-1]!==n.animations.length&&e.push(n.animations.length),e}I.Alignment=pt,I.Anchor=it,I.Animate=Bt,I.Arrow=V0,I.BrowserCanvasRenderer=R1,I.Circle=H0,I.Color=K,I.Easing=Rt,I.FadeIn=N0,I.FadeOut=F0,I.FontStyle=Ie,I.FontWeight=ke,I.Grid=U0,I.Group=Gt,I.Hide=R0,I.IFrame=D0,I.Image=$0,I.Line=W0,I.Mask=G0,I.ObjectType=V,I.Opaque=V1,I.Path=dn,I.Pause=D1,I.Polygon=gn,I.Position=$,I.Presentation=$e,I.Rectangle=pn,I.SVG=xn,I.ScreenCapture=z0,I.Show=B0,I.Size=J,I.Slide=q1,I.SlideObject=et,I.SlideWebExtra=Wt,I.Spotlight=yn,I.Text=Ne,I.TextUnit=z1,I.Transparent=Ee,I.Update=$t,I.Variable=L1,I.getKeySlideBuildIndices=Bi,I.getSizingFunctions=Ri,I.getSmoothPathInterpolator=Fi,I.getTextContentLength=_e,I.interpolateColor=Ye,I.interpolateNumber=Xe,Object.defineProperty(I,Symbol.toStringTag,{value:"Module"})}));
|
|
6
6
|
//# sourceMappingURL=presenter.js.map
|