1"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[6260],{89367:function(e,t,r){r.d(t,{T:function(){return C}});var a=r(83890),l=r(58496),i=r(50672),n=r(53446),o=r(97472),s=r(90459),d=r(34864),c=r(72914),u=r(41595),x=r(96381),m=r(85415),p=r(90133),y=r(58785),g=r(61095),h=r(95515),f=r(86802),v=r(75774);let k=e=>{let{name:t,color:r,onClick:l,activeLegend:i}=e,n=!!l;return(0,a.jsxs)("li",{className:(0,v.cx)("group inline-flex flex-nowrap items-center gap-1.5 rounded-sm px-2 py-1 whitespace-nowrap transition",n?"cursor-pointer hover:bg-gray-100 dark:hover:bg-gray-800":"cursor-default"),onClick:e=>{e.stopPropagation(),null==l||l(t,r)},children:[(0,a.jsx)("span",{className:(0,v.cx)("h-[3px] w-3.5 shrink-0 rounded-full",(0,h.Gd)(r,"bg"),i&&i!==t?"opacity-40":"opacity-100"),"aria-hidden":!0}),(0,a.jsx)("p",{className:(0,v.cx)("truncate text-xs whitespace-nowrap","text-gray-700 dark:text-gray-300",n&&"group-hover:text-gray-900 dark:group-hover:text-gray-50",i&&i!==t?"opacity-40":"opacity-100"),children:t})]})},j=e=>{let{icon:t,onClick:r,disabled:i}=e,[n,o]=l.useState(!1),s=l.useRef(null);return l.useEffect(()=>(n?s.current=setInterval(()=>{null==r||r()},300):clearInterval(s.current),()=>clearInterval(s.current)),[n,r]),l.useEffect(()=>{i&&(clearInterval(s.current),o(!1))},[i]),(0,a.jsx)("button",{type:"button",className:(0,v.cx)("group inline-flex size-5 items-center truncate rounded-sm transition",i?"cursor-not-allowed text-gray-400 dark:text-gray-600":"cursor-pointer text-gray-700 hover:bg-gray-100 hover:text-gray-900 dark:text-gray-300 dark:hover:bg-gray-800 dark:hover:text-gray-50"),disabled:i,onClick:e=>{e.stopPropagation(),null==r||r()},onMouseDown:e=>{e.stopPropagation(),o(!0)},onMouseUp:e=>{e.stopPropagation(),o(!1)},children:(0,a.jsx)(t,{className:"size-full","aria-hidden":"true"})})},b=l.forwardRef((e,t)=>{let{categories:r,colors:n=h.iC,className:o,onClickLegendItem:s,activeLegend:d,enableLegendSlider:c=!1,...u}=e,x=l.useRef(null),m=l.useRef(null),[p,y]=l.useState(null),[g,f]=l.useState(null),b=l.useRef(null),w=l.useCallback(()=>{let e=null==x?void 0:x.current;e&&y({left:e.scrollLeft>0,right:e.scrollWidth-e.clientWidth>e.scrollLeft})},[y]),N=l.useCallback(e=>{var t,r;let a=null==x?void 0:x.current,l=null==m?void 0:m.current,i=null!==(t=null==l?void 0:l.clientWidth)&&void 0!==t?t:0,n=null!==(r=null==a?void 0:a.clientWidth)&&void 0!==r?r:0;a&&c&&(a.scrollTo({left:"left"===e?a.scrollLeft-n+i:a.scrollLeft+n-i,behavior:"smooth"}),setTimeout(()=>{w()},400))},[c,w]);l.useEffect(()=>{let e=e=>{"ArrowLeft"===e?N("left"):"ArrowRight"===e&&N("right")};return g?(e(g),b.current=setInterval(()=>{e(g)},300)):clearInterval(b.current),()=>clearInterval(b.current)},[g,N]);let C=e=>{e.stopPropagation(),("ArrowLeft"===e.key||"ArrowRight"===e.key)&&(e.preventDefault(),f(e.key))},L=e=>{e.stopPropagation(),f(null)};return l.useEffect(()=>{let e=null==x?void 0:x.current;return c&&(w(),null==e||e.addEventListener("keydown",C),null==e||e.addEventListener("keyup",L)),()=>{null==e||e.removeEventListener("keydown",C),null==e||e.removeEventListener("keyup",L)}},[w,c]),(0,a.jsxs)("ol",{ref:t,className:(0,v.cx)("relative overflow-hidden",o),...u,children:[(0,a.jsx)("div",{ref:x,tabIndex:0,className:(0,v.cx)("flex h-full",c?(null==p?void 0:p.right)||(null==p?void 0:p.left)?"snap-mandatory items-center overflow-auto pr-12 pl-4 [scrollbar-width:none] [&::-webkit-scrollbar]:hidden":"":"flex-wrap"),children:r.map((e,t)=>(0,a.jsx)(k,{name:e,color:n[t],onClick:s,activeLegend:d},"item-".concat(t)))}),c&&((null==p?void 0:p.right)||(null==p?void 0:p.left))?(0,a.jsx)(a.Fragment,{children:(0,a.jsxs)("div",{className:(0,v.cx)("absolute top-0 right-0 bottom-0 flex h-full items-center justify-center pr-1","bg-white dark:bg-gray-950"),children:[(0,a.jsx)(j,{icon:i.jW7,onClick:()=>{f(null),N("left")},disabled:!(null==p?void 0:p.left)}),(0,a.jsx)(j,{icon:i.jfD,onClick:()=>{f(null),N("right")},disabled:!(null==p?void 0:p.right)})]})}):null]})});b.displayName="Legend";let w=(e,t,r,i,n,o,s,d)=>{let{payload:c}=e,u=l.useRef(null);(0,f.V)(()=>{var e;let t;r((t=null===(e=u.current)||void 0===e?void 0:e.clientHeight)?Number(t)+15:60)});let x=c.filter(e=>"none"!==e.type);return(0,a.jsx)("div",{ref:u,style:{paddingLeft:"left"===s&&d?d-8:0},className:(0,v.cx)("flex items-center",{"justify-center":"center"===s},{"justify-start":"left"===s},{"justify-end":"right"===s}),children:(0,a.jsx)(b,{categories:x.map(e=>e.value),colors:x.map(e=>t.get(e.value)),onClickLegendItem:n,activeLegend:i,enableLegendSlider:o})})},N=e=>{let{active:t,payload:r,label:l,valueFormatter:i}=e;return t&&r&&r.length?(0,a.jsxs)("div",{className:(0,v.cx)("rounded-md border text-sm shadow-md","border-gray-200 dark:border-gray-800","bg-white dark:bg-gray-950"),children:[(0,a.jsx)("div",{className:(0,v.cx)("border-b border-inherit px-4 py-2"),children:(0,a.jsx)("p",{className:(0,v.cx)("font-medium","text-gray-900 dark:text-gray-50"),children:l})}),(0,a.jsx)("div",{className:(0,v.cx)("space-y-1 px-4 py-2"),children:r.map((e,t)=>{let{value:r,category:l,color:n}=e;return(0,a.jsxs)("div",{className:"flex items-center justify-between space-x-8",children:[(0,a.jsxs)("div",{className:"flex items-center space-x-2",children:[(0,a.jsx)("span",{"aria-hidden":"true",className:(0,v.cx)("h-[3px] w-3.5 shrink-0 rounded-full",(0,h.Gd)(n,"bg"))}),(0,a.jsx)("p",{className:(0,v.cx)("text-right whitespace-nowrap","text-gray-700 dark:text-gray-300"),children:l})]}),(0,a.jsx)("p",{className:(0,v.cx)("text-right font-medium whitespace-nowrap tabular-nums","text-gray-900 dark:text-gray-50"),children:i(r)})]},"id-".concat(t))})})]}):null},C=l.forwardRef((e,t)=>
1{let{data:r=[],categories:i=[],index:f,colors:k=h.iC,valueFormatter:j=e=>e.toString(),startEndOnly:b=!1,showXAxis:C=!0,showYAxis:L=!0,showGridLines:A=!0,yAxisWidth:K=56,intervalType:R="equidistantPreserveStart",showTooltip:S=!0,showLegend:I=!0,autoMinValue:P=!1,minValue:T,maxValue:W,allowDecimals:G=!0,connectNulls:D=!1,className:E,onValueChange:F,enableLegendSlider:M=!1,tickGap:V=5,xAxisLabel:z,yAxisLabel:O,type:_="default",legendPosition:B="right",fill:Y="gradient",tooltipCallback:q,customTooltip:U,...H}=e,$=(C||L)&&(!b||L)?20:0,[Z,J]=l.useState(60),[Q,X]=l.useState(void 0),[ee,et]=l.useState(void 0),er=(0,h.me)(i,k),ea=(0,h.i4)(P,T,W),el=!!F,ei="stacked"===_||"percent"===_,en=l.useId(),eo=l.useRef(void 0),es=l.useRef(void 0),ed=e=>{let{fillType:t,activeDot:r,activeLegend:l,category:i}=e,n=r||l&&l!==i?.1:.3;switch(t){case"none":return(0,a.jsx)("stop",{stopColor:"currentColor",stopOpacity:0});case"gradient":return(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("stop",{offset:"5%",stopColor:"currentColor",stopOpacity:n}),(0,a.jsx)("stop",{offset:"95%",stopColor:"currentColor",stopOpacity:0})]});default:return(0,a.jsx)("stop",{stopColor:"currentColor",stopOpacity:n})}};function ec(e){el&&(e===ee&&!Q||(0,h.Cm)(r,e)&&Q&&Q.dataKey===e?(et(void 0),null==F||F(null)):(et(e),null==F||F({eventType:"category",categoryClicked:e})),X(void 0))}return(0,a.jsx)("div",{ref:t,className:(0,v.cx)("h-80 w-full",E),"tremor-id":"tremor-raw",...H,children:(0,a.jsx)(n.h,{children:(0,a.jsxs)(o.T,{data:r,onClick:el&&(ee||Q)?()=>{X(void 0),et(void 0),null==F||F(null)}:void 0,margin:{bottom:z?30:void 0,left:O?20:void 0,right:O?5:void 0,top:5},stackOffset:"percent"===_?"expand":void 0,children:[A?(0,a.jsx)(s.q,{className:(0,v.cx)("stroke-gray-200 stroke-1 dark:stroke-gray-800"),horizontal:!0,vertical:!1}):null,(0,a.jsx)(d.K,{padding:{left:$,right:$},hide:!C,dataKey:f,interval:b?"preserveStartEnd":R,tick:{transform:"translate(0, 6)"},ticks:b?[r[0][f],r[r.length-1][f]]:void 0,fill:"",stroke:"",className:(0,v.cx)("text-xs","fill-gray-500 dark:fill-gray-500"),tickLine:!1,axisLine:!1,minTickGap:V,children:z&&(0,a.jsx)(c._,{position:"insideBottom",offset:-20,className:"fill-gray-800 text-sm font-medium dark:fill-gray-200",children:z})}),(0,a.jsx)(u.B,{width:K,hide:!L,axisLine:!1,tickLine:!1,type:"number",domain:ea,tick:{transform:"translate(-3, 0)"},fill:"",stroke:"",className:(0,v.cx)("text-xs","fill-gray-500 dark:fill-gray-500"),tickFormatter:"percent"===_?function(e){return"".concat((100*e).toFixed(0),"%")}:j,allowDecimals:G,children:O&&(0,a.jsx)(c._,{position:"insideLeft",style:{textAnchor:"middle"},angle:-90,offset:-15,className:"fill-gray-800 text-sm font-medium dark:fill-gray-200",children:O})}),(0,a.jsx)(x.u,{wrapperStyle:{outline:"none"},isAnimationActive:!0,animationDuration:100,cursor:{stroke:"#d1d5db",strokeWidth:1},offset:20,position:{y:0},content:e=>{let{active:t,payload:r,label:l}=e,i=r?r.map(e=>({category:e.dataKey,value:e.value,index:e.payload[f],color:er.get(e.dataKey),type:e.type,payload:e.payload})):[];return q&&(t!==eo.current||l!==es.current)&&(q({active:t,payload:i,label:l}),eo.current=t,es.current=l),S&&t?U?(0,a.jsx)(U,{active:t,payload:i,label:l}):(0,a.jsx)(N,{active:t,payload:i,label:l,valueFormatter:j}):null}}),I?(0,a.jsx)(m.D,{verticalAlign:"top",height:Z,content:e=>{let{payload:t}=e;return w({payload:t},er,J,ee,el?e=>ec(e):void 0,M,B,K)}}):null,i.map(e=>{let t="".concat(en,"-").concat(e.replace(/[^a-zA-Z0-9]/g,""));return(0,a.jsxs)(l.Fragment,{children:[(0,a.jsx)("defs",{children:(0,a.jsx)("linearGradient",{className:(0,v.cx)((0,h.Gd)(er.get(e),"text")),id:t,x1:"0",y1:"0",x2:"0",y2:"1",children:ed({fillType:Y,activeDot:Q,activeLegend:ee,category:e})},e)},e),(0,a.jsx)(p.u,{className:(0,v.cx)((0,h.Gd)(er.get(e),"stroke")),strokeOpacity:Q||ee&&ee!==e?.3:1,activeDot:e=>{let{cx:t,cy:l,stroke:i,strokeLinecap:n,strokeLinejoin:o,strokeWidth:s,dataKey:d}=e;return(0,a.jsx)(y.o,{className:(0,v.cx)("stroke-white dark:stroke-gray-950",F?"cursor-pointer":"",(0,h.Gd)(er.get(d),"fill")),cx:t,cy:l,r:5,fill:"",stroke:i,strokeLinecap:n,strokeLinejoin:o,strokeWidth:s,onClick:(t,a)=>{a.stopPropagation(),el&&(e.index===(null==Q?void 0:Q.index)&&e.dataKey===(null==Q?void 0:Q.dataKey)||(0,h.Cm)(r,e.dataKey)&&ee&&ee===e.dataKey?(et(void 0),X(void 0),null==F||F(null)):(et(e.dataKey),X({index:e.index,dataKey:e.dataKey}),null==F||F({eventType:"dot",categoryClicked:e.dataKey,...e.payload})))}})},dot:t=>{let{stroke:i,strokeLinecap:n,strokeLinejoin:o,strokeWidth:s,cx:d,cy:c,dataKey:u,index:x}=t;return(0,h.Cm)(r,e)&&!(Q||ee&&ee!==e)||(null==Q?void 0:Q.index)===x&&(null==Q?void 0:Q.dataKey)===e?(0,a.jsx)(y.o,{cx:d,cy:c,r:5,stroke:i,fill:"",strokeLinecap:n,strokeLinejoin:o,strokeWidth:s,className:(0,v.cx)("stroke-white dark:stroke-gray-950",F?"cursor-pointer":"",(0,h.Gd)(er.get(u),"fill"))},x):(0,a.jsx)(l.Fragment,{},x)},name:e,type:"linear",dataKey:e,stroke:"",strokeWidth:2,strokeLinejoin:"round",strokeLinecap:"round",isAnimationActive:!1,connectNulls:D,stackId:ei?"stack":void 0,fill:"url(#".concat(t,")")},e)]},e)}),F?i.map(e=>(0,a.jsx)(g.x,{className:(0,v.cx)("cursor-pointer"),strokeOpacity:0,name:e,type:"linear",dataKey:e,stroke:"transparent",fill:"transparent",legendType:"none",tooltipType:"none",strokeWidth:12,connectNulls:D,onClick:(e,t)=>{t.stopPropagation();let{name:r}=e;ec(r)}},e)):null]})})})});C.displayName="AreaChart"},26805:function(e,t,r){r.d(t,{$:function(){return o}});var a=r(83890),l=r(58496),i=r(75774);function n(e,t){let{data:r=[],valueFormatter:n=e=>e.toString(),showAnimation:o=!1,onValueChange:s,sortOrder:d="descending",className:c,...u}=e,x=s?"button":"div",m=l.useMemo(()=>"none"===d?r:[...r].sort((e,t)=>
1"ascending"===d?e.value-t.value:t.value-e.value),[r,d]),p=l.useMemo(()=>{let e=Math.max(...m.map(e=>e.value),0);return m.map(t=>0===t.value?0:Math.max(t.value/e*100,2))},[m]);return(0,a.jsxs)("div",{ref:t,className:(0,i.cx)("flex justify-between space-x-6",c),"aria-sort":d,"tremor-id":"tremor-raw",...u,children:[(0,a.jsx)("div",{className:"relative w-full space-y-1.5",children:m.map((e,t)=>{var r;return(0,a.jsx)(x,{onClick:()=>{null==s||s(e)},className:(0,i.cx)("group w-full rounded-sm",i.kN,s?["-m-0! cursor-pointer","hover:bg-gray-50 dark:hover:bg-gray-900"]:""),children:(0,a.jsx)("div",{className:(0,i.cx)("flex items-center rounded-sm transition-all","h-8","bg-blue-200 dark:bg-blue-900",s?"group-hover:bg-blue-300 dark:group-hover:bg-blue-800":"",{"mb-0":t===m.length-1,"duration-800":o}),style:{width:"".concat(p[t],"%")},children:(0,a.jsx)("div",{className:(0,i.cx)("absolute left-2 flex max-w-full pr-2"),children:e.href?(0,a.jsx)("a",{href:e.href,className:(0,i.cx)("truncate whitespace-nowrap rounded-sm text-sm","text-gray-900 dark:text-gray-50","hover:underline hover:underline-offset-2",i.kN),target:"_blank",rel:"noreferrer",onClick:e=>e.stopPropagation(),children:e.name}):(0,a.jsx)("p",{className:(0,i.cx)("truncate whitespace-nowrap text-sm","text-gray-900 dark:text-gray-50"),children:e.name})})})},null!==(r=e.key)&&void 0!==r?r:e.name)})}),(0,a.jsx)("div",{children:m.map((e,t)=>{var r;return(0,a.jsx)("div",{className:(0,i.cx)("flex items-center justify-end","h-8",t===m.length-1?"mb-0":"mb-1.5"),children:(0,a.jsx)("p",{className:(0,i.cx)("truncate whitespace-nowrap text-sm leading-none","text-gray-900 dark:text-gray-50"),children:n(e.value)})},null!==(r=e.key)&&void 0!==r?r:e.name)})})]})}n.displayName="BarList";let o=l.forwardRef(n)},15693:function(e,t,r){r.d(t,{q:function(){return m}});var a=r(83890),l=r(58496),i=r(95515),n=r(75774),o=r(56576);let s=(e,t,r)=>{if(void 0===e)return"";if(0===e){for(let e=0;e<t.length;e++)if(t[e]>0)return(0,i.Gd)(r[e],"bg")}let a=0;for(let l=0;l<t.length;l++)if((a+=t[l])>=e)return(0,i.Gd)(r[l],"bg");return(0,i.Gd)(r[t.length-1],"bg")},d=(e,t)=>e?e/t*100:0,c=e=>e.reduce((e,t)=>e+t,0),u=e=>Number.isInteger(e)?e.toString():e.toFixed(1),x=e=>{let{values:t}=e,r=l.useMemo(()=>c(t),[t]),i=0,o=0;return(0,a.jsxs)("div",{className:(0,n.cx)("relative mb-2 flex h-5 w-full text-sm font-medium","text-gray-700 dark:text-gray-300"),children:[(0,a.jsx)("div",{className:"absolute bottom-0 left-0 flex items-center",children:"0"}),t.map((e,t)=>{i+=e;let l=(e>=.1*r||o>=.09*r)&&r-i>=.1*r&&i>=.1*r&&i<.9*r;o=l?0:o+=e;let s=d(e,r);return(0,a.jsx)("div",{className:"flex items-center justify-end pr-0.5",style:{width:"".concat(s,"%")},children:l?(0,a.jsx)("span",{className:(0,n.cx)("block translate-x-1/2 text-sm tabular-nums"),children:u(i)}):null},"item-".concat(t))}),(0,a.jsx)("div",{className:"absolute right-0 bottom-0 flex items-center",children:u(r)})]})},m=l.forwardRef((e,t)=>{let{values:r=[],colors:u=i.iC,marker:m,showLabels:p=!0,className:y,...g}=e,h=l.useMemo(()=>s(null==m?void 0:m.value,r,u),[m,r,u]),f=l.useMemo(()=>c(r),[r]),v=l.useMemo(()=>{if(void 0!==m)return m.value<0?0:m.value>f?f:m.value},[m,f]),k=l.useMemo(()=>d(v,f),[v,f]);return(0,a.jsxs)("div",{ref:t,className:(0,n.cx)(y),"aria-label":"Category bar","aria-valuenow":null==m?void 0:m.value,"tremor-id":"tremor-raw",...g,children:[p?(0,a.jsx)(x,{values:r}):null,(0,a.jsxs)("div",{className:"relative flex h-2 w-full items-center",children:[(0,a.jsx)("div",{className:"flex h-full flex-1 items-center gap-0.5 overflow-hidden rounded-full",children:r.map((e,t)=>{var r;let l=null!==(r=u[t])&&void 0!==r?r:"gray",o=e/f*100;return(0,a.jsx)("div",{className:(0,n.cx)("h-full",(0,i.Gd)(l,"bg"),0===o&&"hidden"),style:{width:"".concat(o,"%")}},"item-".concat(t))})}),void 0!==m?(0,a.jsx)("div",{className:(0,n.cx)("absolute w-2 -translate-x-1/2",m.showAnimation&&"transform-gpu transition-all duration-300 ease-in-out"),style:{left:"".concat(k,"%")},children:m.tooltip?(0,a.jsx)(o.u,{asChild:!0,content:m.tooltip,children:(0,a.jsx)("div",{"aria-hidden":"true",className:(0,n.cx)("relative mx-auto h-4 w-1 rounded-full ring-2","ring-white dark:ring-gray-950",h),children:(0,a.jsx)("div",{"aria-hidden":!0,
1className:"absolute size-7 -translate-x-[45%] -translate-y-[15%]"})})}):(0,a.jsx)("div",{className:(0,n.cx)("mx-auto h-4 w-1 rounded-full ring-2","ring-white dark:ring-gray-950",h)})}):null]})]})});m.displayName="CategoryBar"},21922:function(e,t,r){r.d(t,{U:function(){return A}});var a=r(83890),l=r(58496),i=r(50672),n=r(53446),o=r(98232),s=r(90459),d=r(34864),c=r(72914),u=r(41595),x=r(96381),m=r(85415),p=r(68798),y=r(61095),g=r(58785),h=r(95515),f=r(86802),v=r(75774);function k(e,t){if(e===t)return!0;if("object"!=typeof e||"object"!=typeof t||null===e||null===t)return!1;let r=Object.keys(e),a=Object.keys(t);if(r.length!==a.length)return!1;for(let l of r)if(!a.includes(l)||!k(e[l],t[l]))return!1;return!0}let j=(e,t,r)=>{let{fillOpacity:l,name:i,payload:n,value:o,width:s,x:d}=e,{y:c,height:u}=e;return u<0&&(c+=u,u=Math.abs(u)),(0,a.jsx)("rect",{x:d,y:c,width:s,height:u,opacity:t||r&&r!==i?k(t,{...n,value:o})?l:.3:l})},b=e=>{let{name:t,color:r,onClick:l,activeLegend:i,chartType:n}=e,o=!!l,s=(0,h.Gd)(r,"bg");return(0,a.jsxs)("li",{className:(0,v.cx)("group inline-flex flex-nowrap items-center gap-1.5 rounded-sm px-2 py-1 whitespace-nowrap transition",o?"cursor-pointer hover:bg-gray-100 dark:hover:bg-gray-800":"cursor-default"),onClick:e=>{e.stopPropagation(),null==l||l(t,r)},children:[(0,a.jsx)("span",{className:(0,v.cx)({"size-2 rounded-xs":"bar"===n},{"h-[3px] w-3.5 shrink-0 rounded-full":"line"===n},"shrink-0",s,i&&i!==t?"opacity-40":"opacity-100"),"aria-hidden":!0}),(0,a.jsx)("p",{className:(0,v.cx)("truncate text-xs whitespace-nowrap","text-gray-700 dark:text-gray-300",o&&"group-hover:text-gray-900 dark:group-hover:text-gray-50",i&&i!==t?"opacity-40":"opacity-100"),children:t})]})},w=e=>{let{icon:t,onClick:r,disabled:i}=e,[n,o]=l.useState(!1),s=l.useRef(null);return l.useEffect(()=>(n?s.current=setInterval(()=>{null==r||r()},300):clearInterval(s.current),()=>clearInterval(s.current)),[n,r]),l.useEffect(()=>{i&&(clearInterval(s.current),o(!1))},[i]),(0,a.jsx)("button",{type:"button",className:(0,v.cx)("group inline-flex size-5 items-center truncate rounded-sm transition",i?"cursor-not-allowed text-gray-400 dark:text-gray-600":"cursor-pointer text-gray-700 hover:bg-gray-100 hover:text-gray-900 dark:text-gray-300 dark:hover:bg-gray-800 dark:hover:text-gray-50"),disabled:i,onClick:e=>{e.stopPropagation(),null==r||r()},onMouseDown:e=>{e.stopPropagation(),o(!0)},onMouseUp:e=>{e.stopPropagation(),o(!1)},children:(0,a.jsx)(t,{className:"size-full","aria-hidden":"true"})})},N=l.forwardRef((e,t)=>{let{categories:r,barCategoryColors:n,lineCategoryColors:o,onClickLegendItem:s,activeLegend:d,enableLegendSlider:c=!1,className:u,...x}=e,m=l.useRef(null),[p,y]=l.useState(null),[g,h]=l.useState(null),f=l.useRef(null),k=l.useCallback(()=>{let e=null==m?void 0:m.current;e&&y({left:e.scrollLeft>0,right:e.scrollWidth-e.clientWidth>e.scrollLeft})},[y]),j=l.useCallback(e=>{var t;let r=null==m?void 0:m.current,a=null!==(t=null==r?void 0:r.clientWidth)&&void 0!==t?t:0;r&&c&&(r.scrollTo({left:"left"===e?r.scrollLeft-a:r.scrollLeft+a,behavior:"smooth"}),setTimeout(()=>{k()},400))},[c,k]);l.useEffect(()=>{let e=e=>{"ArrowLeft"===e?j("left"):"ArrowRight"===e&&j("right")};return g?(e(g),f.current=setInterval(()=>{e(g)},300)):clearInterval(f.current),()=>clearInterval(f.current)},[g,j]);let N=e=>{e.stopPropagation(),("ArrowLeft"===e.key||"ArrowRight"===e.key)&&(e.preventDefault(),h(e.key))},C=e=>{e.stopPropagation(),h(null)};return l.useEffect(()=>{let e=null==m?void 0:m.current;return c&&(k(),null==e||e.addEventListener("keydown",N),null==e||e.addEventListener("keyup",C)),()=>{null==e||e.removeEventListener("keydown",N),null==e||e.removeEventListener("keyup",C)}},[k,c]),(0,a.jsxs)("ol",{ref:t,className:(0,v.cx)("relative overflow-hidden",u),...x,children:[(0,a.jsx)("div",{ref:m,className:(0,v.cx)("flex h-full",c?(null==p?void 0:p.right)||(null==p?void 0:p.left)?"snap-mandatory items-center overflow-auto pr-12 pl-4 [scrollbar-width:none] [&::-webkit-scrollbar]:hidden":"":"flex-wrap"),children:r.map((e,t)=>{let r=n.get(e.name),l=o.get(e.name);return(0,a.jsx)(b,{name:e.name,chartType:e.chartType,onClick:s,activeLegend:d,color:"bar"===e.chartType?r:l},"item-".concat(t))})}),c&&((null==p?void 0:p.right)||(null==p?void 0:p.left))?(0,a.jsx)(a.Fragment,{children:(0,a.jsxs)("div",{className:(0,v.cx)("absolute top-0 right-0 bottom-0 flex h-full items-center justify-center pr-1","bg-white dark:bg-gray-950"),children:[(0,a.jsx)(w,{icon:i.jW7,onClick:()=>{h(null),j("left")},disabled:!(null==p?void 0:p.left)}),(0,a.jsx)(w,{icon:i.jfD,onClick:()=>{h(null),j("right")},disabled:!(null==p?void 0:p.right)})]})}):null]})});N.displayName="Legend";
1let C=(e,t,r,i,n,o,s,d,c,u)=>{let{payload:x}=e,m=l.useRef(null);(0,f.V)(()=>{var e;let t;i((t=null===(e=m.current)||void 0===e?void 0:e.clientHeight)?Number(t)+15:60)});let p=x.filter(e=>"none"!==e.type);return(0,a.jsx)("div",{style:{paddingLeft:"left"===d&&c?c-8:0,paddingRight:("right"===d||void 0===d)&&u?u-8:52},ref:m,className:(0,v.cx)("flex items-center",{"justify-center":"center"===d},{"justify-start":"left"===d},{"justify-end":"right"===d}),children:(0,a.jsx)(N,{categories:p.map(e=>({name:e.value,chartType:"rect"===e.type?"bar":e.type})),barCategoryColors:t,lineCategoryColors:r,onClickLegendItem:o,activeLegend:n,enableLegendSlider:s})})},L=e=>{let{active:t,payload:r,label:l,barValueFormatter:i=e=>e.toString(),lineValueFormatter:n=e=>e.toString()}=e;if(t&&r&&r.length){let e=r.filter(e=>"none"!==e.type);return(0,a.jsxs)("div",{className:(0,v.cx)("rounded-md border text-sm shadow-md","border-gray-200 dark:border-gray-800","bg-white dark:bg-gray-950"),children:[(0,a.jsx)("div",{className:(0,v.cx)("border-b border-inherit px-4 py-2"),children:(0,a.jsx)("p",{className:(0,v.cx)("font-medium","text-gray-900 dark:text-gray-50"),children:l})}),(0,a.jsx)("div",{className:(0,v.cx)("space-y-1 px-4 py-2"),children:e.map((e,t)=>{let{value:r,category:l,barColor:o,lineColor:s,chartType:d}=e;return(0,a.jsxs)("div",{className:"flex items-center justify-between space-x-8",children:[(0,a.jsxs)("div",{className:"flex items-center space-x-2",children:[(0,a.jsx)("div",{className:"flex w-5 items-center justify-center",children:(0,a.jsx)("span",{"aria-hidden":"true",className:(0,v.cx)({"size-2 rounded-xs":"bar"===d},{"h-[3px] w-3.5 shrink-0 rounded-full":"line"===d},"shrink-0",(0,h.Gd)("bar"===d?o:s,"bg"))})}),(0,a.jsx)("p",{className:(0,v.cx)("text-right whitespace-nowrap","text-gray-700 dark:text-gray-300"),children:l})]}),(0,a.jsx)("p",{className:(0,v.cx)("text-right font-medium whitespace-nowrap tabular-nums","text-gray-900 dark:text-gray-50"),children:"bar"===d?i(r):n(r)})]},"id-".concat(t))})})]})}return null},A=l.forwardRef((e,t)=>{var r,i,f,b;let w={categories:[],colors:h.iC,valueFormatter:e=>e.toString(),showYAxis:!0,yAxisWidth:56,yAxisLabel:void 0,allowDecimals:!0,type:"default",autoMinValue:!1,minValue:void 0,maxValue:void 0},N={...w,connectNulls:!1},{data:A=[],index:K,startEndOnly:R=!1,showXAxis:S=!0,showGridLines:I=!0,intervalType:P="equidistantPreserveStart",showTooltip:T=!0,showLegend:W=!0,legendPosition:G="right",enableLegendSlider:D=!1,onValueChange:E,tickGap:F=5,xAxisLabel:M,enableBiaxial:V=!1,barSeries:z=w,lineSeries:O=N,tooltipCallback:_,customTooltip:B,className:Y,...q}=e,U={...w,...z},H={...N,...O},$=(S||U.showYAxis||!V||H.showYAxis)&&(!R||U.showYAxis||!V||H.showYAxis)?20:0,[Z,J]=l.useState(60),[Q,X]=l.useState(void 0),[ee,et]=l.useState(void 0),er=l.useRef(void 0),ea=l.useRef(void 0),el=(0,h.me)(U.categories,null!==(r=U.colors)&&void 0!==r?r:h.iC),ei=(0,h.me)(H.categories,null!==(i=H.colors)&&void 0!==i?i:h.iC),[en,eo]=l.useState(void 0),es=(0,h.i4)(null!==(f=U.autoMinValue)&&void 0!==f&&f,U.minValue,U.maxValue),ed=(0,h.i4)(null!==(b=H.autoMinValue)&&void 0!==b&&b,H.minValue,H.maxValue),ec=!!E,eu="stacked"===z.type;function ex(e,t,r){if(r.stopPropagation(),E){if(k(en,{...e.payload,value:e.value}))et(void 0),eo(void 0),null==E||E(null);else{var a,l,i,n;et(null===(l=e.tooltipPayload)||void 0===l?void 0:null===(a=l[0])||void 0===a?void 0:a.dataKey),eo({...e.payload,value:e.value}),null==E||E({eventType:"bar",categoryClicked:null===(n=e.tooltipPayload)||void 0===n?void 0:null===(i=n[0])||void 0===i?void 0:i.dataKey,...e.payload})}}}function em(e){var t,r;ec&&(e!==ee||en||Q?(en&&(null===(r=en.tooltipPayload)||void 0===r?void 0:null===(t=r[0])||void 0===t?void 0:t.dataKey)===e?et(e):(et(e),eo(void 0),X(void 0)),null==E||E({eventType:"category",categoryClicked:e})):(et(void 0),null==E||E(null)))}return(0,a.jsx)("div",{ref:t,className:(0,v.cx)("h-80 w-full",Y),"tremor-id":"tremor-raw",...q,children:(0,a.jsx)(n.h,{children:(0,a.jsxs)(o.c,{data:A,onClick:ec&&(ee||en||Q)?()=>{eo(void 0),X(void 0),et(void 0),null==E||E(null)}:void 0,margin:{bottom:M?30:void 0,left:U.yAxisLabel?20:void 0,right:H.yAxisLabel?20:void 0,top:5},children:[I?(0,a.jsx)(s.q,{className:(0,v.cx)("stroke-gray-200 stroke-1 dark:stroke-gray-800"),horizontal:!0,vertical:!1}):null,(0,a.jsx)(d.K,{hide:!S,tick:{transform:"translate(0, 6)"},fill:"",stroke:"",className:(0,v.cx)("mt-4 text-xs","fill-gray-500 dark:fill-gray-500"),tickLine:!1,axisLine
1:!1,minTickGap:F,padding:{left:$,right:$},dataKey:K,interval:R?"preserveStartEnd":P,ticks:R?[A[0][K],A[A.length-1][K]]:void 0,children:M&&(0,a.jsx)(c._,{position:"insideBottom",offset:-20,className:"fill-gray-800 text-sm font-medium dark:fill-gray-200",children:M})}),(0,a.jsx)(u.B,{yAxisId:V?"left":void 0,width:U.yAxisWidth,hide:!U.showYAxis,axisLine:!1,tickLine:!1,fill:"",stroke:"",className:(0,v.cx)("text-xs","fill-gray-500 dark:fill-gray-500"),tick:{transform:"translate(-3, 0)"},type:"number",domain:es,tickFormatter:U.valueFormatter,allowDecimals:U.allowDecimals,children:U.yAxisLabel&&(0,a.jsx)(c._,{position:"insideLeft",style:{textAnchor:"middle"},angle:-90,offset:-15,className:"fill-gray-800 text-sm font-medium dark:fill-gray-200",children:U.yAxisLabel})}),V?(0,a.jsx)(u.B,{yAxisId:"right",orientation:"right",width:H.yAxisWidth,hide:!H.showYAxis,axisLine:!1,tickLine:!1,fill:"",stroke:"",className:(0,v.cx)("text-xs","fill-gray-500 dark:fill-gray-500"),tick:{transform:"translate(3, 0)"},type:"number",domain:ed,tickFormatter:H.valueFormatter,allowDecimals:H.allowDecimals,children:H.yAxisLabel&&(0,a.jsx)(c._,{position:"insideRight",style:{textAnchor:"middle"},angle:-90,offset:-15,className:"fill-gray-800 text-sm font-medium dark:fill-gray-200",children:H.yAxisLabel})}):null,(0,a.jsx)(x.u,{wrapperStyle:{outline:"none"},isAnimationActive:!0,animationDuration:100,cursor:{stroke:"#d1d5db",strokeWidth:1},offset:20,position:{y:0},content:e=>{let{active:t,payload:r,label:l}=e,i=r?r.map(e=>({category:e.dataKey,value:e.value,index:e.payload[K],barColor:el.get(e.dataKey),lineColor:ei.get(e.dataKey),chartType:el.get(e.dataKey)?"bar":"line",type:e.type,payload:e.payload})):[];return _&&(t!==er.current||l!==ea.current)&&(_({active:t,payload:i,label:l}),er.current=t,ea.current=l),T&&t?B?(0,a.jsx)(B,{active:t,payload:i,label:l}):(0,a.jsx)(L,{active:t,payload:i,label:l,barValueFormatter:U.valueFormatter,lineValueFormatter:H.valueFormatter}):null}}),W?(0,a.jsx)(m.D,{verticalAlign:"top",height:Z,content:e=>{let{payload:t}=e;return C({payload:t},el,ei,J,ee,ec?e=>em(e):void 0,D,G,U.yAxisWidth,H.yAxisWidth)}}):null,U.categories.map(e=>(0,a.jsx)(p.$,{yAxisId:V?"left":void 0,className:(0,v.cx)((0,h.Gd)(el.get(e),"fill"),E?"cursor-pointer":""),name:e,type:"linear",dataKey:e,stackId:eu?"stack":void 0,isAnimationActive:!1,fill:"",shape:e=>j(e,en,ee),onClick:ex},e)),E?H.categories.map(e=>(0,a.jsx)(y.x,{yAxisId:V?"right":void 0,className:(0,v.cx)("cursor-pointer"),strokeOpacity:0,name:e,type:"linear",dataKey:e,stroke:"transparent",fill:"transparent",legendType:"none",tooltipType:"none",strokeWidth:12,connectNulls:H.connectNulls,onClick:(e,t)=>{t.stopPropagation();let{name:r}=e;em(r)}},e)):null,H.categories.map(e=>(0,a.jsx)(y.x,{yAxisId:V?"right":void 0,className:(0,v.cx)((0,h.Gd)(ei.get(e),"stroke"),ec&&"cursor-pointer"),strokeOpacity:Q||ee&&ee!==e?.3:1,activeDot:e=>{let{cx:t,cy:r,stroke:l,strokeLinecap:i,strokeLinejoin:n,strokeWidth:o,dataKey:s}=e;return(0,a.jsx)(g.o,{className:(0,v.cx)("stroke-white dark:stroke-gray-950",E?"cursor-pointer":"",(0,h.Gd)(ei.get(s),"fill")),cx:t,cy:r,r:5,fill:"",stroke:l,strokeLinecap:i,strokeLinejoin:n,strokeWidth:o,onClick:(t,r)=>{r.stopPropagation(),ec&&(e.index===(null==Q?void 0:Q.index)&&e.dataKey===(null==Q?void 0:Q.dataKey)||(0,h.Cm)(A,e.dataKey)&&ee&&ee===e.dataKey?(et(void 0),X(void 0),null==E||E(null)):(eo(void 0),et(e.dataKey),X({index:e.index,dataKey:e.dataKey}),null==E||E({eventType:"dot",categoryClicked:e.dataKey,...e.payload})))}})},dot:t=>{let{stroke:r,strokeLinecap:i,strokeLinejoin:n,strokeWidth:o,cx:s,cy:d,dataKey:c,index:u}=t;return(0,h.Cm)(A,e)&&!(Q||ee&&ee!==e)||(null==Q?void 0:Q.index)===u&&(null==Q?void 0:Q.dataKey)===e?(0,a.jsx)(g.o,{cx:s,cy:d,r:5,stroke:r,fill:"",strokeLinecap:i,strokeLinejoin:n,strokeWidth:o,className:(0,v.cx)("stroke-white dark:stroke-gray-950",E?"cursor-pointer":"",(0,h.Gd)(ei.get(c),"fill"))},u):(0,a.jsx)(l.Fragment,{},u)},name:e,type:"linear",dataKey:e,stroke:"",strokeWidth:2,strokeLinejoin:"round",strokeLinecap:"round",isAnimationActive:!1,connectNulls:H.connectNulls,onClick:(e,t)=>{t.stopPropagation();let{name:r}=e;em(r)}},"".concat(e,"-line-id")))]})})})});A.displayName="ComboChart"},30694:function(e,t,r){r.d(t,{Y:function(){return f}});var a=r(83890),l=r(58496),i=r(61718),n=r(53446),o=r(47251),s=r(70227),d=r(96381),c=r(95515),u=r(75774);let x=e=>e.reduce((e,t)=>
1e+t,0),m=(e,t,r)=>e.map(e=>({...e,color:t.get(e[r])||c.iC[0],className:(0,c.Gd)(t.get(e[r])||c.iC[0],"fill")})),p=(e,t)=>x(e.map(e=>e[t])),y=(e,t,r,a)=>e||t(p(r,a)),g=e=>{let{active:t,payload:r,valueFormatter:l}=e;return t&&r&&r.length?(0,a.jsx)("div",{className:(0,u.cx)("rounded-md border text-sm shadow-md","border-gray-200 dark:border-gray-800","bg-white dark:bg-gray-950"),children:(0,a.jsx)("div",{className:(0,u.cx)("space-y-1 px-4 py-2"),children:r.map((e,t)=>{let{value:r,category:i,color:n}=e;return(0,a.jsxs)("div",{className:"flex items-center justify-between space-x-8",children:[(0,a.jsxs)("div",{className:"flex items-center space-x-2",children:[(0,a.jsx)("span",{"aria-hidden":"true",className:(0,u.cx)("size-2 shrink-0 rounded-full",(0,c.Gd)(n,"bg"))}),(0,a.jsx)("p",{className:(0,u.cx)("text-right whitespace-nowrap","text-gray-700 dark:text-gray-300"),children:i})]}),(0,a.jsx)("p",{className:(0,u.cx)("text-right font-medium whitespace-nowrap tabular-nums","text-gray-900 dark:text-gray-50"),children:l(r)})]},"id-".concat(t))})})}):null},h=e=>{let{cx:t,cy:r,innerRadius:l,outerRadius:n,startAngle:o,endAngle:s,className:d}=e;return(0,a.jsx)(i.L,{cx:t,cy:r,innerRadius:l,outerRadius:n,startAngle:o,endAngle:s,className:d,fill:"",opacity:.3,style:{outline:"none"}})},f=l.forwardRef((e,t)=>{let{data:r=[],value:i,category:x,colors:p=c.iC,variant:f="donut",valueFormatter:v=e=>e.toString(),label:k,showLabel:j=!1,showTooltip:b=!0,onValueChange:w,tooltipCallback:N,customTooltip:C,className:L,...A}=e,[K,R]=l.useState(void 0),S="donut"===f,I=y(k,v,r,i),P=Array.from(new Set(r.map(e=>e[x]))),T=(0,c.me)(P,p),W=l.useRef(void 0),G=l.useRef(void 0);return(0,a.jsx)("div",{ref:t,className:(0,u.cx)("h-40 w-40",L),"tremor-id":"tremor-raw",...A,children:(0,a.jsx)(n.h,{className:"size-full",children:(0,a.jsxs)(o.u,{onClick:w&&void 0!==K?()=>{R(void 0),w(null)}:void 0,margin:{top:0,left:0,right:0,bottom:0},children:[j&&S&&(0,a.jsx)("text",{className:"fill-gray-700 dark:fill-gray-300",x:"50%",y:"50%",textAnchor:"middle",dominantBaseline:"middle",children:I}),(0,a.jsx)(s.b,{className:(0,u.cx)("stroke-white dark:stroke-gray-950 [&_.recharts-pie-sector]:outline-hidden",w?"cursor-pointer":"cursor-default"),data:m(r,T,x),cx:"50%",cy:"50%",startAngle:90,endAngle:-270,innerRadius:S?"75%":"0%",outerRadius:"100%",stroke:"",strokeLinejoin:"round",dataKey:i,nameKey:x,isAnimationActive:!1,onClick:(e,t,r)=>{r.stopPropagation(),w&&(K===t?(R(void 0),w(null)):(R(t),w({eventType:"sector",categoryClicked:e.payload[x],...e.payload})))},activeIndex:K,inactiveShape:h,style:{outline:"none"}}),b&&(0,a.jsx)(d.u,{wrapperStyle:{outline:"none"},isAnimationActive:!1,content:e=>{var t;let{active:r,payload:l}=e,i=l?l.map(e=>({category:e.payload[x],value:e.value,color:T.get(e.payload[x])})):[],n=null===(t=i[0])||void 0===t?void 0:t.category;return N&&(r!==W.current||n!==G.current)&&(N({active:r,payload:i}),W.current=r,G.current=n),b&&r?C?(0,a.jsx)(C,{active:r,payload:i}):(0,a.jsx)(g,{active:r,payload:i,valueFormatter:v}):null}})]})})})});f.displayName="DonutChart"}}]);
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.