@moontra/moonui-pro 3.4.36 → 3.4.37
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.
package/dist/cdn/index.global.js
CHANGED
|
@@ -220,7 +220,7 @@ Defaulting to \`null\`.`}var b7=gwe,xwe=ywe;var x7=_(ue(),1),bo=wwe.forwardRef((
|
|
|
220
220
|
transparent 10px,
|
|
221
221
|
${t}10 10px,
|
|
222
222
|
${t}10 20px
|
|
223
|
-
)`};case"hexagon":return{backgroundImage:`url("data:image/svg+xml,%3Csvg width='40' height='40' viewBox='0 0 40 40' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M20 0l8.66 5v10l-8.66 5-8.66-5V5z' fill='none' stroke='%23${t.replace("#","")}' stroke-opacity='0.1'/%3E%3C/svg%3E")`,backgroundSize:"40px 40px"};case"circuit":return{backgroundImage:`url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M30 10v10m0 10v10m-10-20h10m10 0h10' stroke='%23${t.replace("#","")}' stroke-opacity='0.1' fill='none' stroke-width='2'/%3E%3C/svg%3E")`,backgroundSize:"60px 60px"};default:return{}}},FSe=(0,wc.forwardRef)(({children:e,className:t,variant:r,intensity:n,size:o,glowColor:a="#3b82f6",gradient:i=!1,gradientColors:s=["#3b82f6","#8b5cf6","#ec4899"],gradientAngle:l=45,animationPreset:c="none",animationDuration:u=2,glowLayers:d=[],backdropBlur:f=!1,blurAmount:p=12,pattern:m="none",mouseTrack:h=!1,mouseRadius:g=150,tilt:v=!1,tiltAngle:y=15,theme:b="auto",disableAnimations:w=!1,cssVars:x={},containerProps:C={},style:P,onMouseMove:R,onMouseLeave:L,...U},A)=>{let[I,j]=(0,wc.useState)({x:0,y:0}),[$,S]=(0,wc.useState)(!1),[k,N]=(0,wc.useState)({}),T=(0,wc.useRef)(null),B=V=>{T.current=V,A&&(typeof A=="function"?A(V):A.current=V)},D=V=>{if(!T.current)return;let O=T.current.getBoundingClientRect(),Y=V.clientX-O.left,re=V.clientY-O.top;if(h&&j({x:Y,y:re}),v&&!w){let Q=O.width/2,ae=O.height/2,te=(re-ae)/ae*y,se=(Y-Q)/Q*-y;N({transform:`perspective(1000px) rotateX(${te}deg) rotateY(${se}deg) scale3d(1.02, 1.02, 1.02)`,transformStyle:"preserve-3d"})}R?.(V)},z=V=>{S(!1),v&&N({transform:"perspective(1000px) rotateX(0deg) rotateY(0deg) scale3d(1, 1, 1)",transformStyle:"preserve-3d"}),L?.(V)},M=(0,wc.useMemo)(()=>{if(!i)return{};let V=s.join(", ");return{background:`linear-gradient(${l}deg, ${V})`}},[i,s,l]),G=(0,wc.useMemo)(()=>d.length===0?"":d.map(V=>{let O=V.inset?"inset ":"",Y=V.blur||V.size;return`${O}0 0 ${Y}px ${V.size}px ${V.color}`}).join(", "),[d]),q=(0,wc.useMemo)(()=>!h||!$?{}:{background:`radial-gradient(circle at ${I.x}px ${I.y}px, ${a}40 0%, transparent ${g}px)`},[h,$,I,g,a]),H=(0,wc.useMemo)(()=>b==="dark"?.7:b==="light"?.3:"auto",[b]),F=(0,wc.useMemo)(()=>w||c==="none"?{}:{animationDuration:`${u}s`},[w,c,u]),W=(0,wc.useMemo)(()=>G||Rlt(r,n,o,a,$),[r,n,o,a,$,G]);return(0,rb.jsxs)("div",{...C,className:E("glow-card-container relative",C.className),style:{...C.style,...x},children:[m!=="none"&&(0,rb.jsx)("div",{className:"absolute inset-0 opacity-10 pointer-events-none rounded-inherit",style:Mlt(m,a),"aria-hidden":"true"}),h&&(0,rb.jsx)("div",{className:"absolute inset-0 opacity-50 transition-opacity duration-300 pointer-events-none rounded-inherit",style:q,"aria-hidden":"true"}),(0,rb.jsx)("div",{ref:B,className:E(klt({variant:r,intensity:n,size:o}),!w&&Nlt[c],f&&"backdrop-blur-md","glow-card relative overflow-hidden rounded-lg transition-all duration-300",t),style:{...P,...M,...F,...v&&!w?k:{},boxShadow:W,willChange:"transform, box-shadow",transform:"translateZ(0)"},onMouseMove:D,onMouseEnter:()=>S(!0),onMouseLeave:z,...U,children:e})]})});FSe.displayName="GlowCard";var IK=(0,wc.forwardRef)((e,t)=>{let{hasProAccess:r,isLoading:n}=Ee();return!n&&!r?(0,rb.jsx)(Ve,{componentName:"GlowCard",compact:!0,className:"inline-block"}):(0,rb.jsx)(FSe,{ref:t,...e})});IK.displayName="GlowCard";var Cm=_(ye(),1);var fo=_(ue(),1),LK=gt("relative inline-flex items-center justify-center whitespace-nowrap rounded-md text-sm font-medium transition-all duration-200 focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring disabled:pointer-events-none disabled:opacity-50 overflow-hidden min-w-fit",{variants:{variant:{default:"bg-primary text-primary-foreground shadow hover:bg-primary/90",destructive:"bg-destructive text-destructive-foreground shadow-sm hover:bg-destructive/90",outline:"border border-input bg-background shadow-sm hover:bg-accent hover:text-accent-foreground",secondary:"bg-secondary text-secondary-foreground shadow-sm hover:bg-secondary/80",ghost:"hover:bg-accent hover:text-accent-foreground",link:"text-primary underline-offset-4 hover:underline",gradient:"bg-gradient-to-r from-purple-600 to-pink-600 text-white hover:from-purple-700 hover:to-pink-700",glow:"bg-primary text-primary-foreground shadow-lg hover:shadow-xl hover:shadow-primary/25"},size:{default:"h-9 px-4 py-2",sm:"h-8 rounded-md px-3 text-xs",lg:"h-10 rounded-md px-8",xl:"h-11 rounded-md px-6 text-base font-medium",icon:"h-9 w-9"}},defaultVariants:{variant:"default",size:"default"}}),BSe=Cm.default.forwardRef(({className:e,variant:t,size:r,animation:n="none",state:o="idle",onStateChange:a,children:i,onClick:s,loadingText:l="Loading...",successText:c="Success!",errorText:u="Error!",ripple:d=!1,iconRotate:f=!1,shimmerSpeed:p="normal",glowIntensity:m="medium",showProgressBar:h=!1,autoResetDelay:g=2e3,onDrag:v,onDragEnd:y,onDragStart:b,onAnimationStart:w,onAnimationEnd:x,...C},P)=>{let[R,L]=(0,Cm.useState)("idle"),[U,A]=(0,Cm.useState)([]),[I,j]=(0,Cm.useState)(0),[$,S]=(0,Cm.useState)(!1),k=o!=="idle"?o:R,N=async q=>{if(k!=="loading"){if(d){let H=q.currentTarget.getBoundingClientRect(),F=q.clientX-H.left,W=q.clientY-H.top,V=Date.now();A([...U,{x:F,y:W,id:V}]),setTimeout(()=>{A(O=>O.filter(Y=>Y.id!==V))},600)}if(L("loading"),a?.("loading"),j(0),h){let H=setInterval(()=>{j(F=>F>=90?(clearInterval(H),90):F+10)},200)}if(s)try{await s(q),j(100),L("success"),a?.("success"),setTimeout(()=>{L("idle"),a?.("idle"),j(0)},g)}catch{j(0),L("error"),a?.("error"),setTimeout(()=>{L("idle"),a?.("idle")},g)}}},T=()=>{let q=E("h-4 w-4",{"animate-spin":k==="loading"||f&&k!=="idle"});switch(k){case"loading":return(0,fo.jsx)(kr,{className:q});case"success":return(0,fo.jsx)(Qr,{className:E(q,"animate-scale-in")});case"error":return(0,fo.jsx)(fr,{className:E(q,"animate-shake")});default:return null}},B=()=>{switch(k){case"success":return"bg-green-600";case"error":return"bg-red-600";default:return""}},D=()=>{switch(p){case"slow":return"duration-1500";case"fast":return"duration-500";default:return"duration-1000"}},z=()=>{switch(m){case"low":return"shadow-lg";case"high":return"shadow-2xl";default:return"shadow-xl"}},M,G;return n==="bounce"?M={y:[0,-10,0],transition:{duration:.6,repeat:1/0,repeatType:"loop"}}:n==="pulse"?M={scale:[1,1.1,1],transition:{duration:1,repeat:1/0,repeatType:"loop"}}:n==="shake"?M=void 0:n==="rotate"?M={rotate:10,transition:{type:"spring",stiffness:300}}:n==="scale"?(M={scale:1.05},G={scale:.95}):n==="slide"&&(M={y:-4}),(0,fo.jsxs)(me.button,{...C,className:E(LK({variant:t,size:r}),t==="glow"&&z(),n==="shake"&&$&&"animate-shake",e),ref:P,onClick:N,disabled:k==="loading"||C.disabled,onMouseEnter:()=>S(!0),onMouseLeave:()=>S(!1),whileHover:M,whileTap:G,children:[h&&k==="loading"&&(0,fo.jsx)(me.div,{className:"absolute bottom-0 left-0 h-1 bg-primary-foreground/20 rounded-full",initial:{width:0},animate:{width:`${I}%`},transition:{duration:.3}}),n==="shimmer"&&(0,fo.jsx)(me.div,{className:"absolute inset-0 bg-gradient-to-r from-transparent via-white/20 to-transparent",initial:{x:"-100%"},animate:{x:"100%"},transition:{duration:p==="slow"?1.5:p==="fast"?.5:1,repeat:1/0,repeatDelay:1}}),(0,fo.jsx)("div",{className:"relative flex items-center justify-center gap-2 z-10",children:r==="icon"?k==="idle"?i:T():(0,fo.jsx)(fo.Fragment,{children:k==="idle"?(0,fo.jsxs)(fo.Fragment,{children:[Cm.default.isValidElement(i)&&Cm.default.cloneElement(i),typeof i=="string"&&i,Cm.default.isValidElement(i)||typeof i=="string"?null:i]}):(0,fo.jsxs)(fo.Fragment,{children:[T(),(0,fo.jsxs)("span",{className:"ml-2",children:[k==="loading"&&l,k==="success"&&c,k==="error"&&u]})]})})}),(0,fo.jsx)(me.div,{className:E("absolute inset-0 rounded-md",B()),initial:{scale:0,opacity:0},animate:{scale:k==="success"||k==="error"?1:0,opacity:k==="success"||k==="error"?.2:0},transition:{duration:.3},style:{zIndex:0}}),U.map(q=>(0,fo.jsx)("span",{className:"absolute bg-primary/20 rounded-full animate-ripple pointer-events-none",style:{left:q.x-10,top:q.y-10,width:20,height:20}},q.id))]})});BSe.displayName="MoonUIAnimatedButtonProInternal";var DK=Cm.default.forwardRef((e,t)=>{let{hasProAccess:r,isLoading:n}=Ee();return!n&&!r?(0,fo.jsx)(Ze,{className:E("w-fit",e.className),children:(0,fo.jsx)(tt,{className:"py-6 text-center",children:(0,fo.jsxs)("div",{className:"space-y-4",children:[(0,fo.jsx)("div",{className:"rounded-full bg-purple-100 dark:bg-purple-900/30 p-3 w-fit mx-auto",children:(0,fo.jsx)(Qt,{className:"h-6 w-6 text-purple-600 dark:text-purple-400"})}),(0,fo.jsxs)("div",{children:[(0,fo.jsx)("h3",{className:"font-semibold text-sm mb-2",children:"Pro Feature"}),(0,fo.jsx)("p",{className:"text-muted-foreground text-xs mb-4",children:"Animated Button is available exclusively to MoonUI Pro subscribers."}),(0,fo.jsx)("a",{href:"/pricing",children:(0,fo.jsxs)(xe,{size:"sm",children:[(0,fo.jsx)(jt,{className:"mr-2 h-4 w-4"}),"Upgrade to Pro"]})})]})]})})}):(0,fo.jsx)(BSe,{...e,ref:t})});DK.displayName="MoonUIAnimatedButtonPro";var Sm=_(ye(),1);var Ba=_(ue(),1),Elt=({children:e,delay:t=0,index:r,onMouseEnter:n,onClick:o})=>{let a=(0,Sm.useRef)(null),i=bx(a,{amount:.5,once:!1});return(0,Ba.jsx)(me.div,{ref:a,"data-index":r,onMouseEnter:n,onClick:o,initial:{scale:.7,opacity:0},animate:i?{scale:1,opacity:1}:{scale:.7,opacity:0},transition:{duration:.2,delay:t},className:"mb-4 cursor-pointer",children:e})},Tlt=({items:e=["Item 1","Item 2","Item 3","Item 4","Item 5","Item 6","Item 7","Item 8","Item 9","Item 10","Item 11","Item 12","Item 13","Item 14","Item 15"],onItemSelect:t,showGradients:r=!0,enableArrowNavigation:n=!0,className:o="",itemClassName:a="",displayScrollbar:i=!0,initialSelectedIndex:s=-1})=>{let l=(0,Sm.useRef)(null),[c,u]=(0,Sm.useState)(s),[d,f]=(0,Sm.useState)(!1),[p,m]=(0,Sm.useState)(0),[h,g]=(0,Sm.useState)(1),v=y=>{let{scrollTop:b,scrollHeight:w,clientHeight:x}=y.target;m(Math.min(b/50,1));let C=w-(b+x);g(w<=x?0:Math.min(C/50,1))};return(0,Sm.useEffect)(()=>{if(!n)return;let y=b=>{b.key==="ArrowDown"||b.key==="Tab"&&!b.shiftKey?(b.preventDefault(),f(!0),u(w=>Math.min(w+1,e.length-1))):b.key==="ArrowUp"||b.key==="Tab"&&b.shiftKey?(b.preventDefault(),f(!0),u(w=>Math.max(w-1,0))):b.key==="Enter"&&c>=0&&c<e.length&&(b.preventDefault(),t&&t(e[c],c))};return window.addEventListener("keydown",y),()=>window.removeEventListener("keydown",y)},[e,c,t,n]),(0,Sm.useEffect)(()=>{if(!d||c<0||!l.current)return;let y=l.current,b=y.querySelector(`[data-index="${c}"]`);if(b){let x=y.scrollTop,C=y.clientHeight,P=b.offsetTop,R=P+b.offsetHeight;P<x+50?y.scrollTo({top:P-50,behavior:"smooth"}):R>x+C-50&&y.scrollTo({top:R-C+50,behavior:"smooth"})}f(!1)},[c,d]),(0,Ba.jsxs)("div",{className:E("relative w-[500px]",o),children:[(0,Ba.jsx)("div",{ref:l,className:E("max-h-[400px] overflow-y-auto p-4",i?"[&::-webkit-scrollbar]:w-[8px] [&::-webkit-scrollbar-track]:bg-background [&::-webkit-scrollbar-thumb]:bg-border [&::-webkit-scrollbar-thumb]:rounded-[4px] [&::-webkit-scrollbar-thumb]:hover:bg-muted-foreground/50":"scrollbar-hide"),onScroll:v,style:{scrollbarWidth:i?"thin":"none",scrollbarColor:i?"hsl(var(--border)) hsl(var(--background))":"transparent"},children:e.map((y,b)=>(0,Ba.jsx)(Elt,{delay:.1,index:b,onMouseEnter:()=>u(b),onClick:()=>{u(b),t&&t(y,b)},children:(0,Ba.jsx)("div",{className:E("p-4 bg-card border rounded-lg transition-colors duration-200 hover:bg-accent/50",c===b?"bg-accent border-accent-foreground/20":"border-border",a),children:(0,Ba.jsx)("p",{className:"text-foreground m-0 text-sm",children:y})})},b))}),r&&(0,Ba.jsxs)(Ba.Fragment,{children:[(0,Ba.jsx)("div",{className:"absolute top-0 left-0 right-0 h-[50px] bg-gradient-to-b from-background to-transparent pointer-events-none transition-opacity duration-300 ease",style:{opacity:p}}),(0,Ba.jsx)("div",{className:"absolute bottom-0 left-0 right-0 h-[100px] bg-gradient-to-t from-background to-transparent pointer-events-none transition-opacity duration-300 ease",style:{opacity:h}})]})]})},Z3=e=>{let{hasProAccess:t,isLoading:r}=Ee();return!r&&!t?(0,Ba.jsx)(Ze,{className:E("w-fit",e.className),children:(0,Ba.jsx)(tt,{className:"py-6 text-center",children:(0,Ba.jsxs)("div",{className:"space-y-4",children:[(0,Ba.jsx)("div",{className:"rounded-full bg-purple-100 dark:bg-purple-900/30 p-3 w-fit mx-auto",children:(0,Ba.jsx)(Qt,{className:"h-6 w-6 text-purple-600 dark:text-purple-400"})}),(0,Ba.jsxs)("div",{children:[(0,Ba.jsx)("h3",{className:"font-semibold text-sm mb-2",children:"Pro \xD6zellik"}),(0,Ba.jsx)("p",{className:"text-muted-foreground text-xs mb-4",children:"Animated List sadece MoonUI Pro abonelerine \xF6zeldir."}),(0,Ba.jsx)("a",{href:"/pricing",children:(0,Ba.jsxs)(xe,{size:"sm",children:[(0,Ba.jsx)(jt,{className:"mr-2 h-4 w-4"}),"Pro'ya Y\xFCkselt"]})})]})]})})}):(0,Ba.jsx)(Tlt,{...e})};Z3.displayName="MoonUIAnimatedListPro";var Cc=_(ye(),1);var jw=_(ue(),1);var aI={primary:"hsl(var(--primary) / 0.25)",secondary:"hsl(var(--secondary) / 0.25)",accent:"hsl(var(--accent) / 0.25)",destructive:"hsl(var(--destructive) / 0.25)",muted:"hsl(var(--muted-foreground) / 0.15)",white:"rgba(255, 255, 255, 0.25)",blue:"rgba(59, 130, 246, 0.25)",purple:"rgba(147, 51, 234, 0.25)",green:"rgba(34, 197, 94, 0.25)",orange:"rgba(249, 115, 22, 0.25)",red:"rgba(239, 68, 68, 0.25)",yellow:"rgba(234, 179, 8, 0.25)",pink:"rgba(236, 72, 153, 0.25)",cyan:"rgba(6, 182, 212, 0.25)"},zSe=Cc.default.forwardRef(({children:e,className:t,spotlightColor:r="primary",spotlightSize:n=200,intensity:o=.6,duration:a=500,rounded:i="lg",borderClass:s,backgroundClass:l,borderGlow:c=!1,disabled:u=!1,locked:d=!1,...f},p)=>{let m=(0,Cc.useRef)(null),[h,g]=(0,Cc.useState)(!1),[v,y]=(0,Cc.useState)({x:0,y:0}),[b,w]=(0,Cc.useState)(0),x=Cc.default.useMemo(()=>typeof r=="string"&&r in aI?aI[r]:r,[r]),C=(0,Cc.useCallback)(I=>{if(!m.current||h||u)return;let j=m.current.getBoundingClientRect();y({x:I.clientX-j.left,y:I.clientY-j.top})},[h,u]),P=(0,Cc.useCallback)(()=>{u||(g(!0),w(o))},[u,o]),R=(0,Cc.useCallback)(()=>{g(!1),w(0)},[]),L=(0,Cc.useCallback)(()=>{u||w(o)},[u,o]),U=(0,Cc.useCallback)(()=>{w(0)},[]),A={none:"",sm:"rounded-sm",md:"rounded-md",lg:"rounded-lg",xl:"rounded-xl","2xl":"rounded-2xl","3xl":"rounded-3xl",full:"rounded-full"};return d?(0,jw.jsx)(Ve,{componentName:"SpotlightCard Pro",className:E("min-h-[200px]",t)}):(0,jw.jsxs)("div",{ref:I=>{m.current=I,typeof p=="function"?p(I):p&&(p.current=I)},onMouseMove:C,onFocus:P,onBlur:R,onMouseEnter:L,onMouseLeave:U,className:E("relative overflow-hidden",A[i],s||"border border-border",l||"bg-card","transition-all duration-200",u&&"cursor-not-allowed opacity-50",t),...f,children:[(0,jw.jsx)("div",{className:E("pointer-events-none absolute","transition-all ease-in-out",c&&"border-2 border-white/20",u&&"hidden"),style:{opacity:b,left:`${v.x}px`,top:`${v.y}px`,width:`${n*2}px`,height:`${n*2}px`,transform:"translate(-50%, -50%)",background:`radial-gradient(circle, ${x}, transparent 80%)`,transitionDuration:`${a}ms`,transitionProperty:"opacity, left, top",boxShadow:c?`0 0 20px ${x}`:void 0}}),(0,jw.jsx)("div",{className:"relative z-10",children:e})]})});zSe.displayName="SpotlightCardInternal";var OK=Cc.default.forwardRef((e,t)=>(0,jw.jsx)(zSe,{...e,ref:t}));OK.displayName="MoonUISpotlightCardPro";var fp=_(ye(),1);var e4=_(ue(),1),Alt=gt("font-mono tabular-nums",{variants:{size:{sm:"text-sm",md:"text-base",lg:"text-lg",xl:"text-xl","2xl":"text-2xl","3xl":"text-3xl","4xl":"text-4xl"},variant:{default:"text-foreground",primary:"text-primary",secondary:"text-muted-foreground",success:"text-green-600 dark:text-green-400",warning:"text-orange-600 dark:text-orange-400",destructive:"text-red-600 dark:text-red-400"}},defaultVariants:{size:"md",variant:"default"}}),USe=fp.default.forwardRef(({className:e,value:t,from:r=0,duration:n=2,decimalPlaces:o=0,format:a="number",currency:i="TRY",locale:s="tr-TR",prefix:l="",suffix:c="",triggerOnView:u=!1,ease:d="easeOut",size:f,variant:p,onComplete:m,...h},g)=>{let[v,y]=(0,fp.useState)(!u),b=(0,fp.useRef)(null),w=bx(b,{once:!0}),x=aa(r),C=Hp(x,{duration:n*1e3,bounce:d==="spring"?.4:0}),[P,R]=(0,fp.useState)(r),L=U=>{let A;switch(a){case"currency":A=new Intl.NumberFormat(s,{style:"currency",currency:i,minimumFractionDigits:o,maximumFractionDigits:o}).format(U);break;case"percent":A=new Intl.NumberFormat(s,{style:"percent",minimumFractionDigits:o,maximumFractionDigits:o}).format(U/100);break;default:A=new Intl.NumberFormat(s,{minimumFractionDigits:o,maximumFractionDigits:o}).format(U)}return`${l}${A}${c}`};return(0,fp.useEffect)(()=>{u&&w&&y(!0)},[u,w]),(0,fp.useEffect)(()=>{v&&x.set(t)},[v,t,x]),(0,fp.useEffect)(()=>{let U=C.on("change",I=>{R(I)}),A=C.on("animationComplete",()=>{m?.()});return()=>{U(),A()}},[C,m]),(0,e4.jsx)(me.div,{ref:b,className:E(Alt({size:f,variant:p,className:e})),initial:{opacity:0,scale:.5},animate:v?{opacity:1,scale:1}:{opacity:0,scale:.5},transition:{duration:.5,ease:d==="spring"?"easeOut":d},children:L(P)})});USe.displayName="AnimatedNumberInternal";var t4=fp.default.forwardRef((e,t)=>{let{hasProAccess:r,isLoading:n}=Ee();return!n&&!r?(0,e4.jsx)(Ve,{componentName:"Animated Number",compact:!0,className:"inline-block"}):(0,e4.jsx)(USe,{...e,ref:t})});t4.displayName="AnimatedNumber";var uu=_(ye(),1);var Gl=_(ue(),1),VSe=gt("flex items-center gap-1 rounded-full border bg-background/95 backdrop-blur-md shadow-xl",{variants:{size:{sm:"p-1",md:"p-1.5",lg:"p-2"},position:{bottom:"flex-row",top:"flex-row",left:"flex-col",right:"flex-col"}},defaultVariants:{size:"md",position:"bottom"}}),rAr=gt("flex items-center justify-center rounded-full transition-all duration-200 cursor-pointer",{variants:{size:{sm:"w-9 h-9",md:"w-11 h-11",lg:"w-13 h-13"}},defaultVariants:{size:"md"}}),$Se=uu.default.memo(({item:e,size:t,magnification:r,showTooltip:n,position:o})=>{let a=(0,uu.useRef)(null),[i,s]=(0,uu.useState)(!1),c={sm:36,md:44,lg:52}[t],u=i?r:c,d=aa(c),f=Hp(d,{stiffness:300,damping:30});return(0,uu.useEffect)(()=>{d.set(u)},[u,d]),(0,Gl.jsxs)(me.div,{ref:a,className:"relative flex items-center justify-center",onMouseEnter:()=>s(!0),onMouseLeave:()=>s(!1),children:[(0,Gl.jsx)(me.button,{style:{width:f,height:f},className:E("flex items-center justify-center rounded-full transition-colors duration-200","bg-card/80 hover:bg-card border border-border/50 shadow-sm",e.active&&"bg-primary text-primary-foreground hover:bg-primary/90 border-primary",e.className),onClick:e.onClick,whileTap:{scale:.95},children:e.icon}),(0,Gl.jsx)(Mt,{children:n&&e.label&&i&&(0,Gl.jsx)(me.div,{initial:{opacity:0,scale:.6},animate:{opacity:1,scale:1},exit:{opacity:0,scale:.6},transition:{duration:.15,ease:"easeOut"},style:{position:"absolute",...o==="bottom"&&{bottom:"calc(100% + 8px)",left:"50%",transform:"translateX(-50%)"},...o==="top"&&{top:"calc(100% + 8px)",left:"50%",transform:"translateX(-50%)"},...o==="left"&&{left:"calc(100% + 8px)",top:"50%",transform:"translateY(-50%)"},...o==="right"&&{right:"calc(100% + 8px)",top:"50%",transform:"translateY(-50%)"}},className:"px-2.5 py-1 text-xs font-medium whitespace-nowrap pointer-events-none z-50 bg-foreground text-background rounded-md shadow-lg",children:e.label})})]})}),HSe=uu.default.forwardRef(({className:e,items:t,magnification:r=64,distance:n=120,showTooltip:o=!0,animationDuration:a=500,size:i="md",position:s="bottom",containerMode:l=!1,mobileMode:c="toggle",mobileBreakpoint:u="lg",autoHideDelay:d=5e3,toggleIcon:f,toggleButtonBg:p="bg-background/95",toggleButtonBorder:m="border-border",...h},g)=>{let[v,y]=(0,uu.useState)(!1),[b,w]=(0,uu.useState)(!1),x=(0,uu.useRef)(null);(0,uu.useEffect)(()=>{let j={sm:640,md:768,lg:1024,xl:1280},$=()=>{w(window.innerWidth<j[u])};return $(),window.addEventListener("resize",$),()=>window.removeEventListener("resize",$)},[u]),(0,uu.useEffect)(()=>(v&&c==="toggle"&&b&&(x.current=setTimeout(()=>{y(!1)},d)),()=>{x.current&&clearTimeout(x.current)}),[v,d,c,b]);let C=()=>!b||c==="always"?!0:c==="hidden"?!1:c==="toggle"?v:!0,P={right:{hidden:{x:"calc(100% + 24px)",opacity:0},visible:{x:0,opacity:1}},left:{hidden:{x:"calc(-100% - 24px)",opacity:0},visible:{x:0,opacity:1}},bottom:{hidden:{y:"calc(100% + 24px)",opacity:0},visible:{y:0,opacity:1}},top:{hidden:{y:"calc(-100% - 24px)",opacity:0},visible:{y:0,opacity:1}}},R=()=>{if(l)switch(s){case"bottom":return"absolute bottom-2 left-1/2 -translate-x-1/2";case"top":return"absolute top-2 left-1/2 -translate-x-1/2";case"left":return"absolute left-2 top-1/2 -translate-y-1/2";case"right":return"absolute right-2 top-1/2 -translate-y-1/2";default:return"absolute bottom-2 left-1/2 -translate-x-1/2"}else switch(s){case"bottom":return"fixed bottom-4 left-1/2 -translate-x-1/2";case"top":return"fixed top-4 left-1/2 -translate-x-1/2";case"left":return"fixed left-4 top-1/2 -translate-y-1/2";case"right":return"fixed right-4 top-1/2 -translate-y-1/2";default:return"fixed bottom-4 left-1/2 -translate-x-1/2"}},L=()=>{if(l)switch(s){case"right":return"absolute right-2 top-1/2 -translate-y-1/2";case"left":return"absolute left-2 top-1/2 -translate-y-1/2";case"bottom":return"absolute bottom-2 left-1/2 -translate-x-1/2";case"top":return"absolute top-2 left-1/2 -translate-x-1/2";default:return"absolute right-2 top-1/2 -translate-y-1/2"}else switch(s){case"right":return"fixed right-2 top-1/2 -translate-y-1/2";case"left":return"fixed left-2 top-1/2 -translate-y-1/2";case"bottom":return"fixed bottom-2 left-1/2 -translate-x-1/2";case"top":return"fixed top-2 left-1/2 -translate-x-1/2";default:return"fixed right-2 top-1/2 -translate-y-1/2"}},U=()=>{if(v)switch(s){case"right":return 180;case"left":return 0;case"bottom":return-90;case"top":return 90;default:return 180}else switch(s){case"right":return 0;case"left":return 180;case"bottom":return 90;case"top":return-90;default:return 0}},A=()=>{let j="calc(100% + 56px)";switch(s){case"right":return{x:j,y:0};case"left":return{x:`-${j}`,y:0};case"bottom":return{x:0,y:j};case"top":return{x:0,y:`-${j}`};default:return{x:j,y:0}}};if(!b||c==="always")return(0,Gl.jsx)(me.div,{ref:g,className:E(VSe({size:i,position:s}),R(),"z-[99999]",e),initial:{opacity:0,scale:.95},animate:{opacity:1,scale:1},transition:{duration:.4,ease:"easeOut"},children:t.map(j=>(0,Gl.jsx)($Se,{item:j,size:i||"md",magnification:r,showTooltip:o,position:s||"bottom"},j.id))});if(c==="hidden")return null;let I=A();return(0,Gl.jsx)("div",{className:E("z-[99999]",R()),children:(0,Gl.jsxs)(me.div,{className:"relative",initial:!1,animate:{x:v?0:I.x,y:v?0:I.y},transition:{duration:.35,ease:[.4,0,.2,1]},children:[(0,Gl.jsx)(me.button,{className:E("absolute p-2.5 rounded-full backdrop-blur-md border shadow-lg hover:shadow-xl transition-shadow",p,m,s==="right"&&"-left-14 top-1/2 -translate-y-1/2",s==="left"&&"-right-14 top-1/2 -translate-y-1/2",s==="bottom"&&"left-1/2 -translate-x-1/2 -top-14",s==="top"&&"left-1/2 -translate-x-1/2 -bottom-14"),onClick:()=>y(!v),whileTap:{scale:.95},children:(0,Gl.jsx)(me.div,{animate:{rotate:U()},transition:{duration:.3,ease:"easeOut"},children:f||(0,Gl.jsx)(Sn,{className:"w-4 h-4"})})}),(0,Gl.jsx)("div",{ref:g,className:E(VSe({size:i,position:s}),e),children:t.map(j=>(0,Gl.jsx)($Se,{item:j,size:i||"md",magnification:r,showTooltip:o,position:s||"bottom"},j.id))})]})})});HSe.displayName="FloatingDockInternal";var r4=uu.default.forwardRef((e,t)=>{let{hasProAccess:r,isLoading:n}=Ee();return!n&&!r?(0,Gl.jsx)(Ve,{componentName:"Floating Dock",compact:!0,className:"inline-block"}):(0,Gl.jsx)(HSe,{...e,ref:t})});r4.displayName="FloatingDock";var Mi=_(ye(),1);var Nk=_(ue(),1),Ilt=gt("fixed pointer-events-none z-[9999]",{variants:{size:{sm:"w-4 h-4",md:"w-6 h-6",lg:"w-8 h-8",xl:"w-12 h-12"},variant:{default:"bg-primary",secondary:"bg-secondary",accent:"bg-accent",destructive:"bg-destructive",rainbow:"bg-gradient-to-r from-red-500 via-yellow-500 via-green-500 via-blue-500 to-purple-500"}},defaultVariants:{size:"md",variant:"default"}}),Llt=(e,t,r,n)=>Math.sqrt(Math.pow(r-e,2)+Math.pow(n-t,2)),Dlt=({size:e="md",variant:t="default",duration:r=600,maxSplashes:n=10,threshold:o=1,targetSelector:a,colors:i,showParticles:s=!1,particleCount:l=8,animationType:c="scale",soundUrl:u,enabled:d=!0,containerRef:f})=>{let[p,m]=(0,Mi.useState)([]),h=(0,Mi.useRef)(Date.now()),g=(0,Mi.useRef)({x:0,y:0}),v=(0,Mi.useRef)(null),y=(0,Mi.useRef)(null),b=(0,Mi.useRef)(0),w=(0,Mi.useRef)(new Set);(0,Mi.useEffect)(()=>{if(u&&!v.current){let $=new Audio(u);$.volume=.3,v.current=$}return()=>{v.current&&(v.current=null)}},[u]);let x=(0,Mi.useCallback)($=>{m(S=>S.filter(k=>k.id!==$))},[]),C=(0,Mi.useCallback)(($,S)=>{let k=Date.now();if(k-b.current<16)return;b.current=k;let N={id:k+Math.random(),x:$,y:S,timestamp:k};if(m(B=>B.length>=n?[...B.slice(1),N]:[...B,N]),v.current)try{let B=v.current.cloneNode();B.volume=.3,B.play().catch(()=>{}),setTimeout(()=>B.remove(),1e3)}catch{}let T=setTimeout(()=>{x(N.id),w.current.delete(T)},r);w.current.add(T)},[n,r,x]),P=(0,Mi.useCallback)($=>{y.current||(y.current=requestAnimationFrame(()=>{let S=f?.current,k=$.clientX,N=$.clientY;if(S){let D=S.getBoundingClientRect();if(k=$.clientX-D.left,N=$.clientY-D.top,k<0||N<0||k>D.width||N>D.height){y.current=null;return}}let T=Date.now(),B=T-h.current;B>0&&Llt(g.current.x,g.current.y,k,N)/B>o&&(a?$.target?.closest(a)&&C(k,N):C(k,N)),g.current={x:k,y:N},h.current=T,y.current=null}))},[o,a,C,f]),R=(0,Mi.useCallback)($=>{let S=f?.current,k=$.clientX,N=$.clientY;if(S){let T=S.getBoundingClientRect();if(k=$.clientX-T.left,N=$.clientY-T.top,k<0||N<0||k>T.width||N>T.height)return}a?$.target?.closest(a)&&C(k,N):C(k,N)},[a,C,f]);(0,Mi.useEffect)(()=>{if(!d)return;let $=f?.current||document,S=P,k=R;return $.addEventListener("mousemove",S),$.addEventListener("click",k),()=>{$.removeEventListener("mousemove",S),$.removeEventListener("click",k),y.current&&(cancelAnimationFrame(y.current),y.current=null),w.current.forEach(N=>clearTimeout(N)),w.current.clear()}},[d,P,R,f]);let L=(0,Mi.useMemo)(()=>{switch(c){case"ripple":return{initial:{scale:0,opacity:1},animate:{scale:4,opacity:0},exit:{scale:5,opacity:0}};case"burst":return{initial:{scale:0,rotate:0,opacity:1},animate:{scale:3,rotate:180,opacity:0},exit:{scale:4,opacity:0}};case"fade":return{initial:{scale:1,opacity:1},animate:{scale:1.5,opacity:0},exit:{opacity:0}};default:return{initial:{scale:0,opacity:1},animate:{scale:2,opacity:0},exit:{scale:3,opacity:0}}}},[c]),U=(0,Mi.useCallback)($=>i&&i.length>0?i[$%i.length]:"",[i]),A=(0,Mi.useMemo)(()=>s?Array.from({length:l}).map(($,S)=>{let N=360/l*S*Math.PI/180;return{x:Math.cos(N)*30,y:Math.sin(N)*30}}):[],[s,l]),{hasProAccess:I,isLoading:j}=Ee();return!j&&!I?(0,Nk.jsx)(Ve,{componentName:"Splash Cursor",compact:!0,className:"inline-block"}):d?(0,Nk.jsx)("div",{className:E("pointer-events-none z-[9999]",f?"absolute inset-0":"fixed inset-0"),children:(0,Nk.jsx)(Mt,{mode:"popLayout",children:p.map(($,S)=>[(0,Nk.jsx)(me.div,{className:E(Ilt({size:e,variant:t}),"rounded-full"),style:{position:"absolute",left:$.x-12,top:$.y-12,backgroundColor:U(S)||void 0,willChange:"transform, opacity"},variants:L,initial:"initial",animate:"animate",exit:"exit",transition:{duration:r/1e3,ease:"easeOut"}},$.id),...s?A.map((k,N)=>(0,Nk.jsx)(me.div,{className:"absolute w-1 h-1 bg-current rounded-full",style:{left:$.x,top:$.y,color:U(S+N)||"currentColor",willChange:"transform, opacity"},initial:{x:0,y:0,opacity:1,scale:1},animate:{x:k.x,y:k.y,opacity:0,scale:0},transition:{duration:r/1e3,ease:"easeOut"}},`${$.id}-p${N}`)):[]]).flat()})}):null},Rk=Mi.default.memo(Dlt);Rk.displayName="SplashCursor";var jSe=_(ye(),1);var o4=_(ue(),1),n4=({className:e,children:t,minHeight:r="400px",...n})=>{let o=(0,jSe.useRef)(null);return(0,o4.jsxs)("div",{ref:o,className:E("relative overflow-hidden rounded-lg border bg-background",e),style:{minHeight:r},children:[(0,o4.jsx)(Rk,{...n,containerRef:o}),t]})};n4.displayName="SplashCursorContainer";var nb=_(ye(),1);var rl=_(ue(),1);var Olt=({children:e,speed:t=50,direction:r="left",pauseOnHover:n=!1,repeat:o=2,fade:a=!1,fadeWidth:i=10,autoFill:s=!1,className:l,containerClassName:c,onPlayStateChange:u})=>{let d=(0,nb.useRef)(null),f=(0,nb.useRef)(null),[p,m]=(0,nb.useState)(!0),[h,g]=(0,nb.useState)(o);(0,nb.useEffect)(()=>{if(s&&d.current&&f.current){let C=d.current.offsetWidth,P=f.current.offsetWidth;if(P<C){let R=Math.ceil(C/P)+1;g(R)}}},[s,e]);let v=()=>{n&&(m(!1),u?.(!1))},y=()=>{n&&(m(!0),u?.(!0))},b=`${100/t*20}s`,w=()=>{switch(r){case"right":return"animate-marquee-right";case"up":return"animate-marquee-up";case"down":return"animate-marquee-down";default:return"animate-marquee-left"}},x=r==="up"||r==="down";return(0,rl.jsxs)("div",{ref:d,className:E("relative overflow-hidden",a&&"marquee-fade",c),style:{["--marquee-duration"]:b,["--marquee-fade-width"]:`${i}px`},onMouseEnter:v,onMouseLeave:y,children:[a&&(0,rl.jsx)(rl.Fragment,{children:x?(0,rl.jsxs)(rl.Fragment,{children:[(0,rl.jsx)("div",{className:"absolute top-0 left-0 w-full z-10 pointer-events-none",style:{height:`${i}%`,background:"linear-gradient(to bottom, hsl(var(--background)), transparent)"}}),(0,rl.jsx)("div",{className:"absolute bottom-0 left-0 w-full z-10 pointer-events-none",style:{height:`${i}%`,background:"linear-gradient(to top, hsl(var(--background)), transparent)"}})]}):(0,rl.jsxs)(rl.Fragment,{children:[(0,rl.jsx)("div",{className:"absolute top-0 left-0 h-full z-10 pointer-events-none",style:{width:`${i}%`,background:"linear-gradient(to right, hsl(var(--background)), transparent)"}}),(0,rl.jsx)("div",{className:"absolute top-0 right-0 h-full z-10 pointer-events-none",style:{width:`${i}%`,background:"linear-gradient(to left, hsl(var(--background)), transparent)"}})]})}),(0,rl.jsx)("div",{className:E("flex",x?"flex-col":"flex-row",w(),!p&&"animation-paused",l),children:Array.from({length:h}).map((C,P)=>(0,rl.jsx)("div",{ref:P===0?f:void 0,className:E("flex shrink-0",x?"flex-col":"flex-row",x?"py-2":"px-2"),children:e},P))}),(0,rl.jsx)("style",{children:`
|
|
223
|
+
)`};case"hexagon":return{backgroundImage:`url("data:image/svg+xml,%3Csvg width='40' height='40' viewBox='0 0 40 40' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M20 0l8.66 5v10l-8.66 5-8.66-5V5z' fill='none' stroke='%23${t.replace("#","")}' stroke-opacity='0.1'/%3E%3C/svg%3E")`,backgroundSize:"40px 40px"};case"circuit":return{backgroundImage:`url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M30 10v10m0 10v10m-10-20h10m10 0h10' stroke='%23${t.replace("#","")}' stroke-opacity='0.1' fill='none' stroke-width='2'/%3E%3C/svg%3E")`,backgroundSize:"60px 60px"};default:return{}}},FSe=(0,wc.forwardRef)(({children:e,className:t,variant:r,intensity:n,size:o,glowColor:a="#3b82f6",gradient:i=!1,gradientColors:s=["#3b82f6","#8b5cf6","#ec4899"],gradientAngle:l=45,animationPreset:c="none",animationDuration:u=2,glowLayers:d=[],backdropBlur:f=!1,blurAmount:p=12,pattern:m="none",mouseTrack:h=!1,mouseRadius:g=150,tilt:v=!1,tiltAngle:y=15,theme:b="auto",disableAnimations:w=!1,cssVars:x={},containerProps:C={},style:P,onMouseMove:R,onMouseLeave:L,...U},A)=>{let[I,j]=(0,wc.useState)({x:0,y:0}),[$,S]=(0,wc.useState)(!1),[k,N]=(0,wc.useState)({}),T=(0,wc.useRef)(null),B=V=>{T.current=V,A&&(typeof A=="function"?A(V):A.current=V)},D=V=>{if(!T.current)return;let O=T.current.getBoundingClientRect(),Y=V.clientX-O.left,re=V.clientY-O.top;if(h&&j({x:Y,y:re}),v&&!w){let Q=O.width/2,ae=O.height/2,te=(re-ae)/ae*y,se=(Y-Q)/Q*-y;N({transform:`perspective(1000px) rotateX(${te}deg) rotateY(${se}deg) scale3d(1.02, 1.02, 1.02)`,transformStyle:"preserve-3d"})}R?.(V)},z=V=>{S(!1),v&&N({transform:"perspective(1000px) rotateX(0deg) rotateY(0deg) scale3d(1, 1, 1)",transformStyle:"preserve-3d"}),L?.(V)},M=(0,wc.useMemo)(()=>{if(!i)return{};let V=s.join(", ");return{background:`linear-gradient(${l}deg, ${V})`}},[i,s,l]),G=(0,wc.useMemo)(()=>d.length===0?"":d.map(V=>{let O=V.inset?"inset ":"",Y=V.blur||V.size;return`${O}0 0 ${Y}px ${V.size}px ${V.color}`}).join(", "),[d]),q=(0,wc.useMemo)(()=>!h||!$?{}:{background:`radial-gradient(circle at ${I.x}px ${I.y}px, ${a}40 0%, transparent ${g}px)`},[h,$,I,g,a]),H=(0,wc.useMemo)(()=>b==="dark"?.7:b==="light"?.3:"auto",[b]),F=(0,wc.useMemo)(()=>w||c==="none"?{}:{animationDuration:`${u}s`},[w,c,u]),W=(0,wc.useMemo)(()=>G||Rlt(r,n,o,a,$),[r,n,o,a,$,G]);return(0,rb.jsxs)("div",{...C,className:E("glow-card-container relative",C.className),style:{...C.style,...x},children:[m!=="none"&&(0,rb.jsx)("div",{className:"absolute inset-0 opacity-10 pointer-events-none rounded-inherit",style:Mlt(m,a),"aria-hidden":"true"}),h&&(0,rb.jsx)("div",{className:"absolute inset-0 opacity-50 transition-opacity duration-300 pointer-events-none rounded-inherit",style:q,"aria-hidden":"true"}),(0,rb.jsx)("div",{ref:B,className:E(klt({variant:r,intensity:n,size:o}),!w&&Nlt[c],f&&"backdrop-blur-md","glow-card relative overflow-hidden rounded-lg transition-all duration-300",t),style:{...P,...M,...F,...v&&!w?k:{},boxShadow:W,willChange:"transform, box-shadow",transform:"translateZ(0)"},onMouseMove:D,onMouseEnter:()=>S(!0),onMouseLeave:z,...U,children:e})]})});FSe.displayName="GlowCard";var IK=(0,wc.forwardRef)((e,t)=>{let{hasProAccess:r,isLoading:n}=Ee();return!n&&!r?(0,rb.jsx)(Ve,{componentName:"GlowCard",compact:!0,className:"inline-block"}):(0,rb.jsx)(FSe,{ref:t,...e})});IK.displayName="GlowCard";var Cm=_(ye(),1);var fo=_(ue(),1),LK=gt("relative inline-flex items-center justify-center whitespace-nowrap rounded-md text-sm font-medium transition-all duration-200 focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring disabled:pointer-events-none disabled:opacity-50 overflow-hidden min-w-fit",{variants:{variant:{default:"bg-primary text-primary-foreground shadow hover:bg-primary/90",destructive:"bg-destructive text-destructive-foreground shadow-sm hover:bg-destructive/90",outline:"border border-input bg-background shadow-sm hover:bg-accent hover:text-accent-foreground",secondary:"bg-secondary text-secondary-foreground shadow-sm hover:bg-secondary/80",ghost:"hover:bg-accent hover:text-accent-foreground",link:"text-primary underline-offset-4 hover:underline",gradient:"bg-gradient-to-r from-purple-600 to-pink-600 text-white hover:from-purple-700 hover:to-pink-700",glow:"bg-primary text-primary-foreground shadow-lg hover:shadow-xl hover:shadow-primary/25"},size:{default:"h-9 px-4 py-2",sm:"h-8 rounded-md px-3 text-xs",lg:"h-10 rounded-md px-8",xl:"h-11 rounded-md px-6 text-base font-medium",icon:"h-9 w-9"}},defaultVariants:{variant:"default",size:"default"}}),BSe=Cm.default.forwardRef(({className:e,variant:t,size:r,animation:n="none",state:o="idle",onStateChange:a,children:i,onClick:s,loadingText:l="Loading...",successText:c="Success!",errorText:u="Error!",ripple:d=!1,iconRotate:f=!1,shimmerSpeed:p="normal",glowIntensity:m="medium",showProgressBar:h=!1,autoResetDelay:g=2e3,onDrag:v,onDragEnd:y,onDragStart:b,onAnimationStart:w,onAnimationEnd:x,...C},P)=>{let[R,L]=(0,Cm.useState)("idle"),[U,A]=(0,Cm.useState)([]),[I,j]=(0,Cm.useState)(0),[$,S]=(0,Cm.useState)(!1),k=o!=="idle"?o:R,N=async q=>{if(k!=="loading"&&!(C.type==="submit"&&!s)){if(s&&q.preventDefault(),d){let H=q.currentTarget.getBoundingClientRect(),F=q.clientX-H.left,W=q.clientY-H.top,V=Date.now();A([...U,{x:F,y:W,id:V}]),setTimeout(()=>{A(O=>O.filter(Y=>Y.id!==V))},600)}if(L("loading"),a?.("loading"),j(0),h){let H=setInterval(()=>{j(F=>F>=90?(clearInterval(H),90):F+10)},200)}if(s)try{await s(q),j(100),L("success"),a?.("success"),setTimeout(()=>{L("idle"),a?.("idle"),j(0)},g)}catch{j(0),L("error"),a?.("error"),setTimeout(()=>{L("idle"),a?.("idle")},g)}}},T=()=>{let q=E("h-4 w-4",{"animate-spin":k==="loading"||f&&k!=="idle"});switch(k){case"loading":return(0,fo.jsx)(kr,{className:q});case"success":return(0,fo.jsx)(Qr,{className:E(q,"animate-scale-in")});case"error":return(0,fo.jsx)(fr,{className:E(q,"animate-shake")});default:return null}},B=()=>{switch(k){case"success":return"bg-green-600";case"error":return"bg-red-600";default:return""}},D=()=>{switch(p){case"slow":return"duration-1500";case"fast":return"duration-500";default:return"duration-1000"}},z=()=>{switch(m){case"low":return"shadow-lg";case"high":return"shadow-2xl";default:return"shadow-xl"}},M,G;return n==="bounce"?M={y:[0,-10,0],transition:{duration:.6,repeat:1/0,repeatType:"loop"}}:n==="pulse"?M={scale:[1,1.1,1],transition:{duration:1,repeat:1/0,repeatType:"loop"}}:n==="shake"?M=void 0:n==="rotate"?M={rotate:10,transition:{type:"spring",stiffness:300}}:n==="scale"?(M={scale:1.05},G={scale:.95}):n==="slide"&&(M={y:-4}),(0,fo.jsxs)(me.button,{...C,className:E(LK({variant:t,size:r}),t==="glow"&&z(),n==="shake"&&$&&"animate-shake",e),ref:P,onClick:N,disabled:k==="loading"||C.disabled,onMouseEnter:()=>S(!0),onMouseLeave:()=>S(!1),whileHover:M,whileTap:G,children:[h&&k==="loading"&&(0,fo.jsx)(me.div,{className:"absolute bottom-0 left-0 h-1 bg-primary-foreground/20 rounded-full",initial:{width:0},animate:{width:`${I}%`},transition:{duration:.3}}),n==="shimmer"&&(0,fo.jsx)(me.div,{className:"absolute inset-0 bg-gradient-to-r from-transparent via-white/20 to-transparent",initial:{x:"-100%"},animate:{x:"100%"},transition:{duration:p==="slow"?1.5:p==="fast"?.5:1,repeat:1/0,repeatDelay:1}}),(0,fo.jsx)("div",{className:"relative flex items-center justify-center gap-2 z-10",children:r==="icon"?k==="idle"?i:T():(0,fo.jsx)(fo.Fragment,{children:k==="idle"?(0,fo.jsxs)(fo.Fragment,{children:[Cm.default.isValidElement(i)&&Cm.default.cloneElement(i),typeof i=="string"&&i,Cm.default.isValidElement(i)||typeof i=="string"?null:i]}):(0,fo.jsxs)(fo.Fragment,{children:[T(),(0,fo.jsxs)("span",{className:"ml-2",children:[k==="loading"&&l,k==="success"&&c,k==="error"&&u]})]})})}),(0,fo.jsx)(me.div,{className:E("absolute inset-0 rounded-md",B()),initial:{scale:0,opacity:0},animate:{scale:k==="success"||k==="error"?1:0,opacity:k==="success"||k==="error"?.2:0},transition:{duration:.3},style:{zIndex:0}}),U.map(q=>(0,fo.jsx)("span",{className:"absolute bg-primary/20 rounded-full animate-ripple pointer-events-none",style:{left:q.x-10,top:q.y-10,width:20,height:20}},q.id))]})});BSe.displayName="MoonUIAnimatedButtonProInternal";var DK=Cm.default.forwardRef((e,t)=>{let{hasProAccess:r,isLoading:n}=Ee();return!n&&!r?(0,fo.jsx)(Ze,{className:E("w-fit",e.className),children:(0,fo.jsx)(tt,{className:"py-6 text-center",children:(0,fo.jsxs)("div",{className:"space-y-4",children:[(0,fo.jsx)("div",{className:"rounded-full bg-purple-100 dark:bg-purple-900/30 p-3 w-fit mx-auto",children:(0,fo.jsx)(Qt,{className:"h-6 w-6 text-purple-600 dark:text-purple-400"})}),(0,fo.jsxs)("div",{children:[(0,fo.jsx)("h3",{className:"font-semibold text-sm mb-2",children:"Pro Feature"}),(0,fo.jsx)("p",{className:"text-muted-foreground text-xs mb-4",children:"Animated Button is available exclusively to MoonUI Pro subscribers."}),(0,fo.jsx)("a",{href:"/pricing",children:(0,fo.jsxs)(xe,{size:"sm",children:[(0,fo.jsx)(jt,{className:"mr-2 h-4 w-4"}),"Upgrade to Pro"]})})]})]})})}):(0,fo.jsx)(BSe,{...e,ref:t})});DK.displayName="MoonUIAnimatedButtonPro";var Sm=_(ye(),1);var Ba=_(ue(),1),Elt=({children:e,delay:t=0,index:r,onMouseEnter:n,onClick:o})=>{let a=(0,Sm.useRef)(null),i=bx(a,{amount:.5,once:!1});return(0,Ba.jsx)(me.div,{ref:a,"data-index":r,onMouseEnter:n,onClick:o,initial:{scale:.7,opacity:0},animate:i?{scale:1,opacity:1}:{scale:.7,opacity:0},transition:{duration:.2,delay:t},className:"mb-4 cursor-pointer",children:e})},Tlt=({items:e=["Item 1","Item 2","Item 3","Item 4","Item 5","Item 6","Item 7","Item 8","Item 9","Item 10","Item 11","Item 12","Item 13","Item 14","Item 15"],onItemSelect:t,showGradients:r=!0,enableArrowNavigation:n=!0,className:o="",itemClassName:a="",displayScrollbar:i=!0,initialSelectedIndex:s=-1})=>{let l=(0,Sm.useRef)(null),[c,u]=(0,Sm.useState)(s),[d,f]=(0,Sm.useState)(!1),[p,m]=(0,Sm.useState)(0),[h,g]=(0,Sm.useState)(1),v=y=>{let{scrollTop:b,scrollHeight:w,clientHeight:x}=y.target;m(Math.min(b/50,1));let C=w-(b+x);g(w<=x?0:Math.min(C/50,1))};return(0,Sm.useEffect)(()=>{if(!n)return;let y=b=>{b.key==="ArrowDown"||b.key==="Tab"&&!b.shiftKey?(b.preventDefault(),f(!0),u(w=>Math.min(w+1,e.length-1))):b.key==="ArrowUp"||b.key==="Tab"&&b.shiftKey?(b.preventDefault(),f(!0),u(w=>Math.max(w-1,0))):b.key==="Enter"&&c>=0&&c<e.length&&(b.preventDefault(),t&&t(e[c],c))};return window.addEventListener("keydown",y),()=>window.removeEventListener("keydown",y)},[e,c,t,n]),(0,Sm.useEffect)(()=>{if(!d||c<0||!l.current)return;let y=l.current,b=y.querySelector(`[data-index="${c}"]`);if(b){let x=y.scrollTop,C=y.clientHeight,P=b.offsetTop,R=P+b.offsetHeight;P<x+50?y.scrollTo({top:P-50,behavior:"smooth"}):R>x+C-50&&y.scrollTo({top:R-C+50,behavior:"smooth"})}f(!1)},[c,d]),(0,Ba.jsxs)("div",{className:E("relative w-[500px]",o),children:[(0,Ba.jsx)("div",{ref:l,className:E("max-h-[400px] overflow-y-auto p-4",i?"[&::-webkit-scrollbar]:w-[8px] [&::-webkit-scrollbar-track]:bg-background [&::-webkit-scrollbar-thumb]:bg-border [&::-webkit-scrollbar-thumb]:rounded-[4px] [&::-webkit-scrollbar-thumb]:hover:bg-muted-foreground/50":"scrollbar-hide"),onScroll:v,style:{scrollbarWidth:i?"thin":"none",scrollbarColor:i?"hsl(var(--border)) hsl(var(--background))":"transparent"},children:e.map((y,b)=>(0,Ba.jsx)(Elt,{delay:.1,index:b,onMouseEnter:()=>u(b),onClick:()=>{u(b),t&&t(y,b)},children:(0,Ba.jsx)("div",{className:E("p-4 bg-card border rounded-lg transition-colors duration-200 hover:bg-accent/50",c===b?"bg-accent border-accent-foreground/20":"border-border",a),children:(0,Ba.jsx)("p",{className:"text-foreground m-0 text-sm",children:y})})},b))}),r&&(0,Ba.jsxs)(Ba.Fragment,{children:[(0,Ba.jsx)("div",{className:"absolute top-0 left-0 right-0 h-[50px] bg-gradient-to-b from-background to-transparent pointer-events-none transition-opacity duration-300 ease",style:{opacity:p}}),(0,Ba.jsx)("div",{className:"absolute bottom-0 left-0 right-0 h-[100px] bg-gradient-to-t from-background to-transparent pointer-events-none transition-opacity duration-300 ease",style:{opacity:h}})]})]})},Z3=e=>{let{hasProAccess:t,isLoading:r}=Ee();return!r&&!t?(0,Ba.jsx)(Ze,{className:E("w-fit",e.className),children:(0,Ba.jsx)(tt,{className:"py-6 text-center",children:(0,Ba.jsxs)("div",{className:"space-y-4",children:[(0,Ba.jsx)("div",{className:"rounded-full bg-purple-100 dark:bg-purple-900/30 p-3 w-fit mx-auto",children:(0,Ba.jsx)(Qt,{className:"h-6 w-6 text-purple-600 dark:text-purple-400"})}),(0,Ba.jsxs)("div",{children:[(0,Ba.jsx)("h3",{className:"font-semibold text-sm mb-2",children:"Pro \xD6zellik"}),(0,Ba.jsx)("p",{className:"text-muted-foreground text-xs mb-4",children:"Animated List sadece MoonUI Pro abonelerine \xF6zeldir."}),(0,Ba.jsx)("a",{href:"/pricing",children:(0,Ba.jsxs)(xe,{size:"sm",children:[(0,Ba.jsx)(jt,{className:"mr-2 h-4 w-4"}),"Pro'ya Y\xFCkselt"]})})]})]})})}):(0,Ba.jsx)(Tlt,{...e})};Z3.displayName="MoonUIAnimatedListPro";var Cc=_(ye(),1);var jw=_(ue(),1);var aI={primary:"hsl(var(--primary) / 0.25)",secondary:"hsl(var(--secondary) / 0.25)",accent:"hsl(var(--accent) / 0.25)",destructive:"hsl(var(--destructive) / 0.25)",muted:"hsl(var(--muted-foreground) / 0.15)",white:"rgba(255, 255, 255, 0.25)",blue:"rgba(59, 130, 246, 0.25)",purple:"rgba(147, 51, 234, 0.25)",green:"rgba(34, 197, 94, 0.25)",orange:"rgba(249, 115, 22, 0.25)",red:"rgba(239, 68, 68, 0.25)",yellow:"rgba(234, 179, 8, 0.25)",pink:"rgba(236, 72, 153, 0.25)",cyan:"rgba(6, 182, 212, 0.25)"},zSe=Cc.default.forwardRef(({children:e,className:t,spotlightColor:r="primary",spotlightSize:n=200,intensity:o=.6,duration:a=500,rounded:i="lg",borderClass:s,backgroundClass:l,borderGlow:c=!1,disabled:u=!1,locked:d=!1,...f},p)=>{let m=(0,Cc.useRef)(null),[h,g]=(0,Cc.useState)(!1),[v,y]=(0,Cc.useState)({x:0,y:0}),[b,w]=(0,Cc.useState)(0),x=Cc.default.useMemo(()=>typeof r=="string"&&r in aI?aI[r]:r,[r]),C=(0,Cc.useCallback)(I=>{if(!m.current||h||u)return;let j=m.current.getBoundingClientRect();y({x:I.clientX-j.left,y:I.clientY-j.top})},[h,u]),P=(0,Cc.useCallback)(()=>{u||(g(!0),w(o))},[u,o]),R=(0,Cc.useCallback)(()=>{g(!1),w(0)},[]),L=(0,Cc.useCallback)(()=>{u||w(o)},[u,o]),U=(0,Cc.useCallback)(()=>{w(0)},[]),A={none:"",sm:"rounded-sm",md:"rounded-md",lg:"rounded-lg",xl:"rounded-xl","2xl":"rounded-2xl","3xl":"rounded-3xl",full:"rounded-full"};return d?(0,jw.jsx)(Ve,{componentName:"SpotlightCard Pro",className:E("min-h-[200px]",t)}):(0,jw.jsxs)("div",{ref:I=>{m.current=I,typeof p=="function"?p(I):p&&(p.current=I)},onMouseMove:C,onFocus:P,onBlur:R,onMouseEnter:L,onMouseLeave:U,className:E("relative overflow-hidden",A[i],s||"border border-border",l||"bg-card","transition-all duration-200",u&&"cursor-not-allowed opacity-50",t),...f,children:[(0,jw.jsx)("div",{className:E("pointer-events-none absolute","transition-all ease-in-out",c&&"border-2 border-white/20",u&&"hidden"),style:{opacity:b,left:`${v.x}px`,top:`${v.y}px`,width:`${n*2}px`,height:`${n*2}px`,transform:"translate(-50%, -50%)",background:`radial-gradient(circle, ${x}, transparent 80%)`,transitionDuration:`${a}ms`,transitionProperty:"opacity, left, top",boxShadow:c?`0 0 20px ${x}`:void 0}}),(0,jw.jsx)("div",{className:"relative z-10",children:e})]})});zSe.displayName="SpotlightCardInternal";var OK=Cc.default.forwardRef((e,t)=>(0,jw.jsx)(zSe,{...e,ref:t}));OK.displayName="MoonUISpotlightCardPro";var fp=_(ye(),1);var e4=_(ue(),1),Alt=gt("font-mono tabular-nums",{variants:{size:{sm:"text-sm",md:"text-base",lg:"text-lg",xl:"text-xl","2xl":"text-2xl","3xl":"text-3xl","4xl":"text-4xl"},variant:{default:"text-foreground",primary:"text-primary",secondary:"text-muted-foreground",success:"text-green-600 dark:text-green-400",warning:"text-orange-600 dark:text-orange-400",destructive:"text-red-600 dark:text-red-400"}},defaultVariants:{size:"md",variant:"default"}}),USe=fp.default.forwardRef(({className:e,value:t,from:r=0,duration:n=2,decimalPlaces:o=0,format:a="number",currency:i="TRY",locale:s="tr-TR",prefix:l="",suffix:c="",triggerOnView:u=!1,ease:d="easeOut",size:f,variant:p,onComplete:m,...h},g)=>{let[v,y]=(0,fp.useState)(!u),b=(0,fp.useRef)(null),w=bx(b,{once:!0}),x=aa(r),C=Hp(x,{duration:n*1e3,bounce:d==="spring"?.4:0}),[P,R]=(0,fp.useState)(r),L=U=>{let A;switch(a){case"currency":A=new Intl.NumberFormat(s,{style:"currency",currency:i,minimumFractionDigits:o,maximumFractionDigits:o}).format(U);break;case"percent":A=new Intl.NumberFormat(s,{style:"percent",minimumFractionDigits:o,maximumFractionDigits:o}).format(U/100);break;default:A=new Intl.NumberFormat(s,{minimumFractionDigits:o,maximumFractionDigits:o}).format(U)}return`${l}${A}${c}`};return(0,fp.useEffect)(()=>{u&&w&&y(!0)},[u,w]),(0,fp.useEffect)(()=>{v&&x.set(t)},[v,t,x]),(0,fp.useEffect)(()=>{let U=C.on("change",I=>{R(I)}),A=C.on("animationComplete",()=>{m?.()});return()=>{U(),A()}},[C,m]),(0,e4.jsx)(me.div,{ref:b,className:E(Alt({size:f,variant:p,className:e})),initial:{opacity:0,scale:.5},animate:v?{opacity:1,scale:1}:{opacity:0,scale:.5},transition:{duration:.5,ease:d==="spring"?"easeOut":d},children:L(P)})});USe.displayName="AnimatedNumberInternal";var t4=fp.default.forwardRef((e,t)=>{let{hasProAccess:r,isLoading:n}=Ee();return!n&&!r?(0,e4.jsx)(Ve,{componentName:"Animated Number",compact:!0,className:"inline-block"}):(0,e4.jsx)(USe,{...e,ref:t})});t4.displayName="AnimatedNumber";var uu=_(ye(),1);var Gl=_(ue(),1),VSe=gt("flex items-center gap-1 rounded-full border bg-background/95 backdrop-blur-md shadow-xl",{variants:{size:{sm:"p-1",md:"p-1.5",lg:"p-2"},position:{bottom:"flex-row",top:"flex-row",left:"flex-col",right:"flex-col"}},defaultVariants:{size:"md",position:"bottom"}}),rAr=gt("flex items-center justify-center rounded-full transition-all duration-200 cursor-pointer",{variants:{size:{sm:"w-9 h-9",md:"w-11 h-11",lg:"w-13 h-13"}},defaultVariants:{size:"md"}}),$Se=uu.default.memo(({item:e,size:t,magnification:r,showTooltip:n,position:o})=>{let a=(0,uu.useRef)(null),[i,s]=(0,uu.useState)(!1),c={sm:36,md:44,lg:52}[t],u=i?r:c,d=aa(c),f=Hp(d,{stiffness:300,damping:30});return(0,uu.useEffect)(()=>{d.set(u)},[u,d]),(0,Gl.jsxs)(me.div,{ref:a,className:"relative flex items-center justify-center",onMouseEnter:()=>s(!0),onMouseLeave:()=>s(!1),children:[(0,Gl.jsx)(me.button,{style:{width:f,height:f},className:E("flex items-center justify-center rounded-full transition-colors duration-200","bg-card/80 hover:bg-card border border-border/50 shadow-sm",e.active&&"bg-primary text-primary-foreground hover:bg-primary/90 border-primary",e.className),onClick:e.onClick,whileTap:{scale:.95},children:e.icon}),(0,Gl.jsx)(Mt,{children:n&&e.label&&i&&(0,Gl.jsx)(me.div,{initial:{opacity:0,scale:.6},animate:{opacity:1,scale:1},exit:{opacity:0,scale:.6},transition:{duration:.15,ease:"easeOut"},style:{position:"absolute",...o==="bottom"&&{bottom:"calc(100% + 8px)",left:"50%",transform:"translateX(-50%)"},...o==="top"&&{top:"calc(100% + 8px)",left:"50%",transform:"translateX(-50%)"},...o==="left"&&{left:"calc(100% + 8px)",top:"50%",transform:"translateY(-50%)"},...o==="right"&&{right:"calc(100% + 8px)",top:"50%",transform:"translateY(-50%)"}},className:"px-2.5 py-1 text-xs font-medium whitespace-nowrap pointer-events-none z-50 bg-foreground text-background rounded-md shadow-lg",children:e.label})})]})}),HSe=uu.default.forwardRef(({className:e,items:t,magnification:r=64,distance:n=120,showTooltip:o=!0,animationDuration:a=500,size:i="md",position:s="bottom",containerMode:l=!1,mobileMode:c="toggle",mobileBreakpoint:u="lg",autoHideDelay:d=5e3,toggleIcon:f,toggleButtonBg:p="bg-background/95",toggleButtonBorder:m="border-border",...h},g)=>{let[v,y]=(0,uu.useState)(!1),[b,w]=(0,uu.useState)(!1),x=(0,uu.useRef)(null);(0,uu.useEffect)(()=>{let j={sm:640,md:768,lg:1024,xl:1280},$=()=>{w(window.innerWidth<j[u])};return $(),window.addEventListener("resize",$),()=>window.removeEventListener("resize",$)},[u]),(0,uu.useEffect)(()=>(v&&c==="toggle"&&b&&(x.current=setTimeout(()=>{y(!1)},d)),()=>{x.current&&clearTimeout(x.current)}),[v,d,c,b]);let C=()=>!b||c==="always"?!0:c==="hidden"?!1:c==="toggle"?v:!0,P={right:{hidden:{x:"calc(100% + 24px)",opacity:0},visible:{x:0,opacity:1}},left:{hidden:{x:"calc(-100% - 24px)",opacity:0},visible:{x:0,opacity:1}},bottom:{hidden:{y:"calc(100% + 24px)",opacity:0},visible:{y:0,opacity:1}},top:{hidden:{y:"calc(-100% - 24px)",opacity:0},visible:{y:0,opacity:1}}},R=()=>{if(l)switch(s){case"bottom":return"absolute bottom-2 left-1/2 -translate-x-1/2";case"top":return"absolute top-2 left-1/2 -translate-x-1/2";case"left":return"absolute left-2 top-1/2 -translate-y-1/2";case"right":return"absolute right-2 top-1/2 -translate-y-1/2";default:return"absolute bottom-2 left-1/2 -translate-x-1/2"}else switch(s){case"bottom":return"fixed bottom-4 left-1/2 -translate-x-1/2";case"top":return"fixed top-4 left-1/2 -translate-x-1/2";case"left":return"fixed left-4 top-1/2 -translate-y-1/2";case"right":return"fixed right-4 top-1/2 -translate-y-1/2";default:return"fixed bottom-4 left-1/2 -translate-x-1/2"}},L=()=>{if(l)switch(s){case"right":return"absolute right-2 top-1/2 -translate-y-1/2";case"left":return"absolute left-2 top-1/2 -translate-y-1/2";case"bottom":return"absolute bottom-2 left-1/2 -translate-x-1/2";case"top":return"absolute top-2 left-1/2 -translate-x-1/2";default:return"absolute right-2 top-1/2 -translate-y-1/2"}else switch(s){case"right":return"fixed right-2 top-1/2 -translate-y-1/2";case"left":return"fixed left-2 top-1/2 -translate-y-1/2";case"bottom":return"fixed bottom-2 left-1/2 -translate-x-1/2";case"top":return"fixed top-2 left-1/2 -translate-x-1/2";default:return"fixed right-2 top-1/2 -translate-y-1/2"}},U=()=>{if(v)switch(s){case"right":return 180;case"left":return 0;case"bottom":return-90;case"top":return 90;default:return 180}else switch(s){case"right":return 0;case"left":return 180;case"bottom":return 90;case"top":return-90;default:return 0}},A=()=>{let j="calc(100% + 56px)";switch(s){case"right":return{x:j,y:0};case"left":return{x:`-${j}`,y:0};case"bottom":return{x:0,y:j};case"top":return{x:0,y:`-${j}`};default:return{x:j,y:0}}};if(!b||c==="always")return(0,Gl.jsx)(me.div,{ref:g,className:E(VSe({size:i,position:s}),R(),"z-[99999]",e),initial:{opacity:0,scale:.95},animate:{opacity:1,scale:1},transition:{duration:.4,ease:"easeOut"},children:t.map(j=>(0,Gl.jsx)($Se,{item:j,size:i||"md",magnification:r,showTooltip:o,position:s||"bottom"},j.id))});if(c==="hidden")return null;let I=A();return(0,Gl.jsx)("div",{className:E("z-[99999]",R()),children:(0,Gl.jsxs)(me.div,{className:"relative",initial:!1,animate:{x:v?0:I.x,y:v?0:I.y},transition:{duration:.35,ease:[.4,0,.2,1]},children:[(0,Gl.jsx)(me.button,{className:E("absolute p-2.5 rounded-full backdrop-blur-md border shadow-lg hover:shadow-xl transition-shadow",p,m,s==="right"&&"-left-14 top-1/2 -translate-y-1/2",s==="left"&&"-right-14 top-1/2 -translate-y-1/2",s==="bottom"&&"left-1/2 -translate-x-1/2 -top-14",s==="top"&&"left-1/2 -translate-x-1/2 -bottom-14"),onClick:()=>y(!v),whileTap:{scale:.95},children:(0,Gl.jsx)(me.div,{animate:{rotate:U()},transition:{duration:.3,ease:"easeOut"},children:f||(0,Gl.jsx)(Sn,{className:"w-4 h-4"})})}),(0,Gl.jsx)("div",{ref:g,className:E(VSe({size:i,position:s}),e),children:t.map(j=>(0,Gl.jsx)($Se,{item:j,size:i||"md",magnification:r,showTooltip:o,position:s||"bottom"},j.id))})]})})});HSe.displayName="FloatingDockInternal";var r4=uu.default.forwardRef((e,t)=>{let{hasProAccess:r,isLoading:n}=Ee();return!n&&!r?(0,Gl.jsx)(Ve,{componentName:"Floating Dock",compact:!0,className:"inline-block"}):(0,Gl.jsx)(HSe,{...e,ref:t})});r4.displayName="FloatingDock";var Mi=_(ye(),1);var Nk=_(ue(),1),Ilt=gt("fixed pointer-events-none z-[9999]",{variants:{size:{sm:"w-4 h-4",md:"w-6 h-6",lg:"w-8 h-8",xl:"w-12 h-12"},variant:{default:"bg-primary",secondary:"bg-secondary",accent:"bg-accent",destructive:"bg-destructive",rainbow:"bg-gradient-to-r from-red-500 via-yellow-500 via-green-500 via-blue-500 to-purple-500"}},defaultVariants:{size:"md",variant:"default"}}),Llt=(e,t,r,n)=>Math.sqrt(Math.pow(r-e,2)+Math.pow(n-t,2)),Dlt=({size:e="md",variant:t="default",duration:r=600,maxSplashes:n=10,threshold:o=1,targetSelector:a,colors:i,showParticles:s=!1,particleCount:l=8,animationType:c="scale",soundUrl:u,enabled:d=!0,containerRef:f})=>{let[p,m]=(0,Mi.useState)([]),h=(0,Mi.useRef)(Date.now()),g=(0,Mi.useRef)({x:0,y:0}),v=(0,Mi.useRef)(null),y=(0,Mi.useRef)(null),b=(0,Mi.useRef)(0),w=(0,Mi.useRef)(new Set);(0,Mi.useEffect)(()=>{if(u&&!v.current){let $=new Audio(u);$.volume=.3,v.current=$}return()=>{v.current&&(v.current=null)}},[u]);let x=(0,Mi.useCallback)($=>{m(S=>S.filter(k=>k.id!==$))},[]),C=(0,Mi.useCallback)(($,S)=>{let k=Date.now();if(k-b.current<16)return;b.current=k;let N={id:k+Math.random(),x:$,y:S,timestamp:k};if(m(B=>B.length>=n?[...B.slice(1),N]:[...B,N]),v.current)try{let B=v.current.cloneNode();B.volume=.3,B.play().catch(()=>{}),setTimeout(()=>B.remove(),1e3)}catch{}let T=setTimeout(()=>{x(N.id),w.current.delete(T)},r);w.current.add(T)},[n,r,x]),P=(0,Mi.useCallback)($=>{y.current||(y.current=requestAnimationFrame(()=>{let S=f?.current,k=$.clientX,N=$.clientY;if(S){let D=S.getBoundingClientRect();if(k=$.clientX-D.left,N=$.clientY-D.top,k<0||N<0||k>D.width||N>D.height){y.current=null;return}}let T=Date.now(),B=T-h.current;B>0&&Llt(g.current.x,g.current.y,k,N)/B>o&&(a?$.target?.closest(a)&&C(k,N):C(k,N)),g.current={x:k,y:N},h.current=T,y.current=null}))},[o,a,C,f]),R=(0,Mi.useCallback)($=>{let S=f?.current,k=$.clientX,N=$.clientY;if(S){let T=S.getBoundingClientRect();if(k=$.clientX-T.left,N=$.clientY-T.top,k<0||N<0||k>T.width||N>T.height)return}a?$.target?.closest(a)&&C(k,N):C(k,N)},[a,C,f]);(0,Mi.useEffect)(()=>{if(!d)return;let $=f?.current||document,S=P,k=R;return $.addEventListener("mousemove",S),$.addEventListener("click",k),()=>{$.removeEventListener("mousemove",S),$.removeEventListener("click",k),y.current&&(cancelAnimationFrame(y.current),y.current=null),w.current.forEach(N=>clearTimeout(N)),w.current.clear()}},[d,P,R,f]);let L=(0,Mi.useMemo)(()=>{switch(c){case"ripple":return{initial:{scale:0,opacity:1},animate:{scale:4,opacity:0},exit:{scale:5,opacity:0}};case"burst":return{initial:{scale:0,rotate:0,opacity:1},animate:{scale:3,rotate:180,opacity:0},exit:{scale:4,opacity:0}};case"fade":return{initial:{scale:1,opacity:1},animate:{scale:1.5,opacity:0},exit:{opacity:0}};default:return{initial:{scale:0,opacity:1},animate:{scale:2,opacity:0},exit:{scale:3,opacity:0}}}},[c]),U=(0,Mi.useCallback)($=>i&&i.length>0?i[$%i.length]:"",[i]),A=(0,Mi.useMemo)(()=>s?Array.from({length:l}).map(($,S)=>{let N=360/l*S*Math.PI/180;return{x:Math.cos(N)*30,y:Math.sin(N)*30}}):[],[s,l]),{hasProAccess:I,isLoading:j}=Ee();return!j&&!I?(0,Nk.jsx)(Ve,{componentName:"Splash Cursor",compact:!0,className:"inline-block"}):d?(0,Nk.jsx)("div",{className:E("pointer-events-none z-[9999]",f?"absolute inset-0":"fixed inset-0"),children:(0,Nk.jsx)(Mt,{mode:"popLayout",children:p.map(($,S)=>[(0,Nk.jsx)(me.div,{className:E(Ilt({size:e,variant:t}),"rounded-full"),style:{position:"absolute",left:$.x-12,top:$.y-12,backgroundColor:U(S)||void 0,willChange:"transform, opacity"},variants:L,initial:"initial",animate:"animate",exit:"exit",transition:{duration:r/1e3,ease:"easeOut"}},$.id),...s?A.map((k,N)=>(0,Nk.jsx)(me.div,{className:"absolute w-1 h-1 bg-current rounded-full",style:{left:$.x,top:$.y,color:U(S+N)||"currentColor",willChange:"transform, opacity"},initial:{x:0,y:0,opacity:1,scale:1},animate:{x:k.x,y:k.y,opacity:0,scale:0},transition:{duration:r/1e3,ease:"easeOut"}},`${$.id}-p${N}`)):[]]).flat()})}):null},Rk=Mi.default.memo(Dlt);Rk.displayName="SplashCursor";var jSe=_(ye(),1);var o4=_(ue(),1),n4=({className:e,children:t,minHeight:r="400px",...n})=>{let o=(0,jSe.useRef)(null);return(0,o4.jsxs)("div",{ref:o,className:E("relative overflow-hidden rounded-lg border bg-background",e),style:{minHeight:r},children:[(0,o4.jsx)(Rk,{...n,containerRef:o}),t]})};n4.displayName="SplashCursorContainer";var nb=_(ye(),1);var rl=_(ue(),1);var Olt=({children:e,speed:t=50,direction:r="left",pauseOnHover:n=!1,repeat:o=2,fade:a=!1,fadeWidth:i=10,autoFill:s=!1,className:l,containerClassName:c,onPlayStateChange:u})=>{let d=(0,nb.useRef)(null),f=(0,nb.useRef)(null),[p,m]=(0,nb.useState)(!0),[h,g]=(0,nb.useState)(o);(0,nb.useEffect)(()=>{if(s&&d.current&&f.current){let C=d.current.offsetWidth,P=f.current.offsetWidth;if(P<C){let R=Math.ceil(C/P)+1;g(R)}}},[s,e]);let v=()=>{n&&(m(!1),u?.(!1))},y=()=>{n&&(m(!0),u?.(!0))},b=`${100/t*20}s`,w=()=>{switch(r){case"right":return"animate-marquee-right";case"up":return"animate-marquee-up";case"down":return"animate-marquee-down";default:return"animate-marquee-left"}},x=r==="up"||r==="down";return(0,rl.jsxs)("div",{ref:d,className:E("relative overflow-hidden",a&&"marquee-fade",c),style:{["--marquee-duration"]:b,["--marquee-fade-width"]:`${i}px`},onMouseEnter:v,onMouseLeave:y,children:[a&&(0,rl.jsx)(rl.Fragment,{children:x?(0,rl.jsxs)(rl.Fragment,{children:[(0,rl.jsx)("div",{className:"absolute top-0 left-0 w-full z-10 pointer-events-none",style:{height:`${i}%`,background:"linear-gradient(to bottom, hsl(var(--background)), transparent)"}}),(0,rl.jsx)("div",{className:"absolute bottom-0 left-0 w-full z-10 pointer-events-none",style:{height:`${i}%`,background:"linear-gradient(to top, hsl(var(--background)), transparent)"}})]}):(0,rl.jsxs)(rl.Fragment,{children:[(0,rl.jsx)("div",{className:"absolute top-0 left-0 h-full z-10 pointer-events-none",style:{width:`${i}%`,background:"linear-gradient(to right, hsl(var(--background)), transparent)"}}),(0,rl.jsx)("div",{className:"absolute top-0 right-0 h-full z-10 pointer-events-none",style:{width:`${i}%`,background:"linear-gradient(to left, hsl(var(--background)), transparent)"}})]})}),(0,rl.jsx)("div",{className:E("flex",x?"flex-col":"flex-row",w(),!p&&"animation-paused",l),children:Array.from({length:h}).map((C,P)=>(0,rl.jsx)("div",{ref:P===0?f:void 0,className:E("flex shrink-0",x?"flex-col":"flex-row",x?"py-2":"px-2"),children:e},P))}),(0,rl.jsx)("style",{children:`
|
|
224
224
|
@keyframes marquee-left {
|
|
225
225
|
from {
|
|
226
226
|
transform: translateX(0);
|