import{r as h,j as a,b as n,af as p,p as m,aK as u,a6 as g,a9 as x,ab as b,a8 as f,J as y}from"./index-CYy8zBsj.js";const v=({actions:l,size:t="small"})=>{const[i,o]=h.useState(null),s=!!i,e=l.filter(r=>!r.hidden);return e.length===0?null:a(y,{children:[n(m,{size:t,onClick:r=>{r.stopPropagation(),o(r.currentTarget)},children:n(p,{fontSize:t})}),n(f,{anchorEl:i,open:s,onClose:()=>o(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?n(u,{},`d-${r.key}`):null,a(g,{disabled:r.disabled,onClick:d=>{d.stopPropagation(),o(null),r.onClick()},sx:{fontSize:13,color:r.danger?"error.main":"text.primary"},children:[r.icon&&n(x,{sx:{color:"inherit",minWidth:32},children:r.icon}),n(b,{primaryTypographyProps:{fontSize:13},children:r.label})]},r.key)])})]})};export{v as R};
