jodit-pro 1.2.48 → 1.2.49
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/build/jodit.es5.css +1 -1
- package/build/jodit.es5.js +1 -1
- package/build/jodit.fat.es5.js +1 -1
- package/build/jodit.fat.js +1 -1
- package/build/jodit.js +1 -1
- package/build/plugins/autocomplete/autocomplete.js +1 -1
- package/build/plugins/backup/backup.js +1 -1
- package/build/plugins/button-generator/button-generator.js +1 -1
- package/build/plugins/change-case/change-case.js +1 -1
- package/build/plugins/color-picker/color-picker.js +1 -1
- package/build/plugins/emoji/emoji.js +1 -1
- package/build/plugins/export-docs/export-docs.js +1 -1
- package/build/plugins/finder/finder.js +1 -1
- package/build/plugins/google-maps/google-maps.js +1 -1
- package/build/plugins/google-search/google-search.js +1 -1
- package/build/plugins/highlight-signature/highlight-signature.js +1 -1
- package/build/plugins/iframe-editor/iframe-editor.js +1 -1
- package/build/plugins/keyboard/keyboard.js +1 -1
- package/build/plugins/page-break/page-break.js +1 -1
- package/build/plugins/paste-code/paste-code.js +1 -1
- package/build/plugins/paste-from-word/paste-from-word.es5.js +1 -1
- package/build/plugins/paste-from-word/paste-from-word.js +1 -1
- package/build/plugins/show-blocks/show-blocks.js +1 -1
- package/build/plugins/tune-block/tune-block.js +1 -1
- package/index.html +5 -1
- package/package.json +1 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
((e,t)=>{if("object"==typeof exports&&"object"==typeof module)module.exports=t();else if("function"==typeof define&&define.amd)define([],t);else{var a=t();for(var s in a)("object"==typeof exports?exports:e)[s]=a[s]}})(self,(function(){return(self.webpackChunkjodit_pro=self.webpackChunkjodit_pro||[]).push([[535],{
|
|
1
|
+
((e,t)=>{if("object"==typeof exports&&"object"==typeof module)module.exports=t();else if("function"==typeof define&&define.amd)define([],t);else{var a=t();for(var s in a)("object"==typeof exports?exports:e)[s]=a[s]}})(self,(function(){return(self.webpackChunkjodit_pro=self.webpackChunkjodit_pro||[]).push([[535],{236(e,t,a){"use strict";a.r(t),a.d(t,{pasteCode:()=>p});var s=a(197),o=a(2),i=a(10);o.D.prototype.controls.pasteCode={icon:a(237),tooltip:"Paste code",command:"pasteCode"},o.D.prototype.pasteCode={globalHighlightLib:!1,canonicalLanguageCode(e){switch(e){case"ts":return"typescript";case"js":return"javascript";case"markup":return"html"}return e},highlightLib:{highlight(e,t){return Prism.highlight(e,Prism.languages[t]||Prism.languages.plain,t)},isLangLoaded(e){return!!Prism.languages[e]},js:["https://cdnjs.cloudflare.com/ajax/libs/prism/1.25.0/prism.min.js"],langUrl:e=>`https://cdnjs.cloudflare.com/ajax/libs/prism/1.25.0/components/prism-${e}.min.js`,css:["https://cdnjs.cloudflare.com/ajax/libs/prism/1.25.0/themes/prism.min.css"]},defaultLanguage:"html",insertTemplate:(e,t,a)=>`<pre class="language-${t}">${(0,i.htmlspecialchars)(a)}</pre>`,languages:[{value:"html",text:"HTML/XML"},{value:"plaintext",text:"Plain"},{value:"bash",text:"Bash"},{value:"javascript",text:"JavaScript"},{value:"css",text:"CSS"},{value:"php",text:"PHP"},{value:"ruby",text:"Ruby"},{value:"python",text:"Python"},{value:"java",text:"Java"},{value:"c",text:"C"},{value:"csharp",text:"C#"},{value:"cpp",text:"C++"}],dialog:{width:700,height:600}};var l=a(70),r=a(42),n=a(19),c=a(1),d=a(4);let p=class extends l.S{constructor(){super(...arguments),this.requires=["license"],this.buttons=[{name:"pasteCode",group:"clipboard"}],this.prismJSIsLoaded=!1}afterInit(e){e.registerCommand("pasteCode",(()=>this.openCodeEditDialog()))}openCodeEditDialog(e,t,a){const s=this.j,o=this.createForm(),{code:l,language:r}=(0,i.refs)(o);e&&(r.value=e),t&&(l.value=t),s.async.requestIdleCallback((()=>{l.focus()})),s.s.save(),this.createDialog((()=>{if(!o.validate())return!1;{s.s.restore();const e=s.createInside.fromHTML(s.o.pasteCode.insertTemplate(s,r.value,l.value));if(a)d.Dom.replace(a,e,s.createInside,!1,!0);else{const t=s.s.current(),a=d.Dom.up(t,d.Dom.isBlock,s.editor);a?d.Dom.after(a,e):s.s.insertNode(e)}this.onChange()}}),(()=>{s.s.restore()})).setContent(o.container).open(!0)}beforeDestruct(e){}createForm(){const{jodit:e}=this;return new r.x4(e,[new r.Cj(e,{name:"language",label:"Language",value:e.o.pasteCode.defaultLanguage,options:e.o.pasteCode.languages,required:!0}),new r.GJ(e,{label:"Code view",resizable:!1,name:"code",required:!0,className:"jodit-paste-code__textarea"})],{className:"jodit-paste-code"})}createDialog(e,t){const a=new d.Dialog({language:this.j.o.language});return a.setHeader("Insert/Edit Code Sample").setSize(this.j.o.pasteCode.dialog.width,this.j.o.pasteCode.dialog.height).setFooter([(0,r.zx)(a,"","Cancel","default").onAction((()=>{a.close(),t()})),(0,r.zx)(a,"save","Save","primary").onAction((()=>{a.close(),e()}))]),a}onChange(){(0,i.$$)("pre",this.j.editor).forEach((e=>{(0,i.attr)(e,"contenteditable")||((0,i.attr)(e,"contenteditable",!1),this.highlightCode(e))}))}async highlightCode(e){const{globalHighlightLib:t,highlightLib:{css:a,js:s,langUrl:o,highlight:l,isLangLoaded:r}}=this.j.o.pasteCode;this.prismJSIsLoaded||t||(await Promise.all([(0,i.loadNextStyle)(this.jodit,a),(0,i.loadNext)(this.jodit,s)]),this.prismJSIsLoaded=!0);const n=this.parseLanguage(e);r(n)||t||await(0,i.appendScriptAsync)(this.jodit,o(n)).catch((()=>null));let c=e;e.firstElementChild===e.lastElementChild&&d.Dom.isTag(e.firstElementChild,"code")&&(c=e.firstElementChild),c.innerHTML=l(c.innerText,n)}onPreEdit(e){const t=d.Dom.isNode(e)&&d.Dom.isTag(e,"pre")?e:d.Dom.closest(e.target,"pre",this.j.editor);if(t){const e=this.parseLanguage(t);this.openCodeEditDialog(e,t.innerText,t)}}parseLanguage(e){let t=null;const a=e=>e.classList.forEach((e=>{if(/language-/.test(e)){const a=/language-(.*)/.exec(e);a&&a[1]&&(t=a[1])}}));return a(e),null==t&&e.firstElementChild===e.lastElementChild&&d.Dom.isTag(e.firstElementChild,"code")&&a(e.firstElementChild),this.jodit.o.pasteCode.canonicalLanguageCode(t||"html")}onAfterGetValueFromEditor(e){e.value=e.value.replace(/(<pre[^>]*)contenteditable\s*=\s*(['"]?)false\2([^>]*>\s*<code[^>]*>)(.*?)(<\/code>\s*<\/pre>)/gis,((e,t,a,s,o,l)=>`${t}${s}${(0,i.htmlspecialchars)((0,i.stripTags)(o))}${l}`)).replace(/(<pre[^>]*)contenteditable\s*=\s*(['"]?)false\2([^>]*>)(.*?)(<\/pre>)/gis,((e,t,a,s,o,l)=>`${t}${s}${(0,i.htmlspecialchars)((0,i.stripTags)(o))}${l}`))}};(0,s.gn)([n.autobind],p.prototype,"openCodeEditDialog",null),(0,s.gn)([(0,n.watch)("?:change"),(0,n.debounce)()],p.prototype,"onChange",null),(0,s.gn)([(0,n.watch)(["?:dblclick","?:editPreInPasteCode"])],p.prototype,"onPreEdit",null),(0,s.gn)([(0,n.watch)("?:afterGetValueFromEditor")],p.prototype,"onAfterGetValueFromEditor",null),p=(0,s.gn)([n.component],p),c.Jodit.plugins.add("paste-code",p)},197(e,t,a){"use strict";function s(e,t,a,s){var o,i=arguments.length,l=3>i?t:null===s?s=Object.getOwnPropertyDescriptor(t,a):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)l=Reflect.decorate(e,t,a,s);else for(var r=e.length-1;r>=0;r--)(o=e[r])&&(l=(3>i?o(l):i>3?o(t,a,l):o(t,a))||l);return i>3&&l&&Object.defineProperty(t,a,l),l}a.d(t,{gn:()=>s})},237(e){e.exports='<svg viewBox="0 0 24 24" xml:space="preserve" xmlns="http://www.w3.org/2000/svg"> <path d="M2.5244141,23.5h18.9511719c0.4140625,0,0.75-0.3359375,0.75-0.75V4.9208984 c0-0.1992188-0.0795898-0.390625-0.2207031-0.53125L18.3198242,0.71875C18.1791992,0.5786133,17.9887695,0.5,17.7905273,0.5 H2.5244141c-0.4140625,0-0.75,0.3359375-0.75,0.75v21.5C1.7744141,23.1640625,2.1103516,23.5,2.5244141,23.5z M20.7128296,5.2197266 h-2.6986694V2.531189L20.7128296,5.2197266z M3.2744141,2h13.2397461v3.9697266c0,0.4140625,0.3359375,0.75,0.75,0.75h3.4614258V22 H3.2744141V2z" fill="#1D1D1D"/> <path d="M8.75,10.25h1.75c0.4140625,0,0.75-0.3359375,0.75-0.75s-0.3359375-0.75-0.75-0.75H8 c-0.4140625,0-0.75,0.3359375-0.75,0.75v2.75H6c-0.4140625,0-0.75,0.3359375-0.75,0.75S5.5859375,13.75,6,13.75h1.25v2.75 c0,0.4140625,0.3359375,0.75,0.75,0.75h2.5c0.4140625,0,0.75-0.3359375,0.75-0.75s-0.3359375-0.75-0.75-0.75H8.75V10.25z" fill="#1D1D1D"/> <path d="M18.5,12.25h-1.25V9.5c0-0.4140625-0.3359375-0.75-0.75-0.75H14c-0.4140625,0-0.75,0.3359375-0.75,0.75 s0.3359375,0.75,0.75,0.75h1.75v5.5H14c-0.4140625,0-0.75,0.3359375-0.75,0.75s0.3359375,0.75,0.75,0.75h2.5 c0.4140625,0,0.75-0.3359375,0.75-0.75v-2.75h1.25c0.4140625,0,0.75-0.3359375,0.75-0.75S18.9140625,12.25,18.5,12.25z" fill="#1D1D1D"/></svg>'}},e=>e(e.s=236)])}));
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";!function(e,t){if("object"==typeof exports&&"object"==typeof module)module.exports=t();else if("function"==typeof define&&define.amd)define([],t);else{var r=t();for(var n in r)("object"==typeof exports?exports:e)[n]=r[n]}}(self,(function(){return(self.webpackChunkjodit_pro=self.webpackChunkjodit_pro||[]).push([[92],{835:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),r(120).Config.prototype.pasteFromWordHeuristic=!1},816:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.applyStylesPro=void 0;var n=r(131),i=r(145),o=r(817),a=r(821);t.applyStylesPro=function(e,t){var r,u,l=document.createElement("iframe");l.style.display="none",document.body.appendChild(l);try{var s=null!==(r=l.contentDocument)&&void 0!==r?r:null===(u=l.contentWindow)||void 0===u?void 0:u.document;if(!s)return e;s.open(),s.write(e),s.close();for(var c=function(e){try{for(var t=s.styleSheets[e].cssRules,r=function(e){if(!t[e].selectorText)return"continue";(0,n.$$)(t[e].selectorText,s.body).forEach((function(r){r.setAttribute("style","".concat(t[e].style.cssText,";").concat(r.getAttribute("style")))}))},i=0;t.length>i;i+=1)r(i)}catch(e){}},f=0;s.styleSheets.length>f;f+=1)c(f);return(0,o.transformWordToHtml)(a.JElement.make(s.body),t)}finally{i.Dom.safeRemove(l)}return e}},825:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.clearAttributes=void 0;var n=r(1),i=["cellspacing","cellpadding","border","v:shapes","o:spid"];t.clearAttributes=function(e){var t,r;if(/^OLE_LINK\d+$/.test(e.attributes.name)&&(e.attributes.name=null,0===e.length))return e.remove(),null;"_GoBack"===e.attributes.name&&(e.attributes.name=null);try{for(var o=n.__values(i),a=o.next();!a.done;a=o.next()){var u=a.value;e.attributes[u]&&(e.attributes[u]=null)}}catch(e){t={error:e}}finally{try{a&&!a.done&&(r=o.return)&&r.call(o)}finally{if(t)throw t.error}}return e}},830:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.clearClassName=void 0;var n=r(204);t.clearClassName=function(e){return e.attributes.class&&(e.attributes.class=e.attributes.class.replace(/(el\d+)|(font\d+)|msonormal|msolistparagraph\w*/gi,""),(0,n.trim)(e.attributes.class)||(e.attributes.class=null)),e}},829:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.convertStyleUnitToPixels=void 0;var n=r(820);t.convertStyleUnitToPixels=function(e){var t=e.style;return Object.keys(t).map((function(e){t[e]&&(t[e]=t[e].replace(/\d+(\.\d+)?(pt|cm)/g,(function(e){return(0,n.convertUnitToPx)(e)+"px"})))})),e}},819:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.convertToList=void 0;var n=r(1),i=r(820),o=r(821),a=r(824),u="jd-list-level",l="jd-list-type",s="jd-list-style-type",c="list-style-type",f={"·":"disc",o:"circle","§":"square","[ivx]":"lower-roman","[IVX]":"upper-roman","[a-z]":"lower-alpha","[A-Z]":"upper-alpha","\\d":"decimal"};function d(e,t){return!(t.name!==e.attributes[l]||t.attributes[s]!==e.attributes[s]||e.attributes[u]!==t.attributes[u])}t.convertToList=function(e){var t;if((0,o.isPseudoLeaf)(e)){e.name="li",e.style["text-indent"]=null;var r=p(e),a=/[\da-np-zA-NP-Z].?/.test(r)?"ol":"ul",m=function(e){for(var t in f)if(RegExp(t).test(e))return f[t];return"inherit"}(r);e.attributes[l]=a,e.attributes[s]=m,function(e){if(void 0===e.attributes[u]){for(var t=[(0,i.realPixelIndent)(e)],r=[e],a=e.next;a;){if(a.isElement&&!a.attributes[u]&&(0,o.isPseudoLeaf)(a)){var l=(0,i.realPixelIndent)(a);l&&(t.push(l),r.push(a))}a=a.next}var s=Math.min.apply(Math,n.__spreadArray([],n.__read(t.filter((function(e){return e>0}))),!1)),c=t.map((function(e){return Math.ceil(e/s)}));-1!==c.indexOf(0)&&(c=c.map((function(e){return e+1}))),r.forEach((function(e,t){e.attributes[u]=c[t],e.style["margin-left"]&&(e.style["margin-left"]=Math.max((0,i.convertUnitToPx)(e.style["margin-left"])-40*c[t],0)+"px")}))}}(e),function(e){for(;e;){var t=e.previousElement;if(!(0,o.isLeaf)(t)&&!(0,o.isList)(t))break;if((0,o.isLeaf)(t)){if(t.attributes[u]>e.attributes[u])break;if(e.attributes[u]===t.attributes[u]&&e.parent&&d(e,e.parent))break;t.append(e)}else{var r=t;if(r.attributes[u]>e.attributes[u])break;if(e.attributes[u]===r.attributes[u]&&!d(e,r))break;r.append(e)}}}(e);var v=e.parent;if(!(0,o.isList)(v)||!d(e,v)){var b=e.wrap(a);return b.attributes[u]=e.attributes[u],b.attributes[s]=e.attributes[s],b.style[c]=m,(0,o.isList)(v)&&(b.remove(),null===(t=v.lastElement)||void 0===t||t.append(b)),function(e){var t;!(0,o.isList)(e)||"li"===(null===(t=e.parent)||void 0===t?void 0:t.name)||"disc"!==e.style[c]&&"decimal"!==e.style[c]||(e.style[c]=null)}(b),e}}return e};var p=function(e){return e.textBetween((function(e){return e.isComment&&/\[if.*supportLists.*]/.test((0,a.html)(e))}),(function(e){return e.isComment&&/\[endif]/.test((0,a.html)(e))}))}},818:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.cases=void 0;var n=r(819),i=r(825),o=r(826),a=r(827),u=r(828),l=r(829),s=r(830),c=r(831),f=r(832),d=r(833),p=r(834);t.cases=[p.markPageBreakElements,o.removeExtraTags,a.replaceOldTags,i.clearAttributes,n.convertToList,c.processLinks,u.removeInsideComment,l.convertStyleUnitToPixels,s.clearClassName,f.normalizeImageProps,d.removeWidthFromTableCell]},834:function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.markPageBreakElements=void 0,t.markPageBreakElements=function(e){return(e.isElement&&"always"===e.style["page-break-before"]||"page"===e.style["break-before"])&&(e.attributes["jd-safe"]=!0,e.style["page-break-before"]="always",e.isSingle&&(e.name="div")),e}},832:function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.normalizeImageProps=void 0,t.normalizeImageProps=function(e){return e.isElement?("img"===e.name&&(e.attributes.align&&(e.style.float=e.attributes.align,e.attributes.align=null),e.attributes.hspace&&(e.style.marginLeft=e.attributes.hspace+"px",e.style.marginRight=e.attributes.hspace+"px",e.attributes.hspace=null)),e):e}},831:function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.processLinks=void 0,t.processLinks=function(e,t){var r,n=null!==(r=t.links)&&void 0!==r?r:{};if(e.attributes.href&&e.attributes.href.match(/#.+$/)&&(n[e.attributes.href.match(/#(.+)$/)[1]]=e),e.attributes.name&&n[e.attributes.name]){var i=n[e.attributes.name];i.attributes.href=i.attributes.href.replace(/.*#(.*)$/,"#$1")}return t.links=n,e}},826:function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.removeExtraTags=void 0;var r=new Set(["o:p","xml","script","meta","link","v:imagedata","style"]);t.removeExtraTags=function(e){return"none"===e.style.display||0===e.length&&"span"===e.name||r.has(e.name)?(e.remove(),null):e}},828:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.removeInsideComment=void 0;var n=r(824),i=0;t.removeInsideComment=function(e){return e.isComment&&/\[if.*(supportLists|gte vml).*]/.test((0,n.html)(e))&&(i++,e.remove()),e.isComment&&i>0&&(0,n.html)(e).includes("[endif]")&&(i=i>0?i-1:0,e.remove()),e.isText&&i?(e.remove(),null):e}},827:function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.replaceOldTags=void 0;var r={i:"em",b:"strong"};t.replaceOldTags=function(e){var t=e.name;return t in r&&(e.name=r[t]),e}},833:function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.removeWidthFromTableCell=void 0,t.removeWidthFromTableCell=function(e){return!e.attributes.width||"th"!==e.name&&"td"!==e.name||(e.attributes.width=null),e}},822:function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.isPseudoLeaf=t.isLeaf=t.isList=void 0,t.isList=function(e){return Boolean(e&&("ol"===e.name||"ul"===e.name))},t.isLeaf=function(e){return Boolean(e&&"li"===e.name)},t.isPseudoLeaf=function(e){return/msolistparagraph/i.test(e.attributes.class)}},823:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.JElement=void 0;var n=r(1),i=r(145),o=r(204),a=r(203),u=r(121),l=r(131),s=r(824),c=new Set(u.INSEPARABLE_TAGS),f=function(){function e(t,r){var n=this;this.parent=r,this.name=t.nodeName.toLowerCase(),this.type=t.nodeType,this.attributes=e.readAttributes(t),this.style=e.readStyles(this.attributes.style),this.children=[],t.childNodes.forEach((function(t){return n.children.push(e.make(t,n))}))}return Object.defineProperty(e.prototype,"isText",{get:function(){return this.type===Node.TEXT_NODE},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"isElement",{get:function(){return this.type===Node.ELEMENT_NODE},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"isComment",{get:function(){return this.type===Node.COMMENT_NODE},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"isSingle",{get:function(){return c.has(this.name)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"styleStr",{get:function(){var e=this,t=Object.keys(this.style).filter((function(t){return t&&!/^mso-/.test(t)&&null!=e.style[t]}));return t.length?t.map((function(t){return"".concat((0,a.kebabCase)(t),":").concat(e.style[t])})).join(";"):""},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"length",{get:function(){return this.children.length},enumerable:!1,configurable:!0}),e.make=function(t,r){return void 0===r&&(r=null),new e(t,r)},e.prototype.wrap=function(t){var r;(0,l.assert)(null!=this.parent,"You can't wrap the root element");var n=e.make(document.createElement(t),this.parent),i=null!==(r=this.parent.children.indexOf(this))&&void 0!==r?r:-1;return-1===i?this.parent.append(n):this.parent.children[i]=n,n.append(this),n},e.prototype.append=function(e){return(0,l.assert)(e!==this,"Forbidden to add to yourself"),e.remove(),this.children.push(e),e.parent=this,this},Object.defineProperty(e.prototype,"previousElement",{get:function(){if(!this.parent)return null;var e=this.parent.children,t=e.indexOf(this);if(-1!==t)for(var r=t-1;r>=0;r-=1)if(e[r].isElement)return e[r];return null},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"lastElement",{get:function(){for(var e=this.children,t=e.length-1;t>=0;t-=1)if(e[t].isElement)return e[t];return null},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"previous",{get:function(){var e,t,r;return null!==(r=null!==(e=this.sibling(!1))&&void 0!==e?e:null===(t=this.parent)||void 0===t?void 0:t.previous)&&void 0!==r?r:null},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"next",{get:function(){var e,t,r;return null!==(r=null!==(e=this.sibling(!0))&&void 0!==e?e:null===(t=this.parent)||void 0===t?void 0:t.next)&&void 0!==r?r:null},enumerable:!1,configurable:!0}),e.prototype.sibling=function(e){if(!this.parent)return null;var t=this.parent.children,r=t.indexOf(this);return-1!==r&&t[r+(e?1:-1)]?t[r+(e?1:-1)]:null},e.readStyles=function(e){return(null!=e?e:"").split(";").filter(Boolean).map((function(e){return(0,o.trim)(e).split(":").map(o.trim)})).reduce((function(e,t){var r=n.__read(t,2),i=r[0],o=r[1];return i&&o&&(e[i]=o),e}),{})},e.readAttributes=function(e){var t={};if(i.Dom.isElement(e))for(var r=0,n=e.attributes;n.length>r;r+=1)t[n[r].name]=n[r].value;else t.nodeValue=e.nodeValue;return t},e.prototype.forEach=function(e,t){var r,i;void 0===t&&(t=!1);var o=n.__spreadArray([],n.__read(this.children),!1);try{for(var a=n.__values(o),u=a.next();!u.done;u=a.next()){var l=u.value;if(!1===e(l))return!1;if(t&&!1===l.forEach(e,!0))return!1}}catch(e){r={error:e}}finally{try{u&&!u.done&&(i=a.return)&&i.call(a)}finally{if(r)throw r.error}}},e.prototype.find=function(e,t){void 0===t&&(t=!1);var r=[];return this.forEach((function(t){e(t)&&r.push(t)}),t),r},e.prototype.map=function(e){return this.children.map(e)},e.prototype.remove=function(){var e,t,r=null===(e=this.parent)||void 0===e?void 0:e.children.indexOf(this);return null!=r&&-1!==r&&(null===(t=this.parent)||void 0===t||t.children.splice(r,1)),this},e.prototype.textBetween=function(e,t){var r=!1,n=[];return this.forEach((function(i){if(!r&&e(i)&&(r=!0),r&&i.isText&&n.push((0,s.html)(i)),r&&t(i))return!1}),!0),n.join("")},e}();t.JElement=f},821:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});var n=r(1);n.__exportStar(r(822),t),n.__exportStar(r(823),t)},824:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.innerHTML=t.html=void 0;var n=r(131);function i(e,t){switch(void 0===t&&(t=function(){return!0}),!0){case e.isComment:case e.isText:if(!t(e))return"";var r=e.attributes.nodeValue;return e.isComment?"\x3c!--".concat(r,"--\x3e"):r;case e.isElement:var i=e.attributes,u=o(e,t);if(!e.attributes["jd-safe"]&&0===(0,n.trim)(u).length&&!e.isSingle)return"";var l=Object.keys(i).map((function(e){return"style"===e||null==i[e]||/^jd-/.test(e)?"":"".concat(e,'="').concat(a(i[e]),'"')})).filter(Boolean),s=e.styleStr;if(s&&l.push('style="'.concat(a(s),'"')),0===l.length&&["span","a"].includes(e.name))return u;var c=l.length?" "+l.join(" "):"";return t(e)?e.isSingle?"<".concat(e.name).concat(c,"/>"):"<".concat(e.name).concat(c,">").concat(u,"</").concat(e.name,">"):u}return""}function o(e,t){void 0===t&&(t=function(){return!0});var r=e.map((function(e){return i(e,t)})).join("");return"p"===e.name&&0===(0,n.trim)(r).length&&(r="<br>"),r}function a(e){return e.toString().replace(/"/g,"'")}t.html=i,t.innerHTML=o},820:function(e,t){function r(e){if(!e)return[0,0,0,0];var t=e.match(/(0|auto|(-?[.\d]+(?:\w+|%)))/g)||["0px"];switch(t.length){case 2:return[0,1,0,1].map((function(e){return t[e]}));case 3:return[0,1,2,1].map((function(e){return t[e]}));case 4:return[0,1,2,3].map((function(e){return t[e]}));default:return[0,0,0,0].map((function(e){return t[e]}))}}var n;function i(e){if("number"==typeof e)return e;if(/%$/.test(e))return 0;n||(n=document.createElement("div"),Object.assign(n.style,{position:"absolute",left:"-9999px",top:"-9999px",margin:"0",padding:"0",border:"0"}),document.body.append(n),setTimeout((function(){null==n||n.remove(),n=null})));var t=0>parseFloat(e);t&&(e=e.replace("-","")),n.style.width=e;var r=n.clientWidth;return t?-r:r}Object.defineProperty(t,"__esModule",{value:!0}),t.realPixelIndent=t.convertUnitToPx=t.calcMarginParts=void 0,t.calcMarginParts=r,t.convertUnitToPx=i,t.realPixelIndent=function(e){var t=e.style,n=[0,0,0,0],o=t["margin-left"]||0;return!o&&t.margin&&(n=r(t.margin),t["margin-left"]=o=n[3]||0),i(o)}},817:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.transformWordToHtml=void 0;var n=r(1),i=r(818),o=r(204),a=r(824);t.transformWordToHtml=function(e,t){var r={};return e.forEach((function e(t){var o,a;if(t){try{for(var u=n.__values(i.cases),l=u.next();!l.done&&null!=(t=(0,l.value)(t,r));l=u.next());}catch(e){o={error:e}}finally{try{l&&!l.done&&(a=u.return)&&a.call(u)}finally{if(o)throw o.error}}null==t||t.forEach(e)}})),t&&e.forEach((function(e){e.style={}}),!0),(0,o.trim)((0,a.innerHTML)(e,(function(e){return!e.isComment})))}},815:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.PasteFromWordPro=void 0;var n=r(1),i=r(2),o=r(424),a=r(121),u=r(126),l=r(421),s=r(816);r(835);var c=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return n.__extends(t,e),t.prototype.insertFromWordByType=function(t,r,n){var i;if(!this.j.o.pasteFromWordHeuristic||n!==a.INSERT_AS_HTML&&n!==a.INSERT_AS_TEXT)return e.prototype.insertFromWordByType.call(this,t,r,n);if(r=(0,s.applyStylesPro)(r,n===a.INSERT_AS_TEXT),this.j.o.beautifyHTML){var o=null===(i=this.j.events)||void 0===i?void 0:i.fire("beautifyHTML",r);(0,u.isString)(o)&&(r=o)}(0,l.pasteInsertHtml)(t,this.j,r)},t}(o.PasteFromWord);t.PasteFromWordPro=c,i.Jodit.plugins.remove("pasteFromWord"),i.Jodit.plugins.add("pasteFromWordPro",c)}},function(e){return e(e.s=815)}])}));
|
|
1
|
+
"use strict";!function(e,t){if("object"==typeof exports&&"object"==typeof module)module.exports=t();else if("function"==typeof define&&define.amd)define([],t);else{var r=t();for(var n in r)("object"==typeof exports?exports:e)[n]=r[n]}}(self,(function(){return(self.webpackChunkjodit_pro=self.webpackChunkjodit_pro||[]).push([[92],{828:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.clearAttributes=void 0;var n=r(1),i=["cellspacing","cellpadding","border","v:shapes","o:spid"];t.clearAttributes=function(e){var t,r;if(/^OLE_LINK\d+$/.test(e.attributes.name)&&(e.attributes.name=null,0===e.length))return e.remove(),null;"_GoBack"===e.attributes.name&&(e.attributes.name=null);try{for(var o=n.__values(i),a=o.next();!a.done;a=o.next()){var l=a.value;e.attributes[l]&&(e.attributes[l]=null)}}catch(e){t={error:e}}finally{try{a&&!a.done&&(r=o.return)&&r.call(o)}finally{if(t)throw t.error}}return e}},833:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.clearClassName=void 0;var n=r(204);t.clearClassName=function(e){return e.attributes.class&&(e.attributes.class=e.attributes.class.replace(/(el\d+)|(font\d+)|msonormal|msolistparagraph\w*/gi,""),(0,n.trim)(e.attributes.class)||(e.attributes.class=null)),e}},832:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.convertStyleUnitToPixels=void 0;var n=r(816);t.convertStyleUnitToPixels=function(e,t){if(!t.jodit.o.pasteFromWord.convertUnitsToPixel)return e;var r=e.style;return r.forEach((function(e){var t=r.get(e);t&&r.set(e,t.toString().replace(/\d+(\.\d+)?(pt|cm)/g,(function(e){return(0,n.convertUnitToPx)(e)+"px"})))})),e}},821:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.convertToList=void 0;var n=r(816),i=r(822),o=r(121),a=r(825);t.convertToList=function(e){var t;if((0,i.isPseudoLeaf)(e)){e.name="li",e.style.set("text-indent",null);var r=l(e),o=/[\da-np-zA-NP-Z].?/.test(r)?"ol":"ul",u=function(e){for(var t in a.listStyleMap)if(RegExp(t).test(e))return a.listStyleMap[t];return null}(r);e.attributes[a.TYPE_KEY]=o,e.attributes[a.STYLE_KEY]=u,(0,n.calcListLevels)(e),function(e){for(;e;){var t=e.previousElement;if(!(0,i.isLeaf)(t)&&!(0,i.isList)(t))break;if((0,i.isLeaf)(t)){if(t.attributes[a.LEVEL_KEY]>e.attributes[a.LEVEL_KEY])break;if(e.attributes[a.LEVEL_KEY]===t.attributes[a.LEVEL_KEY]&&e.parent&&(0,i.isSameType)(e,e.parent))break;t.append(e)}else{var r=t;if(r.attributes[a.LEVEL_KEY]>e.attributes[a.LEVEL_KEY])break;if(e.attributes[a.LEVEL_KEY]===r.attributes[a.LEVEL_KEY]&&!(0,i.isSameType)(e,r))break;r.append(e)}}}(e);var s=e.parent;if(!(0,i.isList)(s)||!(0,i.isSameType)(e,s)){var c=function(e,t,r,o){var l=e.wrap(t);return l.attributes.start=(0,n.calcStartBySymbol)(r),l.attributes[a.LEVEL_KEY]=e.attributes[a.LEVEL_KEY],l.attributes[a.STYLE_KEY]=e.attributes[a.STYLE_KEY],l.style.set(a.STYLE_CSS_KEY,o),function(e){var t;!(0,i.isList)(e)||"li"===(null===(t=e.parent)||void 0===t?void 0:t.name)||"disc"!==e.style.get(a.STYLE_CSS_KEY)&&"decimal"!==e.style.get(a.STYLE_CSS_KEY)||e.style.set(a.STYLE_CSS_KEY,null)}(l),l}(e,o,r,u);return(0,i.isList)(s)&&(c.remove(),null===(t=s.lastElement)||void 0===t||t.append(c)),e}}return e};var l=function(e){return e.textBetween((function(e){return e.isComment&&/\[if.*supportLists.*]/.test((0,i.html)(e))}),(function(e){return e.isComment&&/\[endif]/.test((0,i.html)(e))})).replace(/ /g,"").replace((0,o.SPACE_REG_EXP)(),"")}},820:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.cases=void 0;var n=r(821),i=r(828),o=r(829),a=r(830),l=r(831),u=r(832),s=r(833),c=r(834),f=r(835),d=r(836),p=r(837);t.cases=[p.markPageBreakElements,o.removeExtraTags,a.replaceOldTags,i.clearAttributes,n.convertToList,c.processLinks,l.removeInsideComment,u.convertStyleUnitToPixels,s.clearClassName,f.normalizeImageProps,d.removeWidthFromTableCell]},837:function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.markPageBreakElements=void 0,t.markPageBreakElements=function(e){return(e.isElement&&"always"===e.style.get("page-break-before")||"page"===e.style.get("break-before"))&&(e.attributes["jd-safe"]=!0,e.style.add("page-break-before","always"),e.isSingle&&(e.name="div")),e}},835:function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.normalizeImageProps=void 0,t.normalizeImageProps=function(e){return e.isElement?("img"===e.name&&(e.attributes.align&&(e.style.add("float",e.attributes.align),e.attributes.align=null),e.attributes.hspace&&(e.style.add("marginLeft",e.attributes.hspace+"px"),e.style.add("marginRight",e.attributes.hspace+"px"),e.attributes.hspace=null)),e):e}},834:function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.processLinks=void 0,t.processLinks=function(e,t){var r,n=null!==(r=t.links)&&void 0!==r?r:{};if(e.attributes.href&&e.attributes.href.match(/#.+$/)&&(n[e.attributes.href.match(/#(.+)$/)[1]]=e),e.attributes.name&&n[e.attributes.name]){var i=n[e.attributes.name];i.attributes.href=i.attributes.href.replace(/.*#(.*)$/,"#$1")}return t.links=n,e}},829:function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.removeExtraTags=void 0;var r=new Set(["o:p","xml","script","meta","link","v:imagedata","style"]);t.removeExtraTags=function(e){return"none"===e.style.get("display")||0===e.length&&"span"===e.name||r.has(e.name)?(e.remove(),null):e}},831:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.removeInsideComment=void 0;var n=r(822),i=0;t.removeInsideComment=function(e){return e.isComment&&/\[if.*(supportLists|gte vml).*]/.test((0,n.html)(e))&&(i++,e.remove()),e.isComment&&i>0&&(0,n.html)(e).includes("[endif]")&&(i=i>0?i-1:0,e.remove()),e.isText&&i?(e.remove(),null):e}},830:function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.replaceOldTags=void 0;var r={i:"em",b:"strong"};t.replaceOldTags=function(e){var t=e.name;return t in r&&(e.name=r[t]),e}},836:function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.removeWidthFromTableCell=void 0,t.removeWidthFromTableCell=function(e){return!e.attributes.width||"th"!==e.name&&"td"!==e.name||(e.attributes.width=null),e}},839:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),r(120).Config.prototype.pasteFromWord={enable:!1,convertUnitsToPixel:!1}},825:function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.listStyleMap=t.STYLE_CSS_KEY=t.STYLE_KEY=t.TYPE_KEY=t.LEVEL_KEY=void 0,t.LEVEL_KEY="jd-list-level",t.TYPE_KEY="jd-list-type",t.STYLE_KEY="jd-list-style-type",t.STYLE_CSS_KEY="list-style-type",t.listStyleMap={"·":"disc",o:"circle","§":"square","[ivx]":"lower-roman","[IVX]":"upper-roman","[a-z]":"lower-alpha","[A-Z]":"upper-alpha","\\d":"decimal"}},823:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.isSameType=t.isPseudoLeaf=t.isLeaf=t.isList=void 0;var n=r(824),i=r(825);t.isList=function(e){return Boolean(e&&("ol"===e.name||"ul"===e.name))},t.isLeaf=function(e){return Boolean(e&&"li"===e.name)},t.isPseudoLeaf=function(e){return/mso-list:\s*l\d+ level\d+ lfo\d+/i.test(e.attributes.style)||/msolistparagraph/i.test(e.attributes.class)&&Boolean(e.find((function(e){return e.isComment&&(0,n.html)(e).includes("supportLists")})).length)},t.isSameType=function(e,t){return!(t.name!==e.attributes[i.TYPE_KEY]||t.attributes[i.STYLE_KEY]!==e.attributes[i.STYLE_KEY]||e.attributes[i.LEVEL_KEY]!==t.attributes[i.LEVEL_KEY])}},826:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.JElement=void 0;var n=r(1),i=r(145),o=r(121),a=r(131),l=r(824),u=r(827),s=new Set(o.INSEPARABLE_TAGS),c=function(){function e(t,r){var n=this;this.parent=r,this.name=t.nodeName.toLowerCase(),this.type=t.nodeType,this.attributes=function(e){var t={};if(i.Dom.isElement(e))for(var r=0,n=e.attributes;n.length>r;r+=1)t[n[r].name]=n[r].value;else t.nodeValue=e.nodeValue;return t}(t),this.style=new u.Style(this.attributes.style),this.children=[],t.childNodes.forEach((function(t){return n.children.push(e.make(t,n))}))}return Object.defineProperty(e.prototype,"isText",{get:function(){return this.type===Node.TEXT_NODE},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"html",{get:function(){return(0,l.html)(this)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"isElement",{get:function(){return this.type===Node.ELEMENT_NODE},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"isComment",{get:function(){return this.type===Node.COMMENT_NODE},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"isSingle",{get:function(){return s.has(this.name)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"length",{get:function(){return this.children.length},enumerable:!1,configurable:!0}),e.make=function(t,r){return void 0===r&&(r=null),new e(t,r)},e.prototype.wrap=function(t){var r;(0,a.assert)(null!=this.parent,"You can't wrap the root element");var n=e.make(document.createElement(t),this.parent),i=null!==(r=this.parent.children.indexOf(this))&&void 0!==r?r:-1;return-1===i?this.parent.append(n):this.parent.children[i]=n,n.append(this),n},e.prototype.append=function(e){return(0,a.assert)(e!==this,"Forbidden to add to yourself"),e.remove(),this.children.push(e),e.parent=this,this},Object.defineProperty(e.prototype,"previousElement",{get:function(){if(!this.parent)return null;var e=this.parent.children,t=e.indexOf(this);if(-1!==t)for(var r=t-1;r>=0;r-=1)if(e[r].isElement)return e[r];return null},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"lastElement",{get:function(){for(var e=this.children,t=e.length-1;t>=0;t-=1)if(e[t].isElement)return e[t];return null},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"previous",{get:function(){var e,t,r;return null!==(r=null!==(e=this.sibling(!1))&&void 0!==e?e:null===(t=this.parent)||void 0===t?void 0:t.previous)&&void 0!==r?r:null},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"next",{get:function(){var e,t,r;return null!==(r=null!==(e=this.sibling(!0))&&void 0!==e?e:null===(t=this.parent)||void 0===t?void 0:t.next)&&void 0!==r?r:null},enumerable:!1,configurable:!0}),e.prototype.sibling=function(e){if(!this.parent)return null;var t=this.parent.children,r=t.indexOf(this);return-1!==r&&t[r+(e?1:-1)]?t[r+(e?1:-1)]:null},e.prototype.forEach=function(e,t){var r,i;void 0===t&&(t=!1);var o=n.__spreadArray([],n.__read(this.children),!1);try{for(var a=n.__values(o),l=a.next();!l.done;l=a.next()){var u=l.value;if(!1===e(u))return!1;if(t&&!1===u.forEach(e,!0))return!1}}catch(e){r={error:e}}finally{try{l&&!l.done&&(i=a.return)&&i.call(a)}finally{if(r)throw r.error}}},e.prototype.find=function(e,t){void 0===t&&(t=!0);var r=[];return this.forEach((function(t){e(t)&&r.push(t)}),t),r},e.prototype.map=function(e){return this.children.map(e)},e.prototype.remove=function(){var e,t,r=null===(e=this.parent)||void 0===e?void 0:e.children.indexOf(this);return null!=r&&-1!==r&&(null===(t=this.parent)||void 0===t||t.children.splice(r,1)),this},e.prototype.textBetween=function(e,t){var r=!1,n=[];return this.forEach((function(i){if(!r&&e(i)&&(r=!0),r&&i.isText&&n.push((0,l.html)(i)),r&&t(i))return!1}),!0),n.join("")},e}();t.JElement=c},822:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});var n=r(1);n.__exportStar(r(823),t),n.__exportStar(r(826),t),n.__exportStar(r(824),t)},824:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.innerHTML=t.html=void 0;var n=r(131);function i(e,t,r){switch(void 0===t&&(t=function(){return!0}),void 0===r&&(r=!0),!0){case e.isComment:case e.isText:if(!t(e))return"";var n=e.attributes.nodeValue;return e.isComment?"\x3c!--".concat(n,"--\x3e"):n;case e.isElement:var i=e.attributes,l=o(e,t,r);if(!e.attributes["jd-safe"]&&r&&0===l.length&&!e.isSingle)return"";var u=Object.keys(i).map((function(e){return"style"===e||null==i[e]||/^jd-/.test(e)?"":"".concat(e,'="').concat(a(i[e]),'"')})).filter(Boolean),s=e.style.str;if(s&&u.push('style="'.concat(a(s),'"')),r&&0===u.length&&["span","a"].includes(e.name))return l;var c=u.length?" "+u.join(" "):"";return t(e)?e.isSingle?"<".concat(e.name).concat(c,"/>"):"<".concat(e.name).concat(c,">").concat(l,"</").concat(e.name,">"):l}return""}function o(e,t,r){void 0===t&&(t=function(){return!0}),void 0===r&&(r=!0);var o=e.map((function(e){return i(e,t,r)})).join("");return"p"===e.name&&0===(0,n.trim)(o).length&&(o=" "),o}function a(e){return e.toString().replace(/"/g,""")}t.html=i,t.innerHTML=o},827:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.Style=void 0;var n=r(1),i=r(131),o=function(){function e(e){this._data=a(e)}return Object.defineProperty(e.prototype,"keys",{get:function(){return Object.keys(this._data)},enumerable:!1,configurable:!0}),e.prototype.forEach=function(e){this.keys.forEach((function(t){return e(t)}))},e.prototype.clear=function(){this._data={}},e.prototype.set=function(e,t){this._data[e]=t},e.prototype.get=function(e){var t;return null!==(t=this._data[e])&&void 0!==t?t:null},e.prototype.add=function(e,t){return this._data=a(this.str+";"+"".concat(e,":").concat(t)),this},Object.defineProperty(e.prototype,"str",{get:function(){var e=this,t=Object.keys(this._data).filter((function(t){return t&&!/^mso-/.test(t)&&null!=e.get(t)}));return t.length?t.map((function(t){return"".concat((0,i.kebabCase)(t),":").concat(e.get(t))})).join(";"):""},enumerable:!1,configurable:!0}),e}();function a(e){return function(e){for(var t={},r=[],n=e.length-1;n>=0;n-=1){var i=e[n][0];t[i]||(t[i]=!0,r.unshift(e[n]))}return r}((null!=e?e:"").replace(/"/g,'"').split(";").filter(Boolean).map((function(e){return(0,i.trim)(e).split(":").map(i.trim)}))).reduce((function(e,t){var r=n.__read(t,2),i=r[0],o=r[1];return i&&o&&(e[i]=o),e}),{})}t.Style=o},818:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.applyStylesPro=void 0;var n=r(131),i=r(145),o=r(819),a=r(822);t.applyStylesPro=function(e,t,r){var l,u,s=document.createElement("iframe");s.style.display="none",document.body.appendChild(s);try{var c=null!==(l=s.contentDocument)&&void 0!==l?l:null===(u=s.contentWindow)||void 0===u?void 0:u.document;if(!c)return t;c.open(),c.write(t),c.close();for(var f="jd-style",d=function(e){try{for(var t=c.styleSheets[e].cssRules,r=function(e){if(!t[e].selectorText)return"continue";(0,n.$$)(t[e].selectorText,c.body).forEach((function(r){(0,n.attr)(r,f)||((0,n.attr)(r,f,(0,n.attr)(r,"style")||""),(0,n.attr)(r,"style","")),(0,n.attr)(r,"style","".concat((0,n.attr)(r,"style"),";").concat(t[e].style.cssText))}))},i=0;t.length>i;i+=1)r(i)}catch(e){}},p=0;c.styleSheets.length>p;p+=1)d(p);return(0,n.$$)("[".concat(f,"]"),c.body).forEach((function(e){(0,n.attr)(e,"style","".concat((0,n.attr)(e,"style"),";").concat((0,n.attr)(e,f)))})),(0,o.transformWordToHtml)(e,a.JElement.make(c.body),r)}finally{i.Dom.safeRemove(s)}return t}},838:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.calcListLevels=void 0;var n=r(1),i=r(822),o=r(825),a=r(817);t.calcListLevels=function(e){if(void 0===e.attributes[o.LEVEL_KEY]){for(var t=[(0,a.realPixelIndent)(e)],r=[e],l=e.next;l;){if(l.isElement&&!l.attributes[o.LEVEL_KEY]&&(0,i.isPseudoLeaf)(l)){var u=(0,a.realPixelIndent)(l);u&&(t.push(u),r.push(l))}l=l.next}var s=Math.min.apply(Math,n.__spreadArray([],n.__read(t.filter((function(e){return e>0}))),!1)),c=t.map((function(e){return Math.ceil(e/10)}));-1!==c.indexOf(0)&&(c=c.map((function(e){return e+1}))),r.forEach((function(e,t){e.attributes[o.LEVEL_KEY]=c[t],e.style.add("margin-left","".concat(Math.max((0,a.realPixelIndent)(e)-10*c[t]/s*40,0),"px"))}))}}},817:function(e,t){function r(e){if(!e)return[0,0,0,0];var t=e.match(/(0|auto|(-?[.\d]+(?:\w+|%)))/g)||["0px"];switch(t.length){case 2:return[0,1,0,1].map((function(e){return t[e]}));case 3:return[0,1,2,1].map((function(e){return t[e]}));case 4:return[0,1,2,3].map((function(e){return t[e]}));default:return[0,0,0,0].map((function(e){return t[e]}))}}var n;function i(e){if("number"==typeof e)return e;if(/%$/.test(e))return 0;n||(n=document.createElement("div"),Object.assign(n.style,{position:"absolute",left:"-9999px",top:"-9999px",margin:"0",padding:"0",border:"0"}),document.body.append(n),setTimeout((function(){null==n||n.remove(),n=null})));var t=0>parseFloat(e);t&&(e=e.replace("-","")),n.style.width=e;var r=n.clientWidth;return t?-r:r}Object.defineProperty(t,"__esModule",{value:!0}),t.calcStartBySymbol=t.realPixelIndent=t.convertUnitToPx=t.calcMarginParts=void 0,t.calcMarginParts=r,t.convertUnitToPx=i,t.realPixelIndent=function(e){var t=e.style,n=t.keys.filter((function(e){return/margin/.test(e)})),o=Math.max(n.indexOf("margin-left"),n.indexOf("margin")),a=o>0?n[o]:"margin-left";return i("margin"===a?r(t.get("margin"))[3]||0:t.get(a)||0)},t.calcStartBySymbol=function(e){return/\d.\d/.test(e)?e.split(".").pop()||null:/^\d/.test(e)?(parseInt(e,10)||1).toString():null}},816:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0});var n=r(1);n.__exportStar(r(817),t),n.__exportStar(r(818),t),n.__exportStar(r(819),t),n.__exportStar(r(838),t)},819:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.transformWordToHtml=void 0;var n=r(1),i=r(820),o=r(204),a=r(822);t.transformWordToHtml=function(e,t,r){var l={jodit:e};return t.forEach((function e(t){var r,o;if(t){try{for(var a=n.__values(i.cases),u=a.next();!u.done&&null!=(t=(0,u.value)(t,l));u=a.next());}catch(e){r={error:e}}finally{try{u&&!u.done&&(o=a.return)&&o.call(a)}finally{if(r)throw r.error}}null==t||t.forEach(e)}})),r&&t.forEach((function(e){e.style.clear()}),!0),(0,o.trim)((0,a.innerHTML)(t,(function(e){return!e.isComment})))}},815:function(e,t,r){Object.defineProperty(t,"__esModule",{value:!0}),t.PasteFromWordPro=void 0;var n=r(1),i=r(2),o=r(424),a=r(121),l=r(126),u=r(421),s=r(816);r(839);var c=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return n.__extends(t,e),t.prototype.insertFromWordByType=function(t,r,n){var i;if(!this.j.o.pasteFromWord.enable||n!==a.INSERT_AS_HTML&&n!==a.INSERT_AS_TEXT)return e.prototype.insertFromWordByType.call(this,t,r,n);if(r=(0,s.applyStylesPro)(this.j,r,n===a.INSERT_AS_TEXT),this.j.o.beautifyHTML){var o=null===(i=this.j.events)||void 0===i?void 0:i.fire("beautifyHTML",r);(0,l.isString)(o)&&(r=o)}(0,u.pasteInsertHtml)(t,this.j,r)},t}(o.PasteFromWord);t.PasteFromWordPro=c,i.Jodit.plugins.remove("pasteFromWord"),i.Jodit.plugins.add("pasteFromWordPro",c)}},function(e){return e(e.s=815)}])}));
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";((t,e)=>{if("object"==typeof exports&&"object"==typeof module)module.exports=e();else if("function"==typeof define&&define.amd)define([],e);else{var n=e();for(var r in n)("object"==typeof exports?exports:t)[r]=n[r]}})(self,(function(){return(self.webpackChunkjodit_pro=self.webpackChunkjodit_pro||[]).push([[92],{268(t,e,n){n.r(e),n.d(e,{PasteFromWordPro:()=>B});var r=n(1),s=n(99),i=n(3),a=n(7),l=n(98),o=n(10),u=n(17);let c;function p(t){if("number"==typeof t)return t;if(/%$/.test(t))return 0;c||(c=document.createElement("div"),Object.assign(c.style,{position:"absolute",left:"-9999px",top:"-9999px",margin:"0",padding:"0",border:"0"}),document.body.append(c),setTimeout((()=>{null==c||c.remove(),c=null})));const e=0>parseFloat(t);e&&(t=t.replace("-","")),c.style.width=t;const n=c.clientWidth;return e?-n:n}function m(t){const{style:e}=t;let n=[0,0,0,0],r=e["margin-left"]||0;if(!r&&e.margin){const{margin:t}=e;n=(t=>{if(!t)return[0,0,0,0];const e=t.match(/(0|auto|(-?[.\d]+(?:\w+|%)))/g)||["0px"];switch(e.length){case 2:return[0,1,0,1].map((t=>e[t]));case 3:return[0,1,2,1].map((t=>e[t]));case 4:return[0,1,2,3].map((t=>e[t]));default:return[0,0,0,0].map((t=>e[t]))}})(t),r=n[3]||0,e["margin-left"]=r}return p(r)}function d(t){return!(!t||"ol"!==t.name&&"ul"!==t.name)}function h(t){return!(!t||"li"!==t.name)}function f(t){return/msolistparagraph/i.test(t.attributes.class)}var b=n(36),y=n(35);function g(t,e=(()=>!0)){switch(!0){case t.isComment:case t.isText:{if(!e(t))return"";const{nodeValue:n}=t.attributes;return t.isComment?`\x3c!--${n}--\x3e`:n}case t.isElement:{const{attributes:n}=t,r=v(t,e);if(!t.attributes["jd-safe"]&&0===(0,o.trim)(r).length&&!t.isSingle)return"";const s=Object.keys(n).map((t=>"style"===t||null==n[t]||/^jd-/.test(t)?"":`${t}="${E(n[t])}"`)).filter(Boolean),{styleStr:i}=t;if(i&&s.push(`style="${E(i)}"`),0===s.length&&["span","a"].includes(t.name))return r;const a=s.length?" "+s.join(" "):"";return e(t)?t.isSingle?`<${t.name}${a}/>`:`<${t.name}${a}>${r}</${t.name}>`:r}}return""}function v(t,e=(()=>!0)){let n=t.map((t=>g(t,e))).join("");return"p"===t.name&&0===(0,o.trim)(n).length&&(n="<br>"),n}function E(t){return(""+t).replace(/"/g,"'")}const x=new Set(i.INSEPARABLE_TAGS);class T{constructor(t,e){this.parent=e,this.name=t.nodeName.toLowerCase(),this.type=t.nodeType,this.attributes=T.readAttributes(t),this.style=T.readStyles(this.attributes.style),this.children=[],t.childNodes.forEach((t=>this.children.push(T.make(t,this))))}get isText(){return this.type===Node.TEXT_NODE}get isElement(){return this.type===Node.ELEMENT_NODE}get isComment(){return this.type===Node.COMMENT_NODE}get isSingle(){return x.has(this.name)}get styleStr(){const t=Object.keys(this.style).filter((t=>t&&!/^mso-/.test(t)&&null!=this.style[t]));return t.length?t.map((t=>`${(0,y.G)(t)}:${this.style[t]}`)).join(";"):""}get length(){return this.children.length}static make(t,e=null){return new T(t,e)}wrap(t){var e;(0,o.assert)(null!=this.parent,"You can't wrap the root element");const n=T.make(document.createElement(t),this.parent),r=null!==(e=this.parent.children.indexOf(this))&&void 0!==e?e:-1;return-1===r?this.parent.append(n):this.parent.children[r]=n,n.append(this),n}append(t){return(0,o.assert)(t!==this,"Forbidden to add to yourself"),t.remove(),this.children.push(t),t.parent=this,this}get previousElement(){if(!this.parent)return null;const{children:t}=this.parent,e=t.indexOf(this);if(-1!==e)for(let n=e-1;n>=0;n-=1)if(t[n].isElement)return t[n];return null}get lastElement(){const{children:t}=this;for(let e=t.length-1;e>=0;e-=1)if(t[e].isElement)return t[e];return null}get previous(){var t,e,n;return null!==(n=null!==(t=this.sibling(!1))&&void 0!==t?t:null===(e=this.parent)||void 0===e?void 0:e.previous)&&void 0!==n?n:null}get next(){var t,e,n;return null!==(n=null!==(t=this.sibling(!0))&&void 0!==t?t:null===(e=this.parent)||void 0===e?void 0:e.next)&&void 0!==n?n:null}sibling(t){if(!this.parent)return null;const{children:e}=this.parent,n=e.indexOf(this);return-1!==n&&e[n+(t?1:-1)]?e[n+(t?1:-1)]:null}static readStyles(t){return(null!=t?t:"").split(";").filter(Boolean).map((t=>(0,b.f)(t).split(":").map(b.f))).reduce(((t,[e,n])=>(e&&n&&(t[e]=n),t)),{})}static readAttributes(t){const e={};if(u.i.isElement(t))for(let n=0,r=t.attributes;r.length>n;n+=1)e[r[n].name]=r[n].value;else e.nodeValue=t.nodeValue;return e}forEach(t,e=!1){const n=[...this.children];for(const r of n){if(!1===t(r))return!1;if(e&&!1===r.forEach(t,!0))return!1}}find(t,e=!1){const n=[];return this.forEach((e=>{t(e)&&n.push(e)}),e),n}map(t){return this.children.map(t)}remove(){var t,e;const n=null===(t=this.parent)||void 0===t?void 0:t.children.indexOf(this);return null!=n&&-1!==n&&(null===(e=this.parent)||void 0===e||e.children.splice(n,1)),this}textBetween(t,e){let n=!1;const r=[];return this.forEach((s=>{if(!n&&t(s)&&(n=!0),n&&s.isText&&r.push(g(s)),n&&e(s))return!1}),!0),r.join("")}}const k="jd-list-level",w="jd-list-type",j="jd-list-style-type",$="list-style-type",S={"·":"disc",o:"circle","§":"square","[ivx]":"lower-roman","[IVX]":"upper-roman","[a-z]":"lower-alpha","[A-Z]":"upper-alpha","\\d":"decimal"};function N(t,e){return!(e.name!==t.attributes[w]||e.attributes[j]!==t.attributes[j]||t.attributes[k]!==e.attributes[k])}const O=["cellspacing","cellpadding","border","v:shapes","o:spid"],_=new Set(["o:p","xml","script","meta","link","v:imagedata","style"]),C={i:"em",b:"strong"};let A=0;const L=[t=>((t.isElement&&"always"===t.style["page-break-before"]||"page"===t.style["break-before"])&&(t.attributes["jd-safe"]=!0,t.style["page-break-before"]="always",t.isSingle&&(t.name="div")),t),t=>"none"===t.style.display||0===t.length&&"span"===t.name||_.has(t.name)?(t.remove(),null):t,t=>{const{name:e}=t;return e in C&&(t.name=C[e]),t},t=>{if(/^OLE_LINK\d+$/.test(t.attributes.name)&&(t.attributes.name=null,0===t.length))return t.remove(),null;"_GoBack"===t.attributes.name&&(t.attributes.name=null);for(const e of O)t.attributes[e]&&(t.attributes[e]=null);return t},t=>{var e;if(f(t)){t.name="li",t.style["text-indent"]=null;const n=(t=>t.textBetween((t=>t.isComment&&/\[if.*supportLists.*]/.test(g(t))),(t=>t.isComment&&/\[endif]/.test(g(t)))))(t),r=/[\da-np-zA-NP-Z].?/.test(n)?"ol":"ul",s=(t=>{for(const e in S)if(RegExp(e).test(t))return S[e];return"inherit"})(n);t.attributes[w]=r,t.attributes[j]=s,(t=>{if(void 0!==t.attributes[k])return;const e=[m(t)],n=[t];let r=t.next;for(;r;){if(r.isElement&&!r.attributes[k]&&f(r)){const t=m(r);t&&(e.push(t),n.push(r))}r=r.next}const s=Math.min(...e.filter((t=>t>0)));let i=e.map((t=>Math.ceil(t/s)));-1!==i.indexOf(0)&&(i=i.map((t=>t+1))),n.forEach(((t,e)=>{t.attributes[k]=i[e],t.style["margin-left"]&&(t.style["margin-left"]=Math.max(p(t.style["margin-left"])-40*i[e],0)+"px")}))})(t),(t=>{for(;t;){const e=t.previousElement;if(!h(e)&&!d(e))break;if(h(e)){if(e.attributes[k]>t.attributes[k])break;if(t.attributes[k]===e.attributes[k]&&t.parent&&N(t,t.parent))break;e.append(t);continue}const n=e;if(n.attributes[k]>t.attributes[k])break;if(t.attributes[k]===n.attributes[k]&&!N(t,n))break;n.append(t)}})(t);const{parent:i}=t;if(!d(i)||!N(t,i)){const n=t.wrap(r);return n.attributes[k]=t.attributes[k],n.attributes[j]=t.attributes[j],n.style[$]=s,d(i)&&(n.remove(),null===(e=i.lastElement)||void 0===e||e.append(n)),(t=>{var e;!d(t)||"li"===(null===(e=t.parent)||void 0===e?void 0:e.name)||"disc"!==t.style[$]&&"decimal"!==t.style[$]||(t.style[$]=null)})(n),t}}return t},(t,e)=>{var n;const r=null!==(n=e.links)&&void 0!==n?n:{};if(t.attributes.href&&t.attributes.href.match(/#.+$/)&&(r[t.attributes.href.match(/#(.+)$/)[1]]=t),t.attributes.name&&r[t.attributes.name]){const e=r[t.attributes.name];e.attributes.href=e.attributes.href.replace(/.*#(.*)$/,"#$1")}return e.links=r,t},t=>(t.isComment&&/\[if.*(supportLists|gte vml).*]/.test(g(t))&&(A++,t.remove()),t.isComment&&A>0&&g(t).includes("[endif]")&&(A=A>0?A-1:0,t.remove()),t.isText&&A?(t.remove(),null):t),t=>{const{style:e}=t;return Object.keys(e).map((t=>{e[t]&&(e[t]=e[t].replace(/\d+(\.\d+)?(pt|cm)/g,(t=>p(t)+"px")))})),t},t=>(t.attributes.class&&(t.attributes.class=t.attributes.class.replace(/(el\d+)|(font\d+)|msonormal|msolistparagraph\w*/gi,""),(0,b.f)(t.attributes.class)||(t.attributes.class=null)),t),t=>t.isElement?("img"===t.name&&(t.attributes.align&&(t.style.float=t.attributes.align,t.attributes.align=null),t.attributes.hspace&&(t.style.marginLeft=t.attributes.hspace+"px",t.style.marginRight=t.attributes.hspace+"px",t.attributes.hspace=null)),t):t,t=>(!t.attributes.width||"th"!==t.name&&"td"!==t.name||(t.attributes.width=null),t)];n(2).D.prototype.pasteFromWordHeuristic=!1;class B extends s.B{insertFromWordByType(t,e,n){var r;if(!this.j.o.pasteFromWordHeuristic||n!==i.INSERT_AS_HTML&&n!==i.INSERT_AS_TEXT)return super.insertFromWordByType(t,e,n);if(e=((t,e)=>{var n,r;const s=document.createElement("iframe");s.style.display="none",document.body.appendChild(s);try{const i=null!==(n=s.contentDocument)&&void 0!==n?n:null===(r=s.contentWindow)||void 0===r?void 0:r.document;if(!i)return t;i.open(),i.write(t),i.close();for(let t=0;i.styleSheets.length>t;t+=1)try{const e=i.styleSheets[t].cssRules;for(let t=0;e.length>t;t+=1)e[t].selectorText&&(0,o.$$)(e[t].selectorText,i.body).forEach((n=>{n.setAttribute("style",`${e[t].style.cssText};${n.getAttribute("style")}`)}))}catch(t){}return((t,e)=>{const n={};return t.forEach((function t(e){if(e){for(const t of L)if(null==(e=t(e,n)))break;null==e||e.forEach(t)}})),e&&t.forEach((t=>{t.style={}}),!0),(0,b.f)(v(t,(t=>!t.isComment)))})(T.make(i.body),e)}finally{u.i.safeRemove(s)}return t})(e,n===i.INSERT_AS_TEXT),this.j.o.beautifyHTML){const t=null===(r=this.j.events)||void 0===r?void 0:r.fire("beautifyHTML",e);(0,a.H)(t)&&(e=t)}(0,l.kU)(t,this.j,e)}}r.Jodit.plugins.remove("pasteFromWord"),r.Jodit.plugins.add("pasteFromWordPro",B)}},t=>t(t.s=268)])}));
|
|
1
|
+
"use strict";((t,e)=>{if("object"==typeof exports&&"object"==typeof module)module.exports=e();else if("function"==typeof define&&define.amd)define([],e);else{var n=e();for(var r in n)("object"==typeof exports?exports:t)[r]=n[r]}})(self,(function(){return(self.webpackChunkjodit_pro=self.webpackChunkjodit_pro||[]).push([[92],{267(t,e,n){n.r(e),n.d(e,{PasteFromWordPro:()=>W});var r=n(1),s=n(98),i=n(3),a=n(7),l=n(97);let o;function u(t){if("number"==typeof t)return t;if(/%$/.test(t))return 0;o||(o=document.createElement("div"),Object.assign(o.style,{position:"absolute",left:"-9999px",top:"-9999px",margin:"0",padding:"0",border:"0"}),document.body.append(o),setTimeout((()=>{null==o||o.remove(),o=null})));const e=0>parseFloat(t);e&&(t=t.replace("-","")),o.style.width=t;const n=o.clientWidth;return e?-n:n}function c(t){const{style:e}=t;let n=[0,0,0,0];const r=e.keys.filter((t=>/margin/.test(t))),s=Math.max(r.indexOf("margin-left"),r.indexOf("margin")),i=s>0?r[s]:"margin-left";let a;return"margin"===i?(n=(t=>{if(!t)return[0,0,0,0];const e=t.match(/(0|auto|(-?[.\d]+(?:\w+|%)))/g)||["0px"];switch(e.length){case 2:return[0,1,0,1].map((t=>e[t]));case 3:return[0,1,2,1].map((t=>e[t]));case 4:return[0,1,2,3].map((t=>e[t]));default:return[0,0,0,0].map((t=>e[t]))}})(e.get("margin")),a=n[3]||0):a=e.get(i)||0,u(a)}var d=n(10),p=n(17);function h(t,e=(()=>!0),n=!0){switch(!0){case t.isComment:case t.isText:{if(!e(t))return"";const{nodeValue:n}=t.attributes;return t.isComment?`\x3c!--${n}--\x3e`:n}case t.isElement:{const{attributes:r}=t,s=m(t,e,n);if(!t.attributes["jd-safe"]&&n&&0===s.length&&!t.isSingle)return"";const i=Object.keys(r).map((t=>"style"===t||null==r[t]||/^jd-/.test(t)?"":`${t}="${f(r[t])}"`)).filter(Boolean),{str:a}=t.style;if(a&&i.push(`style="${f(a)}"`),n&&0===i.length&&["span","a"].includes(t.name))return s;const l=i.length?" "+i.join(" "):"";return e(t)?t.isSingle?`<${t.name}${l}/>`:`<${t.name}${l}>${s}</${t.name}>`:s}}return""}function m(t,e=(()=>!0),n=!0){let r=t.map((t=>h(t,e,n))).join("");return"p"===t.name&&0===(0,d.trim)(r).length&&(r=" "),r}function f(t){return(""+t).replace(/"/g,""")}const b="jd-list-level",g="jd-list-type",y="jd-list-style-type",v="list-style-type",E={"·":"disc",o:"circle","§":"square","[ivx]":"lower-roman","[IVX]":"upper-roman","[a-z]":"lower-alpha","[A-Z]":"upper-alpha","\\d":"decimal"};function x(t){return!(!t||"ol"!==t.name&&"ul"!==t.name)}function k(t){return!(!t||"li"!==t.name)}function $(t){return/mso-list:\s*l\d+ level\d+ lfo\d+/i.test(t.attributes.style)||/msolistparagraph/i.test(t.attributes.class)&&!!t.find((t=>t.isComment&&h(t).includes("supportLists"))).length}function T(t,e){return!(e.name!==t.attributes[g]||e.attributes[y]!==t.attributes[y]||t.attributes[b]!==e.attributes[b])}class j{constructor(t){this._data=w(t)}get keys(){return Object.keys(this._data)}forEach(t){this.keys.forEach((e=>t(e)))}clear(){this._data={}}set(t,e){this._data[t]=e}get(t){var e;return null!==(e=this._data[t])&&void 0!==e?e:null}add(t,e){return this._data=w(this.str+";"+`${t}:${e}`),this}get str(){const t=Object.keys(this._data).filter((t=>t&&!/^mso-/.test(t)&&null!=this.get(t)));return t.length?t.map((t=>`${(0,d.kebabCase)(t)}:${this.get(t)}`)).join(";"):""}}function w(t){return(t=>{const e={},n=[];for(let r=t.length-1;r>=0;r-=1){const s=t[r][0];e[s]||(e[s]=!0,n.unshift(t[r]))}return n})((null!=t?t:"").replace(/"/g,'"').split(";").filter(Boolean).map((t=>(0,d.trim)(t).split(":").map(d.trim)))).reduce(((t,[e,n])=>(e&&n&&(t[e]=n),t)),{})}const _=new Set(i.INSEPARABLE_TAGS);class S{constructor(t,e){this.parent=e,this.name=t.nodeName.toLowerCase(),this.type=t.nodeType,this.attributes=(t=>{const e={};if(p.i.isElement(t))for(let n=0,r=t.attributes;r.length>n;n+=1)e[r[n].name]=r[n].value;else e.nodeValue=t.nodeValue;return e})(t),this.style=new j(this.attributes.style),this.children=[],t.childNodes.forEach((t=>this.children.push(S.make(t,this))))}get isText(){return this.type===Node.TEXT_NODE}get html(){return h(this)}get isElement(){return this.type===Node.ELEMENT_NODE}get isComment(){return this.type===Node.COMMENT_NODE}get isSingle(){return _.has(this.name)}get length(){return this.children.length}static make(t,e=null){return new S(t,e)}wrap(t){var e;(0,d.assert)(null!=this.parent,"You can't wrap the root element");const n=S.make(document.createElement(t),this.parent),r=null!==(e=this.parent.children.indexOf(this))&&void 0!==e?e:-1;return-1===r?this.parent.append(n):this.parent.children[r]=n,n.append(this),n}append(t){return(0,d.assert)(t!==this,"Forbidden to add to yourself"),t.remove(),this.children.push(t),t.parent=this,this}get previousElement(){if(!this.parent)return null;const{children:t}=this.parent,e=t.indexOf(this);if(-1!==e)for(let n=e-1;n>=0;n-=1)if(t[n].isElement)return t[n];return null}get lastElement(){const{children:t}=this;for(let e=t.length-1;e>=0;e-=1)if(t[e].isElement)return t[e];return null}get previous(){var t,e,n;return null!==(n=null!==(t=this.sibling(!1))&&void 0!==t?t:null===(e=this.parent)||void 0===e?void 0:e.previous)&&void 0!==n?n:null}get next(){var t,e,n;return null!==(n=null!==(t=this.sibling(!0))&&void 0!==t?t:null===(e=this.parent)||void 0===e?void 0:e.next)&&void 0!==n?n:null}sibling(t){if(!this.parent)return null;const{children:e}=this.parent,n=e.indexOf(this);return-1!==n&&e[n+(t?1:-1)]?e[n+(t?1:-1)]:null}forEach(t,e=!1){const n=[...this.children];for(const r of n){if(!1===t(r))return!1;if(e&&!1===r.forEach(t,!0))return!1}}find(t,e=!0){const n=[];return this.forEach((e=>{t(e)&&n.push(e)}),e),n}map(t){return this.children.map(t)}remove(){var t,e;const n=null===(t=this.parent)||void 0===t?void 0:t.children.indexOf(this);return null!=n&&-1!==n&&(null===(e=this.parent)||void 0===e||e.children.splice(n,1)),this}textBetween(t,e){let n=!1;const r=[];return this.forEach((s=>{if(!n&&t(s)&&(n=!0),n&&s.isText&&r.push(h(s)),n&&e(s))return!1}),!0),r.join("")}}const C=["cellspacing","cellpadding","border","v:shapes","o:spid"],N=new Set(["o:p","xml","script","meta","link","v:imagedata","style"]),O={i:"em",b:"strong"};let L=0;var F=n(35);const M=[t=>((t.isElement&&"always"===t.style.get("page-break-before")||"page"===t.style.get("break-before"))&&(t.attributes["jd-safe"]=!0,t.style.add("page-break-before","always"),t.isSingle&&(t.name="div")),t),t=>"none"===t.style.get("display")||0===t.length&&"span"===t.name||N.has(t.name)?(t.remove(),null):t,t=>{const{name:e}=t;return e in O&&(t.name=O[e]),t},t=>{if(/^OLE_LINK\d+$/.test(t.attributes.name)&&(t.attributes.name=null,0===t.length))return t.remove(),null;"_GoBack"===t.attributes.name&&(t.attributes.name=null);for(const e of C)t.attributes[e]&&(t.attributes[e]=null);return t},t=>{var e;if($(t)){t.name="li",t.style.set("text-indent",null);const n=(t=>t.textBetween((t=>t.isComment&&/\[if.*supportLists.*]/.test(h(t))),(t=>t.isComment&&/\[endif]/.test(h(t)))).replace(/ /g,"").replace((0,i.SPACE_REG_EXP)(),""))(t),r=/[\da-np-zA-NP-Z].?/.test(n)?"ol":"ul",s=(t=>{for(const e in E)if(RegExp(e).test(t))return E[e];return null})(n);t.attributes[g]=r,t.attributes[y]=s,(t=>{if(void 0!==t.attributes[b])return;const e=[c(t)],n=[t];let r=t.next;for(;r;){if(r.isElement&&!r.attributes[b]&&$(r)){const t=c(r);t&&(e.push(t),n.push(r))}r=r.next}const s=Math.min(...e.filter((t=>t>0)));let i=e.map((t=>Math.ceil(t/10)));-1!==i.indexOf(0)&&(i=i.map((t=>t+1))),n.forEach(((t,e)=>{t.attributes[b]=i[e],t.style.add("margin-left",Math.max(c(t)-10*i[e]/s*40,0)+"px")}))})(t),(t=>{for(;t;){const e=t.previousElement;if(!k(e)&&!x(e))break;if(k(e)){if(e.attributes[b]>t.attributes[b])break;if(t.attributes[b]===e.attributes[b]&&t.parent&&T(t,t.parent))break;e.append(t);continue}const n=e;if(n.attributes[b]>t.attributes[b])break;if(t.attributes[b]===n.attributes[b]&&!T(t,n))break;n.append(t)}})(t);const{parent:a}=t;if(!x(a)||!T(t,a)){const i=((t,e,n,r)=>{const s=t.wrap(e);return s.attributes.start=(t=>/\d.\d/.test(t)?t.split(".").pop()||null:/^\d/.test(t)?""+(parseInt(t,10)||1):null)(n),s.attributes[b]=t.attributes[b],s.attributes[y]=t.attributes[y],s.style.set(v,r),(t=>{var e;!x(t)||"li"===(null===(e=t.parent)||void 0===e?void 0:e.name)||"disc"!==t.style.get(v)&&"decimal"!==t.style.get(v)||t.style.set(v,null)})(s),s})(t,r,n,s);return x(a)&&(i.remove(),null===(e=a.lastElement)||void 0===e||e.append(i)),t}}return t},(t,e)=>{var n;const r=null!==(n=e.links)&&void 0!==n?n:{};if(t.attributes.href&&t.attributes.href.match(/#.+$/)&&(r[t.attributes.href.match(/#(.+)$/)[1]]=t),t.attributes.name&&r[t.attributes.name]){const e=r[t.attributes.name];e.attributes.href=e.attributes.href.replace(/.*#(.*)$/,"#$1")}return e.links=r,t},t=>(t.isComment&&/\[if.*(supportLists|gte vml).*]/.test(h(t))&&(L++,t.remove()),t.isComment&&L>0&&h(t).includes("[endif]")&&(L=L>0?L-1:0,t.remove()),t.isText&&L?(t.remove(),null):t),(t,{jodit:e})=>{if(!e.o.pasteFromWord.convertUnitsToPixel)return t;const{style:n}=t;return n.forEach((t=>{const e=n.get(t);e&&n.set(t,(""+e).replace(/\d+(\.\d+)?(pt|cm)/g,(t=>u(t)+"px")))})),t},t=>(t.attributes.class&&(t.attributes.class=t.attributes.class.replace(/(el\d+)|(font\d+)|msonormal|msolistparagraph\w*/gi,""),(0,F.f)(t.attributes.class)||(t.attributes.class=null)),t),t=>t.isElement?("img"===t.name&&(t.attributes.align&&(t.style.add("float",t.attributes.align),t.attributes.align=null),t.attributes.hspace&&(t.style.add("marginLeft",t.attributes.hspace+"px"),t.style.add("marginRight",t.attributes.hspace+"px"),t.attributes.hspace=null)),t):t,t=>(!t.attributes.width||"th"!==t.name&&"td"!==t.name||(t.attributes.width=null),t)];n(2).D.prototype.pasteFromWord={enable:!1,convertUnitsToPixel:!1};class W extends s.B{insertFromWordByType(t,e,n){var r;if(!this.j.o.pasteFromWord.enable||n!==i.INSERT_AS_HTML&&n!==i.INSERT_AS_TEXT)return super.insertFromWordByType(t,e,n);if(e=((t,e,n)=>{var r,s;const i=document.createElement("iframe");i.style.display="none",document.body.appendChild(i);try{const a=null!==(r=i.contentDocument)&&void 0!==r?r:null===(s=i.contentWindow)||void 0===s?void 0:s.document;if(!a)return e;a.open(),a.write(e),a.close();const l="jd-style";for(let t=0;a.styleSheets.length>t;t+=1)try{const e=a.styleSheets[t].cssRules;for(let t=0;e.length>t;t+=1)e[t].selectorText&&(0,d.$$)(e[t].selectorText,a.body).forEach((n=>{(0,d.attr)(n,l)||((0,d.attr)(n,l,(0,d.attr)(n,"style")||""),(0,d.attr)(n,"style","")),(0,d.attr)(n,"style",`${(0,d.attr)(n,"style")};${e[t].style.cssText}`)}))}catch(t){}return(0,d.$$)(`[${l}]`,a.body).forEach((t=>{(0,d.attr)(t,"style",`${(0,d.attr)(t,"style")};${(0,d.attr)(t,l)}`)})),((t,e,n)=>{const r={jodit:t};return e.forEach((function t(e){if(e){for(const t of M)if(null==(e=t(e,r)))break;null==e||e.forEach(t)}})),n&&e.forEach((t=>{t.style.clear()}),!0),(0,F.f)(m(e,(t=>!t.isComment)))})(t,S.make(a.body),n)}finally{p.i.safeRemove(i)}return e})(this.j,e,n===i.INSERT_AS_TEXT),this.j.o.beautifyHTML){const t=null===(r=this.j.events)||void 0===r?void 0:r.fire("beautifyHTML",e);(0,a.H)(t)&&(e=t)}(0,l.kU)(t,this.j,e)}}r.Jodit.plugins.remove("pasteFromWord"),r.Jodit.plugins.add("pasteFromWordPro",W)}},t=>t(t.s=267)])}));
|
|
@@ -1 +1 @@
|
|
|
1
|
-
((t,e)=>{if("object"==typeof exports&&"object"==typeof module)module.exports=e();else if("function"==typeof define&&define.amd)define([],e);else{var o=e();for(var s in o)("object"==typeof exports?exports:t)[s]=o[s]}})(self,(function(){return(self.webpackChunkjodit_pro=self.webpackChunkjodit_pro||[]).push([[876],{
|
|
1
|
+
((t,e)=>{if("object"==typeof exports&&"object"==typeof module)module.exports=e();else if("function"==typeof define&&define.amd)define([],e);else{var o=e();for(var s in o)("object"==typeof exports?exports:t)[s]=o[s]}})(self,(function(){return(self.webpackChunkjodit_pro=self.webpackChunkjodit_pro||[]).push([[876],{201(t,e,o){"use strict";o.r(e),o.d(e,{ar:()=>s,cs_cz:()=>l,de:()=>r,es:()=>i,fa:()=>n,fr:()=>a,he:()=>c,hu:()=>h,id:()=>p,it:()=>d,ja:()=>k,ko:()=>u,nl:()=>b,pl:()=>g,pt_br:()=>w,ru:()=>f,tr:()=>B,zh_cn:()=>x,zh_tw:()=>m});const s=o(202),l=o(203),r=o(204),i=o(205),n=o(206),a=o(207),c=o(208),h=o(209),p=o(210),d=o(211),k=o(212),u=o(213),b=o(214),g=o(215),w=o(216),f=o(217),B=o(218),x=o(219),m=o(220)},200(t,e,o){"use strict";o.r(e),o.d(e,{showBlocks:()=>p});var s=o(197),l=o(2);l.D.prototype.showBlocks={enable:!1,color:"#ccc",tagList:["html","body","div","span","applet","object","iframe","h1","h2","h3","h4","h5","h6","p","blockquote","pre","a","abbr","acronym","address","big","cite","code","del","dfn","em","img","ins","kbd","q","s","samp","small","strike","strong","sub","sup","tt","var","b","u","i","center","dl","dt","dd","fieldset","form","label","legend","caption","th","td","li","ol","ul","article","aside","canvas","details","embed","figure","figcaption","footer","header","hgroup","menu","nav","output","ruby","section","summary","time","mark","audio","video"]},l.D.prototype.controls.showBlocks={isActive(t){return!!t.e.fire("showBlocksEnabled")},tooltip:"Show Blocks",command:"toggleShowBlocks"};var r=o(70),i=o(4),n=o(42),a=o(15),c=o(19),h=o(1);class p extends r.S{constructor(t){super(t),this.requires=["license"],this.buttons=[{name:"showBlocks",group:"state"}],this.isEnabled=!1,(0,a.xl)(o(201)),n.JO.set("showBlocks",o(221))}enable(){this.isEnabled=!0;const t=this.j.o.iframe?"body":".jodit-wysiwyg",{tagList:e,color:o}=this.j.o.showBlocks;this.style.innerHTML=e.map((e=>{return`${t} ${e}{\n\t\t\t\t\toutline: 1px dashed ${o};\n\t\t\t\t\tbackground-image: url("${s='<svg xmlns="http://www.w3.org/2000/svg" width="50px"><text dominant-baseline="hanging" text-anchor="end" style="fill: '+o+';font: 10px sans-serif" x="50px" y="0">'+e+"</text></svg>","data:image/svg+xml;utf8,"+escape(s)}");\n\t\t\t\t\tbackground-position: top 2px ${"rtl"===this.j.o.direction?"left":"right"} 4px;\n\t\t\t\t\tbackground-repeat: no-repeat;\n\t\t\t\t\tposition: relative;\n\t\t\t\t}`;var s})).join("")}disable(){this.isEnabled=!1,this.style.innerHTML=""}toggle(){this.isEnabled?this.disable():this.enable(),this.j.e.fire("updateToolbar")}afterInit(t){this.style=(0,a.ZO)(t,p,"style",!0),t.e.on("showBlocksEnabled",(()=>this.isEnabled)),t.registerCommand("enableShowBlocks",this.enable).registerCommand("disableShowBlocks",this.disable).registerCommand("toggleShowBlocks",this.toggle),this.j.o.showBlocks.enable&&this.enable()}beforeDestruct(t){this.disable(),i.Dom.safeRemove(this.style)}}(0,s.gn)([c.autobind],p.prototype,"enable",null),(0,s.gn)([c.autobind],p.prototype,"disable",null),(0,s.gn)([c.autobind],p.prototype,"toggle",null),h.Jodit.plugins.add("show-blocks",p)},197(t,e,o){"use strict";function s(t,e,o,s){var l,r=arguments.length,i=3>r?e:null===s?s=Object.getOwnPropertyDescriptor(e,o):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)i=Reflect.decorate(t,e,o,s);else for(var n=t.length-1;n>=0;n--)(l=t[n])&&(i=(3>r?l(i):r>3?l(e,o,i):l(e,o))||i);return r>3&&i&&Object.defineProperty(e,o,i),i}o.d(e,{gn:()=>s})},202(t){t.exports={"Show Blocks":"تظهر كتل"}},203(t){t.exports={"Show Blocks":"Ukázat Bloky"}},204(t){t.exports={"Show Blocks":"Zeigen Blöcke"}},205(t){t.exports={"Show Blocks":"Mostrar Bloques"}},206(t){t.exports={"Show Blocks":"نشان می دهد بلوک"}},207(t){t.exports={"Show Blocks":"Afficher Les Blocs"}},208(t){t.exports={"Show Blocks":"תראה רחובות"}},209(t){t.exports={"Show Blocks":"Mutasd Meg Blokkok"}},210(t){t.exports={"Show Blocks":"Menunjukkan Blok"}},211(t){t.exports={"Show Blocks":"Visualizza Blocchi"}},212(t){t.exports={"Show Blocks":"ショーのブロック"}},213(t){t.exports={"Show Blocks":"쇼 블록"}},214(t){t.exports={"Show Blocks":"Toon Blokken"}},215(t){t.exports={"Show Blocks":"Pokaż Bloki"}},216(t){t.exports={"Show Blocks":"Mostrar Blocos"}},217(t){t.exports={"Show Blocks":"Показать Блоки"}},218(t){t.exports={"Show Blocks":"Haritayı Blokları"}},219(t){t.exports={"Show Blocks":"显示块"}},220(t){t.exports={"Show Blocks":"แสดงช่วงตึก"}},221(t){t.exports='<svg viewBox="0 0 1792 1792" xmlns="http://www.w3.org/2000/svg"> <g> <rect rx="10" height="1620" width="1620" y="79.646973" x="80" stroke-width="100" stroke-dasharray="8% 10%" fill="none"/> <path d="m1333.992706,381.692384l0,52.982419q0,21.04781 -12.98052,44.272981t-29.820114,23.22517q-35.082487,0 -37.889085,0.725787q-18.242893,4.354719 -22.452791,22.499384q-2.104949,7.983652 -2.104949,46.45034l0,836.106125q0,18.144664 -12.629695,31.208822t-30.170938,13.064158l-75.778171,0q-17.541243,0 -30.170938,-13.064158t-12.629695,-31.208822l0,-884.008038l-100.335911,0l0,884.008038q0,18.144664 -12.27887,31.208822t-30.521763,13.064158l-75.778171,0q-18.242893,0 -30.521763,-13.064158t-12.27887,-31.208822l0,-359.990137q-103.14251,-8.709439 -171.904184,-42.821407q-88.407866,-42.095621 -134.716748,-129.915795q-44.905583,-84.917028 -44.905583,-187.978721q0,-120.48057 61.745176,-207.574958q61.745176,-85.642815 146.644794,-115.400064q77.88312,-26.854103 292.587937,-26.854103l336.090221,0q17.541243,0 30.170938,13.064158t12.629695,31.208822z"/> </g> </svg>'}},t=>t(t.s=200)])}));
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";((e,t)=>{if("object"==typeof exports&&"object"==typeof module)module.exports=t();else if("function"==typeof define&&define.amd)define([],t);else{var o=t();for(var n in o)("object"==typeof exports?exports:e)[n]=o[n]}})(self,(function(){return(self.webpackChunkjodit_pro=self.webpackChunkjodit_pro||[]).push([[288],{
|
|
1
|
+
"use strict";((e,t)=>{if("object"==typeof exports&&"object"==typeof module)module.exports=t();else if("function"==typeof define&&define.amd)define([],t);else{var o=t();for(var n in o)("object"==typeof exports?exports:e)[n]=o[n]}})(self,(function(){return(self.webpackChunkjodit_pro=self.webpackChunkjodit_pro||[]).push([[288],{250(e,t,o){o.r(t),o.d(t,{tuneBlock:()=>b});var n=o(197),i=o(70),s=o(19),r=o(1),l=o(42),c=o(17),h=o(10),u=o(64);let p=class extends l.u1{constructor(){super(...arguments),this.isShown=!1,this.toolbar=(0,u.R)(this.j,this),this.popup=new l.GI(this.j,!1)}className(){return"UITuner"}render(){return"<div>\n\t\t\t<div class='&__handle' title='~Click to tune~'/>\n\t\t</div>"}show(){const e=this.j.s.current();if(!e)return this.hide();const t=c.i.isBlock(e)?e:c.i.closest(e,(e=>!(!e||!this.j.o.tuneBlock.popup[e.nodeName.toLowerCase()])),this.j.editor);if(!t||t===this.j.editor||!this.j.o.tuneBlock.popup[t.tagName.toLowerCase()])return this.hide();this.currentBlock=t,this.isShown=!0,this.closeToolbar(),this.calcPosition(),this.container.parentNode||this.j.workplace.append(this.container)}hide(){this.isShown&&(this.isShown=!1,c.i.safeRemove(this.container),this.closeToolbar())}onEditorScroll(){this.isShown&&this.calcPosition()}calcPosition(){const e=(0,h.css)(this.j.editor,"marginLeft"),t=(0,h.css)(this.j.editor,"paddingLeft"),o=(0,h.css)(this.j.editor,"marginTop");(0,h.css)(this.container,{transform:`translate3d(${this.currentBlock.offsetWidth-15+e+t}px, ${this.currentBlock.offsetTop-this.j.editor.scrollTop+o}px, 0)`}),this.popup.isOpened&&this.popup.updatePosition()}onAfterExecTune(e){e&&(this.currentBlock=e),this.calcPosition(),this.openToolbar()}onClickPrevent(e){e.preventDefault(),e.stopPropagation()}onTargetClick(){this.toggleToolbar()}openToolbar(){if(this.setMod("opened",!0),this.toolbar.build(this.j.o.tuneBlock.popup[this.currentBlock.tagName.toLowerCase()],this.currentBlock),this.popup.setContent(this.toolbar.container),!this.popup.isOpened){const e=this.getElm("handle");(0,h.assert)(null!=e,"Handle element does not exist"),this.popup.open((()=>(0,h.position)(e)))}}closeToolbar(){this.setMod("opened",!1),this.popup.close()}toggleToolbar(){this.getMod("opened")?this.closeToolbar():this.openToolbar()}};(0,n.gn)([(0,s.watch)(":hideTuner.tune")],p.prototype,"hide",null),(0,n.gn)([(0,s.watch)("j.editor:scroll"),(0,s.throttle)(10)],p.prototype,"onEditorScroll",null),(0,n.gn)([(0,s.watch)(":afterExecTune.tune"),(0,s.idle)()],p.prototype,"onAfterExecTune",null),(0,n.gn)([(0,s.watch)("container:click container:mousedown")],p.prototype,"onClickPrevent",null),(0,n.gn)([(0,s.watch)("handle:click")],p.prototype,"onTargetClick",null),(0,n.gn)([(0,s.watch)(":closeTuner.tune")],p.prototype,"closeToolbar",null),p=(0,n.gn)([s.component],p);var a=o(2);const d=["tune.up","tune.remove","tune.down"],f=["tune.h1","tune.h2","tune.h3","\n","tune.h4","tune.h5","tune.h6","\n",...d];function g(e){return{icon:'<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 50 50"><text dominant-baseline="text-before-edge" style="font: 45px sans-serif" x="0" y="0">'+e.toUpperCase()+"</text></svg>",isActive(t,o,n){var i;return(null===(i=null==n?void 0:n.target)||void 0===i?void 0:i.tagName.toLowerCase())===e},exec(t,o){if(o){t.selection.save();const n=c.i.replace(o,e,t.createInside);t.selection.restore(),t.e.fire("synchro"),t.e.fire("afterExecTune.tune",n)}return!0}}}function w(e){const t=e?"previousSibling":"nextSibling";return{icon:e?"angle-up":"angle-down",isDisabled(e,o,n){var i;return!(null===(i=null==n?void 0:n.target)||void 0===i?void 0:i[t])},exec(o,n){const i=null==n?void 0:n[t];return n&&i&&(o.selection.save(),(0,h.call)(e?c.i.before:c.i.after,i,n),o.selection.restore()),o.e.fire("synchro"),o.e.fire("afterExecTune.tune"),!0}}}a.D.prototype.tuneBlock={popup:{p:d,table:d,img:d,blockquote:d,div:d,pre:["tune.editPre",...d],h1:f,h2:f,h3:f,h4:f,h5:f,h6:f}},a.D.prototype.controls.tune={h1:g("h1"),h2:g("h2"),h3:g("h3"),h4:g("h4"),h5:g("h5"),h6:g("h6"),up:w(!0),down:w(!1),editPre:{icon:"pencil",exec(e,t){e.e.fire("editPreInPasteCode",t)}},remove:{icon:"bin",exec(e,t){c.i.safeRemove(t),e.e.fire("synchro"),e.e.fire("closeTuner.tune"),e.e.fire("hideTuner.tune")}}};class b extends i.S{constructor(){super(...arguments),this.requires=["license"]}afterInit(e){this.tuner=new p(e)}hideTuner(){this.tuner.hide()}onChangeSelection(){this.j.s.isCollapsed()||this.hideTuner()}onClickInBlock(e){this.j.s.isCollapsed()&&this.tuner.show()}beforeDestruct(e){this.tuner.destruct()}}(0,n.gn)([(0,s.watch)(":outsideClick :keydown")],b.prototype,"hideTuner",null),(0,n.gn)([(0,s.watch)("j.ed:selectionchange"),(0,s.debounce)()],b.prototype,"onChangeSelection",null),(0,n.gn)([(0,s.watch)(":click")],b.prototype,"onClickInBlock",null),r.Jodit.plugins.add("tune-block",b)},197(e,t,o){function n(e,t,o,n){var i,s=arguments.length,r=3>s?t:null===n?n=Object.getOwnPropertyDescriptor(t,o):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)r=Reflect.decorate(e,t,o,n);else for(var l=e.length-1;l>=0;l--)(i=e[l])&&(r=(3>s?i(r):s>3?i(t,o,r):i(t,o))||r);return s>3&&r&&Object.defineProperty(t,o,r),r}o.d(t,{gn:()=>n})}},e=>e(e.s=250)])}));
|
package/index.html
CHANGED
|
@@ -107,6 +107,10 @@
|
|
|
107
107
|
'src/plugins/paste-from-word/assets/content.css',
|
|
108
108
|
'src/plugins/paste-from-word/assets/document-mode.css'
|
|
109
109
|
],
|
|
110
|
+
defaultFontSizePoints: 'pt',
|
|
111
|
+
pasteFromWord: {
|
|
112
|
+
enable: true
|
|
113
|
+
},
|
|
110
114
|
|
|
111
115
|
language: 'en',
|
|
112
116
|
|
|
@@ -182,7 +186,7 @@
|
|
|
182
186
|
// buttons: [],
|
|
183
187
|
// "textIcons": true,
|
|
184
188
|
|
|
185
|
-
// disablePlugins: ['
|
|
189
|
+
// disablePlugins: ['pasteFromWordPro'],
|
|
186
190
|
|
|
187
191
|
keyboard: {
|
|
188
192
|
// showLayoutSwitcher: false,
|