import{u as s,a as h,b as p,j as t,T as x,c as g,d as m,e as u,B as b,X as j}from"./index-BkPfLH67.js";function C({actions:l}){const n=s(e=>e.setRightPanelOpen),o=s(e=>e.activeRightPanelTab),r=s(e=>e.setActiveRightPanelTab),c=h({select:e=>e.location.pathname}),a=p("right-panel").filter(e=>!e.visibleWhen||e.visibleWhen({pathname:c}));return t.jsxs("div",{className:"flex w-full items-center justify-between px-3 py-2","data-slot":"right-panel-header",children:[a.length>1?t.jsx("div",{className:"bg-accent/60 inline-flex gap-0.5 rounded-lg p-0.5",role:"tablist","aria-label":"Right panel tabs",children:a.map(e=>{const i=e.id===o,d=e.icon;return t.jsxs(x,{children:[t.jsx(g,{asChild:!0,children:t.jsxs("button",{type:"button",role:"tab","aria-selected":i,"aria-label":e.title,onClick:()=>r(e.id),className:m("flex items-center gap-1.5 rounded-md px-2.5 py-1 text-[10px] font-medium transition-colors",i?"bg-background text-foreground shadow-sm":"text-muted-foreground hover:text-foreground"),children:[t.jsx(d,{className:"size-3.5"}),t.jsx("span",{children:e.title})]})}),t.jsx(u,{side:"bottom",children:e.title})]},e.id)})}):t.jsx("div",{}),t.jsxs("div",{className:"flex items-center gap-1",children:[l,t.jsx(b,{variant:"ghost",size:"icon","aria-label":"Close panel",className:"size-7 shrink-0",onClick:()=>n(!1),children:t.jsx(j,{className:"size-3.5"})})]})]})}export{C as R};
