import{O as A,ao as r,bi as n}from"./index-DlNZgIG9.js";const E=({onSubmit:t,submitLabel:a="Submit",submitBtnType:c="submit",extraButtons:u=[],disabled:d=!1,visible:p=!0,position:m="sticky",bottom:f=0,left:b=0,right:x,top:y,zIndex:h=99,width:k="100%",height:T,gap:o=8,padding:l="12px 24px",justifyContent:j="flex-end",alignItems:C="center",backgroundColor:q,borderTop:v,backdropFilter:F="blur(100px)",customStyle:N={},className:S,id:$})=>{const i=A().palette.mode==="dark";if(!p)return null;const g=()=>{var e;if(t==="submit"){const s=document.querySelector("form");s?(e=s.requestSubmit)==null||e.call(s):console.warn("No form found to submit")}else typeof t=="function"&&t()},w={position:m,bottom:f,left:b,right:x,top:y,width:k,height:T,zIndex:h,display:"flex",justifyContent:j,alignItems:C,gap:typeof o=="number"?`${o}px`:o,padding:typeof l=="number"?`${l}px`:l,backdropFilter:F,borderTop:v||(i?"1px solid #444":"1px solid #eee"),backgroundColor:q||(i?"rgba(0,0,0,0.8)":"rgba(255,255,255,0.9)"),...N};return r.jsxs("div",{className:S,id:$,style:w,children:[u.map((e,s)=>e.visible===!1?null:r.jsx(n,{btnType:e.btnType,onClick:e.onClick,disabled:e.disabled,children:e.label},s)),t&&r.jsx(n,{btnType:c,onClick:g,disabled:d,children:a})]})};export{E as F};
