fluency-v8-components 1.1.0 → 1.1.1
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.
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { H as e, O as t, bn as r, at as o, ay as n, b9 as i, aX as l, ba as C, aY as u, aM as g, aL as b, W as P, V as d, aB as p, aC as h, X as c, a6 as m, a7 as T, a8 as S, a5 as f, aq as I, bb as y, aZ as D, C as B, u as k, aN as A, as as G, s as F, t as L, bc as M, a_ as w, az as H, al as E, am as N, ah as R, aQ as v, D as x, L as V, E as z, ar as W, aJ as j, aU as K, aV as O, aW as Q, an as U, aP as q, ap as J, l as X, m as Y, n as Z, au as $, aD as _, o as aa, G as sa, a as ea, d as ta, b as ra, e as oa, f as na, i as ia, j as la, k as Ca, h as ua, aR as ga, p as ba, av as Pa, be as da, b0 as pa, a4 as ha, bd as ca, a$ as ma, J as Ta, K as Sa, bf as fa, b1 as Ia, r as ya, aO as Da, aA as Ba, aj as ka, ak as Aa, aS as Ga, M as Fa, aT as La, bg as Ma, b2 as wa, w as Ha, v as Ea, x as Na, y as Ra, a0 as va, a1 as xa, bo as Va, aG as za, bh as Wa, b3 as ja, ai as Ka, F as Oa, aw as Qa, Z as Ua, $ as qa, aH as Ja, z as Xa, R as Ya, bp as Za, B as $a, ax as _a, ao as as, U as ss, Y as es, ag as ts, aa as rs, a9 as os, bi as ns, b4 as is, bj as ls, b5 as Cs, aE as us, aF as gs, N as bs, ab as Ps, bk as ds, ac as ps, ad as hs, b6 as cs, ae as ms, a2 as Ts, S as Ss, Q as fs, I as Is, bl as ys, b7 as Ds, T as Bs, aI as ks, a3 as As, bm as Gs, b8 as Fs, P as Ls, q as Ms, af as ws, A as Hs, aK as Es } from "./index-
|
|
1
|
+
import { H as e, O as t, bn as r, at as o, ay as n, b9 as i, aX as l, ba as C, aY as u, aM as g, aL as b, W as P, V as d, aB as p, aC as h, X as c, a6 as m, a7 as T, a8 as S, a5 as f, aq as I, bb as y, aZ as D, C as B, u as k, aN as A, as as G, s as F, t as L, bc as M, a_ as w, az as H, al as E, am as N, ah as R, aQ as v, D as x, L as V, E as z, ar as W, aJ as j, aU as K, aV as O, aW as Q, an as U, aP as q, ap as J, l as X, m as Y, n as Z, au as $, aD as _, o as aa, G as sa, a as ea, d as ta, b as ra, e as oa, f as na, i as ia, j as la, k as Ca, h as ua, aR as ga, p as ba, av as Pa, be as da, b0 as pa, a4 as ha, bd as ca, a$ as ma, J as Ta, K as Sa, bf as fa, b1 as Ia, r as ya, aO as Da, aA as Ba, aj as ka, ak as Aa, aS as Ga, M as Fa, aT as La, bg as Ma, b2 as wa, w as Ha, v as Ea, x as Na, y as Ra, a0 as va, a1 as xa, bo as Va, aG as za, bh as Wa, b3 as ja, ai as Ka, F as Oa, aw as Qa, Z as Ua, $ as qa, aH as Ja, z as Xa, R as Ya, bp as Za, B as $a, ax as _a, ao as as, U as ss, Y as es, ag as ts, aa as rs, a9 as os, bi as ns, b4 as is, bj as ls, b5 as Cs, aE as us, aF as gs, N as bs, ab as Ps, bk as ds, ac as ps, ad as hs, b6 as cs, ae as ms, a2 as Ts, S as Ss, Q as fs, I as Is, bl as ys, b7 as Ds, T as Bs, aI as ks, a3 as As, bm as Gs, b8 as Fs, P as Ls, q as Ms, af as ws, A as Hs, aK as Es } from "./index-BiMMXHfr.mjs";
|
|
2
2
|
export {
|
|
3
3
|
e as ActionButtons,
|
|
4
4
|
t as Active,
|
|
@@ -427,7 +427,7 @@ end
|
|
|
427
427
|
end`};t.events.push(["putFont",function(a){(function(o){var s=o.font,u=o.out,c=o.newObject,A=o.putStream;if(s.metadata instanceof e.API.TTFFont&&s.encoding==="Identity-H"){for(var d=s.metadata.Unicode.widths,f=s.metadata.subset.encode(s.metadata.glyIdsUsed,1),h="",p=0;p<f.length;p++)h+=String.fromCharCode(f[p]);var m=c();A({data:h,addLength1:!0,objectId:m}),u("endobj");var v=c();A({data:r(s.metadata.toUnicode),addLength1:!0,objectId:v}),u("endobj");var y=c();u("<<"),u("/Type /FontDescriptor"),u("/FontName /"+Rp(s.fontName)),u("/FontFile2 "+m+" 0 R"),u("/FontBBox "+e.API.PDFObject.convert(s.metadata.bbox)),u("/Flags "+s.metadata.flags),u("/StemV "+s.metadata.stemV),u("/ItalicAngle "+s.metadata.italicAngle),u("/Ascent "+s.metadata.ascender),u("/Descent "+s.metadata.decender),u("/CapHeight "+s.metadata.capHeight),u(">>"),u("endobj");var g=c();u("<<"),u("/Type /Font"),u("/BaseFont /"+Rp(s.fontName)),u("/FontDescriptor "+y+" 0 R"),u("/W "+e.API.PDFObject.convert(d)),u("/CIDToGIDMap /Identity"),u("/DW 1000"),u("/Subtype /CIDFontType2"),u("/CIDSystemInfo"),u("<<"),u("/Supplement 0"),u("/Registry (Adobe)"),u("/Ordering ("+s.encoding+")"),u(">>"),u(">>"),u("endobj"),s.objectNumber=c(),u("<<"),u("/Type /Font"),u("/Subtype /Type0"),u("/ToUnicode "+v+" 0 R"),u("/BaseFont /"+Rp(s.fontName)),u("/Encoding /"+s.encoding),u("/DescendantFonts ["+g+" 0 R]"),u(">>"),u("endobj"),s.isAlreadyPutted=!0}})(a)}]),t.events.push(["putFont",function(a){(function(o){var s=o.font,u=o.out,c=o.newObject,A=o.putStream;if(s.metadata instanceof e.API.TTFFont&&s.encoding==="WinAnsiEncoding"){for(var d=s.metadata.rawData,f="",h=0;h<d.length;h++)f+=String.fromCharCode(d[h]);var p=c();A({data:f,addLength1:!0,objectId:p}),u("endobj");var m=c();A({data:r(s.metadata.toUnicode),addLength1:!0,objectId:m}),u("endobj");var v=c();u("<<"),u("/Descent "+s.metadata.decender),u("/CapHeight "+s.metadata.capHeight),u("/StemV "+s.metadata.stemV),u("/Type /FontDescriptor"),u("/FontFile2 "+p+" 0 R"),u("/Flags 96"),u("/FontBBox "+e.API.PDFObject.convert(s.metadata.bbox)),u("/FontName /"+Rp(s.fontName)),u("/ItalicAngle "+s.metadata.italicAngle),u("/Ascent "+s.metadata.ascender),u(">>"),u("endobj"),s.objectNumber=c();for(var y=0;y<s.metadata.hmtx.widths.length;y++)s.metadata.hmtx.widths[y]=parseInt(s.metadata.hmtx.widths[y]*(1e3/s.metadata.head.unitsPerEm));u("<</Subtype/TrueType/Type/Font/ToUnicode "+m+" 0 R/BaseFont/"+Rp(s.fontName)+"/FontDescriptor "+v+" 0 R/Encoding/"+s.encoding+" /FirstChar 29 /LastChar 255 /Widths "+e.API.PDFObject.convert(s.metadata.hmtx.widths)+">>"),u("endobj"),s.isAlreadyPutted=!0}})(a)}]);var i=function(a){var o,s=a.text||"",u=a.x,c=a.y,A=a.options||{},d=a.mutex||{},f=d.pdfEscape,h=d.activeFontKey,p=d.fonts,m=h,v="",y=0,g="",b=p[m].encoding;if(p[m].encoding!=="Identity-H")return{text:s,x:u,y:c,options:A,mutex:d};for(g=s,m=h,Array.isArray(s)&&(g=s[0]),y=0;y<g.length;y+=1)p[m].metadata.hasOwnProperty("cmap")&&(o=p[m].metadata.cmap.unicode.codeMap[g[y].charCodeAt(0)]),o||g[y].charCodeAt(0)<256&&p[m].metadata.hasOwnProperty("Unicode")?v+=g[y]:v+="";var w="";return parseInt(m.slice(1))<14||b==="WinAnsiEncoding"?w=f(v,m).split("").map(function(_){return _.charCodeAt(0).toString(16)}).join(""):b==="Identity-H"&&(w=n(v,p[m])),d.isHex=!0,{text:w,x:u,y:c,options:A,mutex:d}};t.events.push(["postProcessText",function(a){var o=a.text||"",s=[],u={text:o,x:a.x,y:a.y,options:a.options,mutex:a.mutex};if(Array.isArray(o)){var c=0;for(c=0;c<o.length;c+=1)Array.isArray(o[c])&&o[c].length===3?s.push([i(Object.assign({},u,{text:o[c][0]})).text,o[c][1],o[c][2]]):s.push(i(Object.assign({},u,{text:o[c]})).text);a.text=s}else a.text=i(Object.assign({},u,{text:o})).text}])}(mn),function(e){var t=function(){return this.internal.vFS===void 0&&(this.internal.vFS={}),!0};e.existsFileInVFS=function(n){return t.call(this),this.internal.vFS[n]!==void 0},e.addFileToVFS=function(n,r){return t.call(this),this.internal.vFS[n]=r,this},e.getFileFromVFS=function(n){return t.call(this),this.internal.vFS[n]!==void 0?this.internal.vFS[n]:null}}(mn.API),function(e){e.__bidiEngine__=e.prototype.__bidiEngine__=function(r){var i,a,o,s,u,c,A,d=t,f=[[0,3,0,1,0,0,0],[0,3,0,1,2,2,0],[0,3,0,17,2,0,1],[0,3,5,5,4,1,0],[0,3,21,21,4,0,1],[0,3,5,5,4,2,0]],h=[[2,0,1,1,0,1,0],[2,0,1,1,0,2,0],[2,0,2,1,3,2,0],[2,0,2,33,3,1,1]],p={L:0,R:1,EN:2,AN:3,N:4,B:5,S:6},m={0:0,5:1,6:2,7:3,32:4,251:5,254:6,255:7},v=["(",")","(","<",">","<","[","]","[","{","}","{","«","»","«","‹","›","‹","⁅","⁆","⁅","⁽","⁾","⁽","₍","₎","₍","≤","≥","≤","〈","〉","〈","﹙","﹚","﹙","﹛","﹜","﹛","﹝","﹞","﹝","﹤","﹥","﹤"],y=new RegExp(/^([1-4|9]|1[0-9]|2[0-9]|3[0168]|4[04589]|5[012]|7[78]|159|16[0-9]|17[0-2]|21[569]|22[03489]|250)$/),g=!1,b=0;this.__bidiEngine__={};var w=function(M){var N=M.charCodeAt(),F=N>>8,L=m[F];return L!==void 0?d[256*L+(255&N)]:F===252||F===253?"AL":y.test(F)?"L":F===8?"R":"N"},_=function(M){for(var N,F=0;F<M.length;F++){if((N=w(M.charAt(F)))==="L")return!1;if(N==="R")return!0}return!1},C=function(M,N,F,L){var P,K,V,j,q=N[L];switch(q){case"L":case"R":g=!1;break;case"N":case"AN":break;case"EN":g&&(q="AN");break;case"AL":g=!0,q="R";break;case"WS":q="N";break;case"CS":L<1||L+1>=N.length||(P=F[L-1])!=="EN"&&P!=="AN"||(K=N[L+1])!=="EN"&&K!=="AN"?q="N":g&&(K="AN"),q=K===P?K:"N";break;case"ES":q=(P=L>0?F[L-1]:"B")==="EN"&&L+1<N.length&&N[L+1]==="EN"?"EN":"N";break;case"ET":if(L>0&&F[L-1]==="EN"){q="EN";break}if(g){q="N";break}for(V=L+1,j=N.length;V<j&&N[V]==="ET";)V++;q=V<j&&N[V]==="EN"?"EN":"N";break;case"NSM":if(o&&!s){for(j=N.length,V=L+1;V<j&&N[V]==="NSM";)V++;if(V<j){var ee=M[L],te=ee>=1425&&ee<=2303||ee===64286;if(P=N[V],te&&(P==="R"||P==="AL")){q="R";break}}}q=L<1||(P=N[L-1])==="B"?"N":F[L-1];break;case"B":g=!1,i=!0,q=b;break;case"S":a=!0,q="N";break;case"LRE":case"RLE":case"LRO":case"RLO":case"PDF":g=!1;break;case"BN":q="N"}return q},B=function(M,N,F){var L=M.split("");return F&&k(L,F,{hiLevel:b}),L.reverse(),N&&N.reverse(),L.join("")},k=function(M,N,F){var L,P,K,V,j,q=-1,ee=M.length,te=0,U=[],W=b?h:f,$=[];for(g=!1,i=!1,a=!1,P=0;P<ee;P++)$[P]=w(M[P]);for(K=0;K<ee;K++){if(j=te,U[K]=C(M,$,U,K),L=240&(te=W[j][p[U[K]]]),te&=15,N[K]=V=W[te][5],L>0)if(L===16){for(P=q;P<K;P++)N[P]=1;q=-1}else q=-1;if(W[te][6])q===-1&&(q=K);else if(q>-1){for(P=q;P<K;P++)N[P]=V;q=-1}$[K]==="B"&&(N[K]=0),F.hiLevel|=V}a&&function(re,me,fe){for(var de=0;de<fe;de++)if(re[de]==="S"){me[de]=b;for(var le=de-1;le>=0&&re[le]==="WS";le--)me[le]=b}}($,N,ee)},O=function(M,N,F,L,P){if(!(P.hiLevel<M)){if(M===1&&b===1&&!i)return N.reverse(),void(F&&F.reverse());for(var K,V,j,q,ee=N.length,te=0;te<ee;){if(L[te]>=M){for(j=te+1;j<ee&&L[j]>=M;)j++;for(q=te,V=j-1;q<V;q++,V--)K=N[q],N[q]=N[V],N[V]=K,F&&(K=F[q],F[q]=F[V],F[V]=K);te=j}te++}}},Y=function(M,N,F){var L=M.split(""),P={hiLevel:b};return F||(F=[]),k(L,F,P),function(K,V,j){if(j.hiLevel!==0&&A)for(var q,ee=0;ee<K.length;ee++)V[ee]===1&&(q=v.indexOf(K[ee]))>=0&&(K[ee]=v[q+1])}(L,F,P),O(2,L,N,F,P),O(1,L,N,F,P),L.join("")};return this.__bidiEngine__.doBidiReorder=function(M,N,F){if(function(P,K){if(K)for(var V=0;V<P.length;V++)K[V]=V;s===void 0&&(s=_(P)),c===void 0&&(c=_(P))}(M,N),o||!u||c)if(o&&u&&s^c)b=s?1:0,M=B(M,N,F);else if(!o&&u&&c)b=s?1:0,M=Y(M,N,F),M=B(M,N);else if(!o||s||u||c){if(o&&!u&&s^c)M=B(M,N),s?(b=0,M=Y(M,N,F)):(b=1,M=Y(M,N,F),M=B(M,N));else if(o&&s&&!u&&c)b=1,M=Y(M,N,F),M=B(M,N);else if(!o&&!u&&s^c){var L=A;s?(b=1,M=Y(M,N,F),b=0,A=!1,M=Y(M,N,F),A=L):(b=0,M=Y(M,N,F),M=B(M,N),b=1,A=!1,M=Y(M,N,F),A=L,M=B(M,N))}}else b=0,M=Y(M,N,F);else b=s?1:0,M=Y(M,N,F);return M},this.__bidiEngine__.setOptions=function(M){M&&(o=M.isInputVisual,u=M.isOutputVisual,s=M.isInputRtl,c=M.isOutputRtl,A=M.isSymmetricSwapping)},this.__bidiEngine__.setOptions(r),this.__bidiEngine__};var t=["BN","BN","BN","BN","BN","BN","BN","BN","BN","S","B","S","WS","B","BN","BN","BN","BN","BN","BN","BN","BN","BN","BN","BN","BN","BN","BN","B","B","B","S","WS","N","N","ET","ET","ET","N","N","N","N","N","ES","CS","ES","CS","CS","EN","EN","EN","EN","EN","EN","EN","EN","EN","EN","CS","N","N","N","N","N","N","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","N","N","N","N","N","N","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","N","N","N","N","BN","BN","BN","BN","BN","BN","B","BN","BN","BN","BN","BN","BN","BN","BN","BN","BN","BN","BN","BN","BN","BN","BN","BN","BN","BN","BN","BN","BN","BN","BN","BN","BN","CS","N","ET","ET","ET","ET","N","N","N","N","L","N","N","BN","N","N","ET","ET","EN","EN","N","L","N","N","N","EN","L","N","N","N","N","N","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","N","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","N","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","N","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","N","N","L","L","L","L","L","L","L","N","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","N","L","N","N","N","N","N","ET","N","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","R","NSM","R","NSM","NSM","R","NSM","NSM","R","NSM","N","N","N","N","N","N","N","N","R","R","R","R","R","R","R","R","R","R","R","R","R","R","R","R","R","R","R","R","R","R","R","R","R","R","R","N","N","N","N","N","R","R","R","R","R","N","N","N","N","N","N","N","N","N","N","N","AN","AN","AN","AN","AN","AN","N","N","AL","ET","ET","AL","CS","AL","N","N","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","AL","AL","N","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","AN","AN","AN","AN","AN","AN","AN","AN","AN","AN","ET","AN","AN","AL","AL","AL","NSM","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","NSM","NSM","NSM","NSM","NSM","NSM","NSM","AN","N","NSM","NSM","NSM","NSM","NSM","NSM","AL","AL","NSM","NSM","N","NSM","NSM","NSM","NSM","AL","AL","EN","EN","EN","EN","EN","EN","EN","EN","EN","EN","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","N","AL","AL","NSM","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","N","N","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","AL","N","N","N","N","N","N","N","N","N","N","N","N","N","N","R","R","R","R","R","R","R","R","R","R","R","R","R","R","R","R","R","R","R","R","R","R","R","R","R","R","R","R","R","R","R","R","R","R","R","R","R","R","R","R","R","R","R","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","R","R","N","N","N","N","R","N","N","N","N","N","WS","WS","WS","WS","WS","WS","WS","WS","WS","WS","WS","BN","BN","BN","L","R","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","WS","B","LRE","RLE","PDF","LRO","RLO","CS","ET","ET","ET","ET","ET","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","CS","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","WS","BN","BN","BN","BN","BN","N","LRI","RLI","FSI","PDI","BN","BN","BN","BN","BN","BN","EN","L","N","N","EN","EN","EN","EN","EN","EN","ES","ES","N","N","N","L","EN","EN","EN","EN","EN","EN","EN","EN","EN","EN","ES","ES","N","N","N","N","L","L","L","L","L","L","L","L","L","L","L","L","L","N","N","N","ET","ET","ET","ET","ET","ET","ET","ET","ET","ET","ET","ET","ET","ET","ET","ET","ET","ET","ET","ET","ET","ET","ET","ET","ET","ET","ET","ET","ET","ET","ET","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","L","L","L","L","L","L","L","N","N","N","N","N","N","N","N","N","N","N","N","L","L","L","L","L","N","N","N","N","N","R","NSM","R","R","R","R","R","R","R","R","R","R","ES","R","R","R","R","R","R","R","R","R","R","R","R","R","N","R","R","R","R","R","N","R","N","R","R","N","R","R","N","R","R","R","R","R","R","R","R","R","R","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","CS","N","CS","N","N","CS","N","N","N","N","N","N","N","N","N","ET","N","N","ES","ES","N","N","N","N","N","ET","ET","N","N","N","N","N","AL","AL","AL","AL","AL","N","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","N","N","BN","N","N","N","ET","ET","ET","N","N","N","N","N","ES","CS","ES","CS","CS","EN","EN","EN","EN","EN","EN","EN","EN","EN","EN","CS","N","N","N","N","N","N","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","N","N","N","N","N","N","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","N","N","N","N","N","N","N","N","N","N","N","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","N","N","N","L","L","L","L","L","L","N","N","L","L","L","L","L","L","N","N","L","L","L","L","L","L","N","N","L","L","L","N","N","N","ET","ET","N","N","N","ET","ET","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N"],n=new e.__bidiEngine__({isInputVisual:!0});e.API.events.push(["postProcessText",function(r){var i=r.text;r.x,r.y;var a=r.options||{};r.mutex,a.lang;var o=[];if(a.isInputVisual=typeof a.isInputVisual!="boolean"||a.isInputVisual,n.setOptions(a),Object.prototype.toString.call(i)==="[object Array]"){var s=0;for(o=[],s=0;s<i.length;s+=1)Object.prototype.toString.call(i[s])==="[object Array]"?o.push([n.doBidiReorder(i[s][0]),i[s][1],i[s][2]]):o.push([n.doBidiReorder(i[s])]);r.text=o}else r.text=n.doBidiReorder(i);n.setOptions({isInputVisual:!0})}])}(mn),mn.API.TTFFont=function(){function e(t){var n;if(this.rawData=t,n=this.contents=new ZA(t),this.contents.pos=4,n.readString(4)==="ttcf")throw new Error("TTCF not supported.");n.pos=0,this.parse(),this.subset=new fUe(this),this.registerTTF()}return e.open=function(t){return new e(t)},e.prototype.parse=function(){return this.directory=new $7e(this.contents),this.head=new tUe(this),this.name=new oUe(this),this.cmap=new JV(this),this.toUnicode={},this.hhea=new nUe(this),this.maxp=new sUe(this),this.hmtx=new lUe(this),this.post=new iUe(this),this.os2=new rUe(this),this.loca=new dUe(this),this.glyf=new uUe(this),this.ascender=this.os2.exists&&this.os2.ascender||this.hhea.ascender,this.decender=this.os2.exists&&this.os2.decender||this.hhea.decender,this.lineGap=this.os2.exists&&this.os2.lineGap||this.hhea.lineGap,this.bbox=[this.head.xMin,this.head.yMin,this.head.xMax,this.head.yMax]},e.prototype.registerTTF=function(){var t,n,r,i,a;if(this.scaleFactor=1e3/this.head.unitsPerEm,this.bbox=(function(){var o,s,u,c;for(c=[],o=0,s=(u=this.bbox).length;o<s;o++)t=u[o],c.push(Math.round(t*this.scaleFactor));return c}).call(this),this.stemV=0,this.post.exists?(r=255&(i=this.post.italic_angle),(32768&(n=i>>16))!=0&&(n=-(1+(65535^n))),this.italicAngle=+(n+"."+r)):this.italicAngle=0,this.ascender=Math.round(this.ascender*this.scaleFactor),this.decender=Math.round(this.decender*this.scaleFactor),this.lineGap=Math.round(this.lineGap*this.scaleFactor),this.capHeight=this.os2.exists&&this.os2.capHeight||this.ascender,this.xHeight=this.os2.exists&&this.os2.xHeight||0,this.familyClass=(this.os2.exists&&this.os2.familyClass||0)>>8,this.isSerif=(a=this.familyClass)===1||a===2||a===3||a===4||a===5||a===7,this.isScript=this.familyClass===10,this.flags=0,this.post.isFixedPitch&&(this.flags|=1),this.isSerif&&(this.flags|=2),this.isScript&&(this.flags|=8),this.italicAngle!==0&&(this.flags|=64),this.flags|=32,!this.cmap.unicode)throw new Error("No unicode cmap for font")},e.prototype.characterToGlyph=function(t){var n;return((n=this.cmap.unicode)!=null?n.codeMap[t]:void 0)||0},e.prototype.widthOfGlyph=function(t){var n;return n=1e3/this.head.unitsPerEm,this.hmtx.forGlyph(t).advance*n},e.prototype.widthOfString=function(t,n,r){var i,a,o,s;for(o=0,a=0,s=(t=""+t).length;0<=s?a<s:a>s;a=0<=s?++a:--a)i=t.charCodeAt(a),o+=this.widthOfGlyph(this.characterToGlyph(i))+r*(1e3/n)||0;return o*(n/1e3)},e.prototype.lineHeight=function(t,n){var r;return n==null&&(n=!1),r=n?this.lineGap:0,(this.ascender+r-this.decender)/1e3*t},e}();var yl,ZA=function(){function e(t){this.data=t??[],this.pos=0,this.length=this.data.length}return e.prototype.readByte=function(){return this.data[this.pos++]},e.prototype.writeByte=function(t){return this.data[this.pos++]=t},e.prototype.readUInt32=function(){return 16777216*this.readByte()+(this.readByte()<<16)+(this.readByte()<<8)+this.readByte()},e.prototype.writeUInt32=function(t){return this.writeByte(t>>>24&255),this.writeByte(t>>16&255),this.writeByte(t>>8&255),this.writeByte(255&t)},e.prototype.readInt32=function(){var t;return(t=this.readUInt32())>=2147483648?t-4294967296:t},e.prototype.writeInt32=function(t){return t<0&&(t+=4294967296),this.writeUInt32(t)},e.prototype.readUInt16=function(){return this.readByte()<<8|this.readByte()},e.prototype.writeUInt16=function(t){return this.writeByte(t>>8&255),this.writeByte(255&t)},e.prototype.readInt16=function(){var t;return(t=this.readUInt16())>=32768?t-65536:t},e.prototype.writeInt16=function(t){return t<0&&(t+=65536),this.writeUInt16(t)},e.prototype.readString=function(t){var n,r;for(r=[],n=0;0<=t?n<t:n>t;n=0<=t?++n:--n)r[n]=String.fromCharCode(this.readByte());return r.join("")},e.prototype.writeString=function(t){var n,r,i;for(i=[],n=0,r=t.length;0<=r?n<r:n>r;n=0<=r?++n:--n)i.push(this.writeByte(t.charCodeAt(n)));return i},e.prototype.readShort=function(){return this.readInt16()},e.prototype.writeShort=function(t){return this.writeInt16(t)},e.prototype.readLongLong=function(){var t,n,r,i,a,o,s,u;return t=this.readByte(),n=this.readByte(),r=this.readByte(),i=this.readByte(),a=this.readByte(),o=this.readByte(),s=this.readByte(),u=this.readByte(),128&t?-1*(72057594037927940*(255^t)+281474976710656*(255^n)+1099511627776*(255^r)+4294967296*(255^i)+16777216*(255^a)+65536*(255^o)+256*(255^s)+(255^u)+1):72057594037927940*t+281474976710656*n+1099511627776*r+4294967296*i+16777216*a+65536*o+256*s+u},e.prototype.writeLongLong=function(t){var n,r;return n=Math.floor(t/4294967296),r=4294967295&t,this.writeByte(n>>24&255),this.writeByte(n>>16&255),this.writeByte(n>>8&255),this.writeByte(255&n),this.writeByte(r>>24&255),this.writeByte(r>>16&255),this.writeByte(r>>8&255),this.writeByte(255&r)},e.prototype.readInt=function(){return this.readInt32()},e.prototype.writeInt=function(t){return this.writeInt32(t)},e.prototype.read=function(t){var n,r;for(n=[],r=0;0<=t?r<t:r>t;r=0<=t?++r:--r)n.push(this.readByte());return n},e.prototype.write=function(t){var n,r,i,a;for(a=[],r=0,i=t.length;r<i;r++)n=t[r],a.push(this.writeByte(n));return a},e}(),$7e=function(){var e;function t(n){var r,i,a;for(this.scalarType=n.readInt(),this.tableCount=n.readShort(),this.searchRange=n.readShort(),this.entrySelector=n.readShort(),this.rangeShift=n.readShort(),this.tables={},i=0,a=this.tableCount;0<=a?i<a:i>a;i=0<=a?++i:--i)r={tag:n.readString(4),checksum:n.readInt(),offset:n.readInt(),length:n.readInt()},this.tables[r.tag]=r}return t.prototype.encode=function(n){var r,i,a,o,s,u,c,A,d,f,h,p,m;for(m in h=Object.keys(n).length,u=Math.log(2),d=16*Math.floor(Math.log(h)/u),o=Math.floor(d/u),A=16*h-d,(i=new ZA).writeInt(this.scalarType),i.writeShort(h),i.writeShort(d),i.writeShort(o),i.writeShort(A),a=16*h,c=i.pos+a,s=null,p=[],n)for(f=n[m],i.writeString(m),i.writeInt(e(f)),i.writeInt(c),i.writeInt(f.length),p=p.concat(f),m==="head"&&(s=c),c+=f.length;c%4;)p.push(0),c++;return i.write(p),r=2981146554-e(i.data),i.pos=s+8,i.writeUInt32(r),i.data},e=function(n){var r,i,a,o;for(n=ZV.call(n);n.length%4;)n.push(0);for(a=new ZA(n),i=0,r=0,o=n.length;r<o;r=r+=4)i+=a.readUInt32();return 4294967295&i},t}(),eUe={}.hasOwnProperty,_u=function(e,t){for(var n in t)eUe.call(t,n)&&(e[n]=t[n]);function r(){this.constructor=e}return r.prototype=t.prototype,e.prototype=new r,e.__super__=t.prototype,e};yl=function(){function e(t){var n;this.file=t,n=this.file.directory.tables[this.tag],this.exists=!!n,n&&(this.offset=n.offset,this.length=n.length,this.parse(this.file.contents))}return e.prototype.parse=function(){},e.prototype.encode=function(){},e.prototype.raw=function(){return this.exists?(this.file.contents.pos=this.offset,this.file.contents.read(this.length)):null},e}();var tUe=function(e){function t(){return t.__super__.constructor.apply(this,arguments)}return _u(t,yl),t.prototype.tag="head",t.prototype.parse=function(n){return n.pos=this.offset,this.version=n.readInt(),this.revision=n.readInt(),this.checkSumAdjustment=n.readInt(),this.magicNumber=n.readInt(),this.flags=n.readShort(),this.unitsPerEm=n.readShort(),this.created=n.readLongLong(),this.modified=n.readLongLong(),this.xMin=n.readShort(),this.yMin=n.readShort(),this.xMax=n.readShort(),this.yMax=n.readShort(),this.macStyle=n.readShort(),this.lowestRecPPEM=n.readShort(),this.fontDirectionHint=n.readShort(),this.indexToLocFormat=n.readShort(),this.glyphDataFormat=n.readShort()},t.prototype.encode=function(n){var r;return(r=new ZA).writeInt(this.version),r.writeInt(this.revision),r.writeInt(this.checkSumAdjustment),r.writeInt(this.magicNumber),r.writeShort(this.flags),r.writeShort(this.unitsPerEm),r.writeLongLong(this.created),r.writeLongLong(this.modified),r.writeShort(this.xMin),r.writeShort(this.yMin),r.writeShort(this.xMax),r.writeShort(this.yMax),r.writeShort(this.macStyle),r.writeShort(this.lowestRecPPEM),r.writeShort(this.fontDirectionHint),r.writeShort(n),r.writeShort(this.glyphDataFormat),r.data},t}(),XV=function(){function e(t,n){var r,i,a,o,s,u,c,A,d,f,h,p,m,v,y,g,b;switch(this.platformID=t.readUInt16(),this.encodingID=t.readShort(),this.offset=n+t.readInt(),d=t.pos,t.pos=this.offset,this.format=t.readUInt16(),this.length=t.readUInt16(),this.language=t.readUInt16(),this.isUnicode=this.platformID===3&&this.encodingID===1&&this.format===4||this.platformID===0&&this.format===4,this.codeMap={},this.format){case 0:for(u=0;u<256;++u)this.codeMap[u]=t.readByte();break;case 4:for(h=t.readUInt16(),f=h/2,t.pos+=6,a=function(){var w,_;for(_=[],u=w=0;0<=f?w<f:w>f;u=0<=f?++w:--w)_.push(t.readUInt16());return _}(),t.pos+=2,m=function(){var w,_;for(_=[],u=w=0;0<=f?w<f:w>f;u=0<=f?++w:--w)_.push(t.readUInt16());return _}(),c=function(){var w,_;for(_=[],u=w=0;0<=f?w<f:w>f;u=0<=f?++w:--w)_.push(t.readUInt16());return _}(),A=function(){var w,_;for(_=[],u=w=0;0<=f?w<f:w>f;u=0<=f?++w:--w)_.push(t.readUInt16());return _}(),i=(this.length-t.pos+this.offset)/2,s=function(){var w,_;for(_=[],u=w=0;0<=i?w<i:w>i;u=0<=i?++w:--w)_.push(t.readUInt16());return _}(),u=y=0,b=a.length;y<b;u=++y)for(v=a[u],r=g=p=m[u];p<=v?g<=v:g>=v;r=p<=v?++g:--g)A[u]===0?o=r+c[u]:(o=s[A[u]/2+(r-p)-(f-u)]||0)!==0&&(o+=c[u]),this.codeMap[r]=65535&o}t.pos=d}return e.encode=function(t,n){var r,i,a,o,s,u,c,A,d,f,h,p,m,v,y,g,b,w,_,C,B,k,O,Y,M,N,F,L,P,K,V,j,q,ee,te,U,W,$,re,me,fe,de,le,ge,Be,xe;switch(L=new ZA,o=Object.keys(t).sort(function(Ie,Q){return Ie-Q}),n){case"macroman":for(m=0,v=function(){var Ie=[];for(p=0;p<256;++p)Ie.push(0);return Ie}(),g={0:0},a={},P=0,q=o.length;P<q;P++)g[le=t[i=o[P]]]==null&&(g[le]=++m),a[i]={old:t[i],new:g[t[i]]},v[i]=g[t[i]];return L.writeUInt16(1),L.writeUInt16(0),L.writeUInt32(12),L.writeUInt16(0),L.writeUInt16(262),L.writeUInt16(0),L.write(v),{charMap:a,subtable:L.data,maxGlyphID:m+1};case"unicode":for(N=[],d=[],b=0,g={},r={},y=c=null,K=0,ee=o.length;K<ee;K++)g[_=t[i=o[K]]]==null&&(g[_]=++b),r[i]={old:_,new:g[_]},s=g[_]-i,y!=null&&s===c||(y&&d.push(y),N.push(i),c=s),y=i;for(y&&d.push(y),d.push(65535),N.push(65535),Y=2*(O=N.length),k=2*Math.pow(Math.log(O)/Math.LN2,2),f=Math.log(k/2)/Math.LN2,B=2*O-k,u=[],C=[],h=[],p=V=0,te=N.length;V<te;p=++V){if(M=N[p],A=d[p],M===65535){u.push(0),C.push(0);break}if(M-(F=r[M].new)>=32768)for(u.push(0),C.push(2*(h.length+O-p)),i=j=M;M<=A?j<=A:j>=A;i=M<=A?++j:--j)h.push(r[i].new);else u.push(F-M),C.push(0)}for(L.writeUInt16(3),L.writeUInt16(1),L.writeUInt32(12),L.writeUInt16(4),L.writeUInt16(16+8*O+2*h.length),L.writeUInt16(0),L.writeUInt16(Y),L.writeUInt16(k),L.writeUInt16(f),L.writeUInt16(B),fe=0,U=d.length;fe<U;fe++)i=d[fe],L.writeUInt16(i);for(L.writeUInt16(0),de=0,W=N.length;de<W;de++)i=N[de],L.writeUInt16(i);for(ge=0,$=u.length;ge<$;ge++)s=u[ge],L.writeUInt16(s);for(Be=0,re=C.length;Be<re;Be++)w=C[Be],L.writeUInt16(w);for(xe=0,me=h.length;xe<me;xe++)m=h[xe],L.writeUInt16(m);return{charMap:r,subtable:L.data,maxGlyphID:b+1}}},e}(),JV=function(e){function t(){return t.__super__.constructor.apply(this,arguments)}return _u(t,yl),t.prototype.tag="cmap",t.prototype.parse=function(n){var r,i,a;for(n.pos=this.offset,this.version=n.readUInt16(),a=n.readUInt16(),this.tables=[],this.unicode=null,i=0;0<=a?i<a:i>a;i=0<=a?++i:--i)r=new XV(n,this.offset),this.tables.push(r),r.isUnicode&&this.unicode==null&&(this.unicode=r);return!0},t.encode=function(n,r){var i,a;return r==null&&(r="macroman"),i=XV.encode(n,r),(a=new ZA).writeUInt16(0),a.writeUInt16(1),i.table=a.data.concat(i.subtable),i},t}(),nUe=function(e){function t(){return t.__super__.constructor.apply(this,arguments)}return _u(t,yl),t.prototype.tag="hhea",t.prototype.parse=function(n){return n.pos=this.offset,this.version=n.readInt(),this.ascender=n.readShort(),this.decender=n.readShort(),this.lineGap=n.readShort(),this.advanceWidthMax=n.readShort(),this.minLeftSideBearing=n.readShort(),this.minRightSideBearing=n.readShort(),this.xMaxExtent=n.readShort(),this.caretSlopeRise=n.readShort(),this.caretSlopeRun=n.readShort(),this.caretOffset=n.readShort(),n.pos+=8,this.metricDataFormat=n.readShort(),this.numberOfMetrics=n.readUInt16()},t}(),rUe=function(e){function t(){return t.__super__.constructor.apply(this,arguments)}return _u(t,yl),t.prototype.tag="OS/2",t.prototype.parse=function(n){if(n.pos=this.offset,this.version=n.readUInt16(),this.averageCharWidth=n.readShort(),this.weightClass=n.readUInt16(),this.widthClass=n.readUInt16(),this.type=n.readShort(),this.ySubscriptXSize=n.readShort(),this.ySubscriptYSize=n.readShort(),this.ySubscriptXOffset=n.readShort(),this.ySubscriptYOffset=n.readShort(),this.ySuperscriptXSize=n.readShort(),this.ySuperscriptYSize=n.readShort(),this.ySuperscriptXOffset=n.readShort(),this.ySuperscriptYOffset=n.readShort(),this.yStrikeoutSize=n.readShort(),this.yStrikeoutPosition=n.readShort(),this.familyClass=n.readShort(),this.panose=function(){var r,i;for(i=[],r=0;r<10;++r)i.push(n.readByte());return i}(),this.charRange=function(){var r,i;for(i=[],r=0;r<4;++r)i.push(n.readInt());return i}(),this.vendorID=n.readString(4),this.selection=n.readShort(),this.firstCharIndex=n.readShort(),this.lastCharIndex=n.readShort(),this.version>0&&(this.ascent=n.readShort(),this.descent=n.readShort(),this.lineGap=n.readShort(),this.winAscent=n.readShort(),this.winDescent=n.readShort(),this.codePageRange=function(){var r,i;for(i=[],r=0;r<2;r=++r)i.push(n.readInt());return i}(),this.version>1))return this.xHeight=n.readShort(),this.capHeight=n.readShort(),this.defaultChar=n.readShort(),this.breakChar=n.readShort(),this.maxContext=n.readShort()},t}(),iUe=function(e){function t(){return t.__super__.constructor.apply(this,arguments)}return _u(t,yl),t.prototype.tag="post",t.prototype.parse=function(n){var r,i,a;switch(n.pos=this.offset,this.format=n.readInt(),this.italicAngle=n.readInt(),this.underlinePosition=n.readShort(),this.underlineThickness=n.readShort(),this.isFixedPitch=n.readInt(),this.minMemType42=n.readInt(),this.maxMemType42=n.readInt(),this.minMemType1=n.readInt(),this.maxMemType1=n.readInt(),this.format){case 65536:break;case 131072:var o;for(i=n.readUInt16(),this.glyphNameIndex=[],o=0;0<=i?o<i:o>i;o=0<=i?++o:--o)this.glyphNameIndex.push(n.readUInt16());for(this.names=[],a=[];n.pos<this.offset+this.length;)r=n.readByte(),a.push(this.names.push(n.readString(r)));return a;case 151552:return i=n.readUInt16(),this.offsets=n.read(i);case 196608:break;case 262144:return this.map=(function(){var s,u,c;for(c=[],o=s=0,u=this.file.maxp.numGlyphs;0<=u?s<u:s>u;o=0<=u?++s:--s)c.push(n.readUInt32());return c}).call(this)}},t}(),aUe=function(e,t){this.raw=e,this.length=e.length,this.platformID=t.platformID,this.encodingID=t.encodingID,this.languageID=t.languageID},oUe=function(e){function t(){return t.__super__.constructor.apply(this,arguments)}return _u(t,yl),t.prototype.tag="name",t.prototype.parse=function(n){var r,i,a,o,s,u,c,A,d,f,h;for(n.pos=this.offset,n.readShort(),r=n.readShort(),u=n.readShort(),i=[],o=0;0<=r?o<r:o>r;o=0<=r?++o:--o)i.push({platformID:n.readShort(),encodingID:n.readShort(),languageID:n.readShort(),nameID:n.readShort(),length:n.readShort(),offset:this.offset+u+n.readShort()});for(c={},o=d=0,f=i.length;d<f;o=++d)a=i[o],n.pos=a.offset,A=n.readString(a.length),s=new aUe(A,a),c[h=a.nameID]==null&&(c[h]=[]),c[a.nameID].push(s);this.strings=c,this.copyright=c[0],this.fontFamily=c[1],this.fontSubfamily=c[2],this.uniqueSubfamily=c[3],this.fontName=c[4],this.version=c[5];try{this.postscriptName=c[6][0].raw.replace(/[\x00-\x19\x80-\xff]/g,"")}catch{this.postscriptName=c[4][0].raw.replace(/[\x00-\x19\x80-\xff]/g,"")}return this.trademark=c[7],this.manufacturer=c[8],this.designer=c[9],this.description=c[10],this.vendorUrl=c[11],this.designerUrl=c[12],this.license=c[13],this.licenseUrl=c[14],this.preferredFamily=c[15],this.preferredSubfamily=c[17],this.compatibleFull=c[18],this.sampleText=c[19]},t}(),sUe=function(e){function t(){return t.__super__.constructor.apply(this,arguments)}return _u(t,yl),t.prototype.tag="maxp",t.prototype.parse=function(n){return n.pos=this.offset,this.version=n.readInt(),this.numGlyphs=n.readUInt16(),this.maxPoints=n.readUInt16(),this.maxContours=n.readUInt16(),this.maxCompositePoints=n.readUInt16(),this.maxComponentContours=n.readUInt16(),this.maxZones=n.readUInt16(),this.maxTwilightPoints=n.readUInt16(),this.maxStorage=n.readUInt16(),this.maxFunctionDefs=n.readUInt16(),this.maxInstructionDefs=n.readUInt16(),this.maxStackElements=n.readUInt16(),this.maxSizeOfInstructions=n.readUInt16(),this.maxComponentElements=n.readUInt16(),this.maxComponentDepth=n.readUInt16()},t}(),lUe=function(e){function t(){return t.__super__.constructor.apply(this,arguments)}return _u(t,yl),t.prototype.tag="hmtx",t.prototype.parse=function(n){var r,i,a,o,s,u,c;for(n.pos=this.offset,this.metrics=[],r=0,u=this.file.hhea.numberOfMetrics;0<=u?r<u:r>u;r=0<=u?++r:--r)this.metrics.push({advance:n.readUInt16(),lsb:n.readInt16()});for(a=this.file.maxp.numGlyphs-this.file.hhea.numberOfMetrics,this.leftSideBearings=function(){var A,d;for(d=[],r=A=0;0<=a?A<a:A>a;r=0<=a?++A:--A)d.push(n.readInt16());return d}(),this.widths=(function(){var A,d,f,h;for(h=[],A=0,d=(f=this.metrics).length;A<d;A++)o=f[A],h.push(o.advance);return h}).call(this),i=this.widths[this.widths.length-1],c=[],r=s=0;0<=a?s<a:s>a;r=0<=a?++s:--s)c.push(this.widths.push(i));return c},t.prototype.forGlyph=function(n){return n in this.metrics?this.metrics[n]:{advance:this.metrics[this.metrics.length-1].advance,lsb:this.leftSideBearings[n-this.metrics.length]}},t}(),ZV=[].slice,uUe=function(e){function t(){return t.__super__.constructor.apply(this,arguments)}return _u(t,yl),t.prototype.tag="glyf",t.prototype.parse=function(){return this.cache={}},t.prototype.glyphFor=function(n){var r,i,a,o,s,u,c,A,d,f;return n in this.cache?this.cache[n]:(o=this.file.loca,r=this.file.contents,i=o.indexOf(n),(a=o.lengthOf(n))===0?this.cache[n]=null:(r.pos=this.offset+i,s=(u=new ZA(r.read(a))).readShort(),A=u.readShort(),f=u.readShort(),c=u.readShort(),d=u.readShort(),this.cache[n]=s===-1?new AUe(u,A,f,c,d):new cUe(u,s,A,f,c,d),this.cache[n]))},t.prototype.encode=function(n,r,i){var a,o,s,u,c;for(s=[],o=[],u=0,c=r.length;u<c;u++)a=n[r[u]],o.push(s.length),a&&(s=s.concat(a.encode(i)));return o.push(s.length),{table:s,offsets:o}},t}(),cUe=function(){function e(t,n,r,i,a,o){this.raw=t,this.numberOfContours=n,this.xMin=r,this.yMin=i,this.xMax=a,this.yMax=o,this.compound=!1}return e.prototype.encode=function(){return this.raw.data},e}(),AUe=function(){function e(t,n,r,i,a){var o,s;for(this.raw=t,this.xMin=n,this.yMin=r,this.xMax=i,this.yMax=a,this.compound=!0,this.glyphIDs=[],this.glyphOffsets=[],o=this.raw;s=o.readShort(),this.glyphOffsets.push(o.pos),this.glyphIDs.push(o.readUInt16()),32&s;)o.pos+=1&s?4:2,128&s?o.pos+=8:64&s?o.pos+=4:8&s&&(o.pos+=2)}return e.prototype.encode=function(){var t,n,r;for(n=new ZA(ZV.call(this.raw.data)),t=0,r=this.glyphIDs.length;t<r;++t)n.pos=this.glyphOffsets[t];return n.data},e}(),dUe=function(e){function t(){return t.__super__.constructor.apply(this,arguments)}return _u(t,yl),t.prototype.tag="loca",t.prototype.parse=function(n){var r,i;return n.pos=this.offset,r=this.file.head.indexToLocFormat,this.offsets=r===0?(function(){var a,o;for(o=[],i=0,a=this.length;i<a;i+=2)o.push(2*n.readUInt16());return o}).call(this):(function(){var a,o;for(o=[],i=0,a=this.length;i<a;i+=4)o.push(n.readUInt32());return o}).call(this)},t.prototype.indexOf=function(n){return this.offsets[n]},t.prototype.lengthOf=function(n){return this.offsets[n+1]-this.offsets[n]},t.prototype.encode=function(n,r){for(var i=new Uint32Array(this.offsets.length),a=0,o=0,s=0;s<i.length;++s)if(i[s]=a,o<r.length&&r[o]==s){++o,i[s]=a;var u=this.offsets[s],c=this.offsets[s+1]-u;c>0&&(a+=c)}for(var A=new Array(4*i.length),d=0;d<i.length;++d)A[4*d+3]=255&i[d],A[4*d+2]=(65280&i[d])>>8,A[4*d+1]=(16711680&i[d])>>16,A[4*d]=(4278190080&i[d])>>24;return A},t}(),fUe=function(){function e(t){this.font=t,this.subset={},this.unicodes={},this.next=33}return e.prototype.generateCmap=function(){var t,n,r,i,a;for(n in i=this.font.cmap.tables[0].codeMap,t={},a=this.subset)r=a[n],t[n]=i[r];return t},e.prototype.glyphsFor=function(t){var n,r,i,a,o,s,u;for(i={},o=0,s=t.length;o<s;o++)i[a=t[o]]=this.font.glyf.glyphFor(a);for(a in n=[],i)(r=i[a])!=null&&r.compound&&n.push.apply(n,r.glyphIDs);if(n.length>0)for(a in u=this.glyphsFor(n))r=u[a],i[a]=r;return i},e.prototype.encode=function(t,n){var r,i,a,o,s,u,c,A,d,f,h,p,m,v,y;for(i in r=JV.encode(this.generateCmap(),"unicode"),o=this.glyphsFor(t),h={0:0},y=r.charMap)h[(u=y[i]).old]=u.new;for(p in f=r.maxGlyphID,o)p in h||(h[p]=f++);return A=function(g){var b,w;for(b in w={},g)w[g[b]]=b;return w}(h),d=Object.keys(A).sort(function(g,b){return g-b}),m=function(){var g,b,w;for(w=[],g=0,b=d.length;g<b;g++)s=d[g],w.push(A[s]);return w}(),a=this.font.glyf.encode(o,m,h),c=this.font.loca.encode(a.offsets,m),v={cmap:this.font.cmap.raw(),glyf:a.table,loca:c,hmtx:this.font.hmtx.raw(),hhea:this.font.hhea.raw(),maxp:this.font.maxp.raw(),post:this.font.post.raw(),name:this.font.name.raw(),head:this.font.head.encode(n)},this.font.os2.exists&&(v["OS/2"]=this.font.os2.raw()),this.font.directory.encode(v)},e}();mn.API.PDFObject=function(){var e;function t(){}return e=function(n,r){return(Array(r+1).join("0")+n).slice(-r)},t.convert=function(n){var r,i,a,o;if(Array.isArray(n))return"["+function(){var s,u,c;for(c=[],s=0,u=n.length;s<u;s++)r=n[s],c.push(t.convert(r));return c}().join(" ")+"]";if(typeof n=="string")return"/"+n;if(n!=null&&n.isString)return"("+n+")";if(n instanceof Date)return"(D:"+e(n.getUTCFullYear(),4)+e(n.getUTCMonth(),2)+e(n.getUTCDate(),2)+e(n.getUTCHours(),2)+e(n.getUTCMinutes(),2)+e(n.getUTCSeconds(),2)+"Z)";if({}.toString.call(n)==="[object Object]"){for(i in a=["<<"],n)o=n[i],a.push("/"+i+" "+t.convert(o));return a.push(">>"),a.join(`
|
|
428
428
|
`)}return""+n},t}();const hUe=(e,t)=>{const n=new Blob([e],{type:"text/plain"}),r=document.createEvent("MouseEvents"),i=document.createElement("a");i.download=t,i.href=window.URL.createObjectURL(n),i.dataset.downloadurl=["text/csv",i.download,i.href].join(":"),r.initEvent("click",!0,!1,window,0,0,0,0,0,!1,!1,!1,!1,0,null),i.dispatchEvent(r)},pUe=(e,t)=>{let n=e.map(i=>i.header).join(",")+`
|
|
429
429
|
`;const r={};return e.forEach((i,a)=>{r[i.field]=a}),t.forEach(i=>{let a="";Object.keys(r).forEach(o=>{let s=i[o];typeof s>"u"&&(s=""),typeof s=="string"&&(s=s.replace(", "," ").replace(","," ")),a+='"'+s+'",'}),n+=a.slice(0,-1)+`
|
|
430
|
-
`}),n},mUe=(e,t,n)=>{const r=pUe(t,n);hUe(r,`${e||"data"}.csv`)},gUe={key:0,class:"block truncate overflow-hidden text-ellipsis pr-6 w-full pb-1.5"},vUe={class:"leading-[1] font-semibold text-md"},yUe={key:2,class:"absolute right-2 top-2"},bUe={key:1,class:"flex justify-center pt-10 text-lg font-semibold"},TM={__name:"Panel",props:{objects:Array,panel:Object,layout:Object,viewing:{type:Boolean,default:!1},mouseover:{type:Boolean,default:!1},isMobile:{type:Boolean,default:!1},theme:{type:String,default:"light"}},emits:["delete","edit"],setup(e,{emit:t}){const n={Alert:ZY,AlertSprite:$Y,Chart:eR,Counter:tR,Histogram:UR,Image:PR,IPMap:DR,MetricChart:HR,PieChart:YR,SparkChart:RR,StackedBarChart:QR,Table:jR,Text:VR,TopNChart:zR},r=e,i=t,a=l.ref(u()),o=l.computed(()=>r.panel.panelType==="text"||r.panel.panelType==="image"||a.value.table&&a.value.table.rows||a.value.stream?!1:!(a.value.alert&&a.value.alert.alerts));function s(){return!r.panel||!r.panel.panelType?"":n[oQ[r.panel.panelType]]}function u(){const A=r.objects.find(d=>d.name===r.panel.dataTable);return A||{}}function c(){mUe(r.panel.title,r.panel.panelConfig.columns,a.value.table.rows)}return(A,d)=>(l.openBlock(),l.createElementBlock(l.Fragment,null,[l.createElementVNode("div",{class:l.normalizeClass(["relative pl-2 w-full",e.panel.panelType==="image"||e.panel.panelType==="text"?"":"py-1"])},[e.panel.title?(l.openBlock(),l.createElementBlock("div",gUe,[l.createElementVNode("span",vUe,l.toDisplayString(e.panel.title),1)])):l.createCommentVNode("",!0),e.viewing?e.viewing&&e.panel.panelType==="table"&&e.mouseover?(l.openBlock(),l.createElementBlock("div",yUe,[l.createVNode(l.unref(E1),{download:"",hideTooltip:"",onDownload:c})])):l.createCommentVNode("",!0):(l.openBlock(),l.createBlock(l.unref(Nu),{key:1,as:"div",class:"absolute right-1 top-2"},{default:l.withCtx(()=>[l.createVNode(l.unref(Fu),{class:"-m-2.5 block p-2.5 text-gray-400 hover:text-gray-500"},{default:l.withCtx(()=>[d[2]||(d[2]=l.createElementVNode("span",{class:"sr-only"},"Open options",-1)),l.createVNode(l.unref(L6),{class:"icon-md","aria-hidden":"true"})]),_:1,__:[2]}),l.createVNode(l.Transition,{"enter-active-class":"transition ease-out duration-100","enter-from-class":"transform opacity-0 scale-95","enter-to-class":"transform opacity-100 scale-100","leave-active-class":"transition ease-in duration-75","leave-from-class":"transform opacity-100 scale-100","leave-to-class":"transform opacity-0 scale-95"},{default:l.withCtx(()=>[l.createVNode(l.unref(Iu),{class:"absolute right-0 z-10 mt-0.5 w-32 origin-top-right rounded-md py-2 shadow-lg ring-1 ring-gray-900/5 focus:outline-none bg-white dark:bg-black"},{default:l.withCtx(()=>[l.createVNode(l.unref(is),null,{default:l.withCtx(({active:f})=>[l.createElementVNode("div",{class:l.normalizeClass([f?"cursor-pointer bg-gray-50 dark:bg-gray-800":"","block px-3 py-1 text-sm leading-6"]),onClick:d[0]||(d[0]=h=>i("edit",e.panel))}," Edit ",2)]),_:1}),e.panel.panelType==="table"?(l.openBlock(),l.createBlock(l.unref(is),{key:0},{default:l.withCtx(({active:f})=>[l.createElementVNode("div",{class:l.normalizeClass([f?"cursor-pointer bg-gray-50 dark:bg-gray-800":"","block px-3 py-1 text-sm leading-6"]),onClick:c}," Download CSV ",2)]),_:1})):l.createCommentVNode("",!0),l.createVNode(l.unref(is),null,{default:l.withCtx(({active:f})=>[l.createElementVNode("div",{class:l.normalizeClass([f?"cursor-pointer bg-gray-50 dark:bg-gray-800":"","block px-3 py-1 text-sm leading-6"]),onClick:d[1]||(d[1]=h=>i("delete",e.panel.key))}," Delete ",2)]),_:1})]),_:1})]),_:1})]),_:1}))],2),o.value?(l.openBlock(),l.createElementBlock("span",bUe," No data available ")):(l.openBlock(),l.createBlock(l.resolveDynamicComponent(s()),{key:0,config:e.panel.panelConfig,obj:a.value,id:`panel${e.panel.key}${e.isMobile?"-mobile":""}`,layout:e.layout,class:l.normalizeClass(e.panel.panelType==="image"||e.panel.panelType==="text"?"":"p-2"),theme:e.theme},null,8,["config","obj","id","layout","class","theme"]))],64))}};function _Ue(e){return{all:e=e||new Map,on:function(t,n){var r=e.get(t);r?r.push(n):e.set(t,[n])},off:function(t,n){var r=e.get(t);r&&(n?r.splice(r.indexOf(n)>>>0,1):e.set(t,[]))},emit:function(t,n){var r=e.get(t);r&&r.slice().map(function(i){i(n)}),(r=e.get("*"))&&r.slice().map(function(i){i(t,n)})}}}function wUe(e){let t=0,n;for(let r=0,i=e.length;r<i;r++)n=e[r].y+e[r].h,n>t&&(t=n);return t}function NM(e){const t=Array(e.length);for(let n=0,r=e.length;n<r;n++)t[n]=xUe(e[n]);return t}function xUe(e){return JSON.parse(JSON.stringify(e))}function $V(e,t){return!(e===t||e.x+e.w<=t.x||e.x>=t.x+t.w||e.y+e.h<=t.y||e.y>=t.y+t.h)}function Wp(e,t,n){const r=nz(e),i=iz(e),a=Array(e.length);for(let o=0,s=i.length;o<s;o++){let u=i[o];u.static||(u=BUe(r,u,t,n),r.push(u)),a[e.indexOf(u)]=u,u.moved=!1}return a}function BUe(e,t,n,r){if(n)for(;t.y>0&&!tv(e,t);)t.y--;else if(r){const a=r[t.i].y;for(;t.y>a&&!tv(e,t);)t.y--}let i;for(;i=tv(e,t);)t.y=i.y+i.h;return t}function CUe(e,t){const n=nz(e);for(let r=0,i=e.length;r<i;r++){const a=e[r];if(a.x+a.w>t.cols&&(a.x=t.cols-a.w),a.x<0&&(a.x=0,a.w=t.cols),!a.static)n.push(a);else for(;tv(n,a);)a.y++}return e}function ez(e,t){for(let n=0,r=e.length;n<r;n++)if(e[n].i===t)return e[n]}function tv(e,t){for(let n=0,r=e.length;n<r;n++)if($V(e[n],t))return e[n]}function tz(e,t){return e.filter(n=>$V(n,t))}function nz(e){return e.filter(t=>t.static)}function FM(e,t,n,r,i,a){if(t.static)return e;const o=t.x,s=t.y,u=r&&t.y>r;typeof n=="number"&&(t.x=n),typeof r=="number"&&(t.y=r),t.moved=!0;let c=iz(e);u&&(c=c.reverse());const A=tz(c,t);if(a&&A.length)return t.x=o,t.y=s,t.moved=!1,e;for(let d=0,f=A.length;d<f;d++){const h=A[d];h.moved||t.y>h.y&&t.y-h.y>h.h/4||(h.static?e=rz(e,h,t,i):e=rz(e,t,h,i))}return e}function rz(e,t,n,r){if(r){const a={x:n.x,y:n.y,w:n.w,h:n.h};if(a.y=Math.max(t.y-n.h,0),!tv(e,a))return FM(e,n,void 0,a.y,!1)}return FM(e,n,void 0,n.y+1,!1)}function SUe(e,t,n,r){const i="translate3d("+t+"px,"+e+"px, 0)";return{transform:i,WebkitTransform:i,MozTransform:i,msTransform:i,OTransform:i,width:n+"px",height:r+"px",position:"absolute"}}function MUe(e,t,n,r){const i="translate3d("+t*-1+"px,"+e+"px, 0)";return{transform:i,WebkitTransform:i,MozTransform:i,msTransform:i,OTransform:i,width:n+"px",height:r+"px",position:"absolute"}}function kUe(e,t,n,r){return{top:e+"px",left:t+"px",width:n+"px",height:r+"px",position:"absolute"}}function EUe(e,t,n,r){return{top:e+"px",right:t+"px",width:n+"px",height:r+"px",position:"absolute"}}function iz(e){return[].concat(e).sort(function(n,r){return n.y===r.y&&n.x===r.x?0:n.y>r.y||n.y===r.y&&n.x>r.x?1:-1})}function LUe(e,t){t=t||"Layout";const n=["x","y","w","h"],r=[];if(!Array.isArray(e))throw new Error(t+" must be an array!");for(let i=0,a=e.length;i<a;i++){const o=e[i];for(let s=0;s<n.length;s++)if(typeof o[n[s]]!="number")throw new Error("VueGridLayout: "+t+"["+i+"]."+n[s]+" must be a number!");if(o.i===void 0||o.i===null)throw new Error("VueGridLayout: "+t+"["+i+"].i cannot be null!");if(typeof o.i!="number"&&typeof o.i!="string")throw new Error("VueGridLayout: "+t+"["+i+"].i must be a string or number!");if(r.indexOf(o.i)>=0)throw new Error("VueGridLayout: "+t+"["+i+"].i must be unique!");if(r.push(o.i),o.static!==void 0&&typeof o.static!="boolean")throw new Error("VueGridLayout: "+t+"["+i+"].static must be a boolean!")}}function az(e){return TUe(e)}function TUe(e){const t=e.target,n=t.offsetParent||document.body,r=t.offsetParent===document.body?{left:0,top:0}:n.getBoundingClientRect(),i=e.clientX+n.scrollLeft-r.left,a=e.clientY+n.scrollTop-r.top;return{x:i,y:a}}function oz(e,t,n,r){return NUe(e)?{deltaX:n-e,deltaY:r-t,lastX:e,lastY:t,x:n,y:r}:{deltaX:0,deltaY:0,lastX:n,lastY:r,x:n,y:r}}function NUe(e){return typeof e=="number"&&!isNaN(e)}function FUe(e,t){const n=sz(e);let r=n[0];for(let i=1,a=n.length;i<a;i++){const o=n[i];t>e[o]&&(r=o)}return r}function IM(e,t){if(!t[e])throw new Error("ResponsiveGridLayout: `cols` entry for breakpoint "+e+" is missing!");return t[e]}function IUe(e,t,n,r,i,a,o){if(t[r])return NM(t[r]);let s=e;const u=sz(n),c=u.slice(u.indexOf(r));for(let A=0,d=c.length;A<d;A++){const f=c[A];if(t[f]){s=t[f];break}}return s=NM(s||[]),Wp(CUe(s,{cols:a}),o)}function sz(e){return Object.keys(e).sort(function(n,r){return e[n]-e[r]})}let OUe="auto";function DUe(){return typeof document<"u"}function lz(){return typeof window<"u"}function uz(){return DUe()?typeof document.dir<"u"?document.dir:document.getElementsByTagName("html")[0].getAttribute("dir")||"auto":OUe}function UUe(e,t){return lz?(window.addEventListener(e,t),!0):(t(),!1)}function PUe(e,t){lz&&window.removeEventListener(e,t)}const Xr={init:HUe,document:null,DocumentFragment:null,SVGElement:null,SVGSVGElement:null,SVGElementInstance:null,Element:null,HTMLElement:null,Event:null,Touch:null,PointerEvent:null};function Xp(){}function HUe(e){const t=e;Xr.document=t.document,Xr.DocumentFragment=t.DocumentFragment||Xp,Xr.SVGElement=t.SVGElement||Xp,Xr.SVGSVGElement=t.SVGSVGElement||Xp,Xr.SVGElementInstance=t.SVGElementInstance||Xp,Xr.Element=t.Element||Xp,Xr.HTMLElement=t.HTMLElement||Xr.Element,Xr.Event=t.Event,Xr.Touch=t.Touch||Xp,Xr.PointerEvent=t.PointerEvent||t.MSPointerEvent}var cz=e=>!!(e&&e.Window)&&e instanceof e.Window;let Az,$A;function dz(e){Az=e;const t=e.document.createTextNode("");t.ownerDocument!==e.document&&typeof e.wrap=="function"&&e.wrap(t)===t&&(e=e.wrap(e)),$A=e}typeof window<"u"&&window&&dz(window);function Hf(e){return cz(e)?e:(e.ownerDocument||e).defaultView||$A.window}const YUe=e=>e===$A||cz(e),RUe=e=>g2(e)&&e.nodeType===11,g2=e=>!!e&&typeof e=="object",fz=e=>typeof e=="function";var mt={window:YUe,docFrag:RUe,object:g2,func:fz,number:e=>typeof e=="number",bool:e=>typeof e=="boolean",string:e=>typeof e=="string",element:e=>{if(!e||typeof e!="object")return!1;const t=Hf(e)||$A;return/object|function/.test(typeof Element)?e instanceof Element||e instanceof t.Element:e.nodeType===1&&typeof e.nodeName=="string"},plainObject:e=>g2(e)&&!!e.constructor&&/function Object\b/.test(e.constructor.toString()),array:e=>g2(e)&&typeof e.length<"u"&&fz(e.splice)};const vi={init:QUe,supportsTouch:null,supportsPointerEvent:null,isIOS7:null,isIOS:null,isIe9:null,isOperaMobile:null,prefixedMatchesSelector:null,pEventTypes:null,wheelEvent:null};function QUe(e){const t=Xr.Element,n=e.navigator||{};vi.supportsTouch="ontouchstart"in e||mt.func(e.DocumentTouch)&&Xr.document instanceof e.DocumentTouch,vi.supportsPointerEvent=n.pointerEnabled!==!1&&!!Xr.PointerEvent,vi.isIOS=/iP(hone|od|ad)/.test(n.platform),vi.isIOS7=/iP(hone|od|ad)/.test(n.platform)&&/OS 7[^\d]/.test(n.appVersion),vi.isIe9=/MSIE 9/.test(n.userAgent),vi.isOperaMobile=n.appName==="Opera"&&vi.supportsTouch&&/Presto/.test(n.userAgent),vi.prefixedMatchesSelector="matches"in t.prototype?"matches":"webkitMatchesSelector"in t.prototype?"webkitMatchesSelector":"mozMatchesSelector"in t.prototype?"mozMatchesSelector":"oMatchesSelector"in t.prototype?"oMatchesSelector":"msMatchesSelector",vi.pEventTypes=vi.supportsPointerEvent?Xr.PointerEvent===e.MSPointerEvent?{up:"MSPointerUp",down:"MSPointerDown",over:"mouseover",out:"mouseout",move:"MSPointerMove",cancel:"MSPointerCancel"}:{up:"pointerup",down:"pointerdown",over:"pointerover",out:"pointerout",move:"pointermove",cancel:"pointercancel"}:null,vi.wheelEvent=Xr.document&&"onmousewheel"in Xr.document?"mousewheel":"wheel"}function Yf(e,t){if(e.contains)return e.contains(t);for(;t;){if(t===e)return!0;t=t.parentNode}return!1}function hz(e,t){for(;mt.element(e);){if(Rf(e,t))return e;e=ed(e)}return null}function ed(e){let t=e.parentNode;if(mt.docFrag(t)){for(;(t=t.host)&&mt.docFrag(t););return t}return t}function Rf(e,t){return $A!==Az&&(t=t.replace(/\/deep\//g," ")),e[vi.prefixedMatchesSelector](t)}function OM(e,t,n){for(;mt.element(e);){if(Rf(e,t))return!0;if(e=ed(e),e===n)return Rf(e,t)}return!1}function pz(e){return e.correspondingUseElement||e}function jUe(e){return e=e||$A,{x:e.scrollX||e.document.documentElement.scrollLeft,y:e.scrollY||e.document.documentElement.scrollTop}}function DM(e){const t=e instanceof Xr.SVGElement?e.getBoundingClientRect():e.getClientRects()[0];return t&&{left:t.left,right:t.right,top:t.top,bottom:t.bottom,width:t.width||t.right-t.left,height:t.height||t.bottom-t.top}}function UM(e){const t=DM(e);if(!vi.isIOS7&&t){const n=jUe(Hf(e));t.left+=n.x,t.right+=n.x,t.top+=n.y,t.bottom+=n.y}return t}function mz(e){return mt.string(e)?(Xr.document.querySelector(e),!0):!1}function fn(e,t){for(const r in t)e[r]=t[r];return e}function nv(e,t){let n=!1;return function(){return n||($A.console.warn(t),n=!0),e.apply(this,arguments)}}function gz(e,t){return e.name=t.name,e.axis=t.axis,e.edges=t.edges,e}function VUe(e){const{Interactable:t}=e;t.prototype.getAction=function(r,i,a,o){const s=zUe(this,i,a,o,e);return this.options.actionChecker?this.options.actionChecker(r,i,s,this,o,a):s},t.prototype.ignoreFrom=nv(function(n){return this._backCompatOption("ignoreFrom",n)},"Interactable.ignoreFrom() has been deprecated. Use Interactble.draggable({ignoreFrom: newValue})."),t.prototype.allowFrom=nv(function(n){return this._backCompatOption("allowFrom",n)},"Interactable.allowFrom() has been deprecated. Use Interactble.draggable({allowFrom: newValue})."),t.prototype.actionChecker=KUe,t.prototype.styleCursor=qUe}function zUe(e,t,n,r,i){const a=e.getRect(r),o=t.buttons||{0:1,1:4,3:8,4:16}[t.button],s={action:null,interactable:e,interaction:n,element:r,rect:a,buttons:o};return i.fire("auto-start:check",s),s.action}function qUe(e){return mt.bool(e)?(this.options.styleCursor=e,this):e===null?(delete this.options.styleCursor,this):this.options.styleCursor}function KUe(e){return mt.func(e)?(this.options.actionChecker=e,this):e===null?(delete this.options.actionChecker,this):this.options.actionChecker}var GUe={id:"auto-start/interactableMethods",install:VUe};function WUe(e){const{interactStatic:t,defaults:n}=e;e.usePlugin(GUe),n.base.actionChecker=null,n.base.styleCursor=!0,fn(n.perAction,{manualStart:!1,max:1/0,maxPerElement:1,allowFrom:null,ignoreFrom:null,mouseButtons:1}),t.maxInteractions=r=>_z(r,e),e.autoStart={maxInteractions:1/0,withinInteractionLimit:v2,cursorElement:null}}function XUe(e,t){let{interaction:n,pointer:r,event:i,eventTarget:a}=e;if(n.interacting())return;const o=yz(n,r,i,a,t);bz(n,o,t)}function JUe(e,t){let{interaction:n,pointer:r,event:i,eventTarget:a}=e;if(n.pointerType!=="mouse"||n.pointerIsDown||n.interacting())return;const o=yz(n,r,i,a,t);bz(n,o,t)}function ZUe(e,t){const{interaction:n}=e;if(!n.pointerIsDown||n.interacting()||!n.pointerWasMoved||!n.prepared.name)return;t.fire("autoStart:before-start",e);const{interactable:r}=n,i=n.prepared.name;i&&r&&(r.options[i].manualStart||!v2(r,n.element,n.prepared,t)?n.stop():(n.start(n.prepared,r,n.element),wz(n,t)))}function $Ue(e,t){let{interaction:n}=e;const{interactable:r}=n;r&&r.options.styleCursor&&PM(n.element,"",t)}function vz(e,t,n,r,i){return t.testIgnoreAllow(t.options[e.name],n,r)&&t.options[e.name].enabled&&v2(t,n,e,i)?e:null}function ePe(e,t,n,r,i,a,o){for(let s=0,u=r.length;s<u;s++){const c=r[s],A=i[s],d=c.getAction(t,n,e,A);if(!d)continue;const f=vz(d,c,A,a,o);if(f)return{action:f,interactable:c,element:A}}return{action:null,interactable:null,element:null}}function yz(e,t,n,r,i){let a=[],o=[],s=r;function u(c){a.push(c),o.push(s)}for(;mt.element(s);){a=[],o=[],i.interactables.forEachMatch(s,u);const c=ePe(e,t,n,a,o,r,i);if(c.action&&!c.interactable.options[c.action.name].manualStart)return c;s=ed(s)}return{action:null,interactable:null,element:null}}function bz(e,t,n){let{action:r,interactable:i,element:a}=t;r=r||{name:null},e.interactable=i,e.element=a,gz(e.prepared,r),e.rect=i&&r.name?i.getRect(a):null,wz(e,n),n.fire("autoStart:prepared",{interaction:e})}function v2(e,t,n,r){const i=e.options,a=i[n.name].max,o=i[n.name].maxPerElement,s=r.autoStart.maxInteractions;let u=0,c=0,A=0;if(!(a&&o&&s))return!1;for(const d of r.interactions.list){const f=d.prepared.name;if(d.interacting()){if(u++,u>=s)return!1;if(d.interactable===e&&(c+=f===n.name?1:0,c>=a||d.element===t&&(A++,f===n.name&&A>=o)))return!1}}return s>0}function _z(e,t){return mt.number(e)?(t.autoStart.maxInteractions=e,this):t.autoStart.maxInteractions}function PM(e,t,n){const{cursorElement:r}=n.autoStart;r&&r!==e&&(r.style.cursor=""),e.ownerDocument.documentElement.style.cursor=t,e.style.cursor=t,n.autoStart.cursorElement=t?e:null}function wz(e,t){const{interactable:n,element:r,prepared:i}=e;if(!(e.pointerType==="mouse"&&n&&n.options.styleCursor)){t.autoStart.cursorElement&&PM(t.autoStart.cursorElement,"",t);return}let a="";if(i.name){const o=n.options[i.name].cursorChecker;mt.func(o)?a=o(i,n,r,e._interacting):a=t.actions.map[i.name].getCursor(i)}PM(e.element,a||"",t)}const HM={id:"auto-start/base",before:["actions"],install:WUe,listeners:{"interactions:down":XUe,"interactions:move":(e,t)=>{JUe(e,t),ZUe(e,t)},"interactions:stop":$Ue},maxInteractions:_z,withinInteractionLimit:v2,validateAction:vz};function tPe(e,t){let{interaction:n,eventTarget:r,dx:i,dy:a}=e;if(n.prepared.name!=="drag")return;const o=Math.abs(i),s=Math.abs(a),u=n.interactable.options.drag,c=u.startAxis,A=o>s?"x":o<s?"y":"xy";if(n.prepared.axis=u.lockAxis==="start"?A[0]:u.lockAxis,A!=="xy"&&c!=="xy"&&c!==A){n.prepared.name=null;let d=r;const f=function(h){if(h===n.interactable)return;const p=n.interactable.options.drag;if(!p.manualStart&&h.testIgnoreAllow(p,d,r)){const m=h.getAction(n.downPointer,n.downEvent,n,d);if(m&&m.name==="drag"&&nPe(A,h)&&HM.validateAction(m,h,d,r,t))return h}};for(;mt.element(d);){const h=t.interactables.forEachMatch(d,f);if(h){n.prepared.name="drag",n.interactable=h,n.element=d;break}d=ed(d)}}}function nPe(e,t){if(!t)return!1;const n=t.options.drag.startAxis;return e==="xy"||n==="xy"||n===e}var rPe={id:"auto-start/dragAxis",listeners:{"autoStart:before-start":tPe}};function iPe(e){const{defaults:t}=e;e.usePlugin(HM),t.perAction.hold=0,t.perAction.delay=0}function YM(e){const t=e.prepared&&e.prepared.name;if(!t)return null;const n=e.interactable.options;return n[t].hold||n[t].delay}const aPe={id:"auto-start/hold",install:iPe,listeners:{"interactions:new":e=>{let{interaction:t}=e;t.autoStartHoldTimer=null},"autoStart:prepared":e=>{let{interaction:t}=e;const n=YM(t);n>0&&(t.autoStartHoldTimer=setTimeout(()=>{t.start(t.prepared,t.interactable,t.element)},n))},"interactions:move":e=>{let{interaction:t,duplicate:n}=e;t.autoStartHoldTimer&&t.pointerWasMoved&&!n&&(clearTimeout(t.autoStartHoldTimer),t.autoStartHoldTimer=null)},"autoStart:before-start":e=>{let{interaction:t}=e;YM(t)>0&&(t.prepared.name=null)}},getHoldDuration:YM};var oPe={id:"auto-start",install(e){e.usePlugin(HM),e.usePlugin(aPe),e.usePlugin(rPe)}};const xz=(e,t)=>{for(const n of t)e.push(n);return e},Bz=e=>xz([],e),y2=(e,t)=>{for(let n=0;n<e.length;n++)if(t(e[n],n,e))return n;return-1},b2=(e,t)=>e[y2(e,t)];function Jp(e){const t={};for(const n in e){const r=e[n];mt.plainObject(r)?t[n]=Jp(r):mt.array(r)?t[n]=Bz(r):t[n]=r}return t}let Cz=0,Cc,Qf;function sPe(e){if(Cc=e.requestAnimationFrame,Qf=e.cancelAnimationFrame,!Cc){const t=["ms","moz","webkit","o"];for(const n of t)Cc=e[`${n}RequestAnimationFrame`],Qf=e[`${n}CancelAnimationFrame`]||e[`${n}CancelRequestAnimationFrame`]}Cc=Cc&&Cc.bind(e),Qf=Qf&&Qf.bind(e),Cc||(Cc=t=>{const n=Date.now(),r=Math.max(0,16-(n-Cz)),i=e.setTimeout(()=>{t(n+r)},r);return Cz=n+r,i},Qf=t=>clearTimeout(t))}var Zp={request:e=>Cc(e),cancel:e=>Qf(e),init:sPe};function jf(e,t){let n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:i=>!0,r=arguments.length>3?arguments[3]:void 0;if(r=r||{},mt.string(e)&&e.search(" ")!==-1&&(e=Sz(e)),mt.array(e))return e.forEach(i=>jf(i,t,n,r)),r;if(mt.object(e)&&(t=e,e=""),mt.func(t)&&n(e))r[e]=r[e]||[],r[e].push(t);else if(mt.array(t))for(const i of t)jf(e,i,n,r);else if(mt.object(t))for(const i in t){const a=Sz(i).map(o=>`${e}${o}`);jf(a,t[i],n,r)}return r}function Sz(e){return e.trim().split(/ +/)}function Mz(e,t){for(const n of t){if(e.immediatePropagationStopped)break;n(e)}}class kz{constructor(t){this.options=void 0,this.types={},this.propagationStopped=!1,this.immediatePropagationStopped=!1,this.global=void 0,this.options=fn({},t||{})}fire(t){let n;const r=this.global;(n=this.types[t.type])&&Mz(t,n),!t.propagationStopped&&r&&(n=r[t.type])&&Mz(t,n)}on(t,n){const r=jf(t,n);for(t in r)this.types[t]=xz(this.types[t]||[],r[t])}off(t,n){const r=jf(t,n);for(t in r){const i=this.types[t];if(!(!i||!i.length))for(const a of r[t]){const o=i.indexOf(a);o!==-1&&i.splice(o,1)}}}getRect(t){return null}}const lPe=["webkit","moz"];function Ez(e,t){e.__set||(e.__set={});for(const n in t)lPe.some(r=>n.indexOf(r)===0)||typeof e[n]!="function"&&n!=="__set"&&Object.defineProperty(e,n,{get(){return n in e.__set?e.__set[n]:e.__set[n]=t[n]},set(r){e.__set[n]=r},configurable:!0});return e}var _2=(e,t)=>Math.sqrt(e*e+t*t);function RM(e,t){e.page=e.page||{},e.page.x=t.page.x,e.page.y=t.page.y,e.client=e.client||{},e.client.x=t.client.x,e.client.y=t.client.y,e.timeStamp=t.timeStamp}function uPe(e,t,n){e.page.x=n.page.x-t.page.x,e.page.y=n.page.y-t.page.y,e.client.x=n.client.x-t.client.x,e.client.y=n.client.y-t.client.y,e.timeStamp=n.timeStamp-t.timeStamp}function cPe(e,t){const n=Math.max(t.timeStamp/1e3,.001);e.page.x=t.page.x/n,e.page.y=t.page.y/n,e.client.x=t.client.x/n,e.client.y=t.client.y/n,e.timeStamp=n}function APe(e){e.page.x=0,e.page.y=0,e.client.x=0,e.client.y=0}function Lz(e){return e instanceof Xr.Event||e instanceof Xr.Touch}function w2(e,t,n){return n=n||{},e=e||"page",n.x=t[e+"X"],n.y=t[e+"Y"],n}function dPe(e,t){return t=t||{x:0,y:0},vi.isOperaMobile&&Lz(e)?(w2("screen",e,t),t.x+=window.scrollX,t.y+=window.scrollY):w2("page",e,t),t}function fPe(e,t){return t=t||{},vi.isOperaMobile&&Lz(e)?w2("screen",e,t):w2("client",e,t),t}function x2(e){return mt.number(e.pointerId)?e.pointerId:e.identifier}function hPe(e,t,n){const r=t.length>1?Tz(t):t[0];dPe(r,e.page),fPe(r,e.client),e.timeStamp=n}function QM(e){const t=[];return mt.array(e)?(t[0]=e[0],t[1]=e[1]):e.type==="touchend"?e.touches.length===1?(t[0]=e.touches[0],t[1]=e.changedTouches[0]):e.touches.length===0&&(t[0]=e.changedTouches[0],t[1]=e.changedTouches[1]):(t[0]=e.touches[0],t[1]=e.touches[1]),t}function Tz(e){const t={pageX:0,pageY:0,clientX:0,clientY:0,screenX:0,screenY:0};for(const n of e)for(const r in t)t[r]+=n[r];for(const n in t)t[n]/=e.length;return t}function pPe(e){if(!e.length)return null;const t=QM(e),n=Math.min(t[0].pageX,t[1].pageX),r=Math.min(t[0].pageY,t[1].pageY),i=Math.max(t[0].pageX,t[1].pageX),a=Math.max(t[0].pageY,t[1].pageY);return{x:n,y:r,left:n,top:r,right:i,bottom:a,width:i-n,height:a-r}}function mPe(e,t){const n=t+"X",r=t+"Y",i=QM(e),a=i[0][n]-i[1][n],o=i[0][r]-i[1][r];return _2(a,o)}function gPe(e,t){const n=t+"X",r=t+"Y",i=QM(e),a=i[1][n]-i[0][n],o=i[1][r]-i[0][r];return 180*Math.atan2(o,a)/Math.PI}function vPe(e){return mt.string(e.pointerType)?e.pointerType:mt.number(e.pointerType)?[void 0,void 0,"touch","pen","mouse"][e.pointerType]:/touch/.test(e.type||"")||e instanceof Xr.Touch?"touch":"mouse"}function Nz(e){const t=mt.func(e.composedPath)?e.composedPath():e.path;return[pz(t?t[0]:e.target),pz(e.currentTarget)]}function rv(){return{page:{x:0,y:0},client:{x:0,y:0},timeStamp:0}}function yPe(e){var t;const n=[],r={},i=[],a={add:o,remove:s,addDelegate:u,removeDelegate:c,delegateListener:A,delegateUseCapture:d,delegatedEvents:r,documents:i,targets:n,supportsOptions:!1,supportsPassive:!1};(t=e.document)==null||t.createElement("div").addEventListener("test",null,{get capture(){return a.supportsOptions=!0},get passive(){return a.supportsPassive=!0}}),e.events=a;function o(f,h,p,m){if(!f.addEventListener)return;const v=iv(m);let y=b2(n,g=>g.eventTarget===f);y||(y={eventTarget:f,events:{}},n.push(y)),y.events[h]||(y.events[h]=[]),b2(y.events[h],g=>g.func===p&&B2(g.options,v))||(f.addEventListener(h,p,a.supportsOptions?v:v.capture),y.events[h].push({func:p,options:v}))}function s(f,h,p,m){if(!f.addEventListener||!f.removeEventListener)return;const v=y2(n,w=>w.eventTarget===f),y=n[v];if(!y||!y.events)return;if(h==="all"){for(h in y.events)y.events.hasOwnProperty(h)&&s(f,h,"all");return}let g=!1;const b=y.events[h];if(b)if(p==="all"){for(let w=b.length-1;w>=0;w--){const _=b[w];s(f,h,_.func,_.options)}return}else{const w=iv(m);for(let _=0;_<b.length;_++){const C=b[_];if(C.func===p&&B2(C.options,w)){f.removeEventListener(h,p,a.supportsOptions?w:w.capture),b.splice(_,1),b.length===0&&(delete y.events[h],g=!0);break}}}g&&!Object.keys(y.events).length&&n.splice(v,1)}function u(f,h,p,m,v){const y=iv(v);if(!r[p]){r[p]=[];for(const w of i)o(w,p,A),o(w,p,d,!0)}const g=r[p];let b=b2(g,w=>w.selector===f&&w.context===h);b||(b={selector:f,context:h,listeners:[]},g.push(b)),b.listeners.push({func:m,options:y})}function c(f,h,p,m,v){const y=iv(v),g=r[p];let b=!1,w;if(g)for(w=g.length-1;w>=0;w--){const _=g[w];if(_.selector===f&&_.context===h){const{listeners:C}=_;for(let B=C.length-1;B>=0;B--){const k=C[B];if(k.func===m&&B2(k.options,y)){C.splice(B,1),C.length||(g.splice(w,1),s(h,p,A),s(h,p,d,!0)),b=!0;break}}if(b)break}}}function A(f,h){const p=iv(h),m=new bPe(f),v=r[f.type],[y]=Nz(f);let g=y;for(;mt.element(g);){for(let b=0;b<v.length;b++){const w=v[b],{selector:_,context:C}=w;if(Rf(g,_)&&Yf(C,y)&&Yf(C,g)){const{listeners:B}=w;m.currentTarget=g;for(const k of B)B2(k.options,p)&&k.func(m)}}g=ed(g)}}function d(f){return A.call(this,f,!0)}return a}class bPe{constructor(t){this.currentTarget=void 0,this.originalEvent=void 0,this.type=void 0,this.originalEvent=t,Ez(this,t)}preventOriginalDefault(){this.originalEvent.preventDefault()}stopPropagation(){this.originalEvent.stopPropagation()}stopImmediatePropagation(){this.originalEvent.stopImmediatePropagation()}}function iv(e){return mt.object(e)?{capture:!!e.capture,passive:!!e.passive}:{capture:!!e,passive:!1}}function B2(e,t){return e===t?!0:typeof e=="boolean"?!!t.capture===e&&!t.passive:!!e.capture==!!t.capture&&!!e.passive==!!t.passive}var _Pe={id:"events",install:yPe};const wPe=function(t){return/^(always|never|auto)$/.test(t)?(this.options.preventDefault=t,this):mt.bool(t)?(this.options.preventDefault=t?"always":"never",this):this.options.preventDefault};function xPe(e,t,n){const r=e.options.preventDefault;if(r!=="never"){if(r==="always"){n.preventDefault();return}if(t.events.supportsPassive&&/^touch(start|move)$/.test(n.type)){const i=Hf(n.target).document,a=t.getDocOptions(i);if(!(a&&a.events)||a.events.passive!==!1)return}/^(mouse|pointer|touch)*(down|start)/i.test(n.type)||mt.element(n.target)&&Rf(n.target,"input,select,textarea,[contenteditable=true],[contenteditable=true] *")||n.preventDefault()}}function BPe(e){let{interaction:t,event:n}=e;t.interactable&&t.interactable.checkAndPreventDefault(n)}function CPe(e){const{Interactable:t}=e;t.prototype.preventDefault=wPe,t.prototype.checkAndPreventDefault=function(n){return xPe(this,e,n)},e.interactions.docEvents.push({type:"dragstart",listener(n){for(const r of e.interactions.list)if(r.element&&(r.element===n.target||Yf(r.element,n.target))){r.interactable.checkAndPreventDefault(n);return}}})}var SPe={id:"core/interactablePreventDefault",install:CPe,listeners:["down","move","up","cancel"].reduce((e,t)=>(e[`interactions:${t}`]=BPe,e),{})};function Fz(e,t,n){return e==="parent"?ed(n):e==="self"?t.getRect(n):hz(n,e)}function av(e,t,n,r){let i=e;return mt.string(i)?i=Fz(i,t,n):mt.func(i)&&(i=i(...r)),mt.element(i)&&(i=UM(i)),i}function C2(e){return e&&{x:"x"in e?e.x:e.left,y:"y"in e?e.y:e.top}}function MPe(e){return e&&!("left"in e&&"top"in e)&&(e=fn({},e),e.left=e.x||0,e.top=e.y||0,e.right=e.right||e.left+e.width,e.bottom=e.bottom||e.top+e.height),e}function Iz(e){return e&&!("x"in e&&"y"in e)&&(e=fn({},e),e.x=e.left||0,e.y=e.top||0,e.width=e.width||(e.right||0)-e.x,e.height=e.height||(e.bottom||0)-e.y),e}function jM(e,t,n){e.left&&(t.left+=n.x),e.right&&(t.right+=n.x),e.top&&(t.top+=n.y),e.bottom&&(t.bottom+=n.y),t.width=t.right-t.left,t.height=t.bottom-t.top}function VM(e,t,n){const r=n&&e.options[n],a=r&&r.origin||e.options.origin,o=av(a,e,t,[e&&t]);return C2(o)||{x:0,y:0}}class Oz{constructor(t){this.immediatePropagationStopped=!1,this.propagationStopped=!1,this._interaction=t}preventDefault(){}stopPropagation(){this.propagationStopped=!0}stopImmediatePropagation(){this.immediatePropagationStopped=this.propagationStopped=!0}}Object.defineProperty(Oz.prototype,"interaction",{get(){return this._interaction._proxy},set(){}});const Dz={base:{preventDefault:"auto",deltaSource:"page"},perAction:{enabled:!1,origin:{x:0,y:0}},actions:{}};class zM extends Oz{constructor(t,n,r,i,a,o,s){super(t),this.relatedTarget=null,this.screenX=void 0,this.screenY=void 0,this.button=void 0,this.buttons=void 0,this.ctrlKey=void 0,this.shiftKey=void 0,this.altKey=void 0,this.metaKey=void 0,this.page=void 0,this.client=void 0,this.delta=void 0,this.rect=void 0,this.x0=void 0,this.y0=void 0,this.t0=void 0,this.dt=void 0,this.duration=void 0,this.clientX0=void 0,this.clientY0=void 0,this.velocity=void 0,this.speed=void 0,this.swipe=void 0,this.axes=void 0,this.preEnd=void 0,a=a||t.element;const u=t.interactable,c=(u&&u.options||Dz).deltaSource,A=VM(u,a,r),d=i==="start",f=i==="end",h=d?this:t.prevEvent,p=d?t.coords.start:f?{page:h.page,client:h.client,timeStamp:t.coords.cur.timeStamp}:t.coords.cur;this.page=fn({},p.page),this.client=fn({},p.client),this.rect=fn({},t.rect),this.timeStamp=p.timeStamp,f||(this.page.x-=A.x,this.page.y-=A.y,this.client.x-=A.x,this.client.y-=A.y),this.ctrlKey=n.ctrlKey,this.altKey=n.altKey,this.shiftKey=n.shiftKey,this.metaKey=n.metaKey,this.button=n.button,this.buttons=n.buttons,this.target=a,this.currentTarget=a,this.preEnd=o,this.type=s||r+(i||""),this.interactable=u,this.t0=d?t.pointers[t.pointers.length-1].downTime:h.t0,this.x0=t.coords.start.page.x-A.x,this.y0=t.coords.start.page.y-A.y,this.clientX0=t.coords.start.client.x-A.x,this.clientY0=t.coords.start.client.y-A.y,d||f?this.delta={x:0,y:0}:this.delta={x:this[c].x-h[c].x,y:this[c].y-h[c].y},this.dt=t.coords.delta.timeStamp,this.duration=this.timeStamp-this.t0,this.velocity=fn({},t.coords.velocity[c]),this.speed=_2(this.velocity.x,this.velocity.y),this.swipe=f||i==="inertiastart"?this.getSwipe():null}getSwipe(){const t=this._interaction;if(t.prevEvent.speed<600||this.timeStamp-t.prevEvent.timeStamp>150)return null;let n=180*Math.atan2(t.prevEvent.velocityY,t.prevEvent.velocityX)/Math.PI;const r=22.5;n<0&&(n+=360);const i=135-r<=n&&n<225+r,a=225-r<=n&&n<315+r,o=!i&&(315-r<=n||n<45+r),s=!a&&45-r<=n&&n<135+r;return{up:a,down:s,left:i,right:o,angle:n,speed:t.prevEvent.speed,velocity:{x:t.prevEvent.velocityX,y:t.prevEvent.velocityY}}}preventDefault(){}stopImmediatePropagation(){this.immediatePropagationStopped=this.propagationStopped=!0}stopPropagation(){this.propagationStopped=!0}}Object.defineProperties(zM.prototype,{pageX:{get(){return this.page.x},set(e){this.page.x=e}},pageY:{get(){return this.page.y},set(e){this.page.y=e}},clientX:{get(){return this.client.x},set(e){this.client.x=e}},clientY:{get(){return this.client.y},set(e){this.client.y=e}},dx:{get(){return this.delta.x},set(e){this.delta.x=e}},dy:{get(){return this.delta.y},set(e){this.delta.y=e}},velocityX:{get(){return this.velocity.x},set(e){this.velocity.x=e}},velocityY:{get(){return this.velocity.y},set(e){this.velocity.y=e}}});class kPe{constructor(t,n,r,i,a){this.id=void 0,this.pointer=void 0,this.event=void 0,this.downTime=void 0,this.downTarget=void 0,this.id=t,this.pointer=n,this.event=r,this.downTime=i,this.downTarget=a}}let EPe=function(e){return e.interactable="",e.element="",e.prepared="",e.pointerIsDown="",e.pointerWasMoved="",e._proxy="",e}({}),LPe=function(e){return e.start="",e.move="",e.end="",e.stop="",e.interacting="",e}({}),TPe=0;class NPe{get pointerMoveTolerance(){return 1}constructor(t){this.interactable=null,this.element=null,this.rect=null,this._rects=void 0,this.edges=null,this._scopeFire=void 0,this.prepared={name:null,axis:null,edges:null},this.pointerType=void 0,this.pointers=[],this.downEvent=null,this.downPointer={},this._latestPointer={pointer:null,event:null,eventTarget:null},this.prevEvent=null,this.pointerIsDown=!1,this.pointerWasMoved=!1,this._interacting=!1,this._ending=!1,this._stopped=!0,this._proxy=void 0,this.simulation=null,this.doMove=nv(function(a){this.move(a)},"The interaction.doMove() method has been renamed to interaction.move()"),this.coords={start:rv(),prev:rv(),cur:rv(),delta:rv(),velocity:rv()},this._id=TPe++;let{pointerType:n,scopeFire:r}=t;this._scopeFire=r,this.pointerType=n;const i=this;this._proxy={};for(const a in EPe)Object.defineProperty(this._proxy,a,{get(){return i[a]}});for(const a in LPe)Object.defineProperty(this._proxy,a,{value:function(){return i[a](...arguments)}});this._scopeFire("interactions:new",{interaction:this})}pointerDown(t,n,r){const i=this.updatePointer(t,n,r,!0),a=this.pointers[i];this._scopeFire("interactions:down",{pointer:t,event:n,eventTarget:r,pointerIndex:i,pointerInfo:a,type:"down",interaction:this})}start(t,n,r){return this.interacting()||!this.pointerIsDown||this.pointers.length<(t.name==="gesture"?2:1)||!n.options[t.name].enabled?!1:(gz(this.prepared,t),this.interactable=n,this.element=r,this.rect=n.getRect(r),this.edges=this.prepared.edges?fn({},this.prepared.edges):{left:!0,right:!0,top:!0,bottom:!0},this._stopped=!1,this._interacting=this._doPhase({interaction:this,event:this.downEvent,phase:"start"})&&!this._stopped,this._interacting)}pointerMove(t,n,r){!this.simulation&&!(this.modification&&this.modification.endResult)&&this.updatePointer(t,n,r,!1);const i=this.coords.cur.page.x===this.coords.prev.page.x&&this.coords.cur.page.y===this.coords.prev.page.y&&this.coords.cur.client.x===this.coords.prev.client.x&&this.coords.cur.client.y===this.coords.prev.client.y;let a,o;this.pointerIsDown&&!this.pointerWasMoved&&(a=this.coords.cur.client.x-this.coords.start.client.x,o=this.coords.cur.client.y-this.coords.start.client.y,this.pointerWasMoved=_2(a,o)>this.pointerMoveTolerance);const s=this.getPointerIndex(t),u={pointer:t,pointerIndex:s,pointerInfo:this.pointers[s],event:n,type:"move",eventTarget:r,dx:a,dy:o,duplicate:i,interaction:this};i||cPe(this.coords.velocity,this.coords.delta),this._scopeFire("interactions:move",u),!i&&!this.simulation&&(this.interacting()&&(u.type=null,this.move(u)),this.pointerWasMoved&&RM(this.coords.prev,this.coords.cur))}move(t){(!t||!t.event)&&APe(this.coords.delta),t=fn({pointer:this._latestPointer.pointer,event:this._latestPointer.event,eventTarget:this._latestPointer.eventTarget,interaction:this},t||{}),t.phase="move",this._doPhase(t)}pointerUp(t,n,r,i){let a=this.getPointerIndex(t);a===-1&&(a=this.updatePointer(t,n,r,!1));const o=/cancel$/i.test(n.type)?"cancel":"up";this._scopeFire(`interactions:${o}`,{pointer:t,pointerIndex:a,pointerInfo:this.pointers[a],event:n,eventTarget:r,type:o,curEventTarget:i,interaction:this}),this.simulation||this.end(n),this.removePointer(t,n)}documentBlur(t){this.end(t),this._scopeFire("interactions:blur",{event:t,type:"blur",interaction:this})}end(t){this._ending=!0,t=t||this._latestPointer.event;let n;this.interacting()&&(n=this._doPhase({event:t,interaction:this,phase:"end"})),this._ending=!1,n===!0&&this.stop()}currentAction(){return this._interacting?this.prepared.name:null}interacting(){return this._interacting}stop(){this._scopeFire("interactions:stop",{interaction:this}),this.interactable=this.element=null,this._interacting=!1,this._stopped=!0,this.prepared.name=this.prevEvent=null}getPointerIndex(t){const n=x2(t);return this.pointerType==="mouse"||this.pointerType==="pen"?this.pointers.length-1:y2(this.pointers,r=>r.id===n)}getPointerInfo(t){return this.pointers[this.getPointerIndex(t)]}updatePointer(t,n,r,i){const a=x2(t);let o=this.getPointerIndex(t),s=this.pointers[o];return i=i===!1?!1:i||/(down|start)$/i.test(n.type),s?s.pointer=t:(s=new kPe(a,t,n,null,null),o=this.pointers.length,this.pointers.push(s)),hPe(this.coords.cur,this.pointers.map(u=>u.pointer),this._now()),uPe(this.coords.delta,this.coords.prev,this.coords.cur),i&&(this.pointerIsDown=!0,s.downTime=this.coords.cur.timeStamp,s.downTarget=r,Ez(this.downPointer,t),this.interacting()||(RM(this.coords.start,this.coords.cur),RM(this.coords.prev,this.coords.cur),this.downEvent=n,this.pointerWasMoved=!1)),this._updateLatestPointer(t,n,r),this._scopeFire("interactions:update-pointer",{pointer:t,event:n,eventTarget:r,down:i,pointerInfo:s,pointerIndex:o,interaction:this}),o}removePointer(t,n){const r=this.getPointerIndex(t);if(r===-1)return;const i=this.pointers[r];this._scopeFire("interactions:remove-pointer",{pointer:t,event:n,eventTarget:null,pointerIndex:r,pointerInfo:i,interaction:this}),this.pointers.splice(r,1),this.pointerIsDown=!1}_updateLatestPointer(t,n,r){this._latestPointer.pointer=t,this._latestPointer.event=n,this._latestPointer.eventTarget=r}destroy(){this._latestPointer.pointer=null,this._latestPointer.event=null,this._latestPointer.eventTarget=null}_createPreparedEvent(t,n,r,i){return new zM(this,t,this.prepared.name,n,this.element,r,i)}_fireEvent(t){var n;(n=this.interactable)==null||n.fire(t),(!this.prevEvent||t.timeStamp>=this.prevEvent.timeStamp)&&(this.prevEvent=t)}_doPhase(t){const{event:n,phase:r,preEnd:i,type:a}=t,{rect:o}=this;if(o&&r==="move"&&(jM(this.edges,o,this.coords.delta[this.interactable.options.deltaSource]),o.width=o.right-o.left,o.height=o.bottom-o.top),this._scopeFire(`interactions:before-action-${r}`,t)===!1)return!1;const u=t.iEvent=this._createPreparedEvent(n,r,i,a);return this._scopeFire(`interactions:action-${r}`,t),r==="start"&&(this.prevEvent=u),this._fireEvent(u),this._scopeFire(`interactions:after-action-${r}`,t),!0}_now(){return Date.now()}}const qM={methodOrder:["simulationResume","mouseOrPen","hasPointer","idle"],search(e){for(const t of qM.methodOrder){const n=qM[t](e);if(n)return n}return null},simulationResume(e){let{pointerType:t,eventType:n,eventTarget:r,scope:i}=e;if(!/down|start/i.test(n))return null;for(const a of i.interactions.list){let o=r;if(a.simulation&&a.simulation.allowResume&&a.pointerType===t)for(;o;){if(o===a.element)return a;o=ed(o)}}return null},mouseOrPen(e){let{pointerId:t,pointerType:n,eventType:r,scope:i}=e;if(n!=="mouse"&&n!=="pen")return null;let a;for(const o of i.interactions.list)if(o.pointerType===n){if(o.simulation&&!Uz(o,t))continue;if(o.interacting())return o;a||(a=o)}if(a)return a;for(const o of i.interactions.list)if(o.pointerType===n&&!(/down/i.test(r)&&o.simulation))return o;return null},hasPointer(e){let{pointerId:t,scope:n}=e;for(const r of n.interactions.list)if(Uz(r,t))return r;return null},idle(e){let{pointerType:t,scope:n}=e;for(const r of n.interactions.list){if(r.pointers.length===1){const i=r.interactable;if(i&&!(i.options.gesture&&i.options.gesture.enabled))continue}else if(r.pointers.length>=2)continue;if(!r.interacting()&&t===r.pointerType)return r}return null}};function Uz(e,t){return e.pointers.some(n=>{let{id:r}=n;return r===t})}const Pz=["pointerDown","pointerMove","pointerUp","updatePointer","removePointer","windowBlur"];function FPe(e){const t={};for(const a of Pz)t[a]=Hz(a,e);const n=vi.pEventTypes;let r;Xr.PointerEvent?r=[{type:n.down,listener:i},{type:n.down,listener:t.pointerDown},{type:n.move,listener:t.pointerMove},{type:n.up,listener:t.pointerUp},{type:n.cancel,listener:t.pointerUp}]:r=[{type:"mousedown",listener:t.pointerDown},{type:"mousemove",listener:t.pointerMove},{type:"mouseup",listener:t.pointerUp},{type:"touchstart",listener:i},{type:"touchstart",listener:t.pointerDown},{type:"touchmove",listener:t.pointerMove},{type:"touchend",listener:t.pointerUp},{type:"touchcancel",listener:t.pointerUp}],r.push({type:"blur",listener(a){for(const o of e.interactions.list)o.documentBlur(a)}}),e.prevTouchTime=0,e.Interaction=class extends NPe{get pointerMoveTolerance(){return e.interactions.pointerMoveTolerance}set pointerMoveTolerance(a){e.interactions.pointerMoveTolerance=a}_now(){return e.now()}},e.interactions={list:[],new(a){a.scopeFire=(s,u)=>e.fire(s,u);const o=new e.Interaction(a);return e.interactions.list.push(o),o},listeners:t,docEvents:r,pointerMoveTolerance:1};function i(){for(const a of e.interactions.list)if(!(!a.pointerIsDown||a.pointerType!=="touch"||a._interacting))for(const o of a.pointers)e.documents.some(s=>{let{doc:u}=s;return Yf(u,o.downTarget)})||a.removePointer(o.pointer,o.event)}e.usePlugin(SPe)}function Hz(e,t){return function(n){const r=t.interactions.list,i=vPe(n),[a,o]=Nz(n),s=[];if(/^touch/.test(n.type)){t.prevTouchTime=t.now();for(const u of n.changedTouches){const c=u,A=x2(c),d={pointer:c,pointerId:A,pointerType:i,eventType:n.type,eventTarget:a,curEventTarget:o,scope:t},f=Yz(d);s.push([d.pointer,d.eventTarget,d.curEventTarget,f])}}else{let u=!1;if(!vi.supportsPointerEvent&&/mouse/.test(n.type)){for(let c=0;c<r.length&&!u;c++)u=r[c].pointerType!=="mouse"&&r[c].pointerIsDown;u=u||t.now()-t.prevTouchTime<500||n.timeStamp===0}if(!u){const c={pointer:n,pointerId:x2(n),pointerType:i,eventType:n.type,curEventTarget:o,eventTarget:a,scope:t},A=Yz(c);s.push([c.pointer,c.eventTarget,c.curEventTarget,A])}}for(const[u,c,A,d]of s)d[e](u,n,c,A)}}function Yz(e){const{pointerType:t,scope:n}=e,i={interaction:qM.search(e),searchDetails:e};return n.fire("interactions:find",i),i.interaction||n.interactions.new({pointerType:t})}function KM(e,t){let{doc:n,scope:r,options:i}=e;const{interactions:{docEvents:a},events:o}=r,s=o[t];r.browser.isIOS&&!i.events&&(i.events={passive:!1});for(const c in o.delegatedEvents)s(n,c,o.delegateListener),s(n,c,o.delegateUseCapture,!0);const u=i&&i.events;for(const{type:c,listener:A}of a)s(n,c,A,u)}const IPe={id:"core/interactions",install:FPe,listeners:{"scope:add-document":e=>KM(e,"add"),"scope:remove-document":e=>KM(e,"remove"),"interactable:unset":(e,t)=>{let{interactable:n}=e;for(let r=t.interactions.list.length-1;r>=0;r--){const i=t.interactions.list[r];i.interactable===n&&(i.stop(),t.fire("interactions:destroy",{interaction:i}),i.destroy(),t.interactions.list.length>2&&t.interactions.list.splice(r,1))}}},onDocSignal:KM,doOnInteractions:Hz,methodNames:Pz};function ov(e,t){if(t.phaselessTypes[e])return!0;for(const n in t.map)if(e.indexOf(n)===0&&e.substr(n.length)in t.phases)return!0;return!1}var td=function(e){return e[e.On=0]="On",e[e.Off=1]="Off",e}(td||{});class OPe{get _defaults(){return{base:{},perAction:{},actions:{}}}constructor(t,n,r,i){this.target=void 0,this.options=void 0,this._actions=void 0,this.events=new kz,this._context=void 0,this._win=void 0,this._doc=void 0,this._scopeEvents=void 0,this._actions=n.actions,this.target=t,this._context=n.context||r,this._win=Hf(mz(t)?this._context:t),this._doc=this._win.document,this._scopeEvents=i,this.set(n)}setOnEvents(t,n){return mt.func(n.onstart)&&this.on(`${t}start`,n.onstart),mt.func(n.onmove)&&this.on(`${t}move`,n.onmove),mt.func(n.onend)&&this.on(`${t}end`,n.onend),mt.func(n.oninertiastart)&&this.on(`${t}inertiastart`,n.oninertiastart),this}updatePerActionListeners(t,n,r){var i;const a=(i=this._actions.map[t])==null?void 0:i.filterEventType,o=s=>(a==null||a(s))&&ov(s,this._actions);(mt.array(n)||mt.object(n))&&this._onOff(td.Off,t,n,void 0,o),(mt.array(r)||mt.object(r))&&this._onOff(td.On,t,r,void 0,o)}setPerAction(t,n){const r=this._defaults;for(const i in n){const a=i,o=this.options[t],s=n[a];a==="listeners"&&this.updatePerActionListeners(t,o.listeners,s),mt.array(s)?o[a]=Bz(s):mt.plainObject(s)?(o[a]=fn(o[a]||{},Jp(s)),mt.object(r.perAction[a])&&"enabled"in r.perAction[a]&&(o[a].enabled=s.enabled!==!1)):mt.bool(s)&&mt.object(r.perAction[a])?o[a].enabled=s:o[a]=s}}getRect(t){return t=t||(mt.element(this.target)?this.target:null),mt.string(this.target)&&(t=t||this._context.querySelector(this.target)),UM(t)}rectChecker(t){return mt.func(t)?(this.getRect=n=>{const r=fn({},t.apply(this,n));return"width"in r||(r.width=r.right-r.left,r.height=r.bottom-r.top),r},this):t===null?(delete this.getRect,this):this.getRect}_backCompatOption(t,n){if(mz(n)||mt.object(n)){this.options[t]=n;for(const r in this._actions.map)this.options[r][t]=n;return this}return this.options[t]}origin(t){return this._backCompatOption("origin",t)}deltaSource(t){return t==="page"||t==="client"?(this.options.deltaSource=t,this):this.options.deltaSource}getAllElements(){const{target:t}=this;return mt.string(t)?Array.from(this._context.querySelectorAll(t)):mt.func(t)&&t.getAllElements?t.getAllElements():mt.element(t)?[t]:[]}context(){return this._context}inContext(t){return this._context===t.ownerDocument||Yf(this._context,t)}testIgnoreAllow(t,n,r){return!this.testIgnore(t.ignoreFrom,n,r)&&this.testAllow(t.allowFrom,n,r)}testAllow(t,n,r){return t?mt.element(r)?mt.string(t)?OM(r,t,n):mt.element(t)?Yf(t,r):!1:!1:!0}testIgnore(t,n,r){return!t||!mt.element(r)?!1:mt.string(t)?OM(r,t,n):mt.element(t)?Yf(t,r):!1}fire(t){return this.events.fire(t),this}_onOff(t,n,r,i,a){mt.object(n)&&!mt.array(n)&&(i=r,r=null);const o=jf(n,r,a);for(let s in o){s==="wheel"&&(s=vi.wheelEvent);for(const u of o[s])ov(s,this._actions)?this.events[t===td.On?"on":"off"](s,u):mt.string(this.target)?this._scopeEvents[t===td.On?"addDelegate":"removeDelegate"](this.target,this._context,s,u,i):this._scopeEvents[t===td.On?"add":"remove"](this.target,s,u,i)}return this}on(t,n,r){return this._onOff(td.On,t,n,r)}off(t,n,r){return this._onOff(td.Off,t,n,r)}set(t){const n=this._defaults;mt.object(t)||(t={}),this.options=Jp(n.base);for(const r in this._actions.methodDict){const i=r,a=this._actions.methodDict[i];this.options[i]={},this.setPerAction(i,fn(fn({},n.perAction),n.actions[i])),this[a](t[i])}for(const r in t){if(r==="getRect"){this.rectChecker(t.getRect);continue}mt.func(this[r])&&this[r](t[r])}return this}unset(){if(mt.string(this.target))for(const t in this._scopeEvents.delegatedEvents){const n=this._scopeEvents.delegatedEvents[t];for(let r=n.length-1;r>=0;r--){const{selector:i,context:a,listeners:o}=n[r];i===this.target&&a===this._context&&n.splice(r,1);for(let s=o.length-1;s>=0;s--)this._scopeEvents.removeDelegate(this.target,this._context,t,o[s][0],o[s][1])}}else this._scopeEvents.remove(this.target,"all")}}class DPe{constructor(t){this.list=[],this.selectorMap={},this.scope=void 0,this.scope=t,t.addListeners({"interactable:unset":n=>{let{interactable:r}=n;const{target:i}=r,a=mt.string(i)?this.selectorMap[i]:i[this.scope.id],o=y2(a,s=>s===r);a.splice(o,1)}})}new(t,n){n=fn(n||{},{actions:this.scope.actions});const r=new this.scope.Interactable(t,n,this.scope.document,this.scope.events);return this.scope.addDocument(r._doc),this.list.push(r),mt.string(t)?(this.selectorMap[t]||(this.selectorMap[t]=[]),this.selectorMap[t].push(r)):(r.target[this.scope.id]||Object.defineProperty(t,this.scope.id,{value:[],configurable:!0}),t[this.scope.id].push(r)),this.scope.fire("interactable:new",{target:t,options:n,interactable:r,win:this.scope._win}),r}getExisting(t,n){const r=n&&n.context||this.scope.document,i=mt.string(t),a=i?this.selectorMap[t]:t[this.scope.id];if(a)return b2(a,o=>o._context===r&&(i||o.inContext(t)))}forEachMatch(t,n){for(const r of this.list){let i;if((mt.string(r.target)?mt.element(t)&&Rf(t,r.target):t===r.target)&&r.inContext(t)&&(i=n(r)),i!==void 0)return i}}}function UPe(e){const t=(n,r)=>{let i=e.interactables.getExisting(n,r);return i||(i=e.interactables.new(n,r),i.events.global=t.globalEvents),i};return t.getPointerAverage=Tz,t.getTouchBBox=pPe,t.getTouchDistance=mPe,t.getTouchAngle=gPe,t.getElementRect=UM,t.getElementClientRect=DM,t.matchesSelector=Rf,t.closest=hz,t.globalEvents={},t.version="1.10.27",t.scope=e,t.use=function(n,r){return this.scope.usePlugin(n,r),this},t.isSet=function(n,r){return!!this.scope.interactables.get(n,r&&r.context)},t.on=nv(function(r,i,a){if(mt.string(r)&&r.search(" ")!==-1&&(r=r.trim().split(/ +/)),mt.array(r)){for(const o of r)this.on(o,i,a);return this}if(mt.object(r)){for(const o in r)this.on(o,r[o],i);return this}return ov(r,this.scope.actions)?this.globalEvents[r]?this.globalEvents[r].push(i):this.globalEvents[r]=[i]:this.scope.events.add(this.scope.document,r,i,{options:a}),this},"The interact.on() method is being deprecated"),t.off=nv(function(r,i,a){if(mt.string(r)&&r.search(" ")!==-1&&(r=r.trim().split(/ +/)),mt.array(r)){for(const o of r)this.off(o,i,a);return this}if(mt.object(r)){for(const o in r)this.off(o,r[o],i);return this}if(ov(r,this.scope.actions)){let o;r in this.globalEvents&&(o=this.globalEvents[r].indexOf(i))!==-1&&this.globalEvents[r].splice(o,1)}else this.scope.events.remove(this.scope.document,r,i,a);return this},"The interact.off() method is being deprecated"),t.debug=function(){return this.scope},t.supportsTouch=function(){return vi.supportsTouch},t.supportsPointerEvent=function(){return vi.supportsPointerEvent},t.stop=function(){for(const n of this.scope.interactions.list)n.stop();return this},t.pointerMoveTolerance=function(n){return mt.number(n)?(this.scope.interactions.pointerMoveTolerance=n,this):this.scope.interactions.pointerMoveTolerance},t.addDocument=function(n,r){this.scope.addDocument(n,r)},t.removeDocument=function(n){this.scope.removeDocument(n)},t}class PPe{constructor(){this.id=`__interact_scope_${Math.floor(Math.random()*100)}`,this.isInitialized=!1,this.listenerMaps=[],this.browser=vi,this.defaults=Jp(Dz),this.Eventable=kz,this.actions={map:{},phases:{start:!0,move:!0,end:!0},methodDict:{},phaselessTypes:{}},this.interactStatic=UPe(this),this.InteractEvent=zM,this.Interactable=void 0,this.interactables=new DPe(this),this._win=void 0,this.document=void 0,this.window=void 0,this.documents=[],this._plugins={list:[],map:{}},this.onWindowUnload=n=>this.removeDocument(n.target);const t=this;this.Interactable=class extends OPe{get _defaults(){return t.defaults}set(n){return super.set(n),t.fire("interactable:set",{options:n,interactable:this}),this}unset(){super.unset();const n=t.interactables.list.indexOf(this);n<0||(t.interactables.list.splice(n,1),t.fire("interactable:unset",{interactable:this}))}}}addListeners(t,n){this.listenerMaps.push({id:n,map:t})}fire(t,n){for(const{map:{[t]:r}}of this.listenerMaps)if(r&&r(n,this,t)===!1)return!1}init(t){return this.isInitialized?this:HPe(this,t)}pluginIsInstalled(t){const{id:n}=t;return n?!!this._plugins.map[n]:this._plugins.list.indexOf(t)!==-1}usePlugin(t,n){if(!this.isInitialized)return this;if(this.pluginIsInstalled(t))return this;if(t.id&&(this._plugins.map[t.id]=t),this._plugins.list.push(t),t.install&&t.install(this,n),t.listeners&&t.before){let r=0;const i=this.listenerMaps.length,a=t.before.reduce((o,s)=>(o[s]=!0,o[Rz(s)]=!0,o),{});for(;r<i;r++){const o=this.listenerMaps[r].id;if(o&&(a[o]||a[Rz(o)]))break}this.listenerMaps.splice(r,0,{id:t.id,map:t.listeners})}else t.listeners&&this.listenerMaps.push({id:t.id,map:t.listeners});return this}addDocument(t,n){if(this.getDocIndex(t)!==-1)return!1;const r=Hf(t);n=n?fn({},n):{},this.documents.push({doc:t,options:n}),this.events.documents.push(t),t!==this.document&&this.events.add(r,"unload",this.onWindowUnload),this.fire("scope:add-document",{doc:t,window:r,scope:this,options:n})}removeDocument(t){const n=this.getDocIndex(t),r=Hf(t),i=this.documents[n].options;this.events.remove(r,"unload",this.onWindowUnload),this.documents.splice(n,1),this.events.documents.splice(n,1),this.fire("scope:remove-document",{doc:t,window:r,scope:this,options:i})}getDocIndex(t){for(let n=0;n<this.documents.length;n++)if(this.documents[n].doc===t)return n;return-1}getDocOptions(t){const n=this.getDocIndex(t);return n===-1?null:this.documents[n].options}now(){return(this.window.Date||Date).now()}}function HPe(e,t){return e.isInitialized=!0,mt.window(t)&&dz(t),Xr.init(t),vi.init(t),Zp.init(t),e.window=t,e.document=t.document,e.usePlugin(IPe),e.usePlugin(_Pe),e}function Rz(e){return e&&e.replace(/\/.*$/,"")}const Qz=new PPe,Sc=Qz.interactStatic,YPe=typeof globalThis<"u"?globalThis:window;Qz.init(YPe),Sc.use(oPe);function RPe(e){const{defaults:t,actions:n}=e;e.autoScroll=bn,bn.now=()=>e.now(),n.phaselessTypes.autoscroll=!0,t.perAction.autoScroll=bn.defaults}const bn={defaults:{enabled:!1,margin:60,container:null,speed:300},now:Date.now,interaction:null,i:0,x:0,y:0,isScrolling:!1,prevTime:0,margin:0,speed:0,start(e){bn.isScrolling=!0,Zp.cancel(bn.i),e.autoScroll=bn,bn.interaction=e,bn.prevTime=bn.now(),bn.i=Zp.request(bn.scroll)},stop(){bn.isScrolling=!1,bn.interaction&&(bn.interaction.autoScroll=null),Zp.cancel(bn.i)},scroll(){const{interaction:e}=bn,{interactable:t,element:n}=e,r=e.prepared.name,i=t.options[r].autoScroll,a=jz(i.container,t,n),o=bn.now(),s=(o-bn.prevTime)/1e3,u=i.speed*s;if(u>=1){const c={x:bn.x*u,y:bn.y*u};if(c.x||c.y){const A=Vz(a);mt.window(a)?a.scrollBy(c.x,c.y):a&&(a.scrollLeft+=c.x,a.scrollTop+=c.y);const d=Vz(a),f={x:d.x-A.x,y:d.y-A.y};(f.x||f.y)&&t.fire({type:"autoscroll",target:n,interactable:t,delta:f,interaction:e,container:a})}bn.prevTime=o}bn.isScrolling&&(Zp.cancel(bn.i),bn.i=Zp.request(bn.scroll))},check(e,t){var n;return(n=e.options[t].autoScroll)==null?void 0:n.enabled},onInteractionMove(e){let{interaction:t,pointer:n}=e;if(!(t.interacting()&&bn.check(t.interactable,t.prepared.name)))return;if(t.simulation){bn.x=bn.y=0;return}let r,i,a,o;const{interactable:s,element:u}=t,c=t.prepared.name,A=s.options[c].autoScroll,d=jz(A.container,s,u);if(mt.window(d))o=n.clientX<bn.margin,r=n.clientY<bn.margin,i=n.clientX>d.innerWidth-bn.margin,a=n.clientY>d.innerHeight-bn.margin;else{const f=DM(d);o=n.clientX<f.left+bn.margin,r=n.clientY<f.top+bn.margin,i=n.clientX>f.right-bn.margin,a=n.clientY>f.bottom-bn.margin}bn.x=i?1:o?-1:0,bn.y=a?1:r?-1:0,bn.isScrolling||(bn.margin=A.margin,bn.speed=A.speed,bn.start(t))}};function jz(e,t,n){return(mt.string(e)?Fz(e,t,n):e)||Hf(n)}function Vz(e){return mt.window(e)&&(e=window.document.body),{x:e.scrollLeft,y:e.scrollTop}}const QPe={id:"auto-scroll",install:RPe,listeners:{"interactions:new":e=>{let{interaction:t}=e;t.autoScroll=null},"interactions:destroy":e=>{let{interaction:t}=e;t.autoScroll=null,bn.stop(),bn.interaction&&(bn.interaction=null)},"interactions:stop":bn.stop,"interactions:action-move":e=>bn.onInteractionMove(e)}};Sc.use(QPe);function jPe(e){const{actions:t,Interactable:n,defaults:r}=e;n.prototype.draggable=S2.draggable,t.map.drag=S2,t.methodDict.drag="draggable",r.actions.drag=S2.defaults}function GM(e){let{interaction:t}=e;if(t.prepared.name!=="drag")return;const n=t.prepared.axis;n==="x"?(t.coords.cur.page.y=t.coords.start.page.y,t.coords.cur.client.y=t.coords.start.client.y,t.coords.velocity.client.y=0,t.coords.velocity.page.y=0):n==="y"&&(t.coords.cur.page.x=t.coords.start.page.x,t.coords.cur.client.x=t.coords.start.client.x,t.coords.velocity.client.x=0,t.coords.velocity.page.x=0)}function zz(e){let{iEvent:t,interaction:n}=e;if(n.prepared.name!=="drag")return;const r=n.prepared.axis;if(r==="x"||r==="y"){const i=r==="x"?"y":"x";t.page[i]=n.coords.start.page[i],t.client[i]=n.coords.start.client[i],t.delta[i]=0}}const S2={id:"actions/drag",install:jPe,listeners:{"interactions:before-action-move":GM,"interactions:action-resume":GM,"interactions:action-move":zz,"auto-start:check":e=>{const{interaction:t,interactable:n,buttons:r}=e,i=n.options.drag;if(!(!(i&&i.enabled)||t.pointerIsDown&&/mouse|pointer/.test(t.pointerType)&&(r&n.options.drag.mouseButtons)===0))return e.action={name:"drag",axis:i.lockAxis==="start"?i.startAxis:i.lockAxis},!1}},draggable:function(t){return mt.object(t)?(this.options.drag.enabled=t.enabled!==!1,this.setPerAction("drag",t),this.setOnEvents("drag",t),/^(xy|x|y|start)$/.test(t.lockAxis)&&(this.options.drag.lockAxis=t.lockAxis),/^(xy|x|y)$/.test(t.startAxis)&&(this.options.drag.startAxis=t.startAxis),this):mt.bool(t)?(this.options.drag.enabled=t,this):this.options.drag},beforeMove:GM,move:zz,defaults:{startAxis:"xy",lockAxis:"xy"},getCursor(){return"move"},filterEventType:e=>e.search("drag")===0};Sc.use(S2);function VPe(e){const{actions:t,browser:n,Interactable:r,defaults:i}=e;Mc.cursors=GPe(n),Mc.defaultMargin=n.supportsTouch||n.supportsPointerEvent?20:10,r.prototype.resizable=function(a){return qPe(this,a,e)},t.map.resize=Mc,t.methodDict.resize="resizable",i.actions.resize=Mc.defaults}function zPe(e){const{interaction:t,interactable:n,element:r,rect:i,buttons:a}=e;if(!i)return;const o=fn({},t.coords.cur.page),s=n.options.resize;if(!(!(s&&s.enabled)||t.pointerIsDown&&/mouse|pointer/.test(t.pointerType)&&(a&s.mouseButtons)===0)){if(mt.object(s.edges)){const u={left:!1,right:!1,top:!1,bottom:!1};for(const c in u)u[c]=KPe(c,s.edges[c],o,t._latestPointer.eventTarget,r,i,s.margin||Mc.defaultMargin);u.left=u.left&&!u.right,u.top=u.top&&!u.bottom,(u.left||u.right||u.top||u.bottom)&&(e.action={name:"resize",edges:u})}else{const u=s.axis!=="y"&&o.x>i.right-Mc.defaultMargin,c=s.axis!=="x"&&o.y>i.bottom-Mc.defaultMargin;(u||c)&&(e.action={name:"resize",axes:(u?"x":"")+(c?"y":"")})}return e.action?!1:void 0}}function qPe(e,t,n){return mt.object(t)?(e.options.resize.enabled=t.enabled!==!1,e.setPerAction("resize",t),e.setOnEvents("resize",t),mt.string(t.axis)&&/^x$|^y$|^xy$/.test(t.axis)?e.options.resize.axis=t.axis:t.axis===null&&(e.options.resize.axis=n.defaults.actions.resize.axis),mt.bool(t.preserveAspectRatio)?e.options.resize.preserveAspectRatio=t.preserveAspectRatio:mt.bool(t.square)&&(e.options.resize.square=t.square),e):mt.bool(t)?(e.options.resize.enabled=t,e):e.options.resize}function KPe(e,t,n,r,i,a,o){if(!t)return!1;if(t===!0){const s=mt.number(a.width)?a.width:a.right-a.left,u=mt.number(a.height)?a.height:a.bottom-a.top;if(o=Math.min(o,Math.abs((e==="left"||e==="right"?s:u)/2)),s<0&&(e==="left"?e="right":e==="right"&&(e="left")),u<0&&(e==="top"?e="bottom":e==="bottom"&&(e="top")),e==="left"){const c=s>=0?a.left:a.right;return n.x<c+o}if(e==="top"){const c=u>=0?a.top:a.bottom;return n.y<c+o}if(e==="right")return n.x>(s>=0?a.right:a.left)-o;if(e==="bottom")return n.y>(u>=0?a.bottom:a.top)-o}return mt.element(r)?mt.element(t)?t===r:OM(r,t,i):!1}function GPe(e){return e.isIe9?{x:"e-resize",y:"s-resize",xy:"se-resize",top:"n-resize",left:"w-resize",bottom:"s-resize",right:"e-resize",topleft:"se-resize",bottomright:"se-resize",topright:"ne-resize",bottomleft:"ne-resize"}:{x:"ew-resize",y:"ns-resize",xy:"nwse-resize",top:"ns-resize",left:"ew-resize",bottom:"ns-resize",right:"ew-resize",topleft:"nwse-resize",bottomright:"nwse-resize",topright:"nesw-resize",bottomleft:"nesw-resize"}}function WPe(e){let{iEvent:t,interaction:n}=e;if(n.prepared.name!=="resize"||!n.prepared.edges)return;const r=t,i=n.rect;n._rects={start:fn({},i),corrected:fn({},i),previous:fn({},i),delta:{left:0,right:0,width:0,top:0,bottom:0,height:0}},r.edges=n.prepared.edges,r.rect=n._rects.corrected,r.deltaRect=n._rects.delta}function XPe(e){let{iEvent:t,interaction:n}=e;if(n.prepared.name!=="resize"||!n.prepared.edges)return;const r=t,a=n.interactable.options.resize.invert,o=a==="reposition"||a==="negate",s=n.rect,{start:u,corrected:c,delta:A,previous:d}=n._rects;if(fn(d,c),o){if(fn(c,s),a==="reposition"){if(c.top>c.bottom){const f=c.top;c.top=c.bottom,c.bottom=f}if(c.left>c.right){const f=c.left;c.left=c.right,c.right=f}}}else c.top=Math.min(s.top,u.bottom),c.bottom=Math.max(s.bottom,u.top),c.left=Math.min(s.left,u.right),c.right=Math.max(s.right,u.left);c.width=c.right-c.left,c.height=c.bottom-c.top;for(const f in c)A[f]=c[f]-d[f];r.edges=n.prepared.edges,r.rect=c,r.deltaRect=A}function JPe(e){let{iEvent:t,interaction:n}=e;if(n.prepared.name!=="resize"||!n.prepared.edges)return;const r=t;r.edges=n.prepared.edges,r.rect=n._rects.corrected,r.deltaRect=n._rects.delta}function qz(e){let{iEvent:t,interaction:n}=e;if(n.prepared.name!=="resize"||!n.resizeAxes)return;const r=n.interactable.options,i=t;r.resize.square?(n.resizeAxes==="y"?i.delta.x=i.delta.y:i.delta.y=i.delta.x,i.axes="xy"):(i.axes=n.resizeAxes,n.resizeAxes==="x"?i.delta.y=0:n.resizeAxes==="y"&&(i.delta.x=0))}const Mc={id:"actions/resize",before:["actions/drag"],install:VPe,listeners:{"interactions:new":e=>{let{interaction:t}=e;t.resizeAxes="xy"},"interactions:action-start":e=>{WPe(e),qz(e)},"interactions:action-move":e=>{XPe(e),qz(e)},"interactions:action-end":JPe,"auto-start:check":zPe},defaults:{square:!1,preserveAspectRatio:!1,axis:"xy",margin:NaN,edges:null,invert:"none"},cursors:null,getCursor(e){let{edges:t,axis:n,name:r}=e;const i=Mc.cursors;let a=null;if(n)a=i[r+n];else if(t){let o="";for(const s of["top","bottom","left","right"])t[s]&&(o+=s);a=i[o]}return a},filterEventType:e=>e.search("resize")===0,defaultMargin:null};Sc.use(Mc);var ZPe=()=>{},$Pe=()=>{},e9e=e=>{const t=[["x","y"],["left","top"],["right","bottom"],["width","height"]].filter(r=>{let[i,a]=r;return i in e||a in e}),n=(r,i)=>{const{range:a,limits:o={left:-1/0,right:1/0,top:-1/0,bottom:1/0},offset:s={x:0,y:0}}=e,u={range:a,grid:e,x:null,y:null};for(const[c,A]of t){const d=Math.round((r-s.x)/e[c]),f=Math.round((i-s.y)/e[A]);u[c]=Math.max(o.left,Math.min(o.right,d*e[c]+s.x)),u[A]=Math.max(o.top,Math.min(o.bottom,f*e[A]+s.y))}return u};return n.grid=e,n.coordFields=t,n},t9e=Object.freeze({__proto__:null,edgeTarget:ZPe,elements:$Pe,grid:e9e});const n9e={id:"snappers",install(e){const{interactStatic:t}=e;t.snappers=fn(t.snappers||{},t9e),t.createSnapGrid=t.snappers.grid}};class Kz{constructor(t){this.states=[],this.startOffset={left:0,right:0,top:0,bottom:0},this.startDelta=void 0,this.result=void 0,this.endResult=void 0,this.startEdges=void 0,this.edges=void 0,this.interaction=void 0,this.interaction=t,this.result=M2(),this.edges={left:!1,right:!1,top:!1,bottom:!1}}start(t,n){let{phase:r}=t;const{interaction:i}=this,a=r9e(i);this.prepareStates(a),this.startEdges=fn({},i.edges),this.edges=fn({},this.startEdges),this.startOffset=i9e(i.rect,n),this.startDelta={x:0,y:0};const o=this.fillArg({phase:r,pageCoords:n,preEnd:!1});return this.result=M2(),this.startAll(o),this.result=this.setAll(o)}fillArg(t){const{interaction:n}=this;return t.interaction=n,t.interactable=n.interactable,t.element=n.element,t.rect||(t.rect=n.rect),t.edges||(t.edges=this.startEdges),t.startOffset=this.startOffset,t}startAll(t){for(const n of this.states)n.methods.start&&(t.state=n,n.methods.start(t))}setAll(t){const{phase:n,preEnd:r,skipModifiers:i,rect:a,edges:o}=t;t.coords=fn({},t.pageCoords),t.rect=fn({},a),t.edges=fn({},o);const s=i?this.states.slice(i):this.states,u=M2(t.coords,t.rect);for(const f of s){var c;const{options:h}=f,p=fn({},t.coords);let m=null;(c=f.methods)!=null&&c.set&&this.shouldDo(h,r,n)&&(t.state=f,m=f.methods.set(t),jM(t.edges,t.rect,{x:t.coords.x-p.x,y:t.coords.y-p.y})),u.eventProps.push(m)}fn(this.edges,t.edges),u.delta.x=t.coords.x-t.pageCoords.x,u.delta.y=t.coords.y-t.pageCoords.y,u.rectDelta.left=t.rect.left-a.left,u.rectDelta.right=t.rect.right-a.right,u.rectDelta.top=t.rect.top-a.top,u.rectDelta.bottom=t.rect.bottom-a.bottom;const A=this.result.coords,d=this.result.rect;if(A&&d){const f=u.rect.left!==d.left||u.rect.right!==d.right||u.rect.top!==d.top||u.rect.bottom!==d.bottom;u.changed=f||A.x!==u.coords.x||A.y!==u.coords.y}return u}applyToInteraction(t){const{interaction:n}=this,{phase:r}=t,i=n.coords.cur,a=n.coords.start,{result:o,startDelta:s}=this,u=o.delta;r==="start"&&fn(this.startDelta,o.delta);for(const[d,f]of[[a,s],[i,u]])d.page.x+=f.x,d.page.y+=f.y,d.client.x+=f.x,d.client.y+=f.y;const{rectDelta:c}=this.result,A=t.rect||n.rect;A.left+=c.left,A.right+=c.right,A.top+=c.top,A.bottom+=c.bottom,A.width=A.right-A.left,A.height=A.bottom-A.top}setAndApply(t){const{interaction:n}=this,{phase:r,preEnd:i,skipModifiers:a}=t,o=this.setAll(this.fillArg({preEnd:i,phase:r,pageCoords:t.modifiedCoords||n.coords.cur.page}));if(this.result=o,!o.changed&&(!a||a<this.states.length)&&n.interacting())return!1;if(t.modifiedCoords){const{page:s}=n.coords.cur,u={x:t.modifiedCoords.x-s.x,y:t.modifiedCoords.y-s.y};o.coords.x+=u.x,o.coords.y+=u.y,o.delta.x+=u.x,o.delta.y+=u.y}this.applyToInteraction(t)}beforeEnd(t){const{interaction:n,event:r}=t,i=this.states;if(!i||!i.length)return;let a=!1;for(const o of i){t.state=o;const{options:s,methods:u}=o,c=u.beforeEnd&&u.beforeEnd(t);if(c)return this.endResult=c,!1;a=a||!a&&this.shouldDo(s,!0,t.phase,!0)}a&&n.move({event:r,preEnd:!0})}stop(t){const{interaction:n}=t;if(!this.states||!this.states.length)return;const r=fn({states:this.states,interactable:n.interactable,element:n.element,rect:null},t);this.fillArg(r);for(const i of this.states)r.state=i,i.methods.stop&&i.methods.stop(r);this.states=null,this.endResult=null}prepareStates(t){this.states=[];for(let n=0;n<t.length;n++){const{options:r,methods:i,name:a}=t[n];this.states.push({options:r,methods:i,index:n,name:a})}return this.states}restoreInteractionCoords(t){let{interaction:{coords:n,rect:r,modification:i}}=t;if(!i.result)return;const{startDelta:a}=i,{delta:o,rectDelta:s}=i.result,u=[[n.start,a],[n.cur,o]];for(const[c,A]of u)c.page.x-=A.x,c.page.y-=A.y,c.client.x-=A.x,c.client.y-=A.y;r.left-=s.left,r.right-=s.right,r.top-=s.top,r.bottom-=s.bottom}shouldDo(t,n,r,i){return!(!t||t.enabled===!1||i&&!t.endOnly||t.endOnly&&!n||r==="start"&&!t.setStart)}copyFrom(t){this.startOffset=t.startOffset,this.startDelta=t.startDelta,this.startEdges=t.startEdges,this.edges=t.edges,this.states=t.states.map(n=>Jp(n)),this.result=M2(fn({},t.result.coords),fn({},t.result.rect))}destroy(){for(const t in this)this[t]=null}}function M2(e,t){return{rect:t,coords:e,delta:{x:0,y:0},rectDelta:{left:0,right:0,top:0,bottom:0},eventProps:[],changed:!0}}function r9e(e){const t=e.interactable.options[e.prepared.name],n=t.modifiers;return n&&n.length?n:["snap","snapSize","snapEdges","restrict","restrictEdges","restrictSize"].map(r=>{const i=t[r];return i&&i.enabled&&{options:i,methods:i._methods}}).filter(r=>!!r)}function i9e(e,t){return e?{left:t.x-e.left,top:t.y-e.top,right:e.right-t.x,bottom:e.bottom-t.y}:{left:0,top:0,right:0,bottom:0}}function nd(e,t){const{defaults:n}=e,r={start:e.start,set:e.set,beforeEnd:e.beforeEnd,stop:e.stop},i=a=>{const o=a||{};o.enabled=o.enabled!==!1;for(const u in n)u in o||(o[u]=n[u]);const s={options:o,methods:r,name:t,enable:()=>(o.enabled=!0,s),disable:()=>(o.enabled=!1,s)};return s};return t&&typeof t=="string"&&(i._defaults=n,i._methods=r),i}function WM(e){let{iEvent:t,interaction:n}=e;const r=n.modification.result;r&&(t.modifiers=r.eventProps)}const a9e={id:"modifiers/base",before:["actions"],install:e=>{e.defaults.perAction.modifiers=[]},listeners:{"interactions:new":e=>{let{interaction:t}=e;t.modification=new Kz(t)},"interactions:before-action-start":e=>{const{interaction:t}=e,n=e.interaction.modification;n.start(e,t.coords.start.page),t.edges=n.edges,n.applyToInteraction(e)},"interactions:before-action-move":e=>{const{interaction:t}=e,{modification:n}=t,r=n.setAndApply(e);return t.edges=n.edges,r},"interactions:before-action-end":e=>{const{interaction:t}=e,{modification:n}=t,r=n.beforeEnd(e);return t.edges=n.startEdges,r},"interactions:action-start":WM,"interactions:action-move":WM,"interactions:action-end":WM,"interactions:after-action-start":e=>e.interaction.modification.restoreInteractionCoords(e),"interactions:after-action-move":e=>e.interaction.modification.restoreInteractionCoords(e),"interactions:stop":e=>e.interaction.modification.stop(e)}},o9e={start(e){const{state:t,rect:n,edges:r,pageCoords:i}=e;let{ratio:a,enabled:o}=t.options;const{equalDelta:s,modifiers:u}=t.options;a==="preserve"&&(a=n.width/n.height),t.startCoords=fn({},i),t.startRect=fn({},n),t.ratio=a,t.equalDelta=s;const c=t.linkedEdges={top:r.top||r.left&&!r.bottom,left:r.left||r.top&&!r.right,bottom:r.bottom||r.right&&!r.top,right:r.right||r.bottom&&!r.left};if(t.xIsPrimaryAxis=!!(r.left||r.right),t.equalDelta){const d=(c.left?1:-1)*(c.top?1:-1);t.edgeSign={x:d,y:d}}else t.edgeSign={x:c.left?-1:1,y:c.top?-1:1};if(o!==!1&&fn(r,c),!(u!=null&&u.length))return;const A=new Kz(e.interaction);A.copyFrom(e.interaction.modification),A.prepareStates(u),t.subModification=A,A.startAll({...e})},set(e){const{state:t,rect:n,coords:r}=e,{linkedEdges:i}=t,a=fn({},r),o=t.equalDelta?s9e:l9e;if(fn(e.edges,i),o(t,t.xIsPrimaryAxis,r,n),!t.subModification)return null;const s=fn({},n);jM(i,s,{x:r.x-a.x,y:r.y-a.y});const u=t.subModification.setAll({...e,rect:s,edges:i,pageCoords:r,prevCoords:r,prevRect:s}),{delta:c}=u;if(u.changed){const A=Math.abs(c.x)>Math.abs(c.y);o(t,A,u.coords,u.rect),fn(r,u.coords)}return u.eventProps},defaults:{ratio:"preserve",equalDelta:!1,modifiers:[],enabled:!1}};function s9e(e,t,n){let{startCoords:r,edgeSign:i}=e;t?n.y=r.y+(n.x-r.x)*i.y:n.x=r.x+(n.y-r.y)*i.x}function l9e(e,t,n,r){let{startRect:i,startCoords:a,ratio:o,edgeSign:s}=e;if(t){const u=r.width/o;n.y=a.y+(u-i.height)*s.y}else{const u=r.height*o;n.x=a.x+(u-i.width)*s.x}}var u9e=nd(o9e,"aspectRatio");function c9e(e){let{rect:t,startOffset:n,state:r,interaction:i,pageCoords:a}=e;const{options:o}=r,{elementRect:s}=o,u=fn({left:0,top:0,right:0,bottom:0},o.offset||{});if(t&&s){const c=Vf(o.restriction,i,a);if(c){const A=c.right-c.left-t.width,d=c.bottom-c.top-t.height;A<0&&(u.left+=A,u.right+=A),d<0&&(u.top+=d,u.bottom+=d)}u.left+=n.left-t.width*s.left,u.top+=n.top-t.height*s.top,u.right+=n.right-t.width*(1-s.right),u.bottom+=n.bottom-t.height*(1-s.bottom)}r.offset=u}function A9e(e){let{coords:t,interaction:n,state:r}=e;const{options:i,offset:a}=r,o=Vf(i.restriction,n,t);if(!o)return;const s=MPe(o);t.x=Math.max(Math.min(s.right-a.right,t.x),s.left+a.left),t.y=Math.max(Math.min(s.bottom-a.bottom,t.y),s.top+a.top)}function Vf(e,t,n){return mt.func(e)?av(e,t.interactable,t.element,[n.x,n.y,t]):av(e,t.interactable,t.element)}const k2={start:c9e,set:A9e,defaults:{restriction:null,elementRect:null,offset:null,endOnly:!1,enabled:!1}};var d9e=nd(k2,"restrict");const Gz={top:1/0,left:1/0,bottom:-1/0,right:-1/0},Wz={top:-1/0,left:-1/0,bottom:1/0,right:1/0};function f9e(e){let{interaction:t,startOffset:n,state:r}=e;const{options:i}=r;let a;if(i){const o=Vf(i.offset,t,t.coords.start.page);a=C2(o)}a=a||{x:0,y:0},r.offset={top:a.y+n.top,left:a.x+n.left,bottom:a.y-n.bottom,right:a.x-n.right}}function h9e(e){let{coords:t,edges:n,interaction:r,state:i}=e;const{offset:a,options:o}=i;if(!n)return;const s=fn({},t),u=Vf(o.inner,r,s)||{},c=Vf(o.outer,r,s)||{};Xz(u,Gz),Xz(c,Wz),n.top?t.y=Math.min(Math.max(c.top+a.top,s.y),u.top+a.top):n.bottom&&(t.y=Math.max(Math.min(c.bottom+a.bottom,s.y),u.bottom+a.bottom)),n.left?t.x=Math.min(Math.max(c.left+a.left,s.x),u.left+a.left):n.right&&(t.x=Math.max(Math.min(c.right+a.right,s.x),u.right+a.right))}function Xz(e,t){for(const n of["top","left","bottom","right"])n in e||(e[n]=t[n]);return e}const sv={noInner:Gz,noOuter:Wz,start:f9e,set:h9e,defaults:{inner:null,outer:null,offset:null,endOnly:!1,enabled:!1}};var p9e=nd(sv,"restrictEdges");const m9e=fn({get elementRect(){return{top:0,left:0,bottom:1,right:1}},set elementRect(e){}},k2.defaults),g9e={start:k2.start,set:k2.set,defaults:m9e};var v9e=nd(g9e,"restrictRect");const y9e={width:-1/0,height:-1/0},b9e={width:1/0,height:1/0};function _9e(e){return sv.start(e)}function w9e(e){const{interaction:t,state:n,rect:r,edges:i}=e,{options:a}=n;if(!i)return;const o=Iz(Vf(a.min,t,e.coords))||y9e,s=Iz(Vf(a.max,t,e.coords))||b9e;n.options={endOnly:a.endOnly,inner:fn({},sv.noInner),outer:fn({},sv.noOuter)},i.top?(n.options.inner.top=r.bottom-o.height,n.options.outer.top=r.bottom-s.height):i.bottom&&(n.options.inner.bottom=r.top+o.height,n.options.outer.bottom=r.top+s.height),i.left?(n.options.inner.left=r.right-o.width,n.options.outer.left=r.right-s.width):i.right&&(n.options.inner.right=r.left+o.width,n.options.outer.right=r.left+s.width),sv.set(e),n.options=a}var x9e=nd({start:_9e,set:w9e,defaults:{min:null,max:null,endOnly:!1,enabled:!1}},"restrictSize");function B9e(e){const{interaction:t,interactable:n,element:r,rect:i,state:a,startOffset:o}=e,{options:s}=a,u=s.offsetWithOrigin?S9e(e):{x:0,y:0};let c;if(s.offset==="startCoords")c={x:t.coords.start.page.x,y:t.coords.start.page.y};else{const d=av(s.offset,n,r,[t]);c=C2(d)||{x:0,y:0},c.x+=u.x,c.y+=u.y}const{relativePoints:A}=s;a.offsets=i&&A&&A.length?A.map((d,f)=>({index:f,relativePoint:d,x:o.left-i.width*d.x+c.x,y:o.top-i.height*d.y+c.y})):[{index:0,relativePoint:null,x:c.x,y:c.y}]}function C9e(e){const{interaction:t,coords:n,state:r}=e,{options:i,offsets:a}=r,o=VM(t.interactable,t.element,t.prepared.name),s=fn({},n),u=[];i.offsetWithOrigin||(s.x-=o.x,s.y-=o.y);for(const A of a){const d=s.x-A.x,f=s.y-A.y;for(let h=0,p=i.targets.length;h<p;h++){const m=i.targets[h];let v;mt.func(m)?v=m(d,f,t._proxy,A,h):v=m,v&&u.push({x:(mt.number(v.x)?v.x:d)+A.x,y:(mt.number(v.y)?v.y:f)+A.y,range:mt.number(v.range)?v.range:i.range,source:m,index:h,offset:A})}}const c={target:null,inRange:!1,distance:0,range:0,delta:{x:0,y:0}};for(const A of u){const d=A.range,f=A.x-s.x,h=A.y-s.y,p=_2(f,h);let m=p<=d;d===1/0&&c.inRange&&c.range!==1/0&&(m=!1),(!c.target||(m?c.inRange&&d!==1/0?p/d<c.distance/c.range:d===1/0&&c.range!==1/0||p<c.distance:!c.inRange&&p<c.distance))&&(c.target=A,c.distance=p,c.range=d,c.inRange=m,c.delta.x=f,c.delta.y=h)}return c.inRange&&(n.x=c.target.x,n.y=c.target.y),r.closest=c,c}function S9e(e){const{element:t}=e.interaction;return C2(av(e.state.options.origin,null,null,[t]))||VM(e.interactable,t,e.interaction.prepared.name)}const XM={start:B9e,set:C9e,defaults:{range:1/0,targets:null,offset:null,offsetWithOrigin:!0,origin:null,relativePoints:null,endOnly:!1,enabled:!1}};var M9e=nd(XM,"snap");function k9e(e){const{state:t,edges:n}=e,{options:r}=t;if(!n)return null;e.state={options:{targets:null,relativePoints:[{x:n.left?0:1,y:n.top?0:1}],offset:r.offset||"self",origin:{x:0,y:0},range:r.range}},t.targetFields=t.targetFields||[["width","height"],["x","y"]],XM.start(e),t.offsets=e.state.offsets,e.state=t}function E9e(e){const{interaction:t,state:n,coords:r}=e,{options:i,offsets:a}=n,o={x:r.x-a[0].x,y:r.y-a[0].y};n.options=fn({},i),n.options.targets=[];for(const u of i.targets||[]){let c;if(mt.func(u)?c=u(o.x,o.y,t):c=u,!!c){for(const[A,d]of n.targetFields)if(A in c||d in c){c.x=c[A],c.y=c[d];break}n.options.targets.push(c)}}const s=XM.set(e);return n.options=i,s}const E2={start:k9e,set:E9e,defaults:{range:1/0,targets:null,offset:null,endOnly:!1,enabled:!1}};var L9e=nd(E2,"snapSize");function T9e(e){const{edges:t}=e;return t?(e.state.targetFields=e.state.targetFields||[[t.left?"left":"right",t.top?"top":"bottom"]],E2.start(e)):null}const N9e={start:T9e,set:E2.set,defaults:fn(Jp(E2.defaults),{targets:void 0,range:void 0,offset:{x:0,y:0}})};var F9e=nd(N9e,"snapEdges");const lv=()=>{};lv._defaults={};var JM={aspectRatio:u9e,restrictEdges:p9e,restrict:d9e,restrictRect:v9e,restrictSize:x9e,snapEdges:F9e,snap:M9e,snapSize:L9e,spring:lv,avoid:lv,transform:lv,rubberband:lv};const I9e={id:"modifiers",install(e){const{interactStatic:t}=e;e.usePlugin(a9e),e.usePlugin(n9e),t.modifiers=JM;for(const n in JM){const{_defaults:r,_methods:i}=JM[n];r._methods=i,e.defaults.perAction[n]=r}}};Sc.use(I9e);var uv=function(e){return e.touchAction="touchAction",e.boxSizing="boxSizing",e.noListeners="noListeners",e}(uv||{});const ZM="[interact.js] ",$M={touchAction:"https://developer.mozilla.org/en-US/docs/Web/CSS/touch-action",boxSizing:"https://developer.mozilla.org/en-US/docs/Web/CSS/box-sizing"};function O9e(e){let{logger:t}=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};const{Interactable:n,defaults:r}=e;e.logger=t||console,r.base.devTools={ignore:{}},n.prototype.devTools=function(a){return a?(fn(this.options.devTools,a),this):this.options.devTools};const{_onOff:i}=n.prototype;n.prototype._onOff=function(a,o,s,u,c){if(mt.string(this.target)||this.target.addEventListener)return i.call(this,a,o,s,u,c);mt.object(o)&&!mt.array(o)&&(u=s,s=null);const A=jf(o,s,c);for(const d in A)ov(d,e.actions)||e.logger.warn(ZM+`Can't add native "${d}" event listener to target without \`addEventListener(type, listener, options)\` prop.`);return i.call(this,a,A,u)}}const Jz=[{name:uv.touchAction,perform(e){let{element:t}=e;return!!t&&!D9e(t,"touchAction",/pan-|pinch|none/)},getInfo(e){let{element:t}=e;return[t,$M.touchAction]},text:`Consider adding CSS "touch-action: none" to this element
|
|
430
|
+
`}),n},mUe=(e,t,n)=>{const r=pUe(t,n);hUe(r,`${e||"data"}.csv`)},gUe={key:0,class:"block truncate overflow-hidden text-ellipsis pr-6 w-full pb-1.5"},vUe={class:"leading-[1] font-semibold text-md"},yUe={key:2,class:"absolute right-2 top-2"},bUe={key:1,class:"flex justify-center pt-10 text-lg font-semibold"},TM={__name:"Panel",props:{objects:Array,panel:Object,layout:Object,viewing:{type:Boolean,default:!1},mouseover:{type:Boolean,default:!1},isMobile:{type:Boolean,default:!1},theme:{type:String,default:"light"},paginationStore:{type:Object,default:()=>({})}},emits:["delete","edit"],setup(e,{emit:t}){const n={Alert:ZY,AlertSprite:$Y,Chart:eR,Counter:tR,Histogram:UR,Image:PR,IPMap:DR,MetricChart:HR,PieChart:YR,SparkChart:RR,StackedBarChart:QR,Table:jR,Text:VR,TopNChart:zR},r=e,i=t,a=l.ref(u()),o=l.computed(()=>r.panel.panelType==="text"||r.panel.panelType==="image"||a.value.table&&a.value.table.rows||a.value.stream?!1:!(a.value.alert&&a.value.alert.alerts));function s(){return!r.panel||!r.panel.panelType?"":n[oQ[r.panel.panelType]]}function u(){const A=r.objects.find(d=>d.name===r.panel.dataTable);return A||{}}function c(){mUe(r.panel.title,r.panel.panelConfig.columns,a.value.table.rows)}return(A,d)=>(l.openBlock(),l.createElementBlock(l.Fragment,null,[l.createElementVNode("div",{class:l.normalizeClass(["relative pl-2 w-full",e.panel.panelType==="image"||e.panel.panelType==="text"?"":"py-1"])},[e.panel.title?(l.openBlock(),l.createElementBlock("div",gUe,[l.createElementVNode("span",vUe,l.toDisplayString(e.panel.title),1)])):l.createCommentVNode("",!0),e.viewing?e.viewing&&e.panel.panelType==="table"&&e.mouseover?(l.openBlock(),l.createElementBlock("div",yUe,[l.createVNode(l.unref(E1),{download:"",hideTooltip:"",onDownload:c})])):l.createCommentVNode("",!0):(l.openBlock(),l.createBlock(l.unref(Nu),{key:1,as:"div",class:"absolute right-1 top-2"},{default:l.withCtx(()=>[l.createVNode(l.unref(Fu),{class:"-m-2.5 block p-2.5 text-gray-400 hover:text-gray-500"},{default:l.withCtx(()=>[d[2]||(d[2]=l.createElementVNode("span",{class:"sr-only"},"Open options",-1)),l.createVNode(l.unref(L6),{class:"icon-md","aria-hidden":"true"})]),_:1,__:[2]}),l.createVNode(l.Transition,{"enter-active-class":"transition ease-out duration-100","enter-from-class":"transform opacity-0 scale-95","enter-to-class":"transform opacity-100 scale-100","leave-active-class":"transition ease-in duration-75","leave-from-class":"transform opacity-100 scale-100","leave-to-class":"transform opacity-0 scale-95"},{default:l.withCtx(()=>[l.createVNode(l.unref(Iu),{class:"absolute right-0 z-10 mt-0.5 w-32 origin-top-right rounded-md py-2 shadow-lg ring-1 ring-gray-900/5 focus:outline-none bg-white dark:bg-black"},{default:l.withCtx(()=>[l.createVNode(l.unref(is),null,{default:l.withCtx(({active:f})=>[l.createElementVNode("div",{class:l.normalizeClass([f?"cursor-pointer bg-gray-50 dark:bg-gray-800":"","block px-3 py-1 text-sm leading-6"]),onClick:d[0]||(d[0]=h=>i("edit",e.panel))}," Edit ",2)]),_:1}),e.panel.panelType==="table"?(l.openBlock(),l.createBlock(l.unref(is),{key:0},{default:l.withCtx(({active:f})=>[l.createElementVNode("div",{class:l.normalizeClass([f?"cursor-pointer bg-gray-50 dark:bg-gray-800":"","block px-3 py-1 text-sm leading-6"]),onClick:c}," Download CSV ",2)]),_:1})):l.createCommentVNode("",!0),l.createVNode(l.unref(is),null,{default:l.withCtx(({active:f})=>[l.createElementVNode("div",{class:l.normalizeClass([f?"cursor-pointer bg-gray-50 dark:bg-gray-800":"","block px-3 py-1 text-sm leading-6"]),onClick:d[1]||(d[1]=h=>i("delete",e.panel.key))}," Delete ",2)]),_:1})]),_:1})]),_:1})]),_:1}))],2),o.value?(l.openBlock(),l.createElementBlock("span",bUe," No data available ")):(l.openBlock(),l.createBlock(l.resolveDynamicComponent(s()),{key:0,config:e.panel.panelConfig,obj:a.value,id:`panel${e.panel.key}${e.isMobile?"-mobile":""}`,layout:e.layout,class:l.normalizeClass(e.panel.panelType==="image"||e.panel.panelType==="text"?"":"p-2"),theme:e.theme,paginationStore:e.paginationStore},null,8,["config","obj","id","layout","class","theme","paginationStore"]))],64))}};function _Ue(e){return{all:e=e||new Map,on:function(t,n){var r=e.get(t);r?r.push(n):e.set(t,[n])},off:function(t,n){var r=e.get(t);r&&(n?r.splice(r.indexOf(n)>>>0,1):e.set(t,[]))},emit:function(t,n){var r=e.get(t);r&&r.slice().map(function(i){i(n)}),(r=e.get("*"))&&r.slice().map(function(i){i(t,n)})}}}function wUe(e){let t=0,n;for(let r=0,i=e.length;r<i;r++)n=e[r].y+e[r].h,n>t&&(t=n);return t}function NM(e){const t=Array(e.length);for(let n=0,r=e.length;n<r;n++)t[n]=xUe(e[n]);return t}function xUe(e){return JSON.parse(JSON.stringify(e))}function $V(e,t){return!(e===t||e.x+e.w<=t.x||e.x>=t.x+t.w||e.y+e.h<=t.y||e.y>=t.y+t.h)}function Wp(e,t,n){const r=nz(e),i=iz(e),a=Array(e.length);for(let o=0,s=i.length;o<s;o++){let u=i[o];u.static||(u=BUe(r,u,t,n),r.push(u)),a[e.indexOf(u)]=u,u.moved=!1}return a}function BUe(e,t,n,r){if(n)for(;t.y>0&&!tv(e,t);)t.y--;else if(r){const a=r[t.i].y;for(;t.y>a&&!tv(e,t);)t.y--}let i;for(;i=tv(e,t);)t.y=i.y+i.h;return t}function CUe(e,t){const n=nz(e);for(let r=0,i=e.length;r<i;r++){const a=e[r];if(a.x+a.w>t.cols&&(a.x=t.cols-a.w),a.x<0&&(a.x=0,a.w=t.cols),!a.static)n.push(a);else for(;tv(n,a);)a.y++}return e}function ez(e,t){for(let n=0,r=e.length;n<r;n++)if(e[n].i===t)return e[n]}function tv(e,t){for(let n=0,r=e.length;n<r;n++)if($V(e[n],t))return e[n]}function tz(e,t){return e.filter(n=>$V(n,t))}function nz(e){return e.filter(t=>t.static)}function FM(e,t,n,r,i,a){if(t.static)return e;const o=t.x,s=t.y,u=r&&t.y>r;typeof n=="number"&&(t.x=n),typeof r=="number"&&(t.y=r),t.moved=!0;let c=iz(e);u&&(c=c.reverse());const A=tz(c,t);if(a&&A.length)return t.x=o,t.y=s,t.moved=!1,e;for(let d=0,f=A.length;d<f;d++){const h=A[d];h.moved||t.y>h.y&&t.y-h.y>h.h/4||(h.static?e=rz(e,h,t,i):e=rz(e,t,h,i))}return e}function rz(e,t,n,r){if(r){const a={x:n.x,y:n.y,w:n.w,h:n.h};if(a.y=Math.max(t.y-n.h,0),!tv(e,a))return FM(e,n,void 0,a.y,!1)}return FM(e,n,void 0,n.y+1,!1)}function SUe(e,t,n,r){const i="translate3d("+t+"px,"+e+"px, 0)";return{transform:i,WebkitTransform:i,MozTransform:i,msTransform:i,OTransform:i,width:n+"px",height:r+"px",position:"absolute"}}function MUe(e,t,n,r){const i="translate3d("+t*-1+"px,"+e+"px, 0)";return{transform:i,WebkitTransform:i,MozTransform:i,msTransform:i,OTransform:i,width:n+"px",height:r+"px",position:"absolute"}}function kUe(e,t,n,r){return{top:e+"px",left:t+"px",width:n+"px",height:r+"px",position:"absolute"}}function EUe(e,t,n,r){return{top:e+"px",right:t+"px",width:n+"px",height:r+"px",position:"absolute"}}function iz(e){return[].concat(e).sort(function(n,r){return n.y===r.y&&n.x===r.x?0:n.y>r.y||n.y===r.y&&n.x>r.x?1:-1})}function LUe(e,t){t=t||"Layout";const n=["x","y","w","h"],r=[];if(!Array.isArray(e))throw new Error(t+" must be an array!");for(let i=0,a=e.length;i<a;i++){const o=e[i];for(let s=0;s<n.length;s++)if(typeof o[n[s]]!="number")throw new Error("VueGridLayout: "+t+"["+i+"]."+n[s]+" must be a number!");if(o.i===void 0||o.i===null)throw new Error("VueGridLayout: "+t+"["+i+"].i cannot be null!");if(typeof o.i!="number"&&typeof o.i!="string")throw new Error("VueGridLayout: "+t+"["+i+"].i must be a string or number!");if(r.indexOf(o.i)>=0)throw new Error("VueGridLayout: "+t+"["+i+"].i must be unique!");if(r.push(o.i),o.static!==void 0&&typeof o.static!="boolean")throw new Error("VueGridLayout: "+t+"["+i+"].static must be a boolean!")}}function az(e){return TUe(e)}function TUe(e){const t=e.target,n=t.offsetParent||document.body,r=t.offsetParent===document.body?{left:0,top:0}:n.getBoundingClientRect(),i=e.clientX+n.scrollLeft-r.left,a=e.clientY+n.scrollTop-r.top;return{x:i,y:a}}function oz(e,t,n,r){return NUe(e)?{deltaX:n-e,deltaY:r-t,lastX:e,lastY:t,x:n,y:r}:{deltaX:0,deltaY:0,lastX:n,lastY:r,x:n,y:r}}function NUe(e){return typeof e=="number"&&!isNaN(e)}function FUe(e,t){const n=sz(e);let r=n[0];for(let i=1,a=n.length;i<a;i++){const o=n[i];t>e[o]&&(r=o)}return r}function IM(e,t){if(!t[e])throw new Error("ResponsiveGridLayout: `cols` entry for breakpoint "+e+" is missing!");return t[e]}function IUe(e,t,n,r,i,a,o){if(t[r])return NM(t[r]);let s=e;const u=sz(n),c=u.slice(u.indexOf(r));for(let A=0,d=c.length;A<d;A++){const f=c[A];if(t[f]){s=t[f];break}}return s=NM(s||[]),Wp(CUe(s,{cols:a}),o)}function sz(e){return Object.keys(e).sort(function(n,r){return e[n]-e[r]})}let OUe="auto";function DUe(){return typeof document<"u"}function lz(){return typeof window<"u"}function uz(){return DUe()?typeof document.dir<"u"?document.dir:document.getElementsByTagName("html")[0].getAttribute("dir")||"auto":OUe}function UUe(e,t){return lz?(window.addEventListener(e,t),!0):(t(),!1)}function PUe(e,t){lz&&window.removeEventListener(e,t)}const Xr={init:HUe,document:null,DocumentFragment:null,SVGElement:null,SVGSVGElement:null,SVGElementInstance:null,Element:null,HTMLElement:null,Event:null,Touch:null,PointerEvent:null};function Xp(){}function HUe(e){const t=e;Xr.document=t.document,Xr.DocumentFragment=t.DocumentFragment||Xp,Xr.SVGElement=t.SVGElement||Xp,Xr.SVGSVGElement=t.SVGSVGElement||Xp,Xr.SVGElementInstance=t.SVGElementInstance||Xp,Xr.Element=t.Element||Xp,Xr.HTMLElement=t.HTMLElement||Xr.Element,Xr.Event=t.Event,Xr.Touch=t.Touch||Xp,Xr.PointerEvent=t.PointerEvent||t.MSPointerEvent}var cz=e=>!!(e&&e.Window)&&e instanceof e.Window;let Az,$A;function dz(e){Az=e;const t=e.document.createTextNode("");t.ownerDocument!==e.document&&typeof e.wrap=="function"&&e.wrap(t)===t&&(e=e.wrap(e)),$A=e}typeof window<"u"&&window&&dz(window);function Hf(e){return cz(e)?e:(e.ownerDocument||e).defaultView||$A.window}const YUe=e=>e===$A||cz(e),RUe=e=>g2(e)&&e.nodeType===11,g2=e=>!!e&&typeof e=="object",fz=e=>typeof e=="function";var mt={window:YUe,docFrag:RUe,object:g2,func:fz,number:e=>typeof e=="number",bool:e=>typeof e=="boolean",string:e=>typeof e=="string",element:e=>{if(!e||typeof e!="object")return!1;const t=Hf(e)||$A;return/object|function/.test(typeof Element)?e instanceof Element||e instanceof t.Element:e.nodeType===1&&typeof e.nodeName=="string"},plainObject:e=>g2(e)&&!!e.constructor&&/function Object\b/.test(e.constructor.toString()),array:e=>g2(e)&&typeof e.length<"u"&&fz(e.splice)};const vi={init:QUe,supportsTouch:null,supportsPointerEvent:null,isIOS7:null,isIOS:null,isIe9:null,isOperaMobile:null,prefixedMatchesSelector:null,pEventTypes:null,wheelEvent:null};function QUe(e){const t=Xr.Element,n=e.navigator||{};vi.supportsTouch="ontouchstart"in e||mt.func(e.DocumentTouch)&&Xr.document instanceof e.DocumentTouch,vi.supportsPointerEvent=n.pointerEnabled!==!1&&!!Xr.PointerEvent,vi.isIOS=/iP(hone|od|ad)/.test(n.platform),vi.isIOS7=/iP(hone|od|ad)/.test(n.platform)&&/OS 7[^\d]/.test(n.appVersion),vi.isIe9=/MSIE 9/.test(n.userAgent),vi.isOperaMobile=n.appName==="Opera"&&vi.supportsTouch&&/Presto/.test(n.userAgent),vi.prefixedMatchesSelector="matches"in t.prototype?"matches":"webkitMatchesSelector"in t.prototype?"webkitMatchesSelector":"mozMatchesSelector"in t.prototype?"mozMatchesSelector":"oMatchesSelector"in t.prototype?"oMatchesSelector":"msMatchesSelector",vi.pEventTypes=vi.supportsPointerEvent?Xr.PointerEvent===e.MSPointerEvent?{up:"MSPointerUp",down:"MSPointerDown",over:"mouseover",out:"mouseout",move:"MSPointerMove",cancel:"MSPointerCancel"}:{up:"pointerup",down:"pointerdown",over:"pointerover",out:"pointerout",move:"pointermove",cancel:"pointercancel"}:null,vi.wheelEvent=Xr.document&&"onmousewheel"in Xr.document?"mousewheel":"wheel"}function Yf(e,t){if(e.contains)return e.contains(t);for(;t;){if(t===e)return!0;t=t.parentNode}return!1}function hz(e,t){for(;mt.element(e);){if(Rf(e,t))return e;e=ed(e)}return null}function ed(e){let t=e.parentNode;if(mt.docFrag(t)){for(;(t=t.host)&&mt.docFrag(t););return t}return t}function Rf(e,t){return $A!==Az&&(t=t.replace(/\/deep\//g," ")),e[vi.prefixedMatchesSelector](t)}function OM(e,t,n){for(;mt.element(e);){if(Rf(e,t))return!0;if(e=ed(e),e===n)return Rf(e,t)}return!1}function pz(e){return e.correspondingUseElement||e}function jUe(e){return e=e||$A,{x:e.scrollX||e.document.documentElement.scrollLeft,y:e.scrollY||e.document.documentElement.scrollTop}}function DM(e){const t=e instanceof Xr.SVGElement?e.getBoundingClientRect():e.getClientRects()[0];return t&&{left:t.left,right:t.right,top:t.top,bottom:t.bottom,width:t.width||t.right-t.left,height:t.height||t.bottom-t.top}}function UM(e){const t=DM(e);if(!vi.isIOS7&&t){const n=jUe(Hf(e));t.left+=n.x,t.right+=n.x,t.top+=n.y,t.bottom+=n.y}return t}function mz(e){return mt.string(e)?(Xr.document.querySelector(e),!0):!1}function fn(e,t){for(const r in t)e[r]=t[r];return e}function nv(e,t){let n=!1;return function(){return n||($A.console.warn(t),n=!0),e.apply(this,arguments)}}function gz(e,t){return e.name=t.name,e.axis=t.axis,e.edges=t.edges,e}function VUe(e){const{Interactable:t}=e;t.prototype.getAction=function(r,i,a,o){const s=zUe(this,i,a,o,e);return this.options.actionChecker?this.options.actionChecker(r,i,s,this,o,a):s},t.prototype.ignoreFrom=nv(function(n){return this._backCompatOption("ignoreFrom",n)},"Interactable.ignoreFrom() has been deprecated. Use Interactble.draggable({ignoreFrom: newValue})."),t.prototype.allowFrom=nv(function(n){return this._backCompatOption("allowFrom",n)},"Interactable.allowFrom() has been deprecated. Use Interactble.draggable({allowFrom: newValue})."),t.prototype.actionChecker=KUe,t.prototype.styleCursor=qUe}function zUe(e,t,n,r,i){const a=e.getRect(r),o=t.buttons||{0:1,1:4,3:8,4:16}[t.button],s={action:null,interactable:e,interaction:n,element:r,rect:a,buttons:o};return i.fire("auto-start:check",s),s.action}function qUe(e){return mt.bool(e)?(this.options.styleCursor=e,this):e===null?(delete this.options.styleCursor,this):this.options.styleCursor}function KUe(e){return mt.func(e)?(this.options.actionChecker=e,this):e===null?(delete this.options.actionChecker,this):this.options.actionChecker}var GUe={id:"auto-start/interactableMethods",install:VUe};function WUe(e){const{interactStatic:t,defaults:n}=e;e.usePlugin(GUe),n.base.actionChecker=null,n.base.styleCursor=!0,fn(n.perAction,{manualStart:!1,max:1/0,maxPerElement:1,allowFrom:null,ignoreFrom:null,mouseButtons:1}),t.maxInteractions=r=>_z(r,e),e.autoStart={maxInteractions:1/0,withinInteractionLimit:v2,cursorElement:null}}function XUe(e,t){let{interaction:n,pointer:r,event:i,eventTarget:a}=e;if(n.interacting())return;const o=yz(n,r,i,a,t);bz(n,o,t)}function JUe(e,t){let{interaction:n,pointer:r,event:i,eventTarget:a}=e;if(n.pointerType!=="mouse"||n.pointerIsDown||n.interacting())return;const o=yz(n,r,i,a,t);bz(n,o,t)}function ZUe(e,t){const{interaction:n}=e;if(!n.pointerIsDown||n.interacting()||!n.pointerWasMoved||!n.prepared.name)return;t.fire("autoStart:before-start",e);const{interactable:r}=n,i=n.prepared.name;i&&r&&(r.options[i].manualStart||!v2(r,n.element,n.prepared,t)?n.stop():(n.start(n.prepared,r,n.element),wz(n,t)))}function $Ue(e,t){let{interaction:n}=e;const{interactable:r}=n;r&&r.options.styleCursor&&PM(n.element,"",t)}function vz(e,t,n,r,i){return t.testIgnoreAllow(t.options[e.name],n,r)&&t.options[e.name].enabled&&v2(t,n,e,i)?e:null}function ePe(e,t,n,r,i,a,o){for(let s=0,u=r.length;s<u;s++){const c=r[s],A=i[s],d=c.getAction(t,n,e,A);if(!d)continue;const f=vz(d,c,A,a,o);if(f)return{action:f,interactable:c,element:A}}return{action:null,interactable:null,element:null}}function yz(e,t,n,r,i){let a=[],o=[],s=r;function u(c){a.push(c),o.push(s)}for(;mt.element(s);){a=[],o=[],i.interactables.forEachMatch(s,u);const c=ePe(e,t,n,a,o,r,i);if(c.action&&!c.interactable.options[c.action.name].manualStart)return c;s=ed(s)}return{action:null,interactable:null,element:null}}function bz(e,t,n){let{action:r,interactable:i,element:a}=t;r=r||{name:null},e.interactable=i,e.element=a,gz(e.prepared,r),e.rect=i&&r.name?i.getRect(a):null,wz(e,n),n.fire("autoStart:prepared",{interaction:e})}function v2(e,t,n,r){const i=e.options,a=i[n.name].max,o=i[n.name].maxPerElement,s=r.autoStart.maxInteractions;let u=0,c=0,A=0;if(!(a&&o&&s))return!1;for(const d of r.interactions.list){const f=d.prepared.name;if(d.interacting()){if(u++,u>=s)return!1;if(d.interactable===e&&(c+=f===n.name?1:0,c>=a||d.element===t&&(A++,f===n.name&&A>=o)))return!1}}return s>0}function _z(e,t){return mt.number(e)?(t.autoStart.maxInteractions=e,this):t.autoStart.maxInteractions}function PM(e,t,n){const{cursorElement:r}=n.autoStart;r&&r!==e&&(r.style.cursor=""),e.ownerDocument.documentElement.style.cursor=t,e.style.cursor=t,n.autoStart.cursorElement=t?e:null}function wz(e,t){const{interactable:n,element:r,prepared:i}=e;if(!(e.pointerType==="mouse"&&n&&n.options.styleCursor)){t.autoStart.cursorElement&&PM(t.autoStart.cursorElement,"",t);return}let a="";if(i.name){const o=n.options[i.name].cursorChecker;mt.func(o)?a=o(i,n,r,e._interacting):a=t.actions.map[i.name].getCursor(i)}PM(e.element,a||"",t)}const HM={id:"auto-start/base",before:["actions"],install:WUe,listeners:{"interactions:down":XUe,"interactions:move":(e,t)=>{JUe(e,t),ZUe(e,t)},"interactions:stop":$Ue},maxInteractions:_z,withinInteractionLimit:v2,validateAction:vz};function tPe(e,t){let{interaction:n,eventTarget:r,dx:i,dy:a}=e;if(n.prepared.name!=="drag")return;const o=Math.abs(i),s=Math.abs(a),u=n.interactable.options.drag,c=u.startAxis,A=o>s?"x":o<s?"y":"xy";if(n.prepared.axis=u.lockAxis==="start"?A[0]:u.lockAxis,A!=="xy"&&c!=="xy"&&c!==A){n.prepared.name=null;let d=r;const f=function(h){if(h===n.interactable)return;const p=n.interactable.options.drag;if(!p.manualStart&&h.testIgnoreAllow(p,d,r)){const m=h.getAction(n.downPointer,n.downEvent,n,d);if(m&&m.name==="drag"&&nPe(A,h)&&HM.validateAction(m,h,d,r,t))return h}};for(;mt.element(d);){const h=t.interactables.forEachMatch(d,f);if(h){n.prepared.name="drag",n.interactable=h,n.element=d;break}d=ed(d)}}}function nPe(e,t){if(!t)return!1;const n=t.options.drag.startAxis;return e==="xy"||n==="xy"||n===e}var rPe={id:"auto-start/dragAxis",listeners:{"autoStart:before-start":tPe}};function iPe(e){const{defaults:t}=e;e.usePlugin(HM),t.perAction.hold=0,t.perAction.delay=0}function YM(e){const t=e.prepared&&e.prepared.name;if(!t)return null;const n=e.interactable.options;return n[t].hold||n[t].delay}const aPe={id:"auto-start/hold",install:iPe,listeners:{"interactions:new":e=>{let{interaction:t}=e;t.autoStartHoldTimer=null},"autoStart:prepared":e=>{let{interaction:t}=e;const n=YM(t);n>0&&(t.autoStartHoldTimer=setTimeout(()=>{t.start(t.prepared,t.interactable,t.element)},n))},"interactions:move":e=>{let{interaction:t,duplicate:n}=e;t.autoStartHoldTimer&&t.pointerWasMoved&&!n&&(clearTimeout(t.autoStartHoldTimer),t.autoStartHoldTimer=null)},"autoStart:before-start":e=>{let{interaction:t}=e;YM(t)>0&&(t.prepared.name=null)}},getHoldDuration:YM};var oPe={id:"auto-start",install(e){e.usePlugin(HM),e.usePlugin(aPe),e.usePlugin(rPe)}};const xz=(e,t)=>{for(const n of t)e.push(n);return e},Bz=e=>xz([],e),y2=(e,t)=>{for(let n=0;n<e.length;n++)if(t(e[n],n,e))return n;return-1},b2=(e,t)=>e[y2(e,t)];function Jp(e){const t={};for(const n in e){const r=e[n];mt.plainObject(r)?t[n]=Jp(r):mt.array(r)?t[n]=Bz(r):t[n]=r}return t}let Cz=0,Cc,Qf;function sPe(e){if(Cc=e.requestAnimationFrame,Qf=e.cancelAnimationFrame,!Cc){const t=["ms","moz","webkit","o"];for(const n of t)Cc=e[`${n}RequestAnimationFrame`],Qf=e[`${n}CancelAnimationFrame`]||e[`${n}CancelRequestAnimationFrame`]}Cc=Cc&&Cc.bind(e),Qf=Qf&&Qf.bind(e),Cc||(Cc=t=>{const n=Date.now(),r=Math.max(0,16-(n-Cz)),i=e.setTimeout(()=>{t(n+r)},r);return Cz=n+r,i},Qf=t=>clearTimeout(t))}var Zp={request:e=>Cc(e),cancel:e=>Qf(e),init:sPe};function jf(e,t){let n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:i=>!0,r=arguments.length>3?arguments[3]:void 0;if(r=r||{},mt.string(e)&&e.search(" ")!==-1&&(e=Sz(e)),mt.array(e))return e.forEach(i=>jf(i,t,n,r)),r;if(mt.object(e)&&(t=e,e=""),mt.func(t)&&n(e))r[e]=r[e]||[],r[e].push(t);else if(mt.array(t))for(const i of t)jf(e,i,n,r);else if(mt.object(t))for(const i in t){const a=Sz(i).map(o=>`${e}${o}`);jf(a,t[i],n,r)}return r}function Sz(e){return e.trim().split(/ +/)}function Mz(e,t){for(const n of t){if(e.immediatePropagationStopped)break;n(e)}}class kz{constructor(t){this.options=void 0,this.types={},this.propagationStopped=!1,this.immediatePropagationStopped=!1,this.global=void 0,this.options=fn({},t||{})}fire(t){let n;const r=this.global;(n=this.types[t.type])&&Mz(t,n),!t.propagationStopped&&r&&(n=r[t.type])&&Mz(t,n)}on(t,n){const r=jf(t,n);for(t in r)this.types[t]=xz(this.types[t]||[],r[t])}off(t,n){const r=jf(t,n);for(t in r){const i=this.types[t];if(!(!i||!i.length))for(const a of r[t]){const o=i.indexOf(a);o!==-1&&i.splice(o,1)}}}getRect(t){return null}}const lPe=["webkit","moz"];function Ez(e,t){e.__set||(e.__set={});for(const n in t)lPe.some(r=>n.indexOf(r)===0)||typeof e[n]!="function"&&n!=="__set"&&Object.defineProperty(e,n,{get(){return n in e.__set?e.__set[n]:e.__set[n]=t[n]},set(r){e.__set[n]=r},configurable:!0});return e}var _2=(e,t)=>Math.sqrt(e*e+t*t);function RM(e,t){e.page=e.page||{},e.page.x=t.page.x,e.page.y=t.page.y,e.client=e.client||{},e.client.x=t.client.x,e.client.y=t.client.y,e.timeStamp=t.timeStamp}function uPe(e,t,n){e.page.x=n.page.x-t.page.x,e.page.y=n.page.y-t.page.y,e.client.x=n.client.x-t.client.x,e.client.y=n.client.y-t.client.y,e.timeStamp=n.timeStamp-t.timeStamp}function cPe(e,t){const n=Math.max(t.timeStamp/1e3,.001);e.page.x=t.page.x/n,e.page.y=t.page.y/n,e.client.x=t.client.x/n,e.client.y=t.client.y/n,e.timeStamp=n}function APe(e){e.page.x=0,e.page.y=0,e.client.x=0,e.client.y=0}function Lz(e){return e instanceof Xr.Event||e instanceof Xr.Touch}function w2(e,t,n){return n=n||{},e=e||"page",n.x=t[e+"X"],n.y=t[e+"Y"],n}function dPe(e,t){return t=t||{x:0,y:0},vi.isOperaMobile&&Lz(e)?(w2("screen",e,t),t.x+=window.scrollX,t.y+=window.scrollY):w2("page",e,t),t}function fPe(e,t){return t=t||{},vi.isOperaMobile&&Lz(e)?w2("screen",e,t):w2("client",e,t),t}function x2(e){return mt.number(e.pointerId)?e.pointerId:e.identifier}function hPe(e,t,n){const r=t.length>1?Tz(t):t[0];dPe(r,e.page),fPe(r,e.client),e.timeStamp=n}function QM(e){const t=[];return mt.array(e)?(t[0]=e[0],t[1]=e[1]):e.type==="touchend"?e.touches.length===1?(t[0]=e.touches[0],t[1]=e.changedTouches[0]):e.touches.length===0&&(t[0]=e.changedTouches[0],t[1]=e.changedTouches[1]):(t[0]=e.touches[0],t[1]=e.touches[1]),t}function Tz(e){const t={pageX:0,pageY:0,clientX:0,clientY:0,screenX:0,screenY:0};for(const n of e)for(const r in t)t[r]+=n[r];for(const n in t)t[n]/=e.length;return t}function pPe(e){if(!e.length)return null;const t=QM(e),n=Math.min(t[0].pageX,t[1].pageX),r=Math.min(t[0].pageY,t[1].pageY),i=Math.max(t[0].pageX,t[1].pageX),a=Math.max(t[0].pageY,t[1].pageY);return{x:n,y:r,left:n,top:r,right:i,bottom:a,width:i-n,height:a-r}}function mPe(e,t){const n=t+"X",r=t+"Y",i=QM(e),a=i[0][n]-i[1][n],o=i[0][r]-i[1][r];return _2(a,o)}function gPe(e,t){const n=t+"X",r=t+"Y",i=QM(e),a=i[1][n]-i[0][n],o=i[1][r]-i[0][r];return 180*Math.atan2(o,a)/Math.PI}function vPe(e){return mt.string(e.pointerType)?e.pointerType:mt.number(e.pointerType)?[void 0,void 0,"touch","pen","mouse"][e.pointerType]:/touch/.test(e.type||"")||e instanceof Xr.Touch?"touch":"mouse"}function Nz(e){const t=mt.func(e.composedPath)?e.composedPath():e.path;return[pz(t?t[0]:e.target),pz(e.currentTarget)]}function rv(){return{page:{x:0,y:0},client:{x:0,y:0},timeStamp:0}}function yPe(e){var t;const n=[],r={},i=[],a={add:o,remove:s,addDelegate:u,removeDelegate:c,delegateListener:A,delegateUseCapture:d,delegatedEvents:r,documents:i,targets:n,supportsOptions:!1,supportsPassive:!1};(t=e.document)==null||t.createElement("div").addEventListener("test",null,{get capture(){return a.supportsOptions=!0},get passive(){return a.supportsPassive=!0}}),e.events=a;function o(f,h,p,m){if(!f.addEventListener)return;const v=iv(m);let y=b2(n,g=>g.eventTarget===f);y||(y={eventTarget:f,events:{}},n.push(y)),y.events[h]||(y.events[h]=[]),b2(y.events[h],g=>g.func===p&&B2(g.options,v))||(f.addEventListener(h,p,a.supportsOptions?v:v.capture),y.events[h].push({func:p,options:v}))}function s(f,h,p,m){if(!f.addEventListener||!f.removeEventListener)return;const v=y2(n,w=>w.eventTarget===f),y=n[v];if(!y||!y.events)return;if(h==="all"){for(h in y.events)y.events.hasOwnProperty(h)&&s(f,h,"all");return}let g=!1;const b=y.events[h];if(b)if(p==="all"){for(let w=b.length-1;w>=0;w--){const _=b[w];s(f,h,_.func,_.options)}return}else{const w=iv(m);for(let _=0;_<b.length;_++){const C=b[_];if(C.func===p&&B2(C.options,w)){f.removeEventListener(h,p,a.supportsOptions?w:w.capture),b.splice(_,1),b.length===0&&(delete y.events[h],g=!0);break}}}g&&!Object.keys(y.events).length&&n.splice(v,1)}function u(f,h,p,m,v){const y=iv(v);if(!r[p]){r[p]=[];for(const w of i)o(w,p,A),o(w,p,d,!0)}const g=r[p];let b=b2(g,w=>w.selector===f&&w.context===h);b||(b={selector:f,context:h,listeners:[]},g.push(b)),b.listeners.push({func:m,options:y})}function c(f,h,p,m,v){const y=iv(v),g=r[p];let b=!1,w;if(g)for(w=g.length-1;w>=0;w--){const _=g[w];if(_.selector===f&&_.context===h){const{listeners:C}=_;for(let B=C.length-1;B>=0;B--){const k=C[B];if(k.func===m&&B2(k.options,y)){C.splice(B,1),C.length||(g.splice(w,1),s(h,p,A),s(h,p,d,!0)),b=!0;break}}if(b)break}}}function A(f,h){const p=iv(h),m=new bPe(f),v=r[f.type],[y]=Nz(f);let g=y;for(;mt.element(g);){for(let b=0;b<v.length;b++){const w=v[b],{selector:_,context:C}=w;if(Rf(g,_)&&Yf(C,y)&&Yf(C,g)){const{listeners:B}=w;m.currentTarget=g;for(const k of B)B2(k.options,p)&&k.func(m)}}g=ed(g)}}function d(f){return A.call(this,f,!0)}return a}class bPe{constructor(t){this.currentTarget=void 0,this.originalEvent=void 0,this.type=void 0,this.originalEvent=t,Ez(this,t)}preventOriginalDefault(){this.originalEvent.preventDefault()}stopPropagation(){this.originalEvent.stopPropagation()}stopImmediatePropagation(){this.originalEvent.stopImmediatePropagation()}}function iv(e){return mt.object(e)?{capture:!!e.capture,passive:!!e.passive}:{capture:!!e,passive:!1}}function B2(e,t){return e===t?!0:typeof e=="boolean"?!!t.capture===e&&!t.passive:!!e.capture==!!t.capture&&!!e.passive==!!t.passive}var _Pe={id:"events",install:yPe};const wPe=function(t){return/^(always|never|auto)$/.test(t)?(this.options.preventDefault=t,this):mt.bool(t)?(this.options.preventDefault=t?"always":"never",this):this.options.preventDefault};function xPe(e,t,n){const r=e.options.preventDefault;if(r!=="never"){if(r==="always"){n.preventDefault();return}if(t.events.supportsPassive&&/^touch(start|move)$/.test(n.type)){const i=Hf(n.target).document,a=t.getDocOptions(i);if(!(a&&a.events)||a.events.passive!==!1)return}/^(mouse|pointer|touch)*(down|start)/i.test(n.type)||mt.element(n.target)&&Rf(n.target,"input,select,textarea,[contenteditable=true],[contenteditable=true] *")||n.preventDefault()}}function BPe(e){let{interaction:t,event:n}=e;t.interactable&&t.interactable.checkAndPreventDefault(n)}function CPe(e){const{Interactable:t}=e;t.prototype.preventDefault=wPe,t.prototype.checkAndPreventDefault=function(n){return xPe(this,e,n)},e.interactions.docEvents.push({type:"dragstart",listener(n){for(const r of e.interactions.list)if(r.element&&(r.element===n.target||Yf(r.element,n.target))){r.interactable.checkAndPreventDefault(n);return}}})}var SPe={id:"core/interactablePreventDefault",install:CPe,listeners:["down","move","up","cancel"].reduce((e,t)=>(e[`interactions:${t}`]=BPe,e),{})};function Fz(e,t,n){return e==="parent"?ed(n):e==="self"?t.getRect(n):hz(n,e)}function av(e,t,n,r){let i=e;return mt.string(i)?i=Fz(i,t,n):mt.func(i)&&(i=i(...r)),mt.element(i)&&(i=UM(i)),i}function C2(e){return e&&{x:"x"in e?e.x:e.left,y:"y"in e?e.y:e.top}}function MPe(e){return e&&!("left"in e&&"top"in e)&&(e=fn({},e),e.left=e.x||0,e.top=e.y||0,e.right=e.right||e.left+e.width,e.bottom=e.bottom||e.top+e.height),e}function Iz(e){return e&&!("x"in e&&"y"in e)&&(e=fn({},e),e.x=e.left||0,e.y=e.top||0,e.width=e.width||(e.right||0)-e.x,e.height=e.height||(e.bottom||0)-e.y),e}function jM(e,t,n){e.left&&(t.left+=n.x),e.right&&(t.right+=n.x),e.top&&(t.top+=n.y),e.bottom&&(t.bottom+=n.y),t.width=t.right-t.left,t.height=t.bottom-t.top}function VM(e,t,n){const r=n&&e.options[n],a=r&&r.origin||e.options.origin,o=av(a,e,t,[e&&t]);return C2(o)||{x:0,y:0}}class Oz{constructor(t){this.immediatePropagationStopped=!1,this.propagationStopped=!1,this._interaction=t}preventDefault(){}stopPropagation(){this.propagationStopped=!0}stopImmediatePropagation(){this.immediatePropagationStopped=this.propagationStopped=!0}}Object.defineProperty(Oz.prototype,"interaction",{get(){return this._interaction._proxy},set(){}});const Dz={base:{preventDefault:"auto",deltaSource:"page"},perAction:{enabled:!1,origin:{x:0,y:0}},actions:{}};class zM extends Oz{constructor(t,n,r,i,a,o,s){super(t),this.relatedTarget=null,this.screenX=void 0,this.screenY=void 0,this.button=void 0,this.buttons=void 0,this.ctrlKey=void 0,this.shiftKey=void 0,this.altKey=void 0,this.metaKey=void 0,this.page=void 0,this.client=void 0,this.delta=void 0,this.rect=void 0,this.x0=void 0,this.y0=void 0,this.t0=void 0,this.dt=void 0,this.duration=void 0,this.clientX0=void 0,this.clientY0=void 0,this.velocity=void 0,this.speed=void 0,this.swipe=void 0,this.axes=void 0,this.preEnd=void 0,a=a||t.element;const u=t.interactable,c=(u&&u.options||Dz).deltaSource,A=VM(u,a,r),d=i==="start",f=i==="end",h=d?this:t.prevEvent,p=d?t.coords.start:f?{page:h.page,client:h.client,timeStamp:t.coords.cur.timeStamp}:t.coords.cur;this.page=fn({},p.page),this.client=fn({},p.client),this.rect=fn({},t.rect),this.timeStamp=p.timeStamp,f||(this.page.x-=A.x,this.page.y-=A.y,this.client.x-=A.x,this.client.y-=A.y),this.ctrlKey=n.ctrlKey,this.altKey=n.altKey,this.shiftKey=n.shiftKey,this.metaKey=n.metaKey,this.button=n.button,this.buttons=n.buttons,this.target=a,this.currentTarget=a,this.preEnd=o,this.type=s||r+(i||""),this.interactable=u,this.t0=d?t.pointers[t.pointers.length-1].downTime:h.t0,this.x0=t.coords.start.page.x-A.x,this.y0=t.coords.start.page.y-A.y,this.clientX0=t.coords.start.client.x-A.x,this.clientY0=t.coords.start.client.y-A.y,d||f?this.delta={x:0,y:0}:this.delta={x:this[c].x-h[c].x,y:this[c].y-h[c].y},this.dt=t.coords.delta.timeStamp,this.duration=this.timeStamp-this.t0,this.velocity=fn({},t.coords.velocity[c]),this.speed=_2(this.velocity.x,this.velocity.y),this.swipe=f||i==="inertiastart"?this.getSwipe():null}getSwipe(){const t=this._interaction;if(t.prevEvent.speed<600||this.timeStamp-t.prevEvent.timeStamp>150)return null;let n=180*Math.atan2(t.prevEvent.velocityY,t.prevEvent.velocityX)/Math.PI;const r=22.5;n<0&&(n+=360);const i=135-r<=n&&n<225+r,a=225-r<=n&&n<315+r,o=!i&&(315-r<=n||n<45+r),s=!a&&45-r<=n&&n<135+r;return{up:a,down:s,left:i,right:o,angle:n,speed:t.prevEvent.speed,velocity:{x:t.prevEvent.velocityX,y:t.prevEvent.velocityY}}}preventDefault(){}stopImmediatePropagation(){this.immediatePropagationStopped=this.propagationStopped=!0}stopPropagation(){this.propagationStopped=!0}}Object.defineProperties(zM.prototype,{pageX:{get(){return this.page.x},set(e){this.page.x=e}},pageY:{get(){return this.page.y},set(e){this.page.y=e}},clientX:{get(){return this.client.x},set(e){this.client.x=e}},clientY:{get(){return this.client.y},set(e){this.client.y=e}},dx:{get(){return this.delta.x},set(e){this.delta.x=e}},dy:{get(){return this.delta.y},set(e){this.delta.y=e}},velocityX:{get(){return this.velocity.x},set(e){this.velocity.x=e}},velocityY:{get(){return this.velocity.y},set(e){this.velocity.y=e}}});class kPe{constructor(t,n,r,i,a){this.id=void 0,this.pointer=void 0,this.event=void 0,this.downTime=void 0,this.downTarget=void 0,this.id=t,this.pointer=n,this.event=r,this.downTime=i,this.downTarget=a}}let EPe=function(e){return e.interactable="",e.element="",e.prepared="",e.pointerIsDown="",e.pointerWasMoved="",e._proxy="",e}({}),LPe=function(e){return e.start="",e.move="",e.end="",e.stop="",e.interacting="",e}({}),TPe=0;class NPe{get pointerMoveTolerance(){return 1}constructor(t){this.interactable=null,this.element=null,this.rect=null,this._rects=void 0,this.edges=null,this._scopeFire=void 0,this.prepared={name:null,axis:null,edges:null},this.pointerType=void 0,this.pointers=[],this.downEvent=null,this.downPointer={},this._latestPointer={pointer:null,event:null,eventTarget:null},this.prevEvent=null,this.pointerIsDown=!1,this.pointerWasMoved=!1,this._interacting=!1,this._ending=!1,this._stopped=!0,this._proxy=void 0,this.simulation=null,this.doMove=nv(function(a){this.move(a)},"The interaction.doMove() method has been renamed to interaction.move()"),this.coords={start:rv(),prev:rv(),cur:rv(),delta:rv(),velocity:rv()},this._id=TPe++;let{pointerType:n,scopeFire:r}=t;this._scopeFire=r,this.pointerType=n;const i=this;this._proxy={};for(const a in EPe)Object.defineProperty(this._proxy,a,{get(){return i[a]}});for(const a in LPe)Object.defineProperty(this._proxy,a,{value:function(){return i[a](...arguments)}});this._scopeFire("interactions:new",{interaction:this})}pointerDown(t,n,r){const i=this.updatePointer(t,n,r,!0),a=this.pointers[i];this._scopeFire("interactions:down",{pointer:t,event:n,eventTarget:r,pointerIndex:i,pointerInfo:a,type:"down",interaction:this})}start(t,n,r){return this.interacting()||!this.pointerIsDown||this.pointers.length<(t.name==="gesture"?2:1)||!n.options[t.name].enabled?!1:(gz(this.prepared,t),this.interactable=n,this.element=r,this.rect=n.getRect(r),this.edges=this.prepared.edges?fn({},this.prepared.edges):{left:!0,right:!0,top:!0,bottom:!0},this._stopped=!1,this._interacting=this._doPhase({interaction:this,event:this.downEvent,phase:"start"})&&!this._stopped,this._interacting)}pointerMove(t,n,r){!this.simulation&&!(this.modification&&this.modification.endResult)&&this.updatePointer(t,n,r,!1);const i=this.coords.cur.page.x===this.coords.prev.page.x&&this.coords.cur.page.y===this.coords.prev.page.y&&this.coords.cur.client.x===this.coords.prev.client.x&&this.coords.cur.client.y===this.coords.prev.client.y;let a,o;this.pointerIsDown&&!this.pointerWasMoved&&(a=this.coords.cur.client.x-this.coords.start.client.x,o=this.coords.cur.client.y-this.coords.start.client.y,this.pointerWasMoved=_2(a,o)>this.pointerMoveTolerance);const s=this.getPointerIndex(t),u={pointer:t,pointerIndex:s,pointerInfo:this.pointers[s],event:n,type:"move",eventTarget:r,dx:a,dy:o,duplicate:i,interaction:this};i||cPe(this.coords.velocity,this.coords.delta),this._scopeFire("interactions:move",u),!i&&!this.simulation&&(this.interacting()&&(u.type=null,this.move(u)),this.pointerWasMoved&&RM(this.coords.prev,this.coords.cur))}move(t){(!t||!t.event)&&APe(this.coords.delta),t=fn({pointer:this._latestPointer.pointer,event:this._latestPointer.event,eventTarget:this._latestPointer.eventTarget,interaction:this},t||{}),t.phase="move",this._doPhase(t)}pointerUp(t,n,r,i){let a=this.getPointerIndex(t);a===-1&&(a=this.updatePointer(t,n,r,!1));const o=/cancel$/i.test(n.type)?"cancel":"up";this._scopeFire(`interactions:${o}`,{pointer:t,pointerIndex:a,pointerInfo:this.pointers[a],event:n,eventTarget:r,type:o,curEventTarget:i,interaction:this}),this.simulation||this.end(n),this.removePointer(t,n)}documentBlur(t){this.end(t),this._scopeFire("interactions:blur",{event:t,type:"blur",interaction:this})}end(t){this._ending=!0,t=t||this._latestPointer.event;let n;this.interacting()&&(n=this._doPhase({event:t,interaction:this,phase:"end"})),this._ending=!1,n===!0&&this.stop()}currentAction(){return this._interacting?this.prepared.name:null}interacting(){return this._interacting}stop(){this._scopeFire("interactions:stop",{interaction:this}),this.interactable=this.element=null,this._interacting=!1,this._stopped=!0,this.prepared.name=this.prevEvent=null}getPointerIndex(t){const n=x2(t);return this.pointerType==="mouse"||this.pointerType==="pen"?this.pointers.length-1:y2(this.pointers,r=>r.id===n)}getPointerInfo(t){return this.pointers[this.getPointerIndex(t)]}updatePointer(t,n,r,i){const a=x2(t);let o=this.getPointerIndex(t),s=this.pointers[o];return i=i===!1?!1:i||/(down|start)$/i.test(n.type),s?s.pointer=t:(s=new kPe(a,t,n,null,null),o=this.pointers.length,this.pointers.push(s)),hPe(this.coords.cur,this.pointers.map(u=>u.pointer),this._now()),uPe(this.coords.delta,this.coords.prev,this.coords.cur),i&&(this.pointerIsDown=!0,s.downTime=this.coords.cur.timeStamp,s.downTarget=r,Ez(this.downPointer,t),this.interacting()||(RM(this.coords.start,this.coords.cur),RM(this.coords.prev,this.coords.cur),this.downEvent=n,this.pointerWasMoved=!1)),this._updateLatestPointer(t,n,r),this._scopeFire("interactions:update-pointer",{pointer:t,event:n,eventTarget:r,down:i,pointerInfo:s,pointerIndex:o,interaction:this}),o}removePointer(t,n){const r=this.getPointerIndex(t);if(r===-1)return;const i=this.pointers[r];this._scopeFire("interactions:remove-pointer",{pointer:t,event:n,eventTarget:null,pointerIndex:r,pointerInfo:i,interaction:this}),this.pointers.splice(r,1),this.pointerIsDown=!1}_updateLatestPointer(t,n,r){this._latestPointer.pointer=t,this._latestPointer.event=n,this._latestPointer.eventTarget=r}destroy(){this._latestPointer.pointer=null,this._latestPointer.event=null,this._latestPointer.eventTarget=null}_createPreparedEvent(t,n,r,i){return new zM(this,t,this.prepared.name,n,this.element,r,i)}_fireEvent(t){var n;(n=this.interactable)==null||n.fire(t),(!this.prevEvent||t.timeStamp>=this.prevEvent.timeStamp)&&(this.prevEvent=t)}_doPhase(t){const{event:n,phase:r,preEnd:i,type:a}=t,{rect:o}=this;if(o&&r==="move"&&(jM(this.edges,o,this.coords.delta[this.interactable.options.deltaSource]),o.width=o.right-o.left,o.height=o.bottom-o.top),this._scopeFire(`interactions:before-action-${r}`,t)===!1)return!1;const u=t.iEvent=this._createPreparedEvent(n,r,i,a);return this._scopeFire(`interactions:action-${r}`,t),r==="start"&&(this.prevEvent=u),this._fireEvent(u),this._scopeFire(`interactions:after-action-${r}`,t),!0}_now(){return Date.now()}}const qM={methodOrder:["simulationResume","mouseOrPen","hasPointer","idle"],search(e){for(const t of qM.methodOrder){const n=qM[t](e);if(n)return n}return null},simulationResume(e){let{pointerType:t,eventType:n,eventTarget:r,scope:i}=e;if(!/down|start/i.test(n))return null;for(const a of i.interactions.list){let o=r;if(a.simulation&&a.simulation.allowResume&&a.pointerType===t)for(;o;){if(o===a.element)return a;o=ed(o)}}return null},mouseOrPen(e){let{pointerId:t,pointerType:n,eventType:r,scope:i}=e;if(n!=="mouse"&&n!=="pen")return null;let a;for(const o of i.interactions.list)if(o.pointerType===n){if(o.simulation&&!Uz(o,t))continue;if(o.interacting())return o;a||(a=o)}if(a)return a;for(const o of i.interactions.list)if(o.pointerType===n&&!(/down/i.test(r)&&o.simulation))return o;return null},hasPointer(e){let{pointerId:t,scope:n}=e;for(const r of n.interactions.list)if(Uz(r,t))return r;return null},idle(e){let{pointerType:t,scope:n}=e;for(const r of n.interactions.list){if(r.pointers.length===1){const i=r.interactable;if(i&&!(i.options.gesture&&i.options.gesture.enabled))continue}else if(r.pointers.length>=2)continue;if(!r.interacting()&&t===r.pointerType)return r}return null}};function Uz(e,t){return e.pointers.some(n=>{let{id:r}=n;return r===t})}const Pz=["pointerDown","pointerMove","pointerUp","updatePointer","removePointer","windowBlur"];function FPe(e){const t={};for(const a of Pz)t[a]=Hz(a,e);const n=vi.pEventTypes;let r;Xr.PointerEvent?r=[{type:n.down,listener:i},{type:n.down,listener:t.pointerDown},{type:n.move,listener:t.pointerMove},{type:n.up,listener:t.pointerUp},{type:n.cancel,listener:t.pointerUp}]:r=[{type:"mousedown",listener:t.pointerDown},{type:"mousemove",listener:t.pointerMove},{type:"mouseup",listener:t.pointerUp},{type:"touchstart",listener:i},{type:"touchstart",listener:t.pointerDown},{type:"touchmove",listener:t.pointerMove},{type:"touchend",listener:t.pointerUp},{type:"touchcancel",listener:t.pointerUp}],r.push({type:"blur",listener(a){for(const o of e.interactions.list)o.documentBlur(a)}}),e.prevTouchTime=0,e.Interaction=class extends NPe{get pointerMoveTolerance(){return e.interactions.pointerMoveTolerance}set pointerMoveTolerance(a){e.interactions.pointerMoveTolerance=a}_now(){return e.now()}},e.interactions={list:[],new(a){a.scopeFire=(s,u)=>e.fire(s,u);const o=new e.Interaction(a);return e.interactions.list.push(o),o},listeners:t,docEvents:r,pointerMoveTolerance:1};function i(){for(const a of e.interactions.list)if(!(!a.pointerIsDown||a.pointerType!=="touch"||a._interacting))for(const o of a.pointers)e.documents.some(s=>{let{doc:u}=s;return Yf(u,o.downTarget)})||a.removePointer(o.pointer,o.event)}e.usePlugin(SPe)}function Hz(e,t){return function(n){const r=t.interactions.list,i=vPe(n),[a,o]=Nz(n),s=[];if(/^touch/.test(n.type)){t.prevTouchTime=t.now();for(const u of n.changedTouches){const c=u,A=x2(c),d={pointer:c,pointerId:A,pointerType:i,eventType:n.type,eventTarget:a,curEventTarget:o,scope:t},f=Yz(d);s.push([d.pointer,d.eventTarget,d.curEventTarget,f])}}else{let u=!1;if(!vi.supportsPointerEvent&&/mouse/.test(n.type)){for(let c=0;c<r.length&&!u;c++)u=r[c].pointerType!=="mouse"&&r[c].pointerIsDown;u=u||t.now()-t.prevTouchTime<500||n.timeStamp===0}if(!u){const c={pointer:n,pointerId:x2(n),pointerType:i,eventType:n.type,curEventTarget:o,eventTarget:a,scope:t},A=Yz(c);s.push([c.pointer,c.eventTarget,c.curEventTarget,A])}}for(const[u,c,A,d]of s)d[e](u,n,c,A)}}function Yz(e){const{pointerType:t,scope:n}=e,i={interaction:qM.search(e),searchDetails:e};return n.fire("interactions:find",i),i.interaction||n.interactions.new({pointerType:t})}function KM(e,t){let{doc:n,scope:r,options:i}=e;const{interactions:{docEvents:a},events:o}=r,s=o[t];r.browser.isIOS&&!i.events&&(i.events={passive:!1});for(const c in o.delegatedEvents)s(n,c,o.delegateListener),s(n,c,o.delegateUseCapture,!0);const u=i&&i.events;for(const{type:c,listener:A}of a)s(n,c,A,u)}const IPe={id:"core/interactions",install:FPe,listeners:{"scope:add-document":e=>KM(e,"add"),"scope:remove-document":e=>KM(e,"remove"),"interactable:unset":(e,t)=>{let{interactable:n}=e;for(let r=t.interactions.list.length-1;r>=0;r--){const i=t.interactions.list[r];i.interactable===n&&(i.stop(),t.fire("interactions:destroy",{interaction:i}),i.destroy(),t.interactions.list.length>2&&t.interactions.list.splice(r,1))}}},onDocSignal:KM,doOnInteractions:Hz,methodNames:Pz};function ov(e,t){if(t.phaselessTypes[e])return!0;for(const n in t.map)if(e.indexOf(n)===0&&e.substr(n.length)in t.phases)return!0;return!1}var td=function(e){return e[e.On=0]="On",e[e.Off=1]="Off",e}(td||{});class OPe{get _defaults(){return{base:{},perAction:{},actions:{}}}constructor(t,n,r,i){this.target=void 0,this.options=void 0,this._actions=void 0,this.events=new kz,this._context=void 0,this._win=void 0,this._doc=void 0,this._scopeEvents=void 0,this._actions=n.actions,this.target=t,this._context=n.context||r,this._win=Hf(mz(t)?this._context:t),this._doc=this._win.document,this._scopeEvents=i,this.set(n)}setOnEvents(t,n){return mt.func(n.onstart)&&this.on(`${t}start`,n.onstart),mt.func(n.onmove)&&this.on(`${t}move`,n.onmove),mt.func(n.onend)&&this.on(`${t}end`,n.onend),mt.func(n.oninertiastart)&&this.on(`${t}inertiastart`,n.oninertiastart),this}updatePerActionListeners(t,n,r){var i;const a=(i=this._actions.map[t])==null?void 0:i.filterEventType,o=s=>(a==null||a(s))&&ov(s,this._actions);(mt.array(n)||mt.object(n))&&this._onOff(td.Off,t,n,void 0,o),(mt.array(r)||mt.object(r))&&this._onOff(td.On,t,r,void 0,o)}setPerAction(t,n){const r=this._defaults;for(const i in n){const a=i,o=this.options[t],s=n[a];a==="listeners"&&this.updatePerActionListeners(t,o.listeners,s),mt.array(s)?o[a]=Bz(s):mt.plainObject(s)?(o[a]=fn(o[a]||{},Jp(s)),mt.object(r.perAction[a])&&"enabled"in r.perAction[a]&&(o[a].enabled=s.enabled!==!1)):mt.bool(s)&&mt.object(r.perAction[a])?o[a].enabled=s:o[a]=s}}getRect(t){return t=t||(mt.element(this.target)?this.target:null),mt.string(this.target)&&(t=t||this._context.querySelector(this.target)),UM(t)}rectChecker(t){return mt.func(t)?(this.getRect=n=>{const r=fn({},t.apply(this,n));return"width"in r||(r.width=r.right-r.left,r.height=r.bottom-r.top),r},this):t===null?(delete this.getRect,this):this.getRect}_backCompatOption(t,n){if(mz(n)||mt.object(n)){this.options[t]=n;for(const r in this._actions.map)this.options[r][t]=n;return this}return this.options[t]}origin(t){return this._backCompatOption("origin",t)}deltaSource(t){return t==="page"||t==="client"?(this.options.deltaSource=t,this):this.options.deltaSource}getAllElements(){const{target:t}=this;return mt.string(t)?Array.from(this._context.querySelectorAll(t)):mt.func(t)&&t.getAllElements?t.getAllElements():mt.element(t)?[t]:[]}context(){return this._context}inContext(t){return this._context===t.ownerDocument||Yf(this._context,t)}testIgnoreAllow(t,n,r){return!this.testIgnore(t.ignoreFrom,n,r)&&this.testAllow(t.allowFrom,n,r)}testAllow(t,n,r){return t?mt.element(r)?mt.string(t)?OM(r,t,n):mt.element(t)?Yf(t,r):!1:!1:!0}testIgnore(t,n,r){return!t||!mt.element(r)?!1:mt.string(t)?OM(r,t,n):mt.element(t)?Yf(t,r):!1}fire(t){return this.events.fire(t),this}_onOff(t,n,r,i,a){mt.object(n)&&!mt.array(n)&&(i=r,r=null);const o=jf(n,r,a);for(let s in o){s==="wheel"&&(s=vi.wheelEvent);for(const u of o[s])ov(s,this._actions)?this.events[t===td.On?"on":"off"](s,u):mt.string(this.target)?this._scopeEvents[t===td.On?"addDelegate":"removeDelegate"](this.target,this._context,s,u,i):this._scopeEvents[t===td.On?"add":"remove"](this.target,s,u,i)}return this}on(t,n,r){return this._onOff(td.On,t,n,r)}off(t,n,r){return this._onOff(td.Off,t,n,r)}set(t){const n=this._defaults;mt.object(t)||(t={}),this.options=Jp(n.base);for(const r in this._actions.methodDict){const i=r,a=this._actions.methodDict[i];this.options[i]={},this.setPerAction(i,fn(fn({},n.perAction),n.actions[i])),this[a](t[i])}for(const r in t){if(r==="getRect"){this.rectChecker(t.getRect);continue}mt.func(this[r])&&this[r](t[r])}return this}unset(){if(mt.string(this.target))for(const t in this._scopeEvents.delegatedEvents){const n=this._scopeEvents.delegatedEvents[t];for(let r=n.length-1;r>=0;r--){const{selector:i,context:a,listeners:o}=n[r];i===this.target&&a===this._context&&n.splice(r,1);for(let s=o.length-1;s>=0;s--)this._scopeEvents.removeDelegate(this.target,this._context,t,o[s][0],o[s][1])}}else this._scopeEvents.remove(this.target,"all")}}class DPe{constructor(t){this.list=[],this.selectorMap={},this.scope=void 0,this.scope=t,t.addListeners({"interactable:unset":n=>{let{interactable:r}=n;const{target:i}=r,a=mt.string(i)?this.selectorMap[i]:i[this.scope.id],o=y2(a,s=>s===r);a.splice(o,1)}})}new(t,n){n=fn(n||{},{actions:this.scope.actions});const r=new this.scope.Interactable(t,n,this.scope.document,this.scope.events);return this.scope.addDocument(r._doc),this.list.push(r),mt.string(t)?(this.selectorMap[t]||(this.selectorMap[t]=[]),this.selectorMap[t].push(r)):(r.target[this.scope.id]||Object.defineProperty(t,this.scope.id,{value:[],configurable:!0}),t[this.scope.id].push(r)),this.scope.fire("interactable:new",{target:t,options:n,interactable:r,win:this.scope._win}),r}getExisting(t,n){const r=n&&n.context||this.scope.document,i=mt.string(t),a=i?this.selectorMap[t]:t[this.scope.id];if(a)return b2(a,o=>o._context===r&&(i||o.inContext(t)))}forEachMatch(t,n){for(const r of this.list){let i;if((mt.string(r.target)?mt.element(t)&&Rf(t,r.target):t===r.target)&&r.inContext(t)&&(i=n(r)),i!==void 0)return i}}}function UPe(e){const t=(n,r)=>{let i=e.interactables.getExisting(n,r);return i||(i=e.interactables.new(n,r),i.events.global=t.globalEvents),i};return t.getPointerAverage=Tz,t.getTouchBBox=pPe,t.getTouchDistance=mPe,t.getTouchAngle=gPe,t.getElementRect=UM,t.getElementClientRect=DM,t.matchesSelector=Rf,t.closest=hz,t.globalEvents={},t.version="1.10.27",t.scope=e,t.use=function(n,r){return this.scope.usePlugin(n,r),this},t.isSet=function(n,r){return!!this.scope.interactables.get(n,r&&r.context)},t.on=nv(function(r,i,a){if(mt.string(r)&&r.search(" ")!==-1&&(r=r.trim().split(/ +/)),mt.array(r)){for(const o of r)this.on(o,i,a);return this}if(mt.object(r)){for(const o in r)this.on(o,r[o],i);return this}return ov(r,this.scope.actions)?this.globalEvents[r]?this.globalEvents[r].push(i):this.globalEvents[r]=[i]:this.scope.events.add(this.scope.document,r,i,{options:a}),this},"The interact.on() method is being deprecated"),t.off=nv(function(r,i,a){if(mt.string(r)&&r.search(" ")!==-1&&(r=r.trim().split(/ +/)),mt.array(r)){for(const o of r)this.off(o,i,a);return this}if(mt.object(r)){for(const o in r)this.off(o,r[o],i);return this}if(ov(r,this.scope.actions)){let o;r in this.globalEvents&&(o=this.globalEvents[r].indexOf(i))!==-1&&this.globalEvents[r].splice(o,1)}else this.scope.events.remove(this.scope.document,r,i,a);return this},"The interact.off() method is being deprecated"),t.debug=function(){return this.scope},t.supportsTouch=function(){return vi.supportsTouch},t.supportsPointerEvent=function(){return vi.supportsPointerEvent},t.stop=function(){for(const n of this.scope.interactions.list)n.stop();return this},t.pointerMoveTolerance=function(n){return mt.number(n)?(this.scope.interactions.pointerMoveTolerance=n,this):this.scope.interactions.pointerMoveTolerance},t.addDocument=function(n,r){this.scope.addDocument(n,r)},t.removeDocument=function(n){this.scope.removeDocument(n)},t}class PPe{constructor(){this.id=`__interact_scope_${Math.floor(Math.random()*100)}`,this.isInitialized=!1,this.listenerMaps=[],this.browser=vi,this.defaults=Jp(Dz),this.Eventable=kz,this.actions={map:{},phases:{start:!0,move:!0,end:!0},methodDict:{},phaselessTypes:{}},this.interactStatic=UPe(this),this.InteractEvent=zM,this.Interactable=void 0,this.interactables=new DPe(this),this._win=void 0,this.document=void 0,this.window=void 0,this.documents=[],this._plugins={list:[],map:{}},this.onWindowUnload=n=>this.removeDocument(n.target);const t=this;this.Interactable=class extends OPe{get _defaults(){return t.defaults}set(n){return super.set(n),t.fire("interactable:set",{options:n,interactable:this}),this}unset(){super.unset();const n=t.interactables.list.indexOf(this);n<0||(t.interactables.list.splice(n,1),t.fire("interactable:unset",{interactable:this}))}}}addListeners(t,n){this.listenerMaps.push({id:n,map:t})}fire(t,n){for(const{map:{[t]:r}}of this.listenerMaps)if(r&&r(n,this,t)===!1)return!1}init(t){return this.isInitialized?this:HPe(this,t)}pluginIsInstalled(t){const{id:n}=t;return n?!!this._plugins.map[n]:this._plugins.list.indexOf(t)!==-1}usePlugin(t,n){if(!this.isInitialized)return this;if(this.pluginIsInstalled(t))return this;if(t.id&&(this._plugins.map[t.id]=t),this._plugins.list.push(t),t.install&&t.install(this,n),t.listeners&&t.before){let r=0;const i=this.listenerMaps.length,a=t.before.reduce((o,s)=>(o[s]=!0,o[Rz(s)]=!0,o),{});for(;r<i;r++){const o=this.listenerMaps[r].id;if(o&&(a[o]||a[Rz(o)]))break}this.listenerMaps.splice(r,0,{id:t.id,map:t.listeners})}else t.listeners&&this.listenerMaps.push({id:t.id,map:t.listeners});return this}addDocument(t,n){if(this.getDocIndex(t)!==-1)return!1;const r=Hf(t);n=n?fn({},n):{},this.documents.push({doc:t,options:n}),this.events.documents.push(t),t!==this.document&&this.events.add(r,"unload",this.onWindowUnload),this.fire("scope:add-document",{doc:t,window:r,scope:this,options:n})}removeDocument(t){const n=this.getDocIndex(t),r=Hf(t),i=this.documents[n].options;this.events.remove(r,"unload",this.onWindowUnload),this.documents.splice(n,1),this.events.documents.splice(n,1),this.fire("scope:remove-document",{doc:t,window:r,scope:this,options:i})}getDocIndex(t){for(let n=0;n<this.documents.length;n++)if(this.documents[n].doc===t)return n;return-1}getDocOptions(t){const n=this.getDocIndex(t);return n===-1?null:this.documents[n].options}now(){return(this.window.Date||Date).now()}}function HPe(e,t){return e.isInitialized=!0,mt.window(t)&&dz(t),Xr.init(t),vi.init(t),Zp.init(t),e.window=t,e.document=t.document,e.usePlugin(IPe),e.usePlugin(_Pe),e}function Rz(e){return e&&e.replace(/\/.*$/,"")}const Qz=new PPe,Sc=Qz.interactStatic,YPe=typeof globalThis<"u"?globalThis:window;Qz.init(YPe),Sc.use(oPe);function RPe(e){const{defaults:t,actions:n}=e;e.autoScroll=bn,bn.now=()=>e.now(),n.phaselessTypes.autoscroll=!0,t.perAction.autoScroll=bn.defaults}const bn={defaults:{enabled:!1,margin:60,container:null,speed:300},now:Date.now,interaction:null,i:0,x:0,y:0,isScrolling:!1,prevTime:0,margin:0,speed:0,start(e){bn.isScrolling=!0,Zp.cancel(bn.i),e.autoScroll=bn,bn.interaction=e,bn.prevTime=bn.now(),bn.i=Zp.request(bn.scroll)},stop(){bn.isScrolling=!1,bn.interaction&&(bn.interaction.autoScroll=null),Zp.cancel(bn.i)},scroll(){const{interaction:e}=bn,{interactable:t,element:n}=e,r=e.prepared.name,i=t.options[r].autoScroll,a=jz(i.container,t,n),o=bn.now(),s=(o-bn.prevTime)/1e3,u=i.speed*s;if(u>=1){const c={x:bn.x*u,y:bn.y*u};if(c.x||c.y){const A=Vz(a);mt.window(a)?a.scrollBy(c.x,c.y):a&&(a.scrollLeft+=c.x,a.scrollTop+=c.y);const d=Vz(a),f={x:d.x-A.x,y:d.y-A.y};(f.x||f.y)&&t.fire({type:"autoscroll",target:n,interactable:t,delta:f,interaction:e,container:a})}bn.prevTime=o}bn.isScrolling&&(Zp.cancel(bn.i),bn.i=Zp.request(bn.scroll))},check(e,t){var n;return(n=e.options[t].autoScroll)==null?void 0:n.enabled},onInteractionMove(e){let{interaction:t,pointer:n}=e;if(!(t.interacting()&&bn.check(t.interactable,t.prepared.name)))return;if(t.simulation){bn.x=bn.y=0;return}let r,i,a,o;const{interactable:s,element:u}=t,c=t.prepared.name,A=s.options[c].autoScroll,d=jz(A.container,s,u);if(mt.window(d))o=n.clientX<bn.margin,r=n.clientY<bn.margin,i=n.clientX>d.innerWidth-bn.margin,a=n.clientY>d.innerHeight-bn.margin;else{const f=DM(d);o=n.clientX<f.left+bn.margin,r=n.clientY<f.top+bn.margin,i=n.clientX>f.right-bn.margin,a=n.clientY>f.bottom-bn.margin}bn.x=i?1:o?-1:0,bn.y=a?1:r?-1:0,bn.isScrolling||(bn.margin=A.margin,bn.speed=A.speed,bn.start(t))}};function jz(e,t,n){return(mt.string(e)?Fz(e,t,n):e)||Hf(n)}function Vz(e){return mt.window(e)&&(e=window.document.body),{x:e.scrollLeft,y:e.scrollTop}}const QPe={id:"auto-scroll",install:RPe,listeners:{"interactions:new":e=>{let{interaction:t}=e;t.autoScroll=null},"interactions:destroy":e=>{let{interaction:t}=e;t.autoScroll=null,bn.stop(),bn.interaction&&(bn.interaction=null)},"interactions:stop":bn.stop,"interactions:action-move":e=>bn.onInteractionMove(e)}};Sc.use(QPe);function jPe(e){const{actions:t,Interactable:n,defaults:r}=e;n.prototype.draggable=S2.draggable,t.map.drag=S2,t.methodDict.drag="draggable",r.actions.drag=S2.defaults}function GM(e){let{interaction:t}=e;if(t.prepared.name!=="drag")return;const n=t.prepared.axis;n==="x"?(t.coords.cur.page.y=t.coords.start.page.y,t.coords.cur.client.y=t.coords.start.client.y,t.coords.velocity.client.y=0,t.coords.velocity.page.y=0):n==="y"&&(t.coords.cur.page.x=t.coords.start.page.x,t.coords.cur.client.x=t.coords.start.client.x,t.coords.velocity.client.x=0,t.coords.velocity.page.x=0)}function zz(e){let{iEvent:t,interaction:n}=e;if(n.prepared.name!=="drag")return;const r=n.prepared.axis;if(r==="x"||r==="y"){const i=r==="x"?"y":"x";t.page[i]=n.coords.start.page[i],t.client[i]=n.coords.start.client[i],t.delta[i]=0}}const S2={id:"actions/drag",install:jPe,listeners:{"interactions:before-action-move":GM,"interactions:action-resume":GM,"interactions:action-move":zz,"auto-start:check":e=>{const{interaction:t,interactable:n,buttons:r}=e,i=n.options.drag;if(!(!(i&&i.enabled)||t.pointerIsDown&&/mouse|pointer/.test(t.pointerType)&&(r&n.options.drag.mouseButtons)===0))return e.action={name:"drag",axis:i.lockAxis==="start"?i.startAxis:i.lockAxis},!1}},draggable:function(t){return mt.object(t)?(this.options.drag.enabled=t.enabled!==!1,this.setPerAction("drag",t),this.setOnEvents("drag",t),/^(xy|x|y|start)$/.test(t.lockAxis)&&(this.options.drag.lockAxis=t.lockAxis),/^(xy|x|y)$/.test(t.startAxis)&&(this.options.drag.startAxis=t.startAxis),this):mt.bool(t)?(this.options.drag.enabled=t,this):this.options.drag},beforeMove:GM,move:zz,defaults:{startAxis:"xy",lockAxis:"xy"},getCursor(){return"move"},filterEventType:e=>e.search("drag")===0};Sc.use(S2);function VPe(e){const{actions:t,browser:n,Interactable:r,defaults:i}=e;Mc.cursors=GPe(n),Mc.defaultMargin=n.supportsTouch||n.supportsPointerEvent?20:10,r.prototype.resizable=function(a){return qPe(this,a,e)},t.map.resize=Mc,t.methodDict.resize="resizable",i.actions.resize=Mc.defaults}function zPe(e){const{interaction:t,interactable:n,element:r,rect:i,buttons:a}=e;if(!i)return;const o=fn({},t.coords.cur.page),s=n.options.resize;if(!(!(s&&s.enabled)||t.pointerIsDown&&/mouse|pointer/.test(t.pointerType)&&(a&s.mouseButtons)===0)){if(mt.object(s.edges)){const u={left:!1,right:!1,top:!1,bottom:!1};for(const c in u)u[c]=KPe(c,s.edges[c],o,t._latestPointer.eventTarget,r,i,s.margin||Mc.defaultMargin);u.left=u.left&&!u.right,u.top=u.top&&!u.bottom,(u.left||u.right||u.top||u.bottom)&&(e.action={name:"resize",edges:u})}else{const u=s.axis!=="y"&&o.x>i.right-Mc.defaultMargin,c=s.axis!=="x"&&o.y>i.bottom-Mc.defaultMargin;(u||c)&&(e.action={name:"resize",axes:(u?"x":"")+(c?"y":"")})}return e.action?!1:void 0}}function qPe(e,t,n){return mt.object(t)?(e.options.resize.enabled=t.enabled!==!1,e.setPerAction("resize",t),e.setOnEvents("resize",t),mt.string(t.axis)&&/^x$|^y$|^xy$/.test(t.axis)?e.options.resize.axis=t.axis:t.axis===null&&(e.options.resize.axis=n.defaults.actions.resize.axis),mt.bool(t.preserveAspectRatio)?e.options.resize.preserveAspectRatio=t.preserveAspectRatio:mt.bool(t.square)&&(e.options.resize.square=t.square),e):mt.bool(t)?(e.options.resize.enabled=t,e):e.options.resize}function KPe(e,t,n,r,i,a,o){if(!t)return!1;if(t===!0){const s=mt.number(a.width)?a.width:a.right-a.left,u=mt.number(a.height)?a.height:a.bottom-a.top;if(o=Math.min(o,Math.abs((e==="left"||e==="right"?s:u)/2)),s<0&&(e==="left"?e="right":e==="right"&&(e="left")),u<0&&(e==="top"?e="bottom":e==="bottom"&&(e="top")),e==="left"){const c=s>=0?a.left:a.right;return n.x<c+o}if(e==="top"){const c=u>=0?a.top:a.bottom;return n.y<c+o}if(e==="right")return n.x>(s>=0?a.right:a.left)-o;if(e==="bottom")return n.y>(u>=0?a.bottom:a.top)-o}return mt.element(r)?mt.element(t)?t===r:OM(r,t,i):!1}function GPe(e){return e.isIe9?{x:"e-resize",y:"s-resize",xy:"se-resize",top:"n-resize",left:"w-resize",bottom:"s-resize",right:"e-resize",topleft:"se-resize",bottomright:"se-resize",topright:"ne-resize",bottomleft:"ne-resize"}:{x:"ew-resize",y:"ns-resize",xy:"nwse-resize",top:"ns-resize",left:"ew-resize",bottom:"ns-resize",right:"ew-resize",topleft:"nwse-resize",bottomright:"nwse-resize",topright:"nesw-resize",bottomleft:"nesw-resize"}}function WPe(e){let{iEvent:t,interaction:n}=e;if(n.prepared.name!=="resize"||!n.prepared.edges)return;const r=t,i=n.rect;n._rects={start:fn({},i),corrected:fn({},i),previous:fn({},i),delta:{left:0,right:0,width:0,top:0,bottom:0,height:0}},r.edges=n.prepared.edges,r.rect=n._rects.corrected,r.deltaRect=n._rects.delta}function XPe(e){let{iEvent:t,interaction:n}=e;if(n.prepared.name!=="resize"||!n.prepared.edges)return;const r=t,a=n.interactable.options.resize.invert,o=a==="reposition"||a==="negate",s=n.rect,{start:u,corrected:c,delta:A,previous:d}=n._rects;if(fn(d,c),o){if(fn(c,s),a==="reposition"){if(c.top>c.bottom){const f=c.top;c.top=c.bottom,c.bottom=f}if(c.left>c.right){const f=c.left;c.left=c.right,c.right=f}}}else c.top=Math.min(s.top,u.bottom),c.bottom=Math.max(s.bottom,u.top),c.left=Math.min(s.left,u.right),c.right=Math.max(s.right,u.left);c.width=c.right-c.left,c.height=c.bottom-c.top;for(const f in c)A[f]=c[f]-d[f];r.edges=n.prepared.edges,r.rect=c,r.deltaRect=A}function JPe(e){let{iEvent:t,interaction:n}=e;if(n.prepared.name!=="resize"||!n.prepared.edges)return;const r=t;r.edges=n.prepared.edges,r.rect=n._rects.corrected,r.deltaRect=n._rects.delta}function qz(e){let{iEvent:t,interaction:n}=e;if(n.prepared.name!=="resize"||!n.resizeAxes)return;const r=n.interactable.options,i=t;r.resize.square?(n.resizeAxes==="y"?i.delta.x=i.delta.y:i.delta.y=i.delta.x,i.axes="xy"):(i.axes=n.resizeAxes,n.resizeAxes==="x"?i.delta.y=0:n.resizeAxes==="y"&&(i.delta.x=0))}const Mc={id:"actions/resize",before:["actions/drag"],install:VPe,listeners:{"interactions:new":e=>{let{interaction:t}=e;t.resizeAxes="xy"},"interactions:action-start":e=>{WPe(e),qz(e)},"interactions:action-move":e=>{XPe(e),qz(e)},"interactions:action-end":JPe,"auto-start:check":zPe},defaults:{square:!1,preserveAspectRatio:!1,axis:"xy",margin:NaN,edges:null,invert:"none"},cursors:null,getCursor(e){let{edges:t,axis:n,name:r}=e;const i=Mc.cursors;let a=null;if(n)a=i[r+n];else if(t){let o="";for(const s of["top","bottom","left","right"])t[s]&&(o+=s);a=i[o]}return a},filterEventType:e=>e.search("resize")===0,defaultMargin:null};Sc.use(Mc);var ZPe=()=>{},$Pe=()=>{},e9e=e=>{const t=[["x","y"],["left","top"],["right","bottom"],["width","height"]].filter(r=>{let[i,a]=r;return i in e||a in e}),n=(r,i)=>{const{range:a,limits:o={left:-1/0,right:1/0,top:-1/0,bottom:1/0},offset:s={x:0,y:0}}=e,u={range:a,grid:e,x:null,y:null};for(const[c,A]of t){const d=Math.round((r-s.x)/e[c]),f=Math.round((i-s.y)/e[A]);u[c]=Math.max(o.left,Math.min(o.right,d*e[c]+s.x)),u[A]=Math.max(o.top,Math.min(o.bottom,f*e[A]+s.y))}return u};return n.grid=e,n.coordFields=t,n},t9e=Object.freeze({__proto__:null,edgeTarget:ZPe,elements:$Pe,grid:e9e});const n9e={id:"snappers",install(e){const{interactStatic:t}=e;t.snappers=fn(t.snappers||{},t9e),t.createSnapGrid=t.snappers.grid}};class Kz{constructor(t){this.states=[],this.startOffset={left:0,right:0,top:0,bottom:0},this.startDelta=void 0,this.result=void 0,this.endResult=void 0,this.startEdges=void 0,this.edges=void 0,this.interaction=void 0,this.interaction=t,this.result=M2(),this.edges={left:!1,right:!1,top:!1,bottom:!1}}start(t,n){let{phase:r}=t;const{interaction:i}=this,a=r9e(i);this.prepareStates(a),this.startEdges=fn({},i.edges),this.edges=fn({},this.startEdges),this.startOffset=i9e(i.rect,n),this.startDelta={x:0,y:0};const o=this.fillArg({phase:r,pageCoords:n,preEnd:!1});return this.result=M2(),this.startAll(o),this.result=this.setAll(o)}fillArg(t){const{interaction:n}=this;return t.interaction=n,t.interactable=n.interactable,t.element=n.element,t.rect||(t.rect=n.rect),t.edges||(t.edges=this.startEdges),t.startOffset=this.startOffset,t}startAll(t){for(const n of this.states)n.methods.start&&(t.state=n,n.methods.start(t))}setAll(t){const{phase:n,preEnd:r,skipModifiers:i,rect:a,edges:o}=t;t.coords=fn({},t.pageCoords),t.rect=fn({},a),t.edges=fn({},o);const s=i?this.states.slice(i):this.states,u=M2(t.coords,t.rect);for(const f of s){var c;const{options:h}=f,p=fn({},t.coords);let m=null;(c=f.methods)!=null&&c.set&&this.shouldDo(h,r,n)&&(t.state=f,m=f.methods.set(t),jM(t.edges,t.rect,{x:t.coords.x-p.x,y:t.coords.y-p.y})),u.eventProps.push(m)}fn(this.edges,t.edges),u.delta.x=t.coords.x-t.pageCoords.x,u.delta.y=t.coords.y-t.pageCoords.y,u.rectDelta.left=t.rect.left-a.left,u.rectDelta.right=t.rect.right-a.right,u.rectDelta.top=t.rect.top-a.top,u.rectDelta.bottom=t.rect.bottom-a.bottom;const A=this.result.coords,d=this.result.rect;if(A&&d){const f=u.rect.left!==d.left||u.rect.right!==d.right||u.rect.top!==d.top||u.rect.bottom!==d.bottom;u.changed=f||A.x!==u.coords.x||A.y!==u.coords.y}return u}applyToInteraction(t){const{interaction:n}=this,{phase:r}=t,i=n.coords.cur,a=n.coords.start,{result:o,startDelta:s}=this,u=o.delta;r==="start"&&fn(this.startDelta,o.delta);for(const[d,f]of[[a,s],[i,u]])d.page.x+=f.x,d.page.y+=f.y,d.client.x+=f.x,d.client.y+=f.y;const{rectDelta:c}=this.result,A=t.rect||n.rect;A.left+=c.left,A.right+=c.right,A.top+=c.top,A.bottom+=c.bottom,A.width=A.right-A.left,A.height=A.bottom-A.top}setAndApply(t){const{interaction:n}=this,{phase:r,preEnd:i,skipModifiers:a}=t,o=this.setAll(this.fillArg({preEnd:i,phase:r,pageCoords:t.modifiedCoords||n.coords.cur.page}));if(this.result=o,!o.changed&&(!a||a<this.states.length)&&n.interacting())return!1;if(t.modifiedCoords){const{page:s}=n.coords.cur,u={x:t.modifiedCoords.x-s.x,y:t.modifiedCoords.y-s.y};o.coords.x+=u.x,o.coords.y+=u.y,o.delta.x+=u.x,o.delta.y+=u.y}this.applyToInteraction(t)}beforeEnd(t){const{interaction:n,event:r}=t,i=this.states;if(!i||!i.length)return;let a=!1;for(const o of i){t.state=o;const{options:s,methods:u}=o,c=u.beforeEnd&&u.beforeEnd(t);if(c)return this.endResult=c,!1;a=a||!a&&this.shouldDo(s,!0,t.phase,!0)}a&&n.move({event:r,preEnd:!0})}stop(t){const{interaction:n}=t;if(!this.states||!this.states.length)return;const r=fn({states:this.states,interactable:n.interactable,element:n.element,rect:null},t);this.fillArg(r);for(const i of this.states)r.state=i,i.methods.stop&&i.methods.stop(r);this.states=null,this.endResult=null}prepareStates(t){this.states=[];for(let n=0;n<t.length;n++){const{options:r,methods:i,name:a}=t[n];this.states.push({options:r,methods:i,index:n,name:a})}return this.states}restoreInteractionCoords(t){let{interaction:{coords:n,rect:r,modification:i}}=t;if(!i.result)return;const{startDelta:a}=i,{delta:o,rectDelta:s}=i.result,u=[[n.start,a],[n.cur,o]];for(const[c,A]of u)c.page.x-=A.x,c.page.y-=A.y,c.client.x-=A.x,c.client.y-=A.y;r.left-=s.left,r.right-=s.right,r.top-=s.top,r.bottom-=s.bottom}shouldDo(t,n,r,i){return!(!t||t.enabled===!1||i&&!t.endOnly||t.endOnly&&!n||r==="start"&&!t.setStart)}copyFrom(t){this.startOffset=t.startOffset,this.startDelta=t.startDelta,this.startEdges=t.startEdges,this.edges=t.edges,this.states=t.states.map(n=>Jp(n)),this.result=M2(fn({},t.result.coords),fn({},t.result.rect))}destroy(){for(const t in this)this[t]=null}}function M2(e,t){return{rect:t,coords:e,delta:{x:0,y:0},rectDelta:{left:0,right:0,top:0,bottom:0},eventProps:[],changed:!0}}function r9e(e){const t=e.interactable.options[e.prepared.name],n=t.modifiers;return n&&n.length?n:["snap","snapSize","snapEdges","restrict","restrictEdges","restrictSize"].map(r=>{const i=t[r];return i&&i.enabled&&{options:i,methods:i._methods}}).filter(r=>!!r)}function i9e(e,t){return e?{left:t.x-e.left,top:t.y-e.top,right:e.right-t.x,bottom:e.bottom-t.y}:{left:0,top:0,right:0,bottom:0}}function nd(e,t){const{defaults:n}=e,r={start:e.start,set:e.set,beforeEnd:e.beforeEnd,stop:e.stop},i=a=>{const o=a||{};o.enabled=o.enabled!==!1;for(const u in n)u in o||(o[u]=n[u]);const s={options:o,methods:r,name:t,enable:()=>(o.enabled=!0,s),disable:()=>(o.enabled=!1,s)};return s};return t&&typeof t=="string"&&(i._defaults=n,i._methods=r),i}function WM(e){let{iEvent:t,interaction:n}=e;const r=n.modification.result;r&&(t.modifiers=r.eventProps)}const a9e={id:"modifiers/base",before:["actions"],install:e=>{e.defaults.perAction.modifiers=[]},listeners:{"interactions:new":e=>{let{interaction:t}=e;t.modification=new Kz(t)},"interactions:before-action-start":e=>{const{interaction:t}=e,n=e.interaction.modification;n.start(e,t.coords.start.page),t.edges=n.edges,n.applyToInteraction(e)},"interactions:before-action-move":e=>{const{interaction:t}=e,{modification:n}=t,r=n.setAndApply(e);return t.edges=n.edges,r},"interactions:before-action-end":e=>{const{interaction:t}=e,{modification:n}=t,r=n.beforeEnd(e);return t.edges=n.startEdges,r},"interactions:action-start":WM,"interactions:action-move":WM,"interactions:action-end":WM,"interactions:after-action-start":e=>e.interaction.modification.restoreInteractionCoords(e),"interactions:after-action-move":e=>e.interaction.modification.restoreInteractionCoords(e),"interactions:stop":e=>e.interaction.modification.stop(e)}},o9e={start(e){const{state:t,rect:n,edges:r,pageCoords:i}=e;let{ratio:a,enabled:o}=t.options;const{equalDelta:s,modifiers:u}=t.options;a==="preserve"&&(a=n.width/n.height),t.startCoords=fn({},i),t.startRect=fn({},n),t.ratio=a,t.equalDelta=s;const c=t.linkedEdges={top:r.top||r.left&&!r.bottom,left:r.left||r.top&&!r.right,bottom:r.bottom||r.right&&!r.top,right:r.right||r.bottom&&!r.left};if(t.xIsPrimaryAxis=!!(r.left||r.right),t.equalDelta){const d=(c.left?1:-1)*(c.top?1:-1);t.edgeSign={x:d,y:d}}else t.edgeSign={x:c.left?-1:1,y:c.top?-1:1};if(o!==!1&&fn(r,c),!(u!=null&&u.length))return;const A=new Kz(e.interaction);A.copyFrom(e.interaction.modification),A.prepareStates(u),t.subModification=A,A.startAll({...e})},set(e){const{state:t,rect:n,coords:r}=e,{linkedEdges:i}=t,a=fn({},r),o=t.equalDelta?s9e:l9e;if(fn(e.edges,i),o(t,t.xIsPrimaryAxis,r,n),!t.subModification)return null;const s=fn({},n);jM(i,s,{x:r.x-a.x,y:r.y-a.y});const u=t.subModification.setAll({...e,rect:s,edges:i,pageCoords:r,prevCoords:r,prevRect:s}),{delta:c}=u;if(u.changed){const A=Math.abs(c.x)>Math.abs(c.y);o(t,A,u.coords,u.rect),fn(r,u.coords)}return u.eventProps},defaults:{ratio:"preserve",equalDelta:!1,modifiers:[],enabled:!1}};function s9e(e,t,n){let{startCoords:r,edgeSign:i}=e;t?n.y=r.y+(n.x-r.x)*i.y:n.x=r.x+(n.y-r.y)*i.x}function l9e(e,t,n,r){let{startRect:i,startCoords:a,ratio:o,edgeSign:s}=e;if(t){const u=r.width/o;n.y=a.y+(u-i.height)*s.y}else{const u=r.height*o;n.x=a.x+(u-i.width)*s.x}}var u9e=nd(o9e,"aspectRatio");function c9e(e){let{rect:t,startOffset:n,state:r,interaction:i,pageCoords:a}=e;const{options:o}=r,{elementRect:s}=o,u=fn({left:0,top:0,right:0,bottom:0},o.offset||{});if(t&&s){const c=Vf(o.restriction,i,a);if(c){const A=c.right-c.left-t.width,d=c.bottom-c.top-t.height;A<0&&(u.left+=A,u.right+=A),d<0&&(u.top+=d,u.bottom+=d)}u.left+=n.left-t.width*s.left,u.top+=n.top-t.height*s.top,u.right+=n.right-t.width*(1-s.right),u.bottom+=n.bottom-t.height*(1-s.bottom)}r.offset=u}function A9e(e){let{coords:t,interaction:n,state:r}=e;const{options:i,offset:a}=r,o=Vf(i.restriction,n,t);if(!o)return;const s=MPe(o);t.x=Math.max(Math.min(s.right-a.right,t.x),s.left+a.left),t.y=Math.max(Math.min(s.bottom-a.bottom,t.y),s.top+a.top)}function Vf(e,t,n){return mt.func(e)?av(e,t.interactable,t.element,[n.x,n.y,t]):av(e,t.interactable,t.element)}const k2={start:c9e,set:A9e,defaults:{restriction:null,elementRect:null,offset:null,endOnly:!1,enabled:!1}};var d9e=nd(k2,"restrict");const Gz={top:1/0,left:1/0,bottom:-1/0,right:-1/0},Wz={top:-1/0,left:-1/0,bottom:1/0,right:1/0};function f9e(e){let{interaction:t,startOffset:n,state:r}=e;const{options:i}=r;let a;if(i){const o=Vf(i.offset,t,t.coords.start.page);a=C2(o)}a=a||{x:0,y:0},r.offset={top:a.y+n.top,left:a.x+n.left,bottom:a.y-n.bottom,right:a.x-n.right}}function h9e(e){let{coords:t,edges:n,interaction:r,state:i}=e;const{offset:a,options:o}=i;if(!n)return;const s=fn({},t),u=Vf(o.inner,r,s)||{},c=Vf(o.outer,r,s)||{};Xz(u,Gz),Xz(c,Wz),n.top?t.y=Math.min(Math.max(c.top+a.top,s.y),u.top+a.top):n.bottom&&(t.y=Math.max(Math.min(c.bottom+a.bottom,s.y),u.bottom+a.bottom)),n.left?t.x=Math.min(Math.max(c.left+a.left,s.x),u.left+a.left):n.right&&(t.x=Math.max(Math.min(c.right+a.right,s.x),u.right+a.right))}function Xz(e,t){for(const n of["top","left","bottom","right"])n in e||(e[n]=t[n]);return e}const sv={noInner:Gz,noOuter:Wz,start:f9e,set:h9e,defaults:{inner:null,outer:null,offset:null,endOnly:!1,enabled:!1}};var p9e=nd(sv,"restrictEdges");const m9e=fn({get elementRect(){return{top:0,left:0,bottom:1,right:1}},set elementRect(e){}},k2.defaults),g9e={start:k2.start,set:k2.set,defaults:m9e};var v9e=nd(g9e,"restrictRect");const y9e={width:-1/0,height:-1/0},b9e={width:1/0,height:1/0};function _9e(e){return sv.start(e)}function w9e(e){const{interaction:t,state:n,rect:r,edges:i}=e,{options:a}=n;if(!i)return;const o=Iz(Vf(a.min,t,e.coords))||y9e,s=Iz(Vf(a.max,t,e.coords))||b9e;n.options={endOnly:a.endOnly,inner:fn({},sv.noInner),outer:fn({},sv.noOuter)},i.top?(n.options.inner.top=r.bottom-o.height,n.options.outer.top=r.bottom-s.height):i.bottom&&(n.options.inner.bottom=r.top+o.height,n.options.outer.bottom=r.top+s.height),i.left?(n.options.inner.left=r.right-o.width,n.options.outer.left=r.right-s.width):i.right&&(n.options.inner.right=r.left+o.width,n.options.outer.right=r.left+s.width),sv.set(e),n.options=a}var x9e=nd({start:_9e,set:w9e,defaults:{min:null,max:null,endOnly:!1,enabled:!1}},"restrictSize");function B9e(e){const{interaction:t,interactable:n,element:r,rect:i,state:a,startOffset:o}=e,{options:s}=a,u=s.offsetWithOrigin?S9e(e):{x:0,y:0};let c;if(s.offset==="startCoords")c={x:t.coords.start.page.x,y:t.coords.start.page.y};else{const d=av(s.offset,n,r,[t]);c=C2(d)||{x:0,y:0},c.x+=u.x,c.y+=u.y}const{relativePoints:A}=s;a.offsets=i&&A&&A.length?A.map((d,f)=>({index:f,relativePoint:d,x:o.left-i.width*d.x+c.x,y:o.top-i.height*d.y+c.y})):[{index:0,relativePoint:null,x:c.x,y:c.y}]}function C9e(e){const{interaction:t,coords:n,state:r}=e,{options:i,offsets:a}=r,o=VM(t.interactable,t.element,t.prepared.name),s=fn({},n),u=[];i.offsetWithOrigin||(s.x-=o.x,s.y-=o.y);for(const A of a){const d=s.x-A.x,f=s.y-A.y;for(let h=0,p=i.targets.length;h<p;h++){const m=i.targets[h];let v;mt.func(m)?v=m(d,f,t._proxy,A,h):v=m,v&&u.push({x:(mt.number(v.x)?v.x:d)+A.x,y:(mt.number(v.y)?v.y:f)+A.y,range:mt.number(v.range)?v.range:i.range,source:m,index:h,offset:A})}}const c={target:null,inRange:!1,distance:0,range:0,delta:{x:0,y:0}};for(const A of u){const d=A.range,f=A.x-s.x,h=A.y-s.y,p=_2(f,h);let m=p<=d;d===1/0&&c.inRange&&c.range!==1/0&&(m=!1),(!c.target||(m?c.inRange&&d!==1/0?p/d<c.distance/c.range:d===1/0&&c.range!==1/0||p<c.distance:!c.inRange&&p<c.distance))&&(c.target=A,c.distance=p,c.range=d,c.inRange=m,c.delta.x=f,c.delta.y=h)}return c.inRange&&(n.x=c.target.x,n.y=c.target.y),r.closest=c,c}function S9e(e){const{element:t}=e.interaction;return C2(av(e.state.options.origin,null,null,[t]))||VM(e.interactable,t,e.interaction.prepared.name)}const XM={start:B9e,set:C9e,defaults:{range:1/0,targets:null,offset:null,offsetWithOrigin:!0,origin:null,relativePoints:null,endOnly:!1,enabled:!1}};var M9e=nd(XM,"snap");function k9e(e){const{state:t,edges:n}=e,{options:r}=t;if(!n)return null;e.state={options:{targets:null,relativePoints:[{x:n.left?0:1,y:n.top?0:1}],offset:r.offset||"self",origin:{x:0,y:0},range:r.range}},t.targetFields=t.targetFields||[["width","height"],["x","y"]],XM.start(e),t.offsets=e.state.offsets,e.state=t}function E9e(e){const{interaction:t,state:n,coords:r}=e,{options:i,offsets:a}=n,o={x:r.x-a[0].x,y:r.y-a[0].y};n.options=fn({},i),n.options.targets=[];for(const u of i.targets||[]){let c;if(mt.func(u)?c=u(o.x,o.y,t):c=u,!!c){for(const[A,d]of n.targetFields)if(A in c||d in c){c.x=c[A],c.y=c[d];break}n.options.targets.push(c)}}const s=XM.set(e);return n.options=i,s}const E2={start:k9e,set:E9e,defaults:{range:1/0,targets:null,offset:null,endOnly:!1,enabled:!1}};var L9e=nd(E2,"snapSize");function T9e(e){const{edges:t}=e;return t?(e.state.targetFields=e.state.targetFields||[[t.left?"left":"right",t.top?"top":"bottom"]],E2.start(e)):null}const N9e={start:T9e,set:E2.set,defaults:fn(Jp(E2.defaults),{targets:void 0,range:void 0,offset:{x:0,y:0}})};var F9e=nd(N9e,"snapEdges");const lv=()=>{};lv._defaults={};var JM={aspectRatio:u9e,restrictEdges:p9e,restrict:d9e,restrictRect:v9e,restrictSize:x9e,snapEdges:F9e,snap:M9e,snapSize:L9e,spring:lv,avoid:lv,transform:lv,rubberband:lv};const I9e={id:"modifiers",install(e){const{interactStatic:t}=e;e.usePlugin(a9e),e.usePlugin(n9e),t.modifiers=JM;for(const n in JM){const{_defaults:r,_methods:i}=JM[n];r._methods=i,e.defaults.perAction[n]=r}}};Sc.use(I9e);var uv=function(e){return e.touchAction="touchAction",e.boxSizing="boxSizing",e.noListeners="noListeners",e}(uv||{});const ZM="[interact.js] ",$M={touchAction:"https://developer.mozilla.org/en-US/docs/Web/CSS/touch-action",boxSizing:"https://developer.mozilla.org/en-US/docs/Web/CSS/box-sizing"};function O9e(e){let{logger:t}=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};const{Interactable:n,defaults:r}=e;e.logger=t||console,r.base.devTools={ignore:{}},n.prototype.devTools=function(a){return a?(fn(this.options.devTools,a),this):this.options.devTools};const{_onOff:i}=n.prototype;n.prototype._onOff=function(a,o,s,u,c){if(mt.string(this.target)||this.target.addEventListener)return i.call(this,a,o,s,u,c);mt.object(o)&&!mt.array(o)&&(u=s,s=null);const A=jf(o,s,c);for(const d in A)ov(d,e.actions)||e.logger.warn(ZM+`Can't add native "${d}" event listener to target without \`addEventListener(type, listener, options)\` prop.`);return i.call(this,a,A,u)}}const Jz=[{name:uv.touchAction,perform(e){let{element:t}=e;return!!t&&!D9e(t,"touchAction",/pan-|pinch|none/)},getInfo(e){let{element:t}=e;return[t,$M.touchAction]},text:`Consider adding CSS "touch-action: none" to this element
|
|
431
431
|
`},{name:uv.boxSizing,perform(e){const{element:t}=e;return e.prepared.name==="resize"&&t instanceof Xr.HTMLElement&&!Zz(t,"boxSizing",/border-box/)},text:'Consider adding CSS "box-sizing: border-box" to this resizable element',getInfo(e){let{element:t}=e;return[t,$M.boxSizing]}},{name:uv.noListeners,perform(e){var t;const n=e.prepared.name;return!(((t=e.interactable)==null?void 0:t.events.types[`${n}move`])||[]).length},getInfo(e){return[e.prepared.name,e.interactable]},text:"There are no listeners set for this action"}];function Zz(e,t,n){const r=e.style[t]||$A.getComputedStyle(e)[t];return n.test((r||"").toString())}function D9e(e,t,n){let r=e;for(;mt.element(r);){if(Zz(r,t,n))return!0;r=ed(r)}return!1}const U9e={id:"dev-tools",install:O9e,listeners:{"interactions:action-start":(e,t)=>{let{interaction:n}=e;for(const r of Jz){const i=n.interactable&&n.interactable.options;!(i&&i.devTools&&i.devTools.ignore[r.name])&&r.perform(n)&&t.logger.warn(ZM+r.text,...r.getInfo(n))}}},checks:Jz,CheckName:uv,links:$M,prefix:ZM};Sc.use(U9e);function P9e(){const{appContext:e,proxy:t}=l.getCurrentInstance(),n=e.config.globalProperties;return{proxy:t,appContext:e,globalProperties:n}}const H9e={name:"GridItem"},$z=l.defineComponent({...H9e,props:{isDraggable:{type:[Boolean,null],default:null},isResizable:{type:[Boolean,null],default:null},isBounded:{type:[Boolean,null],default:null},static:{type:Boolean,default:!1},minH:{default:1},minW:{default:1},maxH:{default:1/0},maxW:{default:1/0},x:{},y:{},w:{},h:{},i:{},dragIgnoreFrom:{default:"a, button"},dragAllowFrom:{default:null},resizeIgnoreFrom:{default:"a, button"},preserveAspectRatio:{type:Boolean,default:!1},dragOption:{default:()=>({})},resizeOption:{default:()=>({})}},emits:["container-resized","resize","resized","move","moved","dragging","dragend"],setup(e,{expose:t,emit:n}){const{proxy:r}=P9e(),i=r==null?void 0:r.$parent,a=l.inject("eventBus"),o=n,s=e,u=l.ref({}),c=l.ref(1),A=l.ref(100),d=l.ref(30),f=l.ref([10,10]),h=l.ref(1/0),p=l.ref(null),m=l.ref(null),v=l.ref(1),y=l.ref(!0),g=l.ref(!0),b=l.ref(!1),w=l.ref(null),_=l.ref(!1),C=l.ref(null),B=l.ref(NaN),k=l.ref(NaN),O=l.ref(NaN),Y=l.ref(NaN),M=l.ref({}),N=l.ref(!1),F=l.ref(!1),L=l.ref(!1),P=l.ref(null),K=l.ref(null),V=l.ref(null),j=l.ref(null),q=l.ref(s.x),ee=l.ref(s.y),te=l.ref(s.w),U=l.ref(s.h),W=l.ref(null),$=l.ref(null),re=l.computed(()=>m.value&&!s.static),me=l.computed(()=>(p.value||m.value)&&!s.static),fe=l.computed(()=>navigator.userAgent.toLowerCase().indexOf("android")!==-1),de=l.computed(()=>i!=null&&i.isMirrored?!N.value:N.value),le=l.computed(()=>({"vue-resizable":re.value,static:s.static,resizing:_.value,"vue-draggable-dragging":b.value,cssTransforms:y.value,"render-rtl":de.value,"disable-userselect":b.value,"no-touch":fe.value&&me.value})),ge=l.computed(()=>de.value?"vue-resizable-handle vue-rtl-resizable-handle":"vue-resizable-handle");l.watch(()=>s.isDraggable,We=>{p.value=We}),l.watch(()=>s.static,()=>{Ct(),Qt()}),l.watch(p,()=>{Ct()}),l.watch(()=>s.isResizable,We=>{m.value=We}),l.watch(()=>s.isBounded,We=>{W.value=We}),l.watch(m,()=>{Qt()}),l.watch(d,()=>{Se(),we()}),l.watch(c,()=>{Qt(),Se(),we()}),l.watch(A,()=>{Qt(),Se()}),l.watch(()=>s.x,We=>{q.value=We,Se()}),l.watch(()=>s.y,We=>{ee.value=We,Se()}),l.watch(()=>s.h,We=>{U.value=We,Se()}),l.watch(()=>s.w,We=>{te.value=We,Se()}),l.watch(de,()=>{Qt(),Se()}),l.watch(()=>s.minH,()=>{Qt()}),l.watch(()=>s.maxH,()=>{Qt()}),l.watch(()=>s.minW,()=>{Qt()}),l.watch(()=>s.maxW,()=>{Qt()}),l.watch(()=>i==null?void 0:i.margin,We=>{!We||We[0]==f.value[0]&&We[1]==f.value[1]||(f.value=We.map(ut=>Number(ut)),Se(),we())});function Be(We){rt(We)}function xe(We){$t()}function Ie(We){s.isDraggable===null&&(p.value=We)}function Q(We){s.isResizable===null&&(m.value=We)}function ye(We){s.isBounded===null&&(W.value=We)}function X(We){v.value=We}function ne(We){d.value=We}function Z(We){h.value=We}function ae(){N.value=uz()==="rtl",$t()}function _e(We){const ut=We.toString();c.value=parseInt(ut)}a.on("updateWidth",Be),a.on("compact",xe),a.on("setDraggable",Ie),a.on("setResizable",Q),a.on("setBounded",ye),a.on("setTransformScale",X),a.on("setRowHeight",ne),a.on("setMaxRows",Z),a.on("directionchange",ae),a.on("setColNum",_e),N.value=uz()==="rtl",l.onBeforeUnmount(()=>{a.off("updateWidth",Be),a.off("compact",xe),a.off("setDraggable",Ie),a.off("setResizable",Q),a.off("setBounded",ye),a.off("setTransformScale",X),a.off("setRowHeight",ne),a.off("setMaxRows",Z),a.off("directionchange",ae),a.off("setColNum",_e),$.value&&$.value.unset()}),l.onMounted(()=>{i!=null&&i.responsive&&i.lastBreakpoint?c.value=IM(i.lastBreakpoint,i==null?void 0:i.cols):c.value=i==null?void 0:i.colNum,d.value=i==null?void 0:i.rowHeight,A.value=(i==null?void 0:i.width)!==null?i==null?void 0:i.width:100,f.value=(i==null?void 0:i.margin)!==void 0?i.margin:[10,10],h.value=i==null?void 0:i.maxRows,s.isDraggable===null?p.value=i==null?void 0:i.isDraggable:p.value=s.isDraggable,s.isResizable===null?m.value=i==null?void 0:i.isResizable:m.value=s.isResizable,s.isBounded===null?W.value=i==null?void 0:i.isBounded:W.value=s.isBounded,v.value=i==null?void 0:i.transformScale,y.value=i==null?void 0:i.useCssTransforms,g.value=i==null?void 0:i.useStyleCursor,Se()});function Se(){var Yt,kt,jt,Ft,_n;s.x+s.w>c.value?(q.value=0,te.value=s.w>c.value?c.value:s.w):(q.value=s.x,te.value=s.w);let We=Te(q.value,ee.value,te.value,U.value);b.value&&(We.top=(Yt=w.value)==null?void 0:Yt.top,de.value?We.right=(kt=w.value)==null?void 0:kt.left:We.left=(jt=w.value)==null?void 0:jt.left),_.value&&(We.width=(Ft=C.value)==null?void 0:Ft.width,We.height=(_n=C.value)==null?void 0:_n.height);let ut;y.value?de.value?ut=MUe(We.top,We.right,We.width,We.height):ut=SUe(We.top,We.left,We.width,We.height):de.value?ut=EUe(We.top,We.right,We.width,We.height):ut=kUe(We.top,We.left,We.width,We.height),M.value=ut}function we(){let We={};for(let ut of["width","height"]){let kt=M.value[ut].match(/^(\d+)px$/);if(!kt)return;We[ut]=kt[1]}o("container-resized",s.i,s.h,s.w,We.height,We.width)}function He(We){var ut,Yt,kt;{if(s.static)return;const jt=az(We);if(jt==null)return;const{x:Ft,y:_n}=jt,Et={width:0,height:0};let xt;switch(We.type){case"resizestart":{Qt(),P.value=te.value,K.value=U.value,xt=Te(q.value,ee.value,te.value,U.value),Et.width=xt.width,Et.height=xt.height,C.value=Et,_.value=!0;break}case"resizemove":{const En=oz(O.value,Y.value,Ft,_n);de.value?Et.width=Number((ut=C.value)==null?void 0:ut.width)-En.deltaX/v.value:Et.width=Number((Yt=C.value)==null?void 0:Yt.width)+En.deltaX/v.value,Et.height=Number((kt=C.value)==null?void 0:kt.height)+En.deltaY/v.value,C.value=Et;break}case"resizeend":{xt=Te(q.value,ee.value,te.value,U.value),Et.width=xt.width,Et.height=xt.height,C.value=null,_.value=!1;break}}xt=_t(Et.height,Et.width),xt.w<s.minW&&(xt.w=s.minW),xt.w>s.maxW&&(xt.w=s.maxW),xt.h<s.minH&&(xt.h=s.minH),xt.h>s.maxH&&(xt.h=s.maxH),xt.h<1&&(xt.h=1),xt.w<1&&(xt.w=1),O.value=Ft,Y.value=_n,(te.value!==xt.w||U.value!==xt.h)&&o("resize",s.i,xt.h,xt.w,Et.height,Et.width),We.type==="resizeend"&&(P.value!==te.value||K.value!==U.value)&&o("resized",s.i,xt.h,xt.w,Et.height,Et.width);const Sr={eventType:We.type,i:s.i,x:q.value,y:ee.value,h:xt.h,w:xt.w};a.emit("resizeEvent",Sr)}}function Ee(We){var Et,xt,Sr;if(s.static||_.value)return;const ut=az(We);if(ut===null)return;const{x:Yt,y:kt}=ut;let jt={top:0,left:0};switch(We.type){case"dragstart":{V.value=q.value,j.value=ee.value;const En=We.target;let ar=En.offsetParent.getBoundingClientRect(),Lt=En.getBoundingClientRect();const Rr=Lt.left/v.value,ii=ar.left/v.value,Kn=Lt.right/v.value,xn=ar.right/v.value,In=Lt.top/v.value,gn=ar.top/v.value;de.value?jt.left=(Kn-xn)*-1:jt.left=Rr-ii,jt.top=In-gn,w.value=jt,b.value=!0;break}case"dragend":{if(!b.value)return;o("dragend",We,s.i);const En=We.target;let ar=En.offsetParent.getBoundingClientRect(),Lt=En.getBoundingClientRect();const Rr=Lt.left/v.value,ii=ar.left/v.value,Kn=Lt.right/v.value,xn=ar.right/v.value,In=Lt.top/v.value,gn=ar.top/v.value;de.value?jt.left=(Kn-xn)*-1:jt.left=Rr-ii,jt.top=In-gn,w.value=null,b.value=!1;break}case"dragmove":{o("dragging",We,s.i);const En=oz(B.value,k.value,Yt,kt);if(de.value?jt.left=Number((Et=w.value)==null?void 0:Et.left)-En.deltaX/v.value:jt.left=Number((xt=w.value)==null?void 0:xt.left)+En.deltaX/v.value,jt.top=Number((Sr=w.value)==null?void 0:Sr.top)+En.deltaY/v.value,W.value){const Lt=We.target.offsetParent.clientHeight-nt(s.h,d.value,f.value[1]);jt.top=ft(jt.top,0,Lt);const Rr=at(),ii=A.value-nt(s.w,Rr,f.value[0]);jt.left=ft(jt.left,0,ii)}w.value=jt;break}}let Ft;de.value,Ft=Ge(jt.top,jt.left),B.value=Yt,k.value=kt,(q.value!==Ft.x||ee.value!==Ft.y)&&o("move",s.i,Ft.x,Ft.y),We.type==="dragend"&&(V.value!==q.value||j.value!==ee.value)&&o("moved",s.i,Ft.x,Ft.y);const _n={eventType:We.type,i:s.i,x:Ft.x,y:Ft.y,h:U.value,w:te.value};a.emit("dragEvent",_n)}function Te(We,ut,Yt,kt){const jt=at();let Ft;return de.value?Ft={right:Math.round(jt*We+(We+1)*f.value[0]),top:Math.round(d.value*ut+(ut+1)*f.value[1]),width:Yt===1/0?Yt:Math.round(jt*Yt+Math.max(0,Yt-1)*f.value[0]),height:kt===1/0?kt:Math.round(d.value*kt+Math.max(0,kt-1)*f.value[1])}:Ft={left:Math.round(jt*We+(We+1)*f.value[0]),top:Math.round(d.value*ut+(ut+1)*f.value[1]),width:Yt===1/0?Yt:Math.round(jt*Yt+Math.max(0,Yt-1)*f.value[0]),height:kt===1/0?kt:Math.round(d.value*kt+Math.max(0,kt-1)*f.value[1])},Ft}function Ge(We,ut){const Yt=at();let kt=Math.round((ut-f.value[0])/(Yt+f.value[0])),jt=Math.round((We-f.value[1])/(d.value+f.value[1]));return kt=Math.max(Math.min(kt,c.value-te.value),0),jt=Math.max(Math.min(jt,h.value-U.value),0),{x:kt,y:jt}}function at(){return(A.value-f.value[0]*(c.value+1))/c.value}function nt(We,ut,Yt){return Number.isFinite(We)?Math.round(ut*We+Math.max(0,We-1)*Yt):We}function ft(We,ut,Yt){return Math.max(Math.min(We,Yt),ut)}function _t(We,ut,Yt=!1){const kt=at();let jt=Math.round((ut+f.value[0])/(kt+f.value[0])),Ft=0;return Yt?Ft=Math.ceil((We+f.value[1])/(d.value+f.value[1])):Ft=Math.round((We+f.value[1])/(d.value+f.value[1])),jt=Math.max(Math.min(jt,c.value-q.value),0),Ft=Math.max(Math.min(Ft,h.value-ee.value),0),{w:jt,h:Ft}}function rt(We,ut){A.value=We}function $t(We){Se()}function Ct(){if(($.value===null||$.value===void 0)&&($.value=Sc(u.value),g.value||$.value.styleCursor(!1)),p.value&&!s.static){const We={ignoreFrom:s.dragIgnoreFrom,allowFrom:s.dragAllowFrom,...s.dragOption};$.value.draggable(We),F.value||(F.value=!0,$.value.on("dragstart dragmove dragend",function(ut){Ee(ut)}))}else $.value.draggable({enabled:!1})}function Qt(){if(($.value===null||$.value===void 0)&&($.value=Sc(u.value),g.value||$.value.styleCursor(!1)),m.value&&!s.static){let We=Te(0,0,s.maxW,s.maxH),ut=Te(0,0,s.minW,s.minH);const Yt={edges:{left:!1,right:"."+ge.value.trim().replace(" ","."),bottom:"."+ge.value.trim().replace(" ","."),top:!1},ignoreFrom:s.resizeIgnoreFrom,restrictSize:{min:{height:ut.height*v.value,width:ut.width*v.value},max:{height:We.height*v.value,width:We.width*v.value}},...s.resizeOption};s.preserveAspectRatio&&(Yt.modifiers=[Sc.modifiers.aspectRatio({ratio:"preserve"})]),$.value.resizable(Yt),L.value||(L.value=!0,$.value.on("resizestart resizemove resizeend",function(kt){He(kt)}))}else $.value.resizable({enabled:!1})}const Dt=l.useSlots();function tn(){P.value=te.value,K.value=U.value;let We=Dt==null?void 0:Dt.default[0].elm.getBoundingClientRect(),ut=_t(We.height,We.width,!0);if(ut.w<s.minW&&(ut.w=s.minW),ut.w>s.maxW&&(ut.w=s.maxW),ut.h<s.minH&&(ut.h=s.minH),ut.h>s.maxH&&(ut.h=s.maxH),ut.h<1&&(ut.h=1),ut.w<1&&(ut.w=1),(te.value!==ut.w||U.value!==ut.h)&&o("resize",s.i,ut.h,ut.w,We.height,We.width),P.value!==ut.w||K.value!==ut.h){o("resized",s.i,ut.h,ut.w,We.height,We.width);const Yt={eventType:"resizeend",i:s.i,x:q.value,y:ee.value,h:ut.h,w:ut.w};a.emit("resizeEvent",Yt)}}return t({autoSize:tn,calcXY:Ge,dragging:w,...s}),(We,ut)=>(l.openBlock(),l.createElementBlock("div",{ref_key:"this$refsItem",ref:u,class:l.normalizeClass(["vue-grid-item",le.value]),style:l.normalizeStyle(M.value)},[l.renderSlot(We.$slots,"default",{style:l.normalizeStyle(M.value)}),re.value?(l.openBlock(),l.createElementBlock("span",{key:0,ref:"handle",class:l.normalizeClass(ge.value)},null,2)):l.createCommentVNode("",!0)],6))}});var e3={exports:{}},eq;function tq(){if(eq)return e3.exports;eq=1;var e=e3.exports={};return e.forEach=function(t,n){for(var r=0;r<t.length;r++){var i=n(t[r]);if(i)return i}},e3.exports}var t3,nq;function Y9e(){return nq||(nq=1,t3=function(e){var t=e.stateHandler.getState;function n(o){var s=t(o);return s&&!!s.isDetectable}function r(o){t(o).isDetectable=!0}function i(o){return!!t(o).busy}function a(o,s){t(o).busy=!!s}return{isDetectable:n,markAsDetectable:r,isBusy:i,markBusy:a}}),t3}var n3,rq;function R9e(){return rq||(rq=1,n3=function(e){var t={};function n(o){var s=e.get(o);return s===void 0?[]:t[s]||[]}function r(o,s){var u=e.get(o);t[u]||(t[u]=[]),t[u].push(s)}function i(o,s){for(var u=n(o),c=0,A=u.length;c<A;++c)if(u[c]===s){u.splice(c,1);break}}function a(o){var s=n(o);s&&(s.length=0)}return{get:n,add:r,removeListener:i,removeAllListeners:a}}),n3}var r3,iq;function Q9e(){return iq||(iq=1,r3=function(){var e=1;function t(){return e++}return{generate:t}}),r3}var i3,aq;function j9e(){return aq||(aq=1,i3=function(e){var t=e.idGenerator,n=e.stateHandler.getState;function r(a){var o=n(a);return o&&o.id!==void 0?o.id:null}function i(a){var o=n(a);if(!o)throw new Error("setId required the element to have a resize detection state.");var s=t.generate();return o.id=s,s}return{get:r,set:i}}),i3}var a3,oq;function V9e(){return oq||(oq=1,a3=function(e){function t(){}var n={log:t,warn:t,error:t};if(!e&&window.console){var r=function(i,a){i[a]=function(){var s=console[a];if(s.apply)s.apply(console,arguments);else for(var u=0;u<arguments.length;u++)s(arguments[u])}};r(n,"log"),r(n,"warn"),r(n,"error")}return n}),a3}var o3={exports:{}},sq;function lq(){if(sq)return o3.exports;sq=1;var e=o3.exports={};return e.isIE=function(t){function n(){var i=navigator.userAgent.toLowerCase();return i.indexOf("msie")!==-1||i.indexOf("trident")!==-1||i.indexOf(" edge/")!==-1}if(!n())return!1;if(!t)return!0;var r=function(){var i,a=3,o=document.createElement("div"),s=o.getElementsByTagName("i");do o.innerHTML="<!--[if gt IE "+ ++a+"]><i></i><![endif]-->";while(s[0]);return a>4?a:i}();return t===r},e.isLegacyOpera=function(){return!!window.opera},o3.exports}var s3={exports:{}},uq;function z9e(){if(uq)return s3.exports;uq=1;var e=s3.exports={};e.getOption=t;function t(n,r,i){var a=n[r];return a==null&&i!==void 0?i:a}return s3.exports}var l3,cq;function q9e(){if(cq)return l3;cq=1;var e=z9e();l3=function(r){r=r||{};var i=r.reporter,a=e.getOption(r,"async",!0),o=e.getOption(r,"auto",!0);o&&!a&&(i&&i.warn("Invalid options combination. auto=true and async=false is invalid. Setting async=true."),a=!0);var s=t(),u,c=!1;function A(v,y){!c&&o&&a&&s.size()===0&&h(),s.add(v,y)}function d(){for(c=!0;s.size();){var v=s;s=t(),v.process()}c=!1}function f(v){c||(v===void 0&&(v=a),u&&(p(u),u=null),v?h():d())}function h(){u=m(d)}function p(v){var y=clearTimeout;return y(v)}function m(v){var y=function(g){return setTimeout(g,0)};return y(v)}return{add:A,force:f}};function t(){var n={},r=0,i=0,a=0;function o(c,A){A||(A=c,c=0),c>i?i=c:c<a&&(a=c),n[c]||(n[c]=[]),n[c].push(A),r++}function s(){for(var c=a;c<=i;c++)for(var A=n[c],d=0;d<A.length;d++){var f=A[d];f()}}function u(){return r}return{add:o,process:s,size:u}}return l3}var u3,Aq;function K9e(){if(Aq)return u3;Aq=1;var e="_erd";function t(i){return i[e]={},n(i)}function n(i){return i[e]}function r(i){delete i[e]}return u3={initState:t,getState:n,cleanState:r},u3}var c3,dq;function G9e(){if(dq)return c3;dq=1;var e=lq();return c3=function(t){t=t||{};var n=t.reporter,r=t.batchProcessor,i=t.stateHandler.getState;if(!n)throw new Error("Missing required dependency: reporter.");function a(A,d){function f(){d(A)}if(e.isIE(8))i(A).object={proxy:f},A.attachEvent("onresize",f);else{var h=u(A);if(!h)throw new Error("Element is not detectable by this strategy.");h.contentDocument.defaultView.addEventListener("resize",f)}}function o(A){var d=t.important?" !important; ":"; ";return(A.join(d)+d).trim()}function s(A,d,f){f||(f=d,d=A,A=null),A=A||{},A.debug;function h(p,m){var v=o(["display: block","position: absolute","top: 0","left: 0","width: 100%","height: 100%","border: none","padding: 0","margin: 0","opacity: 0","z-index: -1000","pointer-events: none"]),y=!1,g=window.getComputedStyle(p),b=p.offsetWidth,w=p.offsetHeight;i(p).startSize={width:b,height:w};function _(){function C(){if(g.position==="static"){p.style.setProperty("position","relative",A.important?"important":"");var O=function(Y,M,N,F){function L(K){return K.replace(/[^-\d\.]/g,"")}var P=N[F];P!=="auto"&&L(P)!=="0"&&(Y.warn("An element that is positioned static has style."+F+"="+P+" which is ignored due to the static positioning. The element will need to be positioned relative, so the style."+F+" will be set to 0. Element: ",M),M.style.setProperty(F,"0",A.important?"important":""))};O(n,p,g,"top"),O(n,p,g,"right"),O(n,p,g,"bottom"),O(n,p,g,"left")}}function B(){y||C();function O(M,N){if(!M.contentDocument){var F=i(M);F.checkForObjectDocumentTimeoutId&&window.clearTimeout(F.checkForObjectDocumentTimeoutId),F.checkForObjectDocumentTimeoutId=setTimeout(function(){F.checkForObjectDocumentTimeoutId=0,O(M,N)},100);return}N(M.contentDocument)}var Y=this;O(Y,function(N){m(p)})}g.position!==""&&(C(),y=!0);var k=document.createElement("object");k.style.cssText=v,k.tabIndex=-1,k.type="text/html",k.setAttribute("aria-hidden","true"),k.onload=B,e.isIE()||(k.data="about:blank"),i(p)&&(p.appendChild(k),i(p).object=k,e.isIE()&&(k.data="about:blank"))}r?r.add(_):_()}e.isIE(8)?f(d):h(d,f)}function u(A){return i(A).object}function c(A){if(i(A)){var d=u(A);d&&(e.isIE(8)?A.detachEvent("onresize",d.proxy):A.removeChild(d),i(A).checkForObjectDocumentTimeoutId&&window.clearTimeout(i(A).checkForObjectDocumentTimeoutId),delete i(A).object)}}return{makeDetectable:s,addListener:a,uninstall:c}},c3}var A3,fq;function W9e(){if(fq)return A3;fq=1;var e=tq().forEach;return A3=function(t){t=t||{};var n=t.reporter,r=t.batchProcessor,i=t.stateHandler.getState;t.stateHandler.hasState;var a=t.idHandler;if(!r)throw new Error("Missing required dependency: batchProcessor");if(!n)throw new Error("Missing required dependency: reporter.");var o=d(),s="erd_scroll_detection_scrollbar_style",u="erd_scroll_detection_container";function c(_){f(_,s,u)}c(window.document);function A(_){var C=t.important?" !important; ":"; ";return(_.join(C)+C).trim()}function d(){var _=500,C=500,B=document.createElement("div");B.style.cssText=A(["position: absolute","width: "+_*2+"px","height: "+C*2+"px","visibility: hidden","margin: 0","padding: 0"]);var k=document.createElement("div");k.style.cssText=A(["position: absolute","width: "+_+"px","height: "+C+"px","overflow: scroll","visibility: none","top: "+-_*3+"px","left: "+-C*3+"px","visibility: hidden","margin: 0","padding: 0"]),k.appendChild(B),document.body.insertBefore(k,document.body.firstChild);var O=_-k.clientWidth,Y=C-k.clientHeight;return document.body.removeChild(k),{width:O,height:Y}}function f(_,C,B){function k(N,F){F=F||function(P){_.head.appendChild(P)};var L=_.createElement("style");return L.innerHTML=N,L.id=C,F(L),L}if(!_.getElementById(C)){var O=B+"_animation",Y=B+"_animation_active",M=`/* Created by the element-resize-detector library. */
|
|
432
432
|
`;M+="."+B+" > div::-webkit-scrollbar { "+A(["display: none"])+` }
|
|
433
433
|
|
|
@@ -60134,7 +60134,7 @@ function(e) {
|
|
|
60134
60134
|
*/
|
|
60135
60135
|
function(e) {
|
|
60136
60136
|
function t() {
|
|
60137
|
-
return (Bn.canvg ? Promise.resolve(Bn.canvg) : import("./index.es-
|
|
60137
|
+
return (Bn.canvg ? Promise.resolve(Bn.canvg) : import("./index.es-DnaOvzYf.mjs")).catch(function(n) {
|
|
60138
60138
|
return Promise.reject(new Error("Could not load canvg: " + n));
|
|
60139
60139
|
}).then(function(n) {
|
|
60140
60140
|
return n.default ? n.default : n;
|
|
@@ -60985,6 +60985,10 @@ const I6e = (e, t) => {
|
|
|
60985
60985
|
theme: {
|
|
60986
60986
|
type: String,
|
|
60987
60987
|
default: "light"
|
|
60988
|
+
},
|
|
60989
|
+
paginationStore: {
|
|
60990
|
+
type: Object,
|
|
60991
|
+
default: () => ({})
|
|
60988
60992
|
}
|
|
60989
60993
|
},
|
|
60990
60994
|
emits: ["delete", "edit"],
|
|
@@ -61118,8 +61122,9 @@ const I6e = (e, t) => {
|
|
|
61118
61122
|
class: ut(
|
|
61119
61123
|
e.panel.panelType === "image" || e.panel.panelType === "text" ? "" : "p-2"
|
|
61120
61124
|
),
|
|
61121
|
-
theme: e.theme
|
|
61122
|
-
|
|
61125
|
+
theme: e.theme,
|
|
61126
|
+
paginationStore: e.paginationStore
|
|
61127
|
+
}, null, 8, ["config", "obj", "id", "layout", "class", "theme", "paginationStore"]))
|
|
61123
61128
|
], 64));
|
|
61124
61129
|
}
|
|
61125
61130
|
};
|