@dub/ui 0.2.14 → 0.2.16

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,2 +1,2 @@
1
1
  "use client"
2
- import{a as X}from"../chunk-NWME2ANF.mjs";import{c as z,o as T}from"../chunk-LPRQFZ6K.mjs";import{LinearGradient as dt}from"@visx/gradient";import{Group as ut}from"@visx/group";import{Area as ft,AreaClosed as ht,Circle as xt}from"@visx/shape";import{AnimatePresence as gt,motion as _}from"framer-motion";import{useMemo as Ct}from"react";import{createContext as Q,useContext as j}from"react";var V=Q(null);function M(){let t=j(V);if(!t)throw new Error("No chart context");return t}var I=Q(null);function E(){let t=j(I);if(!t)throw new Error("No chart tooltip context");return t}import{jsx as S,jsxs as yt}from"react/jsx-runtime";function Te({seriesStyles:t}){let{data:n,series:l,margin:g,xScale:s,yScale:m,startDate:u,endDate:f}=M();if(!("ticks"in s))throw new Error("Areas require a time scale (type=area)");let{tooltipData:i}=E(),h=Ct(()=>n.map(c=>({...c,values:Object.fromEntries(Object.keys(c.values).map(e=>[e,0]))})),[n]);return S(ut,{left:g.left,top:g.top,children:S(gt,{children:l.filter(({isActive:c})=>c).map(c=>{let e=t==null?void 0:t.find(({id:o})=>o===c.id);return yt(_.g,{initial:{opacity:1},exit:{opacity:0},transition:{duration:.1},children:[S(dt,{id:`${c.id}-mask-gradient`,from:"white",to:"white",fromOpacity:.2,toOpacity:0,x1:0,x2:0,y1:0,y2:1}),S("mask",{id:`${c.id}-mask`,maskContentUnits:"objectBoundingBox",children:S("rect",{width:"1",height:"1",fill:`url(#${c.id}-mask-gradient)`})}),S(ht,{data:n,x:o=>s(o.date),y:o=>m(c.valueAccessor(o)??0),yScale:m,children:({path:o})=>S(_.path,{initial:{d:o(h)||"",opacity:0},animate:{d:o(n)||"",opacity:1},className:T(c.colorClassName??"text-blue-500",e==null?void 0:e.gradientClassName),mask:`url(#${c.id}-mask)`,fill:(e==null?void 0:e.areaFill)??"currentColor"})}),S(ft,{data:n,x:o=>s(o.date),y:o=>m(c.valueAccessor(o)??0),children:({path:o})=>S(_.path,{initial:{d:o(h)||""},animate:{d:o(n)||""},className:T(c.colorClassName??"text-blue-700",e==null?void 0:e.lineClassName),stroke:(e==null?void 0:e.lineStroke)??"currentColor",strokeOpacity:.8,strokeWidth:2,fill:"transparent"})}),!i&&S(xt,{cx:s(n.at(-1).date),cy:m(c.valueAccessor(n.at(-1))),r:4,className:T(c.colorClassName??"text-blue-700",e==null?void 0:e.lineClassName),fill:"currentColor"})]},`${c.id}_${u.toString()}_${f.toString()}`)})})})}import{RectClipPath as bt}from"@visx/clip-path";import{LinearGradient as Tt}from"@visx/gradient";import{Group as vt}from"@visx/group";import{BarRounded as kt}from"@visx/shape";import{AnimatePresence as wt,motion as H}from"framer-motion";import{useId as Nt}from"react";import{jsx as G,jsxs as J}from"react/jsx-runtime";function Le({seriesStyles:t}){let n=Nt(),{data:l,series:g,margin:s,xScale:m,yScale:u,width:f,height:i,startDate:h,endDate:c}=M();if(!("bandwidth"in m))throw new Error("Bars require a band scale (type=bar)");return J(vt,{left:s.left,top:s.top,children:[G(bt,{id:n,x:0,y:0,width:f,height:i}),G(wt,{children:g.filter(({isActive:e})=>e).map(e=>{let o=t==null?void 0:t.find(({id:a})=>a===e.id);return J(H.g,{initial:{opacity:0},animate:{opacity:1},exit:{opacity:0},transition:{duration:.1},clipPath:`url(#${n})`,children:[G(Tt,{className:T(e.colorClassName??"text-blue-500",o==null?void 0:o.gradientClassName),id:`${e.id}-background`,fromOffset:"0%",from:"currentColor",fromOpacity:.01,toOffset:"40%",to:"currentColor",toOpacity:1,x1:0,x2:0,y1:1}),G(H.g,{initial:{y:100},animate:{y:0},transition:{duration:.15,ease:"easeOut"},children:l.map(a=>{let r=m.bandwidth(),p=m(a.date)??0,x=u(e.valueAccessor(a)??0),d=i-x,A=Math.min(r,d)/2;return d>0?G(kt,{x:p,y:x,width:r,height:d,radius:1e3,top:!0,className:T(e.colorClassName??"text-blue-700",o==null?void 0:o.barClassName),fill:(o==null?void 0:o.barFill)??`url(#${e.id}-background)`},a.date.toString()):null})})]},`${e.id}_${h.toString()}_${c.toString()}`)})})]})}import{curveBasis as Dt}from"@visx/curve";import{ParentSize as At}from"@visx/responsive";import{scaleLinear as K}from"@visx/scale";import{Area as St}from"@visx/shape";import{Text as Pt}from"@visx/text";import{motion as Mt}from"framer-motion";import{Fragment as Lt,useMemo as R,useState as Ot}from"react";import{jsx as v,jsxs as O}from"react/jsx-runtime";var Ft=[{opacity:1,padding:0},{opacity:.3,padding:8},{opacity:.15,padding:16}],Z=16,tt=40;function _e(t){return v("div",{className:"size-full",children:v(At,{className:"relative",children:({width:n,height:l})=>n&&l?v($t,{...t,width:n,height:l}):null})})}function $t({width:t,height:n,steps:l,persistentPercentages:g=!0,defaultTooltipStepId:s}){let{isMobile:m}=X(),[u,f]=Ot(s??null),i=l.find(({id:r})=>r===u),h=R(()=>Object.fromEntries(l.map(({id:r,value:p},x)=>{var d;return[r,ot(p,((d=l[x+1])==null?void 0:d.value)??l[l.length-1].value)]})),[l]),c=R(()=>ot(0,0),[l]),e=R(()=>Math.max(...l.map(r=>r.value)),[l]),o=K({domain:[0,l.length],range:[0,t]}),a=K({domain:[e,-e],range:[n-Z-tt,Z+tt]});return O("div",{className:"relative",children:[v("svg",{width:t,height:n,children:l.map(({id:r,value:p,colorClassName:x},d)=>O(Lt,{children:[v("rect",{x:o(d),y:0,width:t/l.length,height:n,className:"fill-transparent transition-colors hover:fill-blue-600/5",onPointerEnter:()=>f(r),onPointerDown:()=>f(r),onPointerLeave:()=>!m&&f(s??null)}),v("line",{x1:o(d),y1:0,x2:o(d),y2:n,className:"stroke-black/5 sm:stroke-black/10"}),Ft.map(({opacity:A,padding:k})=>v(St,{data:h[r],curve:Dt,x:C=>o(d+C.x),y0:C=>a(-C.y)-k,y1:C=>a(C.y)+k,children:({path:C})=>v(Mt.path,{initial:{d:C(c)||"",opacity:0},animate:{d:C(h[r])||"",opacity:A},className:T(x,"pointer-events-none"),fill:"currentColor"})},`${r}-${A}-${k}`)),g&&v(Pt,{x:(o(d)+o(d+1))/2,y:n/2,textAnchor:"middle",verticalAnchor:"middle",fill:"white",fontSize:16,className:"pointer-events-none select-none",children:et(p/e*100)+"%"})]},r))}),i&&v("div",{className:T("pointer-events-none absolute flex items-center justify-center px-1 pb-4",g?"animate-slide-up-fade top-16 sm:top-12":"animate-fade-in top-1/2 -translate-y-1/2"),style:{left:o(l.findIndex(({id:r})=>r===i.id)),width:t/l.length},children:O("div",{className:T("rounded-lg border border-gray-200 bg-white text-base shadow-sm"),children:[v("p",{className:"border-b border-gray-200 px-3 py-2 text-sm text-gray-900 sm:px-4 sm:py-3",children:i.label}),O("div",{className:"flex flex-wrap justify-between gap-x-4 gap-y-2 px-3 py-2 text-sm sm:px-4 sm:py-3",children:[O("div",{className:"flex items-center gap-2",children:[v("div",{className:T(i.colorClassName,"h-2 w-2 shrink-0 rounded-sm bg-current opacity-50 shadow-[inset_0_0_0_1px_#0003]")}),v("p",{className:"whitespace-nowrap capitalize text-gray-600",children:et(i.value/e*100)+"%"})]}),O("p",{className:"whitespace-nowrap font-medium text-gray-900",children:[z(i.value,{full:!0}),i.additionalValue!==void 0&&O("span",{className:"text-gray-500",children:[" ","($",z(i.additionalValue/100),")"]})]})]})]})},i.id)]})}var et=t=>t>0&&t<.01?"< 0.01":z(t,{digits:2}),ot=(t,n)=>[{x:0,y:t},{x:.3,y:t},{x:.5,y:(t+n)/2},{x:.7,y:n},{x:1,y:n}];import{Group as Rt}from"@visx/group";import{ParentSize as Yt}from"@visx/responsive";import{scaleBand as Ut,scaleLinear as qt,scaleUtc as Xt}from"@visx/scale";import{Bar as at,Circle as Qt,Line as jt}from"@visx/shape";import{useMemo as Y,useState as Ht}from"react";import{localPoint as Gt}from"@visx/event";import{TooltipWithBounds as zt,useTooltipInPortal as Et,useTooltip as Wt}from"@visx/tooltip";import{bisector as Bt}from"d3-array";import{useCallback as Vt,useMemo as It}from"react";var _t=Bt(t=>new Date(t.date)).left;function rt({seriesId:t,chartContext:n,renderInPortal:l=!1,snapToY:g=!1,snapToX:s=!0,defaultIndex:m}){let{series:u,data:f,xScale:i,yScale:h,margin:c}=n,e=Et({scroll:!0,detectBounds:!0,debounce:200}),o=m!==void 0?f[m]:void 0,a=It(()=>o!==void 0?{tooltipData:o,tooltipLeft:s?i(o.date):0,tooltipTop:g?h(u.find(d=>d.id===t).valueAccessor(o)):0}:void 0,[o,s,g,i,h,u,t]),r=Wt(a??void 0),p=Vt(d=>{let k=(Gt(d)||{x:0}).x-c.left,C="invert"in i?i.invert(k):i.domain()[Math.round((k-i.step()*.75)/i.step())];if(C===void 0){console.log("x0 is undefined",{defaultTooltipData:a}),a?r.showTooltip(a):r.hideTooltip();return}let F=_t(f,C,1),y=f[F-1],P=f[F],L=y;P!=null&&P.date&&(L=C.valueOf()-y.date.valueOf()>P.date.valueOf()-C.valueOf()?P:y),r.showTooltip({tooltipData:L,tooltipLeft:s?i(L.date):k,tooltipTop:g?h(u.find(w=>w.id===t).valueAccessor(L)):0})},[t,f,i,h,u,a,r.showTooltip]),x=l?e.TooltipInPortal:zt;return{handleTooltip:p,TooltipWrapper:x,containerRef:e.containerRef,...r,hideTooltip:()=>a?r.showTooltip(a):r.hideTooltip()}}import{Fragment as nt,jsx as D,jsxs as W}from"react/jsx-runtime";function ao(t){return D(Yt,{className:"relative",children:({width:n,height:l})=>n>0&&l>0&&D(Jt,{...t,width:n,height:l})})}function Jt({type:t="area",width:n,height:l,children:g,data:s,series:m,tooltipContent:u=e=>m[0].valueAccessor(e).toString(),tooltipClassName:f="",defaultTooltipIndex:i=null,margin:h={top:12,right:4,bottom:32,left:4},padding:c}){let[e,o]=Ht(),a={...h,left:h.left+(e??0)},r=c??{top:.1,bottom:t==="area"?.1:0},p=n-a.left-a.right,x=l-a.top-a.bottom,{startDate:d,endDate:A}=Y(()=>{let b=s.map(({date:$})=>$),N=b.map($=>$.getTime());return{startDate:b[N.indexOf(Math.min(...N))],endDate:b[N.indexOf(Math.max(...N))]}},[s]),{minY:k,maxY:C}=Y(()=>{let b=m.filter(({isActive:N})=>N!==!1).map(({valueAccessor:N})=>s.map($=>N($))).flat().filter(N=>N!=null);return{minY:t==="area"?Math.min(...b):Math.min(0,...b),maxY:Math.max(...b)}},[s,m]),{yScale:F,xScale:y}=Y(()=>{let b=C-k;return{yScale:qt({domain:[k-b*(r.bottom??0),C+b*(r.top??0)],range:[x,0],nice:!0,clamp:!0}),xScale:t==="area"?Xt({domain:[d,A],range:[0,p]}):Ut({domain:s.map(({date:N})=>N),range:[0,p],padding:Math.min(.75,p/s.length*.02),align:.5})}},[d,A,k,C,x,p,s.length,t]),P={type:t,width:p,height:x,data:s,series:m,startDate:d,endDate:A,xScale:y,yScale:F,minY:k,maxY:C,margin:a,padding:r,tooltipContent:u,tooltipClassName:f,defaultTooltipIndex:i,leftAxisMargin:e,setLeftAxisMargin:o},L=rt({seriesId:m[0].id,chartContext:P,defaultIndex:i??void 0}),{tooltipData:w,TooltipWrapper:lt,tooltipLeft:st,tooltipTop:mt,handleTooltip:B,hideTooltip:ct,containerRef:pt}=L;return D(V.Provider,{value:P,children:W(I.Provider,{value:L,children:[W("svg",{width:n,height:l,ref:pt,children:[g,W(Rt,{left:a.left,top:a.top,children:[w&&("bandwidth"in y?D(nt,{children:D(at,{x:(y(w.date)??0)-y.bandwidth()*y.padding(),width:y.bandwidth()*(1+y.padding()*2),y:0,height:x,fill:"black",fillOpacity:.05})}):W(nt,{children:[D(jt,{x1:y(w.date),x2:y(w.date),y1:x,y2:0,stroke:"black",strokeWidth:1.5}),m.filter(({isActive:b})=>b).map(b=>D(Qt,{cx:y(w.date),cy:F(b.valueAccessor(w)),r:4,className:b.colorClassName??"text-blue-800",fill:"currentColor"},b.id))]})),D(at,{x:0,y:0,width:p,height:x,onTouchStart:B,onTouchMove:B,onMouseMove:B,onMouseLeave:ct,fill:"transparent"})]})]}),D("div",{className:"pointer-events-none absolute inset-0",children:w&&D(lt,{left:(st??0)+a.left,top:(mt??0)+a.top,offsetLeft:"bandwidth"in y?y.bandwidth()+8:8,offsetTop:12,className:"absolute",unstyled:!0,children:D("div",{className:T("pointer-events-none rounded-lg border border-gray-200 bg-white px-4 py-2 text-base shadow-sm",f),children:(u==null?void 0:u(w))??m[0].valueAccessor(w)})},w.date.toString())})]})})}import{AxisBottom as Kt}from"@visx/axis";import{Group as Zt}from"@visx/group";import{Line as te}from"@visx/shape";import{useMemo as ee}from"react";var it=t=>[...Array(t+1).keys()].filter(n=>t%n===0);import{Fragment as oe,jsx as U,jsxs as re}from"react/jsx-runtime";function fo({maxTicks:t,showGridLines:n=!1,highlightLast:l=!0,tickFormat:g=s=>s.toLocaleDateString("en-US",{month:"short",day:"numeric"})}){let{data:s,margin:m,width:u,height:f,xScale:i,startDate:h,endDate:c}=M(),{tooltipData:e}=E(),o=ee(()=>{let a=t??u<450?4:u<600?6:8,r=it(s.length).find(x=>(s.length+1)/x<=a)??1,p=s.length/r<2;return s.filter((x,d,{length:A})=>p?d===0||d===A-1:(d+1)%r===0).map(({date:x})=>x)},[u,t,s]);return re(oe,{children:[U(Kt,{left:m.left,top:m.top+f,scale:i,tickValues:o,hideTicks:!0,stroke:"#00000026",tickFormat:a=>g(a),tickLabelProps:(a,r,{length:p})=>({className:"transition-colors",textAnchor:r===0?"start":r===p-1?"end":"middle",fontSize:12,fill:(e?e.date===a:l&&r===p-1)?"#000":"#00000066"})}),n&&U(Zt,{left:m.left,top:m.top,children:o.length>0&&o.map(a=>U(te,{x1:i(a),x2:i(a),y1:f,y2:0,stroke:a===(e==null?void 0:e.date)?"transparent":"#00000026",strokeWidth:1,strokeDasharray:[h,c].includes(a)?0:5},a.toString()))})]})}import{AxisLeft as ae}from"@visx/axis";import{Group as ne}from"@visx/group";import{Line as ie}from"@visx/shape";import{getStringWidth as le}from"@visx/text";import{useLayoutEffect as se,useMemo as me}from"react";import{Fragment as ce,jsx as q,jsxs as pe}from"react/jsx-runtime";function vo({numTicks:t,showGridLines:n=!1,integerTicks:l=!1,tickValues:g,tickFormat:s=u=>u.toString(),tickAxisSpacing:m=8}){let{width:u,height:f,margin:i,yScale:h,minY:c,leftAxisMargin:e,setLeftAxisMargin:o}=M(),a=me(()=>{if(g)return g;let r=t??f<350?3:4;return h.ticks(r).filter(p=>p>=c&&l?Number.isInteger(p):!0)},[g,t,f,h,l]);return se(()=>{let r=Math.max(...a.map(p=>le(s(p),{fontSize:12})??0))+m;(e??0)<r&&o(r)},[a,m,e]),pe(ce,{children:[q(ae,{left:i.left,top:i.top,scale:h,tickValues:a,hideTicks:!0,stroke:"transparent",tickFormat:r=>s(r),tickLength:m,tickLabelProps:()=>({fontSize:12,fill:"#00000066",textAnchor:"end",verticalAnchor:"middle"})}),n&&q(ne,{left:i.left,top:i.top,children:a.length>0&&a.map(r=>{let p=h(r);if(p!==f)return q(ie,{y1:p,y2:p,x1:0,x2:u,stroke:"#00000026",strokeWidth:1,strokeDasharray:5},r.toString())})})]})}export{Te as Areas,Le as Bars,V as ChartContext,I as ChartTooltipContext,_e as FunnelChart,ao as TimeSeriesChart,fo as XAxis,vo as YAxis,M as useChartContext,E as useChartTooltipContext};
2
+ import{a as X}from"../chunk-NWME2ANF.mjs";import{c as z,o as T}from"../chunk-DG4AUGTQ.mjs";import{LinearGradient as dt}from"@visx/gradient";import{Group as ut}from"@visx/group";import{Area as ft,AreaClosed as ht,Circle as xt}from"@visx/shape";import{AnimatePresence as gt,motion as _}from"framer-motion";import{useMemo as Ct}from"react";import{createContext as Q,useContext as j}from"react";var V=Q(null);function M(){let t=j(V);if(!t)throw new Error("No chart context");return t}var I=Q(null);function E(){let t=j(I);if(!t)throw new Error("No chart tooltip context");return t}import{jsx as S,jsxs as yt}from"react/jsx-runtime";function Te({seriesStyles:t}){let{data:n,series:l,margin:g,xScale:s,yScale:m,startDate:u,endDate:f}=M();if(!("ticks"in s))throw new Error("Areas require a time scale (type=area)");let{tooltipData:i}=E(),h=Ct(()=>n.map(c=>({...c,values:Object.fromEntries(Object.keys(c.values).map(e=>[e,0]))})),[n]);return S(ut,{left:g.left,top:g.top,children:S(gt,{children:l.filter(({isActive:c})=>c).map(c=>{let e=t==null?void 0:t.find(({id:o})=>o===c.id);return yt(_.g,{initial:{opacity:1},exit:{opacity:0},transition:{duration:.1},children:[S(dt,{id:`${c.id}-mask-gradient`,from:"white",to:"white",fromOpacity:.2,toOpacity:0,x1:0,x2:0,y1:0,y2:1}),S("mask",{id:`${c.id}-mask`,maskContentUnits:"objectBoundingBox",children:S("rect",{width:"1",height:"1",fill:`url(#${c.id}-mask-gradient)`})}),S(ht,{data:n,x:o=>s(o.date),y:o=>m(c.valueAccessor(o)??0),yScale:m,children:({path:o})=>S(_.path,{initial:{d:o(h)||"",opacity:0},animate:{d:o(n)||"",opacity:1},className:T(c.colorClassName??"text-blue-500",e==null?void 0:e.gradientClassName),mask:`url(#${c.id}-mask)`,fill:(e==null?void 0:e.areaFill)??"currentColor"})}),S(ft,{data:n,x:o=>s(o.date),y:o=>m(c.valueAccessor(o)??0),children:({path:o})=>S(_.path,{initial:{d:o(h)||""},animate:{d:o(n)||""},className:T(c.colorClassName??"text-blue-700",e==null?void 0:e.lineClassName),stroke:(e==null?void 0:e.lineStroke)??"currentColor",strokeOpacity:.8,strokeWidth:2,fill:"transparent"})}),!i&&S(xt,{cx:s(n.at(-1).date),cy:m(c.valueAccessor(n.at(-1))),r:4,className:T(c.colorClassName??"text-blue-700",e==null?void 0:e.lineClassName),fill:"currentColor"})]},`${c.id}_${u.toString()}_${f.toString()}`)})})})}import{RectClipPath as bt}from"@visx/clip-path";import{LinearGradient as Tt}from"@visx/gradient";import{Group as vt}from"@visx/group";import{BarRounded as kt}from"@visx/shape";import{AnimatePresence as wt,motion as H}from"framer-motion";import{useId as Nt}from"react";import{jsx as G,jsxs as J}from"react/jsx-runtime";function Le({seriesStyles:t}){let n=Nt(),{data:l,series:g,margin:s,xScale:m,yScale:u,width:f,height:i,startDate:h,endDate:c}=M();if(!("bandwidth"in m))throw new Error("Bars require a band scale (type=bar)");return J(vt,{left:s.left,top:s.top,children:[G(bt,{id:n,x:0,y:0,width:f,height:i}),G(wt,{children:g.filter(({isActive:e})=>e).map(e=>{let o=t==null?void 0:t.find(({id:a})=>a===e.id);return J(H.g,{initial:{opacity:0},animate:{opacity:1},exit:{opacity:0},transition:{duration:.1},clipPath:`url(#${n})`,children:[G(Tt,{className:T(e.colorClassName??"text-blue-500",o==null?void 0:o.gradientClassName),id:`${e.id}-background`,fromOffset:"0%",from:"currentColor",fromOpacity:.01,toOffset:"40%",to:"currentColor",toOpacity:1,x1:0,x2:0,y1:1}),G(H.g,{initial:{y:100},animate:{y:0},transition:{duration:.15,ease:"easeOut"},children:l.map(a=>{let r=m.bandwidth(),p=m(a.date)??0,x=u(e.valueAccessor(a)??0),d=i-x,A=Math.min(r,d)/2;return d>0?G(kt,{x:p,y:x,width:r,height:d,radius:1e3,top:!0,className:T(e.colorClassName??"text-blue-700",o==null?void 0:o.barClassName),fill:(o==null?void 0:o.barFill)??`url(#${e.id}-background)`},a.date.toString()):null})})]},`${e.id}_${h.toString()}_${c.toString()}`)})})]})}import{curveBasis as Dt}from"@visx/curve";import{ParentSize as At}from"@visx/responsive";import{scaleLinear as K}from"@visx/scale";import{Area as St}from"@visx/shape";import{Text as Pt}from"@visx/text";import{motion as Mt}from"framer-motion";import{Fragment as Lt,useMemo as R,useState as Ot}from"react";import{jsx as v,jsxs as O}from"react/jsx-runtime";var Ft=[{opacity:1,padding:0},{opacity:.3,padding:8},{opacity:.15,padding:16}],Z=16,tt=40;function _e(t){return v("div",{className:"size-full",children:v(At,{className:"relative",children:({width:n,height:l})=>n&&l?v($t,{...t,width:n,height:l}):null})})}function $t({width:t,height:n,steps:l,persistentPercentages:g=!0,defaultTooltipStepId:s}){let{isMobile:m}=X(),[u,f]=Ot(s??null),i=l.find(({id:r})=>r===u),h=R(()=>Object.fromEntries(l.map(({id:r,value:p},x)=>{var d;return[r,ot(p,((d=l[x+1])==null?void 0:d.value)??l[l.length-1].value)]})),[l]),c=R(()=>ot(0,0),[l]),e=R(()=>Math.max(...l.map(r=>r.value)),[l]),o=K({domain:[0,l.length],range:[0,t]}),a=K({domain:[e,-e],range:[n-Z-tt,Z+tt]});return O("div",{className:"relative",children:[v("svg",{width:t,height:n,children:l.map(({id:r,value:p,colorClassName:x},d)=>O(Lt,{children:[v("rect",{x:o(d),y:0,width:t/l.length,height:n,className:"fill-transparent transition-colors hover:fill-blue-600/5",onPointerEnter:()=>f(r),onPointerDown:()=>f(r),onPointerLeave:()=>!m&&f(s??null)}),v("line",{x1:o(d),y1:0,x2:o(d),y2:n,className:"stroke-black/5 sm:stroke-black/10"}),Ft.map(({opacity:A,padding:k})=>v(St,{data:h[r],curve:Dt,x:C=>o(d+C.x),y0:C=>a(-C.y)-k,y1:C=>a(C.y)+k,children:({path:C})=>v(Mt.path,{initial:{d:C(c)||"",opacity:0},animate:{d:C(h[r])||"",opacity:A},className:T(x,"pointer-events-none"),fill:"currentColor"})},`${r}-${A}-${k}`)),g&&v(Pt,{x:(o(d)+o(d+1))/2,y:n/2,textAnchor:"middle",verticalAnchor:"middle",fill:"white",fontSize:16,className:"pointer-events-none select-none",children:et(p/e*100)+"%"})]},r))}),i&&v("div",{className:T("pointer-events-none absolute flex items-center justify-center px-1 pb-4",g?"animate-slide-up-fade top-16 sm:top-12":"animate-fade-in top-1/2 -translate-y-1/2"),style:{left:o(l.findIndex(({id:r})=>r===i.id)),width:t/l.length},children:O("div",{className:T("rounded-lg border border-gray-200 bg-white text-base shadow-sm"),children:[v("p",{className:"border-b border-gray-200 px-3 py-2 text-sm text-gray-900 sm:px-4 sm:py-3",children:i.label}),O("div",{className:"flex flex-wrap justify-between gap-x-4 gap-y-2 px-3 py-2 text-sm sm:px-4 sm:py-3",children:[O("div",{className:"flex items-center gap-2",children:[v("div",{className:T(i.colorClassName,"h-2 w-2 shrink-0 rounded-sm bg-current opacity-50 shadow-[inset_0_0_0_1px_#0003]")}),v("p",{className:"whitespace-nowrap capitalize text-gray-600",children:et(i.value/e*100)+"%"})]}),O("p",{className:"whitespace-nowrap font-medium text-gray-900",children:[z(i.value,{full:!0}),i.additionalValue!==void 0&&O("span",{className:"text-gray-500",children:[" ","($",z(i.additionalValue/100),")"]})]})]})]})},i.id)]})}var et=t=>t>0&&t<.01?"< 0.01":z(t,{digits:2}),ot=(t,n)=>[{x:0,y:t},{x:.3,y:t},{x:.5,y:(t+n)/2},{x:.7,y:n},{x:1,y:n}];import{Group as Rt}from"@visx/group";import{ParentSize as Yt}from"@visx/responsive";import{scaleBand as Ut,scaleLinear as qt,scaleUtc as Xt}from"@visx/scale";import{Bar as at,Circle as Qt,Line as jt}from"@visx/shape";import{useMemo as Y,useState as Ht}from"react";import{localPoint as Gt}from"@visx/event";import{TooltipWithBounds as zt,useTooltipInPortal as Et,useTooltip as Wt}from"@visx/tooltip";import{bisector as Bt}from"d3-array";import{useCallback as Vt,useMemo as It}from"react";var _t=Bt(t=>new Date(t.date)).left;function rt({seriesId:t,chartContext:n,renderInPortal:l=!1,snapToY:g=!1,snapToX:s=!0,defaultIndex:m}){let{series:u,data:f,xScale:i,yScale:h,margin:c}=n,e=Et({scroll:!0,detectBounds:!0,debounce:200}),o=m!==void 0?f[m]:void 0,a=It(()=>o!==void 0?{tooltipData:o,tooltipLeft:s?i(o.date):0,tooltipTop:g?h(u.find(d=>d.id===t).valueAccessor(o)):0}:void 0,[o,s,g,i,h,u,t]),r=Wt(a??void 0),p=Vt(d=>{let k=(Gt(d)||{x:0}).x-c.left,C="invert"in i?i.invert(k):i.domain()[Math.round((k-i.step()*.75)/i.step())];if(C===void 0){console.log("x0 is undefined",{defaultTooltipData:a}),a?r.showTooltip(a):r.hideTooltip();return}let F=_t(f,C,1),y=f[F-1],P=f[F],L=y;P!=null&&P.date&&(L=C.valueOf()-y.date.valueOf()>P.date.valueOf()-C.valueOf()?P:y),r.showTooltip({tooltipData:L,tooltipLeft:s?i(L.date):k,tooltipTop:g?h(u.find(w=>w.id===t).valueAccessor(L)):0})},[t,f,i,h,u,a,r.showTooltip]),x=l?e.TooltipInPortal:zt;return{handleTooltip:p,TooltipWrapper:x,containerRef:e.containerRef,...r,hideTooltip:()=>a?r.showTooltip(a):r.hideTooltip()}}import{Fragment as nt,jsx as D,jsxs as W}from"react/jsx-runtime";function ao(t){return D(Yt,{className:"relative",children:({width:n,height:l})=>n>0&&l>0&&D(Jt,{...t,width:n,height:l})})}function Jt({type:t="area",width:n,height:l,children:g,data:s,series:m,tooltipContent:u=e=>m[0].valueAccessor(e).toString(),tooltipClassName:f="",defaultTooltipIndex:i=null,margin:h={top:12,right:4,bottom:32,left:4},padding:c}){let[e,o]=Ht(),a={...h,left:h.left+(e??0)},r=c??{top:.1,bottom:t==="area"?.1:0},p=n-a.left-a.right,x=l-a.top-a.bottom,{startDate:d,endDate:A}=Y(()=>{let b=s.map(({date:$})=>$),N=b.map($=>$.getTime());return{startDate:b[N.indexOf(Math.min(...N))],endDate:b[N.indexOf(Math.max(...N))]}},[s]),{minY:k,maxY:C}=Y(()=>{let b=m.filter(({isActive:N})=>N!==!1).map(({valueAccessor:N})=>s.map($=>N($))).flat().filter(N=>N!=null);return{minY:t==="area"?Math.min(...b):Math.min(0,...b),maxY:Math.max(...b)}},[s,m]),{yScale:F,xScale:y}=Y(()=>{let b=C-k;return{yScale:qt({domain:[k-b*(r.bottom??0),C+b*(r.top??0)],range:[x,0],nice:!0,clamp:!0}),xScale:t==="area"?Xt({domain:[d,A],range:[0,p]}):Ut({domain:s.map(({date:N})=>N),range:[0,p],padding:Math.min(.75,p/s.length*.02),align:.5})}},[d,A,k,C,x,p,s.length,t]),P={type:t,width:p,height:x,data:s,series:m,startDate:d,endDate:A,xScale:y,yScale:F,minY:k,maxY:C,margin:a,padding:r,tooltipContent:u,tooltipClassName:f,defaultTooltipIndex:i,leftAxisMargin:e,setLeftAxisMargin:o},L=rt({seriesId:m[0].id,chartContext:P,defaultIndex:i??void 0}),{tooltipData:w,TooltipWrapper:lt,tooltipLeft:st,tooltipTop:mt,handleTooltip:B,hideTooltip:ct,containerRef:pt}=L;return D(V.Provider,{value:P,children:W(I.Provider,{value:L,children:[W("svg",{width:n,height:l,ref:pt,children:[g,W(Rt,{left:a.left,top:a.top,children:[w&&("bandwidth"in y?D(nt,{children:D(at,{x:(y(w.date)??0)-y.bandwidth()*y.padding(),width:y.bandwidth()*(1+y.padding()*2),y:0,height:x,fill:"black",fillOpacity:.05})}):W(nt,{children:[D(jt,{x1:y(w.date),x2:y(w.date),y1:x,y2:0,stroke:"black",strokeWidth:1.5}),m.filter(({isActive:b})=>b).map(b=>D(Qt,{cx:y(w.date),cy:F(b.valueAccessor(w)),r:4,className:b.colorClassName??"text-blue-800",fill:"currentColor"},b.id))]})),D(at,{x:0,y:0,width:p,height:x,onTouchStart:B,onTouchMove:B,onMouseMove:B,onMouseLeave:ct,fill:"transparent"})]})]}),D("div",{className:"pointer-events-none absolute inset-0",children:w&&D(lt,{left:(st??0)+a.left,top:(mt??0)+a.top,offsetLeft:"bandwidth"in y?y.bandwidth()+8:8,offsetTop:12,className:"absolute",unstyled:!0,children:D("div",{className:T("pointer-events-none rounded-lg border border-gray-200 bg-white px-4 py-2 text-base shadow-sm",f),children:(u==null?void 0:u(w))??m[0].valueAccessor(w)})},w.date.toString())})]})})}import{AxisBottom as Kt}from"@visx/axis";import{Group as Zt}from"@visx/group";import{Line as te}from"@visx/shape";import{useMemo as ee}from"react";var it=t=>[...Array(t+1).keys()].filter(n=>t%n===0);import{Fragment as oe,jsx as U,jsxs as re}from"react/jsx-runtime";function fo({maxTicks:t,showGridLines:n=!1,highlightLast:l=!0,tickFormat:g=s=>s.toLocaleDateString("en-US",{month:"short",day:"numeric"})}){let{data:s,margin:m,width:u,height:f,xScale:i,startDate:h,endDate:c}=M(),{tooltipData:e}=E(),o=ee(()=>{let a=t??u<450?4:u<600?6:8,r=it(s.length).find(x=>(s.length+1)/x<=a)??1,p=s.length/r<2;return s.filter((x,d,{length:A})=>p?d===0||d===A-1:(d+1)%r===0).map(({date:x})=>x)},[u,t,s]);return re(oe,{children:[U(Kt,{left:m.left,top:m.top+f,scale:i,tickValues:o,hideTicks:!0,stroke:"#00000026",tickFormat:a=>g(a),tickLabelProps:(a,r,{length:p})=>({className:"transition-colors",textAnchor:r===0?"start":r===p-1?"end":"middle",fontSize:12,fill:(e?e.date===a:l&&r===p-1)?"#000":"#00000066"})}),n&&U(Zt,{left:m.left,top:m.top,children:o.length>0&&o.map(a=>U(te,{x1:i(a),x2:i(a),y1:f,y2:0,stroke:a===(e==null?void 0:e.date)?"transparent":"#00000026",strokeWidth:1,strokeDasharray:[h,c].includes(a)?0:5},a.toString()))})]})}import{AxisLeft as ae}from"@visx/axis";import{Group as ne}from"@visx/group";import{Line as ie}from"@visx/shape";import{getStringWidth as le}from"@visx/text";import{useLayoutEffect as se,useMemo as me}from"react";import{Fragment as ce,jsx as q,jsxs as pe}from"react/jsx-runtime";function vo({numTicks:t,showGridLines:n=!1,integerTicks:l=!1,tickValues:g,tickFormat:s=u=>u.toString(),tickAxisSpacing:m=8}){let{width:u,height:f,margin:i,yScale:h,minY:c,leftAxisMargin:e,setLeftAxisMargin:o}=M(),a=me(()=>{if(g)return g;let r=t??f<350?3:4;return h.ticks(r).filter(p=>p>=c&&l?Number.isInteger(p):!0)},[g,t,f,h,l]);return se(()=>{let r=Math.max(...a.map(p=>le(s(p),{fontSize:12})??0))+m;(e??0)<r&&o(r)},[a,m,e]),pe(ce,{children:[q(ae,{left:i.left,top:i.top,scale:h,tickValues:a,hideTicks:!0,stroke:"transparent",tickFormat:r=>s(r),tickLength:m,tickLabelProps:()=>({fontSize:12,fill:"#00000066",textAnchor:"end",verticalAnchor:"middle"})}),n&&q(ne,{left:i.left,top:i.top,children:a.length>0&&a.map(r=>{let p=h(r);if(p!==f)return q(ie,{y1:p,y2:p,x1:0,x2:u,stroke:"#00000026",strokeWidth:1,strokeDasharray:5},r.toString())})})]})}export{Te as Areas,Le as Bars,V as ChartContext,I as ChartTooltipContext,_e as FunnelChart,ao as TimeSeriesChart,fo as XAxis,vo as YAxis,M as useChartContext,E as useChartTooltipContext};
@@ -0,0 +1,2 @@
1
+ "use client"
2
+ var Ee=Object.create;var ie=Object.defineProperty;var _e=Object.getOwnPropertyDescriptor;var Pe=Object.getOwnPropertyNames;var Se=Object.getPrototypeOf,Ie=Object.prototype.hasOwnProperty;var Oe=(e,r)=>()=>(r||e((r={exports:{}}).exports,r),r.exports);var Te=(e,r,t,o)=>{if(r&&typeof r=="object"||typeof r=="function")for(let a of Pe(r))!Ie.call(e,a)&&a!==t&&ie(e,a,{get:()=>r[a],enumerable:!(o=_e(r,a))||o.enumerable});return e};var Le=(e,r,t)=>(t=e!=null?Ee(Se(e)):{},Te(r||!e||!e.__esModule?ie(t,"default",{value:e,enumerable:!0}):t,e));var ue=Oe((kt,de)=>{var I=1e3,O=I*60,T=O*60,_=T*24,ir=_*7,lr=_*365.25;de.exports=function(e,r){r=r||{};var t=typeof e;if(t==="string"&&e.length>0)return cr(e);if(t==="number"&&isFinite(e))return r.long?ur(e):dr(e);throw new Error("val is not a non-empty string or a valid number. val="+JSON.stringify(e))};function cr(e){if(e=String(e),!(e.length>100)){var r=/^(-?(?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|weeks?|w|years?|yrs?|y)?$/i.exec(e);if(!!r){var t=parseFloat(r[1]),o=(r[2]||"ms").toLowerCase();switch(o){case"years":case"year":case"yrs":case"yr":case"y":return t*lr;case"weeks":case"week":case"w":return t*ir;case"days":case"day":case"d":return t*_;case"hours":case"hour":case"hrs":case"hr":case"h":return t*T;case"minutes":case"minute":case"mins":case"min":case"m":return t*O;case"seconds":case"second":case"secs":case"sec":case"s":return t*I;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return t;default:return}}}}function dr(e){var r=Math.abs(e);return r>=_?Math.round(e/_)+"d":r>=T?Math.round(e/T)+"h":r>=O?Math.round(e/O)+"m":r>=I?Math.round(e/I)+"s":e+"ms"}function ur(e){var r=Math.abs(e);return r>=_?J(e,r,_,"day"):r>=T?J(e,r,T,"hour"):r>=O?J(e,r,O,"minute"):r>=I?J(e,r,I,"second"):e+" ms"}function J(e,r,t,o){var a=r>=t*1.5;return Math.round(e/t)+" "+o+(a?"s":"")}});var Ne="https://www.google.com/s2/favicons?sz=64&domain_url=";var Ce=100,Re=60*60*24*14,Ue=new Date("2022-09-22T00:00:00.000Z"),K=1e9;var Me=process.env.NEXT_PUBLIC_APP_NAME||"Dub.co",le=process.env.NEXT_PUBLIC_APP_SHORT_DOMAIN||"dub.sh",De=`https://${process.env.NEXT_PUBLIC_APP_DOMAIN}`,ze=new Set([`app.${process.env.NEXT_PUBLIC_APP_DOMAIN}`,`preview.${process.env.NEXT_PUBLIC_APP_DOMAIN}`,"localhost:8888","localhost"]),Be=process.env.NEXT_PUBLIC_VERCEL_ENV==="production"?`https://app.${process.env.NEXT_PUBLIC_APP_DOMAIN}`:process.env.NEXT_PUBLIC_VERCEL_ENV==="preview"?`https://preview.${process.env.NEXT_PUBLIC_APP_DOMAIN}`:"http://localhost:8888",Ge=process.env.NEXT_PUBLIC_VERCEL_ENV==="production"?`https://app.${process.env.NEXT_PUBLIC_APP_DOMAIN}`:process.env.NEXT_PUBLIC_VERCEL_ENV==="preview"?`https://preview.${process.env.NEXT_PUBLIC_APP_DOMAIN}`:process.env.NEXT_PUBLIC_NGROK_URL||"http://localhost:8888",Ve=new Set([`api.${process.env.NEXT_PUBLIC_APP_DOMAIN}`,`api-staging.${process.env.NEXT_PUBLIC_APP_DOMAIN}`,`api.${le}`,"api.localhost:8888"]),$e=process.env.NEXT_PUBLIC_VERCEL_ENV==="production"?`https://api.${process.env.NEXT_PUBLIC_APP_DOMAIN}`:process.env.NEXT_PUBLIC_VERCEL_ENV==="preview"?`https://api-staging.${process.env.NEXT_PUBLIC_APP_DOMAIN}`:"http://api.localhost:8888",Je=new Set([`admin.${process.env.NEXT_PUBLIC_APP_DOMAIN}`,"admin.localhost:8888"]),je=process.env.NEXT_PUBLIC_VERCEL_ENV==="production"?`https://partners.${process.env.NEXT_PUBLIC_APP_DOMAIN}`:process.env.NEXT_PUBLIC_VERCEL_ENV==="preview"?`https://partners-staging.${process.env.NEXT_PUBLIC_APP_DOMAIN}`:"http://partners.localhost:8888",Fe=new Set([`partners.${process.env.NEXT_PUBLIC_APP_DOMAIN}`,`partners-staging.${process.env.NEXT_PUBLIC_APP_DOMAIN}`,"partners.localhost:8888"]);var qe=process.env.STORAGE_BASE_URL;var V=e=>{try{return new URL(e),!0}catch{return!1}},We=e=>{if(V(e))return e;try{if(e.includes(".")&&!e.includes(" "))return new URL(`https://${e}`).toString()}catch{}return e};var Ye=(e,r,t)=>{if(r==="dub.co")return e;let o=new URL(e.startsWith("/")?`https://dub.co${e}`:e);return t&&Object.entries(t).forEach(([a,s])=>{o.searchParams.set(a,s)}),o.toString()};function X(e,r={digits:1}){if(!e)return"0";if(r.full)return Intl.NumberFormat("en-US").format(e);let t=/\.0+$|(\.[0-9]*[1-9])0+$/;if(e<1)return e.toFixed(r.digits).replace(t,"$1");var o=[{value:1,symbol:""},{value:1e3,symbol:"K"},{value:1e6,symbol:"M"},{value:1e9,symbol:"G"},{value:1e12,symbol:"T"},{value:1e15,symbol:"P"},{value:1e18,symbol:"E"}].slice().reverse().find(function(a){return e>=a.value});return o?(e/o.value).toFixed(r.digits).replace(t,"$1")+o.symbol:"0"}var ce=(e,r)=>Intl.NumberFormat("en-US",{style:"currency",currency:"USD",maximumFractionDigits:0,...r}).format(e);var Xe=new RegExp(/^([a-zA-Z0-9]([a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?\.)+[a-zA-Z]{2,}$/),He=new RegExp(/^[a-zA-Z0-9\-]+$/);var Ze=e=>{if(V(e))return new URL(e).hostname.replace(/^www\./,"");try{if(e.includes(".")&&!e.includes(" "))return new URL(`https://${e}`).hostname.replace(/^www\./,"")}catch{return null}};var $=({name:e="Business",monthly:r=59,yearly:t=49,links:o=5e3,clicks:a=15e4,sales:s=5e5,domains:n=40,users:i=15,ids:c=[]})=>({name:e,tagline:"For fast-growing startups and businesses looking to scale",link:"https://dub.co/help/article/business-plan",price:{monthly:r,yearly:t,ids:c},limits:{links:o,clicks:a,sales:s,domains:n,tags:K,users:i,ai:1e3,api:3e3},colors:{bg:"bg-sky-900",text:"text-sky-900"},cta:{text:`Get started with ${e}`,shortText:`Get ${e}`,href:"https://app.dub.co/register",color:"bg-sky-900 hover:bg-sky-800 hover:ring-sky-100"},featureTitle:"Everything in Pro, plus:",features:[{id:"clicks",text:`${X(a)} tracked clicks/mo`},{id:"links",text:`${Intl.NumberFormat("en-US").format(o)} new links/mo`},{id:"sales",text:`${ce(s/100)} tracked sales/mo`,footnote:{title:"Use Dub Conversions to track how your link clicks are converting to signups and sales. Limits are based on the total sale amount tracked within a given month.",cta:"Learn more.",href:"https://dub.co/help/article/dub-conversions"}},{id:"retention",text:"3-year analytics retention"},{id:"domains",text:`${n} domains`},{id:"users",text:`${i} users`},{id:"events",text:"Real-time events stream",footnote:{title:"Get more data on your link clicks and QR code scans with a detailed, real-time stream of events in your workspace",cta:"Learn more.",href:"https://d.to/events"}},{id:"webhooks",text:"Event webhooks (beta)",footnote:{title:"Get notified when a link is clicked or a QR code is scanned using webhooks.",cta:"Learn more.",href:"https://d.to/webhooks"}}]}),S=[{name:"Free",tagline:"For hobbyists and individuals looking to manage their links",price:{monthly:0,yearly:0},limits:{links:25,clicks:1e3,domains:3,tags:5,users:1,ai:10,api:60},colors:{bg:"bg-black",text:"text-black"},cta:{text:"Start for free",href:"https://app.dub.co/register",color:"bg-white hover:bg-gray-50 border border-gray-200 hover:ring-gray-100 text-neutral-800"},featureTitle:"What's included:",features:[{id:"clicks",text:"1K tracked clicks/mo"},{id:"links",text:"25 new links/mo"},{id:"retention",text:"30-day analytics retention"},{id:"domains",text:"3 domains"},{id:"user",text:"1 user"},{id:"analytics",text:"Advanced analytics",footnote:{title:"Get location (country, city, continent), device (type, browser, OS), and referer data on your clicks.",cta:"Learn more.",href:"https://dub.co/help/article/dub-analytics"}},{id:"ai",text:"10 AI credits/mo"},{id:"basic-support",text:"Basic support"},{id:"api",text:"API Access",footnote:{title:"Programatically manage your links using our REST API.",cta:"Learn more.",href:"https://dub.co/docs/api-reference/introduction"}}]},{name:"Pro",tagline:"For content creators or small teams needing advanced features",link:"https://dub.co/help/article/pro-plan",price:{monthly:24,yearly:19,ids:["price_1LodNLAlJJEpqkPVQSrt33Lc","price_1LodNLAlJJEpqkPVRxUyCQgZ","price_1OTcQBAlJJEpqkPViGtGEsbb","price_1OYJeBAlJJEpqkPVLjTsjX0E","price_1OTcQBAlJJEpqkPVYlCMqdLL","price_1OYJeBAlJJEpqkPVnPGEZeb0"]},limits:{links:1e3,clicks:5e4,domains:10,tags:25,users:5,ai:1e3,api:600},colors:{bg:"bg-blue-500",text:"text-blue-500"},cta:{text:"Get started with Pro",shortText:"Get Pro",href:"https://app.dub.co/register",color:"bg-black hover:bg-neutral-800 hover:ring-gray-200"},featureTitle:"Everything in Free, plus:",features:[{id:"clicks",text:"50K tracked clicks/mo"},{id:"links",text:"1,000 new links/mo"},{id:"retention",text:"1-year analytics retention"},{id:"domains",text:"10 domains"},{id:"users",text:"5 users"},{id:"link-features",text:"Advanced link features",footnote:"Custom social media cards, password-protected links, link expiration, link cloaking, device targeting, geo targeting etc."},{id:"ai",text:"Unlimited AI credits",footnote:{title:"Subject to fair use policy \u2013 you will be notified if you exceed the limit, which are high enough for frequent usage.",cta:"Learn more.",href:"https://dub.co/blog/introducing-dub-ai"}},{id:"priority-support",text:"Priority support"},{id:"dublink",text:"Premium dub.link domain",footnote:{title:"Stand out from the crowd with a premium dub.link domain.",cta:"Learn more.",href:"https://dub.co/help/article/default-dub-domains#premium-dublink-domain"}},{id:"dotlink",text:"Free custom domain",footnote:{title:"All our paid plans come with a free .link custom domain, which helps improve click-through rates.",cta:"Learn more.",href:"https://dub.co/help/article/free-dot-link-domain"}}]},$({name:"Business",monthly:59,yearly:49,links:5e3,clicks:15e4,sales:5e5,domains:40,users:15,ids:["price_1LodLoAlJJEpqkPV9rD0rlNL","price_1LodLoAlJJEpqkPVJdwv5zrG","price_1OZgmnAlJJEpqkPVOj4kV64R","price_1OzNlmAlJJEpqkPV7s9HXNAC","price_1OzNmXAlJJEpqkPVYO89lTdx","price_1OzOFIAlJJEpqkPVJxzc9irl","price_1OzOXMAlJJEpqkPV9ERrjjbw"]}),$({name:"Business Plus",monthly:119,yearly:99,links:15e3,clicks:4e5,sales:15e5,domains:100,users:30,ids:["price_1OnWu0AlJJEpqkPVWk4144ZG","price_1OnWu0AlJJEpqkPVkDWVriAB","price_1OnaK3AlJJEpqkPVaCfCPdHi","price_1OzObrAlJJEpqkPVh6D9HWGO"]}),$({name:"Business Extra",monthly:249,yearly:199,links:4e4,clicks:1e6,sales:4e6,domains:250,users:50,ids:["price_1OnWvCAlJJEpqkPVLzLHx5QD","price_1OnWvCAlJJEpqkPVHhCCvIOq","price_1OnaKJAlJJEpqkPVeJSvPfJb","price_1OzOg1AlJJEpqkPVPlsrxoWm"]}),$({name:"Business Max",monthly:499,yearly:399,links:1e5,clicks:25e5,sales:1e7,domains:500,users:100,ids:["price_1OnWwLAlJJEpqkPVXtJyPqLk","price_1OnWwLAlJJEpqkPV4eMbOkNh","price_1OnaKOAlJJEpqkPVV6gkZPgt","price_1OzOh5AlJJEpqkPVtCSX7dlE"]}),{name:"Enterprise",tagline:"For large organizations and governments with custom needs",link:"https://dub.co/enterprise",price:{monthly:null,yearly:null},limits:{links:25e4,clicks:5e6,domains:1e3,tags:1e3,users:500,ai:1e4,api:1e4},colors:{bg:"bg-violet-600",text:"text-violet-600"},cta:{text:"Contact us",href:"/enterprise",color:"bg-white hover:bg-gray-50 border border-gray-200 hover:ring-gray-100 text-neutral-800"},featureTitle:"Everything in Business, plus:",features:[{id:"sso",text:"SSO/SAML"},{id:"roles",text:"Role-based controls"},{id:"volume",text:"Volume discounts"},{id:"sla",text:"Custom SLA"},{id:"logs",text:"Audit logs"},{id:"success",text:"Dedicated success manager"}]}],Qe=S.find(e=>e.name==="Free"),er=S.find(e=>e.name==="Pro"),rr=S.find(e=>e.name==="Business"),tr=S.find(e=>e.name==="Enterprise");var or=S.filter(e=>e.name!=="Free"&&e.name!=="Enterprise");var ar=[{name:"Spotify Link Shortener",slug:"spotify-link-shortener"},{name:"ChatGPT Link Shortener",slug:"chatgpt-link-shortener"},{name:"GitHub Link Shortener",slug:"github-link-shortener"},{name:"Calendar Link Shortener",slug:"cal-link-shortener"},{name:"Google Link Shortener",slug:"google-link-shortener"},{name:"Amazon Link Shortener",slug:"amazon-link-shortener"},{name:"Figma Link Shortener",slug:"figma-link-shortener"},{name:"Metatags API",slug:"metatags"},{name:"Link Inspector",slug:"inspector"},{name:"QR Code API",slug:"qr-code"},{name:"UTM Builder",slug:"utm-builder"}];var sr=(e,r={width:1200,height:630,quality:1})=>new Promise((t,o)=>{let a=new FileReader;a.onload=s=>{var n;let i=new Image;i.src=(n=s.target)==null?void 0:n.result,i.onload=()=>{let c=r.width,f=r.height,u=document.createElement("canvas");u.width=c,u.height=f;let g=u.getContext("2d");g.imageSmoothingQuality="high";let b=i.width,x=i.height,w=b/x,y=c/f,m,h,v=0,N=0;w>y?(h=x,m=x*y,v=(b-m)/2):(m=b,h=b/y,N=(x-h)/2),g.drawImage(i,v,N,m,h,0,0,c,f);let C=u.toDataURL("image/jpeg",r.quality);t(C)},i.onerror=c=>o(new Error("Image loading error: "+c))},a.onerror=s=>o(new Error("FileReader error: "+s)),a.readAsDataURL(e)});var nr=(e,r)=>e.map((t,o)=>({item:t,index:o})).sort((t,o)=>r(t.item,o.item)||t.index-o.index).map(({item:t})=>t);var pe=Le(ue(),1),pr=(e,{withAgo:r}={})=>{if(!e)return"Never";let t=Date.now()-new Date(e).getTime();return t<1e3?"Just now":t>828e5?new Date(e).toLocaleDateString("en-US",{month:"short",day:"numeric",year:new Date(e).getFullYear()!==new Date().getFullYear()?"numeric":void 0}):`${(0,pe.default)(t)}${r?" ago":""}`};function mr(e){for(let r=e.target,t=0;r&&r!==e.currentTarget&&t<50;r=r.parentElement,t++)if(["button","a","input","textarea"].includes(r.tagName.toLowerCase())||["data-radix-popper-content-wrapper","data-vaul-overlay","data-vaul-drawer"].some(o=>r.getAttribute(o)!==null))return!0;return!1}var me=(e,r)=>{if(e===r)return!0;if(typeof e!="object"||typeof r!="object"||e===null||r===null)return!1;let t=Object.keys(e),o=Object.keys(r);if(t.length!==o.length)return!1;for(let a of t)if(!o.includes(a)||!me(e[a],r[a]))return!1;return!0};async function fr(e,r){let t=await fetch(e,r);if(!t.ok){let o=new Error("An error occurred while fetching the data.");throw o.info=(await t.json()).error,o.status=t.status,o}return t.json()}function fe(e){var r,t,o="";if(typeof e=="string"||typeof e=="number")o+=e;else if(typeof e=="object")if(Array.isArray(e)){var a=e.length;for(r=0;r<a;r++)e[r]&&(t=fe(e[r]))&&(o&&(o+=" "),o+=t)}else for(t in e)e[t]&&(o&&(o+=" "),o+=t);return o}function ge(){for(var e,r,t=0,o="",a=arguments.length;t<a;t++)(e=arguments[t])&&(r=fe(e))&&(o&&(o+=" "),o+=r);return o}var Z="-";function gr(e){let r=br(e),{conflictingClassGroups:t,conflictingClassGroupModifiers:o}=e;function a(n){let i=n.split(Z);return i[0]===""&&i.length!==1&&i.shift(),ye(i,r)||hr(n)}function s(n,i){let c=t[n]||[];return i&&o[n]?[...c,...o[n]]:c}return{getClassGroupId:a,getConflictingClassGroupIds:s}}function ye(e,r){var n;if(e.length===0)return r.classGroupId;let t=e[0],o=r.nextPart.get(t),a=o?ye(e.slice(1),o):void 0;if(a)return a;if(r.validators.length===0)return;let s=e.join(Z);return(n=r.validators.find(({validator:i})=>i(s)))==null?void 0:n.classGroupId}var he=/^\[(.+)\]$/;function hr(e){if(he.test(e)){let r=he.exec(e)[1],t=r==null?void 0:r.substring(0,r.indexOf(":"));if(t)return"arbitrary.."+t}}function br(e){let{theme:r,prefix:t}=e,o={nextPart:new Map,validators:[]};return xr(Object.entries(e.classGroups),t).forEach(([s,n])=>{H(n,o,s,r)}),o}function H(e,r,t,o){e.forEach(a=>{if(typeof a=="string"){let s=a===""?r:be(r,a);s.classGroupId=t;return}if(typeof a=="function"){if(yr(a)){H(a(o),r,t,o);return}r.validators.push({validator:a,classGroupId:t});return}Object.entries(a).forEach(([s,n])=>{H(n,be(r,s),t,o)})})}function be(e,r){let t=e;return r.split(Z).forEach(o=>{t.nextPart.has(o)||t.nextPart.set(o,{nextPart:new Map,validators:[]}),t=t.nextPart.get(o)}),t}function yr(e){return e.isThemeGetter}function xr(e,r){return r?e.map(([t,o])=>{let a=o.map(s=>typeof s=="string"?r+s:typeof s=="object"?Object.fromEntries(Object.entries(s).map(([n,i])=>[r+n,i])):s);return[t,a]}):e}function vr(e){if(e<1)return{get:()=>{},set:()=>{}};let r=0,t=new Map,o=new Map;function a(s,n){t.set(s,n),r++,r>e&&(r=0,o=t,t=new Map)}return{get(s){let n=t.get(s);if(n!==void 0)return n;if((n=o.get(s))!==void 0)return a(s,n),n},set(s,n){t.has(s)?t.set(s,n):a(s,n)}}}var xe="!";function wr(e){let{separator:r,experimentalParseClassName:t}=e,o=r.length===1,a=r[0],s=r.length;function n(i){let c=[],f=0,u=0,g;for(let m=0;m<i.length;m++){let h=i[m];if(f===0){if(h===a&&(o||i.slice(m,m+s)===r)){c.push(i.slice(u,m)),u=m+s;continue}if(h==="/"){g=m;continue}}h==="["?f++:h==="]"&&f--}let b=c.length===0?i:i.substring(u),x=b.startsWith(xe),w=x?b.substring(1):b,y=g&&g>u?g-u:void 0;return{modifiers:c,hasImportantModifier:x,baseClassName:w,maybePostfixModifierPosition:y}}return t?function(c){return t({className:c,parseClassName:n})}:n}function Ar(e){if(e.length<=1)return e;let r=[],t=[];return e.forEach(o=>{o[0]==="["?(r.push(...t.sort(),o),t=[]):t.push(o)}),r.push(...t.sort()),r}function kr(e){return{cache:vr(e.cacheSize),parseClassName:wr(e),...gr(e)}}var Er=/\s+/;function _r(e,r){let{parseClassName:t,getClassGroupId:o,getConflictingClassGroupIds:a}=r,s=new Set;return e.trim().split(Er).map(n=>{let{modifiers:i,hasImportantModifier:c,baseClassName:f,maybePostfixModifierPosition:u}=t(n),g=Boolean(u),b=o(g?f.substring(0,u):f);if(!b){if(!g)return{isTailwindClass:!1,originalClassName:n};if(b=o(f),!b)return{isTailwindClass:!1,originalClassName:n};g=!1}let x=Ar(i).join(":"),w=c?x+xe:x;return{isTailwindClass:!0,modifierId:w,classGroupId:b,originalClassName:n,hasPostfixModifier:g}}).reverse().filter(n=>{if(!n.isTailwindClass)return!0;let{modifierId:i,classGroupId:c,hasPostfixModifier:f}=n,u=i+c;return s.has(u)?!1:(s.add(u),a(c,f).forEach(g=>s.add(i+g)),!0)}).reverse().map(n=>n.originalClassName).join(" ")}function Pr(){let e=0,r,t,o="";for(;e<arguments.length;)(r=arguments[e++])&&(t=ve(r))&&(o&&(o+=" "),o+=t);return o}function ve(e){if(typeof e=="string")return e;let r,t="";for(let o=0;o<e.length;o++)e[o]&&(r=ve(e[o]))&&(t&&(t+=" "),t+=r);return t}function Sr(e,...r){let t,o,a,s=n;function n(c){let f=r.reduce((u,g)=>g(u),e());return t=kr(f),o=t.cache.get,a=t.cache.set,s=i,i(c)}function i(c){let f=o(c);if(f)return f;let u=_r(c,t);return a(c,u),u}return function(){return s(Pr.apply(null,arguments))}}function d(e){let r=t=>t[e]||[];return r.isThemeGetter=!0,r}var we=/^\[(?:([a-z-]+):)?(.+)\]$/i,Ir=/^\d+\/\d+$/,Or=new Set(["px","full","screen"]),Tr=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,Lr=/\d+(%|px|r?em|[sdl]?v([hwib]|min|max)|pt|pc|in|cm|mm|cap|ch|ex|r?lh|cq(w|h|i|b|min|max))|\b(calc|min|max|clamp)\(.+\)|^0$/,Nr=/^(rgba?|hsla?|hwb|(ok)?(lab|lch))\(.+\)$/,Cr=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,Rr=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/;function A(e){return P(e)||Or.has(e)||Ir.test(e)}function k(e){return L(e,"length",$r)}function P(e){return Boolean(e)&&!Number.isNaN(Number(e))}function j(e){return L(e,"number",P)}function M(e){return Boolean(e)&&Number.isInteger(Number(e))}function Ur(e){return e.endsWith("%")&&P(e.slice(0,-1))}function l(e){return we.test(e)}function E(e){return Tr.test(e)}var Mr=new Set(["length","size","percentage"]);function Dr(e){return L(e,Mr,Ae)}function zr(e){return L(e,"position",Ae)}var Br=new Set(["image","url"]);function Gr(e){return L(e,Br,jr)}function Vr(e){return L(e,"",Jr)}function D(){return!0}function L(e,r,t){let o=we.exec(e);return o?o[1]?typeof r=="string"?o[1]===r:r.has(o[1]):t(o[2]):!1}function $r(e){return Lr.test(e)&&!Nr.test(e)}function Ae(){return!1}function Jr(e){return Cr.test(e)}function jr(e){return Rr.test(e)}function Fr(){let e=d("colors"),r=d("spacing"),t=d("blur"),o=d("brightness"),a=d("borderColor"),s=d("borderRadius"),n=d("borderSpacing"),i=d("borderWidth"),c=d("contrast"),f=d("grayscale"),u=d("hueRotate"),g=d("invert"),b=d("gap"),x=d("gradientColorStops"),w=d("gradientColorStopPositions"),y=d("inset"),m=d("margin"),h=d("opacity"),v=d("padding"),N=d("saturate"),C=d("scale"),Q=d("sepia"),ee=d("skew"),re=d("space"),te=d("translate"),F=()=>["auto","contain","none"],q=()=>["auto","hidden","clip","visible","scroll"],W=()=>["auto",l,r],p=()=>[l,r],oe=()=>["",A,k],z=()=>["auto",P,l],ae=()=>["bottom","center","left","left-bottom","left-top","right","right-bottom","right-top","top"],B=()=>["solid","dashed","dotted","double","none"],se=()=>["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity"],Y=()=>["start","end","center","between","around","evenly","stretch"],R=()=>["","0",l],ne=()=>["auto","avoid","all","avoid-page","page","left","right","column"],U=()=>[P,j],G=()=>[P,l];return{cacheSize:500,separator:":",theme:{colors:[D],spacing:[A,k],blur:["none","",E,l],brightness:U(),borderColor:[e],borderRadius:["none","","full",E,l],borderSpacing:p(),borderWidth:oe(),contrast:U(),grayscale:R(),hueRotate:G(),invert:R(),gap:p(),gradientColorStops:[e],gradientColorStopPositions:[Ur,k],inset:W(),margin:W(),opacity:U(),padding:p(),saturate:U(),scale:U(),sepia:R(),skew:G(),space:p(),translate:p()},classGroups:{aspect:[{aspect:["auto","square","video",l]}],container:["container"],columns:[{columns:[E]}],"break-after":[{"break-after":ne()}],"break-before":[{"break-before":ne()}],"break-inside":[{"break-inside":["auto","avoid","avoid-page","avoid-column"]}],"box-decoration":[{"box-decoration":["slice","clone"]}],box:[{box:["border","content"]}],display:["block","inline-block","inline","flex","inline-flex","table","inline-table","table-caption","table-cell","table-column","table-column-group","table-footer-group","table-header-group","table-row-group","table-row","flow-root","grid","inline-grid","contents","list-item","hidden"],float:[{float:["right","left","none","start","end"]}],clear:[{clear:["left","right","both","none","start","end"]}],isolation:["isolate","isolation-auto"],"object-fit":[{object:["contain","cover","fill","none","scale-down"]}],"object-position":[{object:[...ae(),l]}],overflow:[{overflow:q()}],"overflow-x":[{"overflow-x":q()}],"overflow-y":[{"overflow-y":q()}],overscroll:[{overscroll:F()}],"overscroll-x":[{"overscroll-x":F()}],"overscroll-y":[{"overscroll-y":F()}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:[y]}],"inset-x":[{"inset-x":[y]}],"inset-y":[{"inset-y":[y]}],start:[{start:[y]}],end:[{end:[y]}],top:[{top:[y]}],right:[{right:[y]}],bottom:[{bottom:[y]}],left:[{left:[y]}],visibility:["visible","invisible","collapse"],z:[{z:["auto",M,l]}],basis:[{basis:W()}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["wrap","wrap-reverse","nowrap"]}],flex:[{flex:["1","auto","initial","none",l]}],grow:[{grow:R()}],shrink:[{shrink:R()}],order:[{order:["first","last","none",M,l]}],"grid-cols":[{"grid-cols":[D]}],"col-start-end":[{col:["auto",{span:["full",M,l]},l]}],"col-start":[{"col-start":z()}],"col-end":[{"col-end":z()}],"grid-rows":[{"grid-rows":[D]}],"row-start-end":[{row:["auto",{span:[M,l]},l]}],"row-start":[{"row-start":z()}],"row-end":[{"row-end":z()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":["auto","min","max","fr",l]}],"auto-rows":[{"auto-rows":["auto","min","max","fr",l]}],gap:[{gap:[b]}],"gap-x":[{"gap-x":[b]}],"gap-y":[{"gap-y":[b]}],"justify-content":[{justify:["normal",...Y()]}],"justify-items":[{"justify-items":["start","end","center","stretch"]}],"justify-self":[{"justify-self":["auto","start","end","center","stretch"]}],"align-content":[{content:["normal",...Y(),"baseline"]}],"align-items":[{items:["start","end","center","baseline","stretch"]}],"align-self":[{self:["auto","start","end","center","stretch","baseline"]}],"place-content":[{"place-content":[...Y(),"baseline"]}],"place-items":[{"place-items":["start","end","center","baseline","stretch"]}],"place-self":[{"place-self":["auto","start","end","center","stretch"]}],p:[{p:[v]}],px:[{px:[v]}],py:[{py:[v]}],ps:[{ps:[v]}],pe:[{pe:[v]}],pt:[{pt:[v]}],pr:[{pr:[v]}],pb:[{pb:[v]}],pl:[{pl:[v]}],m:[{m:[m]}],mx:[{mx:[m]}],my:[{my:[m]}],ms:[{ms:[m]}],me:[{me:[m]}],mt:[{mt:[m]}],mr:[{mr:[m]}],mb:[{mb:[m]}],ml:[{ml:[m]}],"space-x":[{"space-x":[re]}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":[re]}],"space-y-reverse":["space-y-reverse"],w:[{w:["auto","min","max","fit","svw","lvw","dvw",l,r]}],"min-w":[{"min-w":[l,r,"min","max","fit"]}],"max-w":[{"max-w":[l,r,"none","full","min","max","fit","prose",{screen:[E]},E]}],h:[{h:[l,r,"auto","min","max","fit","svh","lvh","dvh"]}],"min-h":[{"min-h":[l,r,"min","max","fit","svh","lvh","dvh"]}],"max-h":[{"max-h":[l,r,"min","max","fit","svh","lvh","dvh"]}],size:[{size:[l,r,"auto","min","max","fit"]}],"font-size":[{text:["base",E,k]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:["thin","extralight","light","normal","medium","semibold","bold","extrabold","black",j]}],"font-family":[{font:[D]}],"fvn-normal":["normal-nums"],"fvn-ordinal":["ordinal"],"fvn-slashed-zero":["slashed-zero"],"fvn-figure":["lining-nums","oldstyle-nums"],"fvn-spacing":["proportional-nums","tabular-nums"],"fvn-fraction":["diagonal-fractions","stacked-fractons"],tracking:[{tracking:["tighter","tight","normal","wide","wider","widest",l]}],"line-clamp":[{"line-clamp":["none",P,j]}],leading:[{leading:["none","tight","snug","normal","relaxed","loose",A,l]}],"list-image":[{"list-image":["none",l]}],"list-style-type":[{list:["none","disc","decimal",l]}],"list-style-position":[{list:["inside","outside"]}],"placeholder-color":[{placeholder:[e]}],"placeholder-opacity":[{"placeholder-opacity":[h]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"text-color":[{text:[e]}],"text-opacity":[{"text-opacity":[h]}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:[...B(),"wavy"]}],"text-decoration-thickness":[{decoration:["auto","from-font",A,k]}],"underline-offset":[{"underline-offset":["auto",A,l]}],"text-decoration-color":[{decoration:[e]}],"text-transform":["uppercase","lowercase","capitalize","normal-case"],"text-overflow":["truncate","text-ellipsis","text-clip"],"text-wrap":[{text:["wrap","nowrap","balance","pretty"]}],indent:[{indent:p()}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",l]}],whitespace:[{whitespace:["normal","nowrap","pre","pre-line","pre-wrap","break-spaces"]}],break:[{break:["normal","words","all","keep"]}],hyphens:[{hyphens:["none","manual","auto"]}],content:[{content:["none",l]}],"bg-attachment":[{bg:["fixed","local","scroll"]}],"bg-clip":[{"bg-clip":["border","padding","content","text"]}],"bg-opacity":[{"bg-opacity":[h]}],"bg-origin":[{"bg-origin":["border","padding","content"]}],"bg-position":[{bg:[...ae(),zr]}],"bg-repeat":[{bg:["no-repeat",{repeat:["","x","y","round","space"]}]}],"bg-size":[{bg:["auto","cover","contain",Dr]}],"bg-image":[{bg:["none",{"gradient-to":["t","tr","r","br","b","bl","l","tl"]},Gr]}],"bg-color":[{bg:[e]}],"gradient-from-pos":[{from:[w]}],"gradient-via-pos":[{via:[w]}],"gradient-to-pos":[{to:[w]}],"gradient-from":[{from:[x]}],"gradient-via":[{via:[x]}],"gradient-to":[{to:[x]}],rounded:[{rounded:[s]}],"rounded-s":[{"rounded-s":[s]}],"rounded-e":[{"rounded-e":[s]}],"rounded-t":[{"rounded-t":[s]}],"rounded-r":[{"rounded-r":[s]}],"rounded-b":[{"rounded-b":[s]}],"rounded-l":[{"rounded-l":[s]}],"rounded-ss":[{"rounded-ss":[s]}],"rounded-se":[{"rounded-se":[s]}],"rounded-ee":[{"rounded-ee":[s]}],"rounded-es":[{"rounded-es":[s]}],"rounded-tl":[{"rounded-tl":[s]}],"rounded-tr":[{"rounded-tr":[s]}],"rounded-br":[{"rounded-br":[s]}],"rounded-bl":[{"rounded-bl":[s]}],"border-w":[{border:[i]}],"border-w-x":[{"border-x":[i]}],"border-w-y":[{"border-y":[i]}],"border-w-s":[{"border-s":[i]}],"border-w-e":[{"border-e":[i]}],"border-w-t":[{"border-t":[i]}],"border-w-r":[{"border-r":[i]}],"border-w-b":[{"border-b":[i]}],"border-w-l":[{"border-l":[i]}],"border-opacity":[{"border-opacity":[h]}],"border-style":[{border:[...B(),"hidden"]}],"divide-x":[{"divide-x":[i]}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":[i]}],"divide-y-reverse":["divide-y-reverse"],"divide-opacity":[{"divide-opacity":[h]}],"divide-style":[{divide:B()}],"border-color":[{border:[a]}],"border-color-x":[{"border-x":[a]}],"border-color-y":[{"border-y":[a]}],"border-color-t":[{"border-t":[a]}],"border-color-r":[{"border-r":[a]}],"border-color-b":[{"border-b":[a]}],"border-color-l":[{"border-l":[a]}],"divide-color":[{divide:[a]}],"outline-style":[{outline:["",...B()]}],"outline-offset":[{"outline-offset":[A,l]}],"outline-w":[{outline:[A,k]}],"outline-color":[{outline:[e]}],"ring-w":[{ring:oe()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:[e]}],"ring-opacity":[{"ring-opacity":[h]}],"ring-offset-w":[{"ring-offset":[A,k]}],"ring-offset-color":[{"ring-offset":[e]}],shadow:[{shadow:["","inner","none",E,Vr]}],"shadow-color":[{shadow:[D]}],opacity:[{opacity:[h]}],"mix-blend":[{"mix-blend":[...se(),"plus-lighter","plus-darker"]}],"bg-blend":[{"bg-blend":se()}],filter:[{filter:["","none"]}],blur:[{blur:[t]}],brightness:[{brightness:[o]}],contrast:[{contrast:[c]}],"drop-shadow":[{"drop-shadow":["","none",E,l]}],grayscale:[{grayscale:[f]}],"hue-rotate":[{"hue-rotate":[u]}],invert:[{invert:[g]}],saturate:[{saturate:[N]}],sepia:[{sepia:[Q]}],"backdrop-filter":[{"backdrop-filter":["","none"]}],"backdrop-blur":[{"backdrop-blur":[t]}],"backdrop-brightness":[{"backdrop-brightness":[o]}],"backdrop-contrast":[{"backdrop-contrast":[c]}],"backdrop-grayscale":[{"backdrop-grayscale":[f]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[u]}],"backdrop-invert":[{"backdrop-invert":[g]}],"backdrop-opacity":[{"backdrop-opacity":[h]}],"backdrop-saturate":[{"backdrop-saturate":[N]}],"backdrop-sepia":[{"backdrop-sepia":[Q]}],"border-collapse":[{border:["collapse","separate"]}],"border-spacing":[{"border-spacing":[n]}],"border-spacing-x":[{"border-spacing-x":[n]}],"border-spacing-y":[{"border-spacing-y":[n]}],"table-layout":[{table:["auto","fixed"]}],caption:[{caption:["top","bottom"]}],transition:[{transition:["none","all","","colors","opacity","shadow","transform",l]}],duration:[{duration:G()}],ease:[{ease:["linear","in","out","in-out",l]}],delay:[{delay:G()}],animate:[{animate:["none","spin","ping","pulse","bounce",l]}],transform:[{transform:["","gpu","none"]}],scale:[{scale:[C]}],"scale-x":[{"scale-x":[C]}],"scale-y":[{"scale-y":[C]}],rotate:[{rotate:[M,l]}],"translate-x":[{"translate-x":[te]}],"translate-y":[{"translate-y":[te]}],"skew-x":[{"skew-x":[ee]}],"skew-y":[{"skew-y":[ee]}],"transform-origin":[{origin:["center","top","top-right","right","bottom-right","bottom","bottom-left","left","top-left",l]}],accent:[{accent:["auto",e]}],appearance:[{appearance:["none","auto"]}],cursor:[{cursor:["auto","default","pointer","wait","text","move","help","not-allowed","none","context-menu","progress","cell","crosshair","vertical-text","alias","copy","no-drop","grab","grabbing","all-scroll","col-resize","row-resize","n-resize","e-resize","s-resize","w-resize","ne-resize","nw-resize","se-resize","sw-resize","ew-resize","ns-resize","nesw-resize","nwse-resize","zoom-in","zoom-out",l]}],"caret-color":[{caret:[e]}],"pointer-events":[{"pointer-events":["none","auto"]}],resize:[{resize:["none","y","x",""]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scroll-m":[{"scroll-m":p()}],"scroll-mx":[{"scroll-mx":p()}],"scroll-my":[{"scroll-my":p()}],"scroll-ms":[{"scroll-ms":p()}],"scroll-me":[{"scroll-me":p()}],"scroll-mt":[{"scroll-mt":p()}],"scroll-mr":[{"scroll-mr":p()}],"scroll-mb":[{"scroll-mb":p()}],"scroll-ml":[{"scroll-ml":p()}],"scroll-p":[{"scroll-p":p()}],"scroll-px":[{"scroll-px":p()}],"scroll-py":[{"scroll-py":p()}],"scroll-ps":[{"scroll-ps":p()}],"scroll-pe":[{"scroll-pe":p()}],"scroll-pt":[{"scroll-pt":p()}],"scroll-pr":[{"scroll-pr":p()}],"scroll-pb":[{"scroll-pb":p()}],"scroll-pl":[{"scroll-pl":p()}],"snap-align":[{snap:["start","end","center","align-none"]}],"snap-stop":[{snap:["normal","always"]}],"snap-type":[{snap:["none","x","y","both"]}],"snap-strictness":[{snap:["mandatory","proximity"]}],touch:[{touch:["auto","none","manipulation"]}],"touch-x":[{"touch-pan":["x","left","right"]}],"touch-y":[{"touch-pan":["y","up","down"]}],"touch-pz":["touch-pinch-zoom"],select:[{select:["none","text","all","auto"]}],"will-change":[{"will-change":["auto","scroll","contents","transform",l]}],fill:[{fill:[e,"none"]}],"stroke-w":[{stroke:[A,k,j]}],stroke:[{stroke:[e,"none"]}],sr:["sr-only","not-sr-only"],"forced-color-adjust":[{"forced-color-adjust":["auto","none"]}]},conflictingClassGroups:{overflow:["overflow-x","overflow-y"],overscroll:["overscroll-x","overscroll-y"],inset:["inset-x","inset-y","start","end","top","right","bottom","left"],"inset-x":["right","left"],"inset-y":["top","bottom"],flex:["basis","grow","shrink"],gap:["gap-x","gap-y"],p:["px","py","ps","pe","pt","pr","pb","pl"],px:["pr","pl"],py:["pt","pb"],m:["mx","my","ms","me","mt","mr","mb","ml"],mx:["mr","ml"],my:["mt","mb"],size:["w","h"],"font-size":["leading"],"fvn-normal":["fvn-ordinal","fvn-slashed-zero","fvn-figure","fvn-spacing","fvn-fraction"],"fvn-ordinal":["fvn-normal"],"fvn-slashed-zero":["fvn-normal"],"fvn-figure":["fvn-normal"],"fvn-spacing":["fvn-normal"],"fvn-fraction":["fvn-normal"],"line-clamp":["display","overflow"],rounded:["rounded-s","rounded-e","rounded-t","rounded-r","rounded-b","rounded-l","rounded-ss","rounded-se","rounded-ee","rounded-es","rounded-tl","rounded-tr","rounded-br","rounded-bl"],"rounded-s":["rounded-ss","rounded-es"],"rounded-e":["rounded-se","rounded-ee"],"rounded-t":["rounded-tl","rounded-tr"],"rounded-r":["rounded-tr","rounded-br"],"rounded-b":["rounded-br","rounded-bl"],"rounded-l":["rounded-tl","rounded-bl"],"border-spacing":["border-spacing-x","border-spacing-y"],"border-w":["border-w-s","border-w-e","border-w-t","border-w-r","border-w-b","border-w-l"],"border-w-x":["border-w-r","border-w-l"],"border-w-y":["border-w-t","border-w-b"],"border-color":["border-color-t","border-color-r","border-color-b","border-color-l"],"border-color-x":["border-color-r","border-color-l"],"border-color-y":["border-color-t","border-color-b"],"scroll-m":["scroll-mx","scroll-my","scroll-ms","scroll-me","scroll-mt","scroll-mr","scroll-mb","scroll-ml"],"scroll-mx":["scroll-mr","scroll-ml"],"scroll-my":["scroll-mt","scroll-mb"],"scroll-p":["scroll-px","scroll-py","scroll-ps","scroll-pe","scroll-pt","scroll-pr","scroll-pb","scroll-pl"],"scroll-px":["scroll-pr","scroll-pl"],"scroll-py":["scroll-pt","scroll-pb"],touch:["touch-x","touch-y","touch-pz"],"touch-x":["touch"],"touch-y":["touch"],"touch-pz":["touch"]},conflictingClassGroupModifiers:{"font-size":["leading"]}}}var ke=Sr(Fr);function qr(...e){return ke(ge(e))}var Wr=(e,r)=>!e||e.length<=r?e??null:`${e.slice(0,r-3)}...`;export{Ne as a,Ce as b,Be as c,We as d,Ye as e,X as f,Ze as g,ar as h,sr as i,Wr as j,nr as k,pr as l,mr as m,me as n,fr as o,qr as p};