import{j as r,B as l}from"./index-d2b25495.js";import{R as p}from"./componentStyles-0e851d91.js";import{C as x}from"./index.esm-ce3c2c20.js";/* empty css                   */import{I as h}from"./InputLabel-bb6ab40e.js";const v=({control:n,name:e,overrideModule:a,label:c,onChange:o,required:d,styles:m})=>{const u={toolbar:[[{font:[]},{size:[]}],["bold","italic","underline","strike"],[{color:[]},{background:[]}],[{script:"super"},{script:"sub"}],[{header:[!1,1,2,3,4,5,6]},"blockquote","code-block"],[{list:"ordered"},{list:"bullet"},{indent:"-1"},{indent:"+1"}],["direction",{align:[]}],["link","image","video"],["clean"]],...a};return r.jsx(l,{sx:{display:"flex",flexDirection:"column",gap:"24px"},children:r.jsx(x,{name:e,control:n,render:({field:t,fieldState:s})=>r.jsxs(l,{children:[r.jsx(h,{sx:{".MuiInputLabel-asterisk":{color:"red"}},required:d,htmlFor:e,style:{fontWeight:"medium"},error:s.error!=null,children:c}),r.jsx(p,{modules:u,theme:"snow",value:t.value||"",onChange:i=>{o&&o(i),t.onChange(i)},className:`${s.error?"editor-error":""}`,style:{height:"200px",marginBottom:"50px",...m}})]})})})};export{v as E};
