(globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,27341,e=>{"use strict";var t=e.i(43476),a=e.i(71645),i=e.i(81140),n=e.i(30030),r=e.i(42727),s=e.i(96626),o=e.i(48425),l=e.i(86318),c=e.i(69340),d=e.i(10772),u="Tabs",[b,f]=(0,n.createContextScope)(u,[r.createRovingFocusGroupScope]),v=(0,r.createRovingFocusGroupScope)(),[p,g]=b(u),m=a.forwardRef((e,a)=>{let{__scopeTabs:i,value:n,onValueChange:r,defaultValue:s,orientation:u="horizontal",dir:b,activationMode:f="automatic",...v}=e,g=(0,l.useDirection)(b),[m,x]=(0,c.useControllableState)({prop:n,onChange:r,defaultProp:s});return(0,t.jsx)(p,{scope:i,baseId:(0,d.useId)(),value:m,onValueChange:x,orientation:u,dir:g,activationMode:f,children:(0,t.jsx)(o.Primitive.div,{dir:g,"data-orientation":u,...v,ref:a})})});m.displayName=u;var x="TabsList",h=a.forwardRef((e,a)=>{let{__scopeTabs:i,loop:n=!0,...s}=e,l=g(x,i),c=v(i);return(0,t.jsx)(r.Root,{asChild:!0,...c,orientation:l.orientation,dir:l.dir,loop:n,children:(0,t.jsx)(o.Primitive.div,{role:"tablist","aria-orientation":l.orientation,...s,ref:a})})});h.displayName=x;var y="TabsTrigger",C=a.forwardRef((e,a)=>{let{__scopeTabs:n,value:s,disabled:l=!1,...c}=e,d=g(y,n),u=v(n),b=T(d.baseId,s),f=k(d.baseId,s),p=s===d.value;return(0,t.jsx)(r.Item,{asChild:!0,...u,focusable:!l,active:p,children:(0,t.jsx)(o.Primitive.button,{type:"button",role:"tab","aria-selected":p,"aria-controls":f,"data-state":p?"active":"inactive","data-disabled":l?"":void 0,disabled:l,id:b,...c,ref:a,onMouseDown:(0,i.composeEventHandlers)(e.onMouseDown,e=>{l||0!==e.button||!1!==e.ctrlKey?e.preventDefault():d.onValueChange(s)}),onKeyDown:(0,i.composeEventHandlers)(e.onKeyDown,e=>{[" ","Enter"].includes(e.key)&&d.onValueChange(s)}),onFocus:(0,i.composeEventHandlers)(e.onFocus,()=>{let e="manual"!==d.activationMode;p||l||!e||d.onValueChange(s)})})})});C.displayName=y;var j="TabsContent",w=a.forwardRef((e,i)=>{let{__scopeTabs:n,value:r,forceMount:l,children:c,...d}=e,u=g(j,n),b=T(u.baseId,r),f=k(u.baseId,r),v=r===u.value,p=a.useRef(v);return a.useEffect(()=>{let e=requestAnimationFrame(()=>p.current=!1);return()=>cancelAnimationFrame(e)},[]),(0,t.jsx)(s.Presence,{present:l||v,children:({present:a})=>(0,t.jsx)(o.Primitive.div,{"data-state":v?"active":"inactive","data-orientation":u.orientation,role:"tabpanel","aria-labelledby":b,hidden:!a,id:f,tabIndex:0,...d,ref:i,style:{...e.style,animationDuration:p.current?"0s":void 0},children:a&&c})})});function T(e,t){return`${e}-trigger-${t}`}function k(e,t){return`${e}-content-${t}`}w.displayName=j;var P=e.i(47163);function N({className:e,...a}){return(0,t.jsx)(m,{"data-slot":"tabs",className:(0,P.cn)("flex flex-col gap-2",e),...a})}function R({className:e,...a}){return(0,t.jsx)(h,{"data-slot":"tabs-list",className:(0,P.cn)("bg-muted text-muted-foreground inline-flex h-9 w-fit items-center justify-center rounded-lg p-[3px]",e),...a})}function I({className:e,...a}){return(0,t.jsx)(C,{"data-slot":"tabs-trigger",className:(0,P.cn)("data-[state=active]:bg-background dark:data-[state=active]:text-foreground focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:outline-ring dark:data-[state=active]:border-input dark:data-[state=active]:bg-input/30 text-foreground dark:text-muted-foreground inline-flex h-[calc(100%-1px)] flex-1 items-center justify-center gap-1.5 rounded-md border border-transparent px-2 py-1 text-sm font-medium whitespace-nowrap transition-[color,box-shadow] focus-visible:ring-[3px] focus-visible:outline-1 disabled:pointer-events-none disabled:opacity-50 data-[state=active]:shadow-sm [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",e),...a})}function D({className:e,...a}){return(0,t.jsx)(w,{"data-slot":"tabs-content",className:(0,P.cn)("flex-1 outline-none",e),...a})}e.s(["Tabs",()=>N,"TabsContent",()=>D,"TabsList",()=>R,"TabsTrigger",()=>I],27341)},74323,e=>{"use strict";let t=(0,e.i(75254).default)("CirclePlus",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M8 12h8",key:"1wcyev"}],["path",{d:"M12 8v8",key:"napkw2"}]]);e.s(["PlusCircle",()=>t],74323)},32537,e=>{"use strict";var t=e.i(43476),a=e.i(67881),i=e.i(74323),n=e.i(22016),r=e.i(94433);function s(){let{user:e}=(0,r.useAuth)();return e?.role!=="expert"?null:(0,t.jsx)(a.Button,{size:"lg",className:"gap-2 shadow-lg",asChild:!0,children:(0,t.jsxs)(n.default,{href:"/insights/create",children:[(0,t.jsx)(i.PlusCircle,{className:"h-5 w-5"}),"Create Expert Article"]})})}e.s(["CreateInsightButton",()=>s])}]);