{"version":3,"file":"ckeditor.js","sources":["webpack://ClassicEditor/ckeditor.js"],"sourcesContent":["/*!\n * @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved.\n * For licensing, see LICENSE.md.\n */\n(function(t){const e=t[\"fa\"]=t[\"fa\"]||{};e.dictionary=Object.assign(e.dictionary||{},{\"%0 of %1\":\"0% از 1%\",\"Align center\":\"تراز وسط\",\"Align left\":\"تراز چپ\",\"Align right\":\"تراز راست\",Aquamarine:\"زمرد کبود\",Big:\"بزرگ\",Black:\"سیاه\",\"Block quote\":\" بلوک نقل قول\",Blue:\"آبی\",\"Blue marker\":\"نشانگر آبی\",Bold:\"درشت\",\"Bulleted List\":\"لیست نشانهدار\",Cancel:\"لغو\",\"Centered image\":\"تصویر در وسط\",\"Change image text alternative\":\"تغییر متن جایگزین تصویر\",\"Choose heading\":\"انتخاب عنوان\",Code:\"کد\",Column:\"ستون\",\"Decrease indent\":\"کاهش تورفتگی\",Default:\"پیش فرض\",\"Delete column\":\"حذف ستون\",\"Delete row\":\"حذف سطر\",\"Dim grey\":\"خاکستری تیره\",\"Document colors\":\"رنگ اسناد\",Downloadable:\"قابل بارگیری\",\"Dropdown toolbar\":\"نوارابزار کشویی\",\"Edit block\":\"ویرایش قطعه\",\"Edit link\":\"ویرایش پیوند\",\"Editor toolbar\":\"نوارابزار ویرایشگر\",\"Enter image caption\":\"عنوان تصویر را وارد کنید\",\"Font Background Color\":\"رنگ پس زمینه فونت\",\"Font Color\":\"رنگ فونت\",\"Font Size\":\"اندازه فونت\",\"Full size image\":\"تصویر در اندازه کامل\",Green:\"سبز\",\"Green marker\":\"نشانگر سبز\",\"Green pen\":\"قلم سبز\",Grey:\"خاکستری\",\"Header column\":\"ستون سربرگ\",\"Header row\":\"سطر سربرگ\",Heading:\"عنوان\",\"Heading 1\":\"عنوان 1\",\"Heading 2\":\"عنوان 2\",\"Heading 3\":\"عنوان 3\",\"Heading 4\":\"عنوان 4\",\"Heading 5\":\"عنوان 5\",\"Heading 6\":\"عنوان 6\",Highlight:\"برجسته\",\"Horizontal line\":\"خط افقی\",Huge:\"بسیار بزرگ\",\"Image toolbar\":\"نوارابزار تصویر\",\"image widget\":\"ابزاره تصویر\",\"Increase indent\":\"افزایش تورفتگی\",\"Insert column left\":\"درج ستون در سمت چپ\",\"Insert column right\":\"درج ستون در سمت راست\",\"Insert image\":\"قرار دادن تصویر\",\"Insert media\":\"وارد کردن رسانه\",\"Insert paragraph after block\":\"درج پاراگراف بعد از بلوک\",\"Insert paragraph before block\":\"درج پاراگراف قبل از بلوک\",\"Insert row above\":\"درج سطر در بالا\",\"Insert row below\":\"درج سطر در پایین\",\"Insert table\":\"درج جدول\",Italic:\"کج\",Justify:\"هم تراز کردن\",\"Left aligned image\":\"تصویر تراز شده چپ\",\"Light blue\":\"آبی روشن\",\"Light green\":\"سبز روشن\",\"Light grey\":\"خاکستری روشن\",Link:\"پیوند\",\"Link URL\":\"نشانی اینترنتی پیوند\",\"Media URL\":\"آدرس اینترنتی رسانه\",\"media widget\":\"ویجت رسانه\",\"Merge cell down\":\"ادغام سلول پایین\",\"Merge cell left\":\"ادغام سلول چپ\",\"Merge cell right\":\"ادغام سلول راست\",\"Merge cell up\":\"ادغام سلول بالا\",\"Merge cells\":\"ادغام سلول ها\",Next:\"بعدی\",\"Numbered List\":\"لیست عددی\",\"Open in a new tab\":\"بازکردن در برگه جدید\",\"Open link in new tab\":\"باز کردن پیوند در برگه جدید\",Orange:\"نارنجی\",Paragraph:\"پاراگراف\",\"Paste the media URL in the input.\":\"آدرس رسانه را در ورودی قرار دهید\",\"Pink marker\":\"نشانگر صورتی\",Previous:\"قبلی\",Purple:\"بنفش\",Red:\"قرمز\",\"Red pen\":\"قلم قرمز\",Redo:\"باز انجام\",\"Remove color\":\"حذف رنگ\",\"Remove highlight\":\"حذف برجسته\",\"Rich Text Editor\":\"ویرایشگر متن غنی\",\"Rich Text Editor, %0\":\"ویرایشگر متن غنی، %0\",\"Right aligned image\":\"تصویر تراز شده راست\",Row:\"سطر\",Save:\"ذخیره\",\"Select all\":\"انتخاب همه\",\"Select column\":\"\",\"Select row\":\"\",\"Show more items\":\"نمایش گزینههای بیشتر\",\"Side image\":\"تصویر جانبی\",Small:\"کوچک\",\"Split cell horizontally\":\"تقسیم افقی سلول\",\"Split cell vertically\":\"تقسیم عمودی سلول\",\"Table toolbar\":\"نوارابزار جدول\",\"Text alignment\":\"تراز متن\",\"Text alignment toolbar\":\"نوار ابزار ترازبندی متن\",\"Text alternative\":\"متن جایگزین\",\"Text highlight toolbar\":\"نوارابزار برجستگی متن\",\"The URL must not be empty.\":\"آدرس اینترنتی URL نباید خالی باشد.\",\"This link has no URL\":\"این پیوند نشانی اینترنتی ندارد\",\"This media URL is not supported.\":\"این آدرس اینترنتی رسانه پشتیبانی نمیشود\",Tiny:\"بسیار کوچک\",\"Tip: Paste the URL into the content to embed faster.\":\"نکته : آدرس را در محتوا قراردهید تا سریع تر جاسازی شود\",Turquoise:\"فیروزه ای\",Undo:\"بازگردانی\",Unlink:\"لغو پیوند\",\"Upload failed\":\"آپلود ناموفق بود\",\"Upload in progress\":\"آپلود در حال انجام\",White:\"سفید\",\"Widget toolbar\":\"نوار ابزار ویجت\",Yellow:\"زرد\",\"Yellow marker\":\"نشانگر زرد\"});e.getPluralForm=function(t){return t>1}})(window.CKEDITOR_TRANSLATIONS||(window.CKEDITOR_TRANSLATIONS={}));(function t(e,n){if(typeof exports===\"object\"&&typeof module===\"object\")module.exports=n();else if(typeof define===\"function\"&&define.amd)define([],n);else if(typeof exports===\"object\")exports[\"ClassicEditor\"]=n();else e[\"ClassicEditor\"]=n()})(window,(function(){return function(t){var e={};function n(o){if(e[o]){return e[o].exports}var i=e[o]={i:o,l:false,exports:{}};t[o].call(i.exports,i,i.exports,n);i.l=true;return i.exports}n.m=t;n.c=e;n.d=function(t,e,o){if(!n.o(t,e)){Object.defineProperty(t,e,{enumerable:true,get:o})}};n.r=function(t){if(typeof Symbol!==\"undefined\"&&Symbol.toStringTag){Object.defineProperty(t,Symbol.toStringTag,{value:\"Module\"})}Object.defineProperty(t,\"__esModule\",{value:true})};n.t=function(t,e){if(e&1)t=n(t);if(e&8)return t;if(e&4&&typeof t===\"object\"&&t&&t.__esModule)return t;var o=Object.create(null);n.r(o);Object.defineProperty(o,\"default\",{enumerable:true,value:t});if(e&2&&typeof t!=\"string\")for(var i in t)n.d(o,i,function(e){return t[e]}.bind(null,i));return o};n.n=function(t){var e=t&&t.__esModule?function e(){return t[\"default\"]}:function e(){return t};n.d(e,\"a\",e);return e};n.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)};n.p=\"\";return n(n.s=67)}([function(t,e,n){\"use strict\";n.d(e,\"a\",(function(){return i}));n.d(e,\"b\",(function(){return r}));const o=\"https://ckeditor.com/docs/ckeditor5/latest/framework/guides/support/error-codes.html\";class i extends Error{constructor(t,e,n){const o=`${t}${n?` ${JSON.stringify(n)}`:\"\"}${a(t)}`;super(o);this.name=\"CKEditorError\";this.context=e;this.data=n}is(t){return t===\"CKEditorError\"}static rethrowUnexpectedError(t,e){if(t.is&&t.is(\"CKEditorError\")){throw t}const n=new i(t.message,e);n.stack=t.stack;throw n}}function r(t,e){console.warn(...c(t,e))}function s(t,e){console.error(...c(t,e))}function a(t){return`\\nRead more: ${o}#error-${t}`}function c(t,e){const n=a(t);return e?[t,e,n]:[t,n]}},function(t,e,n){\"use strict\";var o=function t(){var e;return function t(){if(typeof e===\"undefined\"){e=Boolean(window&&document&&document.all&&!window.atob)}return e}}();var i=function t(){var e={};return function t(n){if(typeof e[n]===\"undefined\"){var o=document.querySelector(n);if(window.HTMLIFrameElement&&o instanceof window.HTMLIFrameElement){try{o=o.contentDocument.head}catch(t){o=null}}e[n]=o}return e[n]}}();var r=[];function s(t){var e=-1;for(var n=0;n0){if(++e>=Kt){return arguments[0]}}else{e=0}return t.apply(undefined,arguments)}}var Yt=qt;var $t=Yt(Ht);var Qt=$t;function Jt(t,e){return Qt(jt(t,e,Pt),t+\"\")}var Zt=Jt;var Xt=9007199254740991;function te(t){return typeof t==\"number\"&&t>-1&&t%1==0&&t<=Xt}var ee=te;function ne(t){return t!=null&&ee(t.length)&&!Z(t)}var oe=ne;var ie=9007199254740991;var re=/^(?:0|[1-9]\\d*)$/;function se(t,e){var n=typeof t;e=e==null?ie:e;return!!e&&(n==\"number\"||n!=\"symbol\"&&re.test(t))&&(t>-1&&t%1==0&&t
\").replace(/\\r?\\n/g,\"
\").replace(/^\\s/,\" \").replace(/\\s$/,\" \").replace(/\\s\\s/g,\" \");if(t.includes(\"
\")||t.includes(\"
\")){t=`
${t}
`}return t}function Wx(t){return t.replace(/(\\s+)<\\/span>/g,((t,e)=>{if(e.length==1){return\" \"}return e}))}const qx=[\"figcaption\",\"li\"];function Yx(t){let e=\"\";if(t.is(\"$text\")||t.is(\"$textProxy\")){e=t.data}else if(t.is(\"element\",\"img\")&&t.hasAttribute(\"alt\")){e=t.getAttribute(\"alt\")}else if(t.is(\"element\",\"br\")){e=\"\\n\"}else{let n=null;for(const o of t.getChildren()){const t=Yx(o);if(n&&(n.is(\"containerElement\")||o.is(\"containerElement\"))){if(qx.includes(n.name)||qx.includes(o.name)){e+=\"\\n\"}else{e+=\"\\n\\n\"}}e+=t;n=o}}return e}class $x extends Un{static get pluginName(){return\"ClipboardPipeline\"}init(){const t=this.editor;const e=t.editing.view;e.addObserver(Hx);this._setupPasteDrop();this._setupCopyCut()}_setupPasteDrop(){const t=this.editor;const e=t.model;const n=t.editing.view;const o=n.document;this.listenTo(o,\"clipboardInput\",(e=>{if(t.isReadOnly){e.stop()}}),{priority:\"highest\"});this.listenTo(o,\"clipboardInput\",((t,e)=>{const o=e.dataTransfer;let i=e.content||\"\";if(!i){if(o.getData(\"text/html\")){i=Wx(o.getData(\"text/html\"))}else if(o.getData(\"text/plain\")){i=Gx(o.getData(\"text/plain\"))}i=this.editor.data.htmlProcessor.toView(i)}const s=new r(this,\"inputTransformation\");this.fire(s,{content:i,dataTransfer:o,targetRanges:e.targetRanges,method:e.method});if(s.stop.called){t.stop()}n.scrollToTheSelection()}),{priority:\"low\"});this.listenTo(this,\"inputTransformation\",((t,n)=>{if(n.content.isEmpty){return}const o=this.editor.data;const i=o.toModel(n.content,\"$clipboardHolder\");if(i.childCount==0){return}t.stop();e.change((()=>{this.fire(\"contentInsertion\",{content:i,method:n.method,dataTransfer:n.dataTransfer,targetRanges:n.targetRanges})}))}),{priority:\"low\"});this.listenTo(this,\"contentInsertion\",((t,n)=>{n.resultRange=e.insertContent(n.content)}),{priority:\"low\"})}_setupCopyCut(){const t=this.editor;const e=t.model.document;const n=t.editing.view;const o=n.document;function i(n,i){const r=i.dataTransfer;i.preventDefault();const s=t.data.toView(t.model.getSelectedContent(e.selection));o.fire(\"clipboardOutput\",{dataTransfer:r,content:s,method:n.name})}this.listenTo(o,\"copy\",i,{priority:\"low\"});this.listenTo(o,\"cut\",((e,n)=>{if(t.isReadOnly){n.preventDefault()}else{i(e,n)}}),{priority:\"low\"});this.listenTo(o,\"clipboardOutput\",((n,o)=>{if(!o.content.isEmpty){o.dataTransfer.setData(\"text/html\",this.editor.data.htmlProcessor.toData(o.content));o.dataTransfer.setData(\"text/plain\",Yx(o.content))}if(o.method==\"cut\"){t.model.deleteContent(e.selection)}}),{priority:\"low\"})}}class Qx{constructor(){this._stack=[]}add(t,e){const n=this._stack;const o=n[0];this._insertDescriptor(t);const i=n[0];if(o!==i&&!Jx(o,i)){this.fire(\"change:top\",{oldDescriptor:o,newDescriptor:i,writer:e})}}remove(t,e){const n=this._stack;const o=n[0];this._removeDescriptor(t);const i=n[0];if(o!==i&&!Jx(o,i)){this.fire(\"change:top\",{oldDescriptor:o,newDescriptor:i,writer:e})}}_insertDescriptor(t){const e=this._stack;const n=e.findIndex((e=>e.id===t.id));if(Jx(t,e[n])){return}if(n>-1){e.splice(n,1)}let o=0;while(e[o]&&Zx(e[o],t)){o++}e.splice(o,0,t)}_removeDescriptor(t){const e=this._stack;const n=e.findIndex((e=>e.id===t));if(n>-1){e.splice(n,1)}}}Vn(Qx,m);function Jx(t,e){return t&&e&&t.priority==e.priority&&Xx(t.classes)==Xx(e.classes)}function Zx(t,e){if(t.priority>e.priority){return true}else if(t.priority