mirror of
https://github.com/invoke-ai/InvokeAI
synced 2024-08-30 20:32:17 +00:00
170 lines
906 KiB
JavaScript
170 lines
906 KiB
JavaScript
|
var V0=(e,t,n)=>{if(!t.has(e))throw TypeError("Cannot "+n)};var Se=(e,t,n)=>(V0(e,t,"read from private field"),n?n.call(e):t.get(e)),en=(e,t,n)=>{if(t.has(e))throw TypeError("Cannot add the same private member more than once");t instanceof WeakSet?t.add(e):t.set(e,n)},eo=(e,t,n,r)=>(V0(e,t,"write to private field"),r?r.call(e,n):t.set(e,n),n);var vu=(e,t,n,r)=>({set _(o){eo(e,t,o,n)},get _(){return Se(e,t,r)}}),os=(e,t,n)=>(V0(e,t,"access private method"),n);import{a as gd,b as Cj,S as wj,c as Sj,d as kj,e as Jv,f as _j,i as e1,g as u7,k as d7,h as RC,j as jj,t as f7,l as p7,m as h7,n as m7,o as g7,p as v7,q as x7,r as W0,s as b7,u as d,v as a,w as Dx,x as Bp,y as y7,z as C7,A as w7,B as S7,P as k7,C as Rx,D as _7,E as j7,F as P7,G as I7,H as Pj,I as Pe,J as E7,K as _e,L as et,M as Fe,N as vd,O as nr,Q as vn,R as Hn,T as Yt,U as Ki,V as Qa,W as at,X as co,Y as Yl,Z as aa,_ as cm,$ as Ax,a0 as Dc,a1 as rn,a2 as M7,a3 as H,a4 as AC,a5 as O7,a6 as Ij,a7 as t1,a8 as xd,a9 as D7,aa as Ej,ab as Mj,ac as ds,ad as R7,ae as ie,af as we,ag as _t,ah as F,ai as A7,aj as NC,ak as N7,al as T7,am as $7,an as qi,ao as ee,ap as L7,aq as Tt,ar as Ft,as as Ie,at as $,au as so,av as be,aw as wn,ax as Oj,ay as z7,az as F7,aA as B7,aB as H7,aC as Lr,aD as Nx,aE as ia,aF as Ir,aG as um,aH as V7,aI as W7,aJ as TC,aK as Tx,aL as ye,aM as Ro,aN as U7,aO as Dj,aP as Rj,aQ as $C,aR as G7,aS as K7,aT as q7,aU as Xi,aV as Aj,aW as vt,aX as X7,aY as Y7,aZ as Q7,a_ as Nj,a$ as rr,b0 as dm,b1 as Z7,b2 as LC,b3 as Tj,b4 as J7,b5 as eD,b6 as tD,b7 as nD,b8 as rD,b9 as oD,ba as sD,bb as aD,bc as $j,bd as iD,be as lD,bf as cD,bg as uD,bh as dD,bi as Fr,bj as fD,bk as pD,bl as hD,bm as zC,bn as mD,bo as gD,bp as Fa,bq as fm,br as Lj,bs as zj,bt as po,bu as Fj,bv as vD,bw as Ri,bx as Eu,by as FC,bz as xD,bA as bD,bB as yD,bC as Hf,bD as Vf,bE as xu,bF as U0,bG as $u,bH as Lu,bI as zu,bJ as Fu,bK as BC,bL as Hp,bM as G0,bN as Vp,bO as HC,bP as n1,bQ as K0,bR as r1,bS as q0,bT as Wp,bU as VC,bV as Ai,bW as WC,bX as Ni,bY as UC,bZ as Up,b_ as pm,b$ as CD,c0 as Bj,c1 as o1,c2 as s1,c3 as Hj,c4 as wD,c5 as a1,c6 as SD,c7 as i1,c8 as kD,c9 as l1,ca as $x,cb as Lx,cc as zx,cd as Fx,ce as Bx,cf as hm,cg as Hx,ch as Ra,ci as Vj,cj as Wj,ck as Vx,cl as Uj,cm as _D,cn as bu,co as Ti,cp as Gj,cq as Kj,cr as GC,cs as jD,ct as PD,cu as ID,cv as Cn,cw as ED,cx as Tn,cy as bd,cz as mm,cA as MD,cB as OD,cC as DD,cD as RD,cE as AD,cF as ND,cG as TD,cH as $D,cI as LD,cJ as zD,cK as KC,cL as Wx,cM as FD,cN as BD,cO as yd,cP as HD,cQ as VD,cR as gm,cS as WD,cT as UD,cU as GD,cV as Ux,cW as KD,cX as dn,cY as qD,cZ as XD,c_ as YD,c$ as vm,d0 as QD,d1 as ZD,d2 as JD,d3 as Xu,d4 as qC,d5 as Bo,d6 as qj,d7 as eR,d8 as Gx,d9 as tR,da as XC,db as nR,dc as rR,dd as oR,de as Xj,df as sR,dg as aR,dh as iR,di as lR,dj as Yj,dk as cR,dl as uR,dm as dR,dn as fR,dp as pR,dq as hR,dr as mR,ds as gR,dt as Qj,du as Zj,dv as vR,dw as xR,dx as bR,dy as yR,dz as CR,dA as Ao,dB as wR,dC as go,dD as SR,dE as kR,dF as _R,dG as jR,dH as PR,dI as IR,dJ as ER,dK as MR,dL as OR,dM as DR,dN as RR,dO as AR,dP as NR,dQ as TR,dR as $R,dS as LR,dT as YC,dU as zR,dV as QC,dW as FR,dX as BR,dY as HR,dZ as VR,d_ as WR,d$ as UR,e0 as ZC,e1 as JC,e2 as ew,e3 as Kx,e4 as GR,e5 as Mo,e6 as Yu,e7 as fr,e8 as KR,e9 as qR,ea as Jj,eb as e5,ec as XR,ed as tw,ee as YR,ef as nw,eg as rw,eh as ow,ei as QR,ej as ZR,ek as sw,el as aw,em as JR,en as eA,eo as Gp,ep as tA,eq as iw,er as Wf,es as lw,et as cw,eu as nA,ev as rA,ew as oA,ex as t5,ey as sA,ez as aA,eA as uw,eB as iA,eC as dw,eD as lA,eE as n5,eF as r5,eG as Cd,eH as o5,eI as Ci,eJ as s5,eK as fw,eL as cA,eM as uA,eN as a5,eO as dA,eP as fA,eQ as pA,eR as hA,eS as mA,eT as qx,eU as c1,eV as pw,eW as Yi,eX as gA,eY as vA,eZ as i5,e_ as Us,e$ as Gs,f0 as l5,f1 as c5,f2 as Xx,f3 as u5,f4 as xA,f5 as Ks,f6 as bA,f7 as d5,f8 as yA,f9 as CA,fa as wA,fb as SA,fc as kA,fd as _A,fe as jA,ff as Kp,fg as Mu,fh as Vl,fi as PA,fj as IA,fk as EA,fl as MA,fm as OA,fn as DA,fo as RA,fp as AA,fq as NA,fr as TA,fs as $A,ft as LA,fu as zA,fv as FA,fw as BA,fx as HA,fy as VA,fz as WA,fA
|
||
|
M${O.x},${O.y}h${O.width}v${O.height}h${-O.width}z`,fill:u,fillRule:"evenodd",stroke:p,strokeWidth:h,pointerEvents:"none"})]})})}y5.displayName="MiniMap";var GN=d.memo(y5),To;(function(e){e.Lines="lines",e.Dots="dots",e.Cross="cross"})(To||(To={}));function KN({color:e,dimensions:t,lineWidth:n}){return a.jsx("path",{stroke:e,strokeWidth:n,d:`M${t[0]/2} 0 V${t[1]} M0 ${t[1]/2} H${t[0]}`})}function qN({color:e,radius:t}){return a.jsx("circle",{cx:t,cy:t,r:t,fill:e})}const XN={[To.Dots]:"#91919a",[To.Lines]:"#eee",[To.Cross]:"#e2e2e2"},YN={[To.Dots]:1,[To.Lines]:1,[To.Cross]:6},QN=e=>({transform:e.transform,patternId:`pattern-${e.rfId}`});function C5({id:e,variant:t=To.Dots,gap:n=20,size:r,lineWidth:o=1,offset:s=2,color:i,style:l,className:u}){const p=d.useRef(null),{transform:h,patternId:m}=Bp(QN,Rx),v=i||XN[t],x=r||YN[t],y=t===To.Dots,b=t===To.Cross,w=Array.isArray(n)?n:[n,n],k=[w[0]*h[2]||1,w[1]*h[2]||1],_=x*h[2],j=b?[_,_]:k,I=y?[_/s,_/s]:[j[0]/s,j[1]/s];return a.jsxs("svg",{className:Dx(["react-flow__background",u]),style:{...l,position:"absolute",width:"100%",height:"100%",top:0,left:0},ref:p,"data-testid":"rf__background",children:[a.jsx("pattern",{id:m+e,x:h[0]%k[0],y:h[1]%k[1],width:k[0],height:k[1],patternUnits:"userSpaceOnUse",patternTransform:`translate(-${I[0]},-${I[1]})`,children:y?a.jsx(qN,{color:v,radius:_/s}):a.jsx(KN,{dimensions:j,color:v,lineWidth:o})}),a.jsx("rect",{x:"0",y:"0",width:"100%",height:"100%",fill:`url(#${m+e})`})]})}C5.displayName="Background";var ZN=d.memo(C5);const _w=(e,t,n)=>{JN(n);const r=Pj(e,t);return w5[n].includes(r)},w5={">":[1],">=":[0,1],"=":[0],"<=":[-1,0],"<":[-1],"!=":[-1,1]},jw=Object.keys(w5),JN=e=>{if(typeof e!="string")throw new TypeError(`Invalid operator type, expected string but got ${typeof e}`);if(jw.indexOf(e)===-1)throw new Error(`Invalid operator, expected one of ${jw.join("|")}`)};function eT(){return!!(typeof window<"u"&&window.document&&window.document.createElement)}var tT=eT();const S5=1/60*1e3,nT=typeof performance<"u"?()=>performance.now():()=>Date.now(),k5=typeof window<"u"?e=>window.requestAnimationFrame(e):e=>setTimeout(()=>e(nT()),S5);function rT(e){let t=[],n=[],r=0,o=!1,s=!1;const i=new WeakSet,l={schedule:(u,p=!1,h=!1)=>{const m=h&&o,v=m?t:n;return p&&i.add(u),v.indexOf(u)===-1&&(v.push(u),m&&o&&(r=t.length)),u},cancel:u=>{const p=n.indexOf(u);p!==-1&&n.splice(p,1),i.delete(u)},process:u=>{if(o){s=!0;return}if(o=!0,[t,n]=[n,t],n.length=0,r=t.length,r)for(let p=0;p<r;p++){const h=t[p];h(u),i.has(h)&&(l.schedule(h),e())}o=!1,s&&(s=!1,l.process(u))}};return l}const oT=40;let f1=!0,Qu=!1,p1=!1;const Zl={delta:0,timestamp:0},Sd=["read","update","preRender","render","postRender"],xm=Sd.reduce((e,t)=>(e[t]=rT(()=>Qu=!0),e),{}),sT=Sd.reduce((e,t)=>{const n=xm[t];return e[t]=(r,o=!1,s=!1)=>(Qu||lT(),n.schedule(r,o,s)),e},{}),aT=Sd.reduce((e,t)=>(e[t]=xm[t].cancel,e),{});Sd.reduce((e,t)=>(e[t]=()=>xm[t].process(Zl),e),{});const iT=e=>xm[e].process(Zl),_5=e=>{Qu=!1,Zl.delta=f1?S5:Math.max(Math.min(e-Zl.timestamp,oT),1),Zl.timestamp=e,p1=!0,Sd.forEach(iT),p1=!1,Qu&&(f1=!1,k5(_5))},lT=()=>{Qu=!0,f1=!0,p1||k5(_5)},Pw=()=>Zl;function kd(e){const{viewBox:t="0 0 24 24",d:n,displayName:r,defaultProps:o={}}=e,s=d.Children.toArray(e.path),i=Pe((l,u)=>a.jsx(An,{ref:u,viewBox:t,...o,...l,children:s.length?s:a.jsx("path",{fill:"currentColor",d:n})}));return i.displayName=r,i}function j5(e){const{theme:t}=E7(),n=fN();return d.useMemo(()=>pN(t.direction,{...n,...e}),[e,t.direction,n])}var cT=Object.defineProperty,uT=(e,t,n)=>t in e?cT(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,hn=(e,t,n)=>(uT(e,typeof t!="symbol"?t+"":t,n),n);function Iw(e){return e.sort((t,n)=>{const r=t.compareDocumentPosition(n);if(r&Node.DOCUMENT_POSITION_FOLLOWING||r&Node.DOCUMENT_POSITION_CONTAINED_BY)return-1;if(r&Node.DOCUMENT_POSITION_PRECEDING||r&Node.DOCUMENT_POSITION_CONTAINS)return 1;if(r&Node.DOCUMENT_POSITION_DISCONNECTED||r&Node.DOCUMENT_POSITION_IMPLEMENTATION_SPECIFIC)throw Error("Cannot sort the given nodes.");return 0})}var dT=e=>typeof e=="object"&&"nodeType"i
|
||
|
`})}function ET(e){vd({condition:e.isOpen&&!!e.isDisabled,message:"Cannot open a disabled accordion item"})}function Nl(e){const{isOpen:t,isDisabled:n}=Zx(),{reduceMotion:r}=Jx(),o=et("chakra-accordion__icon",e.className),s=bm(),i={opacity:n?.4:1,transform:t?"rotate(-180deg)":void 0,transition:r?void 0:"transform 0.2s",transformOrigin:"center",...s.icon};return a.jsx(An,{viewBox:"0 0 24 24","aria-hidden":!0,className:o,__css:i,...e,children:a.jsx("path",{fill:"currentColor",d:"M16.59 8.59L12 13.17 7.41 8.59 6 10l6 6 6-6z"})})}Nl.displayName="AccordionIcon";var Tl=Pe(function(t,n){const{children:r,className:o}=t,{htmlProps:s,...i}=_T(t),u={...bm().container,overflowAnchor:"none"},p=d.useMemo(()=>i,[i]);return a.jsx(bT,{value:p,children:a.jsx(_e.div,{ref:n,...s,className:et("chakra-accordion__item",o),__css:u,children:typeof r=="function"?r({isExpanded:!!i.isOpen,isDisabled:!!i.isDisabled}):r})})});Tl.displayName="AccordionItem";var Wl={ease:[.25,.1,.25,1],easeIn:[.4,0,1,1],easeOut:[0,0,.2,1],easeInOut:[.4,0,.2,1]},ki={enter:{duration:.2,ease:Wl.easeOut},exit:{duration:.1,ease:Wl.easeIn}},Xs={enter:(e,t)=>({...e,delay:typeof t=="number"?t:t==null?void 0:t.enter}),exit:(e,t)=>({...e,delay:typeof t=="number"?t:t==null?void 0:t.exit})},MT=e=>e!=null&&parseInt(e.toString(),10)>0,Ow={exit:{height:{duration:.2,ease:Wl.ease},opacity:{duration:.3,ease:Wl.ease}},enter:{height:{duration:.3,ease:Wl.ease},opacity:{duration:.4,ease:Wl.ease}}},OT={exit:({animateOpacity:e,startingHeight:t,transition:n,transitionEnd:r,delay:o})=>{var s;return{...e&&{opacity:MT(t)?1:0},height:t,transitionEnd:r==null?void 0:r.exit,transition:(s=n==null?void 0:n.exit)!=null?s:Xs.exit(Ow.exit,o)}},enter:({animateOpacity:e,endingHeight:t,transition:n,transitionEnd:r,delay:o})=>{var s;return{...e&&{opacity:1},height:t,transitionEnd:r==null?void 0:r.enter,transition:(s=n==null?void 0:n.enter)!=null?s:Xs.enter(Ow.enter,o)}}},ym=d.forwardRef((e,t)=>{const{in:n,unmountOnExit:r,animateOpacity:o=!0,startingHeight:s=0,endingHeight:i="auto",style:l,className:u,transition:p,transitionEnd:h,...m}=e,[v,x]=d.useState(!1);d.useEffect(()=>{const _=setTimeout(()=>{x(!0)});return()=>clearTimeout(_)},[]),vd({condition:Number(s)>0&&!!r,message:"startingHeight and unmountOnExit are mutually exclusive. You can't use them together"});const y=parseFloat(s.toString())>0,b={startingHeight:s,endingHeight:i,animateOpacity:o,transition:v?p:{enter:{duration:0}},transitionEnd:{enter:h==null?void 0:h.enter,exit:r?h==null?void 0:h.exit:{...h==null?void 0:h.exit,display:y?"block":"none"}}},w=r?n:!0,k=n||r?"enter":"exit";return a.jsx(nr,{initial:!1,custom:b,children:w&&a.jsx(vn.div,{ref:t,...m,className:et("chakra-collapse",u),style:{overflow:"hidden",display:"block",...l},custom:b,variants:OT,initial:r?"exit":!1,animate:k,exit:"exit"})})});ym.displayName="Collapse";var DT={enter:({transition:e,transitionEnd:t,delay:n}={})=>{var r;return{opacity:1,transition:(r=e==null?void 0:e.enter)!=null?r:Xs.enter(ki.enter,n),transitionEnd:t==null?void 0:t.enter}},exit:({transition:e,transitionEnd:t,delay:n}={})=>{var r;return{opacity:0,transition:(r=e==null?void 0:e.exit)!=null?r:Xs.exit(ki.exit,n),transitionEnd:t==null?void 0:t.exit}}},I5={initial:"exit",animate:"enter",exit:"exit",variants:DT},RT=d.forwardRef(function(t,n){const{unmountOnExit:r,in:o,className:s,transition:i,transitionEnd:l,delay:u,...p}=t,h=o||r?"enter":"exit",m=r?o&&r:!0,v={transition:i,transitionEnd:l,delay:u};return a.jsx(nr,{custom:v,children:m&&a.jsx(vn.div,{ref:n,className:et("chakra-fade",s),custom:v,...I5,animate:h,...p})})});RT.displayName="Fade";var AT={exit:({reverse:e,initialScale:t,transition:n,transitionEnd:r,delay:o})=>{var s;return{opacity:0,...e?{scale:t,transitionEnd:r==null?void 0:r.exit}:{transitionEnd:{scale:t,...r==null?void 0:r.exit}},transition:(s=n==null?void 0:n.exit)!=null?s:Xs.exit(ki.exit,o)}},enter:({transitionEnd:e,transition:t,delay:n})=>{var r;return{opacity:1,scale:1,transition:(r=t==null?void 0:t.enter)!=null?r:Xs.enter(ki.enter,n),transitionEnd:e==null?void 0:e.enter}}},E5={initial:"exit",animate
|
||
|
.`.concat(dB,` {
|
||
|
overflow: hidden `).concat(r,`;
|
||
|
padding-right: `).concat(l,"px ").concat(r,`;
|
||
|
}
|
||
|
body {
|
||
|
overflow: hidden `).concat(r,`;
|
||
|
overscroll-behavior: contain;
|
||
|
`).concat([t&&"position: relative ".concat(r,";"),n==="margin"&&`
|
||
|
padding-left: `.concat(o,`px;
|
||
|
padding-top: `).concat(s,`px;
|
||
|
padding-right: `).concat(i,`px;
|
||
|
margin-left:0;
|
||
|
margin-top:0;
|
||
|
margin-right: `).concat(l,"px ").concat(r,`;
|
||
|
`),n==="padding"&&"padding-right: ".concat(l,"px ").concat(r,";")].filter(Boolean).join(""),`
|
||
|
}
|
||
|
|
||
|
.`).concat(Mp,` {
|
||
|
right: `).concat(l,"px ").concat(r,`;
|
||
|
}
|
||
|
|
||
|
.`).concat(Op,` {
|
||
|
margin-right: `).concat(l,"px ").concat(r,`;
|
||
|
}
|
||
|
|
||
|
.`).concat(Mp," .").concat(Mp,` {
|
||
|
right: 0 `).concat(r,`;
|
||
|
}
|
||
|
|
||
|
.`).concat(Op," .").concat(Op,` {
|
||
|
margin-right: 0 `).concat(r,`;
|
||
|
}
|
||
|
|
||
|
body {
|
||
|
`).concat(fB,": ").concat(l,`px;
|
||
|
}
|
||
|
`)},kB=function(e){var t=e.noRelative,n=e.noImportant,r=e.gapMode,o=r===void 0?"margin":r,s=d.useMemo(function(){return CB(o)},[o]);return d.createElement(wB,{styles:SB(s,!t,o,n?"":"!important")})},O1=!1;if(typeof window<"u")try{var Yf=Object.defineProperty({},"passive",{get:function(){return O1=!0,!0}});window.addEventListener("test",Yf,Yf),window.removeEventListener("test",Yf,Yf)}catch{O1=!1}var Pl=O1?{passive:!1}:!1,_B=function(e){return e.tagName==="TEXTAREA"},sP=function(e,t){var n=window.getComputedStyle(e);return n[t]!=="hidden"&&!(n.overflowY===n.overflowX&&!_B(e)&&n[t]==="visible")},jB=function(e){return sP(e,"overflowY")},PB=function(e){return sP(e,"overflowX")},aS=function(e,t){var n=t.ownerDocument,r=t;do{typeof ShadowRoot<"u"&&r instanceof ShadowRoot&&(r=r.host);var o=aP(e,r);if(o){var s=iP(e,r),i=s[1],l=s[2];if(i>l)return!0}r=r.parentNode}while(r&&r!==n.body);return!1},IB=function(e){var t=e.scrollTop,n=e.scrollHeight,r=e.clientHeight;return[t,n,r]},EB=function(e){var t=e.scrollLeft,n=e.scrollWidth,r=e.clientWidth;return[t,n,r]},aP=function(e,t){return e==="v"?jB(t):PB(t)},iP=function(e,t){return e==="v"?IB(t):EB(t)},MB=function(e,t){return e==="h"&&t==="rtl"?-1:1},OB=function(e,t,n,r,o){var s=MB(e,window.getComputedStyle(t).direction),i=s*r,l=n.target,u=t.contains(l),p=!1,h=i>0,m=0,v=0;do{var x=iP(e,l),y=x[0],b=x[1],w=x[2],k=b-w-s*y;(y||k)&&aP(e,l)&&(m+=k,v+=y),l=l.parentNode}while(!u&&l!==document.body||u&&(t.contains(l)||t===l));return(h&&(o&&m===0||!o&&i>m)||!h&&(o&&v===0||!o&&-i>v))&&(p=!0),p},Qf=function(e){return"changedTouches"in e?[e.changedTouches[0].clientX,e.changedTouches[0].clientY]:[0,0]},iS=function(e){return[e.deltaX,e.deltaY]},lS=function(e){return e&&"current"in e?e.current:e},DB=function(e,t){return e[0]===t[0]&&e[1]===t[1]},RB=function(e){return`
|
||
|
.block-interactivity-`.concat(e,` {pointer-events: none;}
|
||
|
.allow-interactivity-`).concat(e,` {pointer-events: all;}
|
||
|
`)},AB=0,Il=[];function NB(e){var t=d.useRef([]),n=d.useRef([0,0]),r=d.useRef(),o=d.useState(AB++)[0],s=d.useState(oP)[0],i=d.useRef(e);d.useEffect(function(){i.current=e},[e]),d.useEffect(function(){if(e.inert){document.body.classList.add("block-interactivity-".concat(o));var b=w1([e.lockRef.current],(e.shards||[]).map(lS),!0).filter(Boolean);return b.forEach(function(w){return w.classList.add("allow-interactivity-".concat(o))}),function(){document.body.classList.remove("block-interactivity-".concat(o)),b.forEach(function(w){return w.classList.remove("allow-interactivity-".concat(o))})}}},[e.inert,e.lockRef.current,e.shards]);var l=d.useCallback(function(b,w){if("touches"in b&&b.touches.length===2)return!i.current.allowPinchZoom;var k=Qf(b),_=n.current,j="deltaX"in b?b.deltaX:_[0]-k[0],I="deltaY"in b?b.deltaY:_[1]-k[1],M,E=b.target,O=Math.abs(j)>Math.abs(I)?"h":"v";if("touches"in b&&O==="h"&&E.type==="range")return!1;var D=aS(O,E);if(!D)return!0;if(D?M=O:(M=O==="v"?"h":"v",D=aS(O,E)),!D)return!1;if(!r.current&&"changedTouches"in b&&(j||I)&&(r.current=M),!M)return!0;var A=r.current||M;return OB(A,w,b,A==="h"?j:I,!0)},[]),u=d.useCallback(function(b){var w=b;if(!(!Il.length||Il[Il.length-1]!==s)){var k="deltaY"in w?iS(w):Qf(w),_=t.current.filter(function(M){return M.name===w.type&&M.target===w.target&&DB(M.delta,k)})[0];if(_&&_.should){w.cancelable&&w.preventDefault();return}if(!_){var j=(i.current.shards||[]).map(lS).filter(Boolean).filter(function(M){return M.contains(w.target)}),I=j.length>0?l(w,j[0]):!i.current.noIsolation;I&&w.cancelable&&w.preventDefault()}}},[]),p=d.useCallback(function(b,w,k,_){var j={name:b,delta:w,target:k,should:_};t.current.push(j),setTimeout(function(){t.current=t.current.filter(function(I){return I!==j})},1)},[]),h=d.useCallback(function(b){n.current=Qf(b),r.current=void 0},[]),m=d.useCallback(function(b){p(b.type,iS(b),b.target,l(b,e.lockRef.current))},[]),v=d.useCallback(function(b){p(b.type,Qf(b),b.target,l(b,e.lockRef.current))},[]);d.useEffect(function(){return Il.push(s),e.setCallbacks({onScrollCapture:m,onWheelCapture:m,onTouchMoveCapture:v}),document.addEventListener("wheel",u,Pl),document.addEventListener("touchmove",u,Pl),document.addEventListener("touchstart",h,Pl),function(){Il=Il.filter(function(b){return b!==s}),document.removeEventListener("wheel",u,Pl),document.removeEventListener("touchmove",u,Pl),document.removeEventListener("touchstart",h,Pl)}},[]);var x=e.removeScrollBar,y=e.inert;return d.createElement(d.Fragment,null,y?d.createElement(s,{styles:RB(o)}):null,x?d.createElement(kB,{gapMode:e.gapMode}):null)}const TB=A$(rP,NB);var lP=d.forwardRef(function(e,t){return d.createElement(Mm,us({},e,{ref:t,sideCar:TB}))});lP.classNames=Mm.classNames;const $B=lP;function LB(e){const{autoFocus:t,trapFocus:n,dialogRef:r,initialFocusRef:o,blockScrollOnMount:s,allowPinchZoom:i,finalFocusRef:l,returnFocusOnClose:u,preserveScrollBarGap:p,lockFocusAcrossFrames:h,isOpen:m}=zi(),[v,x]=D7();d.useEffect(()=>{!v&&x&&setTimeout(x)},[v,x]);const y=tP(r,m);return a.jsx(E3,{autoFocus:t,isDisabled:!n,initialFocusRef:o,finalFocusRef:l,restoreFocus:u,contentRef:r,lockFocusAcrossFrames:h,children:a.jsx($B,{removeScrollBar:!p,allowPinchZoom:i,enabled:y===1&&s,forwardProps:!0,children:e.children})})}var Bi=Pe((e,t)=>{const{className:n,children:r,containerProps:o,motionProps:s,...i}=e,{getDialogProps:l,getDialogContainerProps:u}=zi(),p=l(i,t),h=u(o),m=et("chakra-modal__content",n),v=$c(),x={display:"flex",flexDirection:"column",position:"relative",width:"100%",outline:0,...v.dialog},y={display:"flex",width:"100vw",height:"$100vh",position:"fixed",left:0,top:0,...v.dialogContainer},{motionPreset:b}=zi();return a.jsx(LB,{children:a.jsx(_e.div,{...h,className:"chakra-modal__content-container",tabIndex:-1,__css:y,children:a.jsx(eP,{preset:b,motionProps:s,className:m,...p,__css:x,children:r})})})});Bi.displayName="ModalContent";function Ad(e){const{leastDestructiveRef:t,...n}=e;return a.jsx(Fi,{...n,initialFocusRef:t})}var Nd=Pe((e,t)=>a.jsx(Bi,{ref:t,role:"alertdialog",...e})),gs=Pe((e,t)=>{const{className:
|
||
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function BV(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function HV(e){if(Array.isArray(e))return z1(e)}function vS(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),n.push.apply(n,r)}return n}function xS(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?vS(Object(n),!0).forEach(function(r){$P(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):vS(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function $P(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function rd(e,t){return UV(e)||WV(e,t)||LP(e,t)||VV()}function VV(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
||
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function LP(e,t){if(e){if(typeof e=="string")return z1(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return z1(e,t)}}function z1(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function WV(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r=[],o=!0,s=!1,i,l;try{for(n=n.call(e);!(o=(i=n.next()).done)&&(r.push(i.value),!(t&&r.length===t));o=!0);}catch(u){s=!0,l=u}finally{try{!o&&n.return!=null&&n.return()}finally{if(s)throw l}}return r}}function UV(e){if(Array.isArray(e))return e}var GV="file-invalid-type",KV="file-too-large",qV="file-too-small",XV="too-many-files",YV=function(t){t=Array.isArray(t)&&t.length===1?t[0]:t;var n=Array.isArray(t)?"one of ".concat(t.join(", ")):t;return{code:GV,message:"File type must be ".concat(n)}},bS=function(t){return{code:KV,message:"File is larger than ".concat(t," ").concat(t===1?"byte":"bytes")}},yS=function(t){return{code:qV,message:"File is smaller than ".concat(t," ").concat(t===1?"byte":"bytes")}},QV={code:XV,message:"Too many files"};function zP(e,t){var n=e.type==="application/x-moz-file"||zV(e,t);return[n,n?null:YV(t)]}function FP(e,t,n){if(bi(e.size))if(bi(t)&&bi(n)){if(e.size>n)return[!1,bS(n)];if(e.size<t)return[!1,yS(t)]}else{if(bi(t)&&e.size<t)return[!1,yS(t)];if(bi(n)&&e.size>n)return[!1,bS(n)]}return[!0,null]}function bi(e){return e!=null}function ZV(e){var t=e.files,n=e.accept,r=e.minSize,o=e.maxSize,s=e.multiple,i=e.maxFiles,l=e.validator;return!s&&t.length>1||s&&i>=1&&t.length>i?!1:t.every(function(u){var p=zP(u,n),h=rd(p,1),m=h[0],v=FP(u,r,o),x=rd(v,1),y=x[0],b=l?l(u):null;return m&&y&&!b})}function ah(e){return typeof e.isPropagationStopped=="function"?e.isPropagationStopped():typeof e.cancelBubble<"u"?e.cancelBubble:!1}function Jf(e){return e.dataTransfer?Array.prototype.some.call(e.dataTransfer.types,function(t){return t==="Files"||t==="application/x-moz-file"}):!!e.target&&!!e.target.files}function CS(e){e.preventDefault()}function JV(e){return e.indexOf("MSIE")!==-1||e.indexOf("Trident/")!==-1}function eW(e){return e.indexOf("Edge/")!==-1}function tW(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:window.navigator.userAgent;return JV(e)||eW(e)}function ss(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return function(r){for(var o=arguments.length,s=new Array(o>1?o-1:0),i=1;i<o;i++)s[i-1]=arguments[i];return t.some(function(l){return!ah(r)&&l&&l.apply(void 0,[r].concat(s)),ah(r)})}}function nW(){return"showOpenFilePicker"in window}function rW(e){if(bi(e)){var t=Object.entries(e).filter(function(n){var r=rd(n,2),o=r[0],s=r[1],i=!0;return BP(o)||(console.warn('Skipped "'.concat(o,'" because it is not a valid MIME type. Check https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/MIME_types/Common_types for a list of valid MIME types.')),i=!1),(!Array.isArray(s)||!s.every(HP))&&(console.warn('Skipped "'.concat(o,'" because an invalid file extension was provided.')),i=!1),i}).reduce(function(n,r){var o=rd(r,2),s=o[0],i=o[1];return xS(xS({},n),{},$P({},s,i))},{});return[{description:"Files",accept:t}]}return e}function oW(e){if(bi(e))return Object.entries(e).reduce(function(t,n){var r=rd(n,2),o=r[0],s=r[1];return[].concat(gS(t),[o],gS(s))},[]).filter(function(t){return BP(t)||HP(t)}).join(",")}function sW(e){return e instanceof DOMException&&(e.name==="AbortError"||e.code===e.ABORT_ERR)}function aW(e){return e instanceof DOMException&&(e.name==="SecurityError"||e.code===e.SECURITY_ERR)}function BP(e){return e==="audio/*"||e==="video/*"||e==="image/*"||e==="text/*"||/\w+\/[-+.\w]+/g.test(e)}function HP(e){return/^.*\.[\w]+$/.test(e)}var iW=["children"],lW=["open"],cW=["refKey","role","onKeyDown","onFocus","onBlur","onClick","onDragEnter","onDragOver","onDragLeave","onDr
|
||
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function pW(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function hW(e){if(Array.isArray(e))return F1(e)}function mv(e,t){return vW(e)||gW(e,t)||VP(e,t)||mW()}function mW(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
||
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function VP(e,t){if(e){if(typeof e=="string")return F1(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return F1(e,t)}}function F1(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function gW(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r=[],o=!0,s=!1,i,l;try{for(n=n.call(e);!(o=(i=n.next()).done)&&(r.push(i.value),!(t&&r.length===t));o=!0);}catch(u){s=!0,l=u}finally{try{!o&&n.return!=null&&n.return()}finally{if(s)throw l}}return r}}function vW(e){if(Array.isArray(e))return e}function wS(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),n.push.apply(n,r)}return n}function ln(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?wS(Object(n),!0).forEach(function(r){B1(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):wS(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function B1(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function ih(e,t){if(e==null)return{};var n=xW(e,t),r,o;if(Object.getOwnPropertySymbols){var s=Object.getOwnPropertySymbols(e);for(o=0;o<s.length;o++)r=s[o],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function xW(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,s;for(s=0;s<r.length;s++)o=r[s],!(t.indexOf(o)>=0)&&(n[o]=e[o]);return n}var Fb=d.forwardRef(function(e,t){var n=e.children,r=ih(e,iW),o=Bb(r),s=o.open,i=ih(o,lW);return d.useImperativeHandle(t,function(){return{open:s}},[s]),H.createElement(d.Fragment,null,n(ln(ln({},i),{},{open:s})))});Fb.displayName="Dropzone";var WP={disabled:!1,getFilesFromEvent:MV,maxSize:1/0,minSize:0,multiple:!0,maxFiles:0,preventDropOnDocument:!0,noClick:!1,noKeyboard:!1,noDrag:!1,noDragEventsBubbling:!1,validator:null,useFsAccessApi:!0,autoFocus:!1};Fb.defaultProps=WP;Fb.propTypes={children:Ht.func,accept:Ht.objectOf(Ht.arrayOf(Ht.string)),multiple:Ht.bool,preventDropOnDocument:Ht.bool,noClick:Ht.bool,noKeyboard:Ht.bool,noDrag:Ht.bool,noDragEventsBubbling:Ht.bool,minSize:Ht.number,maxSize:Ht.number,maxFiles:Ht.number,disabled:Ht.bool,getFilesFromEvent:Ht.func,onFileDialogCancel:Ht.func,onFileDialogOpen:Ht.func,useFsAccessApi:Ht.bool,autoFocus:Ht.bool,onDragEnter:Ht.func,onDragLeave:Ht.func,onDragOver:Ht.func,onDrop:Ht.func,onDropAccepted:Ht.func,onDropRejected:Ht.func,onError:Ht.func,validator:Ht.func};var H1={isFocused:!1,isFileDialogActive:!1,isDragActive:!1,isDragAccept:!1,isDragReject:!1,acceptedFiles:[],fileRejections:[]};function Bb(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},t=ln(ln({},WP),e),n=t.accept,r=t.disabled,o=t.getFilesFromEvent,s=t.maxSize,i=t.minSize,l=t.multiple,u=t.maxFiles,p=t.onDragEnter,h=t.onDragLeave,m=t.onDragOver,v=t.onDrop,x=t.onDropAccepted,y=t.onDropRejected,b=t.onFileDialogCancel,w=t.onFileDialogOpen,k=t.useFsAccessApi,_=t.autoFocus,j=t.preventDropOnDocument,I=t.noClick,M=t.noKeyboard,E=t.noDrag,O=t.noDragEventsBubbling,D=t.onError,A=t.validator,R=d.useMemo(function(){return oW(n)},[n]),T=d.useMemo(function(){return rW(n)},[n]),X=d.useMemo(function(){return typeof w=="function"?w:SS},[w]),B=d.useMemo(function(){return typeof b=="function"?b:SS},[b]),U=d.useRef(null),Y=d.useRef(null),V=d.useReducer(bW,H1),L=mv(V,2),q=L[0],z=L[1],K=q.isFocused,re=q.isFileDialogActive,Q=d.useRef(typeof window<"u"&&window.isSecureContext&&k&&nW()),le=function(){!Q.current&&re&&setTimeout(function(){if(Y.current){var Re=Y.current.files;Re.length||(z({type:"closeDialog"}),B())}},300)};d.useEffect(function
|
||
|
`),status:"error"})},[i,s]),m=d.useCallback(async j=>{p({file:j,image_category:"user",is_intermediate:!1,postUploadAction:r,board_id:n==="none"?void 0:n})},[n,r,p]),v=d.useCallback((j,I)=>{if(I.length>1){s({title:i("toast.uploadFailed"),description:i("toast.uploadFailedInvalidUploadDesc"),status:"error"});return}I.forEach(M=>{h(M)}),j.forEach(M=>{m(M)})},[i,s,m,h]),{getRootProps:x,getInputProps:y,isDragAccept:b,isDragReject:w,isDragActive:k,inputRef:_}=Bb({accept:{"image/png":[".png"],"image/jpeg":[".jpg",".jpeg",".png"]},noClick:!0,onDrop:v,onDragOver:()=>u(!0),disabled:o,multiple:!1});return d.useEffect(()=>{const j=async I=>{var M,E;_.current&&(M=I.clipboardData)!=null&&M.files&&(_.current.files=I.clipboardData.files,(E=_.current)==null||E.dispatchEvent(new Event("change",{bubbles:!0})))};return document.addEventListener("paste",j),()=>{document.removeEventListener("paste",j)}},[_]),a.jsxs(Ie,{...x({style:{}}),onKeyDown:j=>{j.key},children:[a.jsx("input",{...y()}),t,a.jsx(nr,{children:k&&l&&a.jsx(vn.div,{initial:{opacity:0},animate:{opacity:1,transition:{duration:.1}},exit:{opacity:0,transition:{duration:.1}},children:a.jsx(AW,{isDragAccept:b,isDragReject:w,setIsHandlingUpload:u})},"image-upload-overlay")})]})},$W=d.memo(TW),LW=Pe((e,t)=>{const{children:n,tooltip:r="",tooltipProps:{placement:o="top",hasArrow:s=!0,...i}={},isChecked:l,...u}=e;return a.jsx(Rt,{label:r,placement:o,hasArrow:s,...i,children:a.jsx(vc,{ref:t,colorScheme:l?"accent":"base",...u,children:n})})}),it=d.memo(LW);function zW(e){const t=d.createContext(null);return[({children:o,value:s})=>H.createElement(t.Provider,{value:s},o),()=>{const o=d.useContext(t);if(o===null)throw new Error(e);return o}]}function YP(e){return Array.isArray(e)?e:[e]}const FW=()=>{};function BW(e,t={active:!0}){return typeof e!="function"||!t.active?t.onKeyDown||FW:n=>{var r;n.key==="Escape"&&(e(n),(r=t.onTrigger)==null||r.call(t))}}function QP({data:e}){const t=[],n=[],r=e.reduce((o,s,i)=>(s.group?o[s.group]?o[s.group].push(i):o[s.group]=[i]:n.push(i),o),{});return Object.keys(r).forEach(o=>{t.push(...r[o].map(s=>e[s]))}),t.push(...n.map(o=>e[o])),t}function ZP(e){return Array.isArray(e)||e===null?!1:typeof e=="object"?e.type!==H.Fragment:!1}function JP(e){var t,n,r="";if(typeof e=="string"||typeof e=="number")r+=e;else if(typeof e=="object")if(Array.isArray(e))for(t=0;t<e.length;t++)e[t]&&(n=JP(e[t]))&&(r&&(r+=" "),r+=n);else for(t in e)e[t]&&(r&&(r+=" "),r+=t);return r}function e6(){for(var e=0,t,n,r="";e<arguments.length;)(t=arguments[e++])&&(n=JP(t))&&(r&&(r+=" "),r+=n);return r}const HW={app:100,modal:200,popover:300,overlay:400,max:9999};function Vb(e){return HW[e]}function VW(e,t){const n=d.useRef();return(!n.current||t.length!==n.current.prevDeps.length||n.current.prevDeps.map((r,o)=>r===t[o]).indexOf(!1)>=0)&&(n.current={v:e(),prevDeps:[...t]}),n.current.v}const WW=z7({key:"mantine",prepend:!0});function UW(){return x5()||WW}var GW=Object.defineProperty,_S=Object.getOwnPropertySymbols,KW=Object.prototype.hasOwnProperty,qW=Object.prototype.propertyIsEnumerable,jS=(e,t,n)=>t in e?GW(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,XW=(e,t)=>{for(var n in t||(t={}))KW.call(t,n)&&jS(e,n,t[n]);if(_S)for(var n of _S(t))qW.call(t,n)&&jS(e,n,t[n]);return e};const xv="ref";function YW(e){let t;if(e.length!==1)return{args:e,ref:t};const[n]=e;if(!(n instanceof Object))return{args:e,ref:t};if(!(xv in n))return{args:e,ref:t};t=n[xv];const r=XW({},n);return delete r[xv],{args:[r],ref:t}}const{cssFactory:QW}=(()=>{function e(n,r,o){const s=[],i=H7(n,s,o);return s.length<2?o:i+r(s)}function t(n){const{cache:r}=n,o=(...i)=>{const{ref:l,args:u}=YW(i),p=F7(u,r.registered);return B7(r,p,!1),`${r.key}-${p.name}${l===void 0?"":` ${l}`}`};return{css:o,cx:(...i)=>e(r.registered,o,e6(i))}}return{cssFactory:t}})();function t6(){const e=UW();return VW(()=>QW({cache:e}),[e])}function ZW({cx:e,classes:t,context:n,classNames:r,name:o,cache:s}){const i=n.reduce((l,u)=>(Object.keys(u.classNames).forEach(p=>{typeof l[p]!="string"?l[p]=`${u.classNames[p]}`:l[p]=`${l[p]} ${u.classNam
|
||
|
* OverlayScrollbars
|
||
|
* Version: 2.2.1
|
||
|
*
|
||
|
* Copyright (c) Rene Haas | KingSora.
|
||
|
* https://github.com/KingSora
|
||
|
*
|
||
|
* Released under the MIT license.
|
||
|
*/function Dt(e,t){if(og(e))for(let n=0;n<e.length&&t(e[n],n,e)!==!1;n++);else e&&Dt(Object.keys(e),n=>t(e[n],n,e));return e}function er(e,t){const n=ni(t);if(Ko(t)||n){let o=n?"":{};if(e){const s=window.getComputedStyle(e,null);o=n?Ak(e,s,t):t.reduce((i,l)=>(i[l]=Ak(e,s,l),i),o)}return o}e&&Dt(Vr(t),o=>NJ(e,o,t[o]))}const Oo=(e,t)=>{const{o:n,u:r,_:o}=e;let s=n,i;const l=(h,m)=>{const v=s,x=h,y=m||(r?!r(v,x):v!==x);return(y||o)&&(s=x,i=v),[s,y,i]};return[t?h=>l(t(s,i),h):l,h=>[s,!!h,i]]},Hd=()=>typeof window<"u",BE=Hd()&&Node.ELEMENT_NODE,{toString:yJ,hasOwnProperty:jv}=Object.prototype,fa=e=>e===void 0,rg=e=>e===null,CJ=e=>fa(e)||rg(e)?`${e}`:yJ.call(e).replace(/^\[object (.+)\]$/,"$1").toLowerCase(),Va=e=>typeof e=="number",ni=e=>typeof e=="string",oy=e=>typeof e=="boolean",Go=e=>typeof e=="function",Ko=e=>Array.isArray(e),ad=e=>typeof e=="object"&&!Ko(e)&&!rg(e),og=e=>{const t=!!e&&e.length,n=Va(t)&&t>-1&&t%1==0;return Ko(e)||!Go(e)&&n?t>0&&ad(e)?t-1 in e:!0:!1},tx=e=>{if(!e||!ad(e)||CJ(e)!=="object")return!1;let t;const n="constructor",r=e[n],o=r&&r.prototype,s=jv.call(e,n),i=o&&jv.call(o,"isPrototypeOf");if(r&&!s&&!i)return!1;for(t in e);return fa(t)||jv.call(e,t)},Kh=e=>{const t=HTMLElement;return e?t?e instanceof t:e.nodeType===BE:!1},sg=e=>{const t=Element;return e?t?e instanceof t:e.nodeType===BE:!1},sy=(e,t,n)=>e.indexOf(t,n),zt=(e,t,n)=>(!n&&!ni(t)&&og(t)?Array.prototype.push.apply(e,t):e.push(t),e),Wi=e=>{const t=Array.from,n=[];return t&&e?t(e):(e instanceof Set?e.forEach(r=>{zt(n,r)}):Dt(e,r=>{zt(n,r)}),n)},ay=e=>!!e&&e.length===0,js=(e,t,n)=>{Dt(e,o=>o&&o.apply(void 0,t||[])),!n&&(e.length=0)},ag=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),Vr=e=>e?Object.keys(e):[],un=(e,t,n,r,o,s,i)=>{const l=[t,n,r,o,s,i];return(typeof e!="object"||rg(e))&&!Go(e)&&(e={}),Dt(l,u=>{Dt(Vr(u),p=>{const h=u[p];if(e===h)return!0;const m=Ko(h);if(h&&(tx(h)||m)){const v=e[p];let x=v;m&&!Ko(v)?x=[]:!m&&!tx(v)&&(x={}),e[p]=un(x,h)}else e[p]=h})}),e},iy=e=>{for(const t in e)return!1;return!0},HE=(e,t,n,r)=>{if(fa(r))return n?n[e]:t;n&&(ni(r)||Va(r))&&(n[e]=r)},Jn=(e,t,n)=>{if(fa(n))return e?e.getAttribute(t):null;e&&e.setAttribute(t,n)},Cr=(e,t)=>{e&&e.removeAttribute(t)},Ii=(e,t,n,r)=>{if(n){const o=Jn(e,t)||"",s=new Set(o.split(" "));s[r?"add":"delete"](n);const i=Wi(s).join(" ").trim();Jn(e,t,i)}},wJ=(e,t,n)=>{const r=Jn(e,t)||"";return new Set(r.split(" ")).has(n)},zo=(e,t)=>HE("scrollLeft",0,e,t),Zs=(e,t)=>HE("scrollTop",0,e,t),nx=Hd()&&Element.prototype,VE=(e,t)=>{const n=[],r=t?sg(t)?t:null:document;return r?zt(n,r.querySelectorAll(e)):n},SJ=(e,t)=>{const n=t?sg(t)?t:null:document;return n?n.querySelector(e):null},qh=(e,t)=>sg(e)?(nx.matches||nx.msMatchesSelector).call(e,t):!1,ly=e=>e?Wi(e.childNodes):[],ra=e=>e?e.parentElement:null,Gl=(e,t)=>{if(sg(e)){const n=nx.closest;if(n)return n.call(e,t);do{if(qh(e,t))return e;e=ra(e)}while(e)}return null},kJ=(e,t,n)=>{const r=e&&Gl(e,t),o=e&&SJ(n,r),s=Gl(o,t)===r;return r&&o?r===e||o===e||s&&Gl(Gl(e,n),t)!==r:!1},cy=(e,t,n)=>{if(n&&e){let r=t,o;og(n)?(o=document.createDocumentFragment(),Dt(n,s=>{s===r&&(r=s.previousSibling),o.appendChild(s)})):o=n,t&&(r?r!==t&&(r=r.nextSibling):r=e.firstChild),e.insertBefore(o,r||null)}},lo=(e,t)=>{cy(e,null,t)},_J=(e,t)=>{cy(ra(e),e,t)},Ok=(e,t)=>{cy(ra(e),e&&e.nextSibling,t)},xs=e=>{if(og(e))Dt(Wi(e),t=>xs(t));else if(e){const t=ra(e);t&&t.removeChild(e)}},Ei=e=>{const t=document.createElement("div");return e&&Jn(t,"class",e),t},WE=e=>{const t=Ei();return t.innerHTML=e.trim(),Dt(ly(t),n=>xs(n))},rx=e=>e.charAt(0).toUpperCase()+e.slice(1),jJ=()=>Ei().style,PJ=["-webkit-","-moz-","-o-","-ms-"],IJ=["WebKit","Moz","O","MS","webkit","moz","o","ms"],Pv={},Iv={},EJ=e=>{let t=Iv[e];if(ag(Iv,e))return t;const n=rx(e),r=jJ();return Dt(PJ,o=>{const s=o.replace(/-/g,"");return!(t=[e,o+e,s+n,rx(s)+n].find(l=>r[l]!==void 0))}),Iv[e]=t||""},Vd=e=>{if(Hd()){let t=Pv[e]||window[e];return ag(Pv,e)||(Dt(IJ,n=>(t=t||window[n+rx(e)],!t)),Pv[e]=t),t}},MJ=Vd("MutationObserver"),Dk=Vd("IntersectionObserver"),Kl=Vd("ResizeObserver"),UE=Vd("cancelAnimationFrame"),G
|
||
|
* @license React
|
||
|
* react-reconciler.production.min.js
|
||
|
*
|
||
|
* Copyright (c) Facebook, Inc. and its affiliates.
|
||
|
*
|
||
|
* This source code is licensed under the MIT license found in the
|
||
|
* LICENSE file in the root directory of this source tree.
|
||
|
*/var the=function(t){var n={},r=d,o=Ip,s=Object.assign;function i(c){for(var f="https://reactjs.org/docs/error-decoder.html?invariant="+c,g=1;g<arguments.length;g++)f+="&args[]="+encodeURIComponent(arguments[g]);return"Minified React error #"+c+"; visit "+f+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}var l=r.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED,u=Symbol.for("react.element"),p=Symbol.for("react.portal"),h=Symbol.for("react.fragment"),m=Symbol.for("react.strict_mode"),v=Symbol.for("react.profiler"),x=Symbol.for("react.provider"),y=Symbol.for("react.context"),b=Symbol.for("react.forward_ref"),w=Symbol.for("react.suspense"),k=Symbol.for("react.suspense_list"),_=Symbol.for("react.memo"),j=Symbol.for("react.lazy"),I=Symbol.for("react.offscreen"),M=Symbol.iterator;function E(c){return c===null||typeof c!="object"?null:(c=M&&c[M]||c["@@iterator"],typeof c=="function"?c:null)}function O(c){if(c==null)return null;if(typeof c=="function")return c.displayName||c.name||null;if(typeof c=="string")return c;switch(c){case h:return"Fragment";case p:return"Portal";case v:return"Profiler";case m:return"StrictMode";case w:return"Suspense";case k:return"SuspenseList"}if(typeof c=="object")switch(c.$$typeof){case y:return(c.displayName||"Context")+".Consumer";case x:return(c._context.displayName||"Context")+".Provider";case b:var f=c.render;return c=c.displayName,c||(c=f.displayName||f.name||"",c=c!==""?"ForwardRef("+c+")":"ForwardRef"),c;case _:return f=c.displayName||null,f!==null?f:O(c.type)||"Memo";case j:f=c._payload,c=c._init;try{return O(c(f))}catch{}}return null}function D(c){var f=c.type;switch(c.tag){case 24:return"Cache";case 9:return(f.displayName||"Context")+".Consumer";case 10:return(f._context.displayName||"Context")+".Provider";case 18:return"DehydratedFragment";case 11:return c=f.render,c=c.displayName||c.name||"",f.displayName||(c!==""?"ForwardRef("+c+")":"ForwardRef");case 7:return"Fragment";case 5:return f;case 4:return"Portal";case 3:return"Root";case 6:return"Text";case 16:return O(f);case 8:return f===m?"StrictMode":"Mode";case 22:return"Offscreen";case 12:return"Profiler";case 21:return"Scope";case 13:return"Suspense";case 19:return"SuspenseList";case 25:return"TracingMarker";case 1:case 0:case 17:case 2:case 14:case 15:if(typeof f=="function")return f.displayName||f.name||null;if(typeof f=="string")return f}return null}function A(c){var f=c,g=c;if(c.alternate)for(;f.return;)f=f.return;else{c=f;do f=c,f.flags&4098&&(g=f.return),c=f.return;while(c)}return f.tag===3?g:null}function R(c){if(A(c)!==c)throw Error(i(188))}function T(c){var f=c.alternate;if(!f){if(f=A(c),f===null)throw Error(i(188));return f!==c?null:c}for(var g=c,C=f;;){var S=g.return;if(S===null)break;var P=S.alternate;if(P===null){if(C=S.return,C!==null){g=C;continue}break}if(S.child===P.child){for(P=S.child;P;){if(P===g)return R(S),c;if(P===C)return R(S),f;P=P.sibling}throw Error(i(188))}if(g.return!==C.return)g=S,C=P;else{for(var N=!1,Z=S.child;Z;){if(Z===g){N=!0,g=S,C=P;break}if(Z===C){N=!0,C=S,g=P;break}Z=Z.sibling}if(!N){for(Z=P.child;Z;){if(Z===g){N=!0,g=P,C=S;break}if(Z===C){N=!0,C=P,g=S;break}Z=Z.sibling}if(!N)throw Error(i(189))}}if(g.alternate!==C)throw Error(i(190))}if(g.tag!==3)throw Error(i(188));return g.stateNode.current===g?c:f}function X(c){return c=T(c),c!==null?B(c):null}function B(c){if(c.tag===5||c.tag===6)return c;for(c=c.child;c!==null;){var f=B(c);if(f!==null)return f;c=c.sibling}return null}function U(c){if(c.tag===5||c.tag===6)return c;for(c=c.child;c!==null;){if(c.tag!==4){var f=U(c);if(f!==null)return f}c=c.sibling}return null}var Y=Array.isArray,V=t.getPublicInstance,L=t.getRootHostContext,q=t.getChildHostContext,z=t.prepareForCommit,K=t.resetAfterCommit,re=t.createInstance,Q=t.appendInitialChild,le=t.finalizeInitialChildren,se=t.prepareUpdate,W=t.shouldSetTextContent,G=t.createTextInstance,te=t.scheduleTimeout,ae=t.cancelTimeout,oe=t.noTimeout,pe=t.isPrimaryRenderer,fe=t.supportsMutation,ge=t.supportsPersistence,Ce=t.supportsHydration,me=t.ge
|
||
|
`+Yc+c}var Qc=!1;function Zc(c,f){if(!c||Qc)return"";Qc=!0;var g=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{if(f)if(f=function(){throw Error()},Object.defineProperty(f.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(f,[])}catch(Ee){var C=Ee}Reflect.construct(c,[],f)}else{try{f.call()}catch(Ee){C=Ee}c.call(f.prototype)}else{try{throw Error()}catch(Ee){C=Ee}c()}}catch(Ee){if(Ee&&C&&typeof Ee.stack=="string"){for(var S=Ee.stack.split(`
|
||
|
`),P=C.stack.split(`
|
||
|
`),N=S.length-1,Z=P.length-1;1<=N&&0<=Z&&S[N]!==P[Z];)Z--;for(;1<=N&&0<=Z;N--,Z--)if(S[N]!==P[Z]){if(N!==1||Z!==1)do if(N--,Z--,0>Z||S[N]!==P[Z]){var ue=`
|
||
|
`+S[N].replace(" at new "," at ");return c.displayName&&ue.includes("<anonymous>")&&(ue=ue.replace("<anonymous>",c.displayName)),ue}while(1<=N&&0<=Z);break}}}finally{Qc=!1,Error.prepareStackTrace=g}return(c=c?c.displayName||c.name:"")?ai(c):""}var Ag=Object.prototype.hasOwnProperty,va=[],Je=-1;function St(c){return{current:c}}function bt(c){0>Je||(c.current=va[Je],va[Je]=null,Je--)}function kt(c,f){Je++,va[Je]=c.current,c.current=f}var Kn={},Wt=St(Kn),kn=St(!1),lr=Kn;function ul(c,f){var g=c.type.contextTypes;if(!g)return Kn;var C=c.stateNode;if(C&&C.__reactInternalMemoizedUnmaskedChildContext===f)return C.__reactInternalMemoizedMaskedChildContext;var S={},P;for(P in g)S[P]=f[P];return C&&(c=c.stateNode,c.__reactInternalMemoizedUnmaskedChildContext=f,c.__reactInternalMemoizedMaskedChildContext=S),S}function gr(c){return c=c.childContextTypes,c!=null}function Yd(){bt(kn),bt(Wt)}function Qy(c,f,g){if(Wt.current!==Kn)throw Error(i(168));kt(Wt,f),kt(kn,g)}function Zy(c,f,g){var C=c.stateNode;if(f=f.childContextTypes,typeof C.getChildContext!="function")return g;C=C.getChildContext();for(var S in C)if(!(S in f))throw Error(i(108,D(c)||"Unknown",S));return s({},g,C)}function Qd(c){return c=(c=c.stateNode)&&c.__reactInternalMemoizedMergedChildContext||Kn,lr=Wt.current,kt(Wt,c),kt(kn,kn.current),!0}function Jy(c,f,g){var C=c.stateNode;if(!C)throw Error(i(169));g?(c=Zy(c,f,lr),C.__reactInternalMemoizedMergedChildContext=c,bt(kn),bt(Wt),kt(Wt,c)):bt(kn),kt(kn,g)}var Co=Math.clz32?Math.clz32:C8,b8=Math.log,y8=Math.LN2;function C8(c){return c>>>=0,c===0?32:31-(b8(c)/y8|0)|0}var Zd=64,Jd=4194304;function Jc(c){switch(c&-c){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return c&4194240;case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:return c&130023424;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 1073741824;default:return c}}function ef(c,f){var g=c.pendingLanes;if(g===0)return 0;var C=0,S=c.suspendedLanes,P=c.pingedLanes,N=g&268435455;if(N!==0){var Z=N&~S;Z!==0?C=Jc(Z):(P&=N,P!==0&&(C=Jc(P)))}else N=g&~S,N!==0?C=Jc(N):P!==0&&(C=Jc(P));if(C===0)return 0;if(f!==0&&f!==C&&!(f&S)&&(S=C&-C,P=f&-f,S>=P||S===16&&(P&4194240)!==0))return f;if(C&4&&(C|=g&16),f=c.entangledLanes,f!==0)for(c=c.entanglements,f&=C;0<f;)g=31-Co(f),S=1<<g,C|=c[g],f&=~S;return C}function w8(c,f){switch(c){case 1:case 2:case 4:return f+250;case 8:case 16:case 32:case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return f+5e3;case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:return-1;case 134217728:case 268435456:case 536870912:case 1073741824:return-1;default:return-1}}function S8(c,f){for(var g=c.suspendedLanes,C=c.pingedLanes,S=c.expirationTimes,P=c.pendingLanes;0<P;){var N=31-Co(P),Z=1<<N,ue=S[N];ue===-1?(!(Z&g)||Z&C)&&(S[N]=w8(Z,f)):ue<=f&&(c.expiredLanes|=Z),P&=~Z}}function Ng(c){return c=c.pendingLanes&-1073741825,c!==0?c:c&1073741824?1073741824:0}function e2(){var c=Zd;return Zd<<=1,!(Zd&4194240)&&(Zd=64),c}function Tg(c){for(var f=[],g=0;31>g;g++)f.push(c);return f}function eu(c,f,g){c.pendingLanes|=f,f!==536870912&&(c.suspendedLanes=0,c.pingedLanes=0),c=c.eventTimes,f=31-Co(f),c[f]=g}function k8(c,f){var g=c.pendingLanes&~f;c.pendingLanes=f,c.suspendedLanes=0,c.pingedLanes=0,c.expiredLanes&=f,c.mutableReadLanes&=f,c.entangledLanes&=f,f=c.entanglements;var C=c.eventTimes;for(c=c.expirationTimes;0<g;){var S=31-Co(g),P=1<<S;f[S]=0,C[S]=-1,c[S]=-1,g&=~P}}function $g(c,f){var g=c.entangledLanes|=f;for(c=c.entanglements;g;){var C=31-Co(g),S=1<<C;S&f|c[C]&f&&(c[C]|=f),g&=~S}}var Et=0;function t2(c){return c&=-c,1<c?4<c?c&268435455?16:536870912:4:1}var Lg=o.unstable_scheduleCallback,n2=o.unstable_cancelCallback,_8=o.unsta
|
||
|
Error generating stack: `+P.message+`
|
||
|
`+P.stack}return{value:c,source:f,stack:S,digest:null}}function p0(c,f,g){return{value:c,source:null,stack:g??null,digest:f??null}}function h0(c,f){try{console.error(f.value)}catch(g){setTimeout(function(){throw g})}}var B8=typeof WeakMap=="function"?WeakMap:Map;function V2(c,f,g){g=As(-1,g),g.tag=3,g.payload={element:null};var C=f.value;return g.callback=function(){Rf||(Rf=!0,A0=C),h0(c,f)},g}function W2(c,f,g){g=As(-1,g),g.tag=3;var C=c.type.getDerivedStateFromError;if(typeof C=="function"){var S=f.value;g.payload=function(){return C(S)},g.callback=function(){h0(c,f)}}var P=c.stateNode;return P!==null&&typeof P.componentDidCatch=="function"&&(g.callback=function(){h0(c,f),typeof C!="function"&&(ya===null?ya=new Set([this]):ya.add(this));var N=f.stack;this.componentDidCatch(f.value,{componentStack:N!==null?N:""})}),g}function U2(c,f,g){var C=c.pingCache;if(C===null){C=c.pingCache=new B8;var S=new Set;C.set(f,S)}else S=C.get(f),S===void 0&&(S=new Set,C.set(f,S));S.has(g)||(S.add(g),c=t7.bind(null,c,f,g),f.then(c,c))}function G2(c){do{var f;if((f=c.tag===13)&&(f=c.memoizedState,f=f!==null?f.dehydrated!==null:!0),f)return c;c=c.return}while(c!==null);return null}function K2(c,f,g,C,S){return c.mode&1?(c.flags|=65536,c.lanes=S,c):(c===f?c.flags|=65536:(c.flags|=128,g.flags|=131072,g.flags&=-52805,g.tag===1&&(g.alternate===null?g.tag=17:(f=As(-1,1),f.tag=2,ba(g,f,1))),g.lanes|=1),c)}var H8=l.ReactCurrentOwner,vr=!1;function cr(c,f,g,C){f.child=c===null?y2(f,null,g,C):gl(f,c.child,g,C)}function q2(c,f,g,C,S){g=g.render;var P=f.ref;return ml(f,S),C=i0(c,f,g,C,P,S),g=l0(),c!==null&&!vr?(f.updateQueue=c.updateQueue,f.flags&=-2053,c.lanes&=~S,Ns(c,f,S)):(Zt&&g&&Hg(f),f.flags|=1,cr(c,f,C,S),f.child)}function X2(c,f,g,C,S){if(c===null){var P=g.type;return typeof P=="function"&&!F0(P)&&P.defaultProps===void 0&&g.compare===null&&g.defaultProps===void 0?(f.tag=15,f.type=P,Y2(c,f,P,C,S)):(c=zf(g.type,null,C,f,f.mode,S),c.ref=f.ref,c.return=f,f.child=c)}if(P=c.child,!(c.lanes&S)){var N=P.memoizedProps;if(g=g.compare,g=g!==null?g:af,g(N,C)&&c.ref===f.ref)return Ns(c,f,S)}return f.flags|=1,c=ka(P,C),c.ref=f.ref,c.return=f,f.child=c}function Y2(c,f,g,C,S){if(c!==null){var P=c.memoizedProps;if(af(P,C)&&c.ref===f.ref)if(vr=!1,f.pendingProps=C=P,(c.lanes&S)!==0)c.flags&131072&&(vr=!0);else return f.lanes=c.lanes,Ns(c,f,S)}return m0(c,f,g,C,S)}function Q2(c,f,g){var C=f.pendingProps,S=C.children,P=c!==null?c.memoizedState:null;if(C.mode==="hidden")if(!(f.mode&1))f.memoizedState={baseLanes:0,cachePool:null,transitions:null},kt(Cl,Nr),Nr|=g;else{if(!(g&1073741824))return c=P!==null?P.baseLanes|g:g,f.lanes=f.childLanes=1073741824,f.memoizedState={baseLanes:c,cachePool:null,transitions:null},f.updateQueue=null,kt(Cl,Nr),Nr|=c,null;f.memoizedState={baseLanes:0,cachePool:null,transitions:null},C=P!==null?P.baseLanes:g,kt(Cl,Nr),Nr|=C}else P!==null?(C=P.baseLanes|g,f.memoizedState=null):C=g,kt(Cl,Nr),Nr|=C;return cr(c,f,S,g),f.child}function Z2(c,f){var g=f.ref;(c===null&&g!==null||c!==null&&c.ref!==g)&&(f.flags|=512,f.flags|=2097152)}function m0(c,f,g,C,S){var P=gr(g)?lr:Wt.current;return P=ul(f,P),ml(f,S),g=i0(c,f,g,C,P,S),C=l0(),c!==null&&!vr?(f.updateQueue=c.updateQueue,f.flags&=-2053,c.lanes&=~S,Ns(c,f,S)):(Zt&&C&&Hg(f),f.flags|=1,cr(c,f,g,S),f.child)}function J2(c,f,g,C,S){if(gr(g)){var P=!0;Qd(f)}else P=!1;if(ml(f,S),f.stateNode===null)Cf(c,f),g2(f,g,C),e0(f,g,C,S),C=!0;else if(c===null){var N=f.stateNode,Z=f.memoizedProps;N.props=Z;var ue=N.context,Ee=g.contextType;typeof Ee=="object"&&Ee!==null?Ee=Xr(Ee):(Ee=gr(g)?lr:Wt.current,Ee=ul(f,Ee));var Ke=g.getDerivedStateFromProps,pt=typeof Ke=="function"||typeof N.getSnapshotBeforeUpdate=="function";pt||typeof N.UNSAFE_componentWillReceiveProps!="function"&&typeof N.componentWillReceiveProps!="function"||(Z!==C||ue!==Ee)&&v2(f,N,C,Ee),xa=!1;var He=f.memoizedState;N.state=He,df(f,C,N,S),ue=f.memoizedState,Z!==C||He!==ue||kn.current||xa?(typeof Ke=="function"&&(Jg(f,g,Ke,C),ue=f.memoizedState),(Z=xa||m2(f,g,Z,C,He,ue,Ee))?(pt||typeof N.UNSAFE_componentWillMount!="function"&&typeof N.componentWillMo
|
||
|
`+(C.join(" > ")+`
|
||
|
|
||
|
No matching component was found for:
|
||
|
`)+c.join(" > ")}return null},n.getPublicRootInstance=function(c){if(c=c.current,!c.child)return null;switch(c.child.tag){case 5:return V(c.child.stateNode);default:return c.child.stateNode}},n.injectIntoDevTools=function(c){if(c={bundleType:c.bundleType,version:c.version,rendererPackageName:c.rendererPackageName,rendererConfig:c.rendererConfig,overrideHookState:null,overrideHookStateDeletePath:null,overrideHookStateRenamePath:null,overrideProps:null,overridePropsDeletePath:null,overridePropsRenamePath:null,setErrorHandler:null,setSuspenseHandler:null,scheduleUpdate:null,currentDispatcherRef:l.ReactCurrentDispatcher,findHostInstanceByFiber:i7,findFiberByHostInstance:c.findFiberByHostInstance||l7,findHostInstancesForRefresh:null,scheduleRefresh:null,scheduleRoot:null,setRefreshHandler:null,getCurrentFiber:null,reconcilerVersion:"18.2.0"},typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u")c=!1;else{var f=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(f.isDisabled||!f.supportsFiber)c=!0;else{try{tf=f.inject(c),Yo=f}catch{}c=!!f.checkDCE}}return c},n.isAlreadyRendering=function(){return!1},n.observeVisibleRects=function(c,f,g,C){if(!Ue)throw Error(i(363));c=E0(c,f);var S=mt(c,g,C).disconnect;return{disconnect:function(){S()}}},n.registerMutableSourceForHydration=function(c,f){var g=f._getVersion;g=g(f._source),c.mutableSourceEagerHydrationData==null?c.mutableSourceEagerHydrationData=[f,g]:c.mutableSourceEagerHydrationData.push(f,g)},n.runWithPriority=function(c,f){var g=Et;try{return Et=c,f()}finally{Et=g}},n.shouldError=function(){return null},n.shouldSuspend=function(){return!1},n.updateContainer=function(c,f,g,C){var S=f.current,P=Qn(),N=wa(S);return g=MC(g),f.context===null?f.context=g:f.pendingContext=g,f=As(P,N),f.payload={element:c},C=C===void 0?null:C,C!==null&&(f.callback=C),c=ba(S,f,N),c!==null&&(Zr(c,S,N,P),uf(c,S,N)),N},n};i8.exports=the;var nhe=i8.exports;const rhe=Dc(nhe);var l8={exports:{}},al={};/**
|
||
|
* @license React
|
||
|
* react-reconciler-constants.production.min.js
|
||
|
*
|
||
|
* Copyright (c) Facebook, Inc. and its affiliates.
|
||
|
*
|
||
|
* This source code is licensed under the MIT license found in the
|
||
|
* LICENSE file in the root directory of this source tree.
|
||
|
*/al.ConcurrentRoot=1;al.ContinuousEventPriority=4;al.DefaultEventPriority=16;al.DiscreteEventPriority=1;al.IdleEventPriority=536870912;al.LegacyRoot=0;l8.exports=al;var c8=l8.exports;const cj={children:!0,ref:!0,key:!0,style:!0,forwardedRef:!0,unstable_applyCache:!0,unstable_applyDrawHitFromCache:!0};let uj=!1,dj=!1;const qy=".react-konva-event",ohe=`ReactKonva: You have a Konva node with draggable = true and position defined but no onDragMove or onDragEnd events are handled.
|
||
|
Position of a node will be changed during drag&drop, so you should update state of the react app as well.
|
||
|
Consider to add onDragMove or onDragEnd events.
|
||
|
For more info see: https://github.com/konvajs/react-konva/issues/256
|
||
|
`,she=`ReactKonva: You are using "zIndex" attribute for a Konva node.
|
||
|
react-konva may get confused with ordering. Just define correct order of elements in your render function of a component.
|
||
|
For more info see: https://github.com/konvajs/react-konva/issues/194
|
||
|
`,ahe={};function Og(e,t,n=ahe){if(!uj&&"zIndex"in t&&(console.warn(she),uj=!0),!dj&&t.draggable){var r=t.x!==void 0||t.y!==void 0,o=t.onDragEnd||t.onDragMove;r&&!o&&(console.warn(ohe),dj=!0)}for(var s in n)if(!cj[s]){var i=s.slice(0,2)==="on",l=n[s]!==t[s];if(i&&l){var u=s.substr(2).toLowerCase();u.substr(0,7)==="content"&&(u="content"+u.substr(7,1).toUpperCase()+u.substr(8)),e.off(u,n[s])}var p=!t.hasOwnProperty(s);p&&e.setAttr(s,void 0)}var h=t._useStrictMode,m={},v=!1;const x={};for(var s in t)if(!cj[s]){var i=s.slice(0,2)==="on",y=n[s]!==t[s];if(i&&y){var u=s.substr(2).toLowerCase();u.substr(0,7)==="content"&&(u="content"+u.substr(7,1).toUpperCase()+u.substr(8)),t[s]&&(x[u]=t[s])}!i&&(t[s]!==n[s]||h&&t[s]!==e.getAttr(s))&&(v=!0,m[s]=t[s])}v&&(e.setAttrs(m),si(e));for(var u in x)e.on(u+qy,x[u])}function si(e){if(!i9.Konva.autoDrawEnabled){var t=e.getLayer()||e.getStage();t&&t.batchDraw()}}const u8={},ihe={};dd.Node.prototype._applyProps=Og;function lhe(e,t){if(typeof t=="string"){console.error(`Do not use plain text as child of Konva.Node. You are using text: ${t}`);return}e.add(t),si(e)}function che(e,t,n){let r=dd[e];r||(console.error(`Konva has no node with the type ${e}. Group will be used instead. If you use minimal version of react-konva, just import required nodes into Konva: "import "konva/lib/shapes/${e}" If you want to render DOM elements as part of canvas tree take a look into this demo: https://konvajs.github.io/docs/react/DOM_Portal.html`),r=dd.Group);const o={},s={};for(var i in t){var l=i.slice(0,2)==="on";l?s[i]=t[i]:o[i]=t[i]}const u=new r(o);return Og(u,s),u}function uhe(e,t,n){console.error(`Text components are not supported for now in ReactKonva. Your text is: "${e}"`)}function dhe(e,t,n){return!1}function fhe(e){return e}function phe(){return null}function hhe(){return null}function mhe(e,t,n,r){return ihe}function ghe(){}function vhe(e){}function xhe(e,t){return!1}function bhe(){return u8}function yhe(){return u8}const Che=setTimeout,whe=clearTimeout,She=-1;function khe(e,t){return!1}const _he=!1,jhe=!0,Phe=!0;function Ihe(e,t){t.parent===e?t.moveToTop():e.add(t),si(e)}function Ehe(e,t){t.parent===e?t.moveToTop():e.add(t),si(e)}function d8(e,t,n){t._remove(),e.add(t),t.setZIndex(n.getZIndex()),si(e)}function Mhe(e,t,n){d8(e,t,n)}function Ohe(e,t){t.destroy(),t.off(qy),si(e)}function Dhe(e,t){t.destroy(),t.off(qy),si(e)}function Rhe(e,t,n){console.error(`Text components are not yet supported in ReactKonva. You text is: "${n}"`)}function Ahe(e,t,n){}function Nhe(e,t,n,r,o){Og(e,o,r)}function The(e){e.hide(),si(e)}function $he(e){}function Lhe(e,t){(t.visible==null||t.visible)&&e.show()}function zhe(e,t){}function Fhe(e){}function Bhe(){}const Hhe=()=>c8.DefaultEventPriority,Vhe=Object.freeze(Object.defineProperty({__proto__:null,appendChild:Ihe,appendChildToContainer:Ehe,appendInitialChild:lhe,cancelTimeout:whe,clearContainer:Fhe,commitMount:Ahe,commitTextUpdate:Rhe,commitUpdate:Nhe,createInstance:che,createTextInstance:uhe,detachDeletedInstance:Bhe,finalizeInitialChildren:dhe,getChildHostContext:yhe,getCurrentEventPriority:Hhe,getPublicInstance:fhe,getRootHostContext:bhe,hideInstance:The,hideTextInstance:$he,idlePriority:Ip.unstable_IdlePriority,insertBefore:d8,insertInContainerBefore:Mhe,isPrimaryRenderer:_he,noTimeout:She,now:Ip.unstable_now,prepareForCommit:phe,preparePortalMount:hhe,prepareUpdate:mhe,removeChild:Ohe,removeChildFromContainer:Dhe,resetAfterCommit:ghe,resetTextContent:vhe,run:Ip.unstable_runWithPriority,scheduleTimeout:Che,shouldDeprioritizeSubtree:xhe,shouldSetTextContent:khe,supportsMutation:Phe,unhideInstance:Lhe,unhideTextInstance:zhe,warnsIfNotActing:jhe},Symbol.toStringTag,{value:"Module"}));var Whe=Object.defineProperty,Uhe=Object.defineProperties,Ghe=Object.getOwnPropertyDescriptors,fj=Object.getOwnPropertySymbols,Khe=Object.prototype.hasOwnProperty,qhe=Object.prototype.propertyIsEnumerable,pj=(e,t,n)=>t in e?Whe(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,hj=(e,t)=>{for(var n in t||(t={}))Khe.call(t,n)&&pj(e,n,t[n]);if(fj)for(var n of fj(t))qhe.cal
|
||
|
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
|
||
|
<svg width="60px" height="60px" viewBox="0 0 30 30" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" xml:space="preserve" xmlns:serif="http://www.serif.com/" style="fill-rule:evenodd;clip-rule:evenodd;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:1.5;">
|
||
|
<g transform="matrix(0.5,0,0,0.5,0,0)">
|
||
|
<path d="M-3.5,63.5L64,-4" style="fill:none;stroke:black;stroke-width:1px;"/>
|
||
|
</g>
|
||
|
<g transform="matrix(0.5,0,0,0.5,0,2.5)">
|
||
|
<path d="M-3.5,63.5L64,-4" style="fill:none;stroke:black;stroke-width:1px;"/>
|
||
|
</g>
|
||
|
<g transform="matrix(0.5,0,0,0.5,0,5)">
|
||
|
<path d="M-3.5,63.5L64,-4" style="fill:none;stroke:black;stroke-width:1px;"/>
|
||
|
</g>
|
||
|
<g transform="matrix(0.5,0,0,0.5,0,7.5)">
|
||
|
<path d="M-3.5,63.5L64,-4" style="fill:none;stroke:black;stroke-width:1px;"/>
|
||
|
</g>
|
||
|
<g transform="matrix(0.5,0,0,0.5,0,10)">
|
||
|
<path d="M-3.5,63.5L64,-4" style="fill:none;stroke:black;stroke-width:1px;"/>
|
||
|
</g>
|
||
|
<g transform="matrix(0.5,0,0,0.5,0,12.5)">
|
||
|
<path d="M-3.5,63.5L64,-4" style="fill:none;stroke:black;stroke-width:1px;"/>
|
||
|
</g>
|
||
|
<g transform="matrix(0.5,0,0,0.5,0,15)">
|
||
|
<path d="M-3.5,63.5L64,-4" style="fill:none;stroke:black;stroke-width:1px;"/>
|
||
|
</g>
|
||
|
<g transform="matrix(0.5,0,0,0.5,0,17.5)">
|
||
|
<path d="M-3.5,63.5L64,-4" style="fill:none;stroke:black;stroke-width:1px;"/>
|
||
|
</g>
|
||
|
<g transform="matrix(0.5,0,0,0.5,0,20)">
|
||
|
<path d="M-3.5,63.5L64,-4" style="fill:none;stroke:black;stroke-width:1px;"/>
|
||
|
</g>
|
||
|
<g transform="matrix(0.5,0,0,0.5,0,22.5)">
|
||
|
<path d="M-3.5,63.5L64,-4" style="fill:none;stroke:black;stroke-width:1px;"/>
|
||
|
</g>
|
||
|
<g transform="matrix(0.5,0,0,0.5,0,25)">
|
||
|
<path d="M-3.5,63.5L64,-4" style="fill:none;stroke:black;stroke-width:1px;"/>
|
||
|
</g>
|
||
|
<g transform="matrix(0.5,0,0,0.5,0,27.5)">
|
||
|
<path d="M-3.5,63.5L64,-4" style="fill:none;stroke:black;stroke-width:1px;"/>
|
||
|
</g>
|
||
|
<g transform="matrix(0.5,0,0,0.5,0,30)">
|
||
|
<path d="M-3.5,63.5L64,-4" style="fill:none;stroke:black;stroke-width:1px;"/>
|
||
|
</g>
|
||
|
<g transform="matrix(0.5,0,0,0.5,0,-2.5)">
|
||
|
<path d="M-3.5,63.5L64,-4" style="fill:none;stroke:black;stroke-width:1px;"/>
|
||
|
</g>
|
||
|
<g transform="matrix(0.5,0,0,0.5,0,-5)">
|
||
|
<path d="M-3.5,63.5L64,-4" style="fill:none;stroke:black;stroke-width:1px;"/>
|
||
|
</g>
|
||
|
<g transform="matrix(0.5,0,0,0.5,0,-7.5)">
|
||
|
<path d="M-3.5,63.5L64,-4" style="fill:none;stroke:black;stroke-width:1px;"/>
|
||
|
</g>
|
||
|
<g transform="matrix(0.5,0,0,0.5,0,-10)">
|
||
|
<path d="M-3.5,63.5L64,-4" style="fill:none;stroke:black;stroke-width:1px;"/>
|
||
|
</g>
|
||
|
<g transform="matrix(0.5,0,0,0.5,0,-12.5)">
|
||
|
<path d="M-3.5,63.5L64,-4" style="fill:none;stroke:black;stroke-width:1px;"/>
|
||
|
</g>
|
||
|
<g transform="matrix(0.5,0,0,0.5,0,-15)">
|
||
|
<path d="M-3.5,63.5L64,-4" style="fill:none;stroke:black;stroke-width:1px;"/>
|
||
|
</g>
|
||
|
<g transform="matrix(0.5,0,0,0.5,0,-17.5)">
|
||
|
<path d="M-3.5,63.5L64,-4" style="fill:none;stroke:black;stroke-width:1px;"/>
|
||
|
</g>
|
||
|
<g transform="matrix(0.5,0,0,0.5,0,-20)">
|
||
|
<path d="M-3.5,63.5L64,-4" style="fill:none;stroke:black;stroke-width:1px;"/>
|
||
|
</g>
|
||
|
<g transform="matrix(0.5,0,0,0.5,0,-22.5)">
|
||
|
<path d="M-3.5,63.5L64,-4" style="fill:none;stroke:black;stroke-width:1px;"/>
|
||
|
</g>
|
||
|
<g transform="matrix(0.5,0,0,0.5,0,-25)">
|
||
|
<path d="M-3.5,63.5L64,-4" style="fill:none;stroke:black;stroke-width:1px;"/>
|
||
|
</g>
|
||
|
<g transform="matrix(0.5,0,0,0.5,0,-27.5)">
|
||
|
<path d="M-3.5,63.5L64,-4" style="fill:none;stroke:black;stroke-width:1px;"/>
|
||
|
</g>
|
||
|
<g transform="matrix(0.5,0,0,0.5,0,-30)">
|
||
|
<path d="M-3.5,63.5L64,-4" style="fill:none;stroke:black;stroke-width:1px;"/>
|
||
|
</g>
|
||
|
</svg>`.replaceAll("black",e),jme=e=>{const{...t}=e,{maskColorString:n,stageCoordinates:r,stageDimensions:o,stageScale:s}=F(_me),[i,l]=d.useState(null),[u,p]=d.useState(0),h=d.useRef(null),m=d.useCallback(()=>{p(u+1),setTimeout(m,500)},[u]);return d.useEffect(()=>{if(i)return;const v=new Image;v.onload=()=>{l(v)},v.src=vj(n)},[i,n]),d.useEffect(()=>{i&&(i.src=vj(n))},[i,n]),d.useEffect(()=>{const v=setInterval(()=>p(x=>(x+1)%5),50);return()=>clearInterval(v)},[]),!i||!Sl(r.x)||!Sl(r.y)||!Sl(s)||!Sl(o.width)||!Sl(o.height)?null:a.jsx(ks,{ref:h,offsetX:r.x/s,offsetY:r.y/s,height:o.height/s,width:o.width/s,fillPatternImage:i,fillPatternOffsetY:Sl(u)?u:0,fillPatternRepeat:"repeat",fillPatternScale:{x:1/s,y:1/s},listening:!0,globalCompositeOperation:"source-in",...t})},Pme=d.memo(jme),Ime=ie([Lt],e=>({objects:e.layerState.objects}),{memoizeOptions:{resultEqualityCheck:_t}}),Eme=e=>{const{...t}=e,{objects:n}=F(Ime);return a.jsx(sa,{listening:!1,...t,children:n.filter(y9).map((r,o)=>a.jsx(lm,{points:r.points,stroke:"rgb(0,0,0)",strokeWidth:r.strokeWidth*2,tension:0,lineCap:"round",lineJoin:"round",shadowForStrokeEnabled:!1,listening:!1,globalCompositeOperation:r.tool==="brush"?"source-over":"destination-out"},o))})},Mme=d.memo(Eme);var xi=d,Ome=function(t,n,r){const o=xi.useRef("loading"),s=xi.useRef(),[i,l]=xi.useState(0),u=xi.useRef(),p=xi.useRef(),h=xi.useRef();return(u.current!==t||p.current!==n||h.current!==r)&&(o.current="loading",s.current=void 0,u.current=t,p.current=n,h.current=r),xi.useLayoutEffect(function(){if(!t)return;var m=document.createElement("img");function v(){o.current="loaded",s.current=m,l(Math.random())}function x(){o.current="failed",s.current=void 0,l(Math.random())}return m.addEventListener("load",v),m.addEventListener("error",x),n&&(m.crossOrigin=n),r&&(m.referrerPolicy=r),m.src=t,function(){m.removeEventListener("load",v),m.removeEventListener("error",x)}},[t,n,r]),[s.current,o.current]};const Dme=Dc(Ome),Rme=e=>{const{width:t,height:n,x:r,y:o,imageName:s}=e.canvasImage,{currentData:i,isError:l}=po(s??Fr.skipToken),[u]=Dme((i==null?void 0:i.image_url)??"",C9.get()?"use-credentials":"anonymous");return l?a.jsx(ks,{x:r,y:o,width:t,height:n,fill:"red"}):a.jsx(m8,{x:r,y:o,image:u,listening:!1})},v8=d.memo(Rme),Ame=ie([Lt],e=>{const{layerState:{objects:t}}=e;return{objects:t}},{memoizeOptions:{resultEqualityCheck:_t}}),Nme=()=>{const{objects:e}=F(Ame);return e?a.jsx(sa,{name:"outpainting-objects",listening:!1,children:e.map((t,n)=>{if(w9(t))return a.jsx(v8,{canvasImage:t},n);if(S9(t)){const r=a.jsx(lm,{points:t.points,stroke:t.color?Di(t.color):"rgb(0,0,0)",strokeWidth:t.strokeWidth*2,tension:0,lineCap:"round",lineJoin:"round",shadowForStrokeEnabled:!1,listening:!1,globalCompositeOperation:t.tool==="brush"?"source-over":"destination-out"},n);return t.clip?a.jsx(sa,{clipX:t.clip.x,clipY:t.clip.y,clipWidth:t.clip.width,clipHeight:t.clip.height,children:r},n):r}else{if(k9(t))return a.jsx(ks,{x:t.x,y:t.y,width:t.width,height:t.height,fill:Di(t.color)},n);if(_9(t))return a.jsx(ks,{x:t.x,y:t.y,width:t.width,height:t.height,fill:"rgb(255, 255, 255)",globalCompositeOperation:"destination-out"},n)}})}):null},Tme=d.memo(Nme),$me=ie([Lt],e=>{const{layerState:t,shouldShowStagingImage:n,shouldShowStagingOutline:r,boundingBoxCoordinates:{x:o,y:s},boundingBoxDimensions:{width:i,height:l}}=e,{selectedImageIndex:u,images:p}=t.stagingArea;return{currentStagingAreaImage:p.length>0&&u!==void 0?p[u]:void 0,isOnFirstImage:u===0,isOnLastImage:u===p.length-1,shouldShowStagingImage:n,shouldShowStagingOutline:r,x:o,y:s,width:i,height:l}},{memoizeOptions:{resultEqualityCheck:_t}}),Lme=e=>{const{...t}=e,{currentStagingAreaImage:n,shouldShowStagingImage:r,shouldShowStagingOutline:o,x:s,y:i,width:l,height:u}=F($me);return a.jsxs(sa,{...t,children:[r&&n&&a.jsx(v8,{canvasImage:n}),o&&a.jsxs(sa,{children:[a.jsx(ks,{x:s,y:i,width:l,height:u,strokeWidth:1,stroke:"white",strokeScaleEnabled:!1}),a.jsx(ks,{x:s,y:i,width:l,height:u,dash:[4,4],strokeWidth:1,stroke:"black",strokeScaleEnabled:!1})]})]})},zme=d.memo(Lme),Fme=ie([Lt],e=>{const{la
|
||
|
${s}
|
||
|
\`\`\``),n({title:"Error Copied"})},[e,n]),o=d.useMemo(()=>Gge({user:"invoke-ai",repo:"InvokeAI",template:"BUG_REPORT.yml",title:`[bug]: ${e.name}: ${e.message}`}),[e.message,e.name]);return a.jsx($,{layerStyle:"body",sx:{w:"100vw",h:"100vh",alignItems:"center",justifyContent:"center",p:4},children:a.jsxs($,{layerStyle:"first",sx:{flexDir:"column",borderRadius:"base",justifyContent:"center",gap:8,p:16},children:[a.jsx(so,{children:"Something went wrong"}),a.jsx($,{layerStyle:"second",sx:{px:8,py:4,borderRadius:"base",gap:4,justifyContent:"space-between",alignItems:"center"},children:a.jsxs(ye,{sx:{fontWeight:600,color:"error.500",_dark:{color:"error.400"}},children:[e.name,": ",e.message]})}),a.jsxs($,{sx:{gap:4},children:[a.jsx(it,{leftIcon:a.jsx(Lpe,{}),onClick:t,children:"Reset UI"}),a.jsx(it,{leftIcon:a.jsx(Hc,{}),onClick:r,children:"Copy Error"}),a.jsx(Im,{href:o,isExternal:!0,children:a.jsx(it,{leftIcon:a.jsx(EE,{}),children:"Create Issue"})})]})]})})},qge=d.memo(Kge),Xge=ie([be],({hotkeys:e})=>{const{shift:t,ctrl:n,meta:r}=e;return{shift:t,ctrl:n,meta:r}},{memoizeOptions:{resultEqualityCheck:_t}}),Yge=()=>{const e=ee(),{shift:t,ctrl:n,meta:r}=F(Xge);return Qe("*",()=>{Tp("shift")?!t&&e(Ir(!0)):t&&e(Ir(!1)),Tp("ctrl")?!n&&e(bw(!0)):n&&e(bw(!1)),Tp("meta")?!r&&e(yw(!0)):r&&e(yw(!1))},{keyup:!0,keydown:!0},[t,n,r]),Qe("1",()=>{e(Ra("txt2img"))}),Qe("2",()=>{e(Ra("img2img"))}),Qe("3",()=>{e(Ra("unifiedCanvas"))}),Qe("4",()=>{e(Ra("nodes"))}),Qe("5",()=>{e(Ra("modelManager"))}),null},Qge=d.memo(Yge),Zge={},Jge=({config:e=Zge,selectedImage:t})=>{const n=F(RP),r=AP("system"),o=ee(),{handlePreselectedImage:s}=Uge(),i=d.useCallback(()=>(localStorage.clear(),location.reload(),!1),[]);d.useEffect(()=>{vt.changeLanguage(n)},[n]),d.useEffect(()=>{Qj(e)&&(r.info({config:e},"Received config"),o(cN(e)))},[o,e,r]),d.useEffect(()=>{o(uN())},[o]),d.useEffect(()=>{s(t)},[s,t]);const l=gg(dN);return a.jsxs(Vge,{onReset:i,FallbackComponent:qge,children:[a.jsx(Ua,{w:"100vw",h:"100vh",position:"relative",overflow:"hidden",children:a.jsx($W,{children:a.jsxs(Ua,{sx:{gap:4,p:4,gridAutoRows:"min-content auto",w:"full",h:"full"},children:[l||a.jsx(gJ,{}),a.jsx($,{sx:{gap:4,w:"full",h:"full"},children:a.jsx(Bge,{})})]})})}),a.jsx(tZ,{}),a.jsx(YQ,{}),a.jsx(jV,{}),a.jsx(Qge,{})]})},l0e=d.memo(Jge);export{l0e as default};
|