import{r as h,j as l,b as n,bx as p,o as m,a6 as u,R as b,bm as x,bn as g,bl as f,F as y}from"./index-ktJf6c6X.js";const v=({actions:s,size:t="small"})=>{const[i,o]=h.useState(null),a=!!i,e=s.filter(r=>!r.hidden);return e.length===0?null:l(y,{children:[n(m,{size:t,onClick:r=>{r.stopPropagation(),o(r.currentTarget)},children:n(p,{fontSize:t})}),n(f,{anchorEl:i,open:a,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,l(b,{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(g,{primaryTypographyProps:{fontSize:13},children:r.label})]},r.key)])})]})};export{v as R};
