import{r as h,j as a,b as o,ad as p,o as m,aI as u,a5 as g,a8 as x,aa as b,a7 as f,F as y}from"./index-DWFi48i_.js";const k=({actions:l,size:t="small"})=>{const[i,n]=h.useState(null),s=!!i,e=l.filter(r=>!r.hidden);return e.length===0?null:a(y,{children:[o(m,{size:t,onClick:r=>{r.stopPropagation(),n(r.currentTarget)},children:o(p,{fontSize:t})}),o(f,{anchorEl:i,open:s,onClose:()=>n(null),anchorOrigin:{vertical:"bottom",horizontal:"right"},transformOrigin:{vertical:"top",horizontal:"right"},PaperProps:{sx:{mt:.5,minWidth:180,borderRadius:1.5,boxShadow:"0 4px 16px rgba(15,23,42,0.1)"}},children:e.map((r,c)=>[r.divider&&c>0?o(u,{},`d-${r.key}`):null,a(g,{disabled:r.disabled,onClick:d=>{d.stopPropagation(),n(null),r.onClick()},sx:{fontSize:13,color:r.danger?"error.main":"text.primary"},children:[r.icon&&o(x,{sx:{color:"inherit",minWidth:32},children:r.icon}),o(b,{primaryTypographyProps:{fontSize:13},children:r.label})]},r.key)])})]})};export{k as R};
