import{j as r,B as l}from"./index-43bf7a1c.js";import{R as p}from"./componentStyles-4624000e.js";import{C as x}from"./index.esm-0548c843.js";/* empty css                   */import{I as h}from"./InputLabel-6c7474f0.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};
