@workflow/web 4.0.1-beta.0 → 4.0.1-beta.10

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 (64) hide show
  1. package/.next/BUILD_ID +1 -1
  2. package/.next/app-build-manifest.json +33 -27
  3. package/.next/app-path-routes-manifest.json +1 -1
  4. package/.next/build-manifest.json +5 -5
  5. package/.next/next-server.js.nft.json +1 -1
  6. package/.next/prerender-manifest.json +3 -3
  7. package/.next/required-server-files.json +1 -1
  8. package/.next/server/app/_not-found/page.js +2 -2
  9. package/.next/server/app/_not-found/page.js.nft.json +1 -1
  10. package/.next/server/app/_not-found/page_client-reference-manifest.js +1 -1
  11. package/.next/server/app/page.js +2 -2
  12. package/.next/server/app/page.js.nft.json +1 -1
  13. package/.next/server/app/page_client-reference-manifest.js +1 -1
  14. package/.next/server/app/run/[runId]/page.js +13 -3
  15. package/.next/server/app/run/[runId]/page.js.nft.json +1 -1
  16. package/.next/server/app/run/[runId]/page_client-reference-manifest.js +1 -1
  17. package/.next/server/app/run/[runId]/streams/[streamId]/page.js +2 -2
  18. package/.next/server/app/run/[runId]/streams/[streamId]/page.js.nft.json +1 -1
  19. package/.next/server/app/run/[runId]/streams/[streamId]/page_client-reference-manifest.js +1 -1
  20. package/.next/server/app-paths-manifest.json +1 -1
  21. package/.next/server/chunks/111.js +20 -1
  22. package/.next/server/chunks/154.js +84 -0
  23. package/.next/server/chunks/381.js +7 -0
  24. package/.next/server/chunks/484.js +1 -0
  25. package/.next/server/chunks/701.js +1 -6
  26. package/.next/server/middleware-build-manifest.js +1 -1
  27. package/.next/server/pages/500.html +1 -1
  28. package/.next/server/server-reference-manifest.js +1 -1
  29. package/.next/server/server-reference-manifest.json +1 -1
  30. package/.next/static/chunks/205-4e232fa55dcf62c9.js +1 -0
  31. package/.next/static/chunks/337-72e50e8e61a1f63c.js +1 -0
  32. package/.next/static/chunks/378-341b236f693d0c1c.js +1 -0
  33. package/.next/static/chunks/388-8918df58def939a2.js +1 -0
  34. package/.next/static/chunks/690-1baa8cdfb9f0e09c.js +1 -0
  35. package/.next/static/chunks/703-fac253843b8db9c9.js +1 -0
  36. package/.next/static/chunks/81-584e1cf8b55925fc.js +1 -0
  37. package/.next/static/chunks/app/layout-f915ea7a433c357d.js +1 -0
  38. package/.next/static/chunks/app/page-6a4e77065ae85c32.js +1 -0
  39. package/.next/static/chunks/app/run/[runId]/page-808c4f3b71dba6a8.js +1 -0
  40. package/.next/static/chunks/app/run/[runId]/streams/[streamId]/page-28e0f111d8f18f9c.js +1 -0
  41. package/.next/static/chunks/{webpack-b430e07cf9392cd1.js → webpack-874997185de8a24e.js} +1 -1
  42. package/.next/static/css/de4aad015642264b.css +3 -0
  43. package/.next/static/css/e949e632d86ee8ea.css +1 -0
  44. package/.next/trace +21 -19
  45. package/LICENSE.md +201 -21
  46. package/README.md +9 -41
  47. package/package.json +15 -7
  48. package/.next/server/chunks/138.js +0 -1
  49. package/.next/server/chunks/656.js +0 -42
  50. package/.next/static/chunks/412-a430cced2eddabdc.js +0 -1
  51. package/.next/static/chunks/508-34c7cba42228a753.js +0 -1
  52. package/.next/static/chunks/687-ad38291defb5159c.js +0 -1
  53. package/.next/static/chunks/724-597f8080461271d4.js +0 -1
  54. package/.next/static/chunks/98-4fb0632ee8eb5945.js +0 -1
  55. package/.next/static/chunks/app/layout-5511efd4ea55fd71.js +0 -1
  56. package/.next/static/chunks/app/page-14a46aa6ed9fb9f8.js +0 -1
  57. package/.next/static/chunks/app/run/[runId]/page-b70fe3bd91479208.js +0 -1
  58. package/.next/static/chunks/app/run/[runId]/streams/[streamId]/page-5813197c8ca1670b.js +0 -1
  59. package/.next/static/css/2002c05225ea0e5e.css +0 -1
  60. package/.next/static/css/bb92b93f39c57915.css +0 -3
  61. /package/.next/server/chunks/{907.js → 947.js} +0 -0
  62. /package/.next/static/{idQnUYapsIqHwK0hfmmKZ → Y0p7_1t2aZhkv6iKjPXHj}/_buildManifest.js +0 -0
  63. /package/.next/static/{idQnUYapsIqHwK0hfmmKZ → Y0p7_1t2aZhkv6iKjPXHj}/_ssgManifest.js +0 -0
  64. /package/.next/static/chunks/{793.b2d5c21bf87e0c8f.js → 874.b2d5c21bf87e0c8f.js} +0 -0
@@ -1 +0,0 @@
1
- "use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[412],{316:(e,t,n)=>{n.d(t,{A:()=>r});let r=(0,n(8258).A)("RefreshCw",[["path",{d:"M3 12a9 9 0 0 1 9-9 9.75 9.75 0 0 1 6.74 2.74L21 8",key:"v9h5vc"}],["path",{d:"M21 3v5h-5",key:"1q7to0"}],["path",{d:"M21 12a9 9 0 0 1-9 9 9.75 9.75 0 0 1-6.74-2.74L3 16",key:"3uifl3"}],["path",{d:"M8 16H3v5",key:"1cv678"}]])},823:(e,t,n)=>{e.exports=n(1554)},1049:(e,t,n)=>{n.d(t,{o:()=>F});var r=n(8995),a=n(4471),i=n(6386),o=n(2399),u=n(8462),l=n(3312);function s(e,t){let n=(0,l.a)(e,null==t?void 0:t.in);return n.setHours(0,0,0,0),n}function d(e,t,n){let[r,a]=(0,i.x)(null==n?void 0:n.in,e,t),l=s(r),d=s(a);return Math.round((l-(0,o.G)(l)-(d-(0,o.G)(d)))/u.w4)}function c(e,t){var n,r,i,o,u,s,d,c;let f=(0,a.q)(),h=null!=(c=null!=(d=null!=(s=null!=(u=null==t?void 0:t.weekStartsOn)?u:null==t||null==(r=t.locale)||null==(n=r.options)?void 0:n.weekStartsOn)?s:f.weekStartsOn)?d:null==(o=f.locale)||null==(i=o.options)?void 0:i.weekStartsOn)?c:0,m=(0,l.a)(e,null==t?void 0:t.in),g=m.getDay();return m.setDate(m.getDate()-(7*(g<h)+g-h)),m.setHours(0,0,0,0),m}function f(e,t){return c(e,{...t,weekStartsOn:1})}var h=n(8270);function m(e,t){let n=(0,l.a)(e,null==t?void 0:t.in),r=n.getFullYear(),a=(0,h.w)(n,0);a.setFullYear(r+1,0,4),a.setHours(0,0,0,0);let i=f(a),o=(0,h.w)(n,0);o.setFullYear(r,0,4),o.setHours(0,0,0,0);let u=f(o);return n.getTime()>=i.getTime()?r+1:n.getTime()>=u.getTime()?r:r-1}function g(e,t){var n,r,i,o,u,s,d,f;let m=(0,l.a)(e,null==t?void 0:t.in),g=m.getFullYear(),w=(0,a.q)(),v=null!=(f=null!=(d=null!=(s=null!=(u=null==t?void 0:t.firstWeekContainsDate)?u:null==t||null==(r=t.locale)||null==(n=r.options)?void 0:n.firstWeekContainsDate)?s:w.firstWeekContainsDate)?d:null==(o=w.locale)||null==(i=o.options)?void 0:i.firstWeekContainsDate)?f:1,y=(0,h.w)((null==t?void 0:t.in)||e,0);y.setFullYear(g+1,0,v),y.setHours(0,0,0,0);let b=c(y,t),p=(0,h.w)((null==t?void 0:t.in)||e,0);p.setFullYear(g,0,v),p.setHours(0,0,0,0);let M=c(p,t);return+m>=+b?g+1:+m>=+M?g:g-1}function w(e,t){let n=Math.abs(e).toString().padStart(t,"0");return(e<0?"-":"")+n}let v={y(e,t){let n=e.getFullYear(),r=n>0?n:1-n;return w("yy"===t?r%100:r,t.length)},M(e,t){let n=e.getMonth();return"M"===t?String(n+1):w(n+1,2)},d:(e,t)=>w(e.getDate(),t.length),a(e,t){let n=e.getHours()/12>=1?"pm":"am";switch(t){case"a":case"aa":return n.toUpperCase();case"aaa":return n;case"aaaaa":return n[0];default:return"am"===n?"a.m.":"p.m."}},h:(e,t)=>w(e.getHours()%12||12,t.length),H:(e,t)=>w(e.getHours(),t.length),m:(e,t)=>w(e.getMinutes(),t.length),s:(e,t)=>w(e.getSeconds(),t.length),S(e,t){let n=t.length;return w(Math.trunc(e.getMilliseconds()*Math.pow(10,n-3)),t.length)}},y={midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},b={G:function(e,t,n){let r=+(e.getFullYear()>0);switch(t){case"G":case"GG":case"GGG":return n.era(r,{width:"abbreviated"});case"GGGGG":return n.era(r,{width:"narrow"});default:return n.era(r,{width:"wide"})}},y:function(e,t,n){if("yo"===t){let t=e.getFullYear();return n.ordinalNumber(t>0?t:1-t,{unit:"year"})}return v.y(e,t)},Y:function(e,t,n,r){let a=g(e,r),i=a>0?a:1-a;return"YY"===t?w(i%100,2):"Yo"===t?n.ordinalNumber(i,{unit:"year"}):w(i,t.length)},R:function(e,t){return w(m(e),t.length)},u:function(e,t){return w(e.getFullYear(),t.length)},Q:function(e,t,n){let r=Math.ceil((e.getMonth()+1)/3);switch(t){case"Q":return String(r);case"QQ":return w(r,2);case"Qo":return n.ordinalNumber(r,{unit:"quarter"});case"QQQ":return n.quarter(r,{width:"abbreviated",context:"formatting"});case"QQQQQ":return n.quarter(r,{width:"narrow",context:"formatting"});default:return n.quarter(r,{width:"wide",context:"formatting"})}},q:function(e,t,n){let r=Math.ceil((e.getMonth()+1)/3);switch(t){case"q":return String(r);case"qq":return w(r,2);case"qo":return n.ordinalNumber(r,{unit:"quarter"});case"qqq":return n.quarter(r,{width:"abbreviated",context:"standalone"});case"qqqqq":return n.quarter(r,{width:"narrow",context:"standalone"});default:return n.quarter(r,{width:"wide",context:"standalone"})}},M:function(e,t,n){let r=e.getMonth();switch(t){case"M":case"MM":return v.M(e,t);case"Mo":return n.ordinalNumber(r+1,{unit:"month"});case"MMM":return n.month(r,{width:"abbreviated",context:"formatting"});case"MMMMM":return n.month(r,{width:"narrow",context:"formatting"});default:return n.month(r,{width:"wide",context:"formatting"})}},L:function(e,t,n){let r=e.getMonth();switch(t){case"L":return String(r+1);case"LL":return w(r+1,2);case"Lo":return n.ordinalNumber(r+1,{unit:"month"});case"LLL":return n.month(r,{width:"abbreviated",context:"standalone"});case"LLLLL":return n.month(r,{width:"narrow",context:"standalone"});default:return n.month(r,{width:"wide",context:"standalone"})}},w:function(e,t,n,r){let i=function(e,t){let n=(0,l.a)(e,null==t?void 0:t.in);return Math.round((c(n,t)-function(e,t){var n,r,i,o,u,l,s,d;let f=(0,a.q)(),m=null!=(d=null!=(s=null!=(l=null!=(u=null==t?void 0:t.firstWeekContainsDate)?u:null==t||null==(r=t.locale)||null==(n=r.options)?void 0:n.firstWeekContainsDate)?l:f.firstWeekContainsDate)?s:null==(o=f.locale)||null==(i=o.options)?void 0:i.firstWeekContainsDate)?d:1,w=g(e,t),v=(0,h.w)((null==t?void 0:t.in)||e,0);return v.setFullYear(w,0,m),v.setHours(0,0,0,0),c(v,t)}(n,t))/u.my)+1}(e,r);return"wo"===t?n.ordinalNumber(i,{unit:"week"}):w(i,t.length)},I:function(e,t,n){let r=function(e,t){let n=(0,l.a)(e,void 0);return Math.round((f(n)-function(e,t){let n=m(e,void 0),r=(0,h.w)(e,0);return r.setFullYear(n,0,4),r.setHours(0,0,0,0),f(r)}(n))/u.my)+1}(e);return"Io"===t?n.ordinalNumber(r,{unit:"week"}):w(r,t.length)},d:function(e,t,n){return"do"===t?n.ordinalNumber(e.getDate(),{unit:"date"}):v.d(e,t)},D:function(e,t,n){let r=function(e,t){let n=(0,l.a)(e,void 0);return d(n,function(e,t){let n=(0,l.a)(e,void 0);return n.setFullYear(n.getFullYear(),0,1),n.setHours(0,0,0,0),n}(n))+1}(e);return"Do"===t?n.ordinalNumber(r,{unit:"dayOfYear"}):w(r,t.length)},E:function(e,t,n){let r=e.getDay();switch(t){case"E":case"EE":case"EEE":return n.day(r,{width:"abbreviated",context:"formatting"});case"EEEEE":return n.day(r,{width:"narrow",context:"formatting"});case"EEEEEE":return n.day(r,{width:"short",context:"formatting"});default:return n.day(r,{width:"wide",context:"formatting"})}},e:function(e,t,n,r){let a=e.getDay(),i=(a-r.weekStartsOn+8)%7||7;switch(t){case"e":return String(i);case"ee":return w(i,2);case"eo":return n.ordinalNumber(i,{unit:"day"});case"eee":return n.day(a,{width:"abbreviated",context:"formatting"});case"eeeee":return n.day(a,{width:"narrow",context:"formatting"});case"eeeeee":return n.day(a,{width:"short",context:"formatting"});default:return n.day(a,{width:"wide",context:"formatting"})}},c:function(e,t,n,r){let a=e.getDay(),i=(a-r.weekStartsOn+8)%7||7;switch(t){case"c":return String(i);case"cc":return w(i,t.length);case"co":return n.ordinalNumber(i,{unit:"day"});case"ccc":return n.day(a,{width:"abbreviated",context:"standalone"});case"ccccc":return n.day(a,{width:"narrow",context:"standalone"});case"cccccc":return n.day(a,{width:"short",context:"standalone"});default:return n.day(a,{width:"wide",context:"standalone"})}},i:function(e,t,n){let r=e.getDay(),a=0===r?7:r;switch(t){case"i":return String(a);case"ii":return w(a,t.length);case"io":return n.ordinalNumber(a,{unit:"day"});case"iii":return n.day(r,{width:"abbreviated",context:"formatting"});case"iiiii":return n.day(r,{width:"narrow",context:"formatting"});case"iiiiii":return n.day(r,{width:"short",context:"formatting"});default:return n.day(r,{width:"wide",context:"formatting"})}},a:function(e,t,n){let r=e.getHours()/12>=1?"pm":"am";switch(t){case"a":case"aa":return n.dayPeriod(r,{width:"abbreviated",context:"formatting"});case"aaa":return n.dayPeriod(r,{width:"abbreviated",context:"formatting"}).toLowerCase();case"aaaaa":return n.dayPeriod(r,{width:"narrow",context:"formatting"});default:return n.dayPeriod(r,{width:"wide",context:"formatting"})}},b:function(e,t,n){let r,a=e.getHours();switch(r=12===a?y.noon:0===a?y.midnight:a/12>=1?"pm":"am",t){case"b":case"bb":return n.dayPeriod(r,{width:"abbreviated",context:"formatting"});case"bbb":return n.dayPeriod(r,{width:"abbreviated",context:"formatting"}).toLowerCase();case"bbbbb":return n.dayPeriod(r,{width:"narrow",context:"formatting"});default:return n.dayPeriod(r,{width:"wide",context:"formatting"})}},B:function(e,t,n){let r,a=e.getHours();switch(r=a>=17?y.evening:a>=12?y.afternoon:a>=4?y.morning:y.night,t){case"B":case"BB":case"BBB":return n.dayPeriod(r,{width:"abbreviated",context:"formatting"});case"BBBBB":return n.dayPeriod(r,{width:"narrow",context:"formatting"});default:return n.dayPeriod(r,{width:"wide",context:"formatting"})}},h:function(e,t,n){if("ho"===t){let t=e.getHours()%12;return 0===t&&(t=12),n.ordinalNumber(t,{unit:"hour"})}return v.h(e,t)},H:function(e,t,n){return"Ho"===t?n.ordinalNumber(e.getHours(),{unit:"hour"}):v.H(e,t)},K:function(e,t,n){let r=e.getHours()%12;return"Ko"===t?n.ordinalNumber(r,{unit:"hour"}):w(r,t.length)},k:function(e,t,n){let r=e.getHours();return(0===r&&(r=24),"ko"===t)?n.ordinalNumber(r,{unit:"hour"}):w(r,t.length)},m:function(e,t,n){return"mo"===t?n.ordinalNumber(e.getMinutes(),{unit:"minute"}):v.m(e,t)},s:function(e,t,n){return"so"===t?n.ordinalNumber(e.getSeconds(),{unit:"second"}):v.s(e,t)},S:function(e,t){return v.S(e,t)},X:function(e,t,n){let r=e.getTimezoneOffset();if(0===r)return"Z";switch(t){case"X":return M(r);case"XXXX":case"XX":return k(r);default:return k(r,":")}},x:function(e,t,n){let r=e.getTimezoneOffset();switch(t){case"x":return M(r);case"xxxx":case"xx":return k(r);default:return k(r,":")}},O:function(e,t,n){let r=e.getTimezoneOffset();switch(t){case"O":case"OO":case"OOO":return"GMT"+p(r,":");default:return"GMT"+k(r,":")}},z:function(e,t,n){let r=e.getTimezoneOffset();switch(t){case"z":case"zz":case"zzz":return"GMT"+p(r,":");default:return"GMT"+k(r,":")}},t:function(e,t,n){return w(Math.trunc(e/1e3),t.length)},T:function(e,t,n){return w(+e,t.length)}};function p(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"",n=e>0?"-":"+",r=Math.abs(e),a=Math.trunc(r/60),i=r%60;return 0===i?n+String(a):n+String(a)+t+w(i,2)}function M(e,t){return e%60==0?(e>0?"-":"+")+w(Math.abs(e)/60,2):k(e,t)}function k(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"",n=Math.abs(e);return(e>0?"-":"+")+w(Math.trunc(n/60),2)+t+w(n%60,2)}let S=(e,t)=>{switch(e){case"P":return t.date({width:"short"});case"PP":return t.date({width:"medium"});case"PPP":return t.date({width:"long"});default:return t.date({width:"full"})}},x=(e,t)=>{switch(e){case"p":return t.time({width:"short"});case"pp":return t.time({width:"medium"});case"ppp":return t.time({width:"long"});default:return t.time({width:"full"})}},O={p:x,P:(e,t)=>{let n,r=e.match(/(P+)(p+)?/)||[],a=r[1],i=r[2];if(!i)return S(e,t);switch(a){case"P":n=t.dateTime({width:"short"});break;case"PP":n=t.dateTime({width:"medium"});break;case"PPP":n=t.dateTime({width:"long"});break;default:n=t.dateTime({width:"full"})}return n.replace("{{date}}",S(a,t)).replace("{{time}}",x(i,t))}},P=/^D+$/,D=/^Y+$/,E=["D","DD","YY","YYYY"],T=/[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g,W=/P+p+|P+|p+|''|'(''|[^'])+('|$)|./g,C=/^'([^]*?)'?$/,L=/''/g,q=/[a-zA-Z]/;function F(e,t,n){var o,u,s,c,f,h,m,g,w,v;let y,[p,M]=(0,i.x)(null==n?void 0:n.in,e,t),k=(0,a.q)(),S=null!=(h=null!=(f=null==n?void 0:n.locale)?f:k.locale)?h:r.c,x=null!=(v=null!=(w=null!=(g=null!=(m=null==n?void 0:n.weekStartsOn)?m:null==n||null==(u=n.locale)||null==(o=u.options)?void 0:o.weekStartsOn)?g:k.weekStartsOn)?w:null==(c=k.locale)||null==(s=c.options)?void 0:s.weekStartsOn)?v:0,F=d(p,M);if(isNaN(F))throw RangeError("Invalid time value");y=F<-6?"other":F<-1?"lastWeek":F<0?"yesterday":F<1?"today":F<2?"tomorrow":F<7?"nextWeek":"other";let Y=S.formatRelative(y,p,M,{locale:S,weekStartsOn:x});return function(e,t,n){var i,o,u,s,d,c,f,h,m,g,w,v,y,p,M,k,S,x;let F=(0,a.q)(),Y=null!=(g=null!=(m=null==n?void 0:n.locale)?m:F.locale)?g:r.c,N=null!=(p=null!=(y=null!=(v=null!=(w=null==n?void 0:n.firstWeekContainsDate)?w:null==n||null==(o=n.locale)||null==(i=o.options)?void 0:i.firstWeekContainsDate)?v:F.firstWeekContainsDate)?y:null==(s=F.locale)||null==(u=s.options)?void 0:u.firstWeekContainsDate)?p:1,j=null!=(x=null!=(S=null!=(k=null!=(M=null==n?void 0:n.weekStartsOn)?M:null==n||null==(c=n.locale)||null==(d=c.options)?void 0:d.weekStartsOn)?k:F.weekStartsOn)?S:null==(h=F.locale)||null==(f=h.options)?void 0:f.weekStartsOn)?x:0,R=(0,l.a)(e,null==n?void 0:n.in);if(!(R instanceof Date||"object"==typeof R&&"[object Date]"===Object.prototype.toString.call(R))&&"number"!=typeof R||isNaN(+(0,l.a)(R)))throw RangeError("Invalid time value");let _=t.match(W).map(e=>{let t=e[0];return"p"===t||"P"===t?(0,O[t])(e,Y.formatLong):e}).join("").match(T).map(e=>{if("''"===e)return{isToken:!1,value:"'"};let t=e[0];if("'"===t)return{isToken:!1,value:function(e){let t=e.match(C);return t?t[1].replace(L,"'"):e}(e)};if(b[t])return{isToken:!0,value:e};if(t.match(q))throw RangeError("Format string contains an unescaped latin alphabet character `"+t+"`");return{isToken:!1,value:e}});Y.localize.preprocessor&&(_=Y.localize.preprocessor(R,_));let A={firstWeekContainsDate:N,weekStartsOn:j,locale:Y};return _.map(r=>{if(!r.isToken)return r.value;let a=r.value;return(!(null==n?void 0:n.useAdditionalWeekYearTokens)&&D.test(a)||!(null==n?void 0:n.useAdditionalDayOfYearTokens)&&P.test(a))&&function(e,t,n){let r=function(e,t,n){let r="Y"===e[0]?"years":"days of the month";return"Use `".concat(e.toLowerCase(),"` instead of `").concat(e,"` (in `").concat(t,"`) for formatting ").concat(r," to the input `").concat(n,"`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md")}(e,t,n);if(console.warn(r),E.includes(e))throw RangeError(r)}(a,t,String(e)),(0,b[a[0]])(R,a,Y.localize,A)}).join("")}(p,Y,{locale:S,weekStartsOn:x})}},1554:(e,t,n)=>{var r=n(4773),a="function"==typeof Object.is?Object.is:function(e,t){return e===t&&(0!==e||1/e==1/t)||e!=e&&t!=t},i=r.useState,o=r.useEffect,u=r.useLayoutEffect,l=r.useDebugValue;function s(e){var t=e.getSnapshot;e=e.value;try{var n=t();return!a(e,n)}catch(e){return!0}}var d="undefined"==typeof window||void 0===window.document||void 0===window.document.createElement?function(e,t){return t()}:function(e,t){var n=t(),r=i({inst:{value:n,getSnapshot:t}}),a=r[0].inst,d=r[1];return u(function(){a.value=n,a.getSnapshot=t,s(a)&&d({inst:a})},[e,n,t]),o(function(){return s(a)&&d({inst:a}),e(function(){s(a)&&d({inst:a})})},[e]),l(n),n};t.useSyncExternalStore=void 0!==r.useSyncExternalStore?r.useSyncExternalStore:d},2399:(e,t,n)=>{n.d(t,{G:()=>a});var r=n(3312);function a(e){let t=(0,r.a)(e),n=new Date(Date.UTC(t.getFullYear(),t.getMonth(),t.getDate(),t.getHours(),t.getMinutes(),t.getSeconds(),t.getMilliseconds()));return n.setUTCFullYear(t.getFullYear()),e-n}},3312:(e,t,n)=>{n.d(t,{a:()=>a});var r=n(8270);function a(e,t){return(0,r.w)(t||e,e)}},4471:(e,t,n)=>{n.d(t,{q:()=>a});let r={};function a(){return r}},5505:(e,t,n)=>{n.d(t,{B:()=>d});var r=n(8270),a=n(8995),i=n(4471),o=n(2399),u=n(6386),l=n(3312),s=n(8462);function d(e,t){return function(e,t,n){var r,d,c,f;let h,m=(0,i.q)(),g=null!=(d=null!=(r=null==n?void 0:n.locale)?r:m.locale)?d:a.c,w=function(e,t){let n=(0,l.a)(e)-(0,l.a)(t);return n<0?-1:n>0?1:n}(e,t);if(isNaN(w))throw RangeError("Invalid time value");let v=Object.assign({},n,{addSuffix:null==n?void 0:n.addSuffix,comparison:w}),[y,b]=(0,u.x)(null==n?void 0:n.in,...w>0?[t,e]:[e,t]),p=(f=null!=(c=null==n?void 0:n.roundingMethod)?c:"round",e=>{let t=(f?Math[f]:Math.trunc)(e);return 0===t?0:t}),M=b.getTime()-y.getTime(),k=M/s.Cg,S=(M-((0,o.G)(b)-(0,o.G)(y)))/s.Cg,x=null==n?void 0:n.unit;if("second"===(h=x||(k<1?"second":k<60?"minute":k<s.F6?"hour":S<s.Nw?"day":S<s.Ks?"month":"year"))){let e=p(M/1e3);return g.formatDistance("xSeconds",e,v)}if("minute"===h){let e=p(k);return g.formatDistance("xMinutes",e,v)}if("hour"===h){let e=p(k/60);return g.formatDistance("xHours",e,v)}if("day"===h){let e=p(S/s.F6);return g.formatDistance("xDays",e,v)}if("month"===h){let e=p(S/s.Nw);return 12===e&&"month"!==x?g.formatDistance("xYears",1,v):g.formatDistance("xMonths",e,v)}else{let e=p(S/s.Ks);return g.formatDistance("xYears",e,v)}}(e,(0,r.w)(e,Date.now()),t)}},6386:(e,t,n)=>{n.d(t,{x:()=>a});var r=n(8270);function a(e){for(var t=arguments.length,n=Array(t>1?t-1:0),a=1;a<t;a++)n[a-1]=arguments[a];let i=r.w.bind(null,e||n.find(e=>"object"==typeof e));return n.map(i)}},6489:(e,t,n)=>{let r;n.d(t,{Ay:()=>U});var a=n(4773),i=n(823),o=Object.prototype.hasOwnProperty;let u=new WeakMap,l=()=>{},s=l(),d=Object,c=e=>e===s,f=(e,t)=>({...e,...t}),h={},m={},g="undefined",w=typeof window!=g,v=typeof document!=g,y=w&&"Deno"in window,b=(e,t)=>{let n=u.get(e);return[()=>!c(t)&&e.get(t)||h,r=>{if(!c(t)){let a=e.get(t);t in m||(m[t]=a),n[5](t,f(a,r),a||h)}},n[6],()=>!c(t)&&t in m?m[t]:!c(t)&&e.get(t)||h]},p=!0,[M,k]=w&&window.addEventListener?[window.addEventListener.bind(window),window.removeEventListener.bind(window)]:[l,l],S={initFocus:e=>(v&&document.addEventListener("visibilitychange",e),M("focus",e),()=>{v&&document.removeEventListener("visibilitychange",e),k("focus",e)}),initReconnect:e=>{let t=()=>{p=!0,e()},n=()=>{p=!1};return M("online",t),M("offline",n),()=>{k("online",t),k("offline",n)}}},x=!a.useId,O=!w||y,P=O?a.useEffect:a.useLayoutEffect,D="undefined"!=typeof navigator&&navigator.connection,E=!O&&D&&(["slow-2g","2g"].includes(D.effectiveType)||D.saveData),T=new WeakMap,W=(e,t)=>e==="[object ".concat(t,"]"),C=0,L=e=>{let t,n,r=typeof e,a=d.prototype.toString.call(e),i=W(a,"Date"),o=W(a,"RegExp"),u=W(a,"Object");if(d(e)!==e||i||o)t=i?e.toJSON():"symbol"==r?e.toString():"string"==r?JSON.stringify(e):""+e;else{if(t=T.get(e))return t;if(t=++C+"~",T.set(e,t),Array.isArray(e)){for(n=0,t="@";n<e.length;n++)t+=L(e[n])+",";T.set(e,t)}if(u){t="#";let r=d.keys(e).sort();for(;!c(n=r.pop());)c(e[n])||(t+=n+":"+L(e[n])+",");T.set(e,t)}}return t},q=e=>{if("function"==typeof e)try{e=e()}catch(t){e=""}let t=e;return[e="string"==typeof e?e:(Array.isArray(e)?e.length:e)?L(e):"",t]},F=0,Y=()=>++F;async function N(){for(var e=arguments.length,t=Array(e),n=0;n<e;n++)t[n]=arguments[n];let[r,a,i,o]=t,l=f({populateCache:!0,throwOnError:!0},"boolean"==typeof o?{revalidate:o}:o||{}),d=l.populateCache,h=l.rollbackOnError,m=l.optimisticData,g=l.throwOnError;if("function"==typeof a){let e=[];for(let t of r.keys())!/^\$(inf|sub)\$/.test(t)&&a(r.get(t)._k)&&e.push(t);return Promise.all(e.map(w))}return w(a);async function w(e){let n,[a]=q(e);if(!a)return;let[o,f]=b(r,a),[w,v,y,p]=u.get(r),M=()=>{let t=w[a];return("function"==typeof l.revalidate?l.revalidate(o().data,e):!1!==l.revalidate)&&(delete y[a],delete p[a],t&&t[0])?t[0](2).then(()=>o().data):o().data};if(t.length<3)return M();let k=i,S=!1,x=Y();v[a]=[x,0];let O=!c(m),P=o(),D=P.data,E=P._c,T=c(E)?D:E;if(O&&f({data:m="function"==typeof m?m(T,D):m,_c:T}),"function"==typeof k)try{k=k(T)}catch(e){n=e,S=!0}if(k&&"function"==typeof k.then){let e;if(k=await k.catch(e=>{n=e,S=!0}),x!==v[a][0]){if(S)throw n;return k}S&&O&&(e=n,"function"==typeof h?h(e):!1!==h)&&(d=!0,f({data:T,_c:s}))}if(d&&!S&&("function"==typeof d?f({data:d(k,T),error:s,_c:s}):f({data:k,error:s,_c:s})),v[a][1]=Y(),Promise.resolve(M()).then(()=>{f({_c:s})}),S){if(g)throw n;return}return k}}let j=(e,t)=>{for(let n in e)e[n][0]&&e[n][0](t)},R=(e,t)=>{if(!u.has(e)){let n=f(S,t),r=Object.create(null),a=N.bind(s,e),i=l,o=Object.create(null),d=(e,t)=>{let n=o[e]||[];return o[e]=n,n.push(t),()=>n.splice(n.indexOf(t),1)},c=(t,n,r)=>{e.set(t,n);let a=o[t];if(a)for(let e of a)e(n,r)},h=()=>{if(!u.has(e)&&(u.set(e,[r,Object.create(null),Object.create(null),Object.create(null),a,c,d]),!O)){let t=n.initFocus(setTimeout.bind(s,j.bind(s,r,0))),a=n.initReconnect(setTimeout.bind(s,j.bind(s,r,1)));i=()=>{t&&t(),a&&a(),u.delete(e)}}};return h(),[e,a,h,i]}return[e,u.get(e)[4]]},[_,A]=R(new Map),H=f({onLoadingSlow:l,onSuccess:l,onError:l,onErrorRetry:(e,t,n,r,a)=>{let i=n.errorRetryCount,o=a.retryCount,u=~~((Math.random()+.5)*(1<<(o<8?o:8)))*n.errorRetryInterval;(c(i)||!(o>i))&&setTimeout(r,u,a)},onDiscarded:l,revalidateOnFocus:!0,revalidateOnReconnect:!0,revalidateIfStale:!0,shouldRetryOnError:!0,errorRetryInterval:E?1e4:5e3,focusThrottleInterval:5e3,dedupingInterval:2e3,loadingTimeout:E?5e3:3e3,compare:function e(t,n){var r,a;if(t===n)return!0;if(t&&n&&(r=t.constructor)===n.constructor){if(r===Date)return t.getTime()===n.getTime();if(r===RegExp)return t.toString()===n.toString();if(r===Array){if((a=t.length)===n.length)for(;a--&&e(t[a],n[a]););return -1===a}if(!r||"object"==typeof t){for(r in a=0,t)if(o.call(t,r)&&++a&&!o.call(n,r)||!(r in n)||!e(t[r],n[r]))return!1;return Object.keys(n).length===a}}return t!=t&&n!=n},isPaused:()=>!1,cache:_,mutate:A,fallback:{}},{isOnline:()=>p,isVisible:()=>{let e=v&&document.visibilityState;return c(e)||"hidden"!==e}}),V=(e,t)=>{let n=f(e,t);if(t){let{use:r,fallback:a}=e,{use:i,fallback:o}=t;r&&i&&(n.use=r.concat(i)),a&&o&&(n.fallback=f(a,o))}return n},z=(0,a.createContext)({}),G=w&&window.__SWR_DEVTOOLS_USE__,Q=(G?window.__SWR_DEVTOOLS_USE__:[]).concat(e=>(t,n,r)=>{let a=n&&((...e)=>{let[r]=q(t),[,,,a]=u.get(_);if(r.startsWith("$inf$"))return n(...e);let i=a[r];return c(i)?n(...e):(delete a[r],i)});return e(t,a,r)});G&&(window.__SWR_DEVTOOLS_REACT__=a);let B=()=>{},I=B();new WeakMap;let X=a.use||(e=>{switch(e.status){case"pending":throw e;case"fulfilled":return e.value;case"rejected":throw e.reason;default:throw e.status="pending",e.then(t=>{e.status="fulfilled",e.value=t},t=>{e.status="rejected",e.reason=t}),e}}),J={dedupe:!0},$=Promise.resolve(s);d.defineProperty(e=>{let{value:t}=e,n=(0,a.useContext)(z),r="function"==typeof t,i=(0,a.useMemo)(()=>r?t(n):t,[r,n,t]),o=(0,a.useMemo)(()=>r?i:V(n,i),[r,n,i]),u=i&&i.provider,l=(0,a.useRef)(s);u&&!l.current&&(l.current=R(u(o.cache||_),i));let d=l.current;return d&&(o.cache=d[0],o.mutate=d[1]),P(()=>{if(d)return d[2]&&d[2](),d[3]},[]),(0,a.createElement)(z.Provider,f(e,{value:o}))},"defaultValue",{value:H});let U=(r=(e,t,n)=>{let{cache:r,compare:o,suspense:l,fallbackData:d,revalidateOnMount:h,revalidateIfStale:m,refreshInterval:v,refreshWhenHidden:y,refreshWhenOffline:p,keepPreviousData:M}=n,[k,S,D,E]=u.get(r),[T,W]=q(e),C=(0,a.useRef)(!1),L=(0,a.useRef)(!1),F=(0,a.useRef)(T),j=(0,a.useRef)(t),R=(0,a.useRef)(n),_=()=>R.current.isVisible()&&R.current.isOnline(),[A,H,V,z]=b(r,T),G=(0,a.useRef)({}).current,Q=c(d)?c(n.fallback)?s:n.fallback[T]:d,B=(e,t)=>{for(let n in G)if("data"===n){if(!o(e[n],t[n])&&(!c(e[n])||!o(ea,t[n])))return!1}else if(t[n]!==e[n])return!1;return!0},I=(0,a.useMemo)(()=>{let e=!!T&&!!t&&(c(h)?!R.current.isPaused()&&!l&&!1!==m:h),n=t=>{let n=f(t);return(delete n._k,e)?{isValidating:!0,isLoading:!0,...n}:n},r=A(),a=z(),i=n(r),o=r===a?i:n(a),u=i;return[()=>{let e=n(A());return B(e,u)?(u.data=e.data,u.isLoading=e.isLoading,u.isValidating=e.isValidating,u.error=e.error,u):(u=e,e)},()=>o]},[r,T]),U=(0,i.useSyncExternalStore)((0,a.useCallback)(e=>V(T,(t,n)=>{B(n,t)||e()}),[r,T]),I[0],I[1]),K=!C.current,Z=k[T]&&k[T].length>0,ee=U.data,et=c(ee)?Q&&"function"==typeof Q.then?X(Q):Q:ee,en=U.error,er=(0,a.useRef)(et),ea=M?c(ee)?c(er.current)?et:er.current:ee:et,ei=(!Z||!!c(en))&&(K&&!c(h)?h:!R.current.isPaused()&&(l?!c(et)&&m:c(et)||m)),eo=!!(T&&t&&K&&ei),eu=c(U.isValidating)?eo:U.isValidating,el=c(U.isLoading)?eo:U.isLoading,es=(0,a.useCallback)(async e=>{let t,r,a=j.current;if(!T||!a||L.current||R.current.isPaused())return!1;let i=!0,u=e||{},l=!D[T]||!u.dedupe,d=()=>x?!L.current&&T===F.current&&C.current:T===F.current,f={isValidating:!1,isLoading:!1},h=()=>{H(f)},m=()=>{let e=D[T];e&&e[1]===r&&delete D[T]},g={isValidating:!0};c(A().data)&&(g.isLoading=!0);try{if(l&&(H(g),n.loadingTimeout&&c(A().data)&&setTimeout(()=>{i&&d()&&R.current.onLoadingSlow(T,n)},n.loadingTimeout),D[T]=[a(W),Y()]),[t,r]=D[T],t=await t,l&&setTimeout(m,n.dedupingInterval),!D[T]||D[T][1]!==r)return l&&d()&&R.current.onDiscarded(T),!1;f.error=s;let e=S[T];if(!c(e)&&(r<=e[0]||r<=e[1]||0===e[1]))return h(),l&&d()&&R.current.onDiscarded(T),!1;let u=A().data;f.data=o(u,t)?u:t,l&&d()&&R.current.onSuccess(t,T,n)}catch(n){m();let e=R.current,{shouldRetryOnError:t}=e;!e.isPaused()&&(f.error=n,l&&d())&&(e.onError(n,T,e),(!0===t||"function"==typeof t&&t(n))&&(!R.current.revalidateOnFocus||!R.current.revalidateOnReconnect||_())&&e.onErrorRetry(n,T,e,e=>{let t=k[T];t&&t[0]&&t[0](3,e)},{retryCount:(u.retryCount||0)+1,dedupe:!0}))}return i=!1,h(),!0},[T,r]),ed=(0,a.useCallback)((...e)=>N(r,F.current,...e),[]);if(P(()=>{j.current=t,R.current=n,c(ee)||(er.current=ee)}),P(()=>{if(!T)return;let e=es.bind(s,J),t=0;R.current.revalidateOnFocus&&(t=Date.now()+R.current.focusThrottleInterval);let n=((e,t,n)=>{let r=t[e]||(t[e]=[]);return r.push(n),()=>{let e=r.indexOf(n);e>=0&&(r[e]=r[r.length-1],r.pop())}})(T,k,(n,r={})=>{if(0==n){let n=Date.now();R.current.revalidateOnFocus&&n>t&&_()&&(t=n+R.current.focusThrottleInterval,e())}else if(1==n)R.current.revalidateOnReconnect&&_()&&e();else if(2==n)return es();else if(3==n)return es(r)});return L.current=!1,F.current=T,C.current=!0,H({_k:W}),ei&&!D[T]&&(c(et)||O?e():(e=>w&&typeof window.requestAnimationFrame!=g?window.requestAnimationFrame(e):setTimeout(e,1))(e)),()=>{L.current=!0,n()}},[T]),P(()=>{let e;function t(){let t="function"==typeof v?v(A().data):v;t&&-1!==e&&(e=setTimeout(n,t))}function n(){!A().error&&(y||R.current.isVisible())&&(p||R.current.isOnline())?es(J).then(t):t()}return t(),()=>{e&&(clearTimeout(e),e=-1)}},[v,y,p,T]),(0,a.useDebugValue)(ea),l){let e=T&&c(et);if(!x&&O&&e)throw Error("Fallback data is required when using Suspense in SSR.");e&&(j.current=t,R.current=n,L.current=!1);let r=E[T];if(X(!c(r)&&e?ed(r):$),!c(en)&&e)throw en;let a=e?es(J):$;!c(ea)&&e&&(a.status="fulfilled",a.value=!0),X(a)}return{mutate:ed,get data(){return G.data=!0,ea},get error(){return G.error=!0,en},get isValidating(){return G.isValidating=!0,eu},get isLoading(){return G.isLoading=!0,el}}},function(...e){let t=(()=>{let e=(0,a.useContext)(z);return(0,a.useMemo)(()=>f(H,e),[e])})(),[n,i,o]="function"==typeof e[1]?[e[0],e[1],e[2]||{}]:[e[0],null,(null===e[1]?e[2]:e[1])||{}],u=V(t,o),l=r,{use:s}=u,d=(s||[]).concat(Q);for(let e=d.length;e--;)l=d[e](l);return l(n,i||u.fetcher||null,u)})},8270:(e,t,n)=>{n.d(t,{w:()=>a});var r=n(8462);function a(e,t){return"function"==typeof e?e(t):e&&"object"==typeof e&&r._P in e?e[r._P](t):e instanceof Date?new e.constructor(t):new Date(t)}},8462:(e,t,n)=>{n.d(t,{Cg:()=>i,F6:()=>l,Ks:()=>o,Nw:()=>u,_P:()=>s,my:()=>r,w4:()=>a});let r=6048e5,a=864e5,i=6e4,o=525600,u=43200,l=1440,s=Symbol.for("constructDateFrom")},8995:(e,t,n)=>{n.d(t,{c:()=>s});let r={lessThanXSeconds:{one:"less than a second",other:"less than {{count}} seconds"},xSeconds:{one:"1 second",other:"{{count}} seconds"},halfAMinute:"half a minute",lessThanXMinutes:{one:"less than a minute",other:"less than {{count}} minutes"},xMinutes:{one:"1 minute",other:"{{count}} minutes"},aboutXHours:{one:"about 1 hour",other:"about {{count}} hours"},xHours:{one:"1 hour",other:"{{count}} hours"},xDays:{one:"1 day",other:"{{count}} days"},aboutXWeeks:{one:"about 1 week",other:"about {{count}} weeks"},xWeeks:{one:"1 week",other:"{{count}} weeks"},aboutXMonths:{one:"about 1 month",other:"about {{count}} months"},xMonths:{one:"1 month",other:"{{count}} months"},aboutXYears:{one:"about 1 year",other:"about {{count}} years"},xYears:{one:"1 year",other:"{{count}} years"},overXYears:{one:"over 1 year",other:"over {{count}} years"},almostXYears:{one:"almost 1 year",other:"almost {{count}} years"}};function a(e){return function(){let t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=t.width?String(t.width):e.defaultWidth;return e.formats[n]||e.formats[e.defaultWidth]}}let i={date:a({formats:{full:"EEEE, MMMM do, y",long:"MMMM do, y",medium:"MMM d, y",short:"MM/dd/yyyy"},defaultWidth:"full"}),time:a({formats:{full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},defaultWidth:"full"}),dateTime:a({formats:{full:"{{date}} 'at' {{time}}",long:"{{date}} 'at' {{time}}",medium:"{{date}}, {{time}}",short:"{{date}}, {{time}}"},defaultWidth:"full"})},o={lastWeek:"'last' eeee 'at' p",yesterday:"'yesterday at' p",today:"'today at' p",tomorrow:"'tomorrow at' p",nextWeek:"eeee 'at' p",other:"P"};function u(e){return(t,n)=>{let r;if("formatting"===((null==n?void 0:n.context)?String(n.context):"standalone")&&e.formattingValues){let t=e.defaultFormattingWidth||e.defaultWidth,a=(null==n?void 0:n.width)?String(n.width):t;r=e.formattingValues[a]||e.formattingValues[t]}else{let t=e.defaultWidth,a=(null==n?void 0:n.width)?String(n.width):e.defaultWidth;r=e.values[a]||e.values[t]}return r[e.argumentCallback?e.argumentCallback(t):t]}}function l(e){return function(t){let n,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},a=r.width,i=a&&e.matchPatterns[a]||e.matchPatterns[e.defaultMatchWidth],o=t.match(i);if(!o)return null;let u=o[0],l=a&&e.parsePatterns[a]||e.parsePatterns[e.defaultParseWidth],s=Array.isArray(l)?function(e,t){for(let n=0;n<e.length;n++)if(t(e[n]))return n}(l,e=>e.test(u)):function(e,t){for(let n in e)if(Object.prototype.hasOwnProperty.call(e,n)&&t(e[n]))return n}(l,e=>e.test(u));return n=e.valueCallback?e.valueCallback(s):s,{value:n=r.valueCallback?r.valueCallback(n):n,rest:t.slice(u.length)}}}let s={code:"en-US",formatDistance:(e,t,n)=>{let a,i=r[e];if(a="string"==typeof i?i:1===t?i.one:i.other.replace("{{count}}",t.toString()),null==n?void 0:n.addSuffix)if(n.comparison&&n.comparison>0)return"in "+a;else return a+" ago";return a},formatLong:i,formatRelative:(e,t,n,r)=>o[e],localize:{ordinalNumber:(e,t)=>{let n=Number(e),r=n%100;if(r>20||r<10)switch(r%10){case 1:return n+"st";case 2:return n+"nd";case 3:return n+"rd"}return n+"th"},era:u({values:{narrow:["B","A"],abbreviated:["BC","AD"],wide:["Before Christ","Anno Domini"]},defaultWidth:"wide"}),quarter:u({values:{narrow:["1","2","3","4"],abbreviated:["Q1","Q2","Q3","Q4"],wide:["1st quarter","2nd quarter","3rd quarter","4th quarter"]},defaultWidth:"wide",argumentCallback:e=>e-1}),month:u({values:{narrow:["J","F","M","A","M","J","J","A","S","O","N","D"],abbreviated:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],wide:["January","February","March","April","May","June","July","August","September","October","November","December"]},defaultWidth:"wide"}),day:u({values:{narrow:["S","M","T","W","T","F","S"],short:["Su","Mo","Tu","We","Th","Fr","Sa"],abbreviated:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],wide:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"]},defaultWidth:"wide"}),dayPeriod:u({values:{narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"}},defaultWidth:"wide",formattingValues:{narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"}},defaultFormattingWidth:"wide"})},match:{ordinalNumber:function(e){return function(t){let n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=t.match(e.matchPattern);if(!r)return null;let a=r[0],i=t.match(e.parsePattern);if(!i)return null;let o=e.valueCallback?e.valueCallback(i[0]):i[0];return{value:o=n.valueCallback?n.valueCallback(o):o,rest:t.slice(a.length)}}}({matchPattern:/^(\d+)(th|st|nd|rd)?/i,parsePattern:/\d+/i,valueCallback:e=>parseInt(e,10)}),era:l({matchPatterns:{narrow:/^(b|a)/i,abbreviated:/^(b\.?\s?c\.?|b\.?\s?c\.?\s?e\.?|a\.?\s?d\.?|c\.?\s?e\.?)/i,wide:/^(before christ|before common era|anno domini|common era)/i},defaultMatchWidth:"wide",parsePatterns:{any:[/^b/i,/^(a|c)/i]},defaultParseWidth:"any"}),quarter:l({matchPatterns:{narrow:/^[1234]/i,abbreviated:/^q[1234]/i,wide:/^[1234](th|st|nd|rd)? quarter/i},defaultMatchWidth:"wide",parsePatterns:{any:[/1/i,/2/i,/3/i,/4/i]},defaultParseWidth:"any",valueCallback:e=>e+1}),month:l({matchPatterns:{narrow:/^[jfmasond]/i,abbreviated:/^(jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec)/i,wide:/^(january|february|march|april|may|june|july|august|september|october|november|december)/i},defaultMatchWidth:"wide",parsePatterns:{narrow:[/^j/i,/^f/i,/^m/i,/^a/i,/^m/i,/^j/i,/^j/i,/^a/i,/^s/i,/^o/i,/^n/i,/^d/i],any:[/^ja/i,/^f/i,/^mar/i,/^ap/i,/^may/i,/^jun/i,/^jul/i,/^au/i,/^s/i,/^o/i,/^n/i,/^d/i]},defaultParseWidth:"any"}),day:l({matchPatterns:{narrow:/^[smtwf]/i,short:/^(su|mo|tu|we|th|fr|sa)/i,abbreviated:/^(sun|mon|tue|wed|thu|fri|sat)/i,wide:/^(sunday|monday|tuesday|wednesday|thursday|friday|saturday)/i},defaultMatchWidth:"wide",parsePatterns:{narrow:[/^s/i,/^m/i,/^t/i,/^w/i,/^t/i,/^f/i,/^s/i],any:[/^su/i,/^m/i,/^tu/i,/^w/i,/^th/i,/^f/i,/^sa/i]},defaultParseWidth:"any"}),dayPeriod:l({matchPatterns:{narrow:/^(a|p|mi|n|(in the|at) (morning|afternoon|evening|night))/i,any:/^([ap]\.?\s?m\.?|midnight|noon|(in the|at) (morning|afternoon|evening|night))/i},defaultMatchWidth:"any",parsePatterns:{any:{am:/^a/i,pm:/^p/i,midnight:/^mi/i,noon:/^no/i,morning:/morning/i,afternoon:/afternoon/i,evening:/evening/i,night:/night/i}},defaultParseWidth:"any"})},options:{weekStartsOn:0,firstWeekContainsDate:1}}}}]);
@@ -1 +0,0 @@
1
- (self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[508],{960:(e,t,r)=>{"use strict";r.d(t,{u:()=>a});var n=r(8033);let a=(0,n.createServerReference)("7e61f819e3d5bcb00e838ebf9081a931fdc322d976",n.callServer,void 0,n.findSourceMapURL,"fetchEventsByCorrelationId")},1402:(e,t,r)=>{"use strict";r.d(t,{wk:()=>i,Xt:()=>s});var n=r(6489),a=r(4635);function i(e){for(var t=arguments.length,r=Array(t>1?t-1:0),n=1;n<t;n++)r[n-1]=arguments[n];return[JSON.stringify(e),...r].filter(Boolean).join("::")}function s(e,t,r){return(0,n.Ay)(i(e,"run",t),()=>(0,a.k)(e,t),{refreshInterval:null==r?void 0:r.refreshInterval,revalidateOnFocus:!1})}r(4773)},1998:e=>{e.exports={spanRunning:"workflow-trace_spanRunning__1efX_",spanPending:"workflow-trace_spanPending__p7rdl",spanCompleted:"workflow-trace_spanCompleted__9NwVS",spanCancelled:"workflow-trace_spanCancelled___ORjw",spanPaused:"workflow-trace_spanPaused__Ffg_N",spanFailed:"workflow-trace_spanFailed__jtT9c",spanPendingStriped:"workflow-trace_spanPendingStriped___Khxv",spanSleep:"workflow-trace_spanSleep__HrTwd",spanHook:"workflow-trace_spanHook__XG6r_",eventFailed:"workflow-trace_eventFailed__3C_AS",eventRetrying:"workflow-trace_eventRetrying__Sm5qS",eventHook:"workflow-trace_eventHook__vpVmv",eventDefault:"workflow-trace_eventDefault__h2jbU"}},2287:(e,t,r)=>{"use strict";r.d(t,{$g:()=>o,Oc:()=>l,cn:()=>s,yQ:()=>i});var n=r(2928),a=r(8997);let i=10;function s(){for(var e=arguments.length,t=Array(e),r=0;r<e;r++)t[r]=arguments[r];return(0,a.QP)((0,n.$)(t))}let l=5e3;function o(e,t,r){return r?"Page ".concat(e," of ").concat(t,"+"):"Page ".concat(e," of ").concat(t)}},2338:(e,t,r)=>{"use strict";r.d(t,{Wu:()=>c,ZB:()=>o,Zp:()=>s,aR:()=>l});var n=r(5386),a=r(4773),i=r(2287);let s=a.forwardRef((e,t)=>{let{className:r,...a}=e;return(0,n.jsx)("div",{ref:t,className:(0,i.cn)("rounded-lg border bg-card text-card-foreground shadow-sm",r),...a})});s.displayName="Card";let l=a.forwardRef((e,t)=>{let{className:r,...a}=e;return(0,n.jsx)("div",{ref:t,className:(0,i.cn)("flex flex-col space-y-1.5 p-6",r),...a})});l.displayName="CardHeader";let o=a.forwardRef((e,t)=>{let{className:r,...a}=e;return(0,n.jsx)("div",{ref:t,className:(0,i.cn)("text-2xl font-semibold leading-none tracking-tight",r),...a})});o.displayName="CardTitle",a.forwardRef((e,t)=>{let{className:r,...a}=e;return(0,n.jsx)("div",{ref:t,className:(0,i.cn)("text-sm text-muted-foreground",r),...a})}).displayName="CardDescription";let c=a.forwardRef((e,t)=>{let{className:r,...a}=e;return(0,n.jsx)("div",{ref:t,className:(0,i.cn)("p-6 pt-0",r),...a})});c.displayName="CardContent",a.forwardRef((e,t)=>{let{className:r,...a}=e;return(0,n.jsx)("div",{ref:t,className:(0,i.cn)("flex items-center p-6 pt-0",r),...a})}).displayName="CardFooter"},2931:(e,t,r)=>{"use strict";function n(e,t){var r;if("string"!=typeof t)return null;let[n,a,...i]=t.split("//");return n===e&&a&&0!==i.length?{shortName:null!=(r=i.at(-1))?r:"",path:a,functionName:i.join("//")}:null}function a(e){return n("workflow",e)}function i(e){return n("step",e)}r.d(t,{Z:()=>i,s:()=>a})},4635:(e,t,r)=>{"use strict";r.d(t,{k:()=>a});var n=r(8033);let a=(0,n.createServerReference)("606fa85065d02470e319ae4dee279b1ecf9767e16e",n.callServer,void 0,n.findSourceMapURL,"fetchRun")},5456:(e,t,r)=>{"use strict";r.d(t,{u:()=>i});var n=r(4773),a=r(2287);function i(e){let{createKey:t,fetcher:r,params:i,live:s=!1,onLimitExceeded:l}=e,[o,c]=(0,n.useState)([]),[d,u]=(0,n.useState)(!0),[m,h]=(0,n.useState)(null),[p,v]=(0,n.useState)(!1),[f,w]=(0,n.useState)(!1),[g,x]=(0,n.useState)(!1),[_,b]=(0,n.useState)(void 0),k=(0,n.useRef)(!1),y=(0,n.useRef)(null),j=t(i),S=(0,n.useCallback)(async()=>{if(!k.current&&g)try{let e=await r(i,_,"asc",5);e.data.length>0&&(e.cursor&&b(e.cursor),c(t=>{let r=["stepId","eventId","hookId","runId","id"],n=e=>{let t=r.find(t=>e[t]);return t?e[t]:null},a=e=>{let t=e.createdAt;return t?new Date(t).getTime():0},i=new Map;for(let e of t){let t=n(e);t&&i.set(t,e)}for(let t of e.data){let e=n(t);e&&i.set(e,t)}return Array.from(i.values()).sort((e,t)=>a(e)-a(t))}))}catch(e){console.error("Live polling error:",e)}},[r,i,g,_]);return(0,n.useEffect)(()=>{c([]),v(!1),w(!1),x(!1),(async()=>{if(!k.current){k.current=!0,u(!0),h(null);try{let e,t=[];for(;;){let n=await r(i,e,"asc",100),a=n.data;if(t=[...t,...a],c(t),t.length>=1e3){w(!0),l&&l();break}if(!n.hasMore||!n.cursor){v(!0);break}(e=n.cursor)&&b(e)}}catch(e){h(e instanceof Error?e:Error(String(e)))}finally{u(!1),k.current=!1,x(!0)}}})()},[j]),(0,n.useEffect)(()=>{if(s&&g)return y.current=setInterval(S,a.Oc),()=>{y.current&&(clearInterval(y.current),y.current=null)}},[s,g,S]),(0,n.useEffect)(()=>{s&&g&&S()},[s,g]),{items:o,loading:d,error:m,hasReachedEnd:p,hasHitLimit:f,initialLoadComplete:g}}},5988:(e,t,r)=>{"use strict";r.d(t,{s:()=>o});var n=r(5386),a=r(1049),i=r(5505),s=r(4773),l=r(8257);function o(e){let{date:t,className:r="",type:o="relative"}=e,[,c]=(0,s.useState)(Date.now()),d="relative"===o?(0,a.o)(new Date(t),new Date):(0,i.B)(new Date(t),{addSuffix:!0}),u=new Date(t).toLocaleString(void 0,{year:"numeric",month:"short",day:"numeric",hour:"2-digit",minute:"2-digit",second:"2-digit",timeZoneName:"short"});return(0,s.useEffect)(()=>{let e=setInterval(()=>{c(Date.now())},1e3);return()=>clearInterval(e)},[]),(0,n.jsxs)(l.m_,{children:[(0,n.jsx)(l.k$,{asChild:!0,children:(0,n.jsx)("span",{className:"".concat(r," cursor-help border-b border-dotted"),children:d})}),(0,n.jsx)(l.ZI,{children:(0,n.jsx)("p",{children:u})})]})}},6016:(e,t,r)=>{"use strict";r.d(t,{$:()=>c});var n=r(5386),a=r(9280),i=r(7586),s=r(4773),l=r(2287);let o=(0,i.F)("inline-flex items-center justify-center gap-2 whitespace-nowrap rounded-md text-sm font-medium ring-offset-background transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50 [&_svg]:pointer-events-none [&_svg]:size-4 [&_svg]:shrink-0",{variants:{variant:{default:"bg-primary text-primary-foreground hover:bg-primary/90",destructive:"bg-destructive text-destructive-foreground hover:bg-destructive/90",outline:"border border-input bg-background hover:bg-accent hover:text-accent-foreground",secondary:"bg-secondary text-secondary-foreground hover:bg-secondary/80",ghost:"hover:bg-accent hover:text-accent-foreground",link:"text-primary underline-offset-4 hover:underline"},size:{default:"h-10 px-4 py-2",sm:"h-9 rounded-md px-3",lg:"h-11 rounded-md px-8",icon:"h-10 w-10"}},defaultVariants:{variant:"default",size:"default"}}),c=s.forwardRef((e,t)=>{let{className:r,variant:i,size:s,asChild:c=!1,...d}=e,u=c?a.DX:"button";return(0,n.jsx)(u,{className:(0,l.cn)(o({variant:i,size:s,className:r})),ref:t,...d})});c.displayName="Button"},6229:e=>{e.exports={traceNode:"trace-viewer_traceNode__EPpHb",childRow:"trace-viewer_childRow__Cq4_k",spanNode:"trace-viewer_spanNode__RjdWo",huge:"trace-viewer_huge__ldvPq",spanName:"trace-viewer_spanName__TQPrX",spanSpacer:"trace-viewer_spanSpacer__Oup0_",spanDuration:"trace-viewer_spanDuration__889FS",small:"trace-viewer_small__3Mgeo",xHover:"trace-viewer_xHover__SDoIm",selected:"trace-viewer_selected__9DCOs",spanNodeEvent:"trace-viewer_spanNodeEvent__NC_lB",eventDiamond:"trace-viewer_eventDiamond__6HyGU",customEventColor:"trace-viewer_customEventColor__pVObz",hoverInfo:"trace-viewer_hoverInfo__v_oM8",eventName:"trace-viewer_eventName__w9uvJ",eventTimestamp:"trace-viewer_eventTimestamp__Rkpqm",alignStart:"trace-viewer_alignStart__ryiEC",alignEnd:"trace-viewer_alignEnd__o4Ha4",colorVercel:"trace-viewer_colorVercel__EJedp",color0:"trace-viewer_color0__smm5S",color1:"trace-viewer_color1__gG1M7",color2:"trace-viewer_color2__FXg_f",color3:"trace-viewer_color3__nGR6u",color4:"trace-viewer_color4__t43hY",colorHighlight:"trace-viewer_colorHighlight__dgPVp",unlit:"trace-viewer_unlit___zTp3",mapContainer:"trace-viewer_mapContainer__slemC",spanDetailPanel:"trace-viewer_spanDetailPanel__gwWqO",spanDetailPanelResizer:"trace-viewer_spanDetailPanelResizer__jLr1h",spanDetailPanelTop:"trace-viewer_spanDetailPanelTop__KFwOZ",spanDetailPanelBody:"trace-viewer_spanDetailPanelBody__4mjfq",spanDetailPanelTopInfo:"trace-viewer_spanDetailPanelTopInfo__EXa6K",spanNameDetailPanel:"trace-viewer_spanNameDetailPanel__dTZKK",spanDetailPanelTruncatedHeading:"trace-viewer_spanDetailPanelTruncatedHeading__fRtSd",spanDetailPanelName:"trace-viewer_spanDetailPanelName__ixgKy",spanDetailPanelDuration:"trace-viewer_spanDetailPanelDuration__VopYl",spanDetailPanelCorner:"trace-viewer_spanDetailPanelCorner__q2atr",spanDetailPanelCornerInner:"trace-viewer_spanDetailPanelCornerInner__jpQt9",spanDetailPanelCloseVerticalRule:"trace-viewer_spanDetailPanelCloseVerticalRule__HiEA4",spanDetailPanelClose:"trace-viewer_spanDetailPanelClose__NV8h5",spanDetailPanelAttribute:"trace-viewer_spanDetailPanelAttribute__7kHaH",spanDetailPanelAttributeKey:"trace-viewer_spanDetailPanelAttributeKey__Lq39Y",spanDetailPanelAttributeValue:"trace-viewer_spanDetailPanelAttributeValue__ZsbcT",spanDetailPanelQuickLink:"trace-viewer_spanDetailPanelQuickLink__PQU8R",spanDetailPanelQuickLinkLabel:"trace-viewer_spanDetailPanelQuickLinkLabel__hDSrZ",detailGroup:"trace-viewer_detailGroup__q9vls",expanded:"trace-viewer_expanded__tgMvz",collapsed:"trace-viewer_collapsed__7UQa4",ancestorGroup:"trace-viewer_ancestorGroup__L1c_l",detailHeading:"trace-viewer_detailHeading__Tzelx",buttonLink:"trace-viewer_buttonLink__4Sr4T",note:"trace-viewer_note__H_BMB",skeleton:"trace-viewer_skeleton__HHaHu",skeletonRounded:"trace-viewer_skeletonRounded___tfB2",detailHeadingIcon:"trace-viewer_detailHeadingIcon__BKl_b",infraSpanDescription:"trace-viewer_infraSpanDescription__u_u4R",ancestorNode:"trace-viewer_ancestorNode__JEATz",ancestorText:"trace-viewer_ancestorText__pLFpE",ancestorName:"trace-viewer_ancestorName__usG_0",ancestorDuration:"trace-viewer_ancestorDuration__UxeMy",ancestorLineContainer:"trace-viewer_ancestorLineContainer__anAFR",ancestorLine:"trace-viewer_ancestorLine__MQKBZ",zoomButtonGroup:"trace-viewer_zoomButtonGroup__bW6dU","zoom-buttons-fade-in":"trace-viewer_zoom-buttons-fade-in__iwgTN",zoomButton:"trace-viewer_zoomButton__nqkXN",divider:"trace-viewer_divider__EYwDq",markersContainer:"trace-viewer_markersContainer__ljrni",markers:"trace-viewer_markers__phdeo",marker:"trace-viewer_marker__qcenH",notch:"trace-viewer_notch__U_RW0",markerLabel:"trace-viewer_markerLabel__k5WI7",eventMarkersContainer:"trace-viewer_eventMarkersContainer__PpoCp",eventMarkers:"trace-viewer_eventMarkers__TL4ep",eventMarker:"trace-viewer_eventMarker__LTOJz",cursorMarkerStickyParent:"trace-viewer_cursorMarkerStickyParent__fBYPl",cursorMarkerLabelContainer:"trace-viewer_cursorMarkerLabelContainer__3nvXM",cursorMarkerLabel:"trace-viewer_cursorMarkerLabel__G1GEQ",cursorMarkerContainer:"trace-viewer_cursorMarkerContainer__6iYUy",cursorMarker:"trace-viewer_cursorMarker__ZRhrA",cursorSelection:"trace-viewer_cursorSelection__RCPRm",traceViewer:"trace-viewer_traceViewer__8he63","span-skeleton":"trace-viewer_span-skeleton__AvhUy",mapCanvas:"trace-viewer_mapCanvas__0UJOT",zoomButtonTraceViewer:"trace-viewer_zoomButtonTraceViewer__D4Lqw",timeline:"trace-viewer_timeline__omxsu",searchBar:"trace-viewer_searchBar__fqBPw",searchInput:"trace-viewer_searchInput__9pXpo",searchInputLabel:"trace-viewer_searchInputLabel__Ki6la",searchInputPrefix:"trace-viewer_searchInputPrefix__vMKU7",mapThumb:"trace-viewer_mapThumb__uGh8v",spanDetailPanelTraceViewer:"trace-viewer_spanDetailPanelTraceViewer__cr4L3",traceViewerContent:"trace-viewer_traceViewerContent__T7h1G",inert:"trace-viewer_inert__4Vm6G",hidden:"trace-viewer_hidden__mlpPM",mobile:"trace-viewer_mobile__NWGVd"}},6810:(e,t,r)=>{"use strict";r.d(t,{W:()=>i});var n=r(5386),a=r(8257);function i(e){let{status:t,context:r,className:i}=e,s=()=>{switch(t){case"running":return"text-blue-600 dark:text-blue-400";case"completed":return"text-green-600 dark:text-green-400";case"failed":return"text-red-600 dark:text-red-400";case"cancelled":return"text-yellow-600 dark:text-yellow-400";case"pending":return"text-gray-600 dark:text-gray-400";case"paused":return"text-orange-600 dark:text-orange-400";default:return"text-gray-500 dark:text-gray-400"}};if("failed"===t&&(null==r?void 0:r.error)){let e="string"==typeof r.error?r.error:r.error instanceof Error?r.error.message:JSON.stringify(r.error);return(0,n.jsxs)(a.m_,{children:[(0,n.jsx)(a.k$,{asChild:!0,children:(0,n.jsx)("span",{className:"".concat(i," border-b border-dotted cursor-help ").concat(s()),children:t})}),(0,n.jsx)(a.ZI,{className:"max-w-md",children:(0,n.jsx)("p",{className:"text-xs whitespace-pre-wrap break-words",children:e})})]})}return(0,n.jsx)("span",{className:"".concat(i," ").concat(s()),children:t})}},7122:(e,t,r)=>{"use strict";r.d(t,{Fc:()=>o,TN:()=>d,XL:()=>c});var n=r(5386),a=r(7586),i=r(4773),s=r(2287);let l=(0,a.F)("relative w-full rounded-lg border p-4 [&>svg~*]:pl-7 [&>svg+div]:translate-y-[-3px] [&>svg]:absolute [&>svg]:left-4 [&>svg]:top-4 [&>svg]:text-foreground",{variants:{variant:{default:"bg-background text-foreground",destructive:"border-destructive/50 text-destructive dark:border-destructive [&>svg]:text-destructive"}},defaultVariants:{variant:"default"}}),o=i.forwardRef((e,t)=>{let{className:r,variant:a,...i}=e;return(0,n.jsx)("div",{ref:t,role:"alert",className:(0,s.cn)(l({variant:a}),r),...i})});o.displayName="Alert";let c=i.forwardRef((e,t)=>{let{className:r,...a}=e;return(0,n.jsx)("h5",{ref:t,className:(0,s.cn)("mb-1 font-medium leading-none tracking-tight",r),...a})});c.displayName="AlertTitle";let d=i.forwardRef((e,t)=>{let{className:r,...a}=e;return(0,n.jsx)("div",{ref:t,className:(0,s.cn)("text-sm [&_p]:leading-relaxed",r),...a})});d.displayName="AlertDescription"},7394:(e,t,r)=>{"use strict";r.d(t,{t:()=>d});var n=r(5386),a=r(3039),i=r(316),s=r(4773),l=r(7122),o=r(6016),c=r(2338);class d extends s.Component{static getDerivedStateFromError(e){return{hasError:!0,error:e}}componentDidCatch(e,t){console.error("Error caught by boundary:",e,t)}render(){return this.state.hasError&&this.state.error?this.props.fallback?this.props.fallback(this.state.error,this.handleReset):(0,n.jsxs)(c.Zp,{className:"border-destructive/50 bg-destructive/5",children:[(0,n.jsx)(c.aR,{children:(0,n.jsxs)(c.ZB,{className:"flex items-center gap-2 text-destructive",children:[(0,n.jsx)(a.A,{className:"h-5 w-5"}),this.props.title||"Error"]})}),(0,n.jsxs)(c.Wu,{className:"space-y-4",children:[(0,n.jsxs)(l.Fc,{variant:"destructive",children:[(0,n.jsx)(a.A,{className:"h-4 w-4"}),(0,n.jsx)(l.XL,{children:"Something went wrong"}),(0,n.jsx)(l.TN,{children:this.props.description||"An unexpected error occurred in this section."})]}),(0,n.jsxs)("div",{className:"bg-muted p-3 rounded-md text-sm font-mono text-muted-foreground overflow-auto max-h-48",children:[(0,n.jsx)("div",{className:"text-xs font-semibold mb-2",children:"Error details:"}),(0,n.jsx)("div",{className:"whitespace-pre-wrap break-words text-xs",children:this.state.error.message}),this.state.error.stack&&(0,n.jsx)("div",{className:"mt-2 opacity-60 text-xs",children:this.state.error.stack})]}),!1!==this.props.showReset&&(0,n.jsxs)(o.$,{variant:"outline",size:"sm",onClick:this.handleReset,className:"gap-2",children:[(0,n.jsx)(i.A,{className:"h-4 w-4"}),"Try again"]})]})]}):this.props.children}constructor(e){super(e),this.handleReset=()=>{this.setState({hasError:!1,error:null})},this.state={hasError:!1,error:null}}}},7554:(e,t,r)=>{"use strict";r.d(t,{J9:()=>eJ,b_:()=>l});var n=r(4773),a=r(2287),i=r(8033);let s=(0,i.createServerReference)("601acd38e20696bc90fc911e9c54b8900ce71e2530",i.callServer,void 0,i.findSourceMapURL,"fetchRuns");function l(e,t){var r,i,l;let{workflowName:o,status:c,limit:d=10,sortOrder:u="desc"}=t,[m,h]=(0,n.useState)(void 0),[p,v]=(0,n.useState)(!1),[f,w]=(0,n.useState)(0),[g,x]=(0,n.useState)([void 0]),[_,b]=(0,n.useState)(1),[k,y]=(0,n.useState)(new Map([[0,{data:null,isLoading:!0,error:null}]])),j=(0,n.useRef)(new Map),S=(0,n.useCallback)(async function(t,r){let n=arguments.length>2&&void 0!==arguments[2]&&arguments[2],a=null!=r?r:"initial";if(y(e=>{var r,n;let a=new Map(e);return a.set(t,{data:null!=(n=null==(r=e.get(t))?void 0:r.data)?n:null,isLoading:!0,error:null}),a}),!n&&j.current.has(a)){let e=j.current.get(a);if(e){y(r=>{let n=new Map(r);return n.set(t,{data:e.data,isLoading:!1,error:null}),n}),h(e.cursor),v(e.hasMore);return}}try{let n=await s(e,{cursor:r,sortOrder:u,limit:d,workflowName:o,status:c});j.current.set(a,{data:n.data,cursor:n.cursor,hasMore:n.hasMore}),y(e=>{let r=new Map(e);return r.set(t,{data:n.data,isLoading:!1,error:null}),r}),h(n.cursor),v(n.hasMore)}catch(r){let e=r instanceof Error?r:Error(String(r));y(r=>{var n,a;let i=new Map(r);return i.set(t,{data:null!=(a=null==(n=r.get(t))?void 0:n.data)?a:null,isLoading:!1,error:e}),i})}},[e,o,d,u,c]);(0,n.useEffect)(()=>{S(0,void 0,!0)},[S,u,e,d,o,c]);let N=(0,n.useCallback)(()=>{if(p&&m){let e=f+1;x(e=>[...e,m]),w(e),b(t=>Math.max(t,e+1)),k.has(e)||y(t=>{let r=new Map(t);return r.set(e,{data:null,isLoading:!0,error:null}),r}),S(e,m)}},[p,m,S,f,k]),T=(0,n.useCallback)(()=>{if(f>0){let e=f-1;w(e);let t=g[e];S(e,t)}},[f,g,S]),L=(0,n.useCallback)(()=>{j.current.clear(),y(new Map([[0,{data:null,isLoading:!0,error:null}]])),w(0),x([void 0]),b(1),S(0,void 0,!0)},[S]),R=null!=(i=k.get(f))?i:{data:null,isLoading:!0,error:null},M=null!=(l=null==(r=Array.from(k.values()).find(e=>e.error))?void 0:r.error)?l:null,C=Array.from(k.values()).some(e=>e.isLoading),D=p?f+2:f+1,E=f+1,I=(0,a.$g)(E,_,E===_&&p);return{data:R,allData:Array.from(k.values()),error:M,isLoading:C,currentPage:f,totalPages:D,nextPage:N,previousPage:T,hasNextPage:p,hasPreviousPage:f>0,reload:L,pageInfo:I}}var o=r(5386),c=r(2928);let d=(0,i.createServerReference)("7063646fd16e68fd4e349c525523607fee915553b6",i.callServer,void 0,i.findSourceMapURL,"fetchStep");var u=r(4635);let m=(0,i.createServerReference)("607126fddf47bc29fcf355ecf18e12be872d75e730",i.callServer,void 0,i.findSourceMapURL,"fetchHook");var h=r(6489),p=r(960),v=r(2931);let f={pending:"workflow.status.0-pending",running:"workflow.status.1-running",completed:"workflow.status.2-completed",paused:"workflow.status.3-paused",sleep:"workflow.status.4-sleep",failed:"workflow.status.5-failed",cancelled:"workflow.status.6-cancelled"},w={name:"vercel-workflow",version:"0.1"};function g(e){let t=0;switch(e){case"completed":t=1;break;case"failed":t=2;break;default:t=0}return{code:t}}function x(e){return"sleep"===("stepId"in e?e.stepName:"").toLowerCase()?f.sleep:"hookId"in e?"workflow.hook":_(e.status)}function _(e){return"pending"===e?f.pending:"running"===e?f.running:"completed"===e?f.completed:"paused"===e?f.paused:"failed"===e?f.failed:"cancelled"===e?f.cancelled:f.pending}function b(e){if(!e||!(e instanceof Date))return[0,0];let t=e.getTime();return[Math.floor(t/1e3),t%1e3*1e6]}function k(e,t){if(!e||!(e instanceof Date))return[0,0];let r=(t&&t instanceof Date?t:new Date).getTime()-e.getTime();return[Math.floor(r/1e3),r%1e3*1e6]}let y=new Set(["hook_created","hook_received","hook_disposed","step_retrying","step_failed","workflow_failed"]);function j(e){let t=!(arguments.length>1)||void 0===arguments[1]||arguments[1];return e.filter(e=>!t||y.has(e.eventType)).map(e=>{var t;return{name:e.eventType,timestamp:b(e.createdAt),attributes:{eventId:e.eventId,correlationId:e.correlationId,eventData:"eventData"in e?e.eventData:void 0},showVerticalLine:"hook_created"===(t=e.eventType)||"hook_received"===t||"hook_disposed"===t}})}function S(e){let{summary:t,children:r}=e;return(0,o.jsxs)("details",{className:"group",children:[(0,o.jsx)("summary",{className:"cursor-pointer rounded-md border px-3 py-2 text-copy-14 hover:brightness-95",style:{borderColor:"var(--ds-gray-300)",backgroundColor:"var(--ds-gray-100)",color:"var(--ds-gray-900)"},children:t}),(0,o.jsx)("div",{className:"p-2",children:r})]})}let N=e=>(0,o.jsx)("pre",{className:"text-copy-12 overflow-x-auto rounded-md border p-4",style:{borderColor:"var(--ds-gray-300)",backgroundColor:"var(--ds-gray-100)",color:"var(--ds-gray-1000)"},children:(0,o.jsx)("code",{children:JSON.stringify(e,null,2)})}),T=["workflowName","stepName","status","stepId","hookId","eventId","runId","attempt","token","correlationId","eventType","deploymentId","ownerId","projectId","environment","executionContext","createdAt","startedAt","updatedAt","completedAt","error","errorCode","metadata","eventData","input","output"],L=(e,t)=>(T.indexOf(e)||0)-(T.indexOf(t)||0),R={workflowName:e=>{var t,r;return null!=(r=null==(t=(0,v.s)(String(e)))?void 0:t.shortName)?r:"?"},stepName:e=>{var t,r;return null!=(r=null==(t=(0,v.Z)(String(e)))?void 0:t.shortName)?r:"?"},runId:e=>String(e),stepId:e=>String(e),hookId:e=>String(e),eventId:e=>String(e),status:e=>String(e),attempt:e=>String(e),token:e=>String(e),eventType:e=>String(e),correlationId:e=>String(e),deploymentId:e=>String(e),ownerId:e=>null,projectId:e=>null,environment:e=>null,executionContext:e=>null,createdAt:e=>new Date(String(e)).toLocaleString(),startedAt:e=>new Date(String(e)).toLocaleString(),updatedAt:e=>new Date(String(e)).toLocaleString(),completedAt:e=>new Date(String(e)).toLocaleString(),metadata:N,input:e=>{let t=Array.isArray(e)?e.length:0;return(0,o.jsx)(S,{summary:"Input (".concat(t," arguments)"),children:Array.isArray(e)?e.map((e,t)=>(0,o.jsx)("div",{className:"mt-2",children:N(e)},t)):N(e)})},output:e=>(0,o.jsx)(S,{summary:"Output",children:N(e)}),error:e=>(0,o.jsx)(S,{summary:"Error",children:N(e)}),errorCode:N,eventData:e=>(0,o.jsx)(S,{summary:"Event Data",children:N(e)})},M=["input","output","error","errorCode","metadata","eventData"],C=e=>{let{attribute:t,value:r,isLoading:n}=e,a=R[t];if(!a)return null;let i=a(r);return i?(0,o.jsxs)("div",{className:"relative",children:["boolean"==typeof n&&n&&(0,o.jsx)("div",{className:"absolute top-2 right-2",children:(0,o.jsx)("div",{className:"animate-spin rounded-full h-4 w-4 border-b-2",style:{borderColor:"var(--ds-gray-900)"}})}),(0,o.jsxs)("div",{className:"flex flex-col gap-0 my-2",children:[(0,o.jsx)("span",{className:"font-medium",style:{color:"var(--ds-gray-500)"},children:t}),(0,o.jsx)("span",{style:{color:"var(--ds-gray-1000)"},children:i})]},t)]}):null},D=e=>{let{data:t,fetchFunc:r,fetchKey:n}=e,{data:a,error:i,isLoading:s}=(0,h.Ay)(n,r,{fallbackData:t,revalidateOnFocus:!1}),l=a||t,c=Object.keys(l).filter(e=>!M.includes(e)).sort(L),d=Object.keys(l).filter(e=>M.includes(e)).sort(L);return(0,o.jsxs)("div",{children:[c.map(e=>(0,o.jsx)(C,{attribute:e,value:l[e]},e)),i?(0,o.jsxs)("div",{className:"text-copy-14 text-red-600",children:["Failed to load step details: ",i.message]}):d.map(e=>(0,o.jsx)(C,{isLoading:s,attribute:e,value:l[e]},e))]})};function E(e){let{id:t,config:r,events:a}=e,i=(0,n.useCallback)(()=>(0,p.u)(r,t,void 0,void 0,100,!0).then(e=>j(e.data||[],!1)),[r,t]),{data:s,error:l,isLoading:c}=(0,h.Ay)(["workflow","events",t],i,{fallbackData:a,revalidateOnFocus:!1}),d=s||a||[];return(0,o.jsxs)("div",{className:"mt-2",style:{color:"var(--ds-gray-1000)"},children:[(0,o.jsx)("h4",{children:"Associated Events"}),l?(0,o.jsxs)("div",{children:["Error loading events: ",l.message]}):null,c?(0,o.jsx)("div",{children:"Loading events..."}):null,d.length>0&&!l?(0,o.jsxs)(o.Fragment,{children:[(0,o.jsxs)("h3",{className:"text-heading-16 font-medium mt-4 mb-2",style:{color:"var(--ds-gray-1000)"},children:["Events (",d.length,")"]}),(0,o.jsx)("div",{className:"flex flex-col gap-2",children:d.map((e,t)=>(0,o.jsx)(S,{summary:(0,o.jsxs)(o.Fragment,{children:[(0,o.jsx)("span",{className:"font-medium",style:{color:"var(--ds-gray-1000)"},children:e.name})," ","-"," ",(0,o.jsx)("span",{style:{color:"var(--ds-gray-700)"},children:new Date(1e3*e.timestamp[0]+e.timestamp[1]/1e6).toLocaleString()})]}),children:(0,o.jsxs)("div",{className:"mt-2 px-4",children:[Object.entries(e.attributes).filter(e=>{let[t]=e;return"eventData"!==t}).map(e=>{let[t,r]=e;return(0,o.jsx)(C,{attribute:t,value:r},t)}),(0,o.jsxs)("div",{className:"relative",children:[l&&(0,o.jsx)("div",{children:"Error loading event data"}),!l&&!c&&e.attributes.eventData&&(0,o.jsx)(C,{isLoading:c,attribute:"eventData",value:e.attributes.eventData})]})]})},"".concat(e.name,"-").concat(t)))})]}):null]})}let I={root:{startTime:0,endTime:1,duration:1,depth:0,children:[]},spanMap:{},resourceMap:{},filter:"",selected:null,baseScale:1,scaleRatio:1,scale:1,width:640,height:480,timelineWidth:640,timelineHeight:480,panelWidth:380,panelHeight:480,scrollbarWidth:0,timelineRef:{current:null},scrollSnapshotRef:{current:void 0},memoCacheRef:{current:new Map},getQuickLinks:()=>[],withPanel:!1,isMobile:!1,customPanelComponent:null},P=e=>(e.width-e.scrollbarWidth-Number(!!(e.selected&&e.withPanel))*e.panelWidth)/e.root.duration,A=(0,n.createContext)({state:I,dispatch:()=>{}});A.displayName="TraceViewerContext";let F=(e,t)=>{switch(t.type){case"setRoot":return e.scrollSnapshotRef.current=void 0,e.memoCacheRef.current.clear(),F({...e,root:t.root,spanMap:t.spanMap,resourceMap:Object.fromEntries(t.resources.map(e=>{let{name:t,attributes:r}=e;return[t,r]}))},{type:"detectBaseScale"});case"setSize":{let r=t.height-56-40-24,n=e.withPanel&&t.width<=768,a={...e,width:t.width,height:t.height,timelineWidth:t.width-Number(!!(e.selected&&e.withPanel&&!n))*e.panelWidth,timelineHeight:r,panelHeight:r,isMobile:n};return a.width!==e.width&&(a=F(a,{type:"detectBaseScale"})),a}case"setPanelWidth":{let r=Math.max(240,Math.min(t.width,e.width-240));return{...e,timelineWidth:e.width-r,panelWidth:r}}case"setFilter":return{...e,filter:t.filter};case"deselect":return F({...e,selected:null,timelineWidth:e.width},{type:"minScale"});case"select":{let r=e.spanMap[t.id];if(!r)return e;return{...e,selected:r,timelineWidth:e.width-(e.withPanel&&!e.isMobile?e.panelWidth:0)}}case"escape":if(e.selected)return F(e,{type:"deselect"});return F(e,{type:"resetScale"});case"toggleSelection":{var r;let n=e;if(e.selected&&(n=F(n,{type:"deselect"})),(null==(r=e.selected)?void 0:r.span.spanId)===t.id)return n;return F(n,{type:"select",id:t.id})}case"detectBaseScale":{let t=(e.width-e.scrollbarWidth)/e.root.duration;return{...e,baseScale:t,scale:t*e.scaleRatio}}case"setScale":return{...e,scaleRatio:t.scale,scale:e.baseScale*t.scale};case"resetScale":return F(e,{type:"scaleToRange",t1:e.root.startTime,t2:e.root.endTime});case"scaleToNode":{let r=e.spanMap[t.id];if(!r)return e;return F(F(e,{type:"setScale",scale:(e.width-e.scrollbarWidth-(e.withPanel&&!e.isMobile?e.panelWidth:0))/r.duration/e.baseScale}),{type:"setScrollSnapshot",anchorT:r.startTime-e.root.startTime,anchorX:0})}case"scaleToRange":{let r=Math.abs(t.t1-t.t2);return F(F(e,{type:"setScale",scale:(e.width-e.scrollbarWidth-(e.selected&&e.withPanel?e.panelWidth:0))/r/e.baseScale}),{type:"setScrollSnapshot",anchorT:Math.min(t.t1,t.t2)-e.root.startTime,anchorX:0})}case"adjustScaleRatio":{let{scaleRatio:r}=e;switch(t.direction){case -1:r*=.8;break;case 1:r*=1.25;break;default:r=1}let n=e.timelineRef.current;if(!n)return console.warn("timelineRef is null"),e;let{clientWidth:a,scrollLeft:i}=n;return F(F({...e,scaleRatio:r,scale:e.baseScale*r},{type:"minScale"}),{type:"setScrollSnapshot",anchorT:(i+.5*a)/e.scale,anchorX:.5*a})}case"trackpadScale":{let r=Math.max(P(e)/e.baseScale,e.scaleRatio*(1+.2*Math.sign(t.delta)*Math.sqrt(Math.abs(t.delta))));return F({...e,scaleRatio:r,scale:e.baseScale*r},{type:"setScrollSnapshot",anchorT:t.anchorT,anchorX:t.anchorX})}case"minScale":{let t=P(e);if(e.scale>=t)return e;return{...e,scale:t,scaleRatio:t/e.baseScale}}case"setScrollSnapshot":{let r=e.timelineRef.current;if(!r)return e;let{anchorT:n,anchorX:a}=t,i=n*e.scale-a,{scrollTop:s}=r,l=(s-24-8)/26,o=l+Math.ceil(e.timelineHeight/26);return e.scrollSnapshotRef.current={anchorT:n,anchorX:a,scrollLeft:i,scrollTop:s,startTime:e.root.startTime+i/e.scale,endTime:e.root.startTime+(i+e.timelineWidth)/e.scale,startRow:l,endRow:o,scale:e.scale},e}case"setWithPanel":if(e.withPanel===t.withPanel)return e;return{...e,withPanel:t.withPanel};case"forceRender":return e.memoCacheRef.current.set("",{}),{...e}}};function H(e){let{getQuickLinks:t,withPanel:r=!1,children:a,customSpanClassNameFunc:i,customSpanEventClassNameFunc:s,customPanelComponent:l=null}=e,c=(0,n.useRef)(null),d=(0,n.useRef)(void 0),u=(0,n.useRef)(t);u.current=t;let m=(0,n.useRef)(new Map),h=(0,n.useRef)(new Map),[p,v]=(0,n.useReducer)(F,I,e=>({...e,scrollbarWidth:(()=>{if(!("document"in globalThis))return 0;let e=document.createElement("div");e.style.width="".concat(400,"px"),e.style.height="".concat(400,"px"),e.style.overflow="scroll",document.body.appendChild(e);let t=400-e.scrollWidth;return e.remove(),t})(),timelineRef:c,scrollSnapshotRef:d,customSpanClassNameFunc:i,customSpanEventClassNameFunc:s,customPanelComponent:l,memoCacheRef:m,withPanel:r,getQuickLinks:e=>{var t;let r=e.spanId,n=h.current.get(r);if(n)return n;let a=(null==(t=u.current)?void 0:t.call(u,e))||[];return h.current.set(r,a),a}}));(0,n.useEffect)(()=>v({type:"setWithPanel",withPanel:r}),[r]);let f=(0,n.useMemo)(()=>({state:p,dispatch:v}),[p,v]);return(0,o.jsx)(A.Provider,{value:f,children:a})}let W=()=>(0,n.useContext)(A);var V=r(6229),O=r.n(V);function B(e){let[t,r]=e;return 1e3*t+r/1e6}function z(e){return[Math.floor(e/1e3),e%1e3*1e3]}let q=new Intl.NumberFormat(void 0,{maximumFractionDigits:2});function U(e){return 0===e?"0":e>=1e3?"".concat(q.format(e/1e3),"s"):"".concat(q.format(e),"ms")}let K=new Intl.NumberFormat(void 0,{minimumFractionDigits:2,maximumFractionDigits:2});function $(e){return e>=1e3?"".concat(K.format(e/1e3),"s"):"".concat(K.format(e),"ms")}let G=(e,t)=>e.duration*t<64,X=(e,t)=>e.duration*t>=500,Z=e=>e.isVercel?String(O().colorVercel):String(O()["color".concat(e.resourceIndex%5)]),Q=(e,t)=>{let r=X(e,t),n=e.isHovered&&!r&&!1!==e.isHighlighted;return(0,c.$)(O().spanNode,r&&O().huge,G(e,t)&&O().small,e.isSelected&&O().selected,n&&O().xHover,e.isHighlighted?O().colorHighlight:Z(e),!1===e.isHighlighted&&O().unlit)},J=(0,n.memo)(function(e){let{root:t,scale:r,spans:n,scrollSnapshotRef:a,cache:i,customSpanClassNameFunc:s,customSpanEventClassNameFunc:l}=e;return n.map(e=>(0,o.jsx)(Y,{cacheKey:i.get(e.span.spanId),customSpanEventClassNameFunc:l,customSpanClassNameFunc:s,node:e,root:t,scale:r,scrollSnapshotRef:a},e.span.spanId))}),Y=(0,n.memo)(function(e){let{node:t,root:r,scale:a,scrollSnapshotRef:i,customSpanClassNameFunc:s,customSpanEventClassNameFunc:l}=e,d=(0,n.useRef)(null);t.ref=d;let{span:u}=t,m=t.isInstrumentationHint?"Get Started":U(t.duration),h=(t.startTime-r.startTime)*a,p=24+26*t.row,v=t.duration*a,f=24,w=X(t,a),g=G(t,a),x=t.isHovered&&!w&&!1!==t.isHighlighted;g&&!x&&(f*=.4,p+=(24-f)*.5);let _=!1;if(x){let{duration:e,endTime:n}=r,a=i.current;a&&(e=a.endTime-a.startTime,n=a.endTime),_=n-t.startTime<.25*e}let b=s?s(t):"";return(0,o.jsxs)(o.Fragment,{children:[(0,o.jsx)("button",{"aria-label":"".concat(u.name," - ").concat(m),className:(0,c.$)(Q(t,a),b),"data-span-id":u.spanId,"data-start-time":t.startTime-r.startTime,"data-right-side":_,ref:d,style:{"--span-width":"".concat(v,"px"),minWidth:x?v:void 0,width:x?void 0:v,height:f,maxWidth:x&&!_?(r.endTime-t.startTime)*a:void 0,containIntrinsicWidth:x?void 0:v,containIntrinsicHeight:f,left:_?void 0:h,right:_?(r.endTime-t.endTime)*a:void 0,top:p},type:"button",children:g&&!x?null:(0,o.jsxs)(o.Fragment,{children:[(0,o.jsx)("span",{className:O().spanName,children:t.label||u.name}),w?(0,o.jsx)("span",{className:O().spanSpacer}):null,x||v>128?(0,o.jsx)("span",{className:O().spanDuration,children:m}):null]})}),t.events&&!g?t.events.map(e=>(0,o.jsx)(ee,{customSpanEventClassNameFunc:l,event:e,node:t,root:r,scale:a},e.key)):null]})}),ee=(0,n.memo)(function(e){let{event:t,node:r,root:a,scale:i,customSpanEventClassNameFunc:s}=e,l=(0,n.useRef)(null);t.ref=l;let{event:{name:d}}=t,u=U(t.timestamp-a.startTime),m=(t.timestamp-a.startTime)*i,h=24+26*r.row,p=s?s(t):"";return(0,o.jsxs)("div",{title:"".concat(d," at ").concat(u),className:(0,c.$)(O().spanNodeEvent,p,r.isHighlighted?O().colorHighlight:Z(r),!1===r.isHighlighted&&O().unlit),"data-hovered":t.isHovered,ref:l,style:{left:m,top:h},children:[(0,o.jsxs)("div",{className:(0,c.$)(O().hoverInfo,(t.timestamp-r.startTime)/r.duration<.5?O().alignStart:O().alignEnd),children:[(0,o.jsx)("span",{className:O().eventName,children:d}),(0,o.jsx)("span",{className:O().eventTimestamp,children:u})]}),(0,o.jsx)("div",{className:O().eventDiamond})]})}),et={"gray-700":"var(--ds-gray-700)","gray-900":"var(--ds-gray-900)"};function er(e){let{size:t=16,color:r="gray-700"}=e,n={color:et[r]||r};return(0,o.jsxs)("svg",{width:t,height:t,viewBox:"0 0 24 24",fill:"none",style:n,"aria-hidden":!0,children:[(0,o.jsx)("title",{children:"Cross"}),(0,o.jsx)("path",{d:"M6 6l12 12M18 6L6 18",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round"})]})}function en(e){let{size:t=16}=e;return(0,o.jsxs)("svg",{width:t,height:t,viewBox:"0 0 24 24",fill:"none","aria-hidden":!0,className:O().detailHeadingIcon,children:[(0,o.jsx)("title",{children:"Chevron Down"}),(0,o.jsx)("path",{d:"M6 9l6 6 6-6",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"})]})}function ea(e){let{size:t=16,color:r="gray-900"}=e,n={color:et[r]||r};return(0,o.jsxs)("svg",{width:t,height:t,viewBox:"0 0 24 24",fill:"none",style:n,"aria-hidden":!0,children:[(0,o.jsx)("title",{children:"External Small"}),(0,o.jsx)("path",{d:"M14 4h6m0 0v6m0-6L10 14",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"}),(0,o.jsx)("path",{d:"M20 14v4a2 2 0 0 1-2 2H6a2 2 0 0 1-2-2V6a2 2 0 0 1 2-2h4",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round"})]})}function ei(e){let{as:t,className:r,href:n,children:a,...i}=e;return"span"!==(t||"a")&&n?(0,o.jsx)("a",{className:r,href:n,...i,children:a}):(0,o.jsx)("span",{className:r,...i,children:a})}function es(e){let{className:t,children:r,size:n,...a}=e;return(0,o.jsx)("a",{...a,className:(0,c.$)(O().buttonLink,t),children:r})}function el(e){let{children:t,className:r}=e;return(0,o.jsx)("div",{className:(0,c.$)(O().note,r),children:t})}function eo(e){let{width:t,height:r,rounded:n}=e;return(0,o.jsx)("span",{className:(0,c.$)(O().skeleton,n&&O().skeletonRounded),style:{width:t,height:r},"aria-hidden":!0})}let ec=e=>"".concat((100*e).toFixed(3),"%"),ed=(e,t)=>e<t?-1:+(e>t),eu=e=>{let t={};for(let[r,n]of Object.entries(e)){let e=r.indexOf("."),a="",i="";-1!==e?(a=r.substring(0,e),i=r.substring(e+1)):i=r;let s=t[a];s||(s={prefix:a,attributes:[]},t[a]=s),s.attributes.push({key:r,suffix:i,value:String(n)})}let r=Array.from(Object.values(t)).sort((e,t)=>ed(e.prefix,t.prefix));for(let e of r)e.attributes.sort((e,t)=>ed(e.suffix,t.suffix));return r},em=()=>{var e;let{state:{root:t,selected:r,resourceMap:a,getQuickLinks:i},dispatch:s}=W(),l=(0,n.useMemo)(()=>((e,t)=>{let r=[];if(!t)return r;for(let e=t;"parent"in e;e=e.parent)r.unshift(e);return r})(0,r),[t,r]),d=(0,n.useMemo)(()=>{var e;return eu(null!=(e=null==r?void 0:r.span.attributes)?e:{})},[r]),u=(0,n.useMemo)(()=>{let e=null==r?void 0:r.span.resource;if(!e)return[];let t=a[e];return t?eu(t):[]},[a,r]);if(!r)return null;let{span:m}=r,h=e_(r);return(0,o.jsxs)(o.Fragment,{children:[r.isVercel?(0,o.jsx)(eb,{node:r}):null,r.isInstrumentationHint?(0,o.jsx)(ej,{}):null,!r.isInstrumentationHint&&l.length?(0,o.jsx)(ev,{className:O().ancestorGroup,name:"Location",children:l.map(e=>(0,o.jsxs)("button",{className:O().ancestorNode,onClick:()=>s({type:"select",id:e.span.spanId}),type:"button",children:[(0,o.jsxs)("div",{className:O().ancestorText,children:[(0,o.jsx)("span",{className:O().ancestorName,children:e.label||e.span.name}),(0,o.jsx)("span",{className:O().ancestorDuration,children:U(e.duration)})]}),(0,o.jsx)("span",{"aria-hidden":!0,className:O().ancestorLineContainer,children:(0,o.jsx)("span",{className:(0,c.$)(O().ancestorLine,Z(e)),style:{left:ec((e.startTime-t.startTime)/t.duration),width:ec(e.duration/t.duration)}})})]},"".concat(r.span.spanId,".").concat(e.span.spanId)))}):null,h?(0,o.jsx)(ek,{getQuickLinks:i,span:r.span}):null,(null==(e=r.events)?void 0:e.length)?(0,o.jsx)(ev,{name:"Events",children:r.events.map(e=>(0,o.jsxs)(n.Fragment,{children:[(0,o.jsxs)("dl",{className:O().spanDetailPanelAttribute,children:[(0,o.jsx)("dt",{className:O().spanDetailPanelAttributeKey,children:e.event.name}),(0,o.jsx)("dd",{className:O().spanDetailPanelAttributeValue,children:U(e.timestamp-t.startTime)})]}),Object.entries(e.event.attributes).map(t=>{let[r,n]=t;return(0,o.jsx)(eS,{name:"".concat(e.event.name,".").concat(r),value:n},r)})]},e.key))}):null,d.length?(0,o.jsx)(ev,{name:"Attributes",children:d.map(e=>(0,o.jsx)(n.Fragment,{children:e.attributes.map(e=>{let{key:t,value:r}=e;return(0,o.jsx)(eS,{name:t,value:r},t)})},e.prefix))}):null,u.length?(0,o.jsx)(ev,{name:"Resource",children:u.map(e=>(0,o.jsx)(n.Fragment,{children:e.attributes.map(e=>{let{key:t,value:r}=e;return(0,o.jsx)(eS,{name:t,value:r},t)})},e.prefix))}):null,r.isInstrumentationHint?null:(0,o.jsxs)(ev,{name:"Library",children:[(0,o.jsx)(eS,{name:"name",value:m.library.name}),m.library.version?(0,o.jsx)(eS,{name:"version",value:m.library.version}):null]})]})};function eh(e){let{attached:t=!1}=e,{state:{selected:r,isMobile:n,customPanelComponent:a},dispatch:i}=W();if(!r)return null;let{span:s}=r;return(0,o.jsxs)("div",{className:(0,c.$)(O().spanDetailPanel,n&&O().mobile),children:[t&&!n?(0,o.jsx)(eN,{}):null,(0,o.jsx)("div",{className:O().spanDetailPanelTop,children:(0,o.jsxs)("div",{className:O().spanDetailPanelTopInfo,children:[(0,o.jsxs)("div",{className:O().spanDetailPanelTruncatedHeading,children:[r.isInstrumentationHint?null:(0,o.jsx)("span",{className:O().spanDetailPanelDuration,children:U(r.duration)}),(0,o.jsx)("span",{className:O().spanDetailPanelName,title:s.name,children:s.name})]}),(0,o.jsxs)("div",{className:O().spanDetailPanelCorner,children:[(0,o.jsx)("div",{className:O().spanDetailPanelCloseVerticalRule}),(0,o.jsx)("button",{"aria-label":"Close Span Details",className:O().spanDetailPanelClose,onClick:()=>i({type:"deselect"}),type:"button",children:(0,o.jsx)(er,{color:"gray-700",size:24})})]})]})}),(0,o.jsx)("div",{className:(0,c.$)("flex gap-3",O().spanDetailPanelBody),children:a||(0,o.jsx)(em,{})})]})}let ep="vc-trace-span-exp:";function ev(e){let{name:t,className:r="",children:a}=e,[i,s]=(0,n.useState)(()=>!("localStorage"in globalThis)||"0"!==localStorage.getItem("".concat(ep).concat(t))),l=(0,n.useCallback)(()=>{s(e=>{let r=!e;return localStorage.setItem("".concat(ep).concat(t),String(Number(r))),r})},[t]);return(0,o.jsxs)("div",{className:(0,c.$)(O().detailGroup,i?O().expanded:O().collapsed,r),children:[(0,o.jsxs)("button",{className:O().detailHeading,onClick:l,type:"button",children:[(0,o.jsx)("span",{children:t}),(0,o.jsx)(en,{})]}),i?a:null]})}let ef=new Set(["OPTIONS","HEAD","GET","PUT","POST","DELETE"]),ew={"Resolve Deployment":"How long it took Vercel's routing layer to retrieve details for the deployment.","Resolve Cache":"How long it took Vercel's routing layer to check for a cached function invocation.","Resolve Route":"How long it took Vercel's routing layer to resolve routing rules, including redirects and rewrites.","Invoke Middleware":"How long it took this middleware to start and run user code.","Invoke Function":"How long it took this Vercel Function to start and run user code.",waitUntil:"How long it took to run user code inside of waitUntil.","Start VM":"How long it took to start the Virtual Machine which contains the Vercel Function.","Spawn Node.js":"How long it took the Virtual Machine to start the Node.js runtime.","Spawn Python":"How long it took the Virtual Machine to start the Python runtime.","Init User Code":"How long it took to import the user code and run any globally-scoped code."},eg=new Set(["Start VM","Spawn Node.js","Spawn Python","Init User Code"]),ex=e=>{if(!e||!("span"in e))return null;let t=e.span.attributes,r=t["vercel.region"]||t["vercel.function.region"];return r?String(r):null},e_=e=>{if(!e.isVercel)return!1;let{name:t}=e.span,r=t.indexOf(" ");if(-1===r)return!1;let n=t.substring(0,r);return ef.has(n)};function eb(e){let{node:t}=e,{name:r}=t.span,n=ew[r];if(!n&&e_(t)&&(n="How long it took for Vercel to process the request and send the response."),!n)return null;let a=(e=>{let{name:t}=e.span,r=ex(e),n=ex(e.parent);return"true"===e.span.attributes["vercel.middleware.internal"]?"The Vercel Toolbar created this middleware.":eg.has(t)||"Invoke Function"===t&&e.children.some(e=>eg.has(e.span.name))?"This function encountered a cold start.":r&&n&&r!==n?"This request was routed across regions.":null})(t);return(0,o.jsx)(ev,{name:"What is this?",children:(0,o.jsxs)("div",{className:O().infraSpanDescription,children:[(0,o.jsx)("span",{children:n}),a?(0,o.jsx)(el,{children:a}):a]})})}let ek=(0,n.memo)(function(e){let{getQuickLinks:t,span:r}=e,n=t(r);return n.length?(0,o.jsx)(ev,{name:"Links",children:n.map(e=>{let{key:t,value:r}=e;return(0,o.jsx)(ey,{link:r,name:t},t)})}):null});function ey(e){let{name:t,link:r}=e,a=function(e){let[t,r]=(0,n.useState)({}),a=void 0!==e.__resolvedValue||void 0!==e.__rejectedValue;return(0,n.useEffect)(()=>{a||e.then(t=>{e.__resolvedValue=t}).catch(t=>{e.__rejectedValue=t}).finally(()=>r({}))},[e,a]),e.__resolvedValue}(r);return(0,o.jsxs)(ei,{as:a?void 0:"span",className:(0,c.$)(O().spanDetailPanelAttribute,O().spanDetailPanelQuickLink),href:(null==a?void 0:a.href)||"",children:[(0,o.jsx)("span",{className:O().spanDetailPanelAttributeKey,children:t}),(0,o.jsx)("span",{className:(0,c.$)(O().spanDetailPanelAttributeValue,O().spanDetailPanelQuickLinkLabel),children:a?(0,o.jsxs)(o.Fragment,{children:[a.label,a.icon||(0,o.jsx)(ea,{color:"gray-900"})]}):(0,o.jsxs)(o.Fragment,{children:[(0,o.jsx)(eo,{height:18,width:32+8*t.length}),(0,o.jsx)(eo,{height:18,rounded:!0,width:18})]})})]})}function ej(){return(0,o.jsx)(ev,{name:"What is this?",children:(0,o.jsxs)("div",{className:O().infraSpanDescription,children:[(0,o.jsx)("span",{children:"You can visualize your application's spans alongside Vercel's spans in this viewer."}),(0,o.jsx)(es,{href:"https://vercel.com/docs/session-tracing#adding-custom-spans",size:"small",target:"_blank",children:"Get Started"})]})})}function eS(e){let{name:t,value:r}=e;return(0,o.jsxs)("dl",{className:O().spanDetailPanelAttribute,children:[(0,o.jsx)("dt",{className:O().spanDetailPanelAttributeKey,children:t}),(0,o.jsx)("dd",{className:O().spanDetailPanelAttributeValue,title:String(r),children:String(r)})]})}function eN(){let{state:{panelWidth:e},dispatch:t}=W(),r=(0,n.useRef)({start:{x:0,width:e},x:0,width:e,isHeld:!1});r.current.width=e;let a=(0,n.useCallback)(e=>{if("mouse"!==e.pointerType)return;e.preventDefault();let t=r.current;t.start.x=e.clientX,t.x=e.clientX,t.start.width=t.width,t.isHeld=!0},[]),i=(0,n.useCallback)(()=>{t({type:"setPanelWidth",width:I.panelWidth})},[t]);return(0,n.useEffect)(()=>{let e=0,n=()=>{let e=r.current;t({type:"setPanelWidth",width:e.start.width+e.start.x-e.x})},a=t=>{r.current.isHeld&&(t.preventDefault(),r.current.x=t.clientX,cancelAnimationFrame(e),e=requestAnimationFrame(n))},i=()=>{r.current.isHeld=!1};return window.addEventListener("pointermove",a),window.addEventListener("pointerup",i),()=>{window.removeEventListener("pointermove",a),window.removeEventListener("pointerup",i)}},[t]),(0,o.jsx)("div",{"aria-hidden":!0,className:O().spanDetailPanelResizer,onDoubleClick:i,onPointerDown:a})}function eT(e){let t=(0,n.useRef)({});return{setStyle:(0,n.useCallback)((r,n)=>{if(t.current[r]=n,e.current){if(!n)return void e.current.style.removeProperty(r);e.current.style.setProperty(r,n)}},[e]),styleRef:t,style:{...t.current}}}let eL=(0,n.memo)(function(e){let{timelineRef:t,rows:r,scale:a}=e,{state:{root:i,baseScale:s,timelineWidth:l,width:c,scrollbarWidth:d}}=W(),u=c+16,m=(()=>{let[e,t]=(0,n.useState)(1);return(0,n.useLayoutEffect)(()=>{let r=()=>t("devicePixelRatio"in globalThis&&globalThis.devicePixelRatio||1),n=matchMedia("(resolution: ".concat(e,"dppx)"));return n.addEventListener("change",r),r(),()=>{n.removeEventListener("change",r)}},[e]),e})(),h=(0,n.useRef)(null),p=(0,n.useRef)(null),v=c/(c-d)*Math.min(c/l,s/a),f=Math.min(c,(l-d)*v);(0,n.useEffect)(()=>{let e,r=!1,n=0,a=e=>{var t;return!!(null==(t=h.current)?void 0:t.contains(e))},i=0,s=()=>{if(!r||!e)return;let a=t.current;a&&(a.scrollLeft=(n-.5*f-e.left)/v)},l=e=>{({clientX:n}=e),cancelAnimationFrame(i),i=requestAnimationFrame(s)},o=t=>{var n;a(t.target)&&(r=!0,e=null==(n=h.current)?void 0:n.getBoundingClientRect(),l(t))},c=()=>{r=!1,e=void 0},d=e=>{a(e.target)&&e.cancelable&&e.preventDefault()},u=e=>{r&&e.cancelable&&e.preventDefault()};return window.addEventListener("pointerdown",o),window.addEventListener("pointermove",l),window.addEventListener("pointerup",c),window.addEventListener("blur",c),window.addEventListener("touchstart",d,{passive:!1}),window.addEventListener("touchmove",u,{passive:!1}),()=>{window.removeEventListener("pointerdown",o),window.removeEventListener("pointermove",l),window.removeEventListener("pointerup",c),window.removeEventListener("blur",c),window.removeEventListener("touchstart",d),window.removeEventListener("touchmove",u),cancelAnimationFrame(i)}},[t,v,f]),(0,n.useEffect)(()=>{let e=p.current,t=null==e?void 0:e.getContext("2d");if(!e||!t)return;let n=requestAnimationFrame(()=>{t.resetTransform(),t.clearRect(0,0,e.width,e.height),t.scale(m,m);let n=(u-16)/i.duration;for(let e of(t.fillStyle="#ccc",t.beginPath(),r))for(let r of e){let e=7+4*r.row;if(e>=45)break;let a=8+(r.startTime-i.startTime)*n,s=r.duration*n;t.roundRect(a,e,s,3,3)}t.fill()});return()=>cancelAnimationFrame(n)},[m,i,u,r]);let w=(0,n.useRef)(null),{style:g,setStyle:x}=eT(w);return(0,n.useLayoutEffect)(()=>{let e=t.current;if(!e)return;let r=0,n=()=>{x("transform","translateX(".concat(8+e.scrollLeft*v,"px)"))};n();let a=()=>{cancelAnimationFrame(r),r=requestAnimationFrame(n)};return e.addEventListener("scroll",a),()=>{cancelAnimationFrame(r),e.removeEventListener("scroll",a)}},[t,v,x]),(0,o.jsxs)("div",{className:O().mapContainer,ref:h,style:{width:f>0?u:"100%",height:56},children:[(0,o.jsx)("canvas",{className:O().mapCanvas,height:56*m,ref:p,style:{width:u,height:56},width:u*m}),(0,o.jsx)("div",{className:O().mapThumb,ref:w,style:{transform:g.transform,width:f>0?f:"calc(100% - ".concat(16,"px)"),top:2,height:52}})]})}),eR=[1,2,4,5,8,10];function eM(e){let{scale:t}=e,{state:{root:r}}=W(),n=r.duration,a=Math.floor(Math.log10(n)),i=Math.max(2,10**a*(Math.floor(Math.log10(.5*n))===a?1:.5)),s=i*t,l=1;for(let e of eR){if(i/e<24)break;l=e}i/=l,s/=l;let d=Math.ceil(n/i),u=Math.ceil(100/s)||1;return(0,o.jsx)("div",{className:O().markersContainer,children:(0,o.jsx)("div",{"aria-hidden":!0,className:O().markers,style:{width:Math.floor(r.duration*t+15),visibility:-1!==t?"visible":"hidden","--marker-width":"".concat(s,"px")},children:Array(d).fill(null).map((e,t)=>{let r=t%u==0;return(0,o.jsx)("span",{className:(0,c.$)(O().marker,!r&&O().notch),children:r?(0,o.jsx)("span",{className:O().markerLabel,children:U(i*t)}):null},String(t))})})})}function eC(e){let{events:t,root:r,scale:a}=e,i=(0,n.useMemo)(()=>t.filter(e=>!1!==e.event.showVerticalLine),[t]);return(0,o.jsx)("div",{className:O().eventMarkersContainer,children:(0,o.jsx)("div",{"aria-hidden":!0,className:O().eventMarkers,style:{width:Math.floor(r.duration*a)},children:i.map(e=>(0,o.jsx)("span",{className:(0,c.$)(O().eventMarker),style:{left:Math.floor((e.timestamp-r.startTime)*a),...e.event.color&&{borderLeftColor:e.event.color}}},e.key))})})}function eD(e){let{memoCacheRef:t,timelineRef:r,root:a,spans:i,events:s,scale:l,dispatch:c,scrollSnapshotRef:d}=e,u=(0,n.useRef)(!1),m=(0,n.useRef)(i);m.current=i;let h=(0,n.useRef)(s);h.current=s;let p=(0,n.useRef)(null),{style:v,setStyle:f}=eT(p),w=(0,n.useRef)(null),g=(0,n.useRef)(null),{style:x,setStyle:_}=eT(g),b=(0,n.useRef)(void 0),k=(0,n.useRef)(null),{style:y,setStyle:j}=eT(k),S=(0,n.useRef)(0);(0,n.useEffect)(()=>{let e=r.current;if(!e)return;let n=S.current,i=0,s=!1,o=!1,d=!1,p=!1,v=0,g=0,x=Date.now()+500,y=()=>{b.current||(b.current=e.getBoundingClientRect())},T=e=>b.current?(e-24-8)/26:0,L=()=>{let e=t.current;for(let t of m.current)t.isHovered&&(t.isHovered=!1,e.set(t.span.spanId,{}));c({type:"forceRender"})},R=0,M=()=>{var r,p,S,N,C,D,E,I;if(!u.current)return;b.current||y();let P=b.current;if(!P)return;let{scrollLeft:A,scrollTop:F}=e,H=Math.max(0,Math.min(n+A-P.left-8,a.duration*l)),W="".concat(H-A+8,"px");_("left",W),f("left",W);let V=a.startTime+H/l,O=V-a.startTime;if(O<0||O>a.duration?null==(r=w.current)||r.removeAttribute("data-text"):null==(p=w.current)||p.setAttribute("data-text",$(O)),s){let e,t,r=n-i,s=Math.abs(r);if(!d){if(s<4)return;d=!0,j("display","flex"),L()}r>0?(j("left",""),j("right","0")):(j("left","0"),j("right","")),j("width","".concat(s,"px"));let o=Math.max(0,Math.min(i+A-P.left-8,a.duration*l))/l;o<O?(e=o,t=O):(e=O,t=o),null==(S=k.current)||S.setAttribute("data-range","".concat($(e)," — ").concat($(t))),null==(N=k.current)||N.setAttribute("data-duration","".concat($(t-e)," selected"))}if(Date.now()<x){R=requestAnimationFrame(M);return}if(A!==v||F!==g){v=A,g=F,R=requestAnimationFrame(M);return}if(n-P.left<128?null==(C=w.current)||C.setAttribute("data-align","left"):n-P.left>P.width-128?null==(D=w.current)||D.setAttribute("data-align","right"):null==(E=w.current)||E.removeAttribute("data-align"),!d&&!o){let e=t.current,r=T(F)-2,n=T(F+P.height)+2;for(let t of m.current){let a=t.row>=r&&t.row<=n&&V>=t.startTime&&V<=t.endTime;t.isHovered!==a&&(t.isHovered=a,e.set(t.span.spanId,{}))}let a=12/l;for(let e of h.current){let t=V>=e.timestamp-a&&V<=e.timestamp+a;if(e.isHovered===t)continue;e.isHovered=t;let r=null==(I=e.ref)?void 0:I.current;r&&r.setAttribute("data-hovered",String(t))}c({type:"forceRender"})}};R=requestAnimationFrame(M);let C=e=>{"mouse"===e.pointerType&&(u.current=!0)},D=()=>{u.current&&(u.current=!1,L())},E=e=>{let{clientX:t}=e;S.current=n=t,cancelAnimationFrame(R),R=requestAnimationFrame(M)},I=e=>{e.preventDefault()},P=e=>{var t;if(2===e.button)p=!0,e.preventDefault();else{if(0!==e.button)return;p=!1}(null==(t=r.current)?void 0:t.contains(e.target))?(i=n,s=!0):(o=!0,requestAnimationFrame(L))},A=t=>{if(o=!1,!s||(s=!1,!d))return;if(d=!1,j("display",""),j("left",""),j("right",""),j("width",""),t.preventDefault(),t.stopImmediatePropagation(),p){p=!1;return}b.current||y();let r=b.current;if(!r)return;let{scrollLeft:u}=e,m=Math.max(0,Math.min((i+u-r.left-8)/l,a.duration)),h=Math.max(0,Math.min((n+u-r.left-8)/l,a.duration));c({type:"scaleToRange",t1:m+a.startTime,t2:h+a.startTime})},F=e=>{s&&"Escape"===e.key&&(p=!0,A(e))},H=()=>{b.current=void 0,N.current=void 0,cancelAnimationFrame(R),R=requestAnimationFrame(M)},W=()=>{cancelAnimationFrame(R),R=requestAnimationFrame(M)},V=new ResizeObserver(()=>{b.current=void 0});return V.observe(e),window.addEventListener("mousemove",E),e.addEventListener("contextmenu",I),window.addEventListener("mousedown",P),window.addEventListener("mouseup",A),window.addEventListener("blur",A),window.addEventListener("keydown",F,!0),window.addEventListener("scroll",H),e.addEventListener("scroll",W),e.addEventListener("pointerenter",C),e.addEventListener("pointerleave",D),()=>{V.disconnect(),window.removeEventListener("mousemove",E),e.removeEventListener("contextmenu",I),window.removeEventListener("mousedown",P),window.removeEventListener("mouseup",A),window.removeEventListener("blur",A),window.removeEventListener("keydown",F,!0),window.removeEventListener("scroll",H),e.removeEventListener("scroll",W),e.removeEventListener("pointerenter",C),e.removeEventListener("pointerleave",D),cancelAnimationFrame(R),S.current=n,L()}},[c,a,l,_,f,j,t,r,d]);let N=(0,n.useRef)(void 0);var T=e=>{let t=r.current;if(!t)return;null!=b.current||(b.current=t.getBoundingClientRect());let n=b.current,a=Math.max(0,Math.min(S.current-n.left-8,n.width-16)),i=0,s=N.current;(null==s?void 0:s.anchorX)===a?i=s.anchorT:N.current=s={anchorT:i=(t.scrollLeft+a)/l,anchorX:a},c({type:"trackpadScale",delta:e/64,anchorT:i,anchorX:a})};let L=(0,n.useRef)(T);return L.current=T,(0,n.useEffect)(()=>{let e=0,t=0,r=()=>{L.current(e),e=0},n=n=>{if(!n.ctrlKey&&!n.metaKey)return;n.preventDefault();let a=-n.deltaY;switch(n.deltaMode){case WheelEvent.DOM_DELTA_PAGE:a*=window.innerHeight;break;case WheelEvent.DOM_DELTA_LINE:a*=20}e+=a,cancelAnimationFrame(t),t=requestAnimationFrame(r)};return window.addEventListener("wheel",n,{passive:!1}),()=>{window.removeEventListener("wheel",n),cancelAnimationFrame(t)}},[]),(0,o.jsxs)(o.Fragment,{children:[(0,o.jsx)("div",{className:O().cursorMarkerStickyParent,children:(0,o.jsx)("div",{className:O().cursorMarkerLabelContainer,ref:p,style:v,children:(0,o.jsx)("div",{className:O().cursorMarkerLabel,ref:w})})}),(0,o.jsx)("div",{className:O().cursorMarkerStickyParent,children:(0,o.jsx)("div",{className:O().cursorMarkerContainer,ref:g,style:x,children:(0,o.jsx)("div",{className:O().cursorMarker,children:(0,o.jsx)("div",{className:O().cursorSelection,ref:k,style:y})})})})]})}function eE(e){let{height:t,width:r,value:n,placeholder:a,onChange:i}=e;return(0,o.jsxs)("label",{className:O().searchInputLabel,children:[(0,o.jsx)("div",{className:O().searchInputPrefix,children:(0,o.jsx)(eI,{})}),(0,o.jsx)("input",{type:"search",value:n,placeholder:a,onChange:i,style:{height:t,width:r}})]})}function eI(){return(0,o.jsxs)("svg",{width:16,height:16,viewBox:"0 0 16 16",fill:"none","aria-hidden":"true",focusable:"false",children:[(0,o.jsx)("circle",{cx:"7",cy:"7",r:"4.5",stroke:"currentColor",strokeWidth:"1.5"}),(0,o.jsx)("path",{d:"M11.5 11.5L14 14",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round"})]})}function eP(){return(0,o.jsx)("nav",{className:O().searchBar,children:(0,o.jsx)(eA,{})})}function eA(){let{dispatch:e}=W(),[t,r]=(0,n.useState)("");return(0,n.useEffect)(()=>{let r=setTimeout(()=>e({type:"setFilter",filter:t}),100);return()=>{clearTimeout(r)}},[e,t]),(0,o.jsx)("div",{className:O().searchInput,children:(0,o.jsx)(eE,{height:40,onChange:e=>r(e.target.value),placeholder:"Search spans…",value:t,width:"100%"})})}function eF(e){let{size:t=16}=e;return(0,o.jsxs)("svg",{width:t,height:t,viewBox:"0 0 24 24",fill:"none","aria-hidden":!0,children:[(0,o.jsx)("title",{children:"Zoom In"}),(0,o.jsx)("path",{d:"M11 19a8 8 0 1 0 0-16 8 8 0 0 0 0 16Z",stroke:"currentColor",strokeWidth:"2"}),(0,o.jsx)("path",{d:"M11 8v6M8 11h6",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round"}),(0,o.jsx)("path",{d:"M20 20l-3.5-3.5",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round"})]})}function eH(e){let{size:t=16}=e;return(0,o.jsxs)("svg",{width:t,height:t,viewBox:"0 0 24 24",fill:"none","aria-hidden":!0,children:[(0,o.jsx)("title",{children:"Zoom Out"}),(0,o.jsx)("path",{d:"M11 19a8 8 0 1 0 0-16 8 8 0 0 0 0 16Z",stroke:"currentColor",strokeWidth:"2"}),(0,o.jsx)("path",{d:"M8 11h6",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round"}),(0,o.jsx)("path",{d:"M20 20l-3.5-3.5",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round"})]})}function eW(e){let{size:t=16}=e;return(0,o.jsxs)("svg",{width:t,height:t,viewBox:"0 0 24 24",fill:"none","aria-hidden":!0,children:[(0,o.jsx)("title",{children:"Minus"}),(0,o.jsx)("path",{d:"M6 12h12",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round"})]})}function eV(){let{dispatch:e}=W(),t=(0,n.useCallback)(()=>{e({type:"adjustScaleRatio",direction:1})},[e]),r=(0,n.useCallback)(()=>{e({type:"adjustScaleRatio",direction:-1})},[e]),a=(0,n.useCallback)(()=>{e({type:"adjustScaleRatio",direction:0})},[e]);return(0,o.jsxs)("div",{className:O().zoomButtonGroup,children:[(0,o.jsx)("button",{"aria-label":"Zoom Out",className:O().zoomButton,onClick:r,type:"button",children:(0,o.jsx)(eH,{size:18})}),(0,o.jsx)("div",{className:O().divider}),(0,o.jsx)("button",{"aria-label":"Reset Zoom",className:O().zoomButton,onClick:a,type:"button",children:(0,o.jsx)(eW,{size:18})}),(0,o.jsx)("div",{className:O().divider}),(0,o.jsx)("button",{"aria-label":"Zoom In",className:O().zoomButton,onClick:t,type:"button",children:(0,o.jsx)(eF,{size:18})})]})}let eO=e=>{if(!e.events.length)return;let t="".concat(e.spanId,":ev");return e.events.map((e,r)=>({key:"".concat(t).concat(r),timestamp:B(e.timestamp),event:e})).sort((e,t)=>e.timestamp-t.timestamp)},eB=(e,t)=>{let r=e.duration*t;return e.isVisible=r>=2,e.isHovered=!1,e.isVisible};function ez(){return[]}let eq={traceId:"skeleton",spans:[{parentSpanId:"",spanId:"root",name:"root span",kind:1,resource:"vercel.runtime",startTime:[5e3,0],endTime:[6e3,0],duration:[1e3,0],library:{name:"vercel-site"},status:{code:1},attributes:{"vercel.ownerId":"team_abc"},traceFlags:1,events:[],links:[]}],resources:[{name:"vercel.runtime",attributes:{}}],rootSpanId:"root"};function eU(e){var t;let{trace:a=eq,className:i="",scrollLock:s=!1,height:l,withPanel:d=!1,highlightedSpans:u}=e,m=a===eq,{state:h,dispatch:p}=W(),{timelineRef:v,scrollSnapshotRef:f}=h,w=h.memoCacheRef.current,g=(null!=(t=null==u?void 0:u.length)?t:0)>0;(0,n.useEffect)(()=>{let{root:e,map:t}=(e=>{let{spans:t}=e,r={startTime:0,endTime:0,duration:0,depth:0,children:[]},n={},a=new Map,i=e=>{let t=a.get(e);if(t)return t;let r=a.size+1;return a.set(e,r),r},s=!1;for(let e of t){let t,a=B(e.startTime),l=B(e.endTime),o=B(e.duration);l>r.endTime&&(r.endTime=l,r.duration=l-r.startTime),(0===r.startTime||a<r.startTime)&&(r.startTime=a,r.duration=r.endTime-a);let c=e.resource.startsWith("vercel.");c||(s=!0);let d=c&&("vercel.serverless-runtime"!==e.resource||!("http.method"in e.attributes)),u=d?0:i(e.resource);d&&(t="▲ ".concat(e.name)),n[e.spanId]={parent:null,startTime:a,endTime:l,duration:o,span:e,depth:0,label:t,events:eO(e),isVercel:d,children:[],resourceIndex:u}}let l=(e,t)=>{let a;t&&(a=n[t])||(a=r),e.parent=a,a.children.push(e)},o=e=>{for(let t of("parent"in e&&(e.depth=e.parent.depth+1),e.children))o(t)},c=1,d=(e,t)=>{if("parent"in e&&e.span.name===t){let t=e.endTime,r=e=>e.children.length?e.children.map(r).sort((e,t)=>e.duration-t.duration)[0]||e:"waitUntil"===e.span.name?(t=e.startTime,e.parent):e,a=r(e),i="instrumentation-hint-".concat(c++),s=.05*e.duration,l=e.startTime+s,o=Math.max(l+s,Math.min(t-.01*e.duration,e.endTime-s)),d=o-l,u={parent:a,startTime:l,endTime:o,duration:d,span:{spanId:i,name:"Add your spans here",resource:"",kind:0,library:{name:""},status:{code:200},traceFlags:0,attributes:{},links:[],events:[],startTime:z(l),endTime:z(o),duration:z(d)},depth:e.depth+1,isVercel:!1,isInstrumentationHint:!0,children:[],resourceIndex:1};return a.children.push(u),n[i]=u,!0}for(let r of e.children)if(d(r,t))return!0;return!1};for(let e of Object.values(n))l(e,e.span.parentSpanId);if(o(r),!s){for(let e of["Invoke Function","Invoke Middleware","Vercel Runtime"])if(d(r,e))break}return{root:r,map:n}})(a);p({type:"setRoot",root:e,spanMap:t,resources:a.resources||[]})},[p,a]);let{rows:x,spans:_,events:b,scale:k}=(e=>{let{state:t,dispatch:a}=W(),{root:i,filter:s,scale:l,timelineRef:o,timelineWidth:c,spanMap:d,scrollSnapshotRef:u,selected:m,memoCacheRef:h}=t,p=function(e){let[t,r]=(0,n.useState)(e);return(0,n.useEffect)(()=>{if(t===e)return;let n=0,a=0,i=()=>{if(++n<=3){a=requestAnimationFrame(i);return}r(e)};return i(),()=>{cancelAnimationFrame(a)}},[t,e]),t}(t.timelineHeight),v=(0,n.useRef)(0),[f,w]=(0,n.useState)(ez),[g,x]=(0,n.useState)(ez),[_,b]=(0,n.useState)(ez),[k,y]=(0,n.useState)(-1),j=(0,n.useRef)(void 0);return(0,n.useEffect)(()=>{var e;return null==(e=j.current)?void 0:e.call(j,s)},[s]),(0,n.useEffect)(()=>{if(null==e?void 0:e.length){for(let t of f)for(let r of t){let t=e.includes(r.span.spanId);r.isHighlighted!==t&&(r.isHighlighted=t,h.current.set(r.span.spanId,{}))}a({type:"forceRender"})}},[f,e,a,h]),(0,n.useEffect)(()=>{if(!i.startTime)return;let e=new Worker(r.tu(new URL(r.p+r.u(793),r.b))),t=++v.current;e.addEventListener("message",e=>{let r=e.data;switch(r.type){case"setRowsResult":if(r.isEnd)for(let e of r.rows)for(let t of e){var n,i;t.span=null!=(i=null==(n=d[t.span.spanId])?void 0:n.span)?i:t.span}w(r.rows);break;case"updateHighlight":{if(r.requestId!==t)return;let{matches:e}=r;w(t=>{for(let r of t)for(let t of r){let r=e.has(t.span.spanId);t.isHighlighted!==r&&(t.isHighlighted=r,h.current.set(t.span.spanId,{}))}return t}),a({type:"forceRender"})}}});let n={requestId:t,type:"calculateSpanPositions",root:i};return e.postMessage(n),j.current=r=>{let n=r.trim().toLocaleLowerCase();if(!n)return void w(e=>e.map(e=>e.map(e=>(e.isHighlighted=void 0,{...e}))));let a={type:"filterSpans",requestId:t=++v.current,root:i,filter:n};e.postMessage(a)},()=>{e.terminate()}},[i,d,a,h]),(0,n.useEffect)(()=>{if(!f.length)return;let e=o.current,t=u.current,r=!1,n=!1,a=0,s=0,d=Math.max(500,.5*c),m=Array(f.length).fill(null),h=e=>t?e<t.startRow?e-t.startRow:e>t.endRow?e-t.endRow:0:0,v=e=>{if(!t)return 0;let r=0;e.endTime<t.startTime?r=t.startTime-e.endTime:e.startTime>t.endTime&&(r=e.startTime-t.endTime);let n=Math.abs(h(e.row));return r||n?Math.sqrt((r/l)**2+(24*n+2)**2):0},w=0,g=()=>{(r||!t)&&(r=!1,(()=>{if(!e)return;let{scrollLeft:r,scrollTop:n}=e,a=(n-24-8)/26,s=a+Math.ceil(p/26);u.current=t={anchorT:r/l,anchorX:0,scrollLeft:r,scrollTop:n,startTime:i.startTime+r/l,endTime:i.startTime+(r+c)/l,startRow:a,endRow:s,scale:l};for(let e=m.length;e--;)m[e]=null})()),(()=>{var e;n=!0;let r=Math.min(1+s+Math.ceil(null!=(e=null==t?void 0:t.endRow)?e:1/0),f.length);for(let e=r;e--;){if(m[e])continue;let t=h(e);if(Math.abs(t)>s){if(n=!1,t>0)continue;break}let r=[],i=f[e];if(i){for(let e of i){if(!eB(e,l))continue;let t=v(e);a=Math.max(t,a),r.push({d:t,span:e})}m[e]=r}}})();let o=[],_=[];for(let e of m)if(e)for(let{d:t,span:r}of e)!(t>s)&&(o.push(r),r.events&&_.push(...r.events));s<d&&(!n||s<a)&&(s=Math.min(d,s+100),w=requestAnimationFrame(g)),x(o),b(_),y(l)};g();let _=Date.now(),k=e=>{(e.ctrlKey||e.metaKey)&&(_=Date.now())};null==e||e.addEventListener("wheel",k);let j=()=>{Date.now()-_<=50||(r=!0,cancelAnimationFrame(w),w=requestAnimationFrame(g))};return null==e||e.addEventListener("scroll",j),()=>{cancelAnimationFrame(w),null==e||e.removeEventListener("wheel",k),null==e||e.removeEventListener("scroll",j)}},[f,i,l,u,o,c,p]),(0,n.useEffect)(()=>{var e;let t;if(!m)return;for(let e of g)if(e.span.spanId===m.span.spanId){t=e;break}let r=null==t||null==(e=t.ref)?void 0:e.current;if(t&&r)return t.isSelected=!0,r.className=Q(t,l),()=>{t.isSelected=!1,r.className=Q(t,l)}},[g,l,m]),{rows:f,spans:g,events:_,scale:k}})(u),y=(0,n.useRef)(null);(0,n.useLayoutEffect)(()=>{let e=y.current;if(!e)return;let t=()=>{let t=e.getBoundingClientRect();p({type:"setSize",width:t.width-16,height:t.height})};t();let r=new ResizeObserver(t);return r.observe(e),window.addEventListener("resize",t),()=>{r.disconnect(),window.removeEventListener("resize",t)}},[p]);let j=(0,n.useRef)({t:0,x:-1,y:-1,spanId:""}),S=(0,n.useCallback)(e=>{let t=j.current,r=Date.now(),{clientX:n,clientY:a}=e,i=Math.sqrt((n-t.x)**2+(a-t.y)**2);if(r-t.t<=500&&i<=8)return(e.stopPropagation(),e.preventDefault(),t.spanId)?(p({type:"select",id:t.spanId}),void p({type:"scaleToNode",id:t.spanId})):void p({type:"resetScale"});let s=e.target;if(!s.closest(".".concat(String(O().timeline))))return;let l=s.closest("[data-span-id]"),o=(null==l?void 0:l.dataset.spanId)||"";j.current={x:n,y:a,t:r,spanId:o},o&&(p({type:"toggleSelection",id:o}),e.stopPropagation())},[p]);(0,n.useLayoutEffect)(()=>{let e=v.current;if(!e)return;let t=f.current;t&&(e.scrollLeft=t.anchorT*k-t.anchorX)},[f,v,k]),(0,n.useEffect)(()=>{var e;let t=null==(e=h.selected)?void 0:e.span.spanId;if(!t)return;let r=setTimeout(()=>{let e=h.timelineRef.current,r=null==e?void 0:e.querySelector('[data-span-id="'.concat(t,'"]'));if(!e||!r)return;let n=e.getBoundingClientRect(),a=r.getBoundingClientRect();a.width<n.width&&(a.left<n.left||a.right>n.right||a.top<n.top||a.bottom>n.bottom)&&r.scrollIntoView({block:"nearest",inline:"center",behavior:"smooth"})},500);return()=>{clearTimeout(r)}},[h.selected,h.timelineRef]),(0,n.useEffect)(()=>{let e=e=>{"Escape"===e.key&&p({type:"escape"})};return window.addEventListener("keydown",e),()=>{window.removeEventListener("keydown",e)}},[p]),(0,n.useEffect)(()=>{if(!s)return;let e=document.documentElement,t=document.body;e.style.overflow="clip",t.style.overflow="clip";let r=e=>{(null==e?void 0:e.cancelable)?e.preventDefault():window.scrollTo({left:0,top:0,behavior:"instant"})};return r(),window.addEventListener("scroll",r,{passive:!1}),()=>{e.style.overflow="",t.style.overflow="",window.removeEventListener("scroll",r)}},[s]);let N=Math.max(h.timelineHeight-h.scrollbarWidth,26+26*x.length-2+84),T=!!(h.isMobile&&h.selected);return(0,o.jsxs)("div",{className:(0,c.$)(O().traceViewer,m&&O().skeleton,i),onClickCapture:S,ref:y,style:{height:l,"--timeline-padding":"".concat(8,"px"),"--row-height":"".concat(24,"px"),"--row-padding":"".concat(2,"px"),"--search-height":"".concat(40*!g,"px"),"--search-gap":"".concat(g?2:8,"px"),"--map-height":"".concat(56,"px"),"--timeline-width":"".concat(h.timelineWidth,"px"),"--timeline-height":"".concat(h.timelineHeight,"px"),"--timeline-scroll-width":"".concat(Math.round(h.root.duration*h.scale),"px"),"--panel-width":"".concat(h.panelWidth,"px"),"--panel-height":"".concat(h.panelHeight,"px"),"--height":"".concat(h.height,"px"),"--scrollbar-width":"".concat(h.scrollbarWidth,"px"),"--marker-height":"".concat(24,"px"),"--marker-notch-height":"".concat(8,"px")},children:[g?null:(0,o.jsx)(eP,{}),(0,o.jsx)(eL,{rows:x,scale:k,timelineRef:v}),(0,o.jsxs)("div",{className:(0,c.$)(O().traceViewerContent,T&&O().inert),children:[(0,o.jsx)("div",{className:O().timeline,ref:v,children:(0,o.jsx)("div",{style:{position:"relative",width:h.timelineWidth,height:h.timelineHeight-16,padding:8,paddingBottom:0},children:(0,o.jsxs)("div",{className:O().traceNode,style:{width:h.root.duration*k||void 0,height:N-16},children:[(0,o.jsx)(eM,{scale:k}),(0,o.jsx)(eC,{events:b,root:h.root,scale:k}),(0,o.jsx)(eD,{dispatch:p,events:b,memoCacheRef:h.memoCacheRef,root:h.root,scale:k,scrollSnapshotRef:f,spans:_,timelineRef:v}),(0,o.jsx)(J,{cacheKey:w.get(""),cache:w,customSpanClassNameFunc:h.customSpanClassNameFunc,customSpanEventClassNameFunc:h.customSpanEventClassNameFunc,root:h.root,scale:k,scrollSnapshotRef:f,spans:_})]})})}),(0,o.jsx)("div",{className:O().zoomButtonTraceViewer,children:(0,o.jsx)(eV,{})})]}),d?(0,o.jsx)("div",{className:(0,c.$)(O().spanDetailPanelTraceViewer,!h.selected&&O().hidden,h.isMobile&&O().mobile),children:(0,o.jsx)(eh,{attached:!0})}):null]})}function eK(e){let{config:t}=e,{state:r}=W(),{selected:a}=r,{resource:i,data:s}=(null==a?void 0:a.span.attributes)||{resource:void 0,data:void 0},l=(0,n.useMemo)(()=>{let e,r;if("step"===i)e=()=>d(t,s.runId,s.stepId),r=["workflow","step",s.stepId];else if("run"===i)e=()=>(0,u.k)(t,s.runId),r=["workflow","run",s.runId];else{if("hook"!==i)return(0,o.jsxs)("div",{className:"text-copy-14 text-red-600",children:["Unsupported resource: ",i]});e=()=>m(t,s.hookId),r=["workflow","hook",s.hookId]}return(0,o.jsx)(D,{data:s,fetchFunc:e,fetchKey:r})},[i,s,t]),h=(0,n.useMemo)(()=>"step"===i?s.stepId:"run"===i?s.runId:"hook"===i?s.hookId:void 0,[i,s]);return a&&i&&s&&h?(0,o.jsxs)("div",{className:(0,c.A)("flex flex-col px-2"),children:[l,"run"!==i&&(0,o.jsx)(E,{id:h,config:t,events:a.span.events})]}):null}var e$=r(1998),eG=r.n(e$);function eX(e){let t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];if(t&&"pending"===e)return eG().spanPendingStriped;switch(e){case"running":return eG().spanRunning;case"pending":return eG().spanPending;case"completed":return eG().spanCompleted;case"cancelled":return eG().spanCancelled;case"paused":return eG().spanPaused;case"failed":return eG().spanFailed;default:return""}}let eZ=e=>{let t=e.span.attributes,r=null==t?void 0:t.resource;if("step"===r){let e=t.data,r=null==e?void 0:e.stepName;if(r&&String(r).toLowerCase().includes("sleep"))return eG().spanSleep;let n=(null==e?void 0:e.status)==="pending";return eX(null==e?void 0:e.status,n)}if("run"===r){let e=t.data;return eX(null==e?void 0:e.status,!1)}return"hook"===r?eG().spanHook:""},eQ=e=>{let t=e.event.name;return"step_failed"===t||"workflow_failed"===t?eG().eventFailed:"step_retrying"===t?eG().eventRetrying:"hook_created"===t||"hook_received"===t||"hook_disposed"===t?eG().eventHook:eG().eventDefault},eJ=e=>{let{run:t,steps:r,hooks:a,events:i,config:s,isLoading:l}=e,[c]=(0,n.useState)(()=>new Date),d=(0,n.useMemo)(()=>{let e=r.slice().sort((e,t)=>new Date(e.createdAt).getTime()-new Date(t.createdAt).getTime()),n=new Map,s=new Map,l=[];for(let t of i){let r=t.correlationId;if(r){let i=e.find(e=>e.stepId===r),o=a.find(e=>e.hookId===r);if(i){let e=n.get(r)||[];e.push(t),n.set(r,e)}else if(o){let e=s.get(r)||[];e.push(t),s.set(r,e)}else l.push(t)}else l.push(t)}let o=e.map((r,a)=>{let i=0===a?t.runId:String(e[a-1].stepId),s=n.get(r.stepId)||[];return function(e,t,r,n){var a,i;let s=null!=n?n:new Date,l=(0,v.Z)(String(e.stepName)),o=_(e.status),c=null!=(a=e.completedAt)?a:s,d=j(r);return{spanId:String(e.stepId),parentSpanId:t,name:null!=(i=null==l?void 0:l.shortName)?i:"",kind:1,resource:o,library:w,status:g(e.status),traceFlags:1,attributes:{resource:"step",data:e},links:[],events:d,startTime:b(e.startedAt),endTime:b(c),duration:k(e.startedAt,c)}}(r,i,s,c)}),d=a.map(e=>{let r=s.get(e.hookId)||[];return function(e,t,r,n){let a=null!=n?n:new Date,i=j(r);return{spanId:String(e.hookId),parentSpanId:t,name:String(e.hookId),kind:1,resource:x(e),library:w,status:{code:1},traceFlags:1,attributes:{resource:"hook",data:e},links:[],events:i,startTime:b(e.createdAt),endTime:b(a),duration:k(e.createdAt,a)}}(e,t.runId,r,c)});return{traceId:t.runId,rootSpanId:t.runId,spans:[function(e,t,r){var n,a,i,s;let l=null!=r?r:new Date,o=null!=(a=e.startedAt)?a:e.createdAt,c=null!=(i=e.completedAt)?i:l,d=j(t);return{spanId:String(e.runId),parentSpanId:void 0,name:String(null!=(s=null==(n=(0,v.s)(e.workflowName))?void 0:n.shortName)?s:"?"),kind:1,resource:x(e),library:w,status:g(e.status),traceFlags:1,attributes:{resource:"run",data:e},links:[],events:d,startTime:b(o),endTime:b(c),duration:k(o,c)}}(t,l,c),...o,...d],resources:[{name:"workflow",attributes:{"service.name":"vercel-workflow"}}]}},[t,r,a,i,c]);return(0,o.jsx)(H,{withPanel:!0,customSpanClassNameFunc:eZ,customSpanEventClassNameFunc:eQ,customPanelComponent:(0,o.jsx)(eK,{config:s}),children:(0,o.jsx)(eU,{height:800,trace:l?void 0:d,withPanel:!0})})}},7973:(e,t,r)=>{"use strict";r.d(t,{h:()=>a});var n=r(8033);let a=(0,n.createServerReference)("7cea6216e71bbd1d88d28dc17d3bb3015a3498ceb3",n.callServer,void 0,n.findSourceMapURL,"fetchHooks")},8052:(e,t,r)=>{"use strict";r.d(t,{Nt:()=>l,dL:()=>o,g0:()=>c,nO:()=>d});var n=r(3283),a=r(4773);let i={backend:"embedded",dataDir:"../../workbench/nextjs-turbopack/.next/workflow-data",port:"3000",env:"production"},s=["backend","env","authToken","project","team","port","dataDir"];function l(){let e=(0,n.useSearchParams)();return(0,a.useMemo)(()=>{let t={...i};for(let r of s){let n=e.get(r);n&&(t[r]=n)}return t},[e])}function o(){let e=(0,n.useRouter)(),t=(0,n.usePathname)(),r=(0,n.useSearchParams)();return(0,a.useMemo)(()=>n=>{let a=new URLSearchParams(r.toString());for(let e of s){let t=n[e];null!=t&&""!==t?(t!==i[e]||r.has(e))&&a.set(e,t):a.delete(e)}let l=a.toString(),o=l?"".concat(t,"?").concat(l):t;e.push(o)},[e,t,r])}function c(e,t,r){let n=function(e){let t=new URLSearchParams;for(let r of s){let n=e[r];null!=n&&""!==n&&n!==i[r]&&t.set(r,n)}return t}(t);if(r)for(let[e,t]of Object.entries(r))null!=t&&""!==t&&n.set(e,t);let a=n.toString();return a?"".concat(e,"?").concat(a):e}let d=e=>({WORKFLOW_TARGET_WORLD:e.backend,WORKFLOW_VERCEL_ENV:e.env,WORKFLOW_VERCEL_AUTH_TOKEN:e.authToken,WORKFLOW_VERCEL_PROJECT:e.project,WORKFLOW_VERCEL_TEAM:e.team})},8257:(e,t,r)=>{"use strict";r.d(t,{ZI:()=>c,k$:()=>o,m_:()=>l});var n=r(5386),a=r(8251),i=r(4773),s=r(2287);a.Kq;let l=a.bL,o=a.l9,c=i.forwardRef((e,t)=>{let{className:r,sideOffset:i=4,...l}=e;return(0,n.jsx)(a.UC,{ref:t,sideOffset:i,className:(0,s.cn)("z-50 overflow-hidden rounded-md border bg-popover px-3 py-1.5 text-sm text-popover-foreground shadow-md animate-in fade-in-0 zoom-in-95 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",r),...l})});c.displayName=a.UC.displayName}}]);
@@ -1 +0,0 @@
1
- "use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[687],{406:(e,t,n)=>{n.d(t,{A:()=>r});let r=(0,n(8258).A)("ChevronDown",[["path",{d:"m6 9 6 6 6-6",key:"qrunsl"}]])},2304:(e,t,n)=>{n.d(t,{UC:()=>tL,YJ:()=>tI,In:()=>tM,q7:()=>tD,VF:()=>tB,p4:()=>tK,JU:()=>tO,ZL:()=>tj,bL:()=>tT,wn:()=>tW,PP:()=>tF,wv:()=>t_,l9:()=>tA,WT:()=>tN,LM:()=>tP});var r,o,l,i=n(4773),a=n(1471);function u(e,[t,n]){return Math.min(n,Math.max(t,e))}var s=n(4053);function c(e,t,n){if(!t.has(e))throw TypeError("attempted to "+n+" private field on non-instance");return t.get(e)}function d(e,t){var n=c(e,t,"get");return n.get?n.get.call(e):n.value}function f(e,t,n){var r=c(e,t,"set");if(r.set)r.set.call(e,n);else{if(!r.writable)throw TypeError("attempted to set read only private field");r.value=n}return n}var p=n(7328),h=n(5034),v=n(9280),m=n(5386),g=new WeakMap;function y(e,t){if("at"in Array.prototype)return Array.prototype.at.call(e,t);let n=function(e,t){let n=e.length,r=w(t),o=r>=0?r:n+r;return o<0||o>=n?-1:o}(e,t);return -1===n?void 0:e[n]}function w(e){return e!=e||0===e?0:Math.trunc(e)}o=new WeakMap,class e extends Map{set(e,t){return g.get(this)&&(this.has(e)?d(this,o)[d(this,o).indexOf(e)]=e:d(this,o).push(e)),super.set(e,t),this}insert(e,t,n){let r,l=this.has(t),i=d(this,o).length,a=w(e),u=a>=0?a:i+a,s=u<0||u>=i?-1:u;if(s===this.size||l&&s===this.size-1||-1===s)return this.set(t,n),this;let c=this.size+ +!l;a<0&&u++;let f=[...d(this,o)],p=!1;for(let e=u;e<c;e++)if(u===e){let o=f[e];f[e]===t&&(o=f[e+1]),l&&this.delete(t),r=this.get(o),this.set(t,n)}else{p||f[e-1]!==t||(p=!0);let n=f[p?e:e-1],o=r;r=this.get(n),this.delete(n),this.set(n,o)}return this}with(t,n,r){let o=new e(this);return o.insert(t,n,r),o}before(e){let t=d(this,o).indexOf(e)-1;if(!(t<0))return this.entryAt(t)}setBefore(e,t,n){let r=d(this,o).indexOf(e);return -1===r?this:this.insert(r,t,n)}after(e){let t=d(this,o).indexOf(e);if(-1!==(t=-1===t||t===this.size-1?-1:t+1))return this.entryAt(t)}setAfter(e,t,n){let r=d(this,o).indexOf(e);return -1===r?this:this.insert(r+1,t,n)}first(){return this.entryAt(0)}last(){return this.entryAt(-1)}clear(){return f(this,o,[]),super.clear()}delete(e){let t=super.delete(e);return t&&d(this,o).splice(d(this,o).indexOf(e),1),t}deleteAt(e){let t=this.keyAt(e);return void 0!==t&&this.delete(t)}at(e){let t=y(d(this,o),e);if(void 0!==t)return this.get(t)}entryAt(e){let t=y(d(this,o),e);if(void 0!==t)return[t,this.get(t)]}indexOf(e){return d(this,o).indexOf(e)}keyAt(e){return y(d(this,o),e)}from(e,t){let n=this.indexOf(e);if(-1===n)return;let r=n+t;return r<0&&(r=0),r>=this.size&&(r=this.size-1),this.at(r)}keyFrom(e,t){let n=this.indexOf(e);if(-1===n)return;let r=n+t;return r<0&&(r=0),r>=this.size&&(r=this.size-1),this.keyAt(r)}find(e,t){let n=0;for(let r of this){if(Reflect.apply(e,t,[r,n,this]))return r;n++}}findIndex(e,t){let n=0;for(let r of this){if(Reflect.apply(e,t,[r,n,this]))return n;n++}return -1}filter(t,n){let r=[],o=0;for(let e of this)Reflect.apply(t,n,[e,o,this])&&r.push(e),o++;return new e(r)}map(t,n){let r=[],o=0;for(let e of this)r.push([e[0],Reflect.apply(t,n,[e,o,this])]),o++;return new e(r)}reduce(){for(var e=arguments.length,t=Array(e),n=0;n<e;n++)t[n]=arguments[n];let[r,o]=t,l=0,i=null!=o?o:this.at(0);for(let e of this)i=0===l&&1===t.length?e:Reflect.apply(r,this,[i,e,l,this]),l++;return i}reduceRight(){for(var e=arguments.length,t=Array(e),n=0;n<e;n++)t[n]=arguments[n];let[r,o]=t,l=null!=o?o:this.at(-1);for(let e=this.size-1;e>=0;e--){let n=this.at(e);l=e===this.size-1&&1===t.length?n:Reflect.apply(r,this,[l,n,e,this])}return l}toSorted(t){return new e([...this.entries()].sort(t))}toReversed(){let t=new e;for(let e=this.size-1;e>=0;e--){let n=this.keyAt(e),r=this.get(n);t.set(n,r)}return t}toSpliced(){for(var t=arguments.length,n=Array(t),r=0;r<t;r++)n[r]=arguments[r];let o=[...this.entries()];return o.splice(...n),new e(o)}slice(t,n){let r=new e,o=this.size-1;if(void 0===t)return r;t<0&&(t+=this.size),void 0!==n&&n>0&&(o=n-1);for(let e=t;e<=o;e++){let t=this.keyAt(e),n=this.get(t);r.set(t,n)}return r}every(e,t){let n=0;for(let r of this){if(!Reflect.apply(e,t,[r,n,this]))return!1;n++}return!0}some(e,t){let n=0;for(let r of this){if(Reflect.apply(e,t,[r,n,this]))return!0;n++}return!1}constructor(e){super(e),function(e,t,n){if(t.has(e))throw TypeError("Cannot initialize the same private elements twice on an object");t.set(e,n)}(this,o,{writable:!0,value:void 0}),f(this,o,[...super.keys()]),g.set(this,!0)}};var b=i.createContext(void 0),x=n(7740),S=0;function E(){let e=document.createElement("span");return e.setAttribute("data-radix-focus-guard",""),e.tabIndex=0,e.style.outline="none",e.style.opacity="0",e.style.position="fixed",e.style.pointerEvents="none",e}var C=n(63),R=n(819),k="focusScope.autoFocusOnMount",T="focusScope.autoFocusOnUnmount",A={bubbles:!1,cancelable:!0},N=i.forwardRef((e,t)=>{let{loop:n=!1,trapped:r=!1,onMountAutoFocus:o,onUnmountAutoFocus:l,...a}=e,[u,s]=i.useState(null),c=(0,R.c)(o),d=(0,R.c)(l),f=i.useRef(null),p=(0,h.s)(t,e=>s(e)),v=i.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;i.useEffect(()=>{if(r){let e=function(e){if(v.paused||!u)return;let t=e.target;u.contains(t)?f.current=t:L(f.current,{select:!0})},t=function(e){if(v.paused||!u)return;let t=e.relatedTarget;null!==t&&(u.contains(t)||L(f.current,{select:!0}))};document.addEventListener("focusin",e),document.addEventListener("focusout",t);let n=new MutationObserver(function(e){if(document.activeElement===document.body)for(let t of e)t.removedNodes.length>0&&L(u)});return u&&n.observe(u,{childList:!0,subtree:!0}),()=>{document.removeEventListener("focusin",e),document.removeEventListener("focusout",t),n.disconnect()}}},[r,u,v.paused]),i.useEffect(()=>{if(u){P.add(v);let e=document.activeElement;if(!u.contains(e)){let t=new CustomEvent(k,A);u.addEventListener(k,c),u.dispatchEvent(t),t.defaultPrevented||(function(e){let{select:t=!1}=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=document.activeElement;for(let r of e)if(L(r,{select:t}),document.activeElement!==n)return}(M(u).filter(e=>"A"!==e.tagName),{select:!0}),document.activeElement===e&&L(u))}return()=>{u.removeEventListener(k,c),setTimeout(()=>{let t=new CustomEvent(T,A);u.addEventListener(T,d),u.dispatchEvent(t),t.defaultPrevented||L(null!=e?e:document.body,{select:!0}),u.removeEventListener(T,d),P.remove(v)},0)}}},[u,c,d,v]);let g=i.useCallback(e=>{if(!n&&!r||v.paused)return;let t="Tab"===e.key&&!e.altKey&&!e.ctrlKey&&!e.metaKey,o=document.activeElement;if(t&&o){let t=e.currentTarget,[r,l]=function(e){let t=M(e);return[j(t,e),j(t.reverse(),e)]}(t);r&&l?e.shiftKey||o!==l?e.shiftKey&&o===r&&(e.preventDefault(),n&&L(l,{select:!0})):(e.preventDefault(),n&&L(r,{select:!0})):o===t&&e.preventDefault()}},[n,r,v.paused]);return(0,m.jsx)(C.sG.div,{tabIndex:-1,...a,ref:p,onKeyDown:g})});function M(e){let t=[],n=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:e=>{let t="INPUT"===e.tagName&&"hidden"===e.type;return e.disabled||e.hidden||t?NodeFilter.FILTER_SKIP:e.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;n.nextNode();)t.push(n.currentNode);return t}function j(e,t){for(let n of e)if(!function(e,t){let{upTo:n}=t;if("hidden"===getComputedStyle(e).visibility)return!0;for(;e&&(void 0===n||e!==n);){if("none"===getComputedStyle(e).display)return!0;e=e.parentElement}return!1}(n,{upTo:t}))return n}function L(e){let{select:t=!1}=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if(e&&e.focus){var n;let r=document.activeElement;e.focus({preventScroll:!0}),e!==r&&(n=e)instanceof HTMLInputElement&&"select"in n&&t&&e.select()}}N.displayName="FocusScope";var P=function(){let e=[];return{add(t){let n=e[0];t!==n&&(null==n||n.pause()),(e=I(e,t)).unshift(t)},remove(t){var n;null==(n=(e=I(e,t))[0])||n.resume()}}}();function I(e,t){let n=[...e],r=n.indexOf(t);return -1!==r&&n.splice(r,1),n}var O=n(5987),D=n(9448),K=n(9302),B=n(9559),F=n(3049),W=n(607),_=new WeakMap,H=new WeakMap,z={},G=0,U=function(e){return e&&(e.host||U(e.parentNode))},V=function(e,t,n,r){var o=(Array.isArray(e)?e:[e]).map(function(e){if(t.contains(e))return e;var n=U(e);return n&&t.contains(n)?n:(console.error("aria-hidden",e,"in not contained inside",t,". Doing nothing"),null)}).filter(function(e){return!!e});z[n]||(z[n]=new WeakMap);var l=z[n],i=[],a=new Set,u=new Set(o),s=function(e){!e||a.has(e)||(a.add(e),s(e.parentNode))};o.forEach(s);var c=function(e){!e||u.has(e)||Array.prototype.forEach.call(e.children,function(e){if(a.has(e))c(e);else try{var t=e.getAttribute(r),o=null!==t&&"false"!==t,u=(_.get(e)||0)+1,s=(l.get(e)||0)+1;_.set(e,u),l.set(e,s),i.push(e),1===u&&o&&H.set(e,!0),1===s&&e.setAttribute(n,"true"),o||e.setAttribute(r,"true")}catch(t){console.error("aria-hidden: cannot operate on ",e,t)}})};return c(t),a.clear(),G++,function(){i.forEach(function(e){var t=_.get(e)-1,o=l.get(e)-1;_.set(e,t),l.set(e,o),t||(H.has(e)||e.removeAttribute(r),H.delete(e)),o||e.removeAttribute(n)}),--G||(_=new WeakMap,_=new WeakMap,H=new WeakMap,z={})}},q=function(e,t,n){void 0===n&&(n="data-aria-hidden");var r=Array.from(Array.isArray(e)?e:[e]),o=t||("undefined"==typeof document?null:(Array.isArray(e)?e[0]:e).ownerDocument.body);return o?(r.push.apply(r,Array.from(o.querySelectorAll("[aria-live], script"))),V(r,o,n,"aria-hidden")):function(){return null}},Y=function(){return(Y=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e}).apply(this,arguments)};function X(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&0>t.indexOf(r)&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols)for(var o=0,r=Object.getOwnPropertySymbols(e);o<r.length;o++)0>t.indexOf(r[o])&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n}Object.create;Object.create;var Z=("function"==typeof SuppressedError&&SuppressedError,"right-scroll-bar-position"),J="width-before-scroll-bar";function Q(e,t){return"function"==typeof e?e(t):e&&(e.current=t),e}var $="undefined"!=typeof window?i.useLayoutEffect:i.useEffect,ee=new WeakMap;function et(e){return e}var en=function(e){void 0===e&&(e={});var t,n,r,o=(void 0===t&&(t=et),n=[],r=!1,{read:function(){if(r)throw Error("Sidecar: could not `read` from an `assigned` medium. `read` could be used only with `useMedium`.");return n.length?n[n.length-1]:null},useMedium:function(e){var o=t(e,r);return n.push(o),function(){n=n.filter(function(e){return e!==o})}},assignSyncMedium:function(e){for(r=!0;n.length;){var t=n;n=[],t.forEach(e)}n={push:function(t){return e(t)},filter:function(){return n}}},assignMedium:function(e){r=!0;var t=[];if(n.length){var o=n;n=[],o.forEach(e),t=n}var l=function(){var n=t;t=[],n.forEach(e)},i=function(){return Promise.resolve().then(l)};i(),n={push:function(e){t.push(e),i()},filter:function(e){return t=t.filter(e),n}}}});return o.options=Y({async:!0,ssr:!1},e),o}(),er=function(){},eo=i.forwardRef(function(e,t){var n,r,o,l,a=i.useRef(null),u=i.useState({onScrollCapture:er,onWheelCapture:er,onTouchMoveCapture:er}),s=u[0],c=u[1],d=e.forwardProps,f=e.children,p=e.className,h=e.removeScrollBar,v=e.enabled,m=e.shards,g=e.sideCar,y=e.noRelative,w=e.noIsolation,b=e.inert,x=e.allowPinchZoom,S=e.as,E=e.gapMode,C=X(e,["forwardProps","children","className","removeScrollBar","enabled","shards","sideCar","noRelative","noIsolation","inert","allowPinchZoom","as","gapMode"]),R=(n=[a,t],r=function(e){return n.forEach(function(t){return Q(t,e)})},(o=(0,i.useState)(function(){return{value:null,callback:r,facade:{get current(){return o.value},set current(value){var e=o.value;e!==value&&(o.value=value,o.callback(value,e))}}}})[0]).callback=r,l=o.facade,$(function(){var e=ee.get(l);if(e){var t=new Set(e),r=new Set(n),o=l.current;t.forEach(function(e){r.has(e)||Q(e,null)}),r.forEach(function(e){t.has(e)||Q(e,o)})}ee.set(l,n)},[n]),l),k=Y(Y({},C),s);return i.createElement(i.Fragment,null,v&&i.createElement(g,{sideCar:en,removeScrollBar:h,shards:m,noRelative:y,noIsolation:w,inert:b,setCallbacks:c,allowPinchZoom:!!x,lockRef:a,gapMode:E}),d?i.cloneElement(i.Children.only(f),Y(Y({},k),{ref:R})):i.createElement(void 0===S?"div":S,Y({},k,{className:p,ref:R}),f))});eo.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1},eo.classNames={fullWidth:J,zeroRight:Z};var el=function(e){var t=e.sideCar,n=X(e,["sideCar"]);if(!t)throw Error("Sidecar: please provide `sideCar` property to import the right car");var r=t.read();if(!r)throw Error("Sidecar medium not found");return i.createElement(r,Y({},n))};el.isSideCarExport=!0;var ei=function(){var e=0,t=null;return{add:function(r){if(0==e&&(t=function(){if(!document)return null;var e=document.createElement("style");e.type="text/css";var t=l||n.nc;return t&&e.setAttribute("nonce",t),e}())){var o,i;(o=t).styleSheet?o.styleSheet.cssText=r:o.appendChild(document.createTextNode(r)),i=t,(document.head||document.getElementsByTagName("head")[0]).appendChild(i)}e++},remove:function(){--e||!t||(t.parentNode&&t.parentNode.removeChild(t),t=null)}}},ea=function(){var e=ei();return function(t,n){i.useEffect(function(){return e.add(t),function(){e.remove()}},[t&&n])}},eu=function(){var e=ea();return function(t){return e(t.styles,t.dynamic),null}},es={left:0,top:0,right:0,gap:0},ec=function(e){return parseInt(e||"",10)||0},ed=function(e){var t=window.getComputedStyle(document.body),n=t["padding"===e?"paddingLeft":"marginLeft"],r=t["padding"===e?"paddingTop":"marginTop"],o=t["padding"===e?"paddingRight":"marginRight"];return[ec(n),ec(r),ec(o)]},ef=function(e){if(void 0===e&&(e="margin"),"undefined"==typeof window)return es;var t=ed(e),n=document.documentElement.clientWidth,r=window.innerWidth;return{left:t[0],top:t[1],right:t[2],gap:Math.max(0,r-n+t[2]-t[0])}},ep=eu(),eh="data-scroll-locked",ev=function(e,t,n,r){var o=e.left,l=e.top,i=e.right,a=e.gap;return void 0===n&&(n="margin"),"\n .".concat("with-scroll-bars-hidden"," {\n overflow: hidden ").concat(r,";\n padding-right: ").concat(a,"px ").concat(r,";\n }\n body[").concat(eh,"] {\n overflow: hidden ").concat(r,";\n overscroll-behavior: contain;\n ").concat([t&&"position: relative ".concat(r,";"),"margin"===n&&"\n padding-left: ".concat(o,"px;\n padding-top: ").concat(l,"px;\n padding-right: ").concat(i,"px;\n margin-left:0;\n margin-top:0;\n margin-right: ").concat(a,"px ").concat(r,";\n "),"padding"===n&&"padding-right: ".concat(a,"px ").concat(r,";")].filter(Boolean).join(""),"\n }\n \n .").concat(Z," {\n right: ").concat(a,"px ").concat(r,";\n }\n \n .").concat(J," {\n margin-right: ").concat(a,"px ").concat(r,";\n }\n \n .").concat(Z," .").concat(Z," {\n right: 0 ").concat(r,";\n }\n \n .").concat(J," .").concat(J," {\n margin-right: 0 ").concat(r,";\n }\n \n body[").concat(eh,"] {\n ").concat("--removed-body-scroll-bar-size",": ").concat(a,"px;\n }\n")},em=function(){var e=parseInt(document.body.getAttribute(eh)||"0",10);return isFinite(e)?e:0},eg=function(){i.useEffect(function(){return document.body.setAttribute(eh,(em()+1).toString()),function(){var e=em()-1;e<=0?document.body.removeAttribute(eh):document.body.setAttribute(eh,e.toString())}},[])},ey=function(e){var t=e.noRelative,n=e.noImportant,r=e.gapMode,o=void 0===r?"margin":r;eg();var l=i.useMemo(function(){return ef(o)},[o]);return i.createElement(ep,{styles:ev(l,!t,o,n?"":"!important")})},ew=!1;if("undefined"!=typeof window)try{var eb=Object.defineProperty({},"passive",{get:function(){return ew=!0,!0}});window.addEventListener("test",eb,eb),window.removeEventListener("test",eb,eb)}catch(e){ew=!1}var ex=!!ew&&{passive:!1},eS=function(e,t){if(!(e instanceof Element))return!1;var n=window.getComputedStyle(e);return"hidden"!==n[t]&&(n.overflowY!==n.overflowX||"TEXTAREA"===e.tagName||"visible"!==n[t])},eE=function(e,t){var n=t.ownerDocument,r=t;do{if("undefined"!=typeof ShadowRoot&&r instanceof ShadowRoot&&(r=r.host),eC(e,r)){var o=eR(e,r);if(o[1]>o[2])return!0}r=r.parentNode}while(r&&r!==n.body);return!1},eC=function(e,t){return"v"===e?eS(t,"overflowY"):eS(t,"overflowX")},eR=function(e,t){return"v"===e?[t.scrollTop,t.scrollHeight,t.clientHeight]:[t.scrollLeft,t.scrollWidth,t.clientWidth]},ek=function(e,t,n,r,o){var l,i=(l=window.getComputedStyle(t).direction,"h"===e&&"rtl"===l?-1:1),a=i*r,u=n.target,s=t.contains(u),c=!1,d=a>0,f=0,p=0;do{if(!u)break;var h=eR(e,u),v=h[0],m=h[1]-h[2]-i*v;(v||m)&&eC(e,u)&&(f+=m,p+=v);var g=u.parentNode;u=g&&g.nodeType===Node.DOCUMENT_FRAGMENT_NODE?g.host:g}while(!s&&u!==document.body||s&&(t.contains(u)||t===u));return d&&(o&&1>Math.abs(f)||!o&&a>f)?c=!0:!d&&(o&&1>Math.abs(p)||!o&&-a>p)&&(c=!0),c},eT=function(e){return"changedTouches"in e?[e.changedTouches[0].clientX,e.changedTouches[0].clientY]:[0,0]},eA=function(e){return[e.deltaX,e.deltaY]},eN=function(e){return e&&"current"in e?e.current:e},eM=0,ej=[];let eL=(r=function(e){var t=i.useRef([]),n=i.useRef([0,0]),r=i.useRef(),o=i.useState(eM++)[0],l=i.useState(eu)[0],a=i.useRef(e);i.useEffect(function(){a.current=e},[e]),i.useEffect(function(){if(e.inert){document.body.classList.add("block-interactivity-".concat(o));var t=(function(e,t,n){if(n||2==arguments.length)for(var r,o=0,l=t.length;o<l;o++)!r&&o in t||(r||(r=Array.prototype.slice.call(t,0,o)),r[o]=t[o]);return e.concat(r||Array.prototype.slice.call(t))})([e.lockRef.current],(e.shards||[]).map(eN),!0).filter(Boolean);return t.forEach(function(e){return e.classList.add("allow-interactivity-".concat(o))}),function(){document.body.classList.remove("block-interactivity-".concat(o)),t.forEach(function(e){return e.classList.remove("allow-interactivity-".concat(o))})}}},[e.inert,e.lockRef.current,e.shards]);var u=i.useCallback(function(e,t){if("touches"in e&&2===e.touches.length||"wheel"===e.type&&e.ctrlKey)return!a.current.allowPinchZoom;var o,l=eT(e),i=n.current,u="deltaX"in e?e.deltaX:i[0]-l[0],s="deltaY"in e?e.deltaY:i[1]-l[1],c=e.target,d=Math.abs(u)>Math.abs(s)?"h":"v";if("touches"in e&&"h"===d&&"range"===c.type)return!1;var f=eE(d,c);if(!f)return!0;if(f?o=d:(o="v"===d?"h":"v",f=eE(d,c)),!f)return!1;if(!r.current&&"changedTouches"in e&&(u||s)&&(r.current=o),!o)return!0;var p=r.current||o;return ek(p,t,e,"h"===p?u:s,!0)},[]),s=i.useCallback(function(e){if(ej.length&&ej[ej.length-1]===l){var n="deltaY"in e?eA(e):eT(e),r=t.current.filter(function(t){var r;return t.name===e.type&&(t.target===e.target||e.target===t.shadowParent)&&(r=t.delta,r[0]===n[0]&&r[1]===n[1])})[0];if(r&&r.should){e.cancelable&&e.preventDefault();return}if(!r){var o=(a.current.shards||[]).map(eN).filter(Boolean).filter(function(t){return t.contains(e.target)});(o.length>0?u(e,o[0]):!a.current.noIsolation)&&e.cancelable&&e.preventDefault()}}},[]),c=i.useCallback(function(e,n,r,o){var l={name:e,delta:n,target:r,should:o,shadowParent:function(e){for(var t=null;null!==e;)e instanceof ShadowRoot&&(t=e.host,e=e.host),e=e.parentNode;return t}(r)};t.current.push(l),setTimeout(function(){t.current=t.current.filter(function(e){return e!==l})},1)},[]),d=i.useCallback(function(e){n.current=eT(e),r.current=void 0},[]),f=i.useCallback(function(t){c(t.type,eA(t),t.target,u(t,e.lockRef.current))},[]),p=i.useCallback(function(t){c(t.type,eT(t),t.target,u(t,e.lockRef.current))},[]);i.useEffect(function(){return ej.push(l),e.setCallbacks({onScrollCapture:f,onWheelCapture:f,onTouchMoveCapture:p}),document.addEventListener("wheel",s,ex),document.addEventListener("touchmove",s,ex),document.addEventListener("touchstart",d,ex),function(){ej=ej.filter(function(e){return e!==l}),document.removeEventListener("wheel",s,ex),document.removeEventListener("touchmove",s,ex),document.removeEventListener("touchstart",d,ex)}},[]);var h=e.removeScrollBar,v=e.inert;return i.createElement(i.Fragment,null,v?i.createElement(l,{styles:"\n .block-interactivity-".concat(o," {pointer-events: none;}\n .allow-interactivity-").concat(o," {pointer-events: all;}\n")}):null,h?i.createElement(ey,{noRelative:e.noRelative,gapMode:e.gapMode}):null)},en.useMedium(r),el);var eP=i.forwardRef(function(e,t){return i.createElement(eo,Y({},e,{ref:t,sideCar:eL}))});eP.classNames=eo.classNames;var eI=[" ","Enter","ArrowUp","ArrowDown"],eO=[" ","Enter"],eD="Select",[eK,eB,eF]=function(e){let t=e+"CollectionProvider",[n,r]=(0,p.A)(t),[o,l]=n(t,{collectionRef:{current:null},itemMap:new Map}),a=e=>{let{scope:t,children:n}=e,r=i.useRef(null),l=i.useRef(new Map).current;return(0,m.jsx)(o,{scope:t,itemMap:l,collectionRef:r,children:n})};a.displayName=t;let u=e+"CollectionSlot",s=(0,v.TL)(u),c=i.forwardRef((e,t)=>{let{scope:n,children:r}=e,o=l(u,n),i=(0,h.s)(t,o.collectionRef);return(0,m.jsx)(s,{ref:i,children:r})});c.displayName=u;let d=e+"CollectionItemSlot",f="data-radix-collection-item",g=(0,v.TL)(d),y=i.forwardRef((e,t)=>{let{scope:n,children:r,...o}=e,a=i.useRef(null),u=(0,h.s)(t,a),s=l(d,n);return i.useEffect(()=>(s.itemMap.set(a,{ref:a,...o}),()=>void s.itemMap.delete(a))),(0,m.jsx)(g,{...{[f]:""},ref:u,children:r})});return y.displayName=d,[{Provider:a,Slot:c,ItemSlot:y},function(t){let n=l(e+"CollectionConsumer",t);return i.useCallback(()=>{let e=n.collectionRef.current;if(!e)return[];let t=Array.from(e.querySelectorAll("[".concat(f,"]")));return Array.from(n.itemMap.values()).sort((e,n)=>t.indexOf(e.ref.current)-t.indexOf(n.ref.current))},[n.collectionRef,n.itemMap])},r]}(eD),[eW,e_]=(0,p.A)(eD,[eF,D.Bk]),eH=(0,D.Bk)(),[ez,eG]=eW(eD),[eU,eV]=eW(eD),eq=e=>{let{__scopeSelect:t,children:n,open:r,defaultOpen:o,onOpenChange:l,value:a,defaultValue:u,onValueChange:s,dir:c,name:d,autoComplete:f,disabled:p,required:h,form:v}=e,g=eH(t),[y,w]=i.useState(null),[x,S]=i.useState(null),[E,C]=i.useState(!1),R=function(e){let t=i.useContext(b);return e||t||"ltr"}(c),[k,T]=(0,B.i)({prop:r,defaultProp:null!=o&&o,onChange:l,caller:eD}),[A,N]=(0,B.i)({prop:a,defaultProp:u,onChange:s,caller:eD}),M=i.useRef(null),j=!y||v||!!y.closest("form"),[L,P]=i.useState(new Set),I=Array.from(L).map(e=>e.props.value).join(";");return(0,m.jsx)(D.bL,{...g,children:(0,m.jsxs)(ez,{required:h,scope:t,trigger:y,onTriggerChange:w,valueNode:x,onValueNodeChange:S,valueNodeHasChildren:E,onValueNodeHasChildrenChange:C,contentId:(0,O.B)(),value:A,onValueChange:N,open:k,onOpenChange:T,dir:R,triggerPointerDownPosRef:M,disabled:p,children:[(0,m.jsx)(eK.Provider,{scope:t,children:(0,m.jsx)(eU,{scope:e.__scopeSelect,onNativeOptionAdd:i.useCallback(e=>{P(t=>new Set(t).add(e))},[]),onNativeOptionRemove:i.useCallback(e=>{P(t=>{let n=new Set(t);return n.delete(e),n})},[]),children:n})}),j?(0,m.jsxs)(tE,{"aria-hidden":!0,required:h,tabIndex:-1,name:d,autoComplete:f,value:A,onChange:e=>N(e.target.value),disabled:p,form:v,children:[void 0===A?(0,m.jsx)("option",{value:""}):null,Array.from(L)]},I):null]})})};eq.displayName=eD;var eY="SelectTrigger",eX=i.forwardRef((e,t)=>{let{__scopeSelect:n,disabled:r=!1,...o}=e,l=eH(n),a=eG(eY,n),u=a.disabled||r,c=(0,h.s)(t,a.onTriggerChange),d=eB(n),f=i.useRef("touch"),[p,v,g]=tR(e=>{let t=d().filter(e=>!e.disabled),n=t.find(e=>e.value===a.value),r=tk(t,e,n);void 0!==r&&a.onValueChange(r.value)}),y=e=>{u||(a.onOpenChange(!0),g()),e&&(a.triggerPointerDownPosRef.current={x:Math.round(e.pageX),y:Math.round(e.pageY)})};return(0,m.jsx)(D.Mz,{asChild:!0,...l,children:(0,m.jsx)(C.sG.button,{type:"button",role:"combobox","aria-controls":a.contentId,"aria-expanded":a.open,"aria-required":a.required,"aria-autocomplete":"none",dir:a.dir,"data-state":a.open?"open":"closed",disabled:u,"data-disabled":u?"":void 0,"data-placeholder":tC(a.value)?"":void 0,...o,ref:c,onClick:(0,s.mK)(o.onClick,e=>{e.currentTarget.focus(),"mouse"!==f.current&&y(e)}),onPointerDown:(0,s.mK)(o.onPointerDown,e=>{f.current=e.pointerType;let t=e.target;t.hasPointerCapture(e.pointerId)&&t.releasePointerCapture(e.pointerId),0===e.button&&!1===e.ctrlKey&&"mouse"===e.pointerType&&(y(e),e.preventDefault())}),onKeyDown:(0,s.mK)(o.onKeyDown,e=>{let t=""!==p.current;e.ctrlKey||e.altKey||e.metaKey||1!==e.key.length||v(e.key),(!t||" "!==e.key)&&eI.includes(e.key)&&(y(),e.preventDefault())})})})});eX.displayName=eY;var eZ="SelectValue",eJ=i.forwardRef((e,t)=>{let{__scopeSelect:n,className:r,style:o,children:l,placeholder:i="",...a}=e,u=eG(eZ,n),{onValueNodeHasChildrenChange:s}=u,c=void 0!==l,d=(0,h.s)(t,u.onValueNodeChange);return(0,F.N)(()=>{s(c)},[s,c]),(0,m.jsx)(C.sG.span,{...a,ref:d,style:{pointerEvents:"none"},children:tC(u.value)?(0,m.jsx)(m.Fragment,{children:i}):l})});eJ.displayName=eZ;var eQ=i.forwardRef((e,t)=>{let{__scopeSelect:n,children:r,...o}=e;return(0,m.jsx)(C.sG.span,{"aria-hidden":!0,...o,ref:t,children:r||"▼"})});eQ.displayName="SelectIcon";var e$=e=>(0,m.jsx)(K.Z,{asChild:!0,...e});e$.displayName="SelectPortal";var e0="SelectContent",e1=i.forwardRef((e,t)=>{let n=eG(e0,e.__scopeSelect),[r,o]=i.useState();return((0,F.N)(()=>{o(new DocumentFragment)},[]),n.open)?(0,m.jsx)(e5,{...e,ref:t}):r?a.createPortal((0,m.jsx)(e2,{scope:e.__scopeSelect,children:(0,m.jsx)(eK.Slot,{scope:e.__scopeSelect,children:(0,m.jsx)("div",{children:e.children})})}),r):null});e1.displayName=e0;var[e2,e6]=eW(e0),e3=(0,v.TL)("SelectContent.RemoveScroll"),e5=i.forwardRef((e,t)=>{let{__scopeSelect:n,position:r="item-aligned",onCloseAutoFocus:o,onEscapeKeyDown:l,onPointerDownOutside:a,side:u,sideOffset:c,align:d,alignOffset:f,arrowPadding:p,collisionBoundary:v,collisionPadding:g,sticky:y,hideWhenDetached:w,avoidCollisions:b,...C}=e,R=eG(e0,n),[k,T]=i.useState(null),[A,M]=i.useState(null),j=(0,h.s)(t,e=>T(e)),[L,P]=i.useState(null),[I,O]=i.useState(null),D=eB(n),[K,B]=i.useState(!1),F=i.useRef(!1);i.useEffect(()=>{if(k)return q(k)},[k]),i.useEffect(()=>{var e,t;let n=document.querySelectorAll("[data-radix-focus-guard]");return document.body.insertAdjacentElement("afterbegin",null!=(e=n[0])?e:E()),document.body.insertAdjacentElement("beforeend",null!=(t=n[1])?t:E()),S++,()=>{1===S&&document.querySelectorAll("[data-radix-focus-guard]").forEach(e=>e.remove()),S--}},[]);let W=i.useCallback(e=>{let[t,...n]=D().map(e=>e.ref.current),[r]=n.slice(-1),o=document.activeElement;for(let n of e)if(n===o||(null==n||n.scrollIntoView({block:"nearest"}),n===t&&A&&(A.scrollTop=0),n===r&&A&&(A.scrollTop=A.scrollHeight),null==n||n.focus(),document.activeElement!==o))return},[D,A]),_=i.useCallback(()=>W([L,k]),[W,L,k]);i.useEffect(()=>{K&&_()},[K,_]);let{onOpenChange:H,triggerPointerDownPosRef:z}=R;i.useEffect(()=>{if(k){let e={x:0,y:0},t=t=>{var n,r,o,l;e={x:Math.abs(Math.round(t.pageX)-(null!=(o=null==(n=z.current)?void 0:n.x)?o:0)),y:Math.abs(Math.round(t.pageY)-(null!=(l=null==(r=z.current)?void 0:r.y)?l:0))}},n=n=>{e.x<=10&&e.y<=10?n.preventDefault():k.contains(n.target)||H(!1),document.removeEventListener("pointermove",t),z.current=null};return null!==z.current&&(document.addEventListener("pointermove",t),document.addEventListener("pointerup",n,{capture:!0,once:!0})),()=>{document.removeEventListener("pointermove",t),document.removeEventListener("pointerup",n,{capture:!0})}}},[k,H,z]),i.useEffect(()=>{let e=()=>H(!1);return window.addEventListener("blur",e),window.addEventListener("resize",e),()=>{window.removeEventListener("blur",e),window.removeEventListener("resize",e)}},[H]);let[G,U]=tR(e=>{let t=D().filter(e=>!e.disabled),n=t.find(e=>e.ref.current===document.activeElement),r=tk(t,e,n);r&&setTimeout(()=>r.ref.current.focus())}),V=i.useCallback((e,t,n)=>{let r=!F.current&&!n;(void 0!==R.value&&R.value===t||r)&&(P(e),r&&(F.current=!0))},[R.value]),Y=i.useCallback(()=>null==k?void 0:k.focus(),[k]),X=i.useCallback((e,t,n)=>{let r=!F.current&&!n;(void 0!==R.value&&R.value===t||r)&&O(e)},[R.value]),Z="popper"===r?e4:e8,J=Z===e4?{side:u,sideOffset:c,align:d,alignOffset:f,arrowPadding:p,collisionBoundary:v,collisionPadding:g,sticky:y,hideWhenDetached:w,avoidCollisions:b}:{};return(0,m.jsx)(e2,{scope:n,content:k,viewport:A,onViewportChange:M,itemRefCallback:V,selectedItem:L,onItemLeave:Y,itemTextRefCallback:X,focusSelectedItem:_,selectedItemText:I,position:r,isPositioned:K,searchRef:G,children:(0,m.jsx)(eP,{as:e3,allowPinchZoom:!0,children:(0,m.jsx)(N,{asChild:!0,trapped:R.open,onMountAutoFocus:e=>{e.preventDefault()},onUnmountAutoFocus:(0,s.mK)(o,e=>{var t;null==(t=R.trigger)||t.focus({preventScroll:!0}),e.preventDefault()}),children:(0,m.jsx)(x.qW,{asChild:!0,disableOutsidePointerEvents:!0,onEscapeKeyDown:l,onPointerDownOutside:a,onFocusOutside:e=>e.preventDefault(),onDismiss:()=>R.onOpenChange(!1),children:(0,m.jsx)(Z,{role:"listbox",id:R.contentId,"data-state":R.open?"open":"closed",dir:R.dir,onContextMenu:e=>e.preventDefault(),...C,...J,onPlaced:()=>B(!0),ref:j,style:{display:"flex",flexDirection:"column",outline:"none",...C.style},onKeyDown:(0,s.mK)(C.onKeyDown,e=>{let t=e.ctrlKey||e.altKey||e.metaKey;if("Tab"===e.key&&e.preventDefault(),t||1!==e.key.length||U(e.key),["ArrowUp","ArrowDown","Home","End"].includes(e.key)){let t=D().filter(e=>!e.disabled).map(e=>e.ref.current);if(["ArrowUp","End"].includes(e.key)&&(t=t.slice().reverse()),["ArrowUp","ArrowDown"].includes(e.key)){let n=e.target,r=t.indexOf(n);t=t.slice(r+1)}setTimeout(()=>W(t)),e.preventDefault()}})})})})})})});e5.displayName="SelectContentImpl";var e8=i.forwardRef((e,t)=>{let{__scopeSelect:n,onPlaced:r,...o}=e,l=eG(e0,n),a=e6(e0,n),[s,c]=i.useState(null),[d,f]=i.useState(null),p=(0,h.s)(t,e=>f(e)),v=eB(n),g=i.useRef(!1),y=i.useRef(!0),{viewport:w,selectedItem:b,selectedItemText:x,focusSelectedItem:S}=a,E=i.useCallback(()=>{if(l.trigger&&l.valueNode&&s&&d&&w&&b&&x){let e=l.trigger.getBoundingClientRect(),t=d.getBoundingClientRect(),n=l.valueNode.getBoundingClientRect(),o=x.getBoundingClientRect();if("rtl"!==l.dir){let r=o.left-t.left,l=n.left-r,i=e.left-l,a=e.width+i,c=Math.max(a,t.width),d=u(l,[10,Math.max(10,window.innerWidth-10-c)]);s.style.minWidth=a+"px",s.style.left=d+"px"}else{let r=t.right-o.right,l=window.innerWidth-n.right-r,i=window.innerWidth-e.right-l,a=e.width+i,c=Math.max(a,t.width),d=u(l,[10,Math.max(10,window.innerWidth-10-c)]);s.style.minWidth=a+"px",s.style.right=d+"px"}let i=v(),a=window.innerHeight-20,c=w.scrollHeight,f=window.getComputedStyle(d),p=parseInt(f.borderTopWidth,10),h=parseInt(f.paddingTop,10),m=parseInt(f.borderBottomWidth,10),y=p+h+c+parseInt(f.paddingBottom,10)+m,S=Math.min(5*b.offsetHeight,y),E=window.getComputedStyle(w),C=parseInt(E.paddingTop,10),R=parseInt(E.paddingBottom,10),k=e.top+e.height/2-10,T=b.offsetHeight/2,A=p+h+(b.offsetTop+T);if(A<=k){let e=i.length>0&&b===i[i.length-1].ref.current;s.style.bottom="0px";let t=Math.max(a-k,T+(e?R:0)+(d.clientHeight-w.offsetTop-w.offsetHeight)+m);s.style.height=A+t+"px"}else{let e=i.length>0&&b===i[0].ref.current;s.style.top="0px";let t=Math.max(k,p+w.offsetTop+(e?C:0)+T);s.style.height=t+(y-A)+"px",w.scrollTop=A-k+w.offsetTop}s.style.margin="".concat(10,"px 0"),s.style.minHeight=S+"px",s.style.maxHeight=a+"px",null==r||r(),requestAnimationFrame(()=>g.current=!0)}},[v,l.trigger,l.valueNode,s,d,w,b,x,l.dir,r]);(0,F.N)(()=>E(),[E]);let[R,k]=i.useState();(0,F.N)(()=>{d&&k(window.getComputedStyle(d).zIndex)},[d]);let T=i.useCallback(e=>{e&&!0===y.current&&(E(),null==S||S(),y.current=!1)},[E,S]);return(0,m.jsx)(e7,{scope:n,contentWrapper:s,shouldExpandOnScrollRef:g,onScrollButtonChange:T,children:(0,m.jsx)("div",{ref:c,style:{display:"flex",flexDirection:"column",position:"fixed",zIndex:R},children:(0,m.jsx)(C.sG.div,{...o,ref:p,style:{boxSizing:"border-box",maxHeight:"100%",...o.style}})})})});e8.displayName="SelectItemAlignedPosition";var e4=i.forwardRef((e,t)=>{let{__scopeSelect:n,align:r="start",collisionPadding:o=10,...l}=e,i=eH(n);return(0,m.jsx)(D.UC,{...i,...l,ref:t,align:r,collisionPadding:o,style:{boxSizing:"border-box",...l.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)"}})});e4.displayName="SelectPopperPosition";var[e7,e9]=eW(e0,{}),te="SelectViewport",tt=i.forwardRef((e,t)=>{let{__scopeSelect:n,nonce:r,...o}=e,l=e6(te,n),a=e9(te,n),u=(0,h.s)(t,l.onViewportChange),c=i.useRef(0);return(0,m.jsxs)(m.Fragment,{children:[(0,m.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}"},nonce:r}),(0,m.jsx)(eK.Slot,{scope:n,children:(0,m.jsx)(C.sG.div,{"data-radix-select-viewport":"",role:"presentation",...o,ref:u,style:{position:"relative",flex:1,overflow:"hidden auto",...o.style},onScroll:(0,s.mK)(o.onScroll,e=>{let t=e.currentTarget,{contentWrapper:n,shouldExpandOnScrollRef:r}=a;if((null==r?void 0:r.current)&&n){let e=Math.abs(c.current-t.scrollTop);if(e>0){let r=window.innerHeight-20,o=Math.max(parseFloat(n.style.minHeight),parseFloat(n.style.height));if(o<r){let l=o+e,i=Math.min(r,l),a=l-i;n.style.height=i+"px","0px"===n.style.bottom&&(t.scrollTop=a>0?a:0,n.style.justifyContent="flex-end")}}}c.current=t.scrollTop})})})]})});tt.displayName=te;var tn="SelectGroup",[tr,to]=eW(tn),tl=i.forwardRef((e,t)=>{let{__scopeSelect:n,...r}=e,o=(0,O.B)();return(0,m.jsx)(tr,{scope:n,id:o,children:(0,m.jsx)(C.sG.div,{role:"group","aria-labelledby":o,...r,ref:t})})});tl.displayName=tn;var ti="SelectLabel",ta=i.forwardRef((e,t)=>{let{__scopeSelect:n,...r}=e,o=to(ti,n);return(0,m.jsx)(C.sG.div,{id:o.id,...r,ref:t})});ta.displayName=ti;var tu="SelectItem",[ts,tc]=eW(tu),td=i.forwardRef((e,t)=>{let{__scopeSelect:n,value:r,disabled:o=!1,textValue:l,...a}=e,u=eG(tu,n),c=e6(tu,n),d=u.value===r,[f,p]=i.useState(null!=l?l:""),[v,g]=i.useState(!1),y=(0,h.s)(t,e=>{var t;return null==(t=c.itemRefCallback)?void 0:t.call(c,e,r,o)}),w=(0,O.B)(),b=i.useRef("touch"),x=()=>{o||(u.onValueChange(r),u.onOpenChange(!1))};if(""===r)throw Error("A <Select.Item /> must have a value prop that is not an empty string. This is because the Select value can be set to an empty string to clear the selection and show the placeholder.");return(0,m.jsx)(ts,{scope:n,value:r,disabled:o,textId:w,isSelected:d,onItemTextChange:i.useCallback(e=>{p(t=>{var n;return t||(null!=(n=null==e?void 0:e.textContent)?n:"").trim()})},[]),children:(0,m.jsx)(eK.ItemSlot,{scope:n,value:r,disabled:o,textValue:f,children:(0,m.jsx)(C.sG.div,{role:"option","aria-labelledby":w,"data-highlighted":v?"":void 0,"aria-selected":d&&v,"data-state":d?"checked":"unchecked","aria-disabled":o||void 0,"data-disabled":o?"":void 0,tabIndex:o?void 0:-1,...a,ref:y,onFocus:(0,s.mK)(a.onFocus,()=>g(!0)),onBlur:(0,s.mK)(a.onBlur,()=>g(!1)),onClick:(0,s.mK)(a.onClick,()=>{"mouse"!==b.current&&x()}),onPointerUp:(0,s.mK)(a.onPointerUp,()=>{"mouse"===b.current&&x()}),onPointerDown:(0,s.mK)(a.onPointerDown,e=>{b.current=e.pointerType}),onPointerMove:(0,s.mK)(a.onPointerMove,e=>{if(b.current=e.pointerType,o){var t;null==(t=c.onItemLeave)||t.call(c)}else"mouse"===b.current&&e.currentTarget.focus({preventScroll:!0})}),onPointerLeave:(0,s.mK)(a.onPointerLeave,e=>{if(e.currentTarget===document.activeElement){var t;null==(t=c.onItemLeave)||t.call(c)}}),onKeyDown:(0,s.mK)(a.onKeyDown,e=>{var t;((null==(t=c.searchRef)?void 0:t.current)===""||" "!==e.key)&&(eO.includes(e.key)&&x()," "===e.key&&e.preventDefault())})})})})});td.displayName=tu;var tf="SelectItemText",tp=i.forwardRef((e,t)=>{let{__scopeSelect:n,className:r,style:o,...l}=e,u=eG(tf,n),s=e6(tf,n),c=tc(tf,n),d=eV(tf,n),[f,p]=i.useState(null),v=(0,h.s)(t,e=>p(e),c.onItemTextChange,e=>{var t;return null==(t=s.itemTextRefCallback)?void 0:t.call(s,e,c.value,c.disabled)}),g=null==f?void 0:f.textContent,y=i.useMemo(()=>(0,m.jsx)("option",{value:c.value,disabled:c.disabled,children:g},c.value),[c.disabled,c.value,g]),{onNativeOptionAdd:w,onNativeOptionRemove:b}=d;return(0,F.N)(()=>(w(y),()=>b(y)),[w,b,y]),(0,m.jsxs)(m.Fragment,{children:[(0,m.jsx)(C.sG.span,{id:c.textId,...l,ref:v}),c.isSelected&&u.valueNode&&!u.valueNodeHasChildren?a.createPortal(l.children,u.valueNode):null]})});tp.displayName=tf;var th="SelectItemIndicator",tv=i.forwardRef((e,t)=>{let{__scopeSelect:n,...r}=e;return tc(th,n).isSelected?(0,m.jsx)(C.sG.span,{"aria-hidden":!0,...r,ref:t}):null});tv.displayName=th;var tm="SelectScrollUpButton",tg=i.forwardRef((e,t)=>{let n=e6(tm,e.__scopeSelect),r=e9(tm,e.__scopeSelect),[o,l]=i.useState(!1),a=(0,h.s)(t,r.onScrollButtonChange);return(0,F.N)(()=>{if(n.viewport&&n.isPositioned){let e=function(){l(t.scrollTop>0)},t=n.viewport;return e(),t.addEventListener("scroll",e),()=>t.removeEventListener("scroll",e)}},[n.viewport,n.isPositioned]),o?(0,m.jsx)(tb,{...e,ref:a,onAutoScroll:()=>{let{viewport:e,selectedItem:t}=n;e&&t&&(e.scrollTop=e.scrollTop-t.offsetHeight)}}):null});tg.displayName=tm;var ty="SelectScrollDownButton",tw=i.forwardRef((e,t)=>{let n=e6(ty,e.__scopeSelect),r=e9(ty,e.__scopeSelect),[o,l]=i.useState(!1),a=(0,h.s)(t,r.onScrollButtonChange);return(0,F.N)(()=>{if(n.viewport&&n.isPositioned){let e=function(){let e=t.scrollHeight-t.clientHeight;l(Math.ceil(t.scrollTop)<e)},t=n.viewport;return e(),t.addEventListener("scroll",e),()=>t.removeEventListener("scroll",e)}},[n.viewport,n.isPositioned]),o?(0,m.jsx)(tb,{...e,ref:a,onAutoScroll:()=>{let{viewport:e,selectedItem:t}=n;e&&t&&(e.scrollTop=e.scrollTop+t.offsetHeight)}}):null});tw.displayName=ty;var tb=i.forwardRef((e,t)=>{let{__scopeSelect:n,onAutoScroll:r,...o}=e,l=e6("SelectScrollButton",n),a=i.useRef(null),u=eB(n),c=i.useCallback(()=>{null!==a.current&&(window.clearInterval(a.current),a.current=null)},[]);return i.useEffect(()=>()=>c(),[c]),(0,F.N)(()=>{var e;let t=u().find(e=>e.ref.current===document.activeElement);null==t||null==(e=t.ref.current)||e.scrollIntoView({block:"nearest"})},[u]),(0,m.jsx)(C.sG.div,{"aria-hidden":!0,...o,ref:t,style:{flexShrink:0,...o.style},onPointerDown:(0,s.mK)(o.onPointerDown,()=>{null===a.current&&(a.current=window.setInterval(r,50))}),onPointerMove:(0,s.mK)(o.onPointerMove,()=>{var e;null==(e=l.onItemLeave)||e.call(l),null===a.current&&(a.current=window.setInterval(r,50))}),onPointerLeave:(0,s.mK)(o.onPointerLeave,()=>{c()})})}),tx=i.forwardRef((e,t)=>{let{__scopeSelect:n,...r}=e;return(0,m.jsx)(C.sG.div,{"aria-hidden":!0,...r,ref:t})});tx.displayName="SelectSeparator";var tS="SelectArrow";i.forwardRef((e,t)=>{let{__scopeSelect:n,...r}=e,o=eH(n),l=eG(tS,n),i=e6(tS,n);return l.open&&"popper"===i.position?(0,m.jsx)(D.i3,{...o,...r,ref:t}):null}).displayName=tS;var tE=i.forwardRef((e,t)=>{let{__scopeSelect:n,value:r,...o}=e,l=i.useRef(null),a=(0,h.s)(t,l),u=function(e){let t=i.useRef({value:e,previous:e});return i.useMemo(()=>(t.current.value!==e&&(t.current.previous=t.current.value,t.current.value=e),t.current.previous),[e])}(r);return i.useEffect(()=>{let e=l.current;if(!e)return;let t=Object.getOwnPropertyDescriptor(window.HTMLSelectElement.prototype,"value").set;if(u!==r&&t){let n=new Event("change",{bubbles:!0});t.call(e,r),e.dispatchEvent(n)}},[u,r]),(0,m.jsx)(C.sG.select,{...o,style:{...W.Qg,...o.style},ref:a,defaultValue:r})});function tC(e){return""===e||void 0===e}function tR(e){let t=(0,R.c)(e),n=i.useRef(""),r=i.useRef(0),o=i.useCallback(e=>{let o=n.current+e;t(o),function e(t){n.current=t,window.clearTimeout(r.current),""!==t&&(r.current=window.setTimeout(()=>e(""),1e3))}(o)},[t]),l=i.useCallback(()=>{n.current="",window.clearTimeout(r.current)},[]);return i.useEffect(()=>()=>window.clearTimeout(r.current),[]),[n,o,l]}function tk(e,t,n){var r,o;let l=t.length>1&&Array.from(t).every(e=>e===t[0])?t[0]:t,i=n?e.indexOf(n):-1,a=(r=e,o=Math.max(i,0),r.map((e,t)=>r[(o+t)%r.length]));1===l.length&&(a=a.filter(e=>e!==n));let u=a.find(e=>e.textValue.toLowerCase().startsWith(l.toLowerCase()));return u!==n?u:void 0}tE.displayName="SelectBubbleInput";var tT=eq,tA=eX,tN=eJ,tM=eQ,tj=e$,tL=e1,tP=tt,tI=tl,tO=ta,tD=td,tK=tp,tB=tv,tF=tg,tW=tw,t_=tx},7163:(e,t,n)=>{n.d(t,{A:()=>r});let r=(0,n(8258).A)("ChevronUp",[["path",{d:"m18 15-6-6-6 6",key:"153udz"}]])}}]);
@@ -1 +0,0 @@
1
- "use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[724],{63:(e,t,n)=>{n.d(t,{hO:()=>u,sG:()=>a});var r=n(4773),o=n(1471),i=n(9280),l=n(5386),a=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"].reduce((e,t)=>{let n=(0,i.TL)(`Primitive.${t}`),o=r.forwardRef((e,r)=>{let{asChild:o,...i}=e;return"undefined"!=typeof window&&(window[Symbol.for("radix-ui")]=!0),(0,l.jsx)(o?n:t,{...i,ref:r})});return o.displayName=`Primitive.${t}`,{...e,[t]:o}},{});function u(e,t){e&&o.flushSync(()=>e.dispatchEvent(t))}},607:(e,t,n)=>{n.d(t,{Qg:()=>l,bL:()=>u});var r=n(4773),o=n(63),i=n(5386),l=Object.freeze({position:"absolute",border:0,width:1,height:1,padding:0,margin:-1,overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",wordWrap:"normal"}),a=r.forwardRef((e,t)=>(0,i.jsx)(o.sG.span,{...e,ref:t,style:{...l,...e.style}}));a.displayName="VisuallyHidden";var u=a},819:(e,t,n)=>{n.d(t,{c:()=>o});var r=n(4773);function o(e){let t=r.useRef(e);return r.useEffect(()=>{t.current=e}),r.useMemo(()=>(...e)=>t.current?.(...e),[])}},3049:(e,t,n)=>{n.d(t,{N:()=>o});var r=n(4773),o=globalThis?.document?r.useLayoutEffect:()=>{}},4053:(e,t,n)=>{function r(e,t,{checkForDefaultPrevented:n=!0}={}){return function(r){if(e?.(r),!1===n||!r.defaultPrevented)return t?.(r)}}n.d(t,{mK:()=>r}),"undefined"!=typeof window&&window.document&&window.document.createElement},5987:(e,t,n)=>{n.d(t,{B:()=>u});var r,o=n(4773),i=n(3049),l=(r||(r=n.t(o,2)))[" useId ".trim().toString()]||(()=>void 0),a=0;function u(e){let[t,n]=o.useState(l());return(0,i.N)(()=>{e||n(e=>e??String(a++))},[e]),e||(t?`radix-${t}`:"")}},7328:(e,t,n)=>{n.d(t,{A:()=>i});var r=n(4773),o=n(5386);function i(e,t=[]){let n=[],l=()=>{let t=n.map(e=>r.createContext(e));return function(n){let o=n?.[e]||t;return r.useMemo(()=>({[`__scope${e}`]:{...n,[e]:o}}),[n,o])}};return l.scopeName=e,[function(t,i){let l=r.createContext(i),a=n.length;n=[...n,i];let u=t=>{let{scope:n,children:i,...u}=t,s=n?.[e]?.[a]||l,c=r.useMemo(()=>u,Object.values(u));return(0,o.jsx)(s.Provider,{value:c,children:i})};return u.displayName=t+"Provider",[u,function(n,o){let u=o?.[e]?.[a]||l,s=r.useContext(u);if(s)return s;if(void 0!==i)return i;throw Error(`\`${n}\` must be used within \`${t}\``)}]},function(...e){let t=e[0];if(1===e.length)return t;let n=()=>{let n=e.map(e=>({useScope:e(),scopeName:e.scopeName}));return function(e){let o=n.reduce((t,{useScope:n,scopeName:r})=>{let o=n(e)[`__scope${r}`];return{...t,...o}},{});return r.useMemo(()=>({[`__scope${t.scopeName}`]:o}),[o])}};return n.scopeName=t.scopeName,n}(l,...t)]}},7536:(e,t,n)=>{n.d(t,{A:()=>r});let r=(0,n(8258).A)("Check",[["path",{d:"M20 6 9 17l-5-5",key:"1gmf2c"}]])},7740:(e,t,n)=>{n.d(t,{qW:()=>d});var r,o=n(4773),i=n(4053),l=n(63),a=n(5034),u=n(819),s=n(5386),c="dismissableLayer.update",f=o.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),d=o.forwardRef((e,t)=>{var n,d;let{disableOutsidePointerEvents:h=!1,onEscapeKeyDown:g,onPointerDownOutside:v,onFocusOutside:y,onInteractOutside:w,onDismiss:x,...b}=e,E=o.useContext(f),[C,R]=o.useState(null),T=null!=(d=null==C?void 0:C.ownerDocument)?d:null==(n=globalThis)?void 0:n.document,[,L]=o.useState({}),A=(0,a.s)(t,e=>R(e)),O=Array.from(E.layers),[P]=[...E.layersWithOutsidePointerEventsDisabled].slice(-1),S=O.indexOf(P),N=C?O.indexOf(C):-1,k=E.layersWithOutsidePointerEventsDisabled.size>0,D=N>=S,M=function(e){var t;let n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null==(t=globalThis)?void 0:t.document,r=(0,u.c)(e),i=o.useRef(!1),l=o.useRef(()=>{});return o.useEffect(()=>{let e=e=>{if(e.target&&!i.current){let t=function(){m("dismissableLayer.pointerDownOutside",r,o,{discrete:!0})},o={originalEvent:e};"touch"===e.pointerType?(n.removeEventListener("click",l.current),l.current=t,n.addEventListener("click",l.current,{once:!0})):t()}else n.removeEventListener("click",l.current);i.current=!1},t=window.setTimeout(()=>{n.addEventListener("pointerdown",e)},0);return()=>{window.clearTimeout(t),n.removeEventListener("pointerdown",e),n.removeEventListener("click",l.current)}},[n,r]),{onPointerDownCapture:()=>i.current=!0}}(e=>{let t=e.target,n=[...E.branches].some(e=>e.contains(t));D&&!n&&(null==v||v(e),null==w||w(e),e.defaultPrevented||null==x||x())},T),j=function(e){var t;let n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null==(t=globalThis)?void 0:t.document,r=(0,u.c)(e),i=o.useRef(!1);return o.useEffect(()=>{let e=e=>{e.target&&!i.current&&m("dismissableLayer.focusOutside",r,{originalEvent:e},{discrete:!1})};return n.addEventListener("focusin",e),()=>n.removeEventListener("focusin",e)},[n,r]),{onFocusCapture:()=>i.current=!0,onBlurCapture:()=>i.current=!1}}(e=>{let t=e.target;![...E.branches].some(e=>e.contains(t))&&(null==y||y(e),null==w||w(e),e.defaultPrevented||null==x||x())},T);return!function(e,t=globalThis?.document){let n=(0,u.c)(e);o.useEffect(()=>{let e=e=>{"Escape"===e.key&&n(e)};return t.addEventListener("keydown",e,{capture:!0}),()=>t.removeEventListener("keydown",e,{capture:!0})},[n,t])}(e=>{N===E.layers.size-1&&(null==g||g(e),!e.defaultPrevented&&x&&(e.preventDefault(),x()))},T),o.useEffect(()=>{if(C)return h&&(0===E.layersWithOutsidePointerEventsDisabled.size&&(r=T.body.style.pointerEvents,T.body.style.pointerEvents="none"),E.layersWithOutsidePointerEventsDisabled.add(C)),E.layers.add(C),p(),()=>{h&&1===E.layersWithOutsidePointerEventsDisabled.size&&(T.body.style.pointerEvents=r)}},[C,T,h,E]),o.useEffect(()=>()=>{C&&(E.layers.delete(C),E.layersWithOutsidePointerEventsDisabled.delete(C),p())},[C,E]),o.useEffect(()=>{let e=()=>L({});return document.addEventListener(c,e),()=>document.removeEventListener(c,e)},[]),(0,s.jsx)(l.sG.div,{...b,ref:A,style:{pointerEvents:k?D?"auto":"none":void 0,...e.style},onFocusCapture:(0,i.mK)(e.onFocusCapture,j.onFocusCapture),onBlurCapture:(0,i.mK)(e.onBlurCapture,j.onBlurCapture),onPointerDownCapture:(0,i.mK)(e.onPointerDownCapture,M.onPointerDownCapture)})});function p(){let e=new CustomEvent(c);document.dispatchEvent(e)}function m(e,t,n,r){let{discrete:o}=r,i=n.originalEvent.target,a=new CustomEvent(e,{bubbles:!1,cancelable:!0,detail:n});t&&i.addEventListener(e,t,{once:!0}),o?(0,l.hO)(i,a):i.dispatchEvent(a)}d.displayName="DismissableLayer",o.forwardRef((e,t)=>{let n=o.useContext(f),r=o.useRef(null),i=(0,a.s)(t,r);return o.useEffect(()=>{let e=r.current;if(e)return n.branches.add(e),()=>{n.branches.delete(e)}},[n.branches]),(0,s.jsx)(l.sG.div,{...e,ref:i})}).displayName="DismissableLayerBranch"},8251:(e,t,n)=>{n.d(t,{UC:()=>V,Kq:()=>z,bL:()=>U,Bc:()=>T,l9:()=>$});var r=n(4773),o=n(4053),i=n(5034),l=n(7328),a=n(7740),u=n(5987),s=n(9448),c=(n(9302),n(3049)),f=e=>{let{present:t,children:n}=e,o=function(e){var t,n;let[o,i]=r.useState(),l=r.useRef(null),a=r.useRef(e),u=r.useRef("none"),[s,f]=(t=e?"mounted":"unmounted",n={mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}},r.useReducer((e,t)=>{let r=n[e][t];return null!=r?r:e},t));return r.useEffect(()=>{let e=d(l.current);u.current="mounted"===s?e:"none"},[s]),(0,c.N)(()=>{let t=l.current,n=a.current;if(n!==e){let r=u.current,o=d(t);e?f("MOUNT"):"none"===o||(null==t?void 0:t.display)==="none"?f("UNMOUNT"):n&&r!==o?f("ANIMATION_OUT"):f("UNMOUNT"),a.current=e}},[e,f]),(0,c.N)(()=>{if(o){var e;let t,n=null!=(e=o.ownerDocument.defaultView)?e:window,r=e=>{let r=d(l.current).includes(CSS.escape(e.animationName));if(e.target===o&&r&&(f("ANIMATION_END"),!a.current)){let e=o.style.animationFillMode;o.style.animationFillMode="forwards",t=n.setTimeout(()=>{"forwards"===o.style.animationFillMode&&(o.style.animationFillMode=e)})}},i=e=>{e.target===o&&(u.current=d(l.current))};return o.addEventListener("animationstart",i),o.addEventListener("animationcancel",r),o.addEventListener("animationend",r),()=>{n.clearTimeout(t),o.removeEventListener("animationstart",i),o.removeEventListener("animationcancel",r),o.removeEventListener("animationend",r)}}f("ANIMATION_END")},[o,f]),{isPresent:["mounted","unmountSuspended"].includes(s),ref:r.useCallback(e=>{l.current=e?getComputedStyle(e):null,i(e)},[])}}(t),l="function"==typeof n?n({present:o.isPresent}):r.Children.only(n),a=(0,i.s)(o.ref,function(e){var t,n;let r=null==(t=Object.getOwnPropertyDescriptor(e.props,"ref"))?void 0:t.get,o=r&&"isReactWarning"in r&&r.isReactWarning;return o?e.ref:(o=(r=null==(n=Object.getOwnPropertyDescriptor(e,"ref"))?void 0:n.get)&&"isReactWarning"in r&&r.isReactWarning)?e.props.ref:e.props.ref||e.ref}(l));return"function"==typeof n||o.isPresent?r.cloneElement(l,{ref:a}):null};function d(e){return(null==e?void 0:e.animationName)||"none"}f.displayName="Presence";var p=n(63),m=n(9280),h=n(9559),g=n(607),v=n(5386),[y,w]=(0,l.A)("Tooltip",[s.Bk]),x=(0,s.Bk)(),b="TooltipProvider",E="tooltip.open",[C,R]=y(b),T=e=>{let{__scopeTooltip:t,delayDuration:n=700,skipDelayDuration:o=300,disableHoverableContent:i=!1,children:l}=e,a=r.useRef(!0),u=r.useRef(!1),s=r.useRef(0);return r.useEffect(()=>{let e=s.current;return()=>window.clearTimeout(e)},[]),(0,v.jsx)(C,{scope:t,isOpenDelayedRef:a,delayDuration:n,onOpen:r.useCallback(()=>{window.clearTimeout(s.current),a.current=!1},[]),onClose:r.useCallback(()=>{window.clearTimeout(s.current),s.current=window.setTimeout(()=>a.current=!0,o)},[o]),isPointerInTransitRef:u,onPointerInTransitChange:r.useCallback(e=>{u.current=e},[]),disableHoverableContent:i,children:l})};T.displayName=b;var L="Tooltip",[A,O]=y(L),P=e=>{let{__scopeTooltip:t,children:n,open:o,defaultOpen:i,onOpenChange:l,disableHoverableContent:a,delayDuration:c}=e,f=R(L,e.__scopeTooltip),d=x(t),[p,m]=r.useState(null),g=(0,u.B)(),y=r.useRef(0),w=null!=a?a:f.disableHoverableContent,b=null!=c?c:f.delayDuration,C=r.useRef(!1),[T,O]=(0,h.i)({prop:o,defaultProp:null!=i&&i,onChange:e=>{e?(f.onOpen(),document.dispatchEvent(new CustomEvent(E))):f.onClose(),null==l||l(e)},caller:L}),P=r.useMemo(()=>T?C.current?"delayed-open":"instant-open":"closed",[T]),S=r.useCallback(()=>{window.clearTimeout(y.current),y.current=0,C.current=!1,O(!0)},[O]),N=r.useCallback(()=>{window.clearTimeout(y.current),y.current=0,O(!1)},[O]),k=r.useCallback(()=>{window.clearTimeout(y.current),y.current=window.setTimeout(()=>{C.current=!0,O(!0),y.current=0},b)},[b,O]);return r.useEffect(()=>()=>{y.current&&(window.clearTimeout(y.current),y.current=0)},[]),(0,v.jsx)(s.bL,{...d,children:(0,v.jsx)(A,{scope:t,contentId:g,open:T,stateAttribute:P,trigger:p,onTriggerChange:m,onTriggerEnter:r.useCallback(()=>{f.isOpenDelayedRef.current?k():S()},[f.isOpenDelayedRef,k,S]),onTriggerLeave:r.useCallback(()=>{w?N():(window.clearTimeout(y.current),y.current=0)},[N,w]),onOpen:S,onClose:N,disableHoverableContent:w,children:n})})};P.displayName=L;var S="TooltipTrigger",N=r.forwardRef((e,t)=>{let{__scopeTooltip:n,...l}=e,a=O(S,n),u=R(S,n),c=x(n),f=r.useRef(null),d=(0,i.s)(t,f,a.onTriggerChange),m=r.useRef(!1),h=r.useRef(!1),g=r.useCallback(()=>m.current=!1,[]);return r.useEffect(()=>()=>document.removeEventListener("pointerup",g),[g]),(0,v.jsx)(s.Mz,{asChild:!0,...c,children:(0,v.jsx)(p.sG.button,{"aria-describedby":a.open?a.contentId:void 0,"data-state":a.stateAttribute,...l,ref:d,onPointerMove:(0,o.mK)(e.onPointerMove,e=>{"touch"!==e.pointerType&&(h.current||u.isPointerInTransitRef.current||(a.onTriggerEnter(),h.current=!0))}),onPointerLeave:(0,o.mK)(e.onPointerLeave,()=>{a.onTriggerLeave(),h.current=!1}),onPointerDown:(0,o.mK)(e.onPointerDown,()=>{a.open&&a.onClose(),m.current=!0,document.addEventListener("pointerup",g,{once:!0})}),onFocus:(0,o.mK)(e.onFocus,()=>{m.current||a.onOpen()}),onBlur:(0,o.mK)(e.onBlur,a.onClose),onClick:(0,o.mK)(e.onClick,a.onClose)})})});N.displayName=S;var[k,D]=y("TooltipPortal",{forceMount:void 0}),M="TooltipContent",j=r.forwardRef((e,t)=>{let n=D(M,e.__scopeTooltip),{forceMount:r=n.forceMount,side:o="top",...i}=e,l=O(M,e.__scopeTooltip);return(0,v.jsx)(f,{present:r||l.open,children:l.disableHoverableContent?(0,v.jsx)(H,{side:o,...i,ref:t}):(0,v.jsx)(W,{side:o,...i,ref:t})})}),W=r.forwardRef((e,t)=>{let n=O(M,e.__scopeTooltip),o=R(M,e.__scopeTooltip),l=r.useRef(null),a=(0,i.s)(t,l),[u,s]=r.useState(null),{trigger:c,onClose:f}=n,d=l.current,{onPointerInTransitChange:p}=o,m=r.useCallback(()=>{s(null),p(!1)},[p]),h=r.useCallback((e,t)=>{let n=e.currentTarget,r={x:e.clientX,y:e.clientY},o=function(e,t){let n=Math.abs(t.top-e.y),r=Math.abs(t.bottom-e.y),o=Math.abs(t.right-e.x),i=Math.abs(t.left-e.x);switch(Math.min(n,r,o,i)){case i:return"left";case o:return"right";case n:return"top";case r:return"bottom";default:throw Error("unreachable")}}(r,n.getBoundingClientRect());s(function(e){let t=e.slice();return t.sort((e,t)=>e.x<t.x?-1:e.x>t.x?1:e.y<t.y?-1:1*!!(e.y>t.y)),function(e){if(e.length<=1)return e.slice();let t=[];for(let n=0;n<e.length;n++){let r=e[n];for(;t.length>=2;){let e=t[t.length-1],n=t[t.length-2];if((e.x-n.x)*(r.y-n.y)>=(e.y-n.y)*(r.x-n.x))t.pop();else break}t.push(r)}t.pop();let n=[];for(let t=e.length-1;t>=0;t--){let r=e[t];for(;n.length>=2;){let e=n[n.length-1],t=n[n.length-2];if((e.x-t.x)*(r.y-t.y)>=(e.y-t.y)*(r.x-t.x))n.pop();else break}n.push(r)}return(n.pop(),1===t.length&&1===n.length&&t[0].x===n[0].x&&t[0].y===n[0].y)?t:t.concat(n)}(t)}([...function(e,t){let n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:5,r=[];switch(t){case"top":r.push({x:e.x-n,y:e.y+n},{x:e.x+n,y:e.y+n});break;case"bottom":r.push({x:e.x-n,y:e.y-n},{x:e.x+n,y:e.y-n});break;case"left":r.push({x:e.x+n,y:e.y-n},{x:e.x+n,y:e.y+n});break;case"right":r.push({x:e.x-n,y:e.y-n},{x:e.x-n,y:e.y+n})}return r}(r,o),...function(e){let{top:t,right:n,bottom:r,left:o}=e;return[{x:o,y:t},{x:n,y:t},{x:n,y:r},{x:o,y:r}]}(t.getBoundingClientRect())])),p(!0)},[p]);return r.useEffect(()=>()=>m(),[m]),r.useEffect(()=>{if(c&&d){let e=e=>h(e,d),t=e=>h(e,c);return c.addEventListener("pointerleave",e),d.addEventListener("pointerleave",t),()=>{c.removeEventListener("pointerleave",e),d.removeEventListener("pointerleave",t)}}},[c,d,h,m]),r.useEffect(()=>{if(u){let e=e=>{let t=e.target,n={x:e.clientX,y:e.clientY},r=(null==c?void 0:c.contains(t))||(null==d?void 0:d.contains(t)),o=!function(e,t){let{x:n,y:r}=e,o=!1;for(let e=0,i=t.length-1;e<t.length;i=e++){let l=t[e],a=t[i],u=l.x,s=l.y,c=a.x,f=a.y;s>r!=f>r&&n<(c-u)*(r-s)/(f-s)+u&&(o=!o)}return o}(n,u);r?m():o&&(m(),f())};return document.addEventListener("pointermove",e),()=>document.removeEventListener("pointermove",e)}},[c,d,u,f,m]),(0,v.jsx)(H,{...e,ref:a})}),[_,F]=y(L,{isInside:!1}),B=(0,m.Dc)("TooltipContent"),H=r.forwardRef((e,t)=>{let{__scopeTooltip:n,children:o,"aria-label":i,onEscapeKeyDown:l,onPointerDownOutside:u,...c}=e,f=O(M,n),d=x(n),{onClose:p}=f;return r.useEffect(()=>(document.addEventListener(E,p),()=>document.removeEventListener(E,p)),[p]),r.useEffect(()=>{if(f.trigger){let e=e=>{let t=e.target;(null==t?void 0:t.contains(f.trigger))&&p()};return window.addEventListener("scroll",e,{capture:!0}),()=>window.removeEventListener("scroll",e,{capture:!0})}},[f.trigger,p]),(0,v.jsx)(a.qW,{asChild:!0,disableOutsidePointerEvents:!1,onEscapeKeyDown:l,onPointerDownOutside:u,onFocusOutside:e=>e.preventDefault(),onDismiss:p,children:(0,v.jsxs)(s.UC,{"data-state":f.stateAttribute,...d,...c,ref:t,style:{...c.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)"},children:[(0,v.jsx)(B,{children:o}),(0,v.jsx)(_,{scope:n,isInside:!0,children:(0,v.jsx)(g.bL,{id:f.contentId,role:"tooltip",children:i||o})})]})})});j.displayName=M;var I="TooltipArrow";r.forwardRef((e,t)=>{let{__scopeTooltip:n,...r}=e,o=x(n);return F(I,n).isInside?null:(0,v.jsx)(s.i3,{...o,...r,ref:t})}).displayName=I;var z=T,U=P,$=N,V=j},9302:(e,t,n)=>{n.d(t,{Z:()=>u});var r=n(4773),o=n(1471),i=n(63),l=n(3049),a=n(5386),u=r.forwardRef((e,t)=>{var n,u;let{container:s,...c}=e,[f,d]=r.useState(!1);(0,l.N)(()=>d(!0),[]);let p=s||f&&(null==(u=globalThis)||null==(n=u.document)?void 0:n.body);return p?o.createPortal((0,a.jsx)(i.sG.div,{...c,ref:t}),p):null});u.displayName="Portal"},9448:(e,t,n)=>{n.d(t,{Mz:()=>e0,i3:()=>e3,UC:()=>e1,bL:()=>eJ,Bk:()=>e_});var r=n(4773);let o=["top","right","bottom","left"],i=Math.min,l=Math.max,a=Math.round,u=Math.floor,s=e=>({x:e,y:e}),c={left:"right",right:"left",bottom:"top",top:"bottom"},f={start:"end",end:"start"};function d(e,t){return"function"==typeof e?e(t):e}function p(e){return e.split("-")[0]}function m(e){return e.split("-")[1]}function h(e){return"x"===e?"y":"x"}function g(e){return"y"===e?"height":"width"}let v=new Set(["top","bottom"]);function y(e){return v.has(p(e))?"y":"x"}function w(e){return e.replace(/start|end/g,e=>f[e])}let x=["left","right"],b=["right","left"],E=["top","bottom"],C=["bottom","top"];function R(e){return e.replace(/left|right|bottom|top/g,e=>c[e])}function T(e){return"number"!=typeof e?{top:0,right:0,bottom:0,left:0,...e}:{top:e,right:e,bottom:e,left:e}}function L(e){let{x:t,y:n,width:r,height:o}=e;return{width:r,height:o,top:n,left:t,right:t+r,bottom:n+o,x:t,y:n}}function A(e,t,n){let r,{reference:o,floating:i}=e,l=y(t),a=h(y(t)),u=g(a),s=p(t),c="y"===l,f=o.x+o.width/2-i.width/2,d=o.y+o.height/2-i.height/2,v=o[u]/2-i[u]/2;switch(s){case"top":r={x:f,y:o.y-i.height};break;case"bottom":r={x:f,y:o.y+o.height};break;case"right":r={x:o.x+o.width,y:d};break;case"left":r={x:o.x-i.width,y:d};break;default:r={x:o.x,y:o.y}}switch(m(t)){case"start":r[a]-=v*(n&&c?-1:1);break;case"end":r[a]+=v*(n&&c?-1:1)}return r}let O=async(e,t,n)=>{let{placement:r="bottom",strategy:o="absolute",middleware:i=[],platform:l}=n,a=i.filter(Boolean),u=await (null==l.isRTL?void 0:l.isRTL(t)),s=await l.getElementRects({reference:e,floating:t,strategy:o}),{x:c,y:f}=A(s,r,u),d=r,p={},m=0;for(let n=0;n<a.length;n++){let{name:i,fn:h}=a[n],{x:g,y:v,data:y,reset:w}=await h({x:c,y:f,initialPlacement:r,placement:d,strategy:o,middlewareData:p,rects:s,platform:l,elements:{reference:e,floating:t}});c=null!=g?g:c,f=null!=v?v:f,p={...p,[i]:{...p[i],...y}},w&&m<=50&&(m++,"object"==typeof w&&(w.placement&&(d=w.placement),w.rects&&(s=!0===w.rects?await l.getElementRects({reference:e,floating:t,strategy:o}):w.rects),{x:c,y:f}=A(s,d,u)),n=-1)}return{x:c,y:f,placement:d,strategy:o,middlewareData:p}};async function P(e,t){var n;void 0===t&&(t={});let{x:r,y:o,platform:i,rects:l,elements:a,strategy:u}=e,{boundary:s="clippingAncestors",rootBoundary:c="viewport",elementContext:f="floating",altBoundary:p=!1,padding:m=0}=d(t,e),h=T(m),g=a[p?"floating"===f?"reference":"floating":f],v=L(await i.getClippingRect({element:null==(n=await (null==i.isElement?void 0:i.isElement(g)))||n?g:g.contextElement||await (null==i.getDocumentElement?void 0:i.getDocumentElement(a.floating)),boundary:s,rootBoundary:c,strategy:u})),y="floating"===f?{x:r,y:o,width:l.floating.width,height:l.floating.height}:l.reference,w=await (null==i.getOffsetParent?void 0:i.getOffsetParent(a.floating)),x=await (null==i.isElement?void 0:i.isElement(w))&&await (null==i.getScale?void 0:i.getScale(w))||{x:1,y:1},b=L(i.convertOffsetParentRelativeRectToViewportRelativeRect?await i.convertOffsetParentRelativeRectToViewportRelativeRect({elements:a,rect:y,offsetParent:w,strategy:u}):y);return{top:(v.top-b.top+h.top)/x.y,bottom:(b.bottom-v.bottom+h.bottom)/x.y,left:(v.left-b.left+h.left)/x.x,right:(b.right-v.right+h.right)/x.x}}function S(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function N(e){return o.some(t=>e[t]>=0)}let k=new Set(["left","top"]);async function D(e,t){let{placement:n,platform:r,elements:o}=e,i=await (null==r.isRTL?void 0:r.isRTL(o.floating)),l=p(n),a=m(n),u="y"===y(n),s=k.has(l)?-1:1,c=i&&u?-1:1,f=d(t,e),{mainAxis:h,crossAxis:g,alignmentAxis:v}="number"==typeof f?{mainAxis:f,crossAxis:0,alignmentAxis:null}:{mainAxis:f.mainAxis||0,crossAxis:f.crossAxis||0,alignmentAxis:f.alignmentAxis};return a&&"number"==typeof v&&(g="end"===a?-1*v:v),u?{x:g*c,y:h*s}:{x:h*s,y:g*c}}function M(){return"undefined"!=typeof window}function j(e){return F(e)?(e.nodeName||"").toLowerCase():"#document"}function W(e){var t;return(null==e||null==(t=e.ownerDocument)?void 0:t.defaultView)||window}function _(e){var t;return null==(t=(F(e)?e.ownerDocument:e.document)||window.document)?void 0:t.documentElement}function F(e){return!!M()&&(e instanceof Node||e instanceof W(e).Node)}function B(e){return!!M()&&(e instanceof Element||e instanceof W(e).Element)}function H(e){return!!M()&&(e instanceof HTMLElement||e instanceof W(e).HTMLElement)}function I(e){return!!M()&&"undefined"!=typeof ShadowRoot&&(e instanceof ShadowRoot||e instanceof W(e).ShadowRoot)}let z=new Set(["inline","contents"]);function U(e){let{overflow:t,overflowX:n,overflowY:r,display:o}=ee(e);return/auto|scroll|overlay|hidden|clip/.test(t+r+n)&&!z.has(o)}let $=new Set(["table","td","th"]),V=[":popover-open",":modal"];function K(e){return V.some(t=>{try{return e.matches(t)}catch(e){return!1}})}let G=["transform","translate","scale","rotate","perspective"],Y=["transform","translate","scale","rotate","perspective","filter"],X=["paint","layout","strict","content"];function q(e){let t=Q(),n=B(e)?ee(e):e;return G.some(e=>!!n[e]&&"none"!==n[e])||!!n.containerType&&"normal"!==n.containerType||!t&&!!n.backdropFilter&&"none"!==n.backdropFilter||!t&&!!n.filter&&"none"!==n.filter||Y.some(e=>(n.willChange||"").includes(e))||X.some(e=>(n.contain||"").includes(e))}function Q(){return"undefined"!=typeof CSS&&!!CSS.supports&&CSS.supports("-webkit-backdrop-filter","none")}let Z=new Set(["html","body","#document"]);function J(e){return Z.has(j(e))}function ee(e){return W(e).getComputedStyle(e)}function et(e){return B(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function en(e){if("html"===j(e))return e;let t=e.assignedSlot||e.parentNode||I(e)&&e.host||_(e);return I(t)?t.host:t}function er(e,t,n){var r;void 0===t&&(t=[]),void 0===n&&(n=!0);let o=function e(t){let n=en(t);return J(n)?t.ownerDocument?t.ownerDocument.body:t.body:H(n)&&U(n)?n:e(n)}(e),i=o===(null==(r=e.ownerDocument)?void 0:r.body),l=W(o);if(i){let e=eo(l);return t.concat(l,l.visualViewport||[],U(o)?o:[],e&&n?er(e):[])}return t.concat(o,er(o,[],n))}function eo(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}function ei(e){let t=ee(e),n=parseFloat(t.width)||0,r=parseFloat(t.height)||0,o=H(e),i=o?e.offsetWidth:n,l=o?e.offsetHeight:r,u=a(n)!==i||a(r)!==l;return u&&(n=i,r=l),{width:n,height:r,$:u}}function el(e){return B(e)?e:e.contextElement}function ea(e){let t=el(e);if(!H(t))return s(1);let n=t.getBoundingClientRect(),{width:r,height:o,$:i}=ei(t),l=(i?a(n.width):n.width)/r,u=(i?a(n.height):n.height)/o;return l&&Number.isFinite(l)||(l=1),u&&Number.isFinite(u)||(u=1),{x:l,y:u}}let eu=s(0);function es(e){let t=W(e);return Q()&&t.visualViewport?{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}:eu}function ec(e,t,n,r){var o;void 0===t&&(t=!1),void 0===n&&(n=!1);let i=e.getBoundingClientRect(),l=el(e),a=s(1);t&&(r?B(r)&&(a=ea(r)):a=ea(e));let u=(void 0===(o=n)&&(o=!1),r&&(!o||r===W(l))&&o)?es(l):s(0),c=(i.left+u.x)/a.x,f=(i.top+u.y)/a.y,d=i.width/a.x,p=i.height/a.y;if(l){let e=W(l),t=r&&B(r)?W(r):r,n=e,o=eo(n);for(;o&&r&&t!==n;){let e=ea(o),t=o.getBoundingClientRect(),r=ee(o),i=t.left+(o.clientLeft+parseFloat(r.paddingLeft))*e.x,l=t.top+(o.clientTop+parseFloat(r.paddingTop))*e.y;c*=e.x,f*=e.y,d*=e.x,p*=e.y,c+=i,f+=l,o=eo(n=W(o))}}return L({width:d,height:p,x:c,y:f})}function ef(e,t){let n=et(e).scrollLeft;return t?t.left+n:ec(_(e)).left+n}function ed(e,t){let n=e.getBoundingClientRect();return{x:n.left+t.scrollLeft-ef(e,n),y:n.top+t.scrollTop}}let ep=new Set(["absolute","fixed"]);function em(e,t,n){let r;if("viewport"===t)r=function(e,t){let n=W(e),r=_(e),o=n.visualViewport,i=r.clientWidth,l=r.clientHeight,a=0,u=0;if(o){i=o.width,l=o.height;let e=Q();(!e||e&&"fixed"===t)&&(a=o.offsetLeft,u=o.offsetTop)}let s=ef(r);if(s<=0){let e=r.ownerDocument,t=e.body,n=getComputedStyle(t),o="CSS1Compat"===e.compatMode&&parseFloat(n.marginLeft)+parseFloat(n.marginRight)||0,l=Math.abs(r.clientWidth-t.clientWidth-o);l<=25&&(i-=l)}else s<=25&&(i+=s);return{width:i,height:l,x:a,y:u}}(e,n);else if("document"===t)r=function(e){let t=_(e),n=et(e),r=e.ownerDocument.body,o=l(t.scrollWidth,t.clientWidth,r.scrollWidth,r.clientWidth),i=l(t.scrollHeight,t.clientHeight,r.scrollHeight,r.clientHeight),a=-n.scrollLeft+ef(e),u=-n.scrollTop;return"rtl"===ee(r).direction&&(a+=l(t.clientWidth,r.clientWidth)-o),{width:o,height:i,x:a,y:u}}(_(e));else if(B(t))r=function(e,t){let n=ec(e,!0,"fixed"===t),r=n.top+e.clientTop,o=n.left+e.clientLeft,i=H(e)?ea(e):s(1),l=e.clientWidth*i.x,a=e.clientHeight*i.y;return{width:l,height:a,x:o*i.x,y:r*i.y}}(t,n);else{let n=es(e);r={x:t.x-n.x,y:t.y-n.y,width:t.width,height:t.height}}return L(r)}function eh(e){return"static"===ee(e).position}function eg(e,t){if(!H(e)||"fixed"===ee(e).position)return null;if(t)return t(e);let n=e.offsetParent;return _(e)===n&&(n=n.ownerDocument.body),n}function ev(e,t){var n;let r=W(e);if(K(e))return r;if(!H(e)){let t=en(e);for(;t&&!J(t);){if(B(t)&&!eh(t))return t;t=en(t)}return r}let o=eg(e,t);for(;o&&(n=o,$.has(j(n)))&&eh(o);)o=eg(o,t);return o&&J(o)&&eh(o)&&!q(o)?r:o||function(e){let t=en(e);for(;H(t)&&!J(t);){if(q(t))return t;if(K(t))break;t=en(t)}return null}(e)||r}let ey=async function(e){let t=this.getOffsetParent||ev,n=this.getDimensions,r=await n(e.floating);return{reference:function(e,t,n){let r=H(t),o=_(t),i="fixed"===n,l=ec(e,!0,i,t),a={scrollLeft:0,scrollTop:0},u=s(0);if(r||!r&&!i)if(("body"!==j(t)||U(o))&&(a=et(t)),r){let e=ec(t,!0,i,t);u.x=e.x+t.clientLeft,u.y=e.y+t.clientTop}else o&&(u.x=ef(o));i&&!r&&o&&(u.x=ef(o));let c=!o||r||i?s(0):ed(o,a);return{x:l.left+a.scrollLeft-u.x-c.x,y:l.top+a.scrollTop-u.y-c.y,width:l.width,height:l.height}}(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,width:r.width,height:r.height}}},ew={convertOffsetParentRelativeRectToViewportRelativeRect:function(e){let{elements:t,rect:n,offsetParent:r,strategy:o}=e,i="fixed"===o,l=_(r),a=!!t&&K(t.floating);if(r===l||a&&i)return n;let u={scrollLeft:0,scrollTop:0},c=s(1),f=s(0),d=H(r);if((d||!d&&!i)&&(("body"!==j(r)||U(l))&&(u=et(r)),H(r))){let e=ec(r);c=ea(r),f.x=e.x+r.clientLeft,f.y=e.y+r.clientTop}let p=!l||d||i?s(0):ed(l,u);return{width:n.width*c.x,height:n.height*c.y,x:n.x*c.x-u.scrollLeft*c.x+f.x+p.x,y:n.y*c.y-u.scrollTop*c.y+f.y+p.y}},getDocumentElement:_,getClippingRect:function(e){let{element:t,boundary:n,rootBoundary:r,strategy:o}=e,a=[..."clippingAncestors"===n?K(t)?[]:function(e,t){let n=t.get(e);if(n)return n;let r=er(e,[],!1).filter(e=>B(e)&&"body"!==j(e)),o=null,i="fixed"===ee(e).position,l=i?en(e):e;for(;B(l)&&!J(l);){let t=ee(l),n=q(l);n||"fixed"!==t.position||(o=null),(i?!n&&!o:!n&&"static"===t.position&&!!o&&ep.has(o.position)||U(l)&&!n&&function e(t,n){let r=en(t);return!(r===n||!B(r)||J(r))&&("fixed"===ee(r).position||e(r,n))}(e,l))?r=r.filter(e=>e!==l):o=t,l=en(l)}return t.set(e,r),r}(t,this._c):[].concat(n),r],u=a[0],s=a.reduce((e,n)=>{let r=em(t,n,o);return e.top=l(r.top,e.top),e.right=i(r.right,e.right),e.bottom=i(r.bottom,e.bottom),e.left=l(r.left,e.left),e},em(t,u,o));return{width:s.right-s.left,height:s.bottom-s.top,x:s.left,y:s.top}},getOffsetParent:ev,getElementRects:ey,getClientRects:function(e){return Array.from(e.getClientRects())},getDimensions:function(e){let{width:t,height:n}=ei(e);return{width:t,height:n}},getScale:ea,isElement:B,isRTL:function(e){return"rtl"===ee(e).direction}};function ex(e,t){return e.x===t.x&&e.y===t.y&&e.width===t.width&&e.height===t.height}let eb=e=>({name:"arrow",options:e,async fn(t){let{x:n,y:r,placement:o,rects:a,platform:u,elements:s,middlewareData:c}=t,{element:f,padding:p=0}=d(e,t)||{};if(null==f)return{};let v=T(p),w={x:n,y:r},x=h(y(o)),b=g(x),E=await u.getDimensions(f),C="y"===x,R=C?"clientHeight":"clientWidth",L=a.reference[b]+a.reference[x]-w[x]-a.floating[b],A=w[x]-a.reference[x],O=await (null==u.getOffsetParent?void 0:u.getOffsetParent(f)),P=O?O[R]:0;P&&await (null==u.isElement?void 0:u.isElement(O))||(P=s.floating[R]||a.floating[b]);let S=P/2-E[b]/2-1,N=i(v[C?"top":"left"],S),k=i(v[C?"bottom":"right"],S),D=P-E[b]-k,M=P/2-E[b]/2+(L/2-A/2),j=l(N,i(M,D)),W=!c.arrow&&null!=m(o)&&M!==j&&a.reference[b]/2-(M<N?N:k)-E[b]/2<0,_=W?M<N?M-N:M-D:0;return{[x]:w[x]+_,data:{[x]:j,centerOffset:M-j-_,...W&&{alignmentOffset:_}},reset:W}}});var eE=n(1471),eC="undefined"!=typeof document?r.useLayoutEffect:function(){};function eR(e,t){let n,r,o;if(e===t)return!0;if(typeof e!=typeof t)return!1;if("function"==typeof e&&e.toString()===t.toString())return!0;if(e&&t&&"object"==typeof e){if(Array.isArray(e)){if((n=e.length)!==t.length)return!1;for(r=n;0!=r--;)if(!eR(e[r],t[r]))return!1;return!0}if((n=(o=Object.keys(e)).length)!==Object.keys(t).length)return!1;for(r=n;0!=r--;)if(!({}).hasOwnProperty.call(t,o[r]))return!1;for(r=n;0!=r--;){let n=o[r];if(("_owner"!==n||!e.$$typeof)&&!eR(e[n],t[n]))return!1}return!0}return e!=e&&t!=t}function eT(e){return"undefined"==typeof window?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function eL(e,t){let n=eT(e);return Math.round(t*n)/n}function eA(e){let t=r.useRef(e);return eC(()=>{t.current=e}),t}var eO=n(63),eP=n(5386),eS=r.forwardRef((e,t)=>{let{children:n,width:r=10,height:o=5,...i}=e;return(0,eP.jsx)(eO.sG.svg,{...i,ref:t,width:r,height:o,viewBox:"0 0 30 10",preserveAspectRatio:"none",children:e.asChild?n:(0,eP.jsx)("polygon",{points:"0,0 30,0 15,10"})})});eS.displayName="Arrow";var eN=n(5034),ek=n(7328),eD=n(819),eM=n(3049),ej="Popper",[eW,e_]=(0,ek.A)(ej),[eF,eB]=eW(ej),eH=e=>{let{__scopePopper:t,children:n}=e,[o,i]=r.useState(null);return(0,eP.jsx)(eF,{scope:t,anchor:o,onAnchorChange:i,children:n})};eH.displayName=ej;var eI="PopperAnchor",ez=r.forwardRef((e,t)=>{let{__scopePopper:n,virtualRef:o,...i}=e,l=eB(eI,n),a=r.useRef(null),u=(0,eN.s)(t,a),s=r.useRef(null);return r.useEffect(()=>{let e=s.current;s.current=(null==o?void 0:o.current)||a.current,e!==s.current&&l.onAnchorChange(s.current)}),o?null:(0,eP.jsx)(eO.sG.div,{...i,ref:u})});ez.displayName=eI;var eU="PopperContent",[e$,eV]=eW(eU),eK=r.forwardRef((e,t)=>{var n,o,a,s,c,f,v,T;let{__scopePopper:L,side:A="bottom",sideOffset:M=0,align:j="center",alignOffset:W=0,arrowPadding:F=0,avoidCollisions:B=!0,collisionBoundary:H=[],collisionPadding:I=0,sticky:z="partial",hideWhenDetached:U=!1,updatePositionStrategy:$="optimized",onPlaced:V,...K}=e,G=eB(eU,L),[Y,X]=r.useState(null),q=(0,eN.s)(t,e=>X(e)),[Q,Z]=r.useState(null),J=function(e){let[t,n]=r.useState(void 0);return(0,eM.N)(()=>{if(e){n({width:e.offsetWidth,height:e.offsetHeight});let t=new ResizeObserver(t=>{let r,o;if(!Array.isArray(t)||!t.length)return;let i=t[0];if("borderBoxSize"in i){let e=i.borderBoxSize,t=Array.isArray(e)?e[0]:e;r=t.inlineSize,o=t.blockSize}else r=e.offsetWidth,o=e.offsetHeight;n({width:r,height:o})});return t.observe(e,{box:"border-box"}),()=>t.unobserve(e)}n(void 0)},[e]),t}(Q),ee=null!=(v=null==J?void 0:J.width)?v:0,et=null!=(T=null==J?void 0:J.height)?T:0,en="number"==typeof I?I:{top:0,right:0,bottom:0,left:0,...I},eo=Array.isArray(H)?H:[H],ei=eo.length>0,ea={padding:en,boundary:eo.filter(eq),altBoundary:ei},{refs:eu,floatingStyles:es,placement:ef,isPositioned:ed,middlewareData:ep}=function(e){void 0===e&&(e={});let{placement:t="bottom",strategy:n="absolute",middleware:o=[],platform:i,elements:{reference:l,floating:a}={},transform:u=!0,whileElementsMounted:s,open:c}=e,[f,d]=r.useState({x:0,y:0,strategy:n,placement:t,middlewareData:{},isPositioned:!1}),[p,m]=r.useState(o);eR(p,o)||m(o);let[h,g]=r.useState(null),[v,y]=r.useState(null),w=r.useCallback(e=>{e!==C.current&&(C.current=e,g(e))},[]),x=r.useCallback(e=>{e!==R.current&&(R.current=e,y(e))},[]),b=l||h,E=a||v,C=r.useRef(null),R=r.useRef(null),T=r.useRef(f),L=null!=s,A=eA(s),P=eA(i),S=eA(c),N=r.useCallback(()=>{if(!C.current||!R.current)return;let e={placement:t,strategy:n,middleware:p};P.current&&(e.platform=P.current),((e,t,n)=>{let r=new Map,o={platform:ew,...n},i={...o.platform,_c:r};return O(e,t,{...o,platform:i})})(C.current,R.current,e).then(e=>{let t={...e,isPositioned:!1!==S.current};k.current&&!eR(T.current,t)&&(T.current=t,eE.flushSync(()=>{d(t)}))})},[p,t,n,P,S]);eC(()=>{!1===c&&T.current.isPositioned&&(T.current.isPositioned=!1,d(e=>({...e,isPositioned:!1})))},[c]);let k=r.useRef(!1);eC(()=>(k.current=!0,()=>{k.current=!1}),[]),eC(()=>{if(b&&(C.current=b),E&&(R.current=E),b&&E){if(A.current)return A.current(b,E,N);N()}},[b,E,N,A,L]);let D=r.useMemo(()=>({reference:C,floating:R,setReference:w,setFloating:x}),[w,x]),M=r.useMemo(()=>({reference:b,floating:E}),[b,E]),j=r.useMemo(()=>{let e={position:n,left:0,top:0};if(!M.floating)return e;let t=eL(M.floating,f.x),r=eL(M.floating,f.y);return u?{...e,transform:"translate("+t+"px, "+r+"px)",...eT(M.floating)>=1.5&&{willChange:"transform"}}:{position:n,left:t,top:r}},[n,u,M.floating,f.x,f.y]);return r.useMemo(()=>({...f,update:N,refs:D,elements:M,floatingStyles:j}),[f,N,D,M,j])}({strategy:"fixed",placement:A+("center"!==j?"-"+j:""),whileElementsMounted:function(){for(var e=arguments.length,t=Array(e),n=0;n<e;n++)t[n]=arguments[n];return function(e,t,n,r){let o;void 0===r&&(r={});let{ancestorScroll:a=!0,ancestorResize:s=!0,elementResize:c="function"==typeof ResizeObserver,layoutShift:f="function"==typeof IntersectionObserver,animationFrame:d=!1}=r,p=el(e),m=a||s?[...p?er(p):[],...er(t)]:[];m.forEach(e=>{a&&e.addEventListener("scroll",n,{passive:!0}),s&&e.addEventListener("resize",n)});let h=p&&f?function(e,t){let n,r=null,o=_(e);function a(){var e;clearTimeout(n),null==(e=r)||e.disconnect(),r=null}return!function s(c,f){void 0===c&&(c=!1),void 0===f&&(f=1),a();let d=e.getBoundingClientRect(),{left:p,top:m,width:h,height:g}=d;if(c||t(),!h||!g)return;let v=u(m),y=u(o.clientWidth-(p+h)),w={rootMargin:-v+"px "+-y+"px "+-u(o.clientHeight-(m+g))+"px "+-u(p)+"px",threshold:l(0,i(1,f))||1},x=!0;function b(t){let r=t[0].intersectionRatio;if(r!==f){if(!x)return s();r?s(!1,r):n=setTimeout(()=>{s(!1,1e-7)},1e3)}1!==r||ex(d,e.getBoundingClientRect())||s(),x=!1}try{r=new IntersectionObserver(b,{...w,root:o.ownerDocument})}catch(e){r=new IntersectionObserver(b,w)}r.observe(e)}(!0),a}(p,n):null,g=-1,v=null;c&&(v=new ResizeObserver(e=>{let[r]=e;r&&r.target===p&&v&&(v.unobserve(t),cancelAnimationFrame(g),g=requestAnimationFrame(()=>{var e;null==(e=v)||e.observe(t)})),n()}),p&&!d&&v.observe(p),v.observe(t));let y=d?ec(e):null;return d&&function t(){let r=ec(e);y&&!ex(y,r)&&n(),y=r,o=requestAnimationFrame(t)}(),n(),()=>{var e;m.forEach(e=>{a&&e.removeEventListener("scroll",n),s&&e.removeEventListener("resize",n)}),null==h||h(),null==(e=v)||e.disconnect(),v=null,d&&cancelAnimationFrame(o)}}(...t,{animationFrame:"always"===$})},elements:{reference:G.anchor},middleware:[((e,t)=>({...function(e){return void 0===e&&(e=0),{name:"offset",options:e,async fn(t){var n,r;let{x:o,y:i,placement:l,middlewareData:a}=t,u=await D(t,e);return l===(null==(n=a.offset)?void 0:n.placement)&&null!=(r=a.arrow)&&r.alignmentOffset?{}:{x:o+u.x,y:i+u.y,data:{...u,placement:l}}}}}(e),options:[e,t]}))({mainAxis:M+et,alignmentAxis:W}),B&&((e,t)=>({...function(e){return void 0===e&&(e={}),{name:"shift",options:e,async fn(t){let{x:n,y:r,placement:o}=t,{mainAxis:a=!0,crossAxis:u=!1,limiter:s={fn:e=>{let{x:t,y:n}=e;return{x:t,y:n}}},...c}=d(e,t),f={x:n,y:r},m=await P(t,c),g=y(p(o)),v=h(g),w=f[v],x=f[g];if(a){let e="y"===v?"top":"left",t="y"===v?"bottom":"right",n=w+m[e],r=w-m[t];w=l(n,i(w,r))}if(u){let e="y"===g?"top":"left",t="y"===g?"bottom":"right",n=x+m[e],r=x-m[t];x=l(n,i(x,r))}let b=s.fn({...t,[v]:w,[g]:x});return{...b,data:{x:b.x-n,y:b.y-r,enabled:{[v]:a,[g]:u}}}}}}(e),options:[e,t]}))({mainAxis:!0,crossAxis:!1,limiter:"partial"===z?((e,t)=>({...function(e){return void 0===e&&(e={}),{options:e,fn(t){let{x:n,y:r,placement:o,rects:i,middlewareData:l}=t,{offset:a=0,mainAxis:u=!0,crossAxis:s=!0}=d(e,t),c={x:n,y:r},f=y(o),m=h(f),g=c[m],v=c[f],w=d(a,t),x="number"==typeof w?{mainAxis:w,crossAxis:0}:{mainAxis:0,crossAxis:0,...w};if(u){let e="y"===m?"height":"width",t=i.reference[m]-i.floating[e]+x.mainAxis,n=i.reference[m]+i.reference[e]-x.mainAxis;g<t?g=t:g>n&&(g=n)}if(s){var b,E;let e="y"===m?"width":"height",t=k.has(p(o)),n=i.reference[f]-i.floating[e]+(t&&(null==(b=l.offset)?void 0:b[f])||0)+(t?0:x.crossAxis),r=i.reference[f]+i.reference[e]+(t?0:(null==(E=l.offset)?void 0:E[f])||0)-(t?x.crossAxis:0);v<n?v=n:v>r&&(v=r)}return{[m]:g,[f]:v}}}}(e),options:[e,t]}))():void 0,...ea}),B&&((e,t)=>({...function(e){return void 0===e&&(e={}),{name:"flip",options:e,async fn(t){var n,r,o,i,l;let{placement:a,middlewareData:u,rects:s,initialPlacement:c,platform:f,elements:v}=t,{mainAxis:T=!0,crossAxis:L=!0,fallbackPlacements:A,fallbackStrategy:O="bestFit",fallbackAxisSideDirection:S="none",flipAlignment:N=!0,...k}=d(e,t);if(null!=(n=u.arrow)&&n.alignmentOffset)return{};let D=p(a),M=y(c),j=p(c)===c,W=await (null==f.isRTL?void 0:f.isRTL(v.floating)),_=A||(j||!N?[R(c)]:function(e){let t=R(e);return[w(e),t,w(t)]}(c)),F="none"!==S;!A&&F&&_.push(...function(e,t,n,r){let o=m(e),i=function(e,t,n){switch(e){case"top":case"bottom":if(n)return t?b:x;return t?x:b;case"left":case"right":return t?E:C;default:return[]}}(p(e),"start"===n,r);return o&&(i=i.map(e=>e+"-"+o),t&&(i=i.concat(i.map(w)))),i}(c,N,S,W));let B=[c,..._],H=await P(t,k),I=[],z=(null==(r=u.flip)?void 0:r.overflows)||[];if(T&&I.push(H[D]),L){let e=function(e,t,n){void 0===n&&(n=!1);let r=m(e),o=h(y(e)),i=g(o),l="x"===o?r===(n?"end":"start")?"right":"left":"start"===r?"bottom":"top";return t.reference[i]>t.floating[i]&&(l=R(l)),[l,R(l)]}(a,s,W);I.push(H[e[0]],H[e[1]])}if(z=[...z,{placement:a,overflows:I}],!I.every(e=>e<=0)){let e=((null==(o=u.flip)?void 0:o.index)||0)+1,t=B[e];if(t&&("alignment"!==L||M===y(t)||z.every(e=>y(e.placement)!==M||e.overflows[0]>0)))return{data:{index:e,overflows:z},reset:{placement:t}};let n=null==(i=z.filter(e=>e.overflows[0]<=0).sort((e,t)=>e.overflows[1]-t.overflows[1])[0])?void 0:i.placement;if(!n)switch(O){case"bestFit":{let e=null==(l=z.filter(e=>{if(F){let t=y(e.placement);return t===M||"y"===t}return!0}).map(e=>[e.placement,e.overflows.filter(e=>e>0).reduce((e,t)=>e+t,0)]).sort((e,t)=>e[1]-t[1])[0])?void 0:l[0];e&&(n=e);break}case"initialPlacement":n=c}if(a!==n)return{reset:{placement:n}}}return{}}}}(e),options:[e,t]}))({...ea}),((e,t)=>({...function(e){return void 0===e&&(e={}),{name:"size",options:e,async fn(t){var n,r;let o,a,{placement:u,rects:s,platform:c,elements:f}=t,{apply:h=()=>{},...g}=d(e,t),v=await P(t,g),w=p(u),x=m(u),b="y"===y(u),{width:E,height:C}=s.floating;"top"===w||"bottom"===w?(o=w,a=x===(await (null==c.isRTL?void 0:c.isRTL(f.floating))?"start":"end")?"left":"right"):(a=w,o="end"===x?"top":"bottom");let R=C-v.top-v.bottom,T=E-v.left-v.right,L=i(C-v[o],R),A=i(E-v[a],T),O=!t.middlewareData.shift,S=L,N=A;if(null!=(n=t.middlewareData.shift)&&n.enabled.x&&(N=T),null!=(r=t.middlewareData.shift)&&r.enabled.y&&(S=R),O&&!x){let e=l(v.left,0),t=l(v.right,0),n=l(v.top,0),r=l(v.bottom,0);b?N=E-2*(0!==e||0!==t?e+t:l(v.left,v.right)):S=C-2*(0!==n||0!==r?n+r:l(v.top,v.bottom))}await h({...t,availableWidth:N,availableHeight:S});let k=await c.getDimensions(f.floating);return E!==k.width||C!==k.height?{reset:{rects:!0}}:{}}}}(e),options:[e,t]}))({...ea,apply:e=>{let{elements:t,rects:n,availableWidth:r,availableHeight:o}=e,{width:i,height:l}=n.reference,a=t.floating.style;a.setProperty("--radix-popper-available-width","".concat(r,"px")),a.setProperty("--radix-popper-available-height","".concat(o,"px")),a.setProperty("--radix-popper-anchor-width","".concat(i,"px")),a.setProperty("--radix-popper-anchor-height","".concat(l,"px"))}}),Q&&((e,t)=>({...(e=>({name:"arrow",options:e,fn(t){let{element:n,padding:r}="function"==typeof e?e(t):e;return n&&({}).hasOwnProperty.call(n,"current")?null!=n.current?eb({element:n.current,padding:r}).fn(t):{}:n?eb({element:n,padding:r}).fn(t):{}}}))(e),options:[e,t]}))({element:Q,padding:F}),eQ({arrowWidth:ee,arrowHeight:et}),U&&((e,t)=>({...function(e){return void 0===e&&(e={}),{name:"hide",options:e,async fn(t){let{rects:n}=t,{strategy:r="referenceHidden",...o}=d(e,t);switch(r){case"referenceHidden":{let e=S(await P(t,{...o,elementContext:"reference"}),n.reference);return{data:{referenceHiddenOffsets:e,referenceHidden:N(e)}}}case"escaped":{let e=S(await P(t,{...o,altBoundary:!0}),n.floating);return{data:{escapedOffsets:e,escaped:N(e)}}}default:return{}}}}}(e),options:[e,t]}))({strategy:"referenceHidden",...ea})]}),[em,eh]=eZ(ef),eg=(0,eD.c)(V);(0,eM.N)(()=>{ed&&(null==eg||eg())},[ed,eg]);let ev=null==(n=ep.arrow)?void 0:n.x,ey=null==(o=ep.arrow)?void 0:o.y,eS=(null==(a=ep.arrow)?void 0:a.centerOffset)!==0,[ek,ej]=r.useState();return(0,eM.N)(()=>{Y&&ej(window.getComputedStyle(Y).zIndex)},[Y]),(0,eP.jsx)("div",{ref:eu.setFloating,"data-radix-popper-content-wrapper":"",style:{...es,transform:ed?es.transform:"translate(0, -200%)",minWidth:"max-content",zIndex:ek,"--radix-popper-transform-origin":[null==(s=ep.transformOrigin)?void 0:s.x,null==(c=ep.transformOrigin)?void 0:c.y].join(" "),...(null==(f=ep.hide)?void 0:f.referenceHidden)&&{visibility:"hidden",pointerEvents:"none"}},dir:e.dir,children:(0,eP.jsx)(e$,{scope:L,placedSide:em,onArrowChange:Z,arrowX:ev,arrowY:ey,shouldHideArrow:eS,children:(0,eP.jsx)(eO.sG.div,{"data-side":em,"data-align":eh,...K,ref:q,style:{...K.style,animation:ed?void 0:"none"}})})})});eK.displayName=eU;var eG="PopperArrow",eY={top:"bottom",right:"left",bottom:"top",left:"right"},eX=r.forwardRef(function(e,t){let{__scopePopper:n,...r}=e,o=eV(eG,n),i=eY[o.placedSide];return(0,eP.jsx)("span",{ref:o.onArrowChange,style:{position:"absolute",left:o.arrowX,top:o.arrowY,[i]: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},children:(0,eP.jsx)(eS,{...r,ref:t,style:{...r.style,display:"block"}})})});function eq(e){return null!==e}eX.displayName=eG;var eQ=e=>({name:"transformOrigin",options:e,fn(t){var n,r,o,i,l;let{placement:a,rects:u,middlewareData:s}=t,c=(null==(n=s.arrow)?void 0:n.centerOffset)!==0,f=c?0:e.arrowWidth,d=c?0:e.arrowHeight,[p,m]=eZ(a),h={start:"0%",center:"50%",end:"100%"}[m],g=(null!=(i=null==(r=s.arrow)?void 0:r.x)?i:0)+f/2,v=(null!=(l=null==(o=s.arrow)?void 0:o.y)?l:0)+d/2,y="",w="";return"bottom"===p?(y=c?h:"".concat(g,"px"),w="".concat(-d,"px")):"top"===p?(y=c?h:"".concat(g,"px"),w="".concat(u.floating.height+d,"px")):"right"===p?(y="".concat(-d,"px"),w=c?h:"".concat(v,"px")):"left"===p&&(y="".concat(u.floating.width+d,"px"),w=c?h:"".concat(v,"px")),{data:{x:y,y:w}}}});function eZ(e){let[t,n="center"]=e.split("-");return[t,n]}var eJ=eH,e0=ez,e1=eK,e3=eX},9559:(e,t,n)=>{n.d(t,{i:()=>a});var r,o=n(4773),i=n(3049),l=(r||(r=n.t(o,2)))[" useInsertionEffect ".trim().toString()]||i.N;function a({prop:e,defaultProp:t,onChange:n=()=>{},caller:r}){let[i,a,u]=function({defaultProp:e,onChange:t}){let[n,r]=o.useState(e),i=o.useRef(n),a=o.useRef(t);return l(()=>{a.current=t},[t]),o.useEffect(()=>{i.current!==n&&(a.current?.(n),i.current=n)},[n,i]),[n,r,a]}({defaultProp:t,onChange:n}),s=void 0!==e,c=s?e:i;{let t=o.useRef(void 0!==e);o.useEffect(()=>{let e=t.current;if(e!==s){let t=s?"controlled":"uncontrolled";console.warn(`${r} is changing from ${e?"controlled":"uncontrolled"} to ${t}. Components should not switch from controlled to uncontrolled (or vice versa). Decide between using a controlled or uncontrolled value for the lifetime of the component.`)}t.current=s},[s,r])}return[c,o.useCallback(t=>{if(s){let n="function"==typeof t?t(e):t;n!==e&&u.current?.(n)}else a(t)},[s,e,a,u])]}Symbol("RADIX:SYNC_STATE")}}]);