/*! * @toast-ui/editor * @version 3.2.2 | Fri Feb 17 2023 * @author NHN Cloud FE Development Lab * @license MIT */ !function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t():"function"==typeof define&&define.amd?define([],t):"object"==typeof exports?exports.toastui=t():(e.toastui=e.toastui||{},e.toastui.Editor=t())}(self,(function(){return function(){var e={368:function(e){ /*! @license DOMPurify 2.3.3 | (c) Cure53 and other contributors | Released under the Apache license 2.0 and Mozilla Public License 2.0 | github.com/cure53/DOMPurify/blob/2.3.3/LICENSE */ e.exports=function(){"use strict";function e(e){if(Array.isArray(e)){for(var t=0,n=Array(e.length);t1?n-1:0),o=1;o/gm),q=a(/^data-[\-\w.\u00B7-\uFFFF]/),V=a(/^aria-[\-\w]+$/),j=a(/^(?:(?:(?:f|ht)tps?|mailto|tel|callto|cid|xmpp):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i),$=a(/^(?:\w+script|data):/i),_=a(/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g),U="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e};function W(e){if(Array.isArray(e)){for(var t=0,n=Array(e.length);t0&&void 0!==arguments[0]?arguments[0]:J(),t=function(e){return K(e)};if(t.version="2.3.3",t.removed=[],!e||!e.document||9!==e.document.nodeType)return t.isSupported=!1,t;var n=e.document,r=e.document,o=e.DocumentFragment,i=e.HTMLTemplateElement,a=e.Node,l=e.Element,c=e.NodeFilter,u=e.NamedNodeMap,d=void 0===u?e.NamedNodeMap||e.MozNamedAttrMap:u,x=e.Text,C=e.Comment,Z=e.DOMParser,X=e.trustedTypes,Q=l.prototype,Y=S(Q,"cloneNode"),ee=S(Q,"nextSibling"),te=S(Q,"childNodes"),ne=S(Q,"parentNode");if("function"==typeof i){var re=r.createElement("template");re.content&&re.content.ownerDocument&&(r=re.content.ownerDocument)}var oe=G(X,n),ie=oe&&Fe?oe.createHTML(""):"",se=r,ae=se.implementation,le=se.createNodeIterator,ce=se.createDocumentFragment,ue=se.getElementsByTagName,de=n.importNode,pe={};try{pe=M(r).documentMode?r.documentMode:{}}catch(e){}var he={};t.isSupported="function"==typeof ne&&ae&&void 0!==ae.createHTMLDocument&&9!==pe;var fe=H,me=z,ge=q,ve=V,ye=$,be=_,we=j,ke=null,xe=T({},[].concat(W(E),W(N),W(O),W(A),W(I))),Ce=null,Te=T({},[].concat(W(R),W(P),W(B),W(F))),Me=null,Se=null,Ee=!0,Ne=!0,Oe=!1,De=!1,Ae=!1,Le=!1,Ie=!1,Re=!1,Pe=!1,Be=!0,Fe=!1,He=!0,ze=!0,qe=!1,Ve={},je=null,$e=T({},["annotation-xml","audio","colgroup","desc","foreignobject","head","iframe","math","mi","mn","mo","ms","mtext","noembed","noframes","noscript","plaintext","script","style","svg","template","thead","title","video","xmp"]),_e=null,Ue=T({},["audio","video","img","source","image","track"]),We=null,Je=T({},["alt","class","for","id","label","name","pattern","placeholder","role","summary","title","value","style","xmlns"]),Ge="http://www.w3.org/1998/Math/MathML",Ke="http://www.w3.org/2000/svg",Ze="http://www.w3.org/1999/xhtml",Xe=Ze,Qe=!1,Ye=void 0,et=["application/xhtml+xml","text/html"],tt="text/html",nt=void 0,rt=null,ot=r.createElement("form"),it=function(e){rt&&rt===e||(e&&"object"===(void 0===e?"undefined":U(e))||(e={}),e=M(e),ke="ALLOWED_TAGS"in e?T({},e.ALLOWED_TAGS):xe,Ce="ALLOWED_ATTR"in e?T({},e.ALLOWED_ATTR):Te,We="ADD_URI_SAFE_ATTR"in e?T(M(Je),e.ADD_URI_SAFE_ATTR):Je,_e="ADD_DATA_URI_TAGS"in e?T(M(Ue),e.ADD_DATA_URI_TAGS):Ue,je="FORBID_CONTENTS"in e?T({},e.FORBID_CONTENTS):$e,Me="FORBID_TAGS"in e?T({},e.FORBID_TAGS):{},Se="FORBID_ATTR"in e?T({},e.FORBID_ATTR):{},Ve="USE_PROFILES"in e&&e.USE_PROFILES,Ee=!1!==e.ALLOW_ARIA_ATTR,Ne=!1!==e.ALLOW_DATA_ATTR,Oe=e.ALLOW_UNKNOWN_PROTOCOLS||!1,De=e.SAFE_FOR_TEMPLATES||!1,Ae=e.WHOLE_DOCUMENT||!1,Re=e.RETURN_DOM||!1,Pe=e.RETURN_DOM_FRAGMENT||!1,Be=!1!==e.RETURN_DOM_IMPORT,Fe=e.RETURN_TRUSTED_TYPE||!1,Ie=e.FORCE_BODY||!1,He=!1!==e.SANITIZE_DOM,ze=!1!==e.KEEP_CONTENT,qe=e.IN_PLACE||!1,we=e.ALLOWED_URI_REGEXP||we,Xe=e.NAMESPACE||Ze,Ye=Ye=-1===et.indexOf(e.PARSER_MEDIA_TYPE)?tt:e.PARSER_MEDIA_TYPE,nt="application/xhtml+xml"===Ye?function(e){return e}:m,De&&(Ne=!1),Pe&&(Re=!0),Ve&&(ke=T({},[].concat(W(I))),Ce=[],!0===Ve.html&&(T(ke,E),T(Ce,R)),!0===Ve.svg&&(T(ke,N),T(Ce,P),T(Ce,F)),!0===Ve.svgFilters&&(T(ke,O),T(Ce,P),T(Ce,F)),!0===Ve.mathMl&&(T(ke,A),T(Ce,B),T(Ce,F))),e.ADD_TAGS&&(ke===xe&&(ke=M(ke)),T(ke,e.ADD_TAGS)),e.ADD_ATTR&&(Ce===Te&&(Ce=M(Ce)),T(Ce,e.ADD_ATTR)),e.ADD_URI_SAFE_ATTR&&T(We,e.ADD_URI_SAFE_ATTR),e.FORBID_CONTENTS&&(je===$e&&(je=M(je)),T(je,e.FORBID_CONTENTS)),ze&&(ke["#text"]=!0),Ae&&T(ke,["html","head","body"]),ke.table&&(T(ke,["tbody"]),delete Me.tbody),s&&s(e),rt=e)},st=T({},["mi","mo","mn","ms","mtext"]),at=T({},["foreignobject","desc","title","annotation-xml"]),lt=T({},N);T(lt,O),T(lt,D);var ct=T({},A);T(ct,L);var ut=function(e){var t=ne(e);t&&t.tagName||(t={namespaceURI:Ze,tagName:"template"});var n=m(e.tagName),r=m(t.tagName);if(e.namespaceURI===Ke)return t.namespaceURI===Ze?"svg"===n:t.namespaceURI===Ge?"svg"===n&&("annotation-xml"===r||st[r]):Boolean(lt[n]);if(e.namespaceURI===Ge)return t.namespaceURI===Ze?"math"===n:t.namespaceURI===Ke?"math"===n&&at[r]:Boolean(ct[n]);if(e.namespaceURI===Ze){if(t.namespaceURI===Ke&&!at[r])return!1;if(t.namespaceURI===Ge&&!st[r])return!1;var o=T({},["title","style","font","a","script"]);return!ct[n]&&(o[n]||!lt[n])}return!1},dt=function(e){f(t.removed,{element:e});try{e.parentNode.removeChild(e)}catch(t){try{e.outerHTML=ie}catch(t){e.remove()}}},pt=function(e,n){try{f(t.removed,{attribute:n.getAttributeNode(e),from:n})}catch(e){f(t.removed,{attribute:null,from:n})}if(n.removeAttribute(e),"is"===e&&!Ce[e])if(Re||Pe)try{dt(n)}catch(e){}else try{n.setAttribute(e,"")}catch(e){}},ht=function(e){var t=void 0,n=void 0;if(Ie)e=""+e;else{var o=g(e,/^[\r\n\t ]+/);n=o&&o[0]}"application/xhtml+xml"===Ye&&(e=''+e+"");var i=oe?oe.createHTML(e):e;if(Xe===Ze)try{t=(new Z).parseFromString(i,Ye)}catch(e){}if(!t||!t.documentElement){t=ae.createDocument(Xe,"template",null);try{t.documentElement.innerHTML=Qe?"":i}catch(e){}}var s=t.body||t.documentElement;return e&&n&&s.insertBefore(r.createTextNode(n),s.childNodes[0]||null),Xe===Ze?ue.call(t,Ae?"html":"body")[0]:Ae?t.documentElement:s},ft=function(e){return le.call(e.ownerDocument||e,e,c.SHOW_ELEMENT|c.SHOW_COMMENT|c.SHOW_TEXT,null,!1)},mt=function(e){return!(e instanceof x||e instanceof C||"string"==typeof e.nodeName&&"string"==typeof e.textContent&&"function"==typeof e.removeChild&&e.attributes instanceof d&&"function"==typeof e.removeAttribute&&"function"==typeof e.setAttribute&&"string"==typeof e.namespaceURI&&"function"==typeof e.insertBefore)},gt=function(e){return"object"===(void 0===a?"undefined":U(a))?e instanceof a:e&&"object"===(void 0===e?"undefined":U(e))&&"number"==typeof e.nodeType&&"string"==typeof e.nodeName},vt=function(e,n,r){he[e]&&p(he[e],(function(e){e.call(t,n,r,rt)}))},yt=function(e){var n=void 0;if(vt("beforeSanitizeElements",e,null),mt(e))return dt(e),!0;if(g(e.nodeName,/[\u0080-\uFFFF]/))return dt(e),!0;var r=nt(e.nodeName);if(vt("uponSanitizeElement",e,{tagName:r,allowedTags:ke}),!gt(e.firstElementChild)&&(!gt(e.content)||!gt(e.content.firstElementChild))&&w(/<[/\w]/g,e.innerHTML)&&w(/<[/\w]/g,e.textContent))return dt(e),!0;if("select"===r&&w(/