strapi-plugin-comments 3.0.9 → 3.0.11

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.
Files changed (30) hide show
  1. package/README.md +3 -1
  2. package/dist/_chunks/fr-Bh0tVDIQ.js +1 -0
  3. package/dist/_chunks/{fr-Dx7zbWW0.mjs → fr-n-k7Rsq9.mjs} +105 -56
  4. package/dist/_chunks/{index-DiQHdq_2.js → index-670UMREc.js} +1 -1
  5. package/dist/_chunks/{index-Bi2NddA5.mjs → index-BcTMW0bl.mjs} +9080 -8884
  6. package/dist/_chunks/index-BgxJUAmG.js +2238 -0
  7. package/dist/_chunks/{index-B8Jogmi4.mjs → index-CFRFtK93.mjs} +328 -331
  8. package/dist/_chunks/{index-gJOowHIB.js → index-CLWGT_vP.js} +44 -44
  9. package/dist/_chunks/{index-BbHOeszY.mjs → index-DexwEcn3.mjs} +8017 -7982
  10. package/dist/_chunks/{index-Bfn0RC18.js → index-QMZY5BnX.js} +5 -5
  11. package/dist/_chunks/{index-D56DrIq3.mjs → index-tUit0Fx4.mjs} +2 -2
  12. package/dist/admin/index.js +1 -1
  13. package/dist/admin/index.mjs +1 -1
  14. package/dist/admin/src/api/schemas.d.ts +16 -16
  15. package/dist/admin/src/components/ActionButton/index.d.ts +4 -2
  16. package/dist/admin/src/components/DiscussionThreadItem/DiscussionThreadItemFooter.d.ts +1 -1
  17. package/dist/admin/src/components/DiscussionThreadItem/index.d.ts +2 -2
  18. package/dist/admin/src/components/IconButtonGroup/index.d.ts +5 -2
  19. package/dist/admin/src/components/StatusBadge/index.d.ts +1 -1
  20. package/dist/admin/src/components/Wysiwyg/EditorLayout.d.ts +1 -1
  21. package/dist/admin/src/components/Wysiwyg/WysiwygStyles.d.ts +4 -4
  22. package/dist/admin/src/translations/fr.d.ts +50 -0
  23. package/dist/server/index.js +26 -26
  24. package/dist/server/index.mjs +1357 -1353
  25. package/dist/server/src/validators/api/controllers/admin.controller.validator.d.ts +6 -10
  26. package/dist/server/src/validators/repositories/comment.validator.d.ts +57 -57
  27. package/dist/server/src/validators/utils.d.ts +8 -8
  28. package/package.json +14 -14
  29. package/dist/_chunks/fr-BIrOYxvf.js +0 -1
  30. package/dist/_chunks/index-BNZz69rC.js +0 -2175
@@ -1,2175 +0,0 @@
1
- "use strict";const b=require("react"),k=require("styled-components"),p=require("react/jsx-runtime"),Za=require("react-dom");function yw(t){if(t&&t.__esModule)return t;const e=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(t){for(const n in t)if(n!=="default"){const r=Object.getOwnPropertyDescriptor(t,n);Object.defineProperty(e,n,r.get?r:{enumerable:!0,get:()=>t[n]})}}return e.default=t,Object.freeze(e)}const $=yw(b),yo=yw(Za),s0=(t,e="")=>Object.keys(t).reduce((n,r)=>{const i=e.length?`${e}.`:"";return typeof t[r]=="object"&&t[r]!==null&&!Array.isArray(t[r])?Object.assign(n,s0(t[r],i+r)):n[i+r]=t[r],n},{}),bv=(t,e)=>{if(!e)throw new TypeError("pluginId can't be empty");return Object.keys(t).reduce((n,r)=>(n[`${e}.${r}`]=t[r],n),{})};function Ct(t){const e=b.useRef(t);return b.useEffect(()=>{e.current=t}),b.useMemo(()=>(...n)=>{var r;return(r=e.current)===null||r===void 0?void 0:r.call(e,...n)},[])}function ud(t,e){return t-e*Math.floor(t/e)}const Cw=1721426;function uc(t,e,n,r){e=H1(t,e);let i=e-1,o=-2;return n<=2?o=0:Gc(e)&&(o=-1),Cw-1+365*i+Math.floor(i/4)-Math.floor(i/100)+Math.floor(i/400)+Math.floor((367*n-362)/12+o+r)}function Gc(t){return t%4===0&&(t%100!==0||t%400===0)}function H1(t,e){return t==="BC"?1-e:e}function lT(t){let e="AD";return t<=0&&(e="BC",t=1-t),[e,t]}const cT={standard:[31,28,31,30,31,30,31,31,30,31,30,31],leapyear:[31,29,31,30,31,30,31,31,30,31,30,31]};class ds{fromJulianDay(e){let n=e,r=n-Cw,i=Math.floor(r/146097),o=ud(r,146097),s=Math.floor(o/36524),a=ud(o,36524),c=Math.floor(a/1461),h=ud(a,1461),f=Math.floor(h/365),d=i*400+s*100+c*4+f+(s!==4&&f!==4?1:0),[m,v]=lT(d),w=n-uc(m,v,1,1),x=2;n<uc(m,v,3,1)?x=0:Gc(v)&&(x=1);let C=Math.floor(((w+x)*12+373)/367),S=n-uc(m,v,C,1)+1;return new Ra(m,v,C,S)}toJulianDay(e){return uc(e.era,e.year,e.month,e.day)}getDaysInMonth(e){return cT[Gc(e.year)?"leapyear":"standard"][e.month-1]}getMonthsInYear(e){return 12}getDaysInYear(e){return Gc(e.year)?366:365}getYearsInEra(e){return 9999}getEras(){return["BC","AD"]}isInverseEra(e){return e.era==="BC"}balanceDate(e){e.year<=0&&(e.era=e.era==="BC"?"AD":"BC",e.year=1-e.year)}constructor(){this.identifier="gregory"}}const uT={"001":1,AD:1,AE:6,AF:6,AI:1,AL:1,AM:1,AN:1,AR:1,AT:1,AU:1,AX:1,AZ:1,BA:1,BE:1,BG:1,BH:6,BM:1,BN:1,BY:1,CH:1,CL:1,CM:1,CN:1,CR:1,CY:1,CZ:1,DE:1,DJ:6,DK:1,DZ:6,EC:1,EE:1,EG:6,ES:1,FI:1,FJ:1,FO:1,FR:1,GB:1,GE:1,GF:1,GP:1,GR:1,HR:1,HU:1,IE:1,IQ:6,IR:6,IS:1,IT:1,JO:6,KG:1,KW:6,KZ:1,LB:1,LI:1,LK:1,LT:1,LU:1,LV:1,LY:6,MC:1,MD:1,ME:1,MK:1,MN:1,MQ:1,MV:5,MY:1,NL:1,NO:1,NZ:1,OM:6,PL:1,QA:6,RE:1,RO:1,RS:1,RU:1,SD:6,SE:1,SI:1,SK:1,SM:1,SY:6,TJ:1,TM:1,TR:1,UA:1,UY:1,UZ:1,VA:1,VN:1,XK:1};function $w(t,e){return e=Gn(e,t.calendar),t.era===e.era&&t.year===e.year&&t.month===e.month&&t.day===e.day}function Sw(t,e){let n=t.calendar.toJulianDay(t),r=Math.ceil(n+1-pT(e))%7;return r<0&&(r+=7),r}function hT(t){return Gr(Date.now(),t)}function P1(t){return Ew(hT(t))}function Aw(t,e){return t.calendar.toJulianDay(t)-e.calendar.toJulianDay(e)}function fT(t,e){return wv(t)-wv(e)}function wv(t){return t.hour*36e5+t.minute*6e4+t.second*1e3+t.millisecond}let hd=null;function gs(){return hd==null&&(hd=new Intl.DateTimeFormat().resolvedOptions().timeZone),hd}function dT(t){return t.subtract({days:t.day-1})}function gT(t){return t.add({days:t.calendar.getDaysInMonth(t)-t.day})}function Rw(t,e){let n=Sw(t,e);return t.subtract({days:n})}const xv=new Map;function mT(t){if(Intl.Locale){let n=xv.get(t);return n||(n=new Intl.Locale(t).maximize().region,n&&xv.set(t,n)),n}let e=t.split("-")[1];return e==="u"?void 0:e}function pT(t){let e=mT(t);return e&&uT[e]||0}function a0(t,e){return t&&e?t.compare(e)<=0?t:e:t||e}function l0(t,e){return t&&e?t.compare(e)>=0?t:e:t||e}function ms(t){t=Gn(t,new ds);let e=H1(t.era,t.year);return kw(e,t.month,t.day,t.hour,t.minute,t.second,t.millisecond)}function kw(t,e,n,r,i,o,s){let a=new Date;return a.setUTCHours(r,i,o,s),a.setUTCFullYear(t,e-1,n),a.getTime()}function c0(t,e){if(e==="UTC")return 0;if(t>0&&e===gs())return new Date(t).getTimezoneOffset()*-6e4;let{year:n,month:r,day:i,hour:o,minute:s,second:a}=Tw(t,e);return kw(n,r,i,o,s,a,0)-Math.floor(t/1e3)*1e3}const yv=new Map;function Tw(t,e){let n=yv.get(e);n||(n=new Intl.DateTimeFormat("en-US",{timeZone:e,hour12:!1,era:"short",year:"numeric",month:"numeric",day:"numeric",hour:"numeric",minute:"numeric",second:"numeric"}),yv.set(e,n));let r=n.formatToParts(new Date(t)),i={};for(let o of r)o.type!=="literal"&&(i[o.type]=o.value);return{year:i.era==="BC"||i.era==="B"?-i.year+1:+i.year,month:+i.month,day:+i.day,hour:i.hour==="24"?0:+i.hour,minute:+i.minute,second:+i.second}}const Cv=864e5;function vT(t,e,n,r){return(n===r?[n]:[n,r]).filter(o=>bT(t,e,o))}function bT(t,e,n){let r=Tw(n,e);return t.year===r.year&&t.month===r.month&&t.day===r.day&&t.hour===r.hour&&t.minute===r.minute&&t.second===r.second}function qr(t,e,n="compatible"){let r=co(t);if(e==="UTC")return ms(r);if(e===gs()&&n==="compatible"){r=Gn(r,new ds);let c=new Date,h=H1(r.era,r.year);return c.setFullYear(h,r.month-1,r.day),c.setHours(r.hour,r.minute,r.second,r.millisecond),c.getTime()}let i=ms(r),o=c0(i-Cv,e),s=c0(i+Cv,e),a=vT(r,e,i-o,i-s);if(a.length===1)return a[0];if(a.length>1)switch(n){case"compatible":case"earlier":return a[0];case"later":return a[a.length-1];case"reject":throw new RangeError("Multiple possible absolute times found")}switch(n){case"earlier":return Math.min(i-o,i-s);case"compatible":case"later":return Math.max(i-o,i-s);case"reject":throw new RangeError("No such absolute time found")}}function Mw(t,e,n="compatible"){return new Date(qr(t,e,n))}function Gr(t,e){let n=c0(t,e),r=new Date(t+n),i=r.getUTCFullYear(),o=r.getUTCMonth()+1,s=r.getUTCDate(),a=r.getUTCHours(),c=r.getUTCMinutes(),h=r.getUTCSeconds(),f=r.getUTCMilliseconds();return new ps(i,o,s,e,n,a,c,h,f)}function Ew(t){return new Ra(t.calendar,t.era,t.year,t.month,t.day)}function co(t,e){let n=0,r=0,i=0,o=0;if("timeZone"in t)({hour:n,minute:r,second:i,millisecond:o}=t);else if("hour"in t&&!e)return t;return e&&({hour:n,minute:r,second:i,millisecond:o}=e),new hu(t.calendar,t.era,t.year,t.month,t.day,n,r,i,o)}function Gn(t,e){if(t.calendar.identifier===e.identifier)return t;let n=e.fromJulianDay(t.calendar.toJulianDay(t)),r=t.copy();return r.calendar=e,r.era=n.era,r.year=n.year,r.month=n.month,r.day=n.day,uo(r),r}function wT(t,e,n){if(t instanceof ps)return t.timeZone===e?t:Ow(t,e);let r=qr(t,e,n);return Gr(r,e)}function xT(t){let e=ms(t)-t.offset;return new Date(e)}function Ow(t,e){let n=ms(t)-t.offset;return Gn(Gr(n,e),t.calendar)}const oa=36e5;function Qu(t,e){let n=t.copy(),r="hour"in n?ST(n,e):0;u0(n,e.years||0),n.calendar.balanceYearMonth&&n.calendar.balanceYearMonth(n,t),n.month+=e.months||0,h0(n),Dw(n),n.day+=(e.weeks||0)*7,n.day+=e.days||0,n.day+=r,yT(n),n.calendar.balanceDate&&n.calendar.balanceDate(n),n.year<1&&(n.year=1,n.month=1,n.day=1);let i=n.calendar.getYearsInEra(n);if(n.year>i){var o,s;let c=(o=(s=n.calendar).isInverseEra)===null||o===void 0?void 0:o.call(s,n);n.year=i,n.month=c?1:n.calendar.getMonthsInYear(n),n.day=c?1:n.calendar.getDaysInMonth(n)}n.month<1&&(n.month=1,n.day=1);let a=n.calendar.getMonthsInYear(n);return n.month>a&&(n.month=a,n.day=n.calendar.getDaysInMonth(n)),n.day=Math.max(1,Math.min(n.calendar.getDaysInMonth(n),n.day)),n}function u0(t,e){var n,r;!((n=(r=t.calendar).isInverseEra)===null||n===void 0)&&n.call(r,t)&&(e=-e),t.year+=e}function h0(t){for(;t.month<1;)u0(t,-1),t.month+=t.calendar.getMonthsInYear(t);let e=0;for(;t.month>(e=t.calendar.getMonthsInYear(t));)t.month-=e,u0(t,1)}function yT(t){for(;t.day<1;)t.month--,h0(t),t.day+=t.calendar.getDaysInMonth(t);for(;t.day>t.calendar.getDaysInMonth(t);)t.day-=t.calendar.getDaysInMonth(t),t.month++,h0(t)}function Dw(t){t.month=Math.max(1,Math.min(t.calendar.getMonthsInYear(t),t.month)),t.day=Math.max(1,Math.min(t.calendar.getDaysInMonth(t),t.day))}function uo(t){t.calendar.constrainDate&&t.calendar.constrainDate(t),t.year=Math.max(1,Math.min(t.calendar.getYearsInEra(t),t.year)),Dw(t)}function Iw(t){let e={};for(let n in t)typeof t[n]=="number"&&(e[n]=-t[n]);return e}function _w(t,e){return Qu(t,Iw(e))}function W1(t,e){let n=t.copy();return e.era!=null&&(n.era=e.era),e.year!=null&&(n.year=e.year),e.month!=null&&(n.month=e.month),e.day!=null&&(n.day=e.day),uo(n),n}function uu(t,e){let n=t.copy();return e.hour!=null&&(n.hour=e.hour),e.minute!=null&&(n.minute=e.minute),e.second!=null&&(n.second=e.second),e.millisecond!=null&&(n.millisecond=e.millisecond),$T(n),n}function CT(t){t.second+=Math.floor(t.millisecond/1e3),t.millisecond=hc(t.millisecond,1e3),t.minute+=Math.floor(t.second/60),t.second=hc(t.second,60),t.hour+=Math.floor(t.minute/60),t.minute=hc(t.minute,60);let e=Math.floor(t.hour/24);return t.hour=hc(t.hour,24),e}function $T(t){t.millisecond=Math.max(0,Math.min(t.millisecond,1e3)),t.second=Math.max(0,Math.min(t.second,59)),t.minute=Math.max(0,Math.min(t.minute,59)),t.hour=Math.max(0,Math.min(t.hour,23))}function hc(t,e){let n=t%e;return n<0&&(n+=e),n}function ST(t,e){return t.hour+=e.hours||0,t.minute+=e.minutes||0,t.second+=e.seconds||0,t.millisecond+=e.milliseconds||0,CT(t)}function z1(t,e,n,r){let i=t.copy();switch(e){case"era":{let a=t.calendar.getEras(),c=a.indexOf(t.era);if(c<0)throw new Error("Invalid era: "+t.era);c=Yr(c,n,0,a.length-1,r?.round),i.era=a[c],uo(i);break}case"year":var o,s;!((o=(s=i.calendar).isInverseEra)===null||o===void 0)&&o.call(s,i)&&(n=-n),i.year=Yr(t.year,n,-1/0,9999,r?.round),i.year===-1/0&&(i.year=1),i.calendar.balanceYearMonth&&i.calendar.balanceYearMonth(i,t);break;case"month":i.month=Yr(t.month,n,1,t.calendar.getMonthsInYear(t),r?.round);break;case"day":i.day=Yr(t.day,n,1,t.calendar.getDaysInMonth(t),r?.round);break;default:throw new Error("Unsupported field "+e)}return t.calendar.balanceDate&&t.calendar.balanceDate(i),uo(i),i}function Lw(t,e,n,r){let i=t.copy();switch(e){case"hour":{let o=t.hour,s=0,a=23;if(r?.hourCycle===12){let c=o>=12;s=c?12:0,a=c?23:11}i.hour=Yr(o,n,s,a,r?.round);break}case"minute":i.minute=Yr(t.minute,n,0,59,r?.round);break;case"second":i.second=Yr(t.second,n,0,59,r?.round);break;case"millisecond":i.millisecond=Yr(t.millisecond,n,0,999,r?.round);break;default:throw new Error("Unsupported field "+e)}return i}function Yr(t,e,n,r,i=!1){if(i){t+=Math.sign(e),t<n&&(t=r);let o=Math.abs(e);e>0?t=Math.ceil(t/o)*o:t=Math.floor(t/o)*o,t>r&&(t=n)}else t+=e,t<n?t=r-(n-t-1):t>r&&(t=n+(t-r-1));return t}function Bw(t,e){let n;if(e.years!=null&&e.years!==0||e.months!=null&&e.months!==0||e.weeks!=null&&e.weeks!==0||e.days!=null&&e.days!==0){let i=Qu(co(t),{years:e.years,months:e.months,weeks:e.weeks,days:e.days});n=qr(i,t.timeZone)}else n=ms(t)-t.offset;n+=e.milliseconds||0,n+=(e.seconds||0)*1e3,n+=(e.minutes||0)*6e4,n+=(e.hours||0)*36e5;let r=Gr(n,t.timeZone);return Gn(r,t.calendar)}function AT(t,e){return Bw(t,Iw(e))}function RT(t,e,n,r){switch(e){case"hour":{let i=0,o=23;if(r?.hourCycle===12){let w=t.hour>=12;i=w?12:0,o=w?23:11}let s=co(t),a=Gn(uu(s,{hour:i}),new ds),c=[qr(a,t.timeZone,"earlier"),qr(a,t.timeZone,"later")].filter(w=>Gr(w,t.timeZone).day===a.day)[0],h=Gn(uu(s,{hour:o}),new ds),f=[qr(h,t.timeZone,"earlier"),qr(h,t.timeZone,"later")].filter(w=>Gr(w,t.timeZone).day===h.day).pop(),d=ms(t)-t.offset,m=Math.floor(d/oa),v=d%oa;return d=Yr(m,n,Math.floor(c/oa),Math.floor(f/oa),r?.round)*oa+v,Gn(Gr(d,t.timeZone),t.calendar)}case"minute":case"second":case"millisecond":return Lw(t,e,n,r);case"era":case"year":case"month":case"day":{let i=z1(co(t),e,n,r),o=qr(i,t.timeZone);return Gn(Gr(o,t.timeZone),t.calendar)}default:throw new Error("Unsupported field "+e)}}function kT(t,e,n){let r=co(t),i=uu(W1(r,e),e);if(i.compare(r)===0)return t;let o=qr(i,t.timeZone,n);return Gn(Gr(o,t.timeZone),t.calendar)}const TT=/^(\d{4})-(\d{2})-(\d{2})(?:T(\d{2}))?(?::(\d{2}))?(?::(\d{2}))?(\.\d+)?(?:(?:([+-]\d{2})(?::?(\d{2}))?)|Z)$/;function Nw(t,e){let n=t.match(TT);if(!n)throw new Error("Invalid ISO 8601 date time string: "+t);let r=new ps(Hr(n[1],1,9999),Hr(n[2],1,12),1,e,0,n[4]?Hr(n[4],0,23):0,n[5]?Hr(n[5],0,59):0,n[6]?Hr(n[6],0,59):0,n[7]?Hr(n[7],0,1/0)*1e3:0);r.day=Hr(n[3],0,r.calendar.getDaysInMonth(r));var i;return n[8]&&(r.offset=Hr(n[8],-23,23)*36e5+Hr((i=n[9])!==null&&i!==void 0?i:"0",0,59)*6e4),Ow(r,e)}function MT(t){return Nw(t,gs())}function Hr(t,e,n){let r=Number(t);if(r<e||r>n)throw new RangeError(`Value out of range: ${e} <= ${r} <= ${n}`);return r}function ET(t){return`${String(t.hour).padStart(2,"0")}:${String(t.minute).padStart(2,"0")}:${String(t.second).padStart(2,"0")}${t.millisecond?String(t.millisecond/1e3).slice(1):""}`}function jw(t){let e=Gn(t,new ds);return`${String(e.year).padStart(4,"0")}-${String(e.month).padStart(2,"0")}-${String(e.day).padStart(2,"0")}`}function Fw(t){return`${jw(t)}T${ET(t)}`}function OT(t){let e=Math.sign(t)<0?"-":"+";t=Math.abs(t);let n=Math.floor(t/36e5),r=t%36e5/6e4;return`${e}${String(n).padStart(2,"0")}:${String(r).padStart(2,"0")}`}function DT(t){return`${Fw(t)}${OT(t.offset)}[${t.timeZone}]`}function IT(t,e){if(e.has(t))throw new TypeError("Cannot initialize the same private elements twice on an object")}function U1(t,e,n){IT(t,e),e.set(t,n)}function q1(t){let e=typeof t[0]=="object"?t.shift():new ds,n;if(typeof t[0]=="string")n=t.shift();else{let s=e.getEras();n=s[s.length-1]}let r=t.shift(),i=t.shift(),o=t.shift();return[e,n,r,i,o]}var _T=new WeakMap;class Ra{copy(){return this.era?new Ra(this.calendar,this.era,this.year,this.month,this.day):new Ra(this.calendar,this.year,this.month,this.day)}add(e){return Qu(this,e)}subtract(e){return _w(this,e)}set(e){return W1(this,e)}cycle(e,n,r){return z1(this,e,n,r)}toDate(e){return Mw(this,e)}toString(){return jw(this)}compare(e){return Aw(this,e)}constructor(...e){U1(this,_T,{writable:!0,value:void 0});let[n,r,i,o,s]=q1(e);this.calendar=n,this.era=r,this.year=i,this.month=o,this.day=s,uo(this)}}var LT=new WeakMap;class hu{copy(){return this.era?new hu(this.calendar,this.era,this.year,this.month,this.day,this.hour,this.minute,this.second,this.millisecond):new hu(this.calendar,this.year,this.month,this.day,this.hour,this.minute,this.second,this.millisecond)}add(e){return Qu(this,e)}subtract(e){return _w(this,e)}set(e){return W1(uu(this,e),e)}cycle(e,n,r){switch(e){case"era":case"year":case"month":case"day":return z1(this,e,n,r);default:return Lw(this,e,n,r)}}toDate(e,n){return Mw(this,e,n)}toString(){return Fw(this)}compare(e){let n=Aw(this,e);return n===0?fT(this,co(e)):n}constructor(...e){U1(this,LT,{writable:!0,value:void 0});let[n,r,i,o,s]=q1(e);this.calendar=n,this.era=r,this.year=i,this.month=o,this.day=s,this.hour=e.shift()||0,this.minute=e.shift()||0,this.second=e.shift()||0,this.millisecond=e.shift()||0,uo(this)}}var BT=new WeakMap;class ps{copy(){return this.era?new ps(this.calendar,this.era,this.year,this.month,this.day,this.timeZone,this.offset,this.hour,this.minute,this.second,this.millisecond):new ps(this.calendar,this.year,this.month,this.day,this.timeZone,this.offset,this.hour,this.minute,this.second,this.millisecond)}add(e){return Bw(this,e)}subtract(e){return AT(this,e)}set(e,n){return kT(this,e,n)}cycle(e,n,r){return RT(this,e,n,r)}toDate(){return xT(this)}toString(){return DT(this)}toAbsoluteString(){return this.toDate().toISOString()}compare(e){return this.toDate().getTime()-wT(e,this.timeZone).toDate().getTime()}constructor(...e){U1(this,BT,{writable:!0,value:void 0});let[n,r,i,o,s]=q1(e),a=e.shift(),c=e.shift();this.calendar=n,this.era=r,this.year=i,this.month=o,this.day=s,this.timeZone=a,this.offset=c,this.hour=e.shift()||0,this.minute=e.shift()||0,this.second=e.shift()||0,this.millisecond=e.shift()||0,uo(this)}}let fd=new Map;class NT{format(e){return this.formatter.format(e)}formatToParts(e){return this.formatter.formatToParts(e)}formatRange(e,n){if(typeof this.formatter.formatRange=="function")return this.formatter.formatRange(e,n);if(n<e)throw new RangeError("End date must be >= start date");return`${this.formatter.format(e)} – ${this.formatter.format(n)}`}formatRangeToParts(e,n){if(typeof this.formatter.formatRangeToParts=="function")return this.formatter.formatRangeToParts(e,n);if(n<e)throw new RangeError("End date must be >= start date");let r=this.formatter.formatToParts(e),i=this.formatter.formatToParts(n);return[...r.map(o=>({...o,source:"startRange"})),{type:"literal",value:" – ",source:"shared"},...i.map(o=>({...o,source:"endRange"}))]}resolvedOptions(){let e=this.formatter.resolvedOptions();return VT()&&(this.resolvedHourCycle||(this.resolvedHourCycle=HT(e.locale,this.options)),e.hourCycle=this.resolvedHourCycle,e.hour12=this.resolvedHourCycle==="h11"||this.resolvedHourCycle==="h12"),e.calendar==="ethiopic-amete-alem"&&(e.calendar="ethioaa"),e}constructor(e,n={}){this.formatter=Vw(e,n),this.options=n}}const jT={true:{ja:"h11"},false:{}};function Vw(t,e={}){if(typeof e.hour12=="boolean"&&FT()){e={...e};let i=jT[String(e.hour12)][t.split("-")[0]],o=e.hour12?"h12":"h23";e.hourCycle=i??o,delete e.hour12}let n=t+(e?Object.entries(e).sort((i,o)=>i[0]<o[0]?-1:1).join():"");if(fd.has(n))return fd.get(n);let r=new Intl.DateTimeFormat(t,e);return fd.set(n,r),r}let dd=null;function FT(){return dd==null&&(dd=new Intl.DateTimeFormat("en-US",{hour:"numeric",hour12:!1}).format(new Date(2020,2,3,0))==="24"),dd}let gd=null;function VT(){return gd==null&&(gd=new Intl.DateTimeFormat("fr",{hour:"numeric",hour12:!1}).resolvedOptions().hourCycle==="h12"),gd}function HT(t,e){if(!e.timeStyle&&!e.hour)return;t=t.replace(/(-u-)?-nu-[a-zA-Z0-9]+/,""),t+=(t.includes("-u-")?"":"-u")+"-nu-latn";let n=Vw(t,{...e,timeZone:void 0}),r=parseInt(n.formatToParts(new Date(2020,2,3,0)).find(o=>o.type==="hour").value,10),i=parseInt(n.formatToParts(new Date(2020,2,3,23)).find(o=>o.type==="hour").value,10);if(r===0&&i===23)return"h23";if(r===24&&i===23)return"h24";if(r===0&&i===11)return"h11";if(r===12&&i===11)return"h12";throw new Error("Unexpected hour cycle result")}function U(){return U=Object.assign?Object.assign.bind():function(t){for(var e=1;e<arguments.length;e++){var n=arguments[e];for(var r in n)({}).hasOwnProperty.call(n,r)&&(t[r]=n[r])}return t},U.apply(null,arguments)}function ne(t,e,{checkForDefaultPrevented:n=!0}={}){return function(i){if(t?.(i),n===!1||!i.defaultPrevented)return e?.(i)}}function PT(t,e){typeof t=="function"?t(e):t!=null&&(t.current=e)}function Ju(...t){return e=>t.forEach(n=>PT(n,e))}function ye(...t){return b.useCallback(Ju(...t),t)}function K1(t,e){const n=b.createContext(e);function r(o){const{children:s,...a}=o,c=b.useMemo(()=>a,Object.values(a));return b.createElement(n.Provider,{value:c},s)}function i(o){const s=b.useContext(n);if(s)return s;if(e!==void 0)return e;throw new Error(`\`${o}\` must be used within \`${t}\``)}return r.displayName=t+"Provider",[r,i]}function bt(t,e=[]){let n=[];function r(o,s){const a=b.createContext(s),c=n.length;n=[...n,s];function h(d){const{scope:m,children:v,...w}=d,x=m?.[t][c]||a,C=b.useMemo(()=>w,Object.values(w));return b.createElement(x.Provider,{value:C},v)}function f(d,m){const v=m?.[t][c]||a,w=b.useContext(v);if(w)return w;if(s!==void 0)return s;throw new Error(`\`${d}\` must be used within \`${o}\``)}return h.displayName=o+"Provider",[h,f]}const i=()=>{const o=n.map(s=>b.createContext(s));return function(a){const c=a?.[t]||o;return b.useMemo(()=>({[`__scope${t}`]:{...a,[t]:c}}),[a,c])}};return i.scopeName=t,[r,WT(i,...e)]}function WT(...t){const e=t[0];if(t.length===1)return e;const n=()=>{const r=t.map(i=>({useScope:i(),scopeName:i.scopeName}));return function(o){const s=r.reduce((a,{useScope:c,scopeName:h})=>{const d=c(o)[`__scope${h}`];return{...a,...d}},{});return b.useMemo(()=>({[`__scope${e.scopeName}`]:s}),[s])}};return n.scopeName=e.scopeName,n}const Cr=b.forwardRef((t,e)=>{const{children:n,...r}=t,i=b.Children.toArray(n),o=i.find(zT);if(o){const s=o.props.children,a=i.map(c=>c===o?b.Children.count(s)>1?b.Children.only(null):b.isValidElement(s)?s.props.children:null:c);return b.createElement(f0,U({},r,{ref:e}),b.isValidElement(s)?b.cloneElement(s,void 0,a):null)}return b.createElement(f0,U({},r,{ref:e}),n)});Cr.displayName="Slot";const f0=b.forwardRef((t,e)=>{const{children:n,...r}=t;return b.isValidElement(n)?b.cloneElement(n,{...UT(r,n.props),ref:e?Ju(e,n.ref):n.ref}):b.Children.count(n)>1?b.Children.only(null):null});f0.displayName="SlotClone";const G1=({children:t})=>b.createElement(b.Fragment,null,t);function zT(t){return b.isValidElement(t)&&t.type===G1}function UT(t,e){const n={...e};for(const r in e){const i=t[r],o=e[r];/^on[A-Z]/.test(r)?i&&o?n[r]=(...a)=>{o(...a),i(...a)}:i&&(n[r]=i):r==="style"?n[r]={...i,...o}:r==="className"&&(n[r]=[i,o].filter(Boolean).join(" "))}return{...t,...n}}const qT=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","span","svg","ul"],me=qT.reduce((t,e)=>{const n=b.forwardRef((r,i)=>{const{asChild:o,...s}=r,a=o?Cr:e;return b.useEffect(()=>{window[Symbol.for("radix-ui")]=!0},[]),b.createElement(a,U({},s,{ref:i}))});return n.displayName=`Primitive.${e}`,{...t,[e]:n}},{});function Hw(t,e){t&&Za.flushSync(()=>t.dispatchEvent(e))}function KT(t,e=globalThis?.document){const n=Ct(t);b.useEffect(()=>{const r=i=>{i.key==="Escape"&&n(i)};return e.addEventListener("keydown",r),()=>e.removeEventListener("keydown",r)},[n,e])}const d0="dismissableLayer.update",GT="dismissableLayer.pointerDownOutside",YT="dismissableLayer.focusOutside";let $v;const XT=b.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),Co=b.forwardRef((t,e)=>{var n;const{disableOutsidePointerEvents:r=!1,onEscapeKeyDown:i,onPointerDownOutside:o,onFocusOutside:s,onInteractOutside:a,onDismiss:c,...h}=t,f=b.useContext(XT),[d,m]=b.useState(null),v=(n=d?.ownerDocument)!==null&&n!==void 0?n:globalThis?.document,[,w]=b.useState({}),x=ye(e,V=>m(V)),C=Array.from(f.layers),[S]=[...f.layersWithOutsidePointerEventsDisabled].slice(-1),A=C.indexOf(S),T=d?C.indexOf(d):-1,O=f.layersWithOutsidePointerEventsDisabled.size>0,D=T>=A,L=ZT(V=>{const F=V.target,H=[...f.branches].some(K=>K.contains(F));!D||H||(o?.(V),a?.(V),V.defaultPrevented||c?.())},v),I=QT(V=>{const F=V.target;[...f.branches].some(K=>K.contains(F))||(s?.(V),a?.(V),V.defaultPrevented||c?.())},v);return KT(V=>{T===f.layers.size-1&&(i?.(V),!V.defaultPrevented&&c&&(V.preventDefault(),c()))},v),b.useEffect(()=>{if(d)return r&&(f.layersWithOutsidePointerEventsDisabled.size===0&&($v=v.body.style.pointerEvents,v.body.style.pointerEvents="none"),f.layersWithOutsidePointerEventsDisabled.add(d)),f.layers.add(d),Sv(),()=>{r&&f.layersWithOutsidePointerEventsDisabled.size===1&&(v.body.style.pointerEvents=$v)}},[d,v,r,f]),b.useEffect(()=>()=>{d&&(f.layers.delete(d),f.layersWithOutsidePointerEventsDisabled.delete(d),Sv())},[d,f]),b.useEffect(()=>{const V=()=>w({});return document.addEventListener(d0,V),()=>document.removeEventListener(d0,V)},[]),b.createElement(me.div,U({},h,{ref:x,style:{pointerEvents:O?D?"auto":"none":void 0,...t.style},onFocusCapture:ne(t.onFocusCapture,I.onFocusCapture),onBlurCapture:ne(t.onBlurCapture,I.onBlurCapture),onPointerDownCapture:ne(t.onPointerDownCapture,L.onPointerDownCapture)}))});function ZT(t,e=globalThis?.document){const n=Ct(t),r=b.useRef(!1),i=b.useRef(()=>{});return b.useEffect(()=>{const o=a=>{if(a.target&&!r.current){let h=function(){Pw(GT,n,c,{discrete:!0})};const c={originalEvent:a};a.pointerType==="touch"?(e.removeEventListener("click",i.current),i.current=h,e.addEventListener("click",i.current,{once:!0})):h()}else e.removeEventListener("click",i.current);r.current=!1},s=window.setTimeout(()=>{e.addEventListener("pointerdown",o)},0);return()=>{window.clearTimeout(s),e.removeEventListener("pointerdown",o),e.removeEventListener("click",i.current)}},[e,n]),{onPointerDownCapture:()=>r.current=!0}}function QT(t,e=globalThis?.document){const n=Ct(t),r=b.useRef(!1);return b.useEffect(()=>{const i=o=>{o.target&&!r.current&&Pw(YT,n,{originalEvent:o},{discrete:!1})};return e.addEventListener("focusin",i),()=>e.removeEventListener("focusin",i)},[e,n]),{onFocusCapture:()=>r.current=!0,onBlurCapture:()=>r.current=!1}}function Sv(){const t=new CustomEvent(d0);document.dispatchEvent(t)}function Pw(t,e,n,{discrete:r}){const i=n.originalEvent.target,o=new CustomEvent(t,{bubbles:!1,cancelable:!0,detail:n});e&&i.addEventListener(t,e,{once:!0}),r?Hw(i,o):i.dispatchEvent(o)}const JT=Co,ut=globalThis?.document?b.useLayoutEffect:()=>{},eM=$.useId||(()=>{});let tM=0;function Lt(t){const[e,n]=$.useState(eM());return ut(()=>{n(r=>r??String(tM++))},[t]),e?`radix-${e}`:""}const nM=["top","right","bottom","left"],Ri=Math.min,An=Math.max,fu=Math.round,fc=Math.floor,wr=t=>({x:t,y:t}),rM={left:"right",right:"left",bottom:"top",top:"bottom"},iM={start:"end",end:"start"};function g0(t,e,n){return An(t,Ri(e,n))}function Qr(t,e){return typeof t=="function"?t(e):t}function Jr(t){return t.split("-")[0]}function Es(t){return t.split("-")[1]}function Y1(t){return t==="x"?"y":"x"}function X1(t){return t==="y"?"height":"width"}function ki(t){return["top","bottom"].includes(Jr(t))?"y":"x"}function Z1(t){return Y1(ki(t))}function oM(t,e,n){n===void 0&&(n=!1);const r=Es(t),i=Z1(t),o=X1(i);let s=i==="x"?r===(n?"end":"start")?"right":"left":r==="start"?"bottom":"top";return e.reference[o]>e.floating[o]&&(s=du(s)),[s,du(s)]}function sM(t){const e=du(t);return[m0(t),e,m0(e)]}function m0(t){return t.replace(/start|end/g,e=>iM[e])}function aM(t,e,n){const r=["left","right"],i=["right","left"],o=["top","bottom"],s=["bottom","top"];switch(t){case"top":case"bottom":return n?e?i:r:e?r:i;case"left":case"right":return e?o:s;default:return[]}}function lM(t,e,n,r){const i=Es(t);let o=aM(Jr(t),n==="start",r);return i&&(o=o.map(s=>s+"-"+i),e&&(o=o.concat(o.map(m0)))),o}function du(t){return t.replace(/left|right|bottom|top/g,e=>rM[e])}function cM(t){return{top:0,right:0,bottom:0,left:0,...t}}function Ww(t){return typeof t!="number"?cM(t):{top:t,right:t,bottom:t,left:t}}function gu(t){const{x:e,y:n,width:r,height:i}=t;return{width:r,height:i,top:n,left:e,right:e+r,bottom:n+i,x:e,y:n}}function Av(t,e,n){let{reference:r,floating:i}=t;const o=ki(e),s=Z1(e),a=X1(s),c=Jr(e),h=o==="y",f=r.x+r.width/2-i.width/2,d=r.y+r.height/2-i.height/2,m=r[a]/2-i[a]/2;let v;switch(c){case"top":v={x:f,y:r.y-i.height};break;case"bottom":v={x:f,y:r.y+r.height};break;case"right":v={x:r.x+r.width,y:d};break;case"left":v={x:r.x-i.width,y:d};break;default:v={x:r.x,y:r.y}}switch(Es(e)){case"start":v[s]-=m*(n&&h?-1:1);break;case"end":v[s]+=m*(n&&h?-1:1);break}return v}const uM=async(t,e,n)=>{const{placement:r="bottom",strategy:i="absolute",middleware:o=[],platform:s}=n,a=o.filter(Boolean),c=await(s.isRTL==null?void 0:s.isRTL(e));let h=await s.getElementRects({reference:t,floating:e,strategy:i}),{x:f,y:d}=Av(h,r,c),m=r,v={},w=0;for(let x=0;x<a.length;x++){const{name:C,fn:S}=a[x],{x:A,y:T,data:O,reset:D}=await S({x:f,y:d,initialPlacement:r,placement:m,strategy:i,middlewareData:v,rects:h,platform:s,elements:{reference:t,floating:e}});f=A??f,d=T??d,v={...v,[C]:{...v[C],...O}},D&&w<=50&&(w++,typeof D=="object"&&(D.placement&&(m=D.placement),D.rects&&(h=D.rects===!0?await s.getElementRects({reference:t,floating:e,strategy:i}):D.rects),{x:f,y:d}=Av(h,m,c)),x=-1)}return{x:f,y:d,placement:m,strategy:i,middlewareData:v}};async function ka(t,e){var n;e===void 0&&(e={});const{x:r,y:i,platform:o,rects:s,elements:a,strategy:c}=t,{boundary:h="clippingAncestors",rootBoundary:f="viewport",elementContext:d="floating",altBoundary:m=!1,padding:v=0}=Qr(e,t),w=Ww(v),C=a[m?d==="floating"?"reference":"floating":d],S=gu(await o.getClippingRect({element:(n=await(o.isElement==null?void 0:o.isElement(C)))==null||n?C:C.contextElement||await(o.getDocumentElement==null?void 0:o.getDocumentElement(a.floating)),boundary:h,rootBoundary:f,strategy:c})),A=d==="floating"?{x:r,y:i,width:s.floating.width,height:s.floating.height}:s.reference,T=await(o.getOffsetParent==null?void 0:o.getOffsetParent(a.floating)),O=await(o.isElement==null?void 0:o.isElement(T))?await(o.getScale==null?void 0:o.getScale(T))||{x:1,y:1}:{x:1,y:1},D=gu(o.convertOffsetParentRelativeRectToViewportRelativeRect?await o.convertOffsetParentRelativeRectToViewportRelativeRect({elements:a,rect:A,offsetParent:T,strategy:c}):A);return{top:(S.top-D.top+w.top)/O.y,bottom:(D.bottom-S.bottom+w.bottom)/O.y,left:(S.left-D.left+w.left)/O.x,right:(D.right-S.right+w.right)/O.x}}const hM=t=>({name:"arrow",options:t,async fn(e){const{x:n,y:r,placement:i,rects:o,platform:s,elements:a,middlewareData:c}=e,{element:h,padding:f=0}=Qr(t,e)||{};if(h==null)return{};const d=Ww(f),m={x:n,y:r},v=Z1(i),w=X1(v),x=await s.getDimensions(h),C=v==="y",S=C?"top":"left",A=C?"bottom":"right",T=C?"clientHeight":"clientWidth",O=o.reference[w]+o.reference[v]-m[v]-o.floating[w],D=m[v]-o.reference[v],L=await(s.getOffsetParent==null?void 0:s.getOffsetParent(h));let I=L?L[T]:0;(!I||!await(s.isElement==null?void 0:s.isElement(L)))&&(I=a.floating[T]||o.floating[w]);const V=O/2-D/2,F=I/2-x[w]/2-1,H=Ri(d[S],F),K=Ri(d[A],F),W=H,J=I-x[w]-K,G=I/2-x[w]/2+V,re=g0(W,G,J),oe=!c.arrow&&Es(i)!=null&&G!==re&&o.reference[w]/2-(G<W?H:K)-x[w]/2<0,te=oe?G<W?G-W:G-J:0;return{[v]:m[v]+te,data:{[v]:re,centerOffset:G-re-te,...oe&&{alignmentOffset:te}},reset:oe}}}),fM=function(t){return t===void 0&&(t={}),{name:"flip",options:t,async fn(e){var n,r;const{placement:i,middlewareData:o,rects:s,initialPlacement:a,platform:c,elements:h}=e,{mainAxis:f=!0,crossAxis:d=!0,fallbackPlacements:m,fallbackStrategy:v="bestFit",fallbackAxisSideDirection:w="none",flipAlignment:x=!0,...C}=Qr(t,e);if((n=o.arrow)!=null&&n.alignmentOffset)return{};const S=Jr(i),A=ki(a),T=Jr(a)===a,O=await(c.isRTL==null?void 0:c.isRTL(h.floating)),D=m||(T||!x?[du(a)]:sM(a)),L=w!=="none";!m&&L&&D.push(...lM(a,x,w,O));const I=[a,...D],V=await ka(e,C),F=[];let H=((r=o.flip)==null?void 0:r.overflows)||[];if(f&&F.push(V[S]),d){const G=oM(i,s,O);F.push(V[G[0]],V[G[1]])}if(H=[...H,{placement:i,overflows:F}],!F.every(G=>G<=0)){var K,W;const G=(((K=o.flip)==null?void 0:K.index)||0)+1,re=I[G];if(re)return{data:{index:G,overflows:H},reset:{placement:re}};let oe=(W=H.filter(te=>te.overflows[0]<=0).sort((te,ie)=>te.overflows[1]-ie.overflows[1])[0])==null?void 0:W.placement;if(!oe)switch(v){case"bestFit":{var J;const te=(J=H.filter(ie=>{if(L){const Y=ki(ie.placement);return Y===A||Y==="y"}return!0}).map(ie=>[ie.placement,ie.overflows.filter(Y=>Y>0).reduce((Y,ue)=>Y+ue,0)]).sort((ie,Y)=>ie[1]-Y[1])[0])==null?void 0:J[0];te&&(oe=te);break}case"initialPlacement":oe=a;break}if(i!==oe)return{reset:{placement:oe}}}return{}}}};function Rv(t,e){return{top:t.top-e.height,right:t.right-e.width,bottom:t.bottom-e.height,left:t.left-e.width}}function kv(t){return nM.some(e=>t[e]>=0)}const dM=function(t){return t===void 0&&(t={}),{name:"hide",options:t,async fn(e){const{rects:n}=e,{strategy:r="referenceHidden",...i}=Qr(t,e);switch(r){case"referenceHidden":{const o=await ka(e,{...i,elementContext:"reference"}),s=Rv(o,n.reference);return{data:{referenceHiddenOffsets:s,referenceHidden:kv(s)}}}case"escaped":{const o=await ka(e,{...i,altBoundary:!0}),s=Rv(o,n.floating);return{data:{escapedOffsets:s,escaped:kv(s)}}}default:return{}}}}};async function gM(t,e){const{placement:n,platform:r,elements:i}=t,o=await(r.isRTL==null?void 0:r.isRTL(i.floating)),s=Jr(n),a=Es(n),c=ki(n)==="y",h=["left","top"].includes(s)?-1:1,f=o&&c?-1:1,d=Qr(e,t);let{mainAxis:m,crossAxis:v,alignmentAxis:w}=typeof d=="number"?{mainAxis:d,crossAxis:0,alignmentAxis:null}:{mainAxis:d.mainAxis||0,crossAxis:d.crossAxis||0,alignmentAxis:d.alignmentAxis};return a&&typeof w=="number"&&(v=a==="end"?w*-1:w),c?{x:v*f,y:m*h}:{x:m*h,y:v*f}}const mM=function(t){return t===void 0&&(t=0),{name:"offset",options:t,async fn(e){var n,r;const{x:i,y:o,placement:s,middlewareData:a}=e,c=await gM(e,t);return s===((n=a.offset)==null?void 0:n.placement)&&(r=a.arrow)!=null&&r.alignmentOffset?{}:{x:i+c.x,y:o+c.y,data:{...c,placement:s}}}}},pM=function(t){return t===void 0&&(t={}),{name:"shift",options:t,async fn(e){const{x:n,y:r,placement:i}=e,{mainAxis:o=!0,crossAxis:s=!1,limiter:a={fn:C=>{let{x:S,y:A}=C;return{x:S,y:A}}},...c}=Qr(t,e),h={x:n,y:r},f=await ka(e,c),d=ki(Jr(i)),m=Y1(d);let v=h[m],w=h[d];if(o){const C=m==="y"?"top":"left",S=m==="y"?"bottom":"right",A=v+f[C],T=v-f[S];v=g0(A,v,T)}if(s){const C=d==="y"?"top":"left",S=d==="y"?"bottom":"right",A=w+f[C],T=w-f[S];w=g0(A,w,T)}const x=a.fn({...e,[m]:v,[d]:w});return{...x,data:{x:x.x-n,y:x.y-r,enabled:{[m]:o,[d]:s}}}}}},vM=function(t){return t===void 0&&(t={}),{options:t,fn(e){const{x:n,y:r,placement:i,rects:o,middlewareData:s}=e,{offset:a=0,mainAxis:c=!0,crossAxis:h=!0}=Qr(t,e),f={x:n,y:r},d=ki(i),m=Y1(d);let v=f[m],w=f[d];const x=Qr(a,e),C=typeof x=="number"?{mainAxis:x,crossAxis:0}:{mainAxis:0,crossAxis:0,...x};if(c){const T=m==="y"?"height":"width",O=o.reference[m]-o.floating[T]+C.mainAxis,D=o.reference[m]+o.reference[T]-C.mainAxis;v<O?v=O:v>D&&(v=D)}if(h){var S,A;const T=m==="y"?"width":"height",O=["top","left"].includes(Jr(i)),D=o.reference[d]-o.floating[T]+(O&&((S=s.offset)==null?void 0:S[d])||0)+(O?0:C.crossAxis),L=o.reference[d]+o.reference[T]+(O?0:((A=s.offset)==null?void 0:A[d])||0)-(O?C.crossAxis:0);w<D?w=D:w>L&&(w=L)}return{[m]:v,[d]:w}}}},bM=function(t){return t===void 0&&(t={}),{name:"size",options:t,async fn(e){var n,r;const{placement:i,rects:o,platform:s,elements:a}=e,{apply:c=()=>{},...h}=Qr(t,e),f=await ka(e,h),d=Jr(i),m=Es(i),v=ki(i)==="y",{width:w,height:x}=o.floating;let C,S;d==="top"||d==="bottom"?(C=d,S=m===(await(s.isRTL==null?void 0:s.isRTL(a.floating))?"start":"end")?"left":"right"):(S=d,C=m==="end"?"top":"bottom");const A=x-f.top-f.bottom,T=w-f.left-f.right,O=Ri(x-f[C],A),D=Ri(w-f[S],T),L=!e.middlewareData.shift;let I=O,V=D;if((n=e.middlewareData.shift)!=null&&n.enabled.x&&(V=T),(r=e.middlewareData.shift)!=null&&r.enabled.y&&(I=A),L&&!m){const H=An(f.left,0),K=An(f.right,0),W=An(f.top,0),J=An(f.bottom,0);v?V=w-2*(H!==0||K!==0?H+K:An(f.left,f.right)):I=x-2*(W!==0||J!==0?W+J:An(f.top,f.bottom))}await c({...e,availableWidth:V,availableHeight:I});const F=await s.getDimensions(a.floating);return w!==F.width||x!==F.height?{reset:{rects:!0}}:{}}}};function eh(){return typeof window<"u"}function Os(t){return zw(t)?(t.nodeName||"").toLowerCase():"#document"}function kn(t){var e;return(t==null||(e=t.ownerDocument)==null?void 0:e.defaultView)||window}function Ar(t){var e;return(e=(zw(t)?t.ownerDocument:t.document)||window.document)==null?void 0:e.documentElement}function zw(t){return eh()?t instanceof Node||t instanceof kn(t).Node:!1}function Qn(t){return eh()?t instanceof Element||t instanceof kn(t).Element:!1}function $r(t){return eh()?t instanceof HTMLElement||t instanceof kn(t).HTMLElement:!1}function Tv(t){return!eh()||typeof ShadowRoot>"u"?!1:t instanceof ShadowRoot||t instanceof kn(t).ShadowRoot}function Qa(t){const{overflow:e,overflowX:n,overflowY:r,display:i}=Jn(t);return/auto|scroll|overlay|hidden|clip/.test(e+r+n)&&!["inline","contents"].includes(i)}function wM(t){return["table","td","th"].includes(Os(t))}function th(t){return[":popover-open",":modal"].some(e=>{try{return t.matches(e)}catch{return!1}})}function Q1(t){const e=J1(),n=Qn(t)?Jn(t):t;return["transform","translate","scale","rotate","perspective"].some(r=>n[r]?n[r]!=="none":!1)||(n.containerType?n.containerType!=="normal":!1)||!e&&(n.backdropFilter?n.backdropFilter!=="none":!1)||!e&&(n.filter?n.filter!=="none":!1)||["transform","translate","scale","rotate","perspective","filter"].some(r=>(n.willChange||"").includes(r))||["paint","layout","strict","content"].some(r=>(n.contain||"").includes(r))}function xM(t){let e=Ti(t);for(;$r(e)&&!vs(e);){if(Q1(e))return e;if(th(e))return null;e=Ti(e)}return null}function J1(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}function vs(t){return["html","body","#document"].includes(Os(t))}function Jn(t){return kn(t).getComputedStyle(t)}function nh(t){return Qn(t)?{scrollLeft:t.scrollLeft,scrollTop:t.scrollTop}:{scrollLeft:t.scrollX,scrollTop:t.scrollY}}function Ti(t){if(Os(t)==="html")return t;const e=t.assignedSlot||t.parentNode||Tv(t)&&t.host||Ar(t);return Tv(e)?e.host:e}function Uw(t){const e=Ti(t);return vs(e)?t.ownerDocument?t.ownerDocument.body:t.body:$r(e)&&Qa(e)?e:Uw(e)}function Ta(t,e,n){var r;e===void 0&&(e=[]),n===void 0&&(n=!0);const i=Uw(t),o=i===((r=t.ownerDocument)==null?void 0:r.body),s=kn(i);if(o){const a=p0(s);return e.concat(s,s.visualViewport||[],Qa(i)?i:[],a&&n?Ta(a):[])}return e.concat(i,Ta(i,[],n))}function p0(t){return t.parent&&Object.getPrototypeOf(t.parent)?t.frameElement:null}function qw(t){const e=Jn(t);let n=parseFloat(e.width)||0,r=parseFloat(e.height)||0;const i=$r(t),o=i?t.offsetWidth:n,s=i?t.offsetHeight:r,a=fu(n)!==o||fu(r)!==s;return a&&(n=o,r=s),{width:n,height:r,$:a}}function eg(t){return Qn(t)?t:t.contextElement}function rs(t){const e=eg(t);if(!$r(e))return wr(1);const n=e.getBoundingClientRect(),{width:r,height:i,$:o}=qw(e);let s=(o?fu(n.width):n.width)/r,a=(o?fu(n.height):n.height)/i;return(!s||!Number.isFinite(s))&&(s=1),(!a||!Number.isFinite(a))&&(a=1),{x:s,y:a}}const yM=wr(0);function Kw(t){const e=kn(t);return!J1()||!e.visualViewport?yM:{x:e.visualViewport.offsetLeft,y:e.visualViewport.offsetTop}}function CM(t,e,n){return e===void 0&&(e=!1),!n||e&&n!==kn(t)?!1:e}function ho(t,e,n,r){e===void 0&&(e=!1),n===void 0&&(n=!1);const i=t.getBoundingClientRect(),o=eg(t);let s=wr(1);e&&(r?Qn(r)&&(s=rs(r)):s=rs(t));const a=CM(o,n,r)?Kw(o):wr(0);let c=(i.left+a.x)/s.x,h=(i.top+a.y)/s.y,f=i.width/s.x,d=i.height/s.y;if(o){const m=kn(o),v=r&&Qn(r)?kn(r):r;let w=m,x=p0(w);for(;x&&r&&v!==w;){const C=rs(x),S=x.getBoundingClientRect(),A=Jn(x),T=S.left+(x.clientLeft+parseFloat(A.paddingLeft))*C.x,O=S.top+(x.clientTop+parseFloat(A.paddingTop))*C.y;c*=C.x,h*=C.y,f*=C.x,d*=C.y,c+=T,h+=O,w=kn(x),x=p0(w)}}return gu({width:f,height:d,x:c,y:h})}function tg(t,e){const n=nh(t).scrollLeft;return e?e.left+n:ho(Ar(t)).left+n}function Gw(t,e,n){n===void 0&&(n=!1);const r=t.getBoundingClientRect(),i=r.left+e.scrollLeft-(n?0:tg(t,r)),o=r.top+e.scrollTop;return{x:i,y:o}}function $M(t){let{elements:e,rect:n,offsetParent:r,strategy:i}=t;const o=i==="fixed",s=Ar(r),a=e?th(e.floating):!1;if(r===s||a&&o)return n;let c={scrollLeft:0,scrollTop:0},h=wr(1);const f=wr(0),d=$r(r);if((d||!d&&!o)&&((Os(r)!=="body"||Qa(s))&&(c=nh(r)),$r(r))){const v=ho(r);h=rs(r),f.x=v.x+r.clientLeft,f.y=v.y+r.clientTop}const m=s&&!d&&!o?Gw(s,c,!0):wr(0);return{width:n.width*h.x,height:n.height*h.y,x:n.x*h.x-c.scrollLeft*h.x+f.x+m.x,y:n.y*h.y-c.scrollTop*h.y+f.y+m.y}}function SM(t){return Array.from(t.getClientRects())}function AM(t){const e=Ar(t),n=nh(t),r=t.ownerDocument.body,i=An(e.scrollWidth,e.clientWidth,r.scrollWidth,r.clientWidth),o=An(e.scrollHeight,e.clientHeight,r.scrollHeight,r.clientHeight);let s=-n.scrollLeft+tg(t);const a=-n.scrollTop;return Jn(r).direction==="rtl"&&(s+=An(e.clientWidth,r.clientWidth)-i),{width:i,height:o,x:s,y:a}}function RM(t,e){const n=kn(t),r=Ar(t),i=n.visualViewport;let o=r.clientWidth,s=r.clientHeight,a=0,c=0;if(i){o=i.width,s=i.height;const h=J1();(!h||h&&e==="fixed")&&(a=i.offsetLeft,c=i.offsetTop)}return{width:o,height:s,x:a,y:c}}function kM(t,e){const n=ho(t,!0,e==="fixed"),r=n.top+t.clientTop,i=n.left+t.clientLeft,o=$r(t)?rs(t):wr(1),s=t.clientWidth*o.x,a=t.clientHeight*o.y,c=i*o.x,h=r*o.y;return{width:s,height:a,x:c,y:h}}function Mv(t,e,n){let r;if(e==="viewport")r=RM(t,n);else if(e==="document")r=AM(Ar(t));else if(Qn(e))r=kM(e,n);else{const i=Kw(t);r={x:e.x-i.x,y:e.y-i.y,width:e.width,height:e.height}}return gu(r)}function Yw(t,e){const n=Ti(t);return n===e||!Qn(n)||vs(n)?!1:Jn(n).position==="fixed"||Yw(n,e)}function TM(t,e){const n=e.get(t);if(n)return n;let r=Ta(t,[],!1).filter(a=>Qn(a)&&Os(a)!=="body"),i=null;const o=Jn(t).position==="fixed";let s=o?Ti(t):t;for(;Qn(s)&&!vs(s);){const a=Jn(s),c=Q1(s);!c&&a.position==="fixed"&&(i=null),(o?!c&&!i:!c&&a.position==="static"&&!!i&&["absolute","fixed"].includes(i.position)||Qa(s)&&!c&&Yw(t,s))?r=r.filter(f=>f!==s):i=a,s=Ti(s)}return e.set(t,r),r}function MM(t){let{element:e,boundary:n,rootBoundary:r,strategy:i}=t;const s=[...n==="clippingAncestors"?th(e)?[]:TM(e,this._c):[].concat(n),r],a=s[0],c=s.reduce((h,f)=>{const d=Mv(e,f,i);return h.top=An(d.top,h.top),h.right=Ri(d.right,h.right),h.bottom=Ri(d.bottom,h.bottom),h.left=An(d.left,h.left),h},Mv(e,a,i));return{width:c.right-c.left,height:c.bottom-c.top,x:c.left,y:c.top}}function EM(t){const{width:e,height:n}=qw(t);return{width:e,height:n}}function OM(t,e,n){const r=$r(e),i=Ar(e),o=n==="fixed",s=ho(t,!0,o,e);let a={scrollLeft:0,scrollTop:0};const c=wr(0);if(r||!r&&!o)if((Os(e)!=="body"||Qa(i))&&(a=nh(e)),r){const m=ho(e,!0,o,e);c.x=m.x+e.clientLeft,c.y=m.y+e.clientTop}else i&&(c.x=tg(i));const h=i&&!r&&!o?Gw(i,a):wr(0),f=s.left+a.scrollLeft-c.x-h.x,d=s.top+a.scrollTop-c.y-h.y;return{x:f,y:d,width:s.width,height:s.height}}function md(t){return Jn(t).position==="static"}function Ev(t,e){if(!$r(t)||Jn(t).position==="fixed")return null;if(e)return e(t);let n=t.offsetParent;return Ar(t)===n&&(n=n.ownerDocument.body),n}function Xw(t,e){const n=kn(t);if(th(t))return n;if(!$r(t)){let i=Ti(t);for(;i&&!vs(i);){if(Qn(i)&&!md(i))return i;i=Ti(i)}return n}let r=Ev(t,e);for(;r&&wM(r)&&md(r);)r=Ev(r,e);return r&&vs(r)&&md(r)&&!Q1(r)?n:r||xM(t)||n}const DM=async function(t){const e=this.getOffsetParent||Xw,n=this.getDimensions,r=await n(t.floating);return{reference:OM(t.reference,await e(t.floating),t.strategy),floating:{x:0,y:0,width:r.width,height:r.height}}};function IM(t){return Jn(t).direction==="rtl"}const _M={convertOffsetParentRelativeRectToViewportRelativeRect:$M,getDocumentElement:Ar,getClippingRect:MM,getOffsetParent:Xw,getElementRects:DM,getClientRects:SM,getDimensions:EM,getScale:rs,isElement:Qn,isRTL:IM};function Zw(t,e){return t.x===e.x&&t.y===e.y&&t.width===e.width&&t.height===e.height}function LM(t,e){let n=null,r;const i=Ar(t);function o(){var a;clearTimeout(r),(a=n)==null||a.disconnect(),n=null}function s(a,c){a===void 0&&(a=!1),c===void 0&&(c=1),o();const h=t.getBoundingClientRect(),{left:f,top:d,width:m,height:v}=h;if(a||e(),!m||!v)return;const w=fc(d),x=fc(i.clientWidth-(f+m)),C=fc(i.clientHeight-(d+v)),S=fc(f),T={rootMargin:-w+"px "+-x+"px "+-C+"px "+-S+"px",threshold:An(0,Ri(1,c))||1};let O=!0;function D(L){const I=L[0].intersectionRatio;if(I!==c){if(!O)return s();I?s(!1,I):r=setTimeout(()=>{s(!1,1e-7)},1e3)}I===1&&!Zw(h,t.getBoundingClientRect())&&s(),O=!1}try{n=new IntersectionObserver(D,{...T,root:i.ownerDocument})}catch{n=new IntersectionObserver(D,T)}n.observe(t)}return s(!0),o}function Qw(t,e,n,r){r===void 0&&(r={});const{ancestorScroll:i=!0,ancestorResize:o=!0,elementResize:s=typeof ResizeObserver=="function",layoutShift:a=typeof IntersectionObserver=="function",animationFrame:c=!1}=r,h=eg(t),f=i||o?[...h?Ta(h):[],...Ta(e)]:[];f.forEach(S=>{i&&S.addEventListener("scroll",n,{passive:!0}),o&&S.addEventListener("resize",n)});const d=h&&a?LM(h,n):null;let m=-1,v=null;s&&(v=new ResizeObserver(S=>{let[A]=S;A&&A.target===h&&v&&(v.unobserve(e),cancelAnimationFrame(m),m=requestAnimationFrame(()=>{var T;(T=v)==null||T.observe(e)})),n()}),h&&!c&&v.observe(h),v.observe(e));let w,x=c?ho(t):null;c&&C();function C(){const S=ho(t);x&&!Zw(x,S)&&n(),x=S,w=requestAnimationFrame(C)}return n(),()=>{var S;f.forEach(A=>{i&&A.removeEventListener("scroll",n),o&&A.removeEventListener("resize",n)}),d?.(),(S=v)==null||S.disconnect(),v=null,c&&cancelAnimationFrame(w)}}const Jw=mM,ex=pM,tx=fM,BM=bM,NM=dM,Ov=hM,jM=vM,nx=(t,e,n)=>{const r=new Map,i={platform:_M,...n},o={...i.platform,_c:r};return uM(t,e,{...i,platform:o})};var Yc=typeof document<"u"?b.useLayoutEffect:b.useEffect;function mu(t,e){if(t===e)return!0;if(typeof t!=typeof e)return!1;if(typeof t=="function"&&t.toString()===e.toString())return!0;let n,r,i;if(t&&e&&typeof t=="object"){if(Array.isArray(t)){if(n=t.length,n!==e.length)return!1;for(r=n;r--!==0;)if(!mu(t[r],e[r]))return!1;return!0}if(i=Object.keys(t),n=i.length,n!==Object.keys(e).length)return!1;for(r=n;r--!==0;)if(!{}.hasOwnProperty.call(e,i[r]))return!1;for(r=n;r--!==0;){const o=i[r];if(!(o==="_owner"&&t.$$typeof)&&!mu(t[o],e[o]))return!1}return!0}return t!==t&&e!==e}function rx(t){return typeof window>"u"?1:(t.ownerDocument.defaultView||window).devicePixelRatio||1}function Dv(t,e){const n=rx(t);return Math.round(e*n)/n}function pd(t){const e=$.useRef(t);return Yc(()=>{e.current=t}),e}function FM(t){t===void 0&&(t={});const{placement:e="bottom",strategy:n="absolute",middleware:r=[],platform:i,elements:{reference:o,floating:s}={},transform:a=!0,whileElementsMounted:c,open:h}=t,[f,d]=$.useState({x:0,y:0,strategy:n,placement:e,middlewareData:{},isPositioned:!1}),[m,v]=$.useState(r);mu(m,r)||v(r);const[w,x]=$.useState(null),[C,S]=$.useState(null),A=$.useCallback(ie=>{ie!==L.current&&(L.current=ie,x(ie))},[]),T=$.useCallback(ie=>{ie!==I.current&&(I.current=ie,S(ie))},[]),O=o||w,D=s||C,L=$.useRef(null),I=$.useRef(null),V=$.useRef(f),F=c!=null,H=pd(c),K=pd(i),W=pd(h),J=$.useCallback(()=>{if(!L.current||!I.current)return;const ie={placement:e,strategy:n,middleware:m};K.current&&(ie.platform=K.current),nx(L.current,I.current,ie).then(Y=>{const ue={...Y,isPositioned:W.current!==!1};G.current&&!mu(V.current,ue)&&(V.current=ue,yo.flushSync(()=>{d(ue)}))})},[m,e,n,K,W]);Yc(()=>{h===!1&&V.current.isPositioned&&(V.current.isPositioned=!1,d(ie=>({...ie,isPositioned:!1})))},[h]);const G=$.useRef(!1);Yc(()=>(G.current=!0,()=>{G.current=!1}),[]),Yc(()=>{if(O&&(L.current=O),D&&(I.current=D),O&&D){if(H.current)return H.current(O,D,J);J()}},[O,D,J,H,F]);const re=$.useMemo(()=>({reference:L,floating:I,setReference:A,setFloating:T}),[A,T]),oe=$.useMemo(()=>({reference:O,floating:D}),[O,D]),te=$.useMemo(()=>{const ie={position:n,left:0,top:0};if(!oe.floating)return ie;const Y=Dv(oe.floating,f.x),ue=Dv(oe.floating,f.y);return a?{...ie,transform:"translate("+Y+"px, "+ue+"px)",...rx(oe.floating)>=1.5&&{willChange:"transform"}}:{position:n,left:Y,top:ue}},[n,a,oe.floating,f.x,f.y]);return $.useMemo(()=>({...f,update:J,refs:re,elements:oe,floatingStyles:te}),[f,J,re,oe,te])}const VM=t=>{function e(n){return{}.hasOwnProperty.call(n,"current")}return{name:"arrow",options:t,fn(n){const{element:r,padding:i}=typeof t=="function"?t(n):t;return r&&e(r)?r.current!=null?Ov({element:r.current,padding:i}).fn(n):{}:r?Ov({element:r,padding:i}).fn(n):{}}}},HM=(t,e)=>({...Jw(t),options:[t,e]}),PM=(t,e)=>({...ex(t),options:[t,e]}),WM=(t,e)=>({...jM(t),options:[t,e]}),zM=(t,e)=>({...tx(t),options:[t,e]}),UM=(t,e)=>({...BM(t),options:[t,e]}),qM=(t,e)=>({...NM(t),options:[t,e]}),KM=(t,e)=>({...VM(t),options:[t,e]}),GM=b.forwardRef((t,e)=>{const{children:n,width:r=10,height:i=5,...o}=t;return b.createElement(me.svg,U({},o,{ref:e,width:r,height:i,viewBox:"0 0 30 10",preserveAspectRatio:"none"}),t.asChild?n:b.createElement("polygon",{points:"0,0 30,0 15,10"}))}),YM=GM;function rh(t){const[e,n]=b.useState(void 0);return ut(()=>{if(t){n({width:t.offsetWidth,height:t.offsetHeight});const r=new ResizeObserver(i=>{if(!Array.isArray(i)||!i.length)return;const o=i[0];let s,a;if("borderBoxSize"in o){const c=o.borderBoxSize,h=Array.isArray(c)?c[0]:c;s=h.inlineSize,a=h.blockSize}else s=t.offsetWidth,a=t.offsetHeight;n({width:s,height:a})});return r.observe(t,{box:"border-box"}),()=>r.unobserve(t)}else n(void 0)},[t]),e}const ix="Popper",[ox,Li]=bt(ix),[XM,sx]=ox(ix),ZM=t=>{const{__scopePopper:e,children:n}=t,[r,i]=b.useState(null);return b.createElement(XM,{scope:e,anchor:r,onAnchorChange:i},n)},QM="PopperAnchor",JM=b.forwardRef((t,e)=>{const{__scopePopper:n,virtualRef:r,...i}=t,o=sx(QM,n),s=b.useRef(null),a=ye(e,s);return b.useEffect(()=>{o.onAnchorChange(r?.current||s.current)}),r?null:b.createElement(me.div,U({},i,{ref:a}))}),ax="PopperContent",[eE,tE]=ox(ax),nE=b.forwardRef((t,e)=>{var n,r,i,o,s,a,c,h;const{__scopePopper:f,side:d="bottom",sideOffset:m=0,align:v="center",alignOffset:w=0,arrowPadding:x=0,avoidCollisions:C=!0,collisionBoundary:S=[],collisionPadding:A=0,sticky:T="partial",hideWhenDetached:O=!1,updatePositionStrategy:D="optimized",onPlaced:L,...I}=t,V=sx(ax,f),[F,H]=b.useState(null),K=ye(e,Pe=>H(Pe)),[W,J]=b.useState(null),G=rh(W),re=(n=G?.width)!==null&&n!==void 0?n:0,oe=(r=G?.height)!==null&&r!==void 0?r:0,te=d+(v!=="center"?"-"+v:""),ie=typeof A=="number"?A:{top:0,right:0,bottom:0,left:0,...A},Y=Array.isArray(S)?S:[S],ue=Y.length>0,ge={padding:ie,boundary:Y.filter(sE),altBoundary:ue},{refs:De,floatingStyles:we,placement:Ve,isPositioned:Ne,middlewareData:He}=FM({strategy:"fixed",placement:te,whileElementsMounted:(...Pe)=>Qw(...Pe,{animationFrame:D==="always"}),elements:{reference:V.anchor},middleware:[HM({mainAxis:m+oe,alignmentAxis:w}),C&&PM({mainAxis:!0,crossAxis:!1,limiter:T==="partial"?WM():void 0,...ge}),C&&zM({...ge}),UM({...ge,apply:({elements:Pe,rects:Yt,availableWidth:ft,availableHeight:Hi})=>{const{width:Ps,height:or}=Yt.reference,wt=Pe.floating.style;wt.setProperty("--radix-popper-available-width",`${ft}px`),wt.setProperty("--radix-popper-available-height",`${Hi}px`),wt.setProperty("--radix-popper-anchor-width",`${Ps}px`),wt.setProperty("--radix-popper-anchor-height",`${or}px`)}}),W&&KM({element:W,padding:x}),aE({arrowWidth:re,arrowHeight:oe}),O&&qM({strategy:"referenceHidden",...ge})]}),[pe,Oe]=lx(Ve),ke=Ct(L);ut(()=>{Ne&&ke?.()},[Ne,ke]);const Ae=(i=He.arrow)===null||i===void 0?void 0:i.x,_e=(o=He.arrow)===null||o===void 0?void 0:o.y,ze=((s=He.arrow)===null||s===void 0?void 0:s.centerOffset)!==0,[Et,Ze]=b.useState();return ut(()=>{F&&Ze(window.getComputedStyle(F).zIndex)},[F]),b.createElement("div",{ref:De.setFloating,"data-radix-popper-content-wrapper":"",style:{...we,transform:Ne?we.transform:"translate(0, -200%)",minWidth:"max-content",zIndex:Et,"--radix-popper-transform-origin":[(a=He.transformOrigin)===null||a===void 0?void 0:a.x,(c=He.transformOrigin)===null||c===void 0?void 0:c.y].join(" ")},dir:t.dir},b.createElement(eE,{scope:f,placedSide:pe,onArrowChange:J,arrowX:Ae,arrowY:_e,shouldHideArrow:ze},b.createElement(me.div,U({"data-side":pe,"data-align":Oe},I,{ref:K,style:{...I.style,animation:Ne?void 0:"none",opacity:(h=He.hide)!==null&&h!==void 0&&h.referenceHidden?0:void 0}}))))}),rE="PopperArrow",iE={top:"bottom",right:"left",bottom:"top",left:"right"},oE=b.forwardRef(function(e,n){const{__scopePopper:r,...i}=e,o=tE(rE,r),s=iE[o.placedSide];return b.createElement("span",{ref:o.onArrowChange,style:{position:"absolute",left:o.arrowX,top:o.arrowY,[s]:0,transformOrigin:{top:"",right:"0 0",bottom:"center 0",left:"100% 0"}[o.placedSide],transform:{top:"translateY(100%)",right:"translateY(50%) rotate(90deg) translateX(-50%)",bottom:"rotate(180deg)",left:"translateY(50%) rotate(-90deg) translateX(50%)"}[o.placedSide],visibility:o.shouldHideArrow?"hidden":void 0}},b.createElement(YM,U({},i,{ref:n,style:{...i.style,display:"block"}})))});function sE(t){return t!==null}const aE=t=>({name:"transformOrigin",options:t,fn(e){var n,r,i,o,s;const{placement:a,rects:c,middlewareData:h}=e,d=((n=h.arrow)===null||n===void 0?void 0:n.centerOffset)!==0,m=d?0:t.arrowWidth,v=d?0:t.arrowHeight,[w,x]=lx(a),C={start:"0%",center:"50%",end:"100%"}[x],S=((r=(i=h.arrow)===null||i===void 0?void 0:i.x)!==null&&r!==void 0?r:0)+m/2,A=((o=(s=h.arrow)===null||s===void 0?void 0:s.y)!==null&&o!==void 0?o:0)+v/2;let T="",O="";return w==="bottom"?(T=d?C:`${S}px`,O=`${-v}px`):w==="top"?(T=d?C:`${S}px`,O=`${c.floating.height+v}px`):w==="right"?(T=`${-v}px`,O=d?C:`${A}px`):w==="left"&&(T=`${c.floating.width+v}px`,O=d?C:`${A}px`),{data:{x:T,y:O}}}});function lx(t){const[e,n="center"]=t.split("-");return[e,n]}const Ja=ZM,el=JM,tl=nE,lE=oE,Ds=b.forwardRef((t,e)=>{var n;const{container:r=globalThis==null||(n=globalThis.document)===null||n===void 0?void 0:n.body,...i}=t;return r?yo.default.createPortal(b.createElement(me.div,U({},i,{ref:e})),r):null});function cE(t,e){return b.useReducer((n,r)=>{const i=e[n][r];return i??n},t)}const Mt=t=>{const{present:e,children:n}=t,r=uE(e),i=typeof n=="function"?n({present:r.isPresent}):b.Children.only(n),o=ye(r.ref,i.ref);return typeof n=="function"||r.isPresent?b.cloneElement(i,{ref:o}):null};Mt.displayName="Presence";function uE(t){const[e,n]=b.useState(),r=b.useRef({}),i=b.useRef(t),o=b.useRef("none"),s=t?"mounted":"unmounted",[a,c]=cE(s,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return b.useEffect(()=>{const h=dc(r.current);o.current=a==="mounted"?h:"none"},[a]),ut(()=>{const h=r.current,f=i.current;if(f!==t){const m=o.current,v=dc(h);t?c("MOUNT"):v==="none"||h?.display==="none"?c("UNMOUNT"):c(f&&m!==v?"ANIMATION_OUT":"UNMOUNT"),i.current=t}},[t,c]),ut(()=>{if(e){const h=d=>{const v=dc(r.current).includes(d.animationName);d.target===e&&v&&Za.flushSync(()=>c("ANIMATION_END"))},f=d=>{d.target===e&&(o.current=dc(r.current))};return e.addEventListener("animationstart",f),e.addEventListener("animationcancel",h),e.addEventListener("animationend",h),()=>{e.removeEventListener("animationstart",f),e.removeEventListener("animationcancel",h),e.removeEventListener("animationend",h)}}else c("ANIMATION_END")},[e,c]),{isPresent:["mounted","unmountSuspended"].includes(a),ref:b.useCallback(h=>{h&&(r.current=getComputedStyle(h)),n(h)},[])}}function dc(t){return t?.animationName||"none"}function _t({prop:t,defaultProp:e,onChange:n=()=>{}}){const[r,i]=hE({defaultProp:e,onChange:n}),o=t!==void 0,s=o?t:r,a=Ct(n),c=b.useCallback(h=>{if(o){const d=typeof h=="function"?h(t):h;d!==t&&a(d)}else i(h)},[o,t,i,a]);return[s,c]}function hE({defaultProp:t,onChange:e}){const n=b.useState(t),[r]=n,i=b.useRef(r),o=Ct(e);return b.useEffect(()=>{i.current!==r&&(o(r),i.current=r)},[r,i,o]),n}const cx=b.forwardRef((t,e)=>b.createElement(me.span,U({},t,{ref:e,style:{position:"absolute",border:0,width:1,height:1,padding:0,margin:-1,overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",wordWrap:"normal",...t.style}}))),fE=cx,[ih,Wee]=bt("Tooltip",[Li]),ng=Li(),dE="TooltipProvider",gE=700,v0="tooltip.open",[mE,rg]=ih(dE),pE=t=>{const{__scopeTooltip:e,delayDuration:n=gE,skipDelayDuration:r=300,disableHoverableContent:i=!1,children:o}=t,[s,a]=b.useState(!0),c=b.useRef(!1),h=b.useRef(0);return b.useEffect(()=>{const f=h.current;return()=>window.clearTimeout(f)},[]),b.createElement(mE,{scope:e,isOpenDelayed:s,delayDuration:n,onOpen:b.useCallback(()=>{window.clearTimeout(h.current),a(!1)},[]),onClose:b.useCallback(()=>{window.clearTimeout(h.current),h.current=window.setTimeout(()=>a(!0),r)},[r]),isPointerInTransitRef:c,onPointerInTransitChange:b.useCallback(f=>{c.current=f},[]),disableHoverableContent:i},o)},ig="Tooltip",[vE,nl]=ih(ig),bE=t=>{const{__scopeTooltip:e,children:n,open:r,defaultOpen:i=!1,onOpenChange:o,disableHoverableContent:s,delayDuration:a}=t,c=rg(ig,t.__scopeTooltip),h=ng(e),[f,d]=b.useState(null),m=Lt(),v=b.useRef(0),w=s??c.disableHoverableContent,x=a??c.delayDuration,C=b.useRef(!1),[S=!1,A]=_t({prop:r,defaultProp:i,onChange:I=>{I?(c.onOpen(),document.dispatchEvent(new CustomEvent(v0))):c.onClose(),o?.(I)}}),T=b.useMemo(()=>S?C.current?"delayed-open":"instant-open":"closed",[S]),O=b.useCallback(()=>{window.clearTimeout(v.current),C.current=!1,A(!0)},[A]),D=b.useCallback(()=>{window.clearTimeout(v.current),A(!1)},[A]),L=b.useCallback(()=>{window.clearTimeout(v.current),v.current=window.setTimeout(()=>{C.current=!0,A(!0)},x)},[x,A]);return b.useEffect(()=>()=>window.clearTimeout(v.current),[]),b.createElement(Ja,h,b.createElement(vE,{scope:e,contentId:m,open:S,stateAttribute:T,trigger:f,onTriggerChange:d,onTriggerEnter:b.useCallback(()=>{c.isOpenDelayed?L():O()},[c.isOpenDelayed,L,O]),onTriggerLeave:b.useCallback(()=>{w?D():window.clearTimeout(v.current)},[D,w]),onOpen:O,onClose:D,disableHoverableContent:w},n))},Iv="TooltipTrigger",wE=b.forwardRef((t,e)=>{const{__scopeTooltip:n,...r}=t,i=nl(Iv,n),o=rg(Iv,n),s=ng(n),a=b.useRef(null),c=ye(e,a,i.onTriggerChange),h=b.useRef(!1),f=b.useRef(!1),d=b.useCallback(()=>h.current=!1,[]);return b.useEffect(()=>()=>document.removeEventListener("pointerup",d),[d]),b.createElement(el,U({asChild:!0},s),b.createElement(me.button,U({"aria-describedby":i.open?i.contentId:void 0,"data-state":i.stateAttribute},r,{ref:c,onPointerMove:ne(t.onPointerMove,m=>{m.pointerType!=="touch"&&!f.current&&!o.isPointerInTransitRef.current&&(i.onTriggerEnter(),f.current=!0)}),onPointerLeave:ne(t.onPointerLeave,()=>{i.onTriggerLeave(),f.current=!1}),onPointerDown:ne(t.onPointerDown,()=>{h.current=!0,document.addEventListener("pointerup",d,{once:!0})}),onFocus:ne(t.onFocus,()=>{h.current||i.onOpen()}),onBlur:ne(t.onBlur,i.onClose),onClick:ne(t.onClick,i.onClose)})))}),ux="TooltipPortal",[xE,yE]=ih(ux,{forceMount:void 0}),CE=t=>{const{__scopeTooltip:e,forceMount:n,children:r,container:i}=t,o=nl(ux,e);return b.createElement(xE,{scope:e,forceMount:n},b.createElement(Mt,{present:n||o.open},b.createElement(Ds,{asChild:!0,container:i},r)))},Ma="TooltipContent",$E=b.forwardRef((t,e)=>{const n=yE(Ma,t.__scopeTooltip),{forceMount:r=n.forceMount,side:i="top",...o}=t,s=nl(Ma,t.__scopeTooltip);return b.createElement(Mt,{present:r||s.open},s.disableHoverableContent?b.createElement(hx,U({side:i},o,{ref:e})):b.createElement(SE,U({side:i},o,{ref:e})))}),SE=b.forwardRef((t,e)=>{const n=nl(Ma,t.__scopeTooltip),r=rg(Ma,t.__scopeTooltip),i=b.useRef(null),o=ye(e,i),[s,a]=b.useState(null),{trigger:c,onClose:h}=n,f=i.current,{onPointerInTransitChange:d}=r,m=b.useCallback(()=>{a(null),d(!1)},[d]),v=b.useCallback((w,x)=>{const C=w.currentTarget,S={x:w.clientX,y:w.clientY},A=RE(S,C.getBoundingClientRect()),T=kE(S,A),O=TE(x.getBoundingClientRect()),D=EE([...T,...O]);a(D),d(!0)},[d]);return b.useEffect(()=>()=>m(),[m]),b.useEffect(()=>{if(c&&f){const w=C=>v(C,f),x=C=>v(C,c);return c.addEventListener("pointerleave",w),f.addEventListener("pointerleave",x),()=>{c.removeEventListener("pointerleave",w),f.removeEventListener("pointerleave",x)}}},[c,f,v,m]),b.useEffect(()=>{if(s){const w=x=>{const C=x.target,S={x:x.clientX,y:x.clientY},A=c?.contains(C)||f?.contains(C),T=!ME(S,s);A?m():T&&(m(),h())};return document.addEventListener("pointermove",w),()=>document.removeEventListener("pointermove",w)}},[c,f,s,h,m]),b.createElement(hx,U({},t,{ref:o}))}),[AE,zee]=ih(ig,{isInside:!1}),hx=b.forwardRef((t,e)=>{const{__scopeTooltip:n,children:r,"aria-label":i,onEscapeKeyDown:o,onPointerDownOutside:s,...a}=t,c=nl(Ma,n),h=ng(n),{onClose:f}=c;return b.useEffect(()=>(document.addEventListener(v0,f),()=>document.removeEventListener(v0,f)),[f]),b.useEffect(()=>{if(c.trigger){const d=m=>{const v=m.target;v!=null&&v.contains(c.trigger)&&f()};return window.addEventListener("scroll",d,{capture:!0}),()=>window.removeEventListener("scroll",d,{capture:!0})}},[c.trigger,f]),b.createElement(Co,{asChild:!0,disableOutsidePointerEvents:!1,onEscapeKeyDown:o,onPointerDownOutside:s,onFocusOutside:d=>d.preventDefault(),onDismiss:f},b.createElement(tl,U({"data-state":c.stateAttribute},h,a,{ref:e,style:{...a.style,"--radix-tooltip-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-tooltip-content-available-width":"var(--radix-popper-available-width)","--radix-tooltip-content-available-height":"var(--radix-popper-available-height)","--radix-tooltip-trigger-width":"var(--radix-popper-anchor-width)","--radix-tooltip-trigger-height":"var(--radix-popper-anchor-height)"}}),b.createElement(G1,null,r),b.createElement(AE,{scope:n,isInside:!0},b.createElement(fE,{id:c.contentId,role:"tooltip"},i||r))))});function RE(t,e){const n=Math.abs(e.top-t.y),r=Math.abs(e.bottom-t.y),i=Math.abs(e.right-t.x),o=Math.abs(e.left-t.x);switch(Math.min(n,r,i,o)){case o:return"left";case i:return"right";case n:return"top";case r:return"bottom";default:throw new Error("unreachable")}}function kE(t,e,n=5){const r=[];switch(e){case"top":r.push({x:t.x-n,y:t.y+n},{x:t.x+n,y:t.y+n});break;case"bottom":r.push({x:t.x-n,y:t.y-n},{x:t.x+n,y:t.y-n});break;case"left":r.push({x:t.x+n,y:t.y-n},{x:t.x+n,y:t.y+n});break;case"right":r.push({x:t.x-n,y:t.y-n},{x:t.x-n,y:t.y+n});break}return r}function TE(t){const{top:e,right:n,bottom:r,left:i}=t;return[{x:i,y:e},{x:n,y:e},{x:n,y:r},{x:i,y:r}]}function ME(t,e){const{x:n,y:r}=t;let i=!1;for(let o=0,s=e.length-1;o<e.length;s=o++){const a=e[o].x,c=e[o].y,h=e[s].x,f=e[s].y;c>r!=f>r&&n<(h-a)*(r-c)/(f-c)+a&&(i=!i)}return i}function EE(t){const e=t.slice();return e.sort((n,r)=>n.x<r.x?-1:n.x>r.x?1:n.y<r.y?-1:n.y>r.y?1:0),OE(e)}function OE(t){if(t.length<=1)return t.slice();const e=[];for(let r=0;r<t.length;r++){const i=t[r];for(;e.length>=2;){const o=e[e.length-1],s=e[e.length-2];if((o.x-s.x)*(i.y-s.y)>=(o.y-s.y)*(i.x-s.x))e.pop();else break}e.push(i)}e.pop();const n=[];for(let r=t.length-1;r>=0;r--){const i=t[r];for(;n.length>=2;){const o=n[n.length-1],s=n[n.length-2];if((o.x-s.x)*(i.y-s.y)>=(o.y-s.y)*(i.x-s.x))n.pop();else break}n.push(i)}return n.pop(),e.length===1&&n.length===1&&e[0].x===n[0].x&&e[0].y===n[0].y?e:e.concat(n)}const DE=pE,fx=bE,dx=wE,gx=CE,mx=$E;let vd=0;function Is(){b.useEffect(()=>{var t,e;const n=document.querySelectorAll("[data-radix-focus-guard]");return document.body.insertAdjacentElement("afterbegin",(t=n[0])!==null&&t!==void 0?t:_v()),document.body.insertAdjacentElement("beforeend",(e=n[1])!==null&&e!==void 0?e:_v()),vd++,()=>{vd===1&&document.querySelectorAll("[data-radix-focus-guard]").forEach(r=>r.remove()),vd--}},[])}function _v(){const t=document.createElement("span");return t.setAttribute("data-radix-focus-guard",""),t.tabIndex=0,t.style.cssText="outline: none; opacity: 0; position: fixed; pointer-events: none",t}const bd="focusScope.autoFocusOnMount",wd="focusScope.autoFocusOnUnmount",Lv={bubbles:!1,cancelable:!0},_s=b.forwardRef((t,e)=>{const{loop:n=!1,trapped:r=!1,onMountAutoFocus:i,onUnmountAutoFocus:o,...s}=t,[a,c]=b.useState(null),h=Ct(i),f=Ct(o),d=b.useRef(null),m=ye(e,x=>c(x)),v=b.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;b.useEffect(()=>{if(r){let x=function(T){if(v.paused||!a)return;const O=T.target;a.contains(O)?d.current=O:vi(d.current,{select:!0})},C=function(T){if(v.paused||!a)return;const O=T.relatedTarget;O!==null&&(a.contains(O)||vi(d.current,{select:!0}))},S=function(T){if(document.activeElement===document.body)for(const D of T)D.removedNodes.length>0&&vi(a)};document.addEventListener("focusin",x),document.addEventListener("focusout",C);const A=new MutationObserver(S);return a&&A.observe(a,{childList:!0,subtree:!0}),()=>{document.removeEventListener("focusin",x),document.removeEventListener("focusout",C),A.disconnect()}}},[r,a,v.paused]),b.useEffect(()=>{if(a){Nv.add(v);const x=document.activeElement;if(!a.contains(x)){const S=new CustomEvent(bd,Lv);a.addEventListener(bd,h),a.dispatchEvent(S),S.defaultPrevented||(IE(jE(px(a)),{select:!0}),document.activeElement===x&&vi(a))}return()=>{a.removeEventListener(bd,h),setTimeout(()=>{const S=new CustomEvent(wd,Lv);a.addEventListener(wd,f),a.dispatchEvent(S),S.defaultPrevented||vi(x??document.body,{select:!0}),a.removeEventListener(wd,f),Nv.remove(v)},0)}}},[a,h,f,v]);const w=b.useCallback(x=>{if(!n&&!r||v.paused)return;const C=x.key==="Tab"&&!x.altKey&&!x.ctrlKey&&!x.metaKey,S=document.activeElement;if(C&&S){const A=x.currentTarget,[T,O]=_E(A);T&&O?!x.shiftKey&&S===O?(x.preventDefault(),n&&vi(T,{select:!0})):x.shiftKey&&S===T&&(x.preventDefault(),n&&vi(O,{select:!0})):S===A&&x.preventDefault()}},[n,r,v.paused]);return b.createElement(me.div,U({tabIndex:-1},s,{ref:m,onKeyDown:w}))});function IE(t,{select:e=!1}={}){const n=document.activeElement;for(const r of t)if(vi(r,{select:e}),document.activeElement!==n)return}function _E(t){const e=px(t),n=Bv(e,t),r=Bv(e.reverse(),t);return[n,r]}function px(t){const e=[],n=document.createTreeWalker(t,NodeFilter.SHOW_ELEMENT,{acceptNode:r=>{const i=r.tagName==="INPUT"&&r.type==="hidden";return r.disabled||r.hidden||i?NodeFilter.FILTER_SKIP:r.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;n.nextNode();)e.push(n.currentNode);return e}function Bv(t,e){for(const n of t)if(!LE(n,{upTo:e}))return n}function LE(t,{upTo:e}){if(getComputedStyle(t).visibility==="hidden")return!0;for(;t;){if(e!==void 0&&t===e)return!1;if(getComputedStyle(t).display==="none")return!0;t=t.parentElement}return!1}function BE(t){return t instanceof HTMLInputElement&&"select"in t}function vi(t,{select:e=!1}={}){if(t&&t.focus){const n=document.activeElement;t.focus({preventScroll:!0}),t!==n&&BE(t)&&e&&t.select()}}const Nv=NE();function NE(){let t=[];return{add(e){const n=t[0];e!==n&&n?.pause(),t=jv(t,e),t.unshift(e)},remove(e){var n;t=jv(t,e),(n=t[0])===null||n===void 0||n.resume()}}}function jv(t,e){const n=[...t],r=n.indexOf(e);return r!==-1&&n.splice(r,1),n}function jE(t){return t.filter(e=>e.tagName!=="A")}var FE=function(t){if(typeof document>"u")return null;var e=Array.isArray(t)?t[0]:t;return e.ownerDocument.body},Wo=new WeakMap,gc=new WeakMap,mc={},xd=0,vx=function(t){return t&&(t.host||vx(t.parentNode))},VE=function(t,e){return e.map(function(n){if(t.contains(n))return n;var r=vx(n);return r&&t.contains(r)?r:(console.error("aria-hidden",n,"in not contained inside",t,". Doing nothing"),null)}).filter(function(n){return!!n})},HE=function(t,e,n,r){var i=VE(e,Array.isArray(t)?t:[t]);mc[n]||(mc[n]=new WeakMap);var o=mc[n],s=[],a=new Set,c=new Set(i),h=function(d){!d||a.has(d)||(a.add(d),h(d.parentNode))};i.forEach(h);var f=function(d){!d||c.has(d)||Array.prototype.forEach.call(d.children,function(m){if(a.has(m))f(m);else try{var v=m.getAttribute(r),w=v!==null&&v!=="false",x=(Wo.get(m)||0)+1,C=(o.get(m)||0)+1;Wo.set(m,x),o.set(m,C),s.push(m),x===1&&w&&gc.set(m,!0),C===1&&m.setAttribute(n,"true"),w||m.setAttribute(r,"true")}catch(S){console.error("aria-hidden: cannot operate on ",m,S)}})};return f(e),a.clear(),xd++,function(){s.forEach(function(d){var m=Wo.get(d)-1,v=o.get(d)-1;Wo.set(d,m),o.set(d,v),m||(gc.has(d)||d.removeAttribute(r),gc.delete(d)),v||d.removeAttribute(n)}),xd--,xd||(Wo=new WeakMap,Wo=new WeakMap,gc=new WeakMap,mc={})}},rl=function(t,e,n){n===void 0&&(n="data-aria-hidden");var r=Array.from(Array.isArray(t)?t:[t]),i=FE(t);return i?(r.push.apply(r,Array.from(i.querySelectorAll("[aria-live]"))),HE(r,i,n,"aria-hidden")):function(){return null}};exports.__assign=function(){return exports.__assign=Object.assign||function(e){for(var n,r=1,i=arguments.length;r<i;r++){n=arguments[r];for(var o in n)Object.prototype.hasOwnProperty.call(n,o)&&(e[o]=n[o])}return e},exports.__assign.apply(this,arguments)};function il(t,e){var n={};for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&e.indexOf(r)<0&&(n[r]=t[r]);if(t!=null&&typeof Object.getOwnPropertySymbols=="function")for(var i=0,r=Object.getOwnPropertySymbols(t);i<r.length;i++)e.indexOf(r[i])<0&&Object.prototype.propertyIsEnumerable.call(t,r[i])&&(n[r[i]]=t[r[i]]);return n}function og(t,e,n){if(n||arguments.length===2)for(var r=0,i=e.length,o;r<i;r++)(o||!(r in e))&&(o||(o=Array.prototype.slice.call(e,0,r)),o[r]=e[r]);return t.concat(o||Array.prototype.slice.call(e))}var is="right-scroll-bar-position",os="width-before-scroll-bar",PE="with-scroll-bars-hidden",WE="--removed-body-scroll-bar-size";function yd(t,e){return typeof t=="function"?t(e):t&&(t.current=e),t}function zE(t,e){var n=b.useState(function(){return{value:t,callback:e,facade:{get current(){return n.value},set current(r){var i=n.value;i!==r&&(n.value=r,n.callback(r,i))}}}})[0];return n.callback=e,n.facade}var UE=typeof window<"u"?$.useLayoutEffect:$.useEffect,Fv=new WeakMap;function sg(t,e){var n=zE(null,function(r){return t.forEach(function(i){return yd(i,r)})});return UE(function(){var r=Fv.get(n);if(r){var i=new Set(r),o=new Set(t),s=n.current;i.forEach(function(a){o.has(a)||yd(a,null)}),o.forEach(function(a){i.has(a)||yd(a,s)})}Fv.set(n,t)},[t]),n}function qE(t){return t}function KE(t,e){e===void 0&&(e=qE);var n=[],r=!1,i={read:function(){if(r)throw new Error("Sidecar: could not `read` from an `assigned` medium. `read` could be used only with `useMedium`.");return n.length?n[n.length-1]:t},useMedium:function(o){var s=e(o,r);return n.push(s),function(){n=n.filter(function(a){return a!==s})}},assignSyncMedium:function(o){for(r=!0;n.length;){var s=n;n=[],s.forEach(o)}n={push:function(a){return o(a)},filter:function(){return n}}},assignMedium:function(o){r=!0;var s=[];if(n.length){var a=n;n=[],a.forEach(o),s=n}var c=function(){var f=s;s=[],f.forEach(o)},h=function(){return Promise.resolve().then(c)};h(),n={push:function(f){s.push(f),h()},filter:function(f){return s=s.filter(f),n}}}};return i}function ag(t){t===void 0&&(t={});var e=KE(null);return e.options=exports.__assign({async:!0,ssr:!1},t),e}var bx=function(t){var e=t.sideCar,n=il(t,["sideCar"]);if(!e)throw new Error("Sidecar: please provide `sideCar` property to import the right car");var r=e.read();if(!r)throw new Error("Sidecar medium not found");return $.createElement(r,exports.__assign({},n))};bx.isSideCarExport=!0;function lg(t,e){return t.useMedium(e),bx}var wx=ag(),Cd=function(){},oh=$.forwardRef(function(t,e){var n=$.useRef(null),r=$.useState({onScrollCapture:Cd,onWheelCapture:Cd,onTouchMoveCapture:Cd}),i=r[0],o=r[1],s=t.forwardProps,a=t.children,c=t.className,h=t.removeScrollBar,f=t.enabled,d=t.shards,m=t.sideCar,v=t.noIsolation,w=t.inert,x=t.allowPinchZoom,C=t.as,S=C===void 0?"div":C,A=t.gapMode,T=il(t,["forwardProps","children","className","removeScrollBar","enabled","shards","sideCar","noIsolation","inert","allowPinchZoom","as","gapMode"]),O=m,D=sg([n,e]),L=exports.__assign(exports.__assign({},T),i);return $.createElement($.Fragment,null,f&&$.createElement(O,{sideCar:wx,removeScrollBar:h,shards:d,noIsolation:v,inert:w,setCallbacks:o,allowPinchZoom:!!x,lockRef:n,gapMode:A}),s?$.cloneElement($.Children.only(a),exports.__assign(exports.__assign({},L),{ref:D})):$.createElement(S,exports.__assign({},L,{className:c,ref:D}),a))});oh.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1};oh.classNames={fullWidth:os,zeroRight:is};var GE=function(){if(typeof __webpack_nonce__<"u")return __webpack_nonce__};function YE(){if(!document)return null;var t=document.createElement("style");t.type="text/css";var e=GE();return e&&t.setAttribute("nonce",e),t}function XE(t,e){t.styleSheet?t.styleSheet.cssText=e:t.appendChild(document.createTextNode(e))}function ZE(t){var e=document.head||document.getElementsByTagName("head")[0];e.appendChild(t)}var QE=function(){var t=0,e=null;return{add:function(n){t==0&&(e=YE())&&(XE(e,n),ZE(e)),t++},remove:function(){t--,!t&&e&&(e.parentNode&&e.parentNode.removeChild(e),e=null)}}},JE=function(){var t=QE();return function(e,n){$.useEffect(function(){return t.add(e),function(){t.remove()}},[e&&n])}},sh=function(){var t=JE(),e=function(n){var r=n.styles,i=n.dynamic;return t(r,i),null};return e},eO={left:0,top:0,right:0,gap:0},$d=function(t){return parseInt(t||"",10)||0},tO=function(t){var e=window.getComputedStyle(document.body),n=e[t==="padding"?"paddingLeft":"marginLeft"],r=e[t==="padding"?"paddingTop":"marginTop"],i=e[t==="padding"?"paddingRight":"marginRight"];return[$d(n),$d(r),$d(i)]},nO=function(t){if(t===void 0&&(t="margin"),typeof window>"u")return eO;var e=tO(t),n=document.documentElement.clientWidth,r=window.innerWidth;return{left:e[0],top:e[1],right:e[2],gap:Math.max(0,r-n+e[2]-e[0])}},rO=sh(),ss="data-scroll-locked",iO=function(t,e,n,r){var i=t.left,o=t.top,s=t.right,a=t.gap;return n===void 0&&(n="margin"),`
2
- .`.concat(PE,` {
3
- overflow: hidden `).concat(r,`;
4
- padding-right: `).concat(a,"px ").concat(r,`;
5
- }
6
- body[`).concat(ss,`] {
7
- overflow: hidden `).concat(r,`;
8
- overscroll-behavior: contain;
9
- `).concat([e&&"position: relative ".concat(r,";"),n==="margin"&&`
10
- padding-left: `.concat(i,`px;
11
- padding-top: `).concat(o,`px;
12
- padding-right: `).concat(s,`px;
13
- margin-left:0;
14
- margin-top:0;
15
- margin-right: `).concat(a,"px ").concat(r,`;
16
- `),n==="padding"&&"padding-right: ".concat(a,"px ").concat(r,";")].filter(Boolean).join(""),`
17
- }
18
-
19
- .`).concat(is,` {
20
- right: `).concat(a,"px ").concat(r,`;
21
- }
22
-
23
- .`).concat(os,` {
24
- margin-right: `).concat(a,"px ").concat(r,`;
25
- }
26
-
27
- .`).concat(is," .").concat(is,` {
28
- right: 0 `).concat(r,`;
29
- }
30
-
31
- .`).concat(os," .").concat(os,` {
32
- margin-right: 0 `).concat(r,`;
33
- }
34
-
35
- body[`).concat(ss,`] {
36
- `).concat(WE,": ").concat(a,`px;
37
- }
38
- `)},Vv=function(){var t=parseInt(document.body.getAttribute(ss)||"0",10);return isFinite(t)?t:0},oO=function(){$.useEffect(function(){return document.body.setAttribute(ss,(Vv()+1).toString()),function(){var t=Vv()-1;t<=0?document.body.removeAttribute(ss):document.body.setAttribute(ss,t.toString())}},[])},cg=function(t){var e=t.noRelative,n=t.noImportant,r=t.gapMode,i=r===void 0?"margin":r;oO();var o=$.useMemo(function(){return nO(i)},[i]);return $.createElement(rO,{styles:iO(o,!e,i,n?"":"!important")})},b0=!1;if(typeof window<"u")try{var pc=Object.defineProperty({},"passive",{get:function(){return b0=!0,!0}});window.addEventListener("test",pc,pc),window.removeEventListener("test",pc,pc)}catch{b0=!1}var zo=b0?{passive:!1}:!1,sO=function(t){return t.tagName==="TEXTAREA"},xx=function(t,e){if(!(t instanceof Element))return!1;var n=window.getComputedStyle(t);return n[e]!=="hidden"&&!(n.overflowY===n.overflowX&&!sO(t)&&n[e]==="visible")},aO=function(t){return xx(t,"overflowY")},lO=function(t){return xx(t,"overflowX")},Hv=function(t,e){var n=e.ownerDocument,r=e;do{typeof ShadowRoot<"u"&&r instanceof ShadowRoot&&(r=r.host);var i=yx(t,r);if(i){var o=Cx(t,r),s=o[1],a=o[2];if(s>a)return!0}r=r.parentNode}while(r&&r!==n.body);return!1},cO=function(t){var e=t.scrollTop,n=t.scrollHeight,r=t.clientHeight;return[e,n,r]},uO=function(t){var e=t.scrollLeft,n=t.scrollWidth,r=t.clientWidth;return[e,n,r]},yx=function(t,e){return t==="v"?aO(e):lO(e)},Cx=function(t,e){return t==="v"?cO(e):uO(e)},hO=function(t,e){return t==="h"&&e==="rtl"?-1:1},fO=function(t,e,n,r,i){var o=hO(t,window.getComputedStyle(e).direction),s=o*r,a=n.target,c=e.contains(a),h=!1,f=s>0,d=0,m=0;do{var v=Cx(t,a),w=v[0],x=v[1],C=v[2],S=x-C-o*w;(w||S)&&yx(t,a)&&(d+=S,m+=w),a instanceof ShadowRoot?a=a.host:a=a.parentNode}while(!c&&a!==document.body||c&&(e.contains(a)||e===a));return(f&&Math.abs(d)<1||!f&&Math.abs(m)<1)&&(h=!0),h},vc=function(t){return"changedTouches"in t?[t.changedTouches[0].clientX,t.changedTouches[0].clientY]:[0,0]},Pv=function(t){return[t.deltaX,t.deltaY]},Wv=function(t){return t&&"current"in t?t.current:t},dO=function(t,e){return t[0]===e[0]&&t[1]===e[1]},gO=function(t){return`
39
- .block-interactivity-`.concat(t,` {pointer-events: none;}
40
- .allow-interactivity-`).concat(t,` {pointer-events: all;}
41
- `)},mO=0,Uo=[];function pO(t){var e=$.useRef([]),n=$.useRef([0,0]),r=$.useRef(),i=$.useState(mO++)[0],o=$.useState(sh)[0],s=$.useRef(t);$.useEffect(function(){s.current=t},[t]),$.useEffect(function(){if(t.inert){document.body.classList.add("block-interactivity-".concat(i));var x=og([t.lockRef.current],(t.shards||[]).map(Wv),!0).filter(Boolean);return x.forEach(function(C){return C.classList.add("allow-interactivity-".concat(i))}),function(){document.body.classList.remove("block-interactivity-".concat(i)),x.forEach(function(C){return C.classList.remove("allow-interactivity-".concat(i))})}}},[t.inert,t.lockRef.current,t.shards]);var a=$.useCallback(function(x,C){if("touches"in x&&x.touches.length===2)return!s.current.allowPinchZoom;var S=vc(x),A=n.current,T="deltaX"in x?x.deltaX:A[0]-S[0],O="deltaY"in x?x.deltaY:A[1]-S[1],D,L=x.target,I=Math.abs(T)>Math.abs(O)?"h":"v";if("touches"in x&&I==="h"&&L.type==="range")return!1;var V=Hv(I,L);if(!V)return!0;if(V?D=I:(D=I==="v"?"h":"v",V=Hv(I,L)),!V)return!1;if(!r.current&&"changedTouches"in x&&(T||O)&&(r.current=D),!D)return!0;var F=r.current||D;return fO(F,C,x,F==="h"?T:O)},[]),c=$.useCallback(function(x){var C=x;if(!(!Uo.length||Uo[Uo.length-1]!==o)){var S="deltaY"in C?Pv(C):vc(C),A=e.current.filter(function(D){return D.name===C.type&&(D.target===C.target||C.target===D.shadowParent)&&dO(D.delta,S)})[0];if(A&&A.should){C.cancelable&&C.preventDefault();return}if(!A){var T=(s.current.shards||[]).map(Wv).filter(Boolean).filter(function(D){return D.contains(C.target)}),O=T.length>0?a(C,T[0]):!s.current.noIsolation;O&&C.cancelable&&C.preventDefault()}}},[]),h=$.useCallback(function(x,C,S,A){var T={name:x,delta:C,target:S,should:A,shadowParent:vO(S)};e.current.push(T),setTimeout(function(){e.current=e.current.filter(function(O){return O!==T})},1)},[]),f=$.useCallback(function(x){n.current=vc(x),r.current=void 0},[]),d=$.useCallback(function(x){h(x.type,Pv(x),x.target,a(x,t.lockRef.current))},[]),m=$.useCallback(function(x){h(x.type,vc(x),x.target,a(x,t.lockRef.current))},[]);$.useEffect(function(){return Uo.push(o),t.setCallbacks({onScrollCapture:d,onWheelCapture:d,onTouchMoveCapture:m}),document.addEventListener("wheel",c,zo),document.addEventListener("touchmove",c,zo),document.addEventListener("touchstart",f,zo),function(){Uo=Uo.filter(function(x){return x!==o}),document.removeEventListener("wheel",c,zo),document.removeEventListener("touchmove",c,zo),document.removeEventListener("touchstart",f,zo)}},[]);var v=t.removeScrollBar,w=t.inert;return $.createElement($.Fragment,null,w?$.createElement(o,{styles:gO(i)}):null,v?$.createElement(cg,{gapMode:t.gapMode}):null)}function vO(t){for(var e=null;t!==null;)t instanceof ShadowRoot&&(e=t.host,t=t.host),t=t.parentNode;return e}const bO=lg(wx,pO);var ug=$.forwardRef(function(t,e){return $.createElement(oh,exports.__assign({},t,{ref:e,sideCar:bO}))});ug.classNames=oh.classNames;function w0(t,[e,n]){return Math.min(n,Math.max(e,t))}function ah(t){const e=t+"CollectionProvider",[n,r]=bt(e),[i,o]=n(e,{collectionRef:{current:null},itemMap:new Map}),s=v=>{const{scope:w,children:x}=v,C=$.default.useRef(null),S=$.default.useRef(new Map).current;return $.default.createElement(i,{scope:w,itemMap:S,collectionRef:C},x)},a=t+"CollectionSlot",c=$.default.forwardRef((v,w)=>{const{scope:x,children:C}=v,S=o(a,x),A=ye(w,S.collectionRef);return $.default.createElement(Cr,{ref:A},C)}),h=t+"CollectionItemSlot",f="data-radix-collection-item",d=$.default.forwardRef((v,w)=>{const{scope:x,children:C,...S}=v,A=$.default.useRef(null),T=ye(w,A),O=o(h,x);return $.default.useEffect(()=>(O.itemMap.set(A,{ref:A,...S}),()=>void O.itemMap.delete(A))),$.default.createElement(Cr,{[f]:"",ref:T},C)});function m(v){const w=o(t+"CollectionConsumer",v);return $.default.useCallback(()=>{const C=w.collectionRef.current;if(!C)return[];const S=Array.from(C.querySelectorAll(`[${f}]`));return Array.from(w.itemMap.values()).sort((O,D)=>S.indexOf(O.ref.current)-S.indexOf(D.ref.current))},[w.collectionRef,w.itemMap])}return[{Provider:s,Slot:c,ItemSlot:d},m,r]}const wO=b.createContext(void 0);function $o(t){const e=b.useContext(wO);return t||e||"ltr"}function lh(t){const e=b.useRef({value:t,previous:t});return b.useMemo(()=>(e.current.value!==t&&(e.current.previous=e.current.value,e.current.value=t),e.current.previous),[t])}function xO(t){const e=`${t}CollectionProvider`,[n,r]=bt(e),[i,o]=n(e,{collectionRef:{current:null},itemMap:new Map,listeners:new Set}),s=v=>{const{scope:w,children:x}=v,C=$.useRef(null),S=$.useRef(new Map).current,A=$.useRef(new Set).current;return p.jsx(i,{scope:w,itemMap:S,collectionRef:C,listeners:A,children:x})};s.displayName=e;const a=`${t}CollectionSlot`,c=$.forwardRef((v,w)=>{const{scope:x,children:C}=v,S=o(a,x),A=ye(w,S.collectionRef);return p.jsx(Cr,{ref:A,children:C})});c.displayName=a;const h=`${t}CollectionItemSlot`,f="data-radix-collection-item",d=$.forwardRef((v,w)=>{const{scope:x,children:C,...S}=v,A=$.useRef(null),T=ye(w,A),O=o(h,x);return $.useEffect(()=>{const D=Array.from(O.itemMap.values());return O.itemMap.set(A,{ref:A,...S}),O.listeners.forEach(L=>L(Array.from(O.itemMap.values()),D)),()=>{const L=Array.from(O.itemMap.values());O.itemMap.delete(A),O.listeners.forEach(I=>I(Array.from(O.itemMap.values()),L))}}),p.jsx(Cr,{[f]:"",ref:T,children:C})});d.displayName=h;function m(v){const w=o(`${t}CollectionConsumer`,v),x=$.useCallback(()=>{const S=w.collectionRef.current;if(!S)return[];const A=Array.from(S.querySelectorAll(`[${f}]`));return Array.from(w.itemMap.values()).sort((D,L)=>A.indexOf(D.ref.current)-A.indexOf(L.ref.current))},[w.collectionRef,w.itemMap]),C=$.useCallback(S=>(w.listeners.add(S),()=>w.listeners.delete(S)),[w.listeners]);return{getItems:x,subscribe:C}}return[{Provider:s,Slot:c,ItemSlot:d},m,r]}const Sd=new Map;function yO(t,e){const n=t+(e?Object.entries(e).sort((i,o)=>i[0]<o[0]?-1:1).join():"");if(Sd.has(n))return Sd.get(n);const r=new Intl.Collator(t,e);return Sd.set(n,r),r}function hg(t,e){const n=yO(t,{usage:"search",...e});return{startsWith(r,i){return i.length===0?!0:(r=r.normalize("NFC"),i=i.normalize("NFC"),n.compare(r.slice(0,i.length),i)===0)},endsWith(r,i){return i.length===0?!0:(r=r.normalize("NFC"),i=i.normalize("NFC"),n.compare(r.slice(-i.length),i)===0)},contains(r,i){if(i.length===0)return!0;r=r.normalize("NFC"),i=i.normalize("NFC");let o=0;const s=i.length;for(;o+s<=r.length;o++){const a=r.slice(o,o+s);if(n.compare(i,a)===0)return!0}return!1}}}const $x=t=>{const e=$.useRef();return $.useEffect(()=>{e.current=t}),e.current},CO=[" ","Enter","ArrowUp","ArrowDown"],$O=["Enter"],SO=t=>!!(t.length===1&&t.match(/\S| /)),Sx="Combobox",[bs,ol]=xO(Sx),[AO,Rr]=K1(Sx),RO=({children:t})=>p.jsx(Ja,{children:p.jsx(bs.Provider,{scope:void 0,children:t})}),kO=t=>typeof t=="string"?t==="none"?{type:t,filter:void 0}:{type:t,filter:"startsWith"}:t,TO=t=>{const{allowCustomValue:e=!1,autocomplete:n="none",children:r,open:i,defaultOpen:o,onOpenChange:s,value:a,defaultValue:c,onValueChange:h,disabled:f,required:d=!1,locale:m="en-EN",onTextValueChange:v,textValue:w,defaultTextValue:x,filterValue:C,defaultFilterValue:S,onFilterValueChange:A,isPrintableCharacter:T=SO}=t,[O,D]=$.useState(null),[L,I]=$.useState(null),[V,F]=$.useState(null),[H,K]=$.useState(null),[W=!1,J]=_t({prop:i,defaultProp:o,onChange:s}),[G,re]=_t({prop:a,defaultProp:c,onChange:h}),[oe,te]=_t({prop:w,defaultProp:e&&!x?a:x,onChange:v}),[ie,Y]=_t({prop:C,defaultProp:S,onChange:A}),ue=Lt(),ge=$.useCallback((we,Ve)=>{const Ne=Ve.map(Ae=>Ae.ref.current),[He,...pe]=Ne,[Oe]=pe.slice(-1),ke=H??Ve.find(Ae=>Ae.value===G)?.ref.current;for(const Ae of we){if(Ae===ke)return;if(Ae?.scrollIntoView({block:"nearest"}),Ae===He&&L&&(L.scrollTop=0),Ae===Oe&&L&&(L.scrollTop=L.scrollHeight),K(Ae),n==="both"){const _e=Ve.find(ze=>ze.ref.current===Ae);_e&&te(_e.textValue)}if(Ae!==ke)return}},[n,te,L,H,G]),De=kO(n);return $.useEffect(()=>{n!=="both"&&K(null)},[oe,n]),$.useEffect(()=>{if(V&&O)return rl([V,O])},[V,O]),p.jsx(RO,{children:p.jsx(AO,{allowCustomValue:e,autocomplete:De,required:d,trigger:O,onTriggerChange:D,contentId:ue,value:G,onValueChange:re,open:W,onOpenChange:J,disabled:f,locale:m,focusFirst:ge,textValue:oe,onTextValueChange:te,onViewportChange:I,onContentChange:F,visuallyFocussedItem:H,filterValue:ie,onFilterValueChange:Y,onVisuallyFocussedItemChange:K,isPrintableCharacter:T,children:r})})},Ax="ComboboxTrigger",Rx=$.forwardRef((t,e)=>{const{...n}=t,r=Rr(Ax),i=()=>{r.disabled||r.onOpenChange(!0)};return p.jsx(el,{asChild:!0,children:p.jsx(_s,{asChild:!0,trapped:r.open,onMountAutoFocus:o=>{o.preventDefault()},onUnmountAutoFocus:o=>{r.trigger?.focus({preventScroll:!0}),document.getSelection()?.empty(),o.preventDefault()},children:p.jsx("div",{ref:e,"data-disabled":r.disabled?"":void 0,...n,onClick:ne(n.onClick,o=>{if(r.disabled){o.preventDefault();return}r.trigger?.focus()}),onPointerDown:ne(n.onPointerDown,o=>{if(r.disabled){o.preventDefault();return}const s=o.target;s.hasPointerCapture(o.pointerId)&&s.releasePointerCapture(o.pointerId),(s.closest("button")??s.closest("div"))===o.currentTarget&&o.button===0&&o.ctrlKey===!1&&(i(),r.trigger?.focus())})})})})});Rx.displayName=Ax;const kx="ComboboxInput",Tx=$.forwardRef((t,e)=>{const n=Rr(kx),r=$.useRef(null),{getItems:i}=ol(void 0),{startsWith:o}=hg(n.locale,{sensitivity:"base"}),s=n.disabled,a=ye(r,e,n.onTriggerChange),c=()=>{s||n.onOpenChange(!0)},h=$x(n.filterValue);return ut(()=>{const f=setTimeout(()=>{if(n.textValue===""||n.textValue===void 0||n.filterValue===""||n.filterValue===void 0)return;const d=i().find(v=>v.type==="option"&&o(v.textValue,n.textValue)),m=WO(h??"",n.filterValue);d&&!n.visuallyFocussedItem&&m===n.filterValue.length&&r.current?.setSelectionRange(n.filterValue.length,n.textValue.length)});return()=>clearTimeout(f)},[n.textValue,n.filterValue,o,n.visuallyFocussedItem,i,h]),p.jsx("input",{type:"text",role:"combobox","aria-controls":n.contentId,"aria-expanded":n.open,"aria-required":n.required,"aria-autocomplete":n.autocomplete.type,"data-state":n.open?"open":"closed","aria-disabled":s,"aria-activedescendant":n.visuallyFocussedItem?.id,disabled:s,"data-disabled":s?"":void 0,"data-placeholder":n.textValue===void 0?"":void 0,value:n.textValue??"",...t,ref:a,onKeyDown:ne(t.onKeyDown,f=>{if(["ArrowUp","ArrowDown","Home","End"].includes(f.key))n.open||c(),setTimeout(()=>{let m=i().filter(v=>!v.disabled&&v.isVisible).map(v=>v.ref.current);if(["ArrowUp","End"].includes(f.key)&&(m=m.slice().reverse()),["ArrowUp","ArrowDown"].includes(f.key)){const v=n.visuallyFocussedItem??i().find(w=>w.value===n.value)?.ref.current;if(v){let w=m.indexOf(v);w===m.length-1&&(w=-1),m=m.slice(w+1)}}if(["ArrowDown"].includes(f.key)&&n.autocomplete.type==="both"&&m.length>1){const[v,...w]=m,x=i().find(C=>C.ref.current===v).textValue;n.textValue===x&&(m=w)}n.focusFirst(m,i())}),f.preventDefault();else if(["Tab"].includes(f.key)&&n.open)f.preventDefault();else if(["Escape"].includes(f.key))n.open?n.onOpenChange(!1):(n.onValueChange(void 0),n.onTextValueChange("")),f.preventDefault();else if($O.includes(f.key)){if(n.visuallyFocussedItem){const d=i().find(m=>m.ref.current===n.visuallyFocussedItem);d&&(n.onValueChange(d.value),n.onTextValueChange(d.textValue),n.autocomplete.type==="both"&&n.onFilterValueChange(d.textValue),d.ref.current?.click())}else{const d=i().find(m=>m.type==="option"&&!m.disabled&&m.textValue===n.textValue);d&&(n.onValueChange(d.value),n.onTextValueChange(d.textValue),n.autocomplete.type==="both"&&n.onFilterValueChange(d.textValue),d.ref.current?.click())}n.onOpenChange(!1),f.preventDefault()}else n.onVisuallyFocussedItemChange(null)}),onChange:ne(t.onChange,f=>{n.onTextValueChange(f.currentTarget.value),n.autocomplete.type==="both"&&n.onFilterValueChange(f.currentTarget.value)}),onKeyUp:ne(t.onKeyUp,f=>{if(!n.open&&(n.isPrintableCharacter(f.key)||["Backspace"].includes(f.key))&&c(),setTimeout(()=>{if(n.autocomplete.type==="both"&&n.isPrintableCharacter(f.key)&&n.filterValue!==void 0){const d=n.filterValue,m=i().find(v=>o(v.textValue,d));m&&n.onTextValueChange(m.textValue)}}),n.autocomplete.type==="none"&&n.isPrintableCharacter(f.key)){const d=n.textValue??"",m=i().find(v=>o(v.textValue,d));m&&(n.onVisuallyFocussedItemChange(m.ref.current),m.ref.current?.scrollIntoView())}}),onBlur:ne(t.onBlur,()=>{if(n.open)return;n.onVisuallyFocussedItemChange(null);const[f]=i().filter(m=>m.textValue===n.textValue&&m.type==="option");if(f){n.onValueChange(f.value),n.autocomplete.type==="both"&&n.onFilterValueChange(f.textValue);return}if(n.allowCustomValue){n.onValueChange(n.textValue),n.autocomplete.type==="both"&&n.onFilterValueChange(n.textValue);return}const[d]=i().filter(m=>m.value===n.value&&m.type==="option");d&&n.textValue!==""?(n.onTextValueChange(d.textValue),n.autocomplete.type==="both"&&n.onFilterValueChange(d.textValue)):(n.onValueChange(void 0),n.onTextValueChange(""))})})});Tx.displayName="ComboboxTextInput";const Mx=$.forwardRef((t,e)=>{const{children:n,...r}=t,i=Rr(kx),o=i.disabled,s=()=>{o||(i.onOpenChange(!0),i.trigger?.focus())};return p.jsx(me.button,{"aria-hidden":!0,type:"button","aria-disabled":o,"aria-controls":i.contentId,"aria-expanded":i.open,disabled:o,"data-disabled":o?"":void 0,...r,tabIndex:-1,ref:e,onClick:ne(r.onClick,()=>{i.trigger?.focus()}),onPointerDown:ne(r.onPointerDown,a=>{a.button===0&&a.ctrlKey===!1&&(s(),a.preventDefault())}),onKeyDown:ne(r.onKeyDown,a=>{CO.includes(a.key)&&(s(),a.preventDefault())}),children:n||"▼"})});Mx.displayName="ComboboxIcon";const MO="ComboboxPortal",Ex=t=>p.jsx(Ds,{asChild:!0,...t});Ex.displayName=MO;const fg="ComboboxContent",Ox=$.forwardRef((t,e)=>{const n=Rr(fg),{getItems:r}=ol(void 0),[i,o]=$.useState();if(ut(()=>{o(new DocumentFragment)},[]),ut(()=>{n.open&&n.autocomplete.type==="none"&&setTimeout(()=>{r().find(a=>a.value===n.value)?.ref.current?.scrollIntoView({block:"nearest"})})},[r,n.autocomplete,n.value,n.open]),!n.open){const s=i;return s?yo.createPortal(p.jsx(bs.Slot,{scope:void 0,children:p.jsx("div",{children:t.children})}),s):null}return p.jsx(Dx,{...t,ref:e})});Ox.displayName=fg;const EO=10,Dx=$.forwardRef((t,e)=>{const{onEscapeKeyDown:n,onPointerDownOutside:r,...i}=t,o=Rr(fg),s=ye(e,c=>o.onContentChange(c)),{onOpenChange:a}=o;return Is(),$.useEffect(()=>{const c=()=>{a(!1)};return window.addEventListener("blur",c),window.addEventListener("resize",c),()=>{window.removeEventListener("blur",c),window.removeEventListener("resize",c)}},[a]),p.jsx(ug,{allowPinchZoom:!0,children:p.jsx(Co,{asChild:!0,onEscapeKeyDown:n,onPointerDownOutside:r,onFocusOutside:c=>{c.preventDefault()},onDismiss:()=>{o.onOpenChange(!1),o.trigger?.focus({preventScroll:!0})},children:p.jsx(Ix,{role:"listbox",id:o.contentId,"data-state":o.open?"open":"closed",onContextMenu:c=>c.preventDefault(),...i,ref:s,style:{display:"flex",flexDirection:"column",outline:"none",...i.style}})})})});Dx.displayName="ComboboxContentImpl";const Ix=$.forwardRef((t,e)=>{const{align:n="start",collisionPadding:r=EO,...i}=t;return p.jsx(tl,{...i,ref:e,align:n,collisionPadding:r,style:{boxSizing:"border-box",...i.style,"--radix-combobox-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-combobox-content-available-width":"var(--radix-popper-available-width)","--radix-combobox-content-available-height":"var(--radix-popper-available-height)","--radix-combobox-trigger-width":"var(--radix-popper-anchor-width)","--radix-combobox-trigger-height":"var(--radix-popper-anchor-height)"}})});Ix.displayName="ComboboxPopperPosition";const _x="ComboboxViewport",Lx=$.forwardRef((t,e)=>{const n=Rr(_x),r=ye(e,n.onViewportChange);return p.jsxs(p.Fragment,{children:[p.jsx("style",{dangerouslySetInnerHTML:{__html:"[data-radix-combobox-viewport]{scrollbar-width:none;-ms-overflow-style:none;-webkit-overflow-scrolling:touch;}[data-radix-combobox-viewport]::-webkit-scrollbar{display:none}"}}),p.jsx(bs.Slot,{scope:void 0,children:p.jsx(me.div,{"data-radix-combobox-viewport":"",role:"presentation",...t,ref:r,style:{position:"relative",flex:1,overflow:"auto",...t.style}})})]})});Lx.displayName=_x;const ch="ComboboxItem",[zv,dg]=K1(ch),gg=$.forwardRef((t,e)=>{const{value:n,disabled:r=!1,textValue:i,...o}=t,[s,a]=$.useState();ut(()=>{a(new DocumentFragment)},[]);const{onTextValueChange:c,textValue:h,...f}=Rr(ch),d=Lt(),[m,v]=$.useState(i??""),w=f.value===n,{startsWith:x,contains:C}=hg(f.locale,{sensitivity:"base"}),S=$.useCallback(A=>{v(T=>T||(A?.textContent??"").trim())},[]);return $.useEffect(()=>{w&&h===void 0&&m!==""&&c(m)},[m,w,h,c]),f.autocomplete.type==="both"&&m&&f.filterValue&&!x(m,f.filterValue)||f.autocomplete.type==="list"&&f.autocomplete.filter==="startsWith"&&m&&h&&!x(m,h)||f.autocomplete.type==="list"&&f.autocomplete.filter==="contains"&&m&&h&&!C(m,h)?s?yo.createPortal(p.jsx(zv,{textId:d,onTextValueChange:S,isSelected:w,textValue:m,children:p.jsx(bs.ItemSlot,{scope:void 0,value:n,textValue:m,disabled:r,type:"option",isVisible:!1,children:p.jsx(x0,{ref:e,value:n,disabled:r,...o})})}),s):null:p.jsx(zv,{textId:d,onTextValueChange:S,isSelected:w,textValue:m,children:p.jsx(bs.ItemSlot,{scope:void 0,value:n,textValue:m,disabled:r,type:"option",isVisible:!0,children:p.jsx(x0,{ref:e,value:n,disabled:r,...o})})})});gg.displayName=ch;const Bx="ComboboxItemImpl",x0=$.forwardRef((t,e)=>{const{value:n,disabled:r=!1,...i}=t,o=$.useRef(null),s=ye(e,o),{getItems:a}=ol(void 0),{onTextValueChange:c,visuallyFocussedItem:h,...f}=Rr(ch),{isSelected:d,textValue:m,textId:v}=dg(Bx),w=()=>{r||(f.onValueChange(n),c(m),f.onOpenChange(!1),f.autocomplete.type==="both"&&f.onFilterValueChange(m),f.trigger?.focus({preventScroll:!0}))},x=$.useMemo(()=>h===a().find(S=>S.ref.current===o.current)?.ref.current,[a,h]),C=Lt();return p.jsx(me.div,{role:"option","aria-labelledby":v,"data-highlighted":x?"":void 0,"aria-selected":d&&x,"data-state":d?"checked":"unchecked","aria-disabled":r||void 0,"data-disabled":r?"":void 0,tabIndex:r?void 0:-1,...i,id:C,ref:s,onPointerUp:ne(i.onPointerUp,w)})});x0.displayName=Bx;const Nx="ComboboxItemText",jx=$.forwardRef((t,e)=>{const{className:n,style:r,...i}=t,o=dg(Nx),s=ye(e,o.onTextValueChange);return p.jsx(me.span,{id:o.textId,...i,ref:s})});jx.displayName=Nx;const Fx="ComboboxItemIndicator",Vx=$.forwardRef((t,e)=>{const{isSelected:n}=dg(Fx);return n?p.jsx(me.span,{"aria-hidden":!0,...t,ref:e}):null});Vx.displayName=Fx;const mg="ComboboxNoValueFound",Hx=$.forwardRef((t,e)=>{const{textValue:n="",filterValue:r="",locale:i,autocomplete:o}=Rr(mg),[s,a]=$.useState([]),{subscribe:c}=ol(void 0),{startsWith:h,contains:f}=hg(i,{sensitivity:"base"});return $.useEffect(()=>{const d=c(m=>{a(m)});return()=>{d()}},[c]),o.type==="none"&&s.length>0||o.type==="list"&&o.filter==="startsWith"&&s.some(d=>h(d.textValue,n))||o.type==="both"&&s.some(d=>h(d.textValue,r))||o.type==="list"&&o.filter==="contains"&&s.some(d=>f(d.textValue,n))?null:p.jsx(me.div,{...t,ref:e})});Hx.displayName=mg;const Px=$.forwardRef((t,e)=>{const{disabled:n=!1,...r}=t,i=Rr(mg),{textValue:o,visuallyFocussedItem:s}=i,{getItems:a,subscribe:c}=ol(void 0),h=$.useRef(null),[f,d]=$.useState(!1),m=ye(e,h),v=$.useMemo(()=>s===a().find(C=>C.ref.current===h.current)?.ref.current,[a,s]),w=Lt(),x=()=>{!n&&o&&(i.onValueChange(o),i.onTextValueChange(o),i.onOpenChange(!1),i.autocomplete.type==="both"&&i.onFilterValueChange(o),i.trigger?.focus({preventScroll:!0}))};return ut(()=>{const C=c(S=>{d(!S.some(A=>A.textValue===o&&A.type!=="create"))});return a().length===0&&d(!0),()=>{C()}},[o,c,a]),!o||!f?null:p.jsx(bs.ItemSlot,{scope:void 0,value:o??"",textValue:o??"",disabled:n,isVisible:!0,type:"create",children:p.jsx(me.div,{role:"option",tabIndex:n?void 0:-1,"aria-disabled":n||void 0,"data-disabled":n?"":void 0,"data-highlighted":v?"":void 0,...r,id:w,ref:m,onPointerUp:ne(r.onPointerUp,x)})})});Px.displayName="ComboboxCreateItem";const OO=TO,DO=Rx,IO=Tx,_O=Mx,LO=Ex,BO=Ox,NO=Lx,jO=gg,FO=jx,VO=Vx,HO=Hx,PO=Px;function WO(t,e){const n=Math.min(t.length,e.length);for(let r=0;r<n;r++)if(t[r]!==e[r])return r;return n}const Yn=Object.freeze(Object.defineProperty({__proto__:null,ComboboxItem:gg,Content:BO,CreateItem:PO,Icon:_O,Item:jO,ItemIndicator:VO,ItemText:FO,NoValueFound:HO,Portal:LO,Root:OO,TextInput:IO,Trigger:DO,Viewport:NO},Symbol.toStringTag,{value:"Module"}));function pg(t){const e=$.useRef(t);return $.useEffect(()=>{e.current=t}),$.useMemo(()=>(...n)=>e.current?.(...n),[])}const zO=[" ","Enter","ArrowUp","ArrowDown"],UO=[" ","Enter"],sl="Select",[uh,al,qO]=ah(sl),[Ls,KO]=bt(sl,[qO,Li]),hh=Li(),[GO,ri]=Ls(sl),[YO,XO]=Ls(sl),vg=t=>{const{__scopeSelect:e,children:n,open:r,defaultOpen:i,onOpenChange:o,value:s,defaultValue:a,onValueChange:c,dir:h,disabled:f,required:d,multi:m=!1}=t,v=hh(e),[w,x]=$.useState(null),[C,S]=$.useState(null),[A,T]=$.useState(!1),O=$o(h),[D=!1,L]=_t({prop:r,defaultProp:i,onChange:o}),[I,V]=_t({prop:s,defaultProp:a,onChange(W){c&&(Array.isArray(W),c(W))}}),F=$.useRef(null),[H,K]=$.useState(new Set);return p.jsx(Ja,{...v,children:p.jsx(GO,{required:d,scope:e,trigger:w,onTriggerChange:x,valueNode:C,onValueNodeChange:S,valueNodeHasChildren:A,onValueNodeHasChildrenChange:T,contentId:Lt(),value:I,onValueChange:V,open:D,onOpenChange:L,dir:O,triggerPointerDownPosRef:F,disabled:f,multi:m,children:p.jsx(uh.Provider,{scope:e,children:p.jsx(YO,{scope:t.__scopeSelect,onNativeOptionAdd:$.useCallback(W=>{K(J=>new Set(J).add(W))},[]),onNativeOptionRemove:$.useCallback(W=>{K(J=>{const G=new Set(J);return G.delete(W),G})},[]),children:n})})})})};vg.displayName=sl;const Wx="SelectTrigger",bg=$.forwardRef((t,e)=>{const{__scopeSelect:n,...r}=t,i=hh(n),o=ri(Wx,n),s=o.disabled,a=ye(e,o.onTriggerChange),c=al(n),[h,f,d]=Qx(v=>{const w=c().filter(S=>!S.disabled),x=w.find(S=>S.value===o.value),C=Jx(w,v,x);if(C!==void 0&&!Array.isArray(C.value)){const S=o.multi?[C.value]:C.value;o.onValueChange(S)}}),m=()=>{s||(o.onOpenChange(!0),d())};return p.jsx(el,{asChild:!0,...i,children:p.jsx(me.div,{role:"combobox","aria-controls":o.contentId,"aria-expanded":o.open,"aria-required":o.required,"aria-autocomplete":"none",dir:o.dir,"data-state":o.open?"open":"closed","data-disabled":s?"":void 0,"data-placeholder":o.value===void 0?"":void 0,tabIndex:s?void 0:0,...r,ref:a,onClick:ne(r.onClick,v=>{v.currentTarget.focus()}),onPointerDown:ne(r.onPointerDown,v=>{const w=v.target;w.hasPointerCapture(v.pointerId)&&w.releasePointerCapture(v.pointerId),(w.closest("button")??w.closest("div"))===v.currentTarget&&v.button===0&&v.ctrlKey===!1&&(m(),o.triggerPointerDownPosRef.current={x:Math.round(v.pageX),y:Math.round(v.pageY)},v.preventDefault())}),onKeyDown:ne(r.onKeyDown,v=>{const w=h.current!=="",x=v.ctrlKey||v.altKey||v.metaKey,C=v.target;(C.closest("button")??C.closest("div"))===v.currentTarget&&(!x&&v.key.length===1&&f(v.key),!(w&&v.key===" ")&&zO.includes(v.key)&&(m(),v.preventDefault()))})})})});bg.displayName=Wx;const zx="SelectValue",wg=$.forwardRef((t,e)=>{const{__scopeSelect:n,children:r,placeholder:i,...o}=t,s=ri(zx,n),{onValueNodeHasChildrenChange:a}=s,c=r!==void 0,h=ye(e,s.onValueNodeChange),[f,d]=$.useState([]),m=al(n);ut(()=>{a(c)},[a,c]),$.useLayoutEffect(()=>{if(Array.isArray(s.value)&&f.length!==s.value.length){const w=setTimeout(()=>{const x=m().filter(C=>Array.isArray(C.value)?!1:s.value?.includes(C.value));d(x)});return()=>{clearTimeout(w)}}},[s.value,m,f]);let v;if((s.value===void 0||s.value.length===0)&&i!==void 0)v=p.jsx("span",{children:i});else if(typeof r=="function")if(Array.isArray(s.value)){const w=s.value.map(x=>{const C=f.find(S=>S.value===x);return C?r({value:x,textValue:C?.textValue}):null});v=w.every(x=>x===null)?i:w}else v=r(s.value);else v=r;return p.jsx(me.span,{...o,ref:h,children:v||null})});wg.displayName=zx;const ZO="SelectIcon",xg=$.forwardRef((t,e)=>{const{__scopeSelect:n,children:r,...i}=t;return p.jsx(me.span,{"aria-hidden":!0,...i,ref:e,children:r||"▼"})});xg.displayName=ZO;const QO="SelectPortal",yg=t=>p.jsx(Ds,{asChild:!0,...t});yg.displayName=QO;const fo="SelectContent",Cg=$.forwardRef((t,e)=>{const n=ri(fo,t.__scopeSelect),[r,i]=$.useState();if(ut(()=>{i(new DocumentFragment)},[]),!n.open){const o=r;return o?yo.createPortal(p.jsx(Ux,{scope:t.__scopeSelect,children:p.jsx(uh.Slot,{scope:t.__scopeSelect,children:p.jsx("div",{children:t.children})})}),o):null}return p.jsx(qx,{...t,ref:e})});Cg.displayName=fo;const Wr=10,[Ux,Bi]=Ls(fo),JO="SelectContentImpl",qx=$.forwardRef((t,e)=>{const{__scopeSelect:n,position:r="item-aligned",onCloseAutoFocus:i,onEscapeKeyDown:o,onPointerDownOutside:s,side:a,sideOffset:c,align:h,alignOffset:f,arrowPadding:d,collisionBoundary:m,collisionPadding:v,sticky:w,hideWhenDetached:x,avoidCollisions:C,...S}=t,A=ri(fo,n),[T,O]=$.useState(null),[D,L]=$.useState(null),I=ye(e,pe=>O(pe)),[V,F]=$.useState(null),[H,K]=$.useState(null),W=al(n),[J,G]=$.useState(!1),re=$.useRef(!1);$.useEffect(()=>{if(T)return rl(T)},[T]),Is();const oe=$.useCallback(pe=>{const[Oe,...ke]=W().map(ze=>ze.ref.current),[Ae]=ke.slice(-1),_e=document.activeElement;for(const ze of pe)if(ze===_e||(ze?.scrollIntoView({block:"nearest"}),ze===Oe&&D&&(D.scrollTop=0),ze===Ae&&D&&(D.scrollTop=D.scrollHeight),ze?.focus(),document.activeElement!==_e))return},[W,D]),te=$.useCallback(()=>oe([V,T]),[oe,V,T]);$.useEffect(()=>{J&&te()},[J,te]);const{onOpenChange:ie,triggerPointerDownPosRef:Y}=A;$.useEffect(()=>{if(T){let pe={x:0,y:0};const Oe=Ae=>{pe={x:Math.abs(Math.round(Ae.pageX)-(Y.current?.x??0)),y:Math.abs(Math.round(Ae.pageY)-(Y.current?.y??0))}},ke=Ae=>{pe.x<=10&&pe.y<=10?Ae.preventDefault():T.contains(Ae.target)||ie(!1),document.removeEventListener("pointermove",Oe),Y.current=null};return Y.current!==null&&(document.addEventListener("pointermove",Oe),document.addEventListener("pointerup",ke,{capture:!0,once:!0})),()=>{document.removeEventListener("pointermove",Oe),document.removeEventListener("pointerup",ke,{capture:!0})}}},[T,ie,Y]),$.useEffect(()=>{const pe=()=>ie(!1);return window.addEventListener("blur",pe),window.addEventListener("resize",pe),()=>{window.removeEventListener("blur",pe),window.removeEventListener("resize",pe)}},[ie]);const[ue,ge]=Qx(pe=>{const Oe=W().filter(_e=>!_e.disabled),ke=Oe.find(_e=>_e.ref.current===document.activeElement),Ae=Jx(Oe,pe,ke);Ae&&setTimeout(()=>Ae.ref.current.focus())}),De=$.useCallback((pe,Oe,ke)=>{const Ae=!re.current&&!ke;(A.value!==void 0&&A.value===Oe||Ae)&&(F(pe),Ae&&(re.current=!0))},[A.value]),we=$.useCallback(()=>T?.focus(),[T]),Ve=$.useCallback((pe,Oe,ke)=>{const Ae=!re.current&&!ke;(A.value!==void 0&&(Array.isArray(Oe)?Oe.every(ze=>A.value?.includes(ze)):A.value===Oe)||Ae)&&K(pe)},[A.value]),Ne=r==="popper"?y0:Kx,He=Ne===y0?{side:a,sideOffset:c,align:h,alignOffset:f,arrowPadding:d,collisionBoundary:m,collisionPadding:v,sticky:w,hideWhenDetached:x,avoidCollisions:C}:{};return p.jsx(Ux,{scope:n,content:T,viewport:D,onViewportChange:L,itemRefCallback:De,selectedItem:V,onItemLeave:we,itemTextRefCallback:Ve,focusSelectedItem:te,selectedItemText:H,position:r,isPositioned:J,searchRef:ue,children:p.jsx(ug,{as:Cr,allowPinchZoom:!0,children:p.jsx(_s,{asChild:!0,trapped:A.open,onMountAutoFocus:pe=>{pe.preventDefault()},onUnmountAutoFocus:ne(i,pe=>{A.trigger?.focus({preventScroll:!0}),document.getSelection()?.empty(),pe.preventDefault()}),children:p.jsx(Co,{asChild:!0,disableOutsidePointerEvents:!0,onEscapeKeyDown:o,onPointerDownOutside:s,onFocusOutside:pe=>pe.preventDefault(),onDismiss:()=>A.onOpenChange(!1),children:p.jsx(Ne,{role:"listbox",id:A.contentId,"data-state":A.open?"open":"closed","aria-multiselectable":A.multi?"true":void 0,dir:A.dir,onContextMenu:pe=>pe.preventDefault(),...S,...He,onPlaced:()=>G(!0),ref:I,style:{display:"flex",flexDirection:"column",outline:"none",...S.style},onKeyDown:ne(S.onKeyDown,pe=>{const Oe=pe.ctrlKey||pe.altKey||pe.metaKey;if(pe.key==="Tab"&&pe.preventDefault(),!Oe&&pe.key.length===1&&ge(pe.key),["ArrowUp","ArrowDown","Home","End"].includes(pe.key)){let Ae=W().filter(_e=>!_e.disabled).map(_e=>_e.ref.current);if(["ArrowUp","End"].includes(pe.key)&&(Ae=Ae.slice().reverse()),["ArrowUp","ArrowDown"].includes(pe.key)){const _e=pe.target,ze=Ae.indexOf(_e);Ae=Ae.slice(ze+1)}setTimeout(()=>oe(Ae)),pe.preventDefault()}})})})})})})});qx.displayName=JO;const eD="SelectItemAlignedPosition",Kx=$.forwardRef((t,e)=>{const{__scopeSelect:n,onPlaced:r,...i}=t,o=ri(fo,n),s=Bi(fo,n),[a,c]=$.useState(null),[h,f]=$.useState(null),d=ye(e,I=>f(I)),m=al(n),v=$.useRef(!1),w=$.useRef(!0),{viewport:x,selectedItem:C,selectedItemText:S,focusSelectedItem:A}=s,T=$.useCallback(()=>{if(o.trigger&&o.valueNode&&a&&h&&x&&C&&S){const I=o.trigger.getBoundingClientRect(),V=h.getBoundingClientRect(),F=o.valueNode.getBoundingClientRect(),H=S.getBoundingClientRect();if(o.dir!=="rtl"){const _e=H.left-V.left,ze=F.left-_e,Et=I.left-ze,Ze=I.width+Et,Pe=Math.max(Ze,V.width),Yt=window.innerWidth-Wr,ft=w0(ze,[Wr,Yt-Pe]);a.style.minWidth=`${Ze}px`,a.style.left=`${ft}px`}else{const _e=V.right-H.right,ze=window.innerWidth-F.right-_e,Et=window.innerWidth-I.right-ze,Ze=I.width+Et,Pe=Math.max(Ze,V.width),Yt=window.innerWidth-Wr,ft=w0(ze,[Wr,Yt-Pe]);a.style.minWidth=`${Ze}px`,a.style.right=`${ft}px`}const K=m(),W=window.innerHeight-Wr*2,J=x.scrollHeight,G=window.getComputedStyle(h),re=parseInt(G.borderTopWidth,10),oe=parseInt(G.paddingTop,10),te=parseInt(G.borderBottomWidth,10),ie=parseInt(G.paddingBottom,10),Y=re+oe+J+ie+te,ue=Math.min(C.offsetHeight*5,Y),ge=window.getComputedStyle(x),De=parseInt(ge.paddingTop,10),we=parseInt(ge.paddingBottom,10),Ve=I.top+I.height/2-Wr,Ne=W-Ve,He=C.offsetHeight/2,pe=C.offsetTop+He,Oe=re+oe+pe,ke=Y-Oe;if(Oe<=Ve){const _e=C===K[K.length-1].ref.current;a.style.bottom="0px";const ze=h.clientHeight-x.offsetTop-x.offsetHeight,Et=Math.max(Ne,He+(_e?we:0)+ze+te),Ze=Oe+Et;a.style.height=`${Ze}px`}else{const _e=C===K[0].ref.current;a.style.top="0px";const Et=Math.max(Ve,re+x.offsetTop+(_e?De:0)+He)+ke;a.style.height=`${Et}px`,x.scrollTop=Oe-Ve+x.offsetTop}a.style.margin=`${Wr}px 0`,a.style.minHeight=`${ue}px`,a.style.maxHeight=`${W}px`,r?.(),requestAnimationFrame(()=>v.current=!0)}},[m,o.trigger,o.valueNode,a,h,x,C,S,o.dir,r]);ut(()=>T(),[T]);const[O,D]=$.useState();ut(()=>{h&&D(window.getComputedStyle(h).zIndex)},[h]);const L=$.useCallback(I=>{I&&w.current===!0&&(T(),A?.(),w.current=!1)},[T,A]);return p.jsx(nD,{scope:n,contentWrapper:a,shouldExpandOnScrollRef:v,onScrollButtonChange:L,children:p.jsx("div",{ref:c,style:{display:"flex",flexDirection:"column",position:"fixed",zIndex:O},children:p.jsx(me.div,{...i,ref:d,style:{boxSizing:"border-box",maxHeight:"100%",...i.style}})})})});Kx.displayName=eD;const tD="SelectPopperPosition",y0=$.forwardRef((t,e)=>{const{__scopeSelect:n,align:r="start",collisionPadding:i=Wr,...o}=t,s=hh(n);return p.jsx(tl,{...s,...o,ref:e,align:r,collisionPadding:i,style:{boxSizing:"border-box",...o.style,"--radix-select-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-select-content-available-width":"var(--radix-popper-available-width)","--radix-select-content-available-height":"var(--radix-popper-available-height)","--radix-select-trigger-width":"var(--radix-popper-anchor-width)","--radix-select-trigger-height":"var(--radix-popper-anchor-height)"}})});y0.displayName=tD;const[nD,$g]=Ls(fo,{}),C0="SelectViewport",Sg=$.forwardRef((t,e)=>{const{__scopeSelect:n,...r}=t,i=Bi(C0,n),o=$g(C0,n),s=ye(e,i.onViewportChange),a=$.useRef(0);return p.jsxs(p.Fragment,{children:[p.jsx("style",{dangerouslySetInnerHTML:{__html:"[data-radix-select-viewport]{scrollbar-width:none;-ms-overflow-style:none;-webkit-overflow-scrolling:touch;}[data-radix-select-viewport]::-webkit-scrollbar{display:none}"}}),p.jsx(uh.Slot,{scope:n,children:p.jsx(me.div,{"data-radix-select-viewport":"",role:"presentation",...r,ref:s,style:{position:"relative",flex:1,overflow:"auto",...r.style},onScroll:ne(r.onScroll,c=>{const h=c.currentTarget,{contentWrapper:f,shouldExpandOnScrollRef:d}=o;if(d?.current&&f){const m=Math.abs(a.current-h.scrollTop);if(m>0){const v=window.innerHeight-Wr*2,w=parseFloat(f.style.minHeight),x=parseFloat(f.style.height),C=Math.max(w,x);if(C<v){const S=C+m,A=Math.min(v,S),T=S-A;f.style.height=`${A}px`,f.style.bottom==="0px"&&(h.scrollTop=T>0?T:0,f.style.justifyContent="flex-end")}}}a.current=h.scrollTop})})})]})});Sg.displayName=C0;const Gx="SelectGroup",[rD,iD]=Ls(Gx),Ag=$.forwardRef((t,e)=>{const{__scopeSelect:n,...r}=t,i=Lt();return p.jsx(rD,{scope:n,id:i,children:p.jsx(me.div,{role:"group","aria-labelledby":i,...r,ref:e})})});Ag.displayName=Gx;const Yx="SelectLabel",Rg=$.forwardRef((t,e)=>{const{__scopeSelect:n,...r}=t,i=iD(Yx,n);return p.jsx(me.div,{id:i.id,...r,ref:e})});Rg.displayName=Yx;const pu="SelectItem",[oD,Xx]=Ls(pu),kg=$.forwardRef((t,e)=>{const{__scopeSelect:n,value:r,disabled:i=!1,textValue:o,...s}=t,a=ri(pu,n),c=Bi(pu,n),h=typeof r=="string"?Array.isArray(a.value)?a.value.includes(r):a.value===r:r.every(A=>a.value?.includes(A)),f=Array.isArray(a.value)&&Array.isArray(r)&&r.some(A=>a.value?.includes(A)),[d,m]=$.useState(o??""),[v,w]=$.useState(!1),x=ye(e,A=>c.itemRefCallback?.(A,r,i)),C=Lt(),S=()=>{if(!i){let A=a.multi&&typeof r=="string"?[r]:r;f&&!h?a.onValueChange(A):Array.isArray(a.value)&&(A=e3(r,a.value)),a.onValueChange(A),a.multi||a.onOpenChange(!1)}};if(!a.multi&&Array.isArray(r))throw new Error("You can only pass an array of values in multi selects");return p.jsx(oD,{scope:n,value:r,disabled:i,textId:C,isSelected:h,isIntermediate:f,onItemTextChange:$.useCallback(A=>{m(T=>T||(A?.textContent??"").trim())},[]),children:p.jsx(uh.ItemSlot,{scope:n,value:r,disabled:i,textValue:d,children:p.jsx(me.div,{role:"option","aria-labelledby":C,"data-highlighted":v?"":void 0,"aria-selected":a.multi?void 0:h&&v,"aria-checked":a.multi?h:void 0,"data-state":h?"checked":"unchecked","aria-disabled":i||void 0,"data-disabled":i?"":void 0,tabIndex:i?void 0:-1,...s,ref:x,onFocus:ne(s.onFocus,()=>w(!0)),onBlur:ne(s.onBlur,()=>w(!1)),onPointerUp:ne(s.onPointerUp,S),onPointerMove:ne(s.onPointerMove,A=>{i?c.onItemLeave?.():A.currentTarget.focus({preventScroll:!0})}),onPointerLeave:ne(s.onPointerLeave,A=>{A.currentTarget===document.activeElement&&c.onItemLeave?.()}),onKeyDown:ne(s.onKeyDown,A=>{c.searchRef?.current!==""&&A.key===" "||(UO.includes(A.key)&&S(),A.key===" "&&A.preventDefault())})})})})});kg.displayName=pu;const da="SelectItemText",Tg=$.forwardRef((t,e)=>{const{__scopeSelect:n,className:r,style:i,...o}=t,s=ri(da,n),a=Bi(da,n),c=Xx(da,n),h=XO(da,n),[f,d]=$.useState(null),m=ye(e,S=>d(S),c.onItemTextChange,S=>a.itemTextRefCallback?.(S,c.value,c.disabled)),v=f?.textContent,w=$.useMemo(()=>p.jsx("option",{value:c.value,disabled:c.disabled,children:v},Array.isArray(c.value)?c.value.join(";"):c.value),[c.disabled,c.value,v]),{onNativeOptionAdd:x,onNativeOptionRemove:C}=h;return ut(()=>(x(w),()=>C(w)),[x,C,w]),p.jsxs(p.Fragment,{children:[p.jsx(me.span,{id:c.textId,...o,ref:m}),c.isSelected&&s.valueNode&&!s.valueNodeHasChildren?yo.createPortal(o.children,s.valueNode):null]})});Tg.displayName=da;const Zx="SelectItemIndicator",Mg=$.forwardRef((t,e)=>{const{__scopeSelect:n,children:r,...i}=t,o=Xx(Zx,n);return typeof r=="function"?p.jsx(me.span,{"aria-hidden":!0,...i,ref:e,children:r({isSelected:o.isSelected,isIntermediate:o.isIntermediate})}):o.isSelected?p.jsx(me.span,{"aria-hidden":!0,...i,ref:e,children:r}):null});Mg.displayName=Zx;const $0="SelectScrollUpButton",Eg=$.forwardRef((t,e)=>{const n=Bi($0,t.__scopeSelect),r=$g($0,t.__scopeSelect),[i,o]=$.useState(!1),s=ye(e,r.onScrollButtonChange);return ut(()=>{if(n.viewport&&n.isPositioned){const a=n.viewport,c=()=>{const h=a.scrollTop>0;o(h)};return c(),a.addEventListener("scroll",c),()=>a.removeEventListener("scroll",c)}},[n.viewport,n.isPositioned]),i?p.jsx(Dg,{...t,ref:s,onAutoScroll:()=>{const{viewport:a,selectedItem:c}=n;a&&c&&(a.scrollTop-=c.offsetHeight)}}):null});Eg.displayName=$0;const S0="SelectScrollDownButton",Og=$.forwardRef((t,e)=>{const n=Bi(S0,t.__scopeSelect),r=$g(S0,t.__scopeSelect),[i,o]=$.useState(!1),s=ye(e,r.onScrollButtonChange);return ut(()=>{if(n.viewport&&n.isPositioned){const a=n.viewport,c=()=>{const h=a.scrollHeight-a.clientHeight,f=Math.ceil(a.scrollTop)<h;o(f)};return c(),a.addEventListener("scroll",c),()=>a.removeEventListener("scroll",c)}},[n.viewport,n.isPositioned]),i?p.jsx(Dg,{...t,ref:s,onAutoScroll:()=>{const{viewport:a,selectedItem:c}=n;a&&c&&(a.scrollTop+=c.offsetHeight)}}):null});Og.displayName=S0;const Dg=$.forwardRef((t,e)=>{const{__scopeSelect:n,onAutoScroll:r,...i}=t,o=Bi("SelectScrollButton",n),s=$.useRef(null),a=al(n),c=$.useCallback(()=>{s.current!==null&&(window.clearInterval(s.current),s.current=null)},[]);return $.useEffect(()=>()=>c(),[c]),ut(()=>{a().find(f=>f.ref.current===document.activeElement)?.ref.current?.scrollIntoView({block:"nearest"})},[a]),p.jsx(me.div,{"aria-hidden":!0,...i,ref:e,style:{flexShrink:0,...i.style},onPointerMove:ne(i.onPointerMove,()=>{o.onItemLeave?.(),s.current===null&&(s.current=window.setInterval(r,50))}),onPointerLeave:ne(i.onPointerLeave,()=>{c()})})});Dg.displayName="SelectScrollButtonImpl";const sD="SelectSeparator",Ig=$.forwardRef((t,e)=>{const{__scopeSelect:n,...r}=t;return p.jsx(me.div,{"aria-hidden":!0,...r,ref:e})});Ig.displayName=sD;const A0="SelectArrow",_g=$.forwardRef((t,e)=>{const{__scopeSelect:n,...r}=t,i=hh(n),o=ri(A0,n),s=Bi(A0,n);return o.open&&s.position==="popper"?p.jsx(lE,{...i,...r,ref:e}):null});_g.displayName=A0;const aD="BubbleSelect",lD=$.forwardRef((t,e)=>{const{value:n,...r}=t,i=$.useRef(null),o=ye(e,i),s=lh(n),a=ri(aD,void 0);$.useEffect(()=>{const h=i.current,f=window.HTMLSelectElement.prototype,m=Object.getOwnPropertyDescriptor(f,"value").set;if(s!==n&&m){const v=new Event("change",{bubbles:!0});m.call(h,n),h.dispatchEvent(v)}},[s,n]);let c=n;return a.multi&&!Array.isArray(n)&&(c=[]),p.jsx(cx,{asChild:!0,children:p.jsx("select",{...r,multiple:a.multi?!0:void 0,ref:o,defaultValue:c})})});lD.displayName="BubbleSelect";function Qx(t){const e=pg(t),n=$.useRef(""),r=$.useRef(0),i=$.useCallback(s=>{const a=n.current+s;e(a),function c(h){n.current=h,window.clearTimeout(r.current),h!==""&&(r.current=window.setTimeout(()=>c(""),1e3))}(a)},[e]),o=$.useCallback(()=>{n.current="",window.clearTimeout(r.current)},[]);return $.useEffect(()=>()=>window.clearTimeout(r.current),[]),[n,i,o]}function Jx(t,e,n){const i=e.length>1&&Array.from(e).every(h=>h===e[0])?e[0]:e,o=n?t.indexOf(n):-1;let s=cD(t,Math.max(o,0));i.length===1&&(s=s.filter(h=>h!==n));const c=s.find(h=>h.textValue.toLowerCase().startsWith(i.toLowerCase()));return c!==n?c:void 0}function cD(t,e){return t.map((n,r)=>t[(e+r)%t.length])}const e3=(t,e=[])=>{if(Array.isArray(t))return t.reduce((r,i)=>e3(i,r),e);const n=e.indexOf(t);return n===-1?[...e,t]:[...e.slice(0,n),...e.slice(n+1)]},uD=vg,hD=bg,fD=wg,dD=xg,gD=yg,mD=Cg,pD=Sg,vD=Ag,bD=Rg,wD=kg,xD=Tg,yD=Mg,CD=Eg,$D=Og,SD=Ig,AD=_g,nr=Object.freeze(Object.defineProperty({__proto__:null,Arrow:AD,Content:mD,Group:vD,Icon:dD,Item:wD,ItemIndicator:yD,ItemText:xD,Label:bD,Portal:gD,Root:uD,ScrollDownButton:$D,ScrollUpButton:CD,Select:vg,SelectArrow:_g,SelectContent:Cg,SelectGroup:Ag,SelectIcon:xg,SelectItem:kg,SelectItemIndicator:Mg,SelectItemText:Tg,SelectLabel:Rg,SelectPortal:yg,SelectScrollDownButton:Og,SelectScrollUpButton:Eg,SelectSeparator:Ig,SelectTrigger:bg,SelectValue:wg,SelectViewport:Sg,Separator:SD,Trigger:hD,Value:fD,Viewport:pD,createSelectScope:KO},Symbol.toStringTag,{value:"Module"}));function oo(t,e,{checkForDefaultPrevented:n=!0}={}){return function(i){if(t?.(i),n===!1||!i.defaultPrevented)return e?.(i)}}const t3="Collapsible",[RD,n3]=bt(t3),[kD,Lg]=RD(t3),TD=b.forwardRef((t,e)=>{const{__scopeCollapsible:n,open:r,defaultOpen:i,disabled:o,onOpenChange:s,...a}=t,[c=!1,h]=_t({prop:r,defaultProp:i,onChange:s});return b.createElement(kD,{scope:n,disabled:o,contentId:Lt(),open:c,onOpenToggle:b.useCallback(()=>h(f=>!f),[h])},b.createElement(me.div,U({"data-state":Bg(c),"data-disabled":o?"":void 0},a,{ref:e})))}),MD="CollapsibleTrigger",ED=b.forwardRef((t,e)=>{const{__scopeCollapsible:n,...r}=t,i=Lg(MD,n);return b.createElement(me.button,U({type:"button","aria-controls":i.contentId,"aria-expanded":i.open||!1,"data-state":Bg(i.open),"data-disabled":i.disabled?"":void 0,disabled:i.disabled},r,{ref:e,onClick:ne(t.onClick,i.onOpenToggle)}))}),r3="CollapsibleContent",OD=b.forwardRef((t,e)=>{const{forceMount:n,...r}=t,i=Lg(r3,t.__scopeCollapsible);return b.createElement(Mt,{present:n||i.open},({present:o})=>b.createElement(DD,U({},r,{ref:e,present:o})))}),DD=b.forwardRef((t,e)=>{const{__scopeCollapsible:n,present:r,children:i,...o}=t,s=Lg(r3,n),[a,c]=b.useState(r),h=b.useRef(null),f=ye(e,h),d=b.useRef(0),m=d.current,v=b.useRef(0),w=v.current,x=s.open||a,C=b.useRef(x),S=b.useRef();return b.useEffect(()=>{const A=requestAnimationFrame(()=>C.current=!1);return()=>cancelAnimationFrame(A)},[]),ut(()=>{const A=h.current;if(A){S.current=S.current||{transitionDuration:A.style.transitionDuration,animationName:A.style.animationName},A.style.transitionDuration="0s",A.style.animationName="none";const T=A.getBoundingClientRect();d.current=T.height,v.current=T.width,C.current||(A.style.transitionDuration=S.current.transitionDuration,A.style.animationName=S.current.animationName),c(r)}},[s.open,r]),b.createElement(me.div,U({"data-state":Bg(s.open),"data-disabled":s.disabled?"":void 0,id:s.contentId,hidden:!x},o,{ref:f,style:{"--radix-collapsible-content-height":m?`${m}px`:void 0,"--radix-collapsible-content-width":w?`${w}px`:void 0,...t.style}}),x&&i)});function Bg(t){return t?"open":"closed"}const ID=TD,_D=ED,LD=OD,Ni="Accordion",BD=["Home","End","ArrowDown","ArrowUp","ArrowLeft","ArrowRight"],[Ng,ND,jD]=ah(Ni),[fh,Uee]=bt(Ni,[jD,n3]),jg=n3(),i3=$.default.forwardRef((t,e)=>{const{type:n,...r}=t,i=r,o=r;return $.default.createElement(Ng.Provider,{scope:t.__scopeAccordion},n==="multiple"?$.default.createElement(PD,U({},o,{ref:e})):$.default.createElement(HD,U({},i,{ref:e})))});i3.propTypes={type(t){const e=t.value||t.defaultValue;return t.type&&!["single","multiple"].includes(t.type)?new Error("Invalid prop `type` supplied to `Accordion`. Expected one of `single | multiple`."):t.type==="multiple"&&typeof e=="string"?new Error("Invalid prop `type` supplied to `Accordion`. Expected `single` when `defaultValue` or `value` is type `string`."):t.type==="single"&&Array.isArray(e)?new Error("Invalid prop `type` supplied to `Accordion`. Expected `multiple` when `defaultValue` or `value` is type `string[]`."):null}};const[o3,FD]=fh(Ni),[s3,VD]=fh(Ni,{collapsible:!1}),HD=$.default.forwardRef((t,e)=>{const{value:n,defaultValue:r,onValueChange:i=()=>{},collapsible:o=!1,...s}=t,[a,c]=_t({prop:n,defaultProp:r,onChange:i});return $.default.createElement(o3,{scope:t.__scopeAccordion,value:a?[a]:[],onItemOpen:c,onItemClose:$.default.useCallback(()=>o&&c(""),[o,c])},$.default.createElement(s3,{scope:t.__scopeAccordion,collapsible:o},$.default.createElement(a3,U({},s,{ref:e}))))}),PD=$.default.forwardRef((t,e)=>{const{value:n,defaultValue:r,onValueChange:i=()=>{},...o}=t,[s=[],a]=_t({prop:n,defaultProp:r,onChange:i}),c=$.default.useCallback(f=>a((d=[])=>[...d,f]),[a]),h=$.default.useCallback(f=>a((d=[])=>d.filter(m=>m!==f)),[a]);return $.default.createElement(o3,{scope:t.__scopeAccordion,value:s,onItemOpen:c,onItemClose:h},$.default.createElement(s3,{scope:t.__scopeAccordion,collapsible:!0},$.default.createElement(a3,U({},o,{ref:e}))))}),[WD,dh]=fh(Ni),a3=$.default.forwardRef((t,e)=>{const{__scopeAccordion:n,disabled:r,dir:i,orientation:o="vertical",...s}=t,a=$.default.useRef(null),c=ye(a,e),h=ND(n),d=$o(i)==="ltr",m=ne(t.onKeyDown,v=>{var w;if(!BD.includes(v.key))return;const x=v.target,C=h().filter(F=>{var H;return!((H=F.ref.current)!==null&&H!==void 0&&H.disabled)}),S=C.findIndex(F=>F.ref.current===x),A=C.length;if(S===-1)return;v.preventDefault();let T=S;const O=0,D=A-1,L=()=>{T=S+1,T>D&&(T=O)},I=()=>{T=S-1,T<O&&(T=D)};switch(v.key){case"Home":T=O;break;case"End":T=D;break;case"ArrowRight":o==="horizontal"&&(d?L():I());break;case"ArrowDown":o==="vertical"&&L();break;case"ArrowLeft":o==="horizontal"&&(d?I():L());break;case"ArrowUp":o==="vertical"&&I();break}const V=T%A;(w=C[V].ref.current)===null||w===void 0||w.focus()});return $.default.createElement(WD,{scope:n,disabled:r,direction:i,orientation:o},$.default.createElement(Ng.Slot,{scope:n},$.default.createElement(me.div,U({},s,{"data-orientation":o,ref:c,onKeyDown:r?void 0:m}))))}),R0="AccordionItem",[zD,Fg]=fh(R0),UD=$.default.forwardRef((t,e)=>{const{__scopeAccordion:n,value:r,...i}=t,o=dh(R0,n),s=FD(R0,n),a=jg(n),c=Lt(),h=r&&s.value.includes(r)||!1,f=o.disabled||t.disabled;return $.default.createElement(zD,{scope:n,open:h,disabled:f,triggerId:c},$.default.createElement(ID,U({"data-orientation":o.orientation,"data-state":l3(h)},a,i,{ref:e,disabled:f,open:h,onOpenChange:d=>{d?s.onItemOpen(r):s.onItemClose(r)}})))}),qD="AccordionHeader",KD=$.default.forwardRef((t,e)=>{const{__scopeAccordion:n,...r}=t,i=dh(Ni,n),o=Fg(qD,n);return $.default.createElement(me.h3,U({"data-orientation":i.orientation,"data-state":l3(o.open),"data-disabled":o.disabled?"":void 0},r,{ref:e}))}),Uv="AccordionTrigger",GD=$.default.forwardRef((t,e)=>{const{__scopeAccordion:n,...r}=t,i=dh(Ni,n),o=Fg(Uv,n),s=VD(Uv,n),a=jg(n);return $.default.createElement(Ng.ItemSlot,{scope:n},$.default.createElement(_D,U({"aria-disabled":o.open&&!s.collapsible||void 0,"data-orientation":i.orientation,id:o.triggerId},a,r,{ref:e})))}),YD="AccordionContent",XD=$.default.forwardRef((t,e)=>{const{__scopeAccordion:n,...r}=t,i=dh(Ni,n),o=Fg(YD,n),s=jg(n);return $.default.createElement(LD,U({role:"region","aria-labelledby":o.triggerId,"data-orientation":i.orientation},s,r,{ref:e,style:{"--radix-accordion-content-height":"var(--radix-collapsible-content-height)","--radix-accordion-content-width":"var(--radix-collapsible-content-width)",...t.style}}))});function l3(t){return t?"open":"closed"}const ZD=i3,QD=UD,JD=KD,eI=GD,tI=XD,nI=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M16 2A12.014 12.014 0 0 0 4 14c0 3 1.57 6.883 4.201 10.375C10.85 27.894 13.764 30 16 30s5.151-2.101 7.799-5.625C26.43 20.875 28 17 28 14A12.014 12.014 0 0 0 16 2M8 14.5A1.5 1.5 0 0 1 9.5 13a4.5 4.5 0 0 1 4.5 4.5 1.5 1.5 0 0 1-1.5 1.5A4.5 4.5 0 0 1 8 14.5M18 25h-4a1 1 0 0 1 0-2h4a1 1 0 0 1 0 2m1.5-6a1.5 1.5 0 0 1-1.5-1.5 4.5 4.5 0 0 1 4.5-4.5 1.5 1.5 0 0 1 1.5 1.5 4.5 4.5 0 0 1-4.5 4.5"})})};b.forwardRef(nI);const rI=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M28 6H4a2 2 0 0 0-2 2v3a2 2 0 0 0 2 2v11a2 2 0 0 0 2 2h20a2 2 0 0 0 2-2V13a2 2 0 0 0 2-2V8a2 2 0 0 0-2-2m-9 12h-6a1 1 0 0 1 0-2h6a1 1 0 0 1 0 2m9-7H4V8h24z"})})};b.forwardRef(rI);const iI=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M30.5 7v6a1.5 1.5 0 0 1-1.5 1.5h-6a1.5 1.5 0 0 1 0-3h2.137l-2.375-2.173-.047-.046a9.5 9.5 0 1 0-6.84 16.219H16a9.44 9.44 0 0 0 6.519-2.59 1.5 1.5 0 1 1 2.061 2.181A12.43 12.43 0 0 1 16 28.5h-.171a12.5 12.5 0 1 1 8.985-21.368L27.5 9.59V7a1.5 1.5 0 0 1 3 0"})})},oI=b.forwardRef(iI),sI=oI,aI=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"m26.061 19.061-9 9a1.503 1.503 0 0 1-2.125 0l-9-9a1.503 1.503 0 1 1 2.125-2.125l6.439 6.439V5a1.5 1.5 0 1 1 3 0v18.375l6.439-6.44a1.502 1.502 0 1 1 2.125 2.125z"})})};b.forwardRef(aI);const lI=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M28.5 16a1.5 1.5 0 0 1-1.5 1.5H8.625l6.44 6.439a1.502 1.502 0 1 1-2.125 2.125l-9-9a1.5 1.5 0 0 1 0-2.125l9-9a1.503 1.503 0 0 1 2.125 2.125L8.625 14.5H27a1.5 1.5 0 0 1 1.5 1.5"})})};b.forwardRef(lI);const cI=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:16,height:16,fill:o,viewBox:"0 0 16 16",stroke:s,ref:r,...n,children:p.jsx("path",{d:"M14.75 8a.75.75 0 0 1-.75.75H6.813l3.22 3.22a.751.751 0 1 1-1.063 1.062l-4.5-4.5a.75.75 0 0 1 0-1.063l4.5-4.5a.751.751 0 0 1 1.063 1.063L6.813 7.25H14a.75.75 0 0 1 .75.75M2.5 1.75a.75.75 0 0 0-.75.75v11a.75.75 0 0 0 1.5 0v-11a.75.75 0 0 0-.75-.75"})})};b.forwardRef(cI);const uI=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:16,height:16,fill:o,viewBox:"0 0 16 16",stroke:s,ref:r,...n,children:p.jsx("path",{d:"M11.53 7.47a.75.75 0 0 1 0 1.062l-4.5 4.5a.751.751 0 1 1-1.062-1.063l3.22-3.219H2a.75.75 0 1 1 0-1.5h7.188L5.969 4.03a.751.751 0 1 1 1.063-1.062zm1.97-5.72a.75.75 0 0 0-.75.75v11a.75.75 0 0 0 1.5 0v-11a.75.75 0 0 0-.75-.75"})})};b.forwardRef(uI);const hI=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"m28.061 17.061-9 9a1.503 1.503 0 1 1-2.125-2.125l6.439-6.436H5a1.5 1.5 0 1 1 0-3h18.375l-6.436-6.44a1.503 1.503 0 0 1 2.125-2.125l9 9a1.5 1.5 0 0 1-.003 2.126"})})};b.forwardRef(hI);const fI=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M26.061 15.061a1.5 1.5 0 0 1-2.125 0L17.5 8.625V27a1.5 1.5 0 1 1-3 0V8.625l-6.439 6.436a1.503 1.503 0 1 1-2.125-2.125l9-9a1.5 1.5 0 0 1 2.125 0l9 9a1.5 1.5 0 0 1 0 2.125"})})},dI=b.forwardRef(fI),gI=dI,mI=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M11 13.5H5A1.5 1.5 0 0 1 3.5 12V6a1.5 1.5 0 0 1 3 0v1.733C8.581 5.683 11.786 3.5 16 3.5c5.558 0 8.92 3.299 9.061 3.439a1.5 1.5 0 0 1-2.117 2.125C22.889 9.01 20.25 6.5 16 6.5c-3.625 0-6.367 2.21-8 4h3a1.5 1.5 0 1 1 0 3m16 5h-6a1.5 1.5 0 1 0 0 3h3c-1.625 1.79-4.375 4-8 4-4.25 0-6.889-2.511-6.944-2.565A1.5 1.5 0 0 0 6.94 25.06c.141.141 3.504 3.44 9.061 3.44 4.214 0 7.419-2.183 9.5-4.233V26a1.5 1.5 0 1 0 3 0v-6a1.5 1.5 0 0 0-1.5-1.5"})})};b.forwardRef(mI);const pI=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 256 256",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M220 48v48a12 12 0 0 1-24 0V77l-39.51 39.52a12 12 0 0 1-17-17L179 60h-19a12 12 0 0 1 0-24h48a12 12 0 0 1 12 12M99.51 139.51 60 179v-19a12 12 0 0 0-24 0v48a12 12 0 0 0 12 12h48a12 12 0 0 0 0-24H77l39.52-39.51a12 12 0 0 0-17-17Z"})})};b.forwardRef(pI);const vI=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M27.725 21.993C27.031 20.798 26 17.416 26 13a10 10 0 0 0-20 0c0 4.418-1.032 7.797-1.726 8.993A2 2 0 0 0 6 25h5.101a5 5 0 0 0 9.798 0H26a2 2 0 0 0 1.725-3.008M16 27a3 3 0 0 1-2.828-2h5.656A3 3 0 0 1 16 27"})})};b.forwardRef(vI);const bI=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M22.135 14.308A6.001 6.001 0 0 0 17.5 4.5H9A1.5 1.5 0 0 0 7.5 6v19A1.5 1.5 0 0 0 9 26.5h10a6.5 6.5 0 0 0 3.135-12.192M10.5 7.5h7a3 3 0 0 1 0 6h-7zm8.5 16h-8.5v-7H19a3.5 3.5 0 1 1 0 7"})})},wI=b.forwardRef(bI),xI=wI,yI=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M27 4v20a1 1 0 0 1-1 1H9a2 2 0 0 0-2 2h17a1 1 0 0 1 0 2H6a1 1 0 0 1-1-1V7a4 4 0 0 1 4-4h17a1 1 0 0 1 1 1"})})};b.forwardRef(yI);const CI=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M19 14a1 1 0 0 1-1 1h-4a1 1 0 0 1 0-2h4a1 1 0 0 1 1 1m10-5v16a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V9a2 2 0 0 1 2-2h5V6a3 3 0 0 1 3-3h6a3 3 0 0 1 3 3v1h5a2 2 0 0 1 2 2M12 7h8V6a1 1 0 0 0-1-1h-6a1 1 0 0 0-1 1zm15 7.201V9H5v5.201A23 23 0 0 0 16 17a23 23 0 0 0 11-2.799"})})};b.forwardRef(CI);const $I=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M9.5 8A1.5 1.5 0 0 1 11 6.5h16a1.5 1.5 0 0 1 0 3H11A1.5 1.5 0 0 1 9.5 8M27 14.5H11a1.5 1.5 0 1 0 0 3h16a1.5 1.5 0 1 0 0-3m0 8H11a1.5 1.5 0 1 0 0 3h16a1.5 1.5 0 1 0 0-3M5.5 14a2 2 0 1 0 0 4 2 2 0 0 0 0-4m0-8a2 2 0 1 0 0 4 2 2 0 0 0 0-4m0 16a2 2 0 1 0 0 4 2 2 0 0 0 0-4"})})},SI=b.forwardRef($I),AI=SI,RI=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M26 4h-3V3a1 1 0 0 0-2 0v1H11V3a1 1 0 0 0-2 0v1H6a2 2 0 0 0-2 2v20a2 2 0 0 0 2 2h20a2 2 0 0 0 2-2V6a2 2 0 0 0-2-2m0 6H6V6h3v1a1 1 0 0 0 2 0V6h10v1a1 1 0 0 0 2 0V6h3z"})})},kI=b.forwardRef(RI),TI=kI,MI=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M30 14h-1.35l-3.472-7.812A2 2 0 0 0 23.35 5H8.65a2 2 0 0 0-1.828 1.188L3.35 14H2a1 1 0 0 0 0 2h1v10a2 2 0 0 0 2 2h3a2 2 0 0 0 2-2v-2h12v2a2 2 0 0 0 2 2h3a2 2 0 0 0 2-2V16h1a1 1 0 0 0 0-2m-20 6H8a1 1 0 0 1 0-2h2a1 1 0 0 1 0 2m12 0a1 1 0 0 1 0-2h2a1 1 0 0 1 0 2z"})})};b.forwardRef(MI);const EI=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"m26.708 12.708-10 10a1 1 0 0 1-1.415 0l-10-10A1 1 0 0 1 6 11h20a1 1 0 0 1 .707 1.707"})})},OI=b.forwardRef(EI),Mi=OI,DI=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M26.924 20.383A1 1 0 0 1 26 21H6a1 1 0 0 1-.708-1.707l10-10a1 1 0 0 1 1.415 0l10 10a1 1 0 0 1 .217 1.09"})})};b.forwardRef(DI);const II=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M7 26a1 1 0 1 1-2 0 1 1 0 0 0-1-1 1 1 0 0 1 0-2 3 3 0 0 1 3 3m-3-7a1 1 0 0 0 0 2 5 5 0 0 1 5 5 1 1 0 1 0 2 0 7.01 7.01 0 0 0-7-7m0-4a1 1 0 0 0 0 2 9.01 9.01 0 0 1 9 9 1 1 0 0 0 2 0A11.01 11.01 0 0 0 4 15M27 5H5a2 2 0 0 0-2 2v5a1 1 0 0 0 1 1 13.014 13.014 0 0 1 13 13 1 1 0 0 0 1 1h9a2 2 0 0 0 2-2V7a2 2 0 0 0-2-2"})})};b.forwardRef(II);const _I=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M25 3h-1a2 2 0 0 0-2 2v2h-3.5V5a2 2 0 0 0-2-2h-1a2 2 0 0 0-2 2v2H10V5a2 2 0 0 0-2-2H7a2 2 0 0 0-2 2v5.586A1.98 1.98 0 0 0 5.586 12L7 13.414V27a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2V13.414L26.414 12A1.98 1.98 0 0 0 27 10.586V5a2 2 0 0 0-2-2m-6 24h-6v-8a3 3 0 0 1 6 0z"})})};b.forwardRef(_I);const LI=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M27 5H5a2 2 0 0 0-2 2v18a2 2 0 0 0 2 2h22a2 2 0 0 0 2-2V7a2 2 0 0 0-2-2m-3.5 4a1.5 1.5 0 1 1 0 3 1.5 1.5 0 0 1 0-3m0 7a1.5 1.5 0 1 1 0 3 1.5 1.5 0 0 1 0-3m-5-2a1.5 1.5 0 1 1 0 3 1.5 1.5 0 0 1 0-3m-3-5a1.5 1.5 0 1 1 0 3 1.5 1.5 0 0 1 0-3m-3 7a1.5 1.5 0 1 1 0 3 1.5 1.5 0 0 1 0-3M25 24H7a1 1 0 0 1-1-1V9a1 1 0 0 1 2 0v13h17a1 1 0 0 1 0 2"})})};b.forwardRef(LI);const BI=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M3.094 14.443a12.8 12.8 0 0 1 2.914-6.72 2 2 0 0 1 2.953-.138l3.459 3.533a1.98 1.98 0 0 1 .211 2.56 3.2 3.2 0 0 0-.462.968.5.5 0 0 1-.478.354h-8.1a.5.5 0 0 1-.497-.557m14.08-11.435A2 2 0 0 0 15 5v5.084a1.98 1.98 0 0 0 1.656 1.97 4 4 0 0 1 .677 7.72.51.51 0 0 0-.333.476v8.154a.5.5 0 0 0 .558.5A13.04 13.04 0 0 0 29 16.185C29.094 9.4 23.899 3.61 17.174 3.008M14.656 19.77a4 4 0 0 1-2.425-2.427.51.51 0 0 0-.475-.343H3.59a.5.5 0 0 0-.5.556A13.01 13.01 0 0 0 14.443 28.91a.5.5 0 0 0 .556-.5V20.25a.51.51 0 0 0-.343-.48"})})};b.forwardRef(BI);const NI=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M16 3a13 13 0 1 0 13 13A13.013 13.013 0 0 0 16 3m0 2a11 11 0 0 1 8.984 4.659L16 14.845zm0 22a11 11 0 0 1-8.984-4.659l18.97-10.951A11 11 0 0 1 16 27"})})};b.forwardRef(NI);const jI=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"m29.061 10.061-16 16a1.5 1.5 0 0 1-2.125 0l-7-7a1.504 1.504 0 0 1 2.125-2.125L12 22.875 26.939 7.939a1.502 1.502 0 1 1 2.125 2.125z"})})},FI=b.forwardRef(jI),VI=FI,HI=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M16 3a13 13 0 1 0 13 13A13.013 13.013 0 0 0 16 3m5.708 10.708-7 7a1 1 0 0 1-1.415 0l-3-3a1 1 0 0 1 1.415-1.415L14 18.586l6.293-6.293a1 1 0 0 1 1.415 1.415"})})},PI=b.forwardRef(HI),WI=PI,zI=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:16,height:16,viewBox:"0 0 256 256",fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M176.49 95.51a12 12 0 0 1 0 17l-56 56a12 12 0 0 1-17 0l-24-24a12 12 0 1 1 17-17L112 143l47.51-47.52a12 12 0 0 1 16.98.03M236 128A108 108 0 1 1 128 20a108.12 108.12 0 0 1 108 108m-24 0a84 84 0 1 0-84 84 84.09 84.09 0 0 0 84-84"})})};b.forwardRef(zI);const UI=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"m27.061 13.061-10 10a1.503 1.503 0 0 1-2.125 0l-10-10a1.503 1.503 0 1 1 2.125-2.125L16 19.875l8.939-8.94a1.502 1.502 0 1 1 2.125 2.125z"})})};b.forwardRef(UI);const qI=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M21.061 24.939a1.503 1.503 0 0 1-2.125 2.125l-10-10a1.5 1.5 0 0 1 0-2.125l10-10a1.503 1.503 0 0 1 2.125 2.125L12.125 16z"})})},KI=b.forwardRef(qI),c3=KI,GI=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"m23.061 17.061-10 10a1.503 1.503 0 0 1-2.125-2.125L19.875 16l-8.936-8.939a1.502 1.502 0 1 1 2.125-2.125l10 10a1.5 1.5 0 0 1-.003 2.125"})})},YI=b.forwardRef(GI),Vg=YI,XI=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M27.061 21.061a1.503 1.503 0 0 1-2.125 0L16 12.125l-8.939 8.936a1.503 1.503 0 0 1-2.125-2.125l10-10a1.5 1.5 0 0 1 2.125 0l10 10a1.5 1.5 0 0 1 0 2.125"})})};b.forwardRef(XI);const ZI=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M16 3a13 13 0 1 0 13 13A13.013 13.013 0 0 0 16 3m7 14h-7a1 1 0 0 1-1-1V9a1 1 0 0 1 2 0v6h6a1 1 0 0 1 0 2"})})},QI=b.forwardRef(ZI),JI=QI,e_=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M28 16a12 12 0 0 1-20.236 8.728 1.002 1.002 0 0 1 1.375-1.456 10 10 0 1 0-.21-14.343c-.441.446-.857.885-1.26 1.321l2.039 2.043A1 1 0 0 1 9 14H4a1 1 0 0 1-1-1V8a1 1 0 0 1 1.707-.707L6.25 8.838c.402-.437.817-.875 1.258-1.32A12 12 0 0 1 28 16M16 9a1 1 0 0 0-1 1v6a1 1 0 0 0 .485.858l5 3a.999.999 0 0 0 1.486-1.1 1 1 0 0 0-.456-.616L17 15.434V10a1 1 0 0 0-1-1"})})};b.forwardRef(e_);const t_=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M20.008 5a11.01 11.01 0 0 0-9.847 6.084A10.9 10.9 0 0 0 9 15.966 1.023 1.023 0 0 1 8.071 17 1 1 0 0 1 7 16a13 13 0 0 1 .668-4.115.5.5 0 0 0-.594-.647A8.01 8.01 0 0 0 1 19c0 4.399 3.719 8 8.125 8H20a11.01 11.01 0 0 0 10.991-11.435C30.764 9.693 25.884 5 20.008 5"})})};b.forwardRef(t_);const n_=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M30.991 15.565C30.764 9.693 25.884 5 20.008 5a11.01 11.01 0 0 0-9.847 6.084A10.9 10.9 0 0 0 9 15.966 1.023 1.023 0 0 1 8.071 17 1 1 0 0 1 7 16a13 13 0 0 1 .668-4.115.5.5 0 0 0-.594-.647A8.01 8.01 0 0 0 1 19c0 4.399 3.719 8 8.125 8H20a11.01 11.01 0 0 0 10.991-11.435m-7.283 3.143a1 1 0 0 1-1.415 0L20 16.414V24a1 1 0 0 1-2 0v-7.586l-2.293 2.293a1 1 0 0 1-1.415-1.415l4-4a1 1 0 0 1 1.415 0l4 4a1 1 0 0 1 0 1.415"})})};b.forwardRef(n_);const r_=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M8.96 12.153 4.342 16l4.618 3.848a1.5 1.5 0 1 1-1.92 2.305l-6-5a1.5 1.5 0 0 1 0-2.305l6-5a1.5 1.5 0 0 1 1.92 2.304m22 2.694-6-5a1.5 1.5 0 1 0-1.92 2.306L27.658 16l-4.618 3.848a1.5 1.5 0 1 0 1.92 2.305l6-5a1.5 1.5 0 0 0 0-2.305M20.512 3.59a1.5 1.5 0 0 0-1.922.898l-8 22a1.5 1.5 0 0 0 2.82 1.024l8-22a1.5 1.5 0 0 0-.898-1.922"})})},i_=b.forwardRef(r_),o_=i_,s_=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:16,height:16,viewBox:"0 0 256 256",fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M200 40h-32a16 16 0 0 0-16-16H32a16 16 0 0 0-16 16v80a16 16 0 0 0 16 16h8v64a16 16 0 0 0 16 16h144a16 16 0 0 0 16-16V56a16 16 0 0 0-16-16m-93.66 21.66a8 8 0 0 1 11.32-11.32l24 24a8 8 0 0 1 0 11.32l-24 24a8 8 0 0 1-11.32-11.32L124.69 80Zm-64 24a8 8 0 0 1 0-11.32l24-24a8 8 0 0 1 11.32 11.32L59.31 80l18.35 18.34a8 8 0 0 1-11.32 11.32ZM200 200H56v-64h96a16 16 0 0 0 16-16V56h32Z"})})};b.forwardRef(s_);const a_=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M26 10H4a1 1 0 0 0-1 1v6a12.04 12.04 0 0 0 4.068 9H4a1 1 0 0 0 0 2h22a1 1 0 0 0 0-2h-3.067a12.1 12.1 0 0 0 3.375-5.011A5 5 0 0 0 31 16v-1a5 5 0 0 0-5-5m3 6a3 3 0 0 1-2.15 2.875Q27 17.944 27 17v-4.828A3 3 0 0 1 29 15zM14 7V3a1 1 0 0 1 2 0v4a1 1 0 0 1-2 0m4 0V3a1 1 0 0 1 2 0v4a1 1 0 0 1-2 0m-8 0V3a1 1 0 0 1 2 0v4a1 1 0 0 1-2 0"})})};b.forwardRef(a_);const l_=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M29.743 13.401a1 1 0 0 0-.487-.675l-3.729-2.125-.015-4.202a1 1 0 0 0-.353-.76 14 14 0 0 0-4.59-2.584 1 1 0 0 0-.808.074L16 5.23l-3.765-2.106a1 1 0 0 0-.809-.075 14 14 0 0 0-4.585 2.594 1 1 0 0 0-.354.758L6.47 10.61 2.74 12.734a1 1 0 0 0-.486.675 13.3 13.3 0 0 0 0 5.195 1 1 0 0 0 .486.675l3.729 2.125.015 4.204a1 1 0 0 0 .353.76 14 14 0 0 0 4.59 2.583 1 1 0 0 0 .808-.073L16 26.768l3.765 2.107a1.013 1.013 0 0 0 .809.073 14 14 0 0 0 4.585-2.592 1 1 0 0 0 .354-.759l.018-4.206 3.729-2.125a1 1 0 0 0 .486-.675c.34-1.713.338-3.477-.003-5.19M16 21a5 5 0 1 1 0-10 5 5 0 0 1 0 10"})})};b.forwardRef(l_);const c_=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M18.5 12V6a1.5 1.5 0 1 1 3 0v4.5H26a1.5 1.5 0 1 1 0 3h-6a1.5 1.5 0 0 1-1.5-1.5M12 18.5H6a1.5 1.5 0 1 0 0 3h4.5V26a1.5 1.5 0 1 0 3 0v-6a1.5 1.5 0 0 0-1.5-1.5m14 0h-6a1.5 1.5 0 0 0-1.5 1.5v6a1.5 1.5 0 1 0 3 0v-4.5H26a1.5 1.5 0 1 0 0-3m-14-14A1.5 1.5 0 0 0 10.5 6v4.5H6a1.5 1.5 0 1 0 0 3h6a1.5 1.5 0 0 0 1.5-1.5V6A1.5 1.5 0 0 0 12 4.5"})})},u_=b.forwardRef(c_),h_=u_,f_=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M22.5 17.5h-2v-3h2a5 5 0 1 0-5-5v2h-3v-2a5 5 0 1 0-5 5h2v3h-2a5 5 0 1 0 5 5v-2h3v2a5 5 0 1 0 5-5m-2-8a2 2 0 1 1 2 2h-2zm-13 0a2 2 0 0 1 4 0v2h-2a2 2 0 0 1-2-2m4 13a2 2 0 1 1-2-2h2zm3-8h3v3h-3zm8 10a2 2 0 0 1-2-2v-2h2a2 2 0 0 1 0 4"})})};b.forwardRef(f_);const d_=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M30.5 24a1.5 1.5 0 0 1-1.5 1.5h-3.5V29a1.5 1.5 0 1 1-3 0v-3.5H8A1.5 1.5 0 0 1 6.5 24V9.5H3a1.5 1.5 0 0 1 0-3h3.5V3a1.5 1.5 0 0 1 3 0v19.5H29a1.5 1.5 0 0 1 1.5 1.5M13 9.5h9.5V19a1.5 1.5 0 1 0 3 0V8A1.5 1.5 0 0 0 24 6.5H13a1.5 1.5 0 0 0 0 3"})})};b.forwardRef(d_);const g_=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M26.061 23.939a1.503 1.503 0 0 1-2.125 2.125L16 18.125l-7.939 7.936a1.503 1.503 0 1 1-2.125-2.125L13.875 16 5.939 8.061a1.503 1.503 0 1 1 2.125-2.125L16 13.875l7.939-7.94a1.502 1.502 0 1 1 2.125 2.125L18.125 16z"})})},m_=b.forwardRef(g_),ji=m_,p_=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M16 3a13 13 0 1 0 13 13A13.013 13.013 0 0 0 16 3m4.708 16.293a1 1 0 0 1-1.415 1.415L16 17.414l-3.293 3.293a1 1 0 0 1-1.415-1.415L14.587 16l-3.293-3.293a1 1 0 1 1 1.415-1.415L16 14.587l3.293-3.293a1 1 0 0 1 1.415 1.415L17.414 16z"})})};b.forwardRef(p_);const v_=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M30.48 9.524a1.51 1.51 0 0 0-1.668-.213l-6.276 3.125-5.24-8.704a1.514 1.514 0 0 0-2.592 0l-5.24 8.708L3.19 9.315a1.514 1.514 0 0 0-2.113 1.825l4.625 14.17a1 1 0 0 0 1.46.55C7.194 25.841 10.39 24 16 24s8.806 1.841 8.835 1.859a1 1 0 0 0 1.464-.549l4.625-14.166a1.51 1.51 0 0 0-.444-1.62M21.98 19.6a1 1 0 0 1-1.159.811 28.5 28.5 0 0 0-9.652 0 1 1 0 0 1-.348-1.97 30.6 30.6 0 0 1 10.348 0 1 1 0 0 1 .816 1.159z"})})};b.forwardRef(v_);const b_=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M27.414 24a2 2 0 0 1 0 2.829l-.585.585a2 2 0 0 1-2.829 0l-6.906-6.905-2.735 6.292A1.98 1.98 0 0 1 12.533 28h-.098a1.98 1.98 0 0 1-1.801-1.375L4.1 6.615A1.994 1.994 0 0 1 6.615 4.1l20.01 6.534a2 2 0 0 1 .176 3.725l-6.292 2.735z"})})};b.forwardRef(b_);const w_=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M16 3C9.271 3 4 6.075 4 10v12c0 3.925 5.271 7 12 7s12-3.075 12-7V10c0-3.925-5.271-7-12-7m10 13c0 1.203-.985 2.429-2.701 3.365C21.366 20.419 18.774 21 16 21s-5.366-.581-7.299-1.635C6.985 18.429 6 17.203 6 16v-2.08C8.133 15.795 11.779 17 16 17s7.868-1.21 10-3.08zm-2.701 9.365C21.366 26.419 18.774 27 16 27s-5.366-.581-7.299-1.635C6.985 24.429 6 23.203 6 22v-2.08C8.133 21.795 11.779 23 16 23s7.868-1.21 10-3.08V22c0 1.203-.985 2.429-2.701 3.365"})})};b.forwardRef(w_);const x_=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M29 12a2 2 0 0 0-2-2h-4V6a2 2 0 0 0-2-2H5a2 2 0 0 0-2 2v16a1 1 0 0 0 1.625.777L9 19.25V23a2 2 0 0 0 2 2h11.699l4.676 3.778A1 1 0 0 0 29 28zm-5.319 11.223a1 1 0 0 0-.625-.223H11v-4h10a2 2 0 0 0 2-2v-5h4v13.906z"})})};b.forwardRef(x_);const y_=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M28.5 19v7a2.5 2.5 0 0 1-2.5 2.5H6A2.5 2.5 0 0 1 3.5 26v-7a1.5 1.5 0 0 1 3 0v6.5h19V19a1.5 1.5 0 1 1 3 0m-13.561 1.061a1.5 1.5 0 0 0 2.125 0l5-5a1.502 1.502 0 1 0-2.125-2.125L17.5 15.375V5a1.5 1.5 0 1 0-3 0v10.375l-2.439-2.436a1.502 1.502 0 1 0-2.125 2.125z"})})};b.forwardRef(y_);const C_=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M13.5 7.5a2 2 0 1 1-4 0 2 2 0 0 1 4 0m7 2a2 2 0 1 0 0-4 2 2 0 0 0 0 4m-9 4.5a2 2 0 1 0 0 4 2 2 0 0 0 0-4m9 0a2 2 0 1 0 0 4 2 2 0 0 0 0-4m-9 8.5a2 2 0 1 0 0 4 2 2 0 0 0 0-4m9 0a2 2 0 1 0 0 4 2 2 0 0 0 0-4"})})};b.forwardRef(C_);const $_=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M27 4H11a1 1 0 0 0-1 1v5H5a1 1 0 0 0-1 1v16a1 1 0 0 0 1 1h16a1 1 0 0 0 1-1v-5h5a1 1 0 0 0 1-1V5a1 1 0 0 0-1-1m-1 16h-4v-9a1 1 0 0 0-1-1h-9V6h14z"})})};b.forwardRef($_);const S_=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M16 3a13 13 0 1 0 13 13A13.013 13.013 0 0 0 16 3m11 13c.001 1.411-.27 2.81-.8 4.118l-5.587-3.437a2 2 0 0 0-.78-.279l-2.853-.385a2.01 2.01 0 0 0-2 .983h-1.09l-.475-.983a1.99 1.99 0 0 0-1.375-1.083l-1-.216.978-1.718h2.088c.338 0 .67-.087.966-.25l1.532-.845q.202-.113.375-.268l3.364-3.042a1.99 1.99 0 0 0 .407-2.458l-.045-.08A11.01 11.01 0 0 1 27 16M5 16a10.94 10.94 0 0 1 1.068-4.725l1.417 3.784a2 2 0 0 0 1.453 1.25l2.678.576.476.99a2.01 2.01 0 0 0 1.8 1.125h.186l-.904 2.029a2 2 0 0 0 .357 2.171l.018.018L16 25.742l-.242 1.25A11.014 11.014 0 0 1 5 16"})})};b.forwardRef(S_);const A_=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:[p.jsx("path",{d:"M20.689 3.88A13 13 0 0 0 16 3a13 13 0 0 0-8.155 23.124l1.02-1.765A11 11 0 0 1 5 16a10.94 10.94 0 0 1 1.068-4.724l1.417 3.784a2 2 0 0 0 1.453 1.25l2.678.576.476.99q.113.226.275.418l1.169-2.025-.121-.25a1.99 1.99 0 0 0-1.375-1.084l-1-.217.978-1.717h2.088c.338 0 .67-.087.966-.25l.726-.4z"}),p.jsx("path",{fillRule:"evenodd",d:"m24 2.144 1.732 1-1.58 2.736q.54.435 1.036.932A13.01 13.01 0 0 1 29 16a13 13 0 0 1-17.69 12.124l-1.578 2.732-1.732-1zm-.86 5.49-4.936 8.549 1.628.22c.277.037.543.132.78.278l5.588 3.436c.53-1.308.801-2.706.8-4.117a11.01 11.01 0 0 0-3.86-8.367M13.92 23.6l-1.593 2.76a11 11 0 0 0 3.43.631l.242-1.25z",clipRule:"evenodd"})]})};b.forwardRef(A_);const R_=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M16 3a13 13 0 1 0 13 13A13.013 13.013 0 0 0 16 3m-4.5 9a1.5 1.5 0 1 1 0 3 1.5 1.5 0 0 1 0-3m10.365 7.5C20.579 21.724 18.441 23 16 23s-4.579-1.275-5.865-3.5a1.001 1.001 0 0 1 1.477-1.31q.157.129.253.31C12.799 20.114 14.266 21 16 21s3.201-.887 4.135-2.5a1 1 0 1 1 1.73 1M20.5 15a1.5 1.5 0 1 1 0-3 1.5 1.5 0 0 1 0 3"})})};b.forwardRef(R_);const k_=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M16 3a13 13 0 1 0 13 13A13.013 13.013 0 0 0 16 3m-4.5 9a1.5 1.5 0 1 1 0 3 1.5 1.5 0 0 1 0-3m10 10.865a1 1 0 0 1-1.365-.365C19.201 20.886 17.734 20 16 20s-3.201.887-4.135 2.5a1.001 1.001 0 1 1-1.73-1C11.421 19.276 13.559 18 16 18s4.579 1.275 5.865 3.5a1 1 0 0 1-.365 1.365M20.5 15a1.5 1.5 0 1 1 0-3 1.5 1.5 0 0 1 0 3"})})};b.forwardRef(k_);const T_=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M27.5 6v5a1.5 1.5 0 1 1-3 0V7.5H21a1.5 1.5 0 0 1 0-3h5A1.5 1.5 0 0 1 27.5 6M11 24.5H7.5V21a1.5 1.5 0 0 0-3 0v5A1.5 1.5 0 0 0 6 27.5h5a1.5 1.5 0 1 0 0-3m15-5a1.5 1.5 0 0 0-1.5 1.5v3.5H21a1.5 1.5 0 1 0 0 3h5a1.5 1.5 0 0 0 1.5-1.5v-5a1.5 1.5 0 0 0-1.5-1.5m-15-15H6A1.5 1.5 0 0 0 4.5 6v5a1.5 1.5 0 0 0 3 0V7.5H11a1.5 1.5 0 0 0 0-3"})})},M_=b.forwardRef(T_),E_=M_,O_=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M28.5 13a1.5 1.5 0 1 1-3 0V8.625l-7.439 7.439a1.503 1.503 0 1 1-2.125-2.125L23.375 6.5H19a1.5 1.5 0 0 1 0-3h8A1.5 1.5 0 0 1 28.5 5zM23 16a1.5 1.5 0 0 0-1.5 1.5v8h-15v-15h8a1.5 1.5 0 1 0 0-3H6A2.5 2.5 0 0 0 3.5 10v16A2.5 2.5 0 0 0 6 28.5h16a2.5 2.5 0 0 0 2.5-2.5v-8.5A1.5 1.5 0 0 0 23 16"})})},D_=b.forwardRef(O_),I_=D_,__=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M30.914 15.595c-.044-.099-1.103-2.447-3.457-4.801C24.322 7.657 20.36 6 16 6S7.679 7.657 4.542 10.794C2.19 13.148 1.125 15.5 1.086 15.595a1 1 0 0 0 0 .812c.044.1 1.103 2.447 3.456 4.8C7.68 24.344 11.64 26 16 26s8.321-1.657 11.458-4.792c2.353-2.354 3.412-4.702 3.456-4.8a1 1 0 0 0 0-.813M16 21a5 5 0 1 1 0-10 5 5 0 0 1 0 10"})})},L_=b.forwardRef(__),B_=L_,N_=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M6.74 4.328a1 1 0 1 0-1.48 1.345l2.405 2.646c-4.54 2.786-6.493 7.081-6.579 7.276a1 1 0 0 0 0 .813c.044.098 1.103 2.446 3.456 4.8C7.68 24.343 11.64 26 16 26c2.24.013 4.459-.448 6.509-1.354l2.75 3.027a1 1 0 1 0 1.48-1.345zm11.125 15.21a4 4 0 0 1-5.209-5.73zm13.049-3.13c-.053.117-1.319 2.92-4.17 5.475a1 1 0 0 1-1.408-.072L12.675 7.884a1 1 0 0 1 .575-1.66A17 17 0 0 1 16 6c4.36 0 8.321 1.658 11.458 4.794 2.353 2.354 3.412 4.702 3.456 4.801a1 1 0 0 1 0 .813"})})};b.forwardRef(N_);const j_=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M17 15v12a1 1 0 0 1-2 0V15a1 1 0 0 1 2 0m8 9a1 1 0 0 0-1 1v2a1 1 0 0 0 2 0v-2a1 1 0 0 0-1-1m3-6h-2V5a1 1 0 0 0-2 0v13h-2a1 1 0 0 0-1 1v2a1 1 0 0 0 1 1h6a1 1 0 0 0 1-1v-2a1 1 0 0 0-1-1M7 20a1 1 0 0 0-1 1v6a1 1 0 1 0 2 0v-6a1 1 0 0 0-1-1m3-6H8V5a1 1 0 0 0-2 0v9H4a1 1 0 0 0-1 1v2a1 1 0 0 0 1 1h6a1 1 0 0 0 1-1v-2a1 1 0 0 0-1-1m9-6h-2V5a1 1 0 0 0-2 0v3h-2a1 1 0 0 0-1 1v2a1 1 0 0 0 1 1h6a1 1 0 0 0 1-1V9a1 1 0 0 0-1-1"})})};b.forwardRef(j_);const F_=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"m26.48 16.851-7.474 7.559a1.97 1.97 0 0 1-1.4.585H9.415l-3.707 3.712a1.001 1.001 0 0 1-1.415-1.415l2.823-2.822L15.588 16h10.537a.5.5 0 0 1 .355.851m.607-13.03a8 8 0 0 0-10.737.518l-1.2 1.185a.5.5 0 0 0-.15.351v7.875l6.875-6.875a1 1 0 0 1 1.414 1.414L17.589 14h11.047a.5.5 0 0 0 .445-.27 8.01 8.01 0 0 0-1.994-9.909M7.854 20.904 13 15.758V8.845a.5.5 0 0 0-.851-.355L7.586 13A1.99 1.99 0 0 0 7 14.414v6.136a.5.5 0 0 0 .854.354"})})};b.forwardRef(F_);const V_=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"m26.708 10.293-7-7A1 1 0 0 0 19 3H7a2 2 0 0 0-2 2v22a2 2 0 0 0 2 2h18a2 2 0 0 0 2-2V11a1 1 0 0 0-.293-.707M19 11V5.5l5.5 5.5z"})})};b.forwardRef(V_);const H_=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:16,height:16,viewBox:"0 0 256 256",fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"m213.66 82.34-56-56A8 8 0 0 0 152 24H56a16 16 0 0 0-16 16v76a4 4 0 0 0 4 4h168a4 4 0 0 0 4-4V88a8 8 0 0 0-2.34-5.66M152 88V44l44 44ZM48 180c0 11 7.18 20 16 20a14.18 14.18 0 0 0 10.06-4.5 8.21 8.21 0 0 1 10.9-.91 8 8 0 0 1 .82 11.81A30.06 30.06 0 0 1 64 216c-17.64 0-32-16.15-32-36s14.36-36 32-36a30 30 0 0 1 21.39 9.19 8.26 8.26 0 0 1 .73 11.09 8 8 0 0 1-11.9.38A14.17 14.17 0 0 0 64 160c-8.82 0-16 9-16 20m103.81 16.31a20.82 20.82 0 0 1-9.19 15.23C137.43 215 131 216 125.13 216a61.1 61.1 0 0 1-15.13-2 8 8 0 1 1 4.3-15.41c4.38 1.2 14.95 2.7 19.55-.36.88-.59 1.83-1.52 2.14-3.93.35-2.67-.71-4.1-12.78-7.59-9.35-2.7-25-7.23-23-23.11a20.56 20.56 0 0 1 9-14.95c11.84-8 30.71-3.31 32.83-2.76a8 8 0 0 1-4.07 15.48c-4.49-1.17-15.23-2.56-19.83.56a4.54 4.54 0 0 0-2 3.67c-.12.9-.14 1.09 1.11 1.9 2.31 1.49 6.45 2.68 10.45 3.84 9.79 2.83 26.35 7.66 24.11 24.97M215.42 155l-19.89 55.68a8 8 0 0 1-15.06 0L160.58 155a8.21 8.21 0 0 1 4.5-10.45 8 8 0 0 1 10.45 4.76l12.47 34.9 12.47-34.9a8 8 0 0 1 10.45-4.76 8.23 8.23 0 0 1 4.5 10.45"})})};b.forwardRef(H_);const P_=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"m26.708 10.293-7-7A1 1 0 0 0 19 3H7a2 2 0 0 0-2 2v22a2 2 0 0 0 2 2h18a2 2 0 0 0 2-2V11a1 1 0 0 0-.293-.707m-7 11a1 1 0 0 1-1.415 1.415L16 20.414l-2.293 2.293a1 1 0 0 1-1.415-1.415L14.587 19l-2.293-2.293a1 1 0 1 1 1.415-1.415L16 17.587l2.293-2.293a1 1 0 0 1 1.415 1.415L17.414 19zM19 11V5.5l5.5 5.5z"})})};b.forwardRef(P_);const W_=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M6 15h20a1 1 0 0 0 1-1v-3a1 1 0 0 0-.293-.707l-7-7A1 1 0 0 0 19 3H7a2 2 0 0 0-2 2v9a1 1 0 0 0 1 1m13-9.5 5.5 5.5H19zM28 19a1 1 0 0 1-1 1h-3v2h2a1 1 0 0 1 0 2h-2v2a1 1 0 0 1-2 0v-7a1 1 0 0 1 1-1h4a1 1 0 0 1 1 1M8 18H6a1 1 0 0 0-1 1v7a1 1 0 1 0 2 0v-1h1a3.5 3.5 0 1 0 0-7m0 5H7v-3h1a1.5 1.5 0 1 1 0 3m8-5h-2a1 1 0 0 0-1 1v7a1 1 0 0 0 1 1h2a4.5 4.5 0 1 0 0-9m0 7h-1v-5h1a2.5 2.5 0 0 1 0 5"})})};b.forwardRef(W_);const z_=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:16,height:16,viewBox:"0 0 256 256",fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M44 120h168a4 4 0 0 0 4-4V88a8 8 0 0 0-2.34-5.66l-56-56A8 8 0 0 0 152 24H56a16 16 0 0 0-16 16v76a4 4 0 0 0 4 4m108-76 44 44h-44Zm4 164.53a8.18 8.18 0 0 1-8.25 7.47H120a8 8 0 0 1-8-8v-55.73a8.18 8.18 0 0 1 7.47-8.25 8 8 0 0 1 8.53 8v48h20a8 8 0 0 1 8 8.51m-61.49-51.88L77.83 180l16.68 23.35a8 8 0 0 1-13 9.3L68 193.76l-13.49 18.89a8 8 0 1 1-13-9.3L58.17 180l-16.68-23.35a8 8 0 0 1 2.3-11.46 8.19 8.19 0 0 1 10.88 2.38L68 166.24l13.49-18.89a8 8 0 0 1 13 9.3Zm121.28 39.66a20.81 20.81 0 0 1-9.18 15.23c-5.19 3.46-11.67 4.46-17.49 4.46a60.6 60.6 0 0 1-15.19-2 8 8 0 0 1 4.31-15.41c4.38 1.21 14.94 2.71 19.54-.35.89-.6 1.84-1.52 2.15-3.93.34-2.67-.72-4.1-12.78-7.59-9.35-2.7-25-7.23-23-23.12a20.58 20.58 0 0 1 8.95-14.94c11.84-8 30.72-3.31 32.83-2.76a8 8 0 0 1-4.07 15.48c-4.48-1.17-15.22-2.56-19.82.56a4.54 4.54 0 0 0-2 3.67c-.11.9-.13 1.08 1.12 1.9 2.31 1.49 6.45 2.68 10.45 3.84 9.87 2.82 26.39 7.65 24.18 24.96"})})};b.forwardRef(z_);const U_=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:16,height:16,viewBox:"0 0 256 256",fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M184 144h-16a8 8 0 0 0-8 8v55.73a8.17 8.17 0 0 0 7.47 8.25 8 8 0 0 0 8.53-8v-8h7.4c15.24 0 28.14-11.92 28.59-27.15A28 28 0 0 0 184 144m-.35 40H176v-24h8a12 12 0 0 1 12 13.16A12.25 12.25 0 0 1 183.65 184M136 152v55.73a8.17 8.17 0 0 1-7.47 8.25 8 8 0 0 1-8.53-8v-55.71a8.17 8.17 0 0 1 7.47-8.25A8 8 0 0 1 136 152m-40 56.53a8.17 8.17 0 0 1-8.27 7.47h-31.5a8.27 8.27 0 0 1-6-2.5 8 8 0 0 1-1.18-9.5l25.16-44H56.27a8.17 8.17 0 0 1-8.27-7.47 8 8 0 0 1 8-8.53h31.77a8.27 8.27 0 0 1 6 2.5A8 8 0 0 1 95 156l-25.21 44H88a8 8 0 0 1 8 8.53M213.66 82.34l-56-56A8 8 0 0 0 152 24H56a16 16 0 0 0-16 16v76a4 4 0 0 0 4 4h168a4 4 0 0 0 4-4V88a8 8 0 0 0-2.34-5.66M152 88V44l44 44Z"})})};b.forwardRef(U_);const q_=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M25.5 16a1.5 1.5 0 0 1-1.5 1.5H8a1.5 1.5 0 1 1 0-3h16a1.5 1.5 0 0 1 1.5 1.5M29 8.5H3a1.5 1.5 0 0 0 0 3h26a1.5 1.5 0 1 0 0-3m-10 12h-6a1.5 1.5 0 1 0 0 3h6a1.5 1.5 0 1 0 0-3"})})};b.forwardRef(q_);const K_=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M27 9H16.414L13 5.586A1.98 1.98 0 0 0 11.586 5H5a2 2 0 0 0-2 2v18.078A1.926 1.926 0 0 0 4.924 27H27.11A1.89 1.89 0 0 0 29 25.111V11a2 2 0 0 0-2-2M5 7h6.586l2 2H5z"})})};b.forwardRef(K_);const G_=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M27 9h-4.385q.075-.06.146-.125A3.7 3.7 0 0 0 24 6.196 4.08 4.08 0 0 0 19.805 2a3.7 3.7 0 0 0-2.68 1.239A6.9 6.9 0 0 0 16 5.049a6.9 6.9 0 0 0-1.125-1.81A3.7 3.7 0 0 0 12.195 2 4.08 4.08 0 0 0 8 6.196a3.7 3.7 0 0 0 1.239 2.679q.072.06.146.125H5a2 2 0 0 0-2 2v4a2 2 0 0 0 2 2v8a2 2 0 0 0 2 2h7.5a.5.5 0 0 0 .5-.5V15H5v-4h10v4h2v-4h10v4H17v11.5a.5.5 0 0 0 .5.5H25a2 2 0 0 0 2-2v-8a2 2 0 0 0 2-2v-4a2 2 0 0 0-2-2M10.564 7.375A1.7 1.7 0 0 1 10 6.125 2.076 2.076 0 0 1 12.074 4h.061a1.71 1.71 0 0 1 1.25.563c1.049 1.185 1.419 3.15 1.549 4.365-1.22-.13-3.184-.5-4.37-1.553m10.875 0c-1.186 1.05-3.155 1.42-4.375 1.55.148-1.314.561-3.237 1.561-4.361A1.7 1.7 0 0 1 19.875 4h.061A2.077 2.077 0 0 1 22 6.135a1.7 1.7 0 0 1-.564 1.24z"})})};b.forwardRef(G_);const Y_=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M16 3a13 13 0 1 0 13 13A13.013 13.013 0 0 0 16 3m9.796 8h-4.428a17.8 17.8 0 0 0-2.533-5.625A11.05 11.05 0 0 1 25.796 11M16 5.014c1.5 1.625 2.625 3.693 3.296 5.986h-6.592C13.375 8.707 14.5 6.641 16 5.014M12 16c0-1.005.084-2.009.25-3h7.5a18.2 18.2 0 0 1 0 6h-7.5a18 18 0 0 1-.25-3m.704 5h6.592c-.671 2.293-1.796 4.359-3.296 5.986-1.5-1.627-2.625-3.693-3.296-5.986m6.131 5.625A17.8 17.8 0 0 0 21.367 21h4.43a11.05 11.05 0 0 1-6.962 5.625M21.776 19a20.2 20.2 0 0 0 0-6h4.808a11 11 0 0 1 0 6z"})})};b.forwardRef(Y_);const X_=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{fillRule:"evenodd",d:"M13.29 28.226 6.765 24.46a2.822 2.822 0 1 1-2.708-4.693v-7.532a2.824 2.824 0 1 1 2.708-4.693l6.525-3.767a2.824 2.824 0 1 1 5.42 0l6.524 3.766a2.822 2.822 0 1 1 2.71 4.693v7.533a2.824 2.824 0 1 1-2.71 4.694l-6.524 3.766A2.825 2.825 0 0 1 16 31.84a2.822 2.822 0 0 1-2.71-3.614M16 5.806q.413-.002.791-.113l8.531 14.776a2.8 2.8 0 0 0-.791 1.37H7.467a2.8 2.8 0 0 0-.79-1.369L15.21 5.693q.377.11.791.112M7.468 23.178l-.033.12 6.526 3.767A2.81 2.81 0 0 1 16 26.195c.802 0 1.526.334 2.04.871l6.523-3.766-.032-.121zM5.397 12.233a2.824 2.824 0 0 0 2.038-3.532l6.526-3.767q.043.045.088.088L5.517 19.8l-.12-.032zM26.482 19.8q.06-.018.121-.033v-7.532a2.824 2.824 0 0 1-2.04-3.534L18.04 4.934q-.045.045-.089.088z",clipRule:"evenodd"})})};b.forwardRef(X_);const Z_=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M27 7v7.5a.5.5 0 0 1-.5.5H17V5.5a.5.5 0 0 1 .5-.5H25a2 2 0 0 1 2 2M14.5 5H7a2 2 0 0 0-2 2v7.5a.5.5 0 0 0 .5.5H15V5.5a.5.5 0 0 0-.5-.5m12 12H17v9.5a.5.5 0 0 0 .5.5H25a2 2 0 0 0 2-2v-7.5a.5.5 0 0 0-.5-.5M5 17.5V25a2 2 0 0 0 2 2h7.5a.5.5 0 0 0 .5-.5V17H5.5a.5.5 0 0 0-.5.5"})})};b.forwardRef(Z_);const Q_=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M10.5 6.5v5h-7A.5.5 0 0 1 3 11V8a2 2 0 0 1 2-2h5a.5.5 0 0 1 .5.5m2 19a.5.5 0 0 0 .5.5h6a.5.5 0 0 0 .5-.5v-5h-7zM3 21v3a2 2 0 0 0 2 2h5a.5.5 0 0 0 .5-.5v-5h-7a.5.5 0 0 0-.5.5m0-7v4a.5.5 0 0 0 .5.5h7v-5h-7a.5.5 0 0 0-.5.5m16-8h-6a.5.5 0 0 0-.5.5v5h7v-5A.5.5 0 0 0 19 6m9.5 7.5h-7v5h7a.5.5 0 0 0 .5-.5v-4a.5.5 0 0 0-.5-.5m-16 5h7v-5h-7zM27 6h-5a.5.5 0 0 0-.5.5v5h7a.5.5 0 0 0 .5-.5V8a2 2 0 0 0-2-2m1.5 14.5h-7v5a.5.5 0 0 0 .5.5h5a2 2 0 0 0 2-2v-3a.5.5 0 0 0-.5-.5"})})};b.forwardRef(Q_);const J_=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M28.791 17.633a3.04 3.04 0 0 0-2.326-.597C28.813 14.666 30 12.31 30 10c0-3.309-2.661-6-5.933-6A5.95 5.95 0 0 0 19.5 6.094 5.95 5.95 0 0 0 14.932 4C11.663 4 9 6.691 9 10c0 1.375.405 2.711 1.258 4.125a4 4 0 0 0-1.844 1.05L5.586 18H2a2 2 0 0 0-2 2v5a2 2 0 0 0 2 2h13q.123 0 .242-.03l8-2a1 1 0 0 0 .15-.05l4.858-2.067.055-.025a3.074 3.074 0 0 0 .491-5.195zm-1.362 3.393-4.75 2.023L14.875 25H7v-5.586l2.829-2.828A1.98 1.98 0 0 1 11.242 16H17.5a1.5 1.5 0 0 1 0 3H14a1 1 0 0 0 0 2h4q.113 0 .224-.025l8.375-1.926.038-.01a1.075 1.075 0 0 1 .788 1.987z"})})};b.forwardRef(J_);const eL=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M28 10.5h-5.475l.951-5.231a1.5 1.5 0 1 0-2.952-.538L19.475 10.5h-4.95l.951-5.231a1.5 1.5 0 1 0-2.952-.538L11.475 10.5H6a1.5 1.5 0 0 0 0 3h4.93l-.909 5H4a1.5 1.5 0 0 0 0 3h5.475l-.951 5.231a1.5 1.5 0 0 0 1.207 1.75q.134.022.269.019a1.5 1.5 0 0 0 1.475-1.233l1.05-5.767h4.95l-.951 5.231a1.5 1.5 0 1 0 2.952.543l1.049-5.774H26a1.5 1.5 0 1 0 0-3h-4.93l.909-5H28a1.5 1.5 0 1 0 0-3m-9.979 8H13.07l.909-5h4.951z"})})};b.forwardRef(eL);const tL=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M31.5 22.5a5 5 0 0 1-5 5 4.94 4.94 0 0 1-3.571-1.45 1.5 1.5 0 0 1 2.142-2.1 1.94 1.94 0 0 0 1.429.55 2 2 0 0 0 0-4 1.94 1.94 0 0 0-1.429.55 1.5 1.5 0 0 1-2.551-1.3l1-6A1.5 1.5 0 0 1 25 12.5h5a1.5 1.5 0 1 1 0 3h-3.729l-.338 2.029q.283-.03.567-.029a5 5 0 0 1 5 5M18 5.5A1.5 1.5 0 0 0 16.5 7v6h-10V7a1.5 1.5 0 0 0-3 0v15a1.5 1.5 0 0 0 3 0v-6h10v6a1.5 1.5 0 1 0 3 0V7A1.5 1.5 0 0 0 18 5.5"})})};b.forwardRef(tL);const nL=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M32 22a1.5 1.5 0 0 1-1.5 1.5V26a1.5 1.5 0 1 1-3 0v-2.5H23a1.5 1.5 0 0 1-1.422-1.974l3-9a1.5 1.5 0 0 1 2.845.948L25.08 20.5H27.5V18a1.5 1.5 0 1 1 3 0v2.5A1.5 1.5 0 0 1 32 22M18 5.5A1.5 1.5 0 0 0 16.5 7v6h-10V7a1.5 1.5 0 0 0-3 0v15a1.5 1.5 0 0 0 3 0v-6h10v6a1.5 1.5 0 1 0 3 0V7A1.5 1.5 0 0 0 18 5.5"})})};b.forwardRef(nL);const rL=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M29.5 14v12a1.5 1.5 0 1 1-3 0v-9.198l-.668.448a1.503 1.503 0 0 1-1.665-2.5l3-2A1.5 1.5 0 0 1 29.5 14M18 5.5A1.5 1.5 0 0 0 16.5 7v6h-10V7a1.5 1.5 0 0 0-3 0v15a1.5 1.5 0 0 0 3 0v-6h10v6a1.5 1.5 0 1 0 3 0V7A1.5 1.5 0 0 0 18 5.5"})})};b.forwardRef(rL);const iL=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"m27.133 17.541 1.655-2.772a1.5 1.5 0 1 0-2.576-1.538l-4.03 6.75q-.018.029-.032.059a5 5 0 1 0 4.983-2.5zM26.5 24.5a2 2 0 1 1 0-4 2 2 0 0 1 0 4M19.5 7v15a1.5 1.5 0 1 1-3 0v-6h-10v6a1.5 1.5 0 0 1-3 0V7a1.5 1.5 0 0 1 3 0v6h10V7a1.5 1.5 0 1 1 3 0"})})};b.forwardRef(iL);const oL=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M31.5 22.5a5 5 0 0 1-8.571 3.5 1.5 1.5 0 1 1 2.142-2.099A2 2 0 1 0 26.5 20.5a1.5 1.5 0 0 1-1.229-2.36l1.854-2.64H24a1.5 1.5 0 1 1 0-3h6a1.5 1.5 0 0 1 1.229 2.36l-2.293 3.275A5 5 0 0 1 31.5 22.5M18 5.5A1.5 1.5 0 0 0 16.5 7v6h-10V7a1.5 1.5 0 0 0-3 0v15a1.5 1.5 0 0 0 3 0v-6h10v6a1.5 1.5 0 1 0 3 0V7A1.5 1.5 0 0 0 18 5.5"})})};b.forwardRef(oL);const sL=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M19.5 7v15a1.5 1.5 0 1 1-3 0v-6h-10v6a1.5 1.5 0 0 1-3 0V7a1.5 1.5 0 0 1 3 0v6h10V7a1.5 1.5 0 1 1 3 0M30 24.5h-3l3.593-4.791a4.499 4.499 0 1 0-7.837-4.209 1.5 1.5 0 1 0 2.829 1q.076-.218.216-.402a1.5 1.5 0 1 1 2.394 1.807L22.8 25.1a1.5 1.5 0 0 0 1.2 2.4h6a1.5 1.5 0 1 0 0-3"})})};b.forwardRef(sL);const aL=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M29 17v7a3 3 0 0 1-3 3h-2a3 3 0 0 1-3-3v-5a3 3 0 0 1 3-3h2.956A10.964 10.964 0 0 0 16.081 6H16A11 11 0 0 0 5.045 16H8a3 3 0 0 1 3 3v5a3 3 0 0 1-3 3H6a3 3 0 0 1-3-3v-7a13.014 13.014 0 0 1 22.236-9.167A12.93 12.93 0 0 1 29 17"})})};b.forwardRef(aL);const lL=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M30 11.75c0 8.75-12.974 15.833-13.526 16.125a1 1 0 0 1-.948 0C14.974 27.582 2 20.5 2 11.75A7.76 7.76 0 0 1 9.75 4c2.581 0 4.841 1.11 6.25 2.986C17.409 5.11 19.669 4 22.25 4A7.76 7.76 0 0 1 30 11.75"})})};b.forwardRef(lL);const cL=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M28 14.444V26a2 2 0 0 1-2 2h-5a2 2 0 0 1-2-2v-5a1 1 0 0 0-1-1h-4a1 1 0 0 0-1 1v5a2 2 0 0 1-2 2H6a2 2 0 0 1-2-2V14.444a2 2 0 0 1 .646-1.473l10-9.435.014-.013a2 2 0 0 1 2.705.013l10 9.435A2 2 0 0 1 28 14.444"})})};b.forwardRef(cL);const uL=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M27 5H5a2 2 0 0 0-2 2v18a2 2 0 0 0 2 2h22a2 2 0 0 0 2-2V7a2 2 0 0 0-2-2m-7.5 6a1.5 1.5 0 1 1 0 3 1.5 1.5 0 0 1 0-3M5 25v-3.5l6.5-6.5 10 10zm22 0h-2.671l-4.5-4.5 2.5-2.5L27 22.672z"})})};b.forwardRef(uL);const hL=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M27 5H9a2 2 0 0 0-2 2v2H5a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h18a2 2 0 0 0 2-2v-2h2a2 2 0 0 0 2-2V7a2 2 0 0 0-2-2m-5.5 4a1.5 1.5 0 1 1 0 3 1.5 1.5 0 0 1 0-3M23 25H5V11h2v10a2 2 0 0 0 2 2h14zm4-4H9v-4.5l4.5-4.5 6.208 6.208a1 1 0 0 0 1.413 0L24.33 15 27 17.672z"})})};b.forwardRef(hL);const fL=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M28.5 16a1.5 1.5 0 0 1-1.5 1.5H15a1.5 1.5 0 0 1 0-3h12a1.5 1.5 0 0 1 1.5 1.5M15 9.5h12a1.5 1.5 0 0 0 0-3H15a1.5 1.5 0 0 0 0 3m12 13H5a1.5 1.5 0 1 0 0 3h22a1.5 1.5 0 0 0 0-3m-18-4a1.5 1.5 0 0 0 1.061-2.561L6.125 12l3.936-3.94a1.503 1.503 0 1 0-2.125-2.125l-5 5a1.5 1.5 0 0 0 0 2.125l5 5A1.5 1.5 0 0 0 9 18.5"})})};b.forwardRef(fL);const dL=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M28.5 16a1.5 1.5 0 0 1-1.5 1.5H15a1.5 1.5 0 0 1 0-3h12a1.5 1.5 0 0 1 1.5 1.5M15 9.5h12a1.5 1.5 0 0 0 0-3H15a1.5 1.5 0 0 0 0 3m12 13H5a1.5 1.5 0 0 0 0 3h22a1.5 1.5 0 1 0 0-3M3.939 18.06a1.5 1.5 0 0 0 2.125 0l5-5a1.5 1.5 0 0 0 0-2.125l-5-5a1.503 1.503 0 0 0-2.125 2.125L7.875 12l-3.936 3.939a1.5 1.5 0 0 0 0 2.122"})})};b.forwardRef(dL);const gL=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M16 3a13 13 0 1 0 13 13A13.013 13.013 0 0 0 16 3m-.5 6a1.5 1.5 0 1 1 0 3 1.5 1.5 0 0 1 0-3M17 23a2 2 0 0 1-2-2v-5a1 1 0 0 1 0-2 2 2 0 0 1 2 2v5a1 1 0 0 1 0 2"})})},mL=b.forwardRef(gL),pL=mL,vL=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M25.5 7A1.5 1.5 0 0 1 24 8.5h-3.919l-5 15H18a1.5 1.5 0 1 1 0 3H8a1.5 1.5 0 1 1 0-3h3.919l5-15H14a1.5 1.5 0 0 1 0-3h10A1.5 1.5 0 0 1 25.5 7"})})},bL=b.forwardRef(vL),wL=bL,xL=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M20 2a10.01 10.01 0 0 0-9.511 13.098l-7.196 7.195A1 1 0 0 0 3 23v5a1 1 0 0 0 1 1h5a1 1 0 0 0 1-1v-2h2a1 1 0 0 0 1-1v-2h2a1 1 0 0 0 .707-.293l1.195-1.196A10 10 0 1 0 20 2m2.5 9.5a2 2 0 1 1 0-4 2 2 0 0 1 0 4"})})};b.forwardRef(xL);const yL=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M27 5H5a2 2 0 0 0-2 2v18a2 2 0 0 0 2 2h22a2 2 0 0 0 2-2V7a2 2 0 0 0-2-2M5 7h22v5H5zm22 18H14V14h13z"})})};b.forwardRef(yL);const CL=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M22 29a1 1 0 0 1-1 1H11a1 1 0 1 1 0-2h10a1 1 0 0 1 1 1m5-16a10.94 10.94 0 0 1-4.205 8.651A2.03 2.03 0 0 0 22 23.25V24a2 2 0 0 1-2 2h-8a2 2 0 0 1-2-2v-.75a2 2 0 0 0-.779-1.582A10.95 10.95 0 0 1 5 13.06C4.967 7.104 9.782 2.143 15.735 2A11 11 0 0 1 27 13m-4.014-1.168a7.2 7.2 0 0 0-5.82-5.818 1 1 0 1 0-.332 1.972c2.071.349 3.829 2.106 4.18 4.182a1 1 0 0 0 1.972-.335"})})};b.forwardRef(CL);const $L=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"m21.731 14.683-14 15a1 1 0 0 1-1.711-.875l1.832-9.167L.65 16.936a1 1 0 0 1-.375-1.625l14-15a1 1 0 0 1 1.71.875l-1.837 9.177 7.204 2.7a1 1 0 0 1 .375 1.62z"})})};b.forwardRef($L);const SL=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M17.046 23.441a1.5 1.5 0 0 1 0 2.125l-.742.743a7.502 7.502 0 1 1-10.61-10.61l3.015-3.014A7.5 7.5 0 0 1 19 12.375a1.506 1.506 0 0 1-2 2.25 4.5 4.5 0 0 0-6.171.184l-3.013 3.01a4.5 4.5 0 0 0 6.365 6.365l.743-.743a1.5 1.5 0 0 1 2.122 0m9.26-17.75a7.51 7.51 0 0 0-10.61 0l-.742.743a1.503 1.503 0 1 0 2.125 2.125l.742-.743a4.5 4.5 0 0 1 6.365 6.365l-3.014 3.015a4.5 4.5 0 0 1-6.172.179 1.506 1.506 0 1 0-2 2.25 7.5 7.5 0 0 0 10.288-.304l3.014-3.014a7.51 7.51 0 0 0 .004-10.613z"})})},AL=b.forwardRef(SL),RL=AL,kL=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M28.5 16a1.5 1.5 0 0 1-1.5 1.5H5a1.5 1.5 0 1 1 0-3h22a1.5 1.5 0 0 1 1.5 1.5M5 9.5h22a1.5 1.5 0 0 0 0-3H5a1.5 1.5 0 0 0 0 3m22 13H5a1.5 1.5 0 1 0 0 3h22a1.5 1.5 0 1 0 0-3"})})};b.forwardRef(kL);const TL=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M3.5 8A1.5 1.5 0 0 1 5 6.5h22a1.5 1.5 0 0 1 0 3H5A1.5 1.5 0 0 1 3.5 8M5 17.5h22a1.5 1.5 0 1 0 0-3H5a1.5 1.5 0 1 0 0 3m13 5H5a1.5 1.5 0 1 0 0 3h13a1.5 1.5 0 1 0 0-3m11 0h-1.5V21a1.5 1.5 0 1 0-3 0v1.5H23a1.5 1.5 0 1 0 0 3h1.5V27a1.5 1.5 0 1 0 3 0v-1.5H29a1.5 1.5 0 1 0 0-3"})})};b.forwardRef(TL);const ML=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:16,height:16,viewBox:"0 0 256 256",fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M28 64a12 12 0 0 1 12-12h176a12 12 0 0 1 0 24H40a12 12 0 0 1-12-12m12 76h64a12 12 0 0 0 0-24H40a12 12 0 0 0 0 24m80 40H40a12 12 0 0 0 0 24h80a12 12 0 0 0 0-24m120.49 20.49a12 12 0 0 1-17 0l-18.08-18.08a44 44 0 1 1 17-17l18.08 18.07a12 12 0 0 1 0 17.01M184 164a20 20 0 1 0-20-20 20 20 0 0 0 20 20"})})};b.forwardRef(ML);const EL=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M17.5 4v4a1.5 1.5 0 1 1-3 0V4a1.5 1.5 0 1 1 3 0m4.156 7.844a1.5 1.5 0 0 0 1.062-.44l2.828-2.829a1.503 1.503 0 1 0-2.125-2.125l-2.825 2.833a1.5 1.5 0 0 0 1.06 2.56M28 14.5h-4a1.5 1.5 0 1 0 0 3h4a1.5 1.5 0 1 0 0-3m-5.282 6.096a1.501 1.501 0 0 0-2.451 1.638c.075.182.186.348.326.487l2.828 2.829a1.503 1.503 0 0 0 2.125-2.125zM16 22.5a1.5 1.5 0 0 0-1.5 1.5v4a1.5 1.5 0 1 0 3 0v-4a1.5 1.5 0 0 0-1.5-1.5m-6.717-1.904-2.83 2.829A1.503 1.503 0 0 0 8.58 25.55l2.829-2.829a1.503 1.503 0 0 0-2.125-2.125M9.5 16A1.5 1.5 0 0 0 8 14.5H4a1.5 1.5 0 1 0 0 3h4A1.5 1.5 0 0 0 9.5 16m-.925-9.546A1.503 1.503 0 0 0 6.45 8.579l2.833 2.825a1.503 1.503 0 0 0 2.125-2.125z"})})},OL=b.forwardRef(EL),u3=OL,DL=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M26 10h-4V7a6 6 0 1 0-12 0v3H6a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h20a2 2 0 0 0 2-2V12a2 2 0 0 0-2-2M16 20.5a1.5 1.5 0 1 1 0-3 1.5 1.5 0 0 1 0 3M20 10h-8V7a4 4 0 1 1 8 0z"})})};b.forwardRef(DL);const IL=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M31 19a1 1 0 0 1-1 1h-2v2a1 1 0 0 1-2 0v-2h-2a1 1 0 0 1 0-2h2v-2a1 1 0 1 1 2 0v2h2a1 1 0 0 1 1 1M7 9h2v2a1 1 0 1 0 2 0V9h2a1 1 0 0 0 0-2h-2V5a1 1 0 0 0-2 0v2H7a1 1 0 0 0 0 2m16 15h-1v-1a1 1 0 0 0-2 0v1h-1a1 1 0 0 0 0 2h1v1a1 1 0 1 0 2 0v-1h1a1 1 0 0 0 0-2m4.414-14L10 27.414a2 2 0 0 1-2.828 0l-2.587-2.585a2 2 0 0 1 0-2.829L22 4.586a2 2 0 0 1 2.829 0l2.585 2.585a2 2 0 0 1 0 2.829M26 8.586 23.414 6l-4 4L22 12.586z"})})};b.forwardRef(IL);const _L=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M28 6H4a1 1 0 0 0-1 1v17a2 2 0 0 0 2 2h22a2 2 0 0 0 2-2V7a1 1 0 0 0-1-1M12.339 16 5 22.726V9.274zm1.48 1.356 1.5 1.381a1 1 0 0 0 1.352 0l1.5-1.38L25.421 24H6.571zM19.66 16 27 9.273v13.455z"})})};b.forwardRef(_L);const LL=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{fillRule:"evenodd",d:"M11 7q0 .432-.088.838L16 10.382l5.088-2.544a4 4 0 1 1 .895 1.789L18.236 11.5l3.747 1.873a4 4 0 1 1 0 5.253L18.236 20.5l3.747 1.874a4 4 0 1 1-.895 1.788L16 21.618l-5.088 2.544Q11 24.567 11 25a4 4 0 1 1-.983-2.626l3.747-1.874-3.747-1.873a4 4 0 1 1 0-5.253l3.747-1.874-3.747-1.874A4 4 0 1 1 11 7M9 7a2 2 0 1 1-4 0 2 2 0 0 1 4 0m2.236 8h9.528L16 12.618zM9 25a2 2 0 1 1-4 0 2 2 0 0 1 4 0m-2-7a2 2 0 1 0 0-4 2 2 0 0 0 0 4M27 7a2 2 0 1 1-4 0 2 2 0 0 1 4 0m-2 20a2 2 0 1 0 0-4 2 2 0 0 0 0 4m2-11a2 2 0 1 1-4 0 2 2 0 0 1 4 0m-11 3.382L20.764 17h-9.528z",clipRule:"evenodd"})})};b.forwardRef(LL);const BL=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{fillRule:"evenodd",d:"M14.8 8.254a4 4 0 1 0-1.082 1.682l7.483 4.81a4 4 0 0 0-.075.254H10.874A4.002 4.002 0 0 0 3 16a4 4 0 0 0 7.874 1h10.252q.033.128.075.254l-7.484 4.81a4 4 0 1 0 1.082 1.682l7.484-4.81a4 4 0 1 0 0-5.871zM11 9a2 2 0 1 0 0-4 2 2 0 0 0 0 4m0 18a2 2 0 1 0 0-4 2 2 0 0 0 0 4M9 16a2 2 0 1 1-4 0 2 2 0 0 1 4 0m16 2a2 2 0 1 0 0-4 2 2 0 0 0 0 4",clipRule:"evenodd"})})};b.forwardRef(BL);const NL=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{fillRule:"evenodd",d:"M18.842 3.227a1 1 0 1 0-.445 1.95l1.747.399L9.6 12.959a4 4 0 1 0 0 6.081l10.546 7.385-1.748.399a1 1 0 1 0 .445 1.95l3.945-.9a1 1 0 0 0 .77-1.1l-.503-4.014a1 1 0 0 0-1.985.248l.223 1.779-10.545-7.384a4 4 0 0 0 .127-.403h14.712l-1.293 1.293a1 1 0 1 0 1.414 1.414l3-3a1 1 0 0 0 0-1.414l-3-3a1 1 0 0 0-1.414 1.414L25.586 15H10.874a4 4 0 0 0-.127-.403l10.544-7.383-.222 1.778a1 1 0 0 0 1.984.249l.503-4.015a1 1 0 0 0-.77-1.099zM9 16a2 2 0 1 1-4 0 2 2 0 0 1 4 0",clipRule:"evenodd"})})};b.forwardRef(NL);const jL=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M27 6H5a2 2 0 0 0-2 2v20a1.98 1.98 0 0 0 1.156 1.813 1.986 1.986 0 0 0 2.141-.299L10.312 26H27a2 2 0 0 0 2-2V8a2 2 0 0 0-2-2M10.5 17.5a1.5 1.5 0 1 1 0-3 1.5 1.5 0 0 1 0 3m5.5 0a1.5 1.5 0 1 1 0-3 1.5 1.5 0 0 1 0 3m5.5 0a1.5 1.5 0 1 1 0-3 1.5 1.5 0 0 1 0 3"})})};b.forwardRef(jL);const FL=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M10 16V8a6 6 0 1 1 12 0v8a6 6 0 1 1-12 0m16 0a1 1 0 0 0-2 0 8 8 0 0 1-16 0 1 1 0 1 0-2 0 10.014 10.014 0 0 0 9 9.95V29a1 1 0 0 0 2 0v-3.05A10.014 10.014 0 0 0 26 16"})})};b.forwardRef(FL);const VL=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M28.5 16a1.5 1.5 0 0 1-1.5 1.5H5a1.5 1.5 0 1 1 0-3h22a1.5 1.5 0 0 1 1.5 1.5"})})},HL=b.forwardRef(VL),PL=HL,WL=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M16 3a13 13 0 1 0 13 13A13.013 13.013 0 0 0 16 3m5 14H11a1 1 0 0 1 0-2h10a1 1 0 0 1 0 2"})})};b.forwardRef(WL);const zL=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M26 5H6a3 3 0 0 0-3 3v14a3 3 0 0 0 3 3h20a3 3 0 0 0 3-3V8a3 3 0 0 0-3-3M20 27h-8a1 1 0 0 0 0 2h8a1 1 0 0 0 0-2"})})};b.forwardRef(zL);const UL=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M29.443 18.776a13.1 13.1 0 0 1-4.626 6.614A13 13 0 0 1 4 15a12.9 12.9 0 0 1 2.61-7.815 13.1 13.1 0 0 1 6.614-4.625 1 1 0 0 1 1.25 1.25 11.01 11.01 0 0 0 13.725 13.725 1 1 0 0 1 1.25 1.25z"})})};b.forwardRef(UL);const qL=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M18 16a2 2 0 1 1-4 0 2 2 0 0 1 4 0M7.5 14a2 2 0 1 0 0 4 2 2 0 0 0 0-4m17 0a2 2 0 1 0 0 4 2 2 0 0 0 0-4"})})},KL=b.forwardRef(qL),GL=KL,YL=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M10.939 8.061a1.5 1.5 0 0 1 0-2.125l4-4a1.5 1.5 0 0 1 2.125 0l4 4a1.503 1.503 0 1 1-2.125 2.125L17.5 6.625V12a1.5 1.5 0 1 1-3 0V6.625l-1.439 1.436a1.5 1.5 0 0 1-2.122 0m8 15.875L17.5 25.375V20a1.5 1.5 0 1 0-3 0v5.375l-1.439-1.44a1.504 1.504 0 0 0-2.125 2.125l4 4a1.5 1.5 0 0 0 2.125 0l4-4a1.502 1.502 0 1 0-2.125-2.125zm11.125-9-4-4a1.503 1.503 0 0 0-2.125 2.125l1.436 1.439H20a1.5 1.5 0 0 0 0 3h5.375l-1.44 1.439a1.503 1.503 0 0 0 2.125 2.125l4-4a1.5 1.5 0 0 0 .001-2.125zM6.625 17.5H12a1.5 1.5 0 1 0 0-3H6.625l1.44-1.439a1.503 1.503 0 1 0-2.125-2.125l-4 4a1.5 1.5 0 0 0 0 2.125l4 4a1.503 1.503 0 0 0 2.125-2.125z"})})};b.forwardRef(YL);const XL=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M26.615 3.214a.99.99 0 0 0-.857-.183l-16 4a1 1 0 0 0-.758.97v13.762a4.5 4.5 0 1 0 2 3.737V13.781l14-3.5v7.482a4.5 4.5 0 1 0 2 3.737V4a1 1 0 0 0-.385-.786"})})};b.forwardRef(XL);const ZL=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M28.5 16a1.5 1.5 0 0 1-1.5 1.5H14.5a1.5 1.5 0 1 1 0-3H27a1.5 1.5 0 0 1 1.5 1.5m-14-6.5H27a1.5 1.5 0 0 0 0-3H14.5a1.5 1.5 0 0 0 0 3m12.5 13H14.5a1.5 1.5 0 1 0 0 3H27a1.5 1.5 0 1 0 0-3M5.5 7.414V13a1.5 1.5 0 0 0 3 0V5a1.5 1.5 0 0 0-2.17-1.341l-2 1a1.5 1.5 0 0 0 1.17 2.75zm4.966 12.107a3.46 3.46 0 0 0-1.4-2.329 3.61 3.61 0 0 0-4.954.683 3.5 3.5 0 0 0-.52.942 1.5 1.5 0 0 0 2.818 1.027.5.5 0 0 1 .072-.125.6.6 0 0 1 .813-.103.48.48 0 0 1 .201.325.45.45 0 0 1-.096.347l-.016.02-3.585 4.794A1.5 1.5 0 0 0 5 27.5h4a1.5 1.5 0 1 0 0-3H8l1.785-2.389a3.43 3.43 0 0 0 .681-2.59"})})},QL=b.forwardRef(ZL),JL=QL,eB=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{fillRule:"evenodd",d:"M17.2 8.254a4 4 0 1 1 1.082 1.682l-7.482 4.81q.04.125.074.254h10.252A4.002 4.002 0 0 1 29 16a4 4 0 0 1-7.874 1H10.874q-.033.128-.075.254l7.484 4.81a4 4 0 1 1-1.082 1.682l-7.484-4.81a4 4 0 1 1 0-5.871zM21 9a2 2 0 1 1 0-4 2 2 0 0 1 0 4m0 18a2 2 0 1 1 0-4 2 2 0 0 1 0 4m2-11a2 2 0 1 0 4 0 2 2 0 0 0-4 0M7 18a2 2 0 1 1 0-4 2 2 0 0 1 0 4",clipRule:"evenodd"})})};b.forwardRef(eB);const tB=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{fillRule:"evenodd",d:"M10.874 17A4.002 4.002 0 0 1 3 16a4 4 0 0 1 7.874-1h10.252A4.002 4.002 0 0 1 29 16a4 4 0 0 1-7.874 1zM7 18a2 2 0 1 0 0-4 2 2 0 0 0 0 4m18 0a2 2 0 1 0 0-4 2 2 0 0 0 0 4",clipRule:"evenodd"})})};b.forwardRef(tB);const nB=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{fillRule:"evenodd",d:"M28.924 16.384c-.05.12-.124.231-.217.324l-4 4a1 1 0 0 1-1.632-.324 1 1 0 0 1 .217-1.09L25.585 17H10.875A4.002 4.002 0 0 1 3 16a4 4 0 0 1 7.874-1h14.712l-2.294-2.293a1 1 0 0 1 1.415-1.415l4 4a1 1 0 0 1 .217 1.09M7 18a2 2 0 1 0 0-4 2 2 0 0 0 0 4",clipRule:"evenodd"})})};b.forwardRef(nB);const rB=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M29 4a1 1 0 0 0-1-1c-5.51 0-11.164 6.214-14.304 10.329A7.5 7.5 0 0 0 4 20.5c0 3.86-2.443 5.591-2.559 5.671A1 1 0 0 0 2 28h9.5a7.5 7.5 0 0 0 7.171-9.696C22.788 15.164 29 9.51 29 4M15.553 14.194a48 48 0 0 1 1.26-1.569 9.5 9.5 0 0 1 2.562 2.561q-.738.618-1.569 1.262a7.6 7.6 0 0 0-2.254-2.254m5.337-.335a11.6 11.6 0 0 0-2.75-2.75c3.973-4.316 6.969-5.625 8.738-5.989-.357 1.77-1.672 4.766-5.988 8.739"})})};b.forwardRef(rB);const iB=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M31 13v6.25a2.01 2.01 0 0 1-1.45 1.922L17 24.75V29a1 1 0 0 1-2 0v-4.25a2.01 2.01 0 0 1 1.45-1.922L29 19.25V13h-2v3a2 2 0 0 1-2 2H6a2 2 0 0 1-2-2v-3H2a1 1 0 0 1 0-2h2V8a2 2 0 0 1 2-2h19a2 2 0 0 1 2 2v3h2a2 2 0 0 1 2 2"})})};b.forwardRef(iB);const oB=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M25.096 6.736A12.9 12.9 0 0 0 16 3h-.134A13 13 0 0 0 3 16c0 5.375 3.323 9.883 8.67 11.771A4 4 0 0 0 17 24a2 2 0 0 1 2-2h5.776a3.976 3.976 0 0 0 3.9-3.11c.224-.984.332-1.99.324-3a12.9 12.9 0 0 0-3.904-9.154M10.5 21a1.5 1.5 0 1 1 0-3 1.5 1.5 0 0 1 0 3m0-7a1.5 1.5 0 1 1 0-3 1.5 1.5 0 0 1 0 3m5.5-3a1.5 1.5 0 1 1 0-3 1.5 1.5 0 0 1 0 3m5.5 3a1.5 1.5 0 1 1 0-3 1.5 1.5 0 0 1 0 3"})})};b.forwardRef(oB);const sB=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M28.925 5.543v.018L21.65 29.554A1.985 1.985 0 0 1 19.728 31a1.98 1.98 0 0 1-1.803-1.144l-4.464-9.423a.5.5 0 0 1 .099-.568l7.158-7.159a1 1 0 0 0-1.414-1.413l-7.169 7.157a.5.5 0 0 1-.567.099l-9.376-4.441A2.05 2.05 0 0 1 1 12.17a1.99 1.99 0 0 1 1.446-1.815L26.44 3.08h.018a2 2 0 0 1 2.468 2.463"})})};b.forwardRef(sB);const aB=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"m26.56 17.061-10.257 10.25a7.501 7.501 0 0 1-10.607-10.61l12.27-12.236a5 5 0 0 1 7.07 7.074l-.021.02L13.04 23.086a1.503 1.503 0 0 1-2.121-.041 1.5 1.5 0 0 1 .041-2.121L22.924 9.409a2 2 0 1 0-2.838-2.82L7.816 18.82a4.5 4.5 0 1 0 6.366 6.364l10.258-10.25a1.503 1.503 0 0 1 2.125 2.125z"})})};b.forwardRef(aB);const lB=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M3.5 8A1.5 1.5 0 0 1 5 6.5h22a1.5 1.5 0 0 1 0 3H5A1.5 1.5 0 0 1 3.5 8M5 14.5h16a1.5 1.5 0 1 0 0-3H5a1.5 1.5 0 1 0 0 3m22 2H5a1.5 1.5 0 1 0 0 3h22a1.5 1.5 0 1 0 0-3m-6 5H5a1.5 1.5 0 1 0 0 3h16a1.5 1.5 0 1 0 0-3"})})};b.forwardRef(lB);const cB=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"m28.414 9.171-5.585-5.586a2 2 0 0 0-2.829 0L4.586 19A1.98 1.98 0 0 0 4 20.414V26a2 2 0 0 0 2 2h5.586A1.98 1.98 0 0 0 13 27.414L28.414 12a2 2 0 0 0 0-2.829M24 13.585 18.414 8l3-3L27 10.585z"})})},uB=b.forwardRef(cB),hB=uB,fB=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M28.985 21.885A7.03 7.03 0 0 1 22 28c-9.925 0-18-8.075-18-18a7.03 7.03 0 0 1 6.115-6.985 2 2 0 0 1 2.078 1.19l2.64 5.894v.015a2 2 0 0 1-.16 1.886 1 1 0 0 1-.07.096L12 15.181c.936 1.903 2.926 3.875 4.854 4.814l3.042-2.589q.045-.037.094-.07a2 2 0 0 1 1.896-.175l.017.008 5.888 2.639a2 2 0 0 1 1.194 2.077"})})};b.forwardRef(fB);const dB=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"m29.416 13-6.683 6.706c.57 1.584.806 4.236-1.65 7.5a2 2 0 0 1-1.458.794h-.141a2 2 0 0 1-1.415-.586l-6.033-6.04-5.328 5.333a1 1 0 1 1-1.415-1.415l5.332-5.328-6.037-6.038a2 2 0 0 1 .162-2.972c3.178-2.564 6.219-2.06 7.55-1.643L19 2.587a2 2 0 0 1 2.829 0l7.586 7.585A2 2 0 0 1 29.416 13"})})};b.forwardRef(dB);const gB=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M16 2A11.013 11.013 0 0 0 5 13c0 9.413 10 16.521 10.426 16.819a1 1 0 0 0 1.148 0C17 29.52 27 22.413 27 13A11.01 11.01 0 0 0 16 2m0 7a4 4 0 1 1 0 8 4 4 0 0 1 0-8"})})};b.forwardRef(gB);const mB=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M30 17v4a1 1 0 0 1-1.196.98L19.5 20.125v2.966l2.207 2.206A1 1 0 0 1 22 26v3a1 1 0 0 1-1.375.929L16 28.078l-4.625 1.85A1 1 0 0 1 10 29v-3a1 1 0 0 1 .293-.707l2.207-2.207v-2.961L3.196 21.98A1 1 0 0 1 2 21v-4a1 1 0 0 1 .553-.895l9.947-4.972V5.5a3.5 3.5 0 1 1 7 0v5.633l9.948 4.972A1 1 0 0 1 30 17"})})};b.forwardRef(mB);const pB=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M25.676 18.884a7.6 7.6 0 0 1-3.978 1.107 9 9 0 0 1-3.42-.707A6.94 6.94 0 0 0 17 23.314V27a1 1 0 0 1-1.066 1A1.023 1.023 0 0 1 15 26.969v-1.555l-4.828-4.828A6.6 6.6 0 0 1 7.93 21a5.73 5.73 0 0 1-2.99-.834C2.216 18.511.75 14.702 1.034 9.974a1 1 0 0 1 .94-.94c4.728-.28 8.537 1.182 10.187 3.906a5.75 5.75 0 0 1 .806 3.56.5.5 0 0 1-.86.304l-2.4-2.513a1 1 0 0 0-1.415 1.414l6.736 6.906q.01-.146.026-.291a8.57 8.57 0 0 1 2.33-4.933l6.323-6.682a1 1 0 0 0-1.413-1.415l-6.125 6.477a.5.5 0 0 1-.848-.217c-.592-2.185-.331-4.36.8-6.228 2.233-3.685 7.428-5.657 13.898-5.277a1 1 0 0 1 .94.94c.375 6.471-1.598 11.666-5.283 13.899"})})};b.forwardRef(pB);const vB=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M30 16a1.97 1.97 0 0 1-.95 1.689L11.04 28.706a2 2 0 0 1-2.767-.688A2 2 0 0 1 8 27.016V4.984a1.98 1.98 0 0 1 1.015-1.728 2 2 0 0 1 2.025.038L29.05 14.31A1.97 1.97 0 0 1 30 16"})})},bB=b.forwardRef(vB),wB=bB,xB=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M28.5 16a1.5 1.5 0 0 1-1.5 1.5h-9.5V27a1.5 1.5 0 1 1-3 0v-9.5H5a1.5 1.5 0 1 1 0-3h9.5V5a1.5 1.5 0 1 1 3 0v9.5H27a1.5 1.5 0 0 1 1.5 1.5"})})},yB=b.forwardRef(xB),CB=yB,$B=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M16 3a13 13 0 1 0 13 13A13.016 13.016 0 0 0 16 3m5 14h-4v4a1 1 0 0 1-2 0v-4h-4a1 1 0 0 1 0-2h4v-4a1 1 0 0 1 2 0v4h4a1 1 0 0 1 0 2"})})};b.forwardRef($B);const SB=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M27 5H17V3a1 1 0 0 0-2 0v2H5a2 2 0 0 0-2 2v15a2 2 0 0 0 2 2h4.92l-2.701 3.375a1 1 0 0 0 1.562 1.25L12.48 24h7.04l3.699 4.625a1 1 0 1 0 1.562-1.25L22.08 24H27a2 2 0 0 0 2-2V7a2 2 0 0 0-2-2M13 18a1 1 0 0 1-2 0v-3a1 1 0 0 1 2 0zm4 0a1 1 0 0 1-2 0v-5a1 1 0 0 1 2 0zm4 0a1 1 0 0 1-2 0v-7a1 1 0 0 1 2 0z"})})};b.forwardRef(SB);const AB=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M30.414 17 18 4.586A1.98 1.98 0 0 0 16.586 4H5a1 1 0 0 0-1 1v11.586A1.98 1.98 0 0 0 4.586 18L17 30.414a2 2 0 0 0 2.829 0l10.585-10.585a2 2 0 0 0 0-2.829M10.5 12a1.5 1.5 0 1 1 0-3 1.5 1.5 0 0 1 0 3"})})};b.forwardRef(AB);const RB=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M20.723 28H26a2 2 0 0 0 2-2v-4.706a1 1 0 0 0-1.383-.919 2.9 2.9 0 0 1-1.117.221c-1.654 0-3-1.387-3-3.091s1.346-3.091 3-3.091c.383 0 .763.075 1.117.221A1 1 0 0 0 28 13.706V9a2 2 0 0 0-2-2h-4.527a4.5 4.5 0 1 0-8.945 0H8a2 2 0 0 0-2 2v4.028a4.5 4.5 0 1 0 0 8.945V26a2 2 0 0 0 2 2h5.278"})})};b.forwardRef(RB);const kB=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M18 22.5a2 2 0 1 1-4 0 2 2 0 0 1 4 0M29.5 16A13.5 13.5 0 1 1 16 2.5 13.515 13.515 0 0 1 29.5 16m-3 0A10.5 10.5 0 1 0 16 26.5 10.51 10.51 0 0 0 26.5 16M16 8c-3.033 0-5.5 2.242-5.5 5v.5a1.5 1.5 0 1 0 3 0V13c0-1.102 1.125-2 2.5-2s2.5.898 2.5 2-1.125 2-2.5 2a1.5 1.5 0 0 0-1.5 1.5v1a1.5 1.5 0 0 0 2.966.32C19.79 17.235 21.5 15.296 21.5 13c0-2.758-2.468-5-5.5-5"})})};b.forwardRef(kB);const TB=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M14.5 9v11a6.006 6.006 0 0 1-6 6 1 1 0 0 1 0-2 4 4 0 0 0 4-4v-1H5a2 2 0 0 1-2-2V9a2 2 0 0 1 2-2h7.5a2 2 0 0 1 2 2M27 7h-7.5a2 2 0 0 0-2 2v8a2 2 0 0 0 2 2H27v1a4 4 0 0 1-4 4 1 1 0 0 0 0 2 6.006 6.006 0 0 0 6-6V9a2 2 0 0 0-2-2"})})},MB=b.forwardRef(TB),EB=MB,OB=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M27 5v23a1 1 0 0 1-2 0v-6h-6a1 1 0 0 1-1-1c.046-2.395.349-4.779.902-7.11 1.223-5.061 3.54-8.454 6.704-9.809a1 1 0 0 1 1.394.92m-12.014-.164a.999.999 0 1 0-1.972.33L13.986 11H11V5a1 1 0 0 0-2 0v6H6.014l.972-5.835a1 1 0 1 0-1.972-.329l-1 6A1 1 0 0 0 4 11a6.01 6.01 0 0 0 5 5.915V28a1 1 0 1 0 2 0V16.915A6.01 6.01 0 0 0 16 11q0-.083-.014-.164z"})})};b.forwardRef(OB);const DB=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M19 28a1 1 0 0 1-1 1h-4a1 1 0 0 1 0-2h4a1 1 0 0 1 1 1m8.953-8.521-1.546 6.954a2 2 0 0 1-3.188 1.138l-3.405-2.57h-7.625L8.78 27.57a2 2 0 0 1-3.189-1.138l-1.545-6.954a2.01 2.01 0 0 1 .415-1.714l3.57-4.282c.12-1.574.482-3.12 1.072-4.584 1.612-4.043 4.5-6.579 5.671-7.481a2 2 0 0 1 2.45 0c1.167.902 4.059 3.438 5.671 7.48.59 1.465.952 3.01 1.072 4.585l3.57 4.282a2.01 2.01 0 0 1 .415 1.714m-17.404 4.25q-2.014-3.666-2.445-7.209L6 19.045 7.545 26l.022-.016zM17.5 12.5a1.5 1.5 0 1 0-3 0 1.5 1.5 0 0 0 3 0m8.5 6.545-2.104-2.525q-.428 3.535-2.445 7.211l2.982 2.25.022.017z"})})};b.forwardRef(DB);const IB=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M19.716 14.141a1 1 0 0 1 .261-1.391l8.458-5.788a1 1 0 0 1 1.125 1.652L21.101 14.4a1 1 0 0 1-1.39-.261zm10.109 10.634a1 1 0 0 1-1.39.261L17 17.211l-5.315 3.636a4.5 4.5 0 1 1-1.125-1.65L15.229 16l-4.673-3.198a4.5 4.5 0 1 1 1.125-1.65l17.875 12.233a1 1 0 0 1 .269 1.39M9 22.5a1.5 1.5 0 1 0-3 0 1.5 1.5 0 0 0 3 0m0-13a1.5 1.5 0 1 0-3 0 1.5 1.5 0 0 0 3 0"})})};b.forwardRef(IB);const _B=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:16,height:16,viewBox:"0 0 256 256",fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M225.86 102.82c-3.77-3.94-7.67-8-9.14-11.57-1.36-3.27-1.44-8.69-1.52-13.94-.15-9.76-.31-20.82-8-28.51s-18.75-7.85-28.51-8c-5.25-.08-10.67-.16-13.94-1.52-3.56-1.47-7.63-5.37-11.57-9.14C146.28 23.51 138.44 16 128 16s-18.27 7.51-25.18 14.14c-3.94 3.77-8 7.67-11.57 9.14-3.25 1.36-8.69 1.44-13.94 1.52-9.76.15-20.82.31-28.51 8s-7.8 18.75-8 28.51c-.08 5.25-.16 10.67-1.52 13.94-1.47 3.56-5.37 7.63-9.14 11.57C23.51 109.72 16 117.56 16 128s7.51 18.27 14.14 25.18c3.77 3.94 7.67 8 9.14 11.57 1.36 3.27 1.44 8.69 1.52 13.94.15 9.76.31 20.82 8 28.51s18.75 7.85 28.51 8c5.25.08 10.67.16 13.94 1.52 3.56 1.47 7.63 5.37 11.57 9.14 6.9 6.63 14.74 14.14 25.18 14.14s18.27-7.51 25.18-14.14c3.94-3.77 8-7.67 11.57-9.14 3.27-1.36 8.69-1.44 13.94-1.52 9.76-.15 20.82-.31 28.51-8s7.85-18.75 8-28.51c.08-5.25.16-10.67 1.52-13.94 1.47-3.56 5.37-7.63 9.14-11.57 6.63-6.9 14.14-14.74 14.14-25.18s-7.51-18.27-14.14-25.18m-52.2 6.84-56 56a8 8 0 0 1-11.32 0l-24-24a8 8 0 0 1 11.32-11.32L112 148.69l50.34-50.35a8 8 0 0 1 11.32 11.32"})})};b.forwardRef(_B);const LB=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M29.061 26.939 23.125 21A11.515 11.515 0 1 0 21 23.125l5.941 5.942a1.503 1.503 0 0 0 2.125-2.125zM5.5 14a8.5 8.5 0 1 1 8.5 8.5A8.51 8.51 0 0 1 5.5 14"})})},BB=b.forwardRef(LB),h3=BB,NB=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M26 5H6a2 2 0 0 0-2 2v6a2 2 0 0 0 2 2h20a2 2 0 0 0 2-2V7a2 2 0 0 0-2-2m-3.5 6.5a1.5 1.5 0 1 1 0-3 1.5 1.5 0 0 1 0 3M26 17H6a2 2 0 0 0-2 2v6a2 2 0 0 0 2 2h20a2 2 0 0 0 2-2v-6a2 2 0 0 0-2-2m-3.5 6.5a1.5 1.5 0 1 1 0-3 1.5 1.5 0 0 1 0 3"})})};b.forwardRef(NB);const jB=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M28 7v7.346c0 11.202-9.477 14.918-11.375 15.549a1.94 1.94 0 0 1-1.25 0C13.475 29.264 4 25.548 4 14.346V7a2 2 0 0 1 2-2h20a2 2 0 0 1 2 2"})})},FB=b.forwardRef(jB),VB=FB,HB=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"m30.949 7.653-6.47-3.528A1 1 0 0 0 24 4h-4a1 1 0 0 0-1 1 3 3 0 0 1-6 0 1 1 0 0 0-1-1H8a1 1 0 0 0-.48.125L1.051 7.653a1.97 1.97 0 0 0-.824 2.657l2.41 4.601A2.05 2.05 0 0 0 4.458 16H7v10a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2V16h2.543a2.05 2.05 0 0 0 1.822-1.089l2.409-4.601a1.97 1.97 0 0 0-.825-2.658M4.459 14a.08.08 0 0 1-.051-.016L2.01 9.408 7 6.685V14zm23.134-.018a.07.07 0 0 1-.052.018H25V6.685l4.99 2.723z"})})};b.forwardRef(HB);const PB=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M12 27a2 2 0 1 1-4 0 2 2 0 0 1 4 0m11-2a2 2 0 1 0 0 4 2 2 0 0 0 0-4m5.805-16.594A1 1 0 0 0 28 8H6.04L5.026 4.45A2.01 2.01 0 0 0 3.103 3H1a1 1 0 0 0 0 2h2.103l4.522 15.824A3.01 3.01 0 0 0 10.509 23h12.014a2.99 2.99 0 0 0 2.867-2.117l3.566-11.59a1 1 0 0 0-.151-.887"})})};b.forwardRef(PB);const WB=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M14.5 27a1.5 1.5 0 0 1-1.5 1.5H6A2.5 2.5 0 0 1 3.5 26V6A2.5 2.5 0 0 1 6 3.5h7a1.5 1.5 0 0 1 0 3H6.5v19H13a1.5 1.5 0 0 1 1.5 1.5m13.561-12.061-5-5a1.503 1.503 0 0 0-2.125 2.125l2.439 2.436H13a1.5 1.5 0 1 0 0 3h10.375l-2.44 2.439a1.503 1.503 0 0 0 2.125 2.125l5-5a1.5 1.5 0 0 0 .001-2.125"})})};b.forwardRef(WB);const zB=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M4 10a1 1 0 0 1 1-1h4.646a3.5 3.5 0 0 1 6.708 0H27a1 1 0 1 1 0 2H16.354a3.5 3.5 0 0 1-6.708 0H5a1 1 0 0 1-1-1m23 11h-2.646a3.5 3.5 0 0 0-6.708 0H5a1 1 0 0 0 0 2h12.646a3.5 3.5 0 0 0 6.708 0H27a1 1 0 1 0 0-2"})})};b.forwardRef(zB);const UB=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M26 18a1.97 1.97 0 0 1-1.302 1.867l-6.457 2.375-2.375 6.452a1.99 1.99 0 0 1-3.735 0L9.75 22.25l-6.452-2.375a1.99 1.99 0 0 1 0-3.735l6.456-2.375 2.375-6.451a1.99 1.99 0 0 1 3.735 0l2.375 6.456 6.451 2.375A1.97 1.97 0 0 1 26 18M19 6h2v2a1 1 0 0 0 2 0V6h2a1 1 0 1 0 0-2h-2V2a1 1 0 1 0-2 0v2h-2a1 1 0 1 0 0 2m11 4h-1V9a1 1 0 1 0-2 0v1h-1a1 1 0 0 0 0 2h1v1a1 1 0 0 0 2 0v-1h1a1 1 0 0 0 0-2"})})};b.forwardRef(UB);const qB=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M15 7v6a2 2 0 0 1-2 2H7a2 2 0 0 1-2-2V7a2 2 0 0 1 2-2h6a2 2 0 0 1 2 2m10-2h-6a2 2 0 0 0-2 2v6a2 2 0 0 0 2 2h6a2 2 0 0 0 2-2V7a2 2 0 0 0-2-2M13 17H7a2 2 0 0 0-2 2v6a2 2 0 0 0 2 2h6a2 2 0 0 0 2-2v-6a2 2 0 0 0-2-2m12 0h-6a2 2 0 0 0-2 2v6a2 2 0 0 0 2 2h6a2 2 0 0 0 2-2v-6a2 2 0 0 0-2-2"})})};b.forwardRef(qB);const KB=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:[p.jsx("path",{d:"M27.5 21.136 16 27.843 4.5 21.136a1 1 0 0 0-1 1.728l12 7a1 1 0 0 0 1.008 0l12-7a1 1 0 1 0-1.008-1.728"}),p.jsx("path",{d:"M27.5 15.136 16 21.843 4.5 15.136a1 1 0 0 0-1 1.728l12 7a1 1 0 0 0 1.008 0l12-7a1 1 0 1 0-1.008-1.728"}),p.jsx("path",{d:"m3.5 10.864 12 7a1 1 0 0 0 1.008 0l12-7a1 1 0 0 0 0-1.728l-12-7a1 1 0 0 0-1.008 0l-12 7a1 1 0 0 0 0 1.728"})]})};b.forwardRef(KB);const GB=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"m29.313 14.298-5.638 4.92 1.689 7.325a2 2 0 0 1-2.98 2.167l-6.389-3.875L9.62 28.71a2 2 0 0 1-2.98-2.168l1.686-7.317-5.638-4.928a2 2 0 0 1 1.138-3.507l7.433-.644 2.901-6.92a1.994 1.994 0 0 1 3.68 0l2.91 6.92 7.43.644a2 2 0 0 1 1.139 3.508z"})})};b.forwardRef(GB);const YB=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M29 19a4 4 0 1 0-4.991 3.875A1 1 0 0 0 24 23a4 4 0 0 1-4 4h-3a4 4 0 0 1-4-4v-5.065c3.934-.5 7-3.934 7-8.039V5a2 2 0 0 0-2-2h-2a1 1 0 1 0 0 2h2v4.896c0 3.323-2.656 6.061-5.92 6.104A6 6 0 0 1 6 10V5h2a1 1 0 0 0 0-2H6a2 2 0 0 0-2 2v5a8 8 0 0 0 7 7.936V23a6.006 6.006 0 0 0 6 6h3a6.006 6.006 0 0 0 6-6 1 1 0 0 0-.009-.125A4 4 0 0 0 29 19m-4 1a1 1 0 1 1 0-2 1 1 0 0 1 0 2"})})};b.forwardRef(YB);const XB=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 256 256",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M216 56v144a16 16 0 0 1-16 16H56a16 16 0 0 1-16-16V56a16 16 0 0 1 16-16h144a16 16 0 0 1 16 16"})})};b.forwardRef(XB);const ZB=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M29 12a1 1 0 0 0-.038-.275L27.17 5.45A2.01 2.01 0 0 0 25.25 4H6.75a2.01 2.01 0 0 0-1.919 1.45L3.04 11.725A1 1 0 0 0 3 12v2a5 5 0 0 0 2 4v8a2 2 0 0 0 2 2h18a2 2 0 0 0 2-2v-8a5 5 0 0 0 2-4zm-18 2a3 3 0 0 1-4.39 2.657 1 1 0 0 0-.228-.132A3 3 0 0 1 5 14v-1h6zm8 0a3 3 0 0 1-6 0v-1h6zm8 0a3 3 0 0 1-1.384 2.525q-.12.051-.225.131A3 3 0 0 1 21 14v-1h6z"})})};b.forwardRef(ZB);const QB=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M28.5 16a1.5 1.5 0 0 1-1.5 1.5h-3.767A5.19 5.19 0 0 1 24.5 21c0 1.806-.976 3.54-2.679 4.756C20.25 26.881 18.18 27.5 16 27.5s-4.25-.619-5.821-1.744C8.476 24.54 7.5 22.806 7.5 21a1.5 1.5 0 0 1 3 0c0 1.898 2.519 3.5 5.5 3.5s5.5-1.602 5.5-3.5c0-1.595-1.163-2.523-4.419-3.5H5a1.5 1.5 0 1 1 0-3h22a1.5 1.5 0 0 1 1.5 1.5M9.389 12.5a1.5 1.5 0 0 0 1.5-1.5c0-2 2.197-3.5 5.111-3.5 2.17 0 3.921.831 4.685 2.223a1.5 1.5 0 0 0 2.625-1.446C22.016 5.914 19.281 4.5 16 4.5c-4.625 0-8.111 2.794-8.111 6.5a1.5 1.5 0 0 0 1.5 1.5"})})},JB=b.forwardRef(QB),eN=JB,tN=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M15 5V2a1 1 0 0 1 2 0v3a1 1 0 0 1-2 0m1 3a8 8 0 1 0 8 8 8.01 8.01 0 0 0-8-8m-8.707.707a1 1 0 1 0 1.414-1.415l-2-2a1 1 0 1 0-1.414 1.415zm0 14.586-2 2a1 1 0 1 0 1.414 1.415l2-2a1 1 0 1 0-1.415-1.415M24 9a1 1 0 0 0 .707-.293l2-2a1 1 0 0 0-1.415-1.414l-2 2A1 1 0 0 0 24 9m.707 14.293a1 1 0 1 0-1.415 1.415l2 2a1 1 0 0 0 1.415-1.415zM6 16a1 1 0 0 0-1-1H2a1 1 0 0 0 0 2h3a1 1 0 0 0 1-1m10 10a1 1 0 0 0-1 1v3a1 1 0 0 0 2 0v-3a1 1 0 0 0-1-1m14-11h-3a1 1 0 0 0 0 2h3a1 1 0 0 0 0-2"})})};b.forwardRef(tN);const nN=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M27 8h-8.586l4.293-4.292a1 1 0 0 0-1.415-1.415L16 7.586l-5.292-5.293a1 1 0 1 0-1.415 1.415L13.586 8H5a2 2 0 0 0-2 2v15a2 2 0 0 0 2 2h22a2 2 0 0 0 2-2V10a2 2 0 0 0-2-2m0 17h-7V10h7zm-2-10.5a1.5 1.5 0 1 1-3 0 1.5 1.5 0 0 1 3 0m0 6a1.5 1.5 0 1 1-3 0 1.5 1.5 0 0 1 3 0"})})};b.forwardRef(nN);const rN=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"m29.978 19.625-1.5-12A3 3 0 0 0 25.5 5H4a2 2 0 0 0-2 2v11a2 2 0 0 0 2 2h5.383l4.722 9.448A1 1 0 0 0 15 30a5 5 0 0 0 5-5v-2h7a3 3 0 0 0 2.977-3.375M9 18H4V7h5z"})})};b.forwardRef(rN);const iN=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M29.25 10.015A3 3 0 0 0 27 9h-7V7a5 5 0 0 0-5-5 1 1 0 0 0-.895.553L9.383 12H4a2 2 0 0 0-2 2v11a2 2 0 0 0 2 2h21.5a3 3 0 0 0 2.977-2.625l1.5-12a3 3 0 0 0-.727-2.36M4 14h5v11H4z"})})};b.forwardRef(iN);const oN=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M23 3H9a4 4 0 0 0-4 4v16a4 4 0 0 0 4 4h1l-1.8 2.4a1 1 0 0 0 1.6 1.2l2.7-3.6h7l2.7 3.6a1 1 0 0 0 1.6-1.2L22 27h1a4 4 0 0 0 4-4V7a4 4 0 0 0-4-4M10.5 23a1.5 1.5 0 1 1 0-3 1.5 1.5 0 0 1 0 3m4.5-8H7v-5h8zm6.5 8a1.5 1.5 0 1 1 0-3 1.5 1.5 0 0 1 0 3m3.5-8h-8v-5h8z"})})};b.forwardRef(oN);const sN=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M27 6h-5V5a3 3 0 0 0-3-3h-6a3 3 0 0 0-3 3v1H5a1 1 0 0 0 0 2h1v18a2 2 0 0 0 2 2h16a2 2 0 0 0 2-2V8h1a1 1 0 1 0 0-2M14 21a1 1 0 0 1-2 0v-8a1 1 0 0 1 2 0zm6 0a1 1 0 0 1-2 0v-8a1 1 0 0 1 2 0zm0-15h-8V5a1 1 0 0 1 1-1h6a1 1 0 0 1 1 1z"})})},aN=b.forwardRef(sN),lN=aN,cN=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"m23.54 2.267-3.711 3.377c1.7.52 3.298 1.397 4.653 2.631 4.684 4.266 4.684 11.184 0 15.45q-5.184 4.72-16.021 6.008l3.71-3.377a12.2 12.2 0 0 1-4.653-2.63c-4.684-4.267-4.712-11.16 0-15.45q5.184-4.721 16.021-6.01m-7.54 8.4c-3.314 0-6 2.388-6 5.333s2.686 5.333 6 5.333 6-2.387 6-5.333c0-2.945-2.686-5.333-6-5.333"})})};b.forwardRef(cN);const uN=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M25.5 28a1.5 1.5 0 0 1-1.5 1.5H8a1.5 1.5 0 1 1 0-3h16a1.5 1.5 0 0 1 1.5 1.5M16 24.5a8.51 8.51 0 0 0 8.5-8.5V7a1.5 1.5 0 1 0-3 0v9a5.5 5.5 0 0 1-11 0V7a1.5 1.5 0 1 0-3 0v9a8.51 8.51 0 0 0 8.5 8.5"})})},hN=b.forwardRef(uN),fN=hN,dN=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M28.5 19v7a2.5 2.5 0 0 1-2.5 2.5H6A2.5 2.5 0 0 1 3.5 26v-7a1.5 1.5 0 0 1 3 0v6.5h19V19a1.5 1.5 0 1 1 3 0m-16.439-7.939L14.5 8.625V19a1.5 1.5 0 1 0 3 0V8.625l2.439 2.44a1.503 1.503 0 0 0 2.125-2.125l-5-5a1.5 1.5 0 0 0-2.125 0l-5 5a1.503 1.503 0 1 0 2.125 2.125z"})})};b.forwardRef(dN);const gN=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M28.866 27.5A1 1 0 0 1 28 28H4a1 1 0 0 1-.865-1.5c1.904-3.291 4.838-5.651 8.261-6.77a9 9 0 1 1 9.208 0c3.424 1.119 6.357 3.479 8.261 6.77a1 1 0 0 1 .001 1"})})};b.forwardRef(gN);const mN=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M19.44 3.101a1 1 0 0 0-1.054.11L9.656 10H4a2 2 0 0 0-2 2v8a2 2 0 0 0 2 2h5.656l8.73 6.789A1 1 0 0 0 20 28V4a1 1 0 0 0-.56-.899M28.414 16l2.293-2.292a1.001 1.001 0 0 0-1.415-1.415L27 14.586l-2.293-2.293a1 1 0 1 0-1.415 1.415L25.587 16l-2.293 2.293a1 1 0 0 0 1.415 1.415L27 17.414l2.293 2.294a1 1 0 0 0 1.415-1.415z"})})};b.forwardRef(mN);const pN=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M19.439 3.101a1 1 0 0 0-1.053.11L9.656 10H4a2 2 0 0 0-2 2v8a2 2 0 0 0 2 2h5.656l8.73 6.789A1.001 1.001 0 0 0 20 28V4a1 1 0 0 0-.561-.899M9 20H4v-8h5zm15.75-7.305a5 5 0 0 1 0 6.61 1 1 0 0 1-1.5-1.322 3 3 0 0 0 0-3.966 1 1 0 0 1 1.5-1.322M31 16a10 10 0 0 1-2.546 6.668 1 1 0 0 1-1.49-1.334 8 8 0 0 0 0-10.666.998.998 0 0 1 .407-1.624 1 1 0 0 1 1.083.29A9.98 9.98 0 0 1 31 16"})})};b.forwardRef(pN);const vN=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M15 6a4 4 0 1 1 8 0 4 4 0 0 1-8 0m11 11c-3.58 0-5.226-1.662-6.969-3.421a25 25 0 0 0-1.375-1.323C13.031 8.24 5.63 15.098 5.316 15.391a1 1 0 0 0 1.369 1.458 20.5 20.5 0 0 1 3.815-2.724c1.723-.922 3.174-1.279 4.338-1.072L8.082 28.6a1 1 0 0 0 1.835.798l4.2-9.659L18 22.515V29a1 1 0 1 0 2 0v-7a1 1 0 0 0-.419-.814l-4.65-3.321L16.61 14c.33.305.657.634 1 .98C19.381 16.774 21.586 19 26 19a1 1 0 0 0 0-2"})})};b.forwardRef(vN);const bN=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"M16 3a13 13 0 1 0 13 13A13.013 13.013 0 0 0 16 3m-1 7a1 1 0 0 1 2 0v7a1 1 0 0 1-2 0zm1 13a1.5 1.5 0 1 1 0-3 1.5 1.5 0 0 1 0 3"})})},wN=b.forwardRef(bN),f3=wN,xN=({fill:t="currentColor",stroke:e,...n},r)=>{const{colors:i}=k.useTheme(),o=t&&t in i?i[t]:t,s=e&&e in i?i[e]:e;return p.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",width:16,height:16,fill:o,stroke:s,ref:r,...n,children:p.jsx("path",{d:"m31.316 24.949-3 1a1 1 0 0 1-1.211-.5l-3.724-7.45H13a1 1 0 0 1-1-1v-3.707A7 7 0 0 0 14 27c3.239 0 6.261-2.256 7.031-5.25a1 1 0 1 1 1.938.5C21.96 26.162 18.19 29 14 29a9 9 0 0 1-2-17.774V8.851a3.5 3.5 0 1 1 2 0V11h7a1 1 0 0 1 0 2h-7v3h10a1 1 0 0 1 .894.552l3.612 7.225 2.178-.726a1 1 0 1 1 .632 1.898"})})};b.forwardRef(xN);const d3="Avatar",[yN,qee]=bt(d3),[CN,g3]=yN(d3),$N=b.forwardRef((t,e)=>{const{__scopeAvatar:n,...r}=t,[i,o]=b.useState("idle");return b.createElement(CN,{scope:n,imageLoadingStatus:i,onImageLoadingStatusChange:o},b.createElement(me.span,U({},r,{ref:e})))}),SN="AvatarImage",AN=b.forwardRef((t,e)=>{const{__scopeAvatar:n,src:r,onLoadingStatusChange:i=()=>{},...o}=t,s=g3(SN,n),a=TN(r),c=Ct(h=>{i(h),s.onImageLoadingStatusChange(h)});return ut(()=>{a!=="idle"&&c(a)},[a,c]),a==="loaded"?b.createElement(me.img,U({},o,{ref:e,src:r})):null}),RN="AvatarFallback",kN=b.forwardRef((t,e)=>{const{__scopeAvatar:n,delayMs:r,...i}=t,o=g3(RN,n),[s,a]=b.useState(r===void 0);return b.useEffect(()=>{if(r!==void 0){const c=window.setTimeout(()=>a(!0),r);return()=>window.clearTimeout(c)}},[r]),s&&o.imageLoadingStatus!=="loaded"?b.createElement(me.span,U({},i,{ref:e})):null});function TN(t){const[e,n]=b.useState("idle");return ut(()=>{if(!t){n("error");return}let r=!0;const i=new window.Image,o=s=>()=>{r&&n(s)};return n("loading"),i.onload=o("loaded"),i.onerror=o("error"),i.src=t,()=>{r=!1}},[t]),e}const MN=$N,EN=AN,ON=kN,Ad="rovingFocusGroup.onEntryFocus",DN={bubbles:!1,cancelable:!0},Hg="RovingFocusGroup",[k0,m3,IN]=ah(Hg),[_N,Bs]=bt(Hg,[IN]),[LN,BN]=_N(Hg),NN=b.forwardRef((t,e)=>b.createElement(k0.Provider,{scope:t.__scopeRovingFocusGroup},b.createElement(k0.Slot,{scope:t.__scopeRovingFocusGroup},b.createElement(jN,U({},t,{ref:e}))))),jN=b.forwardRef((t,e)=>{const{__scopeRovingFocusGroup:n,orientation:r,loop:i=!1,dir:o,currentTabStopId:s,defaultCurrentTabStopId:a,onCurrentTabStopIdChange:c,onEntryFocus:h,...f}=t,d=b.useRef(null),m=ye(e,d),v=$o(o),[w=null,x]=_t({prop:s,defaultProp:a,onChange:c}),[C,S]=b.useState(!1),A=Ct(h),T=m3(n),O=b.useRef(!1),[D,L]=b.useState(0);return b.useEffect(()=>{const I=d.current;if(I)return I.addEventListener(Ad,A),()=>I.removeEventListener(Ad,A)},[A]),b.createElement(LN,{scope:n,orientation:r,dir:v,loop:i,currentTabStopId:w,onItemFocus:b.useCallback(I=>x(I),[x]),onItemShiftTab:b.useCallback(()=>S(!0),[]),onFocusableItemAdd:b.useCallback(()=>L(I=>I+1),[]),onFocusableItemRemove:b.useCallback(()=>L(I=>I-1),[])},b.createElement(me.div,U({tabIndex:C||D===0?-1:0,"data-orientation":r},f,{ref:m,style:{outline:"none",...t.style},onMouseDown:ne(t.onMouseDown,()=>{O.current=!0}),onFocus:ne(t.onFocus,I=>{const V=!O.current;if(I.target===I.currentTarget&&V&&!C){const F=new CustomEvent(Ad,DN);if(I.currentTarget.dispatchEvent(F),!F.defaultPrevented){const H=T().filter(re=>re.focusable),K=H.find(re=>re.active),W=H.find(re=>re.id===w),G=[K,W,...H].filter(Boolean).map(re=>re.ref.current);p3(G)}}O.current=!1}),onBlur:ne(t.onBlur,()=>S(!1))})))}),FN="RovingFocusGroupItem",VN=b.forwardRef((t,e)=>{const{__scopeRovingFocusGroup:n,focusable:r=!0,active:i=!1,tabStopId:o,...s}=t,a=Lt(),c=o||a,h=BN(FN,n),f=h.currentTabStopId===c,d=m3(n),{onFocusableItemAdd:m,onFocusableItemRemove:v}=h;return b.useEffect(()=>{if(r)return m(),()=>v()},[r,m,v]),b.createElement(k0.ItemSlot,{scope:n,id:c,focusable:r,active:i},b.createElement(me.span,U({tabIndex:f?0:-1,"data-orientation":h.orientation},s,{ref:e,onMouseDown:ne(t.onMouseDown,w=>{r?h.onItemFocus(c):w.preventDefault()}),onFocus:ne(t.onFocus,()=>h.onItemFocus(c)),onKeyDown:ne(t.onKeyDown,w=>{if(w.key==="Tab"&&w.shiftKey){h.onItemShiftTab();return}if(w.target!==w.currentTarget)return;const x=WN(w,h.orientation,h.dir);if(x!==void 0){w.preventDefault();let S=d().filter(A=>A.focusable).map(A=>A.ref.current);if(x==="last")S.reverse();else if(x==="prev"||x==="next"){x==="prev"&&S.reverse();const A=S.indexOf(w.currentTarget);S=h.loop?zN(S,A+1):S.slice(A+1)}setTimeout(()=>p3(S))}})})))}),HN={ArrowLeft:"prev",ArrowUp:"prev",ArrowRight:"next",ArrowDown:"next",PageUp:"first",Home:"first",PageDown:"last",End:"last"};function PN(t,e){return e!=="rtl"?t:t==="ArrowLeft"?"ArrowRight":t==="ArrowRight"?"ArrowLeft":t}function WN(t,e,n){const r=PN(t.key,n);if(!(e==="vertical"&&["ArrowLeft","ArrowRight"].includes(r))&&!(e==="horizontal"&&["ArrowUp","ArrowDown"].includes(r)))return HN[r]}function p3(t){const e=document.activeElement;for(const n of t)if(n===e||(n.focus(),document.activeElement!==e))return}function zN(t,e){return t.map((n,r)=>t[(e+r)%t.length])}const Pg=NN,Wg=VN;var v3=ag(),Rd=function(){},gh=$.forwardRef(function(t,e){var n=$.useRef(null),r=$.useState({onScrollCapture:Rd,onWheelCapture:Rd,onTouchMoveCapture:Rd}),i=r[0],o=r[1],s=t.forwardProps,a=t.children,c=t.className,h=t.removeScrollBar,f=t.enabled,d=t.shards,m=t.sideCar,v=t.noIsolation,w=t.inert,x=t.allowPinchZoom,C=t.as,S=C===void 0?"div":C,A=il(t,["forwardProps","children","className","removeScrollBar","enabled","shards","sideCar","noIsolation","inert","allowPinchZoom","as"]),T=m,O=sg([n,e]),D=exports.__assign(exports.__assign({},A),i);return $.createElement($.Fragment,null,f&&$.createElement(T,{sideCar:v3,removeScrollBar:h,shards:d,noIsolation:v,inert:w,setCallbacks:o,allowPinchZoom:!!x,lockRef:n}),s?$.cloneElement($.Children.only(a),exports.__assign(exports.__assign({},D),{ref:O})):$.createElement(S,exports.__assign({},D,{className:c,ref:O}),a))});gh.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1};gh.classNames={fullWidth:os,zeroRight:is};var T0=!1;if(typeof window<"u")try{var bc=Object.defineProperty({},"passive",{get:function(){return T0=!0,!0}});window.addEventListener("test",bc,bc),window.removeEventListener("test",bc,bc)}catch{T0=!1}var qo=T0?{passive:!1}:!1,UN=function(t){return t.tagName==="TEXTAREA"},b3=function(t,e){var n=window.getComputedStyle(t);return n[e]!=="hidden"&&!(n.overflowY===n.overflowX&&!UN(t)&&n[e]==="visible")},qN=function(t){return b3(t,"overflowY")},KN=function(t){return b3(t,"overflowX")},qv=function(t,e){var n=e;do{typeof ShadowRoot<"u"&&n instanceof ShadowRoot&&(n=n.host);var r=w3(t,n);if(r){var i=x3(t,n),o=i[1],s=i[2];if(o>s)return!0}n=n.parentNode}while(n&&n!==document.body);return!1},GN=function(t){var e=t.scrollTop,n=t.scrollHeight,r=t.clientHeight;return[e,n,r]},YN=function(t){var e=t.scrollLeft,n=t.scrollWidth,r=t.clientWidth;return[e,n,r]},w3=function(t,e){return t==="v"?qN(e):KN(e)},x3=function(t,e){return t==="v"?GN(e):YN(e)},XN=function(t,e){return t==="h"&&e==="rtl"?-1:1},ZN=function(t,e,n,r,i){var o=XN(t,window.getComputedStyle(e).direction),s=o*r,a=n.target,c=e.contains(a),h=!1,f=s>0,d=0,m=0;do{var v=x3(t,a),w=v[0],x=v[1],C=v[2],S=x-C-o*w;(w||S)&&w3(t,a)&&(d+=S,m+=w),a=a.parentNode}while(!c&&a!==document.body||c&&(e.contains(a)||e===a));return(f&&d===0||!f&&m===0)&&(h=!0),h},wc=function(t){return"changedTouches"in t?[t.changedTouches[0].clientX,t.changedTouches[0].clientY]:[0,0]},Kv=function(t){return[t.deltaX,t.deltaY]},Gv=function(t){return t&&"current"in t?t.current:t},QN=function(t,e){return t[0]===e[0]&&t[1]===e[1]},JN=function(t){return`
42
- .block-interactivity-`.concat(t,` {pointer-events: none;}
43
- .allow-interactivity-`).concat(t,` {pointer-events: all;}
44
- `)},ej=0,Ko=[];function tj(t){var e=$.useRef([]),n=$.useRef([0,0]),r=$.useRef(),i=$.useState(ej++)[0],o=$.useState(function(){return sh()})[0],s=$.useRef(t);$.useEffect(function(){s.current=t},[t]),$.useEffect(function(){if(t.inert){document.body.classList.add("block-interactivity-".concat(i));var x=og([t.lockRef.current],(t.shards||[]).map(Gv),!0).filter(Boolean);return x.forEach(function(C){return C.classList.add("allow-interactivity-".concat(i))}),function(){document.body.classList.remove("block-interactivity-".concat(i)),x.forEach(function(C){return C.classList.remove("allow-interactivity-".concat(i))})}}},[t.inert,t.lockRef.current,t.shards]);var a=$.useCallback(function(x,C){if("touches"in x&&x.touches.length===2)return!s.current.allowPinchZoom;var S=wc(x),A=n.current,T="deltaX"in x?x.deltaX:A[0]-S[0],O="deltaY"in x?x.deltaY:A[1]-S[1],D,L=x.target,I=Math.abs(T)>Math.abs(O)?"h":"v";if("touches"in x&&I==="h"&&L.type==="range")return!1;var V=qv(I,L);if(!V)return!0;if(V?D=I:(D=I==="v"?"h":"v",V=qv(I,L)),!V)return!1;if(!r.current&&"changedTouches"in x&&(T||O)&&(r.current=D),!D)return!0;var F=r.current||D;return ZN(F,C,x,F==="h"?T:O)},[]),c=$.useCallback(function(x){var C=x;if(!(!Ko.length||Ko[Ko.length-1]!==o)){var S="deltaY"in C?Kv(C):wc(C),A=e.current.filter(function(D){return D.name===C.type&&D.target===C.target&&QN(D.delta,S)})[0];if(A&&A.should){C.cancelable&&C.preventDefault();return}if(!A){var T=(s.current.shards||[]).map(Gv).filter(Boolean).filter(function(D){return D.contains(C.target)}),O=T.length>0?a(C,T[0]):!s.current.noIsolation;O&&C.cancelable&&C.preventDefault()}}},[]),h=$.useCallback(function(x,C,S,A){var T={name:x,delta:C,target:S,should:A};e.current.push(T),setTimeout(function(){e.current=e.current.filter(function(O){return O!==T})},1)},[]),f=$.useCallback(function(x){n.current=wc(x),r.current=void 0},[]),d=$.useCallback(function(x){h(x.type,Kv(x),x.target,a(x,t.lockRef.current))},[]),m=$.useCallback(function(x){h(x.type,wc(x),x.target,a(x,t.lockRef.current))},[]);$.useEffect(function(){return Ko.push(o),t.setCallbacks({onScrollCapture:d,onWheelCapture:d,onTouchMoveCapture:m}),document.addEventListener("wheel",c,qo),document.addEventListener("touchmove",c,qo),document.addEventListener("touchstart",f,qo),function(){Ko=Ko.filter(function(x){return x!==o}),document.removeEventListener("wheel",c,qo),document.removeEventListener("touchmove",c,qo),document.removeEventListener("touchstart",f,qo)}},[]);var v=t.removeScrollBar,w=t.inert;return $.createElement($.Fragment,null,w?$.createElement(o,{styles:JN(i)}):null,v?$.createElement(cg,{gapMode:"margin"}):null)}const nj=lg(v3,tj);var mh=$.forwardRef(function(t,e){return $.createElement(gh,exports.__assign({},t,{ref:e,sideCar:nj}))});mh.classNames=gh.classNames;const M0=["Enter"," "],rj=["ArrowDown","PageUp","Home"],y3=["ArrowUp","PageDown","End"],ij=[...rj,...y3],oj={ltr:[...M0,"ArrowRight"],rtl:[...M0,"ArrowLeft"]},sj={ltr:["ArrowLeft"],rtl:["ArrowRight"]},ph="Menu",[Ea,aj,lj]=ah(ph),[So,C3]=bt(ph,[lj,Li,Bs]),zg=Li(),$3=Bs(),[cj,Ao]=So(ph),[uj,ll]=So(ph),hj=t=>{const{__scopeMenu:e,open:n=!1,children:r,dir:i,onOpenChange:o,modal:s=!0}=t,a=zg(e),[c,h]=b.useState(null),f=b.useRef(!1),d=Ct(o),m=$o(i);return b.useEffect(()=>{const v=()=>{f.current=!0,document.addEventListener("pointerdown",w,{capture:!0,once:!0}),document.addEventListener("pointermove",w,{capture:!0,once:!0})},w=()=>f.current=!1;return document.addEventListener("keydown",v,{capture:!0}),()=>{document.removeEventListener("keydown",v,{capture:!0}),document.removeEventListener("pointerdown",w,{capture:!0}),document.removeEventListener("pointermove",w,{capture:!0})}},[]),b.createElement(Ja,a,b.createElement(cj,{scope:e,open:n,onOpenChange:d,content:c,onContentChange:h},b.createElement(uj,{scope:e,onClose:b.useCallback(()=>d(!1),[d]),isUsingKeyboardRef:f,dir:m,modal:s},r)))},S3=b.forwardRef((t,e)=>{const{__scopeMenu:n,...r}=t,i=zg(n);return b.createElement(el,U({},i,r,{ref:e}))}),A3="MenuPortal",[fj,R3]=So(A3,{forceMount:void 0}),dj=t=>{const{__scopeMenu:e,forceMount:n,children:r,container:i}=t,o=Ao(A3,e);return b.createElement(fj,{scope:e,forceMount:n},b.createElement(Mt,{present:n||o.open},b.createElement(Ds,{asChild:!0,container:i},r)))},Zn="MenuContent",[gj,Ug]=So(Zn),mj=b.forwardRef((t,e)=>{const n=R3(Zn,t.__scopeMenu),{forceMount:r=n.forceMount,...i}=t,o=Ao(Zn,t.__scopeMenu),s=ll(Zn,t.__scopeMenu);return b.createElement(Ea.Provider,{scope:t.__scopeMenu},b.createElement(Mt,{present:r||o.open},b.createElement(Ea.Slot,{scope:t.__scopeMenu},s.modal?b.createElement(pj,U({},i,{ref:e})):b.createElement(vj,U({},i,{ref:e})))))}),pj=b.forwardRef((t,e)=>{const n=Ao(Zn,t.__scopeMenu),r=b.useRef(null),i=ye(e,r);return b.useEffect(()=>{const o=r.current;if(o)return rl(o)},[]),b.createElement(qg,U({},t,{ref:i,trapFocus:n.open,disableOutsidePointerEvents:n.open,disableOutsideScroll:!0,onFocusOutside:ne(t.onFocusOutside,o=>o.preventDefault(),{checkForDefaultPrevented:!1}),onDismiss:()=>n.onOpenChange(!1)}))}),vj=b.forwardRef((t,e)=>{const n=Ao(Zn,t.__scopeMenu);return b.createElement(qg,U({},t,{ref:e,trapFocus:!1,disableOutsidePointerEvents:!1,disableOutsideScroll:!1,onDismiss:()=>n.onOpenChange(!1)}))}),qg=b.forwardRef((t,e)=>{const{__scopeMenu:n,loop:r=!1,trapFocus:i,onOpenAutoFocus:o,onCloseAutoFocus:s,disableOutsidePointerEvents:a,onEntryFocus:c,onEscapeKeyDown:h,onPointerDownOutside:f,onFocusOutside:d,onInteractOutside:m,onDismiss:v,disableOutsideScroll:w,...x}=t,C=Ao(Zn,n),S=ll(Zn,n),A=zg(n),T=$3(n),O=aj(n),[D,L]=b.useState(null),I=b.useRef(null),V=ye(e,I,C.onContentChange),F=b.useRef(0),H=b.useRef(""),K=b.useRef(0),W=b.useRef(null),J=b.useRef("right"),G=b.useRef(0),re=w?mh:b.Fragment,oe=w?{as:Cr,allowPinchZoom:!0}:void 0,te=Y=>{var ue,ge;const De=H.current+Y,we=O().filter(ke=>!ke.disabled),Ve=document.activeElement,Ne=(ue=we.find(ke=>ke.ref.current===Ve))===null||ue===void 0?void 0:ue.textValue,He=we.map(ke=>ke.textValue),pe=Mj(He,De,Ne),Oe=(ge=we.find(ke=>ke.textValue===pe))===null||ge===void 0?void 0:ge.ref.current;(function ke(Ae){H.current=Ae,window.clearTimeout(F.current),Ae!==""&&(F.current=window.setTimeout(()=>ke(""),1e3))})(De),Oe&&setTimeout(()=>Oe.focus())};b.useEffect(()=>()=>window.clearTimeout(F.current),[]),Is();const ie=b.useCallback(Y=>{var ue,ge;return J.current===((ue=W.current)===null||ue===void 0?void 0:ue.side)&&Oj(Y,(ge=W.current)===null||ge===void 0?void 0:ge.area)},[]);return b.createElement(gj,{scope:n,searchRef:H,onItemEnter:b.useCallback(Y=>{ie(Y)&&Y.preventDefault()},[ie]),onItemLeave:b.useCallback(Y=>{var ue;ie(Y)||((ue=I.current)===null||ue===void 0||ue.focus(),L(null))},[ie]),onTriggerLeave:b.useCallback(Y=>{ie(Y)&&Y.preventDefault()},[ie]),pointerGraceTimerRef:K,onPointerGraceIntentChange:b.useCallback(Y=>{W.current=Y},[])},b.createElement(re,oe,b.createElement(_s,{asChild:!0,trapped:i,onMountAutoFocus:ne(o,Y=>{var ue;Y.preventDefault(),(ue=I.current)===null||ue===void 0||ue.focus()}),onUnmountAutoFocus:s},b.createElement(Co,{asChild:!0,disableOutsidePointerEvents:a,onEscapeKeyDown:h,onPointerDownOutside:f,onFocusOutside:d,onInteractOutside:m,onDismiss:v},b.createElement(Pg,U({asChild:!0},T,{dir:S.dir,orientation:"vertical",loop:r,currentTabStopId:D,onCurrentTabStopIdChange:L,onEntryFocus:ne(c,Y=>{S.isUsingKeyboardRef.current||Y.preventDefault()})}),b.createElement(tl,U({role:"menu","aria-orientation":"vertical","data-state":M3(C.open),"data-radix-menu-content":"",dir:S.dir},A,x,{ref:V,style:{outline:"none",...x.style},onKeyDown:ne(x.onKeyDown,Y=>{const ge=Y.target.closest("[data-radix-menu-content]")===Y.currentTarget,De=Y.ctrlKey||Y.altKey||Y.metaKey,we=Y.key.length===1;ge&&(Y.key==="Tab"&&Y.preventDefault(),!De&&we&&te(Y.key));const Ve=I.current;if(Y.target!==Ve||!ij.includes(Y.key))return;Y.preventDefault();const He=O().filter(pe=>!pe.disabled).map(pe=>pe.ref.current);y3.includes(Y.key)&&He.reverse(),kj(He)}),onBlur:ne(t.onBlur,Y=>{Y.currentTarget.contains(Y.target)||(window.clearTimeout(F.current),H.current="")}),onPointerMove:ne(t.onPointerMove,Oa(Y=>{const ue=Y.target,ge=G.current!==Y.clientX;if(Y.currentTarget.contains(ue)&&ge){const De=Y.clientX>G.current?"right":"left";J.current=De,G.current=Y.clientX}}))})))))))}),bj=b.forwardRef((t,e)=>{const{__scopeMenu:n,...r}=t;return b.createElement(me.div,U({},r,{ref:e}))}),E0="MenuItem",Yv="menu.itemSelect",wj=b.forwardRef((t,e)=>{const{disabled:n=!1,onSelect:r,...i}=t,o=b.useRef(null),s=ll(E0,t.__scopeMenu),a=Ug(E0,t.__scopeMenu),c=ye(e,o),h=b.useRef(!1),f=()=>{const d=o.current;if(!n&&d){const m=new CustomEvent(Yv,{bubbles:!0,cancelable:!0});d.addEventListener(Yv,v=>r?.(v),{once:!0}),Hw(d,m),m.defaultPrevented?h.current=!1:s.onClose()}};return b.createElement(k3,U({},i,{ref:c,disabled:n,onClick:ne(t.onClick,f),onPointerDown:d=>{var m;(m=t.onPointerDown)===null||m===void 0||m.call(t,d),h.current=!0},onPointerUp:ne(t.onPointerUp,d=>{var m;h.current||(m=d.currentTarget)===null||m===void 0||m.click()}),onKeyDown:ne(t.onKeyDown,d=>{const m=a.searchRef.current!=="";n||m&&d.key===" "||M0.includes(d.key)&&(d.currentTarget.click(),d.preventDefault())})}))}),k3=b.forwardRef((t,e)=>{const{__scopeMenu:n,disabled:r=!1,textValue:i,...o}=t,s=Ug(E0,n),a=$3(n),c=b.useRef(null),h=ye(e,c),[f,d]=b.useState(!1),[m,v]=b.useState("");return b.useEffect(()=>{const w=c.current;if(w){var x;v(((x=w.textContent)!==null&&x!==void 0?x:"").trim())}},[o.children]),b.createElement(Ea.ItemSlot,{scope:n,disabled:r,textValue:i??m},b.createElement(Wg,U({asChild:!0},a,{focusable:!r}),b.createElement(me.div,U({role:"menuitem","data-highlighted":f?"":void 0,"aria-disabled":r||void 0,"data-disabled":r?"":void 0},o,{ref:h,onPointerMove:ne(t.onPointerMove,Oa(w=>{r?s.onItemLeave(w):(s.onItemEnter(w),w.defaultPrevented||w.currentTarget.focus())})),onPointerLeave:ne(t.onPointerLeave,Oa(w=>s.onItemLeave(w))),onFocus:ne(t.onFocus,()=>d(!0)),onBlur:ne(t.onBlur,()=>d(!1))}))))}),xj="MenuRadioGroup",[Kee,Gee]=So(xj,{value:void 0,onValueChange:()=>{}}),yj="MenuItemIndicator",[Yee,Xee]=So(yj,{checked:!1}),Cj=b.forwardRef((t,e)=>{const{__scopeMenu:n,...r}=t;return b.createElement(me.div,U({role:"separator","aria-orientation":"horizontal"},r,{ref:e}))}),$j="MenuSub",[Zee,T3]=So($j),xc="MenuSubTrigger",Sj=b.forwardRef((t,e)=>{const n=Ao(xc,t.__scopeMenu),r=ll(xc,t.__scopeMenu),i=T3(xc,t.__scopeMenu),o=Ug(xc,t.__scopeMenu),s=b.useRef(null),{pointerGraceTimerRef:a,onPointerGraceIntentChange:c}=o,h={__scopeMenu:t.__scopeMenu},f=b.useCallback(()=>{s.current&&window.clearTimeout(s.current),s.current=null},[]);return b.useEffect(()=>f,[f]),b.useEffect(()=>{const d=a.current;return()=>{window.clearTimeout(d),c(null)}},[a,c]),b.createElement(S3,U({asChild:!0},h),b.createElement(k3,U({id:i.triggerId,"aria-haspopup":"menu","aria-expanded":n.open,"aria-controls":i.contentId,"data-state":M3(n.open)},t,{ref:Ju(e,i.onTriggerChange),onClick:d=>{var m;(m=t.onClick)===null||m===void 0||m.call(t,d),!(t.disabled||d.defaultPrevented)&&(d.currentTarget.focus(),n.open||n.onOpenChange(!0))},onPointerMove:ne(t.onPointerMove,Oa(d=>{o.onItemEnter(d),!d.defaultPrevented&&!t.disabled&&!n.open&&!s.current&&(o.onPointerGraceIntentChange(null),s.current=window.setTimeout(()=>{n.onOpenChange(!0),f()},100))})),onPointerLeave:ne(t.onPointerLeave,Oa(d=>{var m;f();const v=(m=n.content)===null||m===void 0?void 0:m.getBoundingClientRect();if(v){var w;const x=(w=n.content)===null||w===void 0?void 0:w.dataset.side,C=x==="right",S=C?-5:5,A=v[C?"left":"right"],T=v[C?"right":"left"];o.onPointerGraceIntentChange({area:[{x:d.clientX+S,y:d.clientY},{x:A,y:v.top},{x:T,y:v.top},{x:T,y:v.bottom},{x:A,y:v.bottom}],side:x}),window.clearTimeout(a.current),a.current=window.setTimeout(()=>o.onPointerGraceIntentChange(null),300)}else{if(o.onTriggerLeave(d),d.defaultPrevented)return;o.onPointerGraceIntentChange(null)}})),onKeyDown:ne(t.onKeyDown,d=>{const m=o.searchRef.current!=="";if(!(t.disabled||m&&d.key===" ")&&oj[r.dir].includes(d.key)){var v;n.onOpenChange(!0),(v=n.content)===null||v===void 0||v.focus(),d.preventDefault()}})})))}),Aj="MenuSubContent",Rj=b.forwardRef((t,e)=>{const n=R3(Zn,t.__scopeMenu),{forceMount:r=n.forceMount,...i}=t,o=Ao(Zn,t.__scopeMenu),s=ll(Zn,t.__scopeMenu),a=T3(Aj,t.__scopeMenu),c=b.useRef(null),h=ye(e,c);return b.createElement(Ea.Provider,{scope:t.__scopeMenu},b.createElement(Mt,{present:r||o.open},b.createElement(Ea.Slot,{scope:t.__scopeMenu},b.createElement(qg,U({id:a.contentId,"aria-labelledby":a.triggerId},i,{ref:h,align:"start",side:s.dir==="rtl"?"left":"right",disableOutsidePointerEvents:!1,disableOutsideScroll:!1,trapFocus:!1,onOpenAutoFocus:f=>{var d;s.isUsingKeyboardRef.current&&((d=c.current)===null||d===void 0||d.focus()),f.preventDefault()},onCloseAutoFocus:f=>f.preventDefault(),onFocusOutside:ne(t.onFocusOutside,f=>{f.target!==a.trigger&&o.onOpenChange(!1)}),onEscapeKeyDown:ne(t.onEscapeKeyDown,f=>{s.onClose(),f.preventDefault()}),onKeyDown:ne(t.onKeyDown,f=>{const d=f.currentTarget.contains(f.target),m=sj[s.dir].includes(f.key);if(d&&m){var v;o.onOpenChange(!1),(v=a.trigger)===null||v===void 0||v.focus(),f.preventDefault()}})})))))});function M3(t){return t?"open":"closed"}function kj(t){const e=document.activeElement;for(const n of t)if(n===e||(n.focus(),document.activeElement!==e))return}function Tj(t,e){return t.map((n,r)=>t[(e+r)%t.length])}function Mj(t,e,n){const i=e.length>1&&Array.from(e).every(h=>h===e[0])?e[0]:e,o=n?t.indexOf(n):-1;let s=Tj(t,Math.max(o,0));i.length===1&&(s=s.filter(h=>h!==n));const c=s.find(h=>h.toLowerCase().startsWith(i.toLowerCase()));return c!==n?c:void 0}function Ej(t,e){const{x:n,y:r}=t;let i=!1;for(let o=0,s=e.length-1;o<e.length;s=o++){const a=e[o].x,c=e[o].y,h=e[s].x,f=e[s].y;c>r!=f>r&&n<(h-a)*(r-c)/(f-c)+a&&(i=!i)}return i}function Oj(t,e){if(!e)return!1;const n={x:t.clientX,y:t.clientY};return Ej(n,e)}function Oa(t){return e=>e.pointerType==="mouse"?t(e):void 0}const Dj=hj,Ij=S3,_j=dj,Lj=mj,Bj=bj,Nj=wj,jj=Cj,Fj=Sj,Vj=Rj,E3="DropdownMenu",[Hj,Qee]=bt(E3,[C3]),ii=C3(),[Pj,O3]=Hj(E3),Wj=t=>{const{__scopeDropdownMenu:e,children:n,dir:r,open:i,defaultOpen:o,onOpenChange:s,modal:a=!0}=t,c=ii(e),h=b.useRef(null),[f=!1,d]=_t({prop:i,defaultProp:o,onChange:s});return b.createElement(Pj,{scope:e,triggerId:Lt(),triggerRef:h,contentId:Lt(),open:f,onOpenChange:d,onOpenToggle:b.useCallback(()=>d(m=>!m),[d]),modal:a},b.createElement(Dj,U({},c,{open:f,onOpenChange:d,dir:r,modal:a}),n))},zj="DropdownMenuTrigger",Uj=b.forwardRef((t,e)=>{const{__scopeDropdownMenu:n,disabled:r=!1,...i}=t,o=O3(zj,n),s=ii(n);return b.createElement(Ij,U({asChild:!0},s),b.createElement(me.button,U({type:"button",id:o.triggerId,"aria-haspopup":"menu","aria-expanded":o.open,"aria-controls":o.open?o.contentId:void 0,"data-state":o.open?"open":"closed","data-disabled":r?"":void 0,disabled:r},i,{ref:Ju(e,o.triggerRef),onPointerDown:ne(t.onPointerDown,a=>{!r&&a.button===0&&a.ctrlKey===!1&&(o.onOpenToggle(),o.open||a.preventDefault())}),onKeyDown:ne(t.onKeyDown,a=>{r||(["Enter"," "].includes(a.key)&&o.onOpenToggle(),a.key==="ArrowDown"&&o.onOpenChange(!0),["Enter"," ","ArrowDown"].includes(a.key)&&a.preventDefault())})})))}),qj=t=>{const{__scopeDropdownMenu:e,...n}=t,r=ii(e);return b.createElement(_j,U({},r,n))},Kj="DropdownMenuContent",Gj=b.forwardRef((t,e)=>{const{__scopeDropdownMenu:n,...r}=t,i=O3(Kj,n),o=ii(n),s=b.useRef(!1);return b.createElement(Lj,U({id:i.contentId,"aria-labelledby":i.triggerId},o,r,{ref:e,onCloseAutoFocus:ne(t.onCloseAutoFocus,a=>{var c;s.current||(c=i.triggerRef.current)===null||c===void 0||c.focus(),s.current=!1,a.preventDefault()}),onInteractOutside:ne(t.onInteractOutside,a=>{const c=a.detail.originalEvent,h=c.button===0&&c.ctrlKey===!0,f=c.button===2||h;(!i.modal||f)&&(s.current=!0)}),style:{...t.style,"--radix-dropdown-menu-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-dropdown-menu-content-available-width":"var(--radix-popper-available-width)","--radix-dropdown-menu-content-available-height":"var(--radix-popper-available-height)","--radix-dropdown-menu-trigger-width":"var(--radix-popper-anchor-width)","--radix-dropdown-menu-trigger-height":"var(--radix-popper-anchor-height)"}}))}),Yj=b.forwardRef((t,e)=>{const{__scopeDropdownMenu:n,...r}=t,i=ii(n);return b.createElement(Bj,U({},i,r,{ref:e}))}),Xj=b.forwardRef((t,e)=>{const{__scopeDropdownMenu:n,...r}=t,i=ii(n);return b.createElement(Nj,U({},i,r,{ref:e}))}),Zj=b.forwardRef((t,e)=>{const{__scopeDropdownMenu:n,...r}=t,i=ii(n);return b.createElement(jj,U({},i,r,{ref:e}))}),Qj=b.forwardRef((t,e)=>{const{__scopeDropdownMenu:n,...r}=t,i=ii(n);return b.createElement(Fj,U({},i,r,{ref:e}))}),Jj=b.forwardRef((t,e)=>{const{__scopeDropdownMenu:n,...r}=t,i=ii(n);return b.createElement(Vj,U({},i,r,{ref:e,style:{...t.style,"--radix-dropdown-menu-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-dropdown-menu-content-available-width":"var(--radix-popper-available-width)","--radix-dropdown-menu-content-available-height":"var(--radix-popper-available-height)","--radix-dropdown-menu-trigger-width":"var(--radix-popper-anchor-width)","--radix-dropdown-menu-trigger-height":"var(--radix-popper-anchor-height)"}}))}),eF=Wj,tF=Uj,D3=qj,nF=Gj,rF=Yj,iF=Xj,oF=Zj,sF=Qj,aF=Jj,I3="Checkbox",[lF,Jee]=bt(I3),[cF,uF]=lF(I3),hF=b.forwardRef((t,e)=>{const{__scopeCheckbox:n,name:r,checked:i,defaultChecked:o,required:s,disabled:a,value:c="on",onCheckedChange:h,...f}=t,[d,m]=b.useState(null),v=ye(e,T=>m(T)),w=b.useRef(!1),x=d?!!d.closest("form"):!0,[C=!1,S]=_t({prop:i,defaultProp:o,onChange:h}),A=b.useRef(C);return b.useEffect(()=>{const T=d?.form;if(T){const O=()=>S(A.current);return T.addEventListener("reset",O),()=>T.removeEventListener("reset",O)}},[d,S]),b.createElement(cF,{scope:n,state:C,disabled:a},b.createElement(me.button,U({type:"button",role:"checkbox","aria-checked":so(C)?"mixed":C,"aria-required":s,"data-state":_3(C),"data-disabled":a?"":void 0,disabled:a,value:c},f,{ref:v,onKeyDown:ne(t.onKeyDown,T=>{T.key==="Enter"&&T.preventDefault()}),onClick:ne(t.onClick,T=>{S(O=>so(O)?!0:!O),x&&(w.current=T.isPropagationStopped(),w.current||T.stopPropagation())})})),x&&b.createElement(gF,{control:d,bubbles:!w.current,name:r,value:c,checked:C,required:s,disabled:a,style:{transform:"translateX(-100%)"}}))}),fF="CheckboxIndicator",dF=b.forwardRef((t,e)=>{const{__scopeCheckbox:n,forceMount:r,...i}=t,o=uF(fF,n);return b.createElement(Mt,{present:r||so(o.state)||o.state===!0},b.createElement(me.span,U({"data-state":_3(o.state),"data-disabled":o.disabled?"":void 0},i,{ref:e,style:{pointerEvents:"none",...t.style}})))}),gF=t=>{const{control:e,checked:n,bubbles:r=!0,...i}=t,o=b.useRef(null),s=lh(n),a=rh(e);return b.useEffect(()=>{const c=o.current,h=window.HTMLInputElement.prototype,d=Object.getOwnPropertyDescriptor(h,"checked").set;if(s!==n&&d){const m=new Event("click",{bubbles:r});c.indeterminate=so(n),d.call(c,so(n)?!1:n),c.dispatchEvent(m)}},[s,n,r]),b.createElement("input",U({type:"checkbox","aria-hidden":!0,defaultChecked:so(n)?!1:n},i,{tabIndex:-1,ref:o,style:{...t.style,...a,position:"absolute",pointerEvents:"none",opacity:0,margin:0}}))};function so(t){return t==="indeterminate"}function _3(t){return so(t)?"indeterminate":t?"checked":"unchecked"}const mF=hF,pF=dF,L3="Dialog",[B3,N3]=bt(L3),[vF,rr]=B3(L3),bF=t=>{const{__scopeDialog:e,children:n,open:r,defaultOpen:i,onOpenChange:o,modal:s=!0}=t,a=b.useRef(null),c=b.useRef(null),[h=!1,f]=_t({prop:r,defaultProp:i,onChange:o});return b.createElement(vF,{scope:e,triggerRef:a,contentRef:c,contentId:Lt(),titleId:Lt(),descriptionId:Lt(),open:h,onOpenChange:f,onOpenToggle:b.useCallback(()=>f(d=>!d),[f]),modal:s},n)},wF="DialogTrigger",xF=b.forwardRef((t,e)=>{const{__scopeDialog:n,...r}=t,i=rr(wF,n),o=ye(e,i.triggerRef);return b.createElement(me.button,U({type:"button","aria-haspopup":"dialog","aria-expanded":i.open,"aria-controls":i.contentId,"data-state":Kg(i.open)},r,{ref:o,onClick:ne(t.onClick,i.onOpenToggle)}))}),j3="DialogPortal",[yF,F3]=B3(j3,{forceMount:void 0}),CF=t=>{const{__scopeDialog:e,forceMount:n,children:r,container:i}=t,o=rr(j3,e);return b.createElement(yF,{scope:e,forceMount:n},b.Children.map(r,s=>b.createElement(Mt,{present:n||o.open},b.createElement(Ds,{asChild:!0,container:i},s))))},O0="DialogOverlay",$F=b.forwardRef((t,e)=>{const n=F3(O0,t.__scopeDialog),{forceMount:r=n.forceMount,...i}=t,o=rr(O0,t.__scopeDialog);return o.modal?b.createElement(Mt,{present:r||o.open},b.createElement(SF,U({},i,{ref:e}))):null}),SF=b.forwardRef((t,e)=>{const{__scopeDialog:n,...r}=t,i=rr(O0,n);return b.createElement(mh,{as:Cr,allowPinchZoom:!0,shards:[i.contentRef]},b.createElement(me.div,U({"data-state":Kg(i.open)},r,{ref:e,style:{pointerEvents:"auto",...r.style}})))}),ws="DialogContent",AF=b.forwardRef((t,e)=>{const n=F3(ws,t.__scopeDialog),{forceMount:r=n.forceMount,...i}=t,o=rr(ws,t.__scopeDialog);return b.createElement(Mt,{present:r||o.open},o.modal?b.createElement(RF,U({},i,{ref:e})):b.createElement(kF,U({},i,{ref:e})))}),RF=b.forwardRef((t,e)=>{const n=rr(ws,t.__scopeDialog),r=b.useRef(null),i=ye(e,n.contentRef,r);return b.useEffect(()=>{const o=r.current;if(o)return rl(o)},[]),b.createElement(V3,U({},t,{ref:i,trapFocus:n.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:ne(t.onCloseAutoFocus,o=>{var s;o.preventDefault(),(s=n.triggerRef.current)===null||s===void 0||s.focus()}),onPointerDownOutside:ne(t.onPointerDownOutside,o=>{const s=o.detail.originalEvent,a=s.button===0&&s.ctrlKey===!0;(s.button===2||a)&&o.preventDefault()}),onFocusOutside:ne(t.onFocusOutside,o=>o.preventDefault())}))}),kF=b.forwardRef((t,e)=>{const n=rr(ws,t.__scopeDialog),r=b.useRef(!1),i=b.useRef(!1);return b.createElement(V3,U({},t,{ref:e,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:o=>{var s;if((s=t.onCloseAutoFocus)===null||s===void 0||s.call(t,o),!o.defaultPrevented){var a;r.current||(a=n.triggerRef.current)===null||a===void 0||a.focus(),o.preventDefault()}r.current=!1,i.current=!1},onInteractOutside:o=>{var s,a;(s=t.onInteractOutside)===null||s===void 0||s.call(t,o),o.defaultPrevented||(r.current=!0,o.detail.originalEvent.type==="pointerdown"&&(i.current=!0));const c=o.target;((a=n.triggerRef.current)===null||a===void 0?void 0:a.contains(c))&&o.preventDefault(),o.detail.originalEvent.type==="focusin"&&i.current&&o.preventDefault()}}))}),V3=b.forwardRef((t,e)=>{const{__scopeDialog:n,trapFocus:r,onOpenAutoFocus:i,onCloseAutoFocus:o,...s}=t,a=rr(ws,n),c=b.useRef(null),h=ye(e,c);return Is(),b.createElement(b.Fragment,null,b.createElement(_s,{asChild:!0,loop:!0,trapped:r,onMountAutoFocus:i,onUnmountAutoFocus:o},b.createElement(Co,U({role:"dialog",id:a.contentId,"aria-describedby":a.descriptionId,"aria-labelledby":a.titleId,"data-state":Kg(a.open)},s,{ref:h,onDismiss:()=>a.onOpenChange(!1)}))),!1)}),H3="DialogTitle",TF=b.forwardRef((t,e)=>{const{__scopeDialog:n,...r}=t,i=rr(H3,n);return b.createElement(me.h2,U({id:i.titleId},r,{ref:e}))}),MF="DialogDescription",EF=b.forwardRef((t,e)=>{const{__scopeDialog:n,...r}=t,i=rr(MF,n);return b.createElement(me.p,U({id:i.descriptionId},r,{ref:e}))}),OF="DialogClose",DF=b.forwardRef((t,e)=>{const{__scopeDialog:n,...r}=t,i=rr(OF,n);return b.createElement(me.button,U({type:"button"},r,{ref:e,onClick:ne(t.onClick,()=>i.onOpenChange(!1))}))});function Kg(t){return t?"open":"closed"}const IF="DialogTitleWarning",[_F,ete]=K1(IF,{contentName:ws,titleName:H3,docsSlug:"dialog"}),P3=bF,W3=xF,z3=CF,U3=$F,q3=AF,K3=TF,LF=EF,Gg=DF,BF="AlertDialog",[NF,tte]=bt(BF,[N3]),oi=N3(),jF=t=>{const{__scopeAlertDialog:e,...n}=t,r=oi(e);return b.createElement(P3,U({},r,n,{modal:!0}))},FF=b.forwardRef((t,e)=>{const{__scopeAlertDialog:n,...r}=t,i=oi(n);return b.createElement(W3,U({},i,r,{ref:e}))}),VF=t=>{const{__scopeAlertDialog:e,...n}=t,r=oi(e);return b.createElement(z3,U({},r,n))},HF=b.forwardRef((t,e)=>{const{__scopeAlertDialog:n,...r}=t,i=oi(n);return b.createElement(U3,U({},i,r,{ref:e}))}),G3="AlertDialogContent",[PF,WF]=NF(G3),zF=b.forwardRef((t,e)=>{const{__scopeAlertDialog:n,children:r,...i}=t,o=oi(n),s=b.useRef(null),a=ye(e,s),c=b.useRef(null);return b.createElement(_F,{contentName:G3,titleName:UF,docsSlug:"alert-dialog"},b.createElement(PF,{scope:n,cancelRef:c},b.createElement(q3,U({role:"alertdialog"},o,i,{ref:a,onOpenAutoFocus:ne(i.onOpenAutoFocus,h=>{var f;h.preventDefault(),(f=c.current)===null||f===void 0||f.focus({preventScroll:!0})}),onPointerDownOutside:h=>h.preventDefault(),onInteractOutside:h=>h.preventDefault()}),b.createElement(G1,null,r),!1)))}),UF="AlertDialogTitle",qF=b.forwardRef((t,e)=>{const{__scopeAlertDialog:n,...r}=t,i=oi(n);return b.createElement(K3,U({},i,r,{ref:e}))}),KF=b.forwardRef((t,e)=>{const{__scopeAlertDialog:n,...r}=t,i=oi(n);return b.createElement(LF,U({},i,r,{ref:e}))}),GF=b.forwardRef((t,e)=>{const{__scopeAlertDialog:n,...r}=t,i=oi(n);return b.createElement(Gg,U({},i,r,{ref:e}))}),YF="AlertDialogCancel",XF=b.forwardRef((t,e)=>{const{__scopeAlertDialog:n,...r}=t,{cancelRef:i}=WF(YF,n),o=oi(n),s=ye(e,i);return b.createElement(Gg,U({},o,r,{ref:s}))}),ZF=jF,QF=FF,JF=VF,eV=HF,tV=zF,nV=GF,rV=XF,iV=qF,oV=KF;var Xc=typeof document<"u"?b.useLayoutEffect:b.useEffect;function vu(t,e){if(t===e)return!0;if(typeof t!=typeof e)return!1;if(typeof t=="function"&&t.toString()===e.toString())return!0;let n,r,i;if(t&&e&&typeof t=="object"){if(Array.isArray(t)){if(n=t.length,n!==e.length)return!1;for(r=n;r--!==0;)if(!vu(t[r],e[r]))return!1;return!0}if(i=Object.keys(t),n=i.length,n!==Object.keys(e).length)return!1;for(r=n;r--!==0;)if(!{}.hasOwnProperty.call(e,i[r]))return!1;for(r=n;r--!==0;){const o=i[r];if(!(o==="_owner"&&t.$$typeof)&&!vu(t[o],e[o]))return!1}return!0}return t!==t&&e!==e}function Y3(t){return typeof window>"u"?1:(t.ownerDocument.defaultView||window).devicePixelRatio||1}function Xv(t,e){const n=Y3(t);return Math.round(e*n)/n}function Zv(t){const e=$.useRef(t);return Xc(()=>{e.current=t}),e}function sV(t){t===void 0&&(t={});const{placement:e="bottom",strategy:n="absolute",middleware:r=[],platform:i,elements:{reference:o,floating:s}={},transform:a=!0,whileElementsMounted:c,open:h}=t,[f,d]=$.useState({x:0,y:0,strategy:n,placement:e,middlewareData:{},isPositioned:!1}),[m,v]=$.useState(r);vu(m,r)||v(r);const[w,x]=$.useState(null),[C,S]=$.useState(null),A=$.useCallback(te=>{te!==L.current&&(L.current=te,x(te))},[]),T=$.useCallback(te=>{te!==I.current&&(I.current=te,S(te))},[]),O=o||w,D=s||C,L=$.useRef(null),I=$.useRef(null),V=$.useRef(f),F=c!=null,H=Zv(c),K=Zv(i),W=$.useCallback(()=>{if(!L.current||!I.current)return;const te={placement:e,strategy:n,middleware:m};K.current&&(te.platform=K.current),nx(L.current,I.current,te).then(ie=>{const Y={...ie,isPositioned:!0};J.current&&!vu(V.current,Y)&&(V.current=Y,yo.flushSync(()=>{d(Y)}))})},[m,e,n,K]);Xc(()=>{h===!1&&V.current.isPositioned&&(V.current.isPositioned=!1,d(te=>({...te,isPositioned:!1})))},[h]);const J=$.useRef(!1);Xc(()=>(J.current=!0,()=>{J.current=!1}),[]),Xc(()=>{if(O&&(L.current=O),D&&(I.current=D),O&&D){if(H.current)return H.current(O,D,W);W()}},[O,D,W,H,F]);const G=$.useMemo(()=>({reference:L,floating:I,setReference:A,setFloating:T}),[A,T]),re=$.useMemo(()=>({reference:O,floating:D}),[O,D]),oe=$.useMemo(()=>{const te={position:n,left:0,top:0};if(!re.floating)return te;const ie=Xv(re.floating,f.x),Y=Xv(re.floating,f.y);return a?{...te,transform:"translate("+ie+"px, "+Y+"px)",...Y3(re.floating)>=1.5&&{willChange:"transform"}}:{position:n,left:ie,top:Y}},[n,a,re.floating,f.x,f.y]);return $.useMemo(()=>({...f,update:W,refs:G,elements:re,floatingStyles:oe}),[f,W,G,re,oe])}const aV=(t,e)=>({...Jw(t),options:[t,e]}),lV=(t,e)=>({...ex(t),options:[t,e]}),cV=(t,e)=>({...tx(t),options:[t,e]});var X3=ag(),kd=function(){},vh=$.forwardRef(function(t,e){var n=$.useRef(null),r=$.useState({onScrollCapture:kd,onWheelCapture:kd,onTouchMoveCapture:kd}),i=r[0],o=r[1],s=t.forwardProps,a=t.children,c=t.className,h=t.removeScrollBar,f=t.enabled,d=t.shards,m=t.sideCar,v=t.noIsolation,w=t.inert,x=t.allowPinchZoom,C=t.as,S=C===void 0?"div":C,A=t.gapMode,T=il(t,["forwardProps","children","className","removeScrollBar","enabled","shards","sideCar","noIsolation","inert","allowPinchZoom","as","gapMode"]),O=m,D=sg([n,e]),L=exports.__assign(exports.__assign({},T),i);return $.createElement($.Fragment,null,f&&$.createElement(O,{sideCar:X3,removeScrollBar:h,shards:d,noIsolation:v,inert:w,setCallbacks:o,allowPinchZoom:!!x,lockRef:n,gapMode:A}),s?$.cloneElement($.Children.only(a),exports.__assign(exports.__assign({},L),{ref:D})):$.createElement(S,exports.__assign({},L,{className:c,ref:D}),a))});vh.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1};vh.classNames={fullWidth:os,zeroRight:is};var D0=!1;if(typeof window<"u")try{var yc=Object.defineProperty({},"passive",{get:function(){return D0=!0,!0}});window.addEventListener("test",yc,yc),window.removeEventListener("test",yc,yc)}catch{D0=!1}var Go=D0?{passive:!1}:!1,uV=function(t){return t.tagName==="TEXTAREA"},Z3=function(t,e){if(!(t instanceof Element))return!1;var n=window.getComputedStyle(t);return n[e]!=="hidden"&&!(n.overflowY===n.overflowX&&!uV(t)&&n[e]==="visible")},hV=function(t){return Z3(t,"overflowY")},fV=function(t){return Z3(t,"overflowX")},Qv=function(t,e){var n=e.ownerDocument,r=e;do{typeof ShadowRoot<"u"&&r instanceof ShadowRoot&&(r=r.host);var i=Q3(t,r);if(i){var o=J3(t,r),s=o[1],a=o[2];if(s>a)return!0}r=r.parentNode}while(r&&r!==n.body);return!1},dV=function(t){var e=t.scrollTop,n=t.scrollHeight,r=t.clientHeight;return[e,n,r]},gV=function(t){var e=t.scrollLeft,n=t.scrollWidth,r=t.clientWidth;return[e,n,r]},Q3=function(t,e){return t==="v"?hV(e):fV(e)},J3=function(t,e){return t==="v"?dV(e):gV(e)},mV=function(t,e){return t==="h"&&e==="rtl"?-1:1},pV=function(t,e,n,r,i){var o=mV(t,window.getComputedStyle(e).direction),s=o*r,a=n.target,c=e.contains(a),h=!1,f=s>0,d=0,m=0;do{var v=J3(t,a),w=v[0],x=v[1],C=v[2],S=x-C-o*w;(w||S)&&Q3(t,a)&&(d+=S,m+=w),a instanceof ShadowRoot?a=a.host:a=a.parentNode}while(!c&&a!==document.body||c&&(e.contains(a)||e===a));return(f&&Math.abs(d)<1||!f&&Math.abs(m)<1)&&(h=!0),h},Cc=function(t){return"changedTouches"in t?[t.changedTouches[0].clientX,t.changedTouches[0].clientY]:[0,0]},Jv=function(t){return[t.deltaX,t.deltaY]},e5=function(t){return t&&"current"in t?t.current:t},vV=function(t,e){return t[0]===e[0]&&t[1]===e[1]},bV=function(t){return`
45
- .block-interactivity-`.concat(t,` {pointer-events: none;}
46
- .allow-interactivity-`).concat(t,` {pointer-events: all;}
47
- `)},wV=0,Yo=[];function xV(t){var e=$.useRef([]),n=$.useRef([0,0]),r=$.useRef(),i=$.useState(wV++)[0],o=$.useState(sh)[0],s=$.useRef(t);$.useEffect(function(){s.current=t},[t]),$.useEffect(function(){if(t.inert){document.body.classList.add("block-interactivity-".concat(i));var x=og([t.lockRef.current],(t.shards||[]).map(e5),!0).filter(Boolean);return x.forEach(function(C){return C.classList.add("allow-interactivity-".concat(i))}),function(){document.body.classList.remove("block-interactivity-".concat(i)),x.forEach(function(C){return C.classList.remove("allow-interactivity-".concat(i))})}}},[t.inert,t.lockRef.current,t.shards]);var a=$.useCallback(function(x,C){if("touches"in x&&x.touches.length===2)return!s.current.allowPinchZoom;var S=Cc(x),A=n.current,T="deltaX"in x?x.deltaX:A[0]-S[0],O="deltaY"in x?x.deltaY:A[1]-S[1],D,L=x.target,I=Math.abs(T)>Math.abs(O)?"h":"v";if("touches"in x&&I==="h"&&L.type==="range")return!1;var V=Qv(I,L);if(!V)return!0;if(V?D=I:(D=I==="v"?"h":"v",V=Qv(I,L)),!V)return!1;if(!r.current&&"changedTouches"in x&&(T||O)&&(r.current=D),!D)return!0;var F=r.current||D;return pV(F,C,x,F==="h"?T:O)},[]),c=$.useCallback(function(x){var C=x;if(!(!Yo.length||Yo[Yo.length-1]!==o)){var S="deltaY"in C?Jv(C):Cc(C),A=e.current.filter(function(D){return D.name===C.type&&(D.target===C.target||C.target===D.shadowParent)&&vV(D.delta,S)})[0];if(A&&A.should){C.cancelable&&C.preventDefault();return}if(!A){var T=(s.current.shards||[]).map(e5).filter(Boolean).filter(function(D){return D.contains(C.target)}),O=T.length>0?a(C,T[0]):!s.current.noIsolation;O&&C.cancelable&&C.preventDefault()}}},[]),h=$.useCallback(function(x,C,S,A){var T={name:x,delta:C,target:S,should:A,shadowParent:yV(S)};e.current.push(T),setTimeout(function(){e.current=e.current.filter(function(O){return O!==T})},1)},[]),f=$.useCallback(function(x){n.current=Cc(x),r.current=void 0},[]),d=$.useCallback(function(x){h(x.type,Jv(x),x.target,a(x,t.lockRef.current))},[]),m=$.useCallback(function(x){h(x.type,Cc(x),x.target,a(x,t.lockRef.current))},[]);$.useEffect(function(){return Yo.push(o),t.setCallbacks({onScrollCapture:d,onWheelCapture:d,onTouchMoveCapture:m}),document.addEventListener("wheel",c,Go),document.addEventListener("touchmove",c,Go),document.addEventListener("touchstart",f,Go),function(){Yo=Yo.filter(function(x){return x!==o}),document.removeEventListener("wheel",c,Go),document.removeEventListener("touchmove",c,Go),document.removeEventListener("touchstart",f,Go)}},[]);var v=t.removeScrollBar,w=t.inert;return $.createElement($.Fragment,null,w?$.createElement(o,{styles:bV(i)}):null,v?$.createElement(cg,{gapMode:t.gapMode}):null)}function yV(t){for(var e=null;t!==null;)t instanceof ShadowRoot&&(e=t.host,t=t.host),t=t.parentNode;return e}const CV=lg(X3,xV);var ey=$.forwardRef(function(t,e){return $.createElement(vh,exports.__assign({},t,{ref:e,sideCar:CV}))});ey.classNames=vh.classNames;function $V(t,e){return b.useReducer((n,r)=>{const i=e[n][r];return i??n},t)}const ty="ScrollArea",[ny,nte]=bt(ty),[SV,kr]=ny(ty),AV=b.forwardRef((t,e)=>{const{__scopeScrollArea:n,type:r="hover",dir:i,scrollHideDelay:o=600,...s}=t,[a,c]=b.useState(null),[h,f]=b.useState(null),[d,m]=b.useState(null),[v,w]=b.useState(null),[x,C]=b.useState(null),[S,A]=b.useState(0),[T,O]=b.useState(0),[D,L]=b.useState(!1),[I,V]=b.useState(!1),F=ye(e,K=>c(K)),H=$o(i);return b.createElement(SV,{scope:n,type:r,dir:H,scrollHideDelay:o,scrollArea:a,viewport:h,onViewportChange:f,content:d,onContentChange:m,scrollbarX:v,onScrollbarXChange:w,scrollbarXEnabled:D,onScrollbarXEnabledChange:L,scrollbarY:x,onScrollbarYChange:C,scrollbarYEnabled:I,onScrollbarYEnabledChange:V,onCornerWidthChange:A,onCornerHeightChange:O},b.createElement(me.div,U({dir:H},s,{ref:F,style:{position:"relative","--radix-scroll-area-corner-width":S+"px","--radix-scroll-area-corner-height":T+"px",...t.style}})))}),RV="ScrollAreaViewport",kV=b.forwardRef((t,e)=>{const{__scopeScrollArea:n,children:r,...i}=t,o=kr(RV,n),s=b.useRef(null),a=ye(e,s,o.onViewportChange);return b.createElement(b.Fragment,null,b.createElement("style",{dangerouslySetInnerHTML:{__html:"[data-radix-scroll-area-viewport]{scrollbar-width:none;-ms-overflow-style:none;-webkit-overflow-scrolling:touch;}[data-radix-scroll-area-viewport]::-webkit-scrollbar{display:none}"}}),b.createElement(me.div,U({"data-radix-scroll-area-viewport":""},i,{ref:a,style:{overflowX:o.scrollbarXEnabled?"scroll":"hidden",overflowY:o.scrollbarYEnabled?"scroll":"hidden",...t.style}}),b.createElement("div",{ref:o.onContentChange,style:{minWidth:"100%",display:"table"}},r)))}),si="ScrollAreaScrollbar",TV=b.forwardRef((t,e)=>{const{forceMount:n,...r}=t,i=kr(si,t.__scopeScrollArea),{onScrollbarXEnabledChange:o,onScrollbarYEnabledChange:s}=i,a=t.orientation==="horizontal";return b.useEffect(()=>(a?o(!0):s(!0),()=>{a?o(!1):s(!1)}),[a,o,s]),i.type==="hover"?b.createElement(MV,U({},r,{ref:e,forceMount:n})):i.type==="scroll"?b.createElement(EV,U({},r,{ref:e,forceMount:n})):i.type==="auto"?b.createElement(ry,U({},r,{ref:e,forceMount:n})):i.type==="always"?b.createElement(Yg,U({},r,{ref:e})):null}),MV=b.forwardRef((t,e)=>{const{forceMount:n,...r}=t,i=kr(si,t.__scopeScrollArea),[o,s]=b.useState(!1);return b.useEffect(()=>{const a=i.scrollArea;let c=0;if(a){const h=()=>{window.clearTimeout(c),s(!0)},f=()=>{c=window.setTimeout(()=>s(!1),i.scrollHideDelay)};return a.addEventListener("pointerenter",h),a.addEventListener("pointerleave",f),()=>{window.clearTimeout(c),a.removeEventListener("pointerenter",h),a.removeEventListener("pointerleave",f)}}},[i.scrollArea,i.scrollHideDelay]),b.createElement(Mt,{present:n||o},b.createElement(ry,U({"data-state":o?"visible":"hidden"},r,{ref:e})))}),EV=b.forwardRef((t,e)=>{const{forceMount:n,...r}=t,i=kr(si,t.__scopeScrollArea),o=t.orientation==="horizontal",s=wh(()=>c("SCROLL_END"),100),[a,c]=$V("hidden",{hidden:{SCROLL:"scrolling"},scrolling:{SCROLL_END:"idle",POINTER_ENTER:"interacting"},interacting:{SCROLL:"interacting",POINTER_LEAVE:"idle"},idle:{HIDE:"hidden",SCROLL:"scrolling",POINTER_ENTER:"interacting"}});return b.useEffect(()=>{if(a==="idle"){const h=window.setTimeout(()=>c("HIDE"),i.scrollHideDelay);return()=>window.clearTimeout(h)}},[a,i.scrollHideDelay,c]),b.useEffect(()=>{const h=i.viewport,f=o?"scrollLeft":"scrollTop";if(h){let d=h[f];const m=()=>{const v=h[f];d!==v&&(c("SCROLL"),s()),d=v};return h.addEventListener("scroll",m),()=>h.removeEventListener("scroll",m)}},[i.viewport,o,c,s]),b.createElement(Mt,{present:n||a!=="hidden"},b.createElement(Yg,U({"data-state":a==="hidden"?"hidden":"visible"},r,{ref:e,onPointerEnter:ne(t.onPointerEnter,()=>c("POINTER_ENTER")),onPointerLeave:ne(t.onPointerLeave,()=>c("POINTER_LEAVE"))})))}),ry=b.forwardRef((t,e)=>{const n=kr(si,t.__scopeScrollArea),{forceMount:r,...i}=t,[o,s]=b.useState(!1),a=t.orientation==="horizontal",c=wh(()=>{if(n.viewport){const h=n.viewport.offsetWidth<n.viewport.scrollWidth,f=n.viewport.offsetHeight<n.viewport.scrollHeight;s(a?h:f)}},10);return wu(n.viewport,c),wu(n.content,c),b.createElement(Mt,{present:r||o},b.createElement(Yg,U({"data-state":o?"visible":"hidden"},i,{ref:e})))}),Yg=b.forwardRef((t,e)=>{const{orientation:n="vertical",...r}=t,i=kr(si,t.__scopeScrollArea),o=b.useRef(null),s=b.useRef(0),[a,c]=b.useState({content:0,viewport:0,scrollbar:{size:0,paddingStart:0,paddingEnd:0}}),h=sy(a.viewport,a.content),f={...r,sizes:a,onSizesChange:c,hasThumb:h>0&&h<1,onThumbChange:m=>o.current=m,onThumbPointerUp:()=>s.current=0,onThumbPointerDown:m=>s.current=m};function d(m,v){return BV(m,s.current,a,v)}return n==="horizontal"?b.createElement(OV,U({},f,{ref:e,onThumbPositionChange:()=>{if(i.viewport&&o.current){const m=i.viewport.scrollLeft,v=t5(m,a,i.dir);o.current.style.transform=`translate3d(${v}px, 0, 0)`}},onWheelScroll:m=>{i.viewport&&(i.viewport.scrollLeft=m)},onDragScroll:m=>{i.viewport&&(i.viewport.scrollLeft=d(m,i.dir))}})):n==="vertical"?b.createElement(DV,U({},f,{ref:e,onThumbPositionChange:()=>{if(i.viewport&&o.current){const m=i.viewport.scrollTop,v=t5(m,a);o.current.style.transform=`translate3d(0, ${v}px, 0)`}},onWheelScroll:m=>{i.viewport&&(i.viewport.scrollTop=m)},onDragScroll:m=>{i.viewport&&(i.viewport.scrollTop=d(m))}})):null}),OV=b.forwardRef((t,e)=>{const{sizes:n,onSizesChange:r,...i}=t,o=kr(si,t.__scopeScrollArea),[s,a]=b.useState(),c=b.useRef(null),h=ye(e,c,o.onScrollbarXChange);return b.useEffect(()=>{c.current&&a(getComputedStyle(c.current))},[c]),b.createElement(oy,U({"data-orientation":"horizontal"},i,{ref:h,sizes:n,style:{bottom:0,left:o.dir==="rtl"?"var(--radix-scroll-area-corner-width)":0,right:o.dir==="ltr"?"var(--radix-scroll-area-corner-width)":0,"--radix-scroll-area-thumb-width":bh(n)+"px",...t.style},onThumbPointerDown:f=>t.onThumbPointerDown(f.x),onDragScroll:f=>t.onDragScroll(f.x),onWheelScroll:(f,d)=>{if(o.viewport){const m=o.viewport.scrollLeft+f.deltaX;t.onWheelScroll(m),ly(m,d)&&f.preventDefault()}},onResize:()=>{c.current&&o.viewport&&s&&r({content:o.viewport.scrollWidth,viewport:o.viewport.offsetWidth,scrollbar:{size:c.current.clientWidth,paddingStart:bu(s.paddingLeft),paddingEnd:bu(s.paddingRight)}})}}))}),DV=b.forwardRef((t,e)=>{const{sizes:n,onSizesChange:r,...i}=t,o=kr(si,t.__scopeScrollArea),[s,a]=b.useState(),c=b.useRef(null),h=ye(e,c,o.onScrollbarYChange);return b.useEffect(()=>{c.current&&a(getComputedStyle(c.current))},[c]),b.createElement(oy,U({"data-orientation":"vertical"},i,{ref:h,sizes:n,style:{top:0,right:o.dir==="ltr"?0:void 0,left:o.dir==="rtl"?0:void 0,bottom:"var(--radix-scroll-area-corner-height)","--radix-scroll-area-thumb-height":bh(n)+"px",...t.style},onThumbPointerDown:f=>t.onThumbPointerDown(f.y),onDragScroll:f=>t.onDragScroll(f.y),onWheelScroll:(f,d)=>{if(o.viewport){const m=o.viewport.scrollTop+f.deltaY;t.onWheelScroll(m),ly(m,d)&&f.preventDefault()}},onResize:()=>{c.current&&o.viewport&&s&&r({content:o.viewport.scrollHeight,viewport:o.viewport.offsetHeight,scrollbar:{size:c.current.clientHeight,paddingStart:bu(s.paddingTop),paddingEnd:bu(s.paddingBottom)}})}}))}),[IV,iy]=ny(si),oy=b.forwardRef((t,e)=>{const{__scopeScrollArea:n,sizes:r,hasThumb:i,onThumbChange:o,onThumbPointerUp:s,onThumbPointerDown:a,onThumbPositionChange:c,onDragScroll:h,onWheelScroll:f,onResize:d,...m}=t,v=kr(si,n),[w,x]=b.useState(null),C=ye(e,F=>x(F)),S=b.useRef(null),A=b.useRef(""),T=v.viewport,O=r.content-r.viewport,D=Ct(f),L=Ct(c),I=wh(d,10);function V(F){if(S.current){const H=F.clientX-S.current.left,K=F.clientY-S.current.top;h({x:H,y:K})}}return b.useEffect(()=>{const F=H=>{const K=H.target;w?.contains(K)&&D(H,O)};return document.addEventListener("wheel",F,{passive:!1}),()=>document.removeEventListener("wheel",F,{passive:!1})},[T,w,O,D]),b.useEffect(L,[r,L]),wu(w,I),wu(v.content,I),b.createElement(IV,{scope:n,scrollbar:w,hasThumb:i,onThumbChange:Ct(o),onThumbPointerUp:Ct(s),onThumbPositionChange:L,onThumbPointerDown:Ct(a)},b.createElement(me.div,U({},m,{ref:C,style:{position:"absolute",...m.style},onPointerDown:ne(t.onPointerDown,F=>{F.button===0&&(F.target.setPointerCapture(F.pointerId),S.current=w.getBoundingClientRect(),A.current=document.body.style.webkitUserSelect,document.body.style.webkitUserSelect="none",v.viewport&&(v.viewport.style.scrollBehavior="auto"),V(F))}),onPointerMove:ne(t.onPointerMove,V),onPointerUp:ne(t.onPointerUp,F=>{const H=F.target;H.hasPointerCapture(F.pointerId)&&H.releasePointerCapture(F.pointerId),document.body.style.webkitUserSelect=A.current,v.viewport&&(v.viewport.style.scrollBehavior=""),S.current=null})})))}),I0="ScrollAreaThumb",_V=b.forwardRef((t,e)=>{const{forceMount:n,...r}=t,i=iy(I0,t.__scopeScrollArea);return b.createElement(Mt,{present:n||i.hasThumb},b.createElement(LV,U({ref:e},r)))}),LV=b.forwardRef((t,e)=>{const{__scopeScrollArea:n,style:r,...i}=t,o=kr(I0,n),s=iy(I0,n),{onThumbPositionChange:a}=s,c=ye(e,d=>s.onThumbChange(d)),h=b.useRef(),f=wh(()=>{h.current&&(h.current(),h.current=void 0)},100);return b.useEffect(()=>{const d=o.viewport;if(d){const m=()=>{if(f(),!h.current){const v=NV(d,a);h.current=v,a()}};return a(),d.addEventListener("scroll",m),()=>d.removeEventListener("scroll",m)}},[o.viewport,f,a]),b.createElement(me.div,U({"data-state":s.hasThumb?"visible":"hidden"},i,{ref:c,style:{width:"var(--radix-scroll-area-thumb-width)",height:"var(--radix-scroll-area-thumb-height)",...r},onPointerDownCapture:ne(t.onPointerDownCapture,d=>{const v=d.target.getBoundingClientRect(),w=d.clientX-v.left,x=d.clientY-v.top;s.onThumbPointerDown({x:w,y:x})}),onPointerUp:ne(t.onPointerUp,s.onThumbPointerUp)}))});function bu(t){return t?parseInt(t,10):0}function sy(t,e){const n=t/e;return isNaN(n)?0:n}function bh(t){const e=sy(t.viewport,t.content),n=t.scrollbar.paddingStart+t.scrollbar.paddingEnd,r=(t.scrollbar.size-n)*e;return Math.max(r,18)}function BV(t,e,n,r="ltr"){const i=bh(n),o=i/2,s=e||o,a=i-s,c=n.scrollbar.paddingStart+s,h=n.scrollbar.size-n.scrollbar.paddingEnd-a,f=n.content-n.viewport,d=r==="ltr"?[0,f]:[f*-1,0];return ay([c,h],d)(t)}function t5(t,e,n="ltr"){const r=bh(e),i=e.scrollbar.paddingStart+e.scrollbar.paddingEnd,o=e.scrollbar.size-i,s=e.content-e.viewport,a=o-r,c=n==="ltr"?[0,s]:[s*-1,0],h=w0(t,c);return ay([0,s],[0,a])(h)}function ay(t,e){return n=>{if(t[0]===t[1]||e[0]===e[1])return e[0];const r=(e[1]-e[0])/(t[1]-t[0]);return e[0]+r*(n-t[0])}}function ly(t,e){return t>0&&t<e}const NV=(t,e=()=>{})=>{let n={left:t.scrollLeft,top:t.scrollTop},r=0;return function i(){const o={left:t.scrollLeft,top:t.scrollTop},s=n.left!==o.left,a=n.top!==o.top;(s||a)&&e(),n=o,r=window.requestAnimationFrame(i)}(),()=>window.cancelAnimationFrame(r)};function wh(t,e){const n=Ct(t),r=b.useRef(0);return b.useEffect(()=>()=>window.clearTimeout(r.current),[]),b.useCallback(()=>{window.clearTimeout(r.current),r.current=window.setTimeout(n,e)},[n,e])}function wu(t,e){const n=Ct(e);ut(()=>{let r=0;if(t){const i=new ResizeObserver(()=>{cancelAnimationFrame(r),r=window.requestAnimationFrame(n)});return i.observe(t),()=>{window.cancelAnimationFrame(r),i.unobserve(t)}}},[t,n])}const jV=AV,FV=kV,VV=TV,HV=_V,cy=1024;let PV=0,Td=class{constructor(e,n){this.from=e,this.to=n}};class je{constructor(e={}){this.id=PV++,this.perNode=!!e.perNode,this.deserialize=e.deserialize||(()=>{throw new Error("This node type doesn't define a deserialize function")})}add(e){if(this.perNode)throw new RangeError("Can't add per-node props to node types");return typeof e!="function"&&(e=dn.match(e)),n=>{let r=e(n);return r===void 0?null:[this,r]}}}je.closedBy=new je({deserialize:t=>t.split(" ")});je.openedBy=new je({deserialize:t=>t.split(" ")});je.group=new je({deserialize:t=>t.split(" ")});je.isolate=new je({deserialize:t=>{if(t&&t!="rtl"&&t!="ltr"&&t!="auto")throw new RangeError("Invalid value for isolate: "+t);return t||"auto"}});je.contextHash=new je({perNode:!0});je.lookAhead=new je({perNode:!0});je.mounted=new je({perNode:!0});class xu{constructor(e,n,r){this.tree=e,this.overlay=n,this.parser=r}static get(e){return e&&e.props&&e.props[je.mounted.id]}}const WV=Object.create(null);class dn{constructor(e,n,r,i=0){this.name=e,this.props=n,this.id=r,this.flags=i}static define(e){let n=e.props&&e.props.length?Object.create(null):WV,r=(e.top?1:0)|(e.skipped?2:0)|(e.error?4:0)|(e.name==null?8:0),i=new dn(e.name||"",n,e.id,r);if(e.props){for(let o of e.props)if(Array.isArray(o)||(o=o(i)),o){if(o[0].perNode)throw new RangeError("Can't store a per-node prop on a node type");n[o[0].id]=o[1]}}return i}prop(e){return this.props[e.id]}get isTop(){return(this.flags&1)>0}get isSkipped(){return(this.flags&2)>0}get isError(){return(this.flags&4)>0}get isAnonymous(){return(this.flags&8)>0}is(e){if(typeof e=="string"){if(this.name==e)return!0;let n=this.prop(je.group);return n?n.indexOf(e)>-1:!1}return this.id==e}static match(e){let n=Object.create(null);for(let r in e)for(let i of r.split(" "))n[i]=e[r];return r=>{for(let i=r.prop(je.group),o=-1;o<(i?i.length:0);o++){let s=n[o<0?r.name:i[o]];if(s)return s}}}}dn.none=new dn("",Object.create(null),0,8);class Xg{constructor(e){this.types=e;for(let n=0;n<e.length;n++)if(e[n].id!=n)throw new RangeError("Node type ids should correspond to array positions when creating a node set")}extend(...e){let n=[];for(let r of this.types){let i=null;for(let o of e){let s=o(r);s&&(i||(i=Object.assign({},r.props)),i[s[0].id]=s[1])}n.push(i?new dn(r.name,i,r.id,r.flags):r)}return new Xg(n)}}const $c=new WeakMap,n5=new WeakMap;var Dt;(function(t){t[t.ExcludeBuffers=1]="ExcludeBuffers",t[t.IncludeAnonymous=2]="IncludeAnonymous",t[t.IgnoreMounts=4]="IgnoreMounts",t[t.IgnoreOverlays=8]="IgnoreOverlays"})(Dt||(Dt={}));class $t{constructor(e,n,r,i,o){if(this.type=e,this.children=n,this.positions=r,this.length=i,this.props=null,o&&o.length){this.props=Object.create(null);for(let[s,a]of o)this.props[typeof s=="number"?s:s.id]=a}}toString(){let e=xu.get(this);if(e&&!e.overlay)return e.tree.toString();let n="";for(let r of this.children){let i=r.toString();i&&(n&&(n+=","),n+=i)}return this.type.name?(/\W/.test(this.type.name)&&!this.type.isError?JSON.stringify(this.type.name):this.type.name)+(n.length?"("+n+")":""):n}cursor(e=0){return new L0(this.topNode,e)}cursorAt(e,n=0,r=0){let i=$c.get(this)||this.topNode,o=new L0(i);return o.moveTo(e,n),$c.set(this,o._tree),o}get topNode(){return new Fn(this,0,0,null)}resolve(e,n=0){let r=Da($c.get(this)||this.topNode,e,n,!1);return $c.set(this,r),r}resolveInner(e,n=0){let r=Da(n5.get(this)||this.topNode,e,n,!0);return n5.set(this,r),r}resolveStack(e,n=0){return qV(this,e,n)}iterate(e){let{enter:n,leave:r,from:i=0,to:o=this.length}=e,s=e.mode||0,a=(s&Dt.IncludeAnonymous)>0;for(let c=this.cursor(s|Dt.IncludeAnonymous);;){let h=!1;if(c.from<=o&&c.to>=i&&(!a&&c.type.isAnonymous||n(c)!==!1)){if(c.firstChild())continue;h=!0}for(;h&&r&&(a||!c.type.isAnonymous)&&r(c),!c.nextSibling();){if(!c.parent())return;h=!0}}}prop(e){return e.perNode?this.props?this.props[e.id]:void 0:this.type.prop(e)}get propValues(){let e=[];if(this.props)for(let n in this.props)e.push([+n,this.props[n]]);return e}balance(e={}){return this.children.length<=8?this:Jg(dn.none,this.children,this.positions,0,this.children.length,0,this.length,(n,r,i)=>new $t(this.type,n,r,i,this.propValues),e.makeTree||((n,r,i)=>new $t(dn.none,n,r,i)))}static build(e){return KV(e)}}$t.empty=new $t(dn.none,[],[],0);class Zg{constructor(e,n){this.buffer=e,this.index=n}get id(){return this.buffer[this.index-4]}get start(){return this.buffer[this.index-3]}get end(){return this.buffer[this.index-2]}get size(){return this.buffer[this.index-1]}get pos(){return this.index}next(){this.index-=4}fork(){return new Zg(this.buffer,this.index)}}class Ei{constructor(e,n,r){this.buffer=e,this.length=n,this.set=r}get type(){return dn.none}toString(){let e=[];for(let n=0;n<this.buffer.length;)e.push(this.childString(n)),n=this.buffer[n+3];return e.join(",")}childString(e){let n=this.buffer[e],r=this.buffer[e+3],i=this.set.types[n],o=i.name;if(/\W/.test(o)&&!i.isError&&(o=JSON.stringify(o)),e+=4,r==e)return o;let s=[];for(;e<r;)s.push(this.childString(e)),e=this.buffer[e+3];return o+"("+s.join(",")+")"}findChild(e,n,r,i,o){let{buffer:s}=this,a=-1;for(let c=e;c!=n&&!(uy(o,i,s[c+1],s[c+2])&&(a=c,r>0));c=s[c+3]);return a}slice(e,n,r){let i=this.buffer,o=new Uint16Array(n-e),s=0;for(let a=e,c=0;a<n;){o[c++]=i[a++],o[c++]=i[a++]-r;let h=o[c++]=i[a++]-r;o[c++]=i[a++]-e,s=Math.max(s,h)}return new Ei(o,s,this.set)}}function uy(t,e,n,r){switch(t){case-2:return n<e;case-1:return r>=e&&n<e;case 0:return n<e&&r>e;case 1:return n<=e&&r>e;case 2:return r>e;case 4:return!0}}function Da(t,e,n,r){for(var i;t.from==t.to||(n<1?t.from>=e:t.from>e)||(n>-1?t.to<=e:t.to<e);){let s=!r&&t instanceof Fn&&t.index<0?null:t.parent;if(!s)return t;t=s}let o=r?0:Dt.IgnoreOverlays;if(r)for(let s=t,a=s.parent;a;s=a,a=s.parent)s instanceof Fn&&s.index<0&&((i=a.enter(e,n,o))===null||i===void 0?void 0:i.from)!=s.from&&(t=a);for(;;){let s=t.enter(e,n,o);if(!s)return t;t=s}}class hy{cursor(e=0){return new L0(this,e)}getChild(e,n=null,r=null){let i=r5(this,e,n,r);return i.length?i[0]:null}getChildren(e,n=null,r=null){return r5(this,e,n,r)}resolve(e,n=0){return Da(this,e,n,!1)}resolveInner(e,n=0){return Da(this,e,n,!0)}matchContext(e){return _0(this.parent,e)}enterUnfinishedNodesBefore(e){let n=this.childBefore(e),r=this;for(;n;){let i=n.lastChild;if(!i||i.to!=n.to)break;i.type.isError&&i.from==i.to?(r=n,n=i.prevSibling):n=i}return r}get node(){return this}get next(){return this.parent}}class Fn extends hy{constructor(e,n,r,i){super(),this._tree=e,this.from=n,this.index=r,this._parent=i}get type(){return this._tree.type}get name(){return this._tree.type.name}get to(){return this.from+this._tree.length}nextChild(e,n,r,i,o=0){for(let s=this;;){for(let{children:a,positions:c}=s._tree,h=n>0?a.length:-1;e!=h;e+=n){let f=a[e],d=c[e]+s.from;if(uy(i,r,d,d+f.length)){if(f instanceof Ei){if(o&Dt.ExcludeBuffers)continue;let m=f.findChild(0,f.buffer.length,n,r-d,i);if(m>-1)return new yi(new zV(s,f,e,d),null,m)}else if(o&Dt.IncludeAnonymous||!f.type.isAnonymous||Qg(f)){let m;if(!(o&Dt.IgnoreMounts)&&(m=xu.get(f))&&!m.overlay)return new Fn(m.tree,d,e,s);let v=new Fn(f,d,e,s);return o&Dt.IncludeAnonymous||!v.type.isAnonymous?v:v.nextChild(n<0?f.children.length-1:0,n,r,i)}}}if(o&Dt.IncludeAnonymous||!s.type.isAnonymous||(s.index>=0?e=s.index+n:e=n<0?-1:s._parent._tree.children.length,s=s._parent,!s))return null}}get firstChild(){return this.nextChild(0,1,0,4)}get lastChild(){return this.nextChild(this._tree.children.length-1,-1,0,4)}childAfter(e){return this.nextChild(0,1,e,2)}childBefore(e){return this.nextChild(this._tree.children.length-1,-1,e,-2)}enter(e,n,r=0){let i;if(!(r&Dt.IgnoreOverlays)&&(i=xu.get(this._tree))&&i.overlay){let o=e-this.from;for(let{from:s,to:a}of i.overlay)if((n>0?s<=o:s<o)&&(n<0?a>=o:a>o))return new Fn(i.tree,i.overlay[0].from+this.from,-1,this)}return this.nextChild(0,1,e,n,r)}nextSignificantParent(){let e=this;for(;e.type.isAnonymous&&e._parent;)e=e._parent;return e}get parent(){return this._parent?this._parent.nextSignificantParent():null}get nextSibling(){return this._parent&&this.index>=0?this._parent.nextChild(this.index+1,1,0,4):null}get prevSibling(){return this._parent&&this.index>=0?this._parent.nextChild(this.index-1,-1,0,4):null}get tree(){return this._tree}toTree(){return this._tree}toString(){return this._tree.toString()}}function r5(t,e,n,r){let i=t.cursor(),o=[];if(!i.firstChild())return o;if(n!=null){for(let s=!1;!s;)if(s=i.type.is(n),!i.nextSibling())return o}for(;;){if(r!=null&&i.type.is(r))return o;if(i.type.is(e)&&o.push(i.node),!i.nextSibling())return r==null?o:[]}}function _0(t,e,n=e.length-1){for(let r=t;n>=0;r=r.parent){if(!r)return!1;if(!r.type.isAnonymous){if(e[n]&&e[n]!=r.name)return!1;n--}}return!0}class zV{constructor(e,n,r,i){this.parent=e,this.buffer=n,this.index=r,this.start=i}}class yi extends hy{get name(){return this.type.name}get from(){return this.context.start+this.context.buffer.buffer[this.index+1]}get to(){return this.context.start+this.context.buffer.buffer[this.index+2]}constructor(e,n,r){super(),this.context=e,this._parent=n,this.index=r,this.type=e.buffer.set.types[e.buffer.buffer[r]]}child(e,n,r){let{buffer:i}=this.context,o=i.findChild(this.index+4,i.buffer[this.index+3],e,n-this.context.start,r);return o<0?null:new yi(this.context,this,o)}get firstChild(){return this.child(1,0,4)}get lastChild(){return this.child(-1,0,4)}childAfter(e){return this.child(1,e,2)}childBefore(e){return this.child(-1,e,-2)}enter(e,n,r=0){if(r&Dt.ExcludeBuffers)return null;let{buffer:i}=this.context,o=i.findChild(this.index+4,i.buffer[this.index+3],n>0?1:-1,e-this.context.start,n);return o<0?null:new yi(this.context,this,o)}get parent(){return this._parent||this.context.parent.nextSignificantParent()}externalSibling(e){return this._parent?null:this.context.parent.nextChild(this.context.index+e,e,0,4)}get nextSibling(){let{buffer:e}=this.context,n=e.buffer[this.index+3];return n<(this._parent?e.buffer[this._parent.index+3]:e.buffer.length)?new yi(this.context,this._parent,n):this.externalSibling(1)}get prevSibling(){let{buffer:e}=this.context,n=this._parent?this._parent.index+4:0;return this.index==n?this.externalSibling(-1):new yi(this.context,this._parent,e.findChild(n,this.index,-1,0,4))}get tree(){return null}toTree(){let e=[],n=[],{buffer:r}=this.context,i=this.index+4,o=r.buffer[this.index+3];if(o>i){let s=r.buffer[this.index+1];e.push(r.slice(i,o,s)),n.push(0)}return new $t(this.type,e,n,this.to-this.from)}toString(){return this.context.buffer.childString(this.index)}}function fy(t){if(!t.length)return null;let e=0,n=t[0];for(let o=1;o<t.length;o++){let s=t[o];(s.from>n.from||s.to<n.to)&&(n=s,e=o)}let r=n instanceof Fn&&n.index<0?null:n.parent,i=t.slice();return r?i[e]=r:i.splice(e,1),new UV(i,n)}class UV{constructor(e,n){this.heads=e,this.node=n}get next(){return fy(this.heads)}}function qV(t,e,n){let r=t.resolveInner(e,n),i=null;for(let o=r instanceof Fn?r:r.context.parent;o;o=o.parent)if(o.index<0){let s=o.parent;(i||(i=[r])).push(s.resolve(e,n)),o=s}else{let s=xu.get(o.tree);if(s&&s.overlay&&s.overlay[0].from<=e&&s.overlay[s.overlay.length-1].to>=e){let a=new Fn(s.tree,s.overlay[0].from+o.from,-1,o);(i||(i=[r])).push(Da(a,e,n,!1))}}return i?fy(i):r}class L0{get name(){return this.type.name}constructor(e,n=0){if(this.mode=n,this.buffer=null,this.stack=[],this.index=0,this.bufferNode=null,e instanceof Fn)this.yieldNode(e);else{this._tree=e.context.parent,this.buffer=e.context;for(let r=e._parent;r;r=r._parent)this.stack.unshift(r.index);this.bufferNode=e,this.yieldBuf(e.index)}}yieldNode(e){return e?(this._tree=e,this.type=e.type,this.from=e.from,this.to=e.to,!0):!1}yieldBuf(e,n){this.index=e;let{start:r,buffer:i}=this.buffer;return this.type=n||i.set.types[i.buffer[e]],this.from=r+i.buffer[e+1],this.to=r+i.buffer[e+2],!0}yield(e){return e?e instanceof Fn?(this.buffer=null,this.yieldNode(e)):(this.buffer=e.context,this.yieldBuf(e.index,e.type)):!1}toString(){return this.buffer?this.buffer.buffer.childString(this.index):this._tree.toString()}enterChild(e,n,r){if(!this.buffer)return this.yield(this._tree.nextChild(e<0?this._tree._tree.children.length-1:0,e,n,r,this.mode));let{buffer:i}=this.buffer,o=i.findChild(this.index+4,i.buffer[this.index+3],e,n-this.buffer.start,r);return o<0?!1:(this.stack.push(this.index),this.yieldBuf(o))}firstChild(){return this.enterChild(1,0,4)}lastChild(){return this.enterChild(-1,0,4)}childAfter(e){return this.enterChild(1,e,2)}childBefore(e){return this.enterChild(-1,e,-2)}enter(e,n,r=this.mode){return this.buffer?r&Dt.ExcludeBuffers?!1:this.enterChild(1,e,n):this.yield(this._tree.enter(e,n,r))}parent(){if(!this.buffer)return this.yieldNode(this.mode&Dt.IncludeAnonymous?this._tree._parent:this._tree.parent);if(this.stack.length)return this.yieldBuf(this.stack.pop());let e=this.mode&Dt.IncludeAnonymous?this.buffer.parent:this.buffer.parent.nextSignificantParent();return this.buffer=null,this.yieldNode(e)}sibling(e){if(!this.buffer)return this._tree._parent?this.yield(this._tree.index<0?null:this._tree._parent.nextChild(this._tree.index+e,e,0,4,this.mode)):!1;let{buffer:n}=this.buffer,r=this.stack.length-1;if(e<0){let i=r<0?0:this.stack[r]+4;if(this.index!=i)return this.yieldBuf(n.findChild(i,this.index,-1,0,4))}else{let i=n.buffer[this.index+3];if(i<(r<0?n.buffer.length:n.buffer[this.stack[r]+3]))return this.yieldBuf(i)}return r<0?this.yield(this.buffer.parent.nextChild(this.buffer.index+e,e,0,4,this.mode)):!1}nextSibling(){return this.sibling(1)}prevSibling(){return this.sibling(-1)}atLastNode(e){let n,r,{buffer:i}=this;if(i){if(e>0){if(this.index<i.buffer.buffer.length)return!1}else for(let o=0;o<this.index;o++)if(i.buffer.buffer[o+3]<this.index)return!1;({index:n,parent:r}=i)}else({index:n,_parent:r}=this._tree);for(;r;{index:n,_parent:r}=r)if(n>-1)for(let o=n+e,s=e<0?-1:r._tree.children.length;o!=s;o+=e){let a=r._tree.children[o];if(this.mode&Dt.IncludeAnonymous||a instanceof Ei||!a.type.isAnonymous||Qg(a))return!1}return!0}move(e,n){if(n&&this.enterChild(e,0,4))return!0;for(;;){if(this.sibling(e))return!0;if(this.atLastNode(e)||!this.parent())return!1}}next(e=!0){return this.move(1,e)}prev(e=!0){return this.move(-1,e)}moveTo(e,n=0){for(;(this.from==this.to||(n<1?this.from>=e:this.from>e)||(n>-1?this.to<=e:this.to<e))&&this.parent(););for(;this.enterChild(1,e,n););return this}get node(){if(!this.buffer)return this._tree;let e=this.bufferNode,n=null,r=0;if(e&&e.context==this.buffer)e:for(let i=this.index,o=this.stack.length;o>=0;){for(let s=e;s;s=s._parent)if(s.index==i){if(i==this.index)return s;n=s,r=o+1;break e}i=this.stack[--o]}for(let i=r;i<this.stack.length;i++)n=new yi(this.buffer,n,this.stack[i]);return this.bufferNode=new yi(this.buffer,n,this.index)}get tree(){return this.buffer?null:this._tree._tree}iterate(e,n){for(let r=0;;){let i=!1;if(this.type.isAnonymous||e(this)!==!1){if(this.firstChild()){r++;continue}this.type.isAnonymous||(i=!0)}for(;;){if(i&&n&&n(this),i=this.type.isAnonymous,!r)return;if(this.nextSibling())break;this.parent(),r--,i=!0}}}matchContext(e){if(!this.buffer)return _0(this.node.parent,e);let{buffer:n}=this.buffer,{types:r}=n.set;for(let i=e.length-1,o=this.stack.length-1;i>=0;o--){if(o<0)return _0(this._tree,e,i);let s=r[n.buffer[this.stack[o]]];if(!s.isAnonymous){if(e[i]&&e[i]!=s.name)return!1;i--}}return!0}}function Qg(t){return t.children.some(e=>e instanceof Ei||!e.type.isAnonymous||Qg(e))}function KV(t){var e;let{buffer:n,nodeSet:r,maxBufferLength:i=cy,reused:o=[],minRepeatType:s=r.types.length}=t,a=Array.isArray(n)?new Zg(n,n.length):n,c=r.types,h=0,f=0;function d(D,L,I,V,F,H){let{id:K,start:W,end:J,size:G}=a,re=f,oe=h;for(;G<0;)if(a.next(),G==-1){let ge=o[K];I.push(ge),V.push(W-D);return}else if(G==-3){h=K;return}else if(G==-4){f=K;return}else throw new RangeError(`Unrecognized record size: ${G}`);let te=c[K],ie,Y,ue=W-D;if(J-W<=i&&(Y=C(a.pos-L,F))){let ge=new Uint16Array(Y.size-Y.skip),De=a.pos-Y.size,we=ge.length;for(;a.pos>De;)we=S(Y.start,ge,we);ie=new Ei(ge,J-Y.start,r),ue=Y.start-D}else{let ge=a.pos-G;a.next();let De=[],we=[],Ve=K>=s?K:-1,Ne=0,He=J;for(;a.pos>ge;)Ve>=0&&a.id==Ve&&a.size>=0?(a.end<=He-i&&(w(De,we,W,Ne,a.end,He,Ve,re,oe),Ne=De.length,He=a.end),a.next()):H>2500?m(W,ge,De,we):d(W,ge,De,we,Ve,H+1);if(Ve>=0&&Ne>0&&Ne<De.length&&w(De,we,W,Ne,W,He,Ve,re,oe),De.reverse(),we.reverse(),Ve>-1&&Ne>0){let pe=v(te,oe);ie=Jg(te,De,we,0,De.length,0,J-W,pe,pe)}else ie=x(te,De,we,J-W,re-J,oe)}I.push(ie),V.push(ue)}function m(D,L,I,V){let F=[],H=0,K=-1;for(;a.pos>L;){let{id:W,start:J,end:G,size:re}=a;if(re>4)a.next();else{if(K>-1&&J<K)break;K<0&&(K=G-i),F.push(W,J,G),H++,a.next()}}if(H){let W=new Uint16Array(H*4),J=F[F.length-2];for(let G=F.length-3,re=0;G>=0;G-=3)W[re++]=F[G],W[re++]=F[G+1]-J,W[re++]=F[G+2]-J,W[re++]=re;I.push(new Ei(W,F[2]-J,r)),V.push(J-D)}}function v(D,L){return(I,V,F)=>{let H=0,K=I.length-1,W,J;if(K>=0&&(W=I[K])instanceof $t){if(!K&&W.type==D&&W.length==F)return W;(J=W.prop(je.lookAhead))&&(H=V[K]+W.length+J)}return x(D,I,V,F,H,L)}}function w(D,L,I,V,F,H,K,W,J){let G=[],re=[];for(;D.length>V;)G.push(D.pop()),re.push(L.pop()+I-F);D.push(x(r.types[K],G,re,H-F,W-H,J)),L.push(F-I)}function x(D,L,I,V,F,H,K){if(H){let W=[je.contextHash,H];K=K?[W].concat(K):[W]}if(F>25){let W=[je.lookAhead,F];K=K?[W].concat(K):[W]}return new $t(D,L,I,V,K)}function C(D,L){let I=a.fork(),V=0,F=0,H=0,K=I.end-i,W={size:0,start:0,skip:0};e:for(let J=I.pos-D;I.pos>J;){let G=I.size;if(I.id==L&&G>=0){W.size=V,W.start=F,W.skip=H,H+=4,V+=4,I.next();continue}let re=I.pos-G;if(G<0||re<J||I.start<K)break;let oe=I.id>=s?4:0,te=I.start;for(I.next();I.pos>re;){if(I.size<0)if(I.size==-3)oe+=4;else break e;else I.id>=s&&(oe+=4);I.next()}F=te,V+=G,H+=oe}return(L<0||V==D)&&(W.size=V,W.start=F,W.skip=H),W.size>4?W:void 0}function S(D,L,I){let{id:V,start:F,end:H,size:K}=a;if(a.next(),K>=0&&V<s){let W=I;if(K>4){let J=a.pos-(K-4);for(;a.pos>J;)I=S(D,L,I)}L[--I]=W,L[--I]=H-D,L[--I]=F-D,L[--I]=V}else K==-3?h=V:K==-4&&(f=V);return I}let A=[],T=[];for(;a.pos>0;)d(t.start||0,t.bufferStart||0,A,T,-1,0);let O=(e=t.length)!==null&&e!==void 0?e:A.length?T[0]+A[0].length:0;return new $t(c[t.topID],A.reverse(),T.reverse(),O)}const i5=new WeakMap;function Zc(t,e){if(!t.isAnonymous||e instanceof Ei||e.type!=t)return 1;let n=i5.get(e);if(n==null){n=1;for(let r of e.children){if(r.type!=t||!(r instanceof $t)){n=1;break}n+=Zc(t,r)}i5.set(e,n)}return n}function Jg(t,e,n,r,i,o,s,a,c){let h=0;for(let w=r;w<i;w++)h+=Zc(t,e[w]);let f=Math.ceil(h*1.5/8),d=[],m=[];function v(w,x,C,S,A){for(let T=C;T<S;){let O=T,D=x[T],L=Zc(t,w[T]);for(T++;T<S;T++){let I=Zc(t,w[T]);if(L+I>=f)break;L+=I}if(T==O+1){if(L>f){let I=w[O];v(I.children,I.positions,0,I.children.length,x[O]+A);continue}d.push(w[O])}else{let I=x[T-1]+w[T-1].length-D;d.push(Jg(t,w,x,O,T,D,I,null,c))}m.push(D+A-o)}}return v(e,n,r,i,0),(a||c)(d,m,s)}class ao{constructor(e,n,r,i,o=!1,s=!1){this.from=e,this.to=n,this.tree=r,this.offset=i,this.open=(o?1:0)|(s?2:0)}get openStart(){return(this.open&1)>0}get openEnd(){return(this.open&2)>0}static addTree(e,n=[],r=!1){let i=[new ao(0,e.length,e,0,!1,r)];for(let o of n)o.to>e.length&&i.push(o);return i}static applyChanges(e,n,r=128){if(!n.length)return e;let i=[],o=1,s=e.length?e[0]:null;for(let a=0,c=0,h=0;;a++){let f=a<n.length?n[a]:null,d=f?f.fromA:1e9;if(d-c>=r)for(;s&&s.from<d;){let m=s;if(c>=m.from||d<=m.to||h){let v=Math.max(m.from,c)-h,w=Math.min(m.to,d)-h;m=v>=w?null:new ao(v,w,m.tree,m.offset+h,a>0,!!f)}if(m&&i.push(m),s.to>d)break;s=o<e.length?e[o++]:null}if(!f)break;c=f.toA,h=f.toA-f.toB}return i}}class dy{startParse(e,n,r){return typeof e=="string"&&(e=new GV(e)),r=r?r.length?r.map(i=>new Td(i.from,i.to)):[new Td(0,0)]:[new Td(0,e.length)],this.createParse(e,n||[],r)}parse(e,n,r){let i=this.startParse(e,n,r);for(;;){let o=i.advance();if(o)return o}}}class GV{constructor(e){this.string=e}get length(){return this.string.length}chunk(e){return this.string.slice(e)}get lineChunks(){return!1}read(e,n){return this.string.slice(e,n)}}new je({perNode:!0});class yu{constructor(e,n,r,i,o,s,a,c,h,f=0,d){this.p=e,this.stack=n,this.state=r,this.reducePos=i,this.pos=o,this.score=s,this.buffer=a,this.bufferBase=c,this.curContext=h,this.lookAhead=f,this.parent=d}toString(){return`[${this.stack.filter((e,n)=>n%3==0).concat(this.state)}]@${this.pos}${this.score?"!"+this.score:""}`}static start(e,n,r=0){let i=e.parser.context;return new yu(e,[],n,r,r,0,[],0,i?new o5(i,i.start):null,0,null)}get context(){return this.curContext?this.curContext.context:null}pushState(e,n){this.stack.push(this.state,n,this.bufferBase+this.buffer.length),this.state=e}reduce(e){var n;let r=e>>19,i=e&65535,{parser:o}=this.p,s=this.reducePos<this.pos-25;s&&this.setLookAhead(this.pos);let a=o.dynamicPrecedence(i);if(a&&(this.score+=a),r==0){this.pushState(o.getGoto(this.state,i,!0),this.reducePos),i<o.minRepeatTerm&&this.storeNode(i,this.reducePos,this.reducePos,s?8:4,!0),this.reduceContext(i,this.reducePos);return}let c=this.stack.length-(r-1)*3-(e&262144?6:0),h=c?this.stack[c-2]:this.p.ranges[0].from,f=this.reducePos-h;f>=2e3&&!(!((n=this.p.parser.nodeSet.types[i])===null||n===void 0)&&n.isAnonymous)&&(h==this.p.lastBigReductionStart?(this.p.bigReductionCount++,this.p.lastBigReductionSize=f):this.p.lastBigReductionSize<f&&(this.p.bigReductionCount=1,this.p.lastBigReductionStart=h,this.p.lastBigReductionSize=f));let d=c?this.stack[c-1]:0,m=this.bufferBase+this.buffer.length-d;if(i<o.minRepeatTerm||e&131072){let v=o.stateFlag(this.state,1)?this.pos:this.reducePos;this.storeNode(i,h,v,m+4,!0)}if(e&262144)this.state=this.stack[c];else{let v=this.stack[c-3];this.state=o.getGoto(v,i,!0)}for(;this.stack.length>c;)this.stack.pop();this.reduceContext(i,h)}storeNode(e,n,r,i=4,o=!1){if(e==0&&(!this.stack.length||this.stack[this.stack.length-1]<this.buffer.length+this.bufferBase)){let s=this,a=this.buffer.length;if(a==0&&s.parent&&(a=s.bufferBase-s.parent.bufferBase,s=s.parent),a>0&&s.buffer[a-4]==0&&s.buffer[a-1]>-1){if(n==r)return;if(s.buffer[a-2]>=n){s.buffer[a-2]=r;return}}}if(!o||this.pos==r)this.buffer.push(e,n,r,i);else{let s=this.buffer.length;if(s>0&&this.buffer[s-4]!=0){let a=!1;for(let c=s;c>0&&this.buffer[c-2]>r;c-=4)if(this.buffer[c-1]>=0){a=!0;break}if(a)for(;s>0&&this.buffer[s-2]>r;)this.buffer[s]=this.buffer[s-4],this.buffer[s+1]=this.buffer[s-3],this.buffer[s+2]=this.buffer[s-2],this.buffer[s+3]=this.buffer[s-1],s-=4,i>4&&(i-=4)}this.buffer[s]=e,this.buffer[s+1]=n,this.buffer[s+2]=r,this.buffer[s+3]=i}}shift(e,n,r,i){if(e&131072)this.pushState(e&65535,this.pos);else if(e&262144)this.pos=i,this.shiftContext(n,r),n<=this.p.parser.maxNode&&this.buffer.push(n,r,i,4);else{let o=e,{parser:s}=this.p;(i>this.pos||n<=s.maxNode)&&(this.pos=i,s.stateFlag(o,1)||(this.reducePos=i)),this.pushState(o,r),this.shiftContext(n,r),n<=s.maxNode&&this.buffer.push(n,r,i,4)}}apply(e,n,r,i){e&65536?this.reduce(e):this.shift(e,n,r,i)}useNode(e,n){let r=this.p.reused.length-1;(r<0||this.p.reused[r]!=e)&&(this.p.reused.push(e),r++);let i=this.pos;this.reducePos=this.pos=i+e.length,this.pushState(n,i),this.buffer.push(r,i,this.reducePos,-1),this.curContext&&this.updateContext(this.curContext.tracker.reuse(this.curContext.context,e,this,this.p.stream.reset(this.pos-e.length)))}split(){let e=this,n=e.buffer.length;for(;n>0&&e.buffer[n-2]>e.reducePos;)n-=4;let r=e.buffer.slice(n),i=e.bufferBase+n;for(;e&&i==e.bufferBase;)e=e.parent;return new yu(this.p,this.stack.slice(),this.state,this.reducePos,this.pos,this.score,r,i,this.curContext,this.lookAhead,e)}recoverByDelete(e,n){let r=e<=this.p.parser.maxNode;r&&this.storeNode(e,this.pos,n,4),this.storeNode(0,this.pos,n,r?8:4),this.pos=this.reducePos=n,this.score-=190}canShift(e){for(let n=new YV(this);;){let r=this.p.parser.stateSlot(n.state,4)||this.p.parser.hasAction(n.state,e);if(r==0)return!1;if(!(r&65536))return!0;n.reduce(r)}}recoverByInsert(e){if(this.stack.length>=300)return[];let n=this.p.parser.nextStates(this.state);if(n.length>8||this.stack.length>=120){let i=[];for(let o=0,s;o<n.length;o+=2)(s=n[o+1])!=this.state&&this.p.parser.hasAction(s,e)&&i.push(n[o],s);if(this.stack.length<120)for(let o=0;i.length<8&&o<n.length;o+=2){let s=n[o+1];i.some((a,c)=>c&1&&a==s)||i.push(n[o],s)}n=i}let r=[];for(let i=0;i<n.length&&r.length<4;i+=2){let o=n[i+1];if(o==this.state)continue;let s=this.split();s.pushState(o,this.pos),s.storeNode(0,s.pos,s.pos,4,!0),s.shiftContext(n[i],this.pos),s.reducePos=this.pos,s.score-=200,r.push(s)}return r}forceReduce(){let{parser:e}=this.p,n=e.stateSlot(this.state,5);if(!(n&65536))return!1;if(!e.validAction(this.state,n)){let r=n>>19,i=n&65535,o=this.stack.length-r*3;if(o<0||e.getGoto(this.stack[o],i,!1)<0){let s=this.findForcedReduction();if(s==null)return!1;n=s}this.storeNode(0,this.pos,this.pos,4,!0),this.score-=100}return this.reducePos=this.pos,this.reduce(n),!0}findForcedReduction(){let{parser:e}=this.p,n=[],r=(i,o)=>{if(!n.includes(i))return n.push(i),e.allActions(i,s=>{if(!(s&393216))if(s&65536){let a=(s>>19)-o;if(a>1){let c=s&65535,h=this.stack.length-a*3;if(h>=0&&e.getGoto(this.stack[h],c,!1)>=0)return a<<19|65536|c}}else{let a=r(s,o+1);if(a!=null)return a}})};return r(this.state,0)}forceAll(){for(;!this.p.parser.stateFlag(this.state,2);)if(!this.forceReduce()){this.storeNode(0,this.pos,this.pos,4,!0);break}return this}get deadEnd(){if(this.stack.length!=3)return!1;let{parser:e}=this.p;return e.data[e.stateSlot(this.state,1)]==65535&&!e.stateSlot(this.state,4)}restart(){this.storeNode(0,this.pos,this.pos,4,!0),this.state=this.stack[0],this.stack.length=0}sameState(e){if(this.state!=e.state||this.stack.length!=e.stack.length)return!1;for(let n=0;n<this.stack.length;n+=3)if(this.stack[n]!=e.stack[n])return!1;return!0}get parser(){return this.p.parser}dialectEnabled(e){return this.p.parser.dialect.flags[e]}shiftContext(e,n){this.curContext&&this.updateContext(this.curContext.tracker.shift(this.curContext.context,e,this,this.p.stream.reset(n)))}reduceContext(e,n){this.curContext&&this.updateContext(this.curContext.tracker.reduce(this.curContext.context,e,this,this.p.stream.reset(n)))}emitContext(){let e=this.buffer.length-1;(e<0||this.buffer[e]!=-3)&&this.buffer.push(this.curContext.hash,this.pos,this.pos,-3)}emitLookAhead(){let e=this.buffer.length-1;(e<0||this.buffer[e]!=-4)&&this.buffer.push(this.lookAhead,this.pos,this.pos,-4)}updateContext(e){if(e!=this.curContext.context){let n=new o5(this.curContext.tracker,e);n.hash!=this.curContext.hash&&this.emitContext(),this.curContext=n}}setLookAhead(e){e>this.lookAhead&&(this.emitLookAhead(),this.lookAhead=e)}close(){this.curContext&&this.curContext.tracker.strict&&this.emitContext(),this.lookAhead>0&&this.emitLookAhead()}}class o5{constructor(e,n){this.tracker=e,this.context=n,this.hash=e.strict?e.hash(n):0}}class YV{constructor(e){this.start=e,this.state=e.state,this.stack=e.stack,this.base=this.stack.length}reduce(e){let n=e&65535,r=e>>19;r==0?(this.stack==this.start.stack&&(this.stack=this.stack.slice()),this.stack.push(this.state,0,0),this.base+=3):this.base-=(r-1)*3;let i=this.start.p.parser.getGoto(this.stack[this.base-3],n,!0);this.state=i}}class Cu{constructor(e,n,r){this.stack=e,this.pos=n,this.index=r,this.buffer=e.buffer,this.index==0&&this.maybeNext()}static create(e,n=e.bufferBase+e.buffer.length){return new Cu(e,n,n-e.bufferBase)}maybeNext(){let e=this.stack.parent;e!=null&&(this.index=this.stack.bufferBase-e.bufferBase,this.stack=e,this.buffer=e.buffer)}get id(){return this.buffer[this.index-4]}get start(){return this.buffer[this.index-3]}get end(){return this.buffer[this.index-2]}get size(){return this.buffer[this.index-1]}next(){this.index-=4,this.pos-=4,this.index==0&&this.maybeNext()}fork(){return new Cu(this.stack,this.pos,this.index)}}function Sc(t,e=Uint16Array){if(typeof t!="string")return t;let n=null;for(let r=0,i=0;r<t.length;){let o=0;for(;;){let s=t.charCodeAt(r++),a=!1;if(s==126){o=65535;break}s>=92&&s--,s>=34&&s--;let c=s-32;if(c>=46&&(c-=46,a=!0),o+=c,a)break;o*=46}n?n[i++]=o:n=new e(o)}return n}class Qc{constructor(){this.start=-1,this.value=-1,this.end=-1,this.extended=-1,this.lookAhead=0,this.mask=0,this.context=0}}const s5=new Qc;class XV{constructor(e,n){this.input=e,this.ranges=n,this.chunk="",this.chunkOff=0,this.chunk2="",this.chunk2Pos=0,this.next=-1,this.token=s5,this.rangeIndex=0,this.pos=this.chunkPos=n[0].from,this.range=n[0],this.end=n[n.length-1].to,this.readNext()}resolveOffset(e,n){let r=this.range,i=this.rangeIndex,o=this.pos+e;for(;o<r.from;){if(!i)return null;let s=this.ranges[--i];o-=r.from-s.to,r=s}for(;n<0?o>r.to:o>=r.to;){if(i==this.ranges.length-1)return null;let s=this.ranges[++i];o+=s.from-r.to,r=s}return o}clipPos(e){if(e>=this.range.from&&e<this.range.to)return e;for(let n of this.ranges)if(n.to>e)return Math.max(e,n.from);return this.end}peek(e){let n=this.chunkOff+e,r,i;if(n>=0&&n<this.chunk.length)r=this.pos+e,i=this.chunk.charCodeAt(n);else{let o=this.resolveOffset(e,1);if(o==null)return-1;if(r=o,r>=this.chunk2Pos&&r<this.chunk2Pos+this.chunk2.length)i=this.chunk2.charCodeAt(r-this.chunk2Pos);else{let s=this.rangeIndex,a=this.range;for(;a.to<=r;)a=this.ranges[++s];this.chunk2=this.input.chunk(this.chunk2Pos=r),r+this.chunk2.length>a.to&&(this.chunk2=this.chunk2.slice(0,a.to-r)),i=this.chunk2.charCodeAt(0)}}return r>=this.token.lookAhead&&(this.token.lookAhead=r+1),i}acceptToken(e,n=0){let r=n?this.resolveOffset(n,-1):this.pos;if(r==null||r<this.token.start)throw new RangeError("Token end out of bounds");this.token.value=e,this.token.end=r}acceptTokenTo(e,n){this.token.value=e,this.token.end=n}getChunk(){if(this.pos>=this.chunk2Pos&&this.pos<this.chunk2Pos+this.chunk2.length){let{chunk:e,chunkPos:n}=this;this.chunk=this.chunk2,this.chunkPos=this.chunk2Pos,this.chunk2=e,this.chunk2Pos=n,this.chunkOff=this.pos-this.chunkPos}else{this.chunk2=this.chunk,this.chunk2Pos=this.chunkPos;let e=this.input.chunk(this.pos),n=this.pos+e.length;this.chunk=n>this.range.to?e.slice(0,this.range.to-this.pos):e,this.chunkPos=this.pos,this.chunkOff=0}}readNext(){return this.chunkOff>=this.chunk.length&&(this.getChunk(),this.chunkOff==this.chunk.length)?this.next=-1:this.next=this.chunk.charCodeAt(this.chunkOff)}advance(e=1){for(this.chunkOff+=e;this.pos+e>=this.range.to;){if(this.rangeIndex==this.ranges.length-1)return this.setDone();e-=this.range.to-this.pos,this.range=this.ranges[++this.rangeIndex],this.pos=this.range.from}return this.pos+=e,this.pos>=this.token.lookAhead&&(this.token.lookAhead=this.pos+1),this.readNext()}setDone(){return this.pos=this.chunkPos=this.end,this.range=this.ranges[this.rangeIndex=this.ranges.length-1],this.chunk="",this.next=-1}reset(e,n){if(n?(this.token=n,n.start=e,n.lookAhead=e+1,n.value=n.extended=-1):this.token=s5,this.pos!=e){if(this.pos=e,e==this.end)return this.setDone(),this;for(;e<this.range.from;)this.range=this.ranges[--this.rangeIndex];for(;e>=this.range.to;)this.range=this.ranges[++this.rangeIndex];e>=this.chunkPos&&e<this.chunkPos+this.chunk.length?this.chunkOff=e-this.chunkPos:(this.chunk="",this.chunkOff=0),this.readNext()}return this}read(e,n){if(e>=this.chunkPos&&n<=this.chunkPos+this.chunk.length)return this.chunk.slice(e-this.chunkPos,n-this.chunkPos);if(e>=this.chunk2Pos&&n<=this.chunk2Pos+this.chunk2.length)return this.chunk2.slice(e-this.chunk2Pos,n-this.chunk2Pos);if(e>=this.range.from&&n<=this.range.to)return this.input.read(e,n);let r="";for(let i of this.ranges){if(i.from>=n)break;i.to>e&&(r+=this.input.read(Math.max(i.from,e),Math.min(i.to,n)))}return r}}class as{constructor(e,n){this.data=e,this.id=n}token(e,n){let{parser:r}=n.p;ZV(this.data,e,n,this.id,r.data,r.tokenPrecTable)}}as.prototype.contextual=as.prototype.fallback=as.prototype.extend=!1;as.prototype.fallback=as.prototype.extend=!1;function ZV(t,e,n,r,i,o){let s=0,a=1<<r,{dialect:c}=n.p.parser;e:for(;a&t[s];){let h=t[s+1];for(let v=s+3;v<h;v+=2)if((t[v+1]&a)>0){let w=t[v];if(c.allows(w)&&(e.token.value==-1||e.token.value==w||QV(w,e.token.value,i,o))){e.acceptToken(w);break}}let f=e.next,d=0,m=t[s+2];if(e.next<0&&m>d&&t[h+m*3-3]==65535){s=t[h+m*3-1];continue e}for(;d<m;){let v=d+m>>1,w=h+v+(v<<1),x=t[w],C=t[w+1]||65536;if(f<x)m=v;else if(f>=C)d=v+1;else{s=t[w+2],e.advance();continue e}}break}}function a5(t,e,n){for(let r=e,i;(i=t[r])!=65535;r++)if(i==n)return r-e;return-1}function QV(t,e,n,r){let i=a5(n,r,e);return i<0||a5(n,r,t)<i}const Cn=typeof process<"u"&&process.env&&/\bparse\b/.test(process.env.LOG);let Md=null;function l5(t,e,n){let r=t.cursor(Dt.IncludeAnonymous);for(r.moveTo(e);;)if(!(n<0?r.childBefore(e):r.childAfter(e)))for(;;){if((n<0?r.to<e:r.from>e)&&!r.type.isError)return n<0?Math.max(0,Math.min(r.to-1,e-25)):Math.min(t.length,Math.max(r.from+1,e+25));if(n<0?r.prevSibling():r.nextSibling())break;if(!r.parent())return n<0?0:t.length}}class JV{constructor(e,n){this.fragments=e,this.nodeSet=n,this.i=0,this.fragment=null,this.safeFrom=-1,this.safeTo=-1,this.trees=[],this.start=[],this.index=[],this.nextFragment()}nextFragment(){let e=this.fragment=this.i==this.fragments.length?null:this.fragments[this.i++];if(e){for(this.safeFrom=e.openStart?l5(e.tree,e.from+e.offset,1)-e.offset:e.from,this.safeTo=e.openEnd?l5(e.tree,e.to+e.offset,-1)-e.offset:e.to;this.trees.length;)this.trees.pop(),this.start.pop(),this.index.pop();this.trees.push(e.tree),this.start.push(-e.offset),this.index.push(0),this.nextStart=this.safeFrom}else this.nextStart=1e9}nodeAt(e){if(e<this.nextStart)return null;for(;this.fragment&&this.safeTo<=e;)this.nextFragment();if(!this.fragment)return null;for(;;){let n=this.trees.length-1;if(n<0)return this.nextFragment(),null;let r=this.trees[n],i=this.index[n];if(i==r.children.length){this.trees.pop(),this.start.pop(),this.index.pop();continue}let o=r.children[i],s=this.start[n]+r.positions[i];if(s>e)return this.nextStart=s,null;if(o instanceof $t){if(s==e){if(s<this.safeFrom)return null;let a=s+o.length;if(a<=this.safeTo){let c=o.prop(je.lookAhead);if(!c||a+c<this.fragment.to)return o}}this.index[n]++,s+o.length>=Math.max(this.safeFrom,e)&&(this.trees.push(o),this.start.push(s),this.index.push(0))}else this.index[n]++,this.nextStart=s+o.length}}}class eH{constructor(e,n){this.stream=n,this.tokens=[],this.mainToken=null,this.actions=[],this.tokens=e.tokenizers.map(r=>new Qc)}getActions(e){let n=0,r=null,{parser:i}=e.p,{tokenizers:o}=i,s=i.stateSlot(e.state,3),a=e.curContext?e.curContext.hash:0,c=0;for(let h=0;h<o.length;h++){if(!(1<<h&s))continue;let f=o[h],d=this.tokens[h];if(!(r&&!f.fallback)&&((f.contextual||d.start!=e.pos||d.mask!=s||d.context!=a)&&(this.updateCachedToken(d,f,e),d.mask=s,d.context=a),d.lookAhead>d.end+25&&(c=Math.max(d.lookAhead,c)),d.value!=0)){let m=n;if(d.extended>-1&&(n=this.addActions(e,d.extended,d.end,n)),n=this.addActions(e,d.value,d.end,n),!f.extend&&(r=d,n>m))break}}for(;this.actions.length>n;)this.actions.pop();return c&&e.setLookAhead(c),!r&&e.pos==this.stream.end&&(r=new Qc,r.value=e.p.parser.eofTerm,r.start=r.end=e.pos,n=this.addActions(e,r.value,r.end,n)),this.mainToken=r,this.actions}getMainToken(e){if(this.mainToken)return this.mainToken;let n=new Qc,{pos:r,p:i}=e;return n.start=r,n.end=Math.min(r+1,i.stream.end),n.value=r==i.stream.end?i.parser.eofTerm:0,n}updateCachedToken(e,n,r){let i=this.stream.clipPos(r.pos);if(n.token(this.stream.reset(i,e),r),e.value>-1){let{parser:o}=r.p;for(let s=0;s<o.specialized.length;s++)if(o.specialized[s]==e.value){let a=o.specializers[s](this.stream.read(e.start,e.end),r);if(a>=0&&r.p.parser.dialect.allows(a>>1)){a&1?e.extended=a>>1:e.value=a>>1;break}}}else e.value=0,e.end=this.stream.clipPos(i+1)}putAction(e,n,r,i){for(let o=0;o<i;o+=3)if(this.actions[o]==e)return i;return this.actions[i++]=e,this.actions[i++]=n,this.actions[i++]=r,i}addActions(e,n,r,i){let{state:o}=e,{parser:s}=e.p,{data:a}=s;for(let c=0;c<2;c++)for(let h=s.stateSlot(o,c?2:1);;h+=3){if(a[h]==65535)if(a[h+1]==1)h=zr(a,h+2);else{i==0&&a[h+1]==2&&(i=this.putAction(zr(a,h+2),n,r,i));break}a[h]==n&&(i=this.putAction(zr(a,h+1),n,r,i))}return i}}class tH{constructor(e,n,r,i){this.parser=e,this.input=n,this.ranges=i,this.recovering=0,this.nextStackID=9812,this.minStackPos=0,this.reused=[],this.stoppedAt=null,this.lastBigReductionStart=-1,this.lastBigReductionSize=0,this.bigReductionCount=0,this.stream=new XV(n,i),this.tokens=new eH(e,this.stream),this.topTerm=e.top[1];let{from:o}=i[0];this.stacks=[yu.start(this,e.top[0],o)],this.fragments=r.length&&this.stream.end-o>e.bufferLength*4?new JV(r,e.nodeSet):null}get parsedPos(){return this.minStackPos}advance(){let e=this.stacks,n=this.minStackPos,r=this.stacks=[],i,o;if(this.bigReductionCount>300&&e.length==1){let[s]=e;for(;s.forceReduce()&&s.stack.length&&s.stack[s.stack.length-2]>=this.lastBigReductionStart;);this.bigReductionCount=this.lastBigReductionSize=0}for(let s=0;s<e.length;s++){let a=e[s];for(;;){if(this.tokens.mainToken=null,a.pos>n)r.push(a);else{if(this.advanceStack(a,r,e))continue;{i||(i=[],o=[]),i.push(a);let c=this.tokens.getMainToken(a);o.push(c.value,c.end)}}break}}if(!r.length){let s=i&&rH(i);if(s)return Cn&&console.log("Finish with "+this.stackID(s)),this.stackToTree(s);if(this.parser.strict)throw Cn&&i&&console.log("Stuck with token "+(this.tokens.mainToken?this.parser.getName(this.tokens.mainToken.value):"none")),new SyntaxError("No parse at "+n);this.recovering||(this.recovering=5)}if(this.recovering&&i){let s=this.stoppedAt!=null&&i[0].pos>this.stoppedAt?i[0]:this.runRecovery(i,o,r);if(s)return Cn&&console.log("Force-finish "+this.stackID(s)),this.stackToTree(s.forceAll())}if(this.recovering){let s=this.recovering==1?1:this.recovering*3;if(r.length>s)for(r.sort((a,c)=>c.score-a.score);r.length>s;)r.pop();r.some(a=>a.reducePos>n)&&this.recovering--}else if(r.length>1){e:for(let s=0;s<r.length-1;s++){let a=r[s];for(let c=s+1;c<r.length;c++){let h=r[c];if(a.sameState(h)||a.buffer.length>500&&h.buffer.length>500)if((a.score-h.score||a.buffer.length-h.buffer.length)>0)r.splice(c--,1);else{r.splice(s--,1);continue e}}}r.length>12&&r.splice(12,r.length-12)}this.minStackPos=r[0].pos;for(let s=1;s<r.length;s++)r[s].pos<this.minStackPos&&(this.minStackPos=r[s].pos);return null}stopAt(e){if(this.stoppedAt!=null&&this.stoppedAt<e)throw new RangeError("Can't move stoppedAt forward");this.stoppedAt=e}advanceStack(e,n,r){let i=e.pos,{parser:o}=this,s=Cn?this.stackID(e)+" -> ":"";if(this.stoppedAt!=null&&i>this.stoppedAt)return e.forceReduce()?e:null;if(this.fragments){let h=e.curContext&&e.curContext.tracker.strict,f=h?e.curContext.hash:0;for(let d=this.fragments.nodeAt(i);d;){let m=this.parser.nodeSet.types[d.type.id]==d.type?o.getGoto(e.state,d.type.id):-1;if(m>-1&&d.length&&(!h||(d.prop(je.contextHash)||0)==f))return e.useNode(d,m),Cn&&console.log(s+this.stackID(e)+` (via reuse of ${o.getName(d.type.id)})`),!0;if(!(d instanceof $t)||d.children.length==0||d.positions[0]>0)break;let v=d.children[0];if(v instanceof $t&&d.positions[0]==0)d=v;else break}}let a=o.stateSlot(e.state,4);if(a>0)return e.reduce(a),Cn&&console.log(s+this.stackID(e)+` (via always-reduce ${o.getName(a&65535)})`),!0;if(e.stack.length>=8400)for(;e.stack.length>6e3&&e.forceReduce(););let c=this.tokens.getActions(e);for(let h=0;h<c.length;){let f=c[h++],d=c[h++],m=c[h++],v=h==c.length||!r,w=v?e:e.split(),x=this.tokens.mainToken;if(w.apply(f,d,x?x.start:w.pos,m),Cn&&console.log(s+this.stackID(w)+` (via ${f&65536?`reduce of ${o.getName(f&65535)}`:"shift"} for ${o.getName(d)} @ ${i}${w==e?"":", split"})`),v)return!0;w.pos>i?n.push(w):r.push(w)}return!1}advanceFully(e,n){let r=e.pos;for(;;){if(!this.advanceStack(e,null,null))return!1;if(e.pos>r)return c5(e,n),!0}}runRecovery(e,n,r){let i=null,o=!1;for(let s=0;s<e.length;s++){let a=e[s],c=n[s<<1],h=n[(s<<1)+1],f=Cn?this.stackID(a)+" -> ":"";if(a.deadEnd&&(o||(o=!0,a.restart(),Cn&&console.log(f+this.stackID(a)+" (restarted)"),this.advanceFully(a,r))))continue;let d=a.split(),m=f;for(let v=0;d.forceReduce()&&v<10&&(Cn&&console.log(m+this.stackID(d)+" (via force-reduce)"),!this.advanceFully(d,r));v++)Cn&&(m=this.stackID(d)+" -> ");for(let v of a.recoverByInsert(c))Cn&&console.log(f+this.stackID(v)+" (via recover-insert)"),this.advanceFully(v,r);this.stream.end>a.pos?(h==a.pos&&(h++,c=0),a.recoverByDelete(c,h),Cn&&console.log(f+this.stackID(a)+` (via recover-delete ${this.parser.getName(c)})`),c5(a,r)):(!i||i.score<a.score)&&(i=a)}return i}stackToTree(e){return e.close(),$t.build({buffer:Cu.create(e),nodeSet:this.parser.nodeSet,topID:this.topTerm,maxBufferLength:this.parser.bufferLength,reused:this.reused,start:this.ranges[0].from,length:e.pos-this.ranges[0].from,minRepeatType:this.parser.minRepeatTerm})}stackID(e){let n=(Md||(Md=new WeakMap)).get(e);return n||Md.set(e,n=String.fromCodePoint(this.nextStackID++)),n+e}}function c5(t,e){for(let n=0;n<e.length;n++){let r=e[n];if(r.pos==t.pos&&r.sameState(t)){e[n].score<t.score&&(e[n]=t);return}}e.push(t)}class nH{constructor(e,n,r){this.source=e,this.flags=n,this.disabled=r}allows(e){return!this.disabled||this.disabled[e]==0}}class $u extends dy{constructor(e){if(super(),this.wrappers=[],e.version!=14)throw new RangeError(`Parser version (${e.version}) doesn't match runtime version (14)`);let n=e.nodeNames.split(" ");this.minRepeatTerm=n.length;for(let a=0;a<e.repeatNodeCount;a++)n.push("");let r=Object.keys(e.topRules).map(a=>e.topRules[a][1]),i=[];for(let a=0;a<n.length;a++)i.push([]);function o(a,c,h){i[a].push([c,c.deserialize(String(h))])}if(e.nodeProps)for(let a of e.nodeProps){let c=a[0];typeof c=="string"&&(c=je[c]);for(let h=1;h<a.length;){let f=a[h++];if(f>=0)o(f,c,a[h++]);else{let d=a[h+-f];for(let m=-f;m>0;m--)o(a[h++],c,d);h++}}}this.nodeSet=new Xg(n.map((a,c)=>dn.define({name:c>=this.minRepeatTerm?void 0:a,id:c,props:i[c],top:r.indexOf(c)>-1,error:c==0,skipped:e.skippedNodes&&e.skippedNodes.indexOf(c)>-1}))),e.propSources&&(this.nodeSet=this.nodeSet.extend(...e.propSources)),this.strict=!1,this.bufferLength=cy;let s=Sc(e.tokenData);this.context=e.context,this.specializerSpecs=e.specialized||[],this.specialized=new Uint16Array(this.specializerSpecs.length);for(let a=0;a<this.specializerSpecs.length;a++)this.specialized[a]=this.specializerSpecs[a].term;this.specializers=this.specializerSpecs.map(u5),this.states=Sc(e.states,Uint32Array),this.data=Sc(e.stateData),this.goto=Sc(e.goto),this.maxTerm=e.maxTerm,this.tokenizers=e.tokenizers.map(a=>typeof a=="number"?new as(s,a):a),this.topRules=e.topRules,this.dialects=e.dialects||{},this.dynamicPrecedences=e.dynamicPrecedences||null,this.tokenPrecTable=e.tokenPrec,this.termNames=e.termNames||null,this.maxNode=this.nodeSet.types.length-1,this.dialect=this.parseDialect(),this.top=this.topRules[Object.keys(this.topRules)[0]]}createParse(e,n,r){let i=new tH(this,e,n,r);for(let o of this.wrappers)i=o(i,e,n,r);return i}getGoto(e,n,r=!1){let i=this.goto;if(n>=i[0])return-1;for(let o=i[n+1];;){let s=i[o++],a=s&1,c=i[o++];if(a&&r)return c;for(let h=o+(s>>1);o<h;o++)if(i[o]==e)return c;if(a)return-1}}hasAction(e,n){let r=this.data;for(let i=0;i<2;i++)for(let o=this.stateSlot(e,i?2:1),s;;o+=3){if((s=r[o])==65535)if(r[o+1]==1)s=r[o=zr(r,o+2)];else{if(r[o+1]==2)return zr(r,o+2);break}if(s==n||s==0)return zr(r,o+1)}return 0}stateSlot(e,n){return this.states[e*6+n]}stateFlag(e,n){return(this.stateSlot(e,0)&n)>0}validAction(e,n){return!!this.allActions(e,r=>r==n?!0:null)}allActions(e,n){let r=this.stateSlot(e,4),i=r?n(r):void 0;for(let o=this.stateSlot(e,1);i==null;o+=3){if(this.data[o]==65535)if(this.data[o+1]==1)o=zr(this.data,o+2);else break;i=n(zr(this.data,o+1))}return i}nextStates(e){let n=[];for(let r=this.stateSlot(e,1);;r+=3){if(this.data[r]==65535)if(this.data[r+1]==1)r=zr(this.data,r+2);else break;if(!(this.data[r+2]&1)){let i=this.data[r+1];n.some((o,s)=>s&1&&o==i)||n.push(this.data[r],i)}}return n}configure(e){let n=Object.assign(Object.create($u.prototype),this);if(e.props&&(n.nodeSet=this.nodeSet.extend(...e.props)),e.top){let r=this.topRules[e.top];if(!r)throw new RangeError(`Invalid top rule name ${e.top}`);n.top=r}return e.tokenizers&&(n.tokenizers=this.tokenizers.map(r=>{let i=e.tokenizers.find(o=>o.from==r);return i?i.to:r})),e.specializers&&(n.specializers=this.specializers.slice(),n.specializerSpecs=this.specializerSpecs.map((r,i)=>{let o=e.specializers.find(a=>a.from==r.external);if(!o)return r;let s=Object.assign(Object.assign({},r),{external:o.to});return n.specializers[i]=u5(s),s})),e.contextTracker&&(n.context=e.contextTracker),e.dialect&&(n.dialect=this.parseDialect(e.dialect)),e.strict!=null&&(n.strict=e.strict),e.wrap&&(n.wrappers=n.wrappers.concat(e.wrap)),e.bufferLength!=null&&(n.bufferLength=e.bufferLength),n}hasWrappers(){return this.wrappers.length>0}getName(e){return this.termNames?this.termNames[e]:String(e<=this.maxNode&&this.nodeSet.types[e].name||e)}get eofTerm(){return this.maxNode+1}get topNode(){return this.nodeSet.types[this.top[1]]}dynamicPrecedence(e){let n=this.dynamicPrecedences;return n==null?0:n[e]||0}parseDialect(e){let n=Object.keys(this.dialects),r=n.map(()=>!1);if(e)for(let o of e.split(" ")){let s=n.indexOf(o);s>=0&&(r[s]=!0)}let i=null;for(let o=0;o<n.length;o++)if(!r[o])for(let s=this.dialects[n[o]],a;(a=this.data[s++])!=65535;)(i||(i=new Uint8Array(this.maxTerm+1)))[a]=1;return new nH(e,r,i)}static deserialize(e){return new $u(e)}}function zr(t,e){return t[e]|t[e+1]<<16}function rH(t){let e=null;for(let n of t){let r=n.p.stoppedAt;(n.pos==n.p.stream.end||r!=null&&n.pos>r)&&n.p.parser.stateFlag(n.state,2)&&(!e||e.score<n.score)&&(e=n)}return e}function u5(t){if(t.external){let e=t.extend?1:0;return(n,r)=>t.external(n,r)<<1|e}return t.get}let iH=0,Ur=class B0{constructor(e,n,r,i){this.name=e,this.set=n,this.base=r,this.modified=i,this.id=iH++}toString(){let{name:e}=this;for(let n of this.modified)n.name&&(e=`${n.name}(${e})`);return e}static define(e,n){let r=typeof e=="string"?e:"?";if(e instanceof B0&&(n=e),n?.base)throw new Error("Can not derive from a modified tag");let i=new B0(r,[],null,[]);if(i.set.push(i),n)for(let o of n.set)i.set.push(o);return i}static defineModifier(e){let n=new Su(e);return r=>r.modified.indexOf(n)>-1?r:Su.get(r.base||r,r.modified.concat(n).sort((i,o)=>i.id-o.id))}},oH=0;class Su{constructor(e){this.name=e,this.instances=[],this.id=oH++}static get(e,n){if(!n.length)return e;let r=n[0].instances.find(a=>a.base==e&&sH(n,a.modified));if(r)return r;let i=[],o=new Ur(e.name,i,e,n);for(let a of n)a.instances.push(o);let s=aH(n);for(let a of e.set)if(!a.modified.length)for(let c of s)i.push(Su.get(a,c));return o}}function sH(t,e){return t.length==e.length&&t.every((n,r)=>n==e[r])}function aH(t){let e=[[]];for(let n=0;n<t.length;n++)for(let r=0,i=e.length;r<i;r++)e.push(e[r].concat(t[n]));return e.sort((n,r)=>r.length-n.length)}function gy(t){let e=Object.create(null);for(let n in t){let r=t[n];Array.isArray(r)||(r=[r]);for(let i of n.split(" "))if(i){let o=[],s=2,a=i;for(let d=0;;){if(a=="..."&&d>0&&d+3==i.length){s=1;break}let m=/^"(?:[^"\\]|\\.)*?"|[^\/!]+/.exec(a);if(!m)throw new RangeError("Invalid path: "+i);if(o.push(m[0]=="*"?"":m[0][0]=='"'?JSON.parse(m[0]):m[0]),d+=m[0].length,d==i.length)break;let v=i[d++];if(d==i.length&&v=="!"){s=0;break}if(v!="/")throw new RangeError("Invalid path: "+i);a=i.slice(d)}let c=o.length-1,h=o[c];if(!h)throw new RangeError("Invalid path: "+i);let f=new Au(r,s,c>0?o.slice(0,c):null);e[h]=f.sort(e[h])}}return my.add(e)}const my=new je;class Au{constructor(e,n,r,i){this.tags=e,this.mode=n,this.context=r,this.next=i}get opaque(){return this.mode==0}get inherit(){return this.mode==1}sort(e){return!e||e.depth<this.depth?(this.next=e,this):(e.next=this.sort(e.next),e)}get depth(){return this.context?this.context.length:0}}Au.empty=new Au([],2,null);function py(t,e){let n=Object.create(null);for(let o of t)if(!Array.isArray(o.tag))n[o.tag.id]=o.class;else for(let s of o.tag)n[s.id]=o.class;let{scope:r,all:i=null}=e||{};return{style:o=>{let s=i;for(let a of o)for(let c of a.set){let h=n[c.id];if(h){s=s?s+" "+h:h;break}}return s},scope:r}}function lH(t,e){let n=null;for(let r of t){let i=r.style(e);i&&(n=n?n+" "+i:i)}return n}function cH(t,e,n,r=0,i=t.length){let o=new uH(r,Array.isArray(e)?e:[e],n);o.highlightRange(t.cursor(),r,i,"",o.highlighters),o.flush(i)}class uH{constructor(e,n,r){this.at=e,this.highlighters=n,this.span=r,this.class=""}startSpan(e,n){n!=this.class&&(this.flush(e),e>this.at&&(this.at=e),this.class=n)}flush(e){e>this.at&&this.class&&this.span(this.at,e,this.class)}highlightRange(e,n,r,i,o){let{type:s,from:a,to:c}=e;if(a>=r||c<=n)return;s.isTop&&(o=this.highlighters.filter(v=>!v.scope||v.scope(s)));let h=i,f=hH(e)||Au.empty,d=lH(o,f.tags);if(d&&(h&&(h+=" "),h+=d,f.mode==1&&(i+=(i?" ":"")+d)),this.startSpan(Math.max(n,a),h),f.opaque)return;let m=e.tree&&e.tree.prop(je.mounted);if(m&&m.overlay){let v=e.node.enter(m.overlay[0].from+a,1),w=this.highlighters.filter(C=>!C.scope||C.scope(m.tree.type)),x=e.firstChild();for(let C=0,S=a;;C++){let A=C<m.overlay.length?m.overlay[C]:null,T=A?A.from+a:c,O=Math.max(n,S),D=Math.min(r,T);if(O<D&&x)for(;e.from<D&&(this.highlightRange(e,O,D,i,o),this.startSpan(Math.min(D,e.to),h),!(e.to>=T||!e.nextSibling())););if(!A||T>r)break;S=A.to+a,S>n&&(this.highlightRange(v.cursor(),Math.max(n,A.from+a),Math.min(r,S),"",w),this.startSpan(Math.min(r,S),h))}x&&e.parent()}else if(e.firstChild()){m&&(i="");do if(!(e.to<=n)){if(e.from>=r)break;this.highlightRange(e,n,r,i,o),this.startSpan(Math.min(r,e.to),h)}while(e.nextSibling());e.parent()}}}function hH(t){let e=t.type.prop(my);for(;e&&e.context&&!t.matchContext(e.context);)e=e.next;return e||null}const se=Ur.define,Ac=se(),bi=se(),h5=se(bi),f5=se(bi),wi=se(),Rc=se(wi),Ed=se(wi),dr=se(),Qi=se(dr),ur=se(),hr=se(),N0=se(),sa=se(N0),kc=se(),z={comment:Ac,lineComment:se(Ac),blockComment:se(Ac),docComment:se(Ac),name:bi,variableName:se(bi),typeName:h5,tagName:se(h5),propertyName:f5,attributeName:se(f5),className:se(bi),labelName:se(bi),namespace:se(bi),macroName:se(bi),literal:wi,string:Rc,docString:se(Rc),character:se(Rc),attributeValue:se(Rc),number:Ed,integer:se(Ed),float:se(Ed),bool:se(wi),regexp:se(wi),escape:se(wi),color:se(wi),url:se(wi),keyword:ur,self:se(ur),null:se(ur),atom:se(ur),unit:se(ur),modifier:se(ur),operatorKeyword:se(ur),controlKeyword:se(ur),definitionKeyword:se(ur),moduleKeyword:se(ur),operator:hr,derefOperator:se(hr),arithmeticOperator:se(hr),logicOperator:se(hr),bitwiseOperator:se(hr),compareOperator:se(hr),updateOperator:se(hr),definitionOperator:se(hr),typeOperator:se(hr),controlOperator:se(hr),punctuation:N0,separator:se(N0),bracket:sa,angleBracket:se(sa),squareBracket:se(sa),paren:se(sa),brace:se(sa),content:dr,heading:Qi,heading1:se(Qi),heading2:se(Qi),heading3:se(Qi),heading4:se(Qi),heading5:se(Qi),heading6:se(Qi),contentSeparator:se(dr),list:se(dr),quote:se(dr),emphasis:se(dr),strong:se(dr),link:se(dr),monospace:se(dr),strikethrough:se(dr),inserted:se(),deleted:se(),changed:se(),invalid:se(),meta:kc,documentMeta:se(kc),annotation:se(kc),processingInstruction:se(kc),definition:Ur.defineModifier("definition"),constant:Ur.defineModifier("constant"),function:Ur.defineModifier("function"),standard:Ur.defineModifier("standard"),local:Ur.defineModifier("local"),special:Ur.defineModifier("special")};for(let t in z){let e=z[t];e instanceof Ur&&(e.name=t)}py([{tag:z.link,class:"tok-link"},{tag:z.heading,class:"tok-heading"},{tag:z.emphasis,class:"tok-emphasis"},{tag:z.strong,class:"tok-strong"},{tag:z.keyword,class:"tok-keyword"},{tag:z.atom,class:"tok-atom"},{tag:z.bool,class:"tok-bool"},{tag:z.url,class:"tok-url"},{tag:z.labelName,class:"tok-labelName"},{tag:z.inserted,class:"tok-inserted"},{tag:z.deleted,class:"tok-deleted"},{tag:z.literal,class:"tok-literal"},{tag:z.string,class:"tok-string"},{tag:z.number,class:"tok-number"},{tag:[z.regexp,z.escape,z.special(z.string)],class:"tok-string2"},{tag:z.variableName,class:"tok-variableName"},{tag:z.local(z.variableName),class:"tok-variableName tok-local"},{tag:z.definition(z.variableName),class:"tok-variableName tok-definition"},{tag:z.special(z.variableName),class:"tok-variableName2"},{tag:z.definition(z.propertyName),class:"tok-propertyName tok-definition"},{tag:z.typeName,class:"tok-typeName"},{tag:z.namespace,class:"tok-namespace"},{tag:z.className,class:"tok-className"},{tag:z.macroName,class:"tok-macroName"},{tag:z.propertyName,class:"tok-propertyName"},{tag:z.operator,class:"tok-operator"},{tag:z.comment,class:"tok-comment"},{tag:z.meta,class:"tok-meta"},{tag:z.invalid,class:"tok-invalid"},{tag:z.punctuation,class:"tok-punctuation"}]);const fH=gy({String:z.string,Number:z.number,"True False":z.bool,PropertyName:z.propertyName,Null:z.null,", :":z.separator,"[ ]":z.squareBracket,"{ }":z.brace}),dH=$u.deserialize({version:14,states:"$bOVQPOOOOQO'#Cb'#CbOnQPO'#CeOvQPO'#ClOOQO'#Cr'#CrQOQPOOOOQO'#Cg'#CgO}QPO'#CfO!SQPO'#CtOOQO,59P,59PO![QPO,59PO!aQPO'#CuOOQO,59W,59WO!iQPO,59WOVQPO,59QOqQPO'#CmO!nQPO,59`OOQO1G.k1G.kOVQPO'#CnO!vQPO,59aOOQO1G.r1G.rOOQO1G.l1G.lOOQO,59X,59XOOQO-E6k-E6kOOQO,59Y,59YOOQO-E6l-E6l",stateData:"#O~OeOS~OQSORSOSSOTSOWQO_ROgPO~OVXOgUO~O^[O~PVO[^O~O]_OVhX~OVaO~O]bO^iX~O^dO~O]_OVha~O]bO^ia~O",goto:"!kjPPPPPPkPPkqwPPPPk{!RPPP!XP!e!hXSOR^bQWQRf_TVQ_Q`WRg`QcZRicQTOQZRQe^RhbRYQR]R",nodeNames:"⚠ JsonText True False Null Number String } { Object Property PropertyName : , ] [ Array",maxTerm:25,nodeProps:[["isolate",-2,6,11,""],["openedBy",7,"{",14,"["],["closedBy",8,"}",15,"]"]],propSources:[fH],skippedNodes:[0],repeatNodeCount:2,tokenData:"(|~RaXY!WYZ!W]^!Wpq!Wrs!]|}$u}!O$z!Q!R%T!R![&c![!]&t!}#O&y#P#Q'O#Y#Z'T#b#c'r#h#i(Z#o#p(r#q#r(w~!]Oe~~!`Wpq!]qr!]rs!xs#O!]#O#P!}#P;'S!];'S;=`$o<%lO!]~!}Og~~#QXrs!]!P!Q!]#O#P!]#U#V!]#Y#Z!]#b#c!]#f#g!]#h#i!]#i#j#m~#pR!Q![#y!c!i#y#T#Z#y~#|R!Q![$V!c!i$V#T#Z$V~$YR!Q![$c!c!i$c#T#Z$c~$fR!Q![!]!c!i!]#T#Z!]~$rP;=`<%l!]~$zO]~~$}Q!Q!R%T!R![&c~%YRT~!O!P%c!g!h%w#X#Y%w~%fP!Q![%i~%nRT~!Q![%i!g!h%w#X#Y%w~%zR{|&T}!O&T!Q![&Z~&WP!Q![&Z~&`PT~!Q![&Z~&hST~!O!P%c!Q![&c!g!h%w#X#Y%w~&yO[~~'OO_~~'TO^~~'WP#T#U'Z~'^P#`#a'a~'dP#g#h'g~'jP#X#Y'm~'rOR~~'uP#i#j'x~'{P#`#a(O~(RP#`#a(U~(ZOS~~(^P#f#g(a~(dP#i#j(g~(jP#X#Y(m~(rOQ~~(wOW~~(|OV~",tokenizers:[0],topRules:{JsonText:[0,1]},tokenPrec:0});let j0=[],vy=[];(()=>{let t="lc,34,7n,7,7b,19,,,,2,,2,,,20,b,1c,l,g,,2t,7,2,6,2,2,,4,z,,u,r,2j,b,1m,9,9,,o,4,,9,,3,,5,17,3,3b,f,,w,1j,,,,4,8,4,,3,7,a,2,t,,1m,,,,2,4,8,,9,,a,2,q,,2,2,1l,,4,2,4,2,2,3,3,,u,2,3,,b,2,1l,,4,5,,2,4,,k,2,m,6,,,1m,,,2,,4,8,,7,3,a,2,u,,1n,,,,c,,9,,14,,3,,1l,3,5,3,,4,7,2,b,2,t,,1m,,2,,2,,3,,5,2,7,2,b,2,s,2,1l,2,,,2,4,8,,9,,a,2,t,,20,,4,,2,3,,,8,,29,,2,7,c,8,2q,,2,9,b,6,22,2,r,,,,,,1j,e,,5,,2,5,b,,10,9,,2u,4,,6,,2,2,2,p,2,4,3,g,4,d,,2,2,6,,f,,jj,3,qa,3,t,3,t,2,u,2,1s,2,,7,8,,2,b,9,,19,3,3b,2,y,,3a,3,4,2,9,,6,3,63,2,2,,1m,,,7,,,,,2,8,6,a,2,,1c,h,1r,4,1c,7,,,5,,14,9,c,2,w,4,2,2,,3,1k,,,2,3,,,3,1m,8,2,2,48,3,,d,,7,4,,6,,3,2,5i,1m,,5,ek,,5f,x,2da,3,3x,,2o,w,fe,6,2x,2,n9w,4,,a,w,2,28,2,7k,,3,,4,,p,2,5,,47,2,q,i,d,,12,8,p,b,1a,3,1c,,2,4,2,2,13,,1v,6,2,2,2,2,c,,8,,1b,,1f,,,3,2,2,5,2,,,16,2,8,,6m,,2,,4,,fn4,,kh,g,g,g,a6,2,gt,,6a,,45,5,1ae,3,,2,5,4,14,3,4,,4l,2,fx,4,ar,2,49,b,4w,,1i,f,1k,3,1d,4,2,2,1x,3,10,5,,8,1q,,c,2,1g,9,a,4,2,,2n,3,2,,,2,6,,4g,,3,8,l,2,1l,2,,,,,m,,e,7,3,5,5f,8,2,3,,,n,,29,,2,6,,,2,,,2,,2,6j,,2,4,6,2,,2,r,2,2d,8,2,,,2,2y,,,,2,6,,,2t,3,2,4,,5,77,9,,2,6t,,a,2,,,4,,40,4,2,2,4,,w,a,14,6,2,4,8,,9,6,2,3,1a,d,,2,ba,7,,6,,,2a,m,2,7,,2,,2,3e,6,3,,,2,,7,,,20,2,3,,,,9n,2,f0b,5,1n,7,t4,,1r,4,29,,f5k,2,43q,,,3,4,5,8,8,2,7,u,4,44,3,1iz,1j,4,1e,8,,e,,m,5,,f,11s,7,,h,2,7,,2,,5,79,7,c5,4,15s,7,31,7,240,5,gx7k,2o,3k,6o".split(",").map(e=>e?parseInt(e,36):1);for(let e=0,n=0;e<t.length;e++)(e%2?vy:j0).push(n=n+t[e])})();function gH(t){if(t<768)return!1;for(let e=0,n=j0.length;;){let r=e+n>>1;if(t<j0[r])n=r;else if(t>=vy[r])e=r+1;else return!0;if(e==n)return!1}}function d5(t){return t>=127462&&t<=127487}const g5=8205;function mH(t,e,n=!0,r=!0){return(n?by:pH)(t,e,r)}function by(t,e,n){if(e==t.length)return e;e&&wy(t.charCodeAt(e))&&xy(t.charCodeAt(e-1))&&e--;let r=Od(t,e);for(e+=m5(r);e<t.length;){let i=Od(t,e);if(r==g5||i==g5||n&&gH(i))e+=m5(i),r=i;else if(d5(i)){let o=0,s=e-2;for(;s>=0&&d5(Od(t,s));)o++,s-=2;if(o%2==0)break;e+=2}else break}return e}function pH(t,e,n){for(;e>0;){let r=by(t,e-2,n);if(r<e)return r;e--}return 0}function Od(t,e){let n=t.charCodeAt(e);if(!xy(n)||e+1==t.length)return n;let r=t.charCodeAt(e+1);return wy(r)?(n-55296<<10)+(r-56320)+65536:n}function wy(t){return t>=56320&&t<57344}function xy(t){return t>=55296&&t<56320}function m5(t){return t<65536?1:2}class Ge{lineAt(e){if(e<0||e>this.length)throw new RangeError(`Invalid position ${e} in document of length ${this.length}`);return this.lineInner(e,!1,1,0)}line(e){if(e<1||e>this.lines)throw new RangeError(`Invalid line number ${e} in ${this.lines}-line document`);return this.lineInner(e,!0,1,0)}replace(e,n,r){[e,n]=xs(this,e,n);let i=[];return this.decompose(0,e,i,2),r.length&&r.decompose(0,r.length,i,3),this.decompose(n,this.length,i,1),gr.from(i,this.length-(n-e)+r.length)}append(e){return this.replace(this.length,this.length,e)}slice(e,n=this.length){[e,n]=xs(this,e,n);let r=[];return this.decompose(e,n,r,0),gr.from(r,n-e)}eq(e){if(e==this)return!0;if(e.length!=this.length||e.lines!=this.lines)return!1;let n=this.scanIdentical(e,1),r=this.length-this.scanIdentical(e,-1),i=new xa(this),o=new xa(e);for(let s=n,a=n;;){if(i.next(s),o.next(s),s=0,i.lineBreak!=o.lineBreak||i.done!=o.done||i.value!=o.value)return!1;if(a+=i.value.length,i.done||a>=r)return!0}}iter(e=1){return new xa(this,e)}iterRange(e,n=this.length){return new yy(this,e,n)}iterLines(e,n){let r;if(e==null)r=this.iter();else{n==null&&(n=this.lines+1);let i=this.line(e).from;r=this.iterRange(i,Math.max(i,n==this.lines+1?this.length:n<=1?0:this.line(n-1).to))}return new Cy(r)}toString(){return this.sliceString(0)}toJSON(){let e=[];return this.flatten(e),e}constructor(){}static of(e){if(e.length==0)throw new RangeError("A document must have at least one line");return e.length==1&&!e[0]?Ge.empty:e.length<=32?new mt(e):gr.from(mt.split(e,[]))}}class mt extends Ge{constructor(e,n=vH(e)){super(),this.text=e,this.length=n}get lines(){return this.text.length}get children(){return null}lineInner(e,n,r,i){for(let o=0;;o++){let s=this.text[o],a=i+s.length;if((n?r:a)>=e)return new bH(i,a,r,s);i=a+1,r++}}decompose(e,n,r,i){let o=e<=0&&n>=this.length?this:new mt(p5(this.text,e,n),Math.min(n,this.length)-Math.max(0,e));if(i&1){let s=r.pop(),a=Jc(o.text,s.text.slice(),0,o.length);if(a.length<=32)r.push(new mt(a,s.length+o.length));else{let c=a.length>>1;r.push(new mt(a.slice(0,c)),new mt(a.slice(c)))}}else r.push(o)}replace(e,n,r){if(!(r instanceof mt))return super.replace(e,n,r);[e,n]=xs(this,e,n);let i=Jc(this.text,Jc(r.text,p5(this.text,0,e)),n),o=this.length+r.length-(n-e);return i.length<=32?new mt(i,o):gr.from(mt.split(i,[]),o)}sliceString(e,n=this.length,r=`
48
- `){[e,n]=xs(this,e,n);let i="";for(let o=0,s=0;o<=n&&s<this.text.length;s++){let a=this.text[s],c=o+a.length;o>e&&s&&(i+=r),e<c&&n>o&&(i+=a.slice(Math.max(0,e-o),n-o)),o=c+1}return i}flatten(e){for(let n of this.text)e.push(n)}scanIdentical(){return 0}static split(e,n){let r=[],i=-1;for(let o of e)r.push(o),i+=o.length+1,r.length==32&&(n.push(new mt(r,i)),r=[],i=-1);return i>-1&&n.push(new mt(r,i)),n}}class gr extends Ge{constructor(e,n){super(),this.children=e,this.length=n,this.lines=0;for(let r of e)this.lines+=r.lines}lineInner(e,n,r,i){for(let o=0;;o++){let s=this.children[o],a=i+s.length,c=r+s.lines-1;if((n?c:a)>=e)return s.lineInner(e,n,r,i);i=a+1,r=c+1}}decompose(e,n,r,i){for(let o=0,s=0;s<=n&&o<this.children.length;o++){let a=this.children[o],c=s+a.length;if(e<=c&&n>=s){let h=i&((s<=e?1:0)|(c>=n?2:0));s>=e&&c<=n&&!h?r.push(a):a.decompose(e-s,n-s,r,h)}s=c+1}}replace(e,n,r){if([e,n]=xs(this,e,n),r.lines<this.lines)for(let i=0,o=0;i<this.children.length;i++){let s=this.children[i],a=o+s.length;if(e>=o&&n<=a){let c=s.replace(e-o,n-o,r),h=this.lines-s.lines+c.lines;if(c.lines<h>>4&&c.lines>h>>6){let f=this.children.slice();return f[i]=c,new gr(f,this.length-(n-e)+r.length)}return super.replace(o,a,c)}o=a+1}return super.replace(e,n,r)}sliceString(e,n=this.length,r=`
49
- `){[e,n]=xs(this,e,n);let i="";for(let o=0,s=0;o<this.children.length&&s<=n;o++){let a=this.children[o],c=s+a.length;s>e&&o&&(i+=r),e<c&&n>s&&(i+=a.sliceString(e-s,n-s,r)),s=c+1}return i}flatten(e){for(let n of this.children)n.flatten(e)}scanIdentical(e,n){if(!(e instanceof gr))return 0;let r=0,[i,o,s,a]=n>0?[0,0,this.children.length,e.children.length]:[this.children.length-1,e.children.length-1,-1,-1];for(;;i+=n,o+=n){if(i==s||o==a)return r;let c=this.children[i],h=e.children[o];if(c!=h)return r+c.scanIdentical(h,n);r+=c.length+1}}static from(e,n=e.reduce((r,i)=>r+i.length+1,-1)){let r=0;for(let v of e)r+=v.lines;if(r<32){let v=[];for(let w of e)w.flatten(v);return new mt(v,n)}let i=Math.max(32,r>>5),o=i<<1,s=i>>1,a=[],c=0,h=-1,f=[];function d(v){let w;if(v.lines>o&&v instanceof gr)for(let x of v.children)d(x);else v.lines>s&&(c>s||!c)?(m(),a.push(v)):v instanceof mt&&c&&(w=f[f.length-1])instanceof mt&&v.lines+w.lines<=32?(c+=v.lines,h+=v.length+1,f[f.length-1]=new mt(w.text.concat(v.text),w.length+1+v.length)):(c+v.lines>i&&m(),c+=v.lines,h+=v.length+1,f.push(v))}function m(){c!=0&&(a.push(f.length==1?f[0]:gr.from(f,h)),h=-1,c=f.length=0)}for(let v of e)d(v);return m(),a.length==1?a[0]:new gr(a,n)}}Ge.empty=new mt([""],0);function vH(t){let e=-1;for(let n of t)e+=n.length+1;return e}function Jc(t,e,n=0,r=1e9){for(let i=0,o=0,s=!0;o<t.length&&i<=r;o++){let a=t[o],c=i+a.length;c>=n&&(c>r&&(a=a.slice(0,r-i)),i<n&&(a=a.slice(n-i)),s?(e[e.length-1]+=a,s=!1):e.push(a)),i=c+1}return e}function p5(t,e,n){return Jc(t,[""],e,n)}class xa{constructor(e,n=1){this.dir=n,this.done=!1,this.lineBreak=!1,this.value="",this.nodes=[e],this.offsets=[n>0?1:(e instanceof mt?e.text.length:e.children.length)<<1]}nextInner(e,n){for(this.done=this.lineBreak=!1;;){let r=this.nodes.length-1,i=this.nodes[r],o=this.offsets[r],s=o>>1,a=i instanceof mt?i.text.length:i.children.length;if(s==(n>0?a:0)){if(r==0)return this.done=!0,this.value="",this;n>0&&this.offsets[r-1]++,this.nodes.pop(),this.offsets.pop()}else if((o&1)==(n>0?0:1)){if(this.offsets[r]+=n,e==0)return this.lineBreak=!0,this.value=`
50
- `,this;e--}else if(i instanceof mt){let c=i.text[s+(n<0?-1:0)];if(this.offsets[r]+=n,c.length>Math.max(0,e))return this.value=e==0?c:n>0?c.slice(e):c.slice(0,c.length-e),this;e-=c.length}else{let c=i.children[s+(n<0?-1:0)];e>c.length?(e-=c.length,this.offsets[r]+=n):(n<0&&this.offsets[r]--,this.nodes.push(c),this.offsets.push(n>0?1:(c instanceof mt?c.text.length:c.children.length)<<1))}}}next(e=0){return e<0&&(this.nextInner(-e,-this.dir),e=this.value.length),this.nextInner(e,this.dir)}}class yy{constructor(e,n,r){this.value="",this.done=!1,this.cursor=new xa(e,n>r?-1:1),this.pos=n>r?e.length:0,this.from=Math.min(n,r),this.to=Math.max(n,r)}nextInner(e,n){if(n<0?this.pos<=this.from:this.pos>=this.to)return this.value="",this.done=!0,this;e+=Math.max(0,n<0?this.pos-this.to:this.from-this.pos);let r=n<0?this.pos-this.from:this.to-this.pos;e>r&&(e=r),r-=e;let{value:i}=this.cursor.next(e);return this.pos+=(i.length+e)*n,this.value=i.length<=r?i:n<0?i.slice(i.length-r):i.slice(0,r),this.done=!this.value,this}next(e=0){return e<0?e=Math.max(e,this.from-this.pos):e>0&&(e=Math.min(e,this.to-this.pos)),this.nextInner(e,this.cursor.dir)}get lineBreak(){return this.cursor.lineBreak&&this.value!=""}}class Cy{constructor(e){this.inner=e,this.afterBreak=!0,this.value="",this.done=!1}next(e=0){let{done:n,lineBreak:r,value:i}=this.inner.next(e);return n&&this.afterBreak?(this.value="",this.afterBreak=!1):n?(this.done=!0,this.value=""):r?this.afterBreak?this.value="":(this.afterBreak=!0,this.next()):(this.value=i,this.afterBreak=!1),this}get lineBreak(){return!1}}typeof Symbol<"u"&&(Ge.prototype[Symbol.iterator]=function(){return this.iter()},xa.prototype[Symbol.iterator]=yy.prototype[Symbol.iterator]=Cy.prototype[Symbol.iterator]=function(){return this});class bH{constructor(e,n,r,i){this.from=e,this.to=n,this.number=r,this.text=i}get length(){return this.to-this.from}}function xs(t,e,n){return e=Math.max(0,Math.min(t.length,e)),[e,Math.max(e,Math.min(t.length,n))]}function Ht(t,e,n=!0,r=!0){return mH(t,e,n,r)}function wH(t){return t>=56320&&t<57344}function xH(t){return t>=55296&&t<56320}function ln(t,e){let n=t.charCodeAt(e);if(!xH(n)||e+1==t.length)return n;let r=t.charCodeAt(e+1);return wH(r)?(n-55296<<10)+(r-56320)+65536:n}function em(t){return t<=65535?String.fromCharCode(t):(t-=65536,String.fromCharCode((t>>10)+55296,(t&1023)+56320))}function mr(t){return t<65536?1:2}const F0=/\r\n?|\n/;var Jt=function(t){return t[t.Simple=0]="Simple",t[t.TrackDel=1]="TrackDel",t[t.TrackBefore=2]="TrackBefore",t[t.TrackAfter=3]="TrackAfter",t}(Jt||(Jt={}));class xr{constructor(e){this.sections=e}get length(){let e=0;for(let n=0;n<this.sections.length;n+=2)e+=this.sections[n];return e}get newLength(){let e=0;for(let n=0;n<this.sections.length;n+=2){let r=this.sections[n+1];e+=r<0?this.sections[n]:r}return e}get empty(){return this.sections.length==0||this.sections.length==2&&this.sections[1]<0}iterGaps(e){for(let n=0,r=0,i=0;n<this.sections.length;){let o=this.sections[n++],s=this.sections[n++];s<0?(e(r,i,o),i+=o):i+=s,r+=o}}iterChangedRanges(e,n=!1){V0(this,e,n)}get invertedDesc(){let e=[];for(let n=0;n<this.sections.length;){let r=this.sections[n++],i=this.sections[n++];i<0?e.push(r,i):e.push(i,r)}return new xr(e)}composeDesc(e){return this.empty?e:e.empty?this:$y(this,e)}mapDesc(e,n=!1){return e.empty?this:H0(this,e,n)}mapPos(e,n=-1,r=Jt.Simple){let i=0,o=0;for(let s=0;s<this.sections.length;){let a=this.sections[s++],c=this.sections[s++],h=i+a;if(c<0){if(h>e)return o+(e-i);o+=a}else{if(r!=Jt.Simple&&h>=e&&(r==Jt.TrackDel&&i<e&&h>e||r==Jt.TrackBefore&&i<e||r==Jt.TrackAfter&&h>e))return null;if(h>e||h==e&&n<0&&!a)return e==i||n<0?o:o+c;o+=c}i=h}if(e>i)throw new RangeError(`Position ${e} is out of range for changeset of length ${i}`);return o}touchesRange(e,n=e){for(let r=0,i=0;r<this.sections.length&&i<=n;){let o=this.sections[r++],s=this.sections[r++],a=i+o;if(s>=0&&i<=n&&a>=e)return i<e&&a>n?"cover":!0;i=a}return!1}toString(){let e="";for(let n=0;n<this.sections.length;){let r=this.sections[n++],i=this.sections[n++];e+=(e?" ":"")+r+(i>=0?":"+i:"")}return e}toJSON(){return this.sections}static fromJSON(e){if(!Array.isArray(e)||e.length%2||e.some(n=>typeof n!="number"))throw new RangeError("Invalid JSON representation of ChangeDesc");return new xr(e)}static create(e){return new xr(e)}}class kt extends xr{constructor(e,n){super(e),this.inserted=n}apply(e){if(this.length!=e.length)throw new RangeError("Applying change set to a document with the wrong length");return V0(this,(n,r,i,o,s)=>e=e.replace(i,i+(r-n),s),!1),e}mapDesc(e,n=!1){return H0(this,e,n,!0)}invert(e){let n=this.sections.slice(),r=[];for(let i=0,o=0;i<n.length;i+=2){let s=n[i],a=n[i+1];if(a>=0){n[i]=a,n[i+1]=s;let c=i>>1;for(;r.length<c;)r.push(Ge.empty);r.push(s?e.slice(o,o+s):Ge.empty)}o+=s}return new kt(n,r)}compose(e){return this.empty?e:e.empty?this:$y(this,e,!0)}map(e,n=!1){return e.empty?this:H0(this,e,n,!0)}iterChanges(e,n=!1){V0(this,e,n)}get desc(){return xr.create(this.sections)}filter(e){let n=[],r=[],i=[],o=new Ia(this);e:for(let s=0,a=0;;){let c=s==e.length?1e9:e[s++];for(;a<c||a==c&&o.len==0;){if(o.done)break e;let f=Math.min(o.len,c-a);Ut(i,f,-1);let d=o.ins==-1?-1:o.off==0?o.ins:0;Ut(n,f,d),d>0&&Ci(r,n,o.text),o.forward(f),a+=f}let h=e[s++];for(;a<h;){if(o.done)break e;let f=Math.min(o.len,h-a);Ut(n,f,-1),Ut(i,f,o.ins==-1?-1:o.off==0?o.ins:0),o.forward(f),a+=f}}return{changes:new kt(n,r),filtered:xr.create(i)}}toJSON(){let e=[];for(let n=0;n<this.sections.length;n+=2){let r=this.sections[n],i=this.sections[n+1];i<0?e.push(r):i==0?e.push([r]):e.push([r].concat(this.inserted[n>>1].toJSON()))}return e}static of(e,n,r){let i=[],o=[],s=0,a=null;function c(f=!1){if(!f&&!i.length)return;s<n&&Ut(i,n-s,-1);let d=new kt(i,o);a=a?a.compose(d.map(a)):d,i=[],o=[],s=0}function h(f){if(Array.isArray(f))for(let d of f)h(d);else if(f instanceof kt){if(f.length!=n)throw new RangeError(`Mismatched change set length (got ${f.length}, expected ${n})`);c(),a=a?a.compose(f.map(a)):f}else{let{from:d,to:m=d,insert:v}=f;if(d>m||d<0||m>n)throw new RangeError(`Invalid change range ${d} to ${m} (in doc of length ${n})`);let w=v?typeof v=="string"?Ge.of(v.split(r||F0)):v:Ge.empty,x=w.length;if(d==m&&x==0)return;d<s&&c(),d>s&&Ut(i,d-s,-1),Ut(i,m-d,x),Ci(o,i,w),s=m}}return h(e),c(!a),a}static empty(e){return new kt(e?[e,-1]:[],[])}static fromJSON(e){if(!Array.isArray(e))throw new RangeError("Invalid JSON representation of ChangeSet");let n=[],r=[];for(let i=0;i<e.length;i++){let o=e[i];if(typeof o=="number")n.push(o,-1);else{if(!Array.isArray(o)||typeof o[0]!="number"||o.some((s,a)=>a&&typeof s!="string"))throw new RangeError("Invalid JSON representation of ChangeSet");if(o.length==1)n.push(o[0],0);else{for(;r.length<i;)r.push(Ge.empty);r[i]=Ge.of(o.slice(1)),n.push(o[0],r[i].length)}}}return new kt(n,r)}static createSet(e,n){return new kt(e,n)}}function Ut(t,e,n,r=!1){if(e==0&&n<=0)return;let i=t.length-2;i>=0&&n<=0&&n==t[i+1]?t[i]+=e:i>=0&&e==0&&t[i]==0?t[i+1]+=n:r?(t[i]+=e,t[i+1]+=n):t.push(e,n)}function Ci(t,e,n){if(n.length==0)return;let r=e.length-2>>1;if(r<t.length)t[t.length-1]=t[t.length-1].append(n);else{for(;t.length<r;)t.push(Ge.empty);t.push(n)}}function V0(t,e,n){let r=t.inserted;for(let i=0,o=0,s=0;s<t.sections.length;){let a=t.sections[s++],c=t.sections[s++];if(c<0)i+=a,o+=a;else{let h=i,f=o,d=Ge.empty;for(;h+=a,f+=c,c&&r&&(d=d.append(r[s-2>>1])),!(n||s==t.sections.length||t.sections[s+1]<0);)a=t.sections[s++],c=t.sections[s++];e(i,h,o,f,d),i=h,o=f}}}function H0(t,e,n,r=!1){let i=[],o=r?[]:null,s=new Ia(t),a=new Ia(e);for(let c=-1;;){if(s.done&&a.len||a.done&&s.len)throw new Error("Mismatched change set lengths");if(s.ins==-1&&a.ins==-1){let h=Math.min(s.len,a.len);Ut(i,h,-1),s.forward(h),a.forward(h)}else if(a.ins>=0&&(s.ins<0||c==s.i||s.off==0&&(a.len<s.len||a.len==s.len&&!n))){let h=a.len;for(Ut(i,a.ins,-1);h;){let f=Math.min(s.len,h);s.ins>=0&&c<s.i&&s.len<=f&&(Ut(i,0,s.ins),o&&Ci(o,i,s.text),c=s.i),s.forward(f),h-=f}a.next()}else if(s.ins>=0){let h=0,f=s.len;for(;f;)if(a.ins==-1){let d=Math.min(f,a.len);h+=d,f-=d,a.forward(d)}else if(a.ins==0&&a.len<f)f-=a.len,a.next();else break;Ut(i,h,c<s.i?s.ins:0),o&&c<s.i&&Ci(o,i,s.text),c=s.i,s.forward(s.len-f)}else{if(s.done&&a.done)return o?kt.createSet(i,o):xr.create(i);throw new Error("Mismatched change set lengths")}}}function $y(t,e,n=!1){let r=[],i=n?[]:null,o=new Ia(t),s=new Ia(e);for(let a=!1;;){if(o.done&&s.done)return i?kt.createSet(r,i):xr.create(r);if(o.ins==0)Ut(r,o.len,0,a),o.next();else if(s.len==0&&!s.done)Ut(r,0,s.ins,a),i&&Ci(i,r,s.text),s.next();else{if(o.done||s.done)throw new Error("Mismatched change set lengths");{let c=Math.min(o.len2,s.len),h=r.length;if(o.ins==-1){let f=s.ins==-1?-1:s.off?0:s.ins;Ut(r,c,f,a),i&&f&&Ci(i,r,s.text)}else s.ins==-1?(Ut(r,o.off?0:o.len,c,a),i&&Ci(i,r,o.textBit(c))):(Ut(r,o.off?0:o.len,s.off?0:s.ins,a),i&&!s.off&&Ci(i,r,s.text));a=(o.ins>c||s.ins>=0&&s.len>c)&&(a||r.length>h),o.forward2(c),s.forward(c)}}}}class Ia{constructor(e){this.set=e,this.i=0,this.next()}next(){let{sections:e}=this.set;this.i<e.length?(this.len=e[this.i++],this.ins=e[this.i++]):(this.len=0,this.ins=-2),this.off=0}get done(){return this.ins==-2}get len2(){return this.ins<0?this.len:this.ins}get text(){let{inserted:e}=this.set,n=this.i-2>>1;return n>=e.length?Ge.empty:e[n]}textBit(e){let{inserted:n}=this.set,r=this.i-2>>1;return r>=n.length&&!e?Ge.empty:n[r].slice(this.off,e==null?void 0:this.off+e)}forward(e){e==this.len?this.next():(this.len-=e,this.off+=e)}forward2(e){this.ins==-1?this.forward(e):e==this.ins?this.next():(this.ins-=e,this.off+=e)}}class ro{constructor(e,n,r){this.from=e,this.to=n,this.flags=r}get anchor(){return this.flags&32?this.to:this.from}get head(){return this.flags&32?this.from:this.to}get empty(){return this.from==this.to}get assoc(){return this.flags&8?-1:this.flags&16?1:0}get bidiLevel(){let e=this.flags&7;return e==7?null:e}get goalColumn(){let e=this.flags>>6;return e==16777215?void 0:e}map(e,n=-1){let r,i;return this.empty?r=i=e.mapPos(this.from,n):(r=e.mapPos(this.from,1),i=e.mapPos(this.to,-1)),r==this.from&&i==this.to?this:new ro(r,i,this.flags)}extend(e,n=e){if(e<=this.anchor&&n>=this.anchor)return Q.range(e,n);let r=Math.abs(e-this.anchor)>Math.abs(n-this.anchor)?e:n;return Q.range(this.anchor,r)}eq(e,n=!1){return this.anchor==e.anchor&&this.head==e.head&&(!n||!this.empty||this.assoc==e.assoc)}toJSON(){return{anchor:this.anchor,head:this.head}}static fromJSON(e){if(!e||typeof e.anchor!="number"||typeof e.head!="number")throw new RangeError("Invalid JSON representation for SelectionRange");return Q.range(e.anchor,e.head)}static create(e,n,r){return new ro(e,n,r)}}class Q{constructor(e,n){this.ranges=e,this.mainIndex=n}map(e,n=-1){return e.empty?this:Q.create(this.ranges.map(r=>r.map(e,n)),this.mainIndex)}eq(e,n=!1){if(this.ranges.length!=e.ranges.length||this.mainIndex!=e.mainIndex)return!1;for(let r=0;r<this.ranges.length;r++)if(!this.ranges[r].eq(e.ranges[r],n))return!1;return!0}get main(){return this.ranges[this.mainIndex]}asSingle(){return this.ranges.length==1?this:new Q([this.main],0)}addRange(e,n=!0){return Q.create([e].concat(this.ranges),n?0:this.mainIndex+1)}replaceRange(e,n=this.mainIndex){let r=this.ranges.slice();return r[n]=e,Q.create(r,this.mainIndex)}toJSON(){return{ranges:this.ranges.map(e=>e.toJSON()),main:this.mainIndex}}static fromJSON(e){if(!e||!Array.isArray(e.ranges)||typeof e.main!="number"||e.main>=e.ranges.length)throw new RangeError("Invalid JSON representation for EditorSelection");return new Q(e.ranges.map(n=>ro.fromJSON(n)),e.main)}static single(e,n=e){return new Q([Q.range(e,n)],0)}static create(e,n=0){if(e.length==0)throw new RangeError("A selection needs at least one range");for(let r=0,i=0;i<e.length;i++){let o=e[i];if(o.empty?o.from<=r:o.from<r)return Q.normalized(e.slice(),n);r=o.to}return new Q(e,n)}static cursor(e,n=0,r,i){return ro.create(e,e,(n==0?0:n<0?8:16)|(r==null?7:Math.min(6,r))|(i??16777215)<<6)}static range(e,n,r,i){let o=(r??16777215)<<6|(i==null?7:Math.min(6,i));return n<e?ro.create(n,e,48|o):ro.create(e,n,(n>e?8:0)|o)}static normalized(e,n=0){let r=e[n];e.sort((i,o)=>i.from-o.from),n=e.indexOf(r);for(let i=1;i<e.length;i++){let o=e[i],s=e[i-1];if(o.empty?o.from<=s.to:o.from<s.to){let a=s.from,c=Math.max(o.to,s.to);i<=n&&n--,e.splice(--i,2,o.anchor>o.head?Q.range(c,a):Q.range(a,c))}}return new Q(e,n)}}function Sy(t,e){for(let n of t.ranges)if(n.to>e)throw new RangeError("Selection points outside of document")}let tm=0;class fe{constructor(e,n,r,i,o){this.combine=e,this.compareInput=n,this.compare=r,this.isStatic=i,this.id=tm++,this.default=e([]),this.extensions=typeof o=="function"?o(this):o}get reader(){return this}static define(e={}){return new fe(e.combine||(n=>n),e.compareInput||((n,r)=>n===r),e.compare||(e.combine?(n,r)=>n===r:nm),!!e.static,e.enables)}of(e){return new eu([],this,0,e)}compute(e,n){if(this.isStatic)throw new Error("Can't compute a static facet");return new eu(e,this,1,n)}computeN(e,n){if(this.isStatic)throw new Error("Can't compute a static facet");return new eu(e,this,2,n)}from(e,n){return n||(n=r=>r),this.compute([e],r=>n(r.field(e)))}}function nm(t,e){return t==e||t.length==e.length&&t.every((n,r)=>n===e[r])}class eu{constructor(e,n,r,i){this.dependencies=e,this.facet=n,this.type=r,this.value=i,this.id=tm++}dynamicSlot(e){var n;let r=this.value,i=this.facet.compareInput,o=this.id,s=e[o]>>1,a=this.type==2,c=!1,h=!1,f=[];for(let d of this.dependencies)d=="doc"?c=!0:d=="selection"?h=!0:((n=e[d.id])!==null&&n!==void 0?n:1)&1||f.push(e[d.id]);return{create(d){return d.values[s]=r(d),1},update(d,m){if(c&&m.docChanged||h&&(m.docChanged||m.selection)||P0(d,f)){let v=r(d);if(a?!v5(v,d.values[s],i):!i(v,d.values[s]))return d.values[s]=v,1}return 0},reconfigure:(d,m)=>{let v,w=m.config.address[o];if(w!=null){let x=ku(m,w);if(this.dependencies.every(C=>C instanceof fe?m.facet(C)===d.facet(C):C instanceof Bt?m.field(C,!1)==d.field(C,!1):!0)||(a?v5(v=r(d),x,i):i(v=r(d),x)))return d.values[s]=x,0}else v=r(d);return d.values[s]=v,1}}}}function v5(t,e,n){if(t.length!=e.length)return!1;for(let r=0;r<t.length;r++)if(!n(t[r],e[r]))return!1;return!0}function P0(t,e){let n=!1;for(let r of e)ya(t,r)&1&&(n=!0);return n}function yH(t,e,n){let r=n.map(c=>t[c.id]),i=n.map(c=>c.type),o=r.filter(c=>!(c&1)),s=t[e.id]>>1;function a(c){let h=[];for(let f=0;f<r.length;f++){let d=ku(c,r[f]);if(i[f]==2)for(let m of d)h.push(m);else h.push(d)}return e.combine(h)}return{create(c){for(let h of r)ya(c,h);return c.values[s]=a(c),1},update(c,h){if(!P0(c,o))return 0;let f=a(c);return e.compare(f,c.values[s])?0:(c.values[s]=f,1)},reconfigure(c,h){let f=P0(c,r),d=h.config.facets[e.id],m=h.facet(e);if(d&&!f&&nm(n,d))return c.values[s]=m,0;let v=a(c);return e.compare(v,m)?(c.values[s]=m,0):(c.values[s]=v,1)}}}const Tc=fe.define({static:!0});class Bt{constructor(e,n,r,i,o){this.id=e,this.createF=n,this.updateF=r,this.compareF=i,this.spec=o,this.provides=void 0}static define(e){let n=new Bt(tm++,e.create,e.update,e.compare||((r,i)=>r===i),e);return e.provide&&(n.provides=e.provide(n)),n}create(e){let n=e.facet(Tc).find(r=>r.field==this);return(n?.create||this.createF)(e)}slot(e){let n=e[this.id]>>1;return{create:r=>(r.values[n]=this.create(r),1),update:(r,i)=>{let o=r.values[n],s=this.updateF(o,i);return this.compareF(o,s)?0:(r.values[n]=s,1)},reconfigure:(r,i)=>{let o=r.facet(Tc),s=i.facet(Tc),a;return(a=o.find(c=>c.field==this))&&a!=s.find(c=>c.field==this)?(r.values[n]=a.create(r),1):i.config.address[this.id]!=null?(r.values[n]=i.field(this),0):(r.values[n]=this.create(r),1)}}}init(e){return[this,Tc.of({field:this,create:e})]}get extension(){return this}}const eo={lowest:4,low:3,default:2,high:1,highest:0};function aa(t){return e=>new Ay(e,t)}const Ro={highest:aa(eo.highest),high:aa(eo.high),default:aa(eo.default),low:aa(eo.low),lowest:aa(eo.lowest)};class Ay{constructor(e,n){this.inner=e,this.prec=n}}class xh{of(e){return new W0(this,e)}reconfigure(e){return xh.reconfigure.of({compartment:this,extension:e})}get(e){return e.config.compartments.get(this)}}class W0{constructor(e,n){this.compartment=e,this.inner=n}}class Ru{constructor(e,n,r,i,o,s){for(this.base=e,this.compartments=n,this.dynamicSlots=r,this.address=i,this.staticValues=o,this.facets=s,this.statusTemplate=[];this.statusTemplate.length<r.length;)this.statusTemplate.push(0)}staticFacet(e){let n=this.address[e.id];return n==null?e.default:this.staticValues[n>>1]}static resolve(e,n,r){let i=[],o=Object.create(null),s=new Map;for(let m of CH(e,n,s))m instanceof Bt?i.push(m):(o[m.facet.id]||(o[m.facet.id]=[])).push(m);let a=Object.create(null),c=[],h=[];for(let m of i)a[m.id]=h.length<<1,h.push(v=>m.slot(v));let f=r?.config.facets;for(let m in o){let v=o[m],w=v[0].facet,x=f&&f[m]||[];if(v.every(C=>C.type==0))if(a[w.id]=c.length<<1|1,nm(x,v))c.push(r.facet(w));else{let C=w.combine(v.map(S=>S.value));c.push(r&&w.compare(C,r.facet(w))?r.facet(w):C)}else{for(let C of v)C.type==0?(a[C.id]=c.length<<1|1,c.push(C.value)):(a[C.id]=h.length<<1,h.push(S=>C.dynamicSlot(S)));a[w.id]=h.length<<1,h.push(C=>yH(C,w,v))}}let d=h.map(m=>m(a));return new Ru(e,s,d,a,c,o)}}function CH(t,e,n){let r=[[],[],[],[],[]],i=new Map;function o(s,a){let c=i.get(s);if(c!=null){if(c<=a)return;let h=r[c].indexOf(s);h>-1&&r[c].splice(h,1),s instanceof W0&&n.delete(s.compartment)}if(i.set(s,a),Array.isArray(s))for(let h of s)o(h,a);else if(s instanceof W0){if(n.has(s.compartment))throw new RangeError("Duplicate use of compartment in extensions");let h=e.get(s.compartment)||s.inner;n.set(s.compartment,h),o(h,a)}else if(s instanceof Ay)o(s.inner,s.prec);else if(s instanceof Bt)r[a].push(s),s.provides&&o(s.provides,a);else if(s instanceof eu)r[a].push(s),s.facet.extensions&&o(s.facet.extensions,eo.default);else{let h=s.extension;if(!h)throw new Error(`Unrecognized extension value in extension set (${s}). This sometimes happens because multiple instances of @codemirror/state are loaded, breaking instanceof checks.`);o(h,a)}}return o(t,eo.default),r.reduce((s,a)=>s.concat(a))}function ya(t,e){if(e&1)return 2;let n=e>>1,r=t.status[n];if(r==4)throw new Error("Cyclic dependency between fields and/or facets");if(r&2)return r;t.status[n]=4;let i=t.computeSlot(t,t.config.dynamicSlots[n]);return t.status[n]=2|i}function ku(t,e){return e&1?t.config.staticValues[e>>1]:t.values[e>>1]}const Ry=fe.define(),z0=fe.define({combine:t=>t.some(e=>e),static:!0}),ky=fe.define({combine:t=>t.length?t[0]:void 0,static:!0}),Ty=fe.define(),My=fe.define(),Ey=fe.define(),Oy=fe.define({combine:t=>t.length?t[0]:!1});class Tr{constructor(e,n){this.type=e,this.value=n}static define(){return new $H}}class $H{of(e){return new Tr(this,e)}}class SH{constructor(e){this.map=e}of(e){return new Me(this,e)}}class Me{constructor(e,n){this.type=e,this.value=n}map(e){let n=this.type.map(this.value,e);return n===void 0?void 0:n==this.value?this:new Me(this.type,n)}is(e){return this.type==e}static define(e={}){return new SH(e.map||(n=>n))}static mapEffects(e,n){if(!e.length)return e;let r=[];for(let i of e){let o=i.map(n);o&&r.push(o)}return r}}Me.reconfigure=Me.define();Me.appendConfig=Me.define();class Tt{constructor(e,n,r,i,o,s){this.startState=e,this.changes=n,this.selection=r,this.effects=i,this.annotations=o,this.scrollIntoView=s,this._doc=null,this._state=null,r&&Sy(r,n.newLength),o.some(a=>a.type==Tt.time)||(this.annotations=o.concat(Tt.time.of(Date.now())))}static create(e,n,r,i,o,s){return new Tt(e,n,r,i,o,s)}get newDoc(){return this._doc||(this._doc=this.changes.apply(this.startState.doc))}get newSelection(){return this.selection||this.startState.selection.map(this.changes)}get state(){return this._state||this.startState.applyTransaction(this),this._state}annotation(e){for(let n of this.annotations)if(n.type==e)return n.value}get docChanged(){return!this.changes.empty}get reconfigured(){return this.startState.config!=this.state.config}isUserEvent(e){let n=this.annotation(Tt.userEvent);return!!(n&&(n==e||n.length>e.length&&n.slice(0,e.length)==e&&n[e.length]=="."))}}Tt.time=Tr.define();Tt.userEvent=Tr.define();Tt.addToHistory=Tr.define();Tt.remote=Tr.define();function AH(t,e){let n=[];for(let r=0,i=0;;){let o,s;if(r<t.length&&(i==e.length||e[i]>=t[r]))o=t[r++],s=t[r++];else if(i<e.length)o=e[i++],s=e[i++];else return n;!n.length||n[n.length-1]<o?n.push(o,s):n[n.length-1]<s&&(n[n.length-1]=s)}}function Dy(t,e,n){var r;let i,o,s;return n?(i=e.changes,o=kt.empty(e.changes.length),s=t.changes.compose(e.changes)):(i=e.changes.map(t.changes),o=t.changes.mapDesc(e.changes,!0),s=t.changes.compose(i)),{changes:s,selection:e.selection?e.selection.map(o):(r=t.selection)===null||r===void 0?void 0:r.map(i),effects:Me.mapEffects(t.effects,i).concat(Me.mapEffects(e.effects,o)),annotations:t.annotations.length?t.annotations.concat(e.annotations):e.annotations,scrollIntoView:t.scrollIntoView||e.scrollIntoView}}function U0(t,e,n){let r=e.selection,i=ls(e.annotations);return e.userEvent&&(i=i.concat(Tt.userEvent.of(e.userEvent))),{changes:e.changes instanceof kt?e.changes:kt.of(e.changes||[],n,t.facet(ky)),selection:r&&(r instanceof Q?r:Q.single(r.anchor,r.head)),effects:ls(e.effects),annotations:i,scrollIntoView:!!e.scrollIntoView}}function Iy(t,e,n){let r=U0(t,e.length?e[0]:{},t.doc.length);e.length&&e[0].filter===!1&&(n=!1);for(let o=1;o<e.length;o++){e[o].filter===!1&&(n=!1);let s=!!e[o].sequential;r=Dy(r,U0(t,e[o],s?r.changes.newLength:t.doc.length),s)}let i=Tt.create(t,r.changes,r.selection,r.effects,r.annotations,r.scrollIntoView);return kH(n?RH(i):i)}function RH(t){let e=t.startState,n=!0;for(let i of e.facet(Ty)){let o=i(t);if(o===!1){n=!1;break}Array.isArray(o)&&(n=n===!0?o:AH(n,o))}if(n!==!0){let i,o;if(n===!1)o=t.changes.invertedDesc,i=kt.empty(e.doc.length);else{let s=t.changes.filter(n);i=s.changes,o=s.filtered.mapDesc(s.changes).invertedDesc}t=Tt.create(e,i,t.selection&&t.selection.map(o),Me.mapEffects(t.effects,o),t.annotations,t.scrollIntoView)}let r=e.facet(My);for(let i=r.length-1;i>=0;i--){let o=r[i](t);o instanceof Tt?t=o:Array.isArray(o)&&o.length==1&&o[0]instanceof Tt?t=o[0]:t=Iy(e,ls(o),!1)}return t}function kH(t){let e=t.startState,n=e.facet(Ey),r=t;for(let i=n.length-1;i>=0;i--){let o=n[i](t);o&&Object.keys(o).length&&(r=Dy(r,U0(e,o,t.changes.newLength),!0))}return r==t?t:Tt.create(e,t.changes,t.selection,r.effects,r.annotations,r.scrollIntoView)}const TH=[];function ls(t){return t==null?TH:Array.isArray(t)?t:[t]}var lt=function(t){return t[t.Word=0]="Word",t[t.Space=1]="Space",t[t.Other=2]="Other",t}(lt||(lt={}));const MH=/[\u00df\u0587\u0590-\u05f4\u0600-\u06ff\u3040-\u309f\u30a0-\u30ff\u3400-\u4db5\u4e00-\u9fcc\uac00-\ud7af]/;let q0;try{q0=new RegExp("[\\p{Alphabetic}\\p{Number}_]","u")}catch{}function EH(t){if(q0)return q0.test(t);for(let e=0;e<t.length;e++){let n=t[e];if(/\w/.test(n)||n>"€"&&(n.toUpperCase()!=n.toLowerCase()||MH.test(n)))return!0}return!1}function OH(t){return e=>{if(!/\S/.test(e))return lt.Space;if(EH(e))return lt.Word;for(let n=0;n<t.length;n++)if(e.indexOf(t[n])>-1)return lt.Word;return lt.Other}}class qe{constructor(e,n,r,i,o,s){this.config=e,this.doc=n,this.selection=r,this.values=i,this.status=e.statusTemplate.slice(),this.computeSlot=o,s&&(s._state=this);for(let a=0;a<this.config.dynamicSlots.length;a++)ya(this,a<<1);this.computeSlot=null}field(e,n=!0){let r=this.config.address[e.id];if(r==null){if(n)throw new RangeError("Field is not present in this state");return}return ya(this,r),ku(this,r)}update(...e){return Iy(this,e,!0)}applyTransaction(e){let n=this.config,{base:r,compartments:i}=n;for(let a of e.effects)a.is(xh.reconfigure)?(n&&(i=new Map,n.compartments.forEach((c,h)=>i.set(h,c)),n=null),i.set(a.value.compartment,a.value.extension)):a.is(Me.reconfigure)?(n=null,r=a.value):a.is(Me.appendConfig)&&(n=null,r=ls(r).concat(a.value));let o;n?o=e.startState.values.slice():(n=Ru.resolve(r,i,this),o=new qe(n,this.doc,this.selection,n.dynamicSlots.map(()=>null),(c,h)=>h.reconfigure(c,this),null).values);let s=e.startState.facet(z0)?e.newSelection:e.newSelection.asSingle();new qe(n,e.newDoc,s,o,(a,c)=>c.update(a,e),e)}replaceSelection(e){return typeof e=="string"&&(e=this.toText(e)),this.changeByRange(n=>({changes:{from:n.from,to:n.to,insert:e},range:Q.cursor(n.from+e.length)}))}changeByRange(e){let n=this.selection,r=e(n.ranges[0]),i=this.changes(r.changes),o=[r.range],s=ls(r.effects);for(let a=1;a<n.ranges.length;a++){let c=e(n.ranges[a]),h=this.changes(c.changes),f=h.map(i);for(let m=0;m<a;m++)o[m]=o[m].map(f);let d=i.mapDesc(h,!0);o.push(c.range.map(d)),i=i.compose(f),s=Me.mapEffects(s,f).concat(Me.mapEffects(ls(c.effects),d))}return{changes:i,selection:Q.create(o,n.mainIndex),effects:s}}changes(e=[]){return e instanceof kt?e:kt.of(e,this.doc.length,this.facet(qe.lineSeparator))}toText(e){return Ge.of(e.split(this.facet(qe.lineSeparator)||F0))}sliceDoc(e=0,n=this.doc.length){return this.doc.sliceString(e,n,this.lineBreak)}facet(e){let n=this.config.address[e.id];return n==null?e.default:(ya(this,n),ku(this,n))}toJSON(e){let n={doc:this.sliceDoc(),selection:this.selection.toJSON()};if(e)for(let r in e){let i=e[r];i instanceof Bt&&this.config.address[i.id]!=null&&(n[r]=i.spec.toJSON(this.field(e[r]),this))}return n}static fromJSON(e,n={},r){if(!e||typeof e.doc!="string")throw new RangeError("Invalid JSON representation for EditorState");let i=[];if(r){for(let o in r)if(Object.prototype.hasOwnProperty.call(e,o)){let s=r[o],a=e[o];i.push(s.init(c=>s.spec.fromJSON(a,c)))}}return qe.create({doc:e.doc,selection:Q.fromJSON(e.selection),extensions:n.extensions?i.concat([n.extensions]):i})}static create(e={}){let n=Ru.resolve(e.extensions||[],new Map),r=e.doc instanceof Ge?e.doc:Ge.of((e.doc||"").split(n.staticFacet(qe.lineSeparator)||F0)),i=e.selection?e.selection instanceof Q?e.selection:Q.single(e.selection.anchor,e.selection.head):Q.single(0);return Sy(i,r.length),n.staticFacet(z0)||(i=i.asSingle()),new qe(n,r,i,n.dynamicSlots.map(()=>null),(o,s)=>s.create(o),null)}get tabSize(){return this.facet(qe.tabSize)}get lineBreak(){return this.facet(qe.lineSeparator)||`
51
- `}get readOnly(){return this.facet(Oy)}phrase(e,...n){for(let r of this.facet(qe.phrases))if(Object.prototype.hasOwnProperty.call(r,e)){e=r[e];break}return n.length&&(e=e.replace(/\$(\$|\d*)/g,(r,i)=>{if(i=="$")return"$";let o=+(i||1);return!o||o>n.length?r:n[o-1]})),e}languageDataAt(e,n,r=-1){let i=[];for(let o of this.facet(Ry))for(let s of o(this,n,r))Object.prototype.hasOwnProperty.call(s,e)&&i.push(s[e]);return i}charCategorizer(e){return OH(this.languageDataAt("wordChars",e).join(""))}wordAt(e){let{text:n,from:r,length:i}=this.doc.lineAt(e),o=this.charCategorizer(e),s=e-r,a=e-r;for(;s>0;){let c=Ht(n,s,!1);if(o(n.slice(c,s))!=lt.Word)break;s=c}for(;a<i;){let c=Ht(n,a);if(o(n.slice(a,c))!=lt.Word)break;a=c}return s==a?null:Q.range(s+r,a+r)}}qe.allowMultipleSelections=z0;qe.tabSize=fe.define({combine:t=>t.length?t[0]:4});qe.lineSeparator=ky;qe.readOnly=Oy;qe.phrases=fe.define({compare(t,e){let n=Object.keys(t),r=Object.keys(e);return n.length==r.length&&n.every(i=>t[i]==e[i])}});qe.languageData=Ry;qe.changeFilter=Ty;qe.transactionFilter=My;qe.transactionExtender=Ey;xh.reconfigure=Me.define();function Mr(t,e,n={}){let r={};for(let i of t)for(let o of Object.keys(i)){let s=i[o],a=r[o];if(a===void 0)r[o]=s;else if(!(a===s||s===void 0))if(Object.hasOwnProperty.call(n,o))r[o]=n[o](a,s);else throw new Error("Config merge conflict for field "+o)}for(let i in e)r[i]===void 0&&(r[i]=e[i]);return r}class go{eq(e){return this==e}range(e,n=e){return _a.create(e,n,this)}}go.prototype.startSide=go.prototype.endSide=0;go.prototype.point=!1;go.prototype.mapMode=Jt.TrackDel;class _a{constructor(e,n,r){this.from=e,this.to=n,this.value=r}static create(e,n,r){return new _a(e,n,r)}}function K0(t,e){return t.from-e.from||t.value.startSide-e.value.startSide}class rm{constructor(e,n,r,i){this.from=e,this.to=n,this.value=r,this.maxPoint=i}get length(){return this.to[this.to.length-1]}findIndex(e,n,r,i=0){let o=r?this.to:this.from;for(let s=i,a=o.length;;){if(s==a)return s;let c=s+a>>1,h=o[c]-e||(r?this.value[c].endSide:this.value[c].startSide)-n;if(c==s)return h>=0?s:a;h>=0?a=c:s=c+1}}between(e,n,r,i){for(let o=this.findIndex(n,-1e9,!0),s=this.findIndex(r,1e9,!1,o);o<s;o++)if(i(this.from[o]+e,this.to[o]+e,this.value[o])===!1)return!1}map(e,n){let r=[],i=[],o=[],s=-1,a=-1;for(let c=0;c<this.value.length;c++){let h=this.value[c],f=this.from[c]+e,d=this.to[c]+e,m,v;if(f==d){let w=n.mapPos(f,h.startSide,h.mapMode);if(w==null||(m=v=w,h.startSide!=h.endSide&&(v=n.mapPos(f,h.endSide),v<m)))continue}else if(m=n.mapPos(f,h.startSide),v=n.mapPos(d,h.endSide),m>v||m==v&&h.startSide>0&&h.endSide<=0)continue;(v-m||h.endSide-h.startSide)<0||(s<0&&(s=m),h.point&&(a=Math.max(a,v-m)),r.push(h),i.push(m-s),o.push(v-s))}return{mapped:r.length?new rm(i,o,r,a):null,pos:s}}}class Ke{constructor(e,n,r,i){this.chunkPos=e,this.chunk=n,this.nextLayer=r,this.maxPoint=i}static create(e,n,r,i){return new Ke(e,n,r,i)}get length(){let e=this.chunk.length-1;return e<0?0:Math.max(this.chunkEnd(e),this.nextLayer.length)}get size(){if(this.isEmpty)return 0;let e=this.nextLayer.size;for(let n of this.chunk)e+=n.value.length;return e}chunkEnd(e){return this.chunkPos[e]+this.chunk[e].length}update(e){let{add:n=[],sort:r=!1,filterFrom:i=0,filterTo:o=this.length}=e,s=e.filter;if(n.length==0&&!s)return this;if(r&&(n=n.slice().sort(K0)),this.isEmpty)return n.length?Ke.of(n):this;let a=new _y(this,null,-1).goto(0),c=0,h=[],f=new ei;for(;a.value||c<n.length;)if(c<n.length&&(a.from-n[c].from||a.startSide-n[c].value.startSide)>=0){let d=n[c++];f.addInner(d.from,d.to,d.value)||h.push(d)}else a.rangeIndex==1&&a.chunkIndex<this.chunk.length&&(c==n.length||this.chunkEnd(a.chunkIndex)<n[c].from)&&(!s||i>this.chunkEnd(a.chunkIndex)||o<this.chunkPos[a.chunkIndex])&&f.addChunk(this.chunkPos[a.chunkIndex],this.chunk[a.chunkIndex])?a.nextChunk():((!s||i>a.to||o<a.from||s(a.from,a.to,a.value))&&(f.addInner(a.from,a.to,a.value)||h.push(_a.create(a.from,a.to,a.value))),a.next());return f.finishInner(this.nextLayer.isEmpty&&!h.length?Ke.empty:this.nextLayer.update({add:h,filter:s,filterFrom:i,filterTo:o}))}map(e){if(e.empty||this.isEmpty)return this;let n=[],r=[],i=-1;for(let s=0;s<this.chunk.length;s++){let a=this.chunkPos[s],c=this.chunk[s],h=e.touchesRange(a,a+c.length);if(h===!1)i=Math.max(i,c.maxPoint),n.push(c),r.push(e.mapPos(a));else if(h===!0){let{mapped:f,pos:d}=c.map(a,e);f&&(i=Math.max(i,f.maxPoint),n.push(f),r.push(d))}}let o=this.nextLayer.map(e);return n.length==0?o:new Ke(r,n,o||Ke.empty,i)}between(e,n,r){if(!this.isEmpty){for(let i=0;i<this.chunk.length;i++){let o=this.chunkPos[i],s=this.chunk[i];if(n>=o&&e<=o+s.length&&s.between(o,e-o,n-o,r)===!1)return}this.nextLayer.between(e,n,r)}}iter(e=0){return La.from([this]).goto(e)}get isEmpty(){return this.nextLayer==this}static iter(e,n=0){return La.from(e).goto(n)}static compare(e,n,r,i,o=-1){let s=e.filter(d=>d.maxPoint>0||!d.isEmpty&&d.maxPoint>=o),a=n.filter(d=>d.maxPoint>0||!d.isEmpty&&d.maxPoint>=o),c=b5(s,a,r),h=new la(s,c,o),f=new la(a,c,o);r.iterGaps((d,m,v)=>w5(h,d,f,m,v,i)),r.empty&&r.length==0&&w5(h,0,f,0,0,i)}static eq(e,n,r=0,i){i==null&&(i=999999999);let o=e.filter(f=>!f.isEmpty&&n.indexOf(f)<0),s=n.filter(f=>!f.isEmpty&&e.indexOf(f)<0);if(o.length!=s.length)return!1;if(!o.length)return!0;let a=b5(o,s),c=new la(o,a,0).goto(r),h=new la(s,a,0).goto(r);for(;;){if(c.to!=h.to||!G0(c.active,h.active)||c.point&&(!h.point||!c.point.eq(h.point)))return!1;if(c.to>i)return!0;c.next(),h.next()}}static spans(e,n,r,i,o=-1){let s=new la(e,null,o).goto(n),a=n,c=s.openStart;for(;;){let h=Math.min(s.to,r);if(s.point){let f=s.activeForPoint(s.to),d=s.pointFrom<n?f.length+1:s.point.startSide<0?f.length:Math.min(f.length,c);i.point(a,h,s.point,f,d,s.pointRank),c=Math.min(s.openEnd(h),f.length)}else h>a&&(i.span(a,h,s.active,c),c=s.openEnd(h));if(s.to>r)return c+(s.point&&s.to>r?1:0);a=s.to,s.next()}}static of(e,n=!1){let r=new ei;for(let i of e instanceof _a?[e]:n?DH(e):e)r.add(i.from,i.to,i.value);return r.finish()}static join(e){if(!e.length)return Ke.empty;let n=e[e.length-1];for(let r=e.length-2;r>=0;r--)for(let i=e[r];i!=Ke.empty;i=i.nextLayer)n=new Ke(i.chunkPos,i.chunk,n,Math.max(i.maxPoint,n.maxPoint));return n}}Ke.empty=new Ke([],[],null,-1);function DH(t){if(t.length>1)for(let e=t[0],n=1;n<t.length;n++){let r=t[n];if(K0(e,r)>0)return t.slice().sort(K0);e=r}return t}Ke.empty.nextLayer=Ke.empty;class ei{finishChunk(e){this.chunks.push(new rm(this.from,this.to,this.value,this.maxPoint)),this.chunkPos.push(this.chunkStart),this.chunkStart=-1,this.setMaxPoint=Math.max(this.setMaxPoint,this.maxPoint),this.maxPoint=-1,e&&(this.from=[],this.to=[],this.value=[])}constructor(){this.chunks=[],this.chunkPos=[],this.chunkStart=-1,this.last=null,this.lastFrom=-1e9,this.lastTo=-1e9,this.from=[],this.to=[],this.value=[],this.maxPoint=-1,this.setMaxPoint=-1,this.nextLayer=null}add(e,n,r){this.addInner(e,n,r)||(this.nextLayer||(this.nextLayer=new ei)).add(e,n,r)}addInner(e,n,r){let i=e-this.lastTo||r.startSide-this.last.endSide;if(i<=0&&(e-this.lastFrom||r.startSide-this.last.startSide)<0)throw new Error("Ranges must be added sorted by `from` position and `startSide`");return i<0?!1:(this.from.length==250&&this.finishChunk(!0),this.chunkStart<0&&(this.chunkStart=e),this.from.push(e-this.chunkStart),this.to.push(n-this.chunkStart),this.last=r,this.lastFrom=e,this.lastTo=n,this.value.push(r),r.point&&(this.maxPoint=Math.max(this.maxPoint,n-e)),!0)}addChunk(e,n){if((e-this.lastTo||n.value[0].startSide-this.last.endSide)<0)return!1;this.from.length&&this.finishChunk(!0),this.setMaxPoint=Math.max(this.setMaxPoint,n.maxPoint),this.chunks.push(n),this.chunkPos.push(e);let r=n.value.length-1;return this.last=n.value[r],this.lastFrom=n.from[r]+e,this.lastTo=n.to[r]+e,!0}finish(){return this.finishInner(Ke.empty)}finishInner(e){if(this.from.length&&this.finishChunk(!1),this.chunks.length==0)return e;let n=Ke.create(this.chunkPos,this.chunks,this.nextLayer?this.nextLayer.finishInner(e):e,this.setMaxPoint);return this.from=null,n}}function b5(t,e,n){let r=new Map;for(let o of t)for(let s=0;s<o.chunk.length;s++)o.chunk[s].maxPoint<=0&&r.set(o.chunk[s],o.chunkPos[s]);let i=new Set;for(let o of e)for(let s=0;s<o.chunk.length;s++){let a=r.get(o.chunk[s]);a!=null&&(n?n.mapPos(a):a)==o.chunkPos[s]&&!n?.touchesRange(a,a+o.chunk[s].length)&&i.add(o.chunk[s])}return i}class _y{constructor(e,n,r,i=0){this.layer=e,this.skip=n,this.minPoint=r,this.rank=i}get startSide(){return this.value?this.value.startSide:0}get endSide(){return this.value?this.value.endSide:0}goto(e,n=-1e9){return this.chunkIndex=this.rangeIndex=0,this.gotoInner(e,n,!1),this}gotoInner(e,n,r){for(;this.chunkIndex<this.layer.chunk.length;){let i=this.layer.chunk[this.chunkIndex];if(!(this.skip&&this.skip.has(i)||this.layer.chunkEnd(this.chunkIndex)<e||i.maxPoint<this.minPoint))break;this.chunkIndex++,r=!1}if(this.chunkIndex<this.layer.chunk.length){let i=this.layer.chunk[this.chunkIndex].findIndex(e-this.layer.chunkPos[this.chunkIndex],n,!0);(!r||this.rangeIndex<i)&&this.setRangeIndex(i)}this.next()}forward(e,n){(this.to-e||this.endSide-n)<0&&this.gotoInner(e,n,!0)}next(){for(;;)if(this.chunkIndex==this.layer.chunk.length){this.from=this.to=1e9,this.value=null;break}else{let e=this.layer.chunkPos[this.chunkIndex],n=this.layer.chunk[this.chunkIndex],r=e+n.from[this.rangeIndex];if(this.from=r,this.to=e+n.to[this.rangeIndex],this.value=n.value[this.rangeIndex],this.setRangeIndex(this.rangeIndex+1),this.minPoint<0||this.value.point&&this.to-this.from>=this.minPoint)break}}setRangeIndex(e){if(e==this.layer.chunk[this.chunkIndex].value.length){if(this.chunkIndex++,this.skip)for(;this.chunkIndex<this.layer.chunk.length&&this.skip.has(this.layer.chunk[this.chunkIndex]);)this.chunkIndex++;this.rangeIndex=0}else this.rangeIndex=e}nextChunk(){this.chunkIndex++,this.rangeIndex=0,this.next()}compare(e){return this.from-e.from||this.startSide-e.startSide||this.rank-e.rank||this.to-e.to||this.endSide-e.endSide}}class La{constructor(e){this.heap=e}static from(e,n=null,r=-1){let i=[];for(let o=0;o<e.length;o++)for(let s=e[o];!s.isEmpty;s=s.nextLayer)s.maxPoint>=r&&i.push(new _y(s,n,r,o));return i.length==1?i[0]:new La(i)}get startSide(){return this.value?this.value.startSide:0}goto(e,n=-1e9){for(let r of this.heap)r.goto(e,n);for(let r=this.heap.length>>1;r>=0;r--)Dd(this.heap,r);return this.next(),this}forward(e,n){for(let r of this.heap)r.forward(e,n);for(let r=this.heap.length>>1;r>=0;r--)Dd(this.heap,r);(this.to-e||this.value.endSide-n)<0&&this.next()}next(){if(this.heap.length==0)this.from=this.to=1e9,this.value=null,this.rank=-1;else{let e=this.heap[0];this.from=e.from,this.to=e.to,this.value=e.value,this.rank=e.rank,e.value&&e.next(),Dd(this.heap,0)}}}function Dd(t,e){for(let n=t[e];;){let r=(e<<1)+1;if(r>=t.length)break;let i=t[r];if(r+1<t.length&&i.compare(t[r+1])>=0&&(i=t[r+1],r++),n.compare(i)<0)break;t[r]=n,t[e]=i,e=r}}class la{constructor(e,n,r){this.minPoint=r,this.active=[],this.activeTo=[],this.activeRank=[],this.minActive=-1,this.point=null,this.pointFrom=0,this.pointRank=0,this.to=-1e9,this.endSide=0,this.openStart=-1,this.cursor=La.from(e,n,r)}goto(e,n=-1e9){return this.cursor.goto(e,n),this.active.length=this.activeTo.length=this.activeRank.length=0,this.minActive=-1,this.to=e,this.endSide=n,this.openStart=-1,this.next(),this}forward(e,n){for(;this.minActive>-1&&(this.activeTo[this.minActive]-e||this.active[this.minActive].endSide-n)<0;)this.removeActive(this.minActive);this.cursor.forward(e,n)}removeActive(e){Mc(this.active,e),Mc(this.activeTo,e),Mc(this.activeRank,e),this.minActive=x5(this.active,this.activeTo)}addActive(e){let n=0,{value:r,to:i,rank:o}=this.cursor;for(;n<this.activeRank.length&&(o-this.activeRank[n]||i-this.activeTo[n])>0;)n++;Ec(this.active,n,r),Ec(this.activeTo,n,i),Ec(this.activeRank,n,o),e&&Ec(e,n,this.cursor.from),this.minActive=x5(this.active,this.activeTo)}next(){let e=this.to,n=this.point;this.point=null;let r=this.openStart<0?[]:null;for(;;){let i=this.minActive;if(i>-1&&(this.activeTo[i]-this.cursor.from||this.active[i].endSide-this.cursor.startSide)<0){if(this.activeTo[i]>e){this.to=this.activeTo[i],this.endSide=this.active[i].endSide;break}this.removeActive(i),r&&Mc(r,i)}else if(this.cursor.value)if(this.cursor.from>e){this.to=this.cursor.from,this.endSide=this.cursor.startSide;break}else{let o=this.cursor.value;if(!o.point)this.addActive(r),this.cursor.next();else if(n&&this.cursor.to==this.to&&this.cursor.from<this.cursor.to)this.cursor.next();else{this.point=o,this.pointFrom=this.cursor.from,this.pointRank=this.cursor.rank,this.to=this.cursor.to,this.endSide=o.endSide,this.cursor.next(),this.forward(this.to,this.endSide);break}}else{this.to=this.endSide=1e9;break}}if(r){this.openStart=0;for(let i=r.length-1;i>=0&&r[i]<e;i--)this.openStart++}}activeForPoint(e){if(!this.active.length)return this.active;let n=[];for(let r=this.active.length-1;r>=0&&!(this.activeRank[r]<this.pointRank);r--)(this.activeTo[r]>e||this.activeTo[r]==e&&this.active[r].endSide>=this.point.endSide)&&n.push(this.active[r]);return n.reverse()}openEnd(e){let n=0;for(let r=this.activeTo.length-1;r>=0&&this.activeTo[r]>e;r--)n++;return n}}function w5(t,e,n,r,i,o){t.goto(e),n.goto(r);let s=r+i,a=r,c=r-e;for(;;){let h=t.to+c-n.to,f=h||t.endSide-n.endSide,d=f<0?t.to+c:n.to,m=Math.min(d,s);if(t.point||n.point?t.point&&n.point&&(t.point==n.point||t.point.eq(n.point))&&G0(t.activeForPoint(t.to),n.activeForPoint(n.to))||o.comparePoint(a,m,t.point,n.point):m>a&&!G0(t.active,n.active)&&o.compareRange(a,m,t.active,n.active),d>s)break;(h||t.openEnd!=n.openEnd)&&o.boundChange&&o.boundChange(d),a=d,f<=0&&t.next(),f>=0&&n.next()}}function G0(t,e){if(t.length!=e.length)return!1;for(let n=0;n<t.length;n++)if(t[n]!=e[n]&&!t[n].eq(e[n]))return!1;return!0}function Mc(t,e){for(let n=e,r=t.length-1;n<r;n++)t[n]=t[n+1];t.pop()}function Ec(t,e,n){for(let r=t.length-1;r>=e;r--)t[r+1]=t[r];t[e]=n}function x5(t,e){let n=-1,r=1e9;for(let i=0;i<e.length;i++)(e[i]-r||t[i].endSide-t[n].endSide)<0&&(n=i,r=e[i]);return n}function Ns(t,e,n=t.length){let r=0;for(let i=0;i<n&&i<t.length;)t.charCodeAt(i)==9?(r+=e-r%e,i++):(r++,i=Ht(t,i));return r}function Y0(t,e,n,r){for(let i=0,o=0;;){if(o>=e)return i;if(i==t.length)break;o+=t.charCodeAt(i)==9?n-o%n:1,i=Ht(t,i)}return r===!0?-1:t.length}const X0="ͼ",y5=typeof Symbol>"u"?"__"+X0:Symbol.for(X0),Z0=typeof Symbol>"u"?"__styleSet"+Math.floor(Math.random()*1e8):Symbol("styleSet"),C5=typeof globalThis<"u"?globalThis:typeof window<"u"?window:{};class Oi{constructor(e,n){this.rules=[];let{finish:r}=n||{};function i(s){return/^@/.test(s)?[s]:s.split(/,\s*/)}function o(s,a,c,h){let f=[],d=/^@(\w+)\b/.exec(s[0]),m=d&&d[1]=="keyframes";if(d&&a==null)return c.push(s[0]+";");for(let v in a){let w=a[v];if(/&/.test(v))o(v.split(/,\s*/).map(x=>s.map(C=>x.replace(/&/,C))).reduce((x,C)=>x.concat(C)),w,c);else if(w&&typeof w=="object"){if(!d)throw new RangeError("The value of a property ("+v+") should be a primitive value.");o(i(v),w,f,m)}else w!=null&&f.push(v.replace(/_.*/,"").replace(/[A-Z]/g,x=>"-"+x.toLowerCase())+": "+w+";")}(f.length||m)&&c.push((r&&!d&&!h?s.map(r):s).join(", ")+" {"+f.join(" ")+"}")}for(let s in e)o(i(s),e[s],this.rules)}getRules(){return this.rules.join(`
52
- `)}static newName(){let e=C5[y5]||1;return C5[y5]=e+1,X0+e.toString(36)}static mount(e,n,r){let i=e[Z0],o=r&&r.nonce;i?o&&i.setNonce(o):i=new IH(e,o),i.mount(Array.isArray(n)?n:[n],e)}}let $5=new Map;class IH{constructor(e,n){let r=e.ownerDocument||e,i=r.defaultView;if(!e.head&&e.adoptedStyleSheets&&i.CSSStyleSheet){let o=$5.get(r);if(o)return e[Z0]=o;this.sheet=new i.CSSStyleSheet,$5.set(r,this)}else this.styleTag=r.createElement("style"),n&&this.styleTag.setAttribute("nonce",n);this.modules=[],e[Z0]=this}mount(e,n){let r=this.sheet,i=0,o=0;for(let s=0;s<e.length;s++){let a=e[s],c=this.modules.indexOf(a);if(c<o&&c>-1&&(this.modules.splice(c,1),o--,c=-1),c==-1){if(this.modules.splice(o++,0,a),r)for(let h=0;h<a.rules.length;h++)r.insertRule(a.rules[h],i++)}else{for(;o<c;)i+=this.modules[o++].rules.length;i+=a.rules.length,o++}}if(r)n.adoptedStyleSheets.indexOf(this.sheet)<0&&(n.adoptedStyleSheets=[this.sheet,...n.adoptedStyleSheets]);else{let s="";for(let c=0;c<this.modules.length;c++)s+=this.modules[c].getRules()+`
53
- `;this.styleTag.textContent=s;let a=n.head||n;this.styleTag.parentNode!=a&&a.insertBefore(this.styleTag,a.firstChild)}}setNonce(e){this.styleTag&&this.styleTag.getAttribute("nonce")!=e&&this.styleTag.setAttribute("nonce",e)}}var Di={8:"Backspace",9:"Tab",10:"Enter",12:"NumLock",13:"Enter",16:"Shift",17:"Control",18:"Alt",20:"CapsLock",27:"Escape",32:" ",33:"PageUp",34:"PageDown",35:"End",36:"Home",37:"ArrowLeft",38:"ArrowUp",39:"ArrowRight",40:"ArrowDown",44:"PrintScreen",45:"Insert",46:"Delete",59:";",61:"=",91:"Meta",92:"Meta",106:"*",107:"+",108:",",109:"-",110:".",111:"/",144:"NumLock",145:"ScrollLock",160:"Shift",161:"Shift",162:"Control",163:"Control",164:"Alt",165:"Alt",173:"-",186:";",187:"=",188:",",189:"-",190:".",191:"/",192:"`",219:"[",220:"\\",221:"]",222:"'"},Ba={48:")",49:"!",50:"@",51:"#",52:"$",53:"%",54:"^",55:"&",56:"*",57:"(",59:":",61:"+",173:"_",186:":",187:"+",188:"<",189:"_",190:">",191:"?",192:"~",219:"{",220:"|",221:"}",222:'"'},_H=typeof navigator<"u"&&/Mac/.test(navigator.platform),LH=typeof navigator<"u"&&/MSIE \d|Trident\/(?:[7-9]|\d{2,})\..*rv:(\d+)/.exec(navigator.userAgent);for(var Vt=0;Vt<10;Vt++)Di[48+Vt]=Di[96+Vt]=String(Vt);for(var Vt=1;Vt<=24;Vt++)Di[Vt+111]="F"+Vt;for(var Vt=65;Vt<=90;Vt++)Di[Vt]=String.fromCharCode(Vt+32),Ba[Vt]=String.fromCharCode(Vt);for(var Id in Di)Ba.hasOwnProperty(Id)||(Ba[Id]=Di[Id]);function BH(t){var e=_H&&t.metaKey&&t.shiftKey&&!t.ctrlKey&&!t.altKey||LH&&t.shiftKey&&t.key&&t.key.length==1||t.key=="Unidentified",n=!e&&t.key||(t.shiftKey?Ba:Di)[t.keyCode]||t.key||"Unidentified";return n=="Esc"&&(n="Escape"),n=="Del"&&(n="Delete"),n=="Left"&&(n="ArrowLeft"),n=="Up"&&(n="ArrowUp"),n=="Right"&&(n="ArrowRight"),n=="Down"&&(n="ArrowDown"),n}function Na(t){let e;return t.nodeType==11?e=t.getSelection?t:t.ownerDocument:e=t,e.getSelection()}function Q0(t,e){return e?t==e||t.contains(e.nodeType!=1?e.parentNode:e):!1}function tu(t,e){if(!e.anchorNode)return!1;try{return Q0(t,e.anchorNode)}catch{return!1}}function ys(t){return t.nodeType==3?po(t,0,t.nodeValue.length).getClientRects():t.nodeType==1?t.getClientRects():[]}function Ca(t,e,n,r){return n?S5(t,e,n,r,-1)||S5(t,e,n,r,1):!1}function mo(t){for(var e=0;;e++)if(t=t.previousSibling,!t)return e}function Tu(t){return t.nodeType==1&&/^(DIV|P|LI|UL|OL|BLOCKQUOTE|DD|DT|H\d|SECTION|PRE)$/.test(t.nodeName)}function S5(t,e,n,r,i){for(;;){if(t==n&&e==r)return!0;if(e==(i<0?0:Sr(t))){if(t.nodeName=="DIV")return!1;let o=t.parentNode;if(!o||o.nodeType!=1)return!1;e=mo(t)+(i<0?0:1),t=o}else if(t.nodeType==1){if(t=t.childNodes[e+(i<0?-1:0)],t.nodeType==1&&t.contentEditable=="false")return!1;e=i<0?Sr(t):0}else return!1}}function Sr(t){return t.nodeType==3?t.nodeValue.length:t.childNodes.length}function cl(t,e){let n=e?t.left:t.right;return{left:n,right:n,top:t.top,bottom:t.bottom}}function NH(t){let e=t.visualViewport;return e?{left:0,right:e.width,top:0,bottom:e.height}:{left:0,right:t.innerWidth,top:0,bottom:t.innerHeight}}function Ly(t,e){let n=e.width/t.offsetWidth,r=e.height/t.offsetHeight;return(n>.995&&n<1.005||!isFinite(n)||Math.abs(e.width-t.offsetWidth)<1)&&(n=1),(r>.995&&r<1.005||!isFinite(r)||Math.abs(e.height-t.offsetHeight)<1)&&(r=1),{scaleX:n,scaleY:r}}function jH(t,e,n,r,i,o,s,a){let c=t.ownerDocument,h=c.defaultView||window;for(let f=t,d=!1;f&&!d;)if(f.nodeType==1){let m,v=f==c.body,w=1,x=1;if(v)m=NH(h);else{if(/^(fixed|sticky)$/.test(getComputedStyle(f).position)&&(d=!0),f.scrollHeight<=f.clientHeight&&f.scrollWidth<=f.clientWidth){f=f.assignedSlot||f.parentNode;continue}let A=f.getBoundingClientRect();({scaleX:w,scaleY:x}=Ly(f,A)),m={left:A.left,right:A.left+f.clientWidth*w,top:A.top,bottom:A.top+f.clientHeight*x}}let C=0,S=0;if(i=="nearest")e.top<m.top?(S=e.top-(m.top+s),n>0&&e.bottom>m.bottom+S&&(S=e.bottom-m.bottom+s)):e.bottom>m.bottom&&(S=e.bottom-m.bottom+s,n<0&&e.top-S<m.top&&(S=e.top-(m.top+s)));else{let A=e.bottom-e.top,T=m.bottom-m.top;S=(i=="center"&&A<=T?e.top+A/2-T/2:i=="start"||i=="center"&&n<0?e.top-s:e.bottom-T+s)-m.top}if(r=="nearest"?e.left<m.left?(C=e.left-(m.left+o),n>0&&e.right>m.right+C&&(C=e.right-m.right+o)):e.right>m.right&&(C=e.right-m.right+o,n<0&&e.left<m.left+C&&(C=e.left-(m.left+o))):C=(r=="center"?e.left+(e.right-e.left)/2-(m.right-m.left)/2:r=="start"==a?e.left-o:e.right-(m.right-m.left)+o)-m.left,C||S)if(v)h.scrollBy(C,S);else{let A=0,T=0;if(S){let O=f.scrollTop;f.scrollTop+=S/x,T=(f.scrollTop-O)*x}if(C){let O=f.scrollLeft;f.scrollLeft+=C/w,A=(f.scrollLeft-O)*w}e={left:e.left-A,top:e.top-T,right:e.right-A,bottom:e.bottom-T},A&&Math.abs(A-C)<1&&(r="nearest"),T&&Math.abs(T-S)<1&&(i="nearest")}if(v)break;(e.top<m.top||e.bottom>m.bottom||e.left<m.left||e.right>m.right)&&(e={left:Math.max(e.left,m.left),right:Math.min(e.right,m.right),top:Math.max(e.top,m.top),bottom:Math.min(e.bottom,m.bottom)}),f=f.assignedSlot||f.parentNode}else if(f.nodeType==11)f=f.host;else break}function FH(t){let e=t.ownerDocument,n,r;for(let i=t.parentNode;i&&!(i==e.body||n&&r);)if(i.nodeType==1)!r&&i.scrollHeight>i.clientHeight&&(r=i),!n&&i.scrollWidth>i.clientWidth&&(n=i),i=i.assignedSlot||i.parentNode;else if(i.nodeType==11)i=i.host;else break;return{x:n,y:r}}class VH{constructor(){this.anchorNode=null,this.anchorOffset=0,this.focusNode=null,this.focusOffset=0}eq(e){return this.anchorNode==e.anchorNode&&this.anchorOffset==e.anchorOffset&&this.focusNode==e.focusNode&&this.focusOffset==e.focusOffset}setRange(e){let{anchorNode:n,focusNode:r}=e;this.set(n,Math.min(e.anchorOffset,n?Sr(n):0),r,Math.min(e.focusOffset,r?Sr(r):0))}set(e,n,r,i){this.anchorNode=e,this.anchorOffset=n,this.focusNode=r,this.focusOffset=i}}let Xo=null;function By(t){if(t.setActive)return t.setActive();if(Xo)return t.focus(Xo);let e=[];for(let n=t;n&&(e.push(n,n.scrollTop,n.scrollLeft),n!=n.ownerDocument);n=n.parentNode);if(t.focus(Xo==null?{get preventScroll(){return Xo={preventScroll:!0},!0}}:void 0),!Xo){Xo=!1;for(let n=0;n<e.length;){let r=e[n++],i=e[n++],o=e[n++];r.scrollTop!=i&&(r.scrollTop=i),r.scrollLeft!=o&&(r.scrollLeft=o)}}}let A5;function po(t,e,n=e){let r=A5||(A5=document.createRange());return r.setEnd(t,n),r.setStart(t,e),r}function cs(t,e,n,r){let i={key:e,code:e,keyCode:n,which:n,cancelable:!0};r&&({altKey:i.altKey,ctrlKey:i.ctrlKey,shiftKey:i.shiftKey,metaKey:i.metaKey}=r);let o=new KeyboardEvent("keydown",i);o.synthetic=!0,t.dispatchEvent(o);let s=new KeyboardEvent("keyup",i);return s.synthetic=!0,t.dispatchEvent(s),o.defaultPrevented||s.defaultPrevented}function HH(t){for(;t;){if(t&&(t.nodeType==9||t.nodeType==11&&t.host))return t;t=t.assignedSlot||t.parentNode}return null}function Ny(t){for(;t.attributes.length;)t.removeAttributeNode(t.attributes[0])}function PH(t,e){let n=e.focusNode,r=e.focusOffset;if(!n||e.anchorNode!=n||e.anchorOffset!=r)return!1;for(r=Math.min(r,Sr(n));;)if(r){if(n.nodeType!=1)return!1;let i=n.childNodes[r-1];i.contentEditable=="false"?r--:(n=i,r=Sr(n))}else{if(n==t)return!0;r=mo(n),n=n.parentNode}}function jy(t){return t.scrollTop>Math.max(1,t.scrollHeight-t.clientHeight-4)}function Fy(t,e){for(let n=t,r=e;;){if(n.nodeType==3&&r>0)return{node:n,offset:r};if(n.nodeType==1&&r>0){if(n.contentEditable=="false")return null;n=n.childNodes[r-1],r=Sr(n)}else if(n.parentNode&&!Tu(n))r=mo(n),n=n.parentNode;else return null}}function Vy(t,e){for(let n=t,r=e;;){if(n.nodeType==3&&r<n.nodeValue.length)return{node:n,offset:r};if(n.nodeType==1&&r<n.childNodes.length){if(n.contentEditable=="false")return null;n=n.childNodes[r],r=0}else if(n.parentNode&&!Tu(n))r=mo(n)+1,n=n.parentNode;else return null}}class qt{constructor(e,n,r=!0){this.node=e,this.offset=n,this.precise=r}static before(e,n){return new qt(e.parentNode,mo(e),n)}static after(e,n){return new qt(e.parentNode,mo(e)+1,n)}}const im=[];class nt{constructor(){this.parent=null,this.dom=null,this.flags=2}get overrideDOMText(){return null}get posAtStart(){return this.parent?this.parent.posBefore(this):0}get posAtEnd(){return this.posAtStart+this.length}posBefore(e){let n=this.posAtStart;for(let r of this.children){if(r==e)return n;n+=r.length+r.breakAfter}throw new RangeError("Invalid child in posBefore")}posAfter(e){return this.posBefore(e)+e.length}sync(e,n){if(this.flags&2){let r=this.dom,i=null,o;for(let s of this.children){if(s.flags&7){if(!s.dom&&(o=i?i.nextSibling:r.firstChild)){let a=nt.get(o);(!a||!a.parent&&a.canReuseDOM(s))&&s.reuseDOM(o)}s.sync(e,n),s.flags&=-8}if(o=i?i.nextSibling:r.firstChild,n&&!n.written&&n.node==r&&o!=s.dom&&(n.written=!0),s.dom.parentNode==r)for(;o&&o!=s.dom;)o=R5(o);else r.insertBefore(s.dom,o);i=s.dom}for(o=i?i.nextSibling:r.firstChild,o&&n&&n.node==r&&(n.written=!0);o;)o=R5(o)}else if(this.flags&1)for(let r of this.children)r.flags&7&&(r.sync(e,n),r.flags&=-8)}reuseDOM(e){}localPosFromDOM(e,n){let r;if(e==this.dom)r=this.dom.childNodes[n];else{let i=Sr(e)==0?0:n==0?-1:1;for(;;){let o=e.parentNode;if(o==this.dom)break;i==0&&o.firstChild!=o.lastChild&&(e==o.firstChild?i=-1:i=1),e=o}i<0?r=e:r=e.nextSibling}if(r==this.dom.firstChild)return 0;for(;r&&!nt.get(r);)r=r.nextSibling;if(!r)return this.length;for(let i=0,o=0;;i++){let s=this.children[i];if(s.dom==r)return o;o+=s.length+s.breakAfter}}domBoundsAround(e,n,r=0){let i=-1,o=-1,s=-1,a=-1;for(let c=0,h=r,f=r;c<this.children.length;c++){let d=this.children[c],m=h+d.length;if(h<e&&m>n)return d.domBoundsAround(e,n,h);if(m>=e&&i==-1&&(i=c,o=h),h>n&&d.dom.parentNode==this.dom){s=c,a=f;break}f=m,h=m+d.breakAfter}return{from:o,to:a<0?r+this.length:a,startDOM:(i?this.children[i-1].dom.nextSibling:null)||this.dom.firstChild,endDOM:s<this.children.length&&s>=0?this.children[s].dom:null}}markDirty(e=!1){this.flags|=2,this.markParentsDirty(e)}markParentsDirty(e){for(let n=this.parent;n;n=n.parent){if(e&&(n.flags|=2),n.flags&1)return;n.flags|=1,e=!1}}setParent(e){this.parent!=e&&(this.parent=e,this.flags&7&&this.markParentsDirty(!0))}setDOM(e){this.dom!=e&&(this.dom&&(this.dom.cmView=null),this.dom=e,e.cmView=this)}get rootView(){for(let e=this;;){let n=e.parent;if(!n)return e;e=n}}replaceChildren(e,n,r=im){this.markDirty();for(let i=e;i<n;i++){let o=this.children[i];o.parent==this&&r.indexOf(o)<0&&o.destroy()}r.length<250?this.children.splice(e,n-e,...r):this.children=[].concat(this.children.slice(0,e),r,this.children.slice(n));for(let i=0;i<r.length;i++)r[i].setParent(this)}ignoreMutation(e){return!1}ignoreEvent(e){return!1}childCursor(e=this.length){return new Hy(this.children,e,this.children.length)}childPos(e,n=1){return this.childCursor().findPos(e,n)}toString(){let e=this.constructor.name.replace("View","");return e+(this.children.length?"("+this.children.join()+")":this.length?"["+(e=="Text"?this.text:this.length)+"]":"")+(this.breakAfter?"#":"")}static get(e){return e.cmView}get isEditable(){return!0}get isWidget(){return!1}get isHidden(){return!1}merge(e,n,r,i,o,s){return!1}become(e){return!1}canReuseDOM(e){return e.constructor==this.constructor&&!((this.flags|e.flags)&8)}getSide(){return 0}destroy(){for(let e of this.children)e.parent==this&&e.destroy();this.parent=null}}nt.prototype.breakAfter=0;function R5(t){let e=t.nextSibling;return t.parentNode.removeChild(t),e}class Hy{constructor(e,n,r){this.children=e,this.pos=n,this.i=r,this.off=0}findPos(e,n=1){for(;;){if(e>this.pos||e==this.pos&&(n>0||this.i==0||this.children[this.i-1].breakAfter))return this.off=e-this.pos,this;let r=this.children[--this.i];this.pos-=r.length+r.breakAfter}}}function Py(t,e,n,r,i,o,s,a,c){let{children:h}=t,f=h.length?h[e]:null,d=o.length?o[o.length-1]:null,m=d?d.breakAfter:s;if(!(e==r&&f&&!s&&!m&&o.length<2&&f.merge(n,i,o.length?d:null,n==0,a,c))){if(r<h.length){let v=h[r];v&&(i<v.length||v.breakAfter&&d?.breakAfter)?(e==r&&(v=v.split(i),i=0),!m&&d&&v.merge(0,i,d,!0,0,c)?o[o.length-1]=v:((i||v.children.length&&!v.children[0].length)&&v.merge(0,i,null,!1,0,c),o.push(v))):v?.breakAfter&&(d?d.breakAfter=1:s=1),r++}for(f&&(f.breakAfter=s,n>0&&(!s&&o.length&&f.merge(n,f.length,o[0],!1,a,0)?f.breakAfter=o.shift().breakAfter:(n<f.length||f.children.length&&f.children[f.children.length-1].length==0)&&f.merge(n,f.length,null,!1,a,0),e++));e<r&&o.length;)if(h[r-1].become(o[o.length-1]))r--,o.pop(),c=o.length?0:a;else if(h[e].become(o[0]))e++,o.shift(),a=o.length?0:c;else break;!o.length&&e&&r<h.length&&!h[e-1].breakAfter&&h[r].merge(0,0,h[e-1],!1,a,c)&&e--,(e<r||o.length)&&t.replaceChildren(e,r,o)}}function Wy(t,e,n,r,i,o){let s=t.childCursor(),{i:a,off:c}=s.findPos(n,1),{i:h,off:f}=s.findPos(e,-1),d=e-n;for(let m of r)d+=m.length;t.length+=d,Py(t,h,f,a,c,r,0,i,o)}let cn=typeof navigator<"u"?navigator:{userAgent:"",vendor:"",platform:""},J0=typeof document<"u"?document:{documentElement:{style:{}}};const e1=/Edge\/(\d+)/.exec(cn.userAgent),zy=/MSIE \d/.test(cn.userAgent),t1=/Trident\/(?:[7-9]|\d{2,})\..*rv:(\d+)/.exec(cn.userAgent),yh=!!(zy||t1||e1),k5=!yh&&/gecko\/(\d+)/i.test(cn.userAgent),_d=!yh&&/Chrome\/(\d+)/.exec(cn.userAgent),T5="webkitFontSmoothing"in J0.documentElement.style,Uy=!yh&&/Apple Computer/.test(cn.vendor),M5=Uy&&(/Mobile\/\w+/.test(cn.userAgent)||cn.maxTouchPoints>2);var ce={mac:M5||/Mac/.test(cn.platform),windows:/Win/.test(cn.platform),linux:/Linux|X11/.test(cn.platform),ie:yh,ie_version:zy?J0.documentMode||6:t1?+t1[1]:e1?+e1[1]:0,gecko:k5,gecko_version:k5?+(/Firefox\/(\d+)/.exec(cn.userAgent)||[0,0])[1]:0,chrome:!!_d,chrome_version:_d?+_d[1]:0,ios:M5,android:/Android\b/.test(cn.userAgent),webkit:T5,safari:Uy,webkit_version:T5?+(/\bAppleWebKit\/(\d+)/.exec(cn.userAgent)||[0,0])[1]:0,tabSize:J0.documentElement.style.tabSize!=null?"tab-size":"-moz-tab-size"};const WH=256;class er extends nt{constructor(e){super(),this.text=e}get length(){return this.text.length}createDOM(e){this.setDOM(e||document.createTextNode(this.text))}sync(e,n){this.dom||this.createDOM(),this.dom.nodeValue!=this.text&&(n&&n.node==this.dom&&(n.written=!0),this.dom.nodeValue=this.text)}reuseDOM(e){e.nodeType==3&&this.createDOM(e)}merge(e,n,r){return this.flags&8||r&&(!(r instanceof er)||this.length-(n-e)+r.length>WH||r.flags&8)?!1:(this.text=this.text.slice(0,e)+(r?r.text:"")+this.text.slice(n),this.markDirty(),!0)}split(e){let n=new er(this.text.slice(e));return this.text=this.text.slice(0,e),this.markDirty(),n.flags|=this.flags&8,n}localPosFromDOM(e,n){return e==this.dom?n:n?this.text.length:0}domAtPos(e){return new qt(this.dom,e)}domBoundsAround(e,n,r){return{from:r,to:r+this.length,startDOM:this.dom,endDOM:this.dom.nextSibling}}coordsAt(e,n){return zH(this.dom,e,n)}}class ti extends nt{constructor(e,n=[],r=0){super(),this.mark=e,this.children=n,this.length=r;for(let i of n)i.setParent(this)}setAttrs(e){if(Ny(e),this.mark.class&&(e.className=this.mark.class),this.mark.attrs)for(let n in this.mark.attrs)e.setAttribute(n,this.mark.attrs[n]);return e}canReuseDOM(e){return super.canReuseDOM(e)&&!((this.flags|e.flags)&8)}reuseDOM(e){e.nodeName==this.mark.tagName.toUpperCase()&&(this.setDOM(e),this.flags|=6)}sync(e,n){this.dom?this.flags&4&&this.setAttrs(this.dom):this.setDOM(this.setAttrs(document.createElement(this.mark.tagName))),super.sync(e,n)}merge(e,n,r,i,o,s){return r&&(!(r instanceof ti&&r.mark.eq(this.mark))||e&&o<=0||n<this.length&&s<=0)?!1:(Wy(this,e,n,r?r.children.slice():[],o-1,s-1),this.markDirty(),!0)}split(e){let n=[],r=0,i=-1,o=0;for(let a of this.children){let c=r+a.length;c>e&&n.push(r<e?a.split(e-r):a),i<0&&r>=e&&(i=o),r=c,o++}let s=this.length-e;return this.length=e,i>-1&&(this.children.length=i,this.markDirty()),new ti(this.mark,n,s)}domAtPos(e){return qy(this,e)}coordsAt(e,n){return Gy(this,e,n)}}function zH(t,e,n){let r=t.nodeValue.length;e>r&&(e=r);let i=e,o=e,s=0;e==0&&n<0||e==r&&n>=0?ce.chrome||ce.gecko||(e?(i--,s=1):o<r&&(o++,s=-1)):n<0?i--:o<r&&o++;let a=po(t,i,o).getClientRects();if(!a.length)return null;let c=a[(s?s<0:n>=0)?0:a.length-1];return ce.safari&&!s&&c.width==0&&(c=Array.prototype.find.call(a,h=>h.width)||c),s?cl(c,s<0):c||null}class $i extends nt{static create(e,n,r){return new $i(e,n,r)}constructor(e,n,r){super(),this.widget=e,this.length=n,this.side=r,this.prevWidget=null}split(e){let n=$i.create(this.widget,this.length-e,this.side);return this.length-=e,n}sync(e){(!this.dom||!this.widget.updateDOM(this.dom,e))&&(this.dom&&this.prevWidget&&this.prevWidget.destroy(this.dom),this.prevWidget=null,this.setDOM(this.widget.toDOM(e)),this.widget.editable||(this.dom.contentEditable="false"))}getSide(){return this.side}merge(e,n,r,i,o,s){return r&&(!(r instanceof $i)||!this.widget.compare(r.widget)||e>0&&o<=0||n<this.length&&s<=0)?!1:(this.length=e+(r?r.length:0)+(this.length-n),!0)}become(e){return e instanceof $i&&e.side==this.side&&this.widget.constructor==e.widget.constructor?(this.widget.compare(e.widget)||this.markDirty(!0),this.dom&&!this.prevWidget&&(this.prevWidget=this.widget),this.widget=e.widget,this.length=e.length,!0):!1}ignoreMutation(){return!0}ignoreEvent(e){return this.widget.ignoreEvent(e)}get overrideDOMText(){if(this.length==0)return Ge.empty;let e=this;for(;e.parent;)e=e.parent;let{view:n}=e,r=n&&n.state.doc,i=this.posAtStart;return r?r.slice(i,i+this.length):Ge.empty}domAtPos(e){return(this.length?e==0:this.side>0)?qt.before(this.dom):qt.after(this.dom,e==this.length)}domBoundsAround(){return null}coordsAt(e,n){let r=this.widget.coordsAt(this.dom,e,n);if(r)return r;let i=this.dom.getClientRects(),o=null;if(!i.length)return null;let s=this.side?this.side<0:e>0;for(let a=s?i.length-1:0;o=i[a],!(e>0?a==0:a==i.length-1||o.top<o.bottom);a+=s?-1:1);return cl(o,!s)}get isEditable(){return!1}get isWidget(){return!0}get isHidden(){return this.widget.isHidden}destroy(){super.destroy(),this.dom&&this.widget.destroy(this.dom)}}class Cs extends nt{constructor(e){super(),this.side=e}get length(){return 0}merge(){return!1}become(e){return e instanceof Cs&&e.side==this.side}split(){return new Cs(this.side)}sync(){if(!this.dom){let e=document.createElement("img");e.className="cm-widgetBuffer",e.setAttribute("aria-hidden","true"),this.setDOM(e)}}getSide(){return this.side}domAtPos(e){return this.side>0?qt.before(this.dom):qt.after(this.dom)}localPosFromDOM(){return 0}domBoundsAround(){return null}coordsAt(e){return this.dom.getBoundingClientRect()}get overrideDOMText(){return Ge.empty}get isHidden(){return!0}}er.prototype.children=$i.prototype.children=Cs.prototype.children=im;function qy(t,e){let n=t.dom,{children:r}=t,i=0;for(let o=0;i<r.length;i++){let s=r[i],a=o+s.length;if(!(a==o&&s.getSide()<=0)){if(e>o&&e<a&&s.dom.parentNode==n)return s.domAtPos(e-o);if(e<=o)break;o=a}}for(let o=i;o>0;o--){let s=r[o-1];if(s.dom.parentNode==n)return s.domAtPos(s.length)}for(let o=i;o<r.length;o++){let s=r[o];if(s.dom.parentNode==n)return s.domAtPos(0)}return new qt(n,0)}function Ky(t,e,n){let r,{children:i}=t;n>0&&e instanceof ti&&i.length&&(r=i[i.length-1])instanceof ti&&r.mark.eq(e.mark)?Ky(r,e.children[0],n-1):(i.push(e),e.setParent(t)),t.length+=e.length}function Gy(t,e,n){let r=null,i=-1,o=null,s=-1;function a(h,f){for(let d=0,m=0;d<h.children.length&&m<=f;d++){let v=h.children[d],w=m+v.length;w>=f&&(v.children.length?a(v,f-m):(!o||o.isHidden&&n>0)&&(w>f||m==w&&v.getSide()>0)?(o=v,s=f-m):(m<f||m==w&&v.getSide()<0&&!v.isHidden)&&(r=v,i=f-m)),m=w}}a(t,e);let c=(n<0?r:o)||r||o;return c?c.coordsAt(Math.max(0,c==r?i:s),n):UH(t)}function UH(t){let e=t.dom.lastChild;if(!e)return t.dom.getBoundingClientRect();let n=ys(e);return n[n.length-1]||null}function n1(t,e){for(let n in t)n=="class"&&e.class?e.class+=" "+t.class:n=="style"&&e.style?e.style+=";"+t.style:e[n]=t[n];return e}const E5=Object.create(null);function Mu(t,e,n){if(t==e)return!0;t||(t=E5),e||(e=E5);let r=Object.keys(t),i=Object.keys(e);if(r.length-(n&&r.indexOf(n)>-1?1:0)!=i.length-(n&&i.indexOf(n)>-1?1:0))return!1;for(let o of r)if(o!=n&&(i.indexOf(o)==-1||t[o]!==e[o]))return!1;return!0}function r1(t,e,n){let r=!1;if(e)for(let i in e)n&&i in n||(r=!0,i=="style"?t.style.cssText="":t.removeAttribute(i));if(n)for(let i in n)e&&e[i]==n[i]||(r=!0,i=="style"?t.style.cssText=n[i]:t.setAttribute(i,n[i]));return r}function qH(t){let e=Object.create(null);for(let n=0;n<t.attributes.length;n++){let r=t.attributes[n];e[r.name]=r.value}return e}class ai{eq(e){return!1}updateDOM(e,n){return!1}compare(e){return this==e||this.constructor==e.constructor&&this.eq(e)}get estimatedHeight(){return-1}get lineBreaks(){return 0}ignoreEvent(e){return!0}coordsAt(e,n,r){return null}get isHidden(){return!1}get editable(){return!1}destroy(e){}}var en=function(t){return t[t.Text=0]="Text",t[t.WidgetBefore=1]="WidgetBefore",t[t.WidgetAfter=2]="WidgetAfter",t[t.WidgetRange=3]="WidgetRange",t}(en||(en={}));class xe extends go{constructor(e,n,r,i){super(),this.startSide=e,this.endSide=n,this.widget=r,this.spec=i}get heightRelevant(){return!1}static mark(e){return new ul(e)}static widget(e){let n=Math.max(-1e4,Math.min(1e4,e.side||0)),r=!!e.block;return n+=r&&!e.inlineOrder?n>0?3e8:-4e8:n>0?1e8:-1e8,new Ii(e,n,n,r,e.widget||null,!1)}static replace(e){let n=!!e.block,r,i;if(e.isBlockGap)r=-5e8,i=4e8;else{let{start:o,end:s}=Yy(e,n);r=(o?n?-3e8:-1:5e8)-1,i=(s?n?2e8:1:-6e8)+1}return new Ii(e,r,i,n,e.widget||null,!0)}static line(e){return new hl(e)}static set(e,n=!1){return Ke.of(e,n)}hasHeight(){return this.widget?this.widget.estimatedHeight>-1:!1}}xe.none=Ke.empty;class ul extends xe{constructor(e){let{start:n,end:r}=Yy(e);super(n?-1:5e8,r?1:-6e8,null,e),this.tagName=e.tagName||"span",this.class=e.class||"",this.attrs=e.attributes||null}eq(e){var n,r;return this==e||e instanceof ul&&this.tagName==e.tagName&&(this.class||((n=this.attrs)===null||n===void 0?void 0:n.class))==(e.class||((r=e.attrs)===null||r===void 0?void 0:r.class))&&Mu(this.attrs,e.attrs,"class")}range(e,n=e){if(e>=n)throw new RangeError("Mark decorations may not be empty");return super.range(e,n)}}ul.prototype.point=!1;class hl extends xe{constructor(e){super(-2e8,-2e8,null,e)}eq(e){return e instanceof hl&&this.spec.class==e.spec.class&&Mu(this.spec.attributes,e.spec.attributes)}range(e,n=e){if(n!=e)throw new RangeError("Line decoration ranges must be zero-length");return super.range(e,n)}}hl.prototype.mapMode=Jt.TrackBefore;hl.prototype.point=!0;class Ii extends xe{constructor(e,n,r,i,o,s){super(n,r,o,e),this.block=i,this.isReplace=s,this.mapMode=i?n<=0?Jt.TrackBefore:Jt.TrackAfter:Jt.TrackDel}get type(){return this.startSide!=this.endSide?en.WidgetRange:this.startSide<=0?en.WidgetBefore:en.WidgetAfter}get heightRelevant(){return this.block||!!this.widget&&(this.widget.estimatedHeight>=5||this.widget.lineBreaks>0)}eq(e){return e instanceof Ii&&KH(this.widget,e.widget)&&this.block==e.block&&this.startSide==e.startSide&&this.endSide==e.endSide}range(e,n=e){if(this.isReplace&&(e>n||e==n&&this.startSide>0&&this.endSide<=0))throw new RangeError("Invalid range for replacement decoration");if(!this.isReplace&&n!=e)throw new RangeError("Widget decorations can only have zero-length ranges");return super.range(e,n)}}Ii.prototype.point=!0;function Yy(t,e=!1){let{inclusiveStart:n,inclusiveEnd:r}=t;return n==null&&(n=t.inclusive),r==null&&(r=t.inclusive),{start:n??e,end:r??e}}function KH(t,e){return t==e||!!(t&&e&&t.compare(e))}function nu(t,e,n,r=0){let i=n.length-1;i>=0&&n[i]+r>=t?n[i]=Math.max(n[i],e):n.push(t,e)}class yt extends nt{constructor(){super(...arguments),this.children=[],this.length=0,this.prevAttrs=void 0,this.attrs=null,this.breakAfter=0}merge(e,n,r,i,o,s){if(r){if(!(r instanceof yt))return!1;this.dom||r.transferDOM(this)}return i&&this.setDeco(r?r.attrs:null),Wy(this,e,n,r?r.children.slice():[],o,s),!0}split(e){let n=new yt;if(n.breakAfter=this.breakAfter,this.length==0)return n;let{i:r,off:i}=this.childPos(e);i&&(n.append(this.children[r].split(i),0),this.children[r].merge(i,this.children[r].length,null,!1,0,0),r++);for(let o=r;o<this.children.length;o++)n.append(this.children[o],0);for(;r>0&&this.children[r-1].length==0;)this.children[--r].destroy();return this.children.length=r,this.markDirty(),this.length=e,n}transferDOM(e){this.dom&&(this.markDirty(),e.setDOM(this.dom),e.prevAttrs=this.prevAttrs===void 0?this.attrs:this.prevAttrs,this.prevAttrs=void 0,this.dom=null)}setDeco(e){Mu(this.attrs,e)||(this.dom&&(this.prevAttrs=this.attrs,this.markDirty()),this.attrs=e)}append(e,n){Ky(this,e,n)}addLineDeco(e){let n=e.spec.attributes,r=e.spec.class;n&&(this.attrs=n1(n,this.attrs||{})),r&&(this.attrs=n1({class:r},this.attrs||{}))}domAtPos(e){return qy(this,e)}reuseDOM(e){e.nodeName=="DIV"&&(this.setDOM(e),this.flags|=6)}sync(e,n){var r;this.dom?this.flags&4&&(Ny(this.dom),this.dom.className="cm-line",this.prevAttrs=this.attrs?null:void 0):(this.setDOM(document.createElement("div")),this.dom.className="cm-line",this.prevAttrs=this.attrs?null:void 0),this.prevAttrs!==void 0&&(r1(this.dom,this.prevAttrs,this.attrs),this.dom.classList.add("cm-line"),this.prevAttrs=void 0),super.sync(e,n);let i=this.dom.lastChild;for(;i&&nt.get(i)instanceof ti;)i=i.lastChild;if(!i||!this.length||i.nodeName!="BR"&&((r=nt.get(i))===null||r===void 0?void 0:r.isEditable)==!1&&(!ce.ios||!this.children.some(o=>o instanceof er))){let o=document.createElement("BR");o.cmIgnore=!0,this.dom.appendChild(o)}}measureTextSize(){if(this.children.length==0||this.length>20)return null;let e=0,n;for(let r of this.children){if(!(r instanceof er)||/[^ -~]/.test(r.text))return null;let i=ys(r.dom);if(i.length!=1)return null;e+=i[0].width,n=i[0].height}return e?{lineHeight:this.dom.getBoundingClientRect().height,charWidth:e/this.length,textHeight:n}:null}coordsAt(e,n){let r=Gy(this,e,n);if(!this.children.length&&r&&this.parent){let{heightOracle:i}=this.parent.view.viewState,o=r.bottom-r.top;if(Math.abs(o-i.lineHeight)<2&&i.textHeight<o){let s=(o-i.textHeight)/2;return{top:r.top+s,bottom:r.bottom-s,left:r.left,right:r.left}}}return r}become(e){return e instanceof yt&&this.children.length==0&&e.children.length==0&&Mu(this.attrs,e.attrs)&&this.breakAfter==e.breakAfter}covers(){return!0}static find(e,n){for(let r=0,i=0;r<e.children.length;r++){let o=e.children[r],s=i+o.length;if(s>=n){if(o instanceof yt)return o;if(s>n)break}i=s+o.breakAfter}return null}}class Xr extends nt{constructor(e,n,r){super(),this.widget=e,this.length=n,this.deco=r,this.breakAfter=0,this.prevWidget=null}merge(e,n,r,i,o,s){return r&&(!(r instanceof Xr)||!this.widget.compare(r.widget)||e>0&&o<=0||n<this.length&&s<=0)?!1:(this.length=e+(r?r.length:0)+(this.length-n),!0)}domAtPos(e){return e==0?qt.before(this.dom):qt.after(this.dom,e==this.length)}split(e){let n=this.length-e;this.length=e;let r=new Xr(this.widget,n,this.deco);return r.breakAfter=this.breakAfter,r}get children(){return im}sync(e){(!this.dom||!this.widget.updateDOM(this.dom,e))&&(this.dom&&this.prevWidget&&this.prevWidget.destroy(this.dom),this.prevWidget=null,this.setDOM(this.widget.toDOM(e)),this.widget.editable||(this.dom.contentEditable="false"))}get overrideDOMText(){return this.parent?this.parent.view.state.doc.slice(this.posAtStart,this.posAtEnd):Ge.empty}domBoundsAround(){return null}become(e){return e instanceof Xr&&e.widget.constructor==this.widget.constructor?(e.widget.compare(this.widget)||this.markDirty(!0),this.dom&&!this.prevWidget&&(this.prevWidget=this.widget),this.widget=e.widget,this.length=e.length,this.deco=e.deco,this.breakAfter=e.breakAfter,!0):!1}ignoreMutation(){return!0}ignoreEvent(e){return this.widget.ignoreEvent(e)}get isEditable(){return!1}get isWidget(){return!0}coordsAt(e,n){let r=this.widget.coordsAt(this.dom,e,n);return r||(this.widget instanceof i1?null:cl(this.dom.getBoundingClientRect(),this.length?e==0:n<=0))}destroy(){super.destroy(),this.dom&&this.widget.destroy(this.dom)}covers(e){let{startSide:n,endSide:r}=this.deco;return n==r?!1:e<0?n<0:r>0}}class i1 extends ai{constructor(e){super(),this.height=e}toDOM(){let e=document.createElement("div");return e.className="cm-gap",this.updateDOM(e),e}eq(e){return e.height==this.height}updateDOM(e){return e.style.height=this.height+"px",!0}get editable(){return!0}get estimatedHeight(){return this.height}ignoreEvent(){return!1}}class $a{constructor(e,n,r,i){this.doc=e,this.pos=n,this.end=r,this.disallowBlockEffectsFor=i,this.content=[],this.curLine=null,this.breakAtStart=0,this.pendingBuffer=0,this.bufferMarks=[],this.atCursorPos=!0,this.openStart=-1,this.openEnd=-1,this.text="",this.textOff=0,this.cursor=e.iter(),this.skip=n}posCovered(){if(this.content.length==0)return!this.breakAtStart&&this.doc.lineAt(this.pos).from!=this.pos;let e=this.content[this.content.length-1];return!(e.breakAfter||e instanceof Xr&&e.deco.endSide<0)}getLine(){return this.curLine||(this.content.push(this.curLine=new yt),this.atCursorPos=!0),this.curLine}flushBuffer(e=this.bufferMarks){this.pendingBuffer&&(this.curLine.append(Oc(new Cs(-1),e),e.length),this.pendingBuffer=0)}addBlockWidget(e){this.flushBuffer(),this.curLine=null,this.content.push(e)}finish(e){this.pendingBuffer&&e<=this.bufferMarks.length?this.flushBuffer():this.pendingBuffer=0,!this.posCovered()&&!(e&&this.content.length&&this.content[this.content.length-1]instanceof Xr)&&this.getLine()}buildText(e,n,r){for(;e>0;){if(this.textOff==this.text.length){let{value:o,lineBreak:s,done:a}=this.cursor.next(this.skip);if(this.skip=0,a)throw new Error("Ran out of text content when drawing inline views");if(s){this.posCovered()||this.getLine(),this.content.length?this.content[this.content.length-1].breakAfter=1:this.breakAtStart=1,this.flushBuffer(),this.curLine=null,this.atCursorPos=!0,e--;continue}else this.text=o,this.textOff=0}let i=Math.min(this.text.length-this.textOff,e,512);this.flushBuffer(n.slice(n.length-r)),this.getLine().append(Oc(new er(this.text.slice(this.textOff,this.textOff+i)),n),r),this.atCursorPos=!0,this.textOff+=i,e-=i,r=0}}span(e,n,r,i){this.buildText(n-e,r,i),this.pos=n,this.openStart<0&&(this.openStart=i)}point(e,n,r,i,o,s){if(this.disallowBlockEffectsFor[s]&&r instanceof Ii){if(r.block)throw new RangeError("Block decorations may not be specified via plugins");if(n>this.doc.lineAt(this.pos).to)throw new RangeError("Decorations that replace line breaks may not be specified via plugins")}let a=n-e;if(r instanceof Ii)if(r.block)r.startSide>0&&!this.posCovered()&&this.getLine(),this.addBlockWidget(new Xr(r.widget||$s.block,a,r));else{let c=$i.create(r.widget||$s.inline,a,a?0:r.startSide),h=this.atCursorPos&&!c.isEditable&&o<=i.length&&(e<n||r.startSide>0),f=!c.isEditable&&(e<n||o>i.length||r.startSide<=0),d=this.getLine();this.pendingBuffer==2&&!h&&!c.isEditable&&(this.pendingBuffer=0),this.flushBuffer(i),h&&(d.append(Oc(new Cs(1),i),o),o=i.length+Math.max(0,o-i.length)),d.append(Oc(c,i),o),this.atCursorPos=f,this.pendingBuffer=f?e<n||o>i.length?1:2:0,this.pendingBuffer&&(this.bufferMarks=i.slice())}else this.doc.lineAt(this.pos).from==this.pos&&this.getLine().addLineDeco(r);a&&(this.textOff+a<=this.text.length?this.textOff+=a:(this.skip+=a-(this.text.length-this.textOff),this.text="",this.textOff=0),this.pos=n),this.openStart<0&&(this.openStart=o)}static build(e,n,r,i,o){let s=new $a(e,n,r,o);return s.openEnd=Ke.spans(i,n,r,s),s.openStart<0&&(s.openStart=s.openEnd),s.finish(s.openEnd),s}}function Oc(t,e){for(let n of e)t=new ti(n,[t],t.length);return t}class $s extends ai{constructor(e){super(),this.tag=e}eq(e){return e.tag==this.tag}toDOM(){return document.createElement(this.tag)}updateDOM(e){return e.nodeName.toLowerCase()==this.tag}get isHidden(){return!0}}$s.inline=new $s("span");$s.block=new $s("div");var st=function(t){return t[t.LTR=0]="LTR",t[t.RTL=1]="RTL",t}(st||(st={}));const vo=st.LTR,om=st.RTL;function Xy(t){let e=[];for(let n=0;n<t.length;n++)e.push(1<<+t[n]);return e}const GH=Xy("88888888888888888888888888888888888666888888787833333333337888888000000000000000000000000008888880000000000000000000000000088888888888888888888888888888888888887866668888088888663380888308888800000000000000000000000800000000000000000000000000000008"),YH=Xy("4444448826627288999999999992222222222222222222222222222222222222222222222229999999999999999999994444444444644222822222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222999999949999999229989999223333333333"),o1=Object.create(null),fr=[];for(let t of["()","[]","{}"]){let e=t.charCodeAt(0),n=t.charCodeAt(1);o1[e]=n,o1[n]=-e}function Zy(t){return t<=247?GH[t]:1424<=t&&t<=1524?2:1536<=t&&t<=1785?YH[t-1536]:1774<=t&&t<=2220?4:8192<=t&&t<=8204?256:64336<=t&&t<=65023?4:1}const XH=/[\u0590-\u05f4\u0600-\u06ff\u0700-\u08ac\ufb50-\ufdff]/;class Si{get dir(){return this.level%2?om:vo}constructor(e,n,r){this.from=e,this.to=n,this.level=r}side(e,n){return this.dir==n==e?this.to:this.from}forward(e,n){return e==(this.dir==n)}static find(e,n,r,i){let o=-1;for(let s=0;s<e.length;s++){let a=e[s];if(a.from<=n&&a.to>=n){if(a.level==r)return s;(o<0||(i!=0?i<0?a.from<n:a.to>n:e[o].level>a.level))&&(o=s)}}if(o<0)throw new RangeError("Index out of range");return o}}function Qy(t,e){if(t.length!=e.length)return!1;for(let n=0;n<t.length;n++){let r=t[n],i=e[n];if(r.from!=i.from||r.to!=i.to||r.direction!=i.direction||!Qy(r.inner,i.inner))return!1}return!0}const tt=[];function ZH(t,e,n,r,i){for(let o=0;o<=r.length;o++){let s=o?r[o-1].to:e,a=o<r.length?r[o].from:n,c=o?256:i;for(let h=s,f=c,d=c;h<a;h++){let m=Zy(t.charCodeAt(h));m==512?m=f:m==8&&d==4&&(m=16),tt[h]=m==4?2:m,m&7&&(d=m),f=m}for(let h=s,f=c,d=c;h<a;h++){let m=tt[h];if(m==128)h<a-1&&f==tt[h+1]&&f&24?m=tt[h]=f:tt[h]=256;else if(m==64){let v=h+1;for(;v<a&&tt[v]==64;)v++;let w=h&&f==8||v<n&&tt[v]==8?d==1?1:8:256;for(let x=h;x<v;x++)tt[x]=w;h=v-1}else m==8&&d==1&&(tt[h]=1);f=m,m&7&&(d=m)}}}function QH(t,e,n,r,i){let o=i==1?2:1;for(let s=0,a=0,c=0;s<=r.length;s++){let h=s?r[s-1].to:e,f=s<r.length?r[s].from:n;for(let d=h,m,v,w;d<f;d++)if(v=o1[m=t.charCodeAt(d)])if(v<0){for(let x=a-3;x>=0;x-=3)if(fr[x+1]==-v){let C=fr[x+2],S=C&2?i:C&4?C&1?o:i:0;S&&(tt[d]=tt[fr[x]]=S),a=x;break}}else{if(fr.length==189)break;fr[a++]=d,fr[a++]=m,fr[a++]=c}else if((w=tt[d])==2||w==1){let x=w==i;c=x?0:1;for(let C=a-3;C>=0;C-=3){let S=fr[C+2];if(S&2)break;if(x)fr[C+2]|=2;else{if(S&4)break;fr[C+2]|=4}}}}}function JH(t,e,n,r){for(let i=0,o=r;i<=n.length;i++){let s=i?n[i-1].to:t,a=i<n.length?n[i].from:e;for(let c=s;c<a;){let h=tt[c];if(h==256){let f=c+1;for(;;)if(f==a){if(i==n.length)break;f=n[i++].to,a=i<n.length?n[i].from:e}else if(tt[f]==256)f++;else break;let d=o==1,m=(f<e?tt[f]:r)==1,v=d==m?d?1:2:r;for(let w=f,x=i,C=x?n[x-1].to:t;w>c;)w==C&&(w=n[--x].from,C=x?n[x-1].to:t),tt[--w]=v;c=f}else o=h,c++}}}function s1(t,e,n,r,i,o,s){let a=r%2?2:1;if(r%2==i%2)for(let c=e,h=0;c<n;){let f=!0,d=!1;if(h==o.length||c<o[h].from){let x=tt[c];x!=a&&(f=!1,d=x==16)}let m=!f&&a==1?[]:null,v=f?r:r+1,w=c;e:for(;;)if(h<o.length&&w==o[h].from){if(d)break e;let x=o[h];if(!f)for(let C=x.to,S=h+1;;){if(C==n)break e;if(S<o.length&&o[S].from==C)C=o[S++].to;else{if(tt[C]==a)break e;break}}if(h++,m)m.push(x);else{x.from>c&&s.push(new Si(c,x.from,v));let C=x.direction==vo!=!(v%2);a1(t,C?r+1:r,i,x.inner,x.from,x.to,s),c=x.to}w=x.to}else{if(w==n||(f?tt[w]!=a:tt[w]==a))break;w++}m?s1(t,c,w,r+1,i,m,s):c<w&&s.push(new Si(c,w,v)),c=w}else for(let c=n,h=o.length;c>e;){let f=!0,d=!1;if(!h||c>o[h-1].to){let x=tt[c-1];x!=a&&(f=!1,d=x==16)}let m=!f&&a==1?[]:null,v=f?r:r+1,w=c;e:for(;;)if(h&&w==o[h-1].to){if(d)break e;let x=o[--h];if(!f)for(let C=x.from,S=h;;){if(C==e)break e;if(S&&o[S-1].to==C)C=o[--S].from;else{if(tt[C-1]==a)break e;break}}if(m)m.push(x);else{x.to<c&&s.push(new Si(x.to,c,v));let C=x.direction==vo!=!(v%2);a1(t,C?r+1:r,i,x.inner,x.from,x.to,s),c=x.from}w=x.from}else{if(w==e||(f?tt[w-1]!=a:tt[w-1]==a))break;w--}m?s1(t,w,c,r+1,i,m,s):w<c&&s.push(new Si(w,c,v)),c=w}}function a1(t,e,n,r,i,o,s){let a=e%2?2:1;ZH(t,i,o,r,a),QH(t,i,o,r,a),JH(i,o,r,a),s1(t,i,o,e,n,r,s)}function eP(t,e,n){if(!t)return[new Si(0,0,e==om?1:0)];if(e==vo&&!n.length&&!XH.test(t))return Jy(t.length);if(n.length)for(;t.length>tt.length;)tt[tt.length]=256;let r=[],i=e==vo?0:1;return a1(t,i,i,n,0,t.length,r),r}function Jy(t){return[new Si(0,t,0)]}let e6="";function tP(t,e,n,r,i){var o;let s=r.head-t.from,a=Si.find(e,s,(o=r.bidiLevel)!==null&&o!==void 0?o:-1,r.assoc),c=e[a],h=c.side(i,n);if(s==h){let m=a+=i?1:-1;if(m<0||m>=e.length)return null;c=e[a=m],s=c.side(!i,n),h=c.side(i,n)}let f=Ht(t.text,s,c.forward(i,n));(f<c.from||f>c.to)&&(f=h),e6=t.text.slice(Math.min(s,f),Math.max(s,f));let d=a==(i?e.length-1:0)?null:e[a+(i?1:-1)];return d&&f==h&&d.level+(i?0:1)<c.level?Q.cursor(d.side(!i,n)+t.from,d.forward(i,n)?1:-1,d.level):Q.cursor(f+t.from,c.forward(i,n)?-1:1,c.level)}function nP(t,e,n){for(let r=e;r<n;r++){let i=Zy(t.charCodeAt(r));if(i==1)return vo;if(i==2||i==4)return om}return vo}const t6=fe.define(),n6=fe.define(),r6=fe.define(),i6=fe.define(),l1=fe.define(),o6=fe.define(),s6=fe.define(),sm=fe.define(),am=fe.define(),a6=fe.define({combine:t=>t.some(e=>e)}),l6=fe.define({combine:t=>t.some(e=>e)}),c6=fe.define();class us{constructor(e,n="nearest",r="nearest",i=5,o=5,s=!1){this.range=e,this.y=n,this.x=r,this.yMargin=i,this.xMargin=o,this.isSnapshot=s}map(e){return e.empty?this:new us(this.range.map(e),this.y,this.x,this.yMargin,this.xMargin,this.isSnapshot)}clip(e){return this.range.to<=e.doc.length?this:new us(Q.cursor(e.doc.length),this.y,this.x,this.yMargin,this.xMargin,this.isSnapshot)}}const Dc=Me.define({map:(t,e)=>t.map(e)}),u6=Me.define();function hn(t,e,n){let r=t.facet(i6);r.length?r[0](e):window.onerror?window.onerror(String(e),n,void 0,void 0,e):n?console.error(n+":",e):console.error(e)}const Kr=fe.define({combine:t=>t.length?t[0]:!0});let rP=0;const ga=fe.define();class vt{constructor(e,n,r,i,o){this.id=e,this.create=n,this.domEventHandlers=r,this.domEventObservers=i,this.extension=o(this)}static define(e,n){const{eventHandlers:r,eventObservers:i,provide:o,decorations:s}=n||{};return new vt(rP++,e,r,i,a=>{let c=[ga.of(a)];return s&&c.push(ja.of(h=>{let f=h.plugin(a);return f?s(f):xe.none})),o&&c.push(o(a)),c})}static fromClass(e,n){return vt.define(r=>new e(r),n)}}class Ld{constructor(e){this.spec=e,this.mustUpdate=null,this.value=null}update(e){if(this.value){if(this.mustUpdate){let n=this.mustUpdate;if(this.mustUpdate=null,this.value.update)try{this.value.update(n)}catch(r){if(hn(n.state,r,"CodeMirror plugin crashed"),this.value.destroy)try{this.value.destroy()}catch{}this.deactivate()}}}else if(this.spec)try{this.value=this.spec.create(e)}catch(n){hn(e.state,n,"CodeMirror plugin crashed"),this.deactivate()}return this}destroy(e){var n;if(!((n=this.value)===null||n===void 0)&&n.destroy)try{this.value.destroy()}catch(r){hn(e.state,r,"CodeMirror plugin crashed")}}deactivate(){this.spec=this.value=null}}const h6=fe.define(),lm=fe.define(),ja=fe.define(),f6=fe.define(),cm=fe.define(),d6=fe.define();function O5(t,e){let n=t.state.facet(d6);if(!n.length)return n;let r=n.map(o=>o instanceof Function?o(t):o),i=[];return Ke.spans(r,e.from,e.to,{point(){},span(o,s,a,c){let h=o-e.from,f=s-e.from,d=i;for(let m=a.length-1;m>=0;m--,c--){let v=a[m].spec.bidiIsolate,w;if(v==null&&(v=nP(e.text,h,f)),c>0&&d.length&&(w=d[d.length-1]).to==h&&w.direction==v)w.to=f,d=w.inner;else{let x={from:h,to:f,direction:v,inner:[]};d.push(x),d=x.inner}}}}),i}const g6=fe.define();function um(t){let e=0,n=0,r=0,i=0;for(let o of t.state.facet(g6)){let s=o(t);s&&(s.left!=null&&(e=Math.max(e,s.left)),s.right!=null&&(n=Math.max(n,s.right)),s.top!=null&&(r=Math.max(r,s.top)),s.bottom!=null&&(i=Math.max(i,s.bottom)))}return{left:e,right:n,top:r,bottom:i}}const ma=fe.define();class Vn{constructor(e,n,r,i){this.fromA=e,this.toA=n,this.fromB=r,this.toB=i}join(e){return new Vn(Math.min(this.fromA,e.fromA),Math.max(this.toA,e.toA),Math.min(this.fromB,e.fromB),Math.max(this.toB,e.toB))}addToSet(e){let n=e.length,r=this;for(;n>0;n--){let i=e[n-1];if(!(i.fromA>r.toA)){if(i.toA<r.fromA)break;r=r.join(i),e.splice(n-1,1)}}return e.splice(n,0,r),e}static extendWithRanges(e,n){if(n.length==0)return e;let r=[];for(let i=0,o=0,s=0,a=0;;i++){let c=i==e.length?null:e[i],h=s-a,f=c?c.fromB:1e9;for(;o<n.length&&n[o]<f;){let d=n[o],m=n[o+1],v=Math.max(a,d),w=Math.min(f,m);if(v<=w&&new Vn(v+h,w+h,v,w).addToSet(r),m>f)break;o+=2}if(!c)return r;new Vn(c.fromA,c.toA,c.fromB,c.toB).addToSet(r),s=c.toA,a=c.toB}}}class Eu{constructor(e,n,r){this.view=e,this.state=n,this.transactions=r,this.flags=0,this.startState=e.state,this.changes=kt.empty(this.startState.doc.length);for(let o of r)this.changes=this.changes.compose(o.changes);let i=[];this.changes.iterChangedRanges((o,s,a,c)=>i.push(new Vn(o,s,a,c))),this.changedRanges=i}static create(e,n,r){return new Eu(e,n,r)}get viewportChanged(){return(this.flags&4)>0}get viewportMoved(){return(this.flags&8)>0}get heightChanged(){return(this.flags&2)>0}get geometryChanged(){return this.docChanged||(this.flags&18)>0}get focusChanged(){return(this.flags&1)>0}get docChanged(){return!this.changes.empty}get selectionSet(){return this.transactions.some(e=>e.selection)}get empty(){return this.flags==0&&this.transactions.length==0}}class D5 extends nt{get length(){return this.view.state.doc.length}constructor(e){super(),this.view=e,this.decorations=[],this.dynamicDecorationMap=[!1],this.domChanged=null,this.hasComposition=null,this.markedForComposition=new Set,this.editContextFormatting=xe.none,this.lastCompositionAfterCursor=!1,this.minWidth=0,this.minWidthFrom=0,this.minWidthTo=0,this.impreciseAnchor=null,this.impreciseHead=null,this.forceSelection=!1,this.lastUpdate=Date.now(),this.setDOM(e.contentDOM),this.children=[new yt],this.children[0].setParent(this),this.updateDeco(),this.updateInner([new Vn(0,0,0,e.state.doc.length)],0,null)}update(e){var n;let r=e.changedRanges;this.minWidth>0&&r.length&&(r.every(({fromA:h,toA:f})=>f<this.minWidthFrom||h>this.minWidthTo)?(this.minWidthFrom=e.changes.mapPos(this.minWidthFrom,1),this.minWidthTo=e.changes.mapPos(this.minWidthTo,1)):this.minWidth=this.minWidthFrom=this.minWidthTo=0),this.updateEditContextFormatting(e);let i=-1;this.view.inputState.composing>=0&&!this.view.observer.editContext&&(!((n=this.domChanged)===null||n===void 0)&&n.newSel?i=this.domChanged.newSel.head:!uP(e.changes,this.hasComposition)&&!e.selectionSet&&(i=e.state.selection.main.head));let o=i>-1?oP(this.view,e.changes,i):null;if(this.domChanged=null,this.hasComposition){this.markedForComposition.clear();let{from:h,to:f}=this.hasComposition;r=new Vn(h,f,e.changes.mapPos(h,-1),e.changes.mapPos(f,1)).addToSet(r.slice())}this.hasComposition=o?{from:o.range.fromB,to:o.range.toB}:null,(ce.ie||ce.chrome)&&!o&&e&&e.state.doc.lines!=e.startState.doc.lines&&(this.forceSelection=!0);let s=this.decorations,a=this.updateDeco(),c=lP(s,a,e.changes);return r=Vn.extendWithRanges(r,c),!(this.flags&7)&&r.length==0?!1:(this.updateInner(r,e.startState.doc.length,o),e.transactions.length&&(this.lastUpdate=Date.now()),!0)}updateInner(e,n,r){this.view.viewState.mustMeasureContent=!0,this.updateChildren(e,n,r);let{observer:i}=this.view;i.ignore(()=>{this.dom.style.height=this.view.viewState.contentHeight/this.view.scaleY+"px",this.dom.style.flexBasis=this.minWidth?this.minWidth+"px":"";let s=ce.chrome||ce.ios?{node:i.selectionRange.focusNode,written:!1}:void 0;this.sync(this.view,s),this.flags&=-8,s&&(s.written||i.selectionRange.focusNode!=s.node)&&(this.forceSelection=!0),this.dom.style.height=""}),this.markedForComposition.forEach(s=>s.flags&=-9);let o=[];if(this.view.viewport.from||this.view.viewport.to<this.view.state.doc.length)for(let s of this.children)s instanceof Xr&&s.widget instanceof i1&&o.push(s.dom);i.updateGaps(o)}updateChildren(e,n,r){let i=r?r.range.addToSet(e.slice()):e,o=this.childCursor(n);for(let s=i.length-1;;s--){let a=s>=0?i[s]:null;if(!a)break;let{fromA:c,toA:h,fromB:f,toB:d}=a,m,v,w,x;if(r&&r.range.fromB<d&&r.range.toB>f){let O=$a.build(this.view.state.doc,f,r.range.fromB,this.decorations,this.dynamicDecorationMap),D=$a.build(this.view.state.doc,r.range.toB,d,this.decorations,this.dynamicDecorationMap);v=O.breakAtStart,w=O.openStart,x=D.openEnd;let L=this.compositionView(r);D.breakAtStart?L.breakAfter=1:D.content.length&&L.merge(L.length,L.length,D.content[0],!1,D.openStart,0)&&(L.breakAfter=D.content[0].breakAfter,D.content.shift()),O.content.length&&L.merge(0,0,O.content[O.content.length-1],!0,0,O.openEnd)&&O.content.pop(),m=O.content.concat(L).concat(D.content)}else({content:m,breakAtStart:v,openStart:w,openEnd:x}=$a.build(this.view.state.doc,f,d,this.decorations,this.dynamicDecorationMap));let{i:C,off:S}=o.findPos(h,1),{i:A,off:T}=o.findPos(c,-1);Py(this,A,T,C,S,m,v,w,x)}r&&this.fixCompositionDOM(r)}updateEditContextFormatting(e){this.editContextFormatting=this.editContextFormatting.map(e.changes);for(let n of e.transactions)for(let r of n.effects)r.is(u6)&&(this.editContextFormatting=r.value)}compositionView(e){let n=new er(e.text.nodeValue);n.flags|=8;for(let{deco:i}of e.marks)n=new ti(i,[n],n.length);let r=new yt;return r.append(n,0),r}fixCompositionDOM(e){let n=(o,s)=>{s.flags|=8|(s.children.some(c=>c.flags&7)?1:0),this.markedForComposition.add(s);let a=nt.get(o);a&&a!=s&&(a.dom=null),s.setDOM(o)},r=this.childPos(e.range.fromB,1),i=this.children[r.i];n(e.line,i);for(let o=e.marks.length-1;o>=-1;o--)r=i.childPos(r.off,1),i=i.children[r.i],n(o>=0?e.marks[o].node:e.text,i)}updateSelection(e=!1,n=!1){(e||!this.view.observer.selectionRange.focusNode)&&this.view.observer.readSelectionRange();let r=this.view.root.activeElement,i=r==this.dom,o=!i&&!(this.view.state.facet(Kr)||this.dom.tabIndex>-1)&&tu(this.dom,this.view.observer.selectionRange)&&!(r&&this.dom.contains(r));if(!(i||n||o))return;let s=this.forceSelection;this.forceSelection=!1;let a=this.view.state.selection.main,c=this.moveToLine(this.domAtPos(a.anchor)),h=a.empty?c:this.moveToLine(this.domAtPos(a.head));if(ce.gecko&&a.empty&&!this.hasComposition&&iP(c)){let d=document.createTextNode("");this.view.observer.ignore(()=>c.node.insertBefore(d,c.node.childNodes[c.offset]||null)),c=h=new qt(d,0),s=!0}let f=this.view.observer.selectionRange;(s||!f.focusNode||(!Ca(c.node,c.offset,f.anchorNode,f.anchorOffset)||!Ca(h.node,h.offset,f.focusNode,f.focusOffset))&&!this.suppressWidgetCursorChange(f,a))&&(this.view.observer.ignore(()=>{ce.android&&ce.chrome&&this.dom.contains(f.focusNode)&&cP(f.focusNode,this.dom)&&(this.dom.blur(),this.dom.focus({preventScroll:!0}));let d=Na(this.view.root);if(d)if(a.empty){if(ce.gecko){let m=sP(c.node,c.offset);if(m&&m!=3){let v=(m==1?Fy:Vy)(c.node,c.offset);v&&(c=new qt(v.node,v.offset))}}d.collapse(c.node,c.offset),a.bidiLevel!=null&&d.caretBidiLevel!==void 0&&(d.caretBidiLevel=a.bidiLevel)}else if(d.extend){d.collapse(c.node,c.offset);try{d.extend(h.node,h.offset)}catch{}}else{let m=document.createRange();a.anchor>a.head&&([c,h]=[h,c]),m.setEnd(h.node,h.offset),m.setStart(c.node,c.offset),d.removeAllRanges(),d.addRange(m)}o&&this.view.root.activeElement==this.dom&&(this.dom.blur(),r&&r.focus())}),this.view.observer.setSelectionRange(c,h)),this.impreciseAnchor=c.precise?null:new qt(f.anchorNode,f.anchorOffset),this.impreciseHead=h.precise?null:new qt(f.focusNode,f.focusOffset)}suppressWidgetCursorChange(e,n){return this.hasComposition&&n.empty&&Ca(e.focusNode,e.focusOffset,e.anchorNode,e.anchorOffset)&&this.posFromDOM(e.focusNode,e.focusOffset)==n.head}enforceCursorAssoc(){if(this.hasComposition)return;let{view:e}=this,n=e.state.selection.main,r=Na(e.root),{anchorNode:i,anchorOffset:o}=e.observer.selectionRange;if(!r||!n.empty||!n.assoc||!r.modify)return;let s=yt.find(this,n.head);if(!s)return;let a=s.posAtStart;if(n.head==a||n.head==a+s.length)return;let c=this.coordsAt(n.head,-1),h=this.coordsAt(n.head,1);if(!c||!h||c.bottom>h.top)return;let f=this.domAtPos(n.head+n.assoc);r.collapse(f.node,f.offset),r.modify("move",n.assoc<0?"forward":"backward","lineboundary"),e.observer.readSelectionRange();let d=e.observer.selectionRange;e.docView.posFromDOM(d.anchorNode,d.anchorOffset)!=n.from&&r.collapse(i,o)}moveToLine(e){let n=this.dom,r;if(e.node!=n)return e;for(let i=e.offset;!r&&i<n.childNodes.length;i++){let o=nt.get(n.childNodes[i]);o instanceof yt&&(r=o.domAtPos(0))}for(let i=e.offset-1;!r&&i>=0;i--){let o=nt.get(n.childNodes[i]);o instanceof yt&&(r=o.domAtPos(o.length))}return r?new qt(r.node,r.offset,!0):e}nearest(e){for(let n=e;n;){let r=nt.get(n);if(r&&r.rootView==this)return r;n=n.parentNode}return null}posFromDOM(e,n){let r=this.nearest(e);if(!r)throw new RangeError("Trying to find position for a DOM position outside of the document");return r.localPosFromDOM(e,n)+r.posAtStart}domAtPos(e){let{i:n,off:r}=this.childCursor().findPos(e,-1);for(;n<this.children.length-1;){let i=this.children[n];if(r<i.length||i instanceof yt)break;n++,r=0}return this.children[n].domAtPos(r)}coordsAt(e,n){let r=null,i=0;for(let o=this.length,s=this.children.length-1;s>=0;s--){let a=this.children[s],c=o-a.breakAfter,h=c-a.length;if(c<e)break;if(h<=e&&(h<e||a.covers(-1))&&(c>e||a.covers(1))&&(!r||a instanceof yt&&!(r instanceof yt&&n>=0)))r=a,i=h;else if(r&&h==e&&c==e&&a instanceof Xr&&Math.abs(n)<2){if(a.deco.startSide<0)break;s&&(r=null)}o=h}return r?r.coordsAt(e-i,n):null}coordsForChar(e){let{i:n,off:r}=this.childPos(e,1),i=this.children[n];if(!(i instanceof yt))return null;for(;i.children.length;){let{i:a,off:c}=i.childPos(r,1);for(;;a++){if(a==i.children.length)return null;if((i=i.children[a]).length)break}r=c}if(!(i instanceof er))return null;let o=Ht(i.text,r);if(o==r)return null;let s=po(i.dom,r,o).getClientRects();for(let a=0;a<s.length;a++){let c=s[a];if(a==s.length-1||c.top<c.bottom&&c.left<c.right)return c}return null}measureVisibleLineHeights(e){let n=[],{from:r,to:i}=e,o=this.view.contentDOM.clientWidth,s=o>Math.max(this.view.scrollDOM.clientWidth,this.minWidth)+1,a=-1,c=this.view.textDirection==st.LTR;for(let h=0,f=0;f<this.children.length;f++){let d=this.children[f],m=h+d.length;if(m>i)break;if(h>=r){let v=d.dom.getBoundingClientRect();if(n.push(v.height),s){let w=d.dom.lastChild,x=w?ys(w):[];if(x.length){let C=x[x.length-1],S=c?C.right-v.left:v.right-C.left;S>a&&(a=S,this.minWidth=o,this.minWidthFrom=h,this.minWidthTo=m)}}}h=m+d.breakAfter}return n}textDirectionAt(e){let{i:n}=this.childPos(e,1);return getComputedStyle(this.children[n].dom).direction=="rtl"?st.RTL:st.LTR}measureTextSize(){for(let o of this.children)if(o instanceof yt){let s=o.measureTextSize();if(s)return s}let e=document.createElement("div"),n,r,i;return e.className="cm-line",e.style.width="99999px",e.style.position="absolute",e.textContent="abc def ghi jkl mno pqr stu",this.view.observer.ignore(()=>{this.dom.appendChild(e);let o=ys(e.firstChild)[0];n=e.getBoundingClientRect().height,r=o?o.width/27:7,i=o?o.height:n,e.remove()}),{lineHeight:n,charWidth:r,textHeight:i}}childCursor(e=this.length){let n=this.children.length;return n&&(e-=this.children[--n].length),new Hy(this.children,e,n)}computeBlockGapDeco(){let e=[],n=this.view.viewState;for(let r=0,i=0;;i++){let o=i==n.viewports.length?null:n.viewports[i],s=o?o.from-1:this.length;if(s>r){let a=(n.lineBlockAt(s).bottom-n.lineBlockAt(r).top)/this.view.scaleY;e.push(xe.replace({widget:new i1(a),block:!0,inclusive:!0,isBlockGap:!0}).range(r,s))}if(!o)break;r=o.to+1}return xe.set(e)}updateDeco(){let e=1,n=this.view.state.facet(ja).map(o=>(this.dynamicDecorationMap[e++]=typeof o=="function")?o(this.view):o),r=!1,i=this.view.state.facet(f6).map((o,s)=>{let a=typeof o=="function";return a&&(r=!0),a?o(this.view):o});for(i.length&&(this.dynamicDecorationMap[e++]=r,n.push(Ke.join(i))),this.decorations=[this.editContextFormatting,...n,this.computeBlockGapDeco(),this.view.viewState.lineGapDeco];e<this.decorations.length;)this.dynamicDecorationMap[e++]=!1;return this.decorations}scrollIntoView(e){if(e.isSnapshot){let h=this.view.viewState.lineBlockAt(e.range.head);this.view.scrollDOM.scrollTop=h.top-e.yMargin,this.view.scrollDOM.scrollLeft=e.xMargin;return}for(let h of this.view.state.facet(c6))try{if(h(this.view,e.range,e))return!0}catch(f){hn(this.view.state,f,"scroll handler")}let{range:n}=e,r=this.coordsAt(n.head,n.empty?n.assoc:n.head>n.anchor?-1:1),i;if(!r)return;!n.empty&&(i=this.coordsAt(n.anchor,n.anchor>n.head?-1:1))&&(r={left:Math.min(r.left,i.left),top:Math.min(r.top,i.top),right:Math.max(r.right,i.right),bottom:Math.max(r.bottom,i.bottom)});let o=um(this.view),s={left:r.left-o.left,top:r.top-o.top,right:r.right+o.right,bottom:r.bottom+o.bottom},{offsetWidth:a,offsetHeight:c}=this.view.scrollDOM;jH(this.view.scrollDOM,s,n.head<n.anchor?-1:1,e.x,e.y,Math.max(Math.min(e.xMargin,a),-a),Math.max(Math.min(e.yMargin,c),-c),this.view.textDirection==st.LTR)}}function iP(t){return t.node.nodeType==1&&t.node.firstChild&&(t.offset==0||t.node.childNodes[t.offset-1].contentEditable=="false")&&(t.offset==t.node.childNodes.length||t.node.childNodes[t.offset].contentEditable=="false")}function m6(t,e){let n=t.observer.selectionRange;if(!n.focusNode)return null;let r=Fy(n.focusNode,n.focusOffset),i=Vy(n.focusNode,n.focusOffset),o=r||i;if(i&&r&&i.node!=r.node){let a=nt.get(i.node);if(!a||a instanceof er&&a.text!=i.node.nodeValue)o=i;else if(t.docView.lastCompositionAfterCursor){let c=nt.get(r.node);!c||c instanceof er&&c.text!=r.node.nodeValue||(o=i)}}if(t.docView.lastCompositionAfterCursor=o!=r,!o)return null;let s=e-o.offset;return{from:s,to:s+o.node.nodeValue.length,node:o.node}}function oP(t,e,n){let r=m6(t,n);if(!r)return null;let{node:i,from:o,to:s}=r,a=i.nodeValue;if(/[\n\r]/.test(a)||t.state.doc.sliceString(r.from,r.to)!=a)return null;let c=e.invertedDesc,h=new Vn(c.mapPos(o),c.mapPos(s),o,s),f=[];for(let d=i.parentNode;;d=d.parentNode){let m=nt.get(d);if(m instanceof ti)f.push({node:d,deco:m.mark});else{if(m instanceof yt||d.nodeName=="DIV"&&d.parentNode==t.contentDOM)return{range:h,text:i,marks:f,line:d};if(d!=t.contentDOM)f.push({node:d,deco:new ul({inclusive:!0,attributes:qH(d),tagName:d.tagName.toLowerCase()})});else return null}}}function sP(t,e){return t.nodeType!=1?0:(e&&t.childNodes[e-1].contentEditable=="false"?1:0)|(e<t.childNodes.length&&t.childNodes[e].contentEditable=="false"?2:0)}let aP=class{constructor(){this.changes=[]}compareRange(e,n){nu(e,n,this.changes)}comparePoint(e,n){nu(e,n,this.changes)}boundChange(e){nu(e,e,this.changes)}};function lP(t,e,n){let r=new aP;return Ke.compare(t,e,n,r),r.changes}function cP(t,e){for(let n=t;n&&n!=e;n=n.assignedSlot||n.parentNode)if(n.nodeType==1&&n.contentEditable=="false")return!0;return!1}function uP(t,e){let n=!1;return e&&t.iterChangedRanges((r,i)=>{r<e.to&&i>e.from&&(n=!0)}),n}function hP(t,e,n=1){let r=t.charCategorizer(e),i=t.doc.lineAt(e),o=e-i.from;if(i.length==0)return Q.cursor(e);o==0?n=1:o==i.length&&(n=-1);let s=o,a=o;n<0?s=Ht(i.text,o,!1):a=Ht(i.text,o);let c=r(i.text.slice(s,a));for(;s>0;){let h=Ht(i.text,s,!1);if(r(i.text.slice(h,s))!=c)break;s=h}for(;a<i.length;){let h=Ht(i.text,a);if(r(i.text.slice(a,h))!=c)break;a=h}return Q.range(s+i.from,a+i.from)}function fP(t,e){return e.left>t?e.left-t:Math.max(0,t-e.right)}function dP(t,e){return e.top>t?e.top-t:Math.max(0,t-e.bottom)}function Bd(t,e){return t.top<e.bottom-1&&t.bottom>e.top+1}function I5(t,e){return e<t.top?{top:e,left:t.left,right:t.right,bottom:t.bottom}:t}function _5(t,e){return e>t.bottom?{top:t.top,left:t.left,right:t.right,bottom:e}:t}function c1(t,e,n){let r,i,o,s,a=!1,c,h,f,d;for(let w=t.firstChild;w;w=w.nextSibling){let x=ys(w);for(let C=0;C<x.length;C++){let S=x[C];i&&Bd(i,S)&&(S=I5(_5(S,i.bottom),i.top));let A=fP(e,S),T=dP(n,S);if(A==0&&T==0)return w.nodeType==3?L5(w,e,n):c1(w,e,n);if(!r||s>T||s==T&&o>A){r=w,i=S,o=A,s=T;let O=T?n<S.top?-1:1:A?e<S.left?-1:1:0;a=!O||(O>0?C<x.length-1:C>0)}A==0?n>S.bottom&&(!f||f.bottom<S.bottom)?(c=w,f=S):n<S.top&&(!d||d.top>S.top)&&(h=w,d=S):f&&Bd(f,S)?f=_5(f,S.bottom):d&&Bd(d,S)&&(d=I5(d,S.top))}}if(f&&f.bottom>=n?(r=c,i=f):d&&d.top<=n&&(r=h,i=d),!r)return{node:t,offset:0};let m=Math.max(i.left,Math.min(i.right,e));if(r.nodeType==3)return L5(r,m,n);if(a&&r.contentEditable!="false")return c1(r,m,n);let v=Array.prototype.indexOf.call(t.childNodes,r)+(e>=(i.left+i.right)/2?1:0);return{node:t,offset:v}}function L5(t,e,n){let r=t.nodeValue.length,i=-1,o=1e9,s=0;for(let a=0;a<r;a++){let c=po(t,a,a+1).getClientRects();for(let h=0;h<c.length;h++){let f=c[h];if(f.top==f.bottom)continue;s||(s=e-f.left);let d=(f.top>n?f.top-n:n-f.bottom)-1;if(f.left-1<=e&&f.right+1>=e&&d<o){let m=e>=(f.left+f.right)/2,v=m;if((ce.chrome||ce.gecko)&&po(t,a).getBoundingClientRect().left==f.right&&(v=!m),d<=0)return{node:t,offset:a+(v?1:0)};i=a+(v?1:0),o=d}}}return{node:t,offset:i>-1?i:s>0?t.nodeValue.length:0}}function p6(t,e,n,r=-1){var i,o;let s=t.contentDOM.getBoundingClientRect(),a=s.top+t.viewState.paddingTop,c,{docHeight:h}=t.viewState,{x:f,y:d}=e,m=d-a;if(m<0)return 0;if(m>h)return t.state.doc.length;for(let O=t.viewState.heightOracle.textHeight/2,D=!1;c=t.elementAtHeight(m),c.type!=en.Text;)for(;m=r>0?c.bottom+O:c.top-O,!(m>=0&&m<=h);){if(D)return n?null:0;D=!0,r=-r}d=a+m;let v=c.from;if(v<t.viewport.from)return t.viewport.from==0?0:n?null:B5(t,s,c,f,d);if(v>t.viewport.to)return t.viewport.to==t.state.doc.length?t.state.doc.length:n?null:B5(t,s,c,f,d);let w=t.dom.ownerDocument,x=t.root.elementFromPoint?t.root:w,C=x.elementFromPoint(f,d);C&&!t.contentDOM.contains(C)&&(C=null),C||(f=Math.max(s.left+1,Math.min(s.right-1,f)),C=x.elementFromPoint(f,d),C&&!t.contentDOM.contains(C)&&(C=null));let S,A=-1;if(C&&((i=t.docView.nearest(C))===null||i===void 0?void 0:i.isEditable)!=!1){if(w.caretPositionFromPoint){let O=w.caretPositionFromPoint(f,d);O&&({offsetNode:S,offset:A}=O)}else if(w.caretRangeFromPoint){let O=w.caretRangeFromPoint(f,d);O&&({startContainer:S,startOffset:A}=O,(!t.contentDOM.contains(S)||ce.safari&&gP(S,A,f)||ce.chrome&&mP(S,A,f))&&(S=void 0))}S&&(A=Math.min(Sr(S),A))}if(!S||!t.docView.dom.contains(S)){let O=yt.find(t.docView,v);if(!O)return m>c.top+c.height/2?c.to:c.from;({node:S,offset:A}=c1(O.dom,f,d))}let T=t.docView.nearest(S);if(!T)return null;if(T.isWidget&&((o=T.dom)===null||o===void 0?void 0:o.nodeType)==1){let O=T.dom.getBoundingClientRect();return e.y<O.top||e.y<=O.bottom&&e.x<=(O.left+O.right)/2?T.posAtStart:T.posAtEnd}else return T.localPosFromDOM(S,A)+T.posAtStart}function B5(t,e,n,r,i){let o=Math.round((r-e.left)*t.defaultCharacterWidth);if(t.lineWrapping&&n.height>t.defaultLineHeight*1.5){let a=t.viewState.heightOracle.textHeight,c=Math.floor((i-n.top-(t.defaultLineHeight-a)*.5)/a);o+=c*t.viewState.heightOracle.lineLength}let s=t.state.sliceDoc(n.from,n.to);return n.from+Y0(s,o,t.state.tabSize)}function gP(t,e,n){let r;if(t.nodeType!=3||e!=(r=t.nodeValue.length))return!1;for(let i=t.nextSibling;i;i=i.nextSibling)if(i.nodeType!=1||i.nodeName!="BR")return!1;return po(t,r-1,r).getBoundingClientRect().left>n}function mP(t,e,n){if(e!=0)return!1;for(let i=t;;){let o=i.parentNode;if(!o||o.nodeType!=1||o.firstChild!=i)return!1;if(o.classList.contains("cm-line"))break;i=o}let r=t.nodeType==1?t.getBoundingClientRect():po(t,0,Math.max(t.nodeValue.length,1)).getBoundingClientRect();return n-r.left>5}function u1(t,e){let n=t.lineBlockAt(e);if(Array.isArray(n.type)){for(let r of n.type)if(r.to>e||r.to==e&&(r.to==n.to||r.type==en.Text))return r}return n}function pP(t,e,n,r){let i=u1(t,e.head),o=!r||i.type!=en.Text||!(t.lineWrapping||i.widgetLineBreaks)?null:t.coordsAtPos(e.assoc<0&&e.head>i.from?e.head-1:e.head);if(o){let s=t.dom.getBoundingClientRect(),a=t.textDirectionAt(i.from),c=t.posAtCoords({x:n==(a==st.LTR)?s.right-1:s.left+1,y:(o.top+o.bottom)/2});if(c!=null)return Q.cursor(c,n?-1:1)}return Q.cursor(n?i.to:i.from,n?-1:1)}function N5(t,e,n,r){let i=t.state.doc.lineAt(e.head),o=t.bidiSpans(i),s=t.textDirectionAt(i.from);for(let a=e,c=null;;){let h=tP(i,o,s,a,n),f=e6;if(!h){if(i.number==(n?t.state.doc.lines:1))return a;f=`
54
- `,i=t.state.doc.line(i.number+(n?1:-1)),o=t.bidiSpans(i),h=t.visualLineSide(i,!n)}if(c){if(!c(f))return a}else{if(!r)return h;c=r(f)}a=h}}function vP(t,e,n){let r=t.state.charCategorizer(e),i=r(n);return o=>{let s=r(o);return i==lt.Space&&(i=s),i==s}}function bP(t,e,n,r){let i=e.head,o=n?1:-1;if(i==(n?t.state.doc.length:0))return Q.cursor(i,e.assoc);let s=e.goalColumn,a,c=t.contentDOM.getBoundingClientRect(),h=t.coordsAtPos(i,e.assoc||-1),f=t.documentTop;if(h)s==null&&(s=h.left-c.left),a=o<0?h.top:h.bottom;else{let v=t.viewState.lineBlockAt(i);s==null&&(s=Math.min(c.right-c.left,t.defaultCharacterWidth*(i-v.from))),a=(o<0?v.top:v.bottom)+f}let d=c.left+s,m=r??t.viewState.heightOracle.textHeight>>1;for(let v=0;;v+=10){let w=a+(m+v)*o,x=p6(t,{x:d,y:w},!1,o);if(w<c.top||w>c.bottom||(o<0?x<i:x>i)){let C=t.docView.coordsForChar(x),S=!C||w<C.top?-1:1;return Q.cursor(x,S,void 0,s)}}}function ru(t,e,n){for(;;){let r=0;for(let i of t)i.between(e-1,e+1,(o,s,a)=>{if(e>o&&e<s){let c=r||n||(e-o<s-e?-1:1);e=c<0?o:s,r=c}});if(!r)return e}}function Nd(t,e,n){let r=ru(t.state.facet(cm).map(i=>i(t)),n.from,e.head>n.from?-1:1);return r==n.from?n:Q.cursor(r,r<n.from?1:-1)}const pa="￿";class wP{constructor(e,n){this.points=e,this.text="",this.lineSeparator=n.facet(qe.lineSeparator)}append(e){this.text+=e}lineBreak(){this.text+=pa}readRange(e,n){if(!e)return this;let r=e.parentNode;for(let i=e;;){this.findPointBefore(r,i);let o=this.text.length;this.readNode(i);let s=i.nextSibling;if(s==n)break;let a=nt.get(i),c=nt.get(s);(a&&c?a.breakAfter:(a?a.breakAfter:Tu(i))||Tu(s)&&(i.nodeName!="BR"||i.cmIgnore)&&this.text.length>o)&&this.lineBreak(),i=s}return this.findPointBefore(r,n),this}readTextNode(e){let n=e.nodeValue;for(let r of this.points)r.node==e&&(r.pos=this.text.length+Math.min(r.offset,n.length));for(let r=0,i=this.lineSeparator?null:/\r\n?|\n/g;;){let o=-1,s=1,a;if(this.lineSeparator?(o=n.indexOf(this.lineSeparator,r),s=this.lineSeparator.length):(a=i.exec(n))&&(o=a.index,s=a[0].length),this.append(n.slice(r,o<0?n.length:o)),o<0)break;if(this.lineBreak(),s>1)for(let c of this.points)c.node==e&&c.pos>this.text.length&&(c.pos-=s-1);r=o+s}}readNode(e){if(e.cmIgnore)return;let n=nt.get(e),r=n&&n.overrideDOMText;if(r!=null){this.findPointInside(e,r.length);for(let i=r.iter();!i.next().done;)i.lineBreak?this.lineBreak():this.append(i.value)}else e.nodeType==3?this.readTextNode(e):e.nodeName=="BR"?e.nextSibling&&this.lineBreak():e.nodeType==1&&this.readRange(e.firstChild,null)}findPointBefore(e,n){for(let r of this.points)r.node==e&&e.childNodes[r.offset]==n&&(r.pos=this.text.length)}findPointInside(e,n){for(let r of this.points)(e.nodeType==3?r.node==e:e.contains(r.node))&&(r.pos=this.text.length+(xP(e,r.node,r.offset)?n:0))}}function xP(t,e,n){for(;;){if(!e||n<Sr(e))return!1;if(e==t)return!0;n=mo(e)+1,e=e.parentNode}}class j5{constructor(e,n){this.node=e,this.offset=n,this.pos=-1}}class yP{constructor(e,n,r,i){this.typeOver=i,this.bounds=null,this.text="",this.domChanged=n>-1;let{impreciseHead:o,impreciseAnchor:s}=e.docView;if(e.state.readOnly&&n>-1)this.newSel=null;else if(n>-1&&(this.bounds=e.docView.domBoundsAround(n,r,0))){let a=o||s?[]:SP(e),c=new wP(a,e.state);c.readRange(this.bounds.startDOM,this.bounds.endDOM),this.text=c.text,this.newSel=AP(a,this.bounds.from)}else{let a=e.observer.selectionRange,c=o&&o.node==a.focusNode&&o.offset==a.focusOffset||!Q0(e.contentDOM,a.focusNode)?e.state.selection.main.head:e.docView.posFromDOM(a.focusNode,a.focusOffset),h=s&&s.node==a.anchorNode&&s.offset==a.anchorOffset||!Q0(e.contentDOM,a.anchorNode)?e.state.selection.main.anchor:e.docView.posFromDOM(a.anchorNode,a.anchorOffset),f=e.viewport;if((ce.ios||ce.chrome)&&e.state.selection.main.empty&&c!=h&&(f.from>0||f.to<e.state.doc.length)){let d=Math.min(c,h),m=Math.max(c,h),v=f.from-d,w=f.to-m;(v==0||v==1||d==0)&&(w==0||w==-1||m==e.state.doc.length)&&(c=0,h=e.state.doc.length)}this.newSel=Q.single(h,c)}}}function v6(t,e){let n,{newSel:r}=e,i=t.state.selection.main,o=t.inputState.lastKeyTime>Date.now()-100?t.inputState.lastKeyCode:-1;if(e.bounds){let{from:s,to:a}=e.bounds,c=i.from,h=null;(o===8||ce.android&&e.text.length<a-s)&&(c=i.to,h="end");let f=$P(t.state.doc.sliceString(s,a,pa),e.text,c-s,h);f&&(ce.chrome&&o==13&&f.toB==f.from+2&&e.text.slice(f.from,f.toB)==pa+pa&&f.toB--,n={from:s+f.from,to:s+f.toA,insert:Ge.of(e.text.slice(f.from,f.toB).split(pa))})}else r&&(!t.hasFocus&&t.state.facet(Kr)||r.main.eq(i))&&(r=null);if(!n&&!r)return!1;if(!n&&e.typeOver&&!i.empty&&r&&r.main.empty?n={from:i.from,to:i.to,insert:t.state.doc.slice(i.from,i.to)}:(ce.mac||ce.android)&&n&&n.from==n.to&&n.from==i.head-1&&/^\. ?$/.test(n.insert.toString())&&t.contentDOM.getAttribute("autocorrect")=="off"?(r&&n.insert.length==2&&(r=Q.single(r.main.anchor-1,r.main.head-1)),n={from:n.from,to:n.to,insert:Ge.of([n.insert.toString().replace("."," ")])}):n&&n.from>=i.from&&n.to<=i.to&&(n.from!=i.from||n.to!=i.to)&&i.to-i.from-(n.to-n.from)<=4?n={from:i.from,to:i.to,insert:t.state.doc.slice(i.from,n.from).append(n.insert).append(t.state.doc.slice(n.to,i.to))}:ce.chrome&&n&&n.from==n.to&&n.from==i.head&&n.insert.toString()==`
55
- `&&t.lineWrapping&&(r&&(r=Q.single(r.main.anchor-1,r.main.head-1)),n={from:i.from,to:i.to,insert:Ge.of([" "])}),n)return hm(t,n,r,o);if(r&&!r.main.eq(i)){let s=!1,a="select";return t.inputState.lastSelectionTime>Date.now()-50&&(t.inputState.lastSelectionOrigin=="select"&&(s=!0),a=t.inputState.lastSelectionOrigin),t.dispatch({selection:r,scrollIntoView:s,userEvent:a}),!0}else return!1}function hm(t,e,n,r=-1){if(ce.ios&&t.inputState.flushIOSKey(e))return!0;let i=t.state.selection.main;if(ce.android&&(e.to==i.to&&(e.from==i.from||e.from==i.from-1&&t.state.sliceDoc(e.from,i.from)==" ")&&e.insert.length==1&&e.insert.lines==2&&cs(t.contentDOM,"Enter",13)||(e.from==i.from-1&&e.to==i.to&&e.insert.length==0||r==8&&e.insert.length<e.to-e.from&&e.to>i.head)&&cs(t.contentDOM,"Backspace",8)||e.from==i.from&&e.to==i.to+1&&e.insert.length==0&&cs(t.contentDOM,"Delete",46)))return!0;let o=e.insert.toString();t.inputState.composing>=0&&t.inputState.composing++;let s,a=()=>s||(s=CP(t,e,n));return t.state.facet(o6).some(c=>c(t,e.from,e.to,o,a))||t.dispatch(a()),!0}function CP(t,e,n){let r,i=t.state,o=i.selection.main;if(e.from>=o.from&&e.to<=o.to&&e.to-e.from>=(o.to-o.from)/3&&(!n||n.main.empty&&n.main.from==e.from+e.insert.length)&&t.inputState.composing<0){let a=o.from<e.from?i.sliceDoc(o.from,e.from):"",c=o.to>e.to?i.sliceDoc(e.to,o.to):"";r=i.replaceSelection(t.state.toText(a+e.insert.sliceString(0,void 0,t.state.lineBreak)+c))}else{let a=i.changes(e),c=n&&n.main.to<=a.newLength?n.main:void 0;if(i.selection.ranges.length>1&&t.inputState.composing>=0&&e.to<=o.to&&e.to>=o.to-10){let h=t.state.sliceDoc(e.from,e.to),f,d=n&&m6(t,n.main.head);if(d){let w=e.insert.length-(e.to-e.from);f={from:d.from,to:d.to-w}}else f=t.state.doc.lineAt(o.head);let m=o.to-e.to,v=o.to-o.from;r=i.changeByRange(w=>{if(w.from==o.from&&w.to==o.to)return{changes:a,range:c||w.map(a)};let x=w.to-m,C=x-h.length;if(w.to-w.from!=v||t.state.sliceDoc(C,x)!=h||w.to>=f.from&&w.from<=f.to)return{range:w};let S=i.changes({from:C,to:x,insert:e.insert}),A=w.to-o.to;return{changes:S,range:c?Q.range(Math.max(0,c.anchor+A),Math.max(0,c.head+A)):w.map(S)}})}else r={changes:a,selection:c&&i.selection.replaceRange(c)}}let s="input.type";return(t.composing||t.inputState.compositionPendingChange&&t.inputState.compositionEndedAt>Date.now()-50)&&(t.inputState.compositionPendingChange=!1,s+=".compose",t.inputState.compositionFirstChange&&(s+=".start",t.inputState.compositionFirstChange=!1)),i.update(r,{userEvent:s,scrollIntoView:!0})}function $P(t,e,n,r){let i=Math.min(t.length,e.length),o=0;for(;o<i&&t.charCodeAt(o)==e.charCodeAt(o);)o++;if(o==i&&t.length==e.length)return null;let s=t.length,a=e.length;for(;s>0&&a>0&&t.charCodeAt(s-1)==e.charCodeAt(a-1);)s--,a--;if(r=="end"){let c=Math.max(0,o-Math.min(s,a));n-=s+c-o}if(s<o&&t.length<e.length){let c=n<=o&&n>=s?o-n:0;o-=c,a=o+(a-s),s=o}else if(a<o){let c=n<=o&&n>=a?o-n:0;o-=c,s=o+(s-a),a=o}return{from:o,toA:s,toB:a}}function SP(t){let e=[];if(t.root.activeElement!=t.contentDOM)return e;let{anchorNode:n,anchorOffset:r,focusNode:i,focusOffset:o}=t.observer.selectionRange;return n&&(e.push(new j5(n,r)),(i!=n||o!=r)&&e.push(new j5(i,o))),e}function AP(t,e){if(t.length==0)return null;let n=t[0].pos,r=t.length==2?t[1].pos:n;return n>-1&&r>-1?Q.single(n+e,r+e):null}class RP{setSelectionOrigin(e){this.lastSelectionOrigin=e,this.lastSelectionTime=Date.now()}constructor(e){this.view=e,this.lastKeyCode=0,this.lastKeyTime=0,this.lastTouchTime=0,this.lastFocusTime=0,this.lastScrollTop=0,this.lastScrollLeft=0,this.pendingIOSKey=void 0,this.tabFocusMode=-1,this.lastSelectionOrigin=null,this.lastSelectionTime=0,this.lastContextMenu=0,this.scrollHandlers=[],this.handlers=Object.create(null),this.composing=-1,this.compositionFirstChange=null,this.compositionEndedAt=0,this.compositionPendingKey=!1,this.compositionPendingChange=!1,this.mouseSelection=null,this.draggedContent=null,this.handleEvent=this.handleEvent.bind(this),this.notifiedFocused=e.hasFocus,ce.safari&&e.contentDOM.addEventListener("input",()=>null),ce.gecko&&PP(e.contentDOM.ownerDocument)}handleEvent(e){!_P(this.view,e)||this.ignoreDuringComposition(e)||e.type=="keydown"&&this.keydown(e)||(this.view.updateState!=0?Promise.resolve().then(()=>this.runHandlers(e.type,e)):this.runHandlers(e.type,e))}runHandlers(e,n){let r=this.handlers[e];if(r){for(let i of r.observers)i(this.view,n);for(let i of r.handlers){if(n.defaultPrevented)break;if(i(this.view,n)){n.preventDefault();break}}}}ensureHandlers(e){let n=kP(e),r=this.handlers,i=this.view.contentDOM;for(let o in n)if(o!="scroll"){let s=!n[o].handlers.length,a=r[o];a&&s!=!a.handlers.length&&(i.removeEventListener(o,this.handleEvent),a=null),a||i.addEventListener(o,this.handleEvent,{passive:s})}for(let o in r)o!="scroll"&&!n[o]&&i.removeEventListener(o,this.handleEvent);this.handlers=n}keydown(e){if(this.lastKeyCode=e.keyCode,this.lastKeyTime=Date.now(),e.keyCode==9&&this.tabFocusMode>-1&&(!this.tabFocusMode||Date.now()<=this.tabFocusMode))return!0;if(this.tabFocusMode>0&&e.keyCode!=27&&w6.indexOf(e.keyCode)<0&&(this.tabFocusMode=-1),ce.android&&ce.chrome&&!e.synthetic&&(e.keyCode==13||e.keyCode==8))return this.view.observer.delayAndroidKey(e.key,e.keyCode),!0;let n;return ce.ios&&!e.synthetic&&!e.altKey&&!e.metaKey&&((n=b6.find(r=>r.keyCode==e.keyCode))&&!e.ctrlKey||TP.indexOf(e.key)>-1&&e.ctrlKey&&!e.shiftKey)?(this.pendingIOSKey=n||e,setTimeout(()=>this.flushIOSKey(),250),!0):(e.keyCode!=229&&this.view.observer.forceFlush(),!1)}flushIOSKey(e){let n=this.pendingIOSKey;return!n||n.key=="Enter"&&e&&e.from<e.to&&/^\S+$/.test(e.insert.toString())?!1:(this.pendingIOSKey=void 0,cs(this.view.contentDOM,n.key,n.keyCode,n instanceof KeyboardEvent?n:void 0))}ignoreDuringComposition(e){return/^key/.test(e.type)?this.composing>0?!0:ce.safari&&!ce.ios&&this.compositionPendingKey&&Date.now()-this.compositionEndedAt<100?(this.compositionPendingKey=!1,!0):!1:!1}startMouseSelection(e){this.mouseSelection&&this.mouseSelection.destroy(),this.mouseSelection=e}update(e){this.view.observer.update(e),this.mouseSelection&&this.mouseSelection.update(e),this.draggedContent&&e.docChanged&&(this.draggedContent=this.draggedContent.map(e.changes)),e.transactions.length&&(this.lastKeyCode=this.lastSelectionTime=0)}destroy(){this.mouseSelection&&this.mouseSelection.destroy()}}function F5(t,e){return(n,r)=>{try{return e.call(t,r,n)}catch(i){hn(n.state,i)}}}function kP(t){let e=Object.create(null);function n(r){return e[r]||(e[r]={observers:[],handlers:[]})}for(let r of t){let i=r.spec;if(i&&i.domEventHandlers)for(let o in i.domEventHandlers){let s=i.domEventHandlers[o];s&&n(o).handlers.push(F5(r.value,s))}if(i&&i.domEventObservers)for(let o in i.domEventObservers){let s=i.domEventObservers[o];s&&n(o).observers.push(F5(r.value,s))}}for(let r in tr)n(r).handlers.push(tr[r]);for(let r in Hn)n(r).observers.push(Hn[r]);return e}const b6=[{key:"Backspace",keyCode:8,inputType:"deleteContentBackward"},{key:"Enter",keyCode:13,inputType:"insertParagraph"},{key:"Enter",keyCode:13,inputType:"insertLineBreak"},{key:"Delete",keyCode:46,inputType:"deleteContentForward"}],TP="dthko",w6=[16,17,18,20,91,92,224,225],Ic=6;function _c(t){return Math.max(0,t)*.7+8}function MP(t,e){return Math.max(Math.abs(t.clientX-e.clientX),Math.abs(t.clientY-e.clientY))}class EP{constructor(e,n,r,i){this.view=e,this.startEvent=n,this.style=r,this.mustSelect=i,this.scrollSpeed={x:0,y:0},this.scrolling=-1,this.lastEvent=n,this.scrollParents=FH(e.contentDOM),this.atoms=e.state.facet(cm).map(s=>s(e));let o=e.contentDOM.ownerDocument;o.addEventListener("mousemove",this.move=this.move.bind(this)),o.addEventListener("mouseup",this.up=this.up.bind(this)),this.extend=n.shiftKey,this.multiple=e.state.facet(qe.allowMultipleSelections)&&OP(e,n),this.dragging=IP(e,n)&&C6(n)==1?null:!1}start(e){this.dragging===!1&&this.select(e)}move(e){if(e.buttons==0)return this.destroy();if(this.dragging||this.dragging==null&&MP(this.startEvent,e)<10)return;this.select(this.lastEvent=e);let n=0,r=0,i=0,o=0,s=this.view.win.innerWidth,a=this.view.win.innerHeight;this.scrollParents.x&&({left:i,right:s}=this.scrollParents.x.getBoundingClientRect()),this.scrollParents.y&&({top:o,bottom:a}=this.scrollParents.y.getBoundingClientRect());let c=um(this.view);e.clientX-c.left<=i+Ic?n=-_c(i-e.clientX):e.clientX+c.right>=s-Ic&&(n=_c(e.clientX-s)),e.clientY-c.top<=o+Ic?r=-_c(o-e.clientY):e.clientY+c.bottom>=a-Ic&&(r=_c(e.clientY-a)),this.setScrollSpeed(n,r)}up(e){this.dragging==null&&this.select(this.lastEvent),this.dragging||e.preventDefault(),this.destroy()}destroy(){this.setScrollSpeed(0,0);let e=this.view.contentDOM.ownerDocument;e.removeEventListener("mousemove",this.move),e.removeEventListener("mouseup",this.up),this.view.inputState.mouseSelection=this.view.inputState.draggedContent=null}setScrollSpeed(e,n){this.scrollSpeed={x:e,y:n},e||n?this.scrolling<0&&(this.scrolling=setInterval(()=>this.scroll(),50)):this.scrolling>-1&&(clearInterval(this.scrolling),this.scrolling=-1)}scroll(){let{x:e,y:n}=this.scrollSpeed;e&&this.scrollParents.x&&(this.scrollParents.x.scrollLeft+=e,e=0),n&&this.scrollParents.y&&(this.scrollParents.y.scrollTop+=n,n=0),(e||n)&&this.view.win.scrollBy(e,n),this.dragging===!1&&this.select(this.lastEvent)}skipAtoms(e){let n=null;for(let r=0;r<e.ranges.length;r++){let i=e.ranges[r],o=null;if(i.empty){let s=ru(this.atoms,i.from,0);s!=i.from&&(o=Q.cursor(s,-1))}else{let s=ru(this.atoms,i.from,-1),a=ru(this.atoms,i.to,1);(s!=i.from||a!=i.to)&&(o=Q.range(i.from==i.anchor?s:a,i.from==i.head?s:a))}o&&(n||(n=e.ranges.slice()),n[r]=o)}return n?Q.create(n,e.mainIndex):e}select(e){let{view:n}=this,r=this.skipAtoms(this.style.get(e,this.extend,this.multiple));(this.mustSelect||!r.eq(n.state.selection,this.dragging===!1))&&this.view.dispatch({selection:r,userEvent:"select.pointer"}),this.mustSelect=!1}update(e){e.transactions.some(n=>n.isUserEvent("input.type"))?this.destroy():this.style.update(e)&&setTimeout(()=>this.select(this.lastEvent),20)}}function OP(t,e){let n=t.state.facet(t6);return n.length?n[0](e):ce.mac?e.metaKey:e.ctrlKey}function DP(t,e){let n=t.state.facet(n6);return n.length?n[0](e):ce.mac?!e.altKey:!e.ctrlKey}function IP(t,e){let{main:n}=t.state.selection;if(n.empty)return!1;let r=Na(t.root);if(!r||r.rangeCount==0)return!0;let i=r.getRangeAt(0).getClientRects();for(let o=0;o<i.length;o++){let s=i[o];if(s.left<=e.clientX&&s.right>=e.clientX&&s.top<=e.clientY&&s.bottom>=e.clientY)return!0}return!1}function _P(t,e){if(!e.bubbles)return!0;if(e.defaultPrevented)return!1;for(let n=e.target,r;n!=t.contentDOM;n=n.parentNode)if(!n||n.nodeType==11||(r=nt.get(n))&&r.ignoreEvent(e))return!1;return!0}const tr=Object.create(null),Hn=Object.create(null),x6=ce.ie&&ce.ie_version<15||ce.ios&&ce.webkit_version<604;function LP(t){let e=t.dom.parentNode;if(!e)return;let n=e.appendChild(document.createElement("textarea"));n.style.cssText="position: fixed; left: -10000px; top: 10px",n.focus(),setTimeout(()=>{t.focus(),n.remove(),y6(t,n.value)},50)}function Ch(t,e,n){for(let r of t.facet(e))n=r(n,t);return n}function y6(t,e){e=Ch(t.state,sm,e);let{state:n}=t,r,i=1,o=n.toText(e),s=o.lines==n.selection.ranges.length;if(h1!=null&&n.selection.ranges.every(c=>c.empty)&&h1==o.toString()){let c=-1;r=n.changeByRange(h=>{let f=n.doc.lineAt(h.from);if(f.from==c)return{range:h};c=f.from;let d=n.toText((s?o.line(i++).text:e)+n.lineBreak);return{changes:{from:f.from,insert:d},range:Q.cursor(h.from+d.length)}})}else s?r=n.changeByRange(c=>{let h=o.line(i++);return{changes:{from:c.from,to:c.to,insert:h.text},range:Q.cursor(c.from+h.length)}}):r=n.replaceSelection(o);t.dispatch(r,{userEvent:"input.paste",scrollIntoView:!0})}Hn.scroll=t=>{t.inputState.lastScrollTop=t.scrollDOM.scrollTop,t.inputState.lastScrollLeft=t.scrollDOM.scrollLeft};tr.keydown=(t,e)=>(t.inputState.setSelectionOrigin("select"),e.keyCode==27&&t.inputState.tabFocusMode!=0&&(t.inputState.tabFocusMode=Date.now()+2e3),!1);Hn.touchstart=(t,e)=>{t.inputState.lastTouchTime=Date.now(),t.inputState.setSelectionOrigin("select.pointer")};Hn.touchmove=t=>{t.inputState.setSelectionOrigin("select.pointer")};tr.mousedown=(t,e)=>{if(t.observer.flush(),t.inputState.lastTouchTime>Date.now()-2e3)return!1;let n=null;for(let r of t.state.facet(r6))if(n=r(t,e),n)break;if(!n&&e.button==0&&(n=jP(t,e)),n){let r=!t.hasFocus;t.inputState.startMouseSelection(new EP(t,e,n,r)),r&&t.observer.ignore(()=>{By(t.contentDOM);let o=t.root.activeElement;o&&!o.contains(t.contentDOM)&&o.blur()});let i=t.inputState.mouseSelection;if(i)return i.start(e),i.dragging===!1}return!1};function V5(t,e,n,r){if(r==1)return Q.cursor(e,n);if(r==2)return hP(t.state,e,n);{let i=yt.find(t.docView,e),o=t.state.doc.lineAt(i?i.posAtEnd:e),s=i?i.posAtStart:o.from,a=i?i.posAtEnd:o.to;return a<t.state.doc.length&&a==o.to&&a++,Q.range(s,a)}}let H5=(t,e,n)=>e>=n.top&&e<=n.bottom&&t>=n.left&&t<=n.right;function BP(t,e,n,r){let i=yt.find(t.docView,e);if(!i)return 1;let o=e-i.posAtStart;if(o==0)return 1;if(o==i.length)return-1;let s=i.coordsAt(o,-1);if(s&&H5(n,r,s))return-1;let a=i.coordsAt(o,1);return a&&H5(n,r,a)?1:s&&s.bottom>=r?-1:1}function P5(t,e){let n=t.posAtCoords({x:e.clientX,y:e.clientY},!1);return{pos:n,bias:BP(t,n,e.clientX,e.clientY)}}const NP=ce.ie&&ce.ie_version<=11;let W5=null,z5=0,U5=0;function C6(t){if(!NP)return t.detail;let e=W5,n=U5;return W5=t,U5=Date.now(),z5=!e||n>Date.now()-400&&Math.abs(e.clientX-t.clientX)<2&&Math.abs(e.clientY-t.clientY)<2?(z5+1)%3:1}function jP(t,e){let n=P5(t,e),r=C6(e),i=t.state.selection;return{update(o){o.docChanged&&(n.pos=o.changes.mapPos(n.pos),i=i.map(o.changes))},get(o,s,a){let c=P5(t,o),h,f=V5(t,c.pos,c.bias,r);if(n.pos!=c.pos&&!s){let d=V5(t,n.pos,n.bias,r),m=Math.min(d.from,f.from),v=Math.max(d.to,f.to);f=m<f.from?Q.range(m,v):Q.range(v,m)}return s?i.replaceRange(i.main.extend(f.from,f.to)):a&&r==1&&i.ranges.length>1&&(h=FP(i,c.pos))?h:a?i.addRange(f):Q.create([f])}}}function FP(t,e){for(let n=0;n<t.ranges.length;n++){let{from:r,to:i}=t.ranges[n];if(r<=e&&i>=e)return Q.create(t.ranges.slice(0,n).concat(t.ranges.slice(n+1)),t.mainIndex==n?0:t.mainIndex-(t.mainIndex>n?1:0))}return null}tr.dragstart=(t,e)=>{let{selection:{main:n}}=t.state;if(e.target.draggable){let i=t.docView.nearest(e.target);if(i&&i.isWidget){let o=i.posAtStart,s=o+i.length;(o>=n.to||s<=n.from)&&(n=Q.range(o,s))}}let{inputState:r}=t;return r.mouseSelection&&(r.mouseSelection.dragging=!0),r.draggedContent=n,e.dataTransfer&&(e.dataTransfer.setData("Text",Ch(t.state,am,t.state.sliceDoc(n.from,n.to))),e.dataTransfer.effectAllowed="copyMove"),!1};tr.dragend=t=>(t.inputState.draggedContent=null,!1);function q5(t,e,n,r){if(n=Ch(t.state,sm,n),!n)return;let i=t.posAtCoords({x:e.clientX,y:e.clientY},!1),{draggedContent:o}=t.inputState,s=r&&o&&DP(t,e)?{from:o.from,to:o.to}:null,a={from:i,insert:n},c=t.state.changes(s?[s,a]:a);t.focus(),t.dispatch({changes:c,selection:{anchor:c.mapPos(i,-1),head:c.mapPos(i,1)},userEvent:s?"move.drop":"input.drop"}),t.inputState.draggedContent=null}tr.drop=(t,e)=>{if(!e.dataTransfer)return!1;if(t.state.readOnly)return!0;let n=e.dataTransfer.files;if(n&&n.length){let r=Array(n.length),i=0,o=()=>{++i==n.length&&q5(t,e,r.filter(s=>s!=null).join(t.state.lineBreak),!1)};for(let s=0;s<n.length;s++){let a=new FileReader;a.onerror=o,a.onload=()=>{/[\x00-\x08\x0e-\x1f]{2}/.test(a.result)||(r[s]=a.result),o()},a.readAsText(n[s])}return!0}else{let r=e.dataTransfer.getData("Text");if(r)return q5(t,e,r,!0),!0}return!1};tr.paste=(t,e)=>{if(t.state.readOnly)return!0;t.observer.flush();let n=x6?null:e.clipboardData;return n?(y6(t,n.getData("text/plain")||n.getData("text/uri-list")),!0):(LP(t),!1)};function VP(t,e){let n=t.dom.parentNode;if(!n)return;let r=n.appendChild(document.createElement("textarea"));r.style.cssText="position: fixed; left: -10000px; top: 10px",r.value=e,r.focus(),r.selectionEnd=e.length,r.selectionStart=0,setTimeout(()=>{r.remove(),t.focus()},50)}function HP(t){let e=[],n=[],r=!1;for(let i of t.selection.ranges)i.empty||(e.push(t.sliceDoc(i.from,i.to)),n.push(i));if(!e.length){let i=-1;for(let{from:o}of t.selection.ranges){let s=t.doc.lineAt(o);s.number>i&&(e.push(s.text),n.push({from:s.from,to:Math.min(t.doc.length,s.to+1)})),i=s.number}r=!0}return{text:Ch(t,am,e.join(t.lineBreak)),ranges:n,linewise:r}}let h1=null;tr.copy=tr.cut=(t,e)=>{let{text:n,ranges:r,linewise:i}=HP(t.state);if(!n&&!i)return!1;h1=i?n:null,e.type=="cut"&&!t.state.readOnly&&t.dispatch({changes:r,scrollIntoView:!0,userEvent:"delete.cut"});let o=x6?null:e.clipboardData;return o?(o.clearData(),o.setData("text/plain",n),!0):(VP(t,n),!1)};const $6=Tr.define();function S6(t,e){let n=[];for(let r of t.facet(s6)){let i=r(t,e);i&&n.push(i)}return n?t.update({effects:n,annotations:$6.of(!0)}):null}function A6(t){setTimeout(()=>{let e=t.hasFocus;if(e!=t.inputState.notifiedFocused){let n=S6(t.state,e);n?t.dispatch(n):t.update([])}},10)}Hn.focus=t=>{t.inputState.lastFocusTime=Date.now(),!t.scrollDOM.scrollTop&&(t.inputState.lastScrollTop||t.inputState.lastScrollLeft)&&(t.scrollDOM.scrollTop=t.inputState.lastScrollTop,t.scrollDOM.scrollLeft=t.inputState.lastScrollLeft),A6(t)};Hn.blur=t=>{t.observer.clearSelectionRange(),A6(t)};Hn.compositionstart=Hn.compositionupdate=t=>{t.observer.editContext||(t.inputState.compositionFirstChange==null&&(t.inputState.compositionFirstChange=!0),t.inputState.composing<0&&(t.inputState.composing=0))};Hn.compositionend=t=>{t.observer.editContext||(t.inputState.composing=-1,t.inputState.compositionEndedAt=Date.now(),t.inputState.compositionPendingKey=!0,t.inputState.compositionPendingChange=t.observer.pendingRecords().length>0,t.inputState.compositionFirstChange=null,ce.chrome&&ce.android?t.observer.flushSoon():t.inputState.compositionPendingChange?Promise.resolve().then(()=>t.observer.flush()):setTimeout(()=>{t.inputState.composing<0&&t.docView.hasComposition&&t.update([])},50))};Hn.contextmenu=t=>{t.inputState.lastContextMenu=Date.now()};tr.beforeinput=(t,e)=>{var n,r;if(e.inputType=="insertReplacementText"&&t.observer.editContext){let o=(n=e.dataTransfer)===null||n===void 0?void 0:n.getData("text/plain"),s=e.getTargetRanges();if(o&&s.length){let a=s[0],c=t.posAtDOM(a.startContainer,a.startOffset),h=t.posAtDOM(a.endContainer,a.endOffset);return hm(t,{from:c,to:h,insert:t.state.toText(o)},null),!0}}let i;if(ce.chrome&&ce.android&&(i=b6.find(o=>o.inputType==e.inputType))&&(t.observer.delayAndroidKey(i.key,i.keyCode),i.key=="Backspace"||i.key=="Delete")){let o=((r=window.visualViewport)===null||r===void 0?void 0:r.height)||0;setTimeout(()=>{var s;(((s=window.visualViewport)===null||s===void 0?void 0:s.height)||0)>o+10&&t.hasFocus&&(t.contentDOM.blur(),t.focus())},100)}return ce.ios&&e.inputType=="deleteContentForward"&&t.observer.flushSoon(),ce.safari&&e.inputType=="insertText"&&t.inputState.composing>=0&&setTimeout(()=>Hn.compositionend(t,e),20),!1};const K5=new Set;function PP(t){K5.has(t)||(K5.add(t),t.addEventListener("copy",()=>{}),t.addEventListener("cut",()=>{}))}const G5=["pre-wrap","normal","pre-line","break-spaces"];let Ss=!1;function Y5(){Ss=!1}class WP{constructor(e){this.lineWrapping=e,this.doc=Ge.empty,this.heightSamples={},this.lineHeight=14,this.charWidth=7,this.textHeight=14,this.lineLength=30}heightForGap(e,n){let r=this.doc.lineAt(n).number-this.doc.lineAt(e).number+1;return this.lineWrapping&&(r+=Math.max(0,Math.ceil((n-e-r*this.lineLength*.5)/this.lineLength))),this.lineHeight*r}heightForLine(e){return this.lineWrapping?(1+Math.max(0,Math.ceil((e-this.lineLength)/(this.lineLength-5))))*this.lineHeight:this.lineHeight}setDoc(e){return this.doc=e,this}mustRefreshForWrapping(e){return G5.indexOf(e)>-1!=this.lineWrapping}mustRefreshForHeights(e){let n=!1;for(let r=0;r<e.length;r++){let i=e[r];i<0?r++:this.heightSamples[Math.floor(i*10)]||(n=!0,this.heightSamples[Math.floor(i*10)]=!0)}return n}refresh(e,n,r,i,o,s){let a=G5.indexOf(e)>-1,c=Math.round(n)!=Math.round(this.lineHeight)||this.lineWrapping!=a;if(this.lineWrapping=a,this.lineHeight=n,this.charWidth=r,this.textHeight=i,this.lineLength=o,c){this.heightSamples={};for(let h=0;h<s.length;h++){let f=s[h];f<0?h++:this.heightSamples[Math.floor(f*10)]=!0}}return c}}class zP{constructor(e,n){this.from=e,this.heights=n,this.index=0}get more(){return this.index<this.heights.length}}class pr{constructor(e,n,r,i,o){this.from=e,this.length=n,this.top=r,this.height=i,this._content=o}get type(){return typeof this._content=="number"?en.Text:Array.isArray(this._content)?this._content:this._content.type}get to(){return this.from+this.length}get bottom(){return this.top+this.height}get widget(){return this._content instanceof Ii?this._content.widget:null}get widgetLineBreaks(){return typeof this._content=="number"?this._content:0}join(e){let n=(Array.isArray(this._content)?this._content:[this]).concat(Array.isArray(e._content)?e._content:[e]);return new pr(this.from,this.length+e.length,this.top,this.height+e.height,n)}}var ot=function(t){return t[t.ByPos=0]="ByPos",t[t.ByHeight=1]="ByHeight",t[t.ByPosNoHeight=2]="ByPosNoHeight",t}(ot||(ot={}));const iu=.001;class tn{constructor(e,n,r=2){this.length=e,this.height=n,this.flags=r}get outdated(){return(this.flags&2)>0}set outdated(e){this.flags=(e?2:0)|this.flags&-3}setHeight(e){this.height!=e&&(Math.abs(this.height-e)>iu&&(Ss=!0),this.height=e)}replace(e,n,r){return tn.of(r)}decomposeLeft(e,n){n.push(this)}decomposeRight(e,n){n.push(this)}applyChanges(e,n,r,i){let o=this,s=r.doc;for(let a=i.length-1;a>=0;a--){let{fromA:c,toA:h,fromB:f,toB:d}=i[a],m=o.lineAt(c,ot.ByPosNoHeight,r.setDoc(n),0,0),v=m.to>=h?m:o.lineAt(h,ot.ByPosNoHeight,r,0,0);for(d+=v.to-h,h=v.to;a>0&&m.from<=i[a-1].toA;)c=i[a-1].fromA,f=i[a-1].fromB,a--,c<m.from&&(m=o.lineAt(c,ot.ByPosNoHeight,r,0,0));f+=m.from-c,c=m.from;let w=fm.build(r.setDoc(s),e,f,d);o=Ou(o,o.replace(c,h,w))}return o.updateHeight(r,0)}static empty(){return new Sn(0,0)}static of(e){if(e.length==1)return e[0];let n=0,r=e.length,i=0,o=0;for(;;)if(n==r)if(i>o*2){let a=e[n-1];a.break?e.splice(--n,1,a.left,null,a.right):e.splice(--n,1,a.left,a.right),r+=1+a.break,i-=a.size}else if(o>i*2){let a=e[r];a.break?e.splice(r,1,a.left,null,a.right):e.splice(r,1,a.left,a.right),r+=2+a.break,o-=a.size}else break;else if(i<o){let a=e[n++];a&&(i+=a.size)}else{let a=e[--r];a&&(o+=a.size)}let s=0;return e[n-1]==null?(s=1,n--):e[n]==null&&(s=1,r++),new UP(tn.of(e.slice(0,n)),s,tn.of(e.slice(r)))}}function Ou(t,e){return t==e?t:(t.constructor!=e.constructor&&(Ss=!0),e)}tn.prototype.size=1;class R6 extends tn{constructor(e,n,r){super(e,n),this.deco=r}blockAt(e,n,r,i){return new pr(i,this.length,r,this.height,this.deco||0)}lineAt(e,n,r,i,o){return this.blockAt(0,r,i,o)}forEachLine(e,n,r,i,o,s){e<=o+this.length&&n>=o&&s(this.blockAt(0,r,i,o))}updateHeight(e,n=0,r=!1,i){return i&&i.from<=n&&i.more&&this.setHeight(i.heights[i.index++]),this.outdated=!1,this}toString(){return`block(${this.length})`}}class Sn extends R6{constructor(e,n){super(e,n,null),this.collapsed=0,this.widgetHeight=0,this.breaks=0}blockAt(e,n,r,i){return new pr(i,this.length,r,this.height,this.breaks)}replace(e,n,r){let i=r[0];return r.length==1&&(i instanceof Sn||i instanceof Ft&&i.flags&4)&&Math.abs(this.length-i.length)<10?(i instanceof Ft?i=new Sn(i.length,this.height):i.height=this.height,this.outdated||(i.outdated=!1),i):tn.of(r)}updateHeight(e,n=0,r=!1,i){return i&&i.from<=n&&i.more?this.setHeight(i.heights[i.index++]):(r||this.outdated)&&this.setHeight(Math.max(this.widgetHeight,e.heightForLine(this.length-this.collapsed))+this.breaks*e.lineHeight),this.outdated=!1,this}toString(){return`line(${this.length}${this.collapsed?-this.collapsed:""}${this.widgetHeight?":"+this.widgetHeight:""})`}}class Ft extends tn{constructor(e){super(e,0)}heightMetrics(e,n){let r=e.doc.lineAt(n).number,i=e.doc.lineAt(n+this.length).number,o=i-r+1,s,a=0;if(e.lineWrapping){let c=Math.min(this.height,e.lineHeight*o);s=c/o,this.length>o+1&&(a=(this.height-c)/(this.length-o-1))}else s=this.height/o;return{firstLine:r,lastLine:i,perLine:s,perChar:a}}blockAt(e,n,r,i){let{firstLine:o,lastLine:s,perLine:a,perChar:c}=this.heightMetrics(n,i);if(n.lineWrapping){let h=i+(e<n.lineHeight?0:Math.round(Math.max(0,Math.min(1,(e-r)/this.height))*this.length)),f=n.doc.lineAt(h),d=a+f.length*c,m=Math.max(r,e-d/2);return new pr(f.from,f.length,m,d,0)}else{let h=Math.max(0,Math.min(s-o,Math.floor((e-r)/a))),{from:f,length:d}=n.doc.line(o+h);return new pr(f,d,r+a*h,a,0)}}lineAt(e,n,r,i,o){if(n==ot.ByHeight)return this.blockAt(e,r,i,o);if(n==ot.ByPosNoHeight){let{from:v,to:w}=r.doc.lineAt(e);return new pr(v,w-v,0,0,0)}let{firstLine:s,perLine:a,perChar:c}=this.heightMetrics(r,o),h=r.doc.lineAt(e),f=a+h.length*c,d=h.number-s,m=i+a*d+c*(h.from-o-d);return new pr(h.from,h.length,Math.max(i,Math.min(m,i+this.height-f)),f,0)}forEachLine(e,n,r,i,o,s){e=Math.max(e,o),n=Math.min(n,o+this.length);let{firstLine:a,perLine:c,perChar:h}=this.heightMetrics(r,o);for(let f=e,d=i;f<=n;){let m=r.doc.lineAt(f);if(f==e){let w=m.number-a;d+=c*w+h*(e-o-w)}let v=c+h*m.length;s(new pr(m.from,m.length,d,v,0)),d+=v,f=m.to+1}}replace(e,n,r){let i=this.length-n;if(i>0){let o=r[r.length-1];o instanceof Ft?r[r.length-1]=new Ft(o.length+i):r.push(null,new Ft(i-1))}if(e>0){let o=r[0];o instanceof Ft?r[0]=new Ft(e+o.length):r.unshift(new Ft(e-1),null)}return tn.of(r)}decomposeLeft(e,n){n.push(new Ft(e-1),null)}decomposeRight(e,n){n.push(null,new Ft(this.length-e-1))}updateHeight(e,n=0,r=!1,i){let o=n+this.length;if(i&&i.from<=n+this.length&&i.more){let s=[],a=Math.max(n,i.from),c=-1;for(i.from>n&&s.push(new Ft(i.from-n-1).updateHeight(e,n));a<=o&&i.more;){let f=e.doc.lineAt(a).length;s.length&&s.push(null);let d=i.heights[i.index++];c==-1?c=d:Math.abs(d-c)>=iu&&(c=-2);let m=new Sn(f,d);m.outdated=!1,s.push(m),a+=f+1}a<=o&&s.push(null,new Ft(o-a).updateHeight(e,a));let h=tn.of(s);return(c<0||Math.abs(h.height-this.height)>=iu||Math.abs(c-this.heightMetrics(e,n).perLine)>=iu)&&(Ss=!0),Ou(this,h)}else(r||this.outdated)&&(this.setHeight(e.heightForGap(n,n+this.length)),this.outdated=!1);return this}toString(){return`gap(${this.length})`}}class UP extends tn{constructor(e,n,r){super(e.length+n+r.length,e.height+r.height,n|(e.outdated||r.outdated?2:0)),this.left=e,this.right=r,this.size=e.size+r.size}get break(){return this.flags&1}blockAt(e,n,r,i){let o=r+this.left.height;return e<o?this.left.blockAt(e,n,r,i):this.right.blockAt(e,n,o,i+this.left.length+this.break)}lineAt(e,n,r,i,o){let s=i+this.left.height,a=o+this.left.length+this.break,c=n==ot.ByHeight?e<s:e<a,h=c?this.left.lineAt(e,n,r,i,o):this.right.lineAt(e,n,r,s,a);if(this.break||(c?h.to<a:h.from>a))return h;let f=n==ot.ByPosNoHeight?ot.ByPosNoHeight:ot.ByPos;return c?h.join(this.right.lineAt(a,f,r,s,a)):this.left.lineAt(a,f,r,i,o).join(h)}forEachLine(e,n,r,i,o,s){let a=i+this.left.height,c=o+this.left.length+this.break;if(this.break)e<c&&this.left.forEachLine(e,n,r,i,o,s),n>=c&&this.right.forEachLine(e,n,r,a,c,s);else{let h=this.lineAt(c,ot.ByPos,r,i,o);e<h.from&&this.left.forEachLine(e,h.from-1,r,i,o,s),h.to>=e&&h.from<=n&&s(h),n>h.to&&this.right.forEachLine(h.to+1,n,r,a,c,s)}}replace(e,n,r){let i=this.left.length+this.break;if(n<i)return this.balanced(this.left.replace(e,n,r),this.right);if(e>this.left.length)return this.balanced(this.left,this.right.replace(e-i,n-i,r));let o=[];e>0&&this.decomposeLeft(e,o);let s=o.length;for(let a of r)o.push(a);if(e>0&&X5(o,s-1),n<this.length){let a=o.length;this.decomposeRight(n,o),X5(o,a)}return tn.of(o)}decomposeLeft(e,n){let r=this.left.length;if(e<=r)return this.left.decomposeLeft(e,n);n.push(this.left),this.break&&(r++,e>=r&&n.push(null)),e>r&&this.right.decomposeLeft(e-r,n)}decomposeRight(e,n){let r=this.left.length,i=r+this.break;if(e>=i)return this.right.decomposeRight(e-i,n);e<r&&this.left.decomposeRight(e,n),this.break&&e<i&&n.push(null),n.push(this.right)}balanced(e,n){return e.size>2*n.size||n.size>2*e.size?tn.of(this.break?[e,null,n]:[e,n]):(this.left=Ou(this.left,e),this.right=Ou(this.right,n),this.setHeight(e.height+n.height),this.outdated=e.outdated||n.outdated,this.size=e.size+n.size,this.length=e.length+this.break+n.length,this)}updateHeight(e,n=0,r=!1,i){let{left:o,right:s}=this,a=n+o.length+this.break,c=null;return i&&i.from<=n+o.length&&i.more?c=o=o.updateHeight(e,n,r,i):o.updateHeight(e,n,r),i&&i.from<=a+s.length&&i.more?c=s=s.updateHeight(e,a,r,i):s.updateHeight(e,a,r),c?this.balanced(o,s):(this.height=this.left.height+this.right.height,this.outdated=!1,this)}toString(){return this.left+(this.break?" ":"-")+this.right}}function X5(t,e){let n,r;t[e]==null&&(n=t[e-1])instanceof Ft&&(r=t[e+1])instanceof Ft&&t.splice(e-1,3,new Ft(n.length+1+r.length))}const qP=5;class fm{constructor(e,n){this.pos=e,this.oracle=n,this.nodes=[],this.lineStart=-1,this.lineEnd=-1,this.covering=null,this.writtenTo=e}get isCovered(){return this.covering&&this.nodes[this.nodes.length-1]==this.covering}span(e,n){if(this.lineStart>-1){let r=Math.min(n,this.lineEnd),i=this.nodes[this.nodes.length-1];i instanceof Sn?i.length+=r-this.pos:(r>this.pos||!this.isCovered)&&this.nodes.push(new Sn(r-this.pos,-1)),this.writtenTo=r,n>r&&(this.nodes.push(null),this.writtenTo++,this.lineStart=-1)}this.pos=n}point(e,n,r){if(e<n||r.heightRelevant){let i=r.widget?r.widget.estimatedHeight:0,o=r.widget?r.widget.lineBreaks:0;i<0&&(i=this.oracle.lineHeight);let s=n-e;r.block?this.addBlock(new R6(s,i,r)):(s||o||i>=qP)&&this.addLineDeco(i,o,s)}else n>e&&this.span(e,n);this.lineEnd>-1&&this.lineEnd<this.pos&&(this.lineEnd=this.oracle.doc.lineAt(this.pos).to)}enterLine(){if(this.lineStart>-1)return;let{from:e,to:n}=this.oracle.doc.lineAt(this.pos);this.lineStart=e,this.lineEnd=n,this.writtenTo<e&&((this.writtenTo<e-1||this.nodes[this.nodes.length-1]==null)&&this.nodes.push(this.blankContent(this.writtenTo,e-1)),this.nodes.push(null)),this.pos>e&&this.nodes.push(new Sn(this.pos-e,-1)),this.writtenTo=this.pos}blankContent(e,n){let r=new Ft(n-e);return this.oracle.doc.lineAt(e).to==n&&(r.flags|=4),r}ensureLine(){this.enterLine();let e=this.nodes.length?this.nodes[this.nodes.length-1]:null;if(e instanceof Sn)return e;let n=new Sn(0,-1);return this.nodes.push(n),n}addBlock(e){this.enterLine();let n=e.deco;n&&n.startSide>0&&!this.isCovered&&this.ensureLine(),this.nodes.push(e),this.writtenTo=this.pos=this.pos+e.length,n&&n.endSide>0&&(this.covering=e)}addLineDeco(e,n,r){let i=this.ensureLine();i.length+=r,i.collapsed+=r,i.widgetHeight=Math.max(i.widgetHeight,e),i.breaks+=n,this.writtenTo=this.pos=this.pos+r}finish(e){let n=this.nodes.length==0?null:this.nodes[this.nodes.length-1];this.lineStart>-1&&!(n instanceof Sn)&&!this.isCovered?this.nodes.push(new Sn(0,-1)):(this.writtenTo<this.pos||n==null)&&this.nodes.push(this.blankContent(this.writtenTo,this.pos));let r=e;for(let i of this.nodes)i instanceof Sn&&i.updateHeight(this.oracle,r),r+=i?i.length:1;return this.nodes}static build(e,n,r,i){let o=new fm(r,e);return Ke.spans(n,r,i,o,0),o.finish(r)}}function KP(t,e,n){let r=new GP;return Ke.compare(t,e,n,r,0),r.changes}class GP{constructor(){this.changes=[]}compareRange(){}comparePoint(e,n,r,i){(e<n||r&&r.heightRelevant||i&&i.heightRelevant)&&nu(e,n,this.changes,5)}}function YP(t,e){let n=t.getBoundingClientRect(),r=t.ownerDocument,i=r.defaultView||window,o=Math.max(0,n.left),s=Math.min(i.innerWidth,n.right),a=Math.max(0,n.top),c=Math.min(i.innerHeight,n.bottom);for(let h=t.parentNode;h&&h!=r.body;)if(h.nodeType==1){let f=h,d=window.getComputedStyle(f);if((f.scrollHeight>f.clientHeight||f.scrollWidth>f.clientWidth)&&d.overflow!="visible"){let m=f.getBoundingClientRect();o=Math.max(o,m.left),s=Math.min(s,m.right),a=Math.max(a,m.top),c=Math.min(h==t.parentNode?i.innerHeight:c,m.bottom)}h=d.position=="absolute"||d.position=="fixed"?f.offsetParent:f.parentNode}else if(h.nodeType==11)h=h.host;else break;return{left:o-n.left,right:Math.max(o,s)-n.left,top:a-(n.top+e),bottom:Math.max(a,c)-(n.top+e)}}function XP(t){let e=t.getBoundingClientRect(),n=t.ownerDocument.defaultView||window;return e.left<n.innerWidth&&e.right>0&&e.top<n.innerHeight&&e.bottom>0}function ZP(t,e){let n=t.getBoundingClientRect();return{left:0,right:n.right-n.left,top:e,bottom:n.bottom-(n.top+e)}}class jd{constructor(e,n,r,i){this.from=e,this.to=n,this.size=r,this.displaySize=i}static same(e,n){if(e.length!=n.length)return!1;for(let r=0;r<e.length;r++){let i=e[r],o=n[r];if(i.from!=o.from||i.to!=o.to||i.size!=o.size)return!1}return!0}draw(e,n){return xe.replace({widget:new QP(this.displaySize*(n?e.scaleY:e.scaleX),n)}).range(this.from,this.to)}}class QP extends ai{constructor(e,n){super(),this.size=e,this.vertical=n}eq(e){return e.size==this.size&&e.vertical==this.vertical}toDOM(){let e=document.createElement("div");return this.vertical?e.style.height=this.size+"px":(e.style.width=this.size+"px",e.style.height="2px",e.style.display="inline-block"),e}get estimatedHeight(){return this.vertical?this.size:-1}}class Z5{constructor(e){this.state=e,this.pixelViewport={left:0,right:window.innerWidth,top:0,bottom:0},this.inView=!0,this.paddingTop=0,this.paddingBottom=0,this.contentDOMWidth=0,this.contentDOMHeight=0,this.editorHeight=0,this.editorWidth=0,this.scrollTop=0,this.scrolledToBottom=!1,this.scaleX=1,this.scaleY=1,this.scrollAnchorPos=0,this.scrollAnchorHeight=-1,this.scaler=Q5,this.scrollTarget=null,this.printing=!1,this.mustMeasureContent=!0,this.defaultTextDirection=st.LTR,this.visibleRanges=[],this.mustEnforceCursorAssoc=!1;let n=e.facet(lm).some(r=>typeof r!="function"&&r.class=="cm-lineWrapping");this.heightOracle=new WP(n),this.stateDeco=e.facet(ja).filter(r=>typeof r!="function"),this.heightMap=tn.empty().applyChanges(this.stateDeco,Ge.empty,this.heightOracle.setDoc(e.doc),[new Vn(0,0,0,e.doc.length)]);for(let r=0;r<2&&(this.viewport=this.getViewport(0,null),!!this.updateForViewport());r++);this.updateViewportLines(),this.lineGaps=this.ensureLineGaps([]),this.lineGapDeco=xe.set(this.lineGaps.map(r=>r.draw(this,!1))),this.computeVisibleRanges()}updateForViewport(){let e=[this.viewport],{main:n}=this.state.selection;for(let r=0;r<=1;r++){let i=r?n.head:n.anchor;if(!e.some(({from:o,to:s})=>i>=o&&i<=s)){let{from:o,to:s}=this.lineBlockAt(i);e.push(new Lc(o,s))}}return this.viewports=e.sort((r,i)=>r.from-i.from),this.updateScaler()}updateScaler(){let e=this.scaler;return this.scaler=this.heightMap.height<=7e6?Q5:new dm(this.heightOracle,this.heightMap,this.viewports),e.eq(this.scaler)?0:2}updateViewportLines(){this.viewportLines=[],this.heightMap.forEachLine(this.viewport.from,this.viewport.to,this.heightOracle.setDoc(this.state.doc),0,0,e=>{this.viewportLines.push(va(e,this.scaler))})}update(e,n=null){this.state=e.state;let r=this.stateDeco;this.stateDeco=this.state.facet(ja).filter(f=>typeof f!="function");let i=e.changedRanges,o=Vn.extendWithRanges(i,KP(r,this.stateDeco,e?e.changes:kt.empty(this.state.doc.length))),s=this.heightMap.height,a=this.scrolledToBottom?null:this.scrollAnchorAt(this.scrollTop);Y5(),this.heightMap=this.heightMap.applyChanges(this.stateDeco,e.startState.doc,this.heightOracle.setDoc(this.state.doc),o),(this.heightMap.height!=s||Ss)&&(e.flags|=2),a?(this.scrollAnchorPos=e.changes.mapPos(a.from,-1),this.scrollAnchorHeight=a.top):(this.scrollAnchorPos=-1,this.scrollAnchorHeight=this.heightMap.height);let c=o.length?this.mapViewport(this.viewport,e.changes):this.viewport;(n&&(n.range.head<c.from||n.range.head>c.to)||!this.viewportIsAppropriate(c))&&(c=this.getViewport(0,n));let h=c.from!=this.viewport.from||c.to!=this.viewport.to;this.viewport=c,e.flags|=this.updateForViewport(),(h||!e.changes.empty||e.flags&2)&&this.updateViewportLines(),(this.lineGaps.length||this.viewport.to-this.viewport.from>4e3)&&this.updateLineGaps(this.ensureLineGaps(this.mapLineGaps(this.lineGaps,e.changes))),e.flags|=this.computeVisibleRanges(e.changes),n&&(this.scrollTarget=n),!this.mustEnforceCursorAssoc&&e.selectionSet&&e.view.lineWrapping&&e.state.selection.main.empty&&e.state.selection.main.assoc&&!e.state.facet(l6)&&(this.mustEnforceCursorAssoc=!0)}measure(e){let n=e.contentDOM,r=window.getComputedStyle(n),i=this.heightOracle,o=r.whiteSpace;this.defaultTextDirection=r.direction=="rtl"?st.RTL:st.LTR;let s=this.heightOracle.mustRefreshForWrapping(o),a=n.getBoundingClientRect(),c=s||this.mustMeasureContent||this.contentDOMHeight!=a.height;this.contentDOMHeight=a.height,this.mustMeasureContent=!1;let h=0,f=0;if(a.width&&a.height){let{scaleX:O,scaleY:D}=Ly(n,a);(O>.005&&Math.abs(this.scaleX-O)>.005||D>.005&&Math.abs(this.scaleY-D)>.005)&&(this.scaleX=O,this.scaleY=D,h|=16,s=c=!0)}let d=(parseInt(r.paddingTop)||0)*this.scaleY,m=(parseInt(r.paddingBottom)||0)*this.scaleY;(this.paddingTop!=d||this.paddingBottom!=m)&&(this.paddingTop=d,this.paddingBottom=m,h|=18),this.editorWidth!=e.scrollDOM.clientWidth&&(i.lineWrapping&&(c=!0),this.editorWidth=e.scrollDOM.clientWidth,h|=16);let v=e.scrollDOM.scrollTop*this.scaleY;this.scrollTop!=v&&(this.scrollAnchorHeight=-1,this.scrollTop=v),this.scrolledToBottom=jy(e.scrollDOM);let w=(this.printing?ZP:YP)(n,this.paddingTop),x=w.top-this.pixelViewport.top,C=w.bottom-this.pixelViewport.bottom;this.pixelViewport=w;let S=this.pixelViewport.bottom>this.pixelViewport.top&&this.pixelViewport.right>this.pixelViewport.left;if(S!=this.inView&&(this.inView=S,S&&(c=!0)),!this.inView&&!this.scrollTarget&&!XP(e.dom))return 0;let A=a.width;if((this.contentDOMWidth!=A||this.editorHeight!=e.scrollDOM.clientHeight)&&(this.contentDOMWidth=a.width,this.editorHeight=e.scrollDOM.clientHeight,h|=16),c){let O=e.docView.measureVisibleLineHeights(this.viewport);if(i.mustRefreshForHeights(O)&&(s=!0),s||i.lineWrapping&&Math.abs(A-this.contentDOMWidth)>i.charWidth){let{lineHeight:D,charWidth:L,textHeight:I}=e.docView.measureTextSize();s=D>0&&i.refresh(o,D,L,I,A/L,O),s&&(e.docView.minWidth=0,h|=16)}x>0&&C>0?f=Math.max(x,C):x<0&&C<0&&(f=Math.min(x,C)),Y5();for(let D of this.viewports){let L=D.from==this.viewport.from?O:e.docView.measureVisibleLineHeights(D);this.heightMap=(s?tn.empty().applyChanges(this.stateDeco,Ge.empty,this.heightOracle,[new Vn(0,0,0,e.state.doc.length)]):this.heightMap).updateHeight(i,0,s,new zP(D.from,L))}Ss&&(h|=2)}let T=!this.viewportIsAppropriate(this.viewport,f)||this.scrollTarget&&(this.scrollTarget.range.head<this.viewport.from||this.scrollTarget.range.head>this.viewport.to);return T&&(h&2&&(h|=this.updateScaler()),this.viewport=this.getViewport(f,this.scrollTarget),h|=this.updateForViewport()),(h&2||T)&&this.updateViewportLines(),(this.lineGaps.length||this.viewport.to-this.viewport.from>4e3)&&this.updateLineGaps(this.ensureLineGaps(s?[]:this.lineGaps,e)),h|=this.computeVisibleRanges(),this.mustEnforceCursorAssoc&&(this.mustEnforceCursorAssoc=!1,e.docView.enforceCursorAssoc()),h}get visibleTop(){return this.scaler.fromDOM(this.pixelViewport.top)}get visibleBottom(){return this.scaler.fromDOM(this.pixelViewport.bottom)}getViewport(e,n){let r=.5-Math.max(-.5,Math.min(.5,e/1e3/2)),i=this.heightMap,o=this.heightOracle,{visibleTop:s,visibleBottom:a}=this,c=new Lc(i.lineAt(s-r*1e3,ot.ByHeight,o,0,0).from,i.lineAt(a+(1-r)*1e3,ot.ByHeight,o,0,0).to);if(n){let{head:h}=n.range;if(h<c.from||h>c.to){let f=Math.min(this.editorHeight,this.pixelViewport.bottom-this.pixelViewport.top),d=i.lineAt(h,ot.ByPos,o,0,0),m;n.y=="center"?m=(d.top+d.bottom)/2-f/2:n.y=="start"||n.y=="nearest"&&h<c.from?m=d.top:m=d.bottom-f,c=new Lc(i.lineAt(m-1e3/2,ot.ByHeight,o,0,0).from,i.lineAt(m+f+1e3/2,ot.ByHeight,o,0,0).to)}}return c}mapViewport(e,n){let r=n.mapPos(e.from,-1),i=n.mapPos(e.to,1);return new Lc(this.heightMap.lineAt(r,ot.ByPos,this.heightOracle,0,0).from,this.heightMap.lineAt(i,ot.ByPos,this.heightOracle,0,0).to)}viewportIsAppropriate({from:e,to:n},r=0){if(!this.inView)return!0;let{top:i}=this.heightMap.lineAt(e,ot.ByPos,this.heightOracle,0,0),{bottom:o}=this.heightMap.lineAt(n,ot.ByPos,this.heightOracle,0,0),{visibleTop:s,visibleBottom:a}=this;return(e==0||i<=s-Math.max(10,Math.min(-r,250)))&&(n==this.state.doc.length||o>=a+Math.max(10,Math.min(r,250)))&&i>s-2*1e3&&o<a+2*1e3}mapLineGaps(e,n){if(!e.length||n.empty)return e;let r=[];for(let i of e)n.touchesRange(i.from,i.to)||r.push(new jd(n.mapPos(i.from),n.mapPos(i.to),i.size,i.displaySize));return r}ensureLineGaps(e,n){let r=this.heightOracle.lineWrapping,i=r?1e4:2e3,o=i>>1,s=i<<1;if(this.defaultTextDirection!=st.LTR&&!r)return[];let a=[],c=(f,d,m,v)=>{if(d-f<o)return;let w=this.state.selection.main,x=[w.from];w.empty||x.push(w.to);for(let S of x)if(S>f&&S<d){c(f,S-10,m,v),c(S+10,d,m,v);return}let C=eW(e,S=>S.from>=m.from&&S.to<=m.to&&Math.abs(S.from-f)<o&&Math.abs(S.to-d)<o&&!x.some(A=>S.from<A&&S.to>A));if(!C){if(d<m.to&&n&&r&&n.visibleRanges.some(T=>T.from<=d&&T.to>=d)){let T=n.moveToLineBoundary(Q.cursor(d),!1,!0).head;T>f&&(d=T)}let S=this.gapSize(m,f,d,v),A=r||S<2e6?S:2e6;C=new jd(f,d,S,A)}a.push(C)},h=f=>{if(f.length<s||f.type!=en.Text)return;let d=JP(f.from,f.to,this.stateDeco);if(d.total<s)return;let m=this.scrollTarget?this.scrollTarget.range.head:null,v,w;if(r){let x=i/this.heightOracle.lineLength*this.heightOracle.lineHeight,C,S;if(m!=null){let A=Nc(d,m),T=((this.visibleBottom-this.visibleTop)/2+x)/f.height;C=A-T,S=A+T}else C=(this.visibleTop-f.top-x)/f.height,S=(this.visibleBottom-f.top+x)/f.height;v=Bc(d,C),w=Bc(d,S)}else{let x=d.total*this.heightOracle.charWidth,C=i*this.heightOracle.charWidth,S=0;if(x>2e6)for(let L of e)L.from>=f.from&&L.from<f.to&&L.size!=L.displaySize&&L.from*this.heightOracle.charWidth+S<this.pixelViewport.left&&(S=L.size-L.displaySize);let A=this.pixelViewport.left+S,T=this.pixelViewport.right+S,O,D;if(m!=null){let L=Nc(d,m),I=((T-A)/2+C)/x;O=L-I,D=L+I}else O=(A-C)/x,D=(T+C)/x;v=Bc(d,O),w=Bc(d,D)}v>f.from&&c(f.from,v,f,d),w<f.to&&c(w,f.to,f,d)};for(let f of this.viewportLines)Array.isArray(f.type)?f.type.forEach(h):h(f);return a}gapSize(e,n,r,i){let o=Nc(i,r)-Nc(i,n);return this.heightOracle.lineWrapping?e.height*o:i.total*this.heightOracle.charWidth*o}updateLineGaps(e){jd.same(e,this.lineGaps)||(this.lineGaps=e,this.lineGapDeco=xe.set(e.map(n=>n.draw(this,this.heightOracle.lineWrapping))))}computeVisibleRanges(e){let n=this.stateDeco;this.lineGaps.length&&(n=n.concat(this.lineGapDeco));let r=[];Ke.spans(n,this.viewport.from,this.viewport.to,{span(o,s){r.push({from:o,to:s})},point(){}},20);let i=0;if(r.length!=this.visibleRanges.length)i=12;else for(let o=0;o<r.length&&!(i&8);o++){let s=this.visibleRanges[o],a=r[o];(s.from!=a.from||s.to!=a.to)&&(i|=4,e&&e.mapPos(s.from,-1)==a.from&&e.mapPos(s.to,1)==a.to||(i|=8))}return this.visibleRanges=r,i}lineBlockAt(e){return e>=this.viewport.from&&e<=this.viewport.to&&this.viewportLines.find(n=>n.from<=e&&n.to>=e)||va(this.heightMap.lineAt(e,ot.ByPos,this.heightOracle,0,0),this.scaler)}lineBlockAtHeight(e){return e>=this.viewportLines[0].top&&e<=this.viewportLines[this.viewportLines.length-1].bottom&&this.viewportLines.find(n=>n.top<=e&&n.bottom>=e)||va(this.heightMap.lineAt(this.scaler.fromDOM(e),ot.ByHeight,this.heightOracle,0,0),this.scaler)}scrollAnchorAt(e){let n=this.lineBlockAtHeight(e+8);return n.from>=this.viewport.from||this.viewportLines[0].top-e>200?n:this.viewportLines[0]}elementAtHeight(e){return va(this.heightMap.blockAt(this.scaler.fromDOM(e),this.heightOracle,0,0),this.scaler)}get docHeight(){return this.scaler.toDOM(this.heightMap.height)}get contentHeight(){return this.docHeight+this.paddingTop+this.paddingBottom}}let Lc=class{constructor(e,n){this.from=e,this.to=n}};function JP(t,e,n){let r=[],i=t,o=0;return Ke.spans(n,t,e,{span(){},point(s,a){s>i&&(r.push({from:i,to:s}),o+=s-i),i=a}},20),i<e&&(r.push({from:i,to:e}),o+=e-i),{total:o,ranges:r}}function Bc({total:t,ranges:e},n){if(n<=0)return e[0].from;if(n>=1)return e[e.length-1].to;let r=Math.floor(t*n);for(let i=0;;i++){let{from:o,to:s}=e[i],a=s-o;if(r<=a)return o+r;r-=a}}function Nc(t,e){let n=0;for(let{from:r,to:i}of t.ranges){if(e<=i){n+=e-r;break}n+=i-r}return n/t.total}function eW(t,e){for(let n of t)if(e(n))return n}const Q5={toDOM(t){return t},fromDOM(t){return t},scale:1,eq(t){return t==this}};class dm{constructor(e,n,r){let i=0,o=0,s=0;this.viewports=r.map(({from:a,to:c})=>{let h=n.lineAt(a,ot.ByPos,e,0,0).top,f=n.lineAt(c,ot.ByPos,e,0,0).bottom;return i+=f-h,{from:a,to:c,top:h,bottom:f,domTop:0,domBottom:0}}),this.scale=(7e6-i)/(n.height-i);for(let a of this.viewports)a.domTop=s+(a.top-o)*this.scale,s=a.domBottom=a.domTop+(a.bottom-a.top),o=a.bottom}toDOM(e){for(let n=0,r=0,i=0;;n++){let o=n<this.viewports.length?this.viewports[n]:null;if(!o||e<o.top)return i+(e-r)*this.scale;if(e<=o.bottom)return o.domTop+(e-o.top);r=o.bottom,i=o.domBottom}}fromDOM(e){for(let n=0,r=0,i=0;;n++){let o=n<this.viewports.length?this.viewports[n]:null;if(!o||e<o.domTop)return r+(e-i)/this.scale;if(e<=o.domBottom)return o.top+(e-o.domTop);r=o.bottom,i=o.domBottom}}eq(e){return e instanceof dm?this.scale==e.scale&&this.viewports.length==e.viewports.length&&this.viewports.every((n,r)=>n.from==e.viewports[r].from&&n.to==e.viewports[r].to):!1}}function va(t,e){if(e.scale==1)return t;let n=e.toDOM(t.top),r=e.toDOM(t.bottom);return new pr(t.from,t.length,n,r-n,Array.isArray(t._content)?t._content.map(i=>va(i,e)):t._content)}const jc=fe.define({combine:t=>t.join(" ")}),f1=fe.define({combine:t=>t.indexOf(!0)>-1}),d1=Oi.newName(),k6=Oi.newName(),T6=Oi.newName(),M6={"&light":"."+k6,"&dark":"."+T6};function g1(t,e,n){return new Oi(e,{finish(r){return/&/.test(r)?r.replace(/&\w*/,i=>{if(i=="&")return t;if(!n||!n[i])throw new RangeError(`Unsupported selector: ${i}`);return n[i]}):t+" "+r}})}const tW=g1("."+d1,{"&":{position:"relative !important",boxSizing:"border-box","&.cm-focused":{outline:"1px dotted #212121"},display:"flex !important",flexDirection:"column"},".cm-scroller":{display:"flex !important",alignItems:"flex-start !important",fontFamily:"monospace",lineHeight:1.4,height:"100%",overflowX:"auto",position:"relative",zIndex:0,overflowAnchor:"none"},".cm-content":{margin:0,flexGrow:2,flexShrink:0,display:"block",whiteSpace:"pre",wordWrap:"normal",boxSizing:"border-box",minHeight:"100%",padding:"4px 0",outline:"none","&[contenteditable=true]":{WebkitUserModify:"read-write-plaintext-only"}},".cm-lineWrapping":{whiteSpace_fallback:"pre-wrap",whiteSpace:"break-spaces",wordBreak:"break-word",overflowWrap:"anywhere",flexShrink:1},"&light .cm-content":{caretColor:"black"},"&dark .cm-content":{caretColor:"white"},".cm-line":{display:"block",padding:"0 2px 0 6px"},".cm-layer":{position:"absolute",left:0,top:0,contain:"size style","& > *":{position:"absolute"}},"&light .cm-selectionBackground":{background:"#d9d9d9"},"&dark .cm-selectionBackground":{background:"#222"},"&light.cm-focused > .cm-scroller > .cm-selectionLayer .cm-selectionBackground":{background:"#d7d4f0"},"&dark.cm-focused > .cm-scroller > .cm-selectionLayer .cm-selectionBackground":{background:"#233"},".cm-cursorLayer":{pointerEvents:"none"},"&.cm-focused > .cm-scroller > .cm-cursorLayer":{animation:"steps(1) cm-blink 1.2s infinite"},"@keyframes cm-blink":{"0%":{},"50%":{opacity:0},"100%":{}},"@keyframes cm-blink2":{"0%":{},"50%":{opacity:0},"100%":{}},".cm-cursor, .cm-dropCursor":{borderLeft:"1.2px solid black",marginLeft:"-0.6px",pointerEvents:"none"},".cm-cursor":{display:"none"},"&dark .cm-cursor":{borderLeftColor:"#ddd"},".cm-dropCursor":{position:"absolute"},"&.cm-focused > .cm-scroller > .cm-cursorLayer .cm-cursor":{display:"block"},".cm-iso":{unicodeBidi:"isolate"},".cm-announced":{position:"fixed",top:"-10000px"},"@media print":{".cm-announced":{display:"none"}},"&light .cm-activeLine":{backgroundColor:"#cceeff44"},"&dark .cm-activeLine":{backgroundColor:"#99eeff33"},"&light .cm-specialChar":{color:"red"},"&dark .cm-specialChar":{color:"#f78"},".cm-gutters":{flexShrink:0,display:"flex",height:"100%",boxSizing:"border-box",insetInlineStart:0,zIndex:200},"&light .cm-gutters":{backgroundColor:"#f5f5f5",color:"#6c6c6c",borderRight:"1px solid #ddd"},"&dark .cm-gutters":{backgroundColor:"#333338",color:"#ccc"},".cm-gutter":{display:"flex !important",flexDirection:"column",flexShrink:0,boxSizing:"border-box",minHeight:"100%",overflow:"hidden"},".cm-gutterElement":{boxSizing:"border-box"},".cm-lineNumbers .cm-gutterElement":{padding:"0 3px 0 5px",minWidth:"20px",textAlign:"right",whiteSpace:"nowrap"},"&light .cm-activeLineGutter":{backgroundColor:"#e2f2ff"},"&dark .cm-activeLineGutter":{backgroundColor:"#222227"},".cm-panels":{boxSizing:"border-box",position:"sticky",left:0,right:0,zIndex:300},"&light .cm-panels":{backgroundColor:"#f5f5f5",color:"black"},"&light .cm-panels-top":{borderBottom:"1px solid #ddd"},"&light .cm-panels-bottom":{borderTop:"1px solid #ddd"},"&dark .cm-panels":{backgroundColor:"#333338",color:"white"},".cm-tab":{display:"inline-block",overflow:"hidden",verticalAlign:"bottom"},".cm-widgetBuffer":{verticalAlign:"text-top",height:"1em",width:0,display:"inline"},".cm-placeholder":{color:"#888",display:"inline-block",verticalAlign:"top"},".cm-highlightSpace":{backgroundImage:"radial-gradient(circle at 50% 55%, #aaa 20%, transparent 5%)",backgroundPosition:"center"},".cm-highlightTab":{backgroundImage:`url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" width="200" height="20"><path stroke="%23888" stroke-width="1" fill="none" d="M1 10H196L190 5M190 15L196 10M197 4L197 16"/></svg>')`,backgroundSize:"auto 100%",backgroundPosition:"right 90%",backgroundRepeat:"no-repeat"},".cm-trailingSpace":{backgroundColor:"#ff332255"},".cm-button":{verticalAlign:"middle",color:"inherit",fontSize:"70%",padding:".2em 1em",borderRadius:"1px"},"&light .cm-button":{backgroundImage:"linear-gradient(#eff1f5, #d9d9df)",border:"1px solid #888","&:active":{backgroundImage:"linear-gradient(#b4b4b4, #d0d3d6)"}},"&dark .cm-button":{backgroundImage:"linear-gradient(#393939, #111)",border:"1px solid #888","&:active":{backgroundImage:"linear-gradient(#111, #333)"}},".cm-textfield":{verticalAlign:"middle",color:"inherit",fontSize:"70%",border:"1px solid silver",padding:".2em .5em"},"&light .cm-textfield":{backgroundColor:"white"},"&dark .cm-textfield":{border:"1px solid #555",backgroundColor:"inherit"}},M6),nW={childList:!0,characterData:!0,subtree:!0,attributes:!0,characterDataOldValue:!0},Fd=ce.ie&&ce.ie_version<=11;class rW{constructor(e){this.view=e,this.active=!1,this.editContext=null,this.selectionRange=new VH,this.selectionChanged=!1,this.delayedFlush=-1,this.resizeTimeout=-1,this.queue=[],this.delayedAndroidKey=null,this.flushingAndroidKey=-1,this.lastChange=0,this.scrollTargets=[],this.intersection=null,this.resizeScroll=null,this.intersecting=!1,this.gapIntersection=null,this.gaps=[],this.printQuery=null,this.parentCheck=-1,this.dom=e.contentDOM,this.observer=new MutationObserver(n=>{for(let r of n)this.queue.push(r);(ce.ie&&ce.ie_version<=11||ce.ios&&e.composing)&&n.some(r=>r.type=="childList"&&r.removedNodes.length||r.type=="characterData"&&r.oldValue.length>r.target.nodeValue.length)?this.flushSoon():this.flush()}),window.EditContext&&e.constructor.EDIT_CONTEXT!==!1&&!(ce.chrome&&ce.chrome_version<126)&&(this.editContext=new oW(e),e.state.facet(Kr)&&(e.contentDOM.editContext=this.editContext.editContext)),Fd&&(this.onCharData=n=>{this.queue.push({target:n.target,type:"characterData",oldValue:n.prevValue}),this.flushSoon()}),this.onSelectionChange=this.onSelectionChange.bind(this),this.onResize=this.onResize.bind(this),this.onPrint=this.onPrint.bind(this),this.onScroll=this.onScroll.bind(this),window.matchMedia&&(this.printQuery=window.matchMedia("print")),typeof ResizeObserver=="function"&&(this.resizeScroll=new ResizeObserver(()=>{var n;((n=this.view.docView)===null||n===void 0?void 0:n.lastUpdate)<Date.now()-75&&this.onResize()}),this.resizeScroll.observe(e.scrollDOM)),this.addWindowListeners(this.win=e.win),this.start(),typeof IntersectionObserver=="function"&&(this.intersection=new IntersectionObserver(n=>{this.parentCheck<0&&(this.parentCheck=setTimeout(this.listenForScroll.bind(this),1e3)),n.length>0&&n[n.length-1].intersectionRatio>0!=this.intersecting&&(this.intersecting=!this.intersecting,this.intersecting!=this.view.inView&&this.onScrollChanged(document.createEvent("Event")))},{threshold:[0,.001]}),this.intersection.observe(this.dom),this.gapIntersection=new IntersectionObserver(n=>{n.length>0&&n[n.length-1].intersectionRatio>0&&this.onScrollChanged(document.createEvent("Event"))},{})),this.listenForScroll(),this.readSelectionRange()}onScrollChanged(e){this.view.inputState.runHandlers("scroll",e),this.intersecting&&this.view.measure()}onScroll(e){this.intersecting&&this.flush(!1),this.editContext&&this.view.requestMeasure(this.editContext.measureReq),this.onScrollChanged(e)}onResize(){this.resizeTimeout<0&&(this.resizeTimeout=setTimeout(()=>{this.resizeTimeout=-1,this.view.requestMeasure()},50))}onPrint(e){(e.type=="change"||!e.type)&&!e.matches||(this.view.viewState.printing=!0,this.view.measure(),setTimeout(()=>{this.view.viewState.printing=!1,this.view.requestMeasure()},500))}updateGaps(e){if(this.gapIntersection&&(e.length!=this.gaps.length||this.gaps.some((n,r)=>n!=e[r]))){this.gapIntersection.disconnect();for(let n of e)this.gapIntersection.observe(n);this.gaps=e}}onSelectionChange(e){let n=this.selectionChanged;if(!this.readSelectionRange()||this.delayedAndroidKey)return;let{view:r}=this,i=this.selectionRange;if(r.state.facet(Kr)?r.root.activeElement!=this.dom:!tu(this.dom,i))return;let o=i.anchorNode&&r.docView.nearest(i.anchorNode);if(o&&o.ignoreEvent(e)){n||(this.selectionChanged=!1);return}(ce.ie&&ce.ie_version<=11||ce.android&&ce.chrome)&&!r.state.selection.main.empty&&i.focusNode&&Ca(i.focusNode,i.focusOffset,i.anchorNode,i.anchorOffset)?this.flushSoon():this.flush(!1)}readSelectionRange(){let{view:e}=this,n=Na(e.root);if(!n)return!1;let r=ce.safari&&e.root.nodeType==11&&e.root.activeElement==this.dom&&iW(this.view,n)||n;if(!r||this.selectionRange.eq(r))return!1;let i=tu(this.dom,r);return i&&!this.selectionChanged&&e.inputState.lastFocusTime>Date.now()-200&&e.inputState.lastTouchTime<Date.now()-300&&PH(this.dom,r)?(this.view.inputState.lastFocusTime=0,e.docView.updateSelection(),!1):(this.selectionRange.setRange(r),i&&(this.selectionChanged=!0),!0)}setSelectionRange(e,n){this.selectionRange.set(e.node,e.offset,n.node,n.offset),this.selectionChanged=!1}clearSelectionRange(){this.selectionRange.set(null,0,null,0)}listenForScroll(){this.parentCheck=-1;let e=0,n=null;for(let r=this.dom;r;)if(r.nodeType==1)!n&&e<this.scrollTargets.length&&this.scrollTargets[e]==r?e++:n||(n=this.scrollTargets.slice(0,e)),n&&n.push(r),r=r.assignedSlot||r.parentNode;else if(r.nodeType==11)r=r.host;else break;if(e<this.scrollTargets.length&&!n&&(n=this.scrollTargets.slice(0,e)),n){for(let r of this.scrollTargets)r.removeEventListener("scroll",this.onScroll);for(let r of this.scrollTargets=n)r.addEventListener("scroll",this.onScroll)}}ignore(e){if(!this.active)return e();try{return this.stop(),e()}finally{this.start(),this.clear()}}start(){this.active||(this.observer.observe(this.dom,nW),Fd&&this.dom.addEventListener("DOMCharacterDataModified",this.onCharData),this.active=!0)}stop(){this.active&&(this.active=!1,this.observer.disconnect(),Fd&&this.dom.removeEventListener("DOMCharacterDataModified",this.onCharData))}clear(){this.processRecords(),this.queue.length=0,this.selectionChanged=!1}delayAndroidKey(e,n){var r;if(!this.delayedAndroidKey){let i=()=>{let o=this.delayedAndroidKey;o&&(this.clearDelayedAndroidKey(),this.view.inputState.lastKeyCode=o.keyCode,this.view.inputState.lastKeyTime=Date.now(),!this.flush()&&o.force&&cs(this.dom,o.key,o.keyCode))};this.flushingAndroidKey=this.view.win.requestAnimationFrame(i)}(!this.delayedAndroidKey||e=="Enter")&&(this.delayedAndroidKey={key:e,keyCode:n,force:this.lastChange<Date.now()-50||!!(!((r=this.delayedAndroidKey)===null||r===void 0)&&r.force)})}clearDelayedAndroidKey(){this.win.cancelAnimationFrame(this.flushingAndroidKey),this.delayedAndroidKey=null,this.flushingAndroidKey=-1}flushSoon(){this.delayedFlush<0&&(this.delayedFlush=this.view.win.requestAnimationFrame(()=>{this.delayedFlush=-1,this.flush()}))}forceFlush(){this.delayedFlush>=0&&(this.view.win.cancelAnimationFrame(this.delayedFlush),this.delayedFlush=-1),this.flush()}pendingRecords(){for(let e of this.observer.takeRecords())this.queue.push(e);return this.queue}processRecords(){let e=this.pendingRecords();e.length&&(this.queue=[]);let n=-1,r=-1,i=!1;for(let o of e){let s=this.readMutation(o);s&&(s.typeOver&&(i=!0),n==-1?{from:n,to:r}=s:(n=Math.min(s.from,n),r=Math.max(s.to,r)))}return{from:n,to:r,typeOver:i}}readChange(){let{from:e,to:n,typeOver:r}=this.processRecords(),i=this.selectionChanged&&tu(this.dom,this.selectionRange);if(e<0&&!i)return null;e>-1&&(this.lastChange=Date.now()),this.view.inputState.lastFocusTime=0,this.selectionChanged=!1;let o=new yP(this.view,e,n,r);return this.view.docView.domChanged={newSel:o.newSel?o.newSel.main:null},o}flush(e=!0){if(this.delayedFlush>=0||this.delayedAndroidKey)return!1;e&&this.readSelectionRange();let n=this.readChange();if(!n)return this.view.requestMeasure(),!1;let r=this.view.state,i=v6(this.view,n);return this.view.state==r&&(n.domChanged||n.newSel&&!n.newSel.main.eq(this.view.state.selection.main))&&this.view.update([]),i}readMutation(e){let n=this.view.docView.nearest(e.target);if(!n||n.ignoreMutation(e))return null;if(n.markDirty(e.type=="attributes"),e.type=="attributes"&&(n.flags|=4),e.type=="childList"){let r=J5(n,e.previousSibling||e.target.previousSibling,-1),i=J5(n,e.nextSibling||e.target.nextSibling,1);return{from:r?n.posAfter(r):n.posAtStart,to:i?n.posBefore(i):n.posAtEnd,typeOver:!1}}else return e.type=="characterData"?{from:n.posAtStart,to:n.posAtEnd,typeOver:e.target.nodeValue==e.oldValue}:null}setWindow(e){e!=this.win&&(this.removeWindowListeners(this.win),this.win=e,this.addWindowListeners(this.win))}addWindowListeners(e){e.addEventListener("resize",this.onResize),this.printQuery?this.printQuery.addEventListener?this.printQuery.addEventListener("change",this.onPrint):this.printQuery.addListener(this.onPrint):e.addEventListener("beforeprint",this.onPrint),e.addEventListener("scroll",this.onScroll),e.document.addEventListener("selectionchange",this.onSelectionChange)}removeWindowListeners(e){e.removeEventListener("scroll",this.onScroll),e.removeEventListener("resize",this.onResize),this.printQuery?this.printQuery.removeEventListener?this.printQuery.removeEventListener("change",this.onPrint):this.printQuery.removeListener(this.onPrint):e.removeEventListener("beforeprint",this.onPrint),e.document.removeEventListener("selectionchange",this.onSelectionChange)}update(e){this.editContext&&(this.editContext.update(e),e.startState.facet(Kr)!=e.state.facet(Kr)&&(e.view.contentDOM.editContext=e.state.facet(Kr)?this.editContext.editContext:null))}destroy(){var e,n,r;this.stop(),(e=this.intersection)===null||e===void 0||e.disconnect(),(n=this.gapIntersection)===null||n===void 0||n.disconnect(),(r=this.resizeScroll)===null||r===void 0||r.disconnect();for(let i of this.scrollTargets)i.removeEventListener("scroll",this.onScroll);this.removeWindowListeners(this.win),clearTimeout(this.parentCheck),clearTimeout(this.resizeTimeout),this.win.cancelAnimationFrame(this.delayedFlush),this.win.cancelAnimationFrame(this.flushingAndroidKey),this.editContext&&(this.view.contentDOM.editContext=null,this.editContext.destroy())}}function J5(t,e,n){for(;e;){let r=nt.get(e);if(r&&r.parent==t)return r;let i=e.parentNode;e=i!=t.dom?i:n>0?e.nextSibling:e.previousSibling}return null}function eb(t,e){let n=e.startContainer,r=e.startOffset,i=e.endContainer,o=e.endOffset,s=t.docView.domAtPos(t.state.selection.main.anchor);return Ca(s.node,s.offset,i,o)&&([n,r,i,o]=[i,o,n,r]),{anchorNode:n,anchorOffset:r,focusNode:i,focusOffset:o}}function iW(t,e){if(e.getComposedRanges){let i=e.getComposedRanges(t.root)[0];if(i)return eb(t,i)}let n=null;function r(i){i.preventDefault(),i.stopImmediatePropagation(),n=i.getTargetRanges()[0]}return t.contentDOM.addEventListener("beforeinput",r,!0),t.dom.ownerDocument.execCommand("indent"),t.contentDOM.removeEventListener("beforeinput",r,!0),n?eb(t,n):null}class oW{constructor(e){this.from=0,this.to=0,this.pendingContextChange=null,this.handlers=Object.create(null),this.composing=null,this.resetRange(e.state);let n=this.editContext=new window.EditContext({text:e.state.doc.sliceString(this.from,this.to),selectionStart:this.toContextPos(Math.max(this.from,Math.min(this.to,e.state.selection.main.anchor))),selectionEnd:this.toContextPos(e.state.selection.main.head)});this.handlers.textupdate=r=>{let i=e.state.selection.main,{anchor:o,head:s}=i,a=this.toEditorPos(r.updateRangeStart),c=this.toEditorPos(r.updateRangeEnd);e.inputState.composing>=0&&!this.composing&&(this.composing={contextBase:r.updateRangeStart,editorBase:a,drifted:!1});let h={from:a,to:c,insert:Ge.of(r.text.split(`
56
- `))};if(h.from==this.from&&o<this.from?h.from=o:h.to==this.to&&o>this.to&&(h.to=o),h.from==h.to&&!h.insert.length){let f=Q.single(this.toEditorPos(r.selectionStart),this.toEditorPos(r.selectionEnd));f.main.eq(i)||e.dispatch({selection:f,userEvent:"select"});return}if((ce.mac||ce.android)&&h.from==s-1&&/^\. ?$/.test(r.text)&&e.contentDOM.getAttribute("autocorrect")=="off"&&(h={from:a,to:c,insert:Ge.of([r.text.replace("."," ")])}),this.pendingContextChange=h,!e.state.readOnly){let f=this.to-this.from+(h.to-h.from+h.insert.length);hm(e,h,Q.single(this.toEditorPos(r.selectionStart,f),this.toEditorPos(r.selectionEnd,f)))}this.pendingContextChange&&(this.revertPending(e.state),this.setSelection(e.state))},this.handlers.characterboundsupdate=r=>{let i=[],o=null;for(let s=this.toEditorPos(r.rangeStart),a=this.toEditorPos(r.rangeEnd);s<a;s++){let c=e.coordsForChar(s);o=c&&new DOMRect(c.left,c.top,c.right-c.left,c.bottom-c.top)||o||new DOMRect,i.push(o)}n.updateCharacterBounds(r.rangeStart,i)},this.handlers.textformatupdate=r=>{let i=[];for(let o of r.getTextFormats()){let s=o.underlineStyle,a=o.underlineThickness;if(s!="None"&&a!="None"){let c=this.toEditorPos(o.rangeStart),h=this.toEditorPos(o.rangeEnd);if(c<h){let f=`text-decoration: underline ${s=="Dashed"?"dashed ":s=="Squiggle"?"wavy ":""}${a=="Thin"?1:2}px`;i.push(xe.mark({attributes:{style:f}}).range(c,h))}}}e.dispatch({effects:u6.of(xe.set(i))})},this.handlers.compositionstart=()=>{e.inputState.composing<0&&(e.inputState.composing=0,e.inputState.compositionFirstChange=!0)},this.handlers.compositionend=()=>{if(e.inputState.composing=-1,e.inputState.compositionFirstChange=null,this.composing){let{drifted:r}=this.composing;this.composing=null,r&&this.reset(e.state)}};for(let r in this.handlers)n.addEventListener(r,this.handlers[r]);this.measureReq={read:r=>{this.editContext.updateControlBounds(r.contentDOM.getBoundingClientRect());let i=Na(r.root);i&&i.rangeCount&&this.editContext.updateSelectionBounds(i.getRangeAt(0).getBoundingClientRect())}}}applyEdits(e){let n=0,r=!1,i=this.pendingContextChange;return e.changes.iterChanges((o,s,a,c,h)=>{if(r)return;let f=h.length-(s-o);if(i&&s>=i.to)if(i.from==o&&i.to==s&&i.insert.eq(h)){i=this.pendingContextChange=null,n+=f,this.to+=f;return}else i=null,this.revertPending(e.state);if(o+=n,s+=n,s<=this.from)this.from+=f,this.to+=f;else if(o<this.to){if(o<this.from||s>this.to||this.to-this.from+h.length>3e4){r=!0;return}this.editContext.updateText(this.toContextPos(o),this.toContextPos(s),h.toString()),this.to+=f}n+=f}),i&&!r&&this.revertPending(e.state),!r}update(e){let n=this.pendingContextChange,r=e.startState.selection.main;this.composing&&(this.composing.drifted||!e.changes.touchesRange(r.from,r.to)&&e.transactions.some(i=>!i.isUserEvent("input.type")&&i.changes.touchesRange(this.from,this.to)))?(this.composing.drifted=!0,this.composing.editorBase=e.changes.mapPos(this.composing.editorBase)):!this.applyEdits(e)||!this.rangeIsValid(e.state)?(this.pendingContextChange=null,this.reset(e.state)):(e.docChanged||e.selectionSet||n)&&this.setSelection(e.state),(e.geometryChanged||e.docChanged||e.selectionSet)&&e.view.requestMeasure(this.measureReq)}resetRange(e){let{head:n}=e.selection.main;this.from=Math.max(0,n-1e4),this.to=Math.min(e.doc.length,n+1e4)}reset(e){this.resetRange(e),this.editContext.updateText(0,this.editContext.text.length,e.doc.sliceString(this.from,this.to)),this.setSelection(e)}revertPending(e){let n=this.pendingContextChange;this.pendingContextChange=null,this.editContext.updateText(this.toContextPos(n.from),this.toContextPos(n.from+n.insert.length),e.doc.sliceString(n.from,n.to))}setSelection(e){let{main:n}=e.selection,r=this.toContextPos(Math.max(this.from,Math.min(this.to,n.anchor))),i=this.toContextPos(n.head);(this.editContext.selectionStart!=r||this.editContext.selectionEnd!=i)&&this.editContext.updateSelection(r,i)}rangeIsValid(e){let{head:n}=e.selection.main;return!(this.from>0&&n-this.from<500||this.to<e.doc.length&&this.to-n<500||this.to-this.from>1e4*3)}toEditorPos(e,n=this.to-this.from){e=Math.min(e,n);let r=this.composing;return r&&r.drifted?r.editorBase+(e-r.contextBase):e+this.from}toContextPos(e){let n=this.composing;return n&&n.drifted?n.contextBase+(e-n.editorBase):e-this.from}destroy(){for(let e in this.handlers)this.editContext.removeEventListener(e,this.handlers[e])}}class le{get state(){return this.viewState.state}get viewport(){return this.viewState.viewport}get visibleRanges(){return this.viewState.visibleRanges}get inView(){return this.viewState.inView}get composing(){return this.inputState.composing>0}get compositionStarted(){return this.inputState.composing>=0}get root(){return this._root}get win(){return this.dom.ownerDocument.defaultView||window}constructor(e={}){var n;this.plugins=[],this.pluginMap=new Map,this.editorAttrs={},this.contentAttrs={},this.bidiCache=[],this.destroyed=!1,this.updateState=2,this.measureScheduled=-1,this.measureRequests=[],this.contentDOM=document.createElement("div"),this.scrollDOM=document.createElement("div"),this.scrollDOM.tabIndex=-1,this.scrollDOM.className="cm-scroller",this.scrollDOM.appendChild(this.contentDOM),this.announceDOM=document.createElement("div"),this.announceDOM.className="cm-announced",this.announceDOM.setAttribute("aria-live","polite"),this.dom=document.createElement("div"),this.dom.appendChild(this.announceDOM),this.dom.appendChild(this.scrollDOM),e.parent&&e.parent.appendChild(this.dom);let{dispatch:r}=e;this.dispatchTransactions=e.dispatchTransactions||r&&(i=>i.forEach(o=>r(o,this)))||(i=>this.update(i)),this.dispatch=this.dispatch.bind(this),this._root=e.root||HH(e.parent)||document,this.viewState=new Z5(e.state||qe.create(e)),e.scrollTo&&e.scrollTo.is(Dc)&&(this.viewState.scrollTarget=e.scrollTo.value.clip(this.viewState.state)),this.plugins=this.state.facet(ga).map(i=>new Ld(i));for(let i of this.plugins)i.update(this);this.observer=new rW(this),this.inputState=new RP(this),this.inputState.ensureHandlers(this.plugins),this.docView=new D5(this),this.mountStyles(),this.updateAttrs(),this.updateState=0,this.requestMeasure(),!((n=document.fonts)===null||n===void 0)&&n.ready&&document.fonts.ready.then(()=>this.requestMeasure())}dispatch(...e){let n=e.length==1&&e[0]instanceof Tt?e:e.length==1&&Array.isArray(e[0])?e[0]:[this.state.update(...e)];this.dispatchTransactions(n,this)}update(e){if(this.updateState!=0)throw new Error("Calls to EditorView.update are not allowed while an update is in progress");let n=!1,r=!1,i,o=this.state;for(let m of e){if(m.startState!=o)throw new RangeError("Trying to update state with a transaction that doesn't start from the previous state.");o=m.state}if(this.destroyed){this.viewState.state=o;return}let s=this.hasFocus,a=0,c=null;e.some(m=>m.annotation($6))?(this.inputState.notifiedFocused=s,a=1):s!=this.inputState.notifiedFocused&&(this.inputState.notifiedFocused=s,c=S6(o,s),c||(a=1));let h=this.observer.delayedAndroidKey,f=null;if(h?(this.observer.clearDelayedAndroidKey(),f=this.observer.readChange(),(f&&!this.state.doc.eq(o.doc)||!this.state.selection.eq(o.selection))&&(f=null)):this.observer.clear(),o.facet(qe.phrases)!=this.state.facet(qe.phrases))return this.setState(o);i=Eu.create(this,o,e),i.flags|=a;let d=this.viewState.scrollTarget;try{this.updateState=2;for(let m of e){if(d&&(d=d.map(m.changes)),m.scrollIntoView){let{main:v}=m.state.selection;d=new us(v.empty?v:Q.cursor(v.head,v.head>v.anchor?-1:1))}for(let v of m.effects)v.is(Dc)&&(d=v.value.clip(this.state))}this.viewState.update(i,d),this.bidiCache=Du.update(this.bidiCache,i.changes),i.empty||(this.updatePlugins(i),this.inputState.update(i)),n=this.docView.update(i),this.state.facet(ma)!=this.styleModules&&this.mountStyles(),r=this.updateAttrs(),this.showAnnouncements(e),this.docView.updateSelection(n,e.some(m=>m.isUserEvent("select.pointer")))}finally{this.updateState=0}if(i.startState.facet(jc)!=i.state.facet(jc)&&(this.viewState.mustMeasureContent=!0),(n||r||d||this.viewState.mustEnforceCursorAssoc||this.viewState.mustMeasureContent)&&this.requestMeasure(),n&&this.docViewUpdate(),!i.empty)for(let m of this.state.facet(l1))try{m(i)}catch(v){hn(this.state,v,"update listener")}(c||f)&&Promise.resolve().then(()=>{c&&this.state==c.startState&&this.dispatch(c),f&&!v6(this,f)&&h.force&&cs(this.contentDOM,h.key,h.keyCode)})}setState(e){if(this.updateState!=0)throw new Error("Calls to EditorView.setState are not allowed while an update is in progress");if(this.destroyed){this.viewState.state=e;return}this.updateState=2;let n=this.hasFocus;try{for(let r of this.plugins)r.destroy(this);this.viewState=new Z5(e),this.plugins=e.facet(ga).map(r=>new Ld(r)),this.pluginMap.clear();for(let r of this.plugins)r.update(this);this.docView.destroy(),this.docView=new D5(this),this.inputState.ensureHandlers(this.plugins),this.mountStyles(),this.updateAttrs(),this.bidiCache=[]}finally{this.updateState=0}n&&this.focus(),this.requestMeasure()}updatePlugins(e){let n=e.startState.facet(ga),r=e.state.facet(ga);if(n!=r){let i=[];for(let o of r){let s=n.indexOf(o);if(s<0)i.push(new Ld(o));else{let a=this.plugins[s];a.mustUpdate=e,i.push(a)}}for(let o of this.plugins)o.mustUpdate!=e&&o.destroy(this);this.plugins=i,this.pluginMap.clear()}else for(let i of this.plugins)i.mustUpdate=e;for(let i=0;i<this.plugins.length;i++)this.plugins[i].update(this);n!=r&&this.inputState.ensureHandlers(this.plugins)}docViewUpdate(){for(let e of this.plugins){let n=e.value;if(n&&n.docViewUpdate)try{n.docViewUpdate(this)}catch(r){hn(this.state,r,"doc view update listener")}}}measure(e=!0){if(this.destroyed)return;if(this.measureScheduled>-1&&this.win.cancelAnimationFrame(this.measureScheduled),this.observer.delayedAndroidKey){this.measureScheduled=-1,this.requestMeasure();return}this.measureScheduled=0,e&&this.observer.forceFlush();let n=null,r=this.scrollDOM,i=r.scrollTop*this.scaleY,{scrollAnchorPos:o,scrollAnchorHeight:s}=this.viewState;Math.abs(i-this.viewState.scrollTop)>1&&(s=-1),this.viewState.scrollAnchorHeight=-1;try{for(let a=0;;a++){if(s<0)if(jy(r))o=-1,s=this.viewState.heightMap.height;else{let v=this.viewState.scrollAnchorAt(i);o=v.from,s=v.top}this.updateState=1;let c=this.viewState.measure(this);if(!c&&!this.measureRequests.length&&this.viewState.scrollTarget==null)break;if(a>5){console.warn(this.measureRequests.length?"Measure loop restarted more than 5 times":"Viewport failed to stabilize");break}let h=[];c&4||([this.measureRequests,h]=[h,this.measureRequests]);let f=h.map(v=>{try{return v.read(this)}catch(w){return hn(this.state,w),tb}}),d=Eu.create(this,this.state,[]),m=!1;d.flags|=c,n?n.flags|=c:n=d,this.updateState=2,d.empty||(this.updatePlugins(d),this.inputState.update(d),this.updateAttrs(),m=this.docView.update(d),m&&this.docViewUpdate());for(let v=0;v<h.length;v++)if(f[v]!=tb)try{let w=h[v];w.write&&w.write(f[v],this)}catch(w){hn(this.state,w)}if(m&&this.docView.updateSelection(!0),!d.viewportChanged&&this.measureRequests.length==0){if(this.viewState.editorHeight)if(this.viewState.scrollTarget){this.docView.scrollIntoView(this.viewState.scrollTarget),this.viewState.scrollTarget=null,s=-1;continue}else{let w=(o<0?this.viewState.heightMap.height:this.viewState.lineBlockAt(o).top)-s;if(w>1||w<-1){i=i+w,r.scrollTop=i/this.scaleY,s=-1;continue}}break}}}finally{this.updateState=0,this.measureScheduled=-1}if(n&&!n.empty)for(let a of this.state.facet(l1))a(n)}get themeClasses(){return d1+" "+(this.state.facet(f1)?T6:k6)+" "+this.state.facet(jc)}updateAttrs(){let e=nb(this,h6,{class:"cm-editor"+(this.hasFocus?" cm-focused ":" ")+this.themeClasses}),n={spellcheck:"false",autocorrect:"off",autocapitalize:"off",writingsuggestions:"false",translate:"no",contenteditable:this.state.facet(Kr)?"true":"false",class:"cm-content",style:`${ce.tabSize}: ${this.state.tabSize}`,role:"textbox","aria-multiline":"true"};this.state.readOnly&&(n["aria-readonly"]="true"),nb(this,lm,n);let r=this.observer.ignore(()=>{let i=r1(this.contentDOM,this.contentAttrs,n),o=r1(this.dom,this.editorAttrs,e);return i||o});return this.editorAttrs=e,this.contentAttrs=n,r}showAnnouncements(e){let n=!0;for(let r of e)for(let i of r.effects)if(i.is(le.announce)){n&&(this.announceDOM.textContent=""),n=!1;let o=this.announceDOM.appendChild(document.createElement("div"));o.textContent=i.value}}mountStyles(){this.styleModules=this.state.facet(ma);let e=this.state.facet(le.cspNonce);Oi.mount(this.root,this.styleModules.concat(tW).reverse(),e?{nonce:e}:void 0)}readMeasured(){if(this.updateState==2)throw new Error("Reading the editor layout isn't allowed during an update");this.updateState==0&&this.measureScheduled>-1&&this.measure(!1)}requestMeasure(e){if(this.measureScheduled<0&&(this.measureScheduled=this.win.requestAnimationFrame(()=>this.measure())),e){if(this.measureRequests.indexOf(e)>-1)return;if(e.key!=null){for(let n=0;n<this.measureRequests.length;n++)if(this.measureRequests[n].key===e.key){this.measureRequests[n]=e;return}}this.measureRequests.push(e)}}plugin(e){let n=this.pluginMap.get(e);return(n===void 0||n&&n.spec!=e)&&this.pluginMap.set(e,n=this.plugins.find(r=>r.spec==e)||null),n&&n.update(this).value}get documentTop(){return this.contentDOM.getBoundingClientRect().top+this.viewState.paddingTop}get documentPadding(){return{top:this.viewState.paddingTop,bottom:this.viewState.paddingBottom}}get scaleX(){return this.viewState.scaleX}get scaleY(){return this.viewState.scaleY}elementAtHeight(e){return this.readMeasured(),this.viewState.elementAtHeight(e)}lineBlockAtHeight(e){return this.readMeasured(),this.viewState.lineBlockAtHeight(e)}get viewportLineBlocks(){return this.viewState.viewportLines}lineBlockAt(e){return this.viewState.lineBlockAt(e)}get contentHeight(){return this.viewState.contentHeight}moveByChar(e,n,r){return Nd(this,e,N5(this,e,n,r))}moveByGroup(e,n){return Nd(this,e,N5(this,e,n,r=>vP(this,e.head,r)))}visualLineSide(e,n){let r=this.bidiSpans(e),i=this.textDirectionAt(e.from),o=r[n?r.length-1:0];return Q.cursor(o.side(n,i)+e.from,o.forward(!n,i)?1:-1)}moveToLineBoundary(e,n,r=!0){return pP(this,e,n,r)}moveVertically(e,n,r){return Nd(this,e,bP(this,e,n,r))}domAtPos(e){return this.docView.domAtPos(e)}posAtDOM(e,n=0){return this.docView.posFromDOM(e,n)}posAtCoords(e,n=!0){return this.readMeasured(),p6(this,e,n)}coordsAtPos(e,n=1){this.readMeasured();let r=this.docView.coordsAt(e,n);if(!r||r.left==r.right)return r;let i=this.state.doc.lineAt(e),o=this.bidiSpans(i),s=o[Si.find(o,e-i.from,-1,n)];return cl(r,s.dir==st.LTR==n>0)}coordsForChar(e){return this.readMeasured(),this.docView.coordsForChar(e)}get defaultCharacterWidth(){return this.viewState.heightOracle.charWidth}get defaultLineHeight(){return this.viewState.heightOracle.lineHeight}get textDirection(){return this.viewState.defaultTextDirection}textDirectionAt(e){return!this.state.facet(a6)||e<this.viewport.from||e>this.viewport.to?this.textDirection:(this.readMeasured(),this.docView.textDirectionAt(e))}get lineWrapping(){return this.viewState.heightOracle.lineWrapping}bidiSpans(e){if(e.length>sW)return Jy(e.length);let n=this.textDirectionAt(e.from),r;for(let o of this.bidiCache)if(o.from==e.from&&o.dir==n&&(o.fresh||Qy(o.isolates,r=O5(this,e))))return o.order;r||(r=O5(this,e));let i=eP(e.text,n,r);return this.bidiCache.push(new Du(e.from,e.to,n,r,!0,i)),i}get hasFocus(){var e;return(this.dom.ownerDocument.hasFocus()||ce.safari&&((e=this.inputState)===null||e===void 0?void 0:e.lastContextMenu)>Date.now()-3e4)&&this.root.activeElement==this.contentDOM}focus(){this.observer.ignore(()=>{By(this.contentDOM),this.docView.updateSelection()})}setRoot(e){this._root!=e&&(this._root=e,this.observer.setWindow((e.nodeType==9?e:e.ownerDocument).defaultView||window),this.mountStyles())}destroy(){this.root.activeElement==this.contentDOM&&this.contentDOM.blur();for(let e of this.plugins)e.destroy(this);this.plugins=[],this.inputState.destroy(),this.docView.destroy(),this.dom.remove(),this.observer.destroy(),this.measureScheduled>-1&&this.win.cancelAnimationFrame(this.measureScheduled),this.destroyed=!0}static scrollIntoView(e,n={}){return Dc.of(new us(typeof e=="number"?Q.cursor(e):e,n.y,n.x,n.yMargin,n.xMargin))}scrollSnapshot(){let{scrollTop:e,scrollLeft:n}=this.scrollDOM,r=this.viewState.scrollAnchorAt(e);return Dc.of(new us(Q.cursor(r.from),"start","start",r.top-e,n,!0))}setTabFocusMode(e){e==null?this.inputState.tabFocusMode=this.inputState.tabFocusMode<0?0:-1:typeof e=="boolean"?this.inputState.tabFocusMode=e?0:-1:this.inputState.tabFocusMode!=0&&(this.inputState.tabFocusMode=Date.now()+e)}static domEventHandlers(e){return vt.define(()=>({}),{eventHandlers:e})}static domEventObservers(e){return vt.define(()=>({}),{eventObservers:e})}static theme(e,n){let r=Oi.newName(),i=[jc.of(r),ma.of(g1(`.${r}`,e))];return n&&n.dark&&i.push(f1.of(!0)),i}static baseTheme(e){return Ro.lowest(ma.of(g1("."+d1,e,M6)))}static findFromDOM(e){var n;let r=e.querySelector(".cm-content"),i=r&&nt.get(r)||nt.get(e);return((n=i?.rootView)===null||n===void 0?void 0:n.view)||null}}le.styleModule=ma;le.inputHandler=o6;le.clipboardInputFilter=sm;le.clipboardOutputFilter=am;le.scrollHandler=c6;le.focusChangeEffect=s6;le.perLineTextDirection=a6;le.exceptionSink=i6;le.updateListener=l1;le.editable=Kr;le.mouseSelectionStyle=r6;le.dragMovesSelection=n6;le.clickAddsSelectionRange=t6;le.decorations=ja;le.outerDecorations=f6;le.atomicRanges=cm;le.bidiIsolatedRanges=d6;le.scrollMargins=g6;le.darkTheme=f1;le.cspNonce=fe.define({combine:t=>t.length?t[0]:""});le.contentAttributes=lm;le.editorAttributes=h6;le.lineWrapping=le.contentAttributes.of({class:"cm-lineWrapping"});le.announce=Me.define();const sW=4096,tb={};class Du{constructor(e,n,r,i,o,s){this.from=e,this.to=n,this.dir=r,this.isolates=i,this.fresh=o,this.order=s}static update(e,n){if(n.empty&&!e.some(o=>o.fresh))return e;let r=[],i=e.length?e[e.length-1].dir:st.LTR;for(let o=Math.max(0,e.length-10);o<e.length;o++){let s=e[o];s.dir==i&&!n.touchesRange(s.from,s.to)&&r.push(new Du(n.mapPos(s.from,1),n.mapPos(s.to,-1),s.dir,s.isolates,!1,s.order))}return r}}function nb(t,e,n){for(let r=t.state.facet(e),i=r.length-1;i>=0;i--){let o=r[i],s=typeof o=="function"?o(t):o;s&&n1(s,n)}return n}const aW=ce.mac?"mac":ce.windows?"win":ce.linux?"linux":"key";function lW(t,e){const n=t.split(/-(?!$)/);let r=n[n.length-1];r=="Space"&&(r=" ");let i,o,s,a;for(let c=0;c<n.length-1;++c){const h=n[c];if(/^(cmd|meta|m)$/i.test(h))a=!0;else if(/^a(lt)?$/i.test(h))i=!0;else if(/^(c|ctrl|control)$/i.test(h))o=!0;else if(/^s(hift)?$/i.test(h))s=!0;else if(/^mod$/i.test(h))e=="mac"?a=!0:o=!0;else throw new Error("Unrecognized modifier name: "+h)}return i&&(r="Alt-"+r),o&&(r="Ctrl-"+r),a&&(r="Meta-"+r),s&&(r="Shift-"+r),r}function Fc(t,e,n){return e.altKey&&(t="Alt-"+t),e.ctrlKey&&(t="Ctrl-"+t),e.metaKey&&(t="Meta-"+t),n!==!1&&e.shiftKey&&(t="Shift-"+t),t}const cW=Ro.default(le.domEventHandlers({keydown(t,e){return O6(E6(e.state),t,e,"editor")}})),$h=fe.define({enables:cW}),rb=new WeakMap;function E6(t){let e=t.facet($h),n=rb.get(e);return n||rb.set(e,n=fW(e.reduce((r,i)=>r.concat(i),[]))),n}function uW(t,e,n){return O6(E6(t.state),e,t,n)}let xi=null;const hW=4e3;function fW(t,e=aW){let n=Object.create(null),r=Object.create(null),i=(s,a)=>{let c=r[s];if(c==null)r[s]=a;else if(c!=a)throw new Error("Key binding "+s+" is used both as a regular binding and as a multi-stroke prefix")},o=(s,a,c,h,f)=>{var d,m;let v=n[s]||(n[s]=Object.create(null)),w=a.split(/ (?!$)/).map(S=>lW(S,e));for(let S=1;S<w.length;S++){let A=w.slice(0,S).join(" ");i(A,!0),v[A]||(v[A]={preventDefault:!0,stopPropagation:!1,run:[T=>{let O=xi={view:T,prefix:A,scope:s};return setTimeout(()=>{xi==O&&(xi=null)},hW),!0}]})}let x=w.join(" ");i(x,!1);let C=v[x]||(v[x]={preventDefault:!1,stopPropagation:!1,run:((m=(d=v._any)===null||d===void 0?void 0:d.run)===null||m===void 0?void 0:m.slice())||[]});c&&C.run.push(c),h&&(C.preventDefault=!0),f&&(C.stopPropagation=!0)};for(let s of t){let a=s.scope?s.scope.split(" "):["editor"];if(s.any)for(let h of a){let f=n[h]||(n[h]=Object.create(null));f._any||(f._any={preventDefault:!1,stopPropagation:!1,run:[]});let{any:d}=s;for(let m in f)f[m].run.push(v=>d(v,m1))}let c=s[e]||s.key;if(c)for(let h of a)o(h,c,s.run,s.preventDefault,s.stopPropagation),s.shift&&o(h,"Shift-"+c,s.shift,s.preventDefault,s.stopPropagation)}return n}let m1=null;function O6(t,e,n,r){m1=e;let i=BH(e),o=ln(i,0),s=mr(o)==i.length&&i!=" ",a="",c=!1,h=!1,f=!1;xi&&xi.view==n&&xi.scope==r&&(a=xi.prefix+" ",w6.indexOf(e.keyCode)<0&&(h=!0,xi=null));let d=new Set,m=C=>{if(C){for(let S of C.run)if(!d.has(S)&&(d.add(S),S(n)))return C.stopPropagation&&(f=!0),!0;C.preventDefault&&(C.stopPropagation&&(f=!0),h=!0)}return!1},v=t[r],w,x;return v&&(m(v[a+Fc(i,e,!s)])?c=!0:s&&(e.altKey||e.metaKey||e.ctrlKey)&&!(ce.windows&&e.ctrlKey&&e.altKey)&&(w=Di[e.keyCode])&&w!=i?(m(v[a+Fc(w,e,!0)])||e.shiftKey&&(x=Ba[e.keyCode])!=i&&x!=w&&m(v[a+Fc(x,e,!1)]))&&(c=!0):s&&e.shiftKey&&m(v[a+Fc(i,e,!0)])&&(c=!0),!c&&m(v._any)&&(c=!0)),h&&(c=!0),c&&f&&e.stopPropagation(),m1=null,c}class fl{constructor(e,n,r,i,o){this.className=e,this.left=n,this.top=r,this.width=i,this.height=o}draw(){let e=document.createElement("div");return e.className=this.className,this.adjust(e),e}update(e,n){return n.className!=this.className?!1:(this.adjust(e),!0)}adjust(e){e.style.left=this.left+"px",e.style.top=this.top+"px",this.width!=null&&(e.style.width=this.width+"px"),e.style.height=this.height+"px"}eq(e){return this.left==e.left&&this.top==e.top&&this.width==e.width&&this.height==e.height&&this.className==e.className}static forRange(e,n,r){if(r.empty){let i=e.coordsAtPos(r.head,r.assoc||1);if(!i)return[];let o=D6(e);return[new fl(n,i.left-o.left,i.top-o.top,null,i.bottom-i.top)]}else return dW(e,n,r)}}function D6(t){let e=t.scrollDOM.getBoundingClientRect();return{left:(t.textDirection==st.LTR?e.left:e.right-t.scrollDOM.clientWidth*t.scaleX)-t.scrollDOM.scrollLeft*t.scaleX,top:e.top-t.scrollDOM.scrollTop*t.scaleY}}function ib(t,e,n,r){let i=t.coordsAtPos(e,n*2);if(!i)return r;let o=t.dom.getBoundingClientRect(),s=(i.top+i.bottom)/2,a=t.posAtCoords({x:o.left+1,y:s}),c=t.posAtCoords({x:o.right-1,y:s});return a==null||c==null?r:{from:Math.max(r.from,Math.min(a,c)),to:Math.min(r.to,Math.max(a,c))}}function dW(t,e,n){if(n.to<=t.viewport.from||n.from>=t.viewport.to)return[];let r=Math.max(n.from,t.viewport.from),i=Math.min(n.to,t.viewport.to),o=t.textDirection==st.LTR,s=t.contentDOM,a=s.getBoundingClientRect(),c=D6(t),h=s.querySelector(".cm-line"),f=h&&window.getComputedStyle(h),d=a.left+(f?parseInt(f.paddingLeft)+Math.min(0,parseInt(f.textIndent)):0),m=a.right-(f?parseInt(f.paddingRight):0),v=u1(t,r),w=u1(t,i),x=v.type==en.Text?v:null,C=w.type==en.Text?w:null;if(x&&(t.lineWrapping||v.widgetLineBreaks)&&(x=ib(t,r,1,x)),C&&(t.lineWrapping||w.widgetLineBreaks)&&(C=ib(t,i,-1,C)),x&&C&&x.from==C.from&&x.to==C.to)return A(T(n.from,n.to,x));{let D=x?T(n.from,null,x):O(v,!1),L=C?T(null,n.to,C):O(w,!0),I=[];return(x||v).to<(C||w).from-(x&&C?1:0)||v.widgetLineBreaks>1&&D.bottom+t.defaultLineHeight/2<L.top?I.push(S(d,D.bottom,m,L.top)):D.bottom<L.top&&t.elementAtHeight((D.bottom+L.top)/2).type==en.Text&&(D.bottom=L.top=(D.bottom+L.top)/2),A(D).concat(I).concat(A(L))}function S(D,L,I,V){return new fl(e,D-c.left,L-c.top,I-D,V-L)}function A({top:D,bottom:L,horizontal:I}){let V=[];for(let F=0;F<I.length;F+=2)V.push(S(I[F],D,I[F+1],L));return V}function T(D,L,I){let V=1e9,F=-1e9,H=[];function K(G,re,oe,te,ie){let Y=t.coordsAtPos(G,G==I.to?-2:2),ue=t.coordsAtPos(oe,oe==I.from?2:-2);!Y||!ue||(V=Math.min(Y.top,ue.top,V),F=Math.max(Y.bottom,ue.bottom,F),ie==st.LTR?H.push(o&&re?d:Y.left,o&&te?m:ue.right):H.push(!o&&te?d:ue.left,!o&&re?m:Y.right))}let W=D??I.from,J=L??I.to;for(let G of t.visibleRanges)if(G.to>W&&G.from<J)for(let re=Math.max(G.from,W),oe=Math.min(G.to,J);;){let te=t.state.doc.lineAt(re);for(let ie of t.bidiSpans(te)){let Y=ie.from+te.from,ue=ie.to+te.from;if(Y>=oe)break;ue>re&&K(Math.max(Y,re),D==null&&Y<=W,Math.min(ue,oe),L==null&&ue>=J,ie.dir)}if(re=te.to+1,re>=oe)break}return H.length==0&&K(W,D==null,J,L==null,t.textDirection),{top:V,bottom:F,horizontal:H}}function O(D,L){let I=a.top+(L?D.top:D.bottom);return{top:I,bottom:I,horizontal:[]}}}function gW(t,e){return t.constructor==e.constructor&&t.eq(e)}class mW{constructor(e,n){this.view=e,this.layer=n,this.drawn=[],this.scaleX=1,this.scaleY=1,this.measureReq={read:this.measure.bind(this),write:this.draw.bind(this)},this.dom=e.scrollDOM.appendChild(document.createElement("div")),this.dom.classList.add("cm-layer"),n.above&&this.dom.classList.add("cm-layer-above"),n.class&&this.dom.classList.add(n.class),this.scale(),this.dom.setAttribute("aria-hidden","true"),this.setOrder(e.state),e.requestMeasure(this.measureReq),n.mount&&n.mount(this.dom,e)}update(e){e.startState.facet(ou)!=e.state.facet(ou)&&this.setOrder(e.state),(this.layer.update(e,this.dom)||e.geometryChanged)&&(this.scale(),e.view.requestMeasure(this.measureReq))}docViewUpdate(e){this.layer.updateOnDocViewUpdate!==!1&&e.requestMeasure(this.measureReq)}setOrder(e){let n=0,r=e.facet(ou);for(;n<r.length&&r[n]!=this.layer;)n++;this.dom.style.zIndex=String((this.layer.above?150:-1)-n)}measure(){return this.layer.markers(this.view)}scale(){let{scaleX:e,scaleY:n}=this.view;(e!=this.scaleX||n!=this.scaleY)&&(this.scaleX=e,this.scaleY=n,this.dom.style.transform=`scale(${1/e}, ${1/n})`)}draw(e){if(e.length!=this.drawn.length||e.some((n,r)=>!gW(n,this.drawn[r]))){let n=this.dom.firstChild,r=0;for(let i of e)i.update&&n&&i.constructor&&this.drawn[r].constructor&&i.update(n,this.drawn[r])?(n=n.nextSibling,r++):this.dom.insertBefore(i.draw(),n);for(;n;){let i=n.nextSibling;n.remove(),n=i}this.drawn=e}}destroy(){this.layer.destroy&&this.layer.destroy(this.dom,this.view),this.dom.remove()}}const ou=fe.define();function I6(t){return[vt.define(e=>new mW(e,t)),ou.of(t)]}const _6=!(ce.ios&&ce.webkit&&ce.webkit_version<534),Fa=fe.define({combine(t){return Mr(t,{cursorBlinkRate:1200,drawRangeCursor:!0},{cursorBlinkRate:(e,n)=>Math.min(e,n),drawRangeCursor:(e,n)=>e||n})}});function pW(t={}){return[Fa.of(t),vW,bW,wW,l6.of(!0)]}function L6(t){return t.startState.facet(Fa)!=t.state.facet(Fa)}const vW=I6({above:!0,markers(t){let{state:e}=t,n=e.facet(Fa),r=[];for(let i of e.selection.ranges){let o=i==e.selection.main;if(i.empty?!o||_6:n.drawRangeCursor){let s=o?"cm-cursor cm-cursor-primary":"cm-cursor cm-cursor-secondary",a=i.empty?i:Q.cursor(i.head,i.head>i.anchor?-1:1);for(let c of fl.forRange(t,s,a))r.push(c)}}return r},update(t,e){t.transactions.some(r=>r.selection)&&(e.style.animationName=e.style.animationName=="cm-blink"?"cm-blink2":"cm-blink");let n=L6(t);return n&&ob(t.state,e),t.docChanged||t.selectionSet||n},mount(t,e){ob(e.state,t)},class:"cm-cursorLayer"});function ob(t,e){e.style.animationDuration=t.facet(Fa).cursorBlinkRate+"ms"}const bW=I6({above:!1,markers(t){return t.state.selection.ranges.map(e=>e.empty?[]:fl.forRange(t,"cm-selectionBackground",e)).reduce((e,n)=>e.concat(n))},update(t,e){return t.docChanged||t.selectionSet||t.viewportChanged||L6(t)},class:"cm-selectionLayer"}),p1={".cm-line":{"& ::selection, &::selection":{backgroundColor:"transparent !important"}},".cm-content":{"& :focus":{caretColor:"initial !important","&::selection, & ::selection":{backgroundColor:"Highlight !important"}}}};_6&&(p1[".cm-line"].caretColor=p1[".cm-content"].caretColor="transparent !important");const wW=Ro.highest(le.theme(p1)),B6=Me.define({map(t,e){return t==null?null:e.mapPos(t)}}),ba=Bt.define({create(){return null},update(t,e){return t!=null&&(t=e.changes.mapPos(t)),e.effects.reduce((n,r)=>r.is(B6)?r.value:n,t)}}),xW=vt.fromClass(class{constructor(t){this.view=t,this.cursor=null,this.measureReq={read:this.readPos.bind(this),write:this.drawCursor.bind(this)}}update(t){var e;let n=t.state.field(ba);n==null?this.cursor!=null&&((e=this.cursor)===null||e===void 0||e.remove(),this.cursor=null):(this.cursor||(this.cursor=this.view.scrollDOM.appendChild(document.createElement("div")),this.cursor.className="cm-dropCursor"),(t.startState.field(ba)!=n||t.docChanged||t.geometryChanged)&&this.view.requestMeasure(this.measureReq))}readPos(){let{view:t}=this,e=t.state.field(ba),n=e!=null&&t.coordsAtPos(e);if(!n)return null;let r=t.scrollDOM.getBoundingClientRect();return{left:n.left-r.left+t.scrollDOM.scrollLeft*t.scaleX,top:n.top-r.top+t.scrollDOM.scrollTop*t.scaleY,height:n.bottom-n.top}}drawCursor(t){if(this.cursor){let{scaleX:e,scaleY:n}=this.view;t?(this.cursor.style.left=t.left/e+"px",this.cursor.style.top=t.top/n+"px",this.cursor.style.height=t.height/n+"px"):this.cursor.style.left="-100000px"}}destroy(){this.cursor&&this.cursor.remove()}setDropPos(t){this.view.state.field(ba)!=t&&this.view.dispatch({effects:B6.of(t)})}},{eventObservers:{dragover(t){this.setDropPos(this.view.posAtCoords({x:t.clientX,y:t.clientY}))},dragleave(t){(t.target==this.view.contentDOM||!this.view.contentDOM.contains(t.relatedTarget))&&this.setDropPos(null)},dragend(){this.setDropPos(null)},drop(){this.setDropPos(null)}}});function yW(){return[ba,xW]}function sb(t,e,n,r,i){e.lastIndex=0;for(let o=t.iterRange(n,r),s=n,a;!o.next().done;s+=o.value.length)if(!o.lineBreak)for(;a=e.exec(o.value);)i(s+a.index,a)}function CW(t,e){let n=t.visibleRanges;if(n.length==1&&n[0].from==t.viewport.from&&n[0].to==t.viewport.to)return n;let r=[];for(let{from:i,to:o}of n)i=Math.max(t.state.doc.lineAt(i).from,i-e),o=Math.min(t.state.doc.lineAt(o).to,o+e),r.length&&r[r.length-1].to>=i?r[r.length-1].to=o:r.push({from:i,to:o});return r}class $W{constructor(e){const{regexp:n,decoration:r,decorate:i,boundary:o,maxLength:s=1e3}=e;if(!n.global)throw new RangeError("The regular expression given to MatchDecorator should have its 'g' flag set");if(this.regexp=n,i)this.addMatch=(a,c,h,f)=>i(f,h,h+a[0].length,a,c);else if(typeof r=="function")this.addMatch=(a,c,h,f)=>{let d=r(a,c,h);d&&f(h,h+a[0].length,d)};else if(r)this.addMatch=(a,c,h,f)=>f(h,h+a[0].length,r);else throw new RangeError("Either 'decorate' or 'decoration' should be provided to MatchDecorator");this.boundary=o,this.maxLength=s}createDeco(e){let n=new ei,r=n.add.bind(n);for(let{from:i,to:o}of CW(e,this.maxLength))sb(e.state.doc,this.regexp,i,o,(s,a)=>this.addMatch(a,e,s,r));return n.finish()}updateDeco(e,n){let r=1e9,i=-1;return e.docChanged&&e.changes.iterChanges((o,s,a,c)=>{c>=e.view.viewport.from&&a<=e.view.viewport.to&&(r=Math.min(a,r),i=Math.max(c,i))}),e.viewportMoved||i-r>1e3?this.createDeco(e.view):i>-1?this.updateRange(e.view,n.map(e.changes),r,i):n}updateRange(e,n,r,i){for(let o of e.visibleRanges){let s=Math.max(o.from,r),a=Math.min(o.to,i);if(a>s){let c=e.state.doc.lineAt(s),h=c.to<a?e.state.doc.lineAt(a):c,f=Math.max(o.from,c.from),d=Math.min(o.to,h.to);if(this.boundary){for(;s>c.from;s--)if(this.boundary.test(c.text[s-1-c.from])){f=s;break}for(;a<h.to;a++)if(this.boundary.test(h.text[a-h.from])){d=a;break}}let m=[],v,w=(x,C,S)=>m.push(S.range(x,C));if(c==h)for(this.regexp.lastIndex=f-c.from;(v=this.regexp.exec(c.text))&&v.index<d-c.from;)this.addMatch(v,e,v.index+c.from,w);else sb(e.state.doc,this.regexp,f,d,(x,C)=>this.addMatch(C,e,x,w));n=n.update({filterFrom:f,filterTo:d,filter:(x,C)=>x<f||C>d,add:m})}}return n}}const v1=/x/.unicode!=null?"gu":"g",SW=new RegExp(`[\0-\b
57
- --Ÿ­؜​‎‏\u2028\u2029‭‮⁦⁧⁩\uFEFF-]`,v1),AW={0:"null",7:"bell",8:"backspace",10:"newline",11:"vertical tab",13:"carriage return",27:"escape",8203:"zero width space",8204:"zero width non-joiner",8205:"zero width joiner",8206:"left-to-right mark",8207:"right-to-left mark",8232:"line separator",8237:"left-to-right override",8238:"right-to-left override",8294:"left-to-right isolate",8295:"right-to-left isolate",8297:"pop directional isolate",8233:"paragraph separator",65279:"zero width no-break space",65532:"object replacement"};let Vd=null;function RW(){var t;if(Vd==null&&typeof document<"u"&&document.body){let e=document.body.style;Vd=((t=e.tabSize)!==null&&t!==void 0?t:e.MozTabSize)!=null}return Vd||!1}const su=fe.define({combine(t){let e=Mr(t,{render:null,specialChars:SW,addSpecialChars:null});return(e.replaceTabs=!RW())&&(e.specialChars=new RegExp(" |"+e.specialChars.source,v1)),e.addSpecialChars&&(e.specialChars=new RegExp(e.specialChars.source+"|"+e.addSpecialChars.source,v1)),e}});function kW(t={}){return[su.of(t),TW()]}let ab=null;function TW(){return ab||(ab=vt.fromClass(class{constructor(t){this.view=t,this.decorations=xe.none,this.decorationCache=Object.create(null),this.decorator=this.makeDecorator(t.state.facet(su)),this.decorations=this.decorator.createDeco(t)}makeDecorator(t){return new $W({regexp:t.specialChars,decoration:(e,n,r)=>{let{doc:i}=n.state,o=ln(e[0],0);if(o==9){let s=i.lineAt(r),a=n.state.tabSize,c=Ns(s.text,a,r-s.from);return xe.replace({widget:new DW((a-c%a)*this.view.defaultCharacterWidth/this.view.scaleX)})}return this.decorationCache[o]||(this.decorationCache[o]=xe.replace({widget:new OW(t,o)}))},boundary:t.replaceTabs?void 0:/[^]/})}update(t){let e=t.state.facet(su);t.startState.facet(su)!=e?(this.decorator=this.makeDecorator(e),this.decorations=this.decorator.createDeco(t.view)):this.decorations=this.decorator.updateDeco(t,this.decorations)}},{decorations:t=>t.decorations}))}const MW="•";function EW(t){return t>=32?MW:t==10?"␤":String.fromCharCode(9216+t)}class OW extends ai{constructor(e,n){super(),this.options=e,this.code=n}eq(e){return e.code==this.code}toDOM(e){let n=EW(this.code),r=e.state.phrase("Control character")+" "+(AW[this.code]||"0x"+this.code.toString(16)),i=this.options.render&&this.options.render(this.code,r,n);if(i)return i;let o=document.createElement("span");return o.textContent=n,o.title=r,o.setAttribute("aria-label",r),o.className="cm-specialChar",o}ignoreEvent(){return!1}}class DW extends ai{constructor(e){super(),this.width=e}eq(e){return e.width==this.width}toDOM(){let e=document.createElement("span");return e.textContent=" ",e.className="cm-tab",e.style.width=this.width+"px",e}ignoreEvent(){return!1}}function IW(){return LW}const _W=xe.line({class:"cm-activeLine"}),LW=vt.fromClass(class{constructor(t){this.decorations=this.getDeco(t)}update(t){(t.docChanged||t.selectionSet)&&(this.decorations=this.getDeco(t.view))}getDeco(t){let e=-1,n=[];for(let r of t.state.selection.ranges){let i=t.lineBlockAt(r.head);i.from>e&&(n.push(_W.range(i.from)),e=i.from)}return xe.set(n)}},{decorations:t=>t.decorations});class BW extends ai{constructor(e){super(),this.content=e}toDOM(e){let n=document.createElement("span");return n.className="cm-placeholder",n.style.pointerEvents="none",n.appendChild(typeof this.content=="string"?document.createTextNode(this.content):typeof this.content=="function"?this.content(e):this.content.cloneNode(!0)),typeof this.content=="string"?n.setAttribute("aria-label","placeholder "+this.content):n.setAttribute("aria-hidden","true"),n}coordsAt(e){let n=e.firstChild?ys(e.firstChild):[];if(!n.length)return null;let r=window.getComputedStyle(e.parentNode),i=cl(n[0],r.direction!="rtl"),o=parseInt(r.lineHeight);return i.bottom-i.top>o*1.5?{left:i.left,right:i.right,top:i.top,bottom:i.top+o}:i}ignoreEvent(){return!1}}function NW(t){return vt.fromClass(class{constructor(e){this.view=e,this.placeholder=t?xe.set([xe.widget({widget:new BW(t),side:1}).range(0)]):xe.none}get decorations(){return this.view.state.doc.length?xe.none:this.placeholder}},{decorations:e=>e.decorations})}const b1=2e3;function jW(t,e,n){let r=Math.min(e.line,n.line),i=Math.max(e.line,n.line),o=[];if(e.off>b1||n.off>b1||e.col<0||n.col<0){let s=Math.min(e.off,n.off),a=Math.max(e.off,n.off);for(let c=r;c<=i;c++){let h=t.doc.line(c);h.length<=a&&o.push(Q.range(h.from+s,h.to+a))}}else{let s=Math.min(e.col,n.col),a=Math.max(e.col,n.col);for(let c=r;c<=i;c++){let h=t.doc.line(c),f=Y0(h.text,s,t.tabSize,!0);if(f<0)o.push(Q.cursor(h.to));else{let d=Y0(h.text,a,t.tabSize);o.push(Q.range(h.from+f,h.from+d))}}}return o}function FW(t,e){let n=t.coordsAtPos(t.viewport.from);return n?Math.round(Math.abs((n.left-e)/t.defaultCharacterWidth)):-1}function lb(t,e){let n=t.posAtCoords({x:e.clientX,y:e.clientY},!1),r=t.state.doc.lineAt(n),i=n-r.from,o=i>b1?-1:i==r.length?FW(t,e.clientX):Ns(r.text,t.state.tabSize,n-r.from);return{line:r.number,col:o,off:i}}function VW(t,e){let n=lb(t,e),r=t.state.selection;return n?{update(i){if(i.docChanged){let o=i.changes.mapPos(i.startState.doc.line(n.line).from),s=i.state.doc.lineAt(o);n={line:s.number,col:n.col,off:Math.min(n.off,s.length)},r=r.map(i.changes)}},get(i,o,s){let a=lb(t,i);if(!a)return r;let c=jW(t.state,n,a);return c.length?s?Q.create(c.concat(r.ranges)):Q.create(c):r}}:null}function HW(t){let e=n=>n.altKey&&n.button==0;return le.mouseSelectionStyle.of((n,r)=>e(r)?VW(n,r):null)}const PW={Alt:[18,t=>!!t.altKey],Control:[17,t=>!!t.ctrlKey],Shift:[16,t=>!!t.shiftKey],Meta:[91,t=>!!t.metaKey]},WW={style:"cursor: crosshair"};function zW(t={}){let[e,n]=PW[t.key||"Alt"],r=vt.fromClass(class{constructor(i){this.view=i,this.isDown=!1}set(i){this.isDown!=i&&(this.isDown=i,this.view.update([]))}},{eventObservers:{keydown(i){this.set(i.keyCode==e||n(i))},keyup(i){(i.keyCode==e||!n(i))&&this.set(!1)},mousemove(i){this.set(n(i))}}});return[r,le.contentAttributes.of(i=>{var o;return!((o=i.plugin(r))===null||o===void 0)&&o.isDown?WW:null})]}const ca="-10000px";class N6{constructor(e,n,r,i){this.facet=n,this.createTooltipView=r,this.removeTooltipView=i,this.input=e.state.facet(n),this.tooltips=this.input.filter(s=>s);let o=null;this.tooltipViews=this.tooltips.map(s=>o=r(s,o))}update(e,n){var r;let i=e.state.facet(this.facet),o=i.filter(c=>c);if(i===this.input){for(let c of this.tooltipViews)c.update&&c.update(e);return!1}let s=[],a=n?[]:null;for(let c=0;c<o.length;c++){let h=o[c],f=-1;if(h){for(let d=0;d<this.tooltips.length;d++){let m=this.tooltips[d];m&&m.create==h.create&&(f=d)}if(f<0)s[c]=this.createTooltipView(h,c?s[c-1]:null),a&&(a[c]=!!h.above);else{let d=s[c]=this.tooltipViews[f];a&&(a[c]=n[f]),d.update&&d.update(e)}}}for(let c of this.tooltipViews)s.indexOf(c)<0&&(this.removeTooltipView(c),(r=c.destroy)===null||r===void 0||r.call(c));return n&&(a.forEach((c,h)=>n[h]=c),n.length=a.length),this.input=i,this.tooltips=o,this.tooltipViews=s,!0}}function UW(t){let e=t.dom.ownerDocument.documentElement;return{top:0,left:0,bottom:e.clientHeight,right:e.clientWidth}}const Hd=fe.define({combine:t=>{var e,n,r;return{position:ce.ios?"absolute":((e=t.find(i=>i.position))===null||e===void 0?void 0:e.position)||"fixed",parent:((n=t.find(i=>i.parent))===null||n===void 0?void 0:n.parent)||null,tooltipSpace:((r=t.find(i=>i.tooltipSpace))===null||r===void 0?void 0:r.tooltipSpace)||UW}}}),cb=new WeakMap,gm=vt.fromClass(class{constructor(t){this.view=t,this.above=[],this.inView=!0,this.madeAbsolute=!1,this.lastTransaction=0,this.measureTimeout=-1;let e=t.state.facet(Hd);this.position=e.position,this.parent=e.parent,this.classes=t.themeClasses,this.createContainer(),this.measureReq={read:this.readMeasure.bind(this),write:this.writeMeasure.bind(this),key:this},this.resizeObserver=typeof ResizeObserver=="function"?new ResizeObserver(()=>this.measureSoon()):null,this.manager=new N6(t,mm,(n,r)=>this.createTooltip(n,r),n=>{this.resizeObserver&&this.resizeObserver.unobserve(n.dom),n.dom.remove()}),this.above=this.manager.tooltips.map(n=>!!n.above),this.intersectionObserver=typeof IntersectionObserver=="function"?new IntersectionObserver(n=>{Date.now()>this.lastTransaction-50&&n.length>0&&n[n.length-1].intersectionRatio<1&&this.measureSoon()},{threshold:[1]}):null,this.observeIntersection(),t.win.addEventListener("resize",this.measureSoon=this.measureSoon.bind(this)),this.maybeMeasure()}createContainer(){this.parent?(this.container=document.createElement("div"),this.container.style.position="relative",this.container.className=this.view.themeClasses,this.parent.appendChild(this.container)):this.container=this.view.dom}observeIntersection(){if(this.intersectionObserver){this.intersectionObserver.disconnect();for(let t of this.manager.tooltipViews)this.intersectionObserver.observe(t.dom)}}measureSoon(){this.measureTimeout<0&&(this.measureTimeout=setTimeout(()=>{this.measureTimeout=-1,this.maybeMeasure()},50))}update(t){t.transactions.length&&(this.lastTransaction=Date.now());let e=this.manager.update(t,this.above);e&&this.observeIntersection();let n=e||t.geometryChanged,r=t.state.facet(Hd);if(r.position!=this.position&&!this.madeAbsolute){this.position=r.position;for(let i of this.manager.tooltipViews)i.dom.style.position=this.position;n=!0}if(r.parent!=this.parent){this.parent&&this.container.remove(),this.parent=r.parent,this.createContainer();for(let i of this.manager.tooltipViews)this.container.appendChild(i.dom);n=!0}else this.parent&&this.view.themeClasses!=this.classes&&(this.classes=this.container.className=this.view.themeClasses);n&&this.maybeMeasure()}createTooltip(t,e){let n=t.create(this.view),r=e?e.dom:null;if(n.dom.classList.add("cm-tooltip"),t.arrow&&!n.dom.querySelector(".cm-tooltip > .cm-tooltip-arrow")){let i=document.createElement("div");i.className="cm-tooltip-arrow",n.dom.appendChild(i)}return n.dom.style.position=this.position,n.dom.style.top=ca,n.dom.style.left="0px",this.container.insertBefore(n.dom,r),n.mount&&n.mount(this.view),this.resizeObserver&&this.resizeObserver.observe(n.dom),n}destroy(){var t,e,n;this.view.win.removeEventListener("resize",this.measureSoon);for(let r of this.manager.tooltipViews)r.dom.remove(),(t=r.destroy)===null||t===void 0||t.call(r);this.parent&&this.container.remove(),(e=this.resizeObserver)===null||e===void 0||e.disconnect(),(n=this.intersectionObserver)===null||n===void 0||n.disconnect(),clearTimeout(this.measureTimeout)}readMeasure(){let t=1,e=1,n=!1;if(this.position=="fixed"&&this.manager.tooltipViews.length){let{dom:o}=this.manager.tooltipViews[0];if(ce.gecko)n=o.offsetParent!=this.container.ownerDocument.body;else if(o.style.top==ca&&o.style.left=="0px"){let s=o.getBoundingClientRect();n=Math.abs(s.top+1e4)>1||Math.abs(s.left)>1}}if(n||this.position=="absolute")if(this.parent){let o=this.parent.getBoundingClientRect();o.width&&o.height&&(t=o.width/this.parent.offsetWidth,e=o.height/this.parent.offsetHeight)}else({scaleX:t,scaleY:e}=this.view.viewState);let r=this.view.scrollDOM.getBoundingClientRect(),i=um(this.view);return{visible:{left:r.left+i.left,top:r.top+i.top,right:r.right-i.right,bottom:r.bottom-i.bottom},parent:this.parent?this.container.getBoundingClientRect():this.view.dom.getBoundingClientRect(),pos:this.manager.tooltips.map((o,s)=>{let a=this.manager.tooltipViews[s];return a.getCoords?a.getCoords(o.pos):this.view.coordsAtPos(o.pos)}),size:this.manager.tooltipViews.map(({dom:o})=>o.getBoundingClientRect()),space:this.view.state.facet(Hd).tooltipSpace(this.view),scaleX:t,scaleY:e,makeAbsolute:n}}writeMeasure(t){var e;if(t.makeAbsolute){this.madeAbsolute=!0,this.position="absolute";for(let a of this.manager.tooltipViews)a.dom.style.position="absolute"}let{visible:n,space:r,scaleX:i,scaleY:o}=t,s=[];for(let a=0;a<this.manager.tooltips.length;a++){let c=this.manager.tooltips[a],h=this.manager.tooltipViews[a],{dom:f}=h,d=t.pos[a],m=t.size[a];if(!d||c.clip!==!1&&(d.bottom<=Math.max(n.top,r.top)||d.top>=Math.min(n.bottom,r.bottom)||d.right<Math.max(n.left,r.left)-.1||d.left>Math.min(n.right,r.right)+.1)){f.style.top=ca;continue}let v=c.arrow?h.dom.querySelector(".cm-tooltip-arrow"):null,w=v?7:0,x=m.right-m.left,C=(e=cb.get(h))!==null&&e!==void 0?e:m.bottom-m.top,S=h.offset||KW,A=this.view.textDirection==st.LTR,T=m.width>r.right-r.left?A?r.left:r.right-m.width:A?Math.max(r.left,Math.min(d.left-(v?14:0)+S.x,r.right-x)):Math.min(Math.max(r.left,d.left-x+(v?14:0)-S.x),r.right-x),O=this.above[a];!c.strictSide&&(O?d.top-C-w-S.y<r.top:d.bottom+C+w+S.y>r.bottom)&&O==r.bottom-d.bottom>d.top-r.top&&(O=this.above[a]=!O);let D=(O?d.top-r.top:r.bottom-d.bottom)-w;if(D<C&&h.resize!==!1){if(D<this.view.defaultLineHeight){f.style.top=ca;continue}cb.set(h,C),f.style.height=(C=D)/o+"px"}else f.style.height&&(f.style.height="");let L=O?d.top-C-w-S.y:d.bottom+w+S.y,I=T+x;if(h.overlap!==!0)for(let V of s)V.left<I&&V.right>T&&V.top<L+C&&V.bottom>L&&(L=O?V.top-C-2-w:V.bottom+w+2);if(this.position=="absolute"?(f.style.top=(L-t.parent.top)/o+"px",ub(f,(T-t.parent.left)/i)):(f.style.top=L/o+"px",ub(f,T/i)),v){let V=d.left+(A?S.x:-S.x)-(T+14-7);v.style.left=V/i+"px"}h.overlap!==!0&&s.push({left:T,top:L,right:I,bottom:L+C}),f.classList.toggle("cm-tooltip-above",O),f.classList.toggle("cm-tooltip-below",!O),h.positioned&&h.positioned(t.space)}}maybeMeasure(){if(this.manager.tooltips.length&&(this.view.inView&&this.view.requestMeasure(this.measureReq),this.inView!=this.view.inView&&(this.inView=this.view.inView,!this.inView)))for(let t of this.manager.tooltipViews)t.dom.style.top=ca}},{eventObservers:{scroll(){this.maybeMeasure()}}});function ub(t,e){let n=parseInt(t.style.left,10);(isNaN(n)||Math.abs(e-n)>1)&&(t.style.left=e+"px")}const qW=le.baseTheme({".cm-tooltip":{zIndex:500,boxSizing:"border-box"},"&light .cm-tooltip":{border:"1px solid #bbb",backgroundColor:"#f5f5f5"},"&light .cm-tooltip-section:not(:first-child)":{borderTop:"1px solid #bbb"},"&dark .cm-tooltip":{backgroundColor:"#333338",color:"white"},".cm-tooltip-arrow":{height:"7px",width:`${7*2}px`,position:"absolute",zIndex:-1,overflow:"hidden","&:before, &:after":{content:"''",position:"absolute",width:0,height:0,borderLeft:"7px solid transparent",borderRight:"7px solid transparent"},".cm-tooltip-above &":{bottom:"-7px","&:before":{borderTop:"7px solid #bbb"},"&:after":{borderTop:"7px solid #f5f5f5",bottom:"1px"}},".cm-tooltip-below &":{top:"-7px","&:before":{borderBottom:"7px solid #bbb"},"&:after":{borderBottom:"7px solid #f5f5f5",top:"1px"}}},"&dark .cm-tooltip .cm-tooltip-arrow":{"&:before":{borderTopColor:"#333338",borderBottomColor:"#333338"},"&:after":{borderTopColor:"transparent",borderBottomColor:"transparent"}}}),KW={x:0,y:0},mm=fe.define({enables:[gm,qW]}),Iu=fe.define({combine:t=>t.reduce((e,n)=>e.concat(n),[])});class Sh{static create(e){return new Sh(e)}constructor(e){this.view=e,this.mounted=!1,this.dom=document.createElement("div"),this.dom.classList.add("cm-tooltip-hover"),this.manager=new N6(e,Iu,(n,r)=>this.createHostedView(n,r),n=>n.dom.remove())}createHostedView(e,n){let r=e.create(this.view);return r.dom.classList.add("cm-tooltip-section"),this.dom.insertBefore(r.dom,n?n.dom.nextSibling:this.dom.firstChild),this.mounted&&r.mount&&r.mount(this.view),r}mount(e){for(let n of this.manager.tooltipViews)n.mount&&n.mount(e);this.mounted=!0}positioned(e){for(let n of this.manager.tooltipViews)n.positioned&&n.positioned(e)}update(e){this.manager.update(e)}destroy(){var e;for(let n of this.manager.tooltipViews)(e=n.destroy)===null||e===void 0||e.call(n)}passProp(e){let n;for(let r of this.manager.tooltipViews){let i=r[e];if(i!==void 0){if(n===void 0)n=i;else if(n!==i)return}}return n}get offset(){return this.passProp("offset")}get getCoords(){return this.passProp("getCoords")}get overlap(){return this.passProp("overlap")}get resize(){return this.passProp("resize")}}const GW=mm.compute([Iu],t=>{let e=t.facet(Iu);return e.length===0?null:{pos:Math.min(...e.map(n=>n.pos)),end:Math.max(...e.map(n=>{var r;return(r=n.end)!==null&&r!==void 0?r:n.pos})),create:Sh.create,above:e[0].above,arrow:e.some(n=>n.arrow)}});class YW{constructor(e,n,r,i,o){this.view=e,this.source=n,this.field=r,this.setHover=i,this.hoverTime=o,this.hoverTimeout=-1,this.restartTimeout=-1,this.pending=null,this.lastMove={x:0,y:0,target:e.dom,time:0},this.checkHover=this.checkHover.bind(this),e.dom.addEventListener("mouseleave",this.mouseleave=this.mouseleave.bind(this)),e.dom.addEventListener("mousemove",this.mousemove=this.mousemove.bind(this))}update(){this.pending&&(this.pending=null,clearTimeout(this.restartTimeout),this.restartTimeout=setTimeout(()=>this.startHover(),20))}get active(){return this.view.state.field(this.field)}checkHover(){if(this.hoverTimeout=-1,this.active.length)return;let e=Date.now()-this.lastMove.time;e<this.hoverTime?this.hoverTimeout=setTimeout(this.checkHover,this.hoverTime-e):this.startHover()}startHover(){clearTimeout(this.restartTimeout);let{view:e,lastMove:n}=this,r=e.docView.nearest(n.target);if(!r)return;let i,o=1;if(r instanceof $i)i=r.posAtStart;else{if(i=e.posAtCoords(n),i==null)return;let a=e.coordsAtPos(i);if(!a||n.y<a.top||n.y>a.bottom||n.x<a.left-e.defaultCharacterWidth||n.x>a.right+e.defaultCharacterWidth)return;let c=e.bidiSpans(e.state.doc.lineAt(i)).find(f=>f.from<=i&&f.to>=i),h=c&&c.dir==st.RTL?-1:1;o=n.x<a.left?-h:h}let s=this.source(e,i,o);if(s?.then){let a=this.pending={pos:i};s.then(c=>{this.pending==a&&(this.pending=null,c&&!(Array.isArray(c)&&!c.length)&&e.dispatch({effects:this.setHover.of(Array.isArray(c)?c:[c])}))},c=>hn(e.state,c,"hover tooltip"))}else s&&!(Array.isArray(s)&&!s.length)&&e.dispatch({effects:this.setHover.of(Array.isArray(s)?s:[s])})}get tooltip(){let e=this.view.plugin(gm),n=e?e.manager.tooltips.findIndex(r=>r.create==Sh.create):-1;return n>-1?e.manager.tooltipViews[n]:null}mousemove(e){var n,r;this.lastMove={x:e.clientX,y:e.clientY,target:e.target,time:Date.now()},this.hoverTimeout<0&&(this.hoverTimeout=setTimeout(this.checkHover,this.hoverTime));let{active:i,tooltip:o}=this;if(i.length&&o&&!XW(o.dom,e)||this.pending){let{pos:s}=i[0]||this.pending,a=(r=(n=i[0])===null||n===void 0?void 0:n.end)!==null&&r!==void 0?r:s;(s==a?this.view.posAtCoords(this.lastMove)!=s:!ZW(this.view,s,a,e.clientX,e.clientY))&&(this.view.dispatch({effects:this.setHover.of([])}),this.pending=null)}}mouseleave(e){clearTimeout(this.hoverTimeout),this.hoverTimeout=-1;let{active:n}=this;if(n.length){let{tooltip:r}=this;r&&r.dom.contains(e.relatedTarget)?this.watchTooltipLeave(r.dom):this.view.dispatch({effects:this.setHover.of([])})}}watchTooltipLeave(e){let n=r=>{e.removeEventListener("mouseleave",n),this.active.length&&!this.view.dom.contains(r.relatedTarget)&&this.view.dispatch({effects:this.setHover.of([])})};e.addEventListener("mouseleave",n)}destroy(){clearTimeout(this.hoverTimeout),this.view.dom.removeEventListener("mouseleave",this.mouseleave),this.view.dom.removeEventListener("mousemove",this.mousemove)}}const Vc=4;function XW(t,e){let{left:n,right:r,top:i,bottom:o}=t.getBoundingClientRect(),s;if(s=t.querySelector(".cm-tooltip-arrow")){let a=s.getBoundingClientRect();i=Math.min(a.top,i),o=Math.max(a.bottom,o)}return e.clientX>=n-Vc&&e.clientX<=r+Vc&&e.clientY>=i-Vc&&e.clientY<=o+Vc}function ZW(t,e,n,r,i,o){let s=t.scrollDOM.getBoundingClientRect(),a=t.documentTop+t.documentPadding.top+t.contentHeight;if(s.left>r||s.right<r||s.top>i||Math.min(s.bottom,a)<i)return!1;let c=t.posAtCoords({x:r,y:i},!1);return c>=e&&c<=n}function QW(t,e={}){let n=Me.define(),r=Bt.define({create(){return[]},update(i,o){if(i.length&&(e.hideOnChange&&(o.docChanged||o.selection)?i=[]:e.hideOn&&(i=i.filter(s=>!e.hideOn(o,s))),o.docChanged)){let s=[];for(let a of i){let c=o.changes.mapPos(a.pos,-1,Jt.TrackDel);if(c!=null){let h=Object.assign(Object.create(null),a);h.pos=c,h.end!=null&&(h.end=o.changes.mapPos(h.end)),s.push(h)}}i=s}for(let s of o.effects)s.is(n)&&(i=s.value),s.is(JW)&&(i=[]);return i},provide:i=>Iu.from(i)});return{active:r,extension:[r,vt.define(i=>new YW(i,t,r,n,e.hoverTime||300)),GW]}}function j6(t,e){let n=t.plugin(gm);if(!n)return null;let r=n.manager.tooltips.indexOf(e);return r<0?null:n.manager.tooltipViews[r]}const JW=Me.define(),hb=fe.define({combine(t){let e,n;for(let r of t)e=e||r.topContainer,n=n||r.bottomContainer;return{topContainer:e,bottomContainer:n}}});function Va(t,e){let n=t.plugin(F6),r=n?n.specs.indexOf(e):-1;return r>-1?n.panels[r]:null}const F6=vt.fromClass(class{constructor(t){this.input=t.state.facet(Ha),this.specs=this.input.filter(n=>n),this.panels=this.specs.map(n=>n(t));let e=t.state.facet(hb);this.top=new Hc(t,!0,e.topContainer),this.bottom=new Hc(t,!1,e.bottomContainer),this.top.sync(this.panels.filter(n=>n.top)),this.bottom.sync(this.panels.filter(n=>!n.top));for(let n of this.panels)n.dom.classList.add("cm-panel"),n.mount&&n.mount()}update(t){let e=t.state.facet(hb);this.top.container!=e.topContainer&&(this.top.sync([]),this.top=new Hc(t.view,!0,e.topContainer)),this.bottom.container!=e.bottomContainer&&(this.bottom.sync([]),this.bottom=new Hc(t.view,!1,e.bottomContainer)),this.top.syncClasses(),this.bottom.syncClasses();let n=t.state.facet(Ha);if(n!=this.input){let r=n.filter(c=>c),i=[],o=[],s=[],a=[];for(let c of r){let h=this.specs.indexOf(c),f;h<0?(f=c(t.view),a.push(f)):(f=this.panels[h],f.update&&f.update(t)),i.push(f),(f.top?o:s).push(f)}this.specs=r,this.panels=i,this.top.sync(o),this.bottom.sync(s);for(let c of a)c.dom.classList.add("cm-panel"),c.mount&&c.mount()}else for(let r of this.panels)r.update&&r.update(t)}destroy(){this.top.sync([]),this.bottom.sync([])}},{provide:t=>le.scrollMargins.of(e=>{let n=e.plugin(t);return n&&{top:n.top.scrollMargin(),bottom:n.bottom.scrollMargin()}})});class Hc{constructor(e,n,r){this.view=e,this.top=n,this.container=r,this.dom=void 0,this.classes="",this.panels=[],this.syncClasses()}sync(e){for(let n of this.panels)n.destroy&&e.indexOf(n)<0&&n.destroy();this.panels=e,this.syncDOM()}syncDOM(){if(this.panels.length==0){this.dom&&(this.dom.remove(),this.dom=void 0);return}if(!this.dom){this.dom=document.createElement("div"),this.dom.className=this.top?"cm-panels cm-panels-top":"cm-panels cm-panels-bottom",this.dom.style[this.top?"top":"bottom"]="0";let n=this.container||this.view.dom;n.insertBefore(this.dom,this.top?n.firstChild:null)}let e=this.dom.firstChild;for(let n of this.panels)if(n.dom.parentNode==this.dom){for(;e!=n.dom;)e=fb(e);e=e.nextSibling}else this.dom.insertBefore(n.dom,e);for(;e;)e=fb(e)}scrollMargin(){return!this.dom||this.container?0:Math.max(0,this.top?this.dom.getBoundingClientRect().bottom-Math.max(0,this.view.scrollDOM.getBoundingClientRect().top):Math.min(innerHeight,this.view.scrollDOM.getBoundingClientRect().bottom)-this.dom.getBoundingClientRect().top)}syncClasses(){if(!(!this.container||this.classes==this.view.themeClasses)){for(let e of this.classes.split(" "))e&&this.container.classList.remove(e);for(let e of(this.classes=this.view.themeClasses).split(" "))e&&this.container.classList.add(e)}}}function fb(t){let e=t.nextSibling;return t.remove(),e}const Ha=fe.define({enables:F6});class ni extends go{compare(e){return this==e||this.constructor==e.constructor&&this.eq(e)}eq(e){return!1}destroy(e){}}ni.prototype.elementClass="";ni.prototype.toDOM=void 0;ni.prototype.mapMode=Jt.TrackBefore;ni.prototype.startSide=ni.prototype.endSide=-1;ni.prototype.point=!0;const au=fe.define(),ez=fe.define(),tz={class:"",renderEmptyElements:!1,elementStyle:"",markers:()=>Ke.empty,lineMarker:()=>null,widgetMarker:()=>null,lineMarkerChange:null,initialSpacer:null,updateSpacer:null,domEventHandlers:{}},Sa=fe.define();function nz(t){return[V6(),Sa.of(Object.assign(Object.assign({},tz),t))]}const db=fe.define({combine:t=>t.some(e=>e)});function V6(t){return[rz]}const rz=vt.fromClass(class{constructor(t){this.view=t,this.prevViewport=t.viewport,this.dom=document.createElement("div"),this.dom.className="cm-gutters",this.dom.setAttribute("aria-hidden","true"),this.dom.style.minHeight=this.view.contentHeight/this.view.scaleY+"px",this.gutters=t.state.facet(Sa).map(e=>new mb(t,e));for(let e of this.gutters)this.dom.appendChild(e.dom);this.fixed=!t.state.facet(db),this.fixed&&(this.dom.style.position="sticky"),this.syncGutters(!1),t.scrollDOM.insertBefore(this.dom,t.contentDOM)}update(t){if(this.updateGutters(t)){let e=this.prevViewport,n=t.view.viewport,r=Math.min(e.to,n.to)-Math.max(e.from,n.from);this.syncGutters(r<(n.to-n.from)*.8)}t.geometryChanged&&(this.dom.style.minHeight=this.view.contentHeight/this.view.scaleY+"px"),this.view.state.facet(db)!=!this.fixed&&(this.fixed=!this.fixed,this.dom.style.position=this.fixed?"sticky":""),this.prevViewport=t.view.viewport}syncGutters(t){let e=this.dom.nextSibling;t&&this.dom.remove();let n=Ke.iter(this.view.state.facet(au),this.view.viewport.from),r=[],i=this.gutters.map(o=>new iz(o,this.view.viewport,-this.view.documentPadding.top));for(let o of this.view.viewportLineBlocks)if(r.length&&(r=[]),Array.isArray(o.type)){let s=!0;for(let a of o.type)if(a.type==en.Text&&s){w1(n,r,a.from);for(let c of i)c.line(this.view,a,r);s=!1}else if(a.widget)for(let c of i)c.widget(this.view,a)}else if(o.type==en.Text){w1(n,r,o.from);for(let s of i)s.line(this.view,o,r)}else if(o.widget)for(let s of i)s.widget(this.view,o);for(let o of i)o.finish();t&&this.view.scrollDOM.insertBefore(this.dom,e)}updateGutters(t){let e=t.startState.facet(Sa),n=t.state.facet(Sa),r=t.docChanged||t.heightChanged||t.viewportChanged||!Ke.eq(t.startState.facet(au),t.state.facet(au),t.view.viewport.from,t.view.viewport.to);if(e==n)for(let i of this.gutters)i.update(t)&&(r=!0);else{r=!0;let i=[];for(let o of n){let s=e.indexOf(o);s<0?i.push(new mb(this.view,o)):(this.gutters[s].update(t),i.push(this.gutters[s]))}for(let o of this.gutters)o.dom.remove(),i.indexOf(o)<0&&o.destroy();for(let o of i)this.dom.appendChild(o.dom);this.gutters=i}return r}destroy(){for(let t of this.gutters)t.destroy();this.dom.remove()}},{provide:t=>le.scrollMargins.of(e=>{let n=e.plugin(t);return!n||n.gutters.length==0||!n.fixed?null:e.textDirection==st.LTR?{left:n.dom.offsetWidth*e.scaleX}:{right:n.dom.offsetWidth*e.scaleX}})});function gb(t){return Array.isArray(t)?t:[t]}function w1(t,e,n){for(;t.value&&t.from<=n;)t.from==n&&e.push(t.value),t.next()}class iz{constructor(e,n,r){this.gutter=e,this.height=r,this.i=0,this.cursor=Ke.iter(e.markers,n.from)}addElement(e,n,r){let{gutter:i}=this,o=(n.top-this.height)/e.scaleY,s=n.height/e.scaleY;if(this.i==i.elements.length){let a=new H6(e,s,o,r);i.elements.push(a),i.dom.appendChild(a.dom)}else i.elements[this.i].update(e,s,o,r);this.height=n.bottom,this.i++}line(e,n,r){let i=[];w1(this.cursor,i,n.from),r.length&&(i=i.concat(r));let o=this.gutter.config.lineMarker(e,n,i);o&&i.unshift(o);let s=this.gutter;i.length==0&&!s.config.renderEmptyElements||this.addElement(e,n,i)}widget(e,n){let r=this.gutter.config.widgetMarker(e,n.widget,n),i=r?[r]:null;for(let o of e.state.facet(ez)){let s=o(e,n.widget,n);s&&(i||(i=[])).push(s)}i&&this.addElement(e,n,i)}finish(){let e=this.gutter;for(;e.elements.length>this.i;){let n=e.elements.pop();e.dom.removeChild(n.dom),n.destroy()}}}class mb{constructor(e,n){this.view=e,this.config=n,this.elements=[],this.spacer=null,this.dom=document.createElement("div"),this.dom.className="cm-gutter"+(this.config.class?" "+this.config.class:"");for(let r in n.domEventHandlers)this.dom.addEventListener(r,i=>{let o=i.target,s;if(o!=this.dom&&this.dom.contains(o)){for(;o.parentNode!=this.dom;)o=o.parentNode;let c=o.getBoundingClientRect();s=(c.top+c.bottom)/2}else s=i.clientY;let a=e.lineBlockAtHeight(s-e.documentTop);n.domEventHandlers[r](e,a,i)&&i.preventDefault()});this.markers=gb(n.markers(e)),n.initialSpacer&&(this.spacer=new H6(e,0,0,[n.initialSpacer(e)]),this.dom.appendChild(this.spacer.dom),this.spacer.dom.style.cssText+="visibility: hidden; pointer-events: none")}update(e){let n=this.markers;if(this.markers=gb(this.config.markers(e.view)),this.spacer&&this.config.updateSpacer){let i=this.config.updateSpacer(this.spacer.markers[0],e);i!=this.spacer.markers[0]&&this.spacer.update(e.view,0,0,[i])}let r=e.view.viewport;return!Ke.eq(this.markers,n,r.from,r.to)||(this.config.lineMarkerChange?this.config.lineMarkerChange(e):!1)}destroy(){for(let e of this.elements)e.destroy()}}class H6{constructor(e,n,r,i){this.height=-1,this.above=0,this.markers=[],this.dom=document.createElement("div"),this.dom.className="cm-gutterElement",this.update(e,n,r,i)}update(e,n,r,i){this.height!=n&&(this.height=n,this.dom.style.height=n+"px"),this.above!=r&&(this.dom.style.marginTop=(this.above=r)?r+"px":""),oz(this.markers,i)||this.setMarkers(e,i)}setMarkers(e,n){let r="cm-gutterElement",i=this.dom.firstChild;for(let o=0,s=0;;){let a=s,c=o<n.length?n[o++]:null,h=!1;if(c){let f=c.elementClass;f&&(r+=" "+f);for(let d=s;d<this.markers.length;d++)if(this.markers[d].compare(c)){a=d,h=!0;break}}else a=this.markers.length;for(;s<a;){let f=this.markers[s++];if(f.toDOM){f.destroy(i);let d=i.nextSibling;i.remove(),i=d}}if(!c)break;c.toDOM&&(h?i=i.nextSibling:this.dom.insertBefore(c.toDOM(e),i)),h&&s++}this.dom.className=r,this.markers=n}destroy(){this.setMarkers(null,[])}}function oz(t,e){if(t.length!=e.length)return!1;for(let n=0;n<t.length;n++)if(!t[n].compare(e[n]))return!1;return!0}const sz=fe.define(),az=fe.define(),es=fe.define({combine(t){return Mr(t,{formatNumber:String,domEventHandlers:{}},{domEventHandlers(e,n){let r=Object.assign({},e);for(let i in n){let o=r[i],s=n[i];r[i]=o?(a,c,h)=>o(a,c,h)||s(a,c,h):s}return r}})}});class Pd extends ni{constructor(e){super(),this.number=e}eq(e){return this.number==e.number}toDOM(){return document.createTextNode(this.number)}}function Wd(t,e){return t.state.facet(es).formatNumber(e,t.state)}const lz=Sa.compute([es],t=>({class:"cm-lineNumbers",renderEmptyElements:!1,markers(e){return e.state.facet(sz)},lineMarker(e,n,r){return r.some(i=>i.toDOM)?null:new Pd(Wd(e,e.state.doc.lineAt(n.from).number))},widgetMarker:(e,n,r)=>{for(let i of e.state.facet(az)){let o=i(e,n,r);if(o)return o}return null},lineMarkerChange:e=>e.startState.facet(es)!=e.state.facet(es),initialSpacer(e){return new Pd(Wd(e,pb(e.state.doc.lines)))},updateSpacer(e,n){let r=Wd(n.view,pb(n.view.state.doc.lines));return r==e.number?e:new Pd(r)},domEventHandlers:t.facet(es).domEventHandlers}));function cz(t={}){return[es.of(t),V6(),lz]}function pb(t){let e=9;for(;e<t;)e=e*10+9;return e}const uz=new class extends ni{constructor(){super(...arguments),this.elementClass="cm-activeLineGutter"}},hz=au.compute(["selection"],t=>{let e=[],n=-1;for(let r of t.selection.ranges){let i=t.doc.lineAt(r.head).from;i>n&&(n=i,e.push(uz.range(i)))}return Ke.of(e)});function fz(){return hz}var zd;const ts=new je;function dz(t){return fe.define({combine:t?e=>e.concat(t):void 0})}const gz=new je;class Xn{constructor(e,n,r=[],i=""){this.data=e,this.name=i,qe.prototype.hasOwnProperty("tree")||Object.defineProperty(qe.prototype,"tree",{get(){return Kt(this)}}),this.parser=n,this.extension=[_i.of(this),qe.languageData.of((o,s,a)=>{let c=vb(o,s,a),h=c.type.prop(ts);if(!h)return[];let f=o.facet(h),d=c.type.prop(gz);if(d){let m=c.resolve(s-c.from,a);for(let v of d)if(v.test(m,o)){let w=o.facet(v.facet);return v.type=="replace"?w:w.concat(f)}}return f})].concat(r)}isActiveAt(e,n,r=-1){return vb(e,n,r).type.prop(ts)==this.data}findRegions(e){let n=e.facet(_i);if(n?.data==this.data)return[{from:0,to:e.doc.length}];if(!n||!n.allowsNesting)return[];let r=[],i=(o,s)=>{if(o.prop(ts)==this.data){r.push({from:s,to:s+o.length});return}let a=o.prop(je.mounted);if(a){if(a.tree.prop(ts)==this.data){if(a.overlay)for(let c of a.overlay)r.push({from:c.from+s,to:c.to+s});else r.push({from:s,to:s+o.length});return}else if(a.overlay){let c=r.length;if(i(a.tree,a.overlay[0].from+s),r.length>c)return}}for(let c=0;c<o.children.length;c++){let h=o.children[c];h instanceof $t&&i(h,o.positions[c]+s)}};return i(Kt(e),0),r}get allowsNesting(){return!0}}Xn.setState=Me.define();function vb(t,e,n){let r=t.facet(_i),i=Kt(t).topNode;if(!r||r.allowsNesting)for(let o=i;o;o=o.enter(e,n,Dt.ExcludeBuffers))o.type.isTop&&(i=o);return i}class _u extends Xn{constructor(e,n,r){super(e,n,[],r),this.parser=n}static define(e){let n=dz(e.languageData);return new _u(n,e.parser.configure({props:[ts.add(r=>r.isTop?n:void 0)]}),e.name)}configure(e,n){return new _u(this.data,this.parser.configure(e),n||this.name)}get allowsNesting(){return this.parser.hasWrappers()}}function Kt(t){let e=t.field(Xn.state,!1);return e?e.tree:$t.empty}class mz{constructor(e){this.doc=e,this.cursorPos=0,this.string="",this.cursor=e.iter()}get length(){return this.doc.length}syncTo(e){return this.string=this.cursor.next(e-this.cursorPos).value,this.cursorPos=e+this.string.length,this.cursorPos-this.string.length}chunk(e){return this.syncTo(e),this.string}get lineChunks(){return!0}read(e,n){let r=this.cursorPos-this.string.length;return e<r||n>=this.cursorPos?this.doc.sliceString(e,n):this.string.slice(e-r,n-r)}}let ua=null;class Lu{constructor(e,n,r=[],i,o,s,a,c){this.parser=e,this.state=n,this.fragments=r,this.tree=i,this.treeLen=o,this.viewport=s,this.skipped=a,this.scheduleOn=c,this.parse=null,this.tempSkipped=[]}static create(e,n,r){return new Lu(e,n,[],$t.empty,0,r,[],null)}startParse(){return this.parser.startParse(new mz(this.state.doc),this.fragments)}work(e,n){return n!=null&&n>=this.state.doc.length&&(n=void 0),this.tree!=$t.empty&&this.isDone(n??this.state.doc.length)?(this.takeTree(),!0):this.withContext(()=>{var r;if(typeof e=="number"){let i=Date.now()+e;e=()=>Date.now()>i}for(this.parse||(this.parse=this.startParse()),n!=null&&(this.parse.stoppedAt==null||this.parse.stoppedAt>n)&&n<this.state.doc.length&&this.parse.stopAt(n);;){let i=this.parse.advance();if(i)if(this.fragments=this.withoutTempSkipped(ao.addTree(i,this.fragments,this.parse.stoppedAt!=null)),this.treeLen=(r=this.parse.stoppedAt)!==null&&r!==void 0?r:this.state.doc.length,this.tree=i,this.parse=null,this.treeLen<(n??this.state.doc.length))this.parse=this.startParse();else return!0;if(e())return!1}})}takeTree(){let e,n;this.parse&&(e=this.parse.parsedPos)>=this.treeLen&&((this.parse.stoppedAt==null||this.parse.stoppedAt>e)&&this.parse.stopAt(e),this.withContext(()=>{for(;!(n=this.parse.advance()););}),this.treeLen=e,this.tree=n,this.fragments=this.withoutTempSkipped(ao.addTree(this.tree,this.fragments,!0)),this.parse=null)}withContext(e){let n=ua;ua=this;try{return e()}finally{ua=n}}withoutTempSkipped(e){for(let n;n=this.tempSkipped.pop();)e=bb(e,n.from,n.to);return e}changes(e,n){let{fragments:r,tree:i,treeLen:o,viewport:s,skipped:a}=this;if(this.takeTree(),!e.empty){let c=[];if(e.iterChangedRanges((h,f,d,m)=>c.push({fromA:h,toA:f,fromB:d,toB:m})),r=ao.applyChanges(r,c),i=$t.empty,o=0,s={from:e.mapPos(s.from,-1),to:e.mapPos(s.to,1)},this.skipped.length){a=[];for(let h of this.skipped){let f=e.mapPos(h.from,1),d=e.mapPos(h.to,-1);f<d&&a.push({from:f,to:d})}}}return new Lu(this.parser,n,r,i,o,s,a,this.scheduleOn)}updateViewport(e){if(this.viewport.from==e.from&&this.viewport.to==e.to)return!1;this.viewport=e;let n=this.skipped.length;for(let r=0;r<this.skipped.length;r++){let{from:i,to:o}=this.skipped[r];i<e.to&&o>e.from&&(this.fragments=bb(this.fragments,i,o),this.skipped.splice(r--,1))}return this.skipped.length>=n?!1:(this.reset(),!0)}reset(){this.parse&&(this.takeTree(),this.parse=null)}skipUntilInView(e,n){this.skipped.push({from:e,to:n})}static getSkippingParser(e){return new class extends dy{createParse(n,r,i){let o=i[0].from,s=i[i.length-1].to;return{parsedPos:o,advance(){let c=ua;if(c){for(let h of i)c.tempSkipped.push(h);e&&(c.scheduleOn=c.scheduleOn?Promise.all([c.scheduleOn,e]):e)}return this.parsedPos=s,new $t(dn.none,[],[],s-o)},stoppedAt:null,stopAt(){}}}}}isDone(e){e=Math.min(e,this.state.doc.length);let n=this.fragments;return this.treeLen>=e&&n.length&&n[0].from==0&&n[0].to>=e}static get(){return ua}}function bb(t,e,n){return ao.applyChanges(t,[{fromA:e,toA:n,fromB:e,toB:n}])}class As{constructor(e){this.context=e,this.tree=e.tree}apply(e){if(!e.docChanged&&this.tree==this.context.tree)return this;let n=this.context.changes(e.changes,e.state),r=this.context.treeLen==e.startState.doc.length?void 0:Math.max(e.changes.mapPos(this.context.treeLen),n.viewport.to);return n.work(20,r)||n.takeTree(),new As(n)}static init(e){let n=Math.min(3e3,e.doc.length),r=Lu.create(e.facet(_i).parser,e,{from:0,to:n});return r.work(20,n)||r.takeTree(),new As(r)}}Xn.state=Bt.define({create:As.init,update(t,e){for(let n of e.effects)if(n.is(Xn.setState))return n.value;return e.startState.facet(_i)!=e.state.facet(_i)?As.init(e.state):t.apply(e)}});let P6=t=>{let e=setTimeout(()=>t(),500);return()=>clearTimeout(e)};typeof requestIdleCallback<"u"&&(P6=t=>{let e=-1,n=setTimeout(()=>{e=requestIdleCallback(t,{timeout:400})},100);return()=>e<0?clearTimeout(n):cancelIdleCallback(e)});const Ud=typeof navigator<"u"&&(!((zd=navigator.scheduling)===null||zd===void 0)&&zd.isInputPending)?()=>navigator.scheduling.isInputPending():null,pz=vt.fromClass(class{constructor(e){this.view=e,this.working=null,this.workScheduled=0,this.chunkEnd=-1,this.chunkBudget=-1,this.work=this.work.bind(this),this.scheduleWork()}update(e){let n=this.view.state.field(Xn.state).context;(n.updateViewport(e.view.viewport)||this.view.viewport.to>n.treeLen)&&this.scheduleWork(),(e.docChanged||e.selectionSet)&&(this.view.hasFocus&&(this.chunkBudget+=50),this.scheduleWork()),this.checkAsyncSchedule(n)}scheduleWork(){if(this.working)return;let{state:e}=this.view,n=e.field(Xn.state);(n.tree!=n.context.tree||!n.context.isDone(e.doc.length))&&(this.working=P6(this.work))}work(e){this.working=null;let n=Date.now();if(this.chunkEnd<n&&(this.chunkEnd<0||this.view.hasFocus)&&(this.chunkEnd=n+3e4,this.chunkBudget=3e3),this.chunkBudget<=0)return;let{state:r,viewport:{to:i}}=this.view,o=r.field(Xn.state);if(o.tree==o.context.tree&&o.context.isDone(i+1e5))return;let s=Date.now()+Math.min(this.chunkBudget,100,e&&!Ud?Math.max(25,e.timeRemaining()-5):1e9),a=o.context.treeLen<i&&r.doc.length>i+1e3,c=o.context.work(()=>Ud&&Ud()||Date.now()>s,i+(a?0:1e5));this.chunkBudget-=Date.now()-n,(c||this.chunkBudget<=0)&&(o.context.takeTree(),this.view.dispatch({effects:Xn.setState.of(new As(o.context))})),this.chunkBudget>0&&!(c&&!a)&&this.scheduleWork(),this.checkAsyncSchedule(o.context)}checkAsyncSchedule(e){e.scheduleOn&&(this.workScheduled++,e.scheduleOn.then(()=>this.scheduleWork()).catch(n=>hn(this.view.state,n)).then(()=>this.workScheduled--),e.scheduleOn=null)}destroy(){this.working&&this.working()}isWorking(){return!!(this.working||this.workScheduled>0)}},{eventHandlers:{focus(){this.scheduleWork()}}}),_i=fe.define({combine(t){return t.length?t[0]:null},enables:t=>[Xn.state,pz,le.contentAttributes.compute([t],e=>{let n=e.facet(t);return n&&n.name?{"data-language":n.name}:{}})]});class vz{constructor(e,n=[]){this.language=e,this.support=n,this.extension=[e,n]}}const bz=fe.define(),Ah=fe.define({combine:t=>{if(!t.length)return" ";let e=t[0];if(!e||/\S/.test(e)||Array.from(e).some(n=>n!=e[0]))throw new Error("Invalid indent unit: "+JSON.stringify(t[0]));return e}});function Bu(t){let e=t.facet(Ah);return e.charCodeAt(0)==9?t.tabSize*e.length:e.length}function Pa(t,e){let n="",r=t.tabSize,i=t.facet(Ah)[0];if(i==" "){for(;e>=r;)n+=" ",e-=r;i=" "}for(let o=0;o<e;o++)n+=i;return n}function pm(t,e){t instanceof qe&&(t=new Rh(t));for(let r of t.state.facet(bz)){let i=r(t,e);if(i!==void 0)return i}let n=Kt(t.state);return n.length>=e?wz(t,n,e):null}class Rh{constructor(e,n={}){this.state=e,this.options=n,this.unit=Bu(e)}lineAt(e,n=1){let r=this.state.doc.lineAt(e),{simulateBreak:i,simulateDoubleBreak:o}=this.options;return i!=null&&i>=r.from&&i<=r.to?o&&i==e?{text:"",from:e}:(n<0?i<e:i<=e)?{text:r.text.slice(i-r.from),from:i}:{text:r.text.slice(0,i-r.from),from:r.from}:r}textAfterPos(e,n=1){if(this.options.simulateDoubleBreak&&e==this.options.simulateBreak)return"";let{text:r,from:i}=this.lineAt(e,n);return r.slice(e-i,Math.min(r.length,e+100-i))}column(e,n=1){let{text:r,from:i}=this.lineAt(e,n),o=this.countColumn(r,e-i),s=this.options.overrideIndentation?this.options.overrideIndentation(i):-1;return s>-1&&(o+=s-this.countColumn(r,r.search(/\S|$/))),o}countColumn(e,n=e.length){return Ns(e,this.state.tabSize,n)}lineIndent(e,n=1){let{text:r,from:i}=this.lineAt(e,n),o=this.options.overrideIndentation;if(o){let s=o(i);if(s>-1)return s}return this.countColumn(r,r.search(/\S|$/))}get simulatedBreak(){return this.options.simulateBreak||null}}const W6=new je;function wz(t,e,n){let r=e.resolveStack(n),i=e.resolveInner(n,-1).resolve(n,0).enterUnfinishedNodesBefore(n);if(i!=r.node){let o=[];for(let s=i;s&&!(s.from==r.node.from&&s.type==r.node.type);s=s.parent)o.push(s);for(let s=o.length-1;s>=0;s--)r={node:o[s],next:r}}return z6(r,t,n)}function z6(t,e,n){for(let r=t;r;r=r.next){let i=yz(r.node);if(i)return i(vm.create(e,n,r))}return 0}function xz(t){return t.pos==t.options.simulateBreak&&t.options.simulateDoubleBreak}function yz(t){let e=t.type.prop(W6);if(e)return e;let n=t.firstChild,r;if(n&&(r=n.type.prop(je.closedBy))){let i=t.lastChild,o=i&&r.indexOf(i.name)>-1;return s=>Az(s,!0,1,void 0,o&&!xz(s)?i.from:void 0)}return t.parent==null?Cz:null}function Cz(){return 0}class vm extends Rh{constructor(e,n,r){super(e.state,e.options),this.base=e,this.pos=n,this.context=r}get node(){return this.context.node}static create(e,n,r){return new vm(e,n,r)}get textAfter(){return this.textAfterPos(this.pos)}get baseIndent(){return this.baseIndentFor(this.node)}baseIndentFor(e){let n=this.state.doc.lineAt(e.from);for(;;){let r=e.resolve(n.from);for(;r.parent&&r.parent.from==r.from;)r=r.parent;if($z(r,e))break;n=this.state.doc.lineAt(r.from)}return this.lineIndent(n.from)}continue(){return z6(this.context.next,this.base,this.pos)}}function $z(t,e){for(let n=e;n;n=n.parent)if(t==n)return!0;return!1}function Sz(t){let e=t.node,n=e.childAfter(e.from),r=e.lastChild;if(!n)return null;let i=t.options.simulateBreak,o=t.state.doc.lineAt(n.from),s=i==null||i<=o.from?o.to:Math.min(o.to,i);for(let a=n.to;;){let c=e.childAfter(a);if(!c||c==r)return null;if(!c.type.isSkipped){if(c.from>=s)return null;let h=/^ */.exec(o.text.slice(n.to-o.from))[0].length;return{from:n.from,to:n.to+h}}a=c.to}}function Az(t,e,n,r,i){let o=t.textAfter,s=o.match(/^\s*/)[0].length,a=r&&o.slice(s,s+r.length)==r||i==t.pos+s,c=Sz(t);return c?a?t.column(c.from):t.column(c.to):t.baseIndent+(a?0:t.unit*n)}function wb({except:t,units:e=1}={}){return n=>{let r=t&&t.test(n.textAfter);return n.baseIndent+(r?0:e*n.unit)}}const Rz=200;function kz(){return qe.transactionFilter.of(t=>{if(!t.docChanged||!t.isUserEvent("input.type")&&!t.isUserEvent("input.complete"))return t;let e=t.startState.languageDataAt("indentOnInput",t.startState.selection.main.head);if(!e.length)return t;let n=t.newDoc,{head:r}=t.newSelection.main,i=n.lineAt(r);if(r>i.from+Rz)return t;let o=n.sliceString(i.from,r);if(!e.some(h=>h.test(o)))return t;let{state:s}=t,a=-1,c=[];for(let{head:h}of s.selection.ranges){let f=s.doc.lineAt(h);if(f.from==a)continue;a=f.from;let d=pm(s,f.from);if(d==null)continue;let m=/^\s*/.exec(f.text)[0],v=Pa(s,d);m!=v&&c.push({from:f.from,to:f.from+m.length,insert:v})}return c.length?[t,{changes:c,sequential:!0}]:t})}const Tz=fe.define(),U6=new je;function Mz(t){let e=t.firstChild,n=t.lastChild;return e&&e.to<n.from?{from:e.to,to:n.type.isError?t.to:n.from}:null}function Ez(t,e,n){let r=Kt(t);if(r.length<n)return null;let i=r.resolveStack(n,1),o=null;for(let s=i;s;s=s.next){let a=s.node;if(a.to<=n||a.from>n)continue;if(o&&a.from<e)break;let c=a.type.prop(U6);if(c&&(a.to<r.length-50||r.length==t.doc.length||!Oz(a))){let h=c(a,t);h&&h.from<=n&&h.from>=e&&h.to>n&&(o=h)}}return o}function Oz(t){let e=t.lastChild;return e&&e.to==t.to&&e.type.isError}function Nu(t,e,n){for(let r of t.facet(Tz)){let i=r(t,e,n);if(i)return i}return Ez(t,e,n)}function q6(t,e){let n=e.mapPos(t.from,1),r=e.mapPos(t.to,-1);return n>=r?void 0:{from:n,to:r}}const kh=Me.define({map:q6}),dl=Me.define({map:q6});function K6(t){let e=[];for(let{head:n}of t.state.selection.ranges)e.some(r=>r.from<=n&&r.to>=n)||e.push(t.lineBlockAt(n));return e}const bo=Bt.define({create(){return xe.none},update(t,e){t=t.map(e.changes);for(let n of e.effects)if(n.is(kh)&&!Dz(t,n.value.from,n.value.to)){let{preparePlaceholder:r}=e.state.facet(X6),i=r?xe.replace({widget:new Fz(r(e.state,n.value))}):xb;t=t.update({add:[i.range(n.value.from,n.value.to)]})}else n.is(dl)&&(t=t.update({filter:(r,i)=>n.value.from!=r||n.value.to!=i,filterFrom:n.value.from,filterTo:n.value.to}));if(e.selection){let n=!1,{head:r}=e.selection.main;t.between(r,r,(i,o)=>{i<r&&o>r&&(n=!0)}),n&&(t=t.update({filterFrom:r,filterTo:r,filter:(i,o)=>o<=r||i>=r}))}return t},provide:t=>le.decorations.from(t),toJSON(t,e){let n=[];return t.between(0,e.doc.length,(r,i)=>{n.push(r,i)}),n},fromJSON(t){if(!Array.isArray(t)||t.length%2)throw new RangeError("Invalid JSON for fold state");let e=[];for(let n=0;n<t.length;){let r=t[n++],i=t[n++];if(typeof r!="number"||typeof i!="number")throw new RangeError("Invalid JSON for fold state");e.push(xb.range(r,i))}return xe.set(e,!0)}});function ju(t,e,n){var r;let i=null;return(r=t.field(bo,!1))===null||r===void 0||r.between(e,n,(o,s)=>{(!i||i.from>o)&&(i={from:o,to:s})}),i}function Dz(t,e,n){let r=!1;return t.between(e,e,(i,o)=>{i==e&&o==n&&(r=!0)}),r}function G6(t,e){return t.field(bo,!1)?e:e.concat(Me.appendConfig.of(Z6()))}const Iz=t=>{for(let e of K6(t)){let n=Nu(t.state,e.from,e.to);if(n)return t.dispatch({effects:G6(t.state,[kh.of(n),Y6(t,n)])}),!0}return!1},_z=t=>{if(!t.state.field(bo,!1))return!1;let e=[];for(let n of K6(t)){let r=ju(t.state,n.from,n.to);r&&e.push(dl.of(r),Y6(t,r,!1))}return e.length&&t.dispatch({effects:e}),e.length>0};function Y6(t,e,n=!0){let r=t.state.doc.lineAt(e.from).number,i=t.state.doc.lineAt(e.to).number;return le.announce.of(`${t.state.phrase(n?"Folded lines":"Unfolded lines")} ${r} ${t.state.phrase("to")} ${i}.`)}const Lz=t=>{let{state:e}=t,n=[];for(let r=0;r<e.doc.length;){let i=t.lineBlockAt(r),o=Nu(e,i.from,i.to);o&&n.push(kh.of(o)),r=(o?t.lineBlockAt(o.to):i).to+1}return n.length&&t.dispatch({effects:G6(t.state,n)}),!!n.length},Bz=t=>{let e=t.state.field(bo,!1);if(!e||!e.size)return!1;let n=[];return e.between(0,t.state.doc.length,(r,i)=>{n.push(dl.of({from:r,to:i}))}),t.dispatch({effects:n}),!0},Nz=[{key:"Ctrl-Shift-[",mac:"Cmd-Alt-[",run:Iz},{key:"Ctrl-Shift-]",mac:"Cmd-Alt-]",run:_z},{key:"Ctrl-Alt-[",run:Lz},{key:"Ctrl-Alt-]",run:Bz}],jz={placeholderDOM:null,preparePlaceholder:null,placeholderText:"…"},X6=fe.define({combine(t){return Mr(t,jz)}});function Z6(t){return[bo,Pz]}function Q6(t,e){let{state:n}=t,r=n.facet(X6),i=s=>{let a=t.lineBlockAt(t.posAtDOM(s.target)),c=ju(t.state,a.from,a.to);c&&t.dispatch({effects:dl.of(c)}),s.preventDefault()};if(r.placeholderDOM)return r.placeholderDOM(t,i,e);let o=document.createElement("span");return o.textContent=r.placeholderText,o.setAttribute("aria-label",n.phrase("folded code")),o.title=n.phrase("unfold"),o.className="cm-foldPlaceholder",o.onclick=i,o}const xb=xe.replace({widget:new class extends ai{toDOM(t){return Q6(t,null)}}});class Fz extends ai{constructor(e){super(),this.value=e}eq(e){return this.value==e.value}toDOM(e){return Q6(e,this.value)}}const Vz={openText:"⌄",closedText:"›",markerDOM:null,domEventHandlers:{},foldingChanged:()=>!1};class qd extends ni{constructor(e,n){super(),this.config=e,this.open=n}eq(e){return this.config==e.config&&this.open==e.open}toDOM(e){if(this.config.markerDOM)return this.config.markerDOM(this.open);let n=document.createElement("span");return n.textContent=this.open?this.config.openText:this.config.closedText,n.title=e.state.phrase(this.open?"Fold line":"Unfold line"),n}}function Hz(t={}){let e=Object.assign(Object.assign({},Vz),t),n=new qd(e,!0),r=new qd(e,!1),i=vt.fromClass(class{constructor(s){this.from=s.viewport.from,this.markers=this.buildMarkers(s)}update(s){(s.docChanged||s.viewportChanged||s.startState.facet(_i)!=s.state.facet(_i)||s.startState.field(bo,!1)!=s.state.field(bo,!1)||Kt(s.startState)!=Kt(s.state)||e.foldingChanged(s))&&(this.markers=this.buildMarkers(s.view))}buildMarkers(s){let a=new ei;for(let c of s.viewportLineBlocks){let h=ju(s.state,c.from,c.to)?r:Nu(s.state,c.from,c.to)?n:null;h&&a.add(c.from,c.from,h)}return a.finish()}}),{domEventHandlers:o}=e;return[i,nz({class:"cm-foldGutter",markers(s){var a;return((a=s.plugin(i))===null||a===void 0?void 0:a.markers)||Ke.empty},initialSpacer(){return new qd(e,!1)},domEventHandlers:Object.assign(Object.assign({},o),{click:(s,a,c)=>{if(o.click&&o.click(s,a,c))return!0;let h=ju(s.state,a.from,a.to);if(h)return s.dispatch({effects:dl.of(h)}),!0;let f=Nu(s.state,a.from,a.to);return f?(s.dispatch({effects:kh.of(f)}),!0):!1}})}),Z6()]}const Pz=le.baseTheme({".cm-foldPlaceholder":{backgroundColor:"#eee",border:"1px solid #ddd",color:"#888",borderRadius:".2em",margin:"0 1px",padding:"0 1px",cursor:"pointer"},".cm-foldGutter span":{padding:"0 1px",cursor:"pointer"}});class gl{constructor(e,n){this.specs=e;let r;function i(a){let c=Oi.newName();return(r||(r=Object.create(null)))["."+c]=a,c}const o=typeof n.all=="string"?n.all:n.all?i(n.all):void 0,s=n.scope;this.scope=s instanceof Xn?a=>a.prop(ts)==s.data:s?a=>a==s:void 0,this.style=py(e.map(a=>({tag:a.tag,class:a.class||i(Object.assign({},a,{tag:null}))})),{all:o}).style,this.module=r?new Oi(r):null,this.themeType=n.themeType}static define(e,n){return new gl(e,n||{})}}const x1=fe.define(),J6=fe.define({combine(t){return t.length?[t[0]]:null}});function Kd(t){let e=t.facet(x1);return e.length?e:t.facet(J6)}function e4(t,e){let n=[zz],r;return t instanceof gl&&(t.module&&n.push(le.styleModule.of(t.module)),r=t.themeType),e?.fallback?n.push(J6.of(t)):r?n.push(x1.computeN([le.darkTheme],i=>i.facet(le.darkTheme)==(r=="dark")?[t]:[])):n.push(x1.of(t)),n}class Wz{constructor(e){this.markCache=Object.create(null),this.tree=Kt(e.state),this.decorations=this.buildDeco(e,Kd(e.state)),this.decoratedTo=e.viewport.to}update(e){let n=Kt(e.state),r=Kd(e.state),i=r!=Kd(e.startState),{viewport:o}=e.view,s=e.changes.mapPos(this.decoratedTo,1);n.length<o.to&&!i&&n.type==this.tree.type&&s>=o.to?(this.decorations=this.decorations.map(e.changes),this.decoratedTo=s):(n!=this.tree||e.viewportChanged||i)&&(this.tree=n,this.decorations=this.buildDeco(e.view,r),this.decoratedTo=o.to)}buildDeco(e,n){if(!n||!this.tree.length)return xe.none;let r=new ei;for(let{from:i,to:o}of e.visibleRanges)cH(this.tree,n,(s,a,c)=>{r.add(s,a,this.markCache[c]||(this.markCache[c]=xe.mark({class:c})))},i,o);return r.finish()}}const zz=Ro.high(vt.fromClass(Wz,{decorations:t=>t.decorations})),Uz=gl.define([{tag:z.meta,color:"#404740"},{tag:z.link,textDecoration:"underline"},{tag:z.heading,textDecoration:"underline",fontWeight:"bold"},{tag:z.emphasis,fontStyle:"italic"},{tag:z.strong,fontWeight:"bold"},{tag:z.strikethrough,textDecoration:"line-through"},{tag:z.keyword,color:"#708"},{tag:[z.atom,z.bool,z.url,z.contentSeparator,z.labelName],color:"#219"},{tag:[z.literal,z.inserted],color:"#164"},{tag:[z.string,z.deleted],color:"#a11"},{tag:[z.regexp,z.escape,z.special(z.string)],color:"#e40"},{tag:z.definition(z.variableName),color:"#00f"},{tag:z.local(z.variableName),color:"#30a"},{tag:[z.typeName,z.namespace],color:"#085"},{tag:z.className,color:"#167"},{tag:[z.special(z.variableName),z.macroName],color:"#256"},{tag:z.definition(z.propertyName),color:"#00c"},{tag:z.comment,color:"#940"},{tag:z.invalid,color:"#f00"}]),qz=le.baseTheme({"&.cm-focused .cm-matchingBracket":{backgroundColor:"#328c8252"},"&.cm-focused .cm-nonmatchingBracket":{backgroundColor:"#bb555544"}}),t4=1e4,n4="()[]{}",r4=fe.define({combine(t){return Mr(t,{afterCursor:!0,brackets:n4,maxScanDistance:t4,renderMatch:Yz})}}),Kz=xe.mark({class:"cm-matchingBracket"}),Gz=xe.mark({class:"cm-nonmatchingBracket"});function Yz(t){let e=[],n=t.matched?Kz:Gz;return e.push(n.range(t.start.from,t.start.to)),t.end&&e.push(n.range(t.end.from,t.end.to)),e}const Xz=Bt.define({create(){return xe.none},update(t,e){if(!e.docChanged&&!e.selection)return t;let n=[],r=e.state.facet(r4);for(let i of e.state.selection.ranges){if(!i.empty)continue;let o=vr(e.state,i.head,-1,r)||i.head>0&&vr(e.state,i.head-1,1,r)||r.afterCursor&&(vr(e.state,i.head,1,r)||i.head<e.state.doc.length&&vr(e.state,i.head+1,-1,r));o&&(n=n.concat(r.renderMatch(o,e.state)))}return xe.set(n,!0)},provide:t=>le.decorations.from(t)}),Zz=[Xz,qz];function Qz(t={}){return[r4.of(t),Zz]}const Jz=new je;function y1(t,e,n){let r=t.prop(e<0?je.openedBy:je.closedBy);if(r)return r;if(t.name.length==1){let i=n.indexOf(t.name);if(i>-1&&i%2==(e<0?1:0))return[n[i+e]]}return null}function C1(t){let e=t.type.prop(Jz);return e?e(t.node):t}function vr(t,e,n,r={}){let i=r.maxScanDistance||t4,o=r.brackets||n4,s=Kt(t),a=s.resolveInner(e,n);for(let c=a;c;c=c.parent){let h=y1(c.type,n,o);if(h&&c.from<c.to){let f=C1(c);if(f&&(n>0?e>=f.from&&e<f.to:e>f.from&&e<=f.to))return eU(t,e,n,c,f,h,o)}}return tU(t,e,n,s,a.type,i,o)}function eU(t,e,n,r,i,o,s){let a=r.parent,c={from:i.from,to:i.to},h=0,f=a?.cursor();if(f&&(n<0?f.childBefore(r.from):f.childAfter(r.to)))do if(n<0?f.to<=r.from:f.from>=r.to){if(h==0&&o.indexOf(f.type.name)>-1&&f.from<f.to){let d=C1(f);return{start:c,end:d?{from:d.from,to:d.to}:void 0,matched:!0}}else if(y1(f.type,n,s))h++;else if(y1(f.type,-n,s)){if(h==0){let d=C1(f);return{start:c,end:d&&d.from<d.to?{from:d.from,to:d.to}:void 0,matched:!1}}h--}}while(n<0?f.prevSibling():f.nextSibling());return{start:c,matched:!1}}function tU(t,e,n,r,i,o,s){let a=n<0?t.sliceDoc(e-1,e):t.sliceDoc(e,e+1),c=s.indexOf(a);if(c<0||c%2==0!=n>0)return null;let h={from:n<0?e-1:e,to:n>0?e+1:e},f=t.doc.iterRange(e,n>0?t.doc.length:0),d=0;for(let m=0;!f.next().done&&m<=o;){let v=f.value;n<0&&(m+=v.length);let w=e+m*n;for(let x=n>0?0:v.length-1,C=n>0?v.length:-1;x!=C;x+=n){let S=s.indexOf(v[x]);if(!(S<0||r.resolveInner(w+x,1).type!=i))if(S%2==0==n>0)d++;else{if(d==1)return{start:h,end:{from:w+x,to:w+x+1},matched:S>>1==c>>1};d--}}n>0&&(m+=v.length)}return f.done?{start:h,matched:!1}:null}const nU=Object.create(null),yb=[dn.none],Cb=[],$b=Object.create(null),rU=Object.create(null);for(let[t,e]of[["variable","variableName"],["variable-2","variableName.special"],["string-2","string.special"],["def","variableName.definition"],["tag","tagName"],["attribute","attributeName"],["type","typeName"],["builtin","variableName.standard"],["qualifier","modifier"],["error","invalid"],["header","heading"],["property","propertyName"]])rU[t]=iU(nU,e);function Gd(t,e){Cb.indexOf(t)>-1||(Cb.push(t),console.warn(e))}function iU(t,e){let n=[];for(let a of e.split(" ")){let c=[];for(let h of a.split(".")){let f=t[h]||z[h];f?typeof f=="function"?c.length?c=c.map(f):Gd(h,`Modifier ${h} used at start of tag`):c.length?Gd(h,`Tag ${h} used as modifier`):c=Array.isArray(f)?f:[f]:Gd(h,`Unknown highlighting tag ${h}`)}for(let h of c)n.push(h)}if(!n.length)return 0;let r=e.replace(/ /g,"_"),i=r+" "+n.map(a=>a.id),o=$b[i];if(o)return o.id;let s=$b[i]=dn.define({id:yb.length,name:r,props:[gy({[r]:n})]});return yb.push(s),s.id}st.RTL,st.LTR;const oU=()=>t=>{try{JSON.parse(t.state.doc.toString())}catch(e){if(!(e instanceof SyntaxError))throw e;const n=sU(e,t.state.doc);return[{from:n,message:e.message,severity:"error",to:n}]}return[]};function sU(t,e){let n;return(n=t.message.match(/at position (\d+)/))?Math.min(+n[1],e.length):(n=t.message.match(/at line (\d+) column (\d+)/))?Math.min(e.line(+n[1]).from+ +n[2]-1,e.length):0}const aU=_u.define({name:"json",parser:dH.configure({props:[W6.add({Object:wb({except:/^\s*\}/}),Array:wb({except:/^\s*\]/})}),U6.add({"Object Array":Mz})]}),languageData:{closeBrackets:{brackets:["[","{",'"']},indentOnInput:/^\s*[\}\]]$/}});function lU(){return new vz(aU)}function cU(t,e){if(t==null)return{};var n={};for(var r in t)if({}.hasOwnProperty.call(t,r)){if(e.indexOf(r)!==-1)continue;n[r]=t[r]}return n}const uU=t=>{let{state:e}=t,n=e.doc.lineAt(e.selection.main.from),r=wm(t.state,n.from);return r.line?hU(t):r.block?dU(t):!1};function bm(t,e){return({state:n,dispatch:r})=>{if(n.readOnly)return!1;let i=t(e,n);return i?(r(n.update(i)),!0):!1}}const hU=bm(pU,0),fU=bm(i4,0),dU=bm((t,e)=>i4(t,e,mU(e)),0);function wm(t,e){let n=t.languageDataAt("commentTokens",e);return n.length?n[0]:{}}const ha=50;function gU(t,{open:e,close:n},r,i){let o=t.sliceDoc(r-ha,r),s=t.sliceDoc(i,i+ha),a=/\s*$/.exec(o)[0].length,c=/^\s*/.exec(s)[0].length,h=o.length-a;if(o.slice(h-e.length,h)==e&&s.slice(c,c+n.length)==n)return{open:{pos:r-a,margin:a&&1},close:{pos:i+c,margin:c&&1}};let f,d;i-r<=2*ha?f=d=t.sliceDoc(r,i):(f=t.sliceDoc(r,r+ha),d=t.sliceDoc(i-ha,i));let m=/^\s*/.exec(f)[0].length,v=/\s*$/.exec(d)[0].length,w=d.length-v-n.length;return f.slice(m,m+e.length)==e&&d.slice(w,w+n.length)==n?{open:{pos:r+m+e.length,margin:/\s/.test(f.charAt(m+e.length))?1:0},close:{pos:i-v-n.length,margin:/\s/.test(d.charAt(w-1))?1:0}}:null}function mU(t){let e=[];for(let n of t.selection.ranges){let r=t.doc.lineAt(n.from),i=n.to<=r.to?r:t.doc.lineAt(n.to);i.from>r.from&&i.from==n.to&&(i=n.to==r.to+1?r:t.doc.lineAt(n.to-1));let o=e.length-1;o>=0&&e[o].to>r.from?e[o].to=i.to:e.push({from:r.from+/^\s*/.exec(r.text)[0].length,to:i.to})}return e}function i4(t,e,n=e.selection.ranges){let r=n.map(o=>wm(e,o.from).block);if(!r.every(o=>o))return null;let i=n.map((o,s)=>gU(e,r[s],o.from,o.to));if(t!=2&&!i.every(o=>o))return{changes:e.changes(n.map((o,s)=>i[s]?[]:[{from:o.from,insert:r[s].open+" "},{from:o.to,insert:" "+r[s].close}]))};if(t!=1&&i.some(o=>o)){let o=[];for(let s=0,a;s<i.length;s++)if(a=i[s]){let c=r[s],{open:h,close:f}=a;o.push({from:h.pos-c.open.length,to:h.pos+h.margin},{from:f.pos-f.margin,to:f.pos+c.close.length})}return{changes:o}}return null}function pU(t,e,n=e.selection.ranges){let r=[],i=-1;for(let{from:o,to:s}of n){let a=r.length,c=1e9,h=wm(e,o).line;if(h){for(let f=o;f<=s;){let d=e.doc.lineAt(f);if(d.from>i&&(o==s||s>d.from)){i=d.from;let m=/^\s*/.exec(d.text)[0].length,v=m==d.length,w=d.text.slice(m,m+h.length)==h?m:-1;m<d.text.length&&m<c&&(c=m),r.push({line:d,comment:w,token:h,indent:m,empty:v,single:!1})}f=d.to+1}if(c<1e9)for(let f=a;f<r.length;f++)r[f].indent<r[f].line.text.length&&(r[f].indent=c);r.length==a+1&&(r[a].single=!0)}}if(t!=2&&r.some(o=>o.comment<0&&(!o.empty||o.single))){let o=[];for(let{line:a,token:c,indent:h,empty:f,single:d}of r)(d||!f)&&o.push({from:a.from+h,insert:c+" "});let s=e.changes(o);return{changes:s,selection:e.selection.map(s,1)}}else if(t!=1&&r.some(o=>o.comment>=0)){let o=[];for(let{line:s,comment:a,token:c}of r)if(a>=0){let h=s.from+a,f=h+c.length;s.text[f-s.from]==" "&&f++,o.push({from:h,to:f})}return{changes:o}}return null}const $1=Tr.define(),vU=Tr.define(),bU=fe.define(),o4=fe.define({combine(t){return Mr(t,{minDepth:100,newGroupDelay:500,joinToEvent:(e,n)=>n},{minDepth:Math.max,newGroupDelay:Math.min,joinToEvent:(e,n)=>(r,i)=>e(r,i)||n(r,i)})}}),s4=Bt.define({create(){return br.empty},update(t,e){let n=e.state.facet(o4),r=e.annotation($1);if(r){let c=fn.fromTransaction(e,r.selection),h=r.side,f=h==0?t.undone:t.done;return c?f=Fu(f,f.length,n.minDepth,c):f=c4(f,e.startState.selection),new br(h==0?r.rest:f,h==0?f:r.rest)}let i=e.annotation(vU);if((i=="full"||i=="before")&&(t=t.isolate()),e.annotation(Tt.addToHistory)===!1)return e.changes.empty?t:t.addMapping(e.changes.desc);let o=fn.fromTransaction(e),s=e.annotation(Tt.time),a=e.annotation(Tt.userEvent);return o?t=t.addChanges(o,s,a,n,e):e.selection&&(t=t.addSelection(e.startState.selection,s,a,n.newGroupDelay)),(i=="full"||i=="after")&&(t=t.isolate()),t},toJSON(t){return{done:t.done.map(e=>e.toJSON()),undone:t.undone.map(e=>e.toJSON())}},fromJSON(t){return new br(t.done.map(fn.fromJSON),t.undone.map(fn.fromJSON))}});function wU(t={}){return[s4,o4.of(t),le.domEventHandlers({beforeinput(e,n){let r=e.inputType=="historyUndo"?a4:e.inputType=="historyRedo"?S1:null;return r?(e.preventDefault(),r(n)):!1}})]}function Th(t,e){return function({state:n,dispatch:r}){if(!e&&n.readOnly)return!1;let i=n.field(s4,!1);if(!i)return!1;let o=i.pop(t,n,e);return o?(r(o),!0):!1}}const a4=Th(0,!1),S1=Th(1,!1),xU=Th(0,!0),yU=Th(1,!0);class fn{constructor(e,n,r,i,o){this.changes=e,this.effects=n,this.mapped=r,this.startSelection=i,this.selectionsAfter=o}setSelAfter(e){return new fn(this.changes,this.effects,this.mapped,this.startSelection,e)}toJSON(){var e,n,r;return{changes:(e=this.changes)===null||e===void 0?void 0:e.toJSON(),mapped:(n=this.mapped)===null||n===void 0?void 0:n.toJSON(),startSelection:(r=this.startSelection)===null||r===void 0?void 0:r.toJSON(),selectionsAfter:this.selectionsAfter.map(i=>i.toJSON())}}static fromJSON(e){return new fn(e.changes&&kt.fromJSON(e.changes),[],e.mapped&&xr.fromJSON(e.mapped),e.startSelection&&Q.fromJSON(e.startSelection),e.selectionsAfter.map(Q.fromJSON))}static fromTransaction(e,n){let r=Nn;for(let i of e.startState.facet(bU)){let o=i(e);o.length&&(r=r.concat(o))}return!r.length&&e.changes.empty?null:new fn(e.changes.invert(e.startState.doc),r,void 0,n||e.startState.selection,Nn)}static selection(e){return new fn(void 0,Nn,void 0,void 0,e)}}function Fu(t,e,n,r){let i=e+1>n+20?e-n-1:0,o=t.slice(i,e);return o.push(r),o}function CU(t,e){let n=[],r=!1;return t.iterChangedRanges((i,o)=>n.push(i,o)),e.iterChangedRanges((i,o,s,a)=>{for(let c=0;c<n.length;){let h=n[c++],f=n[c++];a>=h&&s<=f&&(r=!0)}}),r}function $U(t,e){return t.ranges.length==e.ranges.length&&t.ranges.filter((n,r)=>n.empty!=e.ranges[r].empty).length===0}function l4(t,e){return t.length?e.length?t.concat(e):t:e}const Nn=[],SU=200;function c4(t,e){if(t.length){let n=t[t.length-1],r=n.selectionsAfter.slice(Math.max(0,n.selectionsAfter.length-SU));return r.length&&r[r.length-1].eq(e)?t:(r.push(e),Fu(t,t.length-1,1e9,n.setSelAfter(r)))}else return[fn.selection([e])]}function AU(t){let e=t[t.length-1],n=t.slice();return n[t.length-1]=e.setSelAfter(e.selectionsAfter.slice(0,e.selectionsAfter.length-1)),n}function Yd(t,e){if(!t.length)return t;let n=t.length,r=Nn;for(;n;){let i=RU(t[n-1],e,r);if(i.changes&&!i.changes.empty||i.effects.length){let o=t.slice(0,n);return o[n-1]=i,o}else e=i.mapped,n--,r=i.selectionsAfter}return r.length?[fn.selection(r)]:Nn}function RU(t,e,n){let r=l4(t.selectionsAfter.length?t.selectionsAfter.map(a=>a.map(e)):Nn,n);if(!t.changes)return fn.selection(r);let i=t.changes.map(e),o=e.mapDesc(t.changes,!0),s=t.mapped?t.mapped.composeDesc(o):o;return new fn(i,Me.mapEffects(t.effects,e),s,t.startSelection.map(o),r)}const kU=/^(input\.type|delete)($|\.)/;class br{constructor(e,n,r=0,i=void 0){this.done=e,this.undone=n,this.prevTime=r,this.prevUserEvent=i}isolate(){return this.prevTime?new br(this.done,this.undone):this}addChanges(e,n,r,i,o){let s=this.done,a=s[s.length-1];return a&&a.changes&&!a.changes.empty&&e.changes&&(!r||kU.test(r))&&(!a.selectionsAfter.length&&n-this.prevTime<i.newGroupDelay&&i.joinToEvent(o,CU(a.changes,e.changes))||r=="input.type.compose")?s=Fu(s,s.length-1,i.minDepth,new fn(e.changes.compose(a.changes),l4(Me.mapEffects(e.effects,a.changes),a.effects),a.mapped,a.startSelection,Nn)):s=Fu(s,s.length,i.minDepth,e),new br(s,Nn,n,r)}addSelection(e,n,r,i){let o=this.done.length?this.done[this.done.length-1].selectionsAfter:Nn;return o.length>0&&n-this.prevTime<i&&r==this.prevUserEvent&&r&&/^select($|\.)/.test(r)&&$U(o[o.length-1],e)?this:new br(c4(this.done,e),this.undone,n,r)}addMapping(e){return new br(Yd(this.done,e),Yd(this.undone,e),this.prevTime,this.prevUserEvent)}pop(e,n,r){let i=e==0?this.done:this.undone;if(i.length==0)return null;let o=i[i.length-1],s=o.selectionsAfter[0]||n.selection;if(r&&o.selectionsAfter.length)return n.update({selection:o.selectionsAfter[o.selectionsAfter.length-1],annotations:$1.of({side:e,rest:AU(i),selection:s}),userEvent:e==0?"select.undo":"select.redo",scrollIntoView:!0});if(o.changes){let a=i.length==1?Nn:i.slice(0,i.length-1);return o.mapped&&(a=Yd(a,o.mapped)),n.update({changes:o.changes,selection:o.startSelection,effects:o.effects,annotations:$1.of({side:e,rest:a,selection:s}),filter:!1,userEvent:e==0?"undo":"redo",scrollIntoView:!0})}else return null}}br.empty=new br(Nn,Nn);const TU=[{key:"Mod-z",run:a4,preventDefault:!0},{key:"Mod-y",mac:"Mod-Shift-z",run:S1,preventDefault:!0},{linux:"Ctrl-Shift-z",run:S1,preventDefault:!0},{key:"Mod-u",run:xU,preventDefault:!0},{key:"Alt-u",mac:"Mod-Shift-u",run:yU,preventDefault:!0}];function js(t,e){return Q.create(t.ranges.map(e),t.mainIndex)}function Er(t,e){return t.update({selection:e,scrollIntoView:!0,userEvent:"select"})}function ir({state:t,dispatch:e},n){let r=js(t.selection,n);return r.eq(t.selection,!0)?!1:(e(Er(t,r)),!0)}function Mh(t,e){return Q.cursor(e?t.to:t.from)}function u4(t,e){return ir(t,n=>n.empty?t.moveByChar(n,e):Mh(n,e))}function Gt(t){return t.textDirectionAt(t.state.selection.main.head)==st.LTR}const h4=t=>u4(t,!Gt(t)),f4=t=>u4(t,Gt(t));function d4(t,e){return ir(t,n=>n.empty?t.moveByGroup(n,e):Mh(n,e))}const MU=t=>d4(t,!Gt(t)),EU=t=>d4(t,Gt(t));function OU(t,e,n){if(e.type.prop(n))return!0;let r=e.to-e.from;return r&&(r>2||/[^\s,.;:]/.test(t.sliceDoc(e.from,e.to)))||e.firstChild}function Eh(t,e,n){let r=Kt(t).resolveInner(e.head),i=n?je.closedBy:je.openedBy;for(let c=e.head;;){let h=n?r.childAfter(c):r.childBefore(c);if(!h)break;OU(t,h,i)?r=h:c=n?h.to:h.from}let o=r.type.prop(i),s,a;return o&&(s=n?vr(t,r.from,1):vr(t,r.to,-1))&&s.matched?a=n?s.end.to:s.end.from:a=n?r.to:r.from,Q.cursor(a,n?-1:1)}const DU=t=>ir(t,e=>Eh(t.state,e,!Gt(t))),IU=t=>ir(t,e=>Eh(t.state,e,Gt(t)));function g4(t,e){return ir(t,n=>{if(!n.empty)return Mh(n,e);let r=t.moveVertically(n,e);return r.head!=n.head?r:t.moveToLineBoundary(n,e)})}const m4=t=>g4(t,!1),p4=t=>g4(t,!0);function v4(t){let e=t.scrollDOM.clientHeight<t.scrollDOM.scrollHeight-2,n=0,r=0,i;if(e){for(let o of t.state.facet(le.scrollMargins)){let s=o(t);s?.top&&(n=Math.max(s?.top,n)),s?.bottom&&(r=Math.max(s?.bottom,r))}i=t.scrollDOM.clientHeight-n-r}else i=(t.dom.ownerDocument.defaultView||window).innerHeight;return{marginTop:n,marginBottom:r,selfScroll:e,height:Math.max(t.defaultLineHeight,i-5)}}function b4(t,e){let n=v4(t),{state:r}=t,i=js(r.selection,s=>s.empty?t.moveVertically(s,e,n.height):Mh(s,e));if(i.eq(r.selection))return!1;let o;if(n.selfScroll){let s=t.coordsAtPos(r.selection.main.head),a=t.scrollDOM.getBoundingClientRect(),c=a.top+n.marginTop,h=a.bottom-n.marginBottom;s&&s.top>c&&s.bottom<h&&(o=le.scrollIntoView(i.main.head,{y:"start",yMargin:s.top-c}))}return t.dispatch(Er(r,i),{effects:o}),!0}const Sb=t=>b4(t,!1),A1=t=>b4(t,!0);function Fi(t,e,n){let r=t.lineBlockAt(e.head),i=t.moveToLineBoundary(e,n);if(i.head==e.head&&i.head!=(n?r.to:r.from)&&(i=t.moveToLineBoundary(e,n,!1)),!n&&i.head==r.from&&r.length){let o=/^\s*/.exec(t.state.sliceDoc(r.from,Math.min(r.from+100,r.to)))[0].length;o&&e.head!=r.from+o&&(i=Q.cursor(r.from+o))}return i}const _U=t=>ir(t,e=>Fi(t,e,!0)),LU=t=>ir(t,e=>Fi(t,e,!1)),BU=t=>ir(t,e=>Fi(t,e,!Gt(t))),NU=t=>ir(t,e=>Fi(t,e,Gt(t))),jU=t=>ir(t,e=>Q.cursor(t.lineBlockAt(e.head).from,1)),FU=t=>ir(t,e=>Q.cursor(t.lineBlockAt(e.head).to,-1));function VU(t,e,n){let r=!1,i=js(t.selection,o=>{let s=vr(t,o.head,-1)||vr(t,o.head,1)||o.head>0&&vr(t,o.head-1,1)||o.head<t.doc.length&&vr(t,o.head+1,-1);if(!s||!s.end)return o;r=!0;let a=s.start.from==o.head?s.end.to:s.end.from;return Q.cursor(a)});return r?(e(Er(t,i)),!0):!1}const HU=({state:t,dispatch:e})=>VU(t,e);function Pn(t,e){let n=js(t.state.selection,r=>{let i=e(r);return Q.range(r.anchor,i.head,i.goalColumn,i.bidiLevel||void 0)});return n.eq(t.state.selection)?!1:(t.dispatch(Er(t.state,n)),!0)}function w4(t,e){return Pn(t,n=>t.moveByChar(n,e))}const x4=t=>w4(t,!Gt(t)),y4=t=>w4(t,Gt(t));function C4(t,e){return Pn(t,n=>t.moveByGroup(n,e))}const PU=t=>C4(t,!Gt(t)),WU=t=>C4(t,Gt(t)),zU=t=>Pn(t,e=>Eh(t.state,e,!Gt(t))),UU=t=>Pn(t,e=>Eh(t.state,e,Gt(t)));function $4(t,e){return Pn(t,n=>t.moveVertically(n,e))}const S4=t=>$4(t,!1),A4=t=>$4(t,!0);function R4(t,e){return Pn(t,n=>t.moveVertically(n,e,v4(t).height))}const Ab=t=>R4(t,!1),Rb=t=>R4(t,!0),qU=t=>Pn(t,e=>Fi(t,e,!0)),KU=t=>Pn(t,e=>Fi(t,e,!1)),GU=t=>Pn(t,e=>Fi(t,e,!Gt(t))),YU=t=>Pn(t,e=>Fi(t,e,Gt(t))),XU=t=>Pn(t,e=>Q.cursor(t.lineBlockAt(e.head).from)),ZU=t=>Pn(t,e=>Q.cursor(t.lineBlockAt(e.head).to)),kb=({state:t,dispatch:e})=>(e(Er(t,{anchor:0})),!0),Tb=({state:t,dispatch:e})=>(e(Er(t,{anchor:t.doc.length})),!0),Mb=({state:t,dispatch:e})=>(e(Er(t,{anchor:t.selection.main.anchor,head:0})),!0),Eb=({state:t,dispatch:e})=>(e(Er(t,{anchor:t.selection.main.anchor,head:t.doc.length})),!0),QU=({state:t,dispatch:e})=>(e(t.update({selection:{anchor:0,head:t.doc.length},userEvent:"select"})),!0),JU=({state:t,dispatch:e})=>{let n=Oh(t).map(({from:r,to:i})=>Q.range(r,Math.min(i+1,t.doc.length)));return e(t.update({selection:Q.create(n),userEvent:"select"})),!0},eq=({state:t,dispatch:e})=>{let n=js(t.selection,r=>{let i=Kt(t),o=i.resolveStack(r.from,1);if(r.empty){let s=i.resolveStack(r.from,-1);s.node.from>=o.node.from&&s.node.to<=o.node.to&&(o=s)}for(let s=o;s;s=s.next){let{node:a}=s;if((a.from<r.from&&a.to>=r.to||a.to>r.to&&a.from<=r.from)&&s.next)return Q.range(a.to,a.from)}return r});return n.eq(t.selection)?!1:(e(Er(t,n)),!0)},tq=({state:t,dispatch:e})=>{let n=t.selection,r=null;return n.ranges.length>1?r=Q.create([n.main]):n.main.empty||(r=Q.create([Q.cursor(n.main.head)])),r?(e(Er(t,r)),!0):!1};function ml(t,e){if(t.state.readOnly)return!1;let n="delete.selection",{state:r}=t,i=r.changeByRange(o=>{let{from:s,to:a}=o;if(s==a){let c=e(o);c<s?(n="delete.backward",c=Pc(t,c,!1)):c>s&&(n="delete.forward",c=Pc(t,c,!0)),s=Math.min(s,c),a=Math.max(a,c)}else s=Pc(t,s,!1),a=Pc(t,a,!0);return s==a?{range:o}:{changes:{from:s,to:a},range:Q.cursor(s,s<o.head?-1:1)}});return i.changes.empty?!1:(t.dispatch(r.update(i,{scrollIntoView:!0,userEvent:n,effects:n=="delete.selection"?le.announce.of(r.phrase("Selection deleted")):void 0})),!0)}function Pc(t,e,n){if(t instanceof le)for(let r of t.state.facet(le.atomicRanges).map(i=>i(t)))r.between(e,e,(i,o)=>{i<e&&o>e&&(e=n?o:i)});return e}const k4=(t,e,n)=>ml(t,r=>{let i=r.from,{state:o}=t,s=o.doc.lineAt(i),a,c;if(n&&!e&&i>s.from&&i<s.from+200&&!/[^ \t]/.test(a=s.text.slice(0,i-s.from))){if(a[a.length-1]==" ")return i-1;let h=Ns(a,o.tabSize),f=h%Bu(o)||Bu(o);for(let d=0;d<f&&a[a.length-1-d]==" ";d++)i--;c=i}else c=Ht(s.text,i-s.from,e,e)+s.from,c==i&&s.number!=(e?o.doc.lines:1)?c+=e?1:-1:!e&&/[\ufe00-\ufe0f]/.test(s.text.slice(c-s.from,i-s.from))&&(c=Ht(s.text,c-s.from,!1,!1)+s.from);return c}),R1=t=>k4(t,!1,!0),T4=t=>k4(t,!0,!1),M4=(t,e)=>ml(t,n=>{let r=n.head,{state:i}=t,o=i.doc.lineAt(r),s=i.charCategorizer(r);for(let a=null;;){if(r==(e?o.to:o.from)){r==n.head&&o.number!=(e?i.doc.lines:1)&&(r+=e?1:-1);break}let c=Ht(o.text,r-o.from,e)+o.from,h=o.text.slice(Math.min(r,c)-o.from,Math.max(r,c)-o.from),f=s(h);if(a!=null&&f!=a)break;(h!=" "||r!=n.head)&&(a=f),r=c}return r}),E4=t=>M4(t,!1),nq=t=>M4(t,!0),rq=t=>ml(t,e=>{let n=t.lineBlockAt(e.head).to;return e.head<n?n:Math.min(t.state.doc.length,e.head+1)}),iq=t=>ml(t,e=>{let n=t.moveToLineBoundary(e,!1).head;return e.head>n?n:Math.max(0,e.head-1)}),oq=t=>ml(t,e=>{let n=t.moveToLineBoundary(e,!0).head;return e.head<n?n:Math.min(t.state.doc.length,e.head+1)}),sq=({state:t,dispatch:e})=>{if(t.readOnly)return!1;let n=t.changeByRange(r=>({changes:{from:r.from,to:r.to,insert:Ge.of(["",""])},range:Q.cursor(r.from)}));return e(t.update(n,{scrollIntoView:!0,userEvent:"input"})),!0},aq=({state:t,dispatch:e})=>{if(t.readOnly)return!1;let n=t.changeByRange(r=>{if(!r.empty||r.from==0||r.from==t.doc.length)return{range:r};let i=r.from,o=t.doc.lineAt(i),s=i==o.from?i-1:Ht(o.text,i-o.from,!1)+o.from,a=i==o.to?i+1:Ht(o.text,i-o.from,!0)+o.from;return{changes:{from:s,to:a,insert:t.doc.slice(i,a).append(t.doc.slice(s,i))},range:Q.cursor(a)}});return n.changes.empty?!1:(e(t.update(n,{scrollIntoView:!0,userEvent:"move.character"})),!0)};function Oh(t){let e=[],n=-1;for(let r of t.selection.ranges){let i=t.doc.lineAt(r.from),o=t.doc.lineAt(r.to);if(!r.empty&&r.to==o.from&&(o=t.doc.lineAt(r.to-1)),n>=i.number){let s=e[e.length-1];s.to=o.to,s.ranges.push(r)}else e.push({from:i.from,to:o.to,ranges:[r]});n=o.number+1}return e}function O4(t,e,n){if(t.readOnly)return!1;let r=[],i=[];for(let o of Oh(t)){if(n?o.to==t.doc.length:o.from==0)continue;let s=t.doc.lineAt(n?o.to+1:o.from-1),a=s.length+1;if(n){r.push({from:o.to,to:s.to},{from:o.from,insert:s.text+t.lineBreak});for(let c of o.ranges)i.push(Q.range(Math.min(t.doc.length,c.anchor+a),Math.min(t.doc.length,c.head+a)))}else{r.push({from:s.from,to:o.from},{from:o.to,insert:t.lineBreak+s.text});for(let c of o.ranges)i.push(Q.range(c.anchor-a,c.head-a))}}return r.length?(e(t.update({changes:r,scrollIntoView:!0,selection:Q.create(i,t.selection.mainIndex),userEvent:"move.line"})),!0):!1}const lq=({state:t,dispatch:e})=>O4(t,e,!1),cq=({state:t,dispatch:e})=>O4(t,e,!0);function D4(t,e,n){if(t.readOnly)return!1;let r=[];for(let i of Oh(t))n?r.push({from:i.from,insert:t.doc.slice(i.from,i.to)+t.lineBreak}):r.push({from:i.to,insert:t.lineBreak+t.doc.slice(i.from,i.to)});return e(t.update({changes:r,scrollIntoView:!0,userEvent:"input.copyline"})),!0}const uq=({state:t,dispatch:e})=>D4(t,e,!1),hq=({state:t,dispatch:e})=>D4(t,e,!0),fq=t=>{if(t.state.readOnly)return!1;let{state:e}=t,n=e.changes(Oh(e).map(({from:i,to:o})=>(i>0?i--:o<e.doc.length&&o++,{from:i,to:o}))),r=js(e.selection,i=>{let o;if(t.lineWrapping){let s=t.lineBlockAt(i.head),a=t.coordsAtPos(i.head,i.assoc||1);a&&(o=s.bottom+t.documentTop-a.bottom+t.defaultLineHeight/2)}return t.moveVertically(i,!0,o)}).map(n);return t.dispatch({changes:n,selection:r,scrollIntoView:!0,userEvent:"delete.line"}),!0};function dq(t,e){if(/\(\)|\[\]|\{\}/.test(t.sliceDoc(e-1,e+1)))return{from:e,to:e};let n=Kt(t).resolveInner(e),r=n.childBefore(e),i=n.childAfter(e),o;return r&&i&&r.to<=e&&i.from>=e&&(o=r.type.prop(je.closedBy))&&o.indexOf(i.name)>-1&&t.doc.lineAt(r.to).from==t.doc.lineAt(i.from).from&&!/\S/.test(t.sliceDoc(r.to,i.from))?{from:r.to,to:i.from}:null}const Ob=I4(!1),gq=I4(!0);function I4(t){return({state:e,dispatch:n})=>{if(e.readOnly)return!1;let r=e.changeByRange(i=>{let{from:o,to:s}=i,a=e.doc.lineAt(o),c=!t&&o==s&&dq(e,o);t&&(o=s=(s<=a.to?a:e.doc.lineAt(s)).to);let h=new Rh(e,{simulateBreak:o,simulateDoubleBreak:!!c}),f=pm(h,o);for(f==null&&(f=Ns(/^\s*/.exec(e.doc.lineAt(o).text)[0],e.tabSize));s<a.to&&/\s/.test(a.text[s-a.from]);)s++;c?{from:o,to:s}=c:o>a.from&&o<a.from+100&&!/\S/.test(a.text.slice(0,o))&&(o=a.from);let d=["",Pa(e,f)];return c&&d.push(Pa(e,h.lineIndent(a.from,-1))),{changes:{from:o,to:s,insert:Ge.of(d)},range:Q.cursor(o+1+d[1].length)}});return n(e.update(r,{scrollIntoView:!0,userEvent:"input"})),!0}}function xm(t,e){let n=-1;return t.changeByRange(r=>{let i=[];for(let s=r.from;s<=r.to;){let a=t.doc.lineAt(s);a.number>n&&(r.empty||r.to>a.from)&&(e(a,i,r),n=a.number),s=a.to+1}let o=t.changes(i);return{changes:i,range:Q.range(o.mapPos(r.anchor,1),o.mapPos(r.head,1))}})}const mq=({state:t,dispatch:e})=>{if(t.readOnly)return!1;let n=Object.create(null),r=new Rh(t,{overrideIndentation:o=>{let s=n[o];return s??-1}}),i=xm(t,(o,s,a)=>{let c=pm(r,o.from);if(c==null)return;/\S/.test(o.text)||(c=0);let h=/^\s*/.exec(o.text)[0],f=Pa(t,c);(h!=f||a.from<o.from+h.length)&&(n[o.from]=c,s.push({from:o.from,to:o.from+h.length,insert:f}))});return i.changes.empty||e(t.update(i,{userEvent:"indent"})),!0},_4=({state:t,dispatch:e})=>t.readOnly?!1:(e(t.update(xm(t,(n,r)=>{r.push({from:n.from,insert:t.facet(Ah)})}),{userEvent:"input.indent"})),!0),L4=({state:t,dispatch:e})=>t.readOnly?!1:(e(t.update(xm(t,(n,r)=>{let i=/^\s*/.exec(n.text)[0];if(!i)return;let o=Ns(i,t.tabSize),s=0,a=Pa(t,Math.max(0,o-Bu(t)));for(;s<i.length&&s<a.length&&i.charCodeAt(s)==a.charCodeAt(s);)s++;r.push({from:n.from+s,to:n.from+i.length,insert:a.slice(s)})}),{userEvent:"delete.dedent"})),!0),pq=t=>(t.setTabFocusMode(),!0),vq=[{key:"Ctrl-b",run:h4,shift:x4,preventDefault:!0},{key:"Ctrl-f",run:f4,shift:y4},{key:"Ctrl-p",run:m4,shift:S4},{key:"Ctrl-n",run:p4,shift:A4},{key:"Ctrl-a",run:jU,shift:XU},{key:"Ctrl-e",run:FU,shift:ZU},{key:"Ctrl-d",run:T4},{key:"Ctrl-h",run:R1},{key:"Ctrl-k",run:rq},{key:"Ctrl-Alt-h",run:E4},{key:"Ctrl-o",run:sq},{key:"Ctrl-t",run:aq},{key:"Ctrl-v",run:A1}],bq=[{key:"ArrowLeft",run:h4,shift:x4,preventDefault:!0},{key:"Mod-ArrowLeft",mac:"Alt-ArrowLeft",run:MU,shift:PU,preventDefault:!0},{mac:"Cmd-ArrowLeft",run:BU,shift:GU,preventDefault:!0},{key:"ArrowRight",run:f4,shift:y4,preventDefault:!0},{key:"Mod-ArrowRight",mac:"Alt-ArrowRight",run:EU,shift:WU,preventDefault:!0},{mac:"Cmd-ArrowRight",run:NU,shift:YU,preventDefault:!0},{key:"ArrowUp",run:m4,shift:S4,preventDefault:!0},{mac:"Cmd-ArrowUp",run:kb,shift:Mb},{mac:"Ctrl-ArrowUp",run:Sb,shift:Ab},{key:"ArrowDown",run:p4,shift:A4,preventDefault:!0},{mac:"Cmd-ArrowDown",run:Tb,shift:Eb},{mac:"Ctrl-ArrowDown",run:A1,shift:Rb},{key:"PageUp",run:Sb,shift:Ab},{key:"PageDown",run:A1,shift:Rb},{key:"Home",run:LU,shift:KU,preventDefault:!0},{key:"Mod-Home",run:kb,shift:Mb},{key:"End",run:_U,shift:qU,preventDefault:!0},{key:"Mod-End",run:Tb,shift:Eb},{key:"Enter",run:Ob,shift:Ob},{key:"Mod-a",run:QU},{key:"Backspace",run:R1,shift:R1},{key:"Delete",run:T4},{key:"Mod-Backspace",mac:"Alt-Backspace",run:E4},{key:"Mod-Delete",mac:"Alt-Delete",run:nq},{mac:"Mod-Backspace",run:iq},{mac:"Mod-Delete",run:oq}].concat(vq.map(t=>({mac:t.key,run:t.run,shift:t.shift}))),wq=[{key:"Alt-ArrowLeft",mac:"Ctrl-ArrowLeft",run:DU,shift:zU},{key:"Alt-ArrowRight",mac:"Ctrl-ArrowRight",run:IU,shift:UU},{key:"Alt-ArrowUp",run:lq},{key:"Shift-Alt-ArrowUp",run:uq},{key:"Alt-ArrowDown",run:cq},{key:"Shift-Alt-ArrowDown",run:hq},{key:"Escape",run:tq},{key:"Mod-Enter",run:gq},{key:"Alt-l",mac:"Ctrl-l",run:JU},{key:"Mod-i",run:eq,preventDefault:!0},{key:"Mod-[",run:L4},{key:"Mod-]",run:_4},{key:"Mod-Alt-\\",run:mq},{key:"Shift-Mod-k",run:fq},{key:"Shift-Mod-\\",run:HU},{key:"Mod-/",run:uU},{key:"Alt-A",run:fU},{key:"Ctrl-m",mac:"Shift-Alt-m",run:pq}].concat(bq),xq={key:"Tab",run:_4,shift:L4};function et(){var t=arguments[0];typeof t=="string"&&(t=document.createElement(t));var e=1,n=arguments[1];if(n&&typeof n=="object"&&n.nodeType==null&&!Array.isArray(n)){for(var r in n)if(Object.prototype.hasOwnProperty.call(n,r)){var i=n[r];typeof i=="string"?t.setAttribute(r,i):i!=null&&(t[r]=i)}e++}for(;e<arguments.length;e++)B4(t,arguments[e]);return t}function B4(t,e){if(typeof e=="string")t.appendChild(document.createTextNode(e));else if(e!=null)if(e.nodeType!=null)t.appendChild(e);else if(Array.isArray(e))for(var n=0;n<e.length;n++)B4(t,e[n]);else throw new RangeError("Unsupported child node: "+e)}const Db=typeof String.prototype.normalize=="function"?t=>t.normalize("NFKD"):t=>t;class Rs{constructor(e,n,r=0,i=e.length,o,s){this.test=s,this.value={from:0,to:0},this.done=!1,this.matches=[],this.buffer="",this.bufferPos=0,this.iter=e.iterRange(r,i),this.bufferStart=r,this.normalize=o?a=>o(Db(a)):Db,this.query=this.normalize(n)}peek(){if(this.bufferPos==this.buffer.length){if(this.bufferStart+=this.buffer.length,this.iter.next(),this.iter.done)return-1;this.bufferPos=0,this.buffer=this.iter.value}return ln(this.buffer,this.bufferPos)}next(){for(;this.matches.length;)this.matches.pop();return this.nextOverlapping()}nextOverlapping(){for(;;){let e=this.peek();if(e<0)return this.done=!0,this;let n=em(e),r=this.bufferStart+this.bufferPos;this.bufferPos+=mr(e);let i=this.normalize(n);if(i.length)for(let o=0,s=r;;o++){let a=i.charCodeAt(o),c=this.match(a,s,this.bufferPos+this.bufferStart);if(o==i.length-1){if(c)return this.value=c,this;break}s==r&&o<n.length&&n.charCodeAt(o)==a&&s++}}}match(e,n,r){let i=null;for(let o=0;o<this.matches.length;o+=2){let s=this.matches[o],a=!1;this.query.charCodeAt(s)==e&&(s==this.query.length-1?i={from:this.matches[o+1],to:r}:(this.matches[o]++,a=!0)),a||(this.matches.splice(o,2),o-=2)}return this.query.charCodeAt(0)==e&&(this.query.length==1?i={from:n,to:r}:this.matches.push(1,n)),i&&this.test&&!this.test(i.from,i.to,this.buffer,this.bufferStart)&&(i=null),i}}typeof Symbol<"u"&&(Rs.prototype[Symbol.iterator]=function(){return this});const N4={from:-1,to:-1,match:/.*/.exec("")},ym="gm"+(/x/.unicode==null?"":"u");class j4{constructor(e,n,r,i=0,o=e.length){if(this.text=e,this.to=o,this.curLine="",this.done=!1,this.value=N4,/\\[sWDnr]|\n|\r|\[\^/.test(n))return new F4(e,n,r,i,o);this.re=new RegExp(n,ym+(r?.ignoreCase?"i":"")),this.test=r?.test,this.iter=e.iter();let s=e.lineAt(i);this.curLineStart=s.from,this.matchPos=Vu(e,i),this.getLine(this.curLineStart)}getLine(e){this.iter.next(e),this.iter.lineBreak?this.curLine="":(this.curLine=this.iter.value,this.curLineStart+this.curLine.length>this.to&&(this.curLine=this.curLine.slice(0,this.to-this.curLineStart)),this.iter.next())}nextLine(){this.curLineStart=this.curLineStart+this.curLine.length+1,this.curLineStart>this.to?this.curLine="":this.getLine(0)}next(){for(let e=this.matchPos-this.curLineStart;;){this.re.lastIndex=e;let n=this.matchPos<=this.to&&this.re.exec(this.curLine);if(n){let r=this.curLineStart+n.index,i=r+n[0].length;if(this.matchPos=Vu(this.text,i+(r==i?1:0)),r==this.curLineStart+this.curLine.length&&this.nextLine(),(r<i||r>this.value.to)&&(!this.test||this.test(r,i,n)))return this.value={from:r,to:i,match:n},this;e=this.matchPos-this.curLineStart}else if(this.curLineStart+this.curLine.length<this.to)this.nextLine(),e=0;else return this.done=!0,this}}}const Xd=new WeakMap;class hs{constructor(e,n){this.from=e,this.text=n}get to(){return this.from+this.text.length}static get(e,n,r){let i=Xd.get(e);if(!i||i.from>=r||i.to<=n){let a=new hs(n,e.sliceString(n,r));return Xd.set(e,a),a}if(i.from==n&&i.to==r)return i;let{text:o,from:s}=i;return s>n&&(o=e.sliceString(n,s)+o,s=n),i.to<r&&(o+=e.sliceString(i.to,r)),Xd.set(e,new hs(s,o)),new hs(n,o.slice(n-s,r-s))}}class F4{constructor(e,n,r,i,o){this.text=e,this.to=o,this.done=!1,this.value=N4,this.matchPos=Vu(e,i),this.re=new RegExp(n,ym+(r?.ignoreCase?"i":"")),this.test=r?.test,this.flat=hs.get(e,i,this.chunkEnd(i+5e3))}chunkEnd(e){return e>=this.to?this.to:this.text.lineAt(e).to}next(){for(;;){let e=this.re.lastIndex=this.matchPos-this.flat.from,n=this.re.exec(this.flat.text);if(n&&!n[0]&&n.index==e&&(this.re.lastIndex=e+1,n=this.re.exec(this.flat.text)),n){let r=this.flat.from+n.index,i=r+n[0].length;if((this.flat.to>=this.to||n.index+n[0].length<=this.flat.text.length-10)&&(!this.test||this.test(r,i,n)))return this.value={from:r,to:i,match:n},this.matchPos=Vu(this.text,i+(r==i?1:0)),this}if(this.flat.to==this.to)return this.done=!0,this;this.flat=hs.get(this.text,this.flat.from,this.chunkEnd(this.flat.from+this.flat.text.length*2))}}}typeof Symbol<"u"&&(j4.prototype[Symbol.iterator]=F4.prototype[Symbol.iterator]=function(){return this});function yq(t){try{return new RegExp(t,ym),!0}catch{return!1}}function Vu(t,e){if(e>=t.length)return e;let n=t.lineAt(e),r;for(;e<n.to&&(r=n.text.charCodeAt(e-n.from))>=56320&&r<57344;)e++;return e}function k1(t){let e=String(t.state.doc.lineAt(t.state.selection.main.head).number),n=et("input",{class:"cm-textfield",name:"line",value:e}),r=et("form",{class:"cm-gotoLine",onkeydown:o=>{o.keyCode==27?(o.preventDefault(),t.dispatch({effects:Aa.of(!1)}),t.focus()):o.keyCode==13&&(o.preventDefault(),i())},onsubmit:o=>{o.preventDefault(),i()}},et("label",t.state.phrase("Go to line"),": ",n)," ",et("button",{class:"cm-button",type:"submit"},t.state.phrase("go")),et("button",{name:"close",onclick:()=>{t.dispatch({effects:Aa.of(!1)}),t.focus()},"aria-label":t.state.phrase("close"),type:"button"},["×"]));function i(){let o=/^([+-])?(\d+)?(:\d+)?(%)?$/.exec(n.value);if(!o)return;let{state:s}=t,a=s.doc.lineAt(s.selection.main.head),[,c,h,f,d]=o,m=f?+f.slice(1):0,v=h?+h:a.number;if(h&&d){let C=v/100;c&&(C=C*(c=="-"?-1:1)+a.number/s.doc.lines),v=Math.round(s.doc.lines*C)}else h&&c&&(v=v*(c=="-"?-1:1)+a.number);let w=s.doc.line(Math.max(1,Math.min(s.doc.lines,v))),x=Q.cursor(w.from+Math.max(0,Math.min(m,w.length)));t.dispatch({effects:[Aa.of(!1),le.scrollIntoView(x.from,{y:"center"})],selection:x}),t.focus()}return{dom:r}}const Aa=Me.define(),Ib=Bt.define({create(){return!0},update(t,e){for(let n of e.effects)n.is(Aa)&&(t=n.value);return t},provide:t=>Ha.from(t,e=>e?k1:null)}),Cq=t=>{let e=Va(t,k1);if(!e){let n=[Aa.of(!0)];t.state.field(Ib,!1)==null&&n.push(Me.appendConfig.of([Ib,$q])),t.dispatch({effects:n}),e=Va(t,k1)}return e&&e.dom.querySelector("input").select(),!0},$q=le.baseTheme({".cm-panel.cm-gotoLine":{padding:"2px 6px 4px",position:"relative","& label":{fontSize:"80%"},"& [name=close]":{position:"absolute",top:"0",bottom:"0",right:"4px",backgroundColor:"inherit",border:"none",font:"inherit",padding:"0"}}}),Sq={highlightWordAroundCursor:!1,minSelectionLength:1,maxMatches:100,wholeWords:!1},Aq=fe.define({combine(t){return Mr(t,Sq,{highlightWordAroundCursor:(e,n)=>e||n,minSelectionLength:Math.min,maxMatches:Math.min})}});function Rq(t){return[Oq,Eq]}const kq=xe.mark({class:"cm-selectionMatch"}),Tq=xe.mark({class:"cm-selectionMatch cm-selectionMatch-main"});function _b(t,e,n,r){return(n==0||t(e.sliceDoc(n-1,n))!=lt.Word)&&(r==e.doc.length||t(e.sliceDoc(r,r+1))!=lt.Word)}function Mq(t,e,n,r){return t(e.sliceDoc(n,n+1))==lt.Word&&t(e.sliceDoc(r-1,r))==lt.Word}const Eq=vt.fromClass(class{constructor(t){this.decorations=this.getDeco(t)}update(t){(t.selectionSet||t.docChanged||t.viewportChanged)&&(this.decorations=this.getDeco(t.view))}getDeco(t){let e=t.state.facet(Aq),{state:n}=t,r=n.selection;if(r.ranges.length>1)return xe.none;let i=r.main,o,s=null;if(i.empty){if(!e.highlightWordAroundCursor)return xe.none;let c=n.wordAt(i.head);if(!c)return xe.none;s=n.charCategorizer(i.head),o=n.sliceDoc(c.from,c.to)}else{let c=i.to-i.from;if(c<e.minSelectionLength||c>200)return xe.none;if(e.wholeWords){if(o=n.sliceDoc(i.from,i.to),s=n.charCategorizer(i.head),!(_b(s,n,i.from,i.to)&&Mq(s,n,i.from,i.to)))return xe.none}else if(o=n.sliceDoc(i.from,i.to),!o)return xe.none}let a=[];for(let c of t.visibleRanges){let h=new Rs(n.doc,o,c.from,c.to);for(;!h.next().done;){let{from:f,to:d}=h.value;if((!s||_b(s,n,f,d))&&(i.empty&&f<=i.from&&d>=i.to?a.push(Tq.range(f,d)):(f>=i.to||d<=i.from)&&a.push(kq.range(f,d)),a.length>e.maxMatches))return xe.none}}return xe.set(a)}},{decorations:t=>t.decorations}),Oq=le.baseTheme({".cm-selectionMatch":{backgroundColor:"#99ff7780"},".cm-searchMatch .cm-selectionMatch":{backgroundColor:"transparent"}}),Dq=({state:t,dispatch:e})=>{let{selection:n}=t,r=Q.create(n.ranges.map(i=>t.wordAt(i.head)||Q.cursor(i.head)),n.mainIndex);return r.eq(n)?!1:(e(t.update({selection:r})),!0)};function Iq(t,e){let{main:n,ranges:r}=t.selection,i=t.wordAt(n.head),o=i&&i.from==n.from&&i.to==n.to;for(let s=!1,a=new Rs(t.doc,e,r[r.length-1].to);;)if(a.next(),a.done){if(s)return null;a=new Rs(t.doc,e,0,Math.max(0,r[r.length-1].from-1)),s=!0}else{if(s&&r.some(c=>c.from==a.value.from))continue;if(o){let c=t.wordAt(a.value.from);if(!c||c.from!=a.value.from||c.to!=a.value.to)continue}return a.value}}const _q=({state:t,dispatch:e})=>{let{ranges:n}=t.selection;if(n.some(o=>o.from===o.to))return Dq({state:t,dispatch:e});let r=t.sliceDoc(n[0].from,n[0].to);if(t.selection.ranges.some(o=>t.sliceDoc(o.from,o.to)!=r))return!1;let i=Iq(t,r);return i?(e(t.update({selection:t.selection.addRange(Q.range(i.from,i.to),!1),effects:le.scrollIntoView(i.to)})),!0):!1},Fs=fe.define({combine(t){return Mr(t,{top:!1,caseSensitive:!1,literal:!1,regexp:!1,wholeWord:!1,createPanel:e=>new qq(e),scrollToMatch:e=>le.scrollIntoView(e)})}});class V4{constructor(e){this.search=e.search,this.caseSensitive=!!e.caseSensitive,this.literal=!!e.literal,this.regexp=!!e.regexp,this.replace=e.replace||"",this.valid=!!this.search&&(!this.regexp||yq(this.search)),this.unquoted=this.unquote(this.search),this.wholeWord=!!e.wholeWord}unquote(e){return this.literal?e:e.replace(/\\([nrt\\])/g,(n,r)=>r=="n"?`
58
- `:r=="r"?"\r":r=="t"?" ":"\\")}eq(e){return this.search==e.search&&this.replace==e.replace&&this.caseSensitive==e.caseSensitive&&this.regexp==e.regexp&&this.wholeWord==e.wholeWord}create(){return this.regexp?new jq(this):new Bq(this)}getCursor(e,n=0,r){let i=e.doc?e:qe.create({doc:e});return r==null&&(r=i.doc.length),this.regexp?Qo(this,i,n,r):Zo(this,i,n,r)}}class H4{constructor(e){this.spec=e}}function Zo(t,e,n,r){return new Rs(e.doc,t.unquoted,n,r,t.caseSensitive?void 0:i=>i.toLowerCase(),t.wholeWord?Lq(e.doc,e.charCategorizer(e.selection.main.head)):void 0)}function Lq(t,e){return(n,r,i,o)=>((o>n||o+i.length<r)&&(o=Math.max(0,n-2),i=t.sliceString(o,Math.min(t.length,r+2))),(e(Hu(i,n-o))!=lt.Word||e(Pu(i,n-o))!=lt.Word)&&(e(Pu(i,r-o))!=lt.Word||e(Hu(i,r-o))!=lt.Word))}class Bq extends H4{constructor(e){super(e)}nextMatch(e,n,r){let i=Zo(this.spec,e,r,e.doc.length).nextOverlapping();if(i.done){let o=Math.min(e.doc.length,n+this.spec.unquoted.length);i=Zo(this.spec,e,0,o).nextOverlapping()}return i.done||i.value.from==n&&i.value.to==r?null:i.value}prevMatchInRange(e,n,r){for(let i=r;;){let o=Math.max(n,i-1e4-this.spec.unquoted.length),s=Zo(this.spec,e,o,i),a=null;for(;!s.nextOverlapping().done;)a=s.value;if(a)return a;if(o==n)return null;i-=1e4}}prevMatch(e,n,r){let i=this.prevMatchInRange(e,0,n);return i||(i=this.prevMatchInRange(e,Math.max(0,r-this.spec.unquoted.length),e.doc.length)),i&&(i.from!=n||i.to!=r)?i:null}getReplacement(e){return this.spec.unquote(this.spec.replace)}matchAll(e,n){let r=Zo(this.spec,e,0,e.doc.length),i=[];for(;!r.next().done;){if(i.length>=n)return null;i.push(r.value)}return i}highlight(e,n,r,i){let o=Zo(this.spec,e,Math.max(0,n-this.spec.unquoted.length),Math.min(r+this.spec.unquoted.length,e.doc.length));for(;!o.next().done;)i(o.value.from,o.value.to)}}function Qo(t,e,n,r){return new j4(e.doc,t.search,{ignoreCase:!t.caseSensitive,test:t.wholeWord?Nq(e.charCategorizer(e.selection.main.head)):void 0},n,r)}function Hu(t,e){return t.slice(Ht(t,e,!1),e)}function Pu(t,e){return t.slice(e,Ht(t,e))}function Nq(t){return(e,n,r)=>!r[0].length||(t(Hu(r.input,r.index))!=lt.Word||t(Pu(r.input,r.index))!=lt.Word)&&(t(Pu(r.input,r.index+r[0].length))!=lt.Word||t(Hu(r.input,r.index+r[0].length))!=lt.Word)}class jq extends H4{nextMatch(e,n,r){let i=Qo(this.spec,e,r,e.doc.length).next();return i.done&&(i=Qo(this.spec,e,0,n).next()),i.done?null:i.value}prevMatchInRange(e,n,r){for(let i=1;;i++){let o=Math.max(n,r-i*1e4),s=Qo(this.spec,e,o,r),a=null;for(;!s.next().done;)a=s.value;if(a&&(o==n||a.from>o+10))return a;if(o==n)return null}}prevMatch(e,n,r){return this.prevMatchInRange(e,0,n)||this.prevMatchInRange(e,r,e.doc.length)}getReplacement(e){return this.spec.unquote(this.spec.replace).replace(/\$([$&]|\d+)/g,(n,r)=>{if(r=="&")return e.match[0];if(r=="$")return"$";for(let i=r.length;i>0;i--){let o=+r.slice(0,i);if(o>0&&o<e.match.length)return e.match[o]+r.slice(i)}return n})}matchAll(e,n){let r=Qo(this.spec,e,0,e.doc.length),i=[];for(;!r.next().done;){if(i.length>=n)return null;i.push(r.value)}return i}highlight(e,n,r,i){let o=Qo(this.spec,e,Math.max(0,n-250),Math.min(r+250,e.doc.length));for(;!o.next().done;)i(o.value.from,o.value.to)}}const Wa=Me.define(),Cm=Me.define(),Ai=Bt.define({create(t){return new Zd(T1(t).create(),null)},update(t,e){for(let n of e.effects)n.is(Wa)?t=new Zd(n.value.create(),t.panel):n.is(Cm)&&(t=new Zd(t.query,n.value?$m:null));return t},provide:t=>Ha.from(t,e=>e.panel)});class Zd{constructor(e,n){this.query=e,this.panel=n}}const Fq=xe.mark({class:"cm-searchMatch"}),Vq=xe.mark({class:"cm-searchMatch cm-searchMatch-selected"}),Hq=vt.fromClass(class{constructor(t){this.view=t,this.decorations=this.highlight(t.state.field(Ai))}update(t){let e=t.state.field(Ai);(e!=t.startState.field(Ai)||t.docChanged||t.selectionSet||t.viewportChanged)&&(this.decorations=this.highlight(e))}highlight({query:t,panel:e}){if(!e||!t.spec.valid)return xe.none;let{view:n}=this,r=new ei;for(let i=0,o=n.visibleRanges,s=o.length;i<s;i++){let{from:a,to:c}=o[i];for(;i<s-1&&c>o[i+1].from-2*250;)c=o[++i].to;t.highlight(n.state,a,c,(h,f)=>{let d=n.state.selection.ranges.some(m=>m.from==h&&m.to==f);r.add(h,f,d?Vq:Fq)})}return r.finish()}},{decorations:t=>t.decorations});function pl(t){return e=>{let n=e.state.field(Ai,!1);return n&&n.query.spec.valid?t(e,n):z4(e)}}const Wu=pl((t,{query:e})=>{let{to:n}=t.state.selection.main,r=e.nextMatch(t.state,n,n);if(!r)return!1;let i=Q.single(r.from,r.to),o=t.state.facet(Fs);return t.dispatch({selection:i,effects:[Sm(t,r),o.scrollToMatch(i.main,t)],userEvent:"select.search"}),W4(t),!0}),zu=pl((t,{query:e})=>{let{state:n}=t,{from:r}=n.selection.main,i=e.prevMatch(n,r,r);if(!i)return!1;let o=Q.single(i.from,i.to),s=t.state.facet(Fs);return t.dispatch({selection:o,effects:[Sm(t,i),s.scrollToMatch(o.main,t)],userEvent:"select.search"}),W4(t),!0}),Pq=pl((t,{query:e})=>{let n=e.matchAll(t.state,1e3);return!n||!n.length?!1:(t.dispatch({selection:Q.create(n.map(r=>Q.range(r.from,r.to))),userEvent:"select.search.matches"}),!0)}),Wq=({state:t,dispatch:e})=>{let n=t.selection;if(n.ranges.length>1||n.main.empty)return!1;let{from:r,to:i}=n.main,o=[],s=0;for(let a=new Rs(t.doc,t.sliceDoc(r,i));!a.next().done;){if(o.length>1e3)return!1;a.value.from==r&&(s=o.length),o.push(Q.range(a.value.from,a.value.to))}return e(t.update({selection:Q.create(o,s),userEvent:"select.search.matches"})),!0},Lb=pl((t,{query:e})=>{let{state:n}=t,{from:r,to:i}=n.selection.main;if(n.readOnly)return!1;let o=e.nextMatch(n,r,r);if(!o)return!1;let s=o,a=[],c,h,f=[];if(s.from==r&&s.to==i&&(h=n.toText(e.getReplacement(s)),a.push({from:s.from,to:s.to,insert:h}),s=e.nextMatch(n,s.from,s.to),f.push(le.announce.of(n.phrase("replaced match on line $",n.doc.lineAt(r).number)+"."))),s){let d=a.length==0||a[0].from>=o.to?0:o.to-o.from-h.length;c=Q.single(s.from-d,s.to-d),f.push(Sm(t,s)),f.push(n.facet(Fs).scrollToMatch(c.main,t))}return t.dispatch({changes:a,selection:c,effects:f,userEvent:"input.replace"}),!0}),zq=pl((t,{query:e})=>{if(t.state.readOnly)return!1;let n=e.matchAll(t.state,1e9).map(i=>{let{from:o,to:s}=i;return{from:o,to:s,insert:e.getReplacement(i)}});if(!n.length)return!1;let r=t.state.phrase("replaced $ matches",n.length)+".";return t.dispatch({changes:n,effects:le.announce.of(r),userEvent:"input.replace.all"}),!0});function $m(t){return t.state.facet(Fs).createPanel(t)}function T1(t,e){var n,r,i,o,s;let a=t.selection.main,c=a.empty||a.to>a.from+100?"":t.sliceDoc(a.from,a.to);if(e&&!c)return e;let h=t.facet(Fs);return new V4({search:((n=e?.literal)!==null&&n!==void 0?n:h.literal)?c:c.replace(/\n/g,"\\n"),caseSensitive:(r=e?.caseSensitive)!==null&&r!==void 0?r:h.caseSensitive,literal:(i=e?.literal)!==null&&i!==void 0?i:h.literal,regexp:(o=e?.regexp)!==null&&o!==void 0?o:h.regexp,wholeWord:(s=e?.wholeWord)!==null&&s!==void 0?s:h.wholeWord})}function P4(t){let e=Va(t,$m);return e&&e.dom.querySelector("[main-field]")}function W4(t){let e=P4(t);e&&e==t.root.activeElement&&e.select()}const z4=t=>{let e=t.state.field(Ai,!1);if(e&&e.panel){let n=P4(t);if(n&&n!=t.root.activeElement){let r=T1(t.state,e.query.spec);r.valid&&t.dispatch({effects:Wa.of(r)}),n.focus(),n.select()}}else t.dispatch({effects:[Cm.of(!0),e?Wa.of(T1(t.state,e.query.spec)):Me.appendConfig.of(Gq)]});return!0},U4=t=>{let e=t.state.field(Ai,!1);if(!e||!e.panel)return!1;let n=Va(t,$m);return n&&n.dom.contains(t.root.activeElement)&&t.focus(),t.dispatch({effects:Cm.of(!1)}),!0},Uq=[{key:"Mod-f",run:z4,scope:"editor search-panel"},{key:"F3",run:Wu,shift:zu,scope:"editor search-panel",preventDefault:!0},{key:"Mod-g",run:Wu,shift:zu,scope:"editor search-panel",preventDefault:!0},{key:"Escape",run:U4,scope:"editor search-panel"},{key:"Mod-Shift-l",run:Wq},{key:"Mod-Alt-g",run:Cq},{key:"Mod-d",run:_q,preventDefault:!0}];class qq{constructor(e){this.view=e;let n=this.query=e.state.field(Ai).query.spec;this.commit=this.commit.bind(this),this.searchField=et("input",{value:n.search,placeholder:$n(e,"Find"),"aria-label":$n(e,"Find"),class:"cm-textfield",name:"search",form:"","main-field":"true",onchange:this.commit,onkeyup:this.commit}),this.replaceField=et("input",{value:n.replace,placeholder:$n(e,"Replace"),"aria-label":$n(e,"Replace"),class:"cm-textfield",name:"replace",form:"",onchange:this.commit,onkeyup:this.commit}),this.caseField=et("input",{type:"checkbox",name:"case",form:"",checked:n.caseSensitive,onchange:this.commit}),this.reField=et("input",{type:"checkbox",name:"re",form:"",checked:n.regexp,onchange:this.commit}),this.wordField=et("input",{type:"checkbox",name:"word",form:"",checked:n.wholeWord,onchange:this.commit});function r(i,o,s){return et("button",{class:"cm-button",name:i,onclick:o,type:"button"},s)}this.dom=et("div",{onkeydown:i=>this.keydown(i),class:"cm-search"},[this.searchField,r("next",()=>Wu(e),[$n(e,"next")]),r("prev",()=>zu(e),[$n(e,"previous")]),r("select",()=>Pq(e),[$n(e,"all")]),et("label",null,[this.caseField,$n(e,"match case")]),et("label",null,[this.reField,$n(e,"regexp")]),et("label",null,[this.wordField,$n(e,"by word")]),...e.state.readOnly?[]:[et("br"),this.replaceField,r("replace",()=>Lb(e),[$n(e,"replace")]),r("replaceAll",()=>zq(e),[$n(e,"replace all")])],et("button",{name:"close",onclick:()=>U4(e),"aria-label":$n(e,"close"),type:"button"},["×"])])}commit(){let e=new V4({search:this.searchField.value,caseSensitive:this.caseField.checked,regexp:this.reField.checked,wholeWord:this.wordField.checked,replace:this.replaceField.value});e.eq(this.query)||(this.query=e,this.view.dispatch({effects:Wa.of(e)}))}keydown(e){uW(this.view,e,"search-panel")?e.preventDefault():e.keyCode==13&&e.target==this.searchField?(e.preventDefault(),(e.shiftKey?zu:Wu)(this.view)):e.keyCode==13&&e.target==this.replaceField&&(e.preventDefault(),Lb(this.view))}update(e){for(let n of e.transactions)for(let r of n.effects)r.is(Wa)&&!r.value.eq(this.query)&&this.setQuery(r.value)}setQuery(e){this.query=e,this.searchField.value=e.search,this.replaceField.value=e.replace,this.caseField.checked=e.caseSensitive,this.reField.checked=e.regexp,this.wordField.checked=e.wholeWord}mount(){this.searchField.select()}get pos(){return 80}get top(){return this.view.state.facet(Fs).top}}function $n(t,e){return t.state.phrase(e)}const Wc=30,zc=/[\s\.,:;?!]/;function Sm(t,{from:e,to:n}){let r=t.state.doc.lineAt(e),i=t.state.doc.lineAt(n).to,o=Math.max(r.from,e-Wc),s=Math.min(i,n+Wc),a=t.state.sliceDoc(o,s);if(o!=r.from){for(let c=0;c<Wc;c++)if(!zc.test(a[c+1])&&zc.test(a[c])){a=a.slice(c);break}}if(s!=i){for(let c=a.length-1;c>a.length-Wc;c--)if(!zc.test(a[c-1])&&zc.test(a[c])){a=a.slice(0,c);break}}return le.announce.of(`${t.state.phrase("current match")}. ${a} ${t.state.phrase("on line")} ${r.number}.`)}const Kq=le.baseTheme({".cm-panel.cm-search":{padding:"2px 6px 4px",position:"relative","& [name=close]":{position:"absolute",top:"0",right:"4px",backgroundColor:"inherit",border:"none",font:"inherit",padding:0,margin:0},"& input, & button, & label":{margin:".2em .6em .2em 0"},"& input[type=checkbox]":{marginRight:".2em"},"& label":{fontSize:"80%",whiteSpace:"pre"}},"&light .cm-searchMatch":{backgroundColor:"#ffff0054"},"&dark .cm-searchMatch":{backgroundColor:"#00ffff8a"},"&light .cm-searchMatch-selected":{backgroundColor:"#ff6a0054"},"&dark .cm-searchMatch-selected":{backgroundColor:"#ff00ff8a"}}),Gq=[Ai,Ro.low(Hq),Kq];class q4{constructor(e,n,r,i){this.state=e,this.pos=n,this.explicit=r,this.view=i,this.abortListeners=[],this.abortOnDocChange=!1}tokenBefore(e){let n=Kt(this.state).resolveInner(this.pos,-1);for(;n&&e.indexOf(n.name)<0;)n=n.parent;return n?{from:n.from,to:this.pos,text:this.state.sliceDoc(n.from,this.pos),type:n.type}:null}matchBefore(e){let n=this.state.doc.lineAt(this.pos),r=Math.max(n.from,this.pos-250),i=n.text.slice(r-n.from,this.pos-n.from),o=i.search(K4(e,!1));return o<0?null:{from:r+o,to:this.pos,text:i.slice(o)}}get aborted(){return this.abortListeners==null}addEventListener(e,n,r){e=="abort"&&this.abortListeners&&(this.abortListeners.push(n),r&&r.onDocChange&&(this.abortOnDocChange=!0))}}function Bb(t){let e=Object.keys(t).join(""),n=/\w/.test(e);return n&&(e=e.replace(/\w/g,"")),`[${n?"\\w":""}${e.replace(/[^\w\s]/g,"\\$&")}]`}function Yq(t){let e=Object.create(null),n=Object.create(null);for(let{label:i}of t){e[i[0]]=!0;for(let o=1;o<i.length;o++)n[i[o]]=!0}let r=Bb(e)+Bb(n)+"*$";return[new RegExp("^"+r),new RegExp(r)]}function Xq(t){let e=t.map(i=>typeof i=="string"?{label:i}:i),[n,r]=e.every(i=>/^\w+$/.test(i.label))?[/\w*$/,/\w+$/]:Yq(e);return i=>{let o=i.matchBefore(r);return o||i.explicit?{from:o?o.from:i.pos,options:e,validFor:n}:null}}let Nb=class{constructor(e,n,r,i){this.completion=e,this.source=n,this.match=r,this.score=i}};function lo(t){return t.selection.main.from}function K4(t,e){var n;let{source:r}=t,i=e&&r[0]!="^",o=r[r.length-1]!="$";return!i&&!o?t:new RegExp(`${i?"^":""}(?:${r})${o?"$":""}`,(n=t.flags)!==null&&n!==void 0?n:t.ignoreCase?"i":"")}const G4=Tr.define();function Zq(t,e,n,r){let{main:i}=t.selection,o=n-i.from,s=r-i.from;return Object.assign(Object.assign({},t.changeByRange(a=>{if(a!=i&&n!=r&&t.sliceDoc(a.from+o,a.from+s)!=t.sliceDoc(n,r))return{range:a};let c=t.toText(e);return{changes:{from:a.from+o,to:r==i.from?a.to:a.from+s,insert:c},range:Q.cursor(a.from+o+c.length)}})),{scrollIntoView:!0,userEvent:"input.complete"})}const jb=new WeakMap;function Qq(t){if(!Array.isArray(t))return t;let e=jb.get(t);return e||jb.set(t,e=Xq(t)),e}const Uu=Me.define(),za=Me.define();class Jq{constructor(e){this.pattern=e,this.chars=[],this.folded=[],this.any=[],this.precise=[],this.byWord=[],this.score=0,this.matched=[];for(let n=0;n<e.length;){let r=ln(e,n),i=mr(r);this.chars.push(r);let o=e.slice(n,n+i),s=o.toUpperCase();this.folded.push(ln(s==o?o.toLowerCase():s,0)),n+=i}this.astral=e.length!=this.chars.length}ret(e,n){return this.score=e,this.matched=n,this}match(e){if(this.pattern.length==0)return this.ret(-100,[]);if(e.length<this.pattern.length)return null;let{chars:n,folded:r,any:i,precise:o,byWord:s}=this;if(n.length==1){let A=ln(e,0),T=mr(A),O=T==e.length?0:-100;if(A!=n[0])if(A==r[0])O+=-200;else return null;return this.ret(O,[0,T])}let a=e.indexOf(this.pattern);if(a==0)return this.ret(e.length==this.pattern.length?0:-100,[0,this.pattern.length]);let c=n.length,h=0;if(a<0){for(let A=0,T=Math.min(e.length,200);A<T&&h<c;){let O=ln(e,A);(O==n[h]||O==r[h])&&(i[h++]=A),A+=mr(O)}if(h<c)return null}let f=0,d=0,m=!1,v=0,w=-1,x=-1,C=/[a-z]/.test(e),S=!0;for(let A=0,T=Math.min(e.length,200),O=0;A<T&&d<c;){let D=ln(e,A);a<0&&(f<c&&D==n[f]&&(o[f++]=A),v<c&&(D==n[v]||D==r[v]?(v==0&&(w=A),x=A+1,v++):v=0));let L,I=D<255?D>=48&&D<=57||D>=97&&D<=122?2:D>=65&&D<=90?1:0:(L=em(D))!=L.toLowerCase()?1:L!=L.toUpperCase()?2:0;(!A||I==1&&C||O==0&&I!=0)&&(n[d]==D||r[d]==D&&(m=!0)?s[d++]=A:s.length&&(S=!1)),O=I,A+=mr(D)}return d==c&&s[0]==0&&S?this.result(-100+(m?-200:0),s,e):v==c&&w==0?this.ret(-200-e.length+(x==e.length?0:-100),[0,x]):a>-1?this.ret(-700-e.length,[a,a+this.pattern.length]):v==c?this.ret(-900-e.length,[w,x]):d==c?this.result(-100+(m?-200:0)+-700+(S?0:-1100),s,e):n.length==2?null:this.result((i[0]?-700:0)+-200+-1100,i,e)}result(e,n,r){let i=[],o=0;for(let s of n){let a=s+(this.astral?mr(ln(r,s)):1);o&&i[o-1]==s?i[o-1]=a:(i[o++]=s,i[o++]=a)}return this.ret(e-r.length,i)}}class eK{constructor(e){this.pattern=e,this.matched=[],this.score=0,this.folded=e.toLowerCase()}match(e){if(e.length<this.pattern.length)return null;let n=e.slice(0,this.pattern.length),r=n==this.pattern?0:n.toLowerCase()==this.folded?-200:null;return r==null?null:(this.matched=[0,n.length],this.score=r+(e.length==this.pattern.length?0:-100),this)}}const It=fe.define({combine(t){return Mr(t,{activateOnTyping:!0,activateOnCompletion:()=>!1,activateOnTypingDelay:100,selectOnOpen:!0,override:null,closeOnBlur:!0,maxRenderedOptions:100,defaultKeymap:!0,tooltipClass:()=>"",optionClass:()=>"",aboveCursor:!1,icons:!0,addToOptions:[],positionInfo:tK,filterStrict:!1,compareCompletions:(e,n)=>e.label.localeCompare(n.label),interactionDelay:75,updateSyncTime:100},{defaultKeymap:(e,n)=>e&&n,closeOnBlur:(e,n)=>e&&n,icons:(e,n)=>e&&n,tooltipClass:(e,n)=>r=>Fb(e(r),n(r)),optionClass:(e,n)=>r=>Fb(e(r),n(r)),addToOptions:(e,n)=>e.concat(n),filterStrict:(e,n)=>e||n})}});function Fb(t,e){return t?e?t+" "+e:t:e}function tK(t,e,n,r,i,o){let s=t.textDirection==st.RTL,a=s,c=!1,h="top",f,d,m=e.left-i.left,v=i.right-e.right,w=r.right-r.left,x=r.bottom-r.top;if(a&&m<Math.min(w,v)?a=!1:!a&&v<Math.min(w,m)&&(a=!0),w<=(a?m:v))f=Math.max(i.top,Math.min(n.top,i.bottom-x))-e.top,d=Math.min(400,a?m:v);else{c=!0,d=Math.min(400,(s?e.right:i.right-e.left)-30);let A=i.bottom-e.bottom;A>=x||A>e.top?f=n.bottom-e.top:(h="bottom",f=e.bottom-n.top)}let C=(e.bottom-e.top)/o.offsetHeight,S=(e.right-e.left)/o.offsetWidth;return{style:`${h}: ${f/C}px; max-width: ${d/S}px`,class:"cm-completionInfo-"+(c?s?"left-narrow":"right-narrow":a?"left":"right")}}function nK(t){let e=t.addToOptions.slice();return t.icons&&e.push({render(n){let r=document.createElement("div");return r.classList.add("cm-completionIcon"),n.type&&r.classList.add(...n.type.split(/\s+/g).map(i=>"cm-completionIcon-"+i)),r.setAttribute("aria-hidden","true"),r},position:20}),e.push({render(n,r,i,o){let s=document.createElement("span");s.className="cm-completionLabel";let a=n.displayLabel||n.label,c=0;for(let h=0;h<o.length;){let f=o[h++],d=o[h++];f>c&&s.appendChild(document.createTextNode(a.slice(c,f)));let m=s.appendChild(document.createElement("span"));m.appendChild(document.createTextNode(a.slice(f,d))),m.className="cm-completionMatchedText",c=d}return c<a.length&&s.appendChild(document.createTextNode(a.slice(c))),s},position:50},{render(n){if(!n.detail)return null;let r=document.createElement("span");return r.className="cm-completionDetail",r.textContent=n.detail,r},position:80}),e.sort((n,r)=>n.position-r.position).map(n=>n.render)}function Qd(t,e,n){if(t<=n)return{from:0,to:t};if(e<0&&(e=0),e<=t>>1){let i=Math.floor(e/n);return{from:i*n,to:(i+1)*n}}let r=Math.floor((t-e)/n);return{from:t-(r+1)*n,to:t-r*n}}class rK{constructor(e,n,r){this.view=e,this.stateField=n,this.applyCompletion=r,this.info=null,this.infoDestroy=null,this.placeInfoReq={read:()=>this.measureInfo(),write:c=>this.placeInfo(c),key:this},this.space=null,this.currentClass="";let i=e.state.field(n),{options:o,selected:s}=i.open,a=e.state.facet(It);this.optionContent=nK(a),this.optionClass=a.optionClass,this.tooltipClass=a.tooltipClass,this.range=Qd(o.length,s,a.maxRenderedOptions),this.dom=document.createElement("div"),this.dom.className="cm-tooltip-autocomplete",this.updateTooltipClass(e.state),this.dom.addEventListener("mousedown",c=>{let{options:h}=e.state.field(n).open;for(let f=c.target,d;f&&f!=this.dom;f=f.parentNode)if(f.nodeName=="LI"&&(d=/-(\d+)$/.exec(f.id))&&+d[1]<h.length){this.applyCompletion(e,h[+d[1]]),c.preventDefault();return}}),this.dom.addEventListener("focusout",c=>{let h=e.state.field(this.stateField,!1);h&&h.tooltip&&e.state.facet(It).closeOnBlur&&c.relatedTarget!=e.contentDOM&&e.dispatch({effects:za.of(null)})}),this.showOptions(o,i.id)}mount(){this.updateSel()}showOptions(e,n){this.list&&this.list.remove(),this.list=this.dom.appendChild(this.createListBox(e,n,this.range)),this.list.addEventListener("scroll",()=>{this.info&&this.view.requestMeasure(this.placeInfoReq)})}update(e){var n;let r=e.state.field(this.stateField),i=e.startState.field(this.stateField);if(this.updateTooltipClass(e.state),r!=i){let{options:o,selected:s,disabled:a}=r.open;(!i.open||i.open.options!=o)&&(this.range=Qd(o.length,s,e.state.facet(It).maxRenderedOptions),this.showOptions(o,r.id)),this.updateSel(),a!=((n=i.open)===null||n===void 0?void 0:n.disabled)&&this.dom.classList.toggle("cm-tooltip-autocomplete-disabled",!!a)}}updateTooltipClass(e){let n=this.tooltipClass(e);if(n!=this.currentClass){for(let r of this.currentClass.split(" "))r&&this.dom.classList.remove(r);for(let r of n.split(" "))r&&this.dom.classList.add(r);this.currentClass=n}}positioned(e){this.space=e,this.info&&this.view.requestMeasure(this.placeInfoReq)}updateSel(){let e=this.view.state.field(this.stateField),n=e.open;if((n.selected>-1&&n.selected<this.range.from||n.selected>=this.range.to)&&(this.range=Qd(n.options.length,n.selected,this.view.state.facet(It).maxRenderedOptions),this.showOptions(n.options,e.id)),this.updateSelectedOption(n.selected)){this.destroyInfo();let{completion:r}=n.options[n.selected],{info:i}=r;if(!i)return;let o=typeof i=="string"?document.createTextNode(i):i(r);if(!o)return;"then"in o?o.then(s=>{s&&this.view.state.field(this.stateField,!1)==e&&this.addInfoPane(s,r)}).catch(s=>hn(this.view.state,s,"completion info")):this.addInfoPane(o,r)}}addInfoPane(e,n){this.destroyInfo();let r=this.info=document.createElement("div");if(r.className="cm-tooltip cm-completionInfo",e.nodeType!=null)r.appendChild(e),this.infoDestroy=null;else{let{dom:i,destroy:o}=e;r.appendChild(i),this.infoDestroy=o||null}this.dom.appendChild(r),this.view.requestMeasure(this.placeInfoReq)}updateSelectedOption(e){let n=null;for(let r=this.list.firstChild,i=this.range.from;r;r=r.nextSibling,i++)r.nodeName!="LI"||!r.id?i--:i==e?r.hasAttribute("aria-selected")||(r.setAttribute("aria-selected","true"),n=r):r.hasAttribute("aria-selected")&&r.removeAttribute("aria-selected");return n&&oK(this.list,n),n}measureInfo(){let e=this.dom.querySelector("[aria-selected]");if(!e||!this.info)return null;let n=this.dom.getBoundingClientRect(),r=this.info.getBoundingClientRect(),i=e.getBoundingClientRect(),o=this.space;if(!o){let s=this.dom.ownerDocument.documentElement;o={left:0,top:0,right:s.clientWidth,bottom:s.clientHeight}}return i.top>Math.min(o.bottom,n.bottom)-10||i.bottom<Math.max(o.top,n.top)+10?null:this.view.state.facet(It).positionInfo(this.view,n,i,r,o,this.dom)}placeInfo(e){this.info&&(e?(e.style&&(this.info.style.cssText=e.style),this.info.className="cm-tooltip cm-completionInfo "+(e.class||"")):this.info.style.cssText="top: -1e6px")}createListBox(e,n,r){const i=document.createElement("ul");i.id=n,i.setAttribute("role","listbox"),i.setAttribute("aria-expanded","true"),i.setAttribute("aria-label",this.view.state.phrase("Completions")),i.addEventListener("mousedown",s=>{s.target==i&&s.preventDefault()});let o=null;for(let s=r.from;s<r.to;s++){let{completion:a,match:c}=e[s],{section:h}=a;if(h){let m=typeof h=="string"?h:h.name;if(m!=o&&(s>r.from||r.from==0))if(o=m,typeof h!="string"&&h.header)i.appendChild(h.header(h));else{let v=i.appendChild(document.createElement("completion-section"));v.textContent=m}}const f=i.appendChild(document.createElement("li"));f.id=n+"-"+s,f.setAttribute("role","option");let d=this.optionClass(a);d&&(f.className=d);for(let m of this.optionContent){let v=m(a,this.view.state,this.view,c);v&&f.appendChild(v)}}return r.from&&i.classList.add("cm-completionListIncompleteTop"),r.to<e.length&&i.classList.add("cm-completionListIncompleteBottom"),i}destroyInfo(){this.info&&(this.infoDestroy&&this.infoDestroy(),this.info.remove(),this.info=null)}destroy(){this.destroyInfo()}}function iK(t,e){return n=>new rK(n,t,e)}function oK(t,e){let n=t.getBoundingClientRect(),r=e.getBoundingClientRect(),i=n.height/t.offsetHeight;r.top<n.top?t.scrollTop-=(n.top-r.top)/i:r.bottom>n.bottom&&(t.scrollTop+=(r.bottom-n.bottom)/i)}function Vb(t){return(t.boost||0)*100+(t.apply?10:0)+(t.info?5:0)+(t.type?1:0)}function sK(t,e){let n=[],r=null,i=h=>{n.push(h);let{section:f}=h.completion;if(f){r||(r=[]);let d=typeof f=="string"?f:f.name;r.some(m=>m.name==d)||r.push(typeof f=="string"?{name:d}:f)}},o=e.facet(It);for(let h of t)if(h.hasResult()){let f=h.result.getMatch;if(h.result.filter===!1)for(let d of h.result.options)i(new Nb(d,h.source,f?f(d):[],1e9-n.length));else{let d=e.sliceDoc(h.from,h.to),m,v=o.filterStrict?new eK(d):new Jq(d);for(let w of h.result.options)if(m=v.match(w.label)){let x=w.displayLabel?f?f(w,m.matched):[]:m.matched;i(new Nb(w,h.source,x,m.score+(w.boost||0)))}}}if(r){let h=Object.create(null),f=0,d=(m,v)=>{var w,x;return((w=m.rank)!==null&&w!==void 0?w:1e9)-((x=v.rank)!==null&&x!==void 0?x:1e9)||(m.name<v.name?-1:1)};for(let m of r.sort(d))f-=1e5,h[m.name]=f;for(let m of n){let{section:v}=m.completion;v&&(m.score+=h[typeof v=="string"?v:v.name])}}let s=[],a=null,c=o.compareCompletions;for(let h of n.sort((f,d)=>d.score-f.score||c(f.completion,d.completion))){let f=h.completion;!a||a.label!=f.label||a.detail!=f.detail||a.type!=null&&f.type!=null&&a.type!=f.type||a.apply!=f.apply||a.boost!=f.boost?s.push(h):Vb(h.completion)>Vb(a)&&(s[s.length-1]=h),a=h.completion}return s}class ns{constructor(e,n,r,i,o,s){this.options=e,this.attrs=n,this.tooltip=r,this.timestamp=i,this.selected=o,this.disabled=s}setSelected(e,n){return e==this.selected||e>=this.options.length?this:new ns(this.options,Hb(n,e),this.tooltip,this.timestamp,e,this.disabled)}static build(e,n,r,i,o,s){if(i&&!s&&e.some(h=>h.isPending))return i.setDisabled();let a=sK(e,n);if(!a.length)return i&&e.some(h=>h.isPending)?i.setDisabled():null;let c=n.facet(It).selectOnOpen?0:-1;if(i&&i.selected!=c&&i.selected!=-1){let h=i.options[i.selected].completion;for(let f=0;f<a.length;f++)if(a[f].completion==h){c=f;break}}return new ns(a,Hb(r,c),{pos:e.reduce((h,f)=>f.hasResult()?Math.min(h,f.from):h,1e8),create:fK,above:o.aboveCursor},i?i.timestamp:Date.now(),c,!1)}map(e){return new ns(this.options,this.attrs,Object.assign(Object.assign({},this.tooltip),{pos:e.mapPos(this.tooltip.pos)}),this.timestamp,this.selected,this.disabled)}setDisabled(){return new ns(this.options,this.attrs,this.tooltip,this.timestamp,this.selected,!0)}}class qu{constructor(e,n,r){this.active=e,this.id=n,this.open=r}static start(){return new qu(uK,"cm-ac-"+Math.floor(Math.random()*2e6).toString(36),null)}update(e){let{state:n}=e,r=n.facet(It),o=(r.override||n.languageDataAt("autocomplete",lo(n)).map(Qq)).map(c=>(this.active.find(f=>f.source==c)||new jn(c,this.active.some(f=>f.state!=0)?1:0)).update(e,r));o.length==this.active.length&&o.every((c,h)=>c==this.active[h])&&(o=this.active);let s=this.open,a=e.effects.some(c=>c.is(Am));s&&e.docChanged&&(s=s.map(e.changes)),e.selection||o.some(c=>c.hasResult()&&e.changes.touchesRange(c.from,c.to))||!aK(o,this.active)||a?s=ns.build(o,n,this.id,s,r,a):s&&s.disabled&&!o.some(c=>c.isPending)&&(s=null),!s&&o.every(c=>!c.isPending)&&o.some(c=>c.hasResult())&&(o=o.map(c=>c.hasResult()?new jn(c.source,0):c));for(let c of e.effects)c.is(X4)&&(s=s&&s.setSelected(c.value,this.id));return o==this.active&&s==this.open?this:new qu(o,this.id,s)}get tooltip(){return this.open?this.open.tooltip:null}get attrs(){return this.open?this.open.attrs:this.active.length?lK:cK}}function aK(t,e){if(t==e)return!0;for(let n=0,r=0;;){for(;n<t.length&&!t[n].hasResult();)n++;for(;r<e.length&&!e[r].hasResult();)r++;let i=n==t.length,o=r==e.length;if(i||o)return i==o;if(t[n++].result!=e[r++].result)return!1}}const lK={"aria-autocomplete":"list"},cK={};function Hb(t,e){let n={"aria-autocomplete":"list","aria-haspopup":"listbox","aria-controls":t};return e>-1&&(n["aria-activedescendant"]=t+"-"+e),n}const uK=[];function Y4(t,e){if(t.isUserEvent("input.complete")){let r=t.annotation(G4);if(r&&e.activateOnCompletion(r))return 12}let n=t.isUserEvent("input.type");return n&&e.activateOnTyping?5:n?1:t.isUserEvent("delete.backward")?2:t.selection?8:t.docChanged?16:0}class jn{constructor(e,n,r=!1){this.source=e,this.state=n,this.explicit=r}hasResult(){return!1}get isPending(){return this.state==1}update(e,n){let r=Y4(e,n),i=this;(r&8||r&16&&this.touches(e))&&(i=new jn(i.source,0)),r&4&&i.state==0&&(i=new jn(this.source,1)),i=i.updateFor(e,r);for(let o of e.effects)if(o.is(Uu))i=new jn(i.source,1,o.value);else if(o.is(za))i=new jn(i.source,0);else if(o.is(Am))for(let s of o.value)s.source==i.source&&(i=s);return i}updateFor(e,n){return this.map(e.changes)}map(e){return this}touches(e){return e.changes.touchesRange(lo(e.state))}}class fs extends jn{constructor(e,n,r,i,o,s){super(e,3,n),this.limit=r,this.result=i,this.from=o,this.to=s}hasResult(){return!0}updateFor(e,n){var r;if(!(n&3))return this.map(e.changes);let i=this.result;i.map&&!e.changes.empty&&(i=i.map(i,e.changes));let o=e.changes.mapPos(this.from),s=e.changes.mapPos(this.to,1),a=lo(e.state);if(a>s||!i||n&2&&(lo(e.startState)==this.from||a<this.limit))return new jn(this.source,n&4?1:0);let c=e.changes.mapPos(this.limit);return hK(i.validFor,e.state,o,s)?new fs(this.source,this.explicit,c,i,o,s):i.update&&(i=i.update(i,o,s,new q4(e.state,a,!1)))?new fs(this.source,this.explicit,c,i,i.from,(r=i.to)!==null&&r!==void 0?r:lo(e.state)):new jn(this.source,1,this.explicit)}map(e){return e.empty?this:(this.result.map?this.result.map(this.result,e):this.result)?new fs(this.source,this.explicit,e.mapPos(this.limit),this.result,e.mapPos(this.from),e.mapPos(this.to,1)):new jn(this.source,0)}touches(e){return e.changes.touchesRange(this.from,this.to)}}function hK(t,e,n,r){if(!t)return!1;let i=e.sliceDoc(n,r);return typeof t=="function"?t(i,n,r,e):K4(t,!0).test(i)}const Am=Me.define({map(t,e){return t.map(n=>n.map(e))}}),X4=Me.define(),un=Bt.define({create(){return qu.start()},update(t,e){return t.update(e)},provide:t=>[mm.from(t,e=>e.tooltip),le.contentAttributes.from(t,e=>e.attrs)]});function Rm(t,e){const n=e.completion.apply||e.completion.label;let r=t.state.field(un).active.find(i=>i.source==e.source);return r instanceof fs?(typeof n=="string"?t.dispatch(Object.assign(Object.assign({},Zq(t.state,n,r.from,r.to)),{annotations:G4.of(e.completion)})):n(t,e.completion,r.from,r.to),!0):!1}const fK=iK(un,Rm);function Uc(t,e="option"){return n=>{let r=n.state.field(un,!1);if(!r||!r.open||r.open.disabled||Date.now()-r.open.timestamp<n.state.facet(It).interactionDelay)return!1;let i=1,o;e=="page"&&(o=j6(n,r.open.tooltip))&&(i=Math.max(2,Math.floor(o.dom.offsetHeight/o.dom.querySelector("li").offsetHeight)-1));let{length:s}=r.open.options,a=r.open.selected>-1?r.open.selected+i*(t?1:-1):t?0:s-1;return a<0?a=e=="page"?0:s-1:a>=s&&(a=e=="page"?s-1:0),n.dispatch({effects:X4.of(a)}),!0}}const dK=t=>{let e=t.state.field(un,!1);return t.state.readOnly||!e||!e.open||e.open.selected<0||e.open.disabled||Date.now()-e.open.timestamp<t.state.facet(It).interactionDelay?!1:Rm(t,e.open.options[e.open.selected])},Pb=t=>t.state.field(un,!1)?(t.dispatch({effects:Uu.of(!0)}),!0):!1,gK=t=>{let e=t.state.field(un,!1);return!e||!e.active.some(n=>n.state!=0)?!1:(t.dispatch({effects:za.of(null)}),!0)};class mK{constructor(e,n){this.active=e,this.context=n,this.time=Date.now(),this.updates=[],this.done=void 0}}const pK=50,vK=1e3,bK=vt.fromClass(class{constructor(t){this.view=t,this.debounceUpdate=-1,this.running=[],this.debounceAccept=-1,this.pendingStart=!1,this.composing=0;for(let e of t.state.field(un).active)e.isPending&&this.startQuery(e)}update(t){let e=t.state.field(un),n=t.state.facet(It);if(!t.selectionSet&&!t.docChanged&&t.startState.field(un)==e)return;let r=t.transactions.some(o=>{let s=Y4(o,n);return s&8||(o.selection||o.docChanged)&&!(s&3)});for(let o=0;o<this.running.length;o++){let s=this.running[o];if(r||s.context.abortOnDocChange&&t.docChanged||s.updates.length+t.transactions.length>pK&&Date.now()-s.time>vK){for(let a of s.context.abortListeners)try{a()}catch(c){hn(this.view.state,c)}s.context.abortListeners=null,this.running.splice(o--,1)}else s.updates.push(...t.transactions)}this.debounceUpdate>-1&&clearTimeout(this.debounceUpdate),t.transactions.some(o=>o.effects.some(s=>s.is(Uu)))&&(this.pendingStart=!0);let i=this.pendingStart?50:n.activateOnTypingDelay;if(this.debounceUpdate=e.active.some(o=>o.isPending&&!this.running.some(s=>s.active.source==o.source))?setTimeout(()=>this.startUpdate(),i):-1,this.composing!=0)for(let o of t.transactions)o.isUserEvent("input.type")?this.composing=2:this.composing==2&&o.selection&&(this.composing=3)}startUpdate(){this.debounceUpdate=-1,this.pendingStart=!1;let{state:t}=this.view,e=t.field(un);for(let n of e.active)n.isPending&&!this.running.some(r=>r.active.source==n.source)&&this.startQuery(n);this.running.length&&e.open&&e.open.disabled&&(this.debounceAccept=setTimeout(()=>this.accept(),this.view.state.facet(It).updateSyncTime))}startQuery(t){let{state:e}=this.view,n=lo(e),r=new q4(e,n,t.explicit,this.view),i=new mK(t,r);this.running.push(i),Promise.resolve(t.source(r)).then(o=>{i.context.aborted||(i.done=o||null,this.scheduleAccept())},o=>{this.view.dispatch({effects:za.of(null)}),hn(this.view.state,o)})}scheduleAccept(){this.running.every(t=>t.done!==void 0)?this.accept():this.debounceAccept<0&&(this.debounceAccept=setTimeout(()=>this.accept(),this.view.state.facet(It).updateSyncTime))}accept(){var t;this.debounceAccept>-1&&clearTimeout(this.debounceAccept),this.debounceAccept=-1;let e=[],n=this.view.state.facet(It),r=this.view.state.field(un);for(let i=0;i<this.running.length;i++){let o=this.running[i];if(o.done===void 0)continue;if(this.running.splice(i--,1),o.done){let a=lo(o.updates.length?o.updates[0].startState:this.view.state),c=Math.min(a,o.done.from+(o.active.explicit?0:1)),h=new fs(o.active.source,o.active.explicit,c,o.done,o.done.from,(t=o.done.to)!==null&&t!==void 0?t:a);for(let f of o.updates)h=h.update(f,n);if(h.hasResult()){e.push(h);continue}}let s=r.active.find(a=>a.source==o.active.source);if(s&&s.isPending)if(o.done==null){let a=new jn(o.active.source,0);for(let c of o.updates)a=a.update(c,n);a.isPending||e.push(a)}else this.startQuery(s)}(e.length||r.open&&r.open.disabled)&&this.view.dispatch({effects:Am.of(e)})}},{eventHandlers:{blur(t){let e=this.view.state.field(un,!1);if(e&&e.tooltip&&this.view.state.facet(It).closeOnBlur){let n=e.open&&j6(this.view,e.open.tooltip);(!n||!n.dom.contains(t.relatedTarget))&&setTimeout(()=>this.view.dispatch({effects:za.of(null)}),10)}},compositionstart(){this.composing=1},compositionend(){this.composing==3&&setTimeout(()=>this.view.dispatch({effects:Uu.of(!1)}),20),this.composing=0}}}),wK=typeof navigator=="object"&&/Win/.test(navigator.platform),xK=Ro.highest(le.domEventHandlers({keydown(t,e){let n=e.state.field(un,!1);if(!n||!n.open||n.open.disabled||n.open.selected<0||t.key.length>1||t.ctrlKey&&!(wK&&t.altKey)||t.metaKey)return!1;let r=n.open.options[n.open.selected],i=n.active.find(s=>s.source==r.source),o=r.completion.commitCharacters||i.result.commitCharacters;return o&&o.indexOf(t.key)>-1&&Rm(e,r),!1}})),yK=le.baseTheme({".cm-tooltip.cm-tooltip-autocomplete":{"& > ul":{fontFamily:"monospace",whiteSpace:"nowrap",overflow:"hidden auto",maxWidth_fallback:"700px",maxWidth:"min(700px, 95vw)",minWidth:"250px",maxHeight:"10em",height:"100%",listStyle:"none",margin:0,padding:0,"& > li, & > completion-section":{padding:"1px 3px",lineHeight:1.2},"& > li":{overflowX:"hidden",textOverflow:"ellipsis",cursor:"pointer"},"& > completion-section":{display:"list-item",borderBottom:"1px solid silver",paddingLeft:"0.5em",opacity:.7}}},"&light .cm-tooltip-autocomplete ul li[aria-selected]":{background:"#17c",color:"white"},"&light .cm-tooltip-autocomplete-disabled ul li[aria-selected]":{background:"#777"},"&dark .cm-tooltip-autocomplete ul li[aria-selected]":{background:"#347",color:"white"},"&dark .cm-tooltip-autocomplete-disabled ul li[aria-selected]":{background:"#444"},".cm-completionListIncompleteTop:before, .cm-completionListIncompleteBottom:after":{content:'"···"',opacity:.5,display:"block",textAlign:"center"},".cm-tooltip.cm-completionInfo":{position:"absolute",padding:"3px 9px",width:"max-content",maxWidth:"400px",boxSizing:"border-box",whiteSpace:"pre-line"},".cm-completionInfo.cm-completionInfo-left":{right:"100%"},".cm-completionInfo.cm-completionInfo-right":{left:"100%"},".cm-completionInfo.cm-completionInfo-left-narrow":{right:"30px"},".cm-completionInfo.cm-completionInfo-right-narrow":{left:"30px"},"&light .cm-snippetField":{backgroundColor:"#00000022"},"&dark .cm-snippetField":{backgroundColor:"#ffffff22"},".cm-snippetFieldPosition":{verticalAlign:"text-top",width:0,height:"1.15em",display:"inline-block",margin:"0 -0.7px -.7em",borderLeft:"1.4px dotted #888"},".cm-completionMatchedText":{textDecoration:"underline"},".cm-completionDetail":{marginLeft:"0.5em",fontStyle:"italic"},".cm-completionIcon":{fontSize:"90%",width:".8em",display:"inline-block",textAlign:"center",paddingRight:".6em",opacity:"0.6",boxSizing:"content-box"},".cm-completionIcon-function, .cm-completionIcon-method":{"&:after":{content:"'ƒ'"}},".cm-completionIcon-class":{"&:after":{content:"'○'"}},".cm-completionIcon-interface":{"&:after":{content:"'◌'"}},".cm-completionIcon-variable":{"&:after":{content:"'𝑥'"}},".cm-completionIcon-constant":{"&:after":{content:"'𝐶'"}},".cm-completionIcon-type":{"&:after":{content:"'𝑡'"}},".cm-completionIcon-enum":{"&:after":{content:"'∪'"}},".cm-completionIcon-property":{"&:after":{content:"'□'"}},".cm-completionIcon-keyword":{"&:after":{content:"'🔑︎'"}},".cm-completionIcon-namespace":{"&:after":{content:"'▢'"}},".cm-completionIcon-text":{"&:after":{content:"'abc'",fontSize:"50%",verticalAlign:"middle"}}}),Ua={brackets:["(","[","{","'",'"'],before:")]}:;>",stringPrefixes:[]},io=Me.define({map(t,e){let n=e.mapPos(t,-1,Jt.TrackAfter);return n??void 0}}),km=new class extends go{};km.startSide=1;km.endSide=-1;const Z4=Bt.define({create(){return Ke.empty},update(t,e){if(t=t.map(e.changes),e.selection){let n=e.state.doc.lineAt(e.selection.main.head);t=t.update({filter:r=>r>=n.from&&r<=n.to})}for(let n of e.effects)n.is(io)&&(t=t.update({add:[km.range(n.value,n.value+1)]}));return t}});function CK(){return[SK,Z4]}const Jd="()[]{}<>«»»«[]{}";function Q4(t){for(let e=0;e<Jd.length;e+=2)if(Jd.charCodeAt(e)==t)return Jd.charAt(e+1);return em(t<128?t:t+1)}function J4(t,e){return t.languageDataAt("closeBrackets",e)[0]||Ua}const $K=typeof navigator=="object"&&/Android\b/.test(navigator.userAgent),SK=le.inputHandler.of((t,e,n,r)=>{if(($K?t.composing:t.compositionStarted)||t.state.readOnly)return!1;let i=t.state.selection.main;if(r.length>2||r.length==2&&mr(ln(r,0))==1||e!=i.from||n!=i.to)return!1;let o=kK(t.state,r);return o?(t.dispatch(o),!0):!1}),AK=({state:t,dispatch:e})=>{if(t.readOnly)return!1;let r=J4(t,t.selection.main.head).brackets||Ua.brackets,i=null,o=t.changeByRange(s=>{if(s.empty){let a=TK(t.doc,s.head);for(let c of r)if(c==a&&Dh(t.doc,s.head)==Q4(ln(c,0)))return{changes:{from:s.head-c.length,to:s.head+c.length},range:Q.cursor(s.head-c.length)}}return{range:i=s}});return i||e(t.update(o,{scrollIntoView:!0,userEvent:"delete.backward"})),!i},RK=[{key:"Backspace",run:AK}];function kK(t,e){let n=J4(t,t.selection.main.head),r=n.brackets||Ua.brackets;for(let i of r){let o=Q4(ln(i,0));if(e==i)return o==i?OK(t,i,r.indexOf(i+i+i)>-1,n):MK(t,i,o,n.before||Ua.before);if(e==o&&eC(t,t.selection.main.from))return EK(t,i,o)}return null}function eC(t,e){let n=!1;return t.field(Z4).between(0,t.doc.length,r=>{r==e&&(n=!0)}),n}function Dh(t,e){let n=t.sliceString(e,e+2);return n.slice(0,mr(ln(n,0)))}function TK(t,e){let n=t.sliceString(e-2,e);return mr(ln(n,0))==n.length?n:n.slice(1)}function MK(t,e,n,r){let i=null,o=t.changeByRange(s=>{if(!s.empty)return{changes:[{insert:e,from:s.from},{insert:n,from:s.to}],effects:io.of(s.to+e.length),range:Q.range(s.anchor+e.length,s.head+e.length)};let a=Dh(t.doc,s.head);return!a||/\s/.test(a)||r.indexOf(a)>-1?{changes:{insert:e+n,from:s.head},effects:io.of(s.head+e.length),range:Q.cursor(s.head+e.length)}:{range:i=s}});return i?null:t.update(o,{scrollIntoView:!0,userEvent:"input.type"})}function EK(t,e,n){let r=null,i=t.changeByRange(o=>o.empty&&Dh(t.doc,o.head)==n?{changes:{from:o.head,to:o.head+n.length,insert:n},range:Q.cursor(o.head+n.length)}:r={range:o});return r?null:t.update(i,{scrollIntoView:!0,userEvent:"input.type"})}function OK(t,e,n,r){let i=r.stringPrefixes||Ua.stringPrefixes,o=null,s=t.changeByRange(a=>{if(!a.empty)return{changes:[{insert:e,from:a.from},{insert:e,from:a.to}],effects:io.of(a.to+e.length),range:Q.range(a.anchor+e.length,a.head+e.length)};let c=a.head,h=Dh(t.doc,c),f;if(h==e){if(Wb(t,c))return{changes:{insert:e+e,from:c},effects:io.of(c+e.length),range:Q.cursor(c+e.length)};if(eC(t,c)){let m=n&&t.sliceDoc(c,c+e.length*3)==e+e+e?e+e+e:e;return{changes:{from:c,to:c+m.length,insert:m},range:Q.cursor(c+m.length)}}}else{if(n&&t.sliceDoc(c-2*e.length,c)==e+e&&(f=zb(t,c-2*e.length,i))>-1&&Wb(t,f))return{changes:{insert:e+e+e+e,from:c},effects:io.of(c+e.length),range:Q.cursor(c+e.length)};if(t.charCategorizer(c)(h)!=lt.Word&&zb(t,c,i)>-1&&!DK(t,c,e,i))return{changes:{insert:e+e,from:c},effects:io.of(c+e.length),range:Q.cursor(c+e.length)}}return{range:o=a}});return o?null:t.update(s,{scrollIntoView:!0,userEvent:"input.type"})}function Wb(t,e){let n=Kt(t).resolveInner(e+1);return n.parent&&n.from==e}function DK(t,e,n,r){let i=Kt(t).resolveInner(e,-1),o=r.reduce((s,a)=>Math.max(s,a.length),0);for(let s=0;s<5;s++){let a=t.sliceDoc(i.from,Math.min(i.to,i.from+n.length+o)),c=a.indexOf(n);if(!c||c>-1&&r.indexOf(a.slice(0,c))>-1){let f=i.firstChild;for(;f&&f.from==i.from&&f.to-f.from>n.length+c;){if(t.sliceDoc(f.to-n.length,f.to)==n)return!1;f=f.firstChild}return!0}let h=i.to==e&&i.parent;if(!h)break;i=h}return!1}function zb(t,e,n){let r=t.charCategorizer(e);if(r(t.sliceDoc(e-1,e))!=lt.Word)return e;for(let i of n){let o=e-i.length;if(t.sliceDoc(o,e)==i&&r(t.sliceDoc(o-1,o))!=lt.Word)return o}return-1}function IK(t={}){return[xK,un,It.of(t),bK,_K,yK]}const tC=[{key:"Ctrl-Space",run:Pb},{mac:"Alt-`",run:Pb},{key:"Escape",run:gK},{key:"ArrowDown",run:Uc(!0)},{key:"ArrowUp",run:Uc(!1)},{key:"PageDown",run:Uc(!0,"page")},{key:"PageUp",run:Uc(!1,"page")},{key:"Enter",run:dK}],_K=Ro.highest($h.computeN([It],t=>t.facet(It).defaultKeymap?[tC]:[]));class Ub{constructor(e,n,r){this.from=e,this.to=n,this.diagnostic=r}}class to{constructor(e,n,r){this.diagnostics=e,this.panel=n,this.selected=r}static init(e,n,r){let i=r.facet(qa).markerFilter;i&&(e=i(e,r));let o=e.slice().sort((f,d)=>f.from-d.from||f.to-d.to),s=new ei,a=[],c=0;for(let f=0;;){let d=f==o.length?null:o[f];if(!d&&!a.length)break;let m,v;for(a.length?(m=c,v=a.reduce((x,C)=>Math.min(x,C.to),d&&d.from>m?d.from:1e8)):(m=d.from,v=d.to,a.push(d),f++);f<o.length;){let x=o[f];if(x.from==m&&(x.to>x.from||x.to==m))a.push(x),f++,v=Math.min(x.to,v);else{v=Math.min(x.from,v);break}}let w=KK(a);if(a.some(x=>x.from==x.to||x.from==x.to-1&&r.doc.lineAt(x.from).to==x.from))s.add(m,m,xe.widget({widget:new WK(w),diagnostics:a.slice()}));else{let x=a.reduce((C,S)=>S.markClass?C+" "+S.markClass:C,"");s.add(m,v,xe.mark({class:"cm-lintRange cm-lintRange-"+w+x,diagnostics:a.slice(),inclusiveEnd:a.some(C=>C.to>v)}))}c=v;for(let x=0;x<a.length;x++)a[x].to<=c&&a.splice(x--,1)}let h=s.finish();return new to(h,n,ks(h))}}function ks(t,e=null,n=0){let r=null;return t.between(n,1e9,(i,o,{spec:s})=>{if(!(e&&s.diagnostics.indexOf(e)<0))if(!r)r=new Ub(i,o,e||s.diagnostics[0]);else{if(s.diagnostics.indexOf(r.diagnostic)<0)return!1;r=new Ub(r.from,o,r.diagnostic)}}),r}function LK(t,e){let n=e.pos,r=e.end||n,i=t.state.facet(qa).hideOn(t,n,r);if(i!=null)return i;let o=t.startState.doc.lineAt(e.pos);return!!(t.effects.some(s=>s.is(nC))||t.changes.touchesRange(o.from,Math.max(o.to,r)))}function BK(t,e){return t.field(Rn,!1)?e:e.concat(Me.appendConfig.of(GK))}const nC=Me.define(),Tm=Me.define(),rC=Me.define(),Rn=Bt.define({create(){return new to(xe.none,null,null)},update(t,e){if(e.docChanged&&t.diagnostics.size){let n=t.diagnostics.map(e.changes),r=null,i=t.panel;if(t.selected){let o=e.changes.mapPos(t.selected.from,1);r=ks(n,t.selected.diagnostic,o)||ks(n,null,o)}!n.size&&i&&e.state.facet(qa).autoPanel&&(i=null),t=new to(n,i,r)}for(let n of e.effects)if(n.is(nC)){let r=e.state.facet(qa).autoPanel?n.value.length?Ka.open:null:t.panel;t=to.init(n.value,r,e.state)}else n.is(Tm)?t=new to(t.diagnostics,n.value?Ka.open:null,t.selected):n.is(rC)&&(t=new to(t.diagnostics,t.panel,n.value));return t},provide:t=>[Ha.from(t,e=>e.panel),le.decorations.from(t,e=>e.diagnostics)]}),NK=xe.mark({class:"cm-lintRange cm-lintRange-active"});function jK(t,e,n){let{diagnostics:r}=t.state.field(Rn),i,o=-1,s=-1;r.between(e-(n<0?1:0),e+(n>0?1:0),(c,h,{spec:f})=>{if(e>=c&&e<=h&&(c==h||(e>c||n>0)&&(e<h||n<0)))return i=f.diagnostics,o=c,s=h,!1});let a=t.state.facet(qa).tooltipFilter;return i&&a&&(i=a(i,t.state)),i?{pos:o,end:s,above:t.state.doc.lineAt(o).to<s,create(){return{dom:FK(t,i)}}}:null}function FK(t,e){return et("ul",{class:"cm-tooltip-lint"},e.map(n=>oC(t,n,!1)))}const VK=t=>{let e=t.state.field(Rn,!1);(!e||!e.panel)&&t.dispatch({effects:BK(t.state,[Tm.of(!0)])});let n=Va(t,Ka.open);return n&&n.dom.querySelector(".cm-panel-lint ul").focus(),!0},qb=t=>{let e=t.state.field(Rn,!1);return!e||!e.panel?!1:(t.dispatch({effects:Tm.of(!1)}),!0)},HK=t=>{let e=t.state.field(Rn,!1);if(!e)return!1;let n=t.state.selection.main,r=e.diagnostics.iter(n.to+1);return!r.value&&(r=e.diagnostics.iter(0),!r.value||r.from==n.from&&r.to==n.to)?!1:(t.dispatch({selection:{anchor:r.from,head:r.to},scrollIntoView:!0}),!0)},PK=[{key:"Mod-Shift-m",run:VK,preventDefault:!0},{key:"F8",run:HK}],qa=fe.define({combine(t){return Object.assign({sources:t.map(e=>e.source).filter(e=>e!=null)},Mr(t.map(e=>e.config),{delay:750,markerFilter:null,tooltipFilter:null,needsRefresh:null,hideOn:()=>null},{needsRefresh:(e,n)=>e?n?r=>e(r)||n(r):e:n}))}});function iC(t){let e=[];if(t)e:for(let{name:n}of t){for(let r=0;r<n.length;r++){let i=n[r];if(/[a-zA-Z]/.test(i)&&!e.some(o=>o.toLowerCase()==i.toLowerCase())){e.push(i);continue e}}e.push("")}return e}function oC(t,e,n){var r;let i=n?iC(e.actions):[];return et("li",{class:"cm-diagnostic cm-diagnostic-"+e.severity},et("span",{class:"cm-diagnosticText"},e.renderMessage?e.renderMessage(t):e.message),(r=e.actions)===null||r===void 0?void 0:r.map((o,s)=>{let a=!1,c=m=>{if(m.preventDefault(),a)return;a=!0;let v=ks(t.state.field(Rn).diagnostics,e);v&&o.apply(t,v.from,v.to)},{name:h}=o,f=i[s]?h.indexOf(i[s]):-1,d=f<0?h:[h.slice(0,f),et("u",h.slice(f,f+1)),h.slice(f+1)];return et("button",{type:"button",class:"cm-diagnosticAction",onclick:c,onmousedown:c,"aria-label":` Action: ${h}${f<0?"":` (access key "${i[s]})"`}.`},d)}),e.source&&et("div",{class:"cm-diagnosticSource"},e.source))}class WK extends ai{constructor(e){super(),this.sev=e}eq(e){return e.sev==this.sev}toDOM(){return et("span",{class:"cm-lintPoint cm-lintPoint-"+this.sev})}}class Kb{constructor(e,n){this.diagnostic=n,this.id="item_"+Math.floor(Math.random()*4294967295).toString(16),this.dom=oC(e,n,!0),this.dom.id=this.id,this.dom.setAttribute("role","option")}}class Ka{constructor(e){this.view=e,this.items=[];let n=i=>{if(i.keyCode==27)qb(this.view),this.view.focus();else if(i.keyCode==38||i.keyCode==33)this.moveSelection((this.selectedIndex-1+this.items.length)%this.items.length);else if(i.keyCode==40||i.keyCode==34)this.moveSelection((this.selectedIndex+1)%this.items.length);else if(i.keyCode==36)this.moveSelection(0);else if(i.keyCode==35)this.moveSelection(this.items.length-1);else if(i.keyCode==13)this.view.focus();else if(i.keyCode>=65&&i.keyCode<=90&&this.selectedIndex>=0){let{diagnostic:o}=this.items[this.selectedIndex],s=iC(o.actions);for(let a=0;a<s.length;a++)if(s[a].toUpperCase().charCodeAt(0)==i.keyCode){let c=ks(this.view.state.field(Rn).diagnostics,o);c&&o.actions[a].apply(e,c.from,c.to)}}else return;i.preventDefault()},r=i=>{for(let o=0;o<this.items.length;o++)this.items[o].dom.contains(i.target)&&this.moveSelection(o)};this.list=et("ul",{tabIndex:0,role:"listbox","aria-label":this.view.state.phrase("Diagnostics"),onkeydown:n,onclick:r}),this.dom=et("div",{class:"cm-panel-lint"},this.list,et("button",{type:"button",name:"close","aria-label":this.view.state.phrase("close"),onclick:()=>qb(this.view)},"×")),this.update()}get selectedIndex(){let e=this.view.state.field(Rn).selected;if(!e)return-1;for(let n=0;n<this.items.length;n++)if(this.items[n].diagnostic==e.diagnostic)return n;return-1}update(){let{diagnostics:e,selected:n}=this.view.state.field(Rn),r=0,i=!1,o=null,s=new Set;for(e.between(0,this.view.state.doc.length,(a,c,{spec:h})=>{for(let f of h.diagnostics){if(s.has(f))continue;s.add(f);let d=-1,m;for(let v=r;v<this.items.length;v++)if(this.items[v].diagnostic==f){d=v;break}d<0?(m=new Kb(this.view,f),this.items.splice(r,0,m),i=!0):(m=this.items[d],d>r&&(this.items.splice(r,d-r),i=!0)),n&&m.diagnostic==n.diagnostic?m.dom.hasAttribute("aria-selected")||(m.dom.setAttribute("aria-selected","true"),o=m):m.dom.hasAttribute("aria-selected")&&m.dom.removeAttribute("aria-selected"),r++}});r<this.items.length&&!(this.items.length==1&&this.items[0].diagnostic.from<0);)i=!0,this.items.pop();this.items.length==0&&(this.items.push(new Kb(this.view,{from:-1,to:-1,severity:"info",message:this.view.state.phrase("No diagnostics")})),i=!0),o?(this.list.setAttribute("aria-activedescendant",o.id),this.view.requestMeasure({key:this,read:()=>({sel:o.dom.getBoundingClientRect(),panel:this.list.getBoundingClientRect()}),write:({sel:a,panel:c})=>{let h=c.height/this.list.offsetHeight;a.top<c.top?this.list.scrollTop-=(c.top-a.top)/h:a.bottom>c.bottom&&(this.list.scrollTop+=(a.bottom-c.bottom)/h)}})):this.selectedIndex<0&&this.list.removeAttribute("aria-activedescendant"),i&&this.sync()}sync(){let e=this.list.firstChild;function n(){let r=e;e=r.nextSibling,r.remove()}for(let r of this.items)if(r.dom.parentNode==this.list){for(;e!=r.dom;)n();e=r.dom.nextSibling}else this.list.insertBefore(r.dom,e);for(;e;)n()}moveSelection(e){if(this.selectedIndex<0)return;let n=this.view.state.field(Rn),r=ks(n.diagnostics,this.items[e].diagnostic);r&&this.view.dispatch({selection:{anchor:r.from,head:r.to},scrollIntoView:!0,effects:rC.of(r)})}static open(e){return new Ka(e)}}function zK(t,e='viewBox="0 0 40 40"'){return`url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" ${e}>${encodeURIComponent(t)}</svg>')`}function qc(t){return zK(`<path d="m0 2.5 l2 -1.5 l1 0 l2 1.5 l1 0" stroke="${t}" fill="none" stroke-width=".7"/>`,'width="6" height="3"')}const UK=le.baseTheme({".cm-diagnostic":{padding:"3px 6px 3px 8px",marginLeft:"-1px",display:"block",whiteSpace:"pre-wrap"},".cm-diagnostic-error":{borderLeft:"5px solid #d11"},".cm-diagnostic-warning":{borderLeft:"5px solid orange"},".cm-diagnostic-info":{borderLeft:"5px solid #999"},".cm-diagnostic-hint":{borderLeft:"5px solid #66d"},".cm-diagnosticAction":{font:"inherit",border:"none",padding:"2px 4px",backgroundColor:"#444",color:"white",borderRadius:"3px",marginLeft:"8px",cursor:"pointer"},".cm-diagnosticSource":{fontSize:"70%",opacity:.7},".cm-lintRange":{backgroundPosition:"left bottom",backgroundRepeat:"repeat-x",paddingBottom:"0.7px"},".cm-lintRange-error":{backgroundImage:qc("#d11")},".cm-lintRange-warning":{backgroundImage:qc("orange")},".cm-lintRange-info":{backgroundImage:qc("#999")},".cm-lintRange-hint":{backgroundImage:qc("#66d")},".cm-lintRange-active":{backgroundColor:"#ffdd9980"},".cm-tooltip-lint":{padding:0,margin:0},".cm-lintPoint":{position:"relative","&:after":{content:'""',position:"absolute",bottom:0,left:"-2px",borderLeft:"3px solid transparent",borderRight:"3px solid transparent",borderBottom:"4px solid #d11"}},".cm-lintPoint-warning":{"&:after":{borderBottomColor:"orange"}},".cm-lintPoint-info":{"&:after":{borderBottomColor:"#999"}},".cm-lintPoint-hint":{"&:after":{borderBottomColor:"#66d"}},".cm-panel.cm-panel-lint":{position:"relative","& ul":{maxHeight:"100px",overflowY:"auto","& [aria-selected]":{backgroundColor:"#ddd","& u":{textDecoration:"underline"}},"&:focus [aria-selected]":{background_fallback:"#bdf",backgroundColor:"Highlight",color_fallback:"white",color:"HighlightText"},"& u":{textDecoration:"none"},padding:0,margin:0},"& [name=close]":{position:"absolute",top:"0",right:"2px",background:"inherit",border:"none",font:"inherit",padding:0,margin:0}}});function qK(t){return t=="error"?4:t=="warning"?3:t=="info"?2:1}function KK(t){let e="hint",n=1;for(let r of t){let i=qK(r.severity);i>n&&(n=i,e=r.severity)}return e}const GK=[Rn,le.decorations.compute([Rn],t=>{let{selected:e,panel:n}=t.field(Rn);return!e||!n||e.from==e.to?xe.none:xe.set([NK.range(e.from,e.to)])}),QW(jK,{hideOn:LK}),UK];var Gb=function(e){e===void 0&&(e={});var{crosshairCursor:n=!1}=e,r=[];e.closeBracketsKeymap!==!1&&(r=r.concat(RK)),e.defaultKeymap!==!1&&(r=r.concat(wq)),e.searchKeymap!==!1&&(r=r.concat(Uq)),e.historyKeymap!==!1&&(r=r.concat(TU)),e.foldKeymap!==!1&&(r=r.concat(Nz)),e.completionKeymap!==!1&&(r=r.concat(tC)),e.lintKeymap!==!1&&(r=r.concat(PK));var i=[];return e.lineNumbers!==!1&&i.push(cz()),e.highlightActiveLineGutter!==!1&&i.push(fz()),e.highlightSpecialChars!==!1&&i.push(kW()),e.history!==!1&&i.push(wU()),e.foldGutter!==!1&&i.push(Hz()),e.drawSelection!==!1&&i.push(pW()),e.dropCursor!==!1&&i.push(yW()),e.allowMultipleSelections!==!1&&i.push(qe.allowMultipleSelections.of(!0)),e.indentOnInput!==!1&&i.push(kz()),e.syntaxHighlighting!==!1&&i.push(e4(Uz,{fallback:!0})),e.bracketMatching!==!1&&i.push(Qz()),e.closeBrackets!==!1&&i.push(CK()),e.autocompletion!==!1&&i.push(IK()),e.rectangularSelection!==!1&&i.push(HW()),n!==!1&&i.push(zW()),e.highlightActiveLine!==!1&&i.push(IW()),e.highlightSelectionMatches!==!1&&i.push(Rq()),e.tabSize&&typeof e.tabSize=="number"&&i.push(Ah.of(" ".repeat(e.tabSize))),i.concat([$h.of(r.flat())]).filter(Boolean)};const YK="#e5c07b",Yb="#e06c75",XK="#56b6c2",ZK="#ffffff",lu="#abb2bf",M1="#7d8799",QK="#61afef",JK="#98c379",Xb="#d19a66",eG="#c678dd",tG="#21252b",Zb="#2c313a",Qb="#282c34",e0="#353a42",nG="#3E4451",Jb="#528bff",rG=le.theme({"&":{color:lu,backgroundColor:Qb},".cm-content":{caretColor:Jb},".cm-cursor, .cm-dropCursor":{borderLeftColor:Jb},"&.cm-focused > .cm-scroller > .cm-selectionLayer .cm-selectionBackground, .cm-selectionBackground, .cm-content ::selection":{backgroundColor:nG},".cm-panels":{backgroundColor:tG,color:lu},".cm-panels.cm-panels-top":{borderBottom:"2px solid black"},".cm-panels.cm-panels-bottom":{borderTop:"2px solid black"},".cm-searchMatch":{backgroundColor:"#72a1ff59",outline:"1px solid #457dff"},".cm-searchMatch.cm-searchMatch-selected":{backgroundColor:"#6199ff2f"},".cm-activeLine":{backgroundColor:"#6699ff0b"},".cm-selectionMatch":{backgroundColor:"#aafe661a"},"&.cm-focused .cm-matchingBracket, &.cm-focused .cm-nonmatchingBracket":{backgroundColor:"#bad0f847"},".cm-gutters":{backgroundColor:Qb,color:M1,border:"none"},".cm-activeLineGutter":{backgroundColor:Zb},".cm-foldPlaceholder":{backgroundColor:"transparent",border:"none",color:"#ddd"},".cm-tooltip":{border:"none",backgroundColor:e0},".cm-tooltip .cm-tooltip-arrow:before":{borderTopColor:"transparent",borderBottomColor:"transparent"},".cm-tooltip .cm-tooltip-arrow:after":{borderTopColor:e0,borderBottomColor:e0},".cm-tooltip-autocomplete":{"& > ul > li[aria-selected]":{backgroundColor:Zb,color:lu}}},{dark:!0}),iG=gl.define([{tag:z.keyword,color:eG},{tag:[z.name,z.deleted,z.character,z.propertyName,z.macroName],color:Yb},{tag:[z.function(z.variableName),z.labelName],color:QK},{tag:[z.color,z.constant(z.name),z.standard(z.name)],color:Xb},{tag:[z.definition(z.name),z.separator],color:lu},{tag:[z.typeName,z.className,z.number,z.changed,z.annotation,z.modifier,z.self,z.namespace],color:YK},{tag:[z.operator,z.operatorKeyword,z.url,z.escape,z.regexp,z.link,z.special(z.string)],color:XK},{tag:[z.meta,z.comment],color:M1},{tag:z.strong,fontWeight:"bold"},{tag:z.emphasis,fontStyle:"italic"},{tag:z.strikethrough,textDecoration:"line-through"},{tag:z.link,color:M1,textDecoration:"underline"},{tag:z.heading,fontWeight:"bold",color:Yb},{tag:[z.atom,z.bool,z.special(z.variableName)],color:Xb},{tag:[z.processingInstruction,z.string,z.inserted],color:JK},{tag:z.invalid,color:ZK}]),oG=[rG,e4(iG)];var sG=le.theme({"&":{backgroundColor:"#fff"}},{dark:!1}),aG=function(e){e===void 0&&(e={});var{indentWithTab:n=!0,editable:r=!0,readOnly:i=!1,theme:o="light",placeholder:s="",basicSetup:a=!0}=e,c=[];switch(n&&c.unshift($h.of([xq])),a&&(typeof a=="boolean"?c.unshift(Gb()):c.unshift(Gb(a))),s&&c.unshift(NW(s)),o){case"light":c.push(sG);break;case"dark":c.push(oG);break;case"none":break;default:c.push(o);break}return r===!1&&c.push(le.editable.of(!1)),i&&c.push(qe.readOnly.of(!0)),[...c]},lG=t=>({line:t.state.doc.lineAt(t.state.selection.main.from),lineCount:t.state.doc.lines,lineBreak:t.state.lineBreak,length:t.state.doc.length,readOnly:t.state.readOnly,tabSize:t.state.tabSize,selection:t.state.selection,selectionAsSingle:t.state.selection.asSingle().main,ranges:t.state.selection.ranges,selectionCode:t.state.sliceDoc(t.state.selection.main.from,t.state.selection.main.to),selections:t.state.selection.ranges.map(e=>t.state.sliceDoc(e.from,e.to)),selectedText:t.state.selection.ranges.some(e=>!e.empty)}),ew=Tr.define(),cG=[];function sC(t){var{value:e,selection:n,onChange:r,onStatistics:i,onCreateEditor:o,onUpdate:s,extensions:a=cG,autoFocus:c,theme:h="light",height:f=null,minHeight:d=null,maxHeight:m=null,width:v=null,minWidth:w=null,maxWidth:x=null,placeholder:C="",editable:S=!0,readOnly:A=!1,indentWithTab:T=!0,basicSetup:O=!0,root:D,initialState:L}=t,[I,V]=b.useState(),[F,H]=b.useState(),[K,W]=b.useState(),J=le.theme({"&":{height:f,minHeight:d,maxHeight:m,width:v,minWidth:w,maxWidth:x},"& .cm-scroller":{height:"100% !important"}}),G=le.updateListener.of(te=>{if(te.docChanged&&typeof r=="function"&&!te.transactions.some(ue=>ue.annotation(ew))){var ie=te.state.doc,Y=ie.toString();r(Y,te)}i&&i(lG(te))}),re=aG({theme:h,editable:S,readOnly:A,placeholder:C,indentWithTab:T,basicSetup:O}),oe=[G,J,...re];return s&&typeof s=="function"&&oe.push(le.updateListener.of(s)),oe=oe.concat(a),b.useEffect(()=>{if(I&&!K){var te={doc:e,selection:n,extensions:oe},ie=L?qe.fromJSON(L.json,te,L.fields):qe.create(te);if(W(ie),!F){var Y=new le({state:ie,parent:I,root:D});H(Y),o&&o(Y,ie)}}return()=>{F&&(W(void 0),H(void 0))}},[I,K]),b.useEffect(()=>V(t.container),[t.container]),b.useEffect(()=>()=>{F&&(F.destroy(),H(void 0))},[F]),b.useEffect(()=>{c&&F&&F.focus()},[c,F]),b.useEffect(()=>{F&&F.dispatch({effects:Me.reconfigure.of(oe)})},[h,a,f,d,m,v,w,x,C,S,A,T,O,r,s]),b.useEffect(()=>{if(e!==void 0){var te=F?F.state.doc.toString():"";F&&e!==te&&F.dispatch({changes:{from:0,to:te.length,insert:e||""},annotations:[ew.of(!0)]})}},[e,F]),{state:K,setState:W,view:F,setView:H,container:I,setContainer:V}}var uG=["className","value","selection","extensions","onChange","onStatistics","onCreateEditor","onUpdate","autoFocus","theme","height","minHeight","maxHeight","width","minWidth","maxWidth","basicSetup","placeholder","indentWithTab","editable","readOnly","root","initialState"],hG=b.forwardRef((t,e)=>{var{className:n,value:r="",selection:i,extensions:o=[],onChange:s,onStatistics:a,onCreateEditor:c,onUpdate:h,autoFocus:f,theme:d="light",height:m,minHeight:v,maxHeight:w,width:x,minWidth:C,maxWidth:S,basicSetup:A,placeholder:T,indentWithTab:O,editable:D,readOnly:L,root:I,initialState:V}=t,F=cU(t,uG),H=b.useRef(null),{state:K,view:W,container:J}=sC({container:H.current,root:I,value:r,autoFocus:f,theme:d,height:m,minHeight:v,maxHeight:w,width:x,minWidth:C,maxWidth:S,basicSetup:A,placeholder:T,indentWithTab:O,editable:D,readOnly:L,selection:i,onChange:s,onStatistics:a,onCreateEditor:c,onUpdate:h,extensions:o,initialState:V});if(b.useImperativeHandle(e,()=>({editor:H.current,state:K,view:W}),[H,J,K,W]),typeof r!="string")throw new Error("value must be typeof string but got "+typeof r);var G=typeof d=="string"?"cm-theme-"+d:"cm-theme";return p.jsx("div",U({ref:H,className:""+G+(n?" "+n:"")},F))});hG.displayName="CodeMirror";let t0=new Map,E1=!1;try{E1=new Intl.NumberFormat("de-DE",{signDisplay:"exceptZero"}).resolvedOptions().signDisplay==="exceptZero"}catch{}let Ku=!1;try{Ku=new Intl.NumberFormat("de-DE",{style:"unit",unit:"degree"}).resolvedOptions().style==="unit"}catch{}const aC={degree:{narrow:{default:"°","ja-JP":" 度","zh-TW":"度","sl-SI":" °"}}};class lC{format(e){let n="";if(!E1&&this.options.signDisplay!=null?n=dG(this.numberFormatter,this.options.signDisplay,e):n=this.numberFormatter.format(e),this.options.style==="unit"&&!Ku){var r;let{unit:i,unitDisplay:o="short",locale:s}=this.resolvedOptions();if(!i)return n;let a=(r=aC[i])===null||r===void 0?void 0:r[o];n+=a[s]||a.default}return n}formatToParts(e){return this.numberFormatter.formatToParts(e)}formatRange(e,n){if(typeof this.numberFormatter.formatRange=="function")return this.numberFormatter.formatRange(e,n);if(n<e)throw new RangeError("End date must be >= start date");return`${this.format(e)} – ${this.format(n)}`}formatRangeToParts(e,n){if(typeof this.numberFormatter.formatRangeToParts=="function")return this.numberFormatter.formatRangeToParts(e,n);if(n<e)throw new RangeError("End date must be >= start date");let r=this.numberFormatter.formatToParts(e),i=this.numberFormatter.formatToParts(n);return[...r.map(o=>({...o,source:"startRange"})),{type:"literal",value:" – ",source:"shared"},...i.map(o=>({...o,source:"endRange"}))]}resolvedOptions(){let e=this.numberFormatter.resolvedOptions();return!E1&&this.options.signDisplay!=null&&(e={...e,signDisplay:this.options.signDisplay}),!Ku&&this.options.style==="unit"&&(e={...e,style:"unit",unit:this.options.unit,unitDisplay:this.options.unitDisplay}),e}constructor(e,n={}){this.numberFormatter=fG(e,n),this.options=n}}function fG(t,e={}){let{numberingSystem:n}=e;if(n&&t.includes("-nu-")&&(t.includes("-u-")||(t+="-u-"),t+=`-nu-${n}`),e.style==="unit"&&!Ku){var r;let{unit:s,unitDisplay:a="short"}=e;if(!s)throw new Error('unit option must be provided with style: "unit"');if(!(!((r=aC[s])===null||r===void 0)&&r[a]))throw new Error(`Unsupported unit ${s} with unitDisplay = ${a}`);e={...e,style:"decimal"}}let i=t+(e?Object.entries(e).sort((s,a)=>s[0]<a[0]?-1:1).join():"");if(t0.has(i))return t0.get(i);let o=new Intl.NumberFormat(t,e);return t0.set(i,o),o}function dG(t,e,n){if(e==="auto")return t.format(n);if(e==="never")return t.format(Math.abs(n));{let r=!1;if(e==="always"?r=n>0||Object.is(n,0):e==="exceptZero"&&(Object.is(n,-0)||Object.is(n,0)?n=Math.abs(n):r=n>0),r){let i=t.format(-n),o=t.format(n),s=i.replace(o,"").replace(/\u200e|\u061C/,"");return[...s].length!==1&&console.warn("@react-aria/i18n polyfill for NumberFormat signDisplay: Unsupported case"),i.replace(o,"!!!").replace(s,"+").replace("!!!",o)}else return t.format(n)}}const gG=new RegExp("^.*\\(.*\\).*$"),mG=["latn","arab","hanidec"];class cC{parse(e){return n0(this.locale,this.options,e).parse(e)}isValidPartialNumber(e,n,r){return n0(this.locale,this.options,e).isValidPartialNumber(e,n,r)}getNumberingSystem(e){return n0(this.locale,this.options,e).options.numberingSystem}constructor(e,n={}){this.locale=e,this.options=n}}const tw=new Map;function n0(t,e,n){let r=nw(t,e);if(!t.includes("-nu-")&&!r.isValidPartialNumber(n)){for(let i of mG)if(i!==r.options.numberingSystem){let o=nw(t+(t.includes("-u-")?"-nu-":"-u-nu-")+i,e);if(o.isValidPartialNumber(n))return o}}return r}function nw(t,e){let n=t+(e?Object.entries(e).sort((i,o)=>i[0]<o[0]?-1:1).join():""),r=tw.get(n);return r||(r=new pG(t,e),tw.set(n,r)),r}class pG{parse(e){let n=this.sanitize(e);if(this.symbols.group&&(n=Kc(n,this.symbols.group,"")),this.symbols.decimal&&(n=n.replace(this.symbols.decimal,".")),this.symbols.minusSign&&(n=n.replace(this.symbols.minusSign,"-")),n=n.replace(this.symbols.numeral,this.symbols.index),this.options.style==="percent"){let s=n.indexOf("-");n=n.replace("-","");let a=n.indexOf(".");a===-1&&(a=n.length),n=n.replace(".",""),a-2===0?n=`0.${n}`:a-2===-1?n=`0.0${n}`:a-2===-2?n="0.00":n=`${n.slice(0,a-2)}.${n.slice(a-2)}`,s>-1&&(n=`-${n}`)}let r=n?+n:NaN;if(isNaN(r))return NaN;if(this.options.style==="percent"){var i,o;let s={...this.options,style:"decimal",minimumFractionDigits:Math.min(((i=this.options.minimumFractionDigits)!==null&&i!==void 0?i:0)+2,20),maximumFractionDigits:Math.min(((o=this.options.maximumFractionDigits)!==null&&o!==void 0?o:0)+2,20)};return new cC(this.locale,s).parse(new lC(this.locale,s).format(r))}return this.options.currencySign==="accounting"&&gG.test(e)&&(r=-1*r),r}sanitize(e){return e=e.replace(this.symbols.literals,""),this.symbols.minusSign&&(e=e.replace("-",this.symbols.minusSign)),this.options.numberingSystem==="arab"&&(this.symbols.decimal&&(e=e.replace(",",this.symbols.decimal),e=e.replace("،",this.symbols.decimal)),this.symbols.group&&(e=Kc(e,".",this.symbols.group))),this.options.locale==="fr-FR"&&(e=Kc(e,"."," ")),e}isValidPartialNumber(e,n=-1/0,r=1/0){return e=this.sanitize(e),this.symbols.minusSign&&e.startsWith(this.symbols.minusSign)&&n<0?e=e.slice(this.symbols.minusSign.length):this.symbols.plusSign&&e.startsWith(this.symbols.plusSign)&&r>0&&(e=e.slice(this.symbols.plusSign.length)),this.symbols.group&&e.startsWith(this.symbols.group)||this.symbols.decimal&&e.indexOf(this.symbols.decimal)>-1&&this.options.maximumFractionDigits===0?!1:(this.symbols.group&&(e=Kc(e,this.symbols.group,"")),e=e.replace(this.symbols.numeral,""),this.symbols.decimal&&(e=e.replace(this.symbols.decimal,"")),e.length===0)}constructor(e,n={}){this.locale=e,this.formatter=new Intl.NumberFormat(e,n),this.options=this.formatter.resolvedOptions(),this.symbols=bG(e,this.formatter,this.options,n);var r,i;this.options.style==="percent"&&(((r=this.options.minimumFractionDigits)!==null&&r!==void 0?r:0)>18||((i=this.options.maximumFractionDigits)!==null&&i!==void 0?i:0)>18)&&console.warn("NumberParser cannot handle percentages with greater than 18 decimal places, please reduce the number in your options.")}}const rw=new Set(["decimal","fraction","integer","minusSign","plusSign","group"]),vG=[0,4,2,1,11,20,3,7,100,21,.1,1.1];function bG(t,e,n,r){var i,o,s,a;let c=new Intl.NumberFormat(t,{...n,minimumSignificantDigits:1,maximumSignificantDigits:21}),h=c.formatToParts(-10000.111),f=c.formatToParts(10000.111),d=vG.map(H=>c.formatToParts(H));var m;let v=(m=(i=h.find(H=>H.type==="minusSign"))===null||i===void 0?void 0:i.value)!==null&&m!==void 0?m:"-",w=(o=f.find(H=>H.type==="plusSign"))===null||o===void 0?void 0:o.value;!w&&(r?.signDisplay==="exceptZero"||r?.signDisplay==="always")&&(w="+");let C=(s=new Intl.NumberFormat(t,{...n,minimumFractionDigits:2,maximumFractionDigits:2}).formatToParts(.001).find(H=>H.type==="decimal"))===null||s===void 0?void 0:s.value,S=(a=h.find(H=>H.type==="group"))===null||a===void 0?void 0:a.value,A=h.filter(H=>!rw.has(H.type)).map(H=>iw(H.value)),T=d.flatMap(H=>H.filter(K=>!rw.has(K.type)).map(K=>iw(K.value))),O=[...new Set([...A,...T])].sort((H,K)=>K.length-H.length),D=O.length===0?new RegExp("[\\p{White_Space}]","gu"):new RegExp(`${O.join("|")}|[\\p{White_Space}]`,"gu"),L=[...new Intl.NumberFormat(n.locale,{useGrouping:!1}).format(9876543210)].reverse(),I=new Map(L.map((H,K)=>[H,K])),V=new RegExp(`[${L.join("")}]`,"g");return{minusSign:v,plusSign:w,decimal:C,group:S,literals:D,numeral:V,index:H=>String(I.get(H))}}function Kc(t,e,n){return t.replaceAll?t.replaceAll(e,n):t.split(e).join(n)}function iw(t){return t.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}const uC="Popover",[hC,lte]=bt(uC,[Li]),Mm=Li(),[wG,Vs]=hC(uC),xG=t=>{const{__scopePopover:e,children:n,open:r,defaultOpen:i,onOpenChange:o,modal:s=!1}=t,a=Mm(e),c=b.useRef(null),[h,f]=b.useState(!1),[d=!1,m]=_t({prop:r,defaultProp:i,onChange:o});return b.createElement(Ja,a,b.createElement(wG,{scope:e,contentId:Lt(),triggerRef:c,open:d,onOpenChange:m,onOpenToggle:b.useCallback(()=>m(v=>!v),[m]),hasCustomAnchor:h,onCustomAnchorAdd:b.useCallback(()=>f(!0),[]),onCustomAnchorRemove:b.useCallback(()=>f(!1),[]),modal:s},n))},yG="PopoverTrigger",CG=b.forwardRef((t,e)=>{const{__scopePopover:n,...r}=t,i=Vs(yG,n),o=Mm(n),s=ye(e,i.triggerRef),a=b.createElement(me.button,U({type:"button","aria-haspopup":"dialog","aria-expanded":i.open,"aria-controls":i.contentId,"data-state":gC(i.open)},r,{ref:s,onClick:ne(t.onClick,i.onOpenToggle)}));return i.hasCustomAnchor?a:b.createElement(el,U({asChild:!0},o),a)}),fC="PopoverPortal",[$G,SG]=hC(fC,{forceMount:void 0}),AG=t=>{const{__scopePopover:e,forceMount:n,children:r,container:i}=t,o=Vs(fC,e);return b.createElement($G,{scope:e,forceMount:n},b.createElement(Mt,{present:n||o.open},b.createElement(Ds,{asChild:!0,container:i},r)))},Ga="PopoverContent",RG=b.forwardRef((t,e)=>{const n=SG(Ga,t.__scopePopover),{forceMount:r=n.forceMount,...i}=t,o=Vs(Ga,t.__scopePopover);return b.createElement(Mt,{present:r||o.open},o.modal?b.createElement(kG,U({},i,{ref:e})):b.createElement(TG,U({},i,{ref:e})))}),kG=b.forwardRef((t,e)=>{const n=Vs(Ga,t.__scopePopover),r=b.useRef(null),i=ye(e,r),o=b.useRef(!1);return b.useEffect(()=>{const s=r.current;if(s)return rl(s)},[]),b.createElement(mh,{as:Cr,allowPinchZoom:!0},b.createElement(dC,U({},t,{ref:i,trapFocus:n.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:ne(t.onCloseAutoFocus,s=>{var a;s.preventDefault(),o.current||(a=n.triggerRef.current)===null||a===void 0||a.focus()}),onPointerDownOutside:ne(t.onPointerDownOutside,s=>{const a=s.detail.originalEvent,c=a.button===0&&a.ctrlKey===!0,h=a.button===2||c;o.current=h},{checkForDefaultPrevented:!1}),onFocusOutside:ne(t.onFocusOutside,s=>s.preventDefault(),{checkForDefaultPrevented:!1})})))}),TG=b.forwardRef((t,e)=>{const n=Vs(Ga,t.__scopePopover),r=b.useRef(!1),i=b.useRef(!1);return b.createElement(dC,U({},t,{ref:e,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:o=>{var s;if((s=t.onCloseAutoFocus)===null||s===void 0||s.call(t,o),!o.defaultPrevented){var a;r.current||(a=n.triggerRef.current)===null||a===void 0||a.focus(),o.preventDefault()}r.current=!1,i.current=!1},onInteractOutside:o=>{var s,a;(s=t.onInteractOutside)===null||s===void 0||s.call(t,o),o.defaultPrevented||(r.current=!0,o.detail.originalEvent.type==="pointerdown"&&(i.current=!0));const c=o.target;((a=n.triggerRef.current)===null||a===void 0?void 0:a.contains(c))&&o.preventDefault(),o.detail.originalEvent.type==="focusin"&&i.current&&o.preventDefault()}}))}),dC=b.forwardRef((t,e)=>{const{__scopePopover:n,trapFocus:r,onOpenAutoFocus:i,onCloseAutoFocus:o,disableOutsidePointerEvents:s,onEscapeKeyDown:a,onPointerDownOutside:c,onFocusOutside:h,onInteractOutside:f,...d}=t,m=Vs(Ga,n),v=Mm(n);return Is(),b.createElement(_s,{asChild:!0,loop:!0,trapped:r,onMountAutoFocus:i,onUnmountAutoFocus:o},b.createElement(Co,{asChild:!0,disableOutsidePointerEvents:s,onInteractOutside:f,onEscapeKeyDown:a,onPointerDownOutside:c,onFocusOutside:h,onDismiss:()=>m.onOpenChange(!1)},b.createElement(tl,U({"data-state":gC(m.open),role:"dialog",id:m.contentId},v,d,{ref:e,style:{...d.style,"--radix-popover-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-popover-content-available-width":"var(--radix-popper-available-width)","--radix-popover-content-available-height":"var(--radix-popper-available-height)","--radix-popover-trigger-width":"var(--radix-popper-anchor-width)","--radix-popover-trigger-height":"var(--radix-popper-anchor-height)"}}))))});function gC(t){return t?"open":"closed"}const MG=xG,EG=CG,OG=AG,DG=RG,mC="Progress",Ih=100,[IG,cte]=bt(mC),[_G,LG]=IG(mC),pC=b.forwardRef((t,e)=>{const{__scopeProgress:n,value:r,max:i,getValueLabel:o=jG,...s}=t,a=O1(i)?i:Ih,c=bC(r,a)?r:null,h=Gu(c)?o(c,a):void 0;return b.createElement(_G,{scope:n,value:c,max:a},b.createElement(me.div,U({"aria-valuemax":a,"aria-valuemin":0,"aria-valuenow":Gu(c)?c:void 0,"aria-valuetext":h,role:"progressbar","data-state":vC(c,a),"data-value":c??void 0,"data-max":a},s,{ref:e})))});pC.propTypes={max(t,e,n){const r=t[e],i=String(r);return r&&!O1(r)?new Error(FG(i,n)):null},value(t,e,n){const r=t[e],i=String(r),o=O1(t.max)?t.max:Ih;return r!=null&&!bC(r,o)?new Error(VG(i,n)):null}};const BG="ProgressIndicator",NG=b.forwardRef((t,e)=>{var n;const{__scopeProgress:r,...i}=t,o=LG(BG,r);return b.createElement(me.div,U({"data-state":vC(o.value,o.max),"data-value":(n=o.value)!==null&&n!==void 0?n:void 0,"data-max":o.max},i,{ref:e}))});function jG(t,e){return`${Math.round(t/e*100)}%`}function vC(t,e){return t==null?"indeterminate":t===e?"complete":"loading"}function Gu(t){return typeof t=="number"}function O1(t){return Gu(t)&&!isNaN(t)&&t>0}function bC(t,e){return Gu(t)&&!isNaN(t)&&t<=e&&t>=0}function FG(t,e){return`Invalid prop \`max\` of value \`${t}\` supplied to \`${e}\`. Only numbers greater than 0 are valid max values. Defaulting to \`${Ih}\`.`}function VG(t,e){return`Invalid prop \`value\` of value \`${t}\` supplied to \`${e}\`. The \`value\` prop must be:
59
- - a positive number
60
- - less than the value passed to \`max\` (or ${Ih} if no \`max\` prop is set)
61
- - \`null\` if the progress is indeterminate.
62
-
63
- Defaulting to \`null\`.`}const HG=pC,PG=NG,wC="Radio",[WG,xC]=bt(wC),[zG,UG]=WG(wC),qG=b.forwardRef((t,e)=>{const{__scopeRadio:n,name:r,checked:i=!1,required:o,disabled:s,value:a="on",onCheck:c,...h}=t,[f,d]=b.useState(null),m=ye(e,x=>d(x)),v=b.useRef(!1),w=f?!!f.closest("form"):!0;return b.createElement(zG,{scope:n,checked:i,disabled:s},b.createElement(me.button,U({type:"button",role:"radio","aria-checked":i,"data-state":yC(i),"data-disabled":s?"":void 0,disabled:s,value:a},h,{ref:m,onClick:ne(t.onClick,x=>{i||c?.(),w&&(v.current=x.isPropagationStopped(),v.current||x.stopPropagation())})})),w&&b.createElement(YG,{control:f,bubbles:!v.current,name:r,value:a,checked:i,required:o,disabled:s,style:{transform:"translateX(-100%)"}}))}),KG="RadioIndicator",GG=b.forwardRef((t,e)=>{const{__scopeRadio:n,forceMount:r,...i}=t,o=UG(KG,n);return b.createElement(Mt,{present:r||o.checked},b.createElement(me.span,U({"data-state":yC(o.checked),"data-disabled":o.disabled?"":void 0},i,{ref:e})))}),YG=t=>{const{control:e,checked:n,bubbles:r=!0,...i}=t,o=b.useRef(null),s=lh(n),a=rh(e);return b.useEffect(()=>{const c=o.current,h=window.HTMLInputElement.prototype,d=Object.getOwnPropertyDescriptor(h,"checked").set;if(s!==n&&d){const m=new Event("click",{bubbles:r});d.call(c,n),c.dispatchEvent(m)}},[s,n,r]),b.createElement("input",U({type:"radio","aria-hidden":!0,defaultChecked:n},i,{tabIndex:-1,ref:o,style:{...t.style,...a,position:"absolute",pointerEvents:"none",opacity:0,margin:0}}))};function yC(t){return t?"checked":"unchecked"}const XG=["ArrowUp","ArrowDown","ArrowLeft","ArrowRight"],CC="RadioGroup",[ZG,ute]=bt(CC,[Bs,xC]),$C=Bs(),SC=xC(),[QG,JG]=ZG(CC),eY=b.forwardRef((t,e)=>{const{__scopeRadioGroup:n,name:r,defaultValue:i,value:o,required:s=!1,disabled:a=!1,orientation:c,dir:h,loop:f=!0,onValueChange:d,...m}=t,v=$C(n),w=$o(h),[x,C]=_t({prop:o,defaultProp:i,onChange:d});return b.createElement(QG,{scope:n,name:r,required:s,disabled:a,value:x,onValueChange:C},b.createElement(Pg,U({asChild:!0},v,{orientation:c,dir:w,loop:f}),b.createElement(me.div,U({role:"radiogroup","aria-required":s,"aria-orientation":c,"data-disabled":a?"":void 0,dir:w},m,{ref:e}))))}),tY="RadioGroupItem",nY=b.forwardRef((t,e)=>{const{__scopeRadioGroup:n,disabled:r,...i}=t,o=JG(tY,n),s=o.disabled||r,a=$C(n),c=SC(n),h=b.useRef(null),f=ye(e,h),d=o.value===i.value,m=b.useRef(!1);return b.useEffect(()=>{const v=x=>{XG.includes(x.key)&&(m.current=!0)},w=()=>m.current=!1;return document.addEventListener("keydown",v),document.addEventListener("keyup",w),()=>{document.removeEventListener("keydown",v),document.removeEventListener("keyup",w)}},[]),b.createElement(Wg,U({asChild:!0},a,{focusable:!s,active:d}),b.createElement(qG,U({disabled:s,required:o.required,checked:d},c,i,{name:o.name,ref:f,onCheck:()=>o.onValueChange(i.value),onKeyDown:ne(v=>{v.key==="Enter"&&v.preventDefault()}),onFocus:ne(i.onFocus,()=>{var v;m.current&&((v=h.current)===null||v===void 0||v.click())})})))}),rY=b.forwardRef((t,e)=>{const{__scopeRadioGroup:n,...r}=t,i=SC(n);return b.createElement(GG,U({},i,r,{ref:e}))}),iY=eY,oY=nY,sY=rY,AC="Switch",[aY,hte]=bt(AC),[lY,cY]=aY(AC),uY=b.forwardRef((t,e)=>{const{__scopeSwitch:n,name:r,checked:i,defaultChecked:o,required:s,disabled:a,value:c="on",onCheckedChange:h,...f}=t,[d,m]=b.useState(null),v=ye(e,A=>m(A)),w=b.useRef(!1),x=d?!!d.closest("form"):!0,[C=!1,S]=_t({prop:i,defaultProp:o,onChange:h});return b.createElement(lY,{scope:n,checked:C,disabled:a},b.createElement(me.button,U({type:"button",role:"switch","aria-checked":C,"aria-required":s,"data-state":RC(C),"data-disabled":a?"":void 0,disabled:a,value:c},f,{ref:v,onClick:ne(t.onClick,A=>{S(T=>!T),x&&(w.current=A.isPropagationStopped(),w.current||A.stopPropagation())})})),x&&b.createElement(dY,{control:d,bubbles:!w.current,name:r,value:c,checked:C,required:s,disabled:a,style:{transform:"translateX(-100%)"}}))}),hY="SwitchThumb",fY=b.forwardRef((t,e)=>{const{__scopeSwitch:n,...r}=t,i=cY(hY,n);return b.createElement(me.span,U({"data-state":RC(i.checked),"data-disabled":i.disabled?"":void 0},r,{ref:e}))}),dY=t=>{const{control:e,checked:n,bubbles:r=!0,...i}=t,o=b.useRef(null),s=lh(n),a=rh(e);return b.useEffect(()=>{const c=o.current,h=window.HTMLInputElement.prototype,d=Object.getOwnPropertyDescriptor(h,"checked").set;if(s!==n&&d){const m=new Event("click",{bubbles:r});d.call(c,n),c.dispatchEvent(m)}},[s,n,r]),b.createElement("input",U({type:"checkbox","aria-hidden":!0,defaultChecked:n},i,{tabIndex:-1,ref:o,style:{...t.style,...a,position:"absolute",pointerEvents:"none",opacity:0,margin:0}}))};function RC(t){return t?"checked":"unchecked"}const gY=uY,mY=fY,kC="Tabs",[pY,fte]=bt(kC,[Bs]),TC=Bs(),[vY,Em]=pY(kC),bY=b.forwardRef((t,e)=>{const{__scopeTabs:n,value:r,onValueChange:i,defaultValue:o,orientation:s="horizontal",dir:a,activationMode:c="automatic",...h}=t,f=$o(a),[d,m]=_t({prop:r,onChange:i,defaultProp:o});return b.createElement(vY,{scope:n,baseId:Lt(),value:d,onValueChange:m,orientation:s,dir:f,activationMode:c},b.createElement(me.div,U({dir:f,"data-orientation":s},h,{ref:e})))}),wY="TabsList",xY=b.forwardRef((t,e)=>{const{__scopeTabs:n,loop:r=!0,...i}=t,o=Em(wY,n),s=TC(n);return b.createElement(Pg,U({asChild:!0},s,{orientation:o.orientation,dir:o.dir,loop:r}),b.createElement(me.div,U({role:"tablist","aria-orientation":o.orientation},i,{ref:e})))}),yY="TabsTrigger",CY=b.forwardRef((t,e)=>{const{__scopeTabs:n,value:r,disabled:i=!1,...o}=t,s=Em(yY,n),a=TC(n),c=MC(s.baseId,r),h=EC(s.baseId,r),f=r===s.value;return b.createElement(Wg,U({asChild:!0},a,{focusable:!i,active:f}),b.createElement(me.button,U({type:"button",role:"tab","aria-selected":f,"aria-controls":h,"data-state":f?"active":"inactive","data-disabled":i?"":void 0,disabled:i,id:c},o,{ref:e,onMouseDown:ne(t.onMouseDown,d=>{!i&&d.button===0&&d.ctrlKey===!1?s.onValueChange(r):d.preventDefault()}),onKeyDown:ne(t.onKeyDown,d=>{[" ","Enter"].includes(d.key)&&s.onValueChange(r)}),onFocus:ne(t.onFocus,()=>{const d=s.activationMode!=="manual";!f&&!i&&d&&s.onValueChange(r)})})))}),$Y="TabsContent",SY=b.forwardRef((t,e)=>{const{__scopeTabs:n,value:r,forceMount:i,children:o,...s}=t,a=Em($Y,n),c=MC(a.baseId,r),h=EC(a.baseId,r),f=r===a.value,d=b.useRef(f);return b.useEffect(()=>{const m=requestAnimationFrame(()=>d.current=!1);return()=>cancelAnimationFrame(m)},[]),b.createElement(Mt,{present:i||f},({present:m})=>b.createElement(me.div,U({"data-state":f?"active":"inactive","data-orientation":a.orientation,role:"tabpanel","aria-labelledby":c,hidden:!m,id:h,tabIndex:0},s,{ref:e,style:{...t.style,animationDuration:d.current?"0s":void 0}}),m&&o))});function MC(t,e){return`${t}-trigger-${e}`}function EC(t,e){return`${t}-content-${e}`}const AY=bY,RY=xY,kY=CY,TY=SY;var Jo=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function MY(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}function EY(t){if(t.__esModule)return t;var e=t.default;if(typeof e=="function"){var n=function r(){return this instanceof r?Reflect.construct(e,arguments,this.constructor):e.apply(this,arguments)};n.prototype=e.prototype}else n={};return Object.defineProperty(n,"__esModule",{value:!0}),Object.keys(t).forEach(function(r){var i=Object.getOwnPropertyDescriptor(t,r);Object.defineProperty(n,r,i.get?i:{enumerable:!0,get:function(){return t[r]}})}),n}var Yu={exports:{}};/**
64
- * @license
65
- * Lodash <https://lodash.com/>
66
- * Copyright OpenJS Foundation and other contributors <https://openjsf.org/>
67
- * Released under MIT license <https://lodash.com/license>
68
- * Based on Underscore.js 1.8.3 <http://underscorejs.org/LICENSE>
69
- * Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors
70
- */Yu.exports;(function(t,e){(function(){var n,r="4.17.21",i=200,o="Unsupported core-js use. Try https://npms.io/search?q=ponyfill.",s="Expected a function",a="Invalid `variable` option passed into `_.template`",c="__lodash_hash_undefined__",h=500,f="__lodash_placeholder__",d=1,m=2,v=4,w=1,x=2,C=1,S=2,A=4,T=8,O=16,D=32,L=64,I=128,V=256,F=512,H=30,K="...",W=800,J=16,G=1,re=2,oe=3,te=1/0,ie=9007199254740991,Y=17976931348623157e292,ue=NaN,ge=4294967295,De=ge-1,we=ge>>>1,Ve=[["ary",I],["bind",C],["bindKey",S],["curry",T],["curryRight",O],["flip",F],["partial",D],["partialRight",L],["rearg",V]],Ne="[object Arguments]",He="[object Array]",pe="[object AsyncFunction]",Oe="[object Boolean]",ke="[object Date]",Ae="[object DOMException]",_e="[object Error]",ze="[object Function]",Et="[object GeneratorFunction]",Ze="[object Map]",Pe="[object Number]",Yt="[object Null]",ft="[object Object]",Hi="[object Promise]",Ps="[object Proxy]",or="[object RegExp]",wt="[object Set]",sr="[object String]",To="[object Symbol]",Ws="[object Undefined]",Pi="[object WeakMap]",Hh="[object WeakSet]",Or="[object ArrayBuffer]",xt="[object DataView]",Ph="[object Float32Array]",Wh="[object Float64Array]",zh="[object Int8Array]",Uh="[object Int16Array]",qh="[object Int32Array]",Kh="[object Uint8Array]",Gh="[object Uint8ClampedArray]",Yh="[object Uint16Array]",Xh="[object Uint32Array]",M$=/\b__p \+= '';/g,E$=/\b(__p \+=) '' \+/g,O$=/(__e\(.*?\)|\b__t\)) \+\n'';/g,Wm=/&(?:amp|lt|gt|quot|#39);/g,zm=/[&<>"']/g,D$=RegExp(Wm.source),I$=RegExp(zm.source),_$=/<%-([\s\S]+?)%>/g,L$=/<%([\s\S]+?)%>/g,Um=/<%=([\s\S]+?)%>/g,B$=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,N$=/^\w*$/,j$=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,Zh=/[\\^$.*+?()[\]{}|]/g,F$=RegExp(Zh.source),Qh=/^\s+/,V$=/\s/,H$=/\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/,P$=/\{\n\/\* \[wrapped with (.+)\] \*/,W$=/,? & /,z$=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g,U$=/[()=,{}\[\]\/\s]/,q$=/\\(\\)?/g,K$=/\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g,qm=/\w*$/,G$=/^[-+]0x[0-9a-f]+$/i,Y$=/^0b[01]+$/i,X$=/^\[object .+?Constructor\]$/,Z$=/^0o[0-7]+$/i,Q$=/^(?:0|[1-9]\d*)$/,J$=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,Cl=/($^)/,e8=/['\n\r\u2028\u2029\\]/g,$l="\\ud800-\\udfff",t8="\\u0300-\\u036f",n8="\\ufe20-\\ufe2f",r8="\\u20d0-\\u20ff",Km=t8+n8+r8,Gm="\\u2700-\\u27bf",Ym="a-z\\xdf-\\xf6\\xf8-\\xff",i8="\\xac\\xb1\\xd7\\xf7",o8="\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf",s8="\\u2000-\\u206f",a8=" \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",Xm="A-Z\\xc0-\\xd6\\xd8-\\xde",Zm="\\ufe0e\\ufe0f",Qm=i8+o8+s8+a8,Jh="['’]",l8="["+$l+"]",Jm="["+Qm+"]",Sl="["+Km+"]",ep="\\d+",c8="["+Gm+"]",tp="["+Ym+"]",np="[^"+$l+Qm+ep+Gm+Ym+Xm+"]",ef="\\ud83c[\\udffb-\\udfff]",u8="(?:"+Sl+"|"+ef+")",rp="[^"+$l+"]",tf="(?:\\ud83c[\\udde6-\\uddff]){2}",nf="[\\ud800-\\udbff][\\udc00-\\udfff]",Mo="["+Xm+"]",ip="\\u200d",op="(?:"+tp+"|"+np+")",h8="(?:"+Mo+"|"+np+")",sp="(?:"+Jh+"(?:d|ll|m|re|s|t|ve))?",ap="(?:"+Jh+"(?:D|LL|M|RE|S|T|VE))?",lp=u8+"?",cp="["+Zm+"]?",f8="(?:"+ip+"(?:"+[rp,tf,nf].join("|")+")"+cp+lp+")*",d8="\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",g8="\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])",up=cp+lp+f8,m8="(?:"+[c8,tf,nf].join("|")+")"+up,p8="(?:"+[rp+Sl+"?",Sl,tf,nf,l8].join("|")+")",v8=RegExp(Jh,"g"),b8=RegExp(Sl,"g"),rf=RegExp(ef+"(?="+ef+")|"+p8+up,"g"),w8=RegExp([Mo+"?"+tp+"+"+sp+"(?="+[Jm,Mo,"$"].join("|")+")",h8+"+"+ap+"(?="+[Jm,Mo+op,"$"].join("|")+")",Mo+"?"+op+"+"+sp,Mo+"+"+ap,g8,d8,ep,m8].join("|"),"g"),x8=RegExp("["+ip+$l+Km+Zm+"]"),y8=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/,C8=["Array","Buffer","DataView","Date","Error","Float32Array","Float64Array","Function","Int8Array","Int16Array","Int32Array","Map","Math","Object","Promise","RegExp","Set","String","Symbol","TypeError","Uint8Array","Uint8ClampedArray","Uint16Array","Uint32Array","WeakMap","_","clearTimeout","isFinite","parseInt","setTimeout"],$8=-1,it={};it[Ph]=it[Wh]=it[zh]=it[Uh]=it[qh]=it[Kh]=it[Gh]=it[Yh]=it[Xh]=!0,it[Ne]=it[He]=it[Or]=it[Oe]=it[xt]=it[ke]=it[_e]=it[ze]=it[Ze]=it[Pe]=it[ft]=it[or]=it[wt]=it[sr]=it[Pi]=!1;var rt={};rt[Ne]=rt[He]=rt[Or]=rt[xt]=rt[Oe]=rt[ke]=rt[Ph]=rt[Wh]=rt[zh]=rt[Uh]=rt[qh]=rt[Ze]=rt[Pe]=rt[ft]=rt[or]=rt[wt]=rt[sr]=rt[To]=rt[Kh]=rt[Gh]=rt[Yh]=rt[Xh]=!0,rt[_e]=rt[ze]=rt[Pi]=!1;var S8={À:"A",Á:"A",Â:"A",Ã:"A",Ä:"A",Å:"A",à:"a",á:"a",â:"a",ã:"a",ä:"a",å:"a",Ç:"C",ç:"c",Ð:"D",ð:"d",È:"E",É:"E",Ê:"E",Ë:"E",è:"e",é:"e",ê:"e",ë:"e",Ì:"I",Í:"I",Î:"I",Ï:"I",ì:"i",í:"i",î:"i",ï:"i",Ñ:"N",ñ:"n",Ò:"O",Ó:"O",Ô:"O",Õ:"O",Ö:"O",Ø:"O",ò:"o",ó:"o",ô:"o",õ:"o",ö:"o",ø:"o",Ù:"U",Ú:"U",Û:"U",Ü:"U",ù:"u",ú:"u",û:"u",ü:"u",Ý:"Y",ý:"y",ÿ:"y",Æ:"Ae",æ:"ae",Þ:"Th",þ:"th",ß:"ss",Ā:"A",Ă:"A",Ą:"A",ā:"a",ă:"a",ą:"a",Ć:"C",Ĉ:"C",Ċ:"C",Č:"C",ć:"c",ĉ:"c",ċ:"c",č:"c",Ď:"D",Đ:"D",ď:"d",đ:"d",Ē:"E",Ĕ:"E",Ė:"E",Ę:"E",Ě:"E",ē:"e",ĕ:"e",ė:"e",ę:"e",ě:"e",Ĝ:"G",Ğ:"G",Ġ:"G",Ģ:"G",ĝ:"g",ğ:"g",ġ:"g",ģ:"g",Ĥ:"H",Ħ:"H",ĥ:"h",ħ:"h",Ĩ:"I",Ī:"I",Ĭ:"I",Į:"I",İ:"I",ĩ:"i",ī:"i",ĭ:"i",į:"i",ı:"i",Ĵ:"J",ĵ:"j",Ķ:"K",ķ:"k",ĸ:"k",Ĺ:"L",Ļ:"L",Ľ:"L",Ŀ:"L",Ł:"L",ĺ:"l",ļ:"l",ľ:"l",ŀ:"l",ł:"l",Ń:"N",Ņ:"N",Ň:"N",Ŋ:"N",ń:"n",ņ:"n",ň:"n",ŋ:"n",Ō:"O",Ŏ:"O",Ő:"O",ō:"o",ŏ:"o",ő:"o",Ŕ:"R",Ŗ:"R",Ř:"R",ŕ:"r",ŗ:"r",ř:"r",Ś:"S",Ŝ:"S",Ş:"S",Š:"S",ś:"s",ŝ:"s",ş:"s",š:"s",Ţ:"T",Ť:"T",Ŧ:"T",ţ:"t",ť:"t",ŧ:"t",Ũ:"U",Ū:"U",Ŭ:"U",Ů:"U",Ű:"U",Ų:"U",ũ:"u",ū:"u",ŭ:"u",ů:"u",ű:"u",ų:"u",Ŵ:"W",ŵ:"w",Ŷ:"Y",ŷ:"y",Ÿ:"Y",Ź:"Z",Ż:"Z",Ž:"Z",ź:"z",ż:"z",ž:"z",IJ:"IJ",ij:"ij",Œ:"Oe",œ:"oe",ʼn:"'n",ſ:"s"},A8={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#39;"},R8={"&amp;":"&","&lt;":"<","&gt;":">","&quot;":'"',"&#39;":"'"},k8={"\\":"\\","'":"'","\n":"n","\r":"r","\u2028":"u2028","\u2029":"u2029"},T8=parseFloat,M8=parseInt,hp=typeof Jo=="object"&&Jo&&Jo.Object===Object&&Jo,E8=typeof self=="object"&&self&&self.Object===Object&&self,Nt=hp||E8||Function("return this")(),of=e&&!e.nodeType&&e,Wi=of&&!0&&t&&!t.nodeType&&t,fp=Wi&&Wi.exports===of,sf=fp&&hp.process,Mn=function(){try{var N=Wi&&Wi.require&&Wi.require("util").types;return N||sf&&sf.binding&&sf.binding("util")}catch{}}(),dp=Mn&&Mn.isArrayBuffer,gp=Mn&&Mn.isDate,mp=Mn&&Mn.isMap,pp=Mn&&Mn.isRegExp,vp=Mn&&Mn.isSet,bp=Mn&&Mn.isTypedArray;function pn(N,q,P){switch(P.length){case 0:return N.call(q);case 1:return N.call(q,P[0]);case 2:return N.call(q,P[0],P[1]);case 3:return N.call(q,P[0],P[1],P[2])}return N.apply(q,P)}function O8(N,q,P,de){for(var Te=-1,Ye=N==null?0:N.length;++Te<Ye;){var St=N[Te];q(de,St,P(St),N)}return de}function En(N,q){for(var P=-1,de=N==null?0:N.length;++P<de&&q(N[P],P,N)!==!1;);return N}function D8(N,q){for(var P=N==null?0:N.length;P--&&q(N[P],P,N)!==!1;);return N}function wp(N,q){for(var P=-1,de=N==null?0:N.length;++P<de;)if(!q(N[P],P,N))return!1;return!0}function li(N,q){for(var P=-1,de=N==null?0:N.length,Te=0,Ye=[];++P<de;){var St=N[P];q(St,P,N)&&(Ye[Te++]=St)}return Ye}function Al(N,q){var P=N==null?0:N.length;return!!P&&Eo(N,q,0)>-1}function af(N,q,P){for(var de=-1,Te=N==null?0:N.length;++de<Te;)if(P(q,N[de]))return!0;return!1}function at(N,q){for(var P=-1,de=N==null?0:N.length,Te=Array(de);++P<de;)Te[P]=q(N[P],P,N);return Te}function ci(N,q){for(var P=-1,de=q.length,Te=N.length;++P<de;)N[Te+P]=q[P];return N}function lf(N,q,P,de){var Te=-1,Ye=N==null?0:N.length;for(de&&Ye&&(P=N[++Te]);++Te<Ye;)P=q(P,N[Te],Te,N);return P}function I8(N,q,P,de){var Te=N==null?0:N.length;for(de&&Te&&(P=N[--Te]);Te--;)P=q(P,N[Te],Te,N);return P}function cf(N,q){for(var P=-1,de=N==null?0:N.length;++P<de;)if(q(N[P],P,N))return!0;return!1}var _8=uf("length");function L8(N){return N.split("")}function B8(N){return N.match(z$)||[]}function xp(N,q,P){var de;return P(N,function(Te,Ye,St){if(q(Te,Ye,St))return de=Ye,!1}),de}function Rl(N,q,P,de){for(var Te=N.length,Ye=P+(de?1:-1);de?Ye--:++Ye<Te;)if(q(N[Ye],Ye,N))return Ye;return-1}function Eo(N,q,P){return q===q?G8(N,q,P):Rl(N,yp,P)}function N8(N,q,P,de){for(var Te=P-1,Ye=N.length;++Te<Ye;)if(de(N[Te],q))return Te;return-1}function yp(N){return N!==N}function Cp(N,q){var P=N==null?0:N.length;return P?ff(N,q)/P:ue}function uf(N){return function(q){return q==null?n:q[N]}}function hf(N){return function(q){return N==null?n:N[q]}}function $p(N,q,P,de,Te){return Te(N,function(Ye,St,Je){P=de?(de=!1,Ye):q(P,Ye,St,Je)}),P}function j8(N,q){var P=N.length;for(N.sort(q);P--;)N[P]=N[P].value;return N}function ff(N,q){for(var P,de=-1,Te=N.length;++de<Te;){var Ye=q(N[de]);Ye!==n&&(P=P===n?Ye:P+Ye)}return P}function df(N,q){for(var P=-1,de=Array(N);++P<N;)de[P]=q(P);return de}function F8(N,q){return at(q,function(P){return[P,N[P]]})}function Sp(N){return N&&N.slice(0,Tp(N)+1).replace(Qh,"")}function vn(N){return function(q){return N(q)}}function gf(N,q){return at(q,function(P){return N[P]})}function zs(N,q){return N.has(q)}function Ap(N,q){for(var P=-1,de=N.length;++P<de&&Eo(q,N[P],0)>-1;);return P}function Rp(N,q){for(var P=N.length;P--&&Eo(q,N[P],0)>-1;);return P}function V8(N,q){for(var P=N.length,de=0;P--;)N[P]===q&&++de;return de}var H8=hf(S8),P8=hf(A8);function W8(N){return"\\"+k8[N]}function z8(N,q){return N==null?n:N[q]}function Oo(N){return x8.test(N)}function U8(N){return y8.test(N)}function q8(N){for(var q,P=[];!(q=N.next()).done;)P.push(q.value);return P}function mf(N){var q=-1,P=Array(N.size);return N.forEach(function(de,Te){P[++q]=[Te,de]}),P}function kp(N,q){return function(P){return N(q(P))}}function ui(N,q){for(var P=-1,de=N.length,Te=0,Ye=[];++P<de;){var St=N[P];(St===q||St===f)&&(N[P]=f,Ye[Te++]=P)}return Ye}function kl(N){var q=-1,P=Array(N.size);return N.forEach(function(de){P[++q]=de}),P}function K8(N){var q=-1,P=Array(N.size);return N.forEach(function(de){P[++q]=[de,de]}),P}function G8(N,q,P){for(var de=P-1,Te=N.length;++de<Te;)if(N[de]===q)return de;return-1}function Y8(N,q,P){for(var de=P+1;de--;)if(N[de]===q)return de;return de}function Do(N){return Oo(N)?Z8(N):_8(N)}function Wn(N){return Oo(N)?Q8(N):L8(N)}function Tp(N){for(var q=N.length;q--&&V$.test(N.charAt(q)););return q}var X8=hf(R8);function Z8(N){for(var q=rf.lastIndex=0;rf.test(N);)++q;return q}function Q8(N){return N.match(rf)||[]}function J8(N){return N.match(w8)||[]}var e7=function N(q){q=q==null?Nt:Io.defaults(Nt.Object(),q,Io.pick(Nt,C8));var P=q.Array,de=q.Date,Te=q.Error,Ye=q.Function,St=q.Math,Je=q.Object,pf=q.RegExp,t7=q.String,On=q.TypeError,Tl=P.prototype,n7=Ye.prototype,_o=Je.prototype,Ml=q["__core-js_shared__"],El=n7.toString,Qe=_o.hasOwnProperty,r7=0,Mp=function(){var l=/[^.]+$/.exec(Ml&&Ml.keys&&Ml.keys.IE_PROTO||"");return l?"Symbol(src)_1."+l:""}(),Ol=_o.toString,i7=El.call(Je),o7=Nt._,s7=pf("^"+El.call(Qe).replace(Zh,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),Dl=fp?q.Buffer:n,hi=q.Symbol,Il=q.Uint8Array,Ep=Dl?Dl.allocUnsafe:n,_l=kp(Je.getPrototypeOf,Je),Op=Je.create,Dp=_o.propertyIsEnumerable,Ll=Tl.splice,Ip=hi?hi.isConcatSpreadable:n,Us=hi?hi.iterator:n,zi=hi?hi.toStringTag:n,Bl=function(){try{var l=Yi(Je,"defineProperty");return l({},"",{}),l}catch{}}(),a7=q.clearTimeout!==Nt.clearTimeout&&q.clearTimeout,l7=de&&de.now!==Nt.Date.now&&de.now,c7=q.setTimeout!==Nt.setTimeout&&q.setTimeout,Nl=St.ceil,jl=St.floor,vf=Je.getOwnPropertySymbols,u7=Dl?Dl.isBuffer:n,_p=q.isFinite,h7=Tl.join,f7=kp(Je.keys,Je),At=St.max,Pt=St.min,d7=de.now,g7=q.parseInt,Lp=St.random,m7=Tl.reverse,bf=Yi(q,"DataView"),qs=Yi(q,"Map"),wf=Yi(q,"Promise"),Lo=Yi(q,"Set"),Ks=Yi(q,"WeakMap"),Gs=Yi(Je,"create"),Fl=Ks&&new Ks,Bo={},p7=Xi(bf),v7=Xi(qs),b7=Xi(wf),w7=Xi(Lo),x7=Xi(Ks),Vl=hi?hi.prototype:n,Ys=Vl?Vl.valueOf:n,Bp=Vl?Vl.toString:n;function M(l){if(ht(l)&&!Ee(l)&&!(l instanceof We)){if(l instanceof Dn)return l;if(Qe.call(l,"__wrapped__"))return N2(l)}return new Dn(l)}var No=function(){function l(){}return function(u){if(!ct(u))return{};if(Op)return Op(u);l.prototype=u;var g=new l;return l.prototype=n,g}}();function Hl(){}function Dn(l,u){this.__wrapped__=l,this.__actions__=[],this.__chain__=!!u,this.__index__=0,this.__values__=n}M.templateSettings={escape:_$,evaluate:L$,interpolate:Um,variable:"",imports:{_:M}},M.prototype=Hl.prototype,M.prototype.constructor=M,Dn.prototype=No(Hl.prototype),Dn.prototype.constructor=Dn;function We(l){this.__wrapped__=l,this.__actions__=[],this.__dir__=1,this.__filtered__=!1,this.__iteratees__=[],this.__takeCount__=ge,this.__views__=[]}function y7(){var l=new We(this.__wrapped__);return l.__actions__=rn(this.__actions__),l.__dir__=this.__dir__,l.__filtered__=this.__filtered__,l.__iteratees__=rn(this.__iteratees__),l.__takeCount__=this.__takeCount__,l.__views__=rn(this.__views__),l}function C7(){if(this.__filtered__){var l=new We(this);l.__dir__=-1,l.__filtered__=!0}else l=this.clone(),l.__dir__*=-1;return l}function $7(){var l=this.__wrapped__.value(),u=this.__dir__,g=Ee(l),y=u<0,R=g?l.length:0,E=LS(0,R,this.__views__),_=E.start,B=E.end,j=B-_,X=y?B:_-1,Z=this.__iteratees__,ee=Z.length,ae=0,ve=Pt(j,this.__takeCount__);if(!g||!y&&R==j&&ve==j)return s2(l,this.__actions__);var $e=[];e:for(;j--&&ae<ve;){X+=u;for(var Le=-1,Se=l[X];++Le<ee;){var Fe=Z[Le],Ue=Fe.iteratee,xn=Fe.type,Qt=Ue(Se);if(xn==re)Se=Qt;else if(!Qt){if(xn==G)continue e;break e}}$e[ae++]=Se}return $e}We.prototype=No(Hl.prototype),We.prototype.constructor=We;function Ui(l){var u=-1,g=l==null?0:l.length;for(this.clear();++u<g;){var y=l[u];this.set(y[0],y[1])}}function S7(){this.__data__=Gs?Gs(null):{},this.size=0}function A7(l){var u=this.has(l)&&delete this.__data__[l];return this.size-=u?1:0,u}function R7(l){var u=this.__data__;if(Gs){var g=u[l];return g===c?n:g}return Qe.call(u,l)?u[l]:n}function k7(l){var u=this.__data__;return Gs?u[l]!==n:Qe.call(u,l)}function T7(l,u){var g=this.__data__;return this.size+=this.has(l)?0:1,g[l]=Gs&&u===n?c:u,this}Ui.prototype.clear=S7,Ui.prototype.delete=A7,Ui.prototype.get=R7,Ui.prototype.has=k7,Ui.prototype.set=T7;function Dr(l){var u=-1,g=l==null?0:l.length;for(this.clear();++u<g;){var y=l[u];this.set(y[0],y[1])}}function M7(){this.__data__=[],this.size=0}function E7(l){var u=this.__data__,g=Pl(u,l);if(g<0)return!1;var y=u.length-1;return g==y?u.pop():Ll.call(u,g,1),--this.size,!0}function O7(l){var u=this.__data__,g=Pl(u,l);return g<0?n:u[g][1]}function D7(l){return Pl(this.__data__,l)>-1}function I7(l,u){var g=this.__data__,y=Pl(g,l);return y<0?(++this.size,g.push([l,u])):g[y][1]=u,this}Dr.prototype.clear=M7,Dr.prototype.delete=E7,Dr.prototype.get=O7,Dr.prototype.has=D7,Dr.prototype.set=I7;function Ir(l){var u=-1,g=l==null?0:l.length;for(this.clear();++u<g;){var y=l[u];this.set(y[0],y[1])}}function _7(){this.size=0,this.__data__={hash:new Ui,map:new(qs||Dr),string:new Ui}}function L7(l){var u=ec(this,l).delete(l);return this.size-=u?1:0,u}function B7(l){return ec(this,l).get(l)}function N7(l){return ec(this,l).has(l)}function j7(l,u){var g=ec(this,l),y=g.size;return g.set(l,u),this.size+=g.size==y?0:1,this}Ir.prototype.clear=_7,Ir.prototype.delete=L7,Ir.prototype.get=B7,Ir.prototype.has=N7,Ir.prototype.set=j7;function qi(l){var u=-1,g=l==null?0:l.length;for(this.__data__=new Ir;++u<g;)this.add(l[u])}function F7(l){return this.__data__.set(l,c),this}function V7(l){return this.__data__.has(l)}qi.prototype.add=qi.prototype.push=F7,qi.prototype.has=V7;function zn(l){var u=this.__data__=new Dr(l);this.size=u.size}function H7(){this.__data__=new Dr,this.size=0}function P7(l){var u=this.__data__,g=u.delete(l);return this.size=u.size,g}function W7(l){return this.__data__.get(l)}function z7(l){return this.__data__.has(l)}function U7(l,u){var g=this.__data__;if(g instanceof Dr){var y=g.__data__;if(!qs||y.length<i-1)return y.push([l,u]),this.size=++g.size,this;g=this.__data__=new Ir(y)}return g.set(l,u),this.size=g.size,this}zn.prototype.clear=H7,zn.prototype.delete=P7,zn.prototype.get=W7,zn.prototype.has=z7,zn.prototype.set=U7;function Np(l,u){var g=Ee(l),y=!g&&Zi(l),R=!g&&!y&&pi(l),E=!g&&!y&&!R&&Ho(l),_=g||y||R||E,B=_?df(l.length,t7):[],j=B.length;for(var X in l)(u||Qe.call(l,X))&&!(_&&(X=="length"||R&&(X=="offset"||X=="parent")||E&&(X=="buffer"||X=="byteLength"||X=="byteOffset")||Nr(X,j)))&&B.push(X);return B}function jp(l){var u=l.length;return u?l[Ef(0,u-1)]:n}function q7(l,u){return tc(rn(l),Ki(u,0,l.length))}function K7(l){return tc(rn(l))}function xf(l,u,g){(g!==n&&!Un(l[u],g)||g===n&&!(u in l))&&_r(l,u,g)}function Xs(l,u,g){var y=l[u];(!(Qe.call(l,u)&&Un(y,g))||g===n&&!(u in l))&&_r(l,u,g)}function Pl(l,u){for(var g=l.length;g--;)if(Un(l[g][0],u))return g;return-1}function G7(l,u,g,y){return fi(l,function(R,E,_){u(y,R,g(R),_)}),y}function Fp(l,u){return l&&lr(u,Ot(u),l)}function Y7(l,u){return l&&lr(u,sn(u),l)}function _r(l,u,g){u=="__proto__"&&Bl?Bl(l,u,{configurable:!0,enumerable:!0,value:g,writable:!0}):l[u]=g}function yf(l,u){for(var g=-1,y=u.length,R=P(y),E=l==null;++g<y;)R[g]=E?n:td(l,u[g]);return R}function Ki(l,u,g){return l===l&&(g!==n&&(l=l<=g?l:g),u!==n&&(l=l>=u?l:u)),l}function In(l,u,g,y,R,E){var _,B=u&d,j=u&m,X=u&v;if(g&&(_=R?g(l,y,R,E):g(l)),_!==n)return _;if(!ct(l))return l;var Z=Ee(l);if(Z){if(_=NS(l),!B)return rn(l,_)}else{var ee=Wt(l),ae=ee==ze||ee==Et;if(pi(l))return c2(l,B);if(ee==ft||ee==Ne||ae&&!R){if(_=j||ae?{}:T2(l),!B)return j?RS(l,Y7(_,l)):AS(l,Fp(_,l))}else{if(!rt[ee])return R?l:{};_=jS(l,ee,B)}}E||(E=new zn);var ve=E.get(l);if(ve)return ve;E.set(l,_),rv(l)?l.forEach(function(Se){_.add(In(Se,u,g,Se,l,E))}):tv(l)&&l.forEach(function(Se,Fe){_.set(Fe,In(Se,u,g,Fe,l,E))});var $e=X?j?Hf:Vf:j?sn:Ot,Le=Z?n:$e(l);return En(Le||l,function(Se,Fe){Le&&(Fe=Se,Se=l[Fe]),Xs(_,Fe,In(Se,u,g,Fe,l,E))}),_}function X7(l){var u=Ot(l);return function(g){return Vp(g,l,u)}}function Vp(l,u,g){var y=g.length;if(l==null)return!y;for(l=Je(l);y--;){var R=g[y],E=u[R],_=l[R];if(_===n&&!(R in l)||!E(_))return!1}return!0}function Hp(l,u,g){if(typeof l!="function")throw new On(s);return ra(function(){l.apply(n,g)},u)}function Zs(l,u,g,y){var R=-1,E=Al,_=!0,B=l.length,j=[],X=u.length;if(!B)return j;g&&(u=at(u,vn(g))),y?(E=af,_=!1):u.length>=i&&(E=zs,_=!1,u=new qi(u));e:for(;++R<B;){var Z=l[R],ee=g==null?Z:g(Z);if(Z=y||Z!==0?Z:0,_&&ee===ee){for(var ae=X;ae--;)if(u[ae]===ee)continue e;j.push(Z)}else E(u,ee,y)||j.push(Z)}return j}var fi=g2(ar),Pp=g2($f,!0);function Z7(l,u){var g=!0;return fi(l,function(y,R,E){return g=!!u(y,R,E),g}),g}function Wl(l,u,g){for(var y=-1,R=l.length;++y<R;){var E=l[y],_=u(E);if(_!=null&&(B===n?_===_&&!wn(_):g(_,B)))var B=_,j=E}return j}function Q7(l,u,g,y){var R=l.length;for(g=Ie(g),g<0&&(g=-g>R?0:R+g),y=y===n||y>R?R:Ie(y),y<0&&(y+=R),y=g>y?0:ov(y);g<y;)l[g++]=u;return l}function Wp(l,u){var g=[];return fi(l,function(y,R,E){u(y,R,E)&&g.push(y)}),g}function jt(l,u,g,y,R){var E=-1,_=l.length;for(g||(g=VS),R||(R=[]);++E<_;){var B=l[E];u>0&&g(B)?u>1?jt(B,u-1,g,y,R):ci(R,B):y||(R[R.length]=B)}return R}var Cf=m2(),zp=m2(!0);function ar(l,u){return l&&Cf(l,u,Ot)}function $f(l,u){return l&&zp(l,u,Ot)}function zl(l,u){return li(u,function(g){return jr(l[g])})}function Gi(l,u){u=gi(u,l);for(var g=0,y=u.length;l!=null&&g<y;)l=l[cr(u[g++])];return g&&g==y?l:n}function Up(l,u,g){var y=u(l);return Ee(l)?y:ci(y,g(l))}function Xt(l){return l==null?l===n?Ws:Yt:zi&&zi in Je(l)?_S(l):KS(l)}function Sf(l,u){return l>u}function J7(l,u){return l!=null&&Qe.call(l,u)}function eS(l,u){return l!=null&&u in Je(l)}function tS(l,u,g){return l>=Pt(u,g)&&l<At(u,g)}function Af(l,u,g){for(var y=g?af:Al,R=l[0].length,E=l.length,_=E,B=P(E),j=1/0,X=[];_--;){var Z=l[_];_&&u&&(Z=at(Z,vn(u))),j=Pt(Z.length,j),B[_]=!g&&(u||R>=120&&Z.length>=120)?new qi(_&&Z):n}Z=l[0];var ee=-1,ae=B[0];e:for(;++ee<R&&X.length<j;){var ve=Z[ee],$e=u?u(ve):ve;if(ve=g||ve!==0?ve:0,!(ae?zs(ae,$e):y(X,$e,g))){for(_=E;--_;){var Le=B[_];if(!(Le?zs(Le,$e):y(l[_],$e,g)))continue e}ae&&ae.push($e),X.push(ve)}}return X}function nS(l,u,g,y){return ar(l,function(R,E,_){u(y,g(R),E,_)}),y}function Qs(l,u,g){u=gi(u,l),l=D2(l,u);var y=l==null?l:l[cr(Ln(u))];return y==null?n:pn(y,l,g)}function qp(l){return ht(l)&&Xt(l)==Ne}function rS(l){return ht(l)&&Xt(l)==Or}function iS(l){return ht(l)&&Xt(l)==ke}function Js(l,u,g,y,R){return l===u?!0:l==null||u==null||!ht(l)&&!ht(u)?l!==l&&u!==u:oS(l,u,g,y,Js,R)}function oS(l,u,g,y,R,E){var _=Ee(l),B=Ee(u),j=_?He:Wt(l),X=B?He:Wt(u);j=j==Ne?ft:j,X=X==Ne?ft:X;var Z=j==ft,ee=X==ft,ae=j==X;if(ae&&pi(l)){if(!pi(u))return!1;_=!0,Z=!1}if(ae&&!Z)return E||(E=new zn),_||Ho(l)?A2(l,u,g,y,R,E):DS(l,u,j,g,y,R,E);if(!(g&w)){var ve=Z&&Qe.call(l,"__wrapped__"),$e=ee&&Qe.call(u,"__wrapped__");if(ve||$e){var Le=ve?l.value():l,Se=$e?u.value():u;return E||(E=new zn),R(Le,Se,g,y,E)}}return ae?(E||(E=new zn),IS(l,u,g,y,R,E)):!1}function sS(l){return ht(l)&&Wt(l)==Ze}function Rf(l,u,g,y){var R=g.length,E=R,_=!y;if(l==null)return!E;for(l=Je(l);R--;){var B=g[R];if(_&&B[2]?B[1]!==l[B[0]]:!(B[0]in l))return!1}for(;++R<E;){B=g[R];var j=B[0],X=l[j],Z=B[1];if(_&&B[2]){if(X===n&&!(j in l))return!1}else{var ee=new zn;if(y)var ae=y(X,Z,j,l,u,ee);if(!(ae===n?Js(Z,X,w|x,y,ee):ae))return!1}}return!0}function Kp(l){if(!ct(l)||PS(l))return!1;var u=jr(l)?s7:X$;return u.test(Xi(l))}function aS(l){return ht(l)&&Xt(l)==or}function lS(l){return ht(l)&&Wt(l)==wt}function cS(l){return ht(l)&&ac(l.length)&&!!it[Xt(l)]}function Gp(l){return typeof l=="function"?l:l==null?an:typeof l=="object"?Ee(l)?Zp(l[0],l[1]):Xp(l):pv(l)}function kf(l){if(!na(l))return f7(l);var u=[];for(var g in Je(l))Qe.call(l,g)&&g!="constructor"&&u.push(g);return u}function uS(l){if(!ct(l))return qS(l);var u=na(l),g=[];for(var y in l)y=="constructor"&&(u||!Qe.call(l,y))||g.push(y);return g}function Tf(l,u){return l<u}function Yp(l,u){var g=-1,y=on(l)?P(l.length):[];return fi(l,function(R,E,_){y[++g]=u(R,E,_)}),y}function Xp(l){var u=Wf(l);return u.length==1&&u[0][2]?E2(u[0][0],u[0][1]):function(g){return g===l||Rf(g,l,u)}}function Zp(l,u){return Uf(l)&&M2(u)?E2(cr(l),u):function(g){var y=td(g,l);return y===n&&y===u?nd(g,l):Js(u,y,w|x)}}function Ul(l,u,g,y,R){l!==u&&Cf(u,function(E,_){if(R||(R=new zn),ct(E))hS(l,u,_,g,Ul,y,R);else{var B=y?y(Kf(l,_),E,_+"",l,u,R):n;B===n&&(B=E),xf(l,_,B)}},sn)}function hS(l,u,g,y,R,E,_){var B=Kf(l,g),j=Kf(u,g),X=_.get(j);if(X){xf(l,g,X);return}var Z=E?E(B,j,g+"",l,u,_):n,ee=Z===n;if(ee){var ae=Ee(j),ve=!ae&&pi(j),$e=!ae&&!ve&&Ho(j);Z=j,ae||ve||$e?Ee(B)?Z=B:dt(B)?Z=rn(B):ve?(ee=!1,Z=c2(j,!0)):$e?(ee=!1,Z=u2(j,!0)):Z=[]:ia(j)||Zi(j)?(Z=B,Zi(B)?Z=sv(B):(!ct(B)||jr(B))&&(Z=T2(j))):ee=!1}ee&&(_.set(j,Z),R(Z,j,y,E,_),_.delete(j)),xf(l,g,Z)}function Qp(l,u){var g=l.length;if(g)return u+=u<0?g:0,Nr(u,g)?l[u]:n}function Jp(l,u,g){u.length?u=at(u,function(E){return Ee(E)?function(_){return Gi(_,E.length===1?E[0]:E)}:E}):u=[an];var y=-1;u=at(u,vn(Ce()));var R=Yp(l,function(E,_,B){var j=at(u,function(X){return X(E)});return{criteria:j,index:++y,value:E}});return j8(R,function(E,_){return SS(E,_,g)})}function fS(l,u){return e2(l,u,function(g,y){return nd(l,y)})}function e2(l,u,g){for(var y=-1,R=u.length,E={};++y<R;){var _=u[y],B=Gi(l,_);g(B,_)&&ea(E,gi(_,l),B)}return E}function dS(l){return function(u){return Gi(u,l)}}function Mf(l,u,g,y){var R=y?N8:Eo,E=-1,_=u.length,B=l;for(l===u&&(u=rn(u)),g&&(B=at(l,vn(g)));++E<_;)for(var j=0,X=u[E],Z=g?g(X):X;(j=R(B,Z,j,y))>-1;)B!==l&&Ll.call(B,j,1),Ll.call(l,j,1);return l}function t2(l,u){for(var g=l?u.length:0,y=g-1;g--;){var R=u[g];if(g==y||R!==E){var E=R;Nr(R)?Ll.call(l,R,1):If(l,R)}}return l}function Ef(l,u){return l+jl(Lp()*(u-l+1))}function gS(l,u,g,y){for(var R=-1,E=At(Nl((u-l)/(g||1)),0),_=P(E);E--;)_[y?E:++R]=l,l+=g;return _}function Of(l,u){var g="";if(!l||u<1||u>ie)return g;do u%2&&(g+=l),u=jl(u/2),u&&(l+=l);while(u);return g}function Be(l,u){return Gf(O2(l,u,an),l+"")}function mS(l){return jp(Po(l))}function pS(l,u){var g=Po(l);return tc(g,Ki(u,0,g.length))}function ea(l,u,g,y){if(!ct(l))return l;u=gi(u,l);for(var R=-1,E=u.length,_=E-1,B=l;B!=null&&++R<E;){var j=cr(u[R]),X=g;if(j==="__proto__"||j==="constructor"||j==="prototype")return l;if(R!=_){var Z=B[j];X=y?y(Z,j,B):n,X===n&&(X=ct(Z)?Z:Nr(u[R+1])?[]:{})}Xs(B,j,X),B=B[j]}return l}var n2=Fl?function(l,u){return Fl.set(l,u),l}:an,vS=Bl?function(l,u){return Bl(l,"toString",{configurable:!0,enumerable:!1,value:id(u),writable:!0})}:an;function bS(l){return tc(Po(l))}function _n(l,u,g){var y=-1,R=l.length;u<0&&(u=-u>R?0:R+u),g=g>R?R:g,g<0&&(g+=R),R=u>g?0:g-u>>>0,u>>>=0;for(var E=P(R);++y<R;)E[y]=l[y+u];return E}function wS(l,u){var g;return fi(l,function(y,R,E){return g=u(y,R,E),!g}),!!g}function ql(l,u,g){var y=0,R=l==null?y:l.length;if(typeof u=="number"&&u===u&&R<=we){for(;y<R;){var E=y+R>>>1,_=l[E];_!==null&&!wn(_)&&(g?_<=u:_<u)?y=E+1:R=E}return R}return Df(l,u,an,g)}function Df(l,u,g,y){var R=0,E=l==null?0:l.length;if(E===0)return 0;u=g(u);for(var _=u!==u,B=u===null,j=wn(u),X=u===n;R<E;){var Z=jl((R+E)/2),ee=g(l[Z]),ae=ee!==n,ve=ee===null,$e=ee===ee,Le=wn(ee);if(_)var Se=y||$e;else X?Se=$e&&(y||ae):B?Se=$e&&ae&&(y||!ve):j?Se=$e&&ae&&!ve&&(y||!Le):ve||Le?Se=!1:Se=y?ee<=u:ee<u;Se?R=Z+1:E=Z}return Pt(E,De)}function r2(l,u){for(var g=-1,y=l.length,R=0,E=[];++g<y;){var _=l[g],B=u?u(_):_;if(!g||!Un(B,j)){var j=B;E[R++]=_===0?0:_}}return E}function i2(l){return typeof l=="number"?l:wn(l)?ue:+l}function bn(l){if(typeof l=="string")return l;if(Ee(l))return at(l,bn)+"";if(wn(l))return Bp?Bp.call(l):"";var u=l+"";return u=="0"&&1/l==-1/0?"-0":u}function di(l,u,g){var y=-1,R=Al,E=l.length,_=!0,B=[],j=B;if(g)_=!1,R=af;else if(E>=i){var X=u?null:ES(l);if(X)return kl(X);_=!1,R=zs,j=new qi}else j=u?[]:B;e:for(;++y<E;){var Z=l[y],ee=u?u(Z):Z;if(Z=g||Z!==0?Z:0,_&&ee===ee){for(var ae=j.length;ae--;)if(j[ae]===ee)continue e;u&&j.push(ee),B.push(Z)}else R(j,ee,g)||(j!==B&&j.push(ee),B.push(Z))}return B}function If(l,u){return u=gi(u,l),l=D2(l,u),l==null||delete l[cr(Ln(u))]}function o2(l,u,g,y){return ea(l,u,g(Gi(l,u)),y)}function Kl(l,u,g,y){for(var R=l.length,E=y?R:-1;(y?E--:++E<R)&&u(l[E],E,l););return g?_n(l,y?0:E,y?E+1:R):_n(l,y?E+1:0,y?R:E)}function s2(l,u){var g=l;return g instanceof We&&(g=g.value()),lf(u,function(y,R){return R.func.apply(R.thisArg,ci([y],R.args))},g)}function _f(l,u,g){var y=l.length;if(y<2)return y?di(l[0]):[];for(var R=-1,E=P(y);++R<y;)for(var _=l[R],B=-1;++B<y;)B!=R&&(E[R]=Zs(E[R]||_,l[B],u,g));return di(jt(E,1),u,g)}function a2(l,u,g){for(var y=-1,R=l.length,E=u.length,_={};++y<R;){var B=y<E?u[y]:n;g(_,l[y],B)}return _}function Lf(l){return dt(l)?l:[]}function Bf(l){return typeof l=="function"?l:an}function gi(l,u){return Ee(l)?l:Uf(l,u)?[l]:B2(Xe(l))}var xS=Be;function mi(l,u,g){var y=l.length;return g=g===n?y:g,!u&&g>=y?l:_n(l,u,g)}var l2=a7||function(l){return Nt.clearTimeout(l)};function c2(l,u){if(u)return l.slice();var g=l.length,y=Ep?Ep(g):new l.constructor(g);return l.copy(y),y}function Nf(l){var u=new l.constructor(l.byteLength);return new Il(u).set(new Il(l)),u}function yS(l,u){var g=u?Nf(l.buffer):l.buffer;return new l.constructor(g,l.byteOffset,l.byteLength)}function CS(l){var u=new l.constructor(l.source,qm.exec(l));return u.lastIndex=l.lastIndex,u}function $S(l){return Ys?Je(Ys.call(l)):{}}function u2(l,u){var g=u?Nf(l.buffer):l.buffer;return new l.constructor(g,l.byteOffset,l.length)}function h2(l,u){if(l!==u){var g=l!==n,y=l===null,R=l===l,E=wn(l),_=u!==n,B=u===null,j=u===u,X=wn(u);if(!B&&!X&&!E&&l>u||E&&_&&j&&!B&&!X||y&&_&&j||!g&&j||!R)return 1;if(!y&&!E&&!X&&l<u||X&&g&&R&&!y&&!E||B&&g&&R||!_&&R||!j)return-1}return 0}function SS(l,u,g){for(var y=-1,R=l.criteria,E=u.criteria,_=R.length,B=g.length;++y<_;){var j=h2(R[y],E[y]);if(j){if(y>=B)return j;var X=g[y];return j*(X=="desc"?-1:1)}}return l.index-u.index}function f2(l,u,g,y){for(var R=-1,E=l.length,_=g.length,B=-1,j=u.length,X=At(E-_,0),Z=P(j+X),ee=!y;++B<j;)Z[B]=u[B];for(;++R<_;)(ee||R<E)&&(Z[g[R]]=l[R]);for(;X--;)Z[B++]=l[R++];return Z}function d2(l,u,g,y){for(var R=-1,E=l.length,_=-1,B=g.length,j=-1,X=u.length,Z=At(E-B,0),ee=P(Z+X),ae=!y;++R<Z;)ee[R]=l[R];for(var ve=R;++j<X;)ee[ve+j]=u[j];for(;++_<B;)(ae||R<E)&&(ee[ve+g[_]]=l[R++]);return ee}function rn(l,u){var g=-1,y=l.length;for(u||(u=P(y));++g<y;)u[g]=l[g];return u}function lr(l,u,g,y){var R=!g;g||(g={});for(var E=-1,_=u.length;++E<_;){var B=u[E],j=y?y(g[B],l[B],B,g,l):n;j===n&&(j=l[B]),R?_r(g,B,j):Xs(g,B,j)}return g}function AS(l,u){return lr(l,zf(l),u)}function RS(l,u){return lr(l,R2(l),u)}function Gl(l,u){return function(g,y){var R=Ee(g)?O8:G7,E=u?u():{};return R(g,l,Ce(y,2),E)}}function jo(l){return Be(function(u,g){var y=-1,R=g.length,E=R>1?g[R-1]:n,_=R>2?g[2]:n;for(E=l.length>3&&typeof E=="function"?(R--,E):n,_&&Zt(g[0],g[1],_)&&(E=R<3?n:E,R=1),u=Je(u);++y<R;){var B=g[y];B&&l(u,B,y,E)}return u})}function g2(l,u){return function(g,y){if(g==null)return g;if(!on(g))return l(g,y);for(var R=g.length,E=u?R:-1,_=Je(g);(u?E--:++E<R)&&y(_[E],E,_)!==!1;);return g}}function m2(l){return function(u,g,y){for(var R=-1,E=Je(u),_=y(u),B=_.length;B--;){var j=_[l?B:++R];if(g(E[j],j,E)===!1)break}return u}}function kS(l,u,g){var y=u&C,R=ta(l);function E(){var _=this&&this!==Nt&&this instanceof E?R:l;return _.apply(y?g:this,arguments)}return E}function p2(l){return function(u){u=Xe(u);var g=Oo(u)?Wn(u):n,y=g?g[0]:u.charAt(0),R=g?mi(g,1).join(""):u.slice(1);return y[l]()+R}}function Fo(l){return function(u){return lf(gv(dv(u).replace(v8,"")),l,"")}}function ta(l){return function(){var u=arguments;switch(u.length){case 0:return new l;case 1:return new l(u[0]);case 2:return new l(u[0],u[1]);case 3:return new l(u[0],u[1],u[2]);case 4:return new l(u[0],u[1],u[2],u[3]);case 5:return new l(u[0],u[1],u[2],u[3],u[4]);case 6:return new l(u[0],u[1],u[2],u[3],u[4],u[5]);case 7:return new l(u[0],u[1],u[2],u[3],u[4],u[5],u[6])}var g=No(l.prototype),y=l.apply(g,u);return ct(y)?y:g}}function TS(l,u,g){var y=ta(l);function R(){for(var E=arguments.length,_=P(E),B=E,j=Vo(R);B--;)_[B]=arguments[B];var X=E<3&&_[0]!==j&&_[E-1]!==j?[]:ui(_,j);if(E-=X.length,E<g)return y2(l,u,Yl,R.placeholder,n,_,X,n,n,g-E);var Z=this&&this!==Nt&&this instanceof R?y:l;return pn(Z,this,_)}return R}function v2(l){return function(u,g,y){var R=Je(u);if(!on(u)){var E=Ce(g,3);u=Ot(u),g=function(B){return E(R[B],B,R)}}var _=l(u,g,y);return _>-1?R[E?u[_]:_]:n}}function b2(l){return Br(function(u){var g=u.length,y=g,R=Dn.prototype.thru;for(l&&u.reverse();y--;){var E=u[y];if(typeof E!="function")throw new On(s);if(R&&!_&&Jl(E)=="wrapper")var _=new Dn([],!0)}for(y=_?y:g;++y<g;){E=u[y];var B=Jl(E),j=B=="wrapper"?Pf(E):n;j&&qf(j[0])&&j[1]==(I|T|D|V)&&!j[4].length&&j[9]==1?_=_[Jl(j[0])].apply(_,j[3]):_=E.length==1&&qf(E)?_[B]():_.thru(E)}return function(){var X=arguments,Z=X[0];if(_&&X.length==1&&Ee(Z))return _.plant(Z).value();for(var ee=0,ae=g?u[ee].apply(this,X):Z;++ee<g;)ae=u[ee].call(this,ae);return ae}})}function Yl(l,u,g,y,R,E,_,B,j,X){var Z=u&I,ee=u&C,ae=u&S,ve=u&(T|O),$e=u&F,Le=ae?n:ta(l);function Se(){for(var Fe=arguments.length,Ue=P(Fe),xn=Fe;xn--;)Ue[xn]=arguments[xn];if(ve)var Qt=Vo(Se),yn=V8(Ue,Qt);if(y&&(Ue=f2(Ue,y,R,ve)),E&&(Ue=d2(Ue,E,_,ve)),Fe-=yn,ve&&Fe<X){var gt=ui(Ue,Qt);return y2(l,u,Yl,Se.placeholder,g,Ue,gt,B,j,X-Fe)}var qn=ee?g:this,Vr=ae?qn[l]:l;return Fe=Ue.length,B?Ue=GS(Ue,B):$e&&Fe>1&&Ue.reverse(),Z&&j<Fe&&(Ue.length=j),this&&this!==Nt&&this instanceof Se&&(Vr=Le||ta(Vr)),Vr.apply(qn,Ue)}return Se}function w2(l,u){return function(g,y){return nS(g,l,u(y),{})}}function Xl(l,u){return function(g,y){var R;if(g===n&&y===n)return u;if(g!==n&&(R=g),y!==n){if(R===n)return y;typeof g=="string"||typeof y=="string"?(g=bn(g),y=bn(y)):(g=i2(g),y=i2(y)),R=l(g,y)}return R}}function jf(l){return Br(function(u){return u=at(u,vn(Ce())),Be(function(g){var y=this;return l(u,function(R){return pn(R,y,g)})})})}function Zl(l,u){u=u===n?" ":bn(u);var g=u.length;if(g<2)return g?Of(u,l):u;var y=Of(u,Nl(l/Do(u)));return Oo(u)?mi(Wn(y),0,l).join(""):y.slice(0,l)}function MS(l,u,g,y){var R=u&C,E=ta(l);function _(){for(var B=-1,j=arguments.length,X=-1,Z=y.length,ee=P(Z+j),ae=this&&this!==Nt&&this instanceof _?E:l;++X<Z;)ee[X]=y[X];for(;j--;)ee[X++]=arguments[++B];return pn(ae,R?g:this,ee)}return _}function x2(l){return function(u,g,y){return y&&typeof y!="number"&&Zt(u,g,y)&&(g=y=n),u=Fr(u),g===n?(g=u,u=0):g=Fr(g),y=y===n?u<g?1:-1:Fr(y),gS(u,g,y,l)}}function Ql(l){return function(u,g){return typeof u=="string"&&typeof g=="string"||(u=Bn(u),g=Bn(g)),l(u,g)}}function y2(l,u,g,y,R,E,_,B,j,X){var Z=u&T,ee=Z?_:n,ae=Z?n:_,ve=Z?E:n,$e=Z?n:E;u|=Z?D:L,u&=~(Z?L:D),u&A||(u&=-4);var Le=[l,u,R,ve,ee,$e,ae,B,j,X],Se=g.apply(n,Le);return qf(l)&&I2(Se,Le),Se.placeholder=y,_2(Se,l,u)}function Ff(l){var u=St[l];return function(g,y){if(g=Bn(g),y=y==null?0:Pt(Ie(y),292),y&&_p(g)){var R=(Xe(g)+"e").split("e"),E=u(R[0]+"e"+(+R[1]+y));return R=(Xe(E)+"e").split("e"),+(R[0]+"e"+(+R[1]-y))}return u(g)}}var ES=Lo&&1/kl(new Lo([,-0]))[1]==te?function(l){return new Lo(l)}:ad;function C2(l){return function(u){var g=Wt(u);return g==Ze?mf(u):g==wt?K8(u):F8(u,l(u))}}function Lr(l,u,g,y,R,E,_,B){var j=u&S;if(!j&&typeof l!="function")throw new On(s);var X=y?y.length:0;if(X||(u&=-97,y=R=n),_=_===n?_:At(Ie(_),0),B=B===n?B:Ie(B),X-=R?R.length:0,u&L){var Z=y,ee=R;y=R=n}var ae=j?n:Pf(l),ve=[l,u,g,y,R,Z,ee,E,_,B];if(ae&&US(ve,ae),l=ve[0],u=ve[1],g=ve[2],y=ve[3],R=ve[4],B=ve[9]=ve[9]===n?j?0:l.length:At(ve[9]-X,0),!B&&u&(T|O)&&(u&=-25),!u||u==C)var $e=kS(l,u,g);else u==T||u==O?$e=TS(l,u,B):(u==D||u==(C|D))&&!R.length?$e=MS(l,u,g,y):$e=Yl.apply(n,ve);var Le=ae?n2:I2;return _2(Le($e,ve),l,u)}function $2(l,u,g,y){return l===n||Un(l,_o[g])&&!Qe.call(y,g)?u:l}function S2(l,u,g,y,R,E){return ct(l)&&ct(u)&&(E.set(u,l),Ul(l,u,n,S2,E),E.delete(u)),l}function OS(l){return ia(l)?n:l}function A2(l,u,g,y,R,E){var _=g&w,B=l.length,j=u.length;if(B!=j&&!(_&&j>B))return!1;var X=E.get(l),Z=E.get(u);if(X&&Z)return X==u&&Z==l;var ee=-1,ae=!0,ve=g&x?new qi:n;for(E.set(l,u),E.set(u,l);++ee<B;){var $e=l[ee],Le=u[ee];if(y)var Se=_?y(Le,$e,ee,u,l,E):y($e,Le,ee,l,u,E);if(Se!==n){if(Se)continue;ae=!1;break}if(ve){if(!cf(u,function(Fe,Ue){if(!zs(ve,Ue)&&($e===Fe||R($e,Fe,g,y,E)))return ve.push(Ue)})){ae=!1;break}}else if(!($e===Le||R($e,Le,g,y,E))){ae=!1;break}}return E.delete(l),E.delete(u),ae}function DS(l,u,g,y,R,E,_){switch(g){case xt:if(l.byteLength!=u.byteLength||l.byteOffset!=u.byteOffset)return!1;l=l.buffer,u=u.buffer;case Or:return!(l.byteLength!=u.byteLength||!E(new Il(l),new Il(u)));case Oe:case ke:case Pe:return Un(+l,+u);case _e:return l.name==u.name&&l.message==u.message;case or:case sr:return l==u+"";case Ze:var B=mf;case wt:var j=y&w;if(B||(B=kl),l.size!=u.size&&!j)return!1;var X=_.get(l);if(X)return X==u;y|=x,_.set(l,u);var Z=A2(B(l),B(u),y,R,E,_);return _.delete(l),Z;case To:if(Ys)return Ys.call(l)==Ys.call(u)}return!1}function IS(l,u,g,y,R,E){var _=g&w,B=Vf(l),j=B.length,X=Vf(u),Z=X.length;if(j!=Z&&!_)return!1;for(var ee=j;ee--;){var ae=B[ee];if(!(_?ae in u:Qe.call(u,ae)))return!1}var ve=E.get(l),$e=E.get(u);if(ve&&$e)return ve==u&&$e==l;var Le=!0;E.set(l,u),E.set(u,l);for(var Se=_;++ee<j;){ae=B[ee];var Fe=l[ae],Ue=u[ae];if(y)var xn=_?y(Ue,Fe,ae,u,l,E):y(Fe,Ue,ae,l,u,E);if(!(xn===n?Fe===Ue||R(Fe,Ue,g,y,E):xn)){Le=!1;break}Se||(Se=ae=="constructor")}if(Le&&!Se){var Qt=l.constructor,yn=u.constructor;Qt!=yn&&"constructor"in l&&"constructor"in u&&!(typeof Qt=="function"&&Qt instanceof Qt&&typeof yn=="function"&&yn instanceof yn)&&(Le=!1)}return E.delete(l),E.delete(u),Le}function Br(l){return Gf(O2(l,n,V2),l+"")}function Vf(l){return Up(l,Ot,zf)}function Hf(l){return Up(l,sn,R2)}var Pf=Fl?function(l){return Fl.get(l)}:ad;function Jl(l){for(var u=l.name+"",g=Bo[u],y=Qe.call(Bo,u)?g.length:0;y--;){var R=g[y],E=R.func;if(E==null||E==l)return R.name}return u}function Vo(l){var u=Qe.call(M,"placeholder")?M:l;return u.placeholder}function Ce(){var l=M.iteratee||od;return l=l===od?Gp:l,arguments.length?l(arguments[0],arguments[1]):l}function ec(l,u){var g=l.__data__;return HS(u)?g[typeof u=="string"?"string":"hash"]:g.map}function Wf(l){for(var u=Ot(l),g=u.length;g--;){var y=u[g],R=l[y];u[g]=[y,R,M2(R)]}return u}function Yi(l,u){var g=z8(l,u);return Kp(g)?g:n}function _S(l){var u=Qe.call(l,zi),g=l[zi];try{l[zi]=n;var y=!0}catch{}var R=Ol.call(l);return y&&(u?l[zi]=g:delete l[zi]),R}var zf=vf?function(l){return l==null?[]:(l=Je(l),li(vf(l),function(u){return Dp.call(l,u)}))}:ld,R2=vf?function(l){for(var u=[];l;)ci(u,zf(l)),l=_l(l);return u}:ld,Wt=Xt;(bf&&Wt(new bf(new ArrayBuffer(1)))!=xt||qs&&Wt(new qs)!=Ze||wf&&Wt(wf.resolve())!=Hi||Lo&&Wt(new Lo)!=wt||Ks&&Wt(new Ks)!=Pi)&&(Wt=function(l){var u=Xt(l),g=u==ft?l.constructor:n,y=g?Xi(g):"";if(y)switch(y){case p7:return xt;case v7:return Ze;case b7:return Hi;case w7:return wt;case x7:return Pi}return u});function LS(l,u,g){for(var y=-1,R=g.length;++y<R;){var E=g[y],_=E.size;switch(E.type){case"drop":l+=_;break;case"dropRight":u-=_;break;case"take":u=Pt(u,l+_);break;case"takeRight":l=At(l,u-_);break}}return{start:l,end:u}}function BS(l){var u=l.match(P$);return u?u[1].split(W$):[]}function k2(l,u,g){u=gi(u,l);for(var y=-1,R=u.length,E=!1;++y<R;){var _=cr(u[y]);if(!(E=l!=null&&g(l,_)))break;l=l[_]}return E||++y!=R?E:(R=l==null?0:l.length,!!R&&ac(R)&&Nr(_,R)&&(Ee(l)||Zi(l)))}function NS(l){var u=l.length,g=new l.constructor(u);return u&&typeof l[0]=="string"&&Qe.call(l,"index")&&(g.index=l.index,g.input=l.input),g}function T2(l){return typeof l.constructor=="function"&&!na(l)?No(_l(l)):{}}function jS(l,u,g){var y=l.constructor;switch(u){case Or:return Nf(l);case Oe:case ke:return new y(+l);case xt:return yS(l,g);case Ph:case Wh:case zh:case Uh:case qh:case Kh:case Gh:case Yh:case Xh:return u2(l,g);case Ze:return new y;case Pe:case sr:return new y(l);case or:return CS(l);case wt:return new y;case To:return $S(l)}}function FS(l,u){var g=u.length;if(!g)return l;var y=g-1;return u[y]=(g>1?"& ":"")+u[y],u=u.join(g>2?", ":" "),l.replace(H$,`{
71
- /* [wrapped with `+u+`] */
72
- `)}function VS(l){return Ee(l)||Zi(l)||!!(Ip&&l&&l[Ip])}function Nr(l,u){var g=typeof l;return u=u??ie,!!u&&(g=="number"||g!="symbol"&&Q$.test(l))&&l>-1&&l%1==0&&l<u}function Zt(l,u,g){if(!ct(g))return!1;var y=typeof u;return(y=="number"?on(g)&&Nr(u,g.length):y=="string"&&u in g)?Un(g[u],l):!1}function Uf(l,u){if(Ee(l))return!1;var g=typeof l;return g=="number"||g=="symbol"||g=="boolean"||l==null||wn(l)?!0:N$.test(l)||!B$.test(l)||u!=null&&l in Je(u)}function HS(l){var u=typeof l;return u=="string"||u=="number"||u=="symbol"||u=="boolean"?l!=="__proto__":l===null}function qf(l){var u=Jl(l),g=M[u];if(typeof g!="function"||!(u in We.prototype))return!1;if(l===g)return!0;var y=Pf(g);return!!y&&l===y[0]}function PS(l){return!!Mp&&Mp in l}var WS=Ml?jr:cd;function na(l){var u=l&&l.constructor,g=typeof u=="function"&&u.prototype||_o;return l===g}function M2(l){return l===l&&!ct(l)}function E2(l,u){return function(g){return g==null?!1:g[l]===u&&(u!==n||l in Je(g))}}function zS(l){var u=oc(l,function(y){return g.size===h&&g.clear(),y}),g=u.cache;return u}function US(l,u){var g=l[1],y=u[1],R=g|y,E=R<(C|S|I),_=y==I&&g==T||y==I&&g==V&&l[7].length<=u[8]||y==(I|V)&&u[7].length<=u[8]&&g==T;if(!(E||_))return l;y&C&&(l[2]=u[2],R|=g&C?0:A);var B=u[3];if(B){var j=l[3];l[3]=j?f2(j,B,u[4]):B,l[4]=j?ui(l[3],f):u[4]}return B=u[5],B&&(j=l[5],l[5]=j?d2(j,B,u[6]):B,l[6]=j?ui(l[5],f):u[6]),B=u[7],B&&(l[7]=B),y&I&&(l[8]=l[8]==null?u[8]:Pt(l[8],u[8])),l[9]==null&&(l[9]=u[9]),l[0]=u[0],l[1]=R,l}function qS(l){var u=[];if(l!=null)for(var g in Je(l))u.push(g);return u}function KS(l){return Ol.call(l)}function O2(l,u,g){return u=At(u===n?l.length-1:u,0),function(){for(var y=arguments,R=-1,E=At(y.length-u,0),_=P(E);++R<E;)_[R]=y[u+R];R=-1;for(var B=P(u+1);++R<u;)B[R]=y[R];return B[u]=g(_),pn(l,this,B)}}function D2(l,u){return u.length<2?l:Gi(l,_n(u,0,-1))}function GS(l,u){for(var g=l.length,y=Pt(u.length,g),R=rn(l);y--;){var E=u[y];l[y]=Nr(E,g)?R[E]:n}return l}function Kf(l,u){if(!(u==="constructor"&&typeof l[u]=="function")&&u!="__proto__")return l[u]}var I2=L2(n2),ra=c7||function(l,u){return Nt.setTimeout(l,u)},Gf=L2(vS);function _2(l,u,g){var y=u+"";return Gf(l,FS(y,YS(BS(y),g)))}function L2(l){var u=0,g=0;return function(){var y=d7(),R=J-(y-g);if(g=y,R>0){if(++u>=W)return arguments[0]}else u=0;return l.apply(n,arguments)}}function tc(l,u){var g=-1,y=l.length,R=y-1;for(u=u===n?y:u;++g<u;){var E=Ef(g,R),_=l[E];l[E]=l[g],l[g]=_}return l.length=u,l}var B2=zS(function(l){var u=[];return l.charCodeAt(0)===46&&u.push(""),l.replace(j$,function(g,y,R,E){u.push(R?E.replace(q$,"$1"):y||g)}),u});function cr(l){if(typeof l=="string"||wn(l))return l;var u=l+"";return u=="0"&&1/l==-1/0?"-0":u}function Xi(l){if(l!=null){try{return El.call(l)}catch{}try{return l+""}catch{}}return""}function YS(l,u){return En(Ve,function(g){var y="_."+g[0];u&g[1]&&!Al(l,y)&&l.push(y)}),l.sort()}function N2(l){if(l instanceof We)return l.clone();var u=new Dn(l.__wrapped__,l.__chain__);return u.__actions__=rn(l.__actions__),u.__index__=l.__index__,u.__values__=l.__values__,u}function XS(l,u,g){(g?Zt(l,u,g):u===n)?u=1:u=At(Ie(u),0);var y=l==null?0:l.length;if(!y||u<1)return[];for(var R=0,E=0,_=P(Nl(y/u));R<y;)_[E++]=_n(l,R,R+=u);return _}function ZS(l){for(var u=-1,g=l==null?0:l.length,y=0,R=[];++u<g;){var E=l[u];E&&(R[y++]=E)}return R}function QS(){var l=arguments.length;if(!l)return[];for(var u=P(l-1),g=arguments[0],y=l;y--;)u[y-1]=arguments[y];return ci(Ee(g)?rn(g):[g],jt(u,1))}var JS=Be(function(l,u){return dt(l)?Zs(l,jt(u,1,dt,!0)):[]}),e9=Be(function(l,u){var g=Ln(u);return dt(g)&&(g=n),dt(l)?Zs(l,jt(u,1,dt,!0),Ce(g,2)):[]}),t9=Be(function(l,u){var g=Ln(u);return dt(g)&&(g=n),dt(l)?Zs(l,jt(u,1,dt,!0),n,g):[]});function n9(l,u,g){var y=l==null?0:l.length;return y?(u=g||u===n?1:Ie(u),_n(l,u<0?0:u,y)):[]}function r9(l,u,g){var y=l==null?0:l.length;return y?(u=g||u===n?1:Ie(u),u=y-u,_n(l,0,u<0?0:u)):[]}function i9(l,u){return l&&l.length?Kl(l,Ce(u,3),!0,!0):[]}function o9(l,u){return l&&l.length?Kl(l,Ce(u,3),!0):[]}function s9(l,u,g,y){var R=l==null?0:l.length;return R?(g&&typeof g!="number"&&Zt(l,u,g)&&(g=0,y=R),Q7(l,u,g,y)):[]}function j2(l,u,g){var y=l==null?0:l.length;if(!y)return-1;var R=g==null?0:Ie(g);return R<0&&(R=At(y+R,0)),Rl(l,Ce(u,3),R)}function F2(l,u,g){var y=l==null?0:l.length;if(!y)return-1;var R=y-1;return g!==n&&(R=Ie(g),R=g<0?At(y+R,0):Pt(R,y-1)),Rl(l,Ce(u,3),R,!0)}function V2(l){var u=l==null?0:l.length;return u?jt(l,1):[]}function a9(l){var u=l==null?0:l.length;return u?jt(l,te):[]}function l9(l,u){var g=l==null?0:l.length;return g?(u=u===n?1:Ie(u),jt(l,u)):[]}function c9(l){for(var u=-1,g=l==null?0:l.length,y={};++u<g;){var R=l[u];y[R[0]]=R[1]}return y}function H2(l){return l&&l.length?l[0]:n}function u9(l,u,g){var y=l==null?0:l.length;if(!y)return-1;var R=g==null?0:Ie(g);return R<0&&(R=At(y+R,0)),Eo(l,u,R)}function h9(l){var u=l==null?0:l.length;return u?_n(l,0,-1):[]}var f9=Be(function(l){var u=at(l,Lf);return u.length&&u[0]===l[0]?Af(u):[]}),d9=Be(function(l){var u=Ln(l),g=at(l,Lf);return u===Ln(g)?u=n:g.pop(),g.length&&g[0]===l[0]?Af(g,Ce(u,2)):[]}),g9=Be(function(l){var u=Ln(l),g=at(l,Lf);return u=typeof u=="function"?u:n,u&&g.pop(),g.length&&g[0]===l[0]?Af(g,n,u):[]});function m9(l,u){return l==null?"":h7.call(l,u)}function Ln(l){var u=l==null?0:l.length;return u?l[u-1]:n}function p9(l,u,g){var y=l==null?0:l.length;if(!y)return-1;var R=y;return g!==n&&(R=Ie(g),R=R<0?At(y+R,0):Pt(R,y-1)),u===u?Y8(l,u,R):Rl(l,yp,R,!0)}function v9(l,u){return l&&l.length?Qp(l,Ie(u)):n}var b9=Be(P2);function P2(l,u){return l&&l.length&&u&&u.length?Mf(l,u):l}function w9(l,u,g){return l&&l.length&&u&&u.length?Mf(l,u,Ce(g,2)):l}function x9(l,u,g){return l&&l.length&&u&&u.length?Mf(l,u,n,g):l}var y9=Br(function(l,u){var g=l==null?0:l.length,y=yf(l,u);return t2(l,at(u,function(R){return Nr(R,g)?+R:R}).sort(h2)),y});function C9(l,u){var g=[];if(!(l&&l.length))return g;var y=-1,R=[],E=l.length;for(u=Ce(u,3);++y<E;){var _=l[y];u(_,y,l)&&(g.push(_),R.push(y))}return t2(l,R),g}function Yf(l){return l==null?l:m7.call(l)}function $9(l,u,g){var y=l==null?0:l.length;return y?(g&&typeof g!="number"&&Zt(l,u,g)?(u=0,g=y):(u=u==null?0:Ie(u),g=g===n?y:Ie(g)),_n(l,u,g)):[]}function S9(l,u){return ql(l,u)}function A9(l,u,g){return Df(l,u,Ce(g,2))}function R9(l,u){var g=l==null?0:l.length;if(g){var y=ql(l,u);if(y<g&&Un(l[y],u))return y}return-1}function k9(l,u){return ql(l,u,!0)}function T9(l,u,g){return Df(l,u,Ce(g,2),!0)}function M9(l,u){var g=l==null?0:l.length;if(g){var y=ql(l,u,!0)-1;if(Un(l[y],u))return y}return-1}function E9(l){return l&&l.length?r2(l):[]}function O9(l,u){return l&&l.length?r2(l,Ce(u,2)):[]}function D9(l){var u=l==null?0:l.length;return u?_n(l,1,u):[]}function I9(l,u,g){return l&&l.length?(u=g||u===n?1:Ie(u),_n(l,0,u<0?0:u)):[]}function _9(l,u,g){var y=l==null?0:l.length;return y?(u=g||u===n?1:Ie(u),u=y-u,_n(l,u<0?0:u,y)):[]}function L9(l,u){return l&&l.length?Kl(l,Ce(u,3),!1,!0):[]}function B9(l,u){return l&&l.length?Kl(l,Ce(u,3)):[]}var N9=Be(function(l){return di(jt(l,1,dt,!0))}),j9=Be(function(l){var u=Ln(l);return dt(u)&&(u=n),di(jt(l,1,dt,!0),Ce(u,2))}),F9=Be(function(l){var u=Ln(l);return u=typeof u=="function"?u:n,di(jt(l,1,dt,!0),n,u)});function V9(l){return l&&l.length?di(l):[]}function H9(l,u){return l&&l.length?di(l,Ce(u,2)):[]}function P9(l,u){return u=typeof u=="function"?u:n,l&&l.length?di(l,n,u):[]}function Xf(l){if(!(l&&l.length))return[];var u=0;return l=li(l,function(g){if(dt(g))return u=At(g.length,u),!0}),df(u,function(g){return at(l,uf(g))})}function W2(l,u){if(!(l&&l.length))return[];var g=Xf(l);return u==null?g:at(g,function(y){return pn(u,n,y)})}var W9=Be(function(l,u){return dt(l)?Zs(l,u):[]}),z9=Be(function(l){return _f(li(l,dt))}),U9=Be(function(l){var u=Ln(l);return dt(u)&&(u=n),_f(li(l,dt),Ce(u,2))}),q9=Be(function(l){var u=Ln(l);return u=typeof u=="function"?u:n,_f(li(l,dt),n,u)}),K9=Be(Xf);function G9(l,u){return a2(l||[],u||[],Xs)}function Y9(l,u){return a2(l||[],u||[],ea)}var X9=Be(function(l){var u=l.length,g=u>1?l[u-1]:n;return g=typeof g=="function"?(l.pop(),g):n,W2(l,g)});function z2(l){var u=M(l);return u.__chain__=!0,u}function Z9(l,u){return u(l),l}function nc(l,u){return u(l)}var Q9=Br(function(l){var u=l.length,g=u?l[0]:0,y=this.__wrapped__,R=function(E){return yf(E,l)};return u>1||this.__actions__.length||!(y instanceof We)||!Nr(g)?this.thru(R):(y=y.slice(g,+g+(u?1:0)),y.__actions__.push({func:nc,args:[R],thisArg:n}),new Dn(y,this.__chain__).thru(function(E){return u&&!E.length&&E.push(n),E}))});function J9(){return z2(this)}function eA(){return new Dn(this.value(),this.__chain__)}function tA(){this.__values__===n&&(this.__values__=iv(this.value()));var l=this.__index__>=this.__values__.length,u=l?n:this.__values__[this.__index__++];return{done:l,value:u}}function nA(){return this}function rA(l){for(var u,g=this;g instanceof Hl;){var y=N2(g);y.__index__=0,y.__values__=n,u?R.__wrapped__=y:u=y;var R=y;g=g.__wrapped__}return R.__wrapped__=l,u}function iA(){var l=this.__wrapped__;if(l instanceof We){var u=l;return this.__actions__.length&&(u=new We(this)),u=u.reverse(),u.__actions__.push({func:nc,args:[Yf],thisArg:n}),new Dn(u,this.__chain__)}return this.thru(Yf)}function oA(){return s2(this.__wrapped__,this.__actions__)}var sA=Gl(function(l,u,g){Qe.call(l,g)?++l[g]:_r(l,g,1)});function aA(l,u,g){var y=Ee(l)?wp:Z7;return g&&Zt(l,u,g)&&(u=n),y(l,Ce(u,3))}function lA(l,u){var g=Ee(l)?li:Wp;return g(l,Ce(u,3))}var cA=v2(j2),uA=v2(F2);function hA(l,u){return jt(rc(l,u),1)}function fA(l,u){return jt(rc(l,u),te)}function dA(l,u,g){return g=g===n?1:Ie(g),jt(rc(l,u),g)}function U2(l,u){var g=Ee(l)?En:fi;return g(l,Ce(u,3))}function q2(l,u){var g=Ee(l)?D8:Pp;return g(l,Ce(u,3))}var gA=Gl(function(l,u,g){Qe.call(l,g)?l[g].push(u):_r(l,g,[u])});function mA(l,u,g,y){l=on(l)?l:Po(l),g=g&&!y?Ie(g):0;var R=l.length;return g<0&&(g=At(R+g,0)),lc(l)?g<=R&&l.indexOf(u,g)>-1:!!R&&Eo(l,u,g)>-1}var pA=Be(function(l,u,g){var y=-1,R=typeof u=="function",E=on(l)?P(l.length):[];return fi(l,function(_){E[++y]=R?pn(u,_,g):Qs(_,u,g)}),E}),vA=Gl(function(l,u,g){_r(l,g,u)});function rc(l,u){var g=Ee(l)?at:Yp;return g(l,Ce(u,3))}function bA(l,u,g,y){return l==null?[]:(Ee(u)||(u=u==null?[]:[u]),g=y?n:g,Ee(g)||(g=g==null?[]:[g]),Jp(l,u,g))}var wA=Gl(function(l,u,g){l[g?0:1].push(u)},function(){return[[],[]]});function xA(l,u,g){var y=Ee(l)?lf:$p,R=arguments.length<3;return y(l,Ce(u,4),g,R,fi)}function yA(l,u,g){var y=Ee(l)?I8:$p,R=arguments.length<3;return y(l,Ce(u,4),g,R,Pp)}function CA(l,u){var g=Ee(l)?li:Wp;return g(l,sc(Ce(u,3)))}function $A(l){var u=Ee(l)?jp:mS;return u(l)}function SA(l,u,g){(g?Zt(l,u,g):u===n)?u=1:u=Ie(u);var y=Ee(l)?q7:pS;return y(l,u)}function AA(l){var u=Ee(l)?K7:bS;return u(l)}function RA(l){if(l==null)return 0;if(on(l))return lc(l)?Do(l):l.length;var u=Wt(l);return u==Ze||u==wt?l.size:kf(l).length}function kA(l,u,g){var y=Ee(l)?cf:wS;return g&&Zt(l,u,g)&&(u=n),y(l,Ce(u,3))}var TA=Be(function(l,u){if(l==null)return[];var g=u.length;return g>1&&Zt(l,u[0],u[1])?u=[]:g>2&&Zt(u[0],u[1],u[2])&&(u=[u[0]]),Jp(l,jt(u,1),[])}),ic=l7||function(){return Nt.Date.now()};function MA(l,u){if(typeof u!="function")throw new On(s);return l=Ie(l),function(){if(--l<1)return u.apply(this,arguments)}}function K2(l,u,g){return u=g?n:u,u=l&&u==null?l.length:u,Lr(l,I,n,n,n,n,u)}function G2(l,u){var g;if(typeof u!="function")throw new On(s);return l=Ie(l),function(){return--l>0&&(g=u.apply(this,arguments)),l<=1&&(u=n),g}}var Zf=Be(function(l,u,g){var y=C;if(g.length){var R=ui(g,Vo(Zf));y|=D}return Lr(l,y,u,g,R)}),Y2=Be(function(l,u,g){var y=C|S;if(g.length){var R=ui(g,Vo(Y2));y|=D}return Lr(u,y,l,g,R)});function X2(l,u,g){u=g?n:u;var y=Lr(l,T,n,n,n,n,n,u);return y.placeholder=X2.placeholder,y}function Z2(l,u,g){u=g?n:u;var y=Lr(l,O,n,n,n,n,n,u);return y.placeholder=Z2.placeholder,y}function Q2(l,u,g){var y,R,E,_,B,j,X=0,Z=!1,ee=!1,ae=!0;if(typeof l!="function")throw new On(s);u=Bn(u)||0,ct(g)&&(Z=!!g.leading,ee="maxWait"in g,E=ee?At(Bn(g.maxWait)||0,u):E,ae="trailing"in g?!!g.trailing:ae);function ve(gt){var qn=y,Vr=R;return y=R=n,X=gt,_=l.apply(Vr,qn),_}function $e(gt){return X=gt,B=ra(Fe,u),Z?ve(gt):_}function Le(gt){var qn=gt-j,Vr=gt-X,vv=u-qn;return ee?Pt(vv,E-Vr):vv}function Se(gt){var qn=gt-j,Vr=gt-X;return j===n||qn>=u||qn<0||ee&&Vr>=E}function Fe(){var gt=ic();if(Se(gt))return Ue(gt);B=ra(Fe,Le(gt))}function Ue(gt){return B=n,ae&&y?ve(gt):(y=R=n,_)}function xn(){B!==n&&l2(B),X=0,y=j=R=B=n}function Qt(){return B===n?_:Ue(ic())}function yn(){var gt=ic(),qn=Se(gt);if(y=arguments,R=this,j=gt,qn){if(B===n)return $e(j);if(ee)return l2(B),B=ra(Fe,u),ve(j)}return B===n&&(B=ra(Fe,u)),_}return yn.cancel=xn,yn.flush=Qt,yn}var EA=Be(function(l,u){return Hp(l,1,u)}),OA=Be(function(l,u,g){return Hp(l,Bn(u)||0,g)});function DA(l){return Lr(l,F)}function oc(l,u){if(typeof l!="function"||u!=null&&typeof u!="function")throw new On(s);var g=function(){var y=arguments,R=u?u.apply(this,y):y[0],E=g.cache;if(E.has(R))return E.get(R);var _=l.apply(this,y);return g.cache=E.set(R,_)||E,_};return g.cache=new(oc.Cache||Ir),g}oc.Cache=Ir;function sc(l){if(typeof l!="function")throw new On(s);return function(){var u=arguments;switch(u.length){case 0:return!l.call(this);case 1:return!l.call(this,u[0]);case 2:return!l.call(this,u[0],u[1]);case 3:return!l.call(this,u[0],u[1],u[2])}return!l.apply(this,u)}}function IA(l){return G2(2,l)}var _A=xS(function(l,u){u=u.length==1&&Ee(u[0])?at(u[0],vn(Ce())):at(jt(u,1),vn(Ce()));var g=u.length;return Be(function(y){for(var R=-1,E=Pt(y.length,g);++R<E;)y[R]=u[R].call(this,y[R]);return pn(l,this,y)})}),Qf=Be(function(l,u){var g=ui(u,Vo(Qf));return Lr(l,D,n,u,g)}),J2=Be(function(l,u){var g=ui(u,Vo(J2));return Lr(l,L,n,u,g)}),LA=Br(function(l,u){return Lr(l,V,n,n,n,u)});function BA(l,u){if(typeof l!="function")throw new On(s);return u=u===n?u:Ie(u),Be(l,u)}function NA(l,u){if(typeof l!="function")throw new On(s);return u=u==null?0:At(Ie(u),0),Be(function(g){var y=g[u],R=mi(g,0,u);return y&&ci(R,y),pn(l,this,R)})}function jA(l,u,g){var y=!0,R=!0;if(typeof l!="function")throw new On(s);return ct(g)&&(y="leading"in g?!!g.leading:y,R="trailing"in g?!!g.trailing:R),Q2(l,u,{leading:y,maxWait:u,trailing:R})}function FA(l){return K2(l,1)}function VA(l,u){return Qf(Bf(u),l)}function HA(){if(!arguments.length)return[];var l=arguments[0];return Ee(l)?l:[l]}function PA(l){return In(l,v)}function WA(l,u){return u=typeof u=="function"?u:n,In(l,v,u)}function zA(l){return In(l,d|v)}function UA(l,u){return u=typeof u=="function"?u:n,In(l,d|v,u)}function qA(l,u){return u==null||Vp(l,u,Ot(u))}function Un(l,u){return l===u||l!==l&&u!==u}var KA=Ql(Sf),GA=Ql(function(l,u){return l>=u}),Zi=qp(function(){return arguments}())?qp:function(l){return ht(l)&&Qe.call(l,"callee")&&!Dp.call(l,"callee")},Ee=P.isArray,YA=dp?vn(dp):rS;function on(l){return l!=null&&ac(l.length)&&!jr(l)}function dt(l){return ht(l)&&on(l)}function XA(l){return l===!0||l===!1||ht(l)&&Xt(l)==Oe}var pi=u7||cd,ZA=gp?vn(gp):iS;function QA(l){return ht(l)&&l.nodeType===1&&!ia(l)}function JA(l){if(l==null)return!0;if(on(l)&&(Ee(l)||typeof l=="string"||typeof l.splice=="function"||pi(l)||Ho(l)||Zi(l)))return!l.length;var u=Wt(l);if(u==Ze||u==wt)return!l.size;if(na(l))return!kf(l).length;for(var g in l)if(Qe.call(l,g))return!1;return!0}function eR(l,u){return Js(l,u)}function tR(l,u,g){g=typeof g=="function"?g:n;var y=g?g(l,u):n;return y===n?Js(l,u,n,g):!!y}function Jf(l){if(!ht(l))return!1;var u=Xt(l);return u==_e||u==Ae||typeof l.message=="string"&&typeof l.name=="string"&&!ia(l)}function nR(l){return typeof l=="number"&&_p(l)}function jr(l){if(!ct(l))return!1;var u=Xt(l);return u==ze||u==Et||u==pe||u==Ps}function ev(l){return typeof l=="number"&&l==Ie(l)}function ac(l){return typeof l=="number"&&l>-1&&l%1==0&&l<=ie}function ct(l){var u=typeof l;return l!=null&&(u=="object"||u=="function")}function ht(l){return l!=null&&typeof l=="object"}var tv=mp?vn(mp):sS;function rR(l,u){return l===u||Rf(l,u,Wf(u))}function iR(l,u,g){return g=typeof g=="function"?g:n,Rf(l,u,Wf(u),g)}function oR(l){return nv(l)&&l!=+l}function sR(l){if(WS(l))throw new Te(o);return Kp(l)}function aR(l){return l===null}function lR(l){return l==null}function nv(l){return typeof l=="number"||ht(l)&&Xt(l)==Pe}function ia(l){if(!ht(l)||Xt(l)!=ft)return!1;var u=_l(l);if(u===null)return!0;var g=Qe.call(u,"constructor")&&u.constructor;return typeof g=="function"&&g instanceof g&&El.call(g)==i7}var ed=pp?vn(pp):aS;function cR(l){return ev(l)&&l>=-9007199254740991&&l<=ie}var rv=vp?vn(vp):lS;function lc(l){return typeof l=="string"||!Ee(l)&&ht(l)&&Xt(l)==sr}function wn(l){return typeof l=="symbol"||ht(l)&&Xt(l)==To}var Ho=bp?vn(bp):cS;function uR(l){return l===n}function hR(l){return ht(l)&&Wt(l)==Pi}function fR(l){return ht(l)&&Xt(l)==Hh}var dR=Ql(Tf),gR=Ql(function(l,u){return l<=u});function iv(l){if(!l)return[];if(on(l))return lc(l)?Wn(l):rn(l);if(Us&&l[Us])return q8(l[Us]());var u=Wt(l),g=u==Ze?mf:u==wt?kl:Po;return g(l)}function Fr(l){if(!l)return l===0?l:0;if(l=Bn(l),l===te||l===-1/0){var u=l<0?-1:1;return u*Y}return l===l?l:0}function Ie(l){var u=Fr(l),g=u%1;return u===u?g?u-g:u:0}function ov(l){return l?Ki(Ie(l),0,ge):0}function Bn(l){if(typeof l=="number")return l;if(wn(l))return ue;if(ct(l)){var u=typeof l.valueOf=="function"?l.valueOf():l;l=ct(u)?u+"":u}if(typeof l!="string")return l===0?l:+l;l=Sp(l);var g=Y$.test(l);return g||Z$.test(l)?M8(l.slice(2),g?2:8):G$.test(l)?ue:+l}function sv(l){return lr(l,sn(l))}function mR(l){return l?Ki(Ie(l),-9007199254740991,ie):l===0?l:0}function Xe(l){return l==null?"":bn(l)}var pR=jo(function(l,u){if(na(u)||on(u)){lr(u,Ot(u),l);return}for(var g in u)Qe.call(u,g)&&Xs(l,g,u[g])}),av=jo(function(l,u){lr(u,sn(u),l)}),cc=jo(function(l,u,g,y){lr(u,sn(u),l,y)}),vR=jo(function(l,u,g,y){lr(u,Ot(u),l,y)}),bR=Br(yf);function wR(l,u){var g=No(l);return u==null?g:Fp(g,u)}var xR=Be(function(l,u){l=Je(l);var g=-1,y=u.length,R=y>2?u[2]:n;for(R&&Zt(u[0],u[1],R)&&(y=1);++g<y;)for(var E=u[g],_=sn(E),B=-1,j=_.length;++B<j;){var X=_[B],Z=l[X];(Z===n||Un(Z,_o[X])&&!Qe.call(l,X))&&(l[X]=E[X])}return l}),yR=Be(function(l){return l.push(n,S2),pn(lv,n,l)});function CR(l,u){return xp(l,Ce(u,3),ar)}function $R(l,u){return xp(l,Ce(u,3),$f)}function SR(l,u){return l==null?l:Cf(l,Ce(u,3),sn)}function AR(l,u){return l==null?l:zp(l,Ce(u,3),sn)}function RR(l,u){return l&&ar(l,Ce(u,3))}function kR(l,u){return l&&$f(l,Ce(u,3))}function TR(l){return l==null?[]:zl(l,Ot(l))}function MR(l){return l==null?[]:zl(l,sn(l))}function td(l,u,g){var y=l==null?n:Gi(l,u);return y===n?g:y}function ER(l,u){return l!=null&&k2(l,u,J7)}function nd(l,u){return l!=null&&k2(l,u,eS)}var OR=w2(function(l,u,g){u!=null&&typeof u.toString!="function"&&(u=Ol.call(u)),l[u]=g},id(an)),DR=w2(function(l,u,g){u!=null&&typeof u.toString!="function"&&(u=Ol.call(u)),Qe.call(l,u)?l[u].push(g):l[u]=[g]},Ce),IR=Be(Qs);function Ot(l){return on(l)?Np(l):kf(l)}function sn(l){return on(l)?Np(l,!0):uS(l)}function _R(l,u){var g={};return u=Ce(u,3),ar(l,function(y,R,E){_r(g,u(y,R,E),y)}),g}function LR(l,u){var g={};return u=Ce(u,3),ar(l,function(y,R,E){_r(g,R,u(y,R,E))}),g}var BR=jo(function(l,u,g){Ul(l,u,g)}),lv=jo(function(l,u,g,y){Ul(l,u,g,y)}),NR=Br(function(l,u){var g={};if(l==null)return g;var y=!1;u=at(u,function(E){return E=gi(E,l),y||(y=E.length>1),E}),lr(l,Hf(l),g),y&&(g=In(g,d|m|v,OS));for(var R=u.length;R--;)If(g,u[R]);return g});function jR(l,u){return cv(l,sc(Ce(u)))}var FR=Br(function(l,u){return l==null?{}:fS(l,u)});function cv(l,u){if(l==null)return{};var g=at(Hf(l),function(y){return[y]});return u=Ce(u),e2(l,g,function(y,R){return u(y,R[0])})}function VR(l,u,g){u=gi(u,l);var y=-1,R=u.length;for(R||(R=1,l=n);++y<R;){var E=l==null?n:l[cr(u[y])];E===n&&(y=R,E=g),l=jr(E)?E.call(l):E}return l}function HR(l,u,g){return l==null?l:ea(l,u,g)}function PR(l,u,g,y){return y=typeof y=="function"?y:n,l==null?l:ea(l,u,g,y)}var uv=C2(Ot),hv=C2(sn);function WR(l,u,g){var y=Ee(l),R=y||pi(l)||Ho(l);if(u=Ce(u,4),g==null){var E=l&&l.constructor;R?g=y?new E:[]:ct(l)?g=jr(E)?No(_l(l)):{}:g={}}return(R?En:ar)(l,function(_,B,j){return u(g,_,B,j)}),g}function zR(l,u){return l==null?!0:If(l,u)}function UR(l,u,g){return l==null?l:o2(l,u,Bf(g))}function qR(l,u,g,y){return y=typeof y=="function"?y:n,l==null?l:o2(l,u,Bf(g),y)}function Po(l){return l==null?[]:gf(l,Ot(l))}function KR(l){return l==null?[]:gf(l,sn(l))}function GR(l,u,g){return g===n&&(g=u,u=n),g!==n&&(g=Bn(g),g=g===g?g:0),u!==n&&(u=Bn(u),u=u===u?u:0),Ki(Bn(l),u,g)}function YR(l,u,g){return u=Fr(u),g===n?(g=u,u=0):g=Fr(g),l=Bn(l),tS(l,u,g)}function XR(l,u,g){if(g&&typeof g!="boolean"&&Zt(l,u,g)&&(u=g=n),g===n&&(typeof u=="boolean"?(g=u,u=n):typeof l=="boolean"&&(g=l,l=n)),l===n&&u===n?(l=0,u=1):(l=Fr(l),u===n?(u=l,l=0):u=Fr(u)),l>u){var y=l;l=u,u=y}if(g||l%1||u%1){var R=Lp();return Pt(l+R*(u-l+T8("1e-"+((R+"").length-1))),u)}return Ef(l,u)}var ZR=Fo(function(l,u,g){return u=u.toLowerCase(),l+(g?fv(u):u)});function fv(l){return rd(Xe(l).toLowerCase())}function dv(l){return l=Xe(l),l&&l.replace(J$,H8).replace(b8,"")}function QR(l,u,g){l=Xe(l),u=bn(u);var y=l.length;g=g===n?y:Ki(Ie(g),0,y);var R=g;return g-=u.length,g>=0&&l.slice(g,R)==u}function JR(l){return l=Xe(l),l&&I$.test(l)?l.replace(zm,P8):l}function ek(l){return l=Xe(l),l&&F$.test(l)?l.replace(Zh,"\\$&"):l}var tk=Fo(function(l,u,g){return l+(g?"-":"")+u.toLowerCase()}),nk=Fo(function(l,u,g){return l+(g?" ":"")+u.toLowerCase()}),rk=p2("toLowerCase");function ik(l,u,g){l=Xe(l),u=Ie(u);var y=u?Do(l):0;if(!u||y>=u)return l;var R=(u-y)/2;return Zl(jl(R),g)+l+Zl(Nl(R),g)}function ok(l,u,g){l=Xe(l),u=Ie(u);var y=u?Do(l):0;return u&&y<u?l+Zl(u-y,g):l}function sk(l,u,g){l=Xe(l),u=Ie(u);var y=u?Do(l):0;return u&&y<u?Zl(u-y,g)+l:l}function ak(l,u,g){return g||u==null?u=0:u&&(u=+u),g7(Xe(l).replace(Qh,""),u||0)}function lk(l,u,g){return(g?Zt(l,u,g):u===n)?u=1:u=Ie(u),Of(Xe(l),u)}function ck(){var l=arguments,u=Xe(l[0]);return l.length<3?u:u.replace(l[1],l[2])}var uk=Fo(function(l,u,g){return l+(g?"_":"")+u.toLowerCase()});function hk(l,u,g){return g&&typeof g!="number"&&Zt(l,u,g)&&(u=g=n),g=g===n?ge:g>>>0,g?(l=Xe(l),l&&(typeof u=="string"||u!=null&&!ed(u))&&(u=bn(u),!u&&Oo(l))?mi(Wn(l),0,g):l.split(u,g)):[]}var fk=Fo(function(l,u,g){return l+(g?" ":"")+rd(u)});function dk(l,u,g){return l=Xe(l),g=g==null?0:Ki(Ie(g),0,l.length),u=bn(u),l.slice(g,g+u.length)==u}function gk(l,u,g){var y=M.templateSettings;g&&Zt(l,u,g)&&(u=n),l=Xe(l),u=cc({},u,y,$2);var R=cc({},u.imports,y.imports,$2),E=Ot(R),_=gf(R,E),B,j,X=0,Z=u.interpolate||Cl,ee="__p += '",ae=pf((u.escape||Cl).source+"|"+Z.source+"|"+(Z===Um?K$:Cl).source+"|"+(u.evaluate||Cl).source+"|$","g"),ve="//# sourceURL="+(Qe.call(u,"sourceURL")?(u.sourceURL+"").replace(/\s/g," "):"lodash.templateSources["+ ++$8+"]")+`
73
- `;l.replace(ae,function(Se,Fe,Ue,xn,Qt,yn){return Ue||(Ue=xn),ee+=l.slice(X,yn).replace(e8,W8),Fe&&(B=!0,ee+=`' +
74
- __e(`+Fe+`) +
75
- '`),Qt&&(j=!0,ee+=`';
76
- `+Qt+`;
77
- __p += '`),Ue&&(ee+=`' +
78
- ((__t = (`+Ue+`)) == null ? '' : __t) +
79
- '`),X=yn+Se.length,Se}),ee+=`';
80
- `;var $e=Qe.call(u,"variable")&&u.variable;if(!$e)ee=`with (obj) {
81
- `+ee+`
82
- }
83
- `;else if(U$.test($e))throw new Te(a);ee=(j?ee.replace(M$,""):ee).replace(E$,"$1").replace(O$,"$1;"),ee="function("+($e||"obj")+`) {
84
- `+($e?"":`obj || (obj = {});
85
- `)+"var __t, __p = ''"+(B?", __e = _.escape":"")+(j?`, __j = Array.prototype.join;
86
- function print() { __p += __j.call(arguments, '') }
87
- `:`;
88
- `)+ee+`return __p
89
- }`;var Le=mv(function(){return Ye(E,ve+"return "+ee).apply(n,_)});if(Le.source=ee,Jf(Le))throw Le;return Le}function mk(l){return Xe(l).toLowerCase()}function pk(l){return Xe(l).toUpperCase()}function vk(l,u,g){if(l=Xe(l),l&&(g||u===n))return Sp(l);if(!l||!(u=bn(u)))return l;var y=Wn(l),R=Wn(u),E=Ap(y,R),_=Rp(y,R)+1;return mi(y,E,_).join("")}function bk(l,u,g){if(l=Xe(l),l&&(g||u===n))return l.slice(0,Tp(l)+1);if(!l||!(u=bn(u)))return l;var y=Wn(l),R=Rp(y,Wn(u))+1;return mi(y,0,R).join("")}function wk(l,u,g){if(l=Xe(l),l&&(g||u===n))return l.replace(Qh,"");if(!l||!(u=bn(u)))return l;var y=Wn(l),R=Ap(y,Wn(u));return mi(y,R).join("")}function xk(l,u){var g=H,y=K;if(ct(u)){var R="separator"in u?u.separator:R;g="length"in u?Ie(u.length):g,y="omission"in u?bn(u.omission):y}l=Xe(l);var E=l.length;if(Oo(l)){var _=Wn(l);E=_.length}if(g>=E)return l;var B=g-Do(y);if(B<1)return y;var j=_?mi(_,0,B).join(""):l.slice(0,B);if(R===n)return j+y;if(_&&(B+=j.length-B),ed(R)){if(l.slice(B).search(R)){var X,Z=j;for(R.global||(R=pf(R.source,Xe(qm.exec(R))+"g")),R.lastIndex=0;X=R.exec(Z);)var ee=X.index;j=j.slice(0,ee===n?B:ee)}}else if(l.indexOf(bn(R),B)!=B){var ae=j.lastIndexOf(R);ae>-1&&(j=j.slice(0,ae))}return j+y}function yk(l){return l=Xe(l),l&&D$.test(l)?l.replace(Wm,X8):l}var Ck=Fo(function(l,u,g){return l+(g?" ":"")+u.toUpperCase()}),rd=p2("toUpperCase");function gv(l,u,g){return l=Xe(l),u=g?n:u,u===n?U8(l)?J8(l):B8(l):l.match(u)||[]}var mv=Be(function(l,u){try{return pn(l,n,u)}catch(g){return Jf(g)?g:new Te(g)}}),$k=Br(function(l,u){return En(u,function(g){g=cr(g),_r(l,g,Zf(l[g],l))}),l});function Sk(l){var u=l==null?0:l.length,g=Ce();return l=u?at(l,function(y){if(typeof y[1]!="function")throw new On(s);return[g(y[0]),y[1]]}):[],Be(function(y){for(var R=-1;++R<u;){var E=l[R];if(pn(E[0],this,y))return pn(E[1],this,y)}})}function Ak(l){return X7(In(l,d))}function id(l){return function(){return l}}function Rk(l,u){return l==null||l!==l?u:l}var kk=b2(),Tk=b2(!0);function an(l){return l}function od(l){return Gp(typeof l=="function"?l:In(l,d))}function Mk(l){return Xp(In(l,d))}function Ek(l,u){return Zp(l,In(u,d))}var Ok=Be(function(l,u){return function(g){return Qs(g,l,u)}}),Dk=Be(function(l,u){return function(g){return Qs(l,g,u)}});function sd(l,u,g){var y=Ot(u),R=zl(u,y);g==null&&!(ct(u)&&(R.length||!y.length))&&(g=u,u=l,l=this,R=zl(u,Ot(u)));var E=!(ct(g)&&"chain"in g)||!!g.chain,_=jr(l);return En(R,function(B){var j=u[B];l[B]=j,_&&(l.prototype[B]=function(){var X=this.__chain__;if(E||X){var Z=l(this.__wrapped__),ee=Z.__actions__=rn(this.__actions__);return ee.push({func:j,args:arguments,thisArg:l}),Z.__chain__=X,Z}return j.apply(l,ci([this.value()],arguments))})}),l}function Ik(){return Nt._===this&&(Nt._=o7),this}function ad(){}function _k(l){return l=Ie(l),Be(function(u){return Qp(u,l)})}var Lk=jf(at),Bk=jf(wp),Nk=jf(cf);function pv(l){return Uf(l)?uf(cr(l)):dS(l)}function jk(l){return function(u){return l==null?n:Gi(l,u)}}var Fk=x2(),Vk=x2(!0);function ld(){return[]}function cd(){return!1}function Hk(){return{}}function Pk(){return""}function Wk(){return!0}function zk(l,u){if(l=Ie(l),l<1||l>ie)return[];var g=ge,y=Pt(l,ge);u=Ce(u),l-=ge;for(var R=df(y,u);++g<l;)u(g);return R}function Uk(l){return Ee(l)?at(l,cr):wn(l)?[l]:rn(B2(Xe(l)))}function qk(l){var u=++r7;return Xe(l)+u}var Kk=Xl(function(l,u){return l+u},0),Gk=Ff("ceil"),Yk=Xl(function(l,u){return l/u},1),Xk=Ff("floor");function Zk(l){return l&&l.length?Wl(l,an,Sf):n}function Qk(l,u){return l&&l.length?Wl(l,Ce(u,2),Sf):n}function Jk(l){return Cp(l,an)}function eT(l,u){return Cp(l,Ce(u,2))}function tT(l){return l&&l.length?Wl(l,an,Tf):n}function nT(l,u){return l&&l.length?Wl(l,Ce(u,2),Tf):n}var rT=Xl(function(l,u){return l*u},1),iT=Ff("round"),oT=Xl(function(l,u){return l-u},0);function sT(l){return l&&l.length?ff(l,an):0}function aT(l,u){return l&&l.length?ff(l,Ce(u,2)):0}return M.after=MA,M.ary=K2,M.assign=pR,M.assignIn=av,M.assignInWith=cc,M.assignWith=vR,M.at=bR,M.before=G2,M.bind=Zf,M.bindAll=$k,M.bindKey=Y2,M.castArray=HA,M.chain=z2,M.chunk=XS,M.compact=ZS,M.concat=QS,M.cond=Sk,M.conforms=Ak,M.constant=id,M.countBy=sA,M.create=wR,M.curry=X2,M.curryRight=Z2,M.debounce=Q2,M.defaults=xR,M.defaultsDeep=yR,M.defer=EA,M.delay=OA,M.difference=JS,M.differenceBy=e9,M.differenceWith=t9,M.drop=n9,M.dropRight=r9,M.dropRightWhile=i9,M.dropWhile=o9,M.fill=s9,M.filter=lA,M.flatMap=hA,M.flatMapDeep=fA,M.flatMapDepth=dA,M.flatten=V2,M.flattenDeep=a9,M.flattenDepth=l9,M.flip=DA,M.flow=kk,M.flowRight=Tk,M.fromPairs=c9,M.functions=TR,M.functionsIn=MR,M.groupBy=gA,M.initial=h9,M.intersection=f9,M.intersectionBy=d9,M.intersectionWith=g9,M.invert=OR,M.invertBy=DR,M.invokeMap=pA,M.iteratee=od,M.keyBy=vA,M.keys=Ot,M.keysIn=sn,M.map=rc,M.mapKeys=_R,M.mapValues=LR,M.matches=Mk,M.matchesProperty=Ek,M.memoize=oc,M.merge=BR,M.mergeWith=lv,M.method=Ok,M.methodOf=Dk,M.mixin=sd,M.negate=sc,M.nthArg=_k,M.omit=NR,M.omitBy=jR,M.once=IA,M.orderBy=bA,M.over=Lk,M.overArgs=_A,M.overEvery=Bk,M.overSome=Nk,M.partial=Qf,M.partialRight=J2,M.partition=wA,M.pick=FR,M.pickBy=cv,M.property=pv,M.propertyOf=jk,M.pull=b9,M.pullAll=P2,M.pullAllBy=w9,M.pullAllWith=x9,M.pullAt=y9,M.range=Fk,M.rangeRight=Vk,M.rearg=LA,M.reject=CA,M.remove=C9,M.rest=BA,M.reverse=Yf,M.sampleSize=SA,M.set=HR,M.setWith=PR,M.shuffle=AA,M.slice=$9,M.sortBy=TA,M.sortedUniq=E9,M.sortedUniqBy=O9,M.split=hk,M.spread=NA,M.tail=D9,M.take=I9,M.takeRight=_9,M.takeRightWhile=L9,M.takeWhile=B9,M.tap=Z9,M.throttle=jA,M.thru=nc,M.toArray=iv,M.toPairs=uv,M.toPairsIn=hv,M.toPath=Uk,M.toPlainObject=sv,M.transform=WR,M.unary=FA,M.union=N9,M.unionBy=j9,M.unionWith=F9,M.uniq=V9,M.uniqBy=H9,M.uniqWith=P9,M.unset=zR,M.unzip=Xf,M.unzipWith=W2,M.update=UR,M.updateWith=qR,M.values=Po,M.valuesIn=KR,M.without=W9,M.words=gv,M.wrap=VA,M.xor=z9,M.xorBy=U9,M.xorWith=q9,M.zip=K9,M.zipObject=G9,M.zipObjectDeep=Y9,M.zipWith=X9,M.entries=uv,M.entriesIn=hv,M.extend=av,M.extendWith=cc,sd(M,M),M.add=Kk,M.attempt=mv,M.camelCase=ZR,M.capitalize=fv,M.ceil=Gk,M.clamp=GR,M.clone=PA,M.cloneDeep=zA,M.cloneDeepWith=UA,M.cloneWith=WA,M.conformsTo=qA,M.deburr=dv,M.defaultTo=Rk,M.divide=Yk,M.endsWith=QR,M.eq=Un,M.escape=JR,M.escapeRegExp=ek,M.every=aA,M.find=cA,M.findIndex=j2,M.findKey=CR,M.findLast=uA,M.findLastIndex=F2,M.findLastKey=$R,M.floor=Xk,M.forEach=U2,M.forEachRight=q2,M.forIn=SR,M.forInRight=AR,M.forOwn=RR,M.forOwnRight=kR,M.get=td,M.gt=KA,M.gte=GA,M.has=ER,M.hasIn=nd,M.head=H2,M.identity=an,M.includes=mA,M.indexOf=u9,M.inRange=YR,M.invoke=IR,M.isArguments=Zi,M.isArray=Ee,M.isArrayBuffer=YA,M.isArrayLike=on,M.isArrayLikeObject=dt,M.isBoolean=XA,M.isBuffer=pi,M.isDate=ZA,M.isElement=QA,M.isEmpty=JA,M.isEqual=eR,M.isEqualWith=tR,M.isError=Jf,M.isFinite=nR,M.isFunction=jr,M.isInteger=ev,M.isLength=ac,M.isMap=tv,M.isMatch=rR,M.isMatchWith=iR,M.isNaN=oR,M.isNative=sR,M.isNil=lR,M.isNull=aR,M.isNumber=nv,M.isObject=ct,M.isObjectLike=ht,M.isPlainObject=ia,M.isRegExp=ed,M.isSafeInteger=cR,M.isSet=rv,M.isString=lc,M.isSymbol=wn,M.isTypedArray=Ho,M.isUndefined=uR,M.isWeakMap=hR,M.isWeakSet=fR,M.join=m9,M.kebabCase=tk,M.last=Ln,M.lastIndexOf=p9,M.lowerCase=nk,M.lowerFirst=rk,M.lt=dR,M.lte=gR,M.max=Zk,M.maxBy=Qk,M.mean=Jk,M.meanBy=eT,M.min=tT,M.minBy=nT,M.stubArray=ld,M.stubFalse=cd,M.stubObject=Hk,M.stubString=Pk,M.stubTrue=Wk,M.multiply=rT,M.nth=v9,M.noConflict=Ik,M.noop=ad,M.now=ic,M.pad=ik,M.padEnd=ok,M.padStart=sk,M.parseInt=ak,M.random=XR,M.reduce=xA,M.reduceRight=yA,M.repeat=lk,M.replace=ck,M.result=VR,M.round=iT,M.runInContext=N,M.sample=$A,M.size=RA,M.snakeCase=uk,M.some=kA,M.sortedIndex=S9,M.sortedIndexBy=A9,M.sortedIndexOf=R9,M.sortedLastIndex=k9,M.sortedLastIndexBy=T9,M.sortedLastIndexOf=M9,M.startCase=fk,M.startsWith=dk,M.subtract=oT,M.sum=sT,M.sumBy=aT,M.template=gk,M.times=zk,M.toFinite=Fr,M.toInteger=Ie,M.toLength=ov,M.toLower=mk,M.toNumber=Bn,M.toSafeInteger=mR,M.toString=Xe,M.toUpper=pk,M.trim=vk,M.trimEnd=bk,M.trimStart=wk,M.truncate=xk,M.unescape=yk,M.uniqueId=qk,M.upperCase=Ck,M.upperFirst=rd,M.each=U2,M.eachRight=q2,M.first=H2,sd(M,function(){var l={};return ar(M,function(u,g){Qe.call(M.prototype,g)||(l[g]=u)}),l}(),{chain:!1}),M.VERSION=r,En(["bind","bindKey","curry","curryRight","partial","partialRight"],function(l){M[l].placeholder=M}),En(["drop","take"],function(l,u){We.prototype[l]=function(g){g=g===n?1:At(Ie(g),0);var y=this.__filtered__&&!u?new We(this):this.clone();return y.__filtered__?y.__takeCount__=Pt(g,y.__takeCount__):y.__views__.push({size:Pt(g,ge),type:l+(y.__dir__<0?"Right":"")}),y},We.prototype[l+"Right"]=function(g){return this.reverse()[l](g).reverse()}}),En(["filter","map","takeWhile"],function(l,u){var g=u+1,y=g==G||g==oe;We.prototype[l]=function(R){var E=this.clone();return E.__iteratees__.push({iteratee:Ce(R,3),type:g}),E.__filtered__=E.__filtered__||y,E}}),En(["head","last"],function(l,u){var g="take"+(u?"Right":"");We.prototype[l]=function(){return this[g](1).value()[0]}}),En(["initial","tail"],function(l,u){var g="drop"+(u?"":"Right");We.prototype[l]=function(){return this.__filtered__?new We(this):this[g](1)}}),We.prototype.compact=function(){return this.filter(an)},We.prototype.find=function(l){return this.filter(l).head()},We.prototype.findLast=function(l){return this.reverse().find(l)},We.prototype.invokeMap=Be(function(l,u){return typeof l=="function"?new We(this):this.map(function(g){return Qs(g,l,u)})}),We.prototype.reject=function(l){return this.filter(sc(Ce(l)))},We.prototype.slice=function(l,u){l=Ie(l);var g=this;return g.__filtered__&&(l>0||u<0)?new We(g):(l<0?g=g.takeRight(-l):l&&(g=g.drop(l)),u!==n&&(u=Ie(u),g=u<0?g.dropRight(-u):g.take(u-l)),g)},We.prototype.takeRightWhile=function(l){return this.reverse().takeWhile(l).reverse()},We.prototype.toArray=function(){return this.take(ge)},ar(We.prototype,function(l,u){var g=/^(?:filter|find|map|reject)|While$/.test(u),y=/^(?:head|last)$/.test(u),R=M[y?"take"+(u=="last"?"Right":""):u],E=y||/^find/.test(u);R&&(M.prototype[u]=function(){var _=this.__wrapped__,B=y?[1]:arguments,j=_ instanceof We,X=B[0],Z=j||Ee(_),ee=function(Fe){var Ue=R.apply(M,ci([Fe],B));return y&&ae?Ue[0]:Ue};Z&&g&&typeof X=="function"&&X.length!=1&&(j=Z=!1);var ae=this.__chain__,ve=!!this.__actions__.length,$e=E&&!ae,Le=j&&!ve;if(!E&&Z){_=Le?_:new We(this);var Se=l.apply(_,B);return Se.__actions__.push({func:nc,args:[ee],thisArg:n}),new Dn(Se,ae)}return $e&&Le?l.apply(this,B):(Se=this.thru(ee),$e?y?Se.value()[0]:Se.value():Se)})}),En(["pop","push","shift","sort","splice","unshift"],function(l){var u=Tl[l],g=/^(?:push|sort|unshift)$/.test(l)?"tap":"thru",y=/^(?:pop|shift)$/.test(l);M.prototype[l]=function(){var R=arguments;if(y&&!this.__chain__){var E=this.value();return u.apply(Ee(E)?E:[],R)}return this[g](function(_){return u.apply(Ee(_)?_:[],R)})}}),ar(We.prototype,function(l,u){var g=M[u];if(g){var y=g.name+"";Qe.call(Bo,y)||(Bo[y]=[]),Bo[y].push({name:u,func:g})}}),Bo[Yl(n,S).name]=[{name:"wrapper",func:n}],We.prototype.clone=y7,We.prototype.reverse=C7,We.prototype.value=$7,M.prototype.at=Q9,M.prototype.chain=J9,M.prototype.commit=eA,M.prototype.next=tA,M.prototype.plant=rA,M.prototype.reverse=iA,M.prototype.toJSON=M.prototype.valueOf=M.prototype.value=oA,M.prototype.first=M.prototype.head,Us&&(M.prototype[Us]=nA),M},Io=e7();Wi?((Wi.exports=Io)._=Io,of._=Io):Nt._=Io}).call(Jo)})(Yu,Yu.exports);var OY=Yu.exports;const vl=(t,e)=>{const n=$.createContext(e),r=o=>{const{children:s,...a}=o,c=$.useMemo(()=>a,Object.values(a));return p.jsx(n.Provider,{value:c,children:s})};function i(o){const s=$.useContext(n);if(s)return s;if(e!==void 0)return e;throw new Error(`\`${o}\` must be used within \`${t}\``)}return r.displayName=`${t}Provider`,[r,i]};function DY(t,e){return typeof t=="string"?!1:e in t}function cu(t,e,n){return t&&e&&DY(t,e)?t[e]:n}const ow={padding:["padding-block-start","padding-inline-end","padding-block-end","padding-inline-start"],paddingTop:"padding-block-start",paddingRight:"padding-inline-end",paddingBottom:"padding-block-end",paddingLeft:"padding-inline-start",margin:["margin-block-start","margin-inline-end","margin-block-end","margin-inline-start"],marginLeft:"margin-inline-start",marginRight:"margin-inline-end",marginTop:"margin-block-start",marginBottom:"margin-block-end",borderRadius:"border-radius",borderStyle:"border-style",borderWidth:"border-width",borderColor:"border-color",fontSize:"font-size",fontWeight:"font-weight",lineHeight:"line-height",zIndex:"z-index",boxShadow:"box-shadow",pointerEvents:"pointer-events",textAlign:"text-align",textTransform:"text-transform",textDecoration:"text-decoration",flexGrow:"flex-grow",flexShrink:"flex-shrink",flexBasis:"flex-basis",minWidth:"min-width",maxWidth:"max-width",minHeight:"min-height",maxHeight:"max-height",flexDirection:"flex-direction",flexWrap:"flex-wrap",justifyContent:"justify-content",alignItems:"align-items"},IY=t=>{const[e,n,r,i]=t,o=n??e;return[e,o,r??e,i??o]};function _Y(t,e){switch(t){case"gap":case"padding":case"margin":case"paddingTop":case"paddingLeft":case"paddingRight":case"paddingBottom":case"marginTop":case"marginLeft":case"marginRight":case"marginBottom":case"left":case"right":case"top":case"bottom":case"width":case"maxWidth":case"minWidth":case"height":case"maxHeight":case"minHeight":case"borderRadius":case"borderWidth":return e.spaces;case"color":case"background":case"borderColor":return e.colors;case"fontSize":return e.fontSizes;case"fontWeight":return e.fontWeights;case"lineHeight":return e.lineHeights;case"zIndex":return e.zIndices;case"boxShadow":return e.shadows;default:return null}}const _h=(t,e)=>{const n=Object.entries(t).reduce((r,i)=>{const[o,s]=i,a=_Y(o,e),c=Object.prototype.hasOwnProperty.call(ow,o)?ow[o]:o;return c&&(s||s===0)&&(typeof s=="object"&&!Array.isArray(s)?Object.entries(s).forEach(([h,f])=>{r[h]={...r[h],...sw(c,f,a)}}):r.initial={...r.initial,...sw(c,s,a)}),r},{initial:{},small:{},medium:{},large:{}});return Object.entries(n).reduce((r,[i,o])=>{if(o&&Object.keys(o).length>0){const s=Object.entries(o).reduce((a,[c,h])=>(a.push(`${c}: ${h};`),a),[]).join(`
90
- `);i==="initial"?r.push(s):r.push(`${e.breakpoints[i]}{ ${s} }`)}return r},[]).join(`
91
- `)},sw=(t,e,n)=>{if(Array.isArray(t)&&Array.isArray(e)){const r=IY(e);return t.reduce((i,o,s)=>(i[o]=cu(n,r[s],r[s]),i),{})}else return Array.isArray(t)&&!Array.isArray(e)?t.reduce((r,i)=>(r[i]=cu(n,e,e),r),{}):!Array.isArray(t)&&!Array.isArray(e)?{[t]:cu(n,e,e)}:(console.warn("You've passed an array of values to a property that does not support it. Please check the property and value you're passing."),{})},nn=$.forwardRef,be=nn((t,e)=>{const{background:n,basis:r,borderColor:i,color:o,flex:s,fontSize:a,grow:c,hasRadius:h,padding:f,paddingBottom:d,paddingLeft:m,paddingRight:v,paddingTop:w,margin:x,marginLeft:C,marginBottom:S,marginRight:A,marginTop:T,shadow:O,shrink:D,lineHeight:L,fontWeight:I,width:V,minWidth:F,maxWidth:H,height:K,minHeight:W,maxHeight:J,top:G,left:re,bottom:oe,right:te,borderRadius:ie,borderStyle:Y,borderWidth:ue,tag:ge,pointerEvents:De,display:we,position:Ve,zIndex:Ne,overflow:He,cursor:pe,transition:Oe,transform:ke,animation:Ae,textAlign:_e,textTransform:ze,...Et}=t,Ze=ge||"div",Pe={$background:n,$basis:r,$borderColor:i,$color:o,$flex:s,$fontSize:a,$grow:c,$hasRadius:h,$padding:f,$paddingBottom:d,$paddingLeft:m,$paddingRight:v,$paddingTop:w,$margin:x,$marginLeft:C,$marginBottom:S,$marginRight:A,$marginTop:T,$shadow:O,$shrink:D,$lineHeight:L,$fontWeight:I,$width:V,$minWidth:F,$maxWidth:H,$height:K,$minHeight:W,$maxHeight:J,$top:G,$left:re,$bottom:oe,$right:te,$borderRadius:ie,$borderStyle:Y,$borderWidth:ue,$pointerEvents:De,$display:we,$position:Ve,$zIndex:Ne,$overflow:He,$cursor:pe,$transition:Oe,$transform:ke,$animation:Ae,$textAlign:_e,$textTransform:ze};return p.jsx(LY,{as:Ze,ref:e,...Pe,...Et})}),LY=k.styled.div`
92
- ${({theme:t,...e})=>_h({padding:e.$padding,paddingTop:e.$paddingTop,paddingBottom:e.$paddingBottom,paddingLeft:e.$paddingLeft,paddingRight:e.$paddingRight,margin:e.$margin,marginTop:e.$marginTop,marginBottom:e.$marginBottom,marginLeft:e.$marginLeft,marginRight:e.$marginRight,top:e.$top,left:e.$left,bottom:e.$bottom,right:e.$right,width:e.$width,minWidth:e.$minWidth,maxWidth:e.$maxWidth,height:e.$height,minHeight:e.$minHeight,maxHeight:e.$maxHeight,color:e.$color,background:e.$background,fontSize:e.$fontSize,fontWeight:e.$fontWeight,lineHeight:e.$lineHeight,borderRadius:e.$hasRadius?t.borderRadius:e.$borderRadius,borderStyle:e.$borderColor&&!e.$borderStyle?"solid":e.$borderStyle,borderWidth:e.$borderColor&&!e.$borderWidth?"1px":e.$borderWidth,borderColor:e.$borderColor,zIndex:e.$zIndex,boxShadow:e.$shadow,display:e.$display,pointerEvents:e.$pointerEvents,cursor:e.$cursor,textAlign:e.$textAlign,textTransform:e.$textTransform,transition:e.$transition,transform:e.$transform,animation:e.$animation,position:e.$position,overflow:e.$overflow,flex:e.$flex,flexShrink:e.$shrink,flexGrow:e.$grow,flexBasis:e.$basis},t)};
93
- `,he=nn((t,e)=>{const{className:n,alignItems:r,direction:i,inline:o,gap:s,justifyContent:a,wrap:c,...h}=t,f={$alignItems:r,$direction:i,$gap:s,$justifyContent:a,$wrap:c,$inline:o};return p.jsx(BY,{className:n,ref:e,...f,...h})}),BY=k.styled(be)`
94
- ${({theme:t,$display:e="flex",$alignItems:n="center",$direction:r="row",...i})=>_h({gap:i.$gap,alignItems:n,justifyContent:i.$justifyContent,flexWrap:i.$wrap,flexDirection:r,display:i.$inline?"inline-flex":e},t)};
95
- `,NY="alpha",jY="beta",FY="delta",VY="epsilon",aw="omega",HY="pi",PY="sigma",OC=k.css`
96
- display: block;
97
- white-space: nowrap;
98
- overflow: hidden;
99
- text-overflow: ellipsis;
100
- `,WY=({$variant:t=aw,theme:e})=>{switch(t){case NY:return`
101
- font-weight: ${e.fontWeights.bold};
102
- font-size: ${e.fontSizes[5]};
103
- line-height: ${e.lineHeights[2]};
104
- `;case jY:return`
105
- font-weight: ${e.fontWeights.bold};
106
- font-size: ${e.fontSizes[4]};
107
- line-height: ${e.lineHeights[1]};
108
- `;case FY:return`
109
- font-weight: ${e.fontWeights.semiBold};
110
- font-size: ${e.fontSizes[3]};
111
- line-height: ${e.lineHeights[2]};
112
- `;case VY:return`
113
- font-size: ${e.fontSizes[3]};
114
- line-height: ${e.lineHeights[6]};
115
- `;case aw:return`
116
- font-size: ${e.fontSizes[2]};
117
- line-height: ${e.lineHeights[4]};
118
- `;case HY:return`
119
- font-size: ${e.fontSizes[1]};
120
- line-height: ${e.lineHeights[3]};
121
- `;case PY:return`
122
- font-weight: ${e.fontWeights.bold};
123
- font-size: ${e.fontSizes[0]};
124
- line-height: ${e.lineHeights[5]};
125
- text-transform: uppercase;
126
- `;default:return`
127
- font-size: ${e.fontSizes[2]};
128
- `}},Re=nn((t,e)=>{const{ellipsis:n,textColor:r="currentcolor",textDecoration:i,textTransform:o,variant:s,lineHeight:a,fontWeight:c,fontSize:h,...f}=t,d={$ellipsis:n,$textColor:r,$textDecoration:i,$textTransform:o,$variant:s,$lineHeight:a,$fontWeight:c,$fontSize:h};return p.jsx(zY,{ref:e,tag:"span",...d,...f})}),zY=k.styled(be)`
129
- ${WY}
130
- ${({$ellipsis:t})=>t?OC:""}
131
-
132
- ${({theme:t,...e})=>_h({color:e.$textColor,textDecoration:e.$textDecoration,textTransform:e.$textTransform,lineHeight:e.$lineHeight,fontWeight:e.$fontWeight,fontSize:e.$fontSize},t)}
133
- `,[UY,Om]=vl("Accordion"),qY=$.forwardRef(({children:t,size:e="S",...n},r)=>p.jsx(KY,{ref:r,$size:e,collapsible:!0,...n,type:"single",children:p.jsx(UY,{size:e,children:t})})),KY=k.styled(ZD)`
134
- background-color: ${t=>t.theme.colors.neutral0};
135
-
136
- ${t=>t.$size==="S"?k.css`
137
- border-radius: ${e=>e.theme.borderRadius};
138
- border: solid 1px ${e=>e.theme.colors.neutral200};
139
- `:k.css``}
140
- `,GY=$.forwardRef((t,e)=>{const{size:n}=Om("Item");return p.jsx(YY,{$size:n,"data-size":n,ref:e,...t})}),YY=k.styled(QD)`
141
- overflow: hidden;
142
- margin: 1px 0;
143
-
144
- &:first-child {
145
- border-top-left-radius: 0.3rem;
146
- border-top-right-radius: 0.3rem;
147
- margin-top: 0;
148
- }
149
-
150
- &:last-child {
151
- border-bottom-left-radius: 0.3rem;
152
- border-bottom-right-radius: 0.3rem;
153
- margin-bottom: 0;
154
- }
155
-
156
- &[data-size='S'] {
157
- & + & {
158
- border-top: solid 1px ${t=>t.theme.colors.neutral200};
159
- }
160
- }
161
-
162
- &[data-state='open'] {
163
- box-shadow: 0 0 0 1px ${t=>t.theme.colors.primary600};
164
- }
165
-
166
- &:not([data-disabled]):hover {
167
- box-shadow: 0 0 0 1px ${t=>t.theme.colors.primary600};
168
- }
169
-
170
- /* This applies our desired focus effect correctly. */
171
- &:focus-within {
172
- position: relative;
173
- z-index: 1;
174
- box-shadow: 0 0 0 1px ${t=>t.theme.colors.primary600};
175
- }
176
-
177
- @media (prefers-reduced-motion: no-preference) {
178
- transition: box-shadow ${t=>t.theme.motion.timings[120]}
179
- ${t=>t.theme.motion.easings.easeOutQuad};
180
- }
181
- `,XY=$.forwardRef(({caretPosition:t="left",description:e,icon:n,iconProps:r,children:i,...o},s)=>{const{size:a}=Om("Trigger");return p.jsxs(IC,{$caretPosition:t,$size:a,ref:s,...o,children:[t==="left"?p.jsx(Xu,{$size:a,children:p.jsx(Mi,{width:a==="S"?"1.2rem":"1.6rem",height:a==="S"?"1.2rem":"1.6rem"})}):null,p.jsxs(he,{tag:"span",gap:2,children:[n&&a==="S"?p.jsx(DC,{children:p.jsx(n,{...r})}):null,p.jsxs(he,{alignItems:"flex-start",direction:"column",tag:"span",ref:s,children:[p.jsx(Re,{fontWeight:a==="S"?"bold":void 0,ellipsis:!0,variant:a==="M"?"delta":void 0,textAlign:"left",children:i}),e&&a==="M"?p.jsx(Re,{textAlign:"left",children:e}):null]})]}),t==="right"?p.jsx(Xu,{$size:a,children:p.jsx(Mi,{width:a==="S"?"1.2rem":"1.6rem",height:a==="S"?"1.2rem":"1.6rem"})}):null]})}),DC=k.styled(be)`
182
- color: ${t=>t.theme.colors.neutral500};
183
- display: flex;
184
-
185
- @media (prefers-reduced-motion: no-preference) {
186
- transition: ${t=>t.theme.transitions.color};
187
- }
188
- `,Xu=k.styled(he).attrs(t=>({...t,tag:"span"}))`
189
- background-color: ${t=>t.theme.colors.neutral200};
190
- width: ${t=>t.$size==="S"?"2.4rem":"3.2rem"};
191
- height: ${t=>t.$size==="S"?"2.4rem":"3.2rem"};
192
- flex: ${t=>t.$size==="S"?"0 0 2.4rem":"0 0 3.2rem"};
193
- border-radius: 50%;
194
- justify-content: center;
195
-
196
- @media (prefers-reduced-motion: no-preference) {
197
- transition:
198
- transform ${t=>t.theme.motion.timings[200]} ${t=>t.theme.motion.easings.authenticMotion},
199
- ${t=>t.theme.transitions.backgroundColor};
200
- }
201
- `,IC=k.styled(eI)`
202
- display: flex;
203
- align-items: center;
204
- justify-content: ${t=>t.$caretPosition==="left"?"flex-start":"space-between"};
205
- width: 100%;
206
- gap: ${t=>t.theme.spaces[4]};
207
- padding-inline: ${t=>t.$size==="S"?t.theme.spaces[4]:t.theme.spaces[6]};
208
- padding-block: ${t=>t.$size==="S"?t.theme.spaces[3]:t.theme.spaces[6]};
209
- cursor: pointer;
210
- color: ${t=>t.theme.colors.neutral800};
211
-
212
- &[data-disabled] {
213
- cursor: default;
214
- color: ${t=>t.theme.colors.neutral600};
215
- }
216
-
217
- &[data-state='open'] > ${Xu} {
218
- transform: rotate(180deg);
219
- }
220
-
221
- /* we remove the default focus because the entire item should have the focus style and the default would be hidden. */
222
- &:focus-visible {
223
- outline: none;
224
- }
225
-
226
- @media (prefers-reduced-motion: no-preference) {
227
- transition: ${t=>t.theme.transitions.color};
228
- }
229
- `,ZY=$.forwardRef((t,e)=>{const{size:n}=Om("Trigger");return p.jsx(_C,{$size:n,...t,ref:e})}),_C=k.styled(he).attrs(t=>({...t,tag:"span"}))`
230
- padding-inline: ${t=>t.$size==="S"?t.theme.spaces[2]:t.theme.spaces[6]};
231
- padding-block: ${t=>t.$size==="S"?t.theme.spaces[2]:t.theme.spaces[6]};
232
-
233
- // Remove default IconButton styles so there are no backgrounds or borders.
234
- & > button {
235
- border: none;
236
- background: none;
237
- color: ${t=>t.theme.colors.neutral600};
238
-
239
- @media (prefers-reduced-motion: no-preference) {
240
- transition: ${t=>t.theme.transitions.color};
241
- }
242
- }
243
- `,QY=$.forwardRef(({variant:t="primary",...e},n)=>p.jsx(JY,{$variant:t,ref:n,...e})),JY=k.styled(JD)`
244
- display: flex;
245
- align-items: center;
246
- background-color: ${t=>t.$variant==="primary"?t.theme.colors.neutral0:t.theme.colors.neutral100};
247
-
248
- &[data-disabled] {
249
- background-color: ${t=>t.theme.colors.neutral150};
250
- }
251
-
252
- &:not([data-disabled]) {
253
- &:hover,
254
- &[data-state='open'] {
255
- background-color: ${t=>t.theme.colors.primary100};
256
-
257
- & > ${IC} {
258
- color: ${t=>t.theme.colors.primary600};
259
-
260
- & ${DC} {
261
- color: ${t=>t.theme.colors.primary600};
262
- }
263
-
264
- & ${Xu} {
265
- background-color: ${t=>t.theme.colors.primary200};
266
- }
267
- }
268
-
269
- & > ${_C} > button {
270
- color: ${t=>t.theme.colors.primary600};
271
- }
272
- }
273
- }
274
-
275
- @media (prefers-reduced-motion: no-preference) {
276
- transition: ${t=>t.theme.transitions.backgroundColor};
277
- }
278
- `,eX=$.forwardRef((t,e)=>p.jsx(rX,{ref:e,...t})),tX=k.keyframes`
279
- from {
280
- height: 0;
281
- }
282
- to {
283
- height: var(--radix-accordion-content-height);
284
- }
285
- `,nX=k.keyframes`
286
- from {
287
- height: var(--radix-accordion-content-height);
288
- }
289
- to {
290
- height: 0;
291
- }
292
- `,rX=k.styled(tI)`
293
- overflow: hidden;
294
-
295
- @media (prefers-reduced-motion: no-preference) {
296
- &[data-state='open'] {
297
- animation: ${tX} ${t=>t.theme.motion.timings[320]}
298
- ${t=>t.theme.motion.easings.authenticMotion};
299
- }
300
-
301
- &[data-state='closed'] {
302
- animation: ${nX} ${t=>t.theme.motion.timings[320]}
303
- ${t=>t.theme.motion.easings.authenticMotion};
304
- }
305
- }
306
- `,iX=Object.freeze(Object.defineProperty({__proto__:null,Actions:ZY,Content:eX,Header:QY,Item:GY,Root:qY,Trigger:XY},Symbol.toStringTag,{value:"Module"})),Lh=k.css`
307
- position: relative;
308
- outline: none;
309
-
310
- &:after {
311
- transition-property: all;
312
- transition-duration: 0.2s;
313
- border-radius: 8px;
314
- content: '';
315
- position: absolute;
316
- top: -4px;
317
- bottom: -4px;
318
- left: -4px;
319
- right: -4px;
320
- border: 2px solid transparent;
321
- }
322
-
323
- &:focus-visible {
324
- outline: none;
325
-
326
- &:after {
327
- border-radius: 8px;
328
- content: '';
329
- position: absolute;
330
- top: -5px;
331
- bottom: -5px;
332
- left: -5px;
333
- right: -5px;
334
- border: 2px solid ${t=>t.theme.colors.primary600};
335
- }
336
- }
337
- `,ko=({tag:t,...e})=>{const n=t||"span";return p.jsx(oX,{...e,as:n})},oX=k.styled.span`
338
- border: 0;
339
- clip: rect(0 0 0 0);
340
- height: 1px;
341
- margin: -1px;
342
- overflow: hidden;
343
- padding: 0;
344
- position: absolute;
345
- width: 1px;
346
- `,Ts=({children:t,label:e})=>{const n=$.Children.only(t);return p.jsxs(p.Fragment,{children:[$.cloneElement(n,{"aria-hidden":"true",focusable:"false"}),p.jsx(ko,{children:e})]})};Ts.displayName="AccessibleIcon";const LC=t=>{switch(t){case"danger":return"danger100";case"success":return"success100";case"warning":return"warning100";default:return"primary100"}},sX=t=>LC(t).replace("100","200"),D1=({theme:t,$variant:e})=>e==="danger"?t.colors.danger700:e==="success"?t.colors.success700:e==="warning"?t.colors.warning700:t.colors.primary700,aX=k.styled(be)`
347
- ${Lh};
348
- `,lX=k.styled(he)`
349
- svg {
350
- height: 100%;
351
- width: 100%;
352
-
353
- path {
354
- fill: ${D1};
355
- }
356
- }
357
- `,cX=({variant:t,...e})=>t==="success"?p.jsx(WI,{...e}):t==="danger"||t==="warning"?p.jsx(f3,{...e}):p.jsx(pL,{...e}),uX=k.styled(be)`
358
- & a > span {
359
- color: ${D1};
360
- }
361
-
362
- svg path {
363
- fill: ${D1};
364
- }
365
- `,hX=({title:t,children:e,variant:n="default",onClose:r,closeLabel:i,titleAs:o="p",action:s,...a})=>p.jsxs(he,{alignItems:"flex-start",background:LC(n),borderColor:sX(n),shadow:"filterShadow",gap:3,hasRadius:!0,padding:5,paddingRight:6,...a,children:[p.jsx(lX,{height:"2rem",shrink:0,$variant:n,width:"2rem",children:p.jsx(cX,{"aria-hidden":!0,variant:n})}),p.jsxs(he,{alignItems:"start",gap:s?2:1,wrap:"wrap",role:n==="danger"?"alert":"status",width:"100%",children:[t&&p.jsx(Re,{fontWeight:"bold",textColor:"neutral800",tag:o,children:t}),p.jsx(Re,{tag:"p",textColor:"neutral800",children:e}),s&&p.jsx(uX,{$variant:n,children:s})]}),p.jsx(aX,{tag:"button",background:"transparent",borderColor:void 0,height:"1.6rem",width:"1.6rem",marginTop:1,onClick:r,color:"neutral700",children:p.jsx(Ts,{label:i,children:p.jsx(ji,{})})})]});function yr({prop:t,defaultProp:e,onChange:n=()=>{}}){const[r,i]=BC({defaultProp:e,onChange:n}),o=t!==void 0,s=o?t:r,a=Ct(n),c=$.useCallback(h=>{if(o){const d=typeof h=="function"?h(t):h;d!==t&&a(d)}else i(h)},[o,t,i,a]);return[s,c]}function BC({defaultProp:t,onChange:e}){const n=$.useState(t),[r]=n,i=$.useRef(r),o=Ct(e);return $.useEffect(()=>{i.current!==r&&(o(r),i.current=r)},[r,i,o]),n}const I1={easeInSine:"cubic-bezier(0.47, 0, 0.745, 0.715)",easeOutSine:"cubic-bezier(0.39, 0.575, 0.565, 1)",easeInOutSine:"cubic-bezier(0.39, 0.575, 0.565, 1)",easeInQuad:"cubic-bezier(0.55, 0.085, 0.68, 0.53)",easeOutQuad:"cubic-bezier(0.25, 0.46, 0.45, 0.94)",easeInOutQuad:"cubic-bezier(0.25, 0.46, 0.45, 0.94)",easeInCubic:"cubic-bezier(0.55, 0.055, 0.675, 0.19)",easeOutCubic:"cubic-bezier(0.215, 0.61, 0.355, 1)",easeInOutCubic:"cubic-bezier(0.215, 0.61, 0.355, 1)",easeInQuart:"cubic-bezier(0.895, 0.03, 0.685, 0.22)",easeOutQuart:"cubic-bezier(0.165, 0.84, 0.44, 1)",easeInOutQuart:"cubic-bezier(0.165, 0.84, 0.44, 1)",easeInQuint:"cubic-bezier(0.755, 0.05, 0.855, 0.06)",easeOutQuint:"cubic-bezier(0.23, 1, 0.32, 1)",easeInOutQuint:"cubic-bezier(0.23, 1, 0.32, 1)",easeInExpo:"cubic-bezier(0.95, 0.05, 0.795, 0.035)",easeOutExpo:"cubic-bezier(0.19, 1, 0.22, 1)",easeInOutExpo:"cubic-bezier(0.19, 1, 0.22, 1)",easeInCirc:"cubic-bezier(0.6, 0.04, 0.98, 0.335)",easeOutCirc:"cubic-bezier(0.075, 0.82, 0.165, 1)",easeInOutCirc:"cubic-bezier(0.075, 0.82, 0.165, 1)",easeInBack:"cubic-bezier(0.6, -0.28, 0.735, 0.045)",easeOutBack:"cubic-bezier(0.175, 0.885, 0.32, 1.275)",easeInOutBack:"cubic-bezier(0.68, -0.55, 0.265, 1.55)",easeInOutFast:"cubic-bezier(1,0,0,1)",authenticMotion:"cubic-bezier(.4,0,.2,1)"},_1={320:"320ms",200:"200ms",120:"120ms"},fX={color:`color ${_1[120]} ${I1.easeOutQuad}`,backgroundColor:`background-color ${_1[120]} ${I1.easeOutQuad}`},pt={overlayFadeIn:k.keyframes`
366
- from {
367
- opacity: 0;
368
- }
369
- to {
370
- opacity: 0.2;
371
- }
372
- `,modalPopIn:k.keyframes`
373
- from {
374
- transform:translate(-50%, -50%) scale(0.8);
375
- opacity: 0;
376
- }
377
- to {
378
- transform: translate(-50%, -50%) scale(1);
379
- opacity: 1;
380
- }
381
- `,modalPopOut:k.keyframes`
382
- from {
383
- transform: translate(-50%, -50%) scale(1);
384
- opacity: 1;
385
- }
386
- to {
387
- transform:translate(-50%, -50%) scale(0.8);
388
- opacity: 0;
389
- }
390
- `,popIn:k.keyframes`
391
- from {
392
- transform: scale(0.8);
393
- opacity: 0;
394
- }
395
- to {
396
- transform: scale(1);
397
- opacity: 1;
398
- }
399
- `,popOut:k.keyframes`
400
- from {
401
- transform: scale(1);
402
- opacity: 1;
403
- }
404
- to {
405
- transform: scale(0.8);
406
- opacity: 0;
407
- }
408
- `,slideDownIn:k.keyframes`
409
- from {
410
- opacity: 0;
411
- transform: translateY(-10px);
412
- }
413
- to {
414
- opacity: 1;
415
- transform: translateY(0);
416
- }
417
- `,slideDownOut:k.keyframes`
418
- from {
419
- opacity: 1;
420
- transform: translateY(0);
421
- }
422
- to {
423
- opacity: 0;
424
- transform: translateY(-10px);
425
- }
426
- `,slideUpIn:k.keyframes`
427
- from {
428
- opacity: 0;
429
- transform: translateY(10px);
430
- }
431
- to {
432
- opacity: 1;
433
- transform: translateY(0);
434
- }
435
- `,slideUpOut:k.keyframes`
436
- from {
437
- opacity: 1;
438
- transform: translateY(0);
439
- }
440
- to {
441
- opacity: 0;
442
- transform: translateY(10px);
443
- }
444
- `,fadeIn:k.keyframes`
445
- from {
446
- opacity: 0;
447
- }
448
- to {
449
- opacity: 1;
450
- }
451
- `,fadeOut:k.keyframes`
452
- from {
453
- opacity: 1;
454
- }
455
- to {
456
- opacity: 0;
457
- }
458
- `},Ya=32,lw=2,dX=$.forwardRef(({onLoadingStatusChange:t,delayMs:e=600,src:n,alt:r,fallback:i,preview:o=!1,...s},a)=>{const[c,h]=yr({onChange:t}),[f,d]=$.useState(!1),m=o&&c==="loaded",v=w=>{m&&d(w)};return p.jsxs(fx,{onOpenChange:v,children:[p.jsx(dx,{asChild:!0,children:p.jsxs(L1,{ref:a,...s,children:[m?p.jsx(gX,{width:"100%",height:"100%",position:"absolute",background:"neutral0",zIndex:"overlay",style:{opacity:f?.4:0}}):null,p.jsx(mX,{src:n,alt:r,onLoadingStatusChange:h}),p.jsx(ON,{delayMs:e,children:p.jsx(Re,{fontWeight:"bold",textTransform:"uppercase",children:i})})]})}),m?p.jsx(gx,{children:p.jsx(pX,{side:"top",sideOffset:4,children:p.jsx(vX,{src:n,alt:r})})}):null]})}),NC=k.css`
459
- display: inline-flex;
460
- align-items: center;
461
- justify-content: center;
462
- vertical-align: middle;
463
- overflow: hidden;
464
- user-select: none;
465
- overflow: hidden;
466
- border-radius: 50%;
467
- `,jC=k.css`
468
- width: 100%;
469
- height: 100%;
470
- object-fit: cover;
471
- border-radius: inherit;
472
- `,L1=k.styled(MN)`
473
- position: relative;
474
- z-index: 0;
475
- ${NC}
476
- width: ${Ya/10}rem;
477
- height: ${Ya/10}rem;
478
- /* TODO: we should get the user email & hash it to turn it into a hex-value so different emails can consistently get a different background */
479
- background-color: ${t=>t.theme.colors.primary600};
480
- color: ${t=>t.theme.colors.neutral0};
481
- `,gX=k.styled(be)`
482
- @media (prefers-reduced-motion: no-preference) {
483
- transition: opacity ${t=>t.theme.motion.timings[200]}
484
- ${t=>t.theme.motion.easings.authenticMotion};
485
- }
486
- `,mX=k.styled(EN)`
487
- ${jC}
488
- `,pX=k.styled(mx)`
489
- ${NC}
490
- width: ${Ya*lw/10}rem;
491
- height: ${Ya*lw/10}rem;
492
-
493
- @media (prefers-reduced-motion: no-preference) {
494
- animation: ${pt.fadeIn} ${t=>t.theme.motion.timings[200]}
495
- ${t=>t.theme.motion.easings.authenticMotion};
496
- }
497
- `,vX=k.styled.img`
498
- ${jC}
499
- `,bX=$.forwardRef((t,e)=>p.jsx(wX,{...t,ref:e,tag:"div"})),wX=k.styled(he)`
500
- & > ${L1} + ${L1} {
501
- margin-left: -${Ya/10/2}rem;
502
- }
503
- `,xX=Object.freeze(Object.defineProperty({__proto__:null,Group:bX,Item:dX},Symbol.toStringTag,{value:"Module"})),Dm=({active:t=!1,size:e="M",textColor:n="neutral600",backgroundColor:r="neutral150",children:i,minWidth:o=5,...s})=>{const a=e==="S"?1:2;return p.jsx(yX,{inline:!0,alignItems:"center",justifyContent:"center",minWidth:o,paddingLeft:a,paddingRight:a,background:t?"primary200":r,$size:e,...s,children:p.jsx(Re,{variant:"sigma",textColor:t?"primary600":n,lineHeight:"1rem",children:i})})},yX=k.styled(he)`
504
- border-radius: ${({theme:t,$size:e})=>e==="S"?"2px":t.borderRadius};
505
- ${({$size:t,theme:e})=>t==="S"?k.css`
506
- padding-block: 0.3rem;
507
- padding-inline ${e.spaces[1]}
508
- `:k.css`
509
- padding-block: 0.7rem;
510
- padding-inline ${e.spaces[2]}
511
- `};
512
- `,bl=nn(({href:t,disabled:e=!1,isExternal:n=!1,...r},i)=>p.jsx(CX,{tag:"a",ref:i,target:n?"_blank":void 0,rel:n?"noreferrer noopener":void 0,href:t,tabIndex:e?-1:void 0,"aria-disabled":e,pointerEvents:e?"none":void 0,cursor:e?void 0:"pointer",...r})),CX=k.styled(be)`
513
- text-decoration: none;
514
-
515
- &:visited {
516
- color: inherit;
517
- }
518
- `,FC=()=>p.jsx(be,{"aria-hidden":!0,paddingLeft:1,paddingRight:1,children:p.jsx(Re,{variant:"pi",textColor:"neutral500",children:"/"})});FC.displayName="Divider";const $X=k.styled(he)`
519
- // CrumbLinks do have padding-x, because they need to have a
520
- // interaction effect, which mis-aligns the breadcrumbs on the left.
521
- // This normalizes the behavior by moving the first item to left by
522
- // the same amount it has inner padding
523
- & > *:first-child {
524
- margin-left: ${({theme:t})=>`calc(-1*${t.spaces[2]})`};
525
- }
526
- `,SX=$.forwardRef(({label:t,children:e,...n},r)=>{const i=$.Children.toArray(e);return p.jsx(be,{"aria-label":t,tag:"nav",...n,ref:r,children:p.jsx($X,{tag:"ol",children:$.Children.map(i,(o,s)=>{const a=i.length>1&&s+1<i.length;return p.jsxs(he,{inline:!0,tag:"li",children:[o,a&&p.jsx(FC,{})]})})})})});SX.displayName="Breadcrumbs";const AX=$.forwardRef(({children:t,isCurrent:e=!1,...n},r)=>p.jsx(be,{paddingLeft:2,paddingRight:2,paddingTop:1,paddingBottom:1,ref:r,children:p.jsx(Re,{variant:"pi",textColor:"neutral800",fontWeight:e?"bold":"regular","aria-current":e,...n,children:t})}));AX.displayName="Crumb";const RX=k.styled(bl)`
527
- border-radius: ${({theme:t})=>t.borderRadius};
528
- color: ${({theme:t})=>t.colors.neutral600};
529
- font-size: ${({theme:t})=>t.fontSizes[1]};
530
- line-height: ${({theme:t})=>t.lineHeights[4]};
531
- padding: ${({theme:t})=>`${t.spaces[1]} ${t.spaces[2]}`};
532
- text-decoration: none;
533
-
534
- :hover,
535
- :focus {
536
- background-color: ${({theme:t})=>t.colors.neutral200};
537
- color: ${({theme:t})=>t.colors.neutral700};
538
- }
539
- `,kX=$.forwardRef(({children:t,...e},n)=>p.jsx(RX,{ref:n,...e,children:t}));kX.displayName="CrumbLink";const Ms=t=>t.replaceAll(":","");function TX(t,e){typeof t=="function"?t(e):t!=null&&(t.current=e)}function VC(...t){return e=>t.forEach(n=>TX(n,e))}function gn(...t){return $.useCallback(VC(...t),t)}const MX=()=>typeof window>"u"||!window.navigator||/ServerSideRendering|^Deno\//.test(window.navigator.userAgent),wo=MX()?b.useEffect:b.useLayoutEffect,EX=$.useId||(()=>{});let OX=0;const Tn=t=>{const[e,n]=$.useState(EX());return wo(()=>{t||n(r=>r??String(OX++))},[t]),t?.toString()??(e||"")},wl=(t,e,{selectorToWatch:n,skipWhen:r=!1})=>{const i=pg(e);$.useEffect(()=>{if(r||!t.current)return;const o={root:t.current,rootMargin:"0px"},s=h=>{h.forEach(f=>{f.isIntersecting&&t.current&&t.current.scrollHeight>t.current.clientHeight&&i(f)})},a=new IntersectionObserver(s,o),c=t.current.querySelector(n);return c&&a.observe(c),()=>{a.disconnect()}},[r,i,n,t])},Im="success-light",_m="danger-light",Bh="default",xl="tertiary",yl="secondary",HC="danger",PC="success",Nh="ghost",Lm=[Im,_m],DX=[Bh,xl,yl,HC,PC,Nh,...Lm],IX=["XS","S","M","L"],Kn=t=>t===Im||t===_m?`${t.substring(0,t.lastIndexOf("-"))}`:t===xl?"neutral":t===Bh||t===yl||DX.every(e=>e!==t)?"primary":`${t}`,WC=({theme:t})=>k.css`
540
- border: 1px solid ${t.colors.neutral200};
541
- background: ${t.colors.neutral150};
542
- color: ${t.colors.neutral600};
543
- cursor: default;
544
- `,zC=({theme:t,$variant:e})=>[...Lm,yl].includes(e)?k.css`
545
- background-color: ${t.colors.neutral0};
546
- `:e===xl?k.css`
547
- background-color: ${t.colors.neutral100};
548
- `:e===Nh?k.css`
549
- background-color: ${t.colors.neutral100};
550
- `:e===Bh?k.css`
551
- border: 1px solid ${t.colors.buttonPrimary500};
552
- background: ${t.colors.buttonPrimary500};
553
- `:k.css`
554
- border: 1px solid ${t.colors[`${Kn(e)}500`]};
555
- background: ${t.colors[`${Kn(e)}500`]};
556
- `,UC=({theme:t,$variant:e})=>[...Lm,yl].includes(e)?k.css`
557
- background-color: ${t.colors.neutral0};
558
- border: 1px solid ${t.colors[`${Kn(e)}600`]};
559
- color: ${t.colors[`${Kn(e)}600`]};
560
- `:e===xl||e===Nh?k.css`
561
- background-color: ${t.colors.neutral150};
562
- `:k.css`
563
- border: 1px solid ${t.colors[`${Kn(e)}600`]};
564
- background: ${t.colors[`${Kn(e)}600`]};
565
- `,qC=({theme:t,$variant:e})=>{switch(e){case _m:case Im:case yl:return k.css`
566
- border: 1px solid ${t.colors[`${Kn(e)}200`]};
567
- background: ${t.colors[`${Kn(e)}100`]};
568
- color: ${t.colors[`${Kn(e)}700`]};
569
- `;case xl:return k.css`
570
- border: 1px solid ${t.colors.neutral200};
571
- background: ${t.colors.neutral0};
572
- color: ${t.colors.neutral800};
573
- `;case Nh:return k.css`
574
- border: 1px solid transparent;
575
- background: transparent;
576
- color: ${t.colors.neutral800};
577
-
578
- svg {
579
- fill: ${t.colors.neutral500};
580
- }
581
- `;case PC:case HC:return k.css`
582
- border: 1px solid ${t.colors[`${Kn(e)}600`]};
583
- background: ${t.colors[`${Kn(e)}600`]};
584
- color: ${t.colors.neutral0};
585
- `;default:return k.css`
586
- border: 1px solid ${t.colors.buttonPrimary600};
587
- background: ${t.colors.buttonPrimary600};
588
- color: ${t.colors.buttonNeutral0};
589
- `}},Zu=nn(({variant:t=Bh,startIcon:e,endIcon:n,disabled:r=!1,children:i,onClick:o,size:s=IX[1],loading:a=!1,fullWidth:c=!1,...h},f)=>{const d=r||a,m=v=>{!d&&o&&o(v)};return p.jsxs(BX,{ref:f,"aria-disabled":d,disabled:d,$size:s,$variant:t,tag:"button",onClick:m,hasRadius:!0,gap:2,inline:!0,alignItems:"center",justifyContent:"center",width:c?"100%":void 0,paddingLeft:4,paddingRight:4,cursor:"pointer",...h,children:[(e||a)&&p.jsx(he,{tag:"span","aria-hidden":!0,children:a?p.jsx(LX,{}):e}),p.jsx(Re,{variant:s==="S"?"pi":void 0,fontWeight:"bold",children:i}),n&&p.jsx(he,{tag:"span","aria-hidden":!0,children:n})]})}),_X=k.keyframes`
590
- from {
591
- transform: rotate(0deg);
592
- }
593
- to {
594
- transform: rotate(359deg);
595
- }
596
- `,LX=k.styled(u3)`
597
- animation: ${_X} 2s infinite linear;
598
- will-change: transform;
599
- `,BX=k.styled(he)`
600
- height: ${({theme:t,$size:e})=>t.sizes.button[e]};
601
- text-decoration: none;
602
- ${qC}
603
-
604
- &:hover {
605
- ${zC}
606
- }
607
-
608
- &:active {
609
- ${UC}
610
- }
611
-
612
- &[aria-disabled='true'] {
613
- ${WC}
614
- }
615
-
616
- @media (prefers-reduced-motion: no-preference) {
617
- transition:
618
- ${t=>t.theme.transitions.backgroundColor},
619
- ${t=>t.theme.transitions.color},
620
- border-color ${t=>t.theme.motion.timings[200]} ${t=>t.theme.motion.easings.easeOutQuad};
621
- }
622
- `,Bm=$.forwardRef(({children:t,description:e,label:n,defaultOpen:r,open:i,onOpenChange:o,delayDuration:s=500,disableHoverableContent:a,...c},h)=>!n&&!e?t:p.jsxs(fx,{defaultOpen:r,open:i,onOpenChange:o,delayDuration:s,disableHoverableContent:a,children:[p.jsx(dx,{asChild:!0,children:t}),p.jsx(gx,{children:p.jsx(NX,{ref:h,sideOffset:8,...c,children:p.jsx(Re,{variant:"pi",fontWeight:"bold",children:n||e})})})]})),NX=k.styled(mx)`
623
- background-color: ${t=>t.theme.colors.neutral900};
624
- color: ${t=>t.theme.colors.neutral0};
625
- padding-inline: ${t=>t.theme.spaces[2]};
626
- padding-block: ${t=>t.theme.spaces[2]};
627
- border-radius: ${t=>t.theme.borderRadius};
628
- z-index: ${t=>t.theme.zIndices.tooltip};
629
- will-change: opacity;
630
- transform-origin: var(--radix-tooltip-content-transform-origin);
631
-
632
- @media (prefers-reduced-motion: no-preference) {
633
- animation: ${pt.fadeIn} ${t=>t.theme.motion.timings[200]}
634
- ${t=>t.theme.motion.easings.authenticMotion};
635
- }
636
- `,Xa=nn(({label:t,background:e,children:n,disabled:r=!1,onClick:i,size:o="S",variant:s="tertiary",withTooltip:a=!0,...c},h)=>{const f=m=>{!r&&i&&i(m)},d=p.jsx(wa,{"aria-disabled":r,background:r?"neutral150":e,tag:"button",display:"inline-flex",justifyContent:"center",hasRadius:!0,cursor:"pointer",...c,ref:h,$size:o,onClick:f,$variant:s,children:p.jsx(Ts,{label:t,children:n})});return a?p.jsx(Bm,{label:t,children:d}):d}),wa=k.styled(he)`
637
- text-decoration: none;
638
-
639
- ${t=>{switch(t.$size){case"XS":return k.css`
640
- padding-block: 0.25rem;
641
- padding-inline: 0.25rem;
642
- `;case"S":return k.css`
643
- padding-block: 0.7rem;
644
- padding-inline: 0.7rem;
645
- `;case"M":return k.css`
646
- padding-block: 0.9rem;
647
- padding-inline: 0.9rem;
648
- `;case"L":return k.css`
649
- padding-block: 1.1rem;
650
- padding-inline: 1.1rem;
651
- `}}}
652
- ${qC}
653
- ${t=>t.$variant==="tertiary"?k.css`
654
- color: ${t.theme.colors.neutral500};
655
- `:""}
656
-
657
- &:hover {
658
- ${zC}
659
- ${t=>t.$variant==="tertiary"?k.css`
660
- color: ${t.theme.colors.neutral600};
661
- `:""}
662
- }
663
-
664
- &:active {
665
- ${UC}
666
- }
667
-
668
- &[aria-disabled='true'] {
669
- ${WC}
670
- }
671
-
672
- @media (prefers-reduced-motion: no-preference) {
673
- transition:
674
- ${t=>t.theme.transitions.backgroundColor},
675
- ${t=>t.theme.transitions.color},
676
- border-color ${t=>t.theme.motion.timings[200]} ${t=>t.theme.motion.easings.easeOutQuad};
677
- }
678
- `,jX=k.styled(he)`
679
- & ${wa}:first-child {
680
- border-radius: ${({theme:t})=>`${t.borderRadius} 0 0 ${t.borderRadius}`};
681
- }
682
-
683
- & ${wa}:last-child {
684
- border-radius: ${({theme:t})=>`0 ${t.borderRadius} ${t.borderRadius} 0`};
685
- }
686
-
687
- & ${wa} {
688
- border-radius: 0;
689
-
690
- & + ${wa} {
691
- border-left: none;
692
- }
693
- }
694
- `,KC=nn(({children:t,href:e,disabled:n=!1,startIcon:r,endIcon:i,isExternal:o=!1,...s},a)=>p.jsxs(FX,{ref:a,href:e,disabled:n,isExternal:o,...s,children:[r,p.jsx(Re,{textColor:n?"neutral600":"primary600",children:t}),i,e&&!i&&o&&p.jsx(I_,{})]})),FX=k.styled(bl)`
695
- display: inline-flex;
696
- align-items: center;
697
- text-decoration: none;
698
- gap: ${({theme:t})=>t.spaces[2]};
699
- pointer-events: ${({disabled:t})=>t?"none":void 0};
700
-
701
- svg {
702
- font-size: 1rem;
703
-
704
- path {
705
- fill: ${({disabled:t,theme:e})=>t?e.colors.neutral600:e.colors.primary600};
706
- }
707
- }
708
-
709
- &:hover {
710
- & > span {
711
- color: ${({theme:t})=>t.colors.primary500};
712
- }
713
-
714
- svg path {
715
- fill: ${({theme:t})=>t.colors.primary500};
716
- }
717
- }
718
-
719
- &:active {
720
- color: ${({theme:t})=>t.colors.primary700};
721
- }
722
-
723
- ${Lh};
724
- `,VX=eF,HX=$.forwardRef(({label:t,endIcon:e=p.jsx(Mi,{width:"1.2rem",height:"1.2rem","aria-hidden":!0}),tag:n=Zu,icon:r,...i},o)=>{const s={...i,ref:o,type:"button"};return p.jsx(tF,{asChild:!0,disabled:s.disabled,children:n===Xa?p.jsx(Xa,{label:t,variant:"tertiary",...s,children:r}):p.jsx(Zu,{endIcon:e,variant:"ghost",...s})})}),PX=$.forwardRef(({children:t,intersectionId:e,onCloseAutoFocus:n,popoverPlacement:r="bottom-start",...i},o)=>{const[s,a]=r.split("-");return p.jsx(D3,{children:p.jsx(WX,{align:a,side:s,loop:!0,onCloseAutoFocus:n,asChild:!0,children:p.jsxs(GC,{ref:o,direction:"column",borderColor:"neutral150",hasRadius:!0,background:"neutral0",shadow:"filterShadow",maxHeight:"15rem",padding:1,marginTop:1,marginBottom:1,alignItems:"flex-start",position:"relative",overflow:"auto",...i,children:[t,p.jsx(be,{id:e,width:"100%",height:"1px"})]})})})}),GC=k.styled(he)`
725
- scrollbar-width: none;
726
- -ms-overflow-style: none;
727
- -webkit-overflow-scrolling: touch;
728
-
729
- &::-webkit-scrollbar {
730
- display: none;
731
- }
732
- `,WX=k.styled(nF)`
733
- @media (prefers-reduced-motion: no-preference) {
734
- animation-duration: ${t=>t.theme.motion.timings[200]};
735
-
736
- &[data-state='open'] {
737
- animation-timing-function: ${t=>t.theme.motion.easings.authenticMotion};
738
-
739
- &[data-side='top'] {
740
- animation-name: ${pt.slideUpIn};
741
- }
742
-
743
- &[data-side='bottom'] {
744
- animation-name: ${pt.slideDownIn};
745
- }
746
- }
747
- }
748
- `,zX=({onSelect:t,disabled:e=!1,isLink:n,startIcon:r,endIcon:i,isExternal:o,...s})=>p.jsx(iF,{asChild:!0,onSelect:t,disabled:e,children:n||o?p.jsx(UX,{color:"neutral800",startIcon:r,endIcon:i,...s,isExternal:o??!1,children:p.jsx(Re,{children:s.children})}):p.jsxs(XC,{cursor:"pointer",color:"neutral800",background:"transparent",borderStyle:"none",gap:2,...s,children:[r&&p.jsx(he,{tag:"span","aria-hidden":!0,children:r}),p.jsx(Re,{grow:1,children:s.children}),i&&p.jsx(he,{tag:"span","aria-hidden":!0,children:i})]})}),YC=({theme:t})=>k.css`
749
- text-align: left;
750
- width: 100%;
751
- border-radius: ${t.borderRadius};
752
- padding: ${t.spaces[2]} ${t.spaces[4]};
753
-
754
- &[aria-disabled='true'] {
755
- cursor: not-allowed;
756
- color: ${t.colors.neutral500};
757
- }
758
-
759
- &[data-highlighted] {
760
- background-color: ${t.colors.primary100};
761
- }
762
-
763
- &:focus-visible {
764
- outline: none;
765
-
766
- &:after {
767
- content: none;
768
- }
769
- }
770
- `,XC=k.styled(he)`
771
- ${YC}
772
- `,UX=k.styled(KC)`
773
- /* We include this here again because typically when people use OptionLink they provide an as prop which cancels the Box props */
774
- color: ${({theme:t,color:e})=>cu(t.colors,e,void 0)};
775
- text-decoration: none;
776
-
777
- &:hover {
778
- color: unset;
779
- }
780
-
781
- /* TODO: do we need this? */
782
- svg > path,
783
- &:focus-visible svg > path {
784
- fill: currentColor;
785
- }
786
-
787
- ${YC}
788
- `,qX=k.styled(be)`
789
- /* Negative horizontal margin to compensate Menu.Content's padding */
790
- margin: ${({theme:t})=>t.spaces[1]} -${({theme:t})=>t.spaces[1]};
791
- width: calc(100% + ${({theme:t})=>t.spaces[2]});
792
- /* Hide separator if there's nothing above in the menu */
793
- &:first-child {
794
- display: none;
795
- }
796
- `;$.forwardRef((t,e)=>p.jsx(oF,{...t,asChild:!0,children:p.jsx(qX,{height:"1px",shrink:0,background:"neutral150",ref:e})}));$.forwardRef((t,e)=>p.jsx(rF,{asChild:!0,children:p.jsx(KX,{ref:e,variant:"sigma",textColor:"neutral600",...t})}));const KX=k.styled(Re)`
797
- padding: ${({theme:t})=>t.spaces[2]} ${({theme:t})=>t.spaces[4]};
798
- `;$.forwardRef(({disabled:t=!1,...e},n)=>p.jsx(sF,{asChild:!0,disabled:t,children:p.jsxs(GX,{ref:n,color:"neutral800",tag:"button",type:"button",background:"transparent",borderStyle:"none",gap:5,...e,children:[p.jsx(Re,{children:e.children}),p.jsx(Vg,{fill:"neutral500",height:"1.2rem",width:"1.2rem"})]})}));const GX=k.styled(XC)`
799
- &[data-state='open'] {
800
- background-color: ${({theme:t})=>t.colors.primary100};
801
- }
802
- `;$.forwardRef((t,e)=>p.jsx(D3,{children:p.jsx(aF,{sideOffset:8,asChild:!0,children:p.jsx(GC,{ref:e,direction:"column",borderStyle:"solid",borderWidth:"1px",borderColor:"neutral150",hasRadius:!0,background:"neutral0",shadow:"filterShadow",maxHeight:"15rem",padding:1,alignItems:"flex-start",overflow:"auto",...t})})}));const YX=VX,XX=HX,ZX=PX,QX=zX,ZC=$.forwardRef(({children:t,onOpen:e,onClose:n,popoverPlacement:r,onReachEnd:i,...o},s)=>{const a=$.useRef(null),c=gn(s,a),h=$.useRef(null),[f,d]=$.useState(!1),m=C=>{i&&i(C)},v=C=>{C&&typeof e=="function"?e():!C&&typeof n=="function"&&n(),d(C)},w=Tn(),x=`intersection-${Ms(w)}`;return wl(h,m,{selectorToWatch:`#${x}`,skipWhen:!f}),p.jsxs(YX,{onOpenChange:v,children:[p.jsx(XX,{ref:c,...o,children:o.label}),p.jsx(ZX,{ref:h,intersectionId:x,popoverPlacement:r,children:t})]})}),JX=QX,eZ=k.styled(ZC)`
803
- padding: ${({theme:t})=>`${t.spaces[1]} ${t.spaces[2]}`};
804
- height: unset;
805
-
806
- :hover,
807
- :focus {
808
- background-color: ${({theme:t})=>t.colors.neutral200};
809
- }
810
- `,tZ=$.forwardRef(({children:t,...e},n)=>p.jsx(eZ,{ref:n,endIcon:null,size:"S",...e,children:t}));tZ.displayName="CrumbSimpleMenu";const QC=$.createContext({id:""}),nZ=()=>$.useContext(QC);$.forwardRef(({id:t,...e},n)=>{const r=Tn(t),i=$.useMemo(()=>({id:r}),[r]);return p.jsx(QC.Provider,{value:i,children:p.jsx(be,{ref:n,id:t,tabIndex:0,hasRadius:!0,background:"neutral0",borderStyle:"solid",borderWidth:"1px",borderColor:"neutral150",shadow:"tableShadow",tag:"article","aria-labelledby":`${r}-title`,...e})})});const rZ=$.forwardRef(({position:t,...e},n)=>p.jsx(iZ,{ref:n,$position:t,...e,direction:"row",gap:2})),iZ=k.styled(he)`
811
- position: absolute;
812
- top: ${({theme:t})=>t.spaces[3]};
813
- right: ${({$position:t,theme:e})=>{if(t==="end")return e.spaces[3]}};
814
- left: ${({$position:t,theme:e})=>{if(t==="start")return e.spaces[3]}};
815
- `;k.styled.img`
816
- // inline flows is based on typography and displays an extra white space below the image
817
- // switch to block is required in order to make the img stick the bottom of the container
818
- // addition infos: https://stackoverflow.com/questions/5804256/image-inside-div-has-extra-space-below-the-image
819
- margin: 0;
820
- padding: 0;
821
- max-height: 100%;
822
- max-width: 100%;
823
- object-fit: contain;
824
- `;k.styled.div`
825
- display: flex;
826
- justify-content: center;
827
- height: ${({$size:t})=>t==="S"?"8.8rem":"16.4rem"};
828
- width: 100%;
829
- background: repeating-conic-gradient(${({theme:t})=>t.colors.neutral100} 0% 25%, transparent 0% 50%) 50% / 20px
830
- 20px;
831
- border-top-left-radius: ${({theme:t})=>t.borderRadius};
832
- border-top-right-radius: ${({theme:t})=>t.borderRadius};
833
- `;k.styled.div`
834
- margin-left: auto;
835
- flex-shrink: 0;
836
- `;k.styled(Dm)`
837
- margin-left: ${({theme:t})=>t.spaces[1]};
838
- `;const oZ=({fill:t,...e})=>{const{colors:n}=k.useTheme();return p.jsx(be,{tag:"svg",viewBox:"0 0 32 32",xmlns:"http://www.w3.org/2000/svg",fill:t?n[t]:void 0,...e,children:p.jsx("path",{d:"M29.0613 10.0613L13.0613 26.0613C12.9219 26.2011 12.7563 26.3121 12.574 26.3878C12.3917 26.4635 12.1962 26.5024 11.9988 26.5024C11.8013 26.5024 11.6059 26.4635 11.4235 26.3878C11.2412 26.3121 11.0756 26.2011 10.9363 26.0613L3.93626 19.0613C3.79673 18.9217 3.68605 18.7561 3.61053 18.5738C3.53502 18.3915 3.49615 18.1961 3.49615 17.9988C3.49615 17.8014 3.53502 17.606 3.61053 17.4237C3.68605 17.2414 3.79673 17.0758 3.93626 16.9363C4.07579 16.7967 4.24143 16.686 4.42374 16.6105C4.60604 16.535 4.80143 16.4962 4.99876 16.4962C5.19608 16.4962 5.39147 16.535 5.57378 16.6105C5.75608 16.686 5.92173 16.7967 6.06126 16.9363L12 22.875L26.9388 7.93876C27.2205 7.65697 27.6027 7.49866 28.0013 7.49866C28.3998 7.49866 28.782 7.65697 29.0638 7.93876C29.3455 8.22055 29.5039 8.60274 29.5039 9.00126C29.5039 9.39977 29.3455 9.78197 29.0638 10.0638L29.0613 10.0613Z"})})},cw=$.forwardRef(({defaultChecked:t,checked:e,onCheckedChange:n,...r},i)=>{const o=$.useRef(null),[s,a]=yr({defaultProp:t,prop:e,onChange:n}),c=gn(o,i);return p.jsx(sZ,{ref:c,checked:s,onCheckedChange:a,...r,children:p.jsxs(aZ,{forceMount:!0,children:[s===!0?p.jsx(oZ,{width:"1.6rem",fill:"neutral0"}):null,s==="indeterminate"?p.jsx(PL,{fill:"neutral0"}):null]})})}),sZ=k.styled(mF)`
839
- background: ${t=>t.theme.colors.neutral0};
840
- width: 2rem;
841
- height: 2rem;
842
- border-radius: ${t=>t.theme.borderRadius};
843
- border: 1px solid ${t=>t.theme.colors.neutral300};
844
- position: relative;
845
- z-index: 0;
846
- display: flex;
847
- justify-content: center;
848
- align-items: center;
849
- // this ensures the checkbox is always a square even in flex-containers.
850
- flex: 0 0 2rem;
851
-
852
- &[data-state='checked'],
853
- &[data-state='indeterminate'] {
854
- border: 1px solid ${t=>t.theme.colors.primary600};
855
- background-color: ${t=>t.theme.colors.primary600};
856
- }
857
-
858
- &[data-disabled] {
859
- background-color: ${t=>t.theme.colors.neutral200};
860
- }
861
-
862
- /* increase target size for touch devices https://www.w3.org/WAI/WCAG21/Understanding/target-size.html */
863
- &::before {
864
- content: '';
865
- position: absolute;
866
- top: 50%;
867
- left: 50%;
868
- transform: translate(-50%, -50%);
869
- width: 100%;
870
- height: 100%;
871
- z-index: -1;
872
- min-width: 44px;
873
- min-height: 44px;
874
- }
875
- `,aZ=k.styled(pF)`
876
- display: inline-flex;
877
- pointer-events: auto !important;
878
- width: 100%;
879
- height: 100%;
880
- cursor: pointer;
881
- justify-content: center;
882
- align-items: center;
883
- `,jh=$.forwardRef(({children:t,...e},n)=>{const r=Tn(e.id);return t?p.jsxs(he,{gap:2,children:[p.jsx(cw,{id:r,...e}),p.jsx(Re,{tag:"label",textColor:"neutral800",htmlFor:r,children:t})]}):p.jsx(cw,{ref:n,...e})});$.forwardRef((t,e)=>{const{id:n}=nZ();return p.jsx(rZ,{position:"start",children:p.jsx(jh,{"aria-labelledby":`${n}-title`,...t,ref:e})})});k.styled(be)`
884
- word-break: break-all;
885
- `;k.styled(he)`
886
- border-bottom: 1px solid ${({theme:t})=>t.colors.neutral150};
887
- `;const Rt={DOWN:"ArrowDown",UP:"ArrowUp",RIGHT:"ArrowRight",LEFT:"ArrowLeft",ESCAPE:"Escape",ENTER:"Enter",TAB:"Tab",END:"End",HOME:"Home",PAGE_UP:"PageUp",PAGE_DOWN:"PageDown"},lZ=k.styled(be)`
888
- grid-template-columns: auto 1fr auto;
889
- grid-template-areas: 'startAction slides endAction';
890
- `,cZ=k.styled(he)`
891
- grid-area: slides;
892
- `,uw=k.styled(be)`
893
- grid-area: ${({$area:t})=>t};
894
-
895
- &:focus svg path,
896
- &:hover svg path {
897
- fill: ${({theme:t})=>t.colors.neutral900};
898
- }
899
- `,uZ=$.forwardRef(({actions:t,children:e,label:n,nextLabel:r,onNext:i,onPrevious:o,previousLabel:s,secondaryLabel:a,selectedSlide:c,...h},f)=>{const d=$.useRef(null),m=$.useRef(null),v=$.Children.map(e,(x,C)=>$.cloneElement(x,{selected:C===c})),w=x=>{switch(x.key){case Rt.RIGHT:{x.preventDefault(),m?.current&&m.current.focus(),i&&i();break}case Rt.LEFT:{x.preventDefault(),d?.current&&d.current.focus(),o&&o();break}}};return p.jsx(be,{ref:f,...h,onKeyDown:w,children:p.jsxs(be,{padding:2,borderColor:"neutral200",hasRadius:!0,background:"neutral100",children:[p.jsxs(lZ,{tag:"section","aria-roledescription":"carousel","aria-label":n,display:"grid",position:"relative",children:[v&&v.length>1&&p.jsxs(p.Fragment,{children:[p.jsx(uw,{tag:"button",onClick:o,$area:"startAction",ref:d,type:"button",children:p.jsx(Ts,{label:s,children:p.jsx(c3,{width:"1.6rem",height:"1.6rem",fill:"neutral600"})})}),p.jsx(uw,{tag:"button",onClick:i,$area:"endAction",ref:m,type:"button",children:p.jsx(Ts,{label:r,children:p.jsx(Vg,{width:"1.6rem",height:"1.6rem",fill:"neutral600"})})})]}),p.jsx(cZ,{"aria-live":"polite",paddingLeft:2,paddingRight:2,width:"100%",overflow:"hidden",children:v}),t]}),a&&p.jsx(be,{paddingTop:2,paddingLeft:4,paddingRight:4,children:p.jsx(Bm,{label:a,children:p.jsx(he,{justifyContent:"center",children:p.jsx(Re,{variant:"pi",textColor:"neutral600",ellipsis:!0,children:a})})})})]})})}),hZ={accordions:{S:"4.8rem",M:"8.8rem"},button:{S:"3.2rem",M:"3.6rem",L:"4rem"}},JC={sizes:hZ,zIndices:{navigation:100,overlay:300,modal:310,dialog:320,popover:500,notification:700,tooltip:1e3},spaces:["0px","4px","8px","12px","16px","20px","24px","32px","40px","48px","56px","64px"],borderRadius:"4px",breakpoints:{initial:"@media(min-width: 0px)",small:"@media(min-width: 520px)",medium:"@media(min-width: 768px)",large:"@media(min-width: 1080px)"},fontSizes:["1.1rem","1.2rem","1.4rem","1.6rem","1.8rem","3.2rem"],lineHeights:[1.14,1.22,1.25,1.33,1.43,1.45,1.5],fontWeights:{regular:400,semiBold:500,bold:600},transitions:fX,motion:{easings:I1,timings:_1}},fZ={color:{alternative100:"#f6ecfc",alternative200:"#e0c1f4",alternative500:"#ac73e6",alternative600:"#9736e8",alternative700:"#8312d1",buttonNeutral0:"#ffffff",buttonPrimary500:"#7b79ff",buttonPrimary600:"#4945ff",danger100:"#fcecea",danger200:"#f5c0b8",danger500:"#ee5e52",danger600:"#d02b20",danger700:"#b72b1a",neutral0:"#ffffff",neutral100:"#f6f6f9",neutral1000:"#181826",neutral150:"#eaeaef",neutral200:"#dcdce4",neutral300:"#c0c0cf",neutral400:"#a5a5ba",neutral500:"#8e8ea9",neutral600:"#666687",neutral700:"#4a4a6a",neutral800:"#32324d",neutral900:"#212134",primary100:"#f0f0ff",primary200:"#d9d8ff",primary500:"#7b79ff",primary600:"#4945ff",primary700:"#271fe0",secondary100:"#eaf5ff",secondary200:"#b8e1ff",secondary500:"#66b7f1",secondary600:"#0c75af",secondary700:"#006096",success100:"#eafbe7",success200:"#c6f0c2",success500:"#5cb176",success600:"#328048",success700:"#2f6846",warning100:"#fdf4dc",warning200:"#fae7b9",warning500:"#f29d41",warning600:"#d9822f",warning700:"#be5d01"}},dZ={shadow:{filterShadow:"0px 1px 4px rgba(33, 33, 52, 0.1)",focus:"inset 2px 0px 0px rgb(39, 31, 224), inset 0px 2px 0px rgb(39, 31, 224), inset -2px 0px 0px rgb(39, 31, 224), inset 0px -2px 0px rgb(39, 31, 224)",focusShadow:"0px 0px 6px rgba(76, 191, 255, 0.75)",popupShadow:"0px 2px 15px rgba(33, 33, 52, 0.1)",tableShadow:"0px 1px 4px rgba(33, 33, 52, 0.1)"}},e$={colors:fZ.color,shadows:dZ.shadow,...JC},gZ={color:{alternative100:"#181826",alternative200:"#4a4a6a",alternative500:"#ac73e6",alternative600:"#ac73e6",alternative700:"#e0c1f4",buttonNeutral0:"#ffffff",buttonPrimary500:"#7b79ff",buttonPrimary600:"#4945ff",danger100:"#181826",danger200:"#4a4a6a",danger500:"#ee5e52",danger600:"#ee5e52",danger700:"#ee5e52",neutral0:"#212134",neutral100:"#181826",neutral1000:"#ffffff",neutral150:"#32324d",neutral200:"#4a4a6a",neutral300:"#666687",neutral400:"#a5a5ba",neutral500:"#c0c0cf",neutral600:"#a5a5ba",neutral700:"#eaeaef",neutral800:"#ffffff",neutral900:"#ffffff",primary100:"#181826",primary200:"#4a4a6a",primary500:"#4945ff",primary600:"#7b79ff",primary700:"#7b79ff",secondary100:"#181826",secondary200:"#4a4a6a",secondary500:"#66b7f1",secondary600:"#66b7f1",secondary700:"#b8e1ff",success100:"#181826",success200:"#4a4a6a",success500:"#5cb176",success600:"#5cb176",success700:"#c6f0c2",warning100:"#181826",warning200:"#4a4a6a",warning500:"#f29d41",warning600:"#f29d41",warning700:"#fae7b9"}},mZ={shadow:{filterShadow:"1px 1px 10px rgba(3, 3, 5, 0.35)",focus:"inset 2px 0px 0px rgb(39, 31, 224), inset 0px 2px 0px rgb(39, 31, 224), inset -2px 0px 0px rgb(39, 31, 224), inset 0px -2px 0px rgb(39, 31, 224)",focusShadow:"0px 0px 6px rgba(76, 191, 255, 0.75)",popupShadow:"1px 1px 10px rgba(3, 3, 5, 0.35)",tableShadow:"1px 1px 10px rgba(3, 3, 5, 0.2)"}},pZ={colors:gZ.color,shadows:mZ.shadow,...JC},Vi=(t="&")=>({theme:e,$hasError:n=!1})=>k.css`
900
- outline: none;
901
- box-shadow: none;
902
- transition-property: border-color, box-shadow, fill;
903
- transition-duration: 0.2s;
904
-
905
- ${t}:focus-within {
906
- border: 1px solid ${n?e.colors.danger600:e.colors.primary600};
907
- box-shadow: ${n?e.colors.danger600:e.colors.primary600} 0px 0px 0px 2px;
908
- }
909
- `,[vZ,mn]=vl("Field",{}),xo=$.forwardRef(({children:t,name:e,error:n=!1,hint:r,id:i,required:o=!1,...s},a)=>{const c=Tn(i),[h,f]=$.useState();return p.jsx(vZ,{name:e,id:c,error:n,hint:r,required:o,labelNode:h,setLabelNode:f,children:p.jsx(he,{direction:"column",alignItems:"stretch",gap:1,ref:a,...s,children:t})})}),Nm=$.forwardRef(({children:t,action:e,...n},r)=>{const{id:i,required:o,setLabelNode:s}=mn("Label"),a=gn(r,s);return t?p.jsxs(bZ,{ref:a,variant:"pi",textColor:"neutral800",fontWeight:"bold",...n,id:`${i}-label`,htmlFor:i,tag:"label",ellipsis:!0,children:[t,o&&p.jsx(Re,{"aria-hidden":!0,lineHeight:"1em",textColor:"danger600",children:"*"}),e&&p.jsx(wZ,{marginLeft:1,children:e})]}):null}),bZ=k.styled(Re)`
910
- display: flex;
911
- `,wZ=k.styled(he)`
912
- line-height: 0;
913
- color: ${({theme:t})=>t.colors.neutral500};
914
- `,Fh=$.forwardRef(({endAction:t,startAction:e,disabled:n=!1,onChange:r,hasError:i,required:o,className:s,size:a="M",...c},h)=>{const{id:f,error:d,hint:m,name:v,required:w}=mn("Input");let x;d?x=`${f}-error`:m&&(x=`${f}-hint`);const C=!!d,S=$.useRef(null),A=$.useRef(null),T=gn(A,h),O=D=>{!n&&r&&r(D)};return $.useLayoutEffect(()=>{if(S.current&&A.current){const D=S.current.offsetWidth,L=A.current;if(L){const I=D+8+16;L.style.paddingRight=`${I}px`}}},[t]),p.jsxs(CZ,{gap:2,justifyContent:"space-between",$hasError:C||i,$disabled:n,$size:a,$hasLeftAction:!!e,$hasRightAction:!!t,className:s,children:[e,p.jsx(xZ,{id:f,name:v,ref:T,$size:a,"aria-describedby":x,"aria-invalid":C||i,"aria-disabled":n,disabled:n,"data-disabled":n?"":void 0,onChange:O,"aria-required":w||o,$hasLeftAction:!!e,$hasRightAction:!!t,...c}),t&&p.jsx(yZ,{ref:S,children:t})]})}),xZ=k.styled.input`
915
- border: none;
916
- border-radius: ${({theme:t})=>t.borderRadius};
917
- cursor: ${t=>t["aria-disabled"]?"not-allowed":void 0};
918
-
919
- color: ${({theme:t})=>t.colors.neutral800};
920
- font-weight: 400;
921
- font-size: ${t=>t.theme.fontSizes[2]};
922
- line-height: 2.2rem;
923
- display: block;
924
- width: 100%;
925
- background: inherit;
926
-
927
- ::placeholder {
928
- color: ${({theme:t})=>t.colors.neutral500};
929
- opacity: 1;
930
- }
931
-
932
- &[aria-disabled='true'] {
933
- color: inherit;
934
- }
935
-
936
- //focus managed by InputWrapper
937
- &:focus {
938
- outline: none;
939
- box-shadow: none;
940
- }
941
-
942
- ${t=>{switch(t.$size){case"S":return k.css`
943
- padding-inline-start: ${t.$hasLeftAction?0:t.theme.spaces[4]};
944
- padding-inline-end: ${t.$hasRightAction?0:t.theme.spaces[4]};
945
- padding-block: ${t.theme.spaces[1]};
946
- `;default:return k.css`
947
- padding-inline-start: ${t.$hasLeftAction?0:t.theme.spaces[4]};
948
- padding-inline-end: ${t.$hasRightAction?0:t.theme.spaces[4]};
949
- padding-block: ${t.theme.spaces[2]};
950
- `}}}
951
- `,yZ=k.styled(he)`
952
- position: absolute;
953
- right: ${({theme:t})=>t.spaces[4]};
954
- top: 50%;
955
- transform: translateY(-50%);
956
- `,CZ=k.styled(he)`
957
- border: 1px solid ${({theme:t,$hasError:e})=>e?t.colors.danger600:t.colors.neutral200};
958
- border-radius: ${({theme:t})=>t.borderRadius};
959
- background: ${({theme:t})=>t.colors.neutral0};
960
- padding-inline-start: ${({$hasLeftAction:t,theme:e})=>t?e.spaces[4]:0};
961
- position: relative;
962
-
963
- ${Vi()}
964
- ${({theme:t,$disabled:e})=>e?k.css`
965
- color: ${t.colors.neutral600};
966
- background: ${t.colors.neutral150};
967
- `:void 0};
968
- `,t$=()=>{const{id:t,hint:e,error:n}=mn("Hint");return!e||n?null:p.jsx(Re,{variant:"pi",tag:"p",id:`${t}-hint`,textColor:"neutral600",children:e})},n$=()=>{const{id:t,error:e}=mn("Error");return!e||typeof e!="string"?null:p.jsx(Re,{variant:"pi",tag:"p",id:`${t}-error`,textColor:"danger600","data-strapi-field-error":!0,children:e})},r$=$.forwardRef(({label:t,children:e,...n},r)=>p.jsx($Z,{justifyContent:"unset",background:"transparent",borderStyle:"none",...n,type:"button",tag:"button",ref:r,children:p.jsx(Ts,{label:t,children:e})})),$Z=k.styled(he)`
969
- font-size: 1.6rem;
970
- padding: 0;
971
- `,SZ=Object.freeze(Object.defineProperty({__proto__:null,Action:r$,Error:n$,Hint:t$,Input:Fh,Label:Nm,Root:xo,useField:mn},Symbol.toStringTag,{value:"Module"}));$.forwardRef(({actions:t,children:e,error:n,hint:r,label:i,labelAction:o,nextLabel:s,onNext:a,onPrevious:c,previousLabel:h,required:f,secondaryLabel:d,selectedSlide:m,id:v,...w},x)=>{const C=Tn(v);return p.jsx(xo,{hint:r,error:n,id:C,required:f,children:p.jsxs(he,{direction:"column",alignItems:"stretch",gap:1,children:[i&&p.jsx(Nm,{action:o,children:i}),p.jsx(uZ,{ref:x,actions:t,label:i,nextLabel:s,onNext:a,onPrevious:c,previousLabel:h,secondaryLabel:d,selectedSlide:m,id:C,...w,children:e}),p.jsx(t$,{}),p.jsx(n$,{})]})})});k.styled(be)`
972
- ${OC}
973
- `;const AZ="data:image/svg+xml,%3csvg%20width='63'%20height='63'%20viewBox='0%200%2063%2063'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cpath%20d='M42.5563%2011.9816C39.484%2010.3071%2035.8575%209.29097%2032.3354%209.13521C28.6443%208.92888%2024.8295%209.72318%2021.3336%2011.4129C20.9123%2011.5901%2020.5376%2011.8101%2020.1722%2012.0249L20.0108%2012.1179C19.8774%2012.1951%2019.7441%2012.2724%2019.608%2012.3536C19.3253%2012.5146%2019.0492%2012.6744%2018.7544%2012.8792C18.5463%2013.0329%2018.3395%2013.1759%2018.1301%2013.323C17.5658%2013.7208%2016.9868%2014.1317%2016.4983%2014.5979C14.8476%2015.9524%2013.5571%2017.6075%2012.6071%2018.9214C10.4365%2022.1566%209.08622%2025.9567%208.80702%2029.6143L8.7764%2030.1588C8.73328%2030.9196%208.68476%2031.7057%208.75353%2032.4555C8.76648%2032.6084%208.7661%2032.7638%208.77506%2032.914C8.78895%2033.229%208.80152%2033.5373%208.846%2033.8672L9.07396%2035.4221C9.09756%2035.5764%209.1198%2035.7413%209.1633%2035.9263L9.65919%2037.9272L10.138%2039.2823C10.2729%2039.6673%2010.4158%2040.0751%2010.6%2040.43C12.0292%2043.637%2014.1425%2046.4578%2016.7063%2048.585C19.0508%2050.5296%2021.824%2052.0023%2024.7491%2052.8452L26.2371%2053.2376C26.3781%2053.2693%2026.4926%2053.2889%2026.6031%2053.3058L26.7775%2053.3311C27.0052%2053.3636%2027.2195%2053.3986%2027.4445%2053.435C27.8598%2053.5076%2028.2672%2053.5748%2028.7079%2053.6183L30.5641%2053.7229C30.9516%2053.7249%2031.3352%2053.7068%2031.7081%2053.6874C31.9039%2053.681%2032.0984%2053.6681%2032.3288%2053.662C34.5253%2053.4772%2036.5106%2053.0634%2038.0516%2052.4652C38.1769%2052.4171%2038.3008%2052.3796%2038.4234%2052.3355C38.6727%2052.2499%2038.9259%2052.167%2039.1432%2052.0599L40.8591%2051.2626L42.5702%2050.266C42.9009%2050.0682%2043.0205%2049.6414%2042.8282%2049.2984C42.632%2048.9526%2042.2034%2048.8308%2041.8634%2049.0166L40.1792%2049.9218L38.4995%2050.6224C38.3169%2050.6953%2038.121%2050.7534%2037.9224%2050.8155C37.7838%2050.8489%2037.6518%2050.8983%2037.5012%2050.9408C36.0711%2051.435%2034.2445%2051.7425%2032.244%2051.8346C32.0442%2051.8383%2031.8471%2051.8379%2031.654%2051.8403C31.3051%2051.8414%2030.9602%2051.8451%2030.6392%2051.8305L28.9177%2051.6725C28.5476%2051.619%2028.1695%2051.5427%2027.7848%2051.4678C27.5639%2051.4167%2027.3376%2051.3737%2027.1299%2051.3374L26.9529%2051.2987C26.8704%2051.2834%2026.7772%2051.2667%2026.7333%2051.2543L25.3466%2050.8322C22.7651%2049.9789%2020.33%2048.5729%2018.2942%2046.7557C16.1056%2044.7951%2014.3339%2042.2335%2013.1742%2039.3582C12.0276%2036.6013%2011.5988%2033.2792%2011.9716%2030.0076C12.3145%2027.0213%2013.3948%2024.1635%2015.1858%2021.5083C15.3034%2021.3339%2015.421%2021.1596%2015.5212%2021.0196C16.4309%2019.8688%2017.5408%2018.5589%2018.9483%2017.496C19.3367%2017.1525%2019.7862%2016.856%2020.2611%2016.5478C20.4878%2016.4009%2020.7079%2016.2553%2020.8907%2016.1306C21.0974%2016.0048%2021.3188%2015.8831%2021.5348%2015.7694C21.6761%2015.6975%2021.8162%2015.619%2021.9388%2015.5576L22.1002%2015.4646C22.4002%2015.3037%2022.6749%2015.1546%2022.9908%2015.039L24.1186%2014.5715C24.3399%2014.4844%2024.5718%2014.4159%2024.7997%2014.3447C24.953%2014.2982%2025.0982%2014.2635%2025.2635%2014.2078C25.786%2014.0182%2026.3283%2013.9112%2026.9105%2013.7965C27.117%2013.7571%2027.3302%2013.7163%2027.5608%2013.6585C27.7553%2013.611%2027.9737%2013.5969%2028.2082%2013.5762C28.364%2013.5603%2028.5172%2013.5483%2028.6318%2013.5333C28.7876%2013.5173%2028.9342%2013.5066%2029.0927%2013.4867C29.3285%2013.4555%2029.5456%2013.4347%2029.7494%2013.4337C30.0237%2013.44%2030.2994%2013.4357%2030.5777%2013.4274C31.0811%2013.421%2031.5579%2013.4197%2032.0318%2013.4914C34.9664%2013.7352%2037.7144%2014.6085%2040.2052%2016.0868C42.3489%2017.3655%2044.2716%2019.1525%2045.7607%2021.264C47.0255%2023.0628%2047.9756%2025.0528%2048.4928%2027.0393C48.572%2027.3176%2048.6299%2027.5931%2048.6839%2027.8659C48.7154%2028.0428%2048.7563%2028.2145%2048.7892%2028.3636C48.8037%2028.4541%2048.8208%2028.5406%2048.8445%2028.6258C48.8749%2028.7443%2048.8986%2028.864%2048.9116%2028.9651L48.9793%2029.6047C48.9922%2029.7748%2049.0132%2029.9331%2049.0301%2030.0887C49.0668%2030.3268%2049.0889%2030.5608%2049.0964%2030.7561L49.1083%2031.9001C49.1312%2032.3307%2049.089%2032.7116%2049.0522%2033.0673C49.0384%2033.2598%2049.0126%2033.4443%2049.0123%2033.5824C48.9961%2033.6926%2048.9918%2033.7935%2048.9836%2033.8917C48.9753%2034.0072%2048.9724%2034.1148%2048.9414%2034.2554L48.5449%2036.3059C48.3134%2037.8623%2049.3793%2039.3365%2050.9488%2039.5822C52.0417%2039.7601%2053.1536%2039.2819%2053.7711%2038.3664C54.0063%2038.0176%2054.1604%2037.6257%2054.2227%2037.2064L54.5217%2035.2574C54.5514%2035.0756%2054.572%2034.83%2054.5846%2034.5791L54.6028%2034.2338C54.6098%2034.0598%2054.6223%2033.8779%2054.6347%2033.6788C54.6734%2033.1052%2054.7163%2032.4479%2054.6619%2031.8058L54.5867%2030.4289C54.5622%2030.0952%2054.5097%2029.76%2054.4559%2029.4181C54.431%2029.2572%2054.4048%2029.0896%2054.3826%2028.9074L54.2687%2028.104C54.2332%2027.9244%2054.1804%2027.7273%2054.1329%2027.5396L54.0643%2027.2454C54.0195%2027.071%2053.9773%2026.8927%2053.9338%2026.7076C53.8455%2026.3309%2053.7479%2025.9422%2053.613%2025.5571C52.84%2023.0292%2051.5383%2020.5194%2049.8338%2018.2799C47.8544%2015.682%2045.3333%2013.5087%2042.5563%2011.9816Z'%20fill='%234945FF'/%3e%3c/svg%3e",i$=$.forwardRef(({children:t,small:e=!1,...n},r)=>p.jsxs("div",{role:"alert","aria-live":"assertive",ref:r,...n,children:[p.jsx(ko,{children:t}),p.jsx(kZ,{src:AZ,"aria-hidden":!0,$small:e})]})),RZ=k.keyframes`
974
- from {
975
- transform: rotate(0deg);
976
- }
977
- to {
978
- transform: rotate(359deg);
979
- }
980
- `,kZ=k.styled.img`
981
- animation: ${RZ} 1s infinite linear;
982
- will-change: transform;
983
- ${({$small:t,theme:e})=>t&&`width: ${e.spaces[6]}; height: ${e.spaces[6]};`}
984
- `,TZ=$.forwardRef(({allowCustomValue:t,autocomplete:e,children:n,className:r,clearLabel:i="clear",creatable:o=!1,createMessage:s=ge=>`Create "${ge}"`,defaultFilterValue:a,defaultTextValue:c,defaultOpen:h=!1,open:f,onOpenChange:d,disabled:m=!1,hasError:v,id:w,filterValue:x,hasMoreItems:C=!1,isPrintableCharacter:S,loading:A=!1,loadingMessage:T="Loading content...",name:O,noOptionsMessage:D=()=>"No results found",onChange:L,onClear:I,onCreateOption:V,onFilterValueChange:F,onInputChange:H,onTextValueChange:K,onLoadMore:W,placeholder:J="Select or enter a value",required:G=!1,size:re="M",startIcon:oe,textValue:te,value:ie,...Y},ue)=>{const[ge,De]=yr({prop:f,defaultProp:h,onChange:d}),[we,Ve]=yr({prop:te,defaultProp:t&&!c?ie:c,onChange:K}),[Ne,He]=yr({prop:x,defaultProp:a,onChange:F}),pe=$.useRef(null),Oe=$.useRef(null),ke=gn(Oe,ue),Ae=$.useRef(null),_e=xt=>{I&&!m&&(Ve(""),He(""),I(xt),Oe.current.focus())},ze=xt=>{De(xt)},Et=xt=>{Ve(xt)},Ze=xt=>{He(xt)},Pe=xt=>{H&&H(xt)},Yt=xt=>{L&&L(xt)},ft=xt=>{W&&C&&!A&&W(xt)},Hi=()=>{V&&we&&V(we)},Ps=Tn(),or=`intersection-${Ms(Ps)}`;wl(pe,ft,{selectorToWatch:`#${or}`,skipWhen:!ge});const{error:wt,...sr}=mn("Combobox"),To=!!wt||v,Ws=sr.id??w,Pi=sr.name??O,Hh=sr.required||G;let Or;return wt?Or=`${Ws}-error`:sr.hint&&(Or=`${Ws}-hint`),p.jsxs(Yn.Root,{autocomplete:e||(o?"list":"both"),onOpenChange:ze,open:ge,onTextValueChange:Et,textValue:we,allowCustomValue:o||t,disabled:m,required:Hh,value:ie,onValueChange:Yt,filterValue:Ne,onFilterValueChange:Ze,isPrintableCharacter:S,children:[p.jsxs(EZ,{$hasError:To,$size:re,className:r,children:[p.jsxs(he,{flex:"1",tag:"span",gap:3,children:[oe?p.jsx(he,{flex:"0 0 1.6rem",tag:"span","aria-hidden":!0,children:oe}):null,p.jsx(OZ,{placeholder:J,id:Ws,"aria-invalid":!!wt,onChange:Pe,ref:ke,name:Pi,"aria-describedby":Or,...Y})]}),p.jsxs(he,{tag:"span",gap:3,children:[we&&I?p.jsx(MZ,{tag:"button",hasRadius:!0,background:"transparent",type:"button",padding:0,color:"neutral600",borderStyle:"none",onClick:_e,"aria-disabled":m,"aria-label":i,title:i,ref:Ae,children:p.jsx(ji,{})}):null,p.jsx(DZ,{children:p.jsx(Mi,{fill:"neutral500"})})]})]}),p.jsx(Yn.Portal,{children:p.jsx(IZ,{sideOffset:4,children:p.jsxs(_Z,{ref:pe,children:[n,o?p.jsx(Yn.CreateItem,{onPointerUp:Hi,onClick:Hi,asChild:!0,children:p.jsx(B1,{children:p.jsx(Re,{children:s(we??"")})})}):null,!o&&!A?p.jsx(Yn.NoValueFound,{asChild:!0,children:p.jsx(B1,{$hasHover:!1,children:p.jsx(Re,{children:D(we??"")})})}):null,A?p.jsx(he,{justifyContent:"center",alignItems:"center",paddingTop:2,paddingBottom:2,children:p.jsx(i$,{small:!0,children:T})}):null,p.jsx(be,{id:or,width:"100%",height:"1px"})]})})})]})}),MZ=k.styled(be)`
985
- padding: 0;
986
- `,EZ=k.styled(Yn.Trigger)`
987
- position: relative;
988
- border: 1px solid ${({theme:t,$hasError:e})=>e?t.colors.danger600:t.colors.neutral200};
989
- border-radius: ${({theme:t})=>t.borderRadius};
990
- background: ${({theme:t})=>t.colors.neutral0};
991
- overflow: hidden;
992
- display: flex;
993
- align-items: center;
994
- justify-content: space-between;
995
- gap: ${({theme:t})=>t.spaces[4]};
996
-
997
- ${t=>{switch(t.$size){case"S":return k.css`
998
- padding-inline-start: ${({theme:e})=>e.spaces[4]};
999
- padding-inline-end: ${({theme:e})=>e.spaces[3]};
1000
- padding-block: ${({theme:e})=>e.spaces[1]};
1001
- `;default:return k.css`
1002
- padding-inline-start: ${({theme:e})=>e.spaces[4]};
1003
- padding-inline-end: ${({theme:e})=>e.spaces[3]};
1004
- padding-block: ${({theme:e})=>e.spaces[2]};
1005
- `}}}
1006
-
1007
- &[data-disabled] {
1008
- color: ${({theme:t})=>t.colors.neutral600};
1009
- background: ${({theme:t})=>t.colors.neutral150};
1010
- cursor: not-allowed;
1011
- }
1012
-
1013
- /* Required to ensure the below inputFocusStyles are adhered too */
1014
- &:focus-visible {
1015
- outline: none;
1016
- }
1017
-
1018
- ${({theme:t,$hasError:e})=>Vi()({theme:t,$hasError:e})};
1019
- `,OZ=k.styled(Yn.TextInput)`
1020
- width: 100%;
1021
- font-size: 1.4rem;
1022
- line-height: 2.2rem;
1023
- color: ${({theme:t})=>t.colors.neutral800};
1024
- padding: 0;
1025
- border: none;
1026
- background-color: transparent;
1027
-
1028
- &:focus-visible {
1029
- outline: none;
1030
- }
1031
-
1032
- &[aria-disabled='true'] {
1033
- cursor: inherit;
1034
- }
1035
- `,DZ=k.styled(Yn.Icon)`
1036
- border: none;
1037
- background: transparent;
1038
- padding: 0;
1039
- color: ${({theme:t})=>t.colors.neutral600};
1040
- display: flex;
1041
-
1042
- &[aria-disabled='true'] {
1043
- cursor: inherit;
1044
- }
1045
- `,IZ=k.styled(Yn.Content)`
1046
- background: ${({theme:t})=>t.colors.neutral0};
1047
- box-shadow: ${({theme:t})=>t.shadows.filterShadow};
1048
- border: 1px solid ${({theme:t})=>t.colors.neutral150};
1049
- border-radius: ${({theme:t})=>t.borderRadius};
1050
- width: var(--radix-combobox-trigger-width);
1051
- /* This is from the design-system figma file. */
1052
- max-height: 15rem;
1053
- z-index: ${({theme:t})=>t.zIndices.popover};
1054
-
1055
- @media (prefers-reduced-motion: no-preference) {
1056
- animation-duration: ${t=>t.theme.motion.timings[200]};
1057
-
1058
- /* The select can't animate out yet, watch https://github.com/radix-ui/primitives/issues/1893, or take a look and solve it yourself. */
1059
- &[data-state='open'] {
1060
- animation-timing-function: ${t=>t.theme.motion.easings.authenticMotion};
1061
-
1062
- &[data-side='top'] {
1063
- animation-name: ${pt.slideUpIn};
1064
- }
1065
-
1066
- &[data-side='bottom'] {
1067
- animation-name: ${pt.slideDownIn};
1068
- }
1069
- }
1070
- }
1071
- `,_Z=k.styled(Yn.Viewport)`
1072
- padding: ${({theme:t})=>t.spaces[1]};
1073
- `,LZ=$.forwardRef(({children:t,value:e,disabled:n,textValue:r,...i},o)=>p.jsx(Yn.ComboboxItem,{asChild:!0,value:e,disabled:n,textValue:r,children:p.jsx(B1,{ref:o,...i,children:p.jsx(Yn.ItemText,{asChild:!0,children:p.jsx(Re,{children:t})})})})),B1=k.styled.div`
1074
- width: 100%;
1075
- border: none;
1076
- text-align: left;
1077
- outline-offset: -3px;
1078
- padding: ${({theme:t})=>t.spaces[2]} ${({theme:t})=>t.spaces[4]};
1079
- background-color: ${({theme:t})=>t.colors.neutral0};
1080
- border-radius: ${({theme:t})=>t.borderRadius};
1081
- user-select: none;
1082
-
1083
- &[data-state='checked'] {
1084
- background-color: ${({theme:t})=>t.colors.primary100};
1085
- color: ${({theme:t})=>t.colors.primary600};
1086
- font-weight: bold;
1087
- }
1088
-
1089
- &:hover,
1090
- &[data-highlighted] {
1091
- outline: none;
1092
- background-color: ${({theme:t,$hasHover:e=!0})=>e?t.colors.primary100:t.colors.neutral0};
1093
- }
1094
-
1095
- &[data-highlighted] {
1096
- color: ${({theme:t})=>t.colors.primary600};
1097
- font-weight: bold;
1098
- }
1099
- `,BZ=ZF,NZ=$.forwardRef((t,e)=>p.jsx(QF,{...t,asChild:!0,ref:e})),jZ=$.forwardRef((t,e)=>p.jsxs(JF,{children:[p.jsx(FZ,{}),p.jsx(VZ,{ref:e,...t})]})),FZ=k.styled(eV)`
1100
- background-color: ${t=>t.theme.colors.neutral800};
1101
- position: fixed;
1102
- inset: 0;
1103
- z-index: ${t=>t.theme.zIndices.overlay};
1104
- opacity: 0.2;
1105
-
1106
- @media (prefers-reduced-motion: no-preference) {
1107
- animation: ${pt.overlayFadeIn} ${t=>t.theme.motion.timings[200]}
1108
- ${t=>t.theme.motion.easings.authenticMotion};
1109
- }
1110
- `,VZ=k.styled(tV)`
1111
- max-width: 42rem;
1112
- height: min-content;
1113
- width: 100%;
1114
- overflow: hidden;
1115
- margin: 0 auto;
1116
- display: flex;
1117
- flex-direction: column;
1118
-
1119
- position: fixed;
1120
- top: 50%;
1121
- left: 50%;
1122
- transform: translate(-50%, -50%);
1123
-
1124
- border-radius: ${t=>t.theme.borderRadius};
1125
- background-color: ${t=>t.theme.colors.neutral0};
1126
- box-shadow: ${t=>t.theme.shadows.popupShadow};
1127
- z-index: ${t=>t.theme.zIndices.modal};
1128
-
1129
- @media (prefers-reduced-motion: no-preference) {
1130
- &[data-state='open'] {
1131
- animation-duration: ${t=>t.theme.motion.timings[200]};
1132
- animation-timing-function: ${t=>t.theme.motion.easings.authenticMotion};
1133
- animation-name: ${pt.modalPopIn};
1134
- }
1135
-
1136
- &[data-state='closed'] {
1137
- animation-duration: ${t=>t.theme.motion.timings[120]};
1138
- animation-timing-function: ${t=>t.theme.motion.easings.easeOutQuad};
1139
- animation-name: ${pt.modalPopOut};
1140
- }
1141
- }
1142
- `,HZ=$.forwardRef(({children:t,...e},n)=>p.jsx(iV,{asChild:!0,children:p.jsx(PZ,{tag:"h2",variant:"beta",ref:n,padding:6,fontWeight:"bold",...e,children:t})})),PZ=k.styled(Re)`
1143
- display: flex;
1144
- justify-content: center;
1145
- border-bottom: solid 1px ${t=>t.theme.colors.neutral150};
1146
- `,WZ=$.forwardRef(({children:t,icon:e,...n},r)=>p.jsx(he,{ref:r,gap:2,direction:"column",paddingTop:8,paddingBottom:8,paddingLeft:6,paddingRight:6,...n,children:typeof t=="string"?p.jsxs(p.Fragment,{children:[e?$.cloneElement(e,{width:24,height:24}):null,p.jsx(o$,{children:t})]}):t})),o$=$.forwardRef((t,e)=>p.jsx(oV,{asChild:!0,children:p.jsx(Re,{ref:e,variant:"omega",...t,tag:"p"})})),zZ=$.forwardRef((t,e)=>p.jsx(UZ,{ref:e,gap:2,padding:4,justifyContent:"space-between",...t,tag:"footer"})),UZ=k.styled(he)`
1147
- border-top: solid 1px ${t=>t.theme.colors.neutral150};
1148
- flex: 1;
1149
- `,qZ=$.forwardRef((t,e)=>p.jsx(rV,{...t,asChild:!0,ref:e})),KZ=$.forwardRef((t,e)=>p.jsx(nV,{...t,asChild:!0,ref:e})),GZ=Object.freeze(Object.defineProperty({__proto__:null,Action:KZ,Body:WZ,Cancel:qZ,Content:jZ,Description:o$,Footer:zZ,Header:HZ,Root:BZ,Trigger:NZ},Symbol.toStringTag,{value:"Module"}));function Zr(t,e){const n=$.useRef(null);return e&&n.current&&YZ(e,n.current)&&(e=n.current),n.current=e??null,$.useMemo(()=>new NT(t,e),[t,e])}function YZ(t,e){if(t===e)return!0;const n=Object.keys(t),r=Object.keys(e);if(n.length!==r.length)return!1;for(const i of n)if(e[i]!==t[i])return!1;return!0}const r0={Log:"live-region-log",Status:"live-region-status",Alert:"live-region-alert"},XZ=()=>p.jsxs(ko,{children:[p.jsx("p",{role:"log","aria-live":"polite",id:r0.Log,"aria-relevant":"all"}),p.jsx("p",{role:"status","aria-live":"polite",id:r0.Status,"aria-relevant":"all"}),p.jsx("p",{role:"alert","aria-live":"assertive",id:r0.Alert,"aria-relevant":"all"})]}),ZZ=k.createGlobalStyle`
1150
- ${k.css`
1151
- *,
1152
- *::before,
1153
- *::after {
1154
- box-sizing: border-box;
1155
- }
1156
-
1157
- * {
1158
- margin: 0;
1159
- }
1160
-
1161
- html {
1162
- /* Sets 1rem === 10px */
1163
- font-size: 62.5%;
1164
- }
1165
-
1166
- body {
1167
- height: 100%;
1168
- font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans',
1169
- 'Helvetica Neue', sans-serif;
1170
- color: ${({theme:t})=>t.colors.neutral800};
1171
- line-height: 1.5;
1172
- -webkit-font-smoothing: antialiased;
1173
- }
1174
-
1175
- img,
1176
- picture,
1177
- video,
1178
- canvas {
1179
- display: block;
1180
- max-width: 100%;
1181
- }
1182
-
1183
- input,
1184
- button,
1185
- textarea,
1186
- select {
1187
- padding: 0;
1188
- font: inherit;
1189
- }
1190
-
1191
- button {
1192
- border: unset;
1193
- background: unset;
1194
- padding: unset;
1195
- margin: unset;
1196
- }
1197
-
1198
- p,
1199
- h1,
1200
- h2,
1201
- h3,
1202
- h4,
1203
- h5,
1204
- h6 {
1205
- overflow-wrap: break-word;
1206
- font: unset;
1207
- }
1208
-
1209
- #root {
1210
- isolation: isolate;
1211
- }
1212
-
1213
- ol,
1214
- ul {
1215
- list-style: none;
1216
- padding: unset;
1217
- margin: unset;
1218
- }
1219
-
1220
- table {
1221
- border-collapse: collapse;
1222
- border-spacing: 0;
1223
- }
1224
-
1225
- *:focus-visible {
1226
- outline: 2px solid ${({theme:t})=>t.colors.primary600};
1227
- outline-offset: 2px;
1228
- }
1229
-
1230
- /* Focusing the button with a mouse, touch, or stylus will show a subtle drop shadow. */
1231
- *:focus:not(:focus-visible) {
1232
- outline: none;
1233
- }
1234
-
1235
- .lock-body-scroll {
1236
- height: 100vh;
1237
- overflow-y: hidden;
1238
- }
1239
- `}
1240
- `,hw="en-EN",s$=()=>typeof navigator>"u"?hw:navigator.language?navigator.language:hw,[QZ,Vh]=vl("StrapiDesignSystem",{locale:s$()}),JZ=({children:t,locale:e=s$(),theme:n=e$,tooltipConfig:r})=>(wo(()=>{const i=document.createElement("style");i.type="text/css",i.appendChild(document.createTextNode(`
1241
- * {
1242
- -webkit-transition: none !important;
1243
- -moz-transition: none !important;
1244
- -o-transition: none !important;
1245
- -ms-transition: none !important;
1246
- transition: none !important;
1247
- animation: none !important;
1248
- }
1249
- `)),document.head.appendChild(i),window.getComputedStyle(i).opacity,document.head.removeChild(i)},[n]),p.jsx(QZ,{locale:e,children:p.jsxs(k.ThemeProvider,{theme:n,children:[p.jsx(DE,{...r,children:t}),p.jsx(XZ,{}),p.jsx(ZZ,{})]})})),eQ=JT,jm=$.forwardRef(({container:t=globalThis?.document?.body,...e},n)=>t?Za.createPortal(p.jsx(be,{ref:n,...e}),t):null);jm.displayName="Portal";const Fm=$.forwardRef(({children:t,viewportRef:e,...n},r)=>p.jsxs(tQ,{ref:r,...n,children:[p.jsx(nQ,{ref:e,children:t}),p.jsx(fw,{orientation:"vertical",children:p.jsx(dw,{})}),p.jsx(fw,{orientation:"horizontal",children:p.jsx(dw,{})})]})),tQ=k.styled(jV)`
1250
- width: 100%;
1251
- height: 100%;
1252
- overflow: hidden;
1253
- display: flex;
1254
- `,nQ=k.styled(FV)`
1255
- min-width: 100%;
1256
- padding-inline: 4px;
1257
- `,fw=k.styled(VV)`
1258
- display: flex;
1259
- /* ensures no selection */
1260
- user-select: none;
1261
- /* disable browser handling of all panning and zooming gestures on touch devices */
1262
- touch-action: none;
1263
-
1264
- &[data-orientation='vertical'] {
1265
- width: 0.4rem;
1266
- }
1267
-
1268
- &[data-orientation='horizontal'] {
1269
- flex-direction: column;
1270
- height: 0.4rem;
1271
- }
1272
- `,dw=k.styled(HV)`
1273
- position: relative;
1274
- flex: 1;
1275
- background-color: ${t=>t.theme.colors.neutral150};
1276
- border-radius: var(--scrollbar-size);
1277
-
1278
- /* increase target size for touch devices https://www.w3.org/WAI/WCAG21/Understanding/target-size.html */
1279
- &::before {
1280
- content: '';
1281
- position: absolute;
1282
- top: 50%;
1283
- left: 50%;
1284
- transform: translate(-50%, -50%);
1285
- width: 100%;
1286
- height: 100%;
1287
- min-width: 44px;
1288
- min-height: 44px;
1289
- }
1290
- `,rQ=$.forwardRef(({onClear:t,clearLabel:e="Clear",startIcon:n,disabled:r,hasError:i,children:o,id:s,size:a="M",withTags:c,...h},f)=>{const d=$.useRef(null),m=x=>{t&&!r&&(t(x),d.current.focus())},{labelNode:v}=mn("SelectTrigger"),w=gn(d,f);return p.jsx(nr.Trigger,{asChild:!0,children:p.jsxs(oQ,{"aria-disabled":r,$hasError:i,ref:w,alignItems:"center",justifyContent:"space-between",position:"relative",overflow:"hidden",hasRadius:!0,background:r?"neutral150":"neutral0",gap:4,cursor:"default","aria-labelledby":v?`${s}-label`:void 0,$size:a,$withTags:c,...h,children:[p.jsxs(he,{flex:"1",tag:"span",gap:3,children:[n&&p.jsx(he,{tag:"span","aria-hidden":!0,children:n}),o]}),p.jsxs(he,{tag:"span",gap:3,children:[t?p.jsx(iQ,{tag:"button",hasRadius:!0,background:"transparent",role:"button",tabIndex:0,onClick:m,"aria-disabled":r,"aria-label":e,title:e,cursor:"pointer",children:p.jsx(ji,{})}):null,p.jsx(sQ,{children:p.jsx(Mi,{})})]})]})})}),iQ=k.styled(be)`
1291
- border: none;
1292
- display: flex;
1293
-
1294
- svg {
1295
- height: 1.1rem;
1296
- width: 1.1rem;
1297
- }
1298
-
1299
- svg path {
1300
- fill: ${({theme:t})=>t.colors.neutral500};
1301
- }
1302
- `,oQ=k.styled(he)`
1303
- border: 1px solid ${({theme:t,$hasError:e})=>e?t.colors.danger600:t.colors.neutral200};
1304
- ${t=>{switch(t.$size){case"S":return k.css`
1305
- padding-block: ${t.theme.spaces[1]};
1306
- padding-inline-start: ${t.$withTags?t.theme.spaces[1]:t.theme.spaces[4]};
1307
- padding-inline-end: ${t.theme.spaces[3]};
1308
- `;default:return k.css`
1309
- padding-block: ${t.$withTags?"0.3rem":t.theme.spaces[2]};
1310
- padding-inline-start: ${t.$withTags?t.theme.spaces[1]:t.theme.spaces[4]};
1311
- padding-inline-end: ${t.theme.spaces[3]};
1312
- `}}}
1313
- cursor: pointer;
1314
-
1315
- &[aria-disabled='true'] {
1316
- color: ${t=>t.theme.colors.neutral500};
1317
- }
1318
-
1319
- /* Required to ensure the below inputFocusStyles are adhered too */
1320
- &:focus-visible {
1321
- outline: none;
1322
- }
1323
-
1324
- ${({theme:t,$hasError:e})=>Vi()({theme:t,$hasError:e})};
1325
- `,sQ=k.styled(nr.Icon)`
1326
- display: flex;
1327
- & > svg {
1328
- fill: ${({theme:t})=>t.colors.neutral500};
1329
- }
1330
- `,aQ=$.forwardRef(({children:t,placeholder:e,...n},r)=>p.jsx(lQ,{ref:r,ellipsis:!0,...n,children:p.jsx(cQ,{placeholder:e,children:t})})),lQ=k.styled(Re)`
1331
- flex: 1;
1332
- font-size: 1.4rem;
1333
- line-height: 2.2rem;
1334
- `,cQ=k.styled(nr.Value)`
1335
- display: flex;
1336
- gap: ${({theme:t})=>t.spaces[1]};
1337
- flex-wrap: wrap;
1338
- `,uQ=$.forwardRef((t,e)=>p.jsx(hQ,{ref:e,...t,children:p.jsx(Fm,{children:t.children})})),hQ=k.styled(nr.Content)`
1339
- background: ${({theme:t})=>t.colors.neutral0};
1340
- box-shadow: ${({theme:t})=>t.shadows.filterShadow};
1341
- border: 1px solid ${({theme:t})=>t.colors.neutral150};
1342
- border-radius: ${({theme:t})=>t.borderRadius};
1343
- min-width: var(--radix-select-trigger-width);
1344
- max-height: 15.6rem;
1345
- z-index: ${({theme:t})=>t.zIndices.popover};
1346
-
1347
- @media (prefers-reduced-motion: no-preference) {
1348
- animation-duration: ${t=>t.theme.motion.timings[200]};
1349
-
1350
- /* The select can't animate out yet, watch https://github.com/radix-ui/primitives/issues/1893, or take a look and solve it yourself. */
1351
- &[data-state='open'] {
1352
- animation-timing-function: ${t=>t.theme.motion.easings.authenticMotion};
1353
-
1354
- &[data-side='top'] {
1355
- animation-name: ${pt.slideUpIn};
1356
- }
1357
-
1358
- &[data-side='bottom'] {
1359
- animation-name: ${pt.slideDownIn};
1360
- }
1361
- }
1362
- }
1363
- `,fQ=k.styled(nr.Viewport)`
1364
- padding: ${({theme:t})=>t.spaces[1]};
1365
- `,dQ=$.forwardRef((t,e)=>p.jsx(mQ,{ref:e,...t})),gQ=k.css`
1366
- width: 100%;
1367
- border: none;
1368
- text-align: left;
1369
- outline-offset: -3px;
1370
- border-radius: ${t=>t.theme.borderRadius};
1371
- padding: ${t=>`${t.theme.spaces[2]} ${t.theme.spaces[4]}`};
1372
- padding-left: ${({theme:t})=>t.spaces[4]};
1373
- background-color: ${({theme:t})=>t.colors.neutral0};
1374
- display: flex;
1375
- align-items: center;
1376
- gap: ${({theme:t})=>t.spaces[2]};
1377
- white-space: nowrap;
1378
- user-select: none;
1379
- color: ${({theme:t})=>t.colors.neutral800};
1380
-
1381
- &:focus-visible {
1382
- outline: none;
1383
- background-color: ${({theme:t})=>t.colors.primary100};
1384
- cursor: pointer;
1385
- }
1386
- `,mQ=k.styled(nr.Item)`
1387
- ${gQ}
1388
-
1389
- &:hover {
1390
- background-color: ${({theme:t})=>t.colors.primary100};
1391
- }
1392
-
1393
- &[data-state='checked'] {
1394
- font-weight: bold;
1395
- background-color: ${({theme:t})=>t.colors.primary100};
1396
- color: ${({theme:t})=>t.colors.primary600};
1397
- font-weight: bold;
1398
- }
1399
- `,a$=nr.Root,l$=rQ,c$=aQ,u$=nr.Portal,h$=uQ,f$=fQ,Vm=dQ,d$=nr.ItemIndicator,g$=nr.ItemText,pQ=nr.Group,N1=$.forwardRef(({children:t,clearLabel:e="Clear",customizeContent:n,disabled:r,hasError:i,id:o,name:s,onChange:a,onClear:c,onCloseAutoFocus:h,onReachEnd:f,placeholder:d,required:m,size:v,startIcon:w,value:x,...C},S)=>{const[A,T]=$.useState(),[O,D]=$.useState(!1),L=ge=>{D(ge)},I=ge=>{c&&c(ge),a||T("")},V=ge=>{a?a(typeof x=="number"?Number(ge):ge):T(ge)},F=$.useRef(null),H=Tn(),K=`intersection-${Ms(H)}`;wl(F,ge=>{f&&f(ge)},{selectorToWatch:`#${K}`,skipWhen:!O});const{error:J,required:G,...re}=mn("SingleSelect"),oe=!!J||i,te=re.id??o,ie=re.name??s;let Y;J?Y=`${te}-error`:re.hint&&(Y=`${te}-hint`);const ue=(typeof x<"u"&&x!==null?x.toString():A)??"";return p.jsxs(a$,{onOpenChange:L,disabled:r,required:G??m,onValueChange:V,value:ue,...C,children:[p.jsx(l$,{ref:S,id:te,name:ie,startIcon:w,hasError:oe,disabled:r,clearLabel:e,onClear:ue&&c?I:void 0,"aria-label":C["aria-label"],"aria-describedby":Y??C["aria-describedby"],size:v,children:p.jsx(c$,{placeholder:d,textColor:ue?"neutral800":"neutral600",children:ue&&n?n(ue):void 0})}),p.jsx(u$,{children:p.jsx(h$,{position:"popper",sideOffset:4,onCloseAutoFocus:h,children:p.jsxs(f$,{ref:F,children:[t,p.jsx(be,{id:K,width:"100%",height:"1px"})]})})})]})}),j1=$.forwardRef(({value:t,startIcon:e,children:n,...r},i)=>p.jsxs(Vm,{ref:i,value:t.toString(),...r,children:[e&&p.jsx(he,{tag:"span","aria-hidden":!0,children:e}),p.jsx(Re,{lineHeight:"20px",width:"100%",children:p.jsx(g$,{children:n})})]})),vQ=200,gw=15,[bQ,Hs]=vl("DatePicker"),wQ=$.forwardRef(({calendarLabel:t,className:e,initialDate:n,locale:r,maxDate:i,minDate:o,monthSelectLabel:s="Month",onChange:a,value:c,yearSelectLabel:h="Year",hasError:f,id:d,name:m,disabled:v=!1,required:w=!1,onClear:x,clearLabel:C="Clear",size:S="M",...A},T)=>{const O=gs(),D=Vh("DatePicker"),L=r??D.locale,I=Zr(L,{day:"2-digit",month:"2-digit",year:"numeric"}),[V,F]=$.useState(!1),[H,K]=$.useState(null),[W,J]=$.useState(null),[G,re]=$.useState(null),[oe,te]=$.useState(),[ie,Y]=yr({defaultProp:n?Ji(n):void 0,prop:c?Ji(c):void 0,onChange(Pe){a&&a(Pe?.toDate(O))}}),[ue,ge]=$.useMemo(()=>{const Pe=n?Ji(n):P1("UTC"),Yt=o?Ji(o):Pe.set({day:1,month:1,year:Pe.year-vQ});let ft=i?Ji(i):Pe.set({day:31,month:12,year:Pe.year+gw});return ft.compare(Yt)<0&&(ft=Yt.set({day:31,month:12,year:Yt.year+gw})),[Yt,ft]},[o,i,n]),[De,we]=$.useState(xQ({currentValue:ie,minDate:ue,maxDate:ge})),Ve=Tn(),Ne=$.useRef(null),He=Pe=>{x&&!v&&(te(""),Y(void 0),x(Pe),W?.focus())},pe=$.useCallback(Pe=>{Pe&&ie&&we(ie),F(Pe)},[ie]);wo(()=>{if(c){const Pe=Ji(c);te(I.format(Pe.toDate(O))),we(Pe)}else te("")},[c,I,O]),wo(()=>{if(n&&oe===void 0){const Pe=Ji(n);te(I.format(Pe.toDate(O)))}},[n,oe,I,O]);const{error:Oe,...ke}=mn("Combobox"),Ae=!!Oe||f,_e=ke.id??d,ze=ke.name??m,Et=ke.required||w;let Ze;return Oe?Ze=`${_e}-error`:ke.hint&&(Ze=`${_e}-hint`),p.jsxs(bQ,{calendarDate:De,content:G,contentId:Ve,disabled:v,locale:L,minDate:ue,maxDate:ge,open:V,onCalendarDateChange:we,onContentChange:re,onOpenChange:pe,onTextInputChange:J,onTextValueChange:te,onTriggerChange:K,onValueChange:Y,required:Et,textInput:W,textValue:oe,timeZone:O,trigger:H,value:ie,children:[p.jsxs(CQ,{className:e,hasError:Ae,size:S,children:[p.jsx(TI,{fill:"neutral500","aria-hidden":!0}),p.jsx(RQ,{ref:T,"aria-describedby":Ze,id:_e,name:ze,...A}),oe&&x?p.jsx(SQ,{tag:"button",hasRadius:!0,background:"transparent",type:"button",onClick:He,"aria-disabled":v,"aria-label":C,title:C,ref:Ne,children:p.jsx(ji,{})}):null]}),p.jsx(jm,{children:p.jsx(EQ,{label:t,children:p.jsx(LQ,{monthSelectLabel:s,yearSelectLabel:h})})})]})}),mw=t=>!!t.match(/^[^a-zA-Z]*$/),xQ=({currentValue:t,minDate:e,maxDate:n})=>{const r=P1("UTC");return t||(a0(e,r)===e&&l0(n,r)===n?r:a0(e,r)===r?e:l0(n,r)===r?n:r)},yQ="DatePickerTrigger",CQ=$.forwardRef(({hasError:t,size:e,...n},r)=>{const i=Hs(yQ),o=gn(r,a=>i.onTriggerChange(a)),s=()=>{i.disabled||i.onOpenChange(!0)};return p.jsx(_s,{asChild:!0,trapped:i.open,onMountAutoFocus:a=>{a.preventDefault()},onUnmountAutoFocus:a=>{document.getSelection()?.empty(),a.preventDefault()},children:p.jsx($Q,{ref:o,$hasError:t,$size:e,...n,hasRadius:!0,gap:3,overflow:"hidden",background:i.disabled?"neutral150":"neutral0",onClick:oo(n.onClick,()=>{i.textInput?.focus()}),onPointerDown:oo(n.onPointerDown,a=>{const c=a.target;c.hasPointerCapture(a.pointerId)&&c.releasePointerCapture(a.pointerId),(c.closest("button")??c.closest("div"))===a.currentTarget&&a.button===0&&a.ctrlKey===!1&&(s(),i.textInput?.focus())})})})}),$Q=k.styled(he)`
1400
- border: 1px solid ${({theme:t,$hasError:e})=>e?t.colors.danger600:t.colors.neutral200};
1401
- ${t=>{switch(t.$size){case"S":return k.css`
1402
- padding-block: ${t.theme.spaces[1]};
1403
- padding-inline: ${t.theme.spaces[3]};
1404
- `;default:return k.css`
1405
- padding-block: ${t.theme.spaces[2]};
1406
- padding-inline: ${t.theme.spaces[3]};
1407
- `}}}
1408
-
1409
- & > svg {
1410
- flex: 1 0 auto;
1411
- }
1412
-
1413
- &[data-disabled] {
1414
- color: ${({theme:t})=>t.colors.neutral600};
1415
- background: ${({theme:t})=>t.colors.neutral150};
1416
- cursor: not-allowed;
1417
- }
1418
-
1419
- /* Required to ensure the below inputFocusStyles are adhered too */
1420
- &:focus-visible {
1421
- outline: none;
1422
- }
1423
-
1424
- ${({theme:t,$hasError:e})=>Vi()({theme:t,$hasError:e})};
1425
- `,SQ=k.styled(be)`
1426
- border: none;
1427
- color: ${({theme:t})=>t.colors.neutral600};
1428
- padding: 0;
1429
- cursor: pointer;
1430
- `,AQ="DatePickerTextInput",RQ=$.forwardRef(({placeholder:t,...e},n)=>{const r=Hs(AQ),{onTextValueChange:i,textValue:o,onTextInputChange:s,onOpenChange:a,disabled:c,locale:h}=r,f=gn(n,S=>s(S)),d=()=>{c||a(!0)},m=Zr(h,{year:"numeric",month:"2-digit",day:"2-digit"}),[v,w,x]=$.useMemo(()=>{const S=m.formatToParts(new Date),A=S.filter(D=>D.type==="year"||D.type==="month"||D.type==="day"),T=A.map(D=>{switch(D.type){case"day":return"DD";case"month":return"MM";case"year":return"YYYY";default:return""}}),O=S.find(D=>D.type==="literal")?.value??"";return[T,O,A]},[m]),C=v.map(S=>`\\d{${S.length}}`).join(`\\${w}`);return p.jsx(TQ,{role:"combobox",type:"text",inputMode:"numeric",ref:f,"aria-autocomplete":"none","aria-controls":r.contentId,"aria-disabled":r.disabled,"aria-expanded":r.open,"aria-required":r.required,"aria-haspopup":"dialog","data-state":r.open?"open":"closed",disabled:c,"data-disabled":c?"":void 0,pattern:C,placeholder:t??v.join(w),...e,value:o??"",onBlur:oo(e.onBlur,()=>{if(!r.textValue){r.onValueChange(void 0);return}r.onTextValueChange(m.format(r.calendarDate.toDate(r.timeZone))),r.onValueChange(r.calendarDate)}),onChange:oo(e.onChange,S=>{if(mw(S.target.value)){const A=S.target.value.split(w),[T,O,D]=x.map((J,G)=>{const re=A[G];return{...J,value:re}}).sort((J,G)=>J.type==="year"?1:G.type==="year"?-1:J.type==="month"?1:G.type==="month"?-1:0).map(J=>J.value),L=r.calendarDate.year;let I=r.calendarDate.year;if(D){const J=D.length===1?`0${D}`:D;I=D.length<3?Number(`${L}`.slice(0,4-J.length)+J):Number(J)}D&&D.length<3&&I>r.maxDate.year&&(I-=100);const V=r.calendarDate.set({year:I}),F=V.calendar.getMonthsInYear(V),H=V.set({month:O&&Number(O)<=F?Number(O):void 0}),K=H.calendar.getDaysInMonth(H),W=H.set({day:T&&Number(T)<=K?Number(T):void 0});r.onCalendarDateChange(kQ(W,r.minDate,r.maxDate)),r.onTextValueChange(S.target.value)}}),onKeyDown:oo(e.onKeyDown,S=>{if(!r.open&&(mw(S.key)||["ArrowDown","Backspace"].includes(S.key)))d();else if(["Tab"].includes(S.key)&&r.open)S.preventDefault();else if(["Escape"].includes(S.key))r.open?r.onOpenChange(!1):(r.onValueChange(void 0),r.onTextValueChange("")),S.preventDefault();else if(r.open&&["ArrowDown","ArrowUp","ArrowLeft","ArrowRight"].includes(S.key))switch(S.preventDefault(),S.key){case"ArrowDown":{const A=r.calendarDate.add({weeks:1});if(r.maxDate&&A.compare(r.maxDate)>0)return;r.onCalendarDateChange(A);return}case"ArrowRight":{const A=r.calendarDate.add({days:1});if(r.maxDate&&A.compare(r.maxDate)>0)return;r.onCalendarDateChange(A);return}case"ArrowUp":{const A=r.calendarDate.subtract({weeks:1});if(r.minDate&&A.compare(r.minDate)<0)return;r.onCalendarDateChange(A);return}case"ArrowLeft":{const A=r.calendarDate.subtract({days:1});if(r.minDate&&A.compare(r.minDate)<0)return;r.onCalendarDateChange(A)}}else r.open&&["Enter"].includes(S.key)&&(S.preventDefault(),i(m.format(r.calendarDate.toDate(r.timeZone))),r.onValueChange(r.calendarDate),r.onOpenChange(!1))})})});function kQ(t,e,n){return e&&(t=l0(t,e)),n&&(t=a0(t,n)),t}const TQ=k.styled.input`
1431
- width: 100%;
1432
- font-size: 1.4rem;
1433
- line-height: 2.2rem;
1434
- color: ${({theme:t})=>t.colors.neutral800};
1435
- border: none;
1436
- background-color: transparent;
1437
-
1438
- &:focus-visible {
1439
- outline: none;
1440
- }
1441
-
1442
- &[aria-disabled='true'] {
1443
- cursor: inherit;
1444
- }
1445
- `,MQ="DatePickerContent",EQ=$.forwardRef((t,e)=>{const[n,r]=$.useState(),i=Hs(MQ);if(wo(()=>{r(new DocumentFragment)},[]),!i.open){const o=n;return o?Za.createPortal(p.jsx("div",{children:t.children}),o):null}return p.jsx(DQ,{...t,ref:e})}),OQ="DatePickerContent",DQ=$.forwardRef((t,e)=>{const{label:n="Choose date",...r}=t,{onOpenChange:i,...o}=Hs(OQ),{x:s,y:a,refs:c,strategy:h,placement:f}=sV({strategy:"fixed",placement:"bottom-start",middleware:[aV({mainAxis:4}),lV(),cV()],elements:{reference:o.trigger},whileElementsMounted:Qw});$.useEffect(()=>{const m=()=>{i(!1)};return window.addEventListener("blur",m),window.addEventListener("resize",m),()=>{window.removeEventListener("blur",m),window.removeEventListener("resize",m)}},[i]);const d=gn(e,m=>o.onContentChange(m),c.setFloating);return Is(),p.jsx(ey,{allowPinchZoom:!0,children:p.jsx(eQ,{asChild:!0,onFocusOutside:m=>{m.preventDefault()},onDismiss:()=>{i(!1)},children:p.jsx(IQ,{ref:d,"data-state":o.open?"open":"closed","data-side":f.includes("top")?"top":"bottom",onContextMenu:m=>m.preventDefault(),id:o.contentId,role:"dialog","aria-modal":"true","aria-label":n,style:{left:s,top:a,position:h},hasRadius:!0,background:"neutral0",padding:1,...r})})})}),IQ=k.styled(be)`
1446
- box-shadow: ${({theme:t})=>t.shadows.filterShadow};
1447
- z-index: ${({theme:t})=>t.zIndices.popover};
1448
- border: 1px solid ${({theme:t})=>t.colors.neutral150};
1449
-
1450
- @media (prefers-reduced-motion: no-preference) {
1451
- animation-duration: ${t=>t.theme.motion.timings[200]};
1452
-
1453
- &[data-state='open'] {
1454
- animation-timing-function: ${t=>t.theme.motion.easings.authenticMotion};
1455
-
1456
- &[data-side='top'] {
1457
- animation-name: ${pt.slideUpIn};
1458
- }
1459
-
1460
- &[data-side='bottom'] {
1461
- animation-name: ${pt.slideDownIn};
1462
- }
1463
- }
1464
- }
1465
- `,_Q="DatePickerCalendar",LQ=$.forwardRef(({monthSelectLabel:t,yearSelectLabel:e,...n},r)=>{const{locale:i,timeZone:o,minDate:s,maxDate:a,calendarDate:c,onCalendarDateChange:h}=Hs(_Q),f=dT(c),d=$.useMemo(()=>{const T=s.year,O=a.year;return[...Array(O-T+1).keys()].map(D=>(T+D).toString())},[s,a]),m=Zr(i,{month:"long"}),v=$.useMemo(()=>[...Array(c.calendar.getMonthsInYear(c)).keys()].map(T=>m.format(c.set({month:T+1}).toDate(o))),[c,m,o]),w=Zr(i,{weekday:"short"}),x=$.useMemo(()=>{const T=Rw(P1(o),i);return[...new Array(7).keys()].map(O=>{const L=T.add({days:O}).toDate(o);return w.format(L)})},[o,i,w]),C=T=>{if(typeof T=="number")return;const O=c.set({month:v.indexOf(T)+1});h(O)},S=T=>{if(typeof T=="number")return;const O=c.set({year:parseInt(T,10)});h(O)},A=BQ(f,i);return p.jsxs(he,{ref:r,direction:"column",alignItems:"stretch",padding:4,...n,children:[p.jsxs(NQ,{justifyContent:"flex-start",paddingBottom:4,paddingLeft:2,paddingRight:2,gap:2,children:[p.jsx(xo,{children:p.jsx(N1,{"aria-label":t,value:v[c.month-1],onChange:C,children:v.map(T=>p.jsx(j1,{value:T,children:T},T))})}),p.jsx(xo,{children:p.jsx(N1,{value:c.year.toString(),"aria-label":e,onChange:S,children:d.map(T=>p.jsx(j1,{value:T,children:T},T))})})]}),p.jsxs("table",{role:"grid",children:[p.jsx("thead",{"aria-hidden":!0,children:p.jsx("tr",{"aria-rowindex":0,children:x.map((T,O)=>p.jsx(jQ,{"aria-colindex":O,children:T},T))})}),p.jsx("tbody",{children:[...new Array(6).keys()].map(T=>p.jsx("tr",{"aria-rowindex":T+2,children:A(T).map((O,D)=>O?p.jsx(HQ,{"aria-colindex":D+1,date:O,startDate:f,disabled:s.compare(O)>0||O.compare(a)>0},O.toString()):p.jsx(m$,{"aria-colindex":D+1},D+1))},T))})]})]})}),BQ=(t,e)=>n=>{let r=t.add({weeks:n});const i=[];r=Rw(r,e);const o=Sw(r,e);for(let s=0;s<o;s++)i.push(null);for(;i.length<7;){i.push(r);const s=r.add({days:1});if($w(r,s))break;r=s}for(;i.length<7;)i.push(null);return i},NQ=k.styled(he)`
1466
- div[role='combobox'] {
1467
- border: 1px solid transparent;
1468
- background: transparent;
1469
- font-weight: ${t=>t.theme.fontWeights.bold};
1470
-
1471
- svg {
1472
- fill: ${({theme:t})=>t.colors.neutral500};
1473
- }
1474
-
1475
- &:hover {
1476
- background-color: ${({theme:t})=>t.colors.neutral100};
1477
- }
1478
- }
1479
- `,jQ=$.forwardRef(({children:t,...e},n)=>p.jsx(FQ,{tag:"th",role:"gridcell",ref:n,...e,height:"2.4rem",width:"3.2rem",children:p.jsx(Re,{variant:"pi",fontWeight:"bold",color:"neutral800",children:t.slice(0,2)})})),FQ=k.styled(be)`
1480
- border-radius: ${({theme:t})=>t.borderRadius};
1481
- text-transform: capitalize;
1482
- `,VQ="DatePickerCalendarCell",HQ=$.forwardRef(({date:t,startDate:e,disabled:n,...r},i)=>{const{timeZone:o,locale:s,calendarDate:a,onValueChange:c,onOpenChange:h,onTextValueChange:f,onCalendarDateChange:d}=Hs(VQ),m=$w(a,t),v=Zr(s,{weekday:"long",day:"numeric",month:"long",year:"numeric"}),w=$.useMemo(()=>v.format(t.toDate(o)),[v,t,o]),x=Zr(s,{day:"numeric",calendar:t.calendar.identifier}),C=$.useMemo(()=>x.formatToParts(t.toDate(o)).find(D=>D.type==="day").value,[x,t,o]),S=Zr(s,{day:"2-digit",month:"2-digit",year:"numeric"}),A=gT(e),T=t.compare(e)<0||t.compare(A)>0;let O="neutral900";return m?O="primary600":T&&(O="neutral600"),p.jsx(m$,{tag:"td",role:"gridcell",ref:i,"aria-selected":m,...r,hasRadius:!0,"aria-label":w,tabIndex:m?0:-1,background:m?"primary100":"neutral0",cursor:"pointer",onPointerDown:oo(r.onPointerDown,D=>{D.preventDefault(),d(t),c(t),f(S.format(t.toDate(o))),h(!1)}),"aria-disabled":n,children:p.jsx(Re,{variant:"pi",textColor:O,children:C})})}),m$=k.styled(be)`
1483
- text-align: center;
1484
- padding: 0.7rem;
1485
- // Trick to prevent the outline from overflowing because of the general outline-offset
1486
- outline-offset: -2px !important;
1487
- &[aria-disabled='true'] {
1488
- pointer-events: none;
1489
- opacity: 0.5;
1490
- }
1491
-
1492
- &[aria-disabled='false'] {
1493
- &:hover {
1494
- background: ${({theme:t})=>t.colors.primary100};
1495
- color: ${({theme:t})=>t.colors.primary600};
1496
- }
1497
- }
1498
- `,Ji=t=>{const e=t.toISOString(),n=Nw(e,"UTC");return Ew(n)},i0=t=>!!t.match(/^[^a-zA-Z]*$/),PQ=$.forwardRef(({step:t=15,value:e,defaultValue:n,onChange:r,...i},o)=>{const s=Vh("TimePicker"),[a,c]=$.useState(""),[h,f]=yr({prop:e,defaultProp:n,onChange:r}),d=Zr(s.locale,{hour:"2-digit",minute:"2-digit",hour12:!1}),m=$.useMemo(()=>{const A=d.formatToParts(new Date),{value:T}=A.find(O=>O.type==="literal");return T},[d]),v=$.useMemo(()=>{const A=60/t;return[...Array(24).keys()].flatMap(T=>[...Array(A).keys()].map(O=>d.format(new Date(0,0,0,T,O*t))))},[t,d]),w=A=>{(!A||i0(A))&&c(A)},x=A=>{const[T,O]=A.split(m);if(!T&&!O)return;const D=Number(T??"0"),L=Number(O??"0");if(!(D>23||L>59))return d.format(new Date(0,0,0,D,L))},C=A=>{const T=x(A.target.value);T?(c(T),f(T)):c(h)},S=A=>{if(typeof A<"u"){const T=x(A);f(T)}else f(A)};return $.useEffect(()=>{const A=typeof e>"u"?"":e;i0(A)&&c(A)},[e,c]),p.jsx(TZ,{...i,ref:o,value:h,onChange:S,isPrintableCharacter:i0,allowCustomValue:!0,placeholder:`--${m}--`,autocomplete:"none",startIcon:p.jsx(JI,{fill:"neutral500"}),inputMode:"numeric",pattern:`\\d{2}\\${m}\\d{2}`,textValue:a,onTextValueChange:w,onBlur:C,children:v.map(A=>p.jsx(LZ,{value:A,children:A},A))})}),WQ=k.styled(wQ)`
1499
- flex: 1 1 70%;
1500
- min-width: 120px;
1501
- `,zQ=k.styled(PQ)`
1502
- flex: 1 1 30%;
1503
- min-width: 140px;
1504
- `;$.forwardRef(({clearLabel:t="clear",dateLabel:e="Choose date",timeLabel:n="Choose time",disabled:r=!1,hasError:i,onChange:o,onClear:s,required:a=!1,step:c,value:h,initialDate:f,size:d,...m},v)=>{const w=$.useRef(null),[x,C]=yr({defaultProp:f?fa(f,!1):void 0,prop:h?fa(h,!1):h??void 0,onChange(J){o&&o(J?.toDate(gs()))}}),S=Vh("DateTimePicker"),A=Zr(S.locale,{hour:"2-digit",minute:"2-digit",hour12:!1}),T=x?A.format(x.toDate(gs())):"",O=J=>{let G=J?fa(J):void 0;if(!(G&&x&&G.compare(x)===0)){if(T&&G){const[re,oe]=T.split(":");G=G.set({hour:parseInt(re,10),minute:parseInt(oe,10)})}C(G)}},D=J=>{if(!J)return;const[G,re]=J.split(":"),oe=x?x.set({hour:parseInt(G,10),minute:parseInt(re,10)}):fa(new Date).set({hour:parseInt(G,10),minute:parseInt(re,10)});C(oe)},L=J=>{C(void 0),s&&s(J)},I=()=>{const J=x?x.set({hour:0,minute:0}):fa(new Date);C(J)},V=gn(w,v),{error:F,id:H,labelNode:K}=mn("DateTimePicker"),W=!!F||i;return p.jsxs(he,{"aria-labelledby":K?`${H}-label`:void 0,role:"group",flex:"1",gap:1,children:[p.jsx(xo,{children:p.jsx(WQ,{...m,size:d,value:x?.toDate("UTC"),onChange:O,required:a,onClear:s?L:void 0,clearLabel:`${t} date`,disabled:r,ref:V,"aria-label":e})}),p.jsx(xo,{children:p.jsx(zQ,{size:d,hasError:W,value:T,onChange:D,onClear:s&&T!==void 0&&T!=="00:00"?I:void 0,clearLabel:`${t} time`,required:a,disabled:r,step:c,"aria-label":n})})]})});const fa=(t,e=!0)=>{const n=t.toISOString();let r=MT(n);return e&&(r=r.set({hour:0,minute:0})),co(r)},p$=$.forwardRef((t,e)=>p.jsx(UQ,{ref:e,background:"neutral150",...t,"data-orientation":"horizontal",role:"separator",tag:"div"})),UQ=k.styled(be)`
1505
- height: 1px;
1506
- border: none;
1507
- /* If contained in a Flex parent we want to prevent the Divider to shink */
1508
- flex-shrink: 0;
1509
- `,qQ=k.styled(be)`
1510
- svg {
1511
- height: 8.8rem;
1512
- }
1513
- `;$.forwardRef(({icon:t,content:e,action:n,hasRadius:r=!0,shadow:i="tableShadow"},o)=>p.jsxs(he,{ref:o,alignItems:"center",direction:"column",padding:11,background:"neutral0",hasRadius:r,shadow:i,children:[t?p.jsx(qQ,{paddingBottom:6,"aria-hidden":!0,children:t}):null,p.jsx(be,{paddingBottom:4,children:p.jsx(Re,{variant:"delta",tag:"p",textAlign:"center",textColor:"neutral600",children:e})}),n]}));const v$=Me.define(),b$=Me.define(),KQ=xe.mark({attributes:{style:"background-color: yellow; color: black"}}),GQ=Bt.define({create(){return xe.none},update(t,e){return t=t.map(e.changes),e.effects.forEach(n=>{n.is(v$)?t=t.update({add:n.value,sort:!0}):n.is(b$)&&(t=t.update({filter:n.value}))}),t},provide:t=>le.decorations.from(t)});$.forwardRef(({hasError:t,required:e,id:n,value:r="",disabled:i=!1,onChange:o=()=>null,...s},a)=>{const c=$.useRef(),h=$.useRef(),f=$.useRef(),{error:d,...m}=mn("JsonInput"),v=!!d||t,w=m.id??n,x=m.required||e;let C;d?C=`${w}-error`:m.hint&&(C=`${w}-hint`);const S=F=>{const H=h.current?.doc;if(H){const{text:K,to:W}=H.line(F),J=W-K.trimStart().length;W>J&&f.current?.dispatch({effects:v$.of([KQ.range(J,W)])})}},A=()=>{const F=h.current?.doc;if(F){const H=F.length||0;f.current?.dispatch({effects:b$.of((K,W)=>W<=0||K>=H)})}},T=({state:F,view:H})=>{f.current=H,h.current=F,A();const W=oU()(H);W.length&&S(F.doc.lineAt(W[0].from).number)},O=(F,H)=>{T(H),o(F)},D=(F,H)=>{f.current=F,h.current=H,T({view:F,state:H})},{setContainer:L,view:I}=sC({value:r,onCreateEditor:D,container:c.current,editable:!i,extensions:[lU(),GQ],onChange:O,theme:"dark",basicSetup:{lineNumbers:!0,bracketMatching:!0,closeBrackets:!0,indentOnInput:!0,syntaxHighlighting:!0,highlightSelectionMatches:!0,tabSize:2}}),V=gn(c,L);return $.useImperativeHandle(a,()=>({...I?.dom,focus(){I&&I.focus()},scrollIntoView(F){I&&I.dom.scrollIntoView(F)}}),[I]),p.jsx(YQ,{ref:V,$hasError:v,alignItems:"stretch",fontSize:2,hasRadius:!0,"aria-required":x,id:w,"aria-describedby":C,...s})});const YQ=k.styled(he)`
1514
- line-height: ${({theme:t})=>t.lineHeights[2]};
1515
-
1516
- .cm-editor {
1517
- /**
1518
- * Hard coded since the color is the same between themes,
1519
- * theme.colors.neutral800 changes between themes
1520
- */
1521
- background-color: #32324d;
1522
- width: 100%;
1523
- outline: none;
1524
- }
1525
-
1526
- .cm-scroller {
1527
- border: 1px solid ${({theme:t,$hasError:e})=>e?t.colors.danger600:t.colors.neutral200};
1528
- /* inputFocusStyle will receive hasError prop */
1529
- ${Vi()}
1530
- }
1531
-
1532
- .cm-editor,
1533
- .cm-scroller {
1534
- border-radius: ${({theme:t})=>t.borderRadius};
1535
- }
1536
-
1537
- .cm-gutters,
1538
- .cm-activeLineGutter {
1539
- /**
1540
- * Hard coded since the color is the same between themes,
1541
- * theme.colors.neutral700 changes between themes
1542
- */
1543
- background-color: #4a4a6a;
1544
- }
1545
- `;nn(({disabled:t,...e},n)=>p.jsx(Zu,{ref:n,tag:bl,tabIndex:t?-1:void 0,disabled:t,...e}));k.styled(be)`
1546
- // To prevent global outline on focus visible to force an outline when Main is focused
1547
- &:focus-visible {
1548
- outline: none;
1549
- }
1550
- `;k.styled(be)`
1551
- text-decoration: none;
1552
-
1553
- &:focus {
1554
- left: ${({theme:t})=>t.spaces[3]};
1555
- top: ${({theme:t})=>t.spaces[3]};
1556
- }
1557
- `;const XQ=(t,e)=>`${t}${Math.floor(e*255).toString(16).padStart(2,"0")}`,ZQ=P3,QQ=$.forwardRef((t,e)=>p.jsx(W3,{...t,asChild:!0,ref:e})),JQ=$.forwardRef((t,e)=>p.jsx(z3,{children:p.jsx(eJ,{children:p.jsx(tJ,{ref:e,...t})})})),eJ=k.styled(U3)`
1558
- background: ${t=>XQ(t.theme.colors.neutral800,.2)};
1559
- position: fixed;
1560
- inset: 0;
1561
- z-index: ${t=>t.theme.zIndices.overlay};
1562
-
1563
- @media (prefers-reduced-motion: no-preference) {
1564
- animation: ${pt.overlayFadeIn} ${t=>t.theme.motion.timings[200]}
1565
- ${t=>t.theme.motion.easings.authenticMotion};
1566
- }
1567
- `,tJ=k.styled(q3)`
1568
- max-width: 83rem;
1569
- max-height: 90vh;
1570
- height: auto;
1571
- width: 60%;
1572
- overflow: hidden;
1573
- margin: 0 auto;
1574
- display: flex;
1575
- flex-direction: column;
1576
-
1577
- position: fixed;
1578
- top: 50%;
1579
- left: 50%;
1580
- transform: translate(-50%, -50%);
1581
-
1582
- border-radius: ${t=>t.theme.borderRadius};
1583
- background-color: ${t=>t.theme.colors.neutral0};
1584
- box-shadow: ${t=>t.theme.shadows.popupShadow};
1585
- z-index: ${t=>t.theme.zIndices.modal};
1586
-
1587
- @media (prefers-reduced-motion: no-preference) {
1588
- &[data-state='open'] {
1589
- animation-duration: ${t=>t.theme.motion.timings[200]};
1590
- animation-timing-function: ${t=>t.theme.motion.easings.authenticMotion};
1591
- animation-name: ${pt.modalPopIn};
1592
- }
1593
-
1594
- &[data-state='closed'] {
1595
- animation-duration: ${t=>t.theme.motion.timings[120]};
1596
- animation-timing-function: ${t=>t.theme.motion.easings.easeOutQuad};
1597
- animation-name: ${pt.modalPopOut};
1598
- }
1599
- }
1600
- `,w$=$.forwardRef((t,e)=>p.jsx(Gg,{...t,asChild:!0,ref:e})),nJ=$.forwardRef(({children:t,closeLabel:e="Close modal",...n},r)=>p.jsxs(rJ,{ref:r,padding:4,paddingLeft:5,paddingRight:5,background:"neutral100",justifyContent:"space-between",...n,tag:"header",children:[t,p.jsx(w$,{children:p.jsx(Xa,{withTooltip:!1,label:e,children:p.jsx(ji,{})})})]})),rJ=k.styled(he)`
1601
- border-bottom: solid 1px ${t=>t.theme.colors.neutral150};
1602
- `,iJ=$.forwardRef((t,e)=>p.jsx(K3,{asChild:!0,children:p.jsx(Re,{tag:"h2",variant:"omega",fontWeight:"bold",ref:e,...t})})),oJ=$.forwardRef(({children:t,...e},n)=>p.jsx(sJ,{ref:n,...e,children:t})),sJ=k.styled(Fm)`
1603
- padding-inline: ${t=>t.theme.spaces[8]};
1604
-
1605
- & > div {
1606
- padding-block: ${t=>t.theme.spaces[8]};
1607
-
1608
- & > div {
1609
- // the scroll area component applies a display: table to the child, which we don't want.
1610
- display: block !important;
1611
- }
1612
- }
1613
- `,aJ=$.forwardRef((t,e)=>p.jsx(lJ,{ref:e,padding:4,paddingLeft:5,paddingRight:5,background:"neutral100",justifyContent:"space-between",...t,tag:"footer"})),lJ=k.styled(he)`
1614
- border-top: solid 1px ${t=>t.theme.colors.neutral150};
1615
- flex: 1;
1616
- `,cJ=Object.freeze(Object.defineProperty({__proto__:null,Body:oJ,Close:w$,Content:JQ,Footer:aJ,Header:nJ,Root:ZQ,Title:iJ,Trigger:QQ},Symbol.toStringTag,{value:"Module"})),uJ="";$.forwardRef(({startAction:t,locale:e,onValueChange:n,value:r,step:i=1,disabled:o=!1,...s},a)=>{const c=Vh("NumberInput"),h=e||c.locale,f=$.useRef(new cC(h,{style:"decimal"})),d=$.useRef(new lC(h,{maximumFractionDigits:20})),[m,v]=hJ({prop(L){const I=String(r);return isNaN(Number(I))||I!==L&&L!==""?L:d.current.format(Number(r))},defaultProp:uJ,onChange(L){const I=f.current.parse(L??"");n(isNaN(I)?void 0:I)}}),w=L=>{v(String(L))},x=({target:{value:L}})=>{f.current.isValidPartialNumber(L)&&w(L)},S=(L=>{const I=L.toString();return I.includes(".")?I.split(".")[1].length:0})(i),A=()=>{if(!m){w(i);return}const L=f.current.parse(m),I=isNaN(L)?i:L+i,V=parseFloat(I.toFixed(S));w(d.current.format(V))},T=()=>{if(!m){w(-i);return}const L=f.current.parse(m),I=isNaN(L)?-i:L-i,V=parseFloat(I.toFixed(S));w(d.current.format(V))},O=L=>{if(!o)switch(L.key){case Rt.DOWN:{L.preventDefault(),T();break}case Rt.UP:{L.preventDefault(),A();break}}},D=()=>{if(m){const L=f.current.parse(m),I=isNaN(L)?"":d.current.format(L);w(I)}};return p.jsx(Fh,{ref:a,startAction:t,disabled:o,type:"text",inputMode:"decimal",onChange:x,onKeyDown:O,onBlur:D,value:m,endAction:p.jsxs(he,{direction:"column",children:[p.jsx(pw,{disabled:o,"aria-hidden":!0,$reverse:!0,onClick:A,tabIndex:-1,type:"button","data-testid":"ArrowUp",children:p.jsx(Mi,{fill:"neutral500"})}),p.jsx(pw,{disabled:o,"aria-hidden":!0,onClick:T,tabIndex:-1,type:"button","data-testid":"ArrowDown",children:p.jsx(Mi,{fill:"neutral500"})})]}),...s})});const pw=k.styled.button`
1617
- display: flex;
1618
- justify-content: center;
1619
- align-items: center;
1620
- transform: translateY(${({$reverse:t})=>t?"-2px":"2px"});
1621
- cursor: ${({disabled:t})=>t?"not-allowed":void 0};
1622
- height: 1.1rem;
1623
-
1624
- svg {
1625
- width: 1.2rem;
1626
- transform: ${({$reverse:t})=>t?"rotateX(180deg)":void 0};
1627
- }
1628
- `;function hJ({prop:t,defaultProp:e,onChange:n=()=>{}}){const[r,i]=BC({defaultProp:e,onChange:n}),o=t!==void 0,s=t instanceof Function?t(r):t,a=o?s:r,c=pg(n),h=$.useCallback(f=>{if(o){const m=typeof f=="function"?f(s):f;m!==s&&(c(m),i(f))}else i(f)},[o,s,i,c]);return[a,h]}const fJ=$.createContext({activePage:1,pageCount:1}),Hm=()=>$.useContext(fJ);nn(({children:t,...e},n)=>{const{activePage:r}=Hm(),i=r===1;return p.jsxs(y$,{ref:n,"aria-disabled":i,tabIndex:i?-1:void 0,...e,children:[p.jsx(ko,{children:t}),p.jsx(c3,{"aria-hidden":!0})]})});nn(({children:t,...e},n)=>{const{activePage:r,pageCount:i}=Hm(),o=r===i;return p.jsxs(y$,{ref:n,"aria-disabled":o,tabIndex:o?-1:void 0,...e,children:[p.jsx(ko,{children:t}),p.jsx(Vg,{"aria-hidden":!0})]})});const x$=k.styled(bl)`
1629
- padding: ${({theme:t})=>t.spaces[3]};
1630
- border-radius: ${({theme:t})=>t.borderRadius};
1631
- box-shadow: ${({$active:t,theme:e})=>t?e.shadows.filterShadow:void 0};
1632
- text-decoration: none;
1633
- display: flex;
1634
-
1635
- ${Lh}
1636
- `,y$=k.styled(x$)`
1637
- font-size: 1.1rem;
1638
-
1639
- svg path {
1640
- fill: ${t=>t["aria-disabled"]?t.theme.colors.neutral300:t.theme.colors.neutral600};
1641
- }
1642
-
1643
- &:focus,
1644
- &:hover {
1645
- svg path {
1646
- fill: ${t=>t["aria-disabled"]?t.theme.colors.neutral300:t.theme.colors.neutral700};
1647
- }
1648
- }
1649
-
1650
- ${t=>t["aria-disabled"]?`
1651
- pointer-events: none;
1652
- `:void 0}
1653
- `;nn(({number:t,children:e,...n},r)=>{const{activePage:i}=Hm(),o=i===t;return p.jsxs(dJ,{ref:r,...n,"aria-current":o,$active:o,children:[p.jsx(ko,{children:e}),p.jsx(Re,{"aria-hidden":!0,fontWeight:o?"bold":void 0,lineHeight:"revert",variant:"pi",children:t})]})});const dJ=k.styled(x$)`
1654
- color: ${({theme:t,$active:e})=>e?t.colors.primary700:t.colors.neutral800};
1655
- background: ${({theme:t,$active:e})=>e?t.colors.neutral0:void 0};
1656
-
1657
- &:hover {
1658
- box-shadow: ${({theme:t})=>t.shadows.filterShadow};
1659
- }
1660
- `,gJ=MG,mJ=$.forwardRef((t,e)=>p.jsx(EG,{...t,asChild:!0,ref:e})),pJ=$.forwardRef((t,e)=>p.jsx(OG,{children:p.jsx(vJ,{sideOffset:4,side:"bottom",align:"start",...t,ref:e})})),vJ=k.styled(DG)`
1661
- box-shadow: ${({theme:t})=>t.shadows.filterShadow};
1662
- z-index: ${({theme:t})=>t.zIndices.popover};
1663
- background-color: ${t=>t.theme.colors.neutral0};
1664
- border: 1px solid ${({theme:t})=>t.colors.neutral150};
1665
- border-radius: ${({theme:t})=>t.borderRadius};
1666
-
1667
- @media (prefers-reduced-motion: no-preference) {
1668
- animation-duration: ${t=>t.theme.motion.timings[200]};
1669
-
1670
- &[data-state='open'] {
1671
- animation-timing-function: ${t=>t.theme.motion.easings.authenticMotion};
1672
-
1673
- &[data-side='top'] {
1674
- animation-name: ${pt.slideUpIn};
1675
- }
1676
-
1677
- &[data-side='bottom'] {
1678
- animation-name: ${pt.slideDownIn};
1679
- }
1680
- }
1681
-
1682
- &[data-state='closed'] {
1683
- animation-timing-function: ${t=>t.theme.motion.easings.easeOutQuad};
1684
-
1685
- &[data-side='top'] {
1686
- animation-name: ${pt.slideUpOut};
1687
- }
1688
-
1689
- &[data-side='bottom'] {
1690
- animation-name: ${pt.slideDownOut};
1691
- }
1692
- }
1693
- }
1694
- `,bJ=$.forwardRef(({children:t,intersectionId:e,onReachEnd:n,...r},i)=>{const o=$.useRef(null),s=gn(o,i),a=Tn();return wl(o,n??(()=>{}),{selectorToWatch:`#${Ms(a)}`,skipWhen:!e||!n}),p.jsxs(wJ,{ref:s,...r,children:[t,e&&n&&p.jsx(be,{id:Ms(a),width:"100%",height:"1px"})]})}),wJ=k.styled(Fm)`
1695
- height: 20rem;
1696
- `,xJ=Object.freeze(Object.defineProperty({__proto__:null,Content:pJ,Root:gJ,ScrollArea:bJ,Trigger:mJ},Symbol.toStringTag,{value:"Module"}));$.forwardRef(({size:t="M",value:e,...n},r)=>p.jsx(yJ,{ref:r,$size:t,...n,children:p.jsx(CJ,{style:{transform:`translate3D(-${100-(e??0)}%, 0, 0)`}})}));const yJ=k.styled(HG)`
1697
- position: relative;
1698
- overflow: hidden;
1699
- width: ${t=>t.$size==="S"?"7.8rem":"10.2rem"};
1700
- height: ${t=>t.$size==="S"?"0.4rem":"0.8rem"};
1701
- background-color: ${t=>t.theme.colors.neutral600};
1702
- border-radius: ${t=>t.theme.borderRadius};
1703
-
1704
- /* Fix overflow clipping in Safari */
1705
- /* https://gist.github.com/domske/b66047671c780a238b51c51ffde8d3a0 */
1706
- transform: translateZ(0);
1707
- `,CJ=k.styled(PG)`
1708
- background-color: ${({theme:t})=>t.colors.neutral0};
1709
- border-radius: ${({theme:t})=>t.borderRadius};
1710
- width: 100%;
1711
- height: 100%;
1712
-
1713
- @media (prefers-reduced-motion: no-preference) {
1714
- transition: transform ${t=>t.theme.motion.timings[320]}
1715
- ${t=>t.theme.motion.easings.authenticMotion};
1716
- }
1717
- `;$.forwardRef((t,e)=>p.jsx($J,{ref:e,...t}));const $J=k.styled(iY)`
1718
- display: flex;
1719
- flex-direction: column;
1720
- gap: ${t=>t.theme.spaces[3]};
1721
- `;$.forwardRef(({children:t,id:e,...n},r)=>{const i=Tn(e);return p.jsxs(he,{gap:2,children:[p.jsx(SJ,{id:i,ref:r,...n,children:p.jsx(AJ,{})}),p.jsx(Re,{tag:"label",htmlFor:i,children:t})]})});const SJ=k.styled(oY)`
1722
- background: ${t=>t.theme.colors.neutral0};
1723
- width: 2rem;
1724
- height: 2rem;
1725
- flex: 0 0 2rem;
1726
- border-radius: 50%;
1727
- border: 1px solid ${t=>t.theme.colors.neutral300};
1728
- position: relative;
1729
- z-index: 0;
1730
-
1731
- @media (prefers-reduced-motion: no-preference) {
1732
- transition: border-color ${t=>t.theme.motion.timings[120]}
1733
- ${t=>t.theme.motion.easings.easeOutQuad};
1734
- }
1735
-
1736
- &[data-state='checked'] {
1737
- border: 1px solid ${t=>t.theme.colors.primary600};
1738
- }
1739
-
1740
- &[data-disabled] {
1741
- background-color: ${t=>t.theme.colors.neutral200};
1742
- }
1743
-
1744
- /* increase target size for touch devices https://www.w3.org/WAI/WCAG21/Understanding/target-size.html */
1745
- &::before {
1746
- content: '';
1747
- position: absolute;
1748
- top: 50%;
1749
- left: 50%;
1750
- transform: translate(-50%, -50%);
1751
- width: 100%;
1752
- height: 100%;
1753
- min-width: 44px;
1754
- min-height: 44px;
1755
- }
1756
- `,AJ=k.styled(sY)`
1757
- display: flex;
1758
- align-items: center;
1759
- justify-content: center;
1760
- width: 100%;
1761
- height: 100%;
1762
- position: relative;
1763
-
1764
- &[data-state='checked'] {
1765
- @media (prefers-reduced-motion: no-preference) {
1766
- animation: ${pt.popIn} ${t=>t.theme.motion.timings[200]};
1767
- }
1768
- }
1769
-
1770
- &::after {
1771
- content: '';
1772
- display: block;
1773
- width: 1rem;
1774
- height: 1rem;
1775
- border-radius: 50%;
1776
- background: ${t=>t.theme.colors.primary600};
1777
- }
1778
- `,RJ=t=>{const e=t.querySelector('[tabindex="0"]');e&&e.focus()},C$=$.createContext({rowIndex:0,colIndex:0,setTableValues(){throw new Error("setTableValues must be initialized via the RawTableContext.Provider")}}),kJ=()=>$.useContext(C$),TJ=$.forwardRef(({colCount:t,rowCount:e,jumpStep:n=3,initialCol:r=0,initialRow:i=0,...o},s)=>{const a=$.useRef(null),c=$.useRef(!1),h=gn(a,s),[f,d]=$.useState(i),[m,v]=$.useState(r),w=$.useCallback(({colIndex:S,rowIndex:A})=>{v(S),d(A)},[]);$.useEffect(()=>{c.current&&RJ(a.current),c.current||(c.current=!0)},[m,f]);const x=S=>{switch(S.key){case Rt.RIGHT:{S.preventDefault(),v(A=>A<t-1?A+1:A);break}case Rt.LEFT:{S.preventDefault(),v(A=>A>0?A-1:A);break}case Rt.UP:{S.preventDefault(),d(A=>A>0?A-1:A);break}case Rt.DOWN:{S.preventDefault(),d(A=>A<e-1?A+1:A);break}case Rt.HOME:{S.preventDefault(),S.ctrlKey&&d(0),v(0);break}case Rt.END:{S.preventDefault(),S.ctrlKey&&d(e-1),v(t-1);break}case Rt.PAGE_DOWN:{S.preventDefault(),d(A=>A+n<e?A+n:e-1);break}case Rt.PAGE_UP:{S.preventDefault(),d(A=>A-n>0?A-n:0);break}}},C=$.useMemo(()=>({rowIndex:f,colIndex:m,setTableValues:w}),[m,f,w]);return p.jsx(C$.Provider,{value:C,children:p.jsx("table",{role:"grid",ref:h,"aria-rowcount":e,"aria-colcount":t,onKeyDown:x,...o})})}),no=(t,e)=>[...t.querySelectorAll('a, button, input, textarea, select, details, [tabindex]:not([tabindex="-1"])')].filter(i=>i.hasAttribute("disabled")?!1:e?!0:i.getAttribute("tabindex")!=="-1"),o0=t=>t.filter(e=>e.tagName==="INPUT"?e.type!=="checkbox"&&e.type!=="radio":!1),$$=$.forwardRef(({coords:t={col:0,row:0},tag:e="td",...n},r)=>{const i=$.useRef(null),o=gn(r,i),{rowIndex:s,colIndex:a,setTableValues:c}=kJ(),[h,f]=$.useState(!1),d=w=>{const x=no(i.current,!0);if(x.length===0||x.length===1&&o0(x).length===0)return;if(x.length>1&&!x.find(S=>S.tagName!=="BUTTON")){w.preventDefault();const S=x.findIndex(A=>A===document.activeElement);if(w.key===Rt.RIGHT){const A=x[S+1];A&&(w.stopPropagation(),A.focus())}else if(w.key===Rt.LEFT){const A=x[S-1];A&&(w.stopPropagation(),A.focus())}return}const C=w.key===Rt.ENTER;if(C&&!h)f(!0);else if((w.key===Rt.ESCAPE||C)&&h){if(C&&document.activeElement?.tagName==="A")return;f(!1),i.current.focus()}else h&&w.stopPropagation()},m=s===t.row-1&&a===t.col-1;wo(()=>{const w=no(i.current,!0);w.length===0||w.length===1&&o0(w).length!==0||w.length>1&&w.find(x=>x.tagName!=="BUTTON")?(i.current.setAttribute("tabIndex",!h&&m?"0":"-1"),w.forEach((x,C)=>{x.setAttribute("tabIndex",h?"0":"-1"),h&&C===0&&x.focus()})):w.forEach(x=>{x.setAttribute("tabIndex",m?"0":"-1")})},[h,m]);const v=$.useCallback(()=>{const w=no(i.current,!0);w.length>=1&&(o0(w).length!==0||!w.find(x=>x.tagName!=="BUTTON"))&&f(!0),c({rowIndex:t.row-1,colIndex:t.col-1})},[t,c]);return wo(()=>{const w=i.current;return no(w,!0).forEach(C=>{C.addEventListener("focus",v)}),()=>{no(w,!0).forEach(S=>{S.removeEventListener("focus",v)})}},[v]),p.jsx(be,{role:"gridcell",tag:e,ref:o,onKeyDown:d,...n})}),MJ=t=>p.jsx($$,{...t,tag:"th"}),EJ=({children:t,...e})=>{const n=$.Children.toArray(t).map(r=>$.isValidElement(r)?$.cloneElement(r,{"aria-rowindex":1}):r);return p.jsx("thead",{...e,children:n})},OJ=({children:t,...e})=>{const n=$.Children.toArray(t).map((r,i)=>$.isValidElement(r)?$.cloneElement(r,{"aria-rowindex":i+2}):r);return p.jsx("tbody",{...e,children:n})},DJ=({children:t,...e})=>{const n=$.Children.toArray(t).map((r,i)=>$.isValidElement(r)?$.cloneElement(r,{"aria-colindex":i+1,coords:{col:i+1,row:e["aria-rowindex"]}}):r);return p.jsx(be,{tag:"tr",...e,children:n})},IJ=k.styled(ji)`
1779
- font-size: 0.5rem;
1780
- path {
1781
- fill: ${({theme:t})=>t.colors.neutral500};
1782
- }
1783
- `,S$=k.styled(h3)`
1784
- font-size: 1rem;
1785
- path {
1786
- fill: ${({theme:t})=>t.colors.neutral500};
1787
- }
1788
- `,_J=k.styled.div`
1789
- border-radius: ${({theme:t})=>t.borderRadius};
1790
- border: 1px solid ${({theme:t})=>t.colors.neutral150}
1791
-
1792
- &:focus-within {
1793
- ${S$} {
1794
- fill: ${({theme:t})=>t.colors.primary600};
1795
- }
1796
- }
1797
- `,LJ=k.styled(Fh)`
1798
- border: 1px solid ${({theme:t})=>t.colors.neutral150}
1799
- height: 16px;
1800
- padding: 0 0 0 8px;
1801
- color: ${({theme:t})=>t.colors.neutral800};
1802
-
1803
- &::placeholder {
1804
- color: ${({theme:t})=>t.colors.neutral500};
1805
- }
1806
-
1807
- &:hover {
1808
- button {
1809
- cursor: pointer;
1810
- }
1811
- }
1812
-
1813
- ${Vi()}
1814
- `,BJ=$.forwardRef(({name:t,children:e,value:n="",onClear:r,clearLabel:i,...o},s)=>{const a=$.useRef(null),c=n.length>0,h=d=>{r(d),a.current.focus()},f=VC(s,a);return p.jsx(_J,{children:p.jsxs(xo,{name:t,children:[p.jsx(ko,{children:p.jsx(Nm,{children:e})}),p.jsx(LJ,{size:"S",ref:f,value:n,startAction:p.jsx(S$,{"aria-hidden":!0}),endAction:c?p.jsx(r$,{label:i,onClick:h,onMouseDown:d=>{d.preventDefault()},children:p.jsx(IJ,{})}):void 0,...o})]})})}),NJ=t=>p.jsx("form",{...t,role:"search"}),jJ=k.styled(be)`
1815
- display: inline-flex;
1816
- border: none;
1817
-
1818
- & > svg {
1819
- height: 1.2rem;
1820
- width: 1.2rem;
1821
- }
1822
-
1823
- & > svg path {
1824
- fill: ${({theme:t,...e})=>e["aria-disabled"]?t.colors.neutral600:t.colors.primary600};
1825
- }
1826
-
1827
- &:hover {
1828
- cursor: ${({$iconAction:t})=>t?"pointer":"initial"};
1829
- }
1830
- `,FJ=({children:t,icon:e,label:n,disabled:r=!1,onClick:i,...o})=>{const s=a=>{r||!i||i(a)};return p.jsxs(he,{inline:!0,background:r?"neutral200":"primary100",color:r?"neutral700":"primary600",paddingLeft:3,paddingRight:1,borderColor:r?"neutral300":"primary200",hasRadius:!0,height:"3.2rem",...o,children:[p.jsx(VJ,{$disabled:r,variant:"pi",fontWeight:"bold",children:t}),p.jsx(jJ,{tag:"button",disabled:r,"aria-disabled":r,"aria-label":n,padding:2,onClick:s,$iconAction:!!i,children:e})]})},VJ=k.styled(Re)`
1831
- color: inherit;
1832
- border-right: 1px solid ${({theme:t,$disabled:e})=>e?t.colors.neutral300:t.colors.primary200};
1833
- padding-right: ${({theme:t})=>t.spaces[2]};
1834
- `,HJ=$.forwardRef(({children:t,clearLabel:e="Clear",customizeContent:n,disabled:r,hasError:i,id:o,name:s,onChange:a,onClear:c,onCloseAutoFocus:h,onReachEnd:f,placeholder:d,required:m,size:v,startIcon:w,value:x,withTags:C,...S},A)=>{const T=$.useRef(null),[O,D]=$.useState(),[L,I]=$.useState(!1),V=we=>{a?a(we):D(we)},F=we=>()=>{const Ve=Array.isArray(x)?x.filter(Ne=>Ne!==we):(O??[]).filter(Ne=>Ne!==we);a?a(Ve):D(Ve)},H=we=>{I(we)},K=Tn(),W=`intersection-${Ms(K)}`;wl(T,we=>{f&&f(we)},{selectorToWatch:`#${W}`,skipWhen:!L});const G=typeof x<"u"&&x!==null?x:O,re=we=>we&&typeof we=="object"&&we.value?p.jsx(FJ,{tabIndex:-1,disabled:r,icon:p.jsx(ji,{width:`${14/16}rem`,height:`${14/16}rem`}),onClick:F(we.value),children:we.textValue},we.value):null,{error:oe,...te}=mn("MultiSelect"),ie=!!oe||i,Y=te.id??o,ue=te.name??s,ge=te.required??m;let De;return oe?De=`${Y}-error`:te.hint&&(De=`${Y}-hint`),p.jsxs(a$,{onOpenChange:H,disabled:r,required:ge,onValueChange:V,value:G,...S,multi:!0,children:[p.jsx(l$,{ref:A,id:Y,name:ue,"aria-label":S["aria-label"],"aria-describedby":De??S["aria-describedby"],startIcon:w,hasError:ie,disabled:r,clearLabel:e,onClear:G?.length?c:void 0,withTags:!!(C&&(G?.length??!1)),size:v,children:p.jsx(c$,{placeholder:d,textColor:G?.length?"neutral800":"neutral600",children:G?.length?C?re:n?n(G):void 0:void 0})}),p.jsx(u$,{children:p.jsx(h$,{position:"popper",sideOffset:4,onCloseAutoFocus:h,children:p.jsxs(f$,{ref:T,children:[t,p.jsx(be,{id:W,width:"100%",height:"1px"})]})})})]})}),A$=$.forwardRef(({value:t,children:e,startIcon:n,...r},i)=>p.jsxs(Vm,{ref:i,value:t.toString(),...r,children:[n&&p.jsx(be,{tag:"span","aria-hidden":!0,children:n}),p.jsx(d$,{children:({isSelected:o,isIntermediate:s})=>p.jsx(jh,{checked:s?"indeterminate":o})}),p.jsx(Re,{children:p.jsx(g$,{children:e})})]}));$.forwardRef(({children:t,label:e,startIcon:n,values:r=[],...i},o)=>p.jsxs(pQ,{ref:o,children:[p.jsxs(Vm,{value:r,...i,children:[n&&p.jsx(be,{tag:"span","aria-hidden":!0,children:n}),p.jsx(d$,{children:({isSelected:s,isIntermediate:a})=>p.jsx(jh,{checked:a?"indeterminate":s})}),p.jsx(Re,{children:e})]}),t]}));k.styled(A$)`
1835
- padding-left: ${({theme:t})=>t.spaces[7]};
1836
- `;const PJ="23.2rem",WJ=$.forwardRef(({...t},e)=>p.jsx(zJ,{ref:e,...t,tag:"nav"})),zJ=k.styled(be)`
1837
- width: ${PJ};
1838
- background: ${({theme:t})=>t.colors.neutral100};
1839
- position: sticky;
1840
- top: 0;
1841
- height: 100vh;
1842
- overflow-y: auto;
1843
- border-right: 1px solid ${({theme:t})=>t.colors.neutral200};
1844
- z-index: 1;
1845
- `,vw=k.styled(p$)`
1846
- width: 2.4rem;
1847
- background-color: ${({theme:t})=>t.colors.neutral200};
1848
- `,UJ=({tag:t="h2",label:e,searchLabel:n="",searchable:r=!1,onChange:i=()=>{},value:o="",onClear:s=()=>{},onSubmit:a=()=>{},id:c,placeholder:h})=>{const[f,d]=$.useState(!1),m=$x(f),v=Tn(c),w=$.useRef(void 0),x=$.useRef(void 0);$.useEffect(()=>{f&&w.current&&w.current.focus(),m&&!f&&x.current&&x.current.focus()},[f,m]);const C=()=>{d(O=>!O)},S=O=>{s(O),w.current.focus()},A=O=>{O.relatedTarget?.id!==v&&d(!1)},T=O=>{O.key===Rt.ESCAPE&&d(!1)};return f?p.jsxs(be,{paddingLeft:4,paddingTop:5,paddingBottom:2,paddingRight:4,children:[p.jsx(NJ,{children:p.jsx(BJ,{name:"searchbar",value:o,onChange:i,placeholder:h,onKeyDown:T,ref:w,onBlur:A,onClear:S,onSubmit:a,clearLabel:"Clear",children:n})}),p.jsx(be,{paddingLeft:2,paddingTop:4,children:p.jsx(vw,{})})]}):p.jsxs(he,{direction:"column",alignItems:"flex-start",paddingLeft:6,paddingTop:6,paddingBottom:2,paddingRight:4,children:[p.jsxs(he,{justifyContent:"space-between",alignItems:"flex-start",width:"100%",gap:2,children:[p.jsx(Re,{variant:"beta",tag:t,children:e}),r&&p.jsx(Xa,{ref:x,onClick:C,label:n,children:p.jsx(h3,{})})]}),p.jsx(be,{paddingTop:4,children:p.jsx(vw,{})})]})},qJ=nn(({active:t,children:e,icon:n=null,withBullet:r=!1,isSubSectionChild:i=!1,...o},s)=>p.jsxs(KJ,{background:"neutral100",paddingLeft:i?9:7,paddingBottom:2,paddingTop:2,ref:s,...o,children:[p.jsxs(he,{children:[n?p.jsx(GJ,{children:n}):p.jsx(F1,{$active:t}),p.jsx(Re,{paddingLeft:2,children:e})]}),r&&p.jsx(he,{paddingRight:4,children:p.jsx(F1,{$active:!0})})]})),F1=k.styled.span`
1849
- width: 0.4rem;
1850
- height: 0.4rem;
1851
- background-color: ${({theme:t,$active:e})=>e?t.colors.primary600:t.colors.neutral600};
1852
- border-radius: 50%;
1853
- `,KJ=k.styled(bl)`
1854
- display: flex;
1855
- align-items: center;
1856
- justify-content: space-between;
1857
- text-decoration: none;
1858
- color: ${({theme:t})=>t.colors.neutral800};
1859
- svg > * {
1860
- fill: ${({theme:t})=>t.colors.neutral600};
1861
- }
1862
-
1863
- &.active {
1864
- ${({theme:t})=>k.css`
1865
- background-color: ${t.colors.primary100};
1866
- border-right: 2px solid ${t.colors.primary600};
1867
- color: ${t.colors.primary700};
1868
- font-weight: 500;
1869
- `}
1870
-
1871
- ${F1} {
1872
- background-color: ${({theme:t})=>t.colors.primary600};
1873
- }
1874
- }
1875
-
1876
- &:focus-visible {
1877
- outline-offset: -2px;
1878
- }
1879
- `,GJ=k.styled.div`
1880
- svg {
1881
- height: 1.6rem;
1882
- width: 1.6rem;
1883
- }
1884
- `;k.styled.button`
1885
- border: none;
1886
- padding: 0;
1887
- background: transparent;
1888
- display: flex;
1889
- align-items: center;
1890
- `;const YJ=({collapsable:t=!1,label:e,onClick:n=()=>{},ariaExpanded:r,ariaControls:i})=>t?p.jsxs(he,{tag:"button",onClick:n,"aria-expanded":r,"aria-controls":i,textAlign:"left",alignItems:"center",children:[p.jsx(be,{paddingRight:1,children:p.jsx(Re,{variant:"sigma",textColor:"neutral600",children:e})}),t&&p.jsx(Mi,{width:"1.2rem","aria-hidden":!0,fill:"neutral500",style:{transform:r?"rotateX(0deg)":"rotateX(180deg)"}})]}):p.jsx(he,{children:p.jsx(be,{paddingRight:1,children:p.jsx(Re,{variant:"sigma",textColor:"neutral600",children:e})})}),XJ=k.styled(be)`
1891
- & > svg {
1892
- height: 0.4rem;
1893
- fill: ${({theme:t})=>t.colors.neutral500};
1894
- }
1895
- `,ZJ=({collapsable:t=!1,label:e,badgeLabel:n,children:r,id:i})=>{const[o,s]=$.useState(!0),a=Tn(i),c=()=>{s(h=>!h)};return p.jsxs(he,{direction:"column",alignItems:"stretch",gap:1,children:[p.jsx(XJ,{paddingLeft:6,paddingTop:2,paddingBottom:2,paddingRight:4,children:p.jsxs(be,{position:"relative",paddingRight:n?6:0,children:[p.jsx(YJ,{onClick:c,ariaExpanded:o,ariaControls:a,collapsable:t,label:e}),n&&p.jsx(Dm,{backgroundColor:"neutral150",textColor:"neutral600",position:"absolute",right:0,top:"50%",transform:"translateY(-50%)",children:n})]})}),(!t||o)&&p.jsx("ol",{id:a,children:$.Children.map(r,(h,f)=>p.jsx("li",{children:h},f))})]})},QJ=({children:t,spacing:e=2,horizontal:n=!1,...r})=>p.jsx(be,{paddingTop:2,paddingBottom:4,children:p.jsx(he,{tag:"ol",gap:e,direction:n?"row":"column",alignItems:n?"center":"stretch",...r,children:$.Children.map(t,(i,o)=>p.jsx("li",{children:i},o))})}),JJ=$.forwardRef(({visibleLabels:t,onLabel:e="On",offLabel:n="Off",onCheckedChange:r,checked:i,defaultChecked:o,disabled:s,...a},c)=>{const[h,f]=yr({prop:i,defaultProp:o}),d=m=>{f(m)};return p.jsxs(he,{gap:3,children:[p.jsx(eee,{ref:c,onCheckedChange:oo(r,d),checked:h,disabled:s,...a,children:p.jsx(tee,{})}),t?p.jsx(nee,{"aria-hidden":!0,"data-disabled":s,"data-state":h?"checked":"unchecked",children:h?e:n}):null]})}),eee=k.styled(gY)`
1896
- width: 4rem;
1897
- height: 2.4rem;
1898
- border-radius: 1.2rem;
1899
- background-color: ${({theme:t})=>t.colors.danger500};
1900
-
1901
- &[data-state='checked'] {
1902
- background-color: ${({theme:t})=>t.colors.success500};
1903
- }
1904
-
1905
- &[data-disabled] {
1906
- background-color: ${({theme:t})=>t.colors.neutral300};
1907
- }
1908
-
1909
- @media (prefers-reduced-motion: no-preference) {
1910
- transition: ${t=>t.theme.transitions.backgroundColor};
1911
- }
1912
- `,tee=k.styled(mY)`
1913
- display: block;
1914
- height: 1.6rem;
1915
- width: 1.6rem;
1916
- border-radius: 50%;
1917
- background-color: ${({theme:t})=>t.colors.neutral0};
1918
- transform: translateX(4px);
1919
-
1920
- &[data-state='checked'] {
1921
- transform: translateX(20px);
1922
- }
1923
-
1924
- @media (prefers-reduced-motion: no-preference) {
1925
- transition: transform ${t=>t.theme.motion.timings[120]}
1926
- ${t=>t.theme.motion.easings.authenticMotion};
1927
- }
1928
- `,nee=k.styled(Re)`
1929
- color: ${t=>t.theme.colors.danger600};
1930
-
1931
- &[data-state='checked'] {
1932
- color: ${t=>t.theme.colors.success600};
1933
- }
1934
-
1935
- &[data-disabled='true'] {
1936
- color: ${({theme:t})=>t.colors.neutral500};
1937
- }
1938
- `,[ree,Pm]=vl("Tabs");$.forwardRef(({disabled:t=!1,variant:e="regular",hasError:n,...r},i)=>p.jsx(ree,{disabled:t,hasError:n,variant:e,children:p.jsx(iee,{ref:i,...r})}));const iee=k.styled(AY)`
1939
- width: 100%;
1940
- position: relative;
1941
- `;$.forwardRef((t,e)=>{const{variant:n}=Pm("List");return p.jsx(oee,{ref:e,...t,$variant:n})});const oee=k.styled(RY)`
1942
- display: flex;
1943
- align-items: ${t=>t.$variant==="regular"?"flex-end":"unset"};
1944
- position: relative;
1945
- z-index: 0;
1946
- `;$.forwardRef(({children:t,disabled:e,...n},r)=>{const{disabled:i,variant:o,hasError:s}=Pm("Trigger"),a=i===!0||i===n.value||e,c=s===n.value;return p.jsxs(see,{ref:r,...n,$hasError:c,$variant:o,disabled:a,children:[p.jsx(k$,{fontWeight:"bold",variant:o==="simple"?"sigma":void 0,children:t}),o==="simple"?p.jsx(R$,{}):null]})});const R$=k.styled.span`
1947
- display: block;
1948
- width: 100%;
1949
- background-color: currentColor;
1950
- position: absolute;
1951
- bottom: 0;
1952
- left: 0;
1953
- opacity: 0;
1954
- height: 0.2rem;
1955
- `,k$=k.styled(Re)``,see=k.styled(kY)`
1956
- position: relative;
1957
- color: ${t=>t.$hasError?t.theme.colors.danger600:t.theme.colors.neutral600};
1958
- cursor: pointer;
1959
- z-index: 0;
1960
-
1961
- ${t=>t.$variant==="simple"?k.css`
1962
- padding-block: ${e=>e.theme.spaces[4]};
1963
- padding-inline: ${e=>e.theme.spaces[4]};
1964
-
1965
- & > ${k$} {
1966
- line-height: 1.2rem;
1967
- }
1968
-
1969
- &[data-state='active'] {
1970
- color: ${t.$hasError?t.theme.colors.danger600:t.theme.colors.primary700};
1971
-
1972
- & > ${R$} {
1973
- opacity: 1;
1974
- }
1975
- }
1976
- `:k.css`
1977
- padding-block: ${e=>e.theme.spaces[3]};
1978
- padding-inline: ${e=>e.theme.spaces[3]};
1979
- flex: 1;
1980
- background-color: ${e=>e.theme.colors.neutral100};
1981
- border-bottom: solid 1px ${e=>e.theme.colors.neutral150};
1982
-
1983
- &:not([data-state='active']) + &:not([data-state='active']) {
1984
- border-left: solid 1px ${e=>e.theme.colors.neutral150};
1985
- }
1986
-
1987
- &[data-state='active'] {
1988
- padding-block: ${e=>e.theme.spaces[4]};
1989
- padding-inline: ${e=>e.theme.spaces[4]};
1990
- color: ${t.$hasError?t.theme.colors.danger600:t.theme.colors.primary700};
1991
- border-top-right-radius: ${e=>e.theme.borderRadius};
1992
- border-top-left-radius: ${e=>e.theme.borderRadius};
1993
- background-color: ${e=>e.theme.colors.neutral0};
1994
- border-bottom: solid 1px ${e=>e.theme.colors.neutral0};
1995
- box-shadow: ${t.theme.shadows.tableShadow};
1996
- z-index: 1;
1997
- }
1998
- `}
1999
-
2000
- &[data-disabled] {
2001
- cursor: not-allowed;
2002
- color: ${t=>t.theme.colors.neutral400};
2003
- }
2004
- `;$.forwardRef((t,e)=>{const{variant:n}=Pm("Content");return p.jsx(aee,{$variant:n,ref:e,...t})});const aee=k.styled(TY)`
2005
- ${t=>t.$variant==="simple"?k.css``:k.css`
2006
- position: relative;
2007
- z-index: 1;
2008
- background-color: ${e=>e.theme.colors.neutral0};
2009
- `}
2010
- `,lee=k.styled(be)`
2011
- overflow: hidden;
2012
- border: 1px solid ${({theme:t})=>t.colors.neutral150};
2013
- `,cee=k.styled(TJ)`
2014
- width: 100%;
2015
- white-space: nowrap;
2016
- `,uee=k.styled(be)`
2017
- &:before {
2018
- // TODO: make sure to add a token for this weird stuff
2019
- background: linear-gradient(90deg, #c0c0cf 0%, rgba(0, 0, 0, 0) 100%);
2020
- opacity: 0.2;
2021
- position: absolute;
2022
- height: 100%;
2023
- content: ${({$overflowing:t})=>t==="both"||t==="left"?"''":void 0};
2024
- box-shadow: ${({theme:t})=>t.shadows.tableShadow};
2025
- width: ${({theme:t})=>t.spaces[2]};
2026
- left: 0;
2027
- }
2028
-
2029
- &:after {
2030
- // TODO: make sure to add a token for this weird stuff
2031
- background: linear-gradient(270deg, #c0c0cf 0%, rgba(0, 0, 0, 0) 100%);
2032
- opacity: 0.2;
2033
- position: absolute;
2034
- height: 100%;
2035
- content: ${({$overflowing:t})=>t==="both"||t==="right"?"''":void 0};
2036
- box-shadow: ${({theme:t})=>t.shadows.tableShadow};
2037
- width: ${({theme:t})=>t.spaces[2]};
2038
- right: 0;
2039
- top: 0;
2040
- }
2041
- `,hee=k.styled(be)`
2042
- overflow-x: auto;
2043
- `,fee=$.forwardRef(({footer:t,...e},n)=>{const r=$.useRef(null),[i,o]=$.useState(),s=a=>{const c=a.target.scrollWidth-a.target.clientWidth;if(a.target.scrollLeft===0){o("right");return}if(a.target.scrollLeft===c){o("left");return}a.target.scrollLeft>0&&o("both")};return $.useEffect(()=>{r.current.scrollWidth>r.current.clientWidth&&o("right")},[]),p.jsxs(lee,{shadow:"tableShadow",hasRadius:!0,background:"neutral0",children:[p.jsx(uee,{$overflowing:i,position:"relative",children:p.jsx(hee,{ref:r,onScroll:s,paddingLeft:6,paddingRight:6,children:p.jsx(cee,{ref:n,...e})})}),t]})}),dee=k.styled(OJ)`
2044
- & tr:last-of-type {
2045
- border-bottom: none;
2046
- }
2047
- `,gee=({children:t,...e})=>p.jsx(dee,{...e,children:t}),mee=k.styled(EJ)`
2048
- border-bottom: 1px solid ${({theme:t})=>t.colors.neutral150};
2049
- `,pee=({children:t,...e})=>p.jsx(mee,{...e,children:t}),vee=k.styled(DJ)`
2050
- border-bottom: 1px solid ${({theme:t})=>t.colors.neutral150};
2051
-
2052
- & td,
2053
- & th {
2054
- padding: ${({theme:t})=>t.spaces[4]};
2055
- }
2056
-
2057
- & td:first-of-type,
2058
- & th:first-of-type {
2059
- padding: 0 ${({theme:t})=>t.spaces[1]};
2060
- }
2061
-
2062
- // Resetting padding values and fixing a height
2063
- th {
2064
- padding-top: 0;
2065
- padding-bottom: 0;
2066
- height: 5.6rem;
2067
- }
2068
- `,bee=t=>p.jsx(vee,{...t}),T$=k.styled($$)`
2069
- vertical-align: middle;
2070
- text-align: left;
2071
- outline-offset: -4px;
2072
-
2073
- /**
2074
- * Hack to make sure the checkbox looks aligned
2075
- */
2076
- input {
2077
- vertical-align: sub;
2078
- }
2079
- `,wee=$.forwardRef(({children:t,action:e,...n},r)=>p.jsx(T$,{color:"neutral600",as:MJ,ref:r,...n,children:p.jsxs(he,{children:[t,e]})})),xee=$.forwardRef(({children:t,...e},n)=>p.jsx(T$,{color:"neutral800",ref:n,...e,children:t}));k.styled(be)`
2080
- height: 2.4rem;
2081
- width: 2.4rem;
2082
- border-radius: 50%;
2083
- display: flex;
2084
- justify-content: center;
2085
- align-items: center;
2086
-
2087
- svg {
2088
- height: 1rem;
2089
- width: 1rem;
2090
- }
2091
-
2092
- svg path {
2093
- fill: ${({theme:t})=>t.colors.primary600};
2094
- }
2095
- `;k.styled(be)`
2096
- border-radius: 0 0 ${({theme:t})=>t.borderRadius} ${({theme:t})=>t.borderRadius};
2097
- display: block;
2098
- width: 100%;
2099
- border: none;
2100
- `;nn(({children:t,startIcon:e,endIcon:n,disabled:r=!1,loading:i=!1,...o},s)=>{const a=r||i;return p.jsxs($ee,{ref:s,disabled:a,"aria-disabled":a,tag:"button",type:"button",gap:2,...o,children:[i?p.jsx(Cee,{"aria-hidden":!0,children:p.jsx(u3,{})}):e,p.jsx(Re,{variant:"pi",children:t}),n]})});const yee=k.keyframes`
2101
- from {
2102
- transform: rotate(0deg);
2103
- }
2104
- to {
2105
- transform: rotate(359deg);
2106
- }
2107
- `,Cee=k.styled.span`
2108
- display: flex;
2109
- animation: ${yee} 2s infinite linear;
2110
- will-change: transform;
2111
- `,$ee=k.styled(he)`
2112
- border: none;
2113
- background-color: transparent;
2114
- color: ${t=>t.theme.colors.primary600};
2115
- cursor: pointer;
2116
-
2117
- &[aria-disabled='true'] {
2118
- pointer-events: none;
2119
- color: ${t=>t.theme.colors.neutral600};
2120
- }
2121
-
2122
- ${Lh}
2123
- `,See=$.forwardRef((t,e)=>p.jsx(Fh,{ref:e,...t}));See.displayName="TextInput";$.forwardRef(({disabled:t,hasError:e,id:n,name:r,required:i,...o},s)=>{const{error:a,...c}=mn("Textarea"),h=!!a||e,f=c.id??n,d=c.name??r,m=c.required||i;let v;return a?v=`${f}-error`:c.hint&&(v=`${f}-hint`),p.jsx(Aee,{borderColor:h?"danger600":"neutral200",$hasError:h,hasRadius:!0,children:p.jsx(Ree,{"aria-invalid":h,"aria-required":m,tag:"textarea",background:t?"neutral150":"neutral0",color:t?"neutral600":"neutral800",disabled:t,fontSize:2,hasRadius:!0,ref:s,lineHeight:4,padding:4,width:"100%",height:"100%",id:f,name:d,"aria-describedby":v,...o})})});const Aee=k.styled(be)`
2124
- height: 10.5rem;
2125
- ${Vi()}
2126
- `,Ree=k.styled(be)`
2127
- border: none;
2128
- resize: none;
2129
-
2130
- ::placeholder {
2131
- color: ${({theme:t})=>t.colors.neutral500};
2132
- font-size: ${({theme:t})=>t.fontSizes[2]};
2133
- color: ${({theme:t})=>t.colors.neutral500};
2134
- opacity: 1;
2135
- }
2136
-
2137
- &:focus-within {
2138
- outline: none;
2139
- }
2140
- `,kee=$.forwardRef(({offLabel:t,onLabel:e,disabled:n,hasError:r,required:i,id:o,name:s,checked:a,onChange:c,...h},f)=>{const[d=!1,m]=yr({prop:a}),v=d!==null&&!d,{error:w,...x}=mn("Toggle"),C=!!w||r,S=x.id??o,A=x.name??s,T=x.required||i;let O;return w?O=`${S}-error`:x.hint&&(O=`${S}-hint`),p.jsxs(Tee,{position:"relative",hasRadius:!0,padding:1,background:n?"neutral150":"neutral100",borderStyle:"solid",borderWidth:"1px",borderColor:"neutral200",wrap:"wrap",cursor:n?"not-allowed":"pointer",$hasError:C,children:[p.jsx(bw,{hasRadius:!0,flex:"1 1 50%",paddingTop:2,paddingBottom:2,paddingLeft:3,paddingRight:3,justifyContent:"center",background:n&&v?"neutral200":v?"neutral0":"transparent",borderColor:n&&v?"neutral300":v?"neutral200":n?"neutral150":"neutral100",children:p.jsx(Re,{variant:"pi",fontWeight:"bold",textTransform:"uppercase",textColor:n?"neutral700":v?"danger700":"neutral600",children:t})}),p.jsx(bw,{hasRadius:!0,flex:"1 1 50%",paddingLeft:3,paddingRight:3,justifyContent:"center",background:n&&d?"neutral200":d?"neutral0":"transparent",borderColor:n&&d?"neutral300":d?"neutral200":n?"neutral150":"neutral100",children:p.jsx(Re,{variant:"pi",fontWeight:"bold",textTransform:"uppercase",textColor:n?"neutral700":d?"primary600":"neutral600",children:e})}),p.jsx(Mee,{...h,id:S,name:A,ref:f,onChange:D=>{m(D.currentTarget.checked),c?.(D)},type:"checkbox","aria-required":T,disabled:n,"aria-disabled":n,checked:!!d,"aria-describedby":O})]})}),Tee=k.styled(he)`
2141
- ${Vi()}
2142
- `,bw=k.styled(he)`
2143
- padding-block: 0.6rem;
2144
- `,Mee=k.styled.input`
2145
- height: 100%;
2146
- left: 0;
2147
- opacity: 0;
2148
- position: absolute;
2149
- top: 0;
2150
- z-index: 0;
2151
- width: 100%;
2152
- `,Eee=nn((t,e)=>{const{gap:n=0,gridCols:r=12,...i}=t;return p.jsx(Oee,{ref:e,$gap:n,$gridCols:r,...i})}),Oee=k.styled(be)`
2153
- display: grid;
2154
- grid-template-columns: repeat(${({$gridCols:t})=>t}, 1fr);
2155
- ${({theme:t,$gap:e})=>_h({gap:e},t)}
2156
- `,Dee=nn(({col:t,s:e,xs:n,m:r,...i},o)=>p.jsx(Iee,{ref:o,$col:t,$s:e,$xs:n,$m:r,...i})),Iee=k.styled(he)`
2157
- grid-column: span ${({$xs:t})=>t??12};
2158
- max-width: 100%;
2159
-
2160
- ${({theme:t})=>t.breakpoints.small} {
2161
- grid-column: span ${({$s:t,$xs:e})=>t??e??12};
2162
- }
2163
-
2164
- ${({theme:t})=>t.breakpoints.medium} {
2165
- grid-column: span ${({$m:t,$s:e,$xs:n})=>t??e??n??12};
2166
- }
2167
-
2168
- ${({theme:t})=>t.breakpoints.large} {
2169
- grid-column: span ${({$col:t,$m:e,$s:n,$xs:r})=>t??e??n??r??12};
2170
- }
2171
- `,_ee=Object.freeze(Object.defineProperty({__proto__:null,Item:Dee,Root:Eee},Symbol.toStringTag,{value:"Module"})),Lee=({onEscape:t,restoreFocus:e=!0,skipAutoFocus:n=!1,...r})=>{const i=$.useRef(null);$.useEffect(()=>{let s=null;return e&&(s=document.activeElement),()=>{s&&s.focus()}},[e]),$.useEffect(()=>{if(!i.current||n)return;const s=no(i.current);s.length>0?s[0].focus():console.warn("[FocusTrap]: it seems there are no focusable elements in the focus trap tree. Make sure there s at least one.")},[n]);const o=s=>{if(s.key===Rt.ESCAPE&&t){t();return}if(s.key!==Rt.TAB)return;const a=no(i.current);if(a.length>0){const c=a[0],h=a[a.length-1];s.shiftKey?c===document.activeElement&&(s.preventDefault(),h.focus()):h===document.activeElement&&(s.preventDefault(),c.focus())}};return p.jsx("div",{ref:i,onKeyDown:o,...r})};k.styled(he)`
2172
- &>* {
2173
- width: 100%;
2174
- }
2175
- `;const Bee="strapi-plugin-comments",Nee={displayName:"Comments"},jee=576,Fee=({width:t=24,height:e=24})=>p.jsx("svg",{viewBox:`0 0 ${t} ${e}`,xmlns:"http://www.w3.org/2000/svg",height:`${e}px`,children:p.jsx("g",{style:{transform:`scale(${t/jee})`},fill:"currentColor",children:p.jsx("path",{d:"M416 192c0-88.4-93.1-160-208-160S0 103.6 0 192c0 34.3 14.1 65.9 38 92-13.4 30.2-35.5 54.2-35.8 54.5-2.2 2.3-2.8 5.7-1.5 8.7S4.8 352 8 352c36.6 0 66.9-12.3 88.7-25 32.2 15.7 70.3 25 111.3 25 114.9 0 208-71.6 208-160zm122 220c23.9-26 38-57.7 38-92 0-66.9-53.5-124.2-129.3-148.1.9 6.6 1.3 13.3 1.3 20.1 0 105.9-107.7 192-240 192-10.8 0-21.3-.8-31.7-1.9C207.8 439.6 281.8 480 368 480c41 0 79.1-9.2 111.3-25 21.8 12.7 52.1 25 88.7 25 3.2 0 6.1-1.9 7.3-4.8 1.3-2.9.7-6.3-1.5-8.7-.3-.3-22.4-24.2-35.8-54.5z"})})}),Vee=p.jsx(Fee,{}),Hee=()=>Vee,zt={render:t=>`plugin::comments.${t}`,comments:{read:"comments-read",moderate:"comments-moderate"},reports:{read:"reports-read",review:"reports-review"},settings:{read:"settings-read",change:"settings-change"}},V1={access:[{action:zt.render(zt.comments.read),subject:null},{action:zt.render(zt.reports.read),subject:null},{action:zt.render(zt.settings.read),subject:null}],moderate:[{action:zt.render(zt.comments.moderate),subject:null}],reports:[{action:zt.render(zt.reports.read),subject:null}],reportsReview:[{action:zt.render(zt.reports.review),subject:null}],settings:[{action:zt.render(zt.settings.read),subject:null}],settingsChange:[{action:zt.render(zt.settings.change),subject:null}]},Pr=Bee.replace(/^strapi-plugin-/i,""),ww={en:()=>Promise.resolve().then(()=>require("./en-CNvRvaLL.js")),fr:()=>Promise.resolve().then(()=>require("./fr-BIrOYxvf.js")),"pt-BR":()=>Promise.resolve().then(()=>require("./pt-BR-CLvbSGaH.js")),tr:()=>Promise.resolve().then(()=>require("./tr-BX-_IBUR.js")),ru:()=>Promise.resolve().then(()=>require("./ru-eLIDfsd3.js")),"zh-Hans":()=>Promise.resolve().then(()=>require("./zh-Hans-DusBjCtd.js")),pl:()=>Promise.resolve().then(()=>require("./pl-DoXe0BV9.js"))},{displayName:xw}=Nee,Pee={register(t){t.addMenuLink({to:`/plugins/${Pr}`,badgeContent:1,icon:Hee,intlLabel:{id:`${Pr}.plugin.name`,defaultMessage:xw},Component:()=>Promise.resolve().then(()=>require("./index-gJOowHIB.js")),permissions:V1.access}),t.createSettingSection({id:Pr,intlLabel:{id:`${Pr}.plugin.section`,defaultMessage:`${xw} plugin`}},[{intlLabel:{id:`${Pr}.plugin.section.item`,defaultMessage:"Configuration"},id:"comments",to:`/settings/${Pr}`,Component:()=>Promise.resolve().then(()=>require("./index-DiQHdq_2.js")),permissions:V1.settings}])},registerTrads:async function({locales:t=[]}){return Promise.all(t.map(async e=>e in ww?ww[e]().then(({default:r})=>({data:bv(s0(r),Pr),locale:e})):{data:bv(s0({}),Pr),locale:e}))}};exports.Accordion=iX;exports.Alert=hX;exports.Avatar=xX;exports.Badge=Dm;exports.Box=be;exports.Button=Zu;exports.CheckboxImpl=jh;exports.DesignSystemProvider=JZ;exports.Dialog=GZ;exports.Divider=p$;exports.Field=SZ;exports.Flex=he;exports.FocusTrap=Lee;exports.ForwardRef$15=EB;exports.ForwardRef$1P=JL;exports.ForwardRef$1V=GL;exports.ForwardRef$1h=CB;exports.ForwardRef$1j=wB;exports.ForwardRef$1v=hB;exports.ForwardRef$2B=wL;exports.ForwardRef$2r=RL;exports.ForwardRef$3=f3;exports.ForwardRef$3D=B_;exports.ForwardRef$3H=E_;exports.ForwardRef$45=ji;exports.ForwardRef$4F=VI;exports.ForwardRef$4Z=AI;exports.ForwardRef$4b=h_;exports.ForwardRef$4j=o_;exports.ForwardRef$53=xI;exports.ForwardRef$5b=gI;exports.ForwardRef$5n=sI;exports.ForwardRef$T=VB;exports.ForwardRef$f=fN;exports.ForwardRef$j=lN;exports.ForwardRef$v=eN;exports.Grid=_ee;exports.IconButton=Xa;exports.IconButtonGroup=jX;exports.Link=KC;exports.Loader=i$;exports.MenuItem=JX;exports.Modal=cJ;exports.MultiSelect=HJ;exports.MultiSelectOption=A$;exports.Popover=xJ;exports.Portal$1=jm;exports.SimpleMenu=ZC;exports.SingleSelect=N1;exports.SingleSelectOption=j1;exports.SubNav=WJ;exports.SubNavHeader=UJ;exports.SubNavLink=qJ;exports.SubNavSection=ZJ;exports.SubNavSections=QJ;exports.SwitchImpl=JJ;exports.Table=fee;exports.Tbody=gee;exports.Td=xee;exports.Th=wee;exports.Thead=pee;exports.Toggle=kee;exports.TooltipImpl=Bm;exports.Tr=bee;exports.Typography=Re;exports.__rest=il;exports.commonjsGlobal=Jo;exports.darkTheme=pZ;exports.getAugmentedNamespace=EY;exports.getDefaultExportFromCjs=MY;exports.index=Pee;exports.lightTheme=e$;exports.lodashExports=OY;exports.pluginId=Pr;exports.pluginPermissions=V1;