import{r as d,D as o,ce as l,cf as c,cg as m,J as s}from"./vendor-D8aaNQoj.js";import{V as p}from"./index-DLF6D3Tj.js";import{bA as f}from"./LogPanel-BfaE547X.js";import"./helpers-BosuxZz1.js";import"./index-BweOkQpw.js";function u(e,r,t){return(r=g(r))in e?Object.defineProperty(e,r,{value:t,enumerable:!0,configurable:!0,writable:!0}):e[r]=t,e}function g(e){var r=v(e,"string");return typeof r=="symbol"?r:r+""}function v(e,r){if(typeof e!="object"||!e)return e;var t=e[Symbol.toPrimitive];if(t!==void 0){var n=t.call(e,r||"default");if(typeof n!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(r==="string"?String:Number)(e)}var h=e=>{var{children:r,inline:t,className:n}=e;if(t===!0)return o.jsx("code",{children:s.Children.map(r,i=>typeof i=="string"?i.trim():i)});var a=n!=null&&n!==void 0&&n.startsWith("language-")?n.substring(9):"plaintext";return o.jsx("pre",{children:o.jsx("code",{children:o.jsx(f,{language:a,children:s.Children.map(r,i=>typeof i=="string"?i.trim():i)})})})};class x extends d.PureComponent{constructor(r){super(r),u(this,"container",void 0),this.container=null}render(){var{isEditing:r,content:t,onEditorInitialized:n}=this.props;return o.jsx("div",{className:"markdown-editor-container",ref:a=>{this.container=a},children:r?o.jsx(p,{settings:{language:"markdown",value:t,lineNumbers:"off"},onEditorInitialized:n}):o.jsx(l,{components:{code:h},remarkPlugins:[c],rehypePlugins:[m],children:t})})}}u(x,"defaultProps",{isEditing:!1,content:""});export{x as default};
//# sourceMappingURL=MarkdownEditor-0v5KKRNJ.js.map
