import{Blockquote as e,Bold as t,BulletList as r,Document as l,Dropcursor as i,Gapcursor as o,HTML as n,HardBreak as d,Heading as s,History as u,HorizontalRule as a,Italic as p,Link as c,ListItem as g,Menu as b,NoSpellCheck as h,OrderedList as f,Paragraph as L,Strike as k,Subscript as B,Superscript as v,Table as S,TableCell as m,TableHeader as y,TableRow as _,Text as H,Typographic as O,Underline as T,createTextareaEditor as j,initializeEditors as w}from"django-prose-editor/editor";let z="data-django-prose-editor-default";function E(w){let E,q=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;if(w.closest(".prose-editor"))return;q||(q=JSON.parse(w.getAttribute(z)));let A=["Blockquote","Bold","BulletList","Heading","HorizontalRule","Italic","Link","OrderedList","Strike","Subscript","Superscript","Underline"],I=(E=q.types,function(){for(var e=arguments.length,t=Array(e),r=0;r<e;r++)t[r]=arguments[r];let l=(null==E?void 0:E.length)?E:A;return!!t.find(e=>l.includes(e))}),R=j(w,[l,i,o,L,d,H,q.history&&u,b,q.html&&n,h,q.typographic&&O,I("Blockquote")&&e,I("Bold","strong")&&t,I("BulletList","bullet_list")&&r,I("Heading")&&s.configure({levels:q.headingLevels||[1,2,3,4,5]}),I("HorizontalRule","horizontal_rule")&&a,I("Italic","em")&&p,I("Link","link")&&c,I("BulletList","bullet_list","OrderedList","ordered_list")&&g,I("OrderedList","ordered_list")&&f,I("Strike","strikethrough")&&k,I("Subscript","sub")&&B,I("Superscript","sup")&&v,I("Underline")&&T,I("Table")&&S,I("Table")&&_,I("Table")&&y,I("Table")&&m].filter(Boolean)),U=new CustomEvent("prose-editor:ready",{detail:{editor:R,textarea:w},bubbles:!0});return w.dispatchEvent(U),R}w(e=>E(e),`[${z}]`),window.DjangoProseEditor={createEditor:E};
//# sourceMappingURL=default.js.map