From 06a8c7e26c6117b641aa16cca9544a95749fe8ab Mon Sep 17 00:00:00 2001 From: Valera Date: Mon, 23 Dec 2019 23:41:36 +0300 Subject: [PATCH] New version 3.3.8. Read more https://github.com/xdan/jodit/releases/tag/3.3.8 --- build/jodit.css | 2931 +++++ build/jodit.es2018.css | 2931 +++++ build/jodit.es2018.js | 19380 ++++++++++++++++++++++++++++++ build/jodit.es2018.min.css | 9 + build/jodit.es2018.min.js | 9 + build/jodit.js | 22679 +++++++++++++++++++++++++++++++++++ build/jodit.min.css | 9 + build/jodit.min.js | 9 + package-lock.json | 2 +- package.json | 2 +- 10 files changed, 47959 insertions(+), 2 deletions(-) create mode 100644 build/jodit.css create mode 100644 build/jodit.es2018.css create mode 100644 build/jodit.es2018.js create mode 100644 build/jodit.es2018.min.css create mode 100644 build/jodit.es2018.min.js create mode 100644 build/jodit.js create mode 100644 build/jodit.min.css create mode 100644 build/jodit.min.js diff --git a/build/jodit.css b/build/jodit.css new file mode 100644 index 000000000..a7159039e --- /dev/null +++ b/build/jodit.css @@ -0,0 +1,2931 @@ +/*! + jodit - Jodit is awesome and usefully wysiwyg editor with filebrowser + Author: Chupurnov (https://xdsoft.net/) + Version: v3.3.8 + Url: https://xdsoft.net/jodit/ + License(s): GPL-2.0-or-later OR MIT OR Commercial +*/ + +.jodit_wysiwyg{ + outline:0; +} +.jodit_wysiwyg::-moz-selection,.jodit_wysiwyg ::-moz-selection{ + background:#b5d6fd; + color:#000; +} +.jodit_wysiwyg::selection,.jodit_wysiwyg ::selection{ + background:#b5d6fd; + color:#000; +} +.jodit_container:not(.jodit_inline) .jodit_wysiwyg{ + margin:0; + padding:10px; + outline:0; + overflow-x:auto; + position:relative; +} +.jodit_container:not(.jodit_inline) .jodit_wysiwyg img{ + position:relative; + max-width:100%; +} +.jodit_container:not(.jodit_inline) .jodit_wysiwyg p,.jodit_container:not(.jodit_inline) .jodit_wysiwyg pre{ + margin:0 0 10px; +} +.jodit_container:not(.jodit_inline) .jodit_wysiwyg h1,.jodit_container:not(.jodit_inline) .jodit_wysiwyg h2,.jodit_container:not(.jodit_inline) .jodit_wysiwyg h3,.jodit_container:not(.jodit_inline) .jodit_wysiwyg h4,.jodit_container:not(.jodit_inline) .jodit_wysiwyg h5{ + margin-top:0; +} +.jodit_container:not(.jodit_inline) .jodit_wysiwyg blockquote{ + border-left:2px solid #222; + margin-left:0; + padding-left:5px; + color:#222; +} +.jodit_container:not(.jodit_inline) .jodit_wysiwyg jodit-media{ + position:relative; +} +.jodit_container:not(.jodit_inline) .jodit_wysiwyg jodit-media *{ + position:relative; + z-index:0; +} +.jodit_container:not(.jodit_inline) .jodit_wysiwyg jodit-media:before{ + z-index:1; + content:""; + position:absolute; + top:0; + left:0; + right:0; + bottom:0; +} +.jodit_form{ + font-family:Helvetica,sans-serif,Arial; + font-size:14px; + color:#000; +} +.jodit_form.jodit_error{ + border-color:#f7d1d1; + box-shadow:inset 0 0 3px 0 hsla(0, 0%, 74.1%, .3); +} +@media (max-width:768px){ + .jodit_form{ + min-width:150px; + } +} +.jodit_form button{ + height:36px; + line-height:1; + color:#000; + padding:10px; + cursor:pointer; + text-decoration:none; + border:none; + background:#d6d6d6; + font-size:16px; + outline:none; + transition:background .2s ease 0s; + margin-top:10px; + margin-bottom:10px; +} +.jodit_form button:hover{ + background-color:#ecebe9; + color:#000; +} +.jodit_form button:active{ + background:#ecebe9; + color:#000; +} +.jodit_form label{ + margin-top:10px; + text-align:left; + white-space:nowrap; + display:-ms-flexbox; + display:flex; + -ms-flex-align:center; + align-items:center; +} +.jodit_form .jodit_form_center{ + -ms-flex-pack:center; + justify-content:center; +} +.jodit_input,.jodit_select,.jodit_textarea{ + font-family:Helvetica,sans-serif,Arial; + font-size:14px; + width:100%; + -webkit-appearance:none; + -moz-appearance:none; + appearance:none; + height:32px; + border-radius:0; + outline:none; + line-height:100%; + border:1px solid #ccc; + padding:5px 10px; + background-color:#fff; +} +.jodit_input[disabled],.jodit_select[disabled],.jodit_textarea[disabled]{ + background-color:#f0f0f0; + color:#ccc; +} +.jodit_input:focus{ + border-color:#66afe9; + outline:0; +} +.jodit_checkbox{ + z-index:2; + border:0; + cursor:pointer; + height:16px; + padding:0; + margin:0 4px; + width:16px; + position:relative; + outline:none; +} +.jodit_checkbox:checked:after{ + background:url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Cpath d='M27 4L12 19l-7-7-5 5 12 12L32 9z' fill='%23FFF'/%3E%3C/svg%3E") no-repeat 50% #b5b5b5; + border-color:#b5b5b5; +} +.jodit_select{ + padding-right:20px; + background-image:url(data:image/svg+xml;base64,PHN2ZyBpZD0iTGF5ZXJfMSIgZGF0YS1uYW1lPSJMYXllciAxIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCA0Ljk1IDEwIj48ZGVmcz48c3R5bGU+LmNscy0ye2ZpbGw6IzQ0NH08L3N0eWxlPjwvZGVmcz48cGF0aCBmaWxsPSIjZmZmIiBkPSJNMCAwaDQuOTV2MTBIMHoiLz48cGF0aCBjbGFzcz0iY2xzLTIiIGQ9Ik0xLjQxIDQuNjdsMS4wNy0xLjQ5IDEuMDYgMS40OUgxLjQxek0zLjU0IDUuMzNMMi40OCA2LjgyIDEuNDEgNS4zM2gyLjEzeiIvPjwvc3ZnPg==); + background-repeat:no-repeat; + background-position:98% 50%; +} +.jodit_textarea{ + height:auto; + min-width:180px; +} +.jodit_form_group{ + display:-ms-flexbox; + display:flex; + -ms-flex-direction:column; + flex-direction:column; + margin-bottom:10px; + min-width:180px; +} +.jodit_button{ + position:relative; + display:-ms-inline-flexbox; + display:inline-flex; + -ms-flex-align:center; + align-items:center; + -ms-flex-pack:center; + justify-content:center; + -webkit-user-select:none; + -moz-user-select:none; + -ms-user-select:none; + user-select:none; + width:auto; + padding:0 10px; + height:40px; + line-height:1; + margin:0; + background-color:hsla(0, 0%, 88.2%, .99); + color:#000; + cursor:pointer; + border:0; + border-radius:.25rem; + text-decoration:none; +} +.jodit_button svg{ + display:inline-block; + width:24px; + height:24px; +} +.jodit_button svg+span{ + margin-left:5px; +} +.jodit_button:active,.jodit_button:focus{ + outline:0; +} +.jodit_button.disabled{ + opacity:.7; +} +.jodit_button .jodit_icon,.jodit_button svg,.jodit_dialog_header .jodit_icon,.jodit_dialog_header svg{ + width:16px; + height:16px; + display:inline-block; + vertical-align:middle; +} +.jodit_button_group{ + display:-ms-flexbox; + display:flex; +} +.jodit_button_group input{ + display:none; +} +.jodit_button_group button{ + display:-ms-flexbox; + display:flex; + -ms-flex:1; + flex:1; + -ms-flex-pack:center; + justify-content:center; + text-align:center; +} +.jodit_button_group button+button{ + margin-left:-1px; +} +.jodit_button_group button:first-child,.jodit_button_group input:first-child+button{ + border-right:0; + border-top-right-radius:0; + border-bottom-right-radius:0; +} +.jodit_button_group button:last-child,.jodit_button_group input:last-child+button{ + border-left:0; + border-top-left-radius:0; + border-bottom-left-radius:0; +} +.jodit_button_group input[type=checkbox]:checked+button,.jodit_button_group input[type=checkbox]:not(:checked)+button+button{ + background-image:none; + box-shadow:inset 0 2px 4px rgba(0, 0, 0, .15),0 1px 2px rgba(0, 0, 0, .05); +} +.jodit_context_menu{ + font-family:Helvetica,sans-serif,Arial; + font-size:14px; + position:absolute; + z-index:2222224; + display:none; + min-width:150px; + background:#fff; + box-shadow:0 0 5px 0 rgba(0, 0, 0, .24); +} +.jodit_context_menu a{ + display:-ms-flexbox; + display:flex; + -ms-flex-align:center; + align-items:center; + height:38px; + text-decoration:none !important; + border-bottom:1px solid hsla(0, 0%, 80%, .24); + color:#727272; +} +.jodit_context_menu a svg{ + display:block; + width:18px; + height:38px; + margin:0 10px; + fill:#727272; +} +.jodit_context_menu a span{ + display:-ms-flexbox; + display:flex; + -ms-flex-align:center; + align-items:center; + padding:10px; + height:38px; + border-left:1px solid hsla(0, 0%, 80%, .24); + box-sizing:border-box; +} +.jodit_context_menu a:hover{ + background-color:#e3e3e3; + color:#000; +} +.jodit_context_menu a:hover .jodit_icon{ + fill:#000; +} +.jodit_context_menu a:last-child{ + border:0; +} +.jodit_context_menu-show{ + display:block; +} +.jodit_dialog_box{ + font-family:Helvetica,sans-serif,Arial; + font-size:14px; + box-sizing:border-box; + position:absolute; + display:none; + width:0; + height:0; + border:0; + will-change:left, top, width, height; +} +.jodit_dialog_box.jodit_dialog_box-moved{ + -webkit-user-select:none; + -moz-user-select:none; + -ms-user-select:none; + user-select:none; +} +.jodit_dialog_box *{ + box-sizing:border-box; +} +.jodit_dialog_box .jodit_elfinder,.jodit_dialog_box .jodit_elfinder *{ + box-sizing:initial; +} +.jodit_dialog_box .jodit_dialog_overlay{ + position:fixed; + top:0; + left:0; + width:100%; + height:100%; + z-index:2222222; + text-align:center; + white-space:nowrap; + overflow:auto; + display:none; + background-color:rgba(0, 0, 0, .5); +} +.jodit_dialog_box.active,.jodit_dialog_box.jodit_modal .jodit_dialog_overlay{ + display:block; +} +.jodit_dialog_box .jodit_dialog{ + z-index:2222223; + display:inline-block; + vertical-align:middle; + white-space:normal; + text-align:left; + position:fixed; + left:0; + top:0; + background-color:#fff; + box-shadow:0 10px 20px rgba(0, 0, 0, .19),0 6px 6px rgba(0, 0, 0, .23); + min-width:200px; + min-height:100px; +} +@media (max-width:480px){ + .jodit_dialog_box .jodit_dialog{ + max-width:100%; + width:100% !important; + height:100% !important; + top:0 !important; + left:0 !important; + } +} +.jodit_dialog_box .jodit_dialog .jodit_promt{ + max-width:300px; + min-width:200px; + padding:10px; + word-break:break-all; +} +.jodit_dialog_box .jodit_dialog .jodit_promt label{ + margin-bottom:5px; + display:block; +} +.jodit_dialog_box .jodit_dialog .jodit_alert{ + max-width:300px; + min-width:200px; + padding:10px; + word-break:break-all; +} +.jodit_dialog_box .jodit_dialog .jodit_dialog_header{ + display:-ms-flexbox; + display:flex; + -ms-flex-pack:justify; + justify-content:space-between; + text-align:left; + color:#222; + box-shadow:0 1px 3px rgba(0, 0, 0, .16),0 1px 2px rgba(0, 0, 0, .23); + cursor:move; + height:48px; + overflow:hidden; +} +.jodit_dialog_box .jodit_dialog .jodit_dialog_header .jodit_dialog_header-title,.jodit_dialog_box .jodit_dialog .jodit_dialog_header .jodit_dialog_header-toolbar{ + display:-ms-flexbox; + display:flex; + -ms-flex-align:center; + align-items:center; + -ms-flex-negative:3; + flex-shrink:3; + font-size:18px; + margin:0; + font-weight:400; + line-height:48px; + vertical-align:top; + padding:0 10px; +} +@media (max-width:480px){ + .jodit_dialog_box .jodit_dialog .jodit_dialog_header .jodit_dialog_header-title,.jodit_dialog_box .jodit_dialog .jodit_dialog_header .jodit_dialog_header-toolbar{ + padding-left:0; + } +} +.jodit_dialog_box .jodit_dialog .jodit_dialog_header .jodit_button{ + margin-left:10px; +} +.jodit_dialog_box .jodit_dialog .jodit_dialog_header .jodit_dialog_header-button{ + color:#222; + font-size:28px; + transition:background-color .2s ease 0s; + -ms-flex-preferred-size:48px; + flex-basis:48px; + height:48px; + line-height:48px; + text-decoration:none; + text-align:center; +} +.jodit_dialog_box .jodit_dialog .jodit_dialog_header .jodit_dialog_header-button:hover{ + background-color:#ecebe9; +} +.jodit_dialog_box .jodit_dialog .jodit_dialog_header .jodit_toolbar{ + background:transparent; + border:0; + box-shadow:none; +} +.jodit_dialog_box .jodit_dialog .jodit_dialog_header .jodit_toolbar>li.jodit_toolbar_btn .jodit_input{ + padding-left:10px; + width:auto; +} +.jodit_dialog_box .jodit_dialog .jodit_dialog_content{ + height:calc(100% - 48px); + overflow:auto; +} +.jodit_dialog_box .jodit_dialog .jodit_dialog_content .jodit_form_group{ + margin-bottom:10px; + padding:0 10px; +} +.jodit_dialog_box .jodit_dialog .jodit_dialog_content .jodit_form_group:first-child{ + margin-top:10px; +} +.jodit_dialog_box .jodit_dialog .jodit_dialog_content .jodit_form_group label{ + display:inline-block; + max-width:100%; + margin-bottom:5px; + font-weight:700; +} +.jodit_dialog_box .jodit_dialog .jodit_dialog_content .jodit_form_group .jodit_input_group{ + display:table; + border-collapse:separate; + width:100%; +} +.jodit_dialog_box .jodit_dialog .jodit_dialog_content .jodit_form_group .jodit_input_group>*{ + vertical-align:middle; + display:table-cell; + height:34px; +} +.jodit_dialog_box .jodit_dialog .jodit_dialog_content .jodit_form_group .jodit_input_group>input{ + margin:0 !important; +} +.jodit_dialog_box .jodit_dialog .jodit_dialog_content .jodit_form_group .jodit_input_group>input:not([class*=col-]){ + width:100%; +} +.jodit_dialog_box .jodit_dialog .jodit_dialog_content .jodit_form_group .jodit_input_group-buttons{ + width:1%; + font-size:0; + white-space:nowrap; + vertical-align:middle; +} +.jodit_dialog_box .jodit_dialog .jodit_dialog_content .jodit_form_group .jodit_input_group-buttons>.jodit_button{ + border:1px solid #ccc; + margin-left:-1px; + height:34px; + line-height:34px; + border-radius:0; +} +.jodit_dialog_box .jodit_dialog .jodit_dialog_footer{ + padding:10px; + display:none; +} +.jodit_dialog_box .jodit_dialog.with_footer .jodit_dialog_content{ + height:calc(100% - 96px); +} +.jodit_dialog_box .jodit_dialog.with_footer .jodit_dialog_footer{ + display:-ms-flexbox; + display:flex; + -ms-flex-pack:justify; + justify-content:space-between; + -ms-flex-wrap:nowrap; + flex-wrap:nowrap; +} +.jodit_dialog_box .jodit_dialog.with_footer .jodit_dialog_footer .jodit_button{ + margin-right:10px; +} +.jodit_dialog_box .jodit_dialog.with_footer .jodit_dialog_footer .jodit_button:last-child{ + margin-right:0; +} +.jodit_dialog_box .jodit_dialog .jodit_dialog_resizer{ + position:absolute; + bottom:0; + right:0; + cursor:se-resize; + width:7px; + height:7px; + display:inline-block; + background-image:url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAcAAAAHCAYAAADEUlfTAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAADFJREFUeNpilJGRYcACIoB4ORMuCSCOZMIlga4TRQJZJ4YETCdWCSBmZMIlATIOIMAAEyAPt4RnNx0AAAAASUVORK5CYII="); +} +.jodit_dialog_box .jodit_dialog .jodit_dialog_resizer:hover{ + border-color:rgba(0, 0, 0, .6); +} +@media (max-width:480px){ + .jodit_dialog_box .jodit_dialog .jodit_dialog_resizer{ + display:none; + } +} +.jodit_dialog_box.jodit_fullsize .jodit_dialog{ + top:0 !important; + bottom:0 !important; + left:0 !important; + right:0 !important; + width:100% !important; + height:100% !important; +} +.jodit_dialog_box.jodit_fullsize .jodit_dialog .jodit_dialog_resizer{ + display:none; +} +@media (max-width:768px){ + .jodit_dialog_header .jodit_input,.jodit_dialog_header .jodit_toolbar_btn-filter,.jodit_dialog_header .jodit_toolbar_btn-separator,.jodit_dialog_header .jodit_toolbar_btn-sort,.jodit_dialog_header_fullsize,.jodit_dialog_header_title{ + display:none !important; + } +} +.jodit_toolbar_list>.jodit_toolbar{ + max-height:400px; + overflow:auto; + box-shadow:0 3px 6px rgba(0, 0, 0, .16),0 3px 6px rgba(0, 0, 0, .23); + padding:0; + margin:auto; + text-align:left; + box-sizing:border-box; + transition:max-height .2s ease 0s; + margin-top:0 !important; + list-style-type:none; + font-size:16px; + z-index:10000; + position:absolute; + left:0; + top:100%; +} +.jodit_toolbar_list>.jodit_toolbar,.jodit_toolbar_list>.jodit_toolbar .jodit_toolbar{ + background:#f9f9f9; +} +.jodit_toolbar_list>.jodit_toolbar blockquote,.jodit_toolbar_list>.jodit_toolbar h1,.jodit_toolbar_list>.jodit_toolbar h2,.jodit_toolbar_list>.jodit_toolbar h3,.jodit_toolbar_list>.jodit_toolbar h4,.jodit_toolbar_list>.jodit_toolbar h5,.jodit_toolbar_list>.jodit_toolbar p,.jodit_toolbar_list>.jodit_toolbar pre{ + font-family:Helvetica,sans-serif,Arial; + margin:0; + padding:0; + font-weight:400; +} +.jodit_toolbar_list>.jodit_toolbar h5{ + font-size:.8em; + line-height:1.4; +} +.jodit_toolbar_list>.jodit_toolbar h3{ + font-size:1.31em; + line-height:1.4; +} +.jodit_toolbar_list>.jodit_toolbar h4,.jodit_toolbar_list>.jodit_toolbar p{ + font-size:1em; + line-height:1.5em; +} +.jodit_toolbar_list>.jodit_toolbar h2{ + font-size:1.74em; + line-height:1.4; +} +.jodit_toolbar_list>.jodit_toolbar h1{ + font-size:2.17em; + line-height:1.4; +} +.jodit_toolbar_list>.jodit_toolbar blockquote,.jodit_toolbar_list>.jodit_toolbar pre{ + font-family:monospace; +} +.jodit_toolbar_list>.jodit_toolbar li.jodit_toolbar_btn{ + display:block; + cursor:pointer; + white-space:nowrap; + color:inherit; + text-decoration:none; + width:100%; + height:auto; + box-sizing:border-box; + text-align:left; +} +.jodit_toolbar_list>.jodit_toolbar li.jodit_toolbar_btn>a{ + background-image:none; + padding:7px 24px; + cursor:pointer; + line-height:100%; + width:auto; + height:auto; + display:block; +} +.jodit_toolbar_list>.jodit_toolbar li.jodit_toolbar_btn>a>span{ + display:inline-block; +} +.jodit_toolbar_list>.jodit_toolbar li.jodit_toolbar_btn>a:hover{ + background-color:#f3f0f0; +} +.jodit_toolbar_list>.jodit_toolbar li.jodit_toolbar_btn>a:after{ + display:none; +} +.jodit_toolbar[dir=rtl] .jodit_toolbar_list>.jodit_toolbar,.jodit_toolbar[dir=rtl] .jodit_toolbar_list>.jodit_toolbar li.jodit_toolbar_btn{ + text-align:right; +} +.jodit_filebrowser{ + font-family:Helvetica,sans-serif,Arial; + height:100%; + display:-ms-flexbox; + display:flex; +} +.jodit_filebrowser_no_files{ + padding:10px; +} +@media (max-width:480px){ + .jodit_filebrowser{ + -ms-flex-direction:column; + flex-direction:column; + -ms-flex-flow:column-reverse; + flex-flow:column-reverse; + } +} +.jodit_filebrowser_loader{ + height:100%; + width:100%; + position:absolute; + top:0; + left:0; +} +.jodit_filebrowser_loader i{ + position:absolute; + top:50%; + left:50%; + margin-top:-24px; + margin-left:-24px; + font-style:normal; + opacity:.7; +} +.jodit_filebrowser_status{ + position:absolute; + font-size:12px; + padding:6px; + text-align:right; + border-top:1px solid hsla(0, 0%, 49.8%, .4); + left:0; + right:0; + bottom:0; + background-color:#4a4a4a; + visibility:hidden; + opacity:0; + transition:opacity .3s linear; + color:#b38888; + word-break:break-all; +} +.jodit_filebrowser_status.success{ + color:#c5c5c5; +} +.jodit_filebrowser_status.active{ + visibility:visible; + opacity:1; +} +.jodit_filebrowser_files,.jodit_filebrowser_tree{ + display:none; + vertical-align:top; + height:100%; + position:relative; +} +.jodit_filebrowser_files .jodit_button,.jodit_filebrowser_tree .jodit_button{ + border-radius:0; +} +.jodit_filebrowser_files.active,.jodit_filebrowser_tree.active{ + display:-ms-flexbox; + display:flex; +} +.jodit_filebrowser_files::-webkit-scrollbar,.jodit_filebrowser_tree::-webkit-scrollbar{ + width:5px; +} +.jodit_filebrowser_files::-webkit-scrollbar-track,.jodit_filebrowser_tree::-webkit-scrollbar-track{ + -webkit-box-shadow:inset 0 0 6px rgba(0, 0, 0, .3); +} +.jodit_filebrowser_files::-webkit-scrollbar-thumb,.jodit_filebrowser_tree::-webkit-scrollbar-thumb{ + background-color:#a9a9a9; + outline:1px solid #708090; +} +.jodit_filebrowser_tree.active{ + -ms-flex-direction:column; + flex-direction:column; + width:31%; + min-width:200px; + max-width:290px; + z-index:2; + background-color:#3f3f3f; + overflow-y:auto; +} +@media (max-width:480px){ + .jodit_filebrowser_tree.active{ + max-width:100%; + width:auto; + height:100px; + } +} +.jodit_filebrowser_tree.active::-webkit-scrollbar{ + width:5px; +} +.jodit_filebrowser_tree.active::-webkit-scrollbar-track{ + -webkit-box-shadow:inset 0 0 6px rgba(0, 0, 0, .3); +} +.jodit_filebrowser_tree.active::-webkit-scrollbar-thumb{ + background-color:hsla(0, 0%, 49.8%, .5); + outline:1px solid #708090; +} +.jodit_filebrowser_tree.active .jodit_filebrowser_source_title{ + -webkit-user-select:none; + -moz-user-select:none; + -ms-user-select:none; + user-select:none; + display:block; + padding:10px; + color:#969696; + border-bottom:1px solid #484848; + line-height:17px; + min-height:38px; + position:relative; + word-break:break-all; + background:#5a5a5a; + font-size:16px; +} +.jodit_filebrowser_tree.active .jodit_filebrowser_tree_item{ + display:-ms-flexbox; + display:flex; + -ms-flex-pack:justify; + justify-content:space-between; + -ms-flex-align:center; + align-items:center; + min-height:38px; + padding:5px 10px; + text-decoration:none; + color:#b1b1b1; + transition:background-color .2s ease 0s; + border-bottom:1px solid #474747; + position:relative; + word-break:break-all; +} +.jodit_filebrowser_tree.active .jodit_filebrowser_tree_item_title{ + -ms-flex:1; + flex:1; +} +.jodit_filebrowser_tree.active .jodit_filebrowser_tree_item .jodit_icon_folder{ + margin-left:5px; + width:16px; + height:16px; + display:-ms-flexbox; + display:flex; + -ms-flex-pack:center; + justify-content:center; + -ms-flex-align:center; + align-items:center; + opacity:.3; +} +.jodit_filebrowser_tree.active .jodit_filebrowser_tree_item .jodit_icon_folder svg{ + width:12px; + height:12px; + stroke:#b1b1b1 !important; + fill:#b1b1b1 !important; +} +.jodit_filebrowser_tree.active .jodit_filebrowser_tree_item .jodit_icon_folder:hover{ + background:#696969; +} +.jodit_filebrowser_tree.active .jodit_filebrowser_tree_item:hover{ + color:#222; + background-color:#ecebe9; +} +.jodit_filebrowser_tree.active .jodit_filebrowser_tree_item:hover i.jodit_icon_folder{ + opacity:.6; +} +.jodit_filebrowser_files.active{ + width:100%; + overflow-y:auto; + padding:5px; + -ms-flex-wrap:wrap; + flex-wrap:wrap; + -ms-flex-line-pack:start; + align-content:flex-start; +} +.jodit_filebrowser_files.active .jodit_filebrowser_source_title{ + -webkit-user-select:none; + -moz-user-select:none; + -ms-user-select:none; + user-select:none; + margin:-10px -10px 0; + display:block; + padding:10px; + line-height:17px; + min-height:38px; + position:relative; + word-break:break-all; + background:#5a5a5a; + font-size:16px; + color:#969696; +} +.jodit_filebrowser_files.active a+.jodit_filebrowser_source_title{ + margin-top:10px; +} +.jodit_filebrowser_files.active .jodit_filebrowser_files_item{ + width:150px; + height:150px; + display:-ms-flexbox; + display:flex; + -ms-flex-pack:center; + justify-content:center; + -ms-flex-align:center; + align-items:center; + text-align:center; + border:1px solid #ccc; + margin:5px; + font-size:0; + overflow:hidden; + transition:border .1s linear,bottom .1s linear; + position:relative; +} +@media (max-width:480px){ + .jodit_filebrowser_files.active .jodit_filebrowser_files_item{ + width:calc(50% - 10px); + } +} +.jodit_filebrowser_files.active .jodit_filebrowser_files_item img{ + max-width:100%; +} +.jodit_filebrowser_files.active .jodit_filebrowser_files_item:hover{ + border-color:#433b5c; +} +.jodit_filebrowser_files.active .jodit_filebrowser_files_item-active-true{ + border-color:#1e88e5; + background-color:#b5b5b5; +} +.jodit_filebrowser_files.active .jodit_filebrowser_files_item-info{ + position:absolute; + right:0; + left:0; + bottom:0; + white-space:normal; + opacity:.85; + overflow:visible; + padding:.3em .6em; + transition:opacity .4s ease; + background-color:#e9e9e9; + color:#333; + text-shadow:#eee 0 1px 0; + font-size:14px; + line-height:16px; + text-align:left; +} +.jodit_filebrowser_files.active .jodit_filebrowser_files_item-info>span{ + display:block; + text-overflow:ellipsis; + white-space:nowrap; + overflow:hidden; + font-size:.75em; +} +.jodit_filebrowser_files.active .jodit_filebrowser_files_item-info>span.jodit_filebrowser_files_item-info-filename{ + font-weight:700; + font-size:.9em; +} +.jodit_filebrowser_files.active .jodit_filebrowser_files_item-active-true .jodit_filebrowser_files_item-info{ + background-color:#b5b5b5; + color:#fff; + text-shadow:none; +} +.jodit_filebrowser_files.active .jodit_filebrowser_files_item:hover:not(.jodit_filebrowser_files_item-active-true) .jodit_filebrowser_files_item-info{ + bottom:-100px; +} +.jodit_filebrowser_files.active.jodit_filebrowser_files_view-list{ + scroll-behavior:smooth; +} +.jodit_filebrowser_files.active.jodit_filebrowser_files_view-list a{ + display:block; + width:100%; + height:26px; + line-height:26px; + margin:0; + border-width:0 0 1px; + text-align:left; + white-space:nowrap; +} +.jodit_filebrowser_files.active.jodit_filebrowser_files_view-list a img{ + min-width:16px; + max-width:16px; + vertical-align:middle; + display:inline-block; + margin-left:4px; +} +.jodit_filebrowser_files.active.jodit_filebrowser_files_view-list a .jodit_filebrowser_files_item-info{ + padding:0; + position:static; + display:inline-block; + width:calc(100% - 20px); + margin-left:4px; + background-color:transparent; + height:100%; + line-height:inherit; + vertical-align:middle; + font-size:0; +} +.jodit_filebrowser_files.active.jodit_filebrowser_files_view-list a .jodit_filebrowser_files_item-info>span{ + display:inline-block; + height:100%; + font-size:12px; +} +.jodit_filebrowser_files.active.jodit_filebrowser_files_view-list a .jodit_filebrowser_files_item-info>span.jodit_filebrowser_files_item-info-filename{ + width:50%; +} +.jodit_filebrowser_files.active.jodit_filebrowser_files_view-list a .jodit_filebrowser_files_item-info>span.jodit_filebrowser_files_item-info-filechanged,.jodit_filebrowser_files.active.jodit_filebrowser_files_view-list a .jodit_filebrowser_files_item-info>span.jodit_filebrowser_files_item-info-filesize{ + width:25%; +} +.jodit_filebrowser_files.active.jodit_filebrowser_files_view-list a:hover{ + background-color:#433b5c; +} +.jodit_filebrowser_files.active.jodit_filebrowser_files_view-list a:hover .jodit_filebrowser_files_item-info{ + color:#fff; + text-shadow:none; +} +.jodit_filebrowser_files.active.jodit_filebrowser_files_view-list a:before{ + height:100%; + content:""; + vertical-align:middle; + display:inline-block; +} +.jodit_draghover{ + background-color:#ecebe9; +} +.jodit_dialog_box .jodit_dialog_header-title .jodit_upload_button{ + position:relative; + width:220px; + border:0; + padding:25px 0; + margin:10px 0; + overflow:hidden; +} +.jodit_dialog_box .jodit_dialog_header-title .jodit_upload_button input{ + cursor:pointer; + position:absolute; + right:0; + top:0; + bottom:0; + margin:0 -10px 0 0; + padding:0; + opacity:0; + font-size:400px; +} +.jodit_dialog_box .jodit_dialog_header-title.jodit_filebrowser_title_box{ + display:-ms-flexbox; + display:flex; + -ms-flex-align:center; + align-items:center; + padding-left:10px; +} +.jodit_filebrowser_preview{ + text-align:center; + min-width:600px; + max-width:1000px; + min-height:700px; + max-height:100%; + position:relative; + display:-ms-flexbox; + display:flex; + -ms-flex-pack:center; + justify-content:center; + -ms-flex-align:center; + align-items:center; +} +@media (max-width:768px){ + .jodit_filebrowser_preview{ + max-width:100%; + max-height:100%; + min-width:auto; + min-height:auto; + height:100%; + } +} +.jodit_filebrowser_preview_box{ + -ms-flex-positive:1; + flex-grow:1; + display:-ms-flexbox; + display:flex; + -ms-flex-pack:center; + justify-content:center; + -ms-flex-align:center; + align-items:center; +} +.jodit_filebrowser_preview_navigation{ + position:absolute; + top:0; + height:100%; + left:0; +} +.jodit_filebrowser_preview_navigation-next{ + left:auto; + right:0; +} +.jodit_filebrowser_preview_navigation svg{ + width:45px; + height:45px; + position:relative; + top:50%; + margin-top:-22px; + transition:fill .3s linear; + fill:#9e9ba7; +} +.jodit_filebrowser_preview_navigation:hover svg{ + fill:#000; +} +.jodit_filebrowser_preview img{ + max-width:100%; + max-height:100%; +} +.jodit_grid{ + display:-ms-flexbox; + display:flex; + width:100%; +} +.jodit_grid [class*=jodit_col-]{ + -ms-flex:1 1 auto; + flex:1 1 auto; +} +.jodit_grid .jodit_col-lg-5-5{ + width:100%; +} +.jodit_grid .jodit_col-lg-4-5{ + width:80%; +} +.jodit_grid .jodit_col-lg-3-5{ + width:60%; +} +.jodit_grid .jodit_col-lg-2-5{ + width:40%; +} +.jodit_grid .jodit_col-lg-1-5{ + width:20%; +} +.jodit_grid .jodit_col-lg-4-4{ + width:100%; +} +.jodit_grid .jodit_col-lg-3-4{ + width:75%; +} +.jodit_grid .jodit_col-lg-2-4{ + width:50%; +} +.jodit_grid .jodit_col-lg-1-4{ + width:25%; +} +@keyframes rotate{ + to{ + transform:rotate(1turn); + } +} +.jodit_icon-loader{ + background:url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAIAAAACACAYAAADDPmHLAAAABGdBTUEAAK/INwWK6QAAABl0RVh0U29mdHdhcmUAQWRvYmUgSW1hZ2VSZWFkeXHJZTwAABRsSURBVHja7F1/aJfVGn/33RgUg8FiNfK2WCykyS7GLoYyUbwYipZMumgLo+iPS9HlXhSHkRXdislESxMz0mapuaFo2myjkfnNlTQ2FJdTu8NvLVcrdbpcfGvxrfs823m/vXt3fjznvOedzr0PPJzzPe+7d+97Ps95nuc851fGAw884CD98ccfI1Jqmc3UpEyQz4FkMqRTgYshn8fymZ57SyGbzf5mENIOz9+ngE9Atg/SLkhPQHoWeEDn3SmpSZlJnvf7ypUrTpb7IyMjY+gGN6WWmaY84l2T3c+u58D1csjOgvwsyBdBvsDRo2zgMl/ZNM59vcAJ4Dj8nzikLa5QmBLv28YCfPd3li7gPHBMwKdcEwhCJgN6FoLOWJtUgiWovALG04FXsbI44xbgw8AplbaU/Q+ZQNgGf0gA/JWhC1aQyle1eN91rPRKKKuEsjzZvSph0m2RiutpIYRrfZC8B+l7kB6jgq0CnQIy9X39v2NYQW5FeUFQlQVN/aALyiYBPw/5M5B+Dvw02vMggqcDukEl57F3xHf9H747+4bA5oD6dzqaYEgAqIDbBl9RhvZ4H/B5yL+IDp3oXhmwNkm3lTLn80VIz+O3QFqm2/rHwgeI6QDOa006LZ3Q4lHNNwK3AVeYAD4WgmHQUivYNzWyb7xufICYaavXVbuKZ6MXfwRVJ+TnXW+Am/oMnNaO3/Y5pPitcyh/a6LqtXwAt+J01LVFEzAJ0jpIj7JunJYd1wHchnBQHUSC3Uan8WPgPVgHlBiBCcAkH4Da2i2DjwGZlcy5W0K17zLwVb9NgaY4iJpawJs+BCnWwUo3SKXT4oOAP8IHCFsIfMCguj8JaQ2kOaaA227d10ALuIR1gHVxErjctPtHBd8btSR3A4MIgSePAZxqVPeQlthq7ZRuZVABCVkLuGkJpGgKsY4ybfUEVO84qhsoAzSgrUfHZ1UQVe99B6o2oMYdwg7latAq5iROGoueQExW6UE0gCe/ANIh9SZ6jqkWsN3STZ0rHWEgpkNmEvILxqQbSAXaAPxqSBswQkbpbpo6fGPR0m3GBYjBIIwqNjCTEAr4wkBQUA0AjKNrdZCu0okAqgQhTKCDhFxV91BNgsDuYx3WQZptG3xtDUCJEDKvthGuLVEJlq4gUMyAylfQERadPrhKOHTmB3Ces4RFEXNsgW8UClbZcEhxqPQIpHOord2k1ZsAH4YvYNJXN3EgWX4Ocw4LbIEvDQSJfADJtULWxSuj+BBUP4DaC6D0DkyFg6JKTVo/5brvXqzbo2zSi3af3/9bGgrW1Ar5kH4MXEzVHEHVf5CuYZC4fti9AoI/gXX8Eda5Tp9f9I4xWWsnOoc5zNMv1okjmKp/vzay3epNJ4+YmALdoWBPWTHksc5zTU1AekqYt7LcWTruTYTZQdmQHoB0GuXv/de8L8e7xrsuA8kPNtx3AZIOxp3APc7wvD6kvi+//DLh3nvPPfegWs1jf4dBGGxpOA+hlOXzgw7VBjEBnDKcs4jzDOZDOmjqD2SJQFGBx9JaSOcQ7xVO2RIJhf86AfB+Z3huHs7Ra2pra+ugtubTp0+jMLgC0e6/ftddd6EgzMO5iGwSaq4NITCdLczy6GzXAj8KnDIxAaM0AKeViwCtgbRSNgGUJwQyDaACngO4w6S/CXgb8KEvvvgiFUaw59y5c64mWXvnnXdmsijdYxjpdP6cXh6oS0g1Bb48zpFEzValA3663pcuXaoleSzFltBIlWhRmWx+v6yMcQJ4PU7A/Oyzz/qca0R33HEHrjlAEJa73rns24JqA0keTUGTjglIJpNOxsMPP6wLfiGkx53hxRbcewwXc1BAx0u4gGMNcP2nn36acq4juv322ytZ5K7UlhBo5LER3AvcTXU60wKgYbsyWTCi3LTV6wLvKesGrvrkk0/qneucCgoKHoJkHbxvYRAhMMij/zMbVzZRTMAvv/wycj4AoRv4Mk7oII4HkLp+vC6drwxt/FrgKeMBfKTe3t69UMFTgPG9B3WcQdMeBsvjhJJqnYGqjMrKSmr/tZxNWAi87o9i+1l5O6SPNjc3dzrjlPLz83HyC/aWpqk0gWZUUHZtJvxuUZmAtAYgtHycr/a6qIXz2DQI5OH1UDRjPIOPdOHChU6o+JmQXW+68JYS4vUB/bozvN5RGAImdwPZA3AC51RKrMAfyBHFGCRBnz4oe7ypqemgc4PQxYsX0YytuOWWW3BRaa3DWd0U1A/w/Z4KvBx4jcoExAitE6dzPStr3RR/QKQ5fOUJ4PsaGxtvGPC9dOnSJfyu+7ALa9MJFPx+lkU05YNBBDVdg0uwKc4eAWCZ83cC8jM+/PDDLucGpr6+Pvy+GWz/ASs9AMFvd7ax1ATEFOBjmLdSBraN3gBwHHhmQ0NDrzMB6PLly73MUYubOs3EiB/GJebyTEB6QogCnGrV6KAFR7AVeP4HH3ww4EwgunLlCn7vfACi1UQDqMb5PWUvm5qAB3HESXNomKz2GaOHv/DAgQNJZwJSf38/fvdC3J5G1iPQnf3jK5sGvx80MQHP69hxHWZ/2wN8//vvv3/BmcD0008/XWCaoEcUJ6C0eoUWeFbXBOBCzTKKJ2/YExgEXrRv374eJyLn6tWrWA+LAJRBy+o/rQUQUx0TsFwzRKzLK/bu3dseQf8nDQwMYH2sCOL0ibx9Vr6cagIKmf0nxe8pguC7vn/Pnj2bIshH088//4z1st+m+veUI6ZFFBOwLGj/XqIh0O4/HkEtJgDmcZ4/EED9e69VKk0ACoDN1u/jqrq6uv4IZjElk0msnypbwPs0wTKVCUBnYbLuMC5REA7v3r37vQhikhBgPTWrTAEFeB9NZt3C0SbAr/6DdPM4jF7/PyNotUzBU26vgAo8x+7zri3jmgAgnOJdKYrVB9QEb+zcubMrgpVOv/76K9bXGzrACwTJfw1D+9k8EzAXOE8GviEPAK+JIDXSAlhvA7yWTWztvMfiXM65PBNQrgLfUBi2v/vuu70RnPo0ODjYC0BtN3D2VNfLR5gAz04eRn17yb0p4A0RlIEI6y+la/MV1xf4fYACSEtDiP031dbWRrY/AP32229dAGCTrs1XrHHEaesFXh+gXCfooyEM2yIIrdC2ADZ/1D1eM+CagHLJ5ExTxrl9hyLsrDiDWI99EjApgPvLRwhAmQh4HV/Axwe3bt06GMEXnFKpFK4tOBgQcH95WdoEAE01nc8Xi8VEArA3gs4q7VWpfsHaCpEg4GrnoeXhOEKUw3u4yZYqbGo4Lk2KR5hZpcOsXjO9GIm0AYFycTErmoDJVLWu0Tto3bJly0CEmT36/fffkzh/UKfVE3yLkix3Xx+v5FjYaaslgiwUZxDrdbrm38guF6EAFFKAF5kEwcFPrRFcoVCrIdAiKsSlYUWqFi/zBwTXOiKsQqGOIKe1cQRmSAPkmYIv0ADY9Yuif+GYgC5Wv9kB1L6X8lAA8k3BFwhB94YNG1IRXPYJutwpINwBpNjSI/O5AhDQGUxEUIVKCRMBEGiFIQG4yX+Daf+fPacvwihUM2Czfm/KcgMLtjZZhudEY//hks2VVJlZ7tJvi5SMMApVA9gMsOVkXYvDFiO6fggFACUqJ6qKcaMBbD5uAH2AlE0fIKJxRSnUAGizcykePtWzjOo1VA2gpa0V2CVRALBbURDwQV4qiGAKVQDyLZ571JfFum0lFqTJvScvgilUytPxAxSY9boawMbD3OtFEUahaoAinQap0gA4JSzhPswSFz733HOZEVT2KZlMYr0WesGV7KpOoQRqgG6DVi4rx5EqjFWfjSCz3vqLHd9IoGyYnoBjNwpAwhBoWXlpJAChCECpv66p5ycJBCSBcwI7daZ7E83FtAiuUGgaT/WLACaYhk4MBCVk0UDKWb2c3+URVqFogOm8OqccqMW5d+Dmm29OuGsDOyw7gmUvvfRSFBCySFevXsX6LBO1cIoG8NEQ5u7KoFbLi0Kz3fODI7JGeHbwTSJADcxCq1cAWnR39yYIQUWEmVX1X2G6SYTgnhavABwL0uoF91dUV1dnR9AFp/7+fjysq0IGvIEGODYkAOwa7t/XYXl3kDzgBRF8Vgg3eczT2SqGYP97vBoA83ELrd6/WPSJCDsr6v8Jw91BRdfS6za9ewQ1qVo9RQv47plXU1NTHEFoTpcvX8aTwueJgKdoAI4wpE8Y9e4SdtgdGLK4S1gm8L8jGAO1fqy/TNmiUE1hQIwPj9AADOQk7ugRdJ9ADj+2bt26aI6AAV26dAnr7THqnsFEYTgEnBRtFl0fwk6hOcCrIjiNaBXOAKIcuq3hG4w4fTXma+lNOEHEZFs4hcA8+eqrr0a+gAZdvHgRbf+TsrMDDMxBr2v/eT7A0L5+8HN7AKdPFhncHMGqZftfB84Wga0yBwKtsN1hk4B5PsCIrd0C2HwRz924cWNlBK2afvzxx0rX89c5Qo4gCNv85bwDI7r8XUKqynfL/KmHazZt2pQbQSymH374AffuqeEB7gWXCrzHFCCmXf5niE4NWxPkJFAJ41GmtRHMUtWP9TNJdYScgQZYo3NoFEYF21WmgAq8776KzZs3Px1BPZq+//57rJcKXhg3oClo90b/qCeHvqLjA2j6B+u2bNlSFkH+J3333XdlAMo6ntq3cJroK6K4gOzgyP2oBaj2nqIdPGXYKzjw5ptvToqgd5yenh5U+Qcgmy07UdxQA7QD7xfFClSnh68Oelag6H5n+Fj6j9566638iQz++fPn8wGMRq/dV4EviwVwrq0W9QpUJsAdINof5LRQxfNLgBu2bt06IaePffvttzjDp8EZ3r6dDL7sQEkfyAdVW82rjo9H/hdkB2y2ft89eEB149tvvz2hlqh/8803OazlTzMFX6ENcKLvU7LgEMUEuIc9vqLb+inBJE8ezyo+un379gkxaPT111/jdx4FEGbJwOd1A2VdQ9896Pj1qIJDMSJI6yHpNGnpGlHFqVgp77zzzg29tjCRSBQx8KfKWrmJBvDkO4HXU3oI7pQwFUDpc/8s9ABk14uB23bs2HFDTiU7d+7cAqj4NrbESxtojeAQYjWoOnyaqwF4AsFSnDm81lT1y2YZ+cpwLmHDzp07a3bt2nVDTCrt6urKBq5hDl8eBXCTHgGjtWxTaVK8IEYFjKWrvVPIdU8VE2kMgUCsBD6ye/fukvEM/ldffVUCFX4EsitVtl3UYjU0wDHg1dQIodQJFJShKXgE0j5dLaACn6MJkKcDH6+rq6uur68fV72EM2fO5Jw9e7YasseBp5u0cKoQsDxO9Vrqqn6R2hdGAjWEoBvSR03B9wPNA95HGDVcBXxqz549D40H8E+fPo3vecoZntGTreqzmwgBRyDw2Plu3TBxxmuvvcYFUQYwy+OQ5UoV6DITQzEJnGsdbLSyfvHixdfVptSnTp2qZMJaqtsVVtWbAiP0zap498ryt956q5OxYcMGyj/gpbhbxS5IlwSJBQQYYsZVzWtREBYtWnTN9ic+efIkOq1LmM9SZDKplioQgrJ6ZpZTVODd32kBIEoZL0UvvdFdCBoUfGo8gXM0/UHgHTireeHChaFrhePHj+N0dzxqdxnwg2xwS0vD6YIvwAOnd89nvhkZeJduu+02J2Pjxo0UKZO9GM7w+cjdFMIgCmiqAXj39bO5DPFYLNY8b948ayeXtLW1lbIT1mcxzjVZUGtqCjh44Bj/34H7ZXjJhCItAAHAd1Mc0fvcPYAqCPhBhIHDF5jP0MF2QkmwE02HTMjs2bPTpqOlpSXPVeHABSwoVcLsOebzTWZH2fADOClO7ZqB3yfDTWUSUACyiHZG9UJY0SiNH7PKIjsiqt6BooegIhTMOYxHUTweN3q26EAN/wkr3t+qvEaKczbvxzoXPcf7brL/a9oNFKXYPZzpnUpGlX6dbqHIDIRNlIWXsuibbjdQkGLdzoQ0YfJ/uJFAamsndllw19HZzDlxVGFmkcqilFnSEFotnnKNOlZPGQX0lWOdzoa01xR47nCwDtBEpwbHoedj94wy0KSKCOoIQhgaQrXZgkoYdMCXPAvrcr57WITuXEHlcLCu00cQGjza7BEcRjbRAFSNQAXXVAh0zuY1BV/Q2r3pekixnz+oGRomvVtMV9Vr3I/98RXAC73LzoM4grIWb1sIxgp8iSnAOlsIKdZhynB8QG8wiKIBDPyCQ5C9F0cRKY6gDFwZ2DaFIEzwCS3e3b/nXlzKras1dFr/KA2go/5FLVRwfzdzDtfodgupZoFqGohbqIYGPsH+Yx3NxF6V7D2omkXlmMZM1T8PDMXfoUl4BruKkHaaaANbtj2MnoEJ+L6/72RdvGe8Kt9kjqBOj4SsAUyvce7BCSV/Ba6C/EBYXcSg5oIKtqkj5ikbgLSKqfwWaheRWqZ6j1gIAFPuQW2AI3lTIN0b1CSonMSwYgCU6wqQ8NunsOHcQcozVKZIVwhiKjVuMEihY0YwevgPSDG0eUy3ezjWYOsEhRRAHWPf/A93Egc1MKTj+FGEIGZhIEgJiMzPYPlmHNxgjmLTtRSCsOw+o2YWzcNvbTYIBVsVgrQGsAW+6cCSJx9nUcS/QbrfVAjCDgQZ/P1+yOM33Q9pPMizqCaAKgSxsMCntk6B2sdVyYsh/QvwC7hriY4QhCkUGi0e3/kF/AYow29pJ8YArJkAihDEwgRfVyNw8rif7X+B74Y8qs03nOGNDq0IgQ3Afff0sXecAfm72bv3UFoxpdWbtH7V32cFcfgoLcyCEKQdJ9zVHNL/AM9ijOP808MYD/CP7UvuO8ZGP+OMB3nP4T1PNfYvey/KXAPKd2XpevA27iWYANk9g8yZamblOa5A4FQtZ/jEsjybWsBTaX1sQkbcA/iACAQd0E2EQgU8RUiyKC02qGnQjS6qwPP9LQJwiLFLuUwQcBuaIiYQuBjTPc8wk/32VtYJFq104xQnmLlJMPuNNr3fUEuQQtDUVm8DeNcc/F+AAQBKd8HaIWdjwQAAAABJRU5ErkJggg==") no-repeat 50%; + background-size:100% 100%; + width:48px; + height:48px; + will-change:transform; + animation:rotate 2s ease-out 0s infinite; +} +.jodit_icon,.jodit_icon-loader{ + display:inline-block; + vertical-align:middle; +} +.jodit_icon{ + font-style:normal; + width:14px; + height:14px; + font-size:8px; + fill:#222; + transform-origin:0 0 !important; + overflow:visible; + background:50% no-repeat; + background-size:contain; +} +.jodit_icon_close{ + stroke:#222; +} +svg.jodit_icon{ + isolation:isolate; + height:auto; +} +.jodit_text_icon{ + font-size:14px; +} +.jodit_toolbar_size-small .jodit_icon{ + min-width:12px; + height:12px; + line-height:12px; +} +.jodit_toolbar_size-large .jodit_icon{ + min-width:16px; + height:16px; + line-height:16px; +} +.jodit_image_editor{ + width:100%; + height:100%; + padding:10px; + overflow:hidden; +} +@media (max-width:768px){ + .jodit_image_editor{ + height:auto; + } +} +.jodit_image_editor>div,.jodit_image_editor>div>div{ + height:100%; +} +@media (max-width:768px){ + .jodit_image_editor>div,.jodit_image_editor>div>div{ + height:auto; + min-height:200px; + } +} +.jodit_image_editor *{ + box-sizing:border-box; +} +.jodit_image_editor .jodit_image_editor_slider-title{ + text-shadow:#f3f3f3 0 1px 0; + color:#333; + border-bottom:1px solid hsla(0, 0%, 62%, .31); + background-color:#f9f9f9; + padding:.8em 1em; + text-overflow:ellipsis; + white-space:nowrap; + cursor:pointer; + -webkit-user-select:none; + -moz-user-select:none; + -ms-user-select:none; + user-select:none; + font-weight:700; + line-height:1em; +} +.jodit_image_editor .jodit_image_editor_slider-title svg{ + margin-right:10px; + width:16px; + display:inline-block; + vertical-align:middle; +} +.jodit_image_editor .jodit_image_editor_slider-content{ + display:none; +} +.jodit_image_editor .jodit_image_editor_slider.active .jodit_image_editor_slider-title{ + background-color:#5d5d5d; + color:#fff; + text-shadow:#000 0 1px 0; +} +.jodit_image_editor .jodit_image_editor_slider.active .jodit_image_editor_slider-title svg{ + fill:#fff; +} +.jodit_image_editor .jodit_image_editor_slider.active .jodit_image_editor_slider-content{ + display:block; +} +.jodit_image_editor_area{ + width:100%; + background-color:#eee; + background-image:linear-gradient(45deg, #ccc 25%, transparent 0, transparent 75%, #ccc 0, #ccc), linear-gradient(45deg, #ccc 25%, transparent 0, transparent 75%, #ccc 0, #ccc); + background-size:30px 30px; + background-position:0 0, 15px 15px; + height:100%; + overflow:hidden; + -webkit-user-select:none; + -moz-user-select:none; + -ms-user-select:none; + user-select:none; + position:relative; + display:none; +} +.jodit_image_editor_area.active{ + display:block; +} +.jodit_image_editor_area .jodit_image_editor_box{ + overflow:hidden; + position:relative; + z-index:1; + pointer-events:none; + height:100%; +} +.jodit_image_editor_area .jodit_image_editor_box img{ + -webkit-user-select:none; + -moz-user-select:none; + -ms-user-select:none; + user-select:none; + max-width:100%; + max-height:100%; +} +.jodit_image_editor_area .jodit_image_editor_croper,.jodit_image_editor_area .jodit_image_editor_resizer{ + z-index:2; + width:100px; + height:100px; + position:absolute; + box-shadow:0 0 11px #000; + border:1px solid #fff; + background-repeat:no-repeat; + top:10px; + left:20px; + pointer-events:none; +} +.jodit_image_editor_area .jodit_image_editor_croper i.jodit_bottomright,.jodit_image_editor_area .jodit_image_editor_resizer i.jodit_bottomright{ + position:absolute; + display:inline-block; + border:1px solid #383838; + z-index:4; + background-color:#8c7878; + cursor:se-resize; + border-radius:10px; + height:20px; + width:20px; + right:-10px; + bottom:-10px; + box-shadow:0 0 11px #000; + pointer-events:all; +} +.jodit_image_editor_area .jodit_image_editor_croper i.jodit_bottomright:active,.jodit_image_editor_area .jodit_image_editor_resizer i.jodit_bottomright:active{ + border:1px solid #ff0; +} +.jodit_image_editor_area.jodit_image_editor_area_crop{ + height:100%; + background:#eee; + text-align:center; + line-height:100%; + position:relative; +} +.jodit_image_editor_area.jodit_image_editor_area_crop:before{ + content:""; + line-height:100%; + vertical-align:middle; + height:100%; + display:inline-block; +} +.jodit_image_editor_area.jodit_image_editor_area_crop .jodit_image_editor_box{ + height:100%; + overflow:visible; + display:inline-block; + vertical-align:middle; + pointer-events:all; + font-size:0; + text-align:left; + line-height:100%; +} +.jodit_image_editor_area.jodit_image_editor_area_crop .jodit_image_editor_box img{ + max-width:100%; + max-height:100%; +} +.jodit_image_editor_area.jodit_image_editor_area_crop .jodit_image_editor_box:before{ + content:""; + line-height:100%; + vertical-align:middle; + height:100%; + display:inline-block; +} +.jodit_image_editor_area.jodit_image_editor_area_crop .jodit_image_editor_box:after{ + content:""; + position:absolute; + top:0; + left:0; + bottom:0; + right:0; + margin:auto; + background:hsla(0, 0%, 100%, .3); + z-index:1; +} +.jodit_image_editor_area.jodit_image_editor_area_crop .jodit_image_editor_box .jodit_image_editor_croper{ + pointer-events:all; + cursor:move; +} +.jodit_image_editor_area.jodit_image_editor_area_crop .jodit_image_editor_box .jodit_image_editor_croper i.jodit_sizes{ + font-size:12px; + white-space:pre; + position:absolute; + bottom:-30px; + left:100%; + text-align:center; + color:#fff; + text-shadow:none; + background:rgba(0, 0, 0, .2); + border-radius:.4em; + padding:9px 6px; + display:block; +} +.jodit_properties{ + font-family:Helvetica,sans-serif,Arial; + font-size:14px; +} +.jodit_properties svg{ + font-style:normal; + display:inline-block; + width:14px; + height:14px; + line-height:14px; + font-size:8px; + overflow:hidden; + vertical-align:middle; + fill:#222; + transform-origin:0 0 !important; +} +.jodit_properties .jodit_properties_view_box{ + padding:10px; +} +.jodit_properties .jodit_properties_view_box .jodit_properties_image_view{ + display:-ms-flexbox; + display:flex; + -ms-flex-align:center; + align-items:center; + -ms-flex-pack:center; + justify-content:center; + height:150px; + padding:0; + margin:0 0 10px; + background-color:#f6f6f6; +} +.jodit_properties .jodit_properties_view_box .jodit_properties_image_view img{ + max-width:100%; + max-height:100%; +} +.jodit_properties .jodit_properties_view_box .jodit_properties_image_sizes.jodit_form_group{ + -ms-flex-direction:row; + flex-direction:row; + -ms-flex-align:center; + align-items:center; + padding:0 !important; + margin:0 !important; +} +.jodit_properties .jodit_properties_view_box .jodit_properties_image_sizes.jodit_form_group a{ + display:inline-block; + cursor:pointer; +} +.jodit_properties .jodit_properties_view_box .jodit_properties_image_sizes.jodit_form_group input[type=number]{ + display:inline-block !important; + width:calc(50% - 8px) !important; +} +.jodit_toolbar,.jodit_toolbar *{ + box-sizing:border-box; +} +.jodit_toolbar{ + font-family:Helvetica,sans-serif,Arial; + font-size:14px; + position:relative; + left:0; + top:0; + display:-ms-flexbox; + display:flex; + -ms-flex:0 0 auto; + flex:0 0 auto; + -ms-flex-negative:0; + flex-shrink:0; + -ms-flex-wrap:wrap; + flex-wrap:wrap; + margin:0 !important; + padding:0 !important; + list-style:none !important; + font-size:0; + background:#f9f9f9; + box-shadow:0 4px 4px -2px rgba(0, 0, 0, .14); + border:1px solid #ccc; + border-bottom:0; + min-height:16px !important; +} +.jodit_toolbar+.jodit_toolbar_dummy{ + display:none; +} +.jodit_toolbar.jodit_fly{ + position:absolute; + left:0; + right:0; + z-index:30000; + background:#fff; +} +.jodit_toolbar>.jodit_toolbar_btn{ + margin:0 !important; + padding:0; + list-style:none !important; + outline:none; + position:relative; + text-align:center; + cursor:pointer; + transition:background-color .2s linear,opacity .1s linear; +} +.jodit_toolbar>.jodit_toolbar_btn.jodit_disabled{ + background-color:transparent !important; + opacity:.3; + cursor:default; +} +.jodit_toolbar>.jodit_toolbar_btn.jodit_disabled a{ + cursor:default; +} +.jodit_toolbar>.jodit_toolbar_btn .jodit_toolbar_btn>a,.jodit_toolbar>.jodit_toolbar_btn>a{ + width:100%; + height:100%; + outline:none; + text-decoration:none; +} +.jodit_toolbar>.jodit_toolbar_btn .jodit_toolbar_btn>a:active+.jodit_tooltip,.jodit_toolbar>.jodit_toolbar_btn>a:active+.jodit_tooltip{ + visibility:hidden !important; +} +.jodit_toolbar>.jodit_toolbar_btn .jodit_toolbar_btn>a:focus,.jodit_toolbar>.jodit_toolbar_btn>a:focus{ + outline:1px solid #ccc; +} +.jodit_toolbar>.jodit_toolbar_btn.jodit_disabled .jodit_tooltip{ + display:none !important; +} +.jodit_toolbar>.jodit_toolbar_btn>a{ + line-height:100%; +} +.jodit_toolbar>.jodit_toolbar_btn.jodit_dropdown_open .jodit_tooltip,.jodit_toolbar>.jodit_toolbar_btn.jodit_popup_open .jodit_tooltip,.jodit_toolbar>.jodit_toolbar_btn .jodit_toolbar_list-open .jodit_tooltip{ + visibility:hidden !important; +} +.jodit_toolbar>.jodit_toolbar_btn:not(.jodit_toolbar-input):hover{ + background-color:#dde4ef; + outline:none; +} +.jodit_toolbar>.jodit_toolbar_btn.jodit_active,.jodit_toolbar>.jodit_toolbar_btn:not(.jodit_toolbar-input):active{ + background-color:hsla(0, 0%, 86.7%, .4); + outline:none; +} +.jodit_toolbar>.jodit_toolbar_btn.jodit-btn-hidden{ + display:none !important; +} +.jodit_toolbar>.jodit_toolbar_btn.jodit_with_dropdownlist .jodit_with_dropdownlist-trigger{ + display:inline-block; + vertical-align:middle; +} +.jodit_toolbar .jodit_toolbar_btn-separator{ + border-left:0; + border-right:1px solid #e6e6e6; + padding:0; + margin:2px 5px 0 !important; + cursor:default; +} +.jodit_toolbar .jodit_toolbar_btn-break{ + -ms-flex-preferred-size:100%; + flex-basis:100%; + width:0; + border-top:1px solid #e6e6e6; + height:0 !important; +} +.jodit_toolbar .jodit_toolbar_btn{ + min-width:32px; + height:32px; + line-height:32px; +} +.jodit_toolbar .jodit_toolbar_btn.jodit_toolbar_btn-separator{ + height:28px; + width:0; + min-width:0; +} +.jodit_toolbar .jodit_toolbar_btn.jodit_with_dropdownlist{ + padding:0 7px; +} +.jodit_toolbar .jodit_toolbar_btn.jodit_with_dropdownlist .jodit_with_dropdownlist-trigger{ + width:8px; + height:8px; + margin-left:5.33333333px; +} +.jodit_toolbar_btn>a{ + color:#000; + text-decoration:none; + display:-ms-flexbox; + display:flex; + -ms-flex-pack:center; + justify-content:center; + -ms-flex-align:center; + align-items:center; + background:no-repeat 50%; +} +.jodit_toolbar.jodit_text_icons>.jodit_toolbar_btn>a{ + line-height:1; +} +.jodit_tooltip{ + position:absolute; + background:#727171; + color:#fff; + font-family:Helvetica,sans-serif,Arial; + font-size:14px; + font-size:12px; + line-height:15px; + white-space:normal; + padding:4px 5px; + z-index:10001; + min-width:90px; + max-width:120px; + width:auto; + transition:opacity .3s linear; +} +@media (max-width:768px){ + .jodit_tooltip{ + display:none; + } +} +.jodit_toolbar_size-small .jodit_toolbar{ + min-height:12px !important; +} +.jodit_toolbar_size-small .jodit_toolbar .jodit_toolbar_btn{ + min-width:24px; + height:24px; + line-height:24px; +} +.jodit_toolbar_size-small .jodit_toolbar .jodit_toolbar_btn.jodit_toolbar_btn-separator{ + height:20px; + width:0; + min-width:0; +} +.jodit_toolbar_size-small .jodit_toolbar .jodit_toolbar_btn.jodit_with_dropdownlist{ + padding:0 5px; +} +.jodit_toolbar_size-small .jodit_toolbar .jodit_toolbar_btn.jodit_with_dropdownlist .jodit_with_dropdownlist-trigger{ + width:6px; + height:6px; + margin-left:4px; +} +.jodit_toolbar_size-large .jodit_toolbar{ + min-height:18px !important; +} +.jodit_toolbar_size-large .jodit_toolbar .jodit_toolbar_btn{ + min-width:36px; + height:36px; + line-height:36px; +} +.jodit_toolbar_size-large .jodit_toolbar .jodit_toolbar_btn.jodit_toolbar_btn-separator{ + height:32px; + width:0; + min-width:0; +} +.jodit_toolbar_size-large .jodit_toolbar .jodit_toolbar_btn.jodit_with_dropdownlist{ + padding:0 8px; +} +.jodit_toolbar_size-large .jodit_toolbar .jodit_toolbar_btn.jodit_with_dropdownlist .jodit_with_dropdownlist-trigger{ + width:9px; + height:9px; + margin-left:6px; +} +.jodit_toolbar_popup{ + position:absolute; + z-index:10; + top:100%; + left:0; + margin-top:10px; + padding-top:0; + font-size:14px; + line-height:14px !important; + background:#fff; + box-shadow:0 2px 4px rgba(0, 0, 0, .2); + border:1px solid rgba(0, 0, 0, .2); +} +.jodit_toolbar_popup .jodit_toolbar{ + box-shadow:none; + border-width:0; + background-color:transparent; +} +.jodit_toolbar_popup .jodit_toolbar .jodit_toolbar{ + background-color:#f9f9f9; + box-shadow:0 4px 4px -2px rgba(0, 0, 0, .14); + border:1px solid #ccc; +} +.jodit_toolbar_popup>*{ + margin:10px; +} +.jodit_toolbar_popup .jodit_popup_triangle{ + position:absolute; + top:-5px; + left:9px; + z-index:6; + padding:0; + margin:0; + width:8px; + height:8px; + display:inline-block; + transform:rotate(45deg); + background:#fff; + border:solid rgba(0, 0, 0, .2); + border-width:1px 0 0 1px; +} +.jodit_toolbar_popup.jodit_right{ + left:auto; + right:0; +} +.jodit_toolbar_popup.jodit_right:before{ + left:auto; + right:14px; +} +.jodit_toolbar .jodit_toolbar_btn>svg{ + max-width:50%; + vertical-align:middle; +} +.jodit_container>.jodit_toolbar>li:first-child{ + margin-left:2px !important; +} +.jodit_container[dir=rtl]>.jodit_toolbar>li:first-child{ + margin-left:0 !important; + margin-right:2px !important; +} +.jodit_draganddrop_file_box,.jodit_uploadfile_button{ + position:relative; + width:100%; + border:1px dashed #ccc; + padding:25px 0; + margin:10px 0; + text-align:center; + overflow:hidden; +} +.jodit_draganddrop_file_box:hover,.jodit_uploadfile_button:hover{ + background-color:#ecebe9; +} +.jodit_draganddrop_file_box input,.jodit_uploadfile_button input{ + cursor:pointer; + position:absolute; + right:0; + top:0; + bottom:0; + left:0; + margin:0; + padding:0; + opacity:0; + font-size:400px; +} +@media (max-width:768px){ + .jodit_draganddrop_file_box{ + width:auto; + max-width:100%; + min-width:180px; + } +} +.jodit_statusbar{ + font-family:Helvetica,sans-serif,Arial; + font-size:14px; + display:-ms-flexbox; + display:flex; + -ms-flex-pack:justify; + justify-content:space-between; + border:1px solid #ccc; + border-top:0; + font-size:0; + background-color:#f9f9f9; + padding:0 5px; +} +.jodit_statusbar .jodit_statusbar_item{ + font-size:11px; + line-height:1.57142857em; + margin:0 10px 0 0; + padding:0; + -ms-flex:1; + flex:1; +} +.jodit_statusbar .jodit_statusbar_item.jodit_statusbar_item-right{ + margin:0 0 0 10px; + -ms-flex-order:1; + order:1; + -ms-flex:0; + flex:0; +} +.jodit_statusbar .jodit_statusbar_item .jodit_icon{ + font-size:11px; +} +.jodit_statusbar .jodit_statusbar_item li,.jodit_statusbar .jodit_statusbar_item ul{ + position:relative; + margin:0; + padding:0; + list-style:none; + display:-ms-flexbox; + display:flex; + -ms-flex-pack:center; + justify-content:center; + -ms-flex-align:center; + align-items:center; +} +.jodit_statusbar .jodit_statusbar_item li li,.jodit_statusbar .jodit_statusbar_item ul li{ + margin-right:5px; +} +.jodit_statusbar .jodit_statusbar_item ul{ + -ms-flex-pack:start; + justify-content:flex-start; +} +.jodit_statusbar .jodit_statusbar_item a,.jodit_statusbar .jodit_statusbar_item span{ + -webkit-user-select:none; + -moz-user-select:none; + -ms-user-select:none; + user-select:none; + display:inline-block; + vertical-align:baseline; + text-align:left; + white-space:nowrap; + padding:2px 3px; + line-height:10px; + outline:0; + border:0; + color:#222; +} +.jodit_statusbar .jodit_statusbar_item a span,.jodit_statusbar .jodit_statusbar_item span span{ + padding:0; +} +.jodit_statusbar .jodit_statusbar_item svg{ + width:11px; + height:11px; + display:inline-block; + vertical-align:top; +} +.jodit_statusbar .jodit_statusbar_item a{ + text-decoration:none; + cursor:default; + border-radius:3px; +} +.jodit_statusbar .jodit_statusbar_item a:hover{ + background-color:hsla(0, 0%, 88.2%, .99); + text-decoration:none; + color:#222; +} +.jodit_statusbar:after{ + content:" "; + display:block; + visibility:hidden; + font-size:0; + height:0; +} +.jodit_disabled .jodit_statusbar{ + opacity:.4; +} +.jodit_about{ + padding:20px; +} +.jodit_about a{ + color:#459ce7; + text-decoration:none; +} +.jodit_about a:focus,.jodit_about a:hover{ + color:#23527c; + text-decoration:underline; + outline:0; +} +.jodit_about div{ + margin-bottom:5px; +} +.jodit_colorpicker{ + min-width:180px; + text-align:left; + margin:0; + -webkit-user-select:none; + -moz-user-select:none; + -ms-user-select:none; + user-select:none; +} +.jodit_colorpicker .jodit_colorpicker_group{ + margin-bottom:5px; + white-space:normal; +} +.jodit_colorpicker a{ + width:18px; + height:18px; + line-height:16px; + display:inline-block; + text-decoration:none; + vertical-align:middle; + text-align:center; +} +.jodit_colorpicker a:before{ + content:""; + display:inline-block; + height:100%; + vertical-align:middle; + width:0; +} +.jodit_colorpicker a svg{ + display:inline-block; + vertical-align:middle; + font-smoothing:antialiased; + max-width:14px; +} +.jodit_colorpicker a:hover{ + border-color:#000; +} +.jodit_colorpicker a:active{ + background:#d6d6d6; + color:#b5b5b5; +} +.jodit_colorpicker .jodit_text_icon{ + width:auto; + text-decoration:none; + color:#000; +} +.jodit_colorpicker span em{ + width:16px; + height:16px; + display:inline-block; + margin-right:4px; +} +.jodit_colorpicker span input{ + width:18px; + height:18px; + padding:0; + border:none; + -webkit-appearance:none; + -moz-appearance:none; + appearance:none; +} +.jodit_colorpicker span input[type=color]::-webkit-color-swatch-wrapper{ + padding:0; +} +.jodit_colorpicker span input input[type=color]::-webkit-color-swatch{ + border:none; +} +@keyframes pulse{ + 30%{ + opacity:.6; + } + 60%{ + opacity:0; + } + to{ + opacity:.6; + } +} +.jodit_progress_bar{ + position:absolute; + top:0; + left:0; + height:2px; + z-index:2147483647; + border-radius:1px; + display:none; +} +.jodit_progress_bar div{ + position:relative; + background:#b91f1f; + height:2px; + transition:width .5s ease-out,opacity .5s linear; + will-change:width, opacity; +} +.jodit_progress_bar div:after,.jodit_progress_bar div:before{ + animation:pulse 2s ease-out 0s infinite; + content:""; + display:inline-block; + position:absolute; + top:0; + height:2px; + box-shadow:1px 0 6px 1px #b91f1f; + border-radius:100%; + opacity:.6; +} +.jodit_progress_bar div:before{ + width:180px; + right:-80px; + clip:rect(-6px, 90px, 14px, -6px); +} +.jodit_progress_bar div:after{ + width:20px; + right:0; + clip:rect(-6px, 22px, 14px, 10px); +} +.jodit_tabs{ + font-family:Helvetica,sans-serif,Arial; + font-size:14px; +} +.jodit_tabs .jodit_tabs_buttons{ + line-height:18px; + margin-bottom:5px; + margin-top:4px; + display:-ms-flexbox; + display:flex; +} +@media (max-width:768px){ + .jodit_tabs .jodit_tabs_buttons{ + display:block; + } +} +.jodit_tabs .jodit_tabs_buttons>a{ + display:-ms-flexbox; + display:flex; + -ms-flex-align:center; + align-items:center; + -ms-flex-pack:center; + justify-content:center; + padding:5px 20px; + font-size:11px; + font-weight:700; + text-align:center; + white-space:nowrap; + height:29px; + line-height:27px; + text-decoration:none; + position:relative; + vertical-align:middle; + transition:background .1s linear; + text-overflow:ellipsis; + overflow:hidden; + box-shadow:none; + background-color:#f5f5f5; + color:#737373; + border:1px solid rgba(0, 0, 0, .1); + outline:none; +} +@media (max-width:768px){ + .jodit_tabs .jodit_tabs_buttons>a{ + width:100% !important; + border-radius:0 !important; + } +} +.jodit_tabs .jodit_tabs_buttons>a+a{ + margin-left:-1px; +} +@media (max-width:768px){ + .jodit_tabs .jodit_tabs_buttons>a+a{ + margin-left:0; + margin-top:-1px; + } +} +.jodit_tabs .jodit_tabs_buttons>a i,.jodit_tabs .jodit_tabs_buttons>a svg{ + width:16px; + height:16px; + display:inline-block; + vertical-align:sub; + margin-right:5px; + fill:#737373; +} +.jodit_tabs .jodit_tabs_buttons>a:hover{ + border:1px solid #c6c6c6; + color:#111; + box-shadow:none; + background-color:#f8f8f8; + outline:none; +} +.jodit_tabs .jodit_tabs_buttons>a:hover i,.jodit_tabs .jodit_tabs_buttons>a:hover svg{ + fill:#111; +} +.jodit_tabs .jodit_tabs_buttons>a.active,.jodit_tabs .jodit_tabs_buttons>a:active{ + outline:none; + background:#fff; + border:1px solid #ccc; + color:#333; +} +.jodit_tabs .jodit_tabs_buttons>a.active i,.jodit_tabs .jodit_tabs_buttons>a.active svg,.jodit_tabs .jodit_tabs_buttons>a:active i,.jodit_tabs .jodit_tabs_buttons>a:active svg{ + fill:#333; +} +.jodit_tabs .jodit_tabs_wrapper .jodit_tab{ + display:none; +} +.jodit_tabs .jodit_tabs_wrapper .jodit_tab.active{ + display:block; +} +.jodit_tabs .jodit_tabs_wrapper .jodit_tab .jodit_tab_empty{ + min-width:220px; + min-height:100px; +} +.jodit-add-new-line{ + z-index:1; + position:absolute; + height:20px; + line-height:100%; + vertical-align:middle; + font-size:0; + top:0; + outline:none; + margin-top:-10px; + display:none; +} +.jodit-add-new-line,.jodit-add-new-line *{ + box-sizing:border-box; +} +.jodit-add-new-line:before{ + height:100%; +} +.jodit-add-new-line:after,.jodit-add-new-line:before{ + display:inline-block; + vertical-align:middle; + content:""; +} +.jodit-add-new-line:after{ + box-sizing:border-box; + border-top:1px solid #ccc; + height:1px; + width:calc(100% - 30px); +} +.jodit-add-new-line span{ + right:0; + position:absolute; + display:inline-block; + width:30px; + height:20px; + background:rgba(236, 235, 233, .3); + vertical-align:top; + border:1px solid #ccc; + padding:0 5px; + cursor:pointer; +} +.jodit-add-new-line span:hover{ + background:#ecebe9; +} +.jodit-add-new-line svg{ + width:16px; + fill:#ccc; + vertical-align:top; +} +.jodit_source_mode .jodit-add-new-line{ + display:none !important; +} +.jodit_error_box_for_messages{ + font-family:Helvetica,sans-serif,Arial; + font-size:14px; + position:absolute; + right:0; + bottom:0; + width:0; + height:0; + overflow:visible; + z-index:3; +} +.jodit_error_box_for_messages>*{ + position:absolute; + right:5px; + bottom:0; + display:block; + transition:opacity .1s linear,bottom .3s linear; + opacity:0; + background:rgba(255, 0, 0, .29); + color:#e02b2b; + padding:2px 7px; + border:1px solid rgba(226, 117, 117, .44); + font-size:14px; + white-space:pre; +} +.jodit_error_box_for_messages>.active{ + opacity:1; +} +.jodit_error_box_for_messages>.info{ + background:rgba(204, 229, 247, .71); + color:#776565; + border:1px solid hsla(0, 0%, 60.4%, .44); +} +.jodit_error_box_for_messages>.success{ + background:rgba(77, 236, 112, .29); + color:#5d5a5a; + border:1px solid hsla(0, 0%, 58%, .44); +} +.jodit_fullsize_box{ + z-index:100000 !important; + position:static !important; + overflow:visible !important; +} +body.jodit_fullsize_box,html.jodit_fullsize_box{ + height:0 !important; + width:0 !important; + overflow:initial !important; +} +html.jodit_fullsize_box{ + position:fixed !important; +} +.jodit_fullsize{ + position:absolute; + top:0; + left:0; + right:0; + bottom:0; + z-index:100000; + max-width:none !important; +} +.jodit_fullsize .toolbar{ + width:100% !important; +} +.jodit_fullsize .jodit_area,.jodit_fullsize .jodit_editor{ + height:100%; +} +.jodit_fullsize .jodit_workflow{ + height:calc(100% - 24px); + overflow:auto; +} +.jodit_fullsize.jodit_toolbar_size-small .jodit_workflow{ + height:calc(100% - 18px); +} +.jodit_fullsize.jodit_toolbar_size-large .jodit_workflow{ + height:calc(100% - 27px); +} +.jodit_placeholder{ + font-family:Helvetica,sans-serif,Arial; + font-size:14px; + -webkit-user-select:none !important; + -moz-user-select:none !important; + -ms-user-select:none !important; + user-select:none !important; + top:0; + left:0; + display:block; + position:absolute; + padding:10px; + color:rgba(0, 0, 0, .35); + z-index:1; + pointer-events:none; +} +.jodit_toolbar_popup-inline-container{ + z-index:1300; + min-width:700px; +} +.jodit_toolbar_popup-inline-target{ + position:absolute; +} +.jodit_toolbar_popup-inline-target.jodit_toolbar_popup-inline-target-hidden{ + display:none; +} +.jodit_toolbar_popup-inline{ + display:inline-block !important; + position:relative !important; +} +.jodit_toolbar_popup-inline>div{ + color:hsla(0, 0%, 88.2%, .99); + background:#fff; + box-shadow:none; + background-clip:padding-box; + font-family:Helvetica,sans-serif,Arial; + box-sizing:border-box; + -webkit-user-select:none; + -moz-user-select:none; + -ms-user-select:none; + user-select:none; + z-index:100001 !important; + text-align:left; + border:1px solid hsla(0, 0%, 88.2%, .99); + display:inline-block; + vertical-align:top; +} +.jodit_toolbar_popup-inline .jodit_toolbar{ + z-index:7; + border:0; + display:block; + white-space:nowrap; +} +.jodit_toolbar_popup-inline .jodit_toolbar_btn{ + display:-ms-inline-flexbox; + display:inline-flex; +} +.jodit_toolbar_popup-inline .jodit_toolbar_btn-break{ + display:block; + width:100%; +} +.jodit_toolbar_popup-inline>div>.jodit_toolbar{ + box-shadow:none; +} +.jodit_toolbar_popup-inline>.jodit_popup_triangle{ + position:absolute; + padding:0; + margin:0 0 0 -4px; + width:8px; + height:8px; + top:-4px; + display:inline-block; + transform:rotate(45deg); + background:#fff; + border:solid hsla(0, 0%, 88.2%, .99); + border-width:1px 0 0 1px; + z-index:6; +} +.jodit_toolbar_popup-inline.jodit_toolbar_popup-inline-top>.jodit_popup_triangle{ + top:auto; + bottom:-4px; + border-width:0 1px 1px 0; +} +.jodit_toolbar_popup-inline .buttons{ + box-shadow:0 1px 3px rgba(0, 0, 0, .12),0 1px 2px rgba(0, 0, 0, .24); + padding:0 2px; + white-space:nowrap; + line-height:0; + border-bottom:0; +} +[data-jodit_iframe_wrapper]{ + display:block; + -webkit-user-select:none; + -moz-user-select:none; + -ms-user-select:none; + user-select:none; + position:relative; +} +[data-jodit_iframe_wrapper]:after{ + position:absolute; + content:""; + z-index:1; + top:0; + left:0; + right:0; + bottom:0; + cursor:pointer; + display:block; + background:transparent; +} +.jodit_resizer{ + width:100px; + height:100px; + position:absolute; + border:1px solid rgba(3, 14, 82, .92); + top:0; + left:0; + display:none; + pointer-events:none; + font-size:0; +} +.jodit_resizer *{ + box-sizing:border-box; +} +.jodit_resizer>span{ + left:50%; + top:50%; + height:24px; + width:70px; + max-width:100%; + margin-left:-35px; + margin-top:-12px; + line-height:24px; + font-size:12px; + text-align:center; + color:#fff; + background-color:rgba(0, 0, 0, .35); + opacity:0; + transition:opacity .2s linear; + overflow:visible; +} +.jodit_resizer>i,.jodit_resizer>span{ + position:absolute; + display:inline-block; +} +.jodit_resizer>i{ + z-index:4; + pointer-events:all; + border:1px solid rgba(3, 14, 82, .92); + background-color:hsla(0, 0%, 88.2%, .99); + width:10px; + height:10px; +} +.jodit_resizer>i:hover{ + background-color:#f8f8f8; +} +.jodit_resizer>i:first-child{ + left:-5px; + top:-5px; + cursor:nw-resize; +} +.jodit_resizer>i:nth-child(2){ + right:-5px; + top:-5px; + cursor:ne-resize; +} +.jodit_resizer>i:nth-child(3){ + right:-5px; + bottom:-5px; + cursor:se-resize; +} +.jodit_resizer>i:nth-child(4){ + left:-5px; + bottom:-5px; + cursor:sw-resize; +} +@media (max-width:768px){ + .jodit_resizer>i{ + width:20px; + height:20px; + } + .jodit_resizer>i:first-child{ + left:-10px; + top:-10px; + cursor:nw-resize; + } + .jodit_resizer>i:nth-child(2){ + right:-10px; + top:-10px; + cursor:ne-resize; + } + .jodit_resizer>i:nth-child(3){ + right:-10px; + bottom:-10px; + cursor:se-resize; + } + .jodit_resizer>i:nth-child(4){ + left:-10px; + bottom:-10px; + cursor:sw-resize; + } +} +.jodit_container{ + min-height:100px; +} +.jodit_container .jodit_workplace{ + display:-ms-flexbox; + display:flex; + height:auto; + min-height:50px; + overflow:hidden; +} +.jodit_editor_resize{ + position:relative; +} +.jodit_editor_resize a{ + position:absolute; + bottom:0; + right:0; + -webkit-user-select:none; + -moz-user-select:none; + -ms-user-select:none; + user-select:none; + width:0; + height:0; + overflow:hidden; + border-color:transparent #ccc transparent transparent; + border-style:dashed solid dashed dashed; + border-width:7px 7px 0 0; + cursor:se-resize; +} +.jodit_source{ + display:none; + position:relative; + background-color:#f8f8f8; + font-size:0; + -ms-flex:1; + flex:1; + overflow:auto; +} +.jodit_source,.jodit_source .jodit_source_mirror-fake{ + min-height:100%; +} +.jodit_container.jodit_source_mode .jodit_wysiwyg,.jodit_container.jodit_source_mode .jodit_wysiwyg_iframe{ + display:none !important; +} +.jodit_container.jodit_source_mode .jodit_source{ + display:block !important; +} +.jodit_container.jodit_split_mode .jodit_source,.jodit_container.jodit_split_mode .jodit_wysiwyg,.jodit_container.jodit_split_mode .jodit_wysiwyg_iframe{ + display:block !important; + width:50%; + -ms-flex:1; + flex:1; +} +.jodit_source_mirror{ + border:0; + width:100%; + background:#3f3f3f; + margin:0; + height:100%; + box-shadow:none; + resize:none; + box-sizing:border-box; + color:#f0f0f0; + outline:none; + font-family:Menlo,Monaco,monospace,sans-serif; + font-size:13px; + line-height:1.3em; + overflow:auto; + z-index:2; + padding:10px; + white-space:pre-wrap; + -moz-tab-size:2em; + -o-tab-size:2em; + tab-size:2em; + min-height:100%; +} +.jodit_source_mirror::-moz-selection{ + background:#bdbdbd; +} +.jodit_source_mirror::selection{ + background:#bdbdbd; +} +.jodit_table_resizer{ + cursor:col-resize; + position:absolute; + z-index:3; + padding-left:5px; + padding-right:5px; + margin-left:-5px; +} +.jodit_table_resizer:after{ + content:""; + display:block; + height:100%; + width:0; + border:0; +} +.jodit_table_resizer-moved{ + background-color:#b5d6fd; + z-index:2; +} +.jodit_table_resizer-moved:after{ + border-right:1px solid #1e88e5; +} +.jodit_wysiwyg table{ + width:100%; + border:none; + border-collapse:collapse; + table-layout:fixed; + empty-cells:show; + max-width:100%; +} +.jodit_wysiwyg table tr{ + -webkit-user-select:none; + -moz-user-select:none; + -ms-user-select:none; + user-select:none; +} +.jodit_wysiwyg table tr td,.jodit_wysiwyg table tr th{ + border:1px solid #ddd; + text-align:left; + vertical-align:middle; + -webkit-user-select:text; + -moz-user-select:text; + -ms-user-select:text; + user-select:text; +} +.jodit_wysiwyg table tr td[data-jodit-selected-cell],.jodit_wysiwyg table tr th[data-jodit-selected-cell]{ + border:1px double #1e88e5; +} +.jodit_form_inserter .jodit_form-table-creator-box{ + display:-ms-flexbox; + display:flex; +} +.jodit_form_inserter .jodit_form-table-creator-box .jodit_form-container{ + padding:0; + margin:0; + min-width:180px; + font-size:0; +} +.jodit_form_inserter .jodit_form-table-creator-box .jodit_form-container>div{ + width:18px; + height:18px; + box-sizing:border-box; + display:inline-block; + position:relative; + vertical-align:top; +} +.jodit_form_inserter .jodit_form-table-creator-box .jodit_form-container>div:after{ + content:""; + position:absolute; + top:0; + left:0; + display:inline-block; + width:12px; + height:12px; + border:1px solid #ccc; +} +.jodit_form_inserter .jodit_form-table-creator-box .jodit_form-container>div.hovered:after{ + background:#7a450f; + border:1px solid #b5b5b5; +} +.jodit_form_inserter .jodit_form-table-creator-box .jodit_form-options{ + font-size:14px; + vertical-align:top; +} +.jodit_form_inserter .jodit_form-table-creator-box .jodit_form-options label{ + text-align:left; + padding-top:0; +} +.jodit_form_inserter .jodit_form-table-creator-box .jodit_form-options label input{ + margin-right:10px; +} +.jodit_form_inserter label{ + text-align:center; + font-size:14px; + padding:8px; + margin:0; +} +.jodit_text_icons .jodit_icon{ + width:auto; + font-size:14px; +} +.jodit_text_icons .jodit_icon:first-letter{ + text-transform:uppercase; +} +.jodit_text_icons .jodit_tabs .jodit_tabs_buttons>a{ + width:auto; + font-family:Helvetica,sans-serif,Arial; +} +.jodit_text_icons .jodit_tabs .jodit_tabs_buttons>a i,.jodit_text_icons .jodit_toolbar>li{ + width:auto; +} +.jodit_text_icons .jodit_toolbar>li>a{ + text-decoration:none; + line-height:1; +} +.jodit_text_icons.jodit_dialog_box .jodit_dialog .jodit_button,.jodit_text_icons.jodit_dialog_box .jodit_dialog .jodit_dialog_header a,.jodit_text_icons .jodit_toolbar>li>a{ + padding:0 12px; + font-family:Helvetica,sans-serif,Arial; + width:auto; + color:rgba(0, 0, 0, .75); +} +.jodit_text_icons.jodit_dialog_box .jodit_dialog .jodit_button .jodit_icon,.jodit_text_icons.jodit_dialog_box .jodit_dialog .jodit_dialog_header a .jodit_icon{ + width:auto; +} +.jodit_widget,.jodit_widget *{ + box-sizing:border-box; +} +.jodit_search{ + font-family:Helvetica,sans-serif,Arial; + font-size:14px; + visibility:hidden; + position:absolute; + top:0; + right:0; + width:0; + height:0; +} +.jodit_search.jodit_search-active{ + visibility:visible; +} +.jodit_search .jodit_search_box{ + width:320px; + position:absolute; + right:0; + background-color:#f9f9f9; + border:solid #ccc; + border-width:0 0 1px 1px; + padding:5px; +} +.jodit_search .jodit_search_box input{ + margin:0; + width:100%; + height:100%; + border:0; + background-color:transparent; + outline:none; + padding:0 10px; +} +.jodit_search .jodit_search_box input.jodit_search-replace{ + display:none; +} +.jodit_search .jodit_search_box .jodit_search_buttons,.jodit_search .jodit_search_box .jodit_search_counts,.jodit_search .jodit_search_box .jodit_search_inputs{ + height:30px; + display:inline-block; + vertical-align:top; +} +.jodit_search .jodit_search_box .jodit_search_inputs{ + width:60%; + padding-right:5px; +} +.jodit_search .jodit_search_box .jodit_search_counts{ + width:15%; + line-height:100%; + text-align:center; + color:#ccc; + border-left:1px solid #ccc; +} +.jodit_search .jodit_search_box .jodit_search_counts:before{ + content:""; + display:inline-block; + vertical-align:middle; + height:100%; +} +.jodit_search .jodit_search_box .jodit_search_counts span{ + display:inline-block; + vertical-align:middle; +} +.jodit_search .jodit_search_box .jodit_search_buttons{ + padding-left:0; + width:25%; +} +.jodit_search .jodit_search_box .jodit_search_buttons button{ + outline:0; + width:32%; + padding:1px 5px; + margin-right:1%; + transition:transform .1s linear; + height:100%; + border:1px solid transparent; + background-color:transparent; +} +.jodit_search .jodit_search_box .jodit_search_buttons button.jodit_search_buttons-replace{ + width:100%; + border:1px solid #ccc; + margin-top:2px; + display:none; +} +.jodit_search .jodit_search_box .jodit_search_buttons button:hover{ + background-color:#ecebe9; +} +.jodit_search .jodit_search_box .jodit_search_buttons button:focus{ + border:1px solid rgba(181, 214, 253, .5); +} +.jodit_search .jodit_search_box .jodit_search_buttons button:active{ + border:1px solid #b5d6fd; + transform:scale(.95); +} +.jodit_search.jodit_search-and-replace .jodit_search_counts,.jodit_search.jodit_search-and-replace .jodit_search_inputs{ + height:60px; +} +.jodit_search.jodit_search-and-replace .jodit_search_counts input,.jodit_search.jodit_search-and-replace .jodit_search_inputs input{ + height:50%; + transition:background-color .1s linear; +} +.jodit_search.jodit_search-and-replace .jodit_search_counts input:focus,.jodit_search.jodit_search-and-replace .jodit_search_inputs input:focus{ + box-shadow:inset 0 0 3px 0 hsla(0, 0%, 80%, .58); +} +.jodit_search.jodit_search-and-replace .jodit_search_buttons button.jodit_search_buttons-replace,.jodit_search.jodit_search-and-replace .jodit_search_inputs input.jodit_search-replace{ + display:block; +} +@media (max-width:320px){ + .jodit_search,.jodit_search .jodit_search_box{ + width:100%; + } +} +.jodit_symbols{ + width:460px; + padding:10px; +} +.jodit_symbols .jodit_symbols-container_preview,.jodit_symbols .jodit_symbols-container_table{ + display:inline-block; + vertical-align:top; +} +.jodit_symbols .jodit_symbols-container_table{ + width:88%; +} +.jodit_symbols .jodit_symbols-container_preview{ + width:12%; +} +.jodit_symbols .jodit_symbols-container_preview .jodit_symbols-preview{ + font-size:34px; + text-align:center; + padding:20px 0; + border:1px solid #ccc; +} +.jodit_symbols table{ + border:0; + border-spacing:0; + table-layout:fixed; +} +.jodit_symbols table td{ + padding:0; +} +.jodit_symbols table td a{ + font-size:16px; + text-decoration:none; + color:#000; + display:inline-block; + box-sizing:border-box; + width:21.6px; + height:21.6px; + border:1px solid transparent; + text-align:center; + line-height:21.6px; + vertical-align:top; +} +.jodit_symbols table td a:focus,.jodit_symbols table td a:hover{ + border:1px solid #1e88e5; +} +.jodit_sticky-dummy_toolbar{ + display:none; +} +.jodit_sticky>.jodit_toolbar_container{ + position:fixed; + position:-webkit-sticky; + position:sticky; + z-index:3; + top:0; + left:auto; +} +.jodit_sticky .jodit_sticky-dummy_toolbar{ + display:block; +} +.jodit_paste_storage{ + padding:10px; + max-width:600px; +} +@media (max-width:768px){ + .jodit_paste_storage{ + max-width:100%; + } +} +.jodit_paste_storage>div{ + max-width:100%; + max-height:300px; + border:1px solid #ccc; +} +.jodit_paste_storage>div:first-child{ + margin-bottom:10px; +} +.jodit_paste_storage>div:first-child a{ + outline:none; + box-sizing:border-box; + display:block; + max-width:100%; + white-space:pre; + overflow:hidden; + text-overflow:ellipsis; + padding:5px; + margin:0; + border:1px solid transparent; + text-decoration:none; + color:#000; +} +.jodit_paste_storage>div:first-child a.jodit_active{ + color:#fff; + background-color:#575757; +} +.jodit_paste_storage>div:first-child a:focus{ + outline:none; +} +.jodit_paste_storage>div:last-child{ + padding:10px; + overflow:auto; +} +.jodit_paste_storage>div:last-child li,.jodit_paste_storage>div:last-child ul{ + margin:0; +} +.jodit,.jodit *,.jodit_container,.jodit_container *{ + box-sizing:border-box; +} +.jodit .jodit_workplace,.jodit_container .jodit_workplace{ + position:relative; + overflow:auto; +} +.jodit .jodit_workplace .jodit_wysiwyg,.jodit .jodit_workplace .jodit_wysiwyg_iframe,.jodit_container .jodit_workplace .jodit_wysiwyg,.jodit_container .jodit_workplace .jodit_wysiwyg_iframe{ + height:100%; + width:100%; +} +.jodit_container:not(.jodit_inline){ + font-family:Helvetica,sans-serif,Arial; + font-size:14px; + background:#fff; +} +.jodit_container:not(.jodit_inline).jodit_disabled{ + background:hsla(0, 0%, 88.2%, .99); +} +.jodit_container:not(.jodit_inline).jodit_disabled .jodit_workplace{ + opacity:.4; +} +.jodit_container:not(.jodit_inline) .jodit_workplace{ + border:1px solid #ccc; +} +.jodit_disabled{ + -webkit-user-select:none !important; + -moz-user-select:none !important; + -ms-user-select:none !important; + user-select:none !important; +} +.jodit_hidden{ + display:none !important; +} +.jodit_vertical_middle{ + display:-ms-flexbox; + display:flex; + -ms-flex-align:center; + align-items:center; +} +.jodit_button,.jodit_status_default{ + background-color:#d8d8d8; + color:#212529; +} +.jodit_button svg,.jodit_status_default svg{ + fill:#212529; + stroke:#212529; +} +.jodit_button:hover,.jodit_status_default:hover{ + background-color:#c9cdd1; + color:#212529; +} +.jodit_button:hover svg,.jodit_status_default:hover svg{ + fill:#212529; + stroke:#212529; +} +.jodit_button:active,.jodit_status_default:active{ + background-color:#dae0e5; + color:#212529; +} +.jodit_button:active svg,.jodit_status_default:active svg{ + fill:#212529; + stroke:#212529; +} +.jodit_button_primary,.jodit_status_primary{ + background-color:#007bff; + color:#fff; +} +.jodit_button_primary svg,.jodit_status_primary svg{ + fill:#fff; + stroke:#fff; +} +.jodit_button_primary:hover,.jodit_status_primary:hover{ + background-color:#0069d9; + color:#fff; +} +.jodit_button_primary:hover svg,.jodit_status_primary:hover svg{ + fill:#fff; + stroke:#fff; +} +.jodit_button_primary:active,.jodit_status_primary:active{ + background-color:#0062cc; + color:#fff; +} +.jodit_button_primary:active svg,.jodit_status_primary:active svg{ + fill:#fff; + stroke:#fff; +} +.jodit_button_success,.jodit_status_success{ + background-color:#28a745; + color:#fff; +} +.jodit_button_success svg,.jodit_status_success svg{ + fill:#fff; + stroke:#fff; +} +.jodit_button_success:hover,.jodit_status_success:hover{ + background-color:#218838; + color:#fff; +} +.jodit_button_success:hover svg,.jodit_status_success:hover svg{ + fill:#fff; + stroke:#fff; +} +.jodit_button_success:active,.jodit_status_success:active{ + background-color:#1e7e34; + color:#fff; +} +.jodit_button_success:active svg,.jodit_status_success:active svg{ + fill:#fff; + stroke:#fff; +} +.jodit_button_danger,.jodit_status_danger{ + background-color:#dc3545; + color:#fff; +} +.jodit_button_danger svg,.jodit_status_danger svg{ + fill:#fff; + stroke:#fff; +} +.jodit_button_danger:hover,.jodit_status_danger:hover{ + background-color:#c82333; + color:#fff; +} +.jodit_button_danger:hover svg,.jodit_status_danger:hover svg{ + fill:#fff; + stroke:#fff; +} +.jodit_button_danger:active,.jodit_status_danger:active{ + background-color:#bd2130; + color:#fff; +} +.jodit_button_danger:active svg,.jodit_status_danger:active svg{ + fill:#fff; + stroke:#fff; +} +.jodit_dark_theme.jodit_container,.jodit_dark_theme.jodit_container.jodit_disabled,.jodit_dark_theme .jodit_toolbar_list>.jodit_toolbar{ + background-color:#575757; +} +.jodit_dark_theme .jodit_statusbar,.jodit_dark_theme .jodit_workplace{ + border-color:rgba(87, 87, 87, .8); +} +.jodit_dark_theme .jodit_statusbar{ + background-color:rgba(95, 92, 92, .8); +} +.jodit_dark_theme .jodit_statusbar,.jodit_dark_theme .jodit_statusbar .jodit_statusbar_item span{ + color:#d1cccc; +} +.jodit_dark_theme .jodit_toolbar_popup,.jodit_dark_theme .jodit_toolbar_popup-inline,.jodit_dark_theme .jodit_toolbar_popup-inline:before,.jodit_dark_theme .jodit_toolbar_popup:before{ + background:#575757; +} +.jodit_dark_theme .jodit_toolbar{ + background:#5f5c5c; + border-color:rgba(87, 87, 87, .8); +} +.jodit_dark_theme .jodit_toolbar li.jodit_toolbar_btn>a{ + color:#d1cccc; +} +.jodit_dark_theme .jodit_toolbar li.jodit_toolbar_btn>a:hover{ + background-color:#575757; +} +.jodit_dark_theme .jodit_toolbar li.jodit_toolbar_btn.jodit_toolbar_btn-break{ + border-top-color:#686767; +} +.jodit_dark_theme .jodit_toolbar li.jodit_toolbar_btn.jodit_toolbar_btn-separator{ + border-right-color:#686767; +} +.jodit_dark_theme .jodit_toolbar li.jodit_toolbar_btn.active,.jodit_dark_theme .jodit_toolbar li.jodit_toolbar_btn.jodit_active,.jodit_dark_theme .jodit_toolbar li.jodit_toolbar_btn:active,.jodit_dark_theme .jodit_toolbar li.jodit_toolbar_btn:hover{ + background-color:#575757; +} +.jodit_dark_theme .jodit_icon,.jodit_dark_theme .jodit_toolbar li.jodit_toolbar_btn.jodit_with_dropdownlist .jodit_with_dropdownlist-trigger{ + fill:silver; +} +.jodit_dark_theme .jodit_wysiwyg,.jodit_dark_theme .jodit_wysiwyg_iframe{ + background-color:#575757; + color:#d1cccc; +} +.jodit_dark_theme .jodit_wysiwyg [data-jodit-selected-cell],.jodit_dark_theme .jodit_wysiwyg_iframe [data-jodit-selected-cell]{ + border-color:#152f5f; +} +.jodit_dark_theme .jodit_dropdownlist{ + background:#5f5c5c; +} +.jodit_dark_theme .jodit_tabs .jodit_tabs_buttons>a{ + background-color:#686767; + color:#d1cccc; +} +.jodit_dark_theme .jodit_tabs .jodit_tabs_buttons>a:hover{ + background-color:rgba(104, 103, 103, .8); + color:#d1cccc; + border-color:rgba(104, 103, 103, .9); +} +.jodit_dark_theme .jodit_tabs .jodit_tabs_buttons>a.active{ + background:rgba(81, 81, 81, .41); + border-color:#686767; +} +.jodit_dark_theme .jodit_tabs .jodit_tabs_buttons>a svg{ + fill:silver; +} +.jodit_dark_theme .jodit_form input[type=text],.jodit_dark_theme .jodit_form input[type=url],.jodit_dark_theme .jodit_form textarea{ + background-color:rgba(81, 81, 81, .41); + border-color:#686767; + color:#d1cccc; +} +.jodit_dark_theme .jodit_form button{ + background-color:rgba(104, 103, 103, .75); + color:#d1cccc; +} +.jodit_dark_theme .jodit_placeholder{ + color:hsla(0, 5.2%, 81%, .8); +} +.jodit_dark_theme .jodit_draganddrop_file_box,.jodit_dark_theme .jodit_uploadfile_button{ + color:#d1cccc; +} +.jodit_dark_theme .jodit_draganddrop_file_box:hover,.jodit_dark_theme .jodit_uploadfile_button:hover{ + background-color:rgba(104, 103, 103, .75); +} +.jodit_dark_theme .jodit-add-new-line:before{ + border-top-color:#686767; +} +.jodit_dark_theme .jodit-add-new-line span{ + background:rgba(104, 103, 103, .75); + border-color:#686767; +} +.jodit_dark_theme .jodit-add-new-line span svg{ + fill:#d1cccc; +} +.jodit_dark_theme .jodit_resizer>i{ + background:rgba(104, 103, 103, .75); + border-color:silver; +} + diff --git a/build/jodit.es2018.css b/build/jodit.es2018.css new file mode 100644 index 000000000..a7159039e --- /dev/null +++ b/build/jodit.es2018.css @@ -0,0 +1,2931 @@ +/*! + jodit - Jodit is awesome and usefully wysiwyg editor with filebrowser + Author: Chupurnov (https://xdsoft.net/) + Version: v3.3.8 + Url: https://xdsoft.net/jodit/ + License(s): GPL-2.0-or-later OR MIT OR Commercial +*/ + +.jodit_wysiwyg{ + outline:0; +} +.jodit_wysiwyg::-moz-selection,.jodit_wysiwyg ::-moz-selection{ + background:#b5d6fd; + color:#000; +} +.jodit_wysiwyg::selection,.jodit_wysiwyg ::selection{ + background:#b5d6fd; + color:#000; +} +.jodit_container:not(.jodit_inline) .jodit_wysiwyg{ + margin:0; + padding:10px; + outline:0; + overflow-x:auto; + position:relative; +} +.jodit_container:not(.jodit_inline) .jodit_wysiwyg img{ + position:relative; + max-width:100%; +} +.jodit_container:not(.jodit_inline) .jodit_wysiwyg p,.jodit_container:not(.jodit_inline) .jodit_wysiwyg pre{ + margin:0 0 10px; +} +.jodit_container:not(.jodit_inline) .jodit_wysiwyg h1,.jodit_container:not(.jodit_inline) .jodit_wysiwyg h2,.jodit_container:not(.jodit_inline) .jodit_wysiwyg h3,.jodit_container:not(.jodit_inline) .jodit_wysiwyg h4,.jodit_container:not(.jodit_inline) .jodit_wysiwyg h5{ + margin-top:0; +} +.jodit_container:not(.jodit_inline) .jodit_wysiwyg blockquote{ + border-left:2px solid #222; + margin-left:0; + padding-left:5px; + color:#222; +} +.jodit_container:not(.jodit_inline) .jodit_wysiwyg jodit-media{ + position:relative; +} +.jodit_container:not(.jodit_inline) .jodit_wysiwyg jodit-media *{ + position:relative; + z-index:0; +} +.jodit_container:not(.jodit_inline) .jodit_wysiwyg jodit-media:before{ + z-index:1; + content:""; + position:absolute; + top:0; + left:0; + right:0; + bottom:0; +} +.jodit_form{ + font-family:Helvetica,sans-serif,Arial; + font-size:14px; + color:#000; +} +.jodit_form.jodit_error{ + border-color:#f7d1d1; + box-shadow:inset 0 0 3px 0 hsla(0, 0%, 74.1%, .3); +} +@media (max-width:768px){ + .jodit_form{ + min-width:150px; + } +} +.jodit_form button{ + height:36px; + line-height:1; + color:#000; + padding:10px; + cursor:pointer; + text-decoration:none; + border:none; + background:#d6d6d6; + font-size:16px; + outline:none; + transition:background .2s ease 0s; + margin-top:10px; + margin-bottom:10px; +} +.jodit_form button:hover{ + background-color:#ecebe9; + color:#000; +} +.jodit_form button:active{ + background:#ecebe9; + color:#000; +} +.jodit_form label{ + margin-top:10px; + text-align:left; + white-space:nowrap; + display:-ms-flexbox; + display:flex; + -ms-flex-align:center; + align-items:center; +} +.jodit_form .jodit_form_center{ + -ms-flex-pack:center; + justify-content:center; +} +.jodit_input,.jodit_select,.jodit_textarea{ + font-family:Helvetica,sans-serif,Arial; + font-size:14px; + width:100%; + -webkit-appearance:none; + -moz-appearance:none; + appearance:none; + height:32px; + border-radius:0; + outline:none; + line-height:100%; + border:1px solid #ccc; + padding:5px 10px; + background-color:#fff; +} +.jodit_input[disabled],.jodit_select[disabled],.jodit_textarea[disabled]{ + background-color:#f0f0f0; + color:#ccc; +} +.jodit_input:focus{ + border-color:#66afe9; + outline:0; +} +.jodit_checkbox{ + z-index:2; + border:0; + cursor:pointer; + height:16px; + padding:0; + margin:0 4px; + width:16px; + position:relative; + outline:none; +} +.jodit_checkbox:checked:after{ + background:url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Cpath d='M27 4L12 19l-7-7-5 5 12 12L32 9z' fill='%23FFF'/%3E%3C/svg%3E") no-repeat 50% #b5b5b5; + border-color:#b5b5b5; +} +.jodit_select{ + padding-right:20px; + background-image:url(data:image/svg+xml;base64,PHN2ZyBpZD0iTGF5ZXJfMSIgZGF0YS1uYW1lPSJMYXllciAxIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCA0Ljk1IDEwIj48ZGVmcz48c3R5bGU+LmNscy0ye2ZpbGw6IzQ0NH08L3N0eWxlPjwvZGVmcz48cGF0aCBmaWxsPSIjZmZmIiBkPSJNMCAwaDQuOTV2MTBIMHoiLz48cGF0aCBjbGFzcz0iY2xzLTIiIGQ9Ik0xLjQxIDQuNjdsMS4wNy0xLjQ5IDEuMDYgMS40OUgxLjQxek0zLjU0IDUuMzNMMi40OCA2LjgyIDEuNDEgNS4zM2gyLjEzeiIvPjwvc3ZnPg==); + background-repeat:no-repeat; + background-position:98% 50%; +} +.jodit_textarea{ + height:auto; + min-width:180px; +} +.jodit_form_group{ + display:-ms-flexbox; + display:flex; + -ms-flex-direction:column; + flex-direction:column; + margin-bottom:10px; + min-width:180px; +} +.jodit_button{ + position:relative; + display:-ms-inline-flexbox; + display:inline-flex; + -ms-flex-align:center; + align-items:center; + -ms-flex-pack:center; + justify-content:center; + -webkit-user-select:none; + -moz-user-select:none; + -ms-user-select:none; + user-select:none; + width:auto; + padding:0 10px; + height:40px; + line-height:1; + margin:0; + background-color:hsla(0, 0%, 88.2%, .99); + color:#000; + cursor:pointer; + border:0; + border-radius:.25rem; + text-decoration:none; +} +.jodit_button svg{ + display:inline-block; + width:24px; + height:24px; +} +.jodit_button svg+span{ + margin-left:5px; +} +.jodit_button:active,.jodit_button:focus{ + outline:0; +} +.jodit_button.disabled{ + opacity:.7; +} +.jodit_button .jodit_icon,.jodit_button svg,.jodit_dialog_header .jodit_icon,.jodit_dialog_header svg{ + width:16px; + height:16px; + display:inline-block; + vertical-align:middle; +} +.jodit_button_group{ + display:-ms-flexbox; + display:flex; +} +.jodit_button_group input{ + display:none; +} +.jodit_button_group button{ + display:-ms-flexbox; + display:flex; + -ms-flex:1; + flex:1; + -ms-flex-pack:center; + justify-content:center; + text-align:center; +} +.jodit_button_group button+button{ + margin-left:-1px; +} +.jodit_button_group button:first-child,.jodit_button_group input:first-child+button{ + border-right:0; + border-top-right-radius:0; + border-bottom-right-radius:0; +} +.jodit_button_group button:last-child,.jodit_button_group input:last-child+button{ + border-left:0; + border-top-left-radius:0; + border-bottom-left-radius:0; +} +.jodit_button_group input[type=checkbox]:checked+button,.jodit_button_group input[type=checkbox]:not(:checked)+button+button{ + background-image:none; + box-shadow:inset 0 2px 4px rgba(0, 0, 0, .15),0 1px 2px rgba(0, 0, 0, .05); +} +.jodit_context_menu{ + font-family:Helvetica,sans-serif,Arial; + font-size:14px; + position:absolute; + z-index:2222224; + display:none; + min-width:150px; + background:#fff; + box-shadow:0 0 5px 0 rgba(0, 0, 0, .24); +} +.jodit_context_menu a{ + display:-ms-flexbox; + display:flex; + -ms-flex-align:center; + align-items:center; + height:38px; + text-decoration:none !important; + border-bottom:1px solid hsla(0, 0%, 80%, .24); + color:#727272; +} +.jodit_context_menu a svg{ + display:block; + width:18px; + height:38px; + margin:0 10px; + fill:#727272; +} +.jodit_context_menu a span{ + display:-ms-flexbox; + display:flex; + -ms-flex-align:center; + align-items:center; + padding:10px; + height:38px; + border-left:1px solid hsla(0, 0%, 80%, .24); + box-sizing:border-box; +} +.jodit_context_menu a:hover{ + background-color:#e3e3e3; + color:#000; +} +.jodit_context_menu a:hover .jodit_icon{ + fill:#000; +} +.jodit_context_menu a:last-child{ + border:0; +} +.jodit_context_menu-show{ + display:block; +} +.jodit_dialog_box{ + font-family:Helvetica,sans-serif,Arial; + font-size:14px; + box-sizing:border-box; + position:absolute; + display:none; + width:0; + height:0; + border:0; + will-change:left, top, width, height; +} +.jodit_dialog_box.jodit_dialog_box-moved{ + -webkit-user-select:none; + -moz-user-select:none; + -ms-user-select:none; + user-select:none; +} +.jodit_dialog_box *{ + box-sizing:border-box; +} +.jodit_dialog_box .jodit_elfinder,.jodit_dialog_box .jodit_elfinder *{ + box-sizing:initial; +} +.jodit_dialog_box .jodit_dialog_overlay{ + position:fixed; + top:0; + left:0; + width:100%; + height:100%; + z-index:2222222; + text-align:center; + white-space:nowrap; + overflow:auto; + display:none; + background-color:rgba(0, 0, 0, .5); +} +.jodit_dialog_box.active,.jodit_dialog_box.jodit_modal .jodit_dialog_overlay{ + display:block; +} +.jodit_dialog_box .jodit_dialog{ + z-index:2222223; + display:inline-block; + vertical-align:middle; + white-space:normal; + text-align:left; + position:fixed; + left:0; + top:0; + background-color:#fff; + box-shadow:0 10px 20px rgba(0, 0, 0, .19),0 6px 6px rgba(0, 0, 0, .23); + min-width:200px; + min-height:100px; +} +@media (max-width:480px){ + .jodit_dialog_box .jodit_dialog{ + max-width:100%; + width:100% !important; + height:100% !important; + top:0 !important; + left:0 !important; + } +} +.jodit_dialog_box .jodit_dialog .jodit_promt{ + max-width:300px; + min-width:200px; + padding:10px; + word-break:break-all; +} +.jodit_dialog_box .jodit_dialog .jodit_promt label{ + margin-bottom:5px; + display:block; +} +.jodit_dialog_box .jodit_dialog .jodit_alert{ + max-width:300px; + min-width:200px; + padding:10px; + word-break:break-all; +} +.jodit_dialog_box .jodit_dialog .jodit_dialog_header{ + display:-ms-flexbox; + display:flex; + -ms-flex-pack:justify; + justify-content:space-between; + text-align:left; + color:#222; + box-shadow:0 1px 3px rgba(0, 0, 0, .16),0 1px 2px rgba(0, 0, 0, .23); + cursor:move; + height:48px; + overflow:hidden; +} +.jodit_dialog_box .jodit_dialog .jodit_dialog_header .jodit_dialog_header-title,.jodit_dialog_box .jodit_dialog .jodit_dialog_header .jodit_dialog_header-toolbar{ + display:-ms-flexbox; + display:flex; + -ms-flex-align:center; + align-items:center; + -ms-flex-negative:3; + flex-shrink:3; + font-size:18px; + margin:0; + font-weight:400; + line-height:48px; + vertical-align:top; + padding:0 10px; +} +@media (max-width:480px){ + .jodit_dialog_box .jodit_dialog .jodit_dialog_header .jodit_dialog_header-title,.jodit_dialog_box .jodit_dialog .jodit_dialog_header .jodit_dialog_header-toolbar{ + padding-left:0; + } +} +.jodit_dialog_box .jodit_dialog .jodit_dialog_header .jodit_button{ + margin-left:10px; +} +.jodit_dialog_box .jodit_dialog .jodit_dialog_header .jodit_dialog_header-button{ + color:#222; + font-size:28px; + transition:background-color .2s ease 0s; + -ms-flex-preferred-size:48px; + flex-basis:48px; + height:48px; + line-height:48px; + text-decoration:none; + text-align:center; +} +.jodit_dialog_box .jodit_dialog .jodit_dialog_header .jodit_dialog_header-button:hover{ + background-color:#ecebe9; +} +.jodit_dialog_box .jodit_dialog .jodit_dialog_header .jodit_toolbar{ + background:transparent; + border:0; + box-shadow:none; +} +.jodit_dialog_box .jodit_dialog .jodit_dialog_header .jodit_toolbar>li.jodit_toolbar_btn .jodit_input{ + padding-left:10px; + width:auto; +} +.jodit_dialog_box .jodit_dialog .jodit_dialog_content{ + height:calc(100% - 48px); + overflow:auto; +} +.jodit_dialog_box .jodit_dialog .jodit_dialog_content .jodit_form_group{ + margin-bottom:10px; + padding:0 10px; +} +.jodit_dialog_box .jodit_dialog .jodit_dialog_content .jodit_form_group:first-child{ + margin-top:10px; +} +.jodit_dialog_box .jodit_dialog .jodit_dialog_content .jodit_form_group label{ + display:inline-block; + max-width:100%; + margin-bottom:5px; + font-weight:700; +} +.jodit_dialog_box .jodit_dialog .jodit_dialog_content .jodit_form_group .jodit_input_group{ + display:table; + border-collapse:separate; + width:100%; +} +.jodit_dialog_box .jodit_dialog .jodit_dialog_content .jodit_form_group .jodit_input_group>*{ + vertical-align:middle; + display:table-cell; + height:34px; +} +.jodit_dialog_box .jodit_dialog .jodit_dialog_content .jodit_form_group .jodit_input_group>input{ + margin:0 !important; +} +.jodit_dialog_box .jodit_dialog .jodit_dialog_content .jodit_form_group .jodit_input_group>input:not([class*=col-]){ + width:100%; +} +.jodit_dialog_box .jodit_dialog .jodit_dialog_content .jodit_form_group .jodit_input_group-buttons{ + width:1%; + font-size:0; + white-space:nowrap; + vertical-align:middle; +} +.jodit_dialog_box .jodit_dialog .jodit_dialog_content .jodit_form_group .jodit_input_group-buttons>.jodit_button{ + border:1px solid #ccc; + margin-left:-1px; + height:34px; + line-height:34px; + border-radius:0; +} +.jodit_dialog_box .jodit_dialog .jodit_dialog_footer{ + padding:10px; + display:none; +} +.jodit_dialog_box .jodit_dialog.with_footer .jodit_dialog_content{ + height:calc(100% - 96px); +} +.jodit_dialog_box .jodit_dialog.with_footer .jodit_dialog_footer{ + display:-ms-flexbox; + display:flex; + -ms-flex-pack:justify; + justify-content:space-between; + -ms-flex-wrap:nowrap; + flex-wrap:nowrap; +} +.jodit_dialog_box .jodit_dialog.with_footer .jodit_dialog_footer .jodit_button{ + margin-right:10px; +} +.jodit_dialog_box .jodit_dialog.with_footer .jodit_dialog_footer .jodit_button:last-child{ + margin-right:0; +} +.jodit_dialog_box .jodit_dialog .jodit_dialog_resizer{ + position:absolute; + bottom:0; + right:0; + cursor:se-resize; + width:7px; + height:7px; + display:inline-block; + background-image:url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAcAAAAHCAYAAADEUlfTAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAADFJREFUeNpilJGRYcACIoB4ORMuCSCOZMIlga4TRQJZJ4YETCdWCSBmZMIlATIOIMAAEyAPt4RnNx0AAAAASUVORK5CYII="); +} +.jodit_dialog_box .jodit_dialog .jodit_dialog_resizer:hover{ + border-color:rgba(0, 0, 0, .6); +} +@media (max-width:480px){ + .jodit_dialog_box .jodit_dialog .jodit_dialog_resizer{ + display:none; + } +} +.jodit_dialog_box.jodit_fullsize .jodit_dialog{ + top:0 !important; + bottom:0 !important; + left:0 !important; + right:0 !important; + width:100% !important; + height:100% !important; +} +.jodit_dialog_box.jodit_fullsize .jodit_dialog .jodit_dialog_resizer{ + display:none; +} +@media (max-width:768px){ + .jodit_dialog_header .jodit_input,.jodit_dialog_header .jodit_toolbar_btn-filter,.jodit_dialog_header .jodit_toolbar_btn-separator,.jodit_dialog_header .jodit_toolbar_btn-sort,.jodit_dialog_header_fullsize,.jodit_dialog_header_title{ + display:none !important; + } +} +.jodit_toolbar_list>.jodit_toolbar{ + max-height:400px; + overflow:auto; + box-shadow:0 3px 6px rgba(0, 0, 0, .16),0 3px 6px rgba(0, 0, 0, .23); + padding:0; + margin:auto; + text-align:left; + box-sizing:border-box; + transition:max-height .2s ease 0s; + margin-top:0 !important; + list-style-type:none; + font-size:16px; + z-index:10000; + position:absolute; + left:0; + top:100%; +} +.jodit_toolbar_list>.jodit_toolbar,.jodit_toolbar_list>.jodit_toolbar .jodit_toolbar{ + background:#f9f9f9; +} +.jodit_toolbar_list>.jodit_toolbar blockquote,.jodit_toolbar_list>.jodit_toolbar h1,.jodit_toolbar_list>.jodit_toolbar h2,.jodit_toolbar_list>.jodit_toolbar h3,.jodit_toolbar_list>.jodit_toolbar h4,.jodit_toolbar_list>.jodit_toolbar h5,.jodit_toolbar_list>.jodit_toolbar p,.jodit_toolbar_list>.jodit_toolbar pre{ + font-family:Helvetica,sans-serif,Arial; + margin:0; + padding:0; + font-weight:400; +} +.jodit_toolbar_list>.jodit_toolbar h5{ + font-size:.8em; + line-height:1.4; +} +.jodit_toolbar_list>.jodit_toolbar h3{ + font-size:1.31em; + line-height:1.4; +} +.jodit_toolbar_list>.jodit_toolbar h4,.jodit_toolbar_list>.jodit_toolbar p{ + font-size:1em; + line-height:1.5em; +} +.jodit_toolbar_list>.jodit_toolbar h2{ + font-size:1.74em; + line-height:1.4; +} +.jodit_toolbar_list>.jodit_toolbar h1{ + font-size:2.17em; + line-height:1.4; +} +.jodit_toolbar_list>.jodit_toolbar blockquote,.jodit_toolbar_list>.jodit_toolbar pre{ + font-family:monospace; +} +.jodit_toolbar_list>.jodit_toolbar li.jodit_toolbar_btn{ + display:block; + cursor:pointer; + white-space:nowrap; + color:inherit; + text-decoration:none; + width:100%; + height:auto; + box-sizing:border-box; + text-align:left; +} +.jodit_toolbar_list>.jodit_toolbar li.jodit_toolbar_btn>a{ + background-image:none; + padding:7px 24px; + cursor:pointer; + line-height:100%; + width:auto; + height:auto; + display:block; +} +.jodit_toolbar_list>.jodit_toolbar li.jodit_toolbar_btn>a>span{ + display:inline-block; +} +.jodit_toolbar_list>.jodit_toolbar li.jodit_toolbar_btn>a:hover{ + background-color:#f3f0f0; +} +.jodit_toolbar_list>.jodit_toolbar li.jodit_toolbar_btn>a:after{ + display:none; +} +.jodit_toolbar[dir=rtl] .jodit_toolbar_list>.jodit_toolbar,.jodit_toolbar[dir=rtl] .jodit_toolbar_list>.jodit_toolbar li.jodit_toolbar_btn{ + text-align:right; +} +.jodit_filebrowser{ + font-family:Helvetica,sans-serif,Arial; + height:100%; + display:-ms-flexbox; + display:flex; +} +.jodit_filebrowser_no_files{ + padding:10px; +} +@media (max-width:480px){ + .jodit_filebrowser{ + -ms-flex-direction:column; + flex-direction:column; + -ms-flex-flow:column-reverse; + flex-flow:column-reverse; + } +} +.jodit_filebrowser_loader{ + height:100%; + width:100%; + position:absolute; + top:0; + left:0; +} +.jodit_filebrowser_loader i{ + position:absolute; + top:50%; + left:50%; + margin-top:-24px; + margin-left:-24px; + font-style:normal; + opacity:.7; +} +.jodit_filebrowser_status{ + position:absolute; + font-size:12px; + padding:6px; + text-align:right; + border-top:1px solid hsla(0, 0%, 49.8%, .4); + left:0; + right:0; + bottom:0; + background-color:#4a4a4a; + visibility:hidden; + opacity:0; + transition:opacity .3s linear; + color:#b38888; + word-break:break-all; +} +.jodit_filebrowser_status.success{ + color:#c5c5c5; +} +.jodit_filebrowser_status.active{ + visibility:visible; + opacity:1; +} +.jodit_filebrowser_files,.jodit_filebrowser_tree{ + display:none; + vertical-align:top; + height:100%; + position:relative; +} +.jodit_filebrowser_files .jodit_button,.jodit_filebrowser_tree .jodit_button{ + border-radius:0; +} +.jodit_filebrowser_files.active,.jodit_filebrowser_tree.active{ + display:-ms-flexbox; + display:flex; +} +.jodit_filebrowser_files::-webkit-scrollbar,.jodit_filebrowser_tree::-webkit-scrollbar{ + width:5px; +} +.jodit_filebrowser_files::-webkit-scrollbar-track,.jodit_filebrowser_tree::-webkit-scrollbar-track{ + -webkit-box-shadow:inset 0 0 6px rgba(0, 0, 0, .3); +} +.jodit_filebrowser_files::-webkit-scrollbar-thumb,.jodit_filebrowser_tree::-webkit-scrollbar-thumb{ + background-color:#a9a9a9; + outline:1px solid #708090; +} +.jodit_filebrowser_tree.active{ + -ms-flex-direction:column; + flex-direction:column; + width:31%; + min-width:200px; + max-width:290px; + z-index:2; + background-color:#3f3f3f; + overflow-y:auto; +} +@media (max-width:480px){ + .jodit_filebrowser_tree.active{ + max-width:100%; + width:auto; + height:100px; + } +} +.jodit_filebrowser_tree.active::-webkit-scrollbar{ + width:5px; +} +.jodit_filebrowser_tree.active::-webkit-scrollbar-track{ + -webkit-box-shadow:inset 0 0 6px rgba(0, 0, 0, .3); +} +.jodit_filebrowser_tree.active::-webkit-scrollbar-thumb{ + background-color:hsla(0, 0%, 49.8%, .5); + outline:1px solid #708090; +} +.jodit_filebrowser_tree.active .jodit_filebrowser_source_title{ + -webkit-user-select:none; + -moz-user-select:none; + -ms-user-select:none; + user-select:none; + display:block; + padding:10px; + color:#969696; + border-bottom:1px solid #484848; + line-height:17px; + min-height:38px; + position:relative; + word-break:break-all; + background:#5a5a5a; + font-size:16px; +} +.jodit_filebrowser_tree.active .jodit_filebrowser_tree_item{ + display:-ms-flexbox; + display:flex; + -ms-flex-pack:justify; + justify-content:space-between; + -ms-flex-align:center; + align-items:center; + min-height:38px; + padding:5px 10px; + text-decoration:none; + color:#b1b1b1; + transition:background-color .2s ease 0s; + border-bottom:1px solid #474747; + position:relative; + word-break:break-all; +} +.jodit_filebrowser_tree.active .jodit_filebrowser_tree_item_title{ + -ms-flex:1; + flex:1; +} +.jodit_filebrowser_tree.active .jodit_filebrowser_tree_item .jodit_icon_folder{ + margin-left:5px; + width:16px; + height:16px; + display:-ms-flexbox; + display:flex; + -ms-flex-pack:center; + justify-content:center; + -ms-flex-align:center; + align-items:center; + opacity:.3; +} +.jodit_filebrowser_tree.active .jodit_filebrowser_tree_item .jodit_icon_folder svg{ + width:12px; + height:12px; + stroke:#b1b1b1 !important; + fill:#b1b1b1 !important; +} +.jodit_filebrowser_tree.active .jodit_filebrowser_tree_item .jodit_icon_folder:hover{ + background:#696969; +} +.jodit_filebrowser_tree.active .jodit_filebrowser_tree_item:hover{ + color:#222; + background-color:#ecebe9; +} +.jodit_filebrowser_tree.active .jodit_filebrowser_tree_item:hover i.jodit_icon_folder{ + opacity:.6; +} +.jodit_filebrowser_files.active{ + width:100%; + overflow-y:auto; + padding:5px; + -ms-flex-wrap:wrap; + flex-wrap:wrap; + -ms-flex-line-pack:start; + align-content:flex-start; +} +.jodit_filebrowser_files.active .jodit_filebrowser_source_title{ + -webkit-user-select:none; + -moz-user-select:none; + -ms-user-select:none; + user-select:none; + margin:-10px -10px 0; + display:block; + padding:10px; + line-height:17px; + min-height:38px; + position:relative; + word-break:break-all; + background:#5a5a5a; + font-size:16px; + color:#969696; +} +.jodit_filebrowser_files.active a+.jodit_filebrowser_source_title{ + margin-top:10px; +} +.jodit_filebrowser_files.active .jodit_filebrowser_files_item{ + width:150px; + height:150px; + display:-ms-flexbox; + display:flex; + -ms-flex-pack:center; + justify-content:center; + -ms-flex-align:center; + align-items:center; + text-align:center; + border:1px solid #ccc; + margin:5px; + font-size:0; + overflow:hidden; + transition:border .1s linear,bottom .1s linear; + position:relative; +} +@media (max-width:480px){ + .jodit_filebrowser_files.active .jodit_filebrowser_files_item{ + width:calc(50% - 10px); + } +} +.jodit_filebrowser_files.active .jodit_filebrowser_files_item img{ + max-width:100%; +} +.jodit_filebrowser_files.active .jodit_filebrowser_files_item:hover{ + border-color:#433b5c; +} +.jodit_filebrowser_files.active .jodit_filebrowser_files_item-active-true{ + border-color:#1e88e5; + background-color:#b5b5b5; +} +.jodit_filebrowser_files.active .jodit_filebrowser_files_item-info{ + position:absolute; + right:0; + left:0; + bottom:0; + white-space:normal; + opacity:.85; + overflow:visible; + padding:.3em .6em; + transition:opacity .4s ease; + background-color:#e9e9e9; + color:#333; + text-shadow:#eee 0 1px 0; + font-size:14px; + line-height:16px; + text-align:left; +} +.jodit_filebrowser_files.active .jodit_filebrowser_files_item-info>span{ + display:block; + text-overflow:ellipsis; + white-space:nowrap; + overflow:hidden; + font-size:.75em; +} +.jodit_filebrowser_files.active .jodit_filebrowser_files_item-info>span.jodit_filebrowser_files_item-info-filename{ + font-weight:700; + font-size:.9em; +} +.jodit_filebrowser_files.active .jodit_filebrowser_files_item-active-true .jodit_filebrowser_files_item-info{ + background-color:#b5b5b5; + color:#fff; + text-shadow:none; +} +.jodit_filebrowser_files.active .jodit_filebrowser_files_item:hover:not(.jodit_filebrowser_files_item-active-true) .jodit_filebrowser_files_item-info{ + bottom:-100px; +} +.jodit_filebrowser_files.active.jodit_filebrowser_files_view-list{ + scroll-behavior:smooth; +} +.jodit_filebrowser_files.active.jodit_filebrowser_files_view-list a{ + display:block; + width:100%; + height:26px; + line-height:26px; + margin:0; + border-width:0 0 1px; + text-align:left; + white-space:nowrap; +} +.jodit_filebrowser_files.active.jodit_filebrowser_files_view-list a img{ + min-width:16px; + max-width:16px; + vertical-align:middle; + display:inline-block; + margin-left:4px; +} +.jodit_filebrowser_files.active.jodit_filebrowser_files_view-list a .jodit_filebrowser_files_item-info{ + padding:0; + position:static; + display:inline-block; + width:calc(100% - 20px); + margin-left:4px; + background-color:transparent; + height:100%; + line-height:inherit; + vertical-align:middle; + font-size:0; +} +.jodit_filebrowser_files.active.jodit_filebrowser_files_view-list a .jodit_filebrowser_files_item-info>span{ + display:inline-block; + height:100%; + font-size:12px; +} +.jodit_filebrowser_files.active.jodit_filebrowser_files_view-list a .jodit_filebrowser_files_item-info>span.jodit_filebrowser_files_item-info-filename{ + width:50%; +} +.jodit_filebrowser_files.active.jodit_filebrowser_files_view-list a .jodit_filebrowser_files_item-info>span.jodit_filebrowser_files_item-info-filechanged,.jodit_filebrowser_files.active.jodit_filebrowser_files_view-list a .jodit_filebrowser_files_item-info>span.jodit_filebrowser_files_item-info-filesize{ + width:25%; +} +.jodit_filebrowser_files.active.jodit_filebrowser_files_view-list a:hover{ + background-color:#433b5c; +} +.jodit_filebrowser_files.active.jodit_filebrowser_files_view-list a:hover .jodit_filebrowser_files_item-info{ + color:#fff; + text-shadow:none; +} +.jodit_filebrowser_files.active.jodit_filebrowser_files_view-list a:before{ + height:100%; + content:""; + vertical-align:middle; + display:inline-block; +} +.jodit_draghover{ + background-color:#ecebe9; +} +.jodit_dialog_box .jodit_dialog_header-title .jodit_upload_button{ + position:relative; + width:220px; + border:0; + padding:25px 0; + margin:10px 0; + overflow:hidden; +} +.jodit_dialog_box .jodit_dialog_header-title .jodit_upload_button input{ + cursor:pointer; + position:absolute; + right:0; + top:0; + bottom:0; + margin:0 -10px 0 0; + padding:0; + opacity:0; + font-size:400px; +} +.jodit_dialog_box .jodit_dialog_header-title.jodit_filebrowser_title_box{ + display:-ms-flexbox; + display:flex; + -ms-flex-align:center; + align-items:center; + padding-left:10px; +} +.jodit_filebrowser_preview{ + text-align:center; + min-width:600px; + max-width:1000px; + min-height:700px; + max-height:100%; + position:relative; + display:-ms-flexbox; + display:flex; + -ms-flex-pack:center; + justify-content:center; + -ms-flex-align:center; + align-items:center; +} +@media (max-width:768px){ + .jodit_filebrowser_preview{ + max-width:100%; + max-height:100%; + min-width:auto; + min-height:auto; + height:100%; + } +} +.jodit_filebrowser_preview_box{ + -ms-flex-positive:1; + flex-grow:1; + display:-ms-flexbox; + display:flex; + -ms-flex-pack:center; + justify-content:center; + -ms-flex-align:center; + align-items:center; +} +.jodit_filebrowser_preview_navigation{ + position:absolute; + top:0; + height:100%; + left:0; +} +.jodit_filebrowser_preview_navigation-next{ + left:auto; + right:0; +} +.jodit_filebrowser_preview_navigation svg{ + width:45px; + height:45px; + position:relative; + top:50%; + margin-top:-22px; + transition:fill .3s linear; + fill:#9e9ba7; +} +.jodit_filebrowser_preview_navigation:hover svg{ + fill:#000; +} +.jodit_filebrowser_preview img{ + max-width:100%; + max-height:100%; +} +.jodit_grid{ + display:-ms-flexbox; + display:flex; + width:100%; +} +.jodit_grid [class*=jodit_col-]{ + -ms-flex:1 1 auto; + flex:1 1 auto; +} +.jodit_grid .jodit_col-lg-5-5{ + width:100%; +} +.jodit_grid .jodit_col-lg-4-5{ + width:80%; +} +.jodit_grid .jodit_col-lg-3-5{ + width:60%; +} +.jodit_grid .jodit_col-lg-2-5{ + width:40%; +} +.jodit_grid .jodit_col-lg-1-5{ + width:20%; +} +.jodit_grid .jodit_col-lg-4-4{ + width:100%; +} +.jodit_grid .jodit_col-lg-3-4{ + width:75%; +} +.jodit_grid .jodit_col-lg-2-4{ + width:50%; +} +.jodit_grid .jodit_col-lg-1-4{ + width:25%; +} +@keyframes rotate{ + to{ + transform:rotate(1turn); + } +} +.jodit_icon-loader{ + background:url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAIAAAACACAYAAADDPmHLAAAABGdBTUEAAK/INwWK6QAAABl0RVh0U29mdHdhcmUAQWRvYmUgSW1hZ2VSZWFkeXHJZTwAABRsSURBVHja7F1/aJfVGn/33RgUg8FiNfK2WCykyS7GLoYyUbwYipZMumgLo+iPS9HlXhSHkRXdislESxMz0mapuaFo2myjkfnNlTQ2FJdTu8NvLVcrdbpcfGvxrfs823m/vXt3fjznvOedzr0PPJzzPe+7d+97Ps95nuc851fGAw884CD98ccfI1Jqmc3UpEyQz4FkMqRTgYshn8fymZ57SyGbzf5mENIOz9+ngE9Atg/SLkhPQHoWeEDn3SmpSZlJnvf7ypUrTpb7IyMjY+gGN6WWmaY84l2T3c+u58D1csjOgvwsyBdBvsDRo2zgMl/ZNM59vcAJ4Dj8nzikLa5QmBLv28YCfPd3li7gPHBMwKdcEwhCJgN6FoLOWJtUgiWovALG04FXsbI44xbgw8AplbaU/Q+ZQNgGf0gA/JWhC1aQyle1eN91rPRKKKuEsjzZvSph0m2RiutpIYRrfZC8B+l7kB6jgq0CnQIy9X39v2NYQW5FeUFQlQVN/aALyiYBPw/5M5B+Dvw02vMggqcDukEl57F3xHf9H747+4bA5oD6dzqaYEgAqIDbBl9RhvZ4H/B5yL+IDp3oXhmwNkm3lTLn80VIz+O3QFqm2/rHwgeI6QDOa006LZ3Q4lHNNwK3AVeYAD4WgmHQUivYNzWyb7xufICYaavXVbuKZ6MXfwRVJ+TnXW+Am/oMnNaO3/Y5pPitcyh/a6LqtXwAt+J01LVFEzAJ0jpIj7JunJYd1wHchnBQHUSC3Uan8WPgPVgHlBiBCcAkH4Da2i2DjwGZlcy5W0K17zLwVb9NgaY4iJpawJs+BCnWwUo3SKXT4oOAP8IHCFsIfMCguj8JaQ2kOaaA227d10ALuIR1gHVxErjctPtHBd8btSR3A4MIgSePAZxqVPeQlthq7ZRuZVABCVkLuGkJpGgKsY4ybfUEVO84qhsoAzSgrUfHZ1UQVe99B6o2oMYdwg7latAq5iROGoueQExW6UE0gCe/ANIh9SZ6jqkWsN3STZ0rHWEgpkNmEvILxqQbSAXaAPxqSBswQkbpbpo6fGPR0m3GBYjBIIwqNjCTEAr4wkBQUA0AjKNrdZCu0okAqgQhTKCDhFxV91BNgsDuYx3WQZptG3xtDUCJEDKvthGuLVEJlq4gUMyAylfQERadPrhKOHTmB3Ces4RFEXNsgW8UClbZcEhxqPQIpHOord2k1ZsAH4YvYNJXN3EgWX4Ocw4LbIEvDQSJfADJtULWxSuj+BBUP4DaC6D0DkyFg6JKTVo/5brvXqzbo2zSi3af3/9bGgrW1Ar5kH4MXEzVHEHVf5CuYZC4fti9AoI/gXX8Eda5Tp9f9I4xWWsnOoc5zNMv1okjmKp/vzay3epNJ4+YmALdoWBPWTHksc5zTU1AekqYt7LcWTruTYTZQdmQHoB0GuXv/de8L8e7xrsuA8kPNtx3AZIOxp3APc7wvD6kvi+//DLh3nvPPfegWs1jf4dBGGxpOA+hlOXzgw7VBjEBnDKcs4jzDOZDOmjqD2SJQFGBx9JaSOcQ7xVO2RIJhf86AfB+Z3huHs7Ra2pra+ugtubTp0+jMLgC0e6/ftddd6EgzMO5iGwSaq4NITCdLczy6GzXAj8KnDIxAaM0AKeViwCtgbRSNgGUJwQyDaACngO4w6S/CXgb8KEvvvgiFUaw59y5c64mWXvnnXdmsijdYxjpdP6cXh6oS0g1Bb48zpFEzValA3663pcuXaoleSzFltBIlWhRmWx+v6yMcQJ4PU7A/Oyzz/qca0R33HEHrjlAEJa73rns24JqA0keTUGTjglIJpNOxsMPP6wLfiGkx53hxRbcewwXc1BAx0u4gGMNcP2nn36acq4juv322ytZ5K7UlhBo5LER3AvcTXU60wKgYbsyWTCi3LTV6wLvKesGrvrkk0/qneucCgoKHoJkHbxvYRAhMMij/zMbVzZRTMAvv/wycj4AoRv4Mk7oII4HkLp+vC6drwxt/FrgKeMBfKTe3t69UMFTgPG9B3WcQdMeBsvjhJJqnYGqjMrKSmr/tZxNWAi87o9i+1l5O6SPNjc3dzrjlPLz83HyC/aWpqk0gWZUUHZtJvxuUZmAtAYgtHycr/a6qIXz2DQI5OH1UDRjPIOPdOHChU6o+JmQXW+68JYS4vUB/bozvN5RGAImdwPZA3AC51RKrMAfyBHFGCRBnz4oe7ypqemgc4PQxYsX0YytuOWWW3BRaa3DWd0U1A/w/Z4KvBx4jcoExAitE6dzPStr3RR/QKQ5fOUJ4PsaGxtvGPC9dOnSJfyu+7ALa9MJFPx+lkU05YNBBDVdg0uwKc4eAWCZ83cC8jM+/PDDLucGpr6+Pvy+GWz/ASs9AMFvd7ax1ATEFOBjmLdSBraN3gBwHHhmQ0NDrzMB6PLly73MUYubOs3EiB/GJebyTEB6QogCnGrV6KAFR7AVeP4HH3ww4EwgunLlCn7vfACi1UQDqMb5PWUvm5qAB3HESXNomKz2GaOHv/DAgQNJZwJSf38/fvdC3J5G1iPQnf3jK5sGvx80MQHP69hxHWZ/2wN8//vvv3/BmcD0008/XWCaoEcUJ6C0eoUWeFbXBOBCzTKKJ2/YExgEXrRv374eJyLn6tWrWA+LAJRBy+o/rQUQUx0TsFwzRKzLK/bu3dseQf8nDQwMYH2sCOL0ibx9Vr6cagIKmf0nxe8pguC7vn/Pnj2bIshH088//4z1st+m+veUI6ZFFBOwLGj/XqIh0O4/HkEtJgDmcZ4/EED9e69VKk0ACoDN1u/jqrq6uv4IZjElk0msnypbwPs0wTKVCUBnYbLuMC5REA7v3r37vQhikhBgPTWrTAEFeB9NZt3C0SbAr/6DdPM4jF7/PyNotUzBU26vgAo8x+7zri3jmgAgnOJdKYrVB9QEb+zcubMrgpVOv/76K9bXGzrACwTJfw1D+9k8EzAXOE8GviEPAK+JIDXSAlhvA7yWTWztvMfiXM65PBNQrgLfUBi2v/vuu70RnPo0ODjYC0BtN3D2VNfLR5gAz04eRn17yb0p4A0RlIEI6y+la/MV1xf4fYACSEtDiP031dbWRrY/AP32229dAGCTrs1XrHHEaesFXh+gXCfooyEM2yIIrdC2ADZ/1D1eM+CagHLJ5ExTxrl9hyLsrDiDWI99EjApgPvLRwhAmQh4HV/Axwe3bt06GMEXnFKpFK4tOBgQcH95WdoEAE01nc8Xi8VEArA3gs4q7VWpfsHaCpEg4GrnoeXhOEKUw3u4yZYqbGo4Lk2KR5hZpcOsXjO9GIm0AYFycTErmoDJVLWu0Tto3bJly0CEmT36/fffkzh/UKfVE3yLkix3Xx+v5FjYaaslgiwUZxDrdbrm38guF6EAFFKAF5kEwcFPrRFcoVCrIdAiKsSlYUWqFi/zBwTXOiKsQqGOIKe1cQRmSAPkmYIv0ADY9Yuif+GYgC5Wv9kB1L6X8lAA8k3BFwhB94YNG1IRXPYJutwpINwBpNjSI/O5AhDQGUxEUIVKCRMBEGiFIQG4yX+Daf+fPacvwihUM2Czfm/KcgMLtjZZhudEY//hks2VVJlZ7tJvi5SMMApVA9gMsOVkXYvDFiO6fggFACUqJ6qKcaMBbD5uAH2AlE0fIKJxRSnUAGizcykePtWzjOo1VA2gpa0V2CVRALBbURDwQV4qiGAKVQDyLZ571JfFum0lFqTJvScvgilUytPxAxSY9boawMbD3OtFEUahaoAinQap0gA4JSzhPswSFz733HOZEVT2KZlMYr0WesGV7KpOoQRqgG6DVi4rx5EqjFWfjSCz3vqLHd9IoGyYnoBjNwpAwhBoWXlpJAChCECpv66p5ycJBCSBcwI7daZ7E83FtAiuUGgaT/WLACaYhk4MBCVk0UDKWb2c3+URVqFogOm8OqccqMW5d+Dmm29OuGsDOyw7gmUvvfRSFBCySFevXsX6LBO1cIoG8NEQ5u7KoFbLi0Kz3fODI7JGeHbwTSJADcxCq1cAWnR39yYIQUWEmVX1X2G6SYTgnhavABwL0uoF91dUV1dnR9AFp/7+fjysq0IGvIEGODYkAOwa7t/XYXl3kDzgBRF8Vgg3eczT2SqGYP97vBoA83ELrd6/WPSJCDsr6v8Jw91BRdfS6za9ewQ1qVo9RQv47plXU1NTHEFoTpcvX8aTwueJgKdoAI4wpE8Y9e4SdtgdGLK4S1gm8L8jGAO1fqy/TNmiUE1hQIwPj9AADOQk7ugRdJ9ADj+2bt26aI6AAV26dAnr7THqnsFEYTgEnBRtFl0fwk6hOcCrIjiNaBXOAKIcuq3hG4w4fTXma+lNOEHEZFs4hcA8+eqrr0a+gAZdvHgRbf+TsrMDDMxBr2v/eT7A0L5+8HN7AKdPFhncHMGqZftfB84Wga0yBwKtsN1hk4B5PsCIrd0C2HwRz924cWNlBK2afvzxx0rX89c5Qo4gCNv85bwDI7r8XUKqynfL/KmHazZt2pQbQSymH374AffuqeEB7gWXCrzHFCCmXf5niE4NWxPkJFAJ41GmtRHMUtWP9TNJdYScgQZYo3NoFEYF21WmgAq8776KzZs3Px1BPZq+//57rJcKXhg3oClo90b/qCeHvqLjA2j6B+u2bNlSFkH+J3333XdlAMo6ntq3cJroK6K4gOzgyP2oBaj2nqIdPGXYKzjw5ptvToqgd5yenh5U+Qcgmy07UdxQA7QD7xfFClSnh68Oelag6H5n+Fj6j9566638iQz++fPn8wGMRq/dV4EviwVwrq0W9QpUJsAdINof5LRQxfNLgBu2bt06IaePffvttzjDp8EZ3r6dDL7sQEkfyAdVW82rjo9H/hdkB2y2ft89eEB149tvvz2hlqh/8803OazlTzMFX6ENcKLvU7LgEMUEuIc9vqLb+inBJE8ezyo+un379gkxaPT111/jdx4FEGbJwOd1A2VdQ9896Pj1qIJDMSJI6yHpNGnpGlHFqVgp77zzzg29tjCRSBQx8KfKWrmJBvDkO4HXU3oI7pQwFUDpc/8s9ABk14uB23bs2HFDTiU7d+7cAqj4NrbESxtojeAQYjWoOnyaqwF4AsFSnDm81lT1y2YZ+cpwLmHDzp07a3bt2nVDTCrt6urKBq5hDl8eBXCTHgGjtWxTaVK8IEYFjKWrvVPIdU8VE2kMgUCsBD6ye/fukvEM/ldffVUCFX4EsitVtl3UYjU0wDHg1dQIodQJFJShKXgE0j5dLaACn6MJkKcDH6+rq6uur68fV72EM2fO5Jw9e7YasseBp5u0cKoQsDxO9Vrqqn6R2hdGAjWEoBvSR03B9wPNA95HGDVcBXxqz549D40H8E+fPo3vecoZntGTreqzmwgBRyDw2Plu3TBxxmuvvcYFUQYwy+OQ5UoV6DITQzEJnGsdbLSyfvHixdfVptSnTp2qZMJaqtsVVtWbAiP0zap498ryt956q5OxYcMGyj/gpbhbxS5IlwSJBQQYYsZVzWtREBYtWnTN9ic+efIkOq1LmM9SZDKplioQgrJ6ZpZTVODd32kBIEoZL0UvvdFdCBoUfGo8gXM0/UHgHTireeHChaFrhePHj+N0dzxqdxnwg2xwS0vD6YIvwAOnd89nvhkZeJduu+02J2Pjxo0UKZO9GM7w+cjdFMIgCmiqAXj39bO5DPFYLNY8b948ayeXtLW1lbIT1mcxzjVZUGtqCjh44Bj/34H7ZXjJhCItAAHAd1Mc0fvcPYAqCPhBhIHDF5jP0MF2QkmwE02HTMjs2bPTpqOlpSXPVeHABSwoVcLsOebzTWZH2fADOClO7ZqB3yfDTWUSUACyiHZG9UJY0SiNH7PKIjsiqt6BooegIhTMOYxHUTweN3q26EAN/wkr3t+qvEaKczbvxzoXPcf7brL/a9oNFKXYPZzpnUpGlX6dbqHIDIRNlIWXsuibbjdQkGLdzoQ0YfJ/uJFAamsndllw19HZzDlxVGFmkcqilFnSEFotnnKNOlZPGQX0lWOdzoa01xR47nCwDtBEpwbHoedj94wy0KSKCOoIQhgaQrXZgkoYdMCXPAvrcr57WITuXEHlcLCu00cQGjza7BEcRjbRAFSNQAXXVAh0zuY1BV/Q2r3pekixnz+oGRomvVtMV9Vr3I/98RXAC73LzoM4grIWb1sIxgp8iSnAOlsIKdZhynB8QG8wiKIBDPyCQ5C9F0cRKY6gDFwZ2DaFIEzwCS3e3b/nXlzKras1dFr/KA2go/5FLVRwfzdzDtfodgupZoFqGohbqIYGPsH+Yx3NxF6V7D2omkXlmMZM1T8PDMXfoUl4BruKkHaaaANbtj2MnoEJ+L6/72RdvGe8Kt9kjqBOj4SsAUyvce7BCSV/Ba6C/EBYXcSg5oIKtqkj5ikbgLSKqfwWaheRWqZ6j1gIAFPuQW2AI3lTIN0b1CSonMSwYgCU6wqQ8NunsOHcQcozVKZIVwhiKjVuMEihY0YwevgPSDG0eUy3ezjWYOsEhRRAHWPf/A93Egc1MKTj+FGEIGZhIEgJiMzPYPlmHNxgjmLTtRSCsOw+o2YWzcNvbTYIBVsVgrQGsAW+6cCSJx9nUcS/QbrfVAjCDgQZ/P1+yOM33Q9pPMizqCaAKgSxsMCntk6B2sdVyYsh/QvwC7hriY4QhCkUGi0e3/kF/AYow29pJ8YArJkAihDEwgRfVyNw8rif7X+B74Y8qs03nOGNDq0IgQ3Afff0sXecAfm72bv3UFoxpdWbtH7V32cFcfgoLcyCEKQdJ9zVHNL/AM9ijOP808MYD/CP7UvuO8ZGP+OMB3nP4T1PNfYvey/KXAPKd2XpevA27iWYANk9g8yZamblOa5A4FQtZ/jEsjybWsBTaX1sQkbcA/iACAQd0E2EQgU8RUiyKC02qGnQjS6qwPP9LQJwiLFLuUwQcBuaIiYQuBjTPc8wk/32VtYJFq104xQnmLlJMPuNNr3fUEuQQtDUVm8DeNcc/F+AAQBKd8HaIWdjwQAAAABJRU5ErkJggg==") no-repeat 50%; + background-size:100% 100%; + width:48px; + height:48px; + will-change:transform; + animation:rotate 2s ease-out 0s infinite; +} +.jodit_icon,.jodit_icon-loader{ + display:inline-block; + vertical-align:middle; +} +.jodit_icon{ + font-style:normal; + width:14px; + height:14px; + font-size:8px; + fill:#222; + transform-origin:0 0 !important; + overflow:visible; + background:50% no-repeat; + background-size:contain; +} +.jodit_icon_close{ + stroke:#222; +} +svg.jodit_icon{ + isolation:isolate; + height:auto; +} +.jodit_text_icon{ + font-size:14px; +} +.jodit_toolbar_size-small .jodit_icon{ + min-width:12px; + height:12px; + line-height:12px; +} +.jodit_toolbar_size-large .jodit_icon{ + min-width:16px; + height:16px; + line-height:16px; +} +.jodit_image_editor{ + width:100%; + height:100%; + padding:10px; + overflow:hidden; +} +@media (max-width:768px){ + .jodit_image_editor{ + height:auto; + } +} +.jodit_image_editor>div,.jodit_image_editor>div>div{ + height:100%; +} +@media (max-width:768px){ + .jodit_image_editor>div,.jodit_image_editor>div>div{ + height:auto; + min-height:200px; + } +} +.jodit_image_editor *{ + box-sizing:border-box; +} +.jodit_image_editor .jodit_image_editor_slider-title{ + text-shadow:#f3f3f3 0 1px 0; + color:#333; + border-bottom:1px solid hsla(0, 0%, 62%, .31); + background-color:#f9f9f9; + padding:.8em 1em; + text-overflow:ellipsis; + white-space:nowrap; + cursor:pointer; + -webkit-user-select:none; + -moz-user-select:none; + -ms-user-select:none; + user-select:none; + font-weight:700; + line-height:1em; +} +.jodit_image_editor .jodit_image_editor_slider-title svg{ + margin-right:10px; + width:16px; + display:inline-block; + vertical-align:middle; +} +.jodit_image_editor .jodit_image_editor_slider-content{ + display:none; +} +.jodit_image_editor .jodit_image_editor_slider.active .jodit_image_editor_slider-title{ + background-color:#5d5d5d; + color:#fff; + text-shadow:#000 0 1px 0; +} +.jodit_image_editor .jodit_image_editor_slider.active .jodit_image_editor_slider-title svg{ + fill:#fff; +} +.jodit_image_editor .jodit_image_editor_slider.active .jodit_image_editor_slider-content{ + display:block; +} +.jodit_image_editor_area{ + width:100%; + background-color:#eee; + background-image:linear-gradient(45deg, #ccc 25%, transparent 0, transparent 75%, #ccc 0, #ccc), linear-gradient(45deg, #ccc 25%, transparent 0, transparent 75%, #ccc 0, #ccc); + background-size:30px 30px; + background-position:0 0, 15px 15px; + height:100%; + overflow:hidden; + -webkit-user-select:none; + -moz-user-select:none; + -ms-user-select:none; + user-select:none; + position:relative; + display:none; +} +.jodit_image_editor_area.active{ + display:block; +} +.jodit_image_editor_area .jodit_image_editor_box{ + overflow:hidden; + position:relative; + z-index:1; + pointer-events:none; + height:100%; +} +.jodit_image_editor_area .jodit_image_editor_box img{ + -webkit-user-select:none; + -moz-user-select:none; + -ms-user-select:none; + user-select:none; + max-width:100%; + max-height:100%; +} +.jodit_image_editor_area .jodit_image_editor_croper,.jodit_image_editor_area .jodit_image_editor_resizer{ + z-index:2; + width:100px; + height:100px; + position:absolute; + box-shadow:0 0 11px #000; + border:1px solid #fff; + background-repeat:no-repeat; + top:10px; + left:20px; + pointer-events:none; +} +.jodit_image_editor_area .jodit_image_editor_croper i.jodit_bottomright,.jodit_image_editor_area .jodit_image_editor_resizer i.jodit_bottomright{ + position:absolute; + display:inline-block; + border:1px solid #383838; + z-index:4; + background-color:#8c7878; + cursor:se-resize; + border-radius:10px; + height:20px; + width:20px; + right:-10px; + bottom:-10px; + box-shadow:0 0 11px #000; + pointer-events:all; +} +.jodit_image_editor_area .jodit_image_editor_croper i.jodit_bottomright:active,.jodit_image_editor_area .jodit_image_editor_resizer i.jodit_bottomright:active{ + border:1px solid #ff0; +} +.jodit_image_editor_area.jodit_image_editor_area_crop{ + height:100%; + background:#eee; + text-align:center; + line-height:100%; + position:relative; +} +.jodit_image_editor_area.jodit_image_editor_area_crop:before{ + content:""; + line-height:100%; + vertical-align:middle; + height:100%; + display:inline-block; +} +.jodit_image_editor_area.jodit_image_editor_area_crop .jodit_image_editor_box{ + height:100%; + overflow:visible; + display:inline-block; + vertical-align:middle; + pointer-events:all; + font-size:0; + text-align:left; + line-height:100%; +} +.jodit_image_editor_area.jodit_image_editor_area_crop .jodit_image_editor_box img{ + max-width:100%; + max-height:100%; +} +.jodit_image_editor_area.jodit_image_editor_area_crop .jodit_image_editor_box:before{ + content:""; + line-height:100%; + vertical-align:middle; + height:100%; + display:inline-block; +} +.jodit_image_editor_area.jodit_image_editor_area_crop .jodit_image_editor_box:after{ + content:""; + position:absolute; + top:0; + left:0; + bottom:0; + right:0; + margin:auto; + background:hsla(0, 0%, 100%, .3); + z-index:1; +} +.jodit_image_editor_area.jodit_image_editor_area_crop .jodit_image_editor_box .jodit_image_editor_croper{ + pointer-events:all; + cursor:move; +} +.jodit_image_editor_area.jodit_image_editor_area_crop .jodit_image_editor_box .jodit_image_editor_croper i.jodit_sizes{ + font-size:12px; + white-space:pre; + position:absolute; + bottom:-30px; + left:100%; + text-align:center; + color:#fff; + text-shadow:none; + background:rgba(0, 0, 0, .2); + border-radius:.4em; + padding:9px 6px; + display:block; +} +.jodit_properties{ + font-family:Helvetica,sans-serif,Arial; + font-size:14px; +} +.jodit_properties svg{ + font-style:normal; + display:inline-block; + width:14px; + height:14px; + line-height:14px; + font-size:8px; + overflow:hidden; + vertical-align:middle; + fill:#222; + transform-origin:0 0 !important; +} +.jodit_properties .jodit_properties_view_box{ + padding:10px; +} +.jodit_properties .jodit_properties_view_box .jodit_properties_image_view{ + display:-ms-flexbox; + display:flex; + -ms-flex-align:center; + align-items:center; + -ms-flex-pack:center; + justify-content:center; + height:150px; + padding:0; + margin:0 0 10px; + background-color:#f6f6f6; +} +.jodit_properties .jodit_properties_view_box .jodit_properties_image_view img{ + max-width:100%; + max-height:100%; +} +.jodit_properties .jodit_properties_view_box .jodit_properties_image_sizes.jodit_form_group{ + -ms-flex-direction:row; + flex-direction:row; + -ms-flex-align:center; + align-items:center; + padding:0 !important; + margin:0 !important; +} +.jodit_properties .jodit_properties_view_box .jodit_properties_image_sizes.jodit_form_group a{ + display:inline-block; + cursor:pointer; +} +.jodit_properties .jodit_properties_view_box .jodit_properties_image_sizes.jodit_form_group input[type=number]{ + display:inline-block !important; + width:calc(50% - 8px) !important; +} +.jodit_toolbar,.jodit_toolbar *{ + box-sizing:border-box; +} +.jodit_toolbar{ + font-family:Helvetica,sans-serif,Arial; + font-size:14px; + position:relative; + left:0; + top:0; + display:-ms-flexbox; + display:flex; + -ms-flex:0 0 auto; + flex:0 0 auto; + -ms-flex-negative:0; + flex-shrink:0; + -ms-flex-wrap:wrap; + flex-wrap:wrap; + margin:0 !important; + padding:0 !important; + list-style:none !important; + font-size:0; + background:#f9f9f9; + box-shadow:0 4px 4px -2px rgba(0, 0, 0, .14); + border:1px solid #ccc; + border-bottom:0; + min-height:16px !important; +} +.jodit_toolbar+.jodit_toolbar_dummy{ + display:none; +} +.jodit_toolbar.jodit_fly{ + position:absolute; + left:0; + right:0; + z-index:30000; + background:#fff; +} +.jodit_toolbar>.jodit_toolbar_btn{ + margin:0 !important; + padding:0; + list-style:none !important; + outline:none; + position:relative; + text-align:center; + cursor:pointer; + transition:background-color .2s linear,opacity .1s linear; +} +.jodit_toolbar>.jodit_toolbar_btn.jodit_disabled{ + background-color:transparent !important; + opacity:.3; + cursor:default; +} +.jodit_toolbar>.jodit_toolbar_btn.jodit_disabled a{ + cursor:default; +} +.jodit_toolbar>.jodit_toolbar_btn .jodit_toolbar_btn>a,.jodit_toolbar>.jodit_toolbar_btn>a{ + width:100%; + height:100%; + outline:none; + text-decoration:none; +} +.jodit_toolbar>.jodit_toolbar_btn .jodit_toolbar_btn>a:active+.jodit_tooltip,.jodit_toolbar>.jodit_toolbar_btn>a:active+.jodit_tooltip{ + visibility:hidden !important; +} +.jodit_toolbar>.jodit_toolbar_btn .jodit_toolbar_btn>a:focus,.jodit_toolbar>.jodit_toolbar_btn>a:focus{ + outline:1px solid #ccc; +} +.jodit_toolbar>.jodit_toolbar_btn.jodit_disabled .jodit_tooltip{ + display:none !important; +} +.jodit_toolbar>.jodit_toolbar_btn>a{ + line-height:100%; +} +.jodit_toolbar>.jodit_toolbar_btn.jodit_dropdown_open .jodit_tooltip,.jodit_toolbar>.jodit_toolbar_btn.jodit_popup_open .jodit_tooltip,.jodit_toolbar>.jodit_toolbar_btn .jodit_toolbar_list-open .jodit_tooltip{ + visibility:hidden !important; +} +.jodit_toolbar>.jodit_toolbar_btn:not(.jodit_toolbar-input):hover{ + background-color:#dde4ef; + outline:none; +} +.jodit_toolbar>.jodit_toolbar_btn.jodit_active,.jodit_toolbar>.jodit_toolbar_btn:not(.jodit_toolbar-input):active{ + background-color:hsla(0, 0%, 86.7%, .4); + outline:none; +} +.jodit_toolbar>.jodit_toolbar_btn.jodit-btn-hidden{ + display:none !important; +} +.jodit_toolbar>.jodit_toolbar_btn.jodit_with_dropdownlist .jodit_with_dropdownlist-trigger{ + display:inline-block; + vertical-align:middle; +} +.jodit_toolbar .jodit_toolbar_btn-separator{ + border-left:0; + border-right:1px solid #e6e6e6; + padding:0; + margin:2px 5px 0 !important; + cursor:default; +} +.jodit_toolbar .jodit_toolbar_btn-break{ + -ms-flex-preferred-size:100%; + flex-basis:100%; + width:0; + border-top:1px solid #e6e6e6; + height:0 !important; +} +.jodit_toolbar .jodit_toolbar_btn{ + min-width:32px; + height:32px; + line-height:32px; +} +.jodit_toolbar .jodit_toolbar_btn.jodit_toolbar_btn-separator{ + height:28px; + width:0; + min-width:0; +} +.jodit_toolbar .jodit_toolbar_btn.jodit_with_dropdownlist{ + padding:0 7px; +} +.jodit_toolbar .jodit_toolbar_btn.jodit_with_dropdownlist .jodit_with_dropdownlist-trigger{ + width:8px; + height:8px; + margin-left:5.33333333px; +} +.jodit_toolbar_btn>a{ + color:#000; + text-decoration:none; + display:-ms-flexbox; + display:flex; + -ms-flex-pack:center; + justify-content:center; + -ms-flex-align:center; + align-items:center; + background:no-repeat 50%; +} +.jodit_toolbar.jodit_text_icons>.jodit_toolbar_btn>a{ + line-height:1; +} +.jodit_tooltip{ + position:absolute; + background:#727171; + color:#fff; + font-family:Helvetica,sans-serif,Arial; + font-size:14px; + font-size:12px; + line-height:15px; + white-space:normal; + padding:4px 5px; + z-index:10001; + min-width:90px; + max-width:120px; + width:auto; + transition:opacity .3s linear; +} +@media (max-width:768px){ + .jodit_tooltip{ + display:none; + } +} +.jodit_toolbar_size-small .jodit_toolbar{ + min-height:12px !important; +} +.jodit_toolbar_size-small .jodit_toolbar .jodit_toolbar_btn{ + min-width:24px; + height:24px; + line-height:24px; +} +.jodit_toolbar_size-small .jodit_toolbar .jodit_toolbar_btn.jodit_toolbar_btn-separator{ + height:20px; + width:0; + min-width:0; +} +.jodit_toolbar_size-small .jodit_toolbar .jodit_toolbar_btn.jodit_with_dropdownlist{ + padding:0 5px; +} +.jodit_toolbar_size-small .jodit_toolbar .jodit_toolbar_btn.jodit_with_dropdownlist .jodit_with_dropdownlist-trigger{ + width:6px; + height:6px; + margin-left:4px; +} +.jodit_toolbar_size-large .jodit_toolbar{ + min-height:18px !important; +} +.jodit_toolbar_size-large .jodit_toolbar .jodit_toolbar_btn{ + min-width:36px; + height:36px; + line-height:36px; +} +.jodit_toolbar_size-large .jodit_toolbar .jodit_toolbar_btn.jodit_toolbar_btn-separator{ + height:32px; + width:0; + min-width:0; +} +.jodit_toolbar_size-large .jodit_toolbar .jodit_toolbar_btn.jodit_with_dropdownlist{ + padding:0 8px; +} +.jodit_toolbar_size-large .jodit_toolbar .jodit_toolbar_btn.jodit_with_dropdownlist .jodit_with_dropdownlist-trigger{ + width:9px; + height:9px; + margin-left:6px; +} +.jodit_toolbar_popup{ + position:absolute; + z-index:10; + top:100%; + left:0; + margin-top:10px; + padding-top:0; + font-size:14px; + line-height:14px !important; + background:#fff; + box-shadow:0 2px 4px rgba(0, 0, 0, .2); + border:1px solid rgba(0, 0, 0, .2); +} +.jodit_toolbar_popup .jodit_toolbar{ + box-shadow:none; + border-width:0; + background-color:transparent; +} +.jodit_toolbar_popup .jodit_toolbar .jodit_toolbar{ + background-color:#f9f9f9; + box-shadow:0 4px 4px -2px rgba(0, 0, 0, .14); + border:1px solid #ccc; +} +.jodit_toolbar_popup>*{ + margin:10px; +} +.jodit_toolbar_popup .jodit_popup_triangle{ + position:absolute; + top:-5px; + left:9px; + z-index:6; + padding:0; + margin:0; + width:8px; + height:8px; + display:inline-block; + transform:rotate(45deg); + background:#fff; + border:solid rgba(0, 0, 0, .2); + border-width:1px 0 0 1px; +} +.jodit_toolbar_popup.jodit_right{ + left:auto; + right:0; +} +.jodit_toolbar_popup.jodit_right:before{ + left:auto; + right:14px; +} +.jodit_toolbar .jodit_toolbar_btn>svg{ + max-width:50%; + vertical-align:middle; +} +.jodit_container>.jodit_toolbar>li:first-child{ + margin-left:2px !important; +} +.jodit_container[dir=rtl]>.jodit_toolbar>li:first-child{ + margin-left:0 !important; + margin-right:2px !important; +} +.jodit_draganddrop_file_box,.jodit_uploadfile_button{ + position:relative; + width:100%; + border:1px dashed #ccc; + padding:25px 0; + margin:10px 0; + text-align:center; + overflow:hidden; +} +.jodit_draganddrop_file_box:hover,.jodit_uploadfile_button:hover{ + background-color:#ecebe9; +} +.jodit_draganddrop_file_box input,.jodit_uploadfile_button input{ + cursor:pointer; + position:absolute; + right:0; + top:0; + bottom:0; + left:0; + margin:0; + padding:0; + opacity:0; + font-size:400px; +} +@media (max-width:768px){ + .jodit_draganddrop_file_box{ + width:auto; + max-width:100%; + min-width:180px; + } +} +.jodit_statusbar{ + font-family:Helvetica,sans-serif,Arial; + font-size:14px; + display:-ms-flexbox; + display:flex; + -ms-flex-pack:justify; + justify-content:space-between; + border:1px solid #ccc; + border-top:0; + font-size:0; + background-color:#f9f9f9; + padding:0 5px; +} +.jodit_statusbar .jodit_statusbar_item{ + font-size:11px; + line-height:1.57142857em; + margin:0 10px 0 0; + padding:0; + -ms-flex:1; + flex:1; +} +.jodit_statusbar .jodit_statusbar_item.jodit_statusbar_item-right{ + margin:0 0 0 10px; + -ms-flex-order:1; + order:1; + -ms-flex:0; + flex:0; +} +.jodit_statusbar .jodit_statusbar_item .jodit_icon{ + font-size:11px; +} +.jodit_statusbar .jodit_statusbar_item li,.jodit_statusbar .jodit_statusbar_item ul{ + position:relative; + margin:0; + padding:0; + list-style:none; + display:-ms-flexbox; + display:flex; + -ms-flex-pack:center; + justify-content:center; + -ms-flex-align:center; + align-items:center; +} +.jodit_statusbar .jodit_statusbar_item li li,.jodit_statusbar .jodit_statusbar_item ul li{ + margin-right:5px; +} +.jodit_statusbar .jodit_statusbar_item ul{ + -ms-flex-pack:start; + justify-content:flex-start; +} +.jodit_statusbar .jodit_statusbar_item a,.jodit_statusbar .jodit_statusbar_item span{ + -webkit-user-select:none; + -moz-user-select:none; + -ms-user-select:none; + user-select:none; + display:inline-block; + vertical-align:baseline; + text-align:left; + white-space:nowrap; + padding:2px 3px; + line-height:10px; + outline:0; + border:0; + color:#222; +} +.jodit_statusbar .jodit_statusbar_item a span,.jodit_statusbar .jodit_statusbar_item span span{ + padding:0; +} +.jodit_statusbar .jodit_statusbar_item svg{ + width:11px; + height:11px; + display:inline-block; + vertical-align:top; +} +.jodit_statusbar .jodit_statusbar_item a{ + text-decoration:none; + cursor:default; + border-radius:3px; +} +.jodit_statusbar .jodit_statusbar_item a:hover{ + background-color:hsla(0, 0%, 88.2%, .99); + text-decoration:none; + color:#222; +} +.jodit_statusbar:after{ + content:" "; + display:block; + visibility:hidden; + font-size:0; + height:0; +} +.jodit_disabled .jodit_statusbar{ + opacity:.4; +} +.jodit_about{ + padding:20px; +} +.jodit_about a{ + color:#459ce7; + text-decoration:none; +} +.jodit_about a:focus,.jodit_about a:hover{ + color:#23527c; + text-decoration:underline; + outline:0; +} +.jodit_about div{ + margin-bottom:5px; +} +.jodit_colorpicker{ + min-width:180px; + text-align:left; + margin:0; + -webkit-user-select:none; + -moz-user-select:none; + -ms-user-select:none; + user-select:none; +} +.jodit_colorpicker .jodit_colorpicker_group{ + margin-bottom:5px; + white-space:normal; +} +.jodit_colorpicker a{ + width:18px; + height:18px; + line-height:16px; + display:inline-block; + text-decoration:none; + vertical-align:middle; + text-align:center; +} +.jodit_colorpicker a:before{ + content:""; + display:inline-block; + height:100%; + vertical-align:middle; + width:0; +} +.jodit_colorpicker a svg{ + display:inline-block; + vertical-align:middle; + font-smoothing:antialiased; + max-width:14px; +} +.jodit_colorpicker a:hover{ + border-color:#000; +} +.jodit_colorpicker a:active{ + background:#d6d6d6; + color:#b5b5b5; +} +.jodit_colorpicker .jodit_text_icon{ + width:auto; + text-decoration:none; + color:#000; +} +.jodit_colorpicker span em{ + width:16px; + height:16px; + display:inline-block; + margin-right:4px; +} +.jodit_colorpicker span input{ + width:18px; + height:18px; + padding:0; + border:none; + -webkit-appearance:none; + -moz-appearance:none; + appearance:none; +} +.jodit_colorpicker span input[type=color]::-webkit-color-swatch-wrapper{ + padding:0; +} +.jodit_colorpicker span input input[type=color]::-webkit-color-swatch{ + border:none; +} +@keyframes pulse{ + 30%{ + opacity:.6; + } + 60%{ + opacity:0; + } + to{ + opacity:.6; + } +} +.jodit_progress_bar{ + position:absolute; + top:0; + left:0; + height:2px; + z-index:2147483647; + border-radius:1px; + display:none; +} +.jodit_progress_bar div{ + position:relative; + background:#b91f1f; + height:2px; + transition:width .5s ease-out,opacity .5s linear; + will-change:width, opacity; +} +.jodit_progress_bar div:after,.jodit_progress_bar div:before{ + animation:pulse 2s ease-out 0s infinite; + content:""; + display:inline-block; + position:absolute; + top:0; + height:2px; + box-shadow:1px 0 6px 1px #b91f1f; + border-radius:100%; + opacity:.6; +} +.jodit_progress_bar div:before{ + width:180px; + right:-80px; + clip:rect(-6px, 90px, 14px, -6px); +} +.jodit_progress_bar div:after{ + width:20px; + right:0; + clip:rect(-6px, 22px, 14px, 10px); +} +.jodit_tabs{ + font-family:Helvetica,sans-serif,Arial; + font-size:14px; +} +.jodit_tabs .jodit_tabs_buttons{ + line-height:18px; + margin-bottom:5px; + margin-top:4px; + display:-ms-flexbox; + display:flex; +} +@media (max-width:768px){ + .jodit_tabs .jodit_tabs_buttons{ + display:block; + } +} +.jodit_tabs .jodit_tabs_buttons>a{ + display:-ms-flexbox; + display:flex; + -ms-flex-align:center; + align-items:center; + -ms-flex-pack:center; + justify-content:center; + padding:5px 20px; + font-size:11px; + font-weight:700; + text-align:center; + white-space:nowrap; + height:29px; + line-height:27px; + text-decoration:none; + position:relative; + vertical-align:middle; + transition:background .1s linear; + text-overflow:ellipsis; + overflow:hidden; + box-shadow:none; + background-color:#f5f5f5; + color:#737373; + border:1px solid rgba(0, 0, 0, .1); + outline:none; +} +@media (max-width:768px){ + .jodit_tabs .jodit_tabs_buttons>a{ + width:100% !important; + border-radius:0 !important; + } +} +.jodit_tabs .jodit_tabs_buttons>a+a{ + margin-left:-1px; +} +@media (max-width:768px){ + .jodit_tabs .jodit_tabs_buttons>a+a{ + margin-left:0; + margin-top:-1px; + } +} +.jodit_tabs .jodit_tabs_buttons>a i,.jodit_tabs .jodit_tabs_buttons>a svg{ + width:16px; + height:16px; + display:inline-block; + vertical-align:sub; + margin-right:5px; + fill:#737373; +} +.jodit_tabs .jodit_tabs_buttons>a:hover{ + border:1px solid #c6c6c6; + color:#111; + box-shadow:none; + background-color:#f8f8f8; + outline:none; +} +.jodit_tabs .jodit_tabs_buttons>a:hover i,.jodit_tabs .jodit_tabs_buttons>a:hover svg{ + fill:#111; +} +.jodit_tabs .jodit_tabs_buttons>a.active,.jodit_tabs .jodit_tabs_buttons>a:active{ + outline:none; + background:#fff; + border:1px solid #ccc; + color:#333; +} +.jodit_tabs .jodit_tabs_buttons>a.active i,.jodit_tabs .jodit_tabs_buttons>a.active svg,.jodit_tabs .jodit_tabs_buttons>a:active i,.jodit_tabs .jodit_tabs_buttons>a:active svg{ + fill:#333; +} +.jodit_tabs .jodit_tabs_wrapper .jodit_tab{ + display:none; +} +.jodit_tabs .jodit_tabs_wrapper .jodit_tab.active{ + display:block; +} +.jodit_tabs .jodit_tabs_wrapper .jodit_tab .jodit_tab_empty{ + min-width:220px; + min-height:100px; +} +.jodit-add-new-line{ + z-index:1; + position:absolute; + height:20px; + line-height:100%; + vertical-align:middle; + font-size:0; + top:0; + outline:none; + margin-top:-10px; + display:none; +} +.jodit-add-new-line,.jodit-add-new-line *{ + box-sizing:border-box; +} +.jodit-add-new-line:before{ + height:100%; +} +.jodit-add-new-line:after,.jodit-add-new-line:before{ + display:inline-block; + vertical-align:middle; + content:""; +} +.jodit-add-new-line:after{ + box-sizing:border-box; + border-top:1px solid #ccc; + height:1px; + width:calc(100% - 30px); +} +.jodit-add-new-line span{ + right:0; + position:absolute; + display:inline-block; + width:30px; + height:20px; + background:rgba(236, 235, 233, .3); + vertical-align:top; + border:1px solid #ccc; + padding:0 5px; + cursor:pointer; +} +.jodit-add-new-line span:hover{ + background:#ecebe9; +} +.jodit-add-new-line svg{ + width:16px; + fill:#ccc; + vertical-align:top; +} +.jodit_source_mode .jodit-add-new-line{ + display:none !important; +} +.jodit_error_box_for_messages{ + font-family:Helvetica,sans-serif,Arial; + font-size:14px; + position:absolute; + right:0; + bottom:0; + width:0; + height:0; + overflow:visible; + z-index:3; +} +.jodit_error_box_for_messages>*{ + position:absolute; + right:5px; + bottom:0; + display:block; + transition:opacity .1s linear,bottom .3s linear; + opacity:0; + background:rgba(255, 0, 0, .29); + color:#e02b2b; + padding:2px 7px; + border:1px solid rgba(226, 117, 117, .44); + font-size:14px; + white-space:pre; +} +.jodit_error_box_for_messages>.active{ + opacity:1; +} +.jodit_error_box_for_messages>.info{ + background:rgba(204, 229, 247, .71); + color:#776565; + border:1px solid hsla(0, 0%, 60.4%, .44); +} +.jodit_error_box_for_messages>.success{ + background:rgba(77, 236, 112, .29); + color:#5d5a5a; + border:1px solid hsla(0, 0%, 58%, .44); +} +.jodit_fullsize_box{ + z-index:100000 !important; + position:static !important; + overflow:visible !important; +} +body.jodit_fullsize_box,html.jodit_fullsize_box{ + height:0 !important; + width:0 !important; + overflow:initial !important; +} +html.jodit_fullsize_box{ + position:fixed !important; +} +.jodit_fullsize{ + position:absolute; + top:0; + left:0; + right:0; + bottom:0; + z-index:100000; + max-width:none !important; +} +.jodit_fullsize .toolbar{ + width:100% !important; +} +.jodit_fullsize .jodit_area,.jodit_fullsize .jodit_editor{ + height:100%; +} +.jodit_fullsize .jodit_workflow{ + height:calc(100% - 24px); + overflow:auto; +} +.jodit_fullsize.jodit_toolbar_size-small .jodit_workflow{ + height:calc(100% - 18px); +} +.jodit_fullsize.jodit_toolbar_size-large .jodit_workflow{ + height:calc(100% - 27px); +} +.jodit_placeholder{ + font-family:Helvetica,sans-serif,Arial; + font-size:14px; + -webkit-user-select:none !important; + -moz-user-select:none !important; + -ms-user-select:none !important; + user-select:none !important; + top:0; + left:0; + display:block; + position:absolute; + padding:10px; + color:rgba(0, 0, 0, .35); + z-index:1; + pointer-events:none; +} +.jodit_toolbar_popup-inline-container{ + z-index:1300; + min-width:700px; +} +.jodit_toolbar_popup-inline-target{ + position:absolute; +} +.jodit_toolbar_popup-inline-target.jodit_toolbar_popup-inline-target-hidden{ + display:none; +} +.jodit_toolbar_popup-inline{ + display:inline-block !important; + position:relative !important; +} +.jodit_toolbar_popup-inline>div{ + color:hsla(0, 0%, 88.2%, .99); + background:#fff; + box-shadow:none; + background-clip:padding-box; + font-family:Helvetica,sans-serif,Arial; + box-sizing:border-box; + -webkit-user-select:none; + -moz-user-select:none; + -ms-user-select:none; + user-select:none; + z-index:100001 !important; + text-align:left; + border:1px solid hsla(0, 0%, 88.2%, .99); + display:inline-block; + vertical-align:top; +} +.jodit_toolbar_popup-inline .jodit_toolbar{ + z-index:7; + border:0; + display:block; + white-space:nowrap; +} +.jodit_toolbar_popup-inline .jodit_toolbar_btn{ + display:-ms-inline-flexbox; + display:inline-flex; +} +.jodit_toolbar_popup-inline .jodit_toolbar_btn-break{ + display:block; + width:100%; +} +.jodit_toolbar_popup-inline>div>.jodit_toolbar{ + box-shadow:none; +} +.jodit_toolbar_popup-inline>.jodit_popup_triangle{ + position:absolute; + padding:0; + margin:0 0 0 -4px; + width:8px; + height:8px; + top:-4px; + display:inline-block; + transform:rotate(45deg); + background:#fff; + border:solid hsla(0, 0%, 88.2%, .99); + border-width:1px 0 0 1px; + z-index:6; +} +.jodit_toolbar_popup-inline.jodit_toolbar_popup-inline-top>.jodit_popup_triangle{ + top:auto; + bottom:-4px; + border-width:0 1px 1px 0; +} +.jodit_toolbar_popup-inline .buttons{ + box-shadow:0 1px 3px rgba(0, 0, 0, .12),0 1px 2px rgba(0, 0, 0, .24); + padding:0 2px; + white-space:nowrap; + line-height:0; + border-bottom:0; +} +[data-jodit_iframe_wrapper]{ + display:block; + -webkit-user-select:none; + -moz-user-select:none; + -ms-user-select:none; + user-select:none; + position:relative; +} +[data-jodit_iframe_wrapper]:after{ + position:absolute; + content:""; + z-index:1; + top:0; + left:0; + right:0; + bottom:0; + cursor:pointer; + display:block; + background:transparent; +} +.jodit_resizer{ + width:100px; + height:100px; + position:absolute; + border:1px solid rgba(3, 14, 82, .92); + top:0; + left:0; + display:none; + pointer-events:none; + font-size:0; +} +.jodit_resizer *{ + box-sizing:border-box; +} +.jodit_resizer>span{ + left:50%; + top:50%; + height:24px; + width:70px; + max-width:100%; + margin-left:-35px; + margin-top:-12px; + line-height:24px; + font-size:12px; + text-align:center; + color:#fff; + background-color:rgba(0, 0, 0, .35); + opacity:0; + transition:opacity .2s linear; + overflow:visible; +} +.jodit_resizer>i,.jodit_resizer>span{ + position:absolute; + display:inline-block; +} +.jodit_resizer>i{ + z-index:4; + pointer-events:all; + border:1px solid rgba(3, 14, 82, .92); + background-color:hsla(0, 0%, 88.2%, .99); + width:10px; + height:10px; +} +.jodit_resizer>i:hover{ + background-color:#f8f8f8; +} +.jodit_resizer>i:first-child{ + left:-5px; + top:-5px; + cursor:nw-resize; +} +.jodit_resizer>i:nth-child(2){ + right:-5px; + top:-5px; + cursor:ne-resize; +} +.jodit_resizer>i:nth-child(3){ + right:-5px; + bottom:-5px; + cursor:se-resize; +} +.jodit_resizer>i:nth-child(4){ + left:-5px; + bottom:-5px; + cursor:sw-resize; +} +@media (max-width:768px){ + .jodit_resizer>i{ + width:20px; + height:20px; + } + .jodit_resizer>i:first-child{ + left:-10px; + top:-10px; + cursor:nw-resize; + } + .jodit_resizer>i:nth-child(2){ + right:-10px; + top:-10px; + cursor:ne-resize; + } + .jodit_resizer>i:nth-child(3){ + right:-10px; + bottom:-10px; + cursor:se-resize; + } + .jodit_resizer>i:nth-child(4){ + left:-10px; + bottom:-10px; + cursor:sw-resize; + } +} +.jodit_container{ + min-height:100px; +} +.jodit_container .jodit_workplace{ + display:-ms-flexbox; + display:flex; + height:auto; + min-height:50px; + overflow:hidden; +} +.jodit_editor_resize{ + position:relative; +} +.jodit_editor_resize a{ + position:absolute; + bottom:0; + right:0; + -webkit-user-select:none; + -moz-user-select:none; + -ms-user-select:none; + user-select:none; + width:0; + height:0; + overflow:hidden; + border-color:transparent #ccc transparent transparent; + border-style:dashed solid dashed dashed; + border-width:7px 7px 0 0; + cursor:se-resize; +} +.jodit_source{ + display:none; + position:relative; + background-color:#f8f8f8; + font-size:0; + -ms-flex:1; + flex:1; + overflow:auto; +} +.jodit_source,.jodit_source .jodit_source_mirror-fake{ + min-height:100%; +} +.jodit_container.jodit_source_mode .jodit_wysiwyg,.jodit_container.jodit_source_mode .jodit_wysiwyg_iframe{ + display:none !important; +} +.jodit_container.jodit_source_mode .jodit_source{ + display:block !important; +} +.jodit_container.jodit_split_mode .jodit_source,.jodit_container.jodit_split_mode .jodit_wysiwyg,.jodit_container.jodit_split_mode .jodit_wysiwyg_iframe{ + display:block !important; + width:50%; + -ms-flex:1; + flex:1; +} +.jodit_source_mirror{ + border:0; + width:100%; + background:#3f3f3f; + margin:0; + height:100%; + box-shadow:none; + resize:none; + box-sizing:border-box; + color:#f0f0f0; + outline:none; + font-family:Menlo,Monaco,monospace,sans-serif; + font-size:13px; + line-height:1.3em; + overflow:auto; + z-index:2; + padding:10px; + white-space:pre-wrap; + -moz-tab-size:2em; + -o-tab-size:2em; + tab-size:2em; + min-height:100%; +} +.jodit_source_mirror::-moz-selection{ + background:#bdbdbd; +} +.jodit_source_mirror::selection{ + background:#bdbdbd; +} +.jodit_table_resizer{ + cursor:col-resize; + position:absolute; + z-index:3; + padding-left:5px; + padding-right:5px; + margin-left:-5px; +} +.jodit_table_resizer:after{ + content:""; + display:block; + height:100%; + width:0; + border:0; +} +.jodit_table_resizer-moved{ + background-color:#b5d6fd; + z-index:2; +} +.jodit_table_resizer-moved:after{ + border-right:1px solid #1e88e5; +} +.jodit_wysiwyg table{ + width:100%; + border:none; + border-collapse:collapse; + table-layout:fixed; + empty-cells:show; + max-width:100%; +} +.jodit_wysiwyg table tr{ + -webkit-user-select:none; + -moz-user-select:none; + -ms-user-select:none; + user-select:none; +} +.jodit_wysiwyg table tr td,.jodit_wysiwyg table tr th{ + border:1px solid #ddd; + text-align:left; + vertical-align:middle; + -webkit-user-select:text; + -moz-user-select:text; + -ms-user-select:text; + user-select:text; +} +.jodit_wysiwyg table tr td[data-jodit-selected-cell],.jodit_wysiwyg table tr th[data-jodit-selected-cell]{ + border:1px double #1e88e5; +} +.jodit_form_inserter .jodit_form-table-creator-box{ + display:-ms-flexbox; + display:flex; +} +.jodit_form_inserter .jodit_form-table-creator-box .jodit_form-container{ + padding:0; + margin:0; + min-width:180px; + font-size:0; +} +.jodit_form_inserter .jodit_form-table-creator-box .jodit_form-container>div{ + width:18px; + height:18px; + box-sizing:border-box; + display:inline-block; + position:relative; + vertical-align:top; +} +.jodit_form_inserter .jodit_form-table-creator-box .jodit_form-container>div:after{ + content:""; + position:absolute; + top:0; + left:0; + display:inline-block; + width:12px; + height:12px; + border:1px solid #ccc; +} +.jodit_form_inserter .jodit_form-table-creator-box .jodit_form-container>div.hovered:after{ + background:#7a450f; + border:1px solid #b5b5b5; +} +.jodit_form_inserter .jodit_form-table-creator-box .jodit_form-options{ + font-size:14px; + vertical-align:top; +} +.jodit_form_inserter .jodit_form-table-creator-box .jodit_form-options label{ + text-align:left; + padding-top:0; +} +.jodit_form_inserter .jodit_form-table-creator-box .jodit_form-options label input{ + margin-right:10px; +} +.jodit_form_inserter label{ + text-align:center; + font-size:14px; + padding:8px; + margin:0; +} +.jodit_text_icons .jodit_icon{ + width:auto; + font-size:14px; +} +.jodit_text_icons .jodit_icon:first-letter{ + text-transform:uppercase; +} +.jodit_text_icons .jodit_tabs .jodit_tabs_buttons>a{ + width:auto; + font-family:Helvetica,sans-serif,Arial; +} +.jodit_text_icons .jodit_tabs .jodit_tabs_buttons>a i,.jodit_text_icons .jodit_toolbar>li{ + width:auto; +} +.jodit_text_icons .jodit_toolbar>li>a{ + text-decoration:none; + line-height:1; +} +.jodit_text_icons.jodit_dialog_box .jodit_dialog .jodit_button,.jodit_text_icons.jodit_dialog_box .jodit_dialog .jodit_dialog_header a,.jodit_text_icons .jodit_toolbar>li>a{ + padding:0 12px; + font-family:Helvetica,sans-serif,Arial; + width:auto; + color:rgba(0, 0, 0, .75); +} +.jodit_text_icons.jodit_dialog_box .jodit_dialog .jodit_button .jodit_icon,.jodit_text_icons.jodit_dialog_box .jodit_dialog .jodit_dialog_header a .jodit_icon{ + width:auto; +} +.jodit_widget,.jodit_widget *{ + box-sizing:border-box; +} +.jodit_search{ + font-family:Helvetica,sans-serif,Arial; + font-size:14px; + visibility:hidden; + position:absolute; + top:0; + right:0; + width:0; + height:0; +} +.jodit_search.jodit_search-active{ + visibility:visible; +} +.jodit_search .jodit_search_box{ + width:320px; + position:absolute; + right:0; + background-color:#f9f9f9; + border:solid #ccc; + border-width:0 0 1px 1px; + padding:5px; +} +.jodit_search .jodit_search_box input{ + margin:0; + width:100%; + height:100%; + border:0; + background-color:transparent; + outline:none; + padding:0 10px; +} +.jodit_search .jodit_search_box input.jodit_search-replace{ + display:none; +} +.jodit_search .jodit_search_box .jodit_search_buttons,.jodit_search .jodit_search_box .jodit_search_counts,.jodit_search .jodit_search_box .jodit_search_inputs{ + height:30px; + display:inline-block; + vertical-align:top; +} +.jodit_search .jodit_search_box .jodit_search_inputs{ + width:60%; + padding-right:5px; +} +.jodit_search .jodit_search_box .jodit_search_counts{ + width:15%; + line-height:100%; + text-align:center; + color:#ccc; + border-left:1px solid #ccc; +} +.jodit_search .jodit_search_box .jodit_search_counts:before{ + content:""; + display:inline-block; + vertical-align:middle; + height:100%; +} +.jodit_search .jodit_search_box .jodit_search_counts span{ + display:inline-block; + vertical-align:middle; +} +.jodit_search .jodit_search_box .jodit_search_buttons{ + padding-left:0; + width:25%; +} +.jodit_search .jodit_search_box .jodit_search_buttons button{ + outline:0; + width:32%; + padding:1px 5px; + margin-right:1%; + transition:transform .1s linear; + height:100%; + border:1px solid transparent; + background-color:transparent; +} +.jodit_search .jodit_search_box .jodit_search_buttons button.jodit_search_buttons-replace{ + width:100%; + border:1px solid #ccc; + margin-top:2px; + display:none; +} +.jodit_search .jodit_search_box .jodit_search_buttons button:hover{ + background-color:#ecebe9; +} +.jodit_search .jodit_search_box .jodit_search_buttons button:focus{ + border:1px solid rgba(181, 214, 253, .5); +} +.jodit_search .jodit_search_box .jodit_search_buttons button:active{ + border:1px solid #b5d6fd; + transform:scale(.95); +} +.jodit_search.jodit_search-and-replace .jodit_search_counts,.jodit_search.jodit_search-and-replace .jodit_search_inputs{ + height:60px; +} +.jodit_search.jodit_search-and-replace .jodit_search_counts input,.jodit_search.jodit_search-and-replace .jodit_search_inputs input{ + height:50%; + transition:background-color .1s linear; +} +.jodit_search.jodit_search-and-replace .jodit_search_counts input:focus,.jodit_search.jodit_search-and-replace .jodit_search_inputs input:focus{ + box-shadow:inset 0 0 3px 0 hsla(0, 0%, 80%, .58); +} +.jodit_search.jodit_search-and-replace .jodit_search_buttons button.jodit_search_buttons-replace,.jodit_search.jodit_search-and-replace .jodit_search_inputs input.jodit_search-replace{ + display:block; +} +@media (max-width:320px){ + .jodit_search,.jodit_search .jodit_search_box{ + width:100%; + } +} +.jodit_symbols{ + width:460px; + padding:10px; +} +.jodit_symbols .jodit_symbols-container_preview,.jodit_symbols .jodit_symbols-container_table{ + display:inline-block; + vertical-align:top; +} +.jodit_symbols .jodit_symbols-container_table{ + width:88%; +} +.jodit_symbols .jodit_symbols-container_preview{ + width:12%; +} +.jodit_symbols .jodit_symbols-container_preview .jodit_symbols-preview{ + font-size:34px; + text-align:center; + padding:20px 0; + border:1px solid #ccc; +} +.jodit_symbols table{ + border:0; + border-spacing:0; + table-layout:fixed; +} +.jodit_symbols table td{ + padding:0; +} +.jodit_symbols table td a{ + font-size:16px; + text-decoration:none; + color:#000; + display:inline-block; + box-sizing:border-box; + width:21.6px; + height:21.6px; + border:1px solid transparent; + text-align:center; + line-height:21.6px; + vertical-align:top; +} +.jodit_symbols table td a:focus,.jodit_symbols table td a:hover{ + border:1px solid #1e88e5; +} +.jodit_sticky-dummy_toolbar{ + display:none; +} +.jodit_sticky>.jodit_toolbar_container{ + position:fixed; + position:-webkit-sticky; + position:sticky; + z-index:3; + top:0; + left:auto; +} +.jodit_sticky .jodit_sticky-dummy_toolbar{ + display:block; +} +.jodit_paste_storage{ + padding:10px; + max-width:600px; +} +@media (max-width:768px){ + .jodit_paste_storage{ + max-width:100%; + } +} +.jodit_paste_storage>div{ + max-width:100%; + max-height:300px; + border:1px solid #ccc; +} +.jodit_paste_storage>div:first-child{ + margin-bottom:10px; +} +.jodit_paste_storage>div:first-child a{ + outline:none; + box-sizing:border-box; + display:block; + max-width:100%; + white-space:pre; + overflow:hidden; + text-overflow:ellipsis; + padding:5px; + margin:0; + border:1px solid transparent; + text-decoration:none; + color:#000; +} +.jodit_paste_storage>div:first-child a.jodit_active{ + color:#fff; + background-color:#575757; +} +.jodit_paste_storage>div:first-child a:focus{ + outline:none; +} +.jodit_paste_storage>div:last-child{ + padding:10px; + overflow:auto; +} +.jodit_paste_storage>div:last-child li,.jodit_paste_storage>div:last-child ul{ + margin:0; +} +.jodit,.jodit *,.jodit_container,.jodit_container *{ + box-sizing:border-box; +} +.jodit .jodit_workplace,.jodit_container .jodit_workplace{ + position:relative; + overflow:auto; +} +.jodit .jodit_workplace .jodit_wysiwyg,.jodit .jodit_workplace .jodit_wysiwyg_iframe,.jodit_container .jodit_workplace .jodit_wysiwyg,.jodit_container .jodit_workplace .jodit_wysiwyg_iframe{ + height:100%; + width:100%; +} +.jodit_container:not(.jodit_inline){ + font-family:Helvetica,sans-serif,Arial; + font-size:14px; + background:#fff; +} +.jodit_container:not(.jodit_inline).jodit_disabled{ + background:hsla(0, 0%, 88.2%, .99); +} +.jodit_container:not(.jodit_inline).jodit_disabled .jodit_workplace{ + opacity:.4; +} +.jodit_container:not(.jodit_inline) .jodit_workplace{ + border:1px solid #ccc; +} +.jodit_disabled{ + -webkit-user-select:none !important; + -moz-user-select:none !important; + -ms-user-select:none !important; + user-select:none !important; +} +.jodit_hidden{ + display:none !important; +} +.jodit_vertical_middle{ + display:-ms-flexbox; + display:flex; + -ms-flex-align:center; + align-items:center; +} +.jodit_button,.jodit_status_default{ + background-color:#d8d8d8; + color:#212529; +} +.jodit_button svg,.jodit_status_default svg{ + fill:#212529; + stroke:#212529; +} +.jodit_button:hover,.jodit_status_default:hover{ + background-color:#c9cdd1; + color:#212529; +} +.jodit_button:hover svg,.jodit_status_default:hover svg{ + fill:#212529; + stroke:#212529; +} +.jodit_button:active,.jodit_status_default:active{ + background-color:#dae0e5; + color:#212529; +} +.jodit_button:active svg,.jodit_status_default:active svg{ + fill:#212529; + stroke:#212529; +} +.jodit_button_primary,.jodit_status_primary{ + background-color:#007bff; + color:#fff; +} +.jodit_button_primary svg,.jodit_status_primary svg{ + fill:#fff; + stroke:#fff; +} +.jodit_button_primary:hover,.jodit_status_primary:hover{ + background-color:#0069d9; + color:#fff; +} +.jodit_button_primary:hover svg,.jodit_status_primary:hover svg{ + fill:#fff; + stroke:#fff; +} +.jodit_button_primary:active,.jodit_status_primary:active{ + background-color:#0062cc; + color:#fff; +} +.jodit_button_primary:active svg,.jodit_status_primary:active svg{ + fill:#fff; + stroke:#fff; +} +.jodit_button_success,.jodit_status_success{ + background-color:#28a745; + color:#fff; +} +.jodit_button_success svg,.jodit_status_success svg{ + fill:#fff; + stroke:#fff; +} +.jodit_button_success:hover,.jodit_status_success:hover{ + background-color:#218838; + color:#fff; +} +.jodit_button_success:hover svg,.jodit_status_success:hover svg{ + fill:#fff; + stroke:#fff; +} +.jodit_button_success:active,.jodit_status_success:active{ + background-color:#1e7e34; + color:#fff; +} +.jodit_button_success:active svg,.jodit_status_success:active svg{ + fill:#fff; + stroke:#fff; +} +.jodit_button_danger,.jodit_status_danger{ + background-color:#dc3545; + color:#fff; +} +.jodit_button_danger svg,.jodit_status_danger svg{ + fill:#fff; + stroke:#fff; +} +.jodit_button_danger:hover,.jodit_status_danger:hover{ + background-color:#c82333; + color:#fff; +} +.jodit_button_danger:hover svg,.jodit_status_danger:hover svg{ + fill:#fff; + stroke:#fff; +} +.jodit_button_danger:active,.jodit_status_danger:active{ + background-color:#bd2130; + color:#fff; +} +.jodit_button_danger:active svg,.jodit_status_danger:active svg{ + fill:#fff; + stroke:#fff; +} +.jodit_dark_theme.jodit_container,.jodit_dark_theme.jodit_container.jodit_disabled,.jodit_dark_theme .jodit_toolbar_list>.jodit_toolbar{ + background-color:#575757; +} +.jodit_dark_theme .jodit_statusbar,.jodit_dark_theme .jodit_workplace{ + border-color:rgba(87, 87, 87, .8); +} +.jodit_dark_theme .jodit_statusbar{ + background-color:rgba(95, 92, 92, .8); +} +.jodit_dark_theme .jodit_statusbar,.jodit_dark_theme .jodit_statusbar .jodit_statusbar_item span{ + color:#d1cccc; +} +.jodit_dark_theme .jodit_toolbar_popup,.jodit_dark_theme .jodit_toolbar_popup-inline,.jodit_dark_theme .jodit_toolbar_popup-inline:before,.jodit_dark_theme .jodit_toolbar_popup:before{ + background:#575757; +} +.jodit_dark_theme .jodit_toolbar{ + background:#5f5c5c; + border-color:rgba(87, 87, 87, .8); +} +.jodit_dark_theme .jodit_toolbar li.jodit_toolbar_btn>a{ + color:#d1cccc; +} +.jodit_dark_theme .jodit_toolbar li.jodit_toolbar_btn>a:hover{ + background-color:#575757; +} +.jodit_dark_theme .jodit_toolbar li.jodit_toolbar_btn.jodit_toolbar_btn-break{ + border-top-color:#686767; +} +.jodit_dark_theme .jodit_toolbar li.jodit_toolbar_btn.jodit_toolbar_btn-separator{ + border-right-color:#686767; +} +.jodit_dark_theme .jodit_toolbar li.jodit_toolbar_btn.active,.jodit_dark_theme .jodit_toolbar li.jodit_toolbar_btn.jodit_active,.jodit_dark_theme .jodit_toolbar li.jodit_toolbar_btn:active,.jodit_dark_theme .jodit_toolbar li.jodit_toolbar_btn:hover{ + background-color:#575757; +} +.jodit_dark_theme .jodit_icon,.jodit_dark_theme .jodit_toolbar li.jodit_toolbar_btn.jodit_with_dropdownlist .jodit_with_dropdownlist-trigger{ + fill:silver; +} +.jodit_dark_theme .jodit_wysiwyg,.jodit_dark_theme .jodit_wysiwyg_iframe{ + background-color:#575757; + color:#d1cccc; +} +.jodit_dark_theme .jodit_wysiwyg [data-jodit-selected-cell],.jodit_dark_theme .jodit_wysiwyg_iframe [data-jodit-selected-cell]{ + border-color:#152f5f; +} +.jodit_dark_theme .jodit_dropdownlist{ + background:#5f5c5c; +} +.jodit_dark_theme .jodit_tabs .jodit_tabs_buttons>a{ + background-color:#686767; + color:#d1cccc; +} +.jodit_dark_theme .jodit_tabs .jodit_tabs_buttons>a:hover{ + background-color:rgba(104, 103, 103, .8); + color:#d1cccc; + border-color:rgba(104, 103, 103, .9); +} +.jodit_dark_theme .jodit_tabs .jodit_tabs_buttons>a.active{ + background:rgba(81, 81, 81, .41); + border-color:#686767; +} +.jodit_dark_theme .jodit_tabs .jodit_tabs_buttons>a svg{ + fill:silver; +} +.jodit_dark_theme .jodit_form input[type=text],.jodit_dark_theme .jodit_form input[type=url],.jodit_dark_theme .jodit_form textarea{ + background-color:rgba(81, 81, 81, .41); + border-color:#686767; + color:#d1cccc; +} +.jodit_dark_theme .jodit_form button{ + background-color:rgba(104, 103, 103, .75); + color:#d1cccc; +} +.jodit_dark_theme .jodit_placeholder{ + color:hsla(0, 5.2%, 81%, .8); +} +.jodit_dark_theme .jodit_draganddrop_file_box,.jodit_dark_theme .jodit_uploadfile_button{ + color:#d1cccc; +} +.jodit_dark_theme .jodit_draganddrop_file_box:hover,.jodit_dark_theme .jodit_uploadfile_button:hover{ + background-color:rgba(104, 103, 103, .75); +} +.jodit_dark_theme .jodit-add-new-line:before{ + border-top-color:#686767; +} +.jodit_dark_theme .jodit-add-new-line span{ + background:rgba(104, 103, 103, .75); + border-color:#686767; +} +.jodit_dark_theme .jodit-add-new-line span svg{ + fill:#d1cccc; +} +.jodit_dark_theme .jodit_resizer>i{ + background:rgba(104, 103, 103, .75); + border-color:silver; +} + diff --git a/build/jodit.es2018.js b/build/jodit.es2018.js new file mode 100644 index 000000000..6a09921c8 --- /dev/null +++ b/build/jodit.es2018.js @@ -0,0 +1,19380 @@ +/*! + jodit - Jodit is awesome and usefully wysiwyg editor with filebrowser + Author: Chupurnov (https://xdsoft.net/) + Version: v3.3.8 + Url: https://xdsoft.net/jodit/ + License(s): GPL-2.0-or-later OR MIT OR Commercial +*/ + +(function webpackUniversalModuleDefinition(root, factory) { + if(typeof exports === 'object' && typeof module === 'object') + module.exports = factory(); + else if(typeof define === 'function' && define.amd) + define([], factory); + else { + var a = factory(); + for(var i in a) (typeof exports === 'object' ? exports : root)[i] = a[i]; + } +})(window, function() { +return /******/ (function(modules) { // webpackBootstrap +/******/ // The module cache +/******/ var installedModules = {}; +/******/ +/******/ // The require function +/******/ function __webpack_require__(moduleId) { +/******/ +/******/ // Check if module is in cache +/******/ if(installedModules[moduleId]) { +/******/ return installedModules[moduleId].exports; +/******/ } +/******/ // Create a new module (and put it into the cache) +/******/ var module = installedModules[moduleId] = { +/******/ i: moduleId, +/******/ l: false, +/******/ exports: {} +/******/ }; +/******/ +/******/ // Execute the module function +/******/ modules[moduleId].call(module.exports, module, module.exports, __webpack_require__); +/******/ +/******/ // Flag the module as loaded +/******/ module.l = true; +/******/ +/******/ // Return the exports of the module +/******/ return module.exports; +/******/ } +/******/ +/******/ +/******/ // expose the modules object (__webpack_modules__) +/******/ __webpack_require__.m = modules; +/******/ +/******/ // expose the module cache +/******/ __webpack_require__.c = installedModules; +/******/ +/******/ // define getter function for harmony exports +/******/ __webpack_require__.d = function(exports, name, getter) { +/******/ if(!__webpack_require__.o(exports, name)) { +/******/ Object.defineProperty(exports, name, { enumerable: true, get: getter }); +/******/ } +/******/ }; +/******/ +/******/ // define __esModule on exports +/******/ __webpack_require__.r = function(exports) { +/******/ if(typeof Symbol !== 'undefined' && Symbol.toStringTag) { +/******/ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' }); +/******/ } +/******/ Object.defineProperty(exports, '__esModule', { value: true }); +/******/ }; +/******/ +/******/ // create a fake namespace object +/******/ // mode & 1: value is a module id, require it +/******/ // mode & 2: merge all properties of value into the ns +/******/ // mode & 4: return value when already ns object +/******/ // mode & 8|1: behave like require +/******/ __webpack_require__.t = function(value, mode) { +/******/ if(mode & 1) value = __webpack_require__(value); +/******/ if(mode & 8) return value; +/******/ if((mode & 4) && typeof value === 'object' && value && value.__esModule) return value; +/******/ var ns = Object.create(null); +/******/ __webpack_require__.r(ns); +/******/ Object.defineProperty(ns, 'default', { enumerable: true, value: value }); +/******/ if(mode & 2 && typeof value != 'string') for(var key in value) __webpack_require__.d(ns, key, function(key) { return value[key]; }.bind(null, key)); +/******/ return ns; +/******/ }; +/******/ +/******/ // getDefaultExport function for compatibility with non-harmony modules +/******/ __webpack_require__.n = function(module) { +/******/ var getter = module && module.__esModule ? +/******/ function getDefault() { return module['default']; } : +/******/ function getModuleExports() { return module; }; +/******/ __webpack_require__.d(getter, 'a', getter); +/******/ return getter; +/******/ }; +/******/ +/******/ // Object.prototype.hasOwnProperty.call +/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); }; +/******/ +/******/ // __webpack_public_path__ +/******/ __webpack_require__.p = "/build/"; +/******/ +/******/ +/******/ // Load entry module and return exports +/******/ return __webpack_require__(__webpack_require__.s = 95); +/******/ }) +/************************************************************************/ +/******/ ([ +/* 0 */ +/***/ (function(module, exports) { + +module.exports.default = ["Type something","About Jodit","Jodit Editor","Free Non-commercial Version","GNU General Public License, version 2 or later","Jodit User's Guide","contains detailed help for using","For information about the license, please go to our website:","Buy full version","Copyright © XDSoft.net - Chupurnov Valeriy. All rights reserved.","Anchor","Open in new tab","Open editor in fullsize","Clear Formatting","Fill color or set the text color","Redo","Undo","Bold","Italic","Insert Unordered List","Insert Ordered List","Align Center","Align Justify","Align Left","Align Right","Insert Horizontal Line","Insert Image","Insert file","Insert youtube/vimeo video","Insert link","Font size","Font family","Insert format block","Normal","Heading 1","Heading 2","Heading 3","Heading 4","Quote","Code","Insert","Insert table","Decrease Indent","Increase Indent","Select Special Character","Insert Special Character","Paint format","Change mode","Margins","top","right","bottom","left","Styles","Classes","Align","Right","Center","Left","--Not Set--","Src","Title","Alternative","Link","Open link in new tab","Image","file","Advanced","Image properties","Cancel","Ok","File Browser","Error on load list","Error on load folders","Are you sure?","Enter Directory name","Create directory","type name","Drop image","Drop file","or click","Alternative text","Upload","Browse","Background","Text","Top","Middle","Bottom","Insert column before","Insert column after","Insert row above","Insert row below","Delete table","Delete row","Delete column","Empty cell","Chars: %d","Words: %d","Strike through","Underline","superscript","subscript","Cut selection","Select all","Break","Search for","Replace with","Replace","Paste","Choose Content to Paste","source","bold","italic","brush","link","undo","redo","table","image","eraser","paragraph","fontsize","video","font","about","print","symbol","underline","strikethrough","indent","outdent","fullsize","shrink","copyformat","hr","ul","ol","cut","selectall","Embed code","Open link","Edit link","No follow","Unlink","Update","pencil","Eye"," URL","Edit","Horizontal align","Filter","Sort by changed","Sort by name","Sort by size","Add folder","Reset","Save","Save as ...","Resize","Crop","Width","Height","Keep Aspect Ratio","Yes","No","Remove","Select","Select %s","Vertical align","Split","Merge","Add column","Add row","License: %s","Delete","Split vertical","Split horizontal","Border","Your code is similar to HTML. Keep as HTML?","Paste as HTML","Keep","Insert as Text","Insert only Text","You can only edit your own images. Download this image on the host?","The image has been successfully uploaded to the host!","palette","There are no files","rename","Enter new name","preview","download","Paste from clipboard","Your browser doesn't support direct access to the clipboard.","Copy selection","copy","Border radius"] + +/***/ }), +/* 1 */ +/***/ (function(module, exports) { + +module.exports = " " + +/***/ }), +/* 2 */ +/***/ (function(module, exports) { + +module.exports = " " + +/***/ }), +/* 3 */ +/***/ (function(module, exports) { + +module.exports = " " + +/***/ }), +/* 4 */ +/***/ (function(module, exports) { + +module.exports = " " + +/***/ }), +/* 5 */ +/***/ (function(module, exports) { + +module.exports = "" + +/***/ }), +/* 6 */ +/***/ (function(module, exports) { + +module.exports = "" + +/***/ }), +/* 7 */ +/***/ (function(module, exports) { + +module.exports = "" + +/***/ }), +/* 8 */ +/***/ (function(module, exports) { + +module.exports = "" + +/***/ }), +/* 9 */ +/***/ (function(module, exports) { + +module.exports = "" + +/***/ }), +/* 10 */ +/***/ (function(module, exports) { + +module.exports = "" + +/***/ }), +/* 11 */ +/***/ (function(module, exports) { + +module.exports = "" + +/***/ }), +/* 12 */ +/***/ (function(module, exports) { + +module.exports = "" + +/***/ }), +/* 13 */ +/***/ (function(module, exports) { + +module.exports = "" + +/***/ }), +/* 14 */ +/***/ (function(module, exports) { + +module.exports = " " + +/***/ }), +/* 15 */ +/***/ (function(module, exports) { + +module.exports = "" + +/***/ }), +/* 16 */ +/***/ (function(module, exports) { + +module.exports = "" + +/***/ }), +/* 17 */ +/***/ (function(module, exports) { + +module.exports = "" + +/***/ }), +/* 18 */ +/***/ (function(module, exports) { + +module.exports = "" + +/***/ }), +/* 19 */ +/***/ (function(module, exports) { + +module.exports = " " + +/***/ }), +/* 20 */ +/***/ (function(module, exports) { + +module.exports = " " + +/***/ }), +/* 21 */ +/***/ (function(module, exports) { + +module.exports = " " + +/***/ }), +/* 22 */ +/***/ (function(module, exports) { + +module.exports = " " + +/***/ }), +/* 23 */ +/***/ (function(module, exports) { + +module.exports = "" + +/***/ }), +/* 24 */ +/***/ (function(module, exports) { + +module.exports = " " + +/***/ }), +/* 25 */ +/***/ (function(module, exports) { + +module.exports = " " + +/***/ }), +/* 26 */ +/***/ (function(module, exports) { + +module.exports = " " + +/***/ }), +/* 27 */ +/***/ (function(module, exports) { + +module.exports = "" + +/***/ }), +/* 28 */ +/***/ (function(module, exports) { + +module.exports = "" + +/***/ }), +/* 29 */ +/***/ (function(module, exports) { + +module.exports = " " + +/***/ }), +/* 30 */ +/***/ (function(module, exports) { + +module.exports = " " + +/***/ }), +/* 31 */ +/***/ (function(module, exports) { + +module.exports = "" + +/***/ }), +/* 32 */ +/***/ (function(module, exports) { + +module.exports = "" + +/***/ }), +/* 33 */ +/***/ (function(module, exports) { + +module.exports = " " + +/***/ }), +/* 34 */ +/***/ (function(module, exports) { + +module.exports = "" + +/***/ }), +/* 35 */ +/***/ (function(module, exports) { + +module.exports = "" + +/***/ }), +/* 36 */ +/***/ (function(module, exports) { + +module.exports = " " + +/***/ }), +/* 37 */ +/***/ (function(module, exports) { + +module.exports = "" + +/***/ }), +/* 38 */ +/***/ (function(module, exports) { + +module.exports = "" + +/***/ }), +/* 39 */ +/***/ (function(module, exports) { + +module.exports = "" + +/***/ }), +/* 40 */ +/***/ (function(module, exports) { + +module.exports = "" + +/***/ }), +/* 41 */ +/***/ (function(module, exports) { + +module.exports = "" + +/***/ }), +/* 42 */ +/***/ (function(module, exports) { + +module.exports = "" + +/***/ }), +/* 43 */ +/***/ (function(module, exports) { + +module.exports = "" + +/***/ }), +/* 44 */ +/***/ (function(module, exports) { + +module.exports = " " + +/***/ }), +/* 45 */ +/***/ (function(module, exports) { + +module.exports = " " + +/***/ }), +/* 46 */ +/***/ (function(module, exports) { + +module.exports = " " + +/***/ }), +/* 47 */ +/***/ (function(module, exports) { + +module.exports = " " + +/***/ }), +/* 48 */ +/***/ (function(module, exports) { + +module.exports = " " + +/***/ }), +/* 49 */ +/***/ (function(module, exports) { + +module.exports = "" + +/***/ }), +/* 50 */ +/***/ (function(module, exports) { + +module.exports = " " + +/***/ }), +/* 51 */ +/***/ (function(module, exports) { + +module.exports = "" + +/***/ }), +/* 52 */ +/***/ (function(module, exports) { + +module.exports = "" + +/***/ }), +/* 53 */ +/***/ (function(module, exports) { + +module.exports = " " + +/***/ }), +/* 54 */ +/***/ (function(module, exports) { + +module.exports = " " + +/***/ }), +/* 55 */ +/***/ (function(module, exports) { + +module.exports = " " + +/***/ }), +/* 56 */ +/***/ (function(module, exports) { + +module.exports = " " + +/***/ }), +/* 57 */ +/***/ (function(module, exports) { + +module.exports = " " + +/***/ }), +/* 58 */ +/***/ (function(module, exports) { + +module.exports = " " + +/***/ }), +/* 59 */ +/***/ (function(module, exports) { + +module.exports = " " + +/***/ }), +/* 60 */ +/***/ (function(module, exports) { + +module.exports = " " + +/***/ }), +/* 61 */ +/***/ (function(module, exports) { + +module.exports = " " + +/***/ }), +/* 62 */ +/***/ (function(module, exports) { + +module.exports = " " + +/***/ }), +/* 63 */ +/***/ (function(module, exports) { + +module.exports = " " + +/***/ }), +/* 64 */ +/***/ (function(module, exports) { + +module.exports = "" + +/***/ }), +/* 65 */ +/***/ (function(module, exports) { + +module.exports = " " + +/***/ }), +/* 66 */ +/***/ (function(module, exports) { + +module.exports = " " + +/***/ }), +/* 67 */ +/***/ (function(module, exports) { + +module.exports = "" + +/***/ }), +/* 68 */ +/***/ (function(module, exports) { + +module.exports = "" + +/***/ }), +/* 69 */ +/***/ (function(module, exports) { + +module.exports = "" + +/***/ }), +/* 70 */ +/***/ (function(module, exports) { + +module.exports = "" + +/***/ }), +/* 71 */ +/***/ (function(module, exports) { + +module.exports = "" + +/***/ }), +/* 72 */ +/***/ (function(module, exports) { + +module.exports = "" + +/***/ }), +/* 73 */ +/***/ (function(module, exports) { + +module.exports = "" + +/***/ }), +/* 74 */ +/***/ (function(module, exports) { + +module.exports = "" + +/***/ }), +/* 75 */ +/***/ (function(module, exports) { + +module.exports = "" + +/***/ }), +/* 76 */ +/***/ (function(module, exports) { + +module.exports = "" + +/***/ }), +/* 77 */ +/***/ (function(module, exports) { + +module.exports = "" + +/***/ }), +/* 78 */ +/***/ (function(module, exports) { + +module.exports = "" + +/***/ }), +/* 79 */ +/***/ (function(module, exports) { + +module.exports.default = ["إبدأ في الكتابة...","حول جوديت","محرر جوديت","الإصدار الغير تجاري مجاني","رخصة جنو العمومية العامة ، الإصدار الثاني أو الأحدث","دليل مستخدم جوديت","يحتوي على مساعدة مفصلة للاستخدام","للحصول على معلومات حول الترخيص، يرجى الذهاب لموقعنا:","شراء النسخة الكاملة","حقوق الطبع والنشر © XDSoft.net - Chupurnov Valeriy. كل الحقوق محفوظة.","مِرْساة","فتح في نافذة جديدة","فتح المحرر في الحجم الكامل","مسح التنسيق","ملء اللون أو تعيين لون النص","إعادة","تراجع","عريض","مائل","إدراج قائمة غير مرتبة","إدراج قائمة مرتبة","محاذاة للوسط","محاذاة مثبتة","محاذاة لليسار","محاذاة لليمين","إدراج خط أفقي","إدراج صورة","ادخال الملف","إدراج فيديو يوتيوب/فيميو ","إدراج رابط","حجم الخط","نوع الخط","إدراج كتلة تنسيق","عادي","عنوان 1","عنوان 2","عنوان 3","عنوان 4","إقتباس","كود","إدراج","إدراج جدول","تقليل المسافة البادئة","زيادة المسافة البادئة","تحديد أحرف خاصة","إدراج حرف خاص","تنسيق الرسم","تغيير الوضع","هوامش","أعلى","يمين","أسفل","يسار","الأنماط","الطبقات","محاذاة","اليمين","الوسط","اليسار","--غير مضبوط--","Src","العنوان","العنوان البديل","الرابط","افتح الرابط في نافذة جديدة","الصورة","ملف","متقدم","خصائص الصورة","إلغاء","حسنا","متصفح الملفات","حدث خطأ في تحميل القائمة ","حدث خطأ في تحميل المجلدات","هل أنت واثق؟","أدخل اسم المجلد","إنشاء مجلد","أكتب إسم","إسقاط صورة","إسقاط الملف","أو أنقر","النص البديل","رفع","تصفح","الخلفية","نص","أعلى","الوسط","الأسفل","إدراج عمود قبل","إدراج عمود بعد","إدراج صف أعلى","إدراج صف أسفل","حذف الجدول","حذف الصف","حذف العمود","خلية فارغة","%d حرف","%d كلام","اضرب من خلال","أكد","حرف فوقي","مخطوطة","قطع الاختيار","اختر الكل","استراحة","البحث عن","استبدل ب","يحل محل","معجون","اختر محتوى للصق","مصدر","بالخط العريض","مائل","شغل","صلة","إلغاء","كرر","طاولة","صورة","نظيف","فقرة","حجم الخط","فيديو","الخط","حول المحرر","طباعة","رمز","أكد","شطب","المسافة البادئة","نتوء","ملء الشاشة","الحجم التقليدي","نسخ التنسيق","الخط","قائمة","قائمة مرقمة","قطع","اختر الكل","قانون","فتح الرابط","تعديل الرابط","سمة Nofollow","إزالة الرابط","تحديث","لتحرير","مراجعة","URL","تحرير","محاذاة أفقية","فلتر","عن طريق التغيير","بالاسم","حسب الحجم","إضافة مجلد","إعادة","احتفظ","حفظ باسم","تغيير الحجم","حجم القطع","عرض","ارتفاع","حافظ على النسب","أن","لا","حذف","تميز","تميز %s","محاذاة عمودية","انشق، مزق","اذهب","أضف العمود","اضف سطر","رخصة %s","حذف","انقسام عمودي","تقسيم أفقي","الحدود","يشبه الكود الخاص بك HTML. تبقي كما HTML؟","الصق ك HTML","احتفظ","إدراج كنص","إدراج النص فقط","يمكنك فقط تحرير صورك الخاصة. تحميل هذه الصورة على المضيف؟","تم تحميل الصورة بنجاح على الخادم!","لوحة","لا توجد ملفات في هذا الدليل.","إعادة تسمية","أدخل اسم جديد","معاينة","تحميل","لصق من الحافظة","متصفحك لا يدعم إمكانية الوصول المباشر إلى الحافظة.","نسخ التحديد","نسخ","دائرة نصف قطرها الحدود"] + +/***/ }), +/* 80 */ +/***/ (function(module, exports) { + +module.exports.default = ["Napiš něco","O Jodit","Editor Jodit","Verze pro nekomerční použití","Licence GNU (GPL), verze 2 nebo vyšší","Jodit Uživatelská příručka","obsahuje detailní nápovědu","Pro informace o licenci, prosím, přejděte na naši stránku:","Koupit plnou verzi","Copyright © XDSoft.net - Chupurnov Valeriy. Všechna práva vyhrazena.","Anchor","Otevřít v nové záložce","Otevřít v celoobrazovkovém režimu","Vyčistit formátování","Barva výplně a písma","Vpřed","Zpět","Tučné","Kurzíva","Odrážky","Číslovaný seznam","Zarovnat na střed","Zarovnat do bloku","Zarovnat vlevo","Zarovnat vpravo","Vložit horizontální linku","Vložit obrázek","Vložit soubor","Vložit video (YT/Vimeo)","Vložit odkaz","Velikost písma","Typ písma","Formátovat blok","Normální text","Nadpis 1","Nadpis 2","Nadpis 3","Nadpis 4","Citát","Kód","Vložit","Vložit tabulku","Zmenšit odsazení","Zvětšit odsazení","Vybrat speciální symbol","Vložit speciální symbol","Použít formát","Změnit mód","Okraje","horní","pravý","spodní","levý","Styly","Třídy","Zarovnání","Vpravo","Na střed","Vlevo","--nenastaveno--","src","Titulek","Alternativní text (alt)","Link","Otevřít link v nové záložce","Obrázek","soubor","Rozšířené","Vlastnosti obrázku","Zpět","Ok","Prohlížeč souborů","Chyba při načítání seznamu souborů","Chyba při načítání složek","Jste si jistý(á)?","Název složky","Vytvořit složku","název","Přetáhněte sem obrázek","Přetáhněte sem soubor","nebo klikněte","Alternativní text","Nahrát","Server","Pozadí","Text","Nahoru","Na střed","Dolu","Vložit sloupec před","Vložit sloupec za","Vložit řádek nad","Vložit řádek pod","Vymazat tabulku","Vymazat řádku","Vymazat sloupec","Vyčistit buňku","Znaky: %d","Slova: %d","Přeškrtnuto","Podtrženo","Horní index","Dolní index","Vyjmout označené","Označit vše","Zalomení","Najdi","Nahradit za","Nahradit","Vložit","Vyber obsah pro vložení","HTML","tučně","kurzíva","štětec","odkaz","zpět","vpřed","tabulka","obrázek","guma","odstavec","velikost písma","video","písmo","о editoru","tisk","symbol","podtrženo","přeškrtnuto","zvětšit odsazení","zmenšit odsazení","celoobrazovkový režim","smrsknout","Kopírovat formát","Linka","Odrážka","Číslovaný seznam","Vyjmout","Označit vše","Kód","Otevřít odkaz","Upravit odkaz","Atribut no-follow","Odstranit odkaz","Aktualizovat","Chcete-li upravit","Zobrazit","URL","Editovat","Horizontální zarovnání","Filtr","Dle poslední změny","Dle názvu","Dle velikosti","Přidat složku","Reset","Uložit","Uložit jako...","Změnit rozměr","Ořezat","Šířka","Výška","Ponechat poměr","Ano","Ne","Vyjmout","Označit","Označit %s","Vertikální zarovnání","Rozdělit","Spojit","Přidat sloupec","Přidat řádek","Licence: %s","Vymazat","Rozdělit vertikálně","Rozdělit horizontálně","Okraj","Váš text se podobá HTML. Vložit ho jako HTML?","Vložit jako HTML","Ponechat originál","Vložit jako TEXT","Vložit pouze TEXT","Můžete upravovat pouze své obrázky. Načíst obrázek?","Obrázek byl úspěšně nahrán!","paleta","V tomto adresáři nejsou žádné soubory.","přejmenovat","Zadejte nový název","náhled","Stažení","Vložit ze schránky","Váš prohlížeč nepodporuje přímý přístup do schránky.","Kopírovat výběr","kopírování","Border radius"] + +/***/ }), +/* 81 */ +/***/ (function(module, exports) { + +module.exports.default = ["Bitte geben Sie einen Text ein","Über Jodit","Jodit Editor","Freie Nicht-kommerzielle Version","GNU General Public License, Version 2 oder höher","Das Jodit Benutzerhandbuch","beinhaltet ausführliche Informationen wie Sie den Editor verwenden können.","Für Lizenz-Informationen, besuchen Sie bitte unsere Webseite:","Vollversion kaufen","Copyright © XDSoft.net - Chupurnov Valeriy. Alle Rechte vorbehalten.","Anker","In neuer Registerkarte öffnen","Editor in voller Größe öffnen","Formatierung löschen","Füllfarbe oder Textfarbe ändern","Wiederholen","Rückgängig machen","Fett","Kursiv","Ungeordnete Liste einfügen","Sortierte Liste einfügen","Mittig ausrichten","Blocksatz","Links ausrichten","Rechts ausrichten","Horizontale Linie einfügen","Bild einfügen","Datei einfügen","Youtube/vimeo Video einfügen","Link einfügen","Schriftgröße","Schriftfamilie","Formatblock einfügen","Normal","Überschrift 1","Überschrift 2","Überschrift 3","Überschrift 4","Zitat","Code","Einfügen","Tabelle einfügen","Einzug verkleinern","Einzug vergrößern","Sonderzeichen auswählen","Sonderzeichen einfügen","Format kopieren","Änderungsmodus","Ränder","Oben","Rechts","Unten","Links","CSS Stiel","CSS Klassen","Ausrichten","Rechts","Zentriert","Links","Keine","Pfad","Titel","Alternativer Text","Link","Link in neuem Tab öffnen","Bild","Datei","Fortgeschritten","Bildeigenschaften","Abbrechen","OK","Dateibrowser","Fehler beim Laden der Liste","Fehler beim Laden der Ordner","Sind Sie sicher?","Geben Sie den Verzeichnisnamen ein","Verzeichnis erstellen","Typname","Bild hier hinziehen","Datei löschen","oder hier klicken","Alternativtext","Hochladen","Auswählen","Hintergrund","Text","Oben","Mittig","Unten","Spalte einfügen vor","Spalte einfügen nach","Zeile einfügen oberhalb","Zeile unterhalb einfügen","Tabelle löschen","Zeile löschen","Spalte löschen","Leere Zelle","Zeichen: %d","Wörter: %d","Durchschlagen","Unterstreichen","hochgestellt","Index","Auswahl ausschneid","Wählen Sie Alle aus","Pause","Suche nach","Ersetzen durch","Ersetzen","Einfügen","Wählen Sie Inhalt zum Einfügen","HTML","Fett gedruckt","kursiv","Bürste","Verknüpfung","rückgängig machen","wiederholen","Tabelle","Bild","Radiergummi","Absatz","Schriftgröße","Video","Schriftart","Über","drucken","Symbol","unterstreichen","durchgestrichen","Einzug","Aussenseiter","Vollgröße","schrumpfen","Format kopierenт","die Linie","Liste von","Nummerierte Liste","Schnitt","Wählen Sie Alle aus","Code einbetten","Link öffnen","Link bearbeiten","Nofollow-Attribut","Link entfernen","Aktualisieren","Bearbeiten","Ansehen","URL","Bearbeiten","Horizontale Ausrichtung","filter","Sortieren nach geändert","Nach Name sortieren","Nach Größe sortiert","Ordner hinzufügen","Wiederherstellen","Speichern","Speichern als","Ändern Sie die Größe","Größe anpassen","Breite","Höhe","Halten Sie Proportionen","Ja","Nein","Entfernen","Markieren","Markieren: %s","Vertikale Ausrichtung","Split","Verschmelzen","Spalte hinzufügen","Zeile hinzufügen",null,"Löschen","Split vertikal","Split horizontally","Rand","Es scheint als dass Sie HTML-Text einfügen möchten","Als HTML einfügen?","Original speichern","Als Text einfügen","Nur Text einfügen","Sie können nur Ihre eigenen Bilder bearbeiten. Laden Sie dieses Bild auf dem Host herunter?","Das Bild wurde erfolgreich auf den Server hochgeladen!null","Palette","In diesem Verzeichnis befinden sich keine Dateien.","umbenennen","Geben Sie einen neuen Namen ein","Vorschau","Herunterladen","Aus der Zwischenablage einfügen","Ihr browser unterstützt kein direkter Zugriff auf die Zwischenablage.","Auswahl kopieren","kopieren","Border-radius"] + +/***/ }), +/* 82 */ +/***/ (function(module, exports) { + +module.exports.default = ["Escriba algo...","Acerca de Jodit","Jodit Editor","Versión gratis no comercial","GNU General Public License, Versión 2 o posterior","Guía de usuario Jodit","contiene ayuda detallada para el uso.","Para información sobre la licencia, por favor visite nuestro sitio:","Compre la versión completa","Copyright © XDSoft.net - Chupurnov Valeriy. Todos los derechos reservados.","Anclar","Abrir en nueva pestaña","Abrir editor en pantalla completa","Limpiar formato","Color de relleno o de letra","Rehacer","Deshacer","Negrita","Cursiva","Insertar lista no ordenada","Insertar lista ordenada","Alinear Centrado","Alinear Justificado","Alinear Izquierda","Alinear Derecha","Insertar línea horizontal","Insertar imagen","Insertar archivo","Insertar video de Youtube/vimeo","Insertar vínculo","Tamaño de letra","Familia de letra","Insertar bloque","Normal","Encabezado 1","Encabezado 2","Encabezado 3","Encabezado 4","Cita","Código","Insertar","Insertar tabla","Disminuir sangría","Aumentar sangría","Seleccionar caracter especial","Insertar caracter especial","Copiar formato","Cambiar modo","Márgenes","arriba","derecha","abajo","izquierda","Estilos CSS","Clases CSS","Alinear","Derecha","Centrado","Izquierda","--No Establecido--","Fuente","Título","Texto Alternativo","Vínculo","Abrir vínculo en nueva pestaña","Imagen","Archivo","Avanzado","Propiedades de imagen","Cancelar","Aceptar","Buscar archivo","Error al cargar la lista","Error al cargar las carpetas","¿Está seguro?","Entre nombre de carpeta","Crear carpeta","Entre el nombre","Soltar imagen","Soltar archivo","o click","Texto alternativo","Subir","Buscar","Fondo","Texto","Arriba","Centro","Abajo","Insertar columna antes","Interar columna después","Insertar fila arriba","Insertar fila debajo","Borrar tabla","Borrar fila","Borrar columna","Vaciar celda","Caracteres: %d","Palabras: %d","Tachado","Subrayado","superíndice","subíndice","Cortar selección","Seleccionar todo","Pausa","Buscar","Reemplazar con","Reemplazar","Pegar","Seleccionar contenido para pegar","HTML","negrita","cursiva","Brocha","Vínculo","deshacer","rehacer","Tabla","Imagen","Borrar","Párrafo","Tamaño de letra","Video","Letra","Acerca de","Imprimir","Símbolo","subrayar","tachar","sangría","quitar sangría","Tamaño completo","encoger","Copiar formato","línea horizontal","lista sin ordenar","lista ordenada","Cortar","Seleccionar todo","Incluir código","Abrir vínculo","Editar vínculo","No seguir","Desvincular","Actualizar","Para editar","Ver","URL","Editar","Alineación horizontal","filtrar","Ordenar por fecha modificación","Ordenar por nombre","Ordenar por tamaño","Agregar carpeta","Resetear","Guardar","Guardar como...","Redimensionar","Recortar","Ancho","Alto","Mantener relación de aspecto","Si","No","Quitar","Seleccionar","Seleccionar: %s","Alineación vertical","Dividir","Mezclar","Agregar columna","Agregar fila",null,"Borrar","Dividir vertical","Dividir horizontal","Borde","El código es similar a HTML. ¿Mantener como HTML?","Pegar como HTML?","Mantener","Insertar como texto","Insertar solo texto","Solo puedes editar tus propias imágenes. ¿Descargar esta imagen en el servidor?","¡La imagen se ha subido correctamente al servidor!","paleta","No hay archivos en este directorio.","renombrar","Ingresa un nuevo nombre","avance","Descargar","Pegar desde el portapapeles","Su navegador no soporta el acceso directo en el portapapeles.","Selección de copia","copia","Radio frontera"] + +/***/ }), +/* 83 */ +/***/ (function(module, exports) { + +module.exports.default = ["Ecrivez ici","A propos de Jodit","Editeur Jodit","Version gratuite, non commerciale","GNU General Public License, version 2 ou ultérieure","Guide de l'utilisateur","Aide détaillée à l'utilisation","Consulter la licence sur notre site web:","Acheter la version complète","Copyright © XDSoft.net - Chupurnov Valeriy. Tous droits réservés.","Ancre","Ouvrir dans un nouvel onglet","Ouvrir l'éditeur en pleine page","Supprimer le formattage","Modifier la couleur du fond ou du texte","Refaire","Défaire","Gras","Italique","Liste non ordonnée","Liste ordonnée","Centrer","Justifier","Aligner à gauche ","Aligner à droite","Insérer une ligne horizontale","Insérer une image","Insérer un fichier","Insérer une vidéo","Insérer un lien","Taille des caractères","Famille des caractères","Bloc formatté","Normal","Titre 1","Titre 2","Titre 3","Titre 4","Citation","Code","Insérer","Insérer un tableau","Diminuer le retrait","Retrait plus","Sélectionnez un caractère spécial","Insérer un caractère spécial","Cloner le format","Mode wysiwyg <-> code html","Marges","haut","droite","Bas","gauche","Styles","Classes","Alignement","Droite","Centre","Gauche","--Non disponible--","Source","Titre","Alternative","Lien","Ouvrir le lien dans un nouvel onglet","Image","fichier","Avancé","Propriétés de l'image","Effacer","OK","Explorateur de fichiers","Erreur de liste de chargement","Erreur de dossier de chargement","Etes-vous sûrs ?","Entrer le non de dossier","Créer un dossier","type de fichier","Coller une image","Déposer un fichier","ou cliquer","Texte de remplacemement","Charger","Chercher","Arrière-plan","Texte","Haut","Milieu","Bas","Insérer une colonne avant","Insérer une colonne après","Insérer une ligne en dessus","Insérer une ligne en dessous","Supprimer le tableau","Supprimer la ligne","Supprimer la colonne","Vider la cellule","Symboles: %d","Mots: %d","Frapper à travers","Souligner","exposant","indice","Couper la sélection","Tout sélectionner","Pause","Rechercher","Remplacer par","Remplacer","Coller","Choisissez le contenu à coller","la source","graisseux","italique","verser","lien","abolir","prêt","graphique","Image","la gommen","clause","taille de police","Video","police","à propos de l'éditeur","impression","caractère","souligné","barré","indentation","indifférent","taille réelle","taille conventionnelle","Format de copie","la ligne","Liste des","Liste numérotée","Couper","Sélectionner tout",null,"Ouvrir le lien","Modifier le lien","Attribut Nofollow","Supprimer le lien","Mettre à jour","Pour éditer","Voir","URL",null,"Alignement horizontal","Filtre","Trier par modifié","Trier par nom","Classer par taille","Ajouter le dossier","Restaurer","Sauvegarder","Enregistrer sous","Changer la taille","Taille de garniture","Largeur","Hauteur","Garder les proportions","Oui","Non","Supprimer","Mettre en évidence","Mettre en évidence: %s","Alignement vertical","Split","aller","Ajouter une colonne","Ajouter une rangée",null,"Effacer","Split vertical","Split horizontal",null,"Votre texte que vous essayez de coller est similaire au HTML. Collez-le en HTML?","Coller en HTML?","Sauvegarder l'original","Coller en tant que texte","Coller le texte seulement","Vous ne pouvez éditer que vos propres images. Téléchargez cette image sur l'hôte?","L'image a été téléchargée avec succès sur le serveur!null","Palette","Il n'y a aucun fichier dans ce répertoire.","renommer","Entrez un nouveau nom","Aperçu","Télécharger","Coller à partir du presse-papiers","Votre navigateur ne prend pas en charge l'accès direct à la presse-papiers.","Copier la sélection","copie","Rayon des frontières"] + +/***/ }), +/* 84 */ +/***/ (function(module, exports) { + +module.exports.default = ["הקלד משהו...","About Jodit","Jodit Editor","Free Non-commercial Version","GNU General Public License, version 2 or later","Jodit User's Guide","contains detailed help for using.","For information about the license, please go to our website:","Buy full version","Copyright © XDSoft.net - Chupurnov Valeriy. All rights reserved.","מקום עיגון","פתח בכרטיסיה חדשה","פתח את העורך בחלון חדש","נקה עיצוב","שנה צבע טקסט או רקע","בצע שוב","בטל","מודגש","נטוי","הכנס רשימת תבליטים","הכנס רשימה ממוספרת","מרכז","ישר ","ישר לשמאל","ישר לימין","הכנס קו אופקי","הכנס תמונה","הכנס קובץ","הכנס סרטון וידאו מYouTube/Vimeo","הכנס קישור","גודל גופן","גופן","מעוצב מראש","רגיל","כותרת 1","כותרת 2","כותרת 3","כותרת 4","ציטוט","קוד","הכנס","הכנס טבלה","הקטן כניסה","הגדל כניסה","בחר תו מיוחד","הכנס תו מיוחד","העתק עיצוב","החלף מצב","ריווח","עליון","ימין","תחתון","שמאל","עיצוב CSS","מחלקת CSS","יישור","ימין","מרכז","שמאל","--לא נקבע--","מקור","כותרת","כיתוב חלופי","קישור","פתח בכרטיסיה חדשה","תמונה","קובץ","מתקדם","מאפייני תמונה","ביטול","אישור","סייר הקבצים","שגיאה בזמן טעינת רשימה","שגיאה בזמן טעינת תקיות","האם אתה בטוח?","הכנס שם תקיה","צור תקיה","סוג הקובץ","הסר תמונה","הסר קובץ","או לחץ","כיתוב חלופי","העלה","סייר","רקע","טקסט","עליון","מרכז","תחתון","הכנס עמודה לפני","הכנס עמודה אחרי","הכנס שורה מעל","הכנס שורה מתחת","מחק טבלה","מחק שורה","מחק עמודה","רוקן תא","תווים: %d","מילים: %d","קו חוצה","קו תחתון","superscript","subscript","גזור בחירה","בחר הכל","שבירת שורה","חפש","החלף ב","החלף","הדבק","בחר תוכן להדבקה","HTML","מודגש","נטוי","מברשת","קישור","בטל","בצע שוב","טבלה","תמונה","מחק","פסקה","גודל גופן","וידאו","גופן","עלינו","הדפס","תו מיוחד","קו תחתון","קו חוצה","הגדל כניסה","הקטן כניסה","גודל מלא","כווץ","העתק עיצוב","קו אופקי","רשימת תבליטים","רשימה ממוספרת","חתוך","בחר הכל","הוסף קוד","פתח קישור","ערוך קישור","ללא מעקב","בטל קישור","עדכן","כדי לערוך","הצג","כתובת","ערוך","יישור אופקי","סנן","מין לפי שינוי","מיין לפי שם","מיין לפי גודל","הוסף תקייה","אפס","שמור","שמור בשם...","שנה גודל","חתוך","רוחב","גובה","שמור יחס","כן","לא","הסר","בחר","נבחר: %s","יישור אנכי","פיצול","מזג","הוסף עמודה","הוסף שורה",null,"מחק","פיצול אנכי","פיצול אופקי","מסגרת","הקוד דומה לHTML, האם להשאיר כHTML","הדבק כHTML","השאר","הכנס כטקסט","הכנס טקסט בלבד","רק קבצים המשוייכים שלך ניתנים לעריכה. האם להוריד את הקובץ?","התמונה עלתה בהצלחה!","לוח","אין קבצים בספריה זו.","הונגרית","הזן שם חדש","תצוגה מקדימה","הורד","להדביק מהלוח","הדפדפן שלך לא תומך גישה ישירה ללוח.","העתק בחירה","העתק","רדיוס הגבול"] + +/***/ }), +/* 85 */ +/***/ (function(module, exports) { + +module.exports.default = ["Írjon be valamit","Joditról","Jodit Editor","Ingyenes változat","GNU General Public License, Verzió 2 vagy későbbi","Jodit útmutató","további segítséget tartalmaz","További licence információkért látogassa meg a weboldalunkat:","Teljes verzió megvásárlása","Copyright © XDSoft.net - Chupurnov Valeriy. Minden jog fenntartva.","Horgony","Megnyitás új lapon","Megnyitás teljes méretben","Formázás törlése","Háttér/szöveg szín","Újra","Visszavon","Félkövér","Dőlt","Pontozott lista","Számozott lista","Középre zárt","Sorkizárt","Balra zárt","Jobbra zárt","Vízszintes vonal beszúrása","Kép beszúrás","Fájl beszúrás","Youtube videó beszúrása","Link beszúrás","Betűméret","Betűtípus","Formázott blokk beszúrása","Normál","Fejléc 1","Fejléc 2","Fejléc 3","Fejléc 4","Idézet","Kód","Beszúr","Táblázat beszúrása","Behúzás csökkentése","Behúzás növelése","Speciális karakter kiválasztása","Speciális karakter beszúrása","Kép formázása","Nézet váltása","Szegélyek","felső","jobb","alsó","bal","CSS stílusok","CSS osztályok","Igazítás","Jobbra","Középre","Balra","Nincs","Forrás","Cím","Helyettesítő szöveg","Link","Link megnyitása új lapon","Kép","Fájl","Haladó","Kép tulajdonságai","Mégsem","OK","Fájl tallózó","Hiba a lista betöltése közben","Hiba a mappák betöltése közben","Biztosan ezt szeretné?","Írjon be egy mappanevet","Mappa létrehozása","írjon be bevet","Húzza ide a képet","Húzza ide a fájlt","vagy kattintson","Helyettesítő szöveg","Feltölt","Tallóz","Háttér","Szöveg","Fent","Középen","Lent","Oszlop beszúrás elé","Oszlop beszúrás utána","Sor beszúrás fölé","Sor beszúrás alá","Táblázat törlése","Sor törlése","Oszlop törlése","Cella tartalmának törlése","Karakterek száma: %d","Szavak száma: %d","Áthúzott","Aláhúzott","Felső index","Alsó index","Kivágás","Összes kijelölése","Szünet","Keresés","Csere erre","Csere","Beillesztés","Válasszon tartalmat a beillesztéshez","HTML","Félkövér","Dőlt","Ecset","Link","Visszavon","Újra","Táblázat","Kép","Törlés","Paragráfus","Betűméret","Videó","Betű","Rólunk","Nyomtat","Szimbólum","Aláhúzott","Áthúzott","Behúzás","Aussenseiter","Teljes méret","Összenyom","Formátum másolás","Egyenes vonal","Lista","Számozott lista","Kivág","Összes kijelölése","Beágyazott kód","Link megnyitása","Link szerkesztése","Nincs követés","Link leválasztása","Frissít","Szerkesztés","felülvizsgálat","URL","Szerkeszt","Vízszintes igazítás","Szűrő","Rendezés módosítás szerint","Rendezés név szerint","Rendezés méret szerint","Mappa hozzáadás","Visszaállít","Mentés","Mentés másként...","Átméretezés","Kivág","Szélesség","Magasság","Képarány megtartása","Igen","Nem","Eltávolít","Kijelöl","Kijelöl: %s","Függőleges igazítás","Felosztás","Összevonás","Oszlop hozzáadás","Sor hozzáadás",null,"Törlés","Függőleges felosztás","Vízszintes felosztás","Szegély","A beillesztett szöveg HTML-nek tűnik. Megtartsuk HTML-ként?","Beszúrás HTML-ként","Megtartás","Beszúrás szövegként","Csak szöveg beillesztése","Csak a saját képeit tudja szerkeszteni. Letölti ezt a képet?","Kép sikeresen feltöltve!","Palette","Er zijn geen bestanden in deze map.","átnevezés","Adja meg az új nevet","előnézet","Letöltés","Illessze be a vágólap","A böngésző nem támogatja a közvetlen hozzáférést biztosít a vágólapra.","Másolás kiválasztása","másolás","Határ sugár"] + +/***/ }), +/* 86 */ +/***/ (function(module, exports) { + +module.exports.default = ["Ketik sesuatu","Tentang Jodit","Editor Jodit","Versi Bebas Non-komersil","Lisensi Publik Umum (GPL), versi 2 atau terbaru","Panduan Pengguna Jodit","mencakup detail bantuan penggunaan","Untuk informasi tentang lisensi, silakan kunjungi website:","Beli versi lengkap","Hak Cipta © XDSoft.net - Chupurnov Valeriy. Hak cipta dilindungi undang-undang.","Tautan","Buka di tab baru","Buka editor dalam ukuran penuh","Hapus Pemformatan","Isi warna atau atur warna teks","Ulangi","Batalkan","Tebal","Miring","Sisipkan Daftar Tidak Berurut","Sisipkan Daftar Berurut","Tengah","Penuh","Kiri","Kanan","Sisipkan Garis Horizontal","Sisipkan Gambar","Sisipkan Berkas","Sisipkan video youtube/vimeo","Sisipkan tautan","Ukuran font","Keluarga font","Sisipkan blok format","Normal","Heading 1","Heading 2","Heading 3","Heading 4","Kutip","Kode","Sisipkan","Sisipkan tabel","Kurangi Indentasi","Tambah Indentasi","Pilih Karakter Spesial","Sisipkan Karakter Spesial","Formar warna","Ubah mode","Batas","atas","kanan","bawah","kiri","Gaya","Class","Rata","Kanan","Tengah","Kiri","--Tidak diset--","Src","Judul","Teks alternatif","Tautan","Buka tautan di tab baru","Gambar","berkas","Lanjutan","Properti gambar","Batal","Ya","Penjelajah Berkas","Error ketika memuat list","Error ketika memuat folder","Apakah Anda yakin?","Masukkan nama Direktori","Buat direktori","ketik nama","Letakkan gambar","Letakkan berkas","atau klik","Teks alternatif","Unggah","Jelajahi","Latar Belakang","Teks","Atas","Tengah","Bawah","Sisipkan kolom sebelumnya","Sisipkan kolom setelahnya","Sisipkan baris di atasnya","Sisipkan baris di bawahnya","Hapus tabel","Hapus baris","Hapus kolom","Kosongkan cell","Karakter: %d","Kata: %d","Coret","Garis Bawah","Superskrip","Subskrip","Potong pilihan","Pilih semua","Berhenti","Mencari","Ganti dengan","Ganti","Paste","Pilih konten untuk dipaste","sumber","tebal","miring","sikat","tautan","batalkan","ulangi","tabel","gambar","penghapus","paragraf","ukuran font","video","font","tentang","cetak","simbol","garis bawah","coret","menjorok ke dalam","menjorok ke luar","ukuran penuh","menyusut","salin format","hr","ul","ol","potong","Pilih semua","Kode embed","Buka tautan","Edit tautan","No follow","Hapus tautan","Perbarui","pensil","Mata","URL","Edit","Perataan horizontal","Filter","Urutkan berdasarkan perubahan","Urutkan berdasarkan nama","Urutkan berdasarkan ukuran","Tambah folder","Reset","Simpan","Simpan sebagai...","Ubah ukuran","Crop","Lebar","Tinggi","Jaga aspek rasio","Ya","Tidak","Copot","Pilih","Pilih %s","Rata vertikal","Bagi","Gabungkan","Tambah kolom","tambah baris","Lisensi: %s","Hapus","Bagi secara vertikal","Bagi secara horizontal","Bingkai","Kode Anda cenderung ke HTML. Biarkan sebagai HTML?","Paste sebagai HTML","Jaga","Sisipkan sebagai teks","Sisipkan hanya teks","Anda hanya dapat mengedit gambar Anda sendiri. Unduh gambar ini di host?","Gambar telah sukses diunggah ke host!","palet","Tidak ada berkas","ganti nama","Masukkan nama baru","pratinjau","Unduh","Paste dari clipboard","Browser anda tidak mendukung akses langsung ke clipboard.","Copy seleksi","copy","Border radius"] + +/***/ }), +/* 87 */ +/***/ (function(module, exports) { + +module.exports.default = ["Scrivi qualcosa...","A proposito di Jodit","Jodit Editor","Versione gratuita non commerciale","Licenza pubblica generale GNU, versione 2 o successiva","Guida utente di Jodit","contiene una guida dettagliata per l'uso.","Per informazioni sulla licenza, si prega di visitare il nostro sito:","Acquista la versione completa","Copyright © XDSoft.net - Chupurnov Valeriy. Alle Rechte vorbehalten.","Ancora","Apri in una nuova scheda","Apri l'editor a schermo intero","Formato chiaro","Riempi colore o lettera","Ripristina","Annulla","Grassetto","Corsivo","Inserisci lista non ordinata","Inserisci l'elenco ordinato","Allinea Centra","Allineare Giustificato","Allinea a Sinistra","Allinea a Destra","Inserisci la linea orizzontale","Inserisci immagine","Inserisci un file","Inserisci video Youtube/Vimeo","Inserisci il link","Dimensione del carattere","Tipo di font","Inserisci blocco","Normale","Heading 1","Heading 2","Heading 3","Heading 4","Citazione","Codice","Inserisci","Inserisci tabella","Riduci il rientro","Aumenta il rientro","Seleziona una funzione speciale","Inserisci un carattere speciale","Copia formato","Cambia modo","Margini","su","destra","giù","sinistra","Stili CSS","Classi CSS","Allinea","Destra","Centro","Sinistra","--Non Impostato--","Fonte","Titolo","Testo Alternativo","Link","Apri il link in una nuova scheda","Immagine","Archivio","Avanzato","Proprietà dell'immagine","Annulla","Accetta","Cerca il file","Errore durante il caricamento dell'elenco","Errore durante il caricamento delle cartelle","Sei sicuro?","Inserisci il nome della cartella","Crea cartella","Entre el nombre","Rilascia l'immagine","Rilascia file","o click","Testo alternativo","Carica","Sfoglia","Sfondo","Testo","Su","Centro","Sotto","Inserisci prima la colonna","Inserisci colonna dopo","Inserisci la riga sopra","Inserisci la riga sotto","Elimina tabella","Elimina riga","Elimina colonna","Cella vuota","Caratteri: %d","Parole: %d","Barrato","Sottolineato","indice","deponente","Taglia la selezione","Seleziona tutto","Pausa","Cerca","Sostituisci con","Sostituisci","Incolla","Seleziona il contenuto da incollare","HTML","Grassetto","Corsivo","Pennello","Link","Annulla","Ripristina","Tabella","Immagine","Gomma","Paragrafo","Dimensione del carattere","Video","Font","Approposito di","Stampa","Simbolo","Sottolineato","Barrato","trattino","annulla rientro","A grandezza normale","comprimere","Copia il formato","linea orizzontale","lista non ordinata","lista ordinata","Taglia","Seleziona tutto","Includi codice","Apri link","Modifica link","Non seguire","Togli link","Aggiornare","Per modificare","Recensione"," URL","Modifica","Allineamento orizzontale","Filtro","Ordina per data di modifica","Ordina per nome","Ordina per dimensione","Aggiungi cartella","Reset","Salva","Salva con nome...","Ridimensiona","Tagliare","Larghezza","Altezza","Mantenere le proporzioni","Si","No","Rimuovere","Seleziona","Seleziona: %s","Allineamento verticala","Dividere","Fondi","Aggiungi colonna","Aggiungi riga",null,"Cancella","Dividere verticalmente","Diviso orizzontale","Bordo","Il codice è simile all'HTML. Mantieni come HTML?","Incolla come HTML?","Mantieni","Inserisci come testo","Inserisci solo il testo","Puoi modificare solo le tue immagini. Scarica questa immagine sul server?","L'immagine è stata caricata con successo sul server!","tavolozza","Non ci sono file in questa directory.","ungherese","Inserisci un nuovo nome","anteprima","Scaricare","Incolla dagli appunti","Il tuo browser non supporta l'accesso diretto agli appunti.","Selezione di copia","copia","Border radius"] + +/***/ }), +/* 88 */ +/***/ (function(module, exports) { + +module.exports.default = ["Begin met typen..","Over Jodit","Jodit Editor","Gratis niet-commerciële versie","GNU General Public License, versie 2 of hoger","Jodit gebruikershandleiding","bevat gedetailleerde informatie voor gebruik.","Voor informatie over de licentie, ga naar onze website:","Volledige versie kopen","Copyright © XDSoft.net - Chupurnov Valeriy. Alle rechten voorbehouden.","Anker","Open in nieuwe tab","Editor in volledig scherm openen","Opmaak verwijderen","Vulkleur of tekstkleur aanpassen","Opnieuw","Ongedaan maken","Vet","Cursief","Geordende list invoegen","Ongeordende lijst invoegen","Centreren","Uitlijnen op volledige breedte","Links uitlijnen","Rechts uitlijnen","Horizontale lijn invoegen","Afbeelding invoegen","Bestand invoegen","Youtube/Vimeo video invoegen","Link toevoegen","Tekstgrootte","Lettertype","Format blok invoegen","Normaal","Koptekst 1","Koptekst 2","Koptekst 3","Koptekst 4","Citaat","Code","Invoegen","Tabel invoegen","Inspringing verkleinen","Inspringing vergroten","Symbool selecteren","Symbool invoegen","Opmaak kopieren","Modus veranderen","Marges","Boven","Rechts","Onder","Links","CSS styles","CSS classes","Uitlijning","Rechts","Gecentreerd","Links","--Leeg--","Src","Titel","Alternatieve tekst","Link","Link in nieuwe tab openen","Afbeelding","Bestand","Geavanceerd","Afbeeldingseigenschappen","Annuleren","OK","Bestandsbrowser","Fout bij het laden van de lijst","Fout bij het laden van de mappenlijst","Weet je het zeker?","Geef de map een naam","Map aanmaken","Type naam","Sleep hier een afbeelding naartoe","Sleep hier een bestand naartoe","of klik","Alternatieve tekst","Uploaden","Bladeren","Achtergrond","Tekst","Boven","Midden","Onder","Kolom invoegen (voor)","Kolom invoegen (na)","Rij invoegen (boven)","Rij invoegen (onder)","Tabel verwijderen","Rij verwijderen","Kolom verwijderen","Cel leegmaken","Tekens: %d","Woorden: %d","Doorstrepen","Onderstrepen","Superscript","Subscript","Selectie knippen","Selecteer alles","Enter","Zoek naar","Vervangen door","Vervangen","Plakken","Kies content om te plakken","Broncode","vet","cursief","kwast","link","ongedaan maken","opnieuw","tabel","afbeelding","gum","paragraaf","lettergrootte","video","lettertype","over","afdrukken","symbool","onderstreept","doorgestreept","inspringen","minder inspringen","volledige grootte","kleiner maken","opmaak kopiëren","horizontale lijn","lijst","genummerde lijst","knip","alles selecteren","Embed code","link openen","link aanpassen","niet volgen","link verwijderen","Updaten","Om te bewerken","Recensie"," URL","Bewerken","Horizontaal uitlijnen","Filteren","Sorteren op wijzigingsdatum","Sorteren op naam","Sorteren op grootte","Map toevoegen","Herstellen","Opslaan","Opslaan als ...","Grootte aanpassen","Bijknippen","Breedte","Hoogte","Verhouding behouden","Ja","Nee","Verwijderen","Selecteren","Selecteer: %s","Verticaal uitlijnen","Splitsen","Samenvoegen","Kolom toevoegen","Rij toevoegen",null,"Verwijderen","Verticaal splitsen","Horizontaal splitsen","Rand","Deze code lijkt op HTML. Als HTML behouden?","Invoegen als HTML","Origineel behouden","Als tekst invoegen","Als onopgemaakte tekst invoegen","Je kunt alleen je eigen afbeeldingen aanpassen. Deze afbeelding downloaden?","De afbeelding is succesvol geüploadet!","Palette","Er zijn geen bestanden in deze map.","Hongaars","Voer een nieuwe naam in","voorvertoning","Download","Plakken van klembord","Uw browser ondersteunt geen directe toegang tot het klembord.","Selectie kopiëren","kopiëren","Border radius"] + +/***/ }), +/* 89 */ +/***/ (function(module, exports) { + +module.exports.default = ["Napisz coś","O Jodit","Edytor Jodit","Darmowa wersja nie komercyjna","GNU General Public License, wersja 2 lub późniejsza","Instrukcja Jodit","zawiera szczegółowe informacje dotyczące użytkowania.","Odwiedź naszą stronę, aby uzyskać więcej informacji na temat licencji:","Zakup pełnej wersji","Copyright © XDSoft.net - Chupurnov Valeriy. Wszystkie prawa zastrzeżone.","Kotwica","Otwórz w nowej zakładce","Otwórz edytor w pełnym rozmiarze","Wyczyść formatowanie","Kolor wypełnienia lub ustaw kolor tekstu","Ponów","Cofnij","Pogrubienie","Kursywa","Wstaw listę wypunktowaną","Wstaw listę numeryczną","Wyśrodkuj","Wyjustuj","Wyrównaj do lewej","Wyrównaj do prawej","Wstaw linię poziomą","Wstaw grafikę","Wstaw plik","Wstaw film Youtube/vimeo","Wstaw link","Rozmiar tekstu","Krój czcionki","Wstaw formatowanie","Normalne","Nagłówek 1","Nagłówek 2","Nagłówek 3","Nagłówek 4","Cytat","Kod","Wstaw","Wstaw tabelę","Zmniejsz wcięcie","Zwiększ wcięcie","Wybierz znak specjalny","Wstaw znak specjalny","Malarz formatów","Zmień tryb","Marginesy","Górny","Prawy","Dolny","Levy","Style CSS","Klasy CSS","Wyrównanie","Prawa","środek","Lewa","brak","Źródło","Tytuł","Tekst alternatywny","Link","Otwórz w nowej zakładce","Grafika","Plik","Zaawansowane","Właściwości grafiki","Anuluj","OK","Przeglądarka plików","Błąd ładowania listy plików","Błąd ładowania folderów","Czy jesteś pewien?","Wprowadź nazwę folderu","Utwórz folder","wprowadź nazwę","Upuść plik graficzny","Upuść plik","lub kliknij tu","Tekst alternatywny","Wczytaj","Przeglądaj","Tło","Treść","Góra","Środek","Dół","Wstaw kolumnę przed","Wstaw kolumnę po","Wstaw wiersz przed","Wstaw wiersz po","Usuń tabelę","Usuń wiersz","Usuń kolumnę","Wyczyść komórkę","Znaki: %d","Słowa: %d","Przekreślenie","Podkreślenie","indeks górny","index dolny","Wytnij zaznaczenie","Wybierz wszystko","Przerwa","Szukaj","Zamień na","Zamień","Wklej","Wybierz zawartość do wklejenia","HTML","pogrubienie","kursywa","pędzel","link","cofnij","ponów","tabela","grafika","wyczyść","akapit","rozmiar czcionki","wideo","czcionka","O programie","drukuj","symbol","podkreślenie","przekreślenie","wcięcie","wycięcie","pełen rozmiar","przytnij","format kopii","linia pozioma","lista","lista numerowana","wytnij","zaznacz wszystko","Wstaw kod","otwórz link","edytuj link","Atrybut no-follow","Usuń link","Aktualizuj","edytuj","szukaj","URL","Edytuj","Wyrównywanie w poziomie","Filtruj","Sortuj wg zmiany","Sortuj wg nazwy","Sortuj wg rozmiaru","Dodaj folder","wyczyść","zapisz","zapisz jako","Zmień rozmiar","Przytnij","Szerokość","Wysokość","Zachowaj proporcje","Tak","Nie","Usuń","Wybierz","Wybierz: %s","Wyrównywanie w pionie","Podziel","Scal","Dodaj kolumnę","Dodaj wiersz",null,"Usuń","Podziel w pionie","Podziel w poziomie","Obramowanie","Twój kod wygląda jak HTML. Zachować HTML?","Wkleić jako HTML?","Oryginalny tekst","Wstaw jako tekst","Wstaw tylko treść","Możesz edytować tylko swoje grafiki. Czy chcesz pobrać tą grafikę?","Grafika została pomyślnienie dodana na serwer","Paleta","Brak plików.","zmień nazwę","Wprowadź nową nazwę","podgląd","pobierz","Wklej ze schowka","Twoja przeglądarka nie obsługuje schowka","Kopiuj zaznaczenie","kopiuj","Zaokrąglenie krawędzi"] + +/***/ }), +/* 90 */ +/***/ (function(module, exports) { + +module.exports.default = ["Escreva algo...","Sobre o Jodit","Editor Jodit","Versão Gratuita não-comercial","Licença Pública GNU General, Versão 2 ou posterior","Guia de usuário Jodit","contém ajuda detalhada para o uso.","Para informação sobre a licença, por favor visite nosso site:","Compre a versão completa","Copyright © XDSoft.net - Chupurnov Valeriy. Todos os direitos reservados.","Link","Abrir em nova aba","Abrir editor em tela cheia","Limpar formatação","Cor de preenchimento ou cor do texto","Refazer","Desfazer","Negrito","Itálico","Inserir lista não ordenada","Inserir lista ordenada","Centralizar","Justificar","Alinhar à Esquerda","Alinhar à Direita","Inserir linha horizontal","Inserir imagem","Inserir arquivo","Inserir vídeo do Youtube/vimeo","Inserir link","Tamanho da letra","Fonte","Inserir bloco","Normal","Cabeçalho 1","Cabeçalho 2","Cabeçalho 3","Cabeçalho 4","Citação","Código","Inserir","Inserir tabela","Diminuir recuo","Aumentar recuo","Selecionar caractere especial","Inserir caractere especial","Copiar formato","Mudar modo","Margens","cima","direta","baixo","esquerda","Estilos CSS","Classes CSS","Alinhamento","Direita","Centro","Esquerda","--Não Estabelecido--","Fonte","Título","Texto Alternativo","Link","Abrir link em nova aba","Imagem","Arquivo","Avançado","Propriedades da imagem","Cancelar","Ok","Procurar arquivo","Erro ao carregar a lista","Erro ao carregar as pastas","Você tem certeza?","Escreva o nome da pasta","Criar pasta","Escreva seu nome","Soltar imagem","Soltar arquivo","ou clique","Texto alternativo","Upload","Explorar","Fundo","Texto","Cima","Meio","Baixo","Inserir coluna antes","Inserir coluna depois","Inserir linha acima","Inserir linha abaixo","Excluir tabela","Excluir linha","Excluir coluna","Limpar célula","Caracteres: %d","Palavras: %d","Tachado","Sublinhar","sobrescrito","subscrito","Cortar seleção","Selecionar tudo","Pausa","Procurar por","Substituir com","Substituir","Colar","Escolher conteúdo para colar","HTML","negrito","itálico","pincel","link","desfazer","refazer","tabela","imagem","apagar","parágrafo","tamanho da letra","vídeo","fonte","Sobre de","Imprimir","Símbolo","sublinhar","tachado","recuar","diminuir recuo","Tamanho completo","diminuir","Copiar formato","linha horizontal","lista não ordenada","lista ordenada","Cortar","Selecionar tudo","Incluir código","Abrir link","Editar link","Não siga","Remover link","Atualizar","Editar","Visualizar","URL","Editar","Alinhamento horizontal","filtrar","Ordenar por modificação","Ordenar por nome","Ordenar por tamanho","Adicionar pasta","Resetar","Salvar","Salvar como...","Redimensionar","Recortar","Largura","Altura","Manter a proporção","Sim","Não","Remover","Selecionar","Selecionar: %s","Alinhamento vertical","Dividir","Mesclar","Adicionar coluna","Adicionar linha",null,"Excluir","Dividir vertical","Dividir horizontal","Borda","Seu código é simular ao HTML. Manter como HTML?","Colar como HTML?","Manter","Inserir como Texto","Inserir somente o Texto","Você só pode editar suas próprias imagens. Baixar essa imagem pro servidor?","A imagem foi enviada com sucesso para o servidor!","Palette","Não há arquivos nesse diretório.","Húngara","Digite um novo nome","preview","Baixar","Colar da área de transferência","O seu navegador não oferece suporte a acesso direto para a área de transferência.","Selecção de cópia","cópia","Border radius"] + +/***/ }), +/* 91 */ +/***/ (function(module, exports) { + +module.exports.default = ["Напишите что-либо","О Jodit","Редактор Jodit","Версия для не коммерческого использования","Стандартная общественная лицензия GNU (GPL), версия 2 или выше","Jodit Руководство пользователя","содержит детальную информацию по использованию","Для получения сведений о лицензии , пожалуйста, перейдите на наш сайт:","Купить полную версию","Авторские права © XDSoft.net - Чупурнов Валерий. Все права защищены.","Анкор","Открывать ссылку в новой вкладке","Открыть редактор в полном размере","Очистить форматирование","Цвет заливки или цвет текста","Повтор","Отмена","Жирный","Наклонный","Вставка маркированного списка","Вставить нумерованный список","Выровнять по центру","Выровнять по ширине","Выровнять по левому краю","Выровнять по правому краю","Вставить горизонтальную линию","Вставить изображение","Вставить файл","Вставьте видео","Вставить ссылку","Размер шрифта","Шрифт","Вставить блочный элемент","Нормальный текст","Заголовок 1","Заголовок 2","Заголовок 3","Заголовок 4","Цитата","Код","Вставить","Вставить таблицу","Уменьшить отступ","Увеличить отступ","Выберите специальный символ","Вставить специальный символ","Формат краски","Источник","Отступы","сверху","справа","снизу","слева","Стили","Классы","Выравнивание","По правому краю","По центру","По левому краю","--не устанавливать--","src","Заголовок","Альтернативный текст (alt)","Ссылка","Открывать ссылку в новом окне",null,"Файл","Расширенные","Свойства изображения","Отмена","Ок","Браузер файлов","Ошибка при загрузке списка изображений","Ошибка при загрузке списка директорий","Вы уверены?","Введите название директории","Создать директорию","введите название","Перетащите сюда изображение","Перетащите сюда файл","или нажмите","Альтернативный текст","Загрузка","Сервер","Фон","Текст"," К верху","По середине","К низу","Вставить столбец до","Вставить столбец после","Вставить ряд выше","Вставить ряд ниже","Удалить таблицу","Удалять ряд","Удалить столбец","Отчистить ячейку","Символов: %d","Слов: %d","Перечеркнуть","Подчеркивание","верхний индекс","индекс","Вырезать","Выделить все","Разделитель","Найти","Заменить на","Заменить","Вставить","Выбрать контент для вставки","HTML","жирный","курсив","заливка","ссылка","отменить","повторить","таблица","Изображение","очистить","параграф","размер шрифта","видео","шрифт","о редакторе","печать","символ","подчеркнутый","перечеркнутый","отступ","выступ","во весь экран","обычный размер","Копировать формат","линия","Список","Нумерованный список","Вырезать","Выделить все","Код","Открыть ссылку","Редактировать ссылку","Атрибут nofollow","Убрать ссылку","Обновить","Редактировать","Просмотр","URL","Редактировать","Горизонтальное выравнивание","Фильтр","По изменению","По имени","По размеру","Добавить папку","Восстановить","Сохранить","Сохранить как","Изменить размер","Обрезать размер","Ширина","Высота","Сохранять пропорции","Да","Нет","Удалить","Выделить","Выделить: %s","Вертикальное выравнивание","Разделить","Объеденить в одну","Добавить столбец","Добавить строку","Лицензия: %s","Удалить","Разделить по вертикали","Разделить по горизонтали","Рамка","Ваш текст, который вы пытаетесь вставить похож на HTML. Вставить его как HTML?","Вставить как HTML?","Сохранить оригинал","Вставить как текст","Вставить только текст","Вы можете редактировать только свои собственные изображения. Загрузить это изображение на ваш сервер?","Изображение успешно загружено на сервер!","палитра","В данном каталоге нет файлов","Переименовать","Введите новое имя","Предпросмотр","Скачать","Вставить из буфера обмена","Ваш браузер не поддерживает прямой доступ к буферу обмена.","Скопировать выделенное","копия","Радиус границы"] + +/***/ }), +/* 92 */ +/***/ (function(module, exports) { + +module.exports.default = ["Bir şey yazın.","Jodit Hakkında","Jodit Editor","Ücretsiz, ticari olmayan versiyon","GNU General Public License, Versiyon 2 ve sonrası için","Jodit Kullanım Kılavuzu","kullanım için detaylı bilgiler içerir","Lisans hakkında bilgi için lütfen web sitemize gidin:","Tam versiyon satın al","Copyright © XDSoft.net - Chupurnov Valeriy. Tüm Hakları Saklıdır","Bağlantı","Yeni sekmede aç","Tam ekran editör","Stili temizle","Dolgu ve yazı rengi seç","İleri Al","Geri Al","Kalın","İtalik","Sırasız Liste Ekle","Sıralı Liste Ekle","Ortala","Kenarlara Yasla","Sola Yasla","Sağa Yasla","Yatay Çizgi Ekle","Resim Ekle","Dosya Ekle","Youtube/vimeo Videosu Ekle","Bağlantı Ekle","Font Boyutu","Font Ailesi","Blok Ekle","Normal","Başlık 1","Başlık 2","Başlık 3","Başlık 4","Alıntı","Code","Ekle","Tablo Ekle","Girintiyi Azalt","Girintiyi Arttır","Özel Karakter Seç","Özel Karakter Ekle","Resim Biçimi","Mod Değiştir","MEsafeler","Üst","Sağ","Alt","Sol","CSS Stilleri","CSS Sınıfları","Hizalama","Sağ","Ortalı","Sol","Belirlenmedi","Kaynak","Başlık","Alternatif Yazı","Link","Bağlantıyı yeni sekmede aç","Resim","Dosya","Gelişmiş","Resim özellikleri","İptal","Tamam","Dosya Gezgini","Liste yüklenirken hata oluştu","Klasörler yüklenirken hata oluştur","Emin misiniz?","Dizin yolu giriniz","Dizin oluştur","Typname","Resim bırak","Dosya bırak","veya tıkla","Alternatif yazı","Yükle","Ekle","Arka plan","Yazı","Üst","Orta","Aşağı","Öncesine kolon ekle","Sonrasına kolon ekle","Üstüne satır ekle","Altına satır ekle","Tabloyu sil","Satır sil","Kolon sil","Hücreyi boşalt","Harfler: %d","Kelimeler: %d","Durchschlagen","Alt çizgi","Üst yazı","Alt yazı","Seçilimi kes","Tümünü seç","Durdur","Ara","Şununla değiştir","Değiştir","Yapıştır","Yapıştırılacak içerik seç","Kaynak","Kalın","italik","Fırça","Bağlantı","Geri al","İleri al","Tablo","Resim","Silgi","Paragraf","Font boyutu","Video","Font","Hakkında","Yazdır","Sembol","Alt çizgi","Üstü çizili","Girinti","Çıkıntı","Tam ekran","Küçült","Kopyalama Biçimi","Ayraç","Sırasız liste","Sıralı liste","Kes","Tümünü seç","Kod ekle","Bağlantıyı aç","Bağlantıyı düzenle","Nofollow özelliği","Bağlantıyı kaldır","Güncelle","Düzenlemek için","Yorumu","URL","Düzenle","Yatay hizalama","Filtre","Değişime göre sırala","İsme göre sırala","Boyuta göre sırala","Klasör ekle","Sıfırla","Kaydet","Farklı kaydet","Boyutlandır","Kırp","Genişlik","Yükseklik","En boy oranını koru","Evet","Hayır","Sil","Seç","Seç: %s","Dikey hizalama","Ayır","Birleştir","Kolon ekle","Satır ekle",null,"Sil","Dikey ayır","Yatay ayır","Kenarlık","Kodunuz HTML koduna benziyor. HTML olarak devam etmek ister misiniz?","HTML olarak yapıştır","Sakla","Yazı olarak ekle","Nur Text einfügen","Sadece kendi resimlerinizi düzenleyebilirsiniz. Bu görseli kendi hostunuza indirmek ister misiniz?","Görsel başarıyla hostunuza yüklendi","Palette","Bu dizinde dosya yok.","Macarca","Yeni isim girin","Ön izleme","İndir","Panodan yapıştır ","Tarayıcınız pano doğrudan erişim desteklemiyor.","Kopya seçimi","kopya","Sınır yarıçapı"] + +/***/ }), +/* 93 */ +/***/ (function(module, exports) { + +module.exports.default = ["输入一些内容","关于Jodit","Jodit Editor","Free Non-commercial Version","GNU General Public License, version 2 or later","开发者指南","使用帮助","有关许可证的信息,请访问我们的网站:","购买完整版本","Copyright © XDSoft.net - Chupurnov Valeriy. All rights reserved.","Anchor","在新窗口打开","全屏编辑","清除样式","颜色","重做","撤销","粗体","斜体","符号列表","编号","居中","对齐文本","左对齐","右对齐","分割线","图片","文件","youtube/vimeo 视频","链接","字号","字体","格式块","文本","标题1","标题2","标题3","标题4","引用","代码","插入","表格","减少缩进","增加缩进","选择特殊符号","特殊符号","格式复制","改变模式","外边距(Margins)","top","right","bottom","left","样式","Classes","对齐方式","居右","居中","居左","无","Src","Title","Alternative","Link","在新窗口打开链接","图片","file","高级","图片属性","取消","确定","文件管理","加载list错误","加载folders错误","你确定吗?","输入路径","创建路径","type name","拖动图片到此","拖动文件到此","或点击","Alternative text","上传","浏览","背景色","文字","顶部","中间","底部","在之前插入列","在之后插入列","在之前插入行","在之后插入行","删除表格","删除行","删除列","清除内容","字符数: %d","单词数: %d","删除线","下划线","上标","下标","剪切","全选","Pause","查找","替换为","替换","粘贴","选择内容并粘贴","源码","粗体","斜体","颜色","链接","撤销","重做","表格","图片","橡皮擦","段落","字号","视频","字体","关于","打印","符号","下划线","上出现","增加缩进","减少缩进","全屏","收缩","复制格式","分割线","无序列表","顺序列表","剪切","全选","嵌入代码","打开链接","编辑链接","No follow","Unlink","更新","铅笔","回顧","URL",null,"水平对齐","筛选","修改时间排序","名称排序","大小排序","新建文件夹","重置","保存","保存为","调整大小","Crop","宽","高","保存长宽比","是","不","移除","选择","选择: %s","垂直对齐","拆分","合并","添加列","添加行",null,"删除","垂直拆分","水平拆分","边框","你粘贴的文本是一段html代码,是否保留源格式","html粘贴","保留源格式","把html代码视为普通文本","只保留文本","你只能编辑你自己的图片。Download this image on the host?","图片上传成功","调色板","此目录中沒有文件。","重命名","输入新名称","预览","下载","粘贴从剪贴板","你浏览器不支持直接访问的剪贴板。","复制的选择","复制","边界半径"] + +/***/ }), +/* 94 */ +/***/ (function(module, exports) { + +module.exports.default = ["輸入一些內容","關於Jodit","Jodit Editor","Free Non-commercial Version","GNU General Public License, version 2 or later","開發者指南","使用幫助","有關許可證的信息,請訪問我們的網站:","購買完整版本","Copyright © XDSoft.net - Chupurnov Valeriy. All rights reserved.","Anchor","在新窗口打開","全屏編輯","清除樣式","顏色","重做","撤銷","粗體","斜體","符號列表","編號","居中","對齊文本","左對齊","右對齊","分割線","圖片","文件","youtube/vimeo 影片","鏈接","字號","字體","格式塊","文本","標題1","標題2","標題3","標題4","引用","代碼","插入","表格","減少縮進","增加縮進","選擇特殊符號","特殊符號","格式複製","改變模式","外邊距(Margins)","top","right","bottom","left","樣式","Classes","對齊方式","居右","居中","居左","無","Src","Title","Alternative","Link","在新窗口打開鏈接","圖片","file","高級","圖片屬性","取消","確定","文件管理","加載list錯誤","加載folders錯誤","你確定嗎?","輸入路徑","創建路徑","type name","拖動圖片到此","拖動文件到此","或點擊","Alternative text","上傳","瀏覽","背景色","文字","頂部","中間","底部","在之前插入列","在之後插入列","在之前插入行","在之後插入行","刪除表格","刪除行","刪除列","清除內容","字符數: %d","單詞數: %d","刪除線","下劃線","上標","下標","剪切","全選","Pause","查找","替換為","替換","黏貼","選擇內容並黏貼","源碼","粗體","斜體","顏色","鏈接","撤銷","重做","表格","圖片","橡皮擦","段落","字號","影片","字體","關於","打印","符號","下劃線","上出現","增加縮進","減少縮進","全屏","收縮","複製格式","分割線","無序列表","順序列表","剪切","全選","嵌入代碼","打開鏈接","編輯鏈接","No follow","Unlink","更新","鉛筆","回顧","URL",null,"水平對齊","篩選","修改時間排序","名稱排序","大小排序","新建文件夾","重置","保存","保存為","調整大小","Crop","寬","高","保存長寬比","是","不","移除","選擇","選擇: %s","垂直對齊","拆分","合併","添加列","添加行",null,"刪除","垂直拆分","水平拆分","邊框","你黏貼的文本是一段html代碼,是否保留源格式","html黏貼","保留源格式","把html代碼視為普通文本","只保留文本","妳只能編輯妳自己的圖片。Download this image on the host?","圖片上傳成功","調色板","此目錄中沒有文件。","重命名","輸入新名稱","預覽","下載","วางจากคลิปบอร์ด","ของเบราว์เซอร์ไม่สนับสนุนโดยตรงเข้าไปยังคลิปบอร์ด","คัดลอกส่วนที่เลือก","คัดลอก","เส้นขอบรัศมี"] + +/***/ }), +/* 95 */ +/***/ (function(module, exports, __webpack_require__) { + +module.exports = __webpack_require__(97); + + +/***/ }), +/* 96 */ +/***/ (function(module, exports, __webpack_require__) { + +// extracted by mini-css-extract-plugin + +/***/ }), +/* 97 */ +/***/ (function(module, __webpack_exports__, __webpack_require__) { + +"use strict"; +__webpack_require__.r(__webpack_exports__); +var constants_namespaceObject = {}; +__webpack_require__.r(constants_namespaceObject); +__webpack_require__.d(constants_namespaceObject, "INVISIBLE_SPACE", function() { return INVISIBLE_SPACE; }); +__webpack_require__.d(constants_namespaceObject, "INVISIBLE_SPACE_REG_EXP", function() { return INVISIBLE_SPACE_REG_EXP; }); +__webpack_require__.d(constants_namespaceObject, "INVISIBLE_SPACE_REG_EXP_END", function() { return INVISIBLE_SPACE_REG_EXP_END; }); +__webpack_require__.d(constants_namespaceObject, "INVISIBLE_SPACE_REG_EXP_START", function() { return INVISIBLE_SPACE_REG_EXP_START; }); +__webpack_require__.d(constants_namespaceObject, "SPACE_REG_EXP", function() { return SPACE_REG_EXP; }); +__webpack_require__.d(constants_namespaceObject, "SPACE_REG_EXP_START", function() { return SPACE_REG_EXP_START; }); +__webpack_require__.d(constants_namespaceObject, "SPACE_REG_EXP_END", function() { return SPACE_REG_EXP_END; }); +__webpack_require__.d(constants_namespaceObject, "IS_BLOCK", function() { return IS_BLOCK; }); +__webpack_require__.d(constants_namespaceObject, "IS_INLINE", function() { return IS_INLINE; }); +__webpack_require__.d(constants_namespaceObject, "MAY_BE_REMOVED_WITH_KEY", function() { return MAY_BE_REMOVED_WITH_KEY; }); +__webpack_require__.d(constants_namespaceObject, "KEY_BACKSPACE", function() { return KEY_BACKSPACE; }); +__webpack_require__.d(constants_namespaceObject, "KEY_TAB", function() { return KEY_TAB; }); +__webpack_require__.d(constants_namespaceObject, "KEY_ENTER", function() { return KEY_ENTER; }); +__webpack_require__.d(constants_namespaceObject, "KEY_ESC", function() { return KEY_ESC; }); +__webpack_require__.d(constants_namespaceObject, "KEY_LEFT", function() { return KEY_LEFT; }); +__webpack_require__.d(constants_namespaceObject, "KEY_UP", function() { return KEY_UP; }); +__webpack_require__.d(constants_namespaceObject, "KEY_RIGHT", function() { return KEY_RIGHT; }); +__webpack_require__.d(constants_namespaceObject, "KEY_DOWN", function() { return KEY_DOWN; }); +__webpack_require__.d(constants_namespaceObject, "KEY_DELETE", function() { return KEY_DELETE; }); +__webpack_require__.d(constants_namespaceObject, "KEY_F", function() { return KEY_F; }); +__webpack_require__.d(constants_namespaceObject, "KEY_R", function() { return KEY_R; }); +__webpack_require__.d(constants_namespaceObject, "KEY_H", function() { return KEY_H; }); +__webpack_require__.d(constants_namespaceObject, "KEY_Y", function() { return KEY_Y; }); +__webpack_require__.d(constants_namespaceObject, "KEY_V", function() { return KEY_V; }); +__webpack_require__.d(constants_namespaceObject, "KEY_Z", function() { return KEY_Z; }); +__webpack_require__.d(constants_namespaceObject, "KEY_F3", function() { return KEY_F3; }); +__webpack_require__.d(constants_namespaceObject, "NEARBY", function() { return NEARBY; }); +__webpack_require__.d(constants_namespaceObject, "ACCURACY", function() { return ACCURACY; }); +__webpack_require__.d(constants_namespaceObject, "COMMAND_KEYS", function() { return COMMAND_KEYS; }); +__webpack_require__.d(constants_namespaceObject, "BR", function() { return BR; }); +__webpack_require__.d(constants_namespaceObject, "PARAGRAPH", function() { return PARAGRAPH; }); +__webpack_require__.d(constants_namespaceObject, "MODE_WYSIWYG", function() { return MODE_WYSIWYG; }); +__webpack_require__.d(constants_namespaceObject, "MODE_SOURCE", function() { return MODE_SOURCE; }); +__webpack_require__.d(constants_namespaceObject, "MODE_SPLIT", function() { return MODE_SPLIT; }); +__webpack_require__.d(constants_namespaceObject, "IS_IE", function() { return IS_IE; }); +__webpack_require__.d(constants_namespaceObject, "URL_LIST", function() { return URL_LIST; }); +__webpack_require__.d(constants_namespaceObject, "TEXT_PLAIN", function() { return TEXT_PLAIN; }); +__webpack_require__.d(constants_namespaceObject, "TEXT_HTML", function() { return TEXT_HTML; }); +__webpack_require__.d(constants_namespaceObject, "MARKER_CLASS", function() { return MARKER_CLASS; }); +__webpack_require__.d(constants_namespaceObject, "EMULATE_DBLCLICK_TIMEOUT", function() { return EMULATE_DBLCLICK_TIMEOUT; }); +__webpack_require__.d(constants_namespaceObject, "JODIT_SELECTED_CELL_MARKER", function() { return JODIT_SELECTED_CELL_MARKER; }); +__webpack_require__.d(constants_namespaceObject, "INSERT_AS_HTML", function() { return INSERT_AS_HTML; }); +__webpack_require__.d(constants_namespaceObject, "INSERT_CLEAR_HTML", function() { return INSERT_CLEAR_HTML; }); +__webpack_require__.d(constants_namespaceObject, "INSERT_AS_TEXT", function() { return INSERT_AS_TEXT; }); +__webpack_require__.d(constants_namespaceObject, "INSERT_ONLY_TEXT", function() { return INSERT_ONLY_TEXT; }); +__webpack_require__.d(constants_namespaceObject, "IS_MAC", function() { return IS_MAC; }); +__webpack_require__.d(constants_namespaceObject, "KEY_ALIASES", function() { return KEY_ALIASES; }); +__webpack_require__.d(constants_namespaceObject, "BASE_PATH", function() { return BASE_PATH; }); +var helpers_namespaceObject = {}; +__webpack_require__.r(helpers_namespaceObject); +__webpack_require__.d(helpers_namespaceObject, "extend", function() { return extend; }); +__webpack_require__.d(helpers_namespaceObject, "JoditArray", function() { return JoditArray_JoditArray; }); +__webpack_require__.d(helpers_namespaceObject, "JoditObject", function() { return JoditObject_JoditObject; }); +__webpack_require__.d(helpers_namespaceObject, "asArray", function() { return asArray; }); +__webpack_require__.d(helpers_namespaceObject, "inArray", function() { return inArray; }); +__webpack_require__.d(helpers_namespaceObject, "splitArray", function() { return splitArray; }); +__webpack_require__.d(helpers_namespaceObject, "debounce", function() { return debounce; }); +__webpack_require__.d(helpers_namespaceObject, "setTimeout", function() { return setTimeout_setTimeout; }); +__webpack_require__.d(helpers_namespaceObject, "isJoditObject", function() { return isJoditObject; }); +__webpack_require__.d(helpers_namespaceObject, "isNumeric", function() { return isNumeric; }); +__webpack_require__.d(helpers_namespaceObject, "isPlainObject", function() { return isPlainObject; }); +__webpack_require__.d(helpers_namespaceObject, "isURL", function() { return isURL; }); +__webpack_require__.d(helpers_namespaceObject, "isValidName", function() { return isValidName; }); +__webpack_require__.d(helpers_namespaceObject, "isWindow", function() { return isWindow; }); +__webpack_require__.d(helpers_namespaceObject, "camelCase", function() { return camelCase; }); +__webpack_require__.d(helpers_namespaceObject, "fromCamelCase", function() { return fromCamelCase; }); +__webpack_require__.d(helpers_namespaceObject, "appendScript", function() { return appendScript; }); +__webpack_require__.d(helpers_namespaceObject, "appendScriptAsync", function() { return appendScriptAsync; }); +__webpack_require__.d(helpers_namespaceObject, "appendStyleAsync", function() { return appendStyleAsync; }); +__webpack_require__.d(helpers_namespaceObject, "browser", function() { return browser; }); +__webpack_require__.d(helpers_namespaceObject, "convertMediaURLToVideoEmbed", function() { return convertMediaURLToVideoEmbed; }); +__webpack_require__.d(helpers_namespaceObject, "css", function() { return css_css; }); +__webpack_require__.d(helpers_namespaceObject, "clearCenterAlign", function() { return clearCenterAlign; }); +__webpack_require__.d(helpers_namespaceObject, "ctrlKey", function() { return ctrlKey; }); +__webpack_require__.d(helpers_namespaceObject, "dataBind", function() { return dataBind; }); +__webpack_require__.d(helpers_namespaceObject, "defaultLanguage", function() { return defaultLanguage_defaultLanguage; }); +__webpack_require__.d(helpers_namespaceObject, "each", function() { return each; }); +__webpack_require__.d(helpers_namespaceObject, "completeUrl", function() { return completeUrl; }); +__webpack_require__.d(helpers_namespaceObject, "humanSizeToBytes", function() { return humanSizeToBytes; }); +__webpack_require__.d(helpers_namespaceObject, "parseQuery", function() { return parseQuery; }); +__webpack_require__.d(helpers_namespaceObject, "buildQuery", function() { return buildQuery; }); +__webpack_require__.d(helpers_namespaceObject, "inView", function() { return inView; }); +__webpack_require__.d(helpers_namespaceObject, "scrollIntoView", function() { return scrollIntoView; }); +__webpack_require__.d(helpers_namespaceObject, "$$", function() { return $$; }); +__webpack_require__.d(helpers_namespaceObject, "getXPathByElement", function() { return getXPathByElement; }); +__webpack_require__.d(helpers_namespaceObject, "hasOwn", function() { return hasOwn; }); +__webpack_require__.d(helpers_namespaceObject, "type", function() { return type_type; }); +__webpack_require__.d(helpers_namespaceObject, "val", function() { return val_val; }); +__webpack_require__.d(helpers_namespaceObject, "throttle", function() { return throttle; }); +__webpack_require__.d(helpers_namespaceObject, "hasBrowserColorPicker", function() { return hasBrowserColorPicker; }); +__webpack_require__.d(helpers_namespaceObject, "isFunction", function() { return isFunction; }); +__webpack_require__.d(helpers_namespaceObject, "isHTML", function() { return isHTML; }); +__webpack_require__.d(helpers_namespaceObject, "isHTMLFromWord", function() { return isHTMLFromWord; }); +__webpack_require__.d(helpers_namespaceObject, "isInitable", function() { return isInitable; }); +__webpack_require__.d(helpers_namespaceObject, "isDestructable", function() { return isDestructable; }); +__webpack_require__.d(helpers_namespaceObject, "isInt", function() { return isInt; }); +__webpack_require__.d(helpers_namespaceObject, "isLicense", function() { return isLicense; }); +__webpack_require__.d(helpers_namespaceObject, "isString", function() { return isString; }); +__webpack_require__.d(helpers_namespaceObject, "hexToRgb", function() { return hexToRgb; }); +__webpack_require__.d(helpers_namespaceObject, "colorToHex", function() { return colorToHex; }); +__webpack_require__.d(helpers_namespaceObject, "applyStyles", function() { return applyStyles; }); +__webpack_require__.d(helpers_namespaceObject, "cleanFromWord", function() { return cleanFromWord; }); +__webpack_require__.d(helpers_namespaceObject, "clear", function() { return clear_clear; }); +__webpack_require__.d(helpers_namespaceObject, "htmlspecialchars", function() { return htmlspecialchars; }); +__webpack_require__.d(helpers_namespaceObject, "stripTags", function() { return stripTags; }); +__webpack_require__.d(helpers_namespaceObject, "normalizeKeyAliases", function() { return normalizeKeyAliases; }); +__webpack_require__.d(helpers_namespaceObject, "normalizeLicense", function() { return normalizeLicense; }); +__webpack_require__.d(helpers_namespaceObject, "normalizeNode", function() { return normalizeNode; }); +__webpack_require__.d(helpers_namespaceObject, "normalizePath", function() { return normalizePath; }); +__webpack_require__.d(helpers_namespaceObject, "normalizeRelativePath", function() { return normalizeRelativePath; }); +__webpack_require__.d(helpers_namespaceObject, "normalizeSize", function() { return normalizeSize; }); +__webpack_require__.d(helpers_namespaceObject, "normalizeURL", function() { return normalizeURL; }); +__webpack_require__.d(helpers_namespaceObject, "normilizeCSSValue", function() { return normilizeCSSValue; }); +__webpack_require__.d(helpers_namespaceObject, "normalizeColor", function() { return normalizeColor; }); +__webpack_require__.d(helpers_namespaceObject, "getContentWidth", function() { return getContentWidth; }); +__webpack_require__.d(helpers_namespaceObject, "innerWidth", function() { return innerWidth_innerWidth; }); +__webpack_require__.d(helpers_namespaceObject, "offset", function() { return offset; }); +__webpack_require__.d(helpers_namespaceObject, "trim", function() { return trim; }); +__webpack_require__.d(helpers_namespaceObject, "ucfirst", function() { return ucfirst; }); +__webpack_require__.d(helpers_namespaceObject, "sprintf", function() { return sprintf; }); +__webpack_require__.d(helpers_namespaceObject, "i18n", function() { return i18n_i18n; }); +var plugins_namespaceObject = {}; +__webpack_require__.r(plugins_namespaceObject); +__webpack_require__.d(plugins_namespaceObject, "addNewLine", function() { return addNewLine; }); +__webpack_require__.d(plugins_namespaceObject, "autofocus", function() { return autofocus; }); +__webpack_require__.d(plugins_namespaceObject, "backspace", function() { return backspace; }); +__webpack_require__.d(plugins_namespaceObject, "bold", function() { return bold; }); +__webpack_require__.d(plugins_namespaceObject, "cleanHtml", function() { return cleanHtml; }); +__webpack_require__.d(plugins_namespaceObject, "clipboard", function() { return cut_clipboard; }); +__webpack_require__.d(plugins_namespaceObject, "paste", function() { return paste; }); +__webpack_require__.d(plugins_namespaceObject, "pasteStorage", function() { return paste_storage_pasteStorage; }); +__webpack_require__.d(plugins_namespaceObject, "color", function() { return color_color; }); +__webpack_require__.d(plugins_namespaceObject, "DragAndDrop", function() { return drag_and_drop_DragAndDrop; }); +__webpack_require__.d(plugins_namespaceObject, "DragAndDropElement", function() { return drag_and_drop_element_DragAndDropElement; }); +__webpack_require__.d(plugins_namespaceObject, "enter", function() { return enter_enter; }); +__webpack_require__.d(plugins_namespaceObject, "errorMessages", function() { return errorMessages; }); +__webpack_require__.d(plugins_namespaceObject, "font", function() { return font_font; }); +__webpack_require__.d(plugins_namespaceObject, "formatBlock", function() { return formatBlock; }); +__webpack_require__.d(plugins_namespaceObject, "fullsize", function() { return fullsize; }); +__webpack_require__.d(plugins_namespaceObject, "hotkeys", function() { return hotkeys_hotkeys; }); +__webpack_require__.d(plugins_namespaceObject, "iframe", function() { return iframe_iframe; }); +__webpack_require__.d(plugins_namespaceObject, "imageProcessor", function() { return imageProcessor; }); +__webpack_require__.d(plugins_namespaceObject, "imageProperties", function() { return imageProperties; }); +__webpack_require__.d(plugins_namespaceObject, "indent", function() { return indent; }); +__webpack_require__.d(plugins_namespaceObject, "inlinePopup", function() { return inline_popup_inlinePopup; }); +__webpack_require__.d(plugins_namespaceObject, "justify", function() { return justify; }); +__webpack_require__.d(plugins_namespaceObject, "limit", function() { return limit; }); +__webpack_require__.d(plugins_namespaceObject, "link", function() { return link_link; }); +__webpack_require__.d(plugins_namespaceObject, "media", function() { return media; }); +__webpack_require__.d(plugins_namespaceObject, "mobile", function() { return mobile; }); +__webpack_require__.d(plugins_namespaceObject, "orderedlist", function() { return orderedlist; }); +__webpack_require__.d(plugins_namespaceObject, "placeholder", function() { return placeholder_placeholder; }); +__webpack_require__.d(plugins_namespaceObject, "redoundo", function() { return redoundo_redoundo; }); +__webpack_require__.d(plugins_namespaceObject, "resizer", function() { return resizer; }); +__webpack_require__.d(plugins_namespaceObject, "search", function() { return search_search; }); +__webpack_require__.d(plugins_namespaceObject, "size", function() { return size_size; }); +__webpack_require__.d(plugins_namespaceObject, "source", function() { return source_source; }); +__webpack_require__.d(plugins_namespaceObject, "stat", function() { return stat_stat; }); +__webpack_require__.d(plugins_namespaceObject, "sticky", function() { return sticky_sticky; }); +__webpack_require__.d(plugins_namespaceObject, "symbols", function() { return symbols_symbols; }); +__webpack_require__.d(plugins_namespaceObject, "tableKeyboardNavigation", function() { return tableKeyboardNavigation; }); +__webpack_require__.d(plugins_namespaceObject, "table", function() { return table_TableProcessor; }); +__webpack_require__.d(plugins_namespaceObject, "xpath", function() { return xpath_xpath; }); +var modules_namespaceObject = {}; +__webpack_require__.r(modules_namespaceObject); +__webpack_require__.d(modules_namespaceObject, "Ajax", function() { return Ajax_Ajax; }); +__webpack_require__.d(modules_namespaceObject, "EventsNative", function() { return eventsNative_EventsNative; }); +__webpack_require__.d(modules_namespaceObject, "Component", function() { return Component_Component; }); +__webpack_require__.d(modules_namespaceObject, "ContextMenu", function() { return ContextMenu_ContextMenu; }); +__webpack_require__.d(modules_namespaceObject, "Alert", function() { return Alert; }); +__webpack_require__.d(modules_namespaceObject, "Confirm", function() { return Confirm; }); +__webpack_require__.d(modules_namespaceObject, "Promt", function() { return Promt; }); +__webpack_require__.d(modules_namespaceObject, "Dialog", function() { return dialog_Dialog; }); +__webpack_require__.d(modules_namespaceObject, "Dom", function() { return Dom_Dom; }); +__webpack_require__.d(modules_namespaceObject, "Plugin", function() { return Plugin_Plugin; }); +__webpack_require__.d(modules_namespaceObject, "Create", function() { return Create_Create; }); +__webpack_require__.d(modules_namespaceObject, "FileBrowser", function() { return fileBrowser_FileBrowser; }); +__webpack_require__.d(modules_namespaceObject, "Helpers", function() { return helpers_namespaceObject; }); +__webpack_require__.d(modules_namespaceObject, "ImageEditor", function() { return ImageEditor_ImageEditor; }); +__webpack_require__.d(modules_namespaceObject, "Observer", function() { return observer_Observer; }); +__webpack_require__.d(modules_namespaceObject, "Select", function() { return Selection_Select; }); +__webpack_require__.d(modules_namespaceObject, "Storage", function() { return storage_Storage; }); +__webpack_require__.d(modules_namespaceObject, "Snapshot", function() { return Snapshot_Snapshot; }); +__webpack_require__.d(modules_namespaceObject, "Table", function() { return Table_Table; }); +__webpack_require__.d(modules_namespaceObject, "ToolbarIcon", function() { return ToolbarIcon; }); +__webpack_require__.d(modules_namespaceObject, "JoditToolbarCollection", function() { return joditToolbarCollection_JoditToolbarCollection; }); +__webpack_require__.d(modules_namespaceObject, "ToolbarCollection", function() { return collection_ToolbarCollection; }); +__webpack_require__.d(modules_namespaceObject, "ToolbarButton", function() { return button_ToolbarButton; }); +__webpack_require__.d(modules_namespaceObject, "Stack", function() { return Stack; }); +__webpack_require__.d(modules_namespaceObject, "Widget", function() { return Widget_Widget; }); +__webpack_require__.d(modules_namespaceObject, "Uploader", function() { return Uploader_Uploader; }); +__webpack_require__.d(modules_namespaceObject, "PluginSystem", function() { return PluginSystem_PluginSystem; }); +var icons_namespaceObject = {}; +__webpack_require__.r(icons_namespaceObject); +__webpack_require__.d(icons_namespaceObject, "about", function() { return about; }); +__webpack_require__.d(icons_namespaceObject, "addcolumn", function() { return addcolumn; }); +__webpack_require__.d(icons_namespaceObject, "addrow", function() { return addrow; }); +__webpack_require__.d(icons_namespaceObject, "angle_down", function() { return angle_down; }); +__webpack_require__.d(icons_namespaceObject, "angle_left", function() { return angle_left; }); +__webpack_require__.d(icons_namespaceObject, "angle_right", function() { return angle_right; }); +__webpack_require__.d(icons_namespaceObject, "angle_up", function() { return angle_up; }); +__webpack_require__.d(icons_namespaceObject, "arrows_alt", function() { return arrows_alt; }); +__webpack_require__.d(icons_namespaceObject, "arrows_h", function() { return arrows_h; }); +__webpack_require__.d(icons_namespaceObject, "attachment", function() { return attachment; }); +__webpack_require__.d(icons_namespaceObject, "bin", function() { return bin; }); +__webpack_require__.d(icons_namespaceObject, "bold", function() { return icons_bold; }); +__webpack_require__.d(icons_namespaceObject, "brush", function() { return brush; }); +__webpack_require__.d(icons_namespaceObject, "cancel", function() { return icons_cancel; }); +__webpack_require__.d(icons_namespaceObject, "center", function() { return center; }); +__webpack_require__.d(icons_namespaceObject, "chain_broken", function() { return chain_broken; }); +__webpack_require__.d(icons_namespaceObject, "check", function() { return check; }); +__webpack_require__.d(icons_namespaceObject, "check_square", function() { return check_square; }); +__webpack_require__.d(icons_namespaceObject, "copyformat", function() { return copyformat; }); +__webpack_require__.d(icons_namespaceObject, "copy", function() { return icons_copy; }); +__webpack_require__.d(icons_namespaceObject, "crop", function() { return crop; }); +__webpack_require__.d(icons_namespaceObject, "cut", function() { return cut; }); +__webpack_require__.d(icons_namespaceObject, "dedent", function() { return dedent; }); +__webpack_require__.d(icons_namespaceObject, "dots", function() { return dots; }); +__webpack_require__.d(icons_namespaceObject, "dropdown_arrow", function() { return dropdown_arrow; }); +__webpack_require__.d(icons_namespaceObject, "enter", function() { return icons_enter; }); +__webpack_require__.d(icons_namespaceObject, "eraser", function() { return eraser; }); +__webpack_require__.d(icons_namespaceObject, "eye", function() { return eye; }); +__webpack_require__.d(icons_namespaceObject, "file", function() { return icons_file; }); +__webpack_require__.d(icons_namespaceObject, "folder", function() { return icons_folder; }); +__webpack_require__.d(icons_namespaceObject, "font", function() { return icons_font; }); +__webpack_require__.d(icons_namespaceObject, "fontsize", function() { return fontsize; }); +__webpack_require__.d(icons_namespaceObject, "fullsize", function() { return icons_fullsize; }); +__webpack_require__.d(icons_namespaceObject, "hr", function() { return icons_hr; }); +__webpack_require__.d(icons_namespaceObject, "image", function() { return icons_image; }); +__webpack_require__.d(icons_namespaceObject, "indent", function() { return icons_indent; }); +__webpack_require__.d(icons_namespaceObject, "info_circle", function() { return info_circle; }); +__webpack_require__.d(icons_namespaceObject, "italic", function() { return italic; }); +__webpack_require__.d(icons_namespaceObject, "justify", function() { return icons_justify; }); +__webpack_require__.d(icons_namespaceObject, "left", function() { return icons_left; }); +__webpack_require__.d(icons_namespaceObject, "link", function() { return icons_link; }); +__webpack_require__.d(icons_namespaceObject, "lock", function() { return lock; }); +__webpack_require__.d(icons_namespaceObject, "menu", function() { return menu; }); +__webpack_require__.d(icons_namespaceObject, "merge", function() { return merge; }); +__webpack_require__.d(icons_namespaceObject, "ol", function() { return ol; }); +__webpack_require__.d(icons_namespaceObject, "omega", function() { return omega; }); +__webpack_require__.d(icons_namespaceObject, "outdent", function() { return outdent; }); +__webpack_require__.d(icons_namespaceObject, "palette", function() { return palette; }); +__webpack_require__.d(icons_namespaceObject, "paragraph", function() { return paragraph; }); +__webpack_require__.d(icons_namespaceObject, "paste", function() { return icons_paste; }); +__webpack_require__.d(icons_namespaceObject, "pencil", function() { return pencil; }); +__webpack_require__.d(icons_namespaceObject, "plus", function() { return plus; }); +__webpack_require__.d(icons_namespaceObject, "print", function() { return print; }); +__webpack_require__.d(icons_namespaceObject, "redo", function() { return redo; }); +__webpack_require__.d(icons_namespaceObject, "resize", function() { return icons_resize; }); +__webpack_require__.d(icons_namespaceObject, "resizer", function() { return icons_resizer; }); +__webpack_require__.d(icons_namespaceObject, "right", function() { return icons_right; }); +__webpack_require__.d(icons_namespaceObject, "save", function() { return icons_save; }); +__webpack_require__.d(icons_namespaceObject, "select_all", function() { return select_all; }); +__webpack_require__.d(icons_namespaceObject, "shrink", function() { return shrink; }); +__webpack_require__.d(icons_namespaceObject, "source", function() { return icons_source; }); +__webpack_require__.d(icons_namespaceObject, "splitg", function() { return splitg; }); +__webpack_require__.d(icons_namespaceObject, "splitv", function() { return splitv; }); +__webpack_require__.d(icons_namespaceObject, "strikethrough", function() { return strikethrough; }); +__webpack_require__.d(icons_namespaceObject, "subscript", function() { return subscript; }); +__webpack_require__.d(icons_namespaceObject, "superscript", function() { return superscript; }); +__webpack_require__.d(icons_namespaceObject, "table", function() { return icons_table; }); +__webpack_require__.d(icons_namespaceObject, "th", function() { return th; }); +__webpack_require__.d(icons_namespaceObject, "th_list", function() { return th_list; }); +__webpack_require__.d(icons_namespaceObject, "ul", function() { return icons_ul; }); +__webpack_require__.d(icons_namespaceObject, "underline", function() { return underline; }); +__webpack_require__.d(icons_namespaceObject, "undo", function() { return undo; }); +__webpack_require__.d(icons_namespaceObject, "unlink", function() { return icons_unlink; }); +__webpack_require__.d(icons_namespaceObject, "unlock", function() { return unlock; }); +__webpack_require__.d(icons_namespaceObject, "update", function() { return icons_update; }); +__webpack_require__.d(icons_namespaceObject, "upload", function() { return upload; }); +__webpack_require__.d(icons_namespaceObject, "valign", function() { return valign; }); +__webpack_require__.d(icons_namespaceObject, "video", function() { return video; }); + +// EXTERNAL MODULE: ./src/styles/bundle.less +var bundle = __webpack_require__(96); + +// CONCATENATED MODULE: ./src/constants.ts +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +const INVISIBLE_SPACE = '\uFEFF'; +const INVISIBLE_SPACE_REG_EXP = /[\uFEFF]/g; +const INVISIBLE_SPACE_REG_EXP_END = /[\uFEFF]+$/g; +const INVISIBLE_SPACE_REG_EXP_START = /^[\uFEFF]+/g; +const SPACE_REG_EXP = /[\s\n\t\r\uFEFF\u200b]+/g; +const SPACE_REG_EXP_START = /^[\s\n\t\r\uFEFF\u200b]+/g; +const SPACE_REG_EXP_END = /[\s\n\t\r\uFEFF\u200b]+$/g; +const IS_BLOCK = /^(PRE|DIV|P|LI|H[1-6]|BLOCKQUOTE|TD|TH|TABLE|BODY|HTML|FIGCAPTION|FIGURE|DT|DD)$/i; +const IS_INLINE = /^(STRONG|SPAN|I|EM|B|SUP|SUB)$/; +const MAY_BE_REMOVED_WITH_KEY = /^(IMG|BR|IFRAME|SCRIPT|INPUT|TEXTAREA|HR|JODIT|JODIT-MEDIA)$/; +const KEY_BACKSPACE = 8; +const KEY_TAB = 9; +const KEY_ENTER = 13; +const KEY_ESC = 27; +const KEY_LEFT = 37; +const KEY_UP = 38; +const KEY_RIGHT = 39; +const KEY_DOWN = 40; +const KEY_DELETE = 46; +const KEY_F = 70; +const KEY_R = 82; +const KEY_H = 72; +const KEY_Y = 89; +const KEY_V = 86; +const KEY_Z = 90; +const KEY_F3 = 114; +const NEARBY = 5; +const ACCURACY = 10; +const COMMAND_KEYS = [ + KEY_BACKSPACE, + KEY_DELETE, + KEY_UP, + KEY_DOWN, + KEY_RIGHT, + KEY_LEFT, + KEY_ENTER, + KEY_ESC, + KEY_F3, + KEY_TAB +]; +const BR = 'br'; +const PARAGRAPH = 'p'; +const MODE_WYSIWYG = 1; +const MODE_SOURCE = 2; +const MODE_SPLIT = 3; +const IS_IE = typeof navigator !== 'undefined' && + (navigator.userAgent.indexOf('MSIE') !== -1 || + /rv:11.0/i.test(navigator.userAgent)); +const URL_LIST = IS_IE ? 'url' : 'text/uri-list'; +const TEXT_PLAIN = IS_IE ? 'text' : 'text/plain'; +const TEXT_HTML = IS_IE ? 'text' : 'text/html'; +const MARKER_CLASS = 'jodit_selection_marker'; +const EMULATE_DBLCLICK_TIMEOUT = 300; +const JODIT_SELECTED_CELL_MARKER = 'data-jodit-selected-cell'; +const INSERT_AS_HTML = 'insert_as_html'; +const INSERT_CLEAR_HTML = 'insert_clear_html'; +const INSERT_AS_TEXT = 'insert_as_text'; +const INSERT_ONLY_TEXT = 'insert_only_text'; +const IS_MAC = typeof window !== 'undefined' && + /Mac|iPod|iPhone|iPad/.test(window.navigator.platform); +const KEY_ALIASES = { + add: '+', + break: 'pause', + cmd: 'meta', + command: 'meta', + ctl: 'control', + ctrl: 'control', + del: 'delete', + down: 'arrowdown', + esc: 'escape', + ins: 'insert', + left: 'arrowleft', + mod: IS_MAC ? 'meta' : 'control', + opt: 'alt', + option: 'alt', + return: 'enter', + right: 'arrowright', + space: ' ', + spacebar: ' ', + up: 'arrowup', + win: 'meta', + windows: 'meta' +}; +const BASE_PATH = (() => { + if (typeof document === 'undefined') { + return ''; + } + const script = document.currentScript, removeScriptName = (s) => s.replace(/\/[^\/]+.js$/, '/'); + if (script) { + return removeScriptName(script.src); + } + const scripts = document.querySelectorAll('script[src]'); + if (scripts && scripts.length) { + return removeScriptName(scripts[scripts.length - 1].src); + } + return window.location.href; +})(); + +// CONCATENATED MODULE: ./src/modules/helpers/array/asArray.ts +const asArray = (a) => (Array.isArray(a) ? a : [a]); + +// CONCATENATED MODULE: ./src/modules/helpers/array/inArray.ts +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +const inArray = (needle, haystack) => haystack.indexOf(needle) !== -1; + +// CONCATENATED MODULE: ./src/modules/helpers/array/splitArray.ts +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +const splitArray = (a) => typeof a === 'string' ? a.split(/[,\s]+/) : a; + +// CONCATENATED MODULE: ./src/modules/helpers/array/index.ts +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ + + + + +// CONCATENATED MODULE: ./src/modules/helpers/async/setTimeout.ts +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +const setTimeout_setTimeout = (callback, timeout, a1, a2, a3) => { + if (!timeout) { + callback.call(null, a1, a2, a3); + } + else { + return window.setTimeout.call(window, callback, timeout, a1, a2, a3); + } + return 0; +}; + +// CONCATENATED MODULE: ./src/modules/helpers/async/debounce.ts +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ + +const debounce = function (fn, timeout, invokeAsap, ctx) { + if (arguments.length === 3 && typeof invokeAsap !== 'boolean') { + ctx = invokeAsap; + invokeAsap = false; + } + let timer = 0; + return function () { + const args = arguments; + const context = ctx || this; + if ((invokeAsap && !timer) || !timeout) { + fn.apply(context, args); + } + if (timeout) { + clearTimeout(timer); + timer = setTimeout_setTimeout(() => { + if (!invokeAsap) { + fn.apply(context, args); + } + timer = 0; + }, timeout); + } + }; +}; + +// CONCATENATED MODULE: ./src/modules/helpers/async/throttle.ts +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ + +const throttle = (fn, timeout, ctx) => { + let timer = null, args, needInvoke, callee; + return function () { + args = arguments; + needInvoke = true; + const context = ctx || this; + if (!timeout) { + fn.apply(context, args); + return; + } + if (!timer) { + callee = () => { + if (needInvoke) { + fn.apply(context, args); + needInvoke = false; + timer = setTimeout_setTimeout(callee, timeout); + } + else { + timer = null; + } + }; + callee(); + } + }; +}; + +// CONCATENATED MODULE: ./src/modules/helpers/async/index.ts +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ + + + + +// CONCATENATED MODULE: ./src/modules/helpers/JoditObject.ts +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ + +class JoditObject_JoditObject { + constructor(data) { + extend(true, this, data); + } +} + +// CONCATENATED MODULE: ./src/modules/helpers/JoditArray.ts +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ + +class JoditArray_JoditArray { + constructor(data) { + this.length = 0; + extend(true, this, data); + this.length = data.length; + const proto = Array.prototype; + [ + 'map', + 'forEach', + 'reduce', + 'push', + 'pop', + 'shift', + 'unshift', + 'slice', + 'splice' + ].forEach((method) => { + this[method] = proto[method]; + }); + } + toString() { + const out = []; + for (let i = 0; i < this.length; i += 1) { + out[i] = this[i]; + } + return out.toString(); + } +} + +// CONCATENATED MODULE: ./src/modules/helpers/type.ts +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +const class2type = {}; +const type_toString = class2type.toString; +const hasOwn = class2type.hasOwnProperty; +[ + 'Boolean', + 'Number', + 'String', + 'Function', + 'Array', + 'Date', + 'RegExp', + 'Object', + 'Error', + 'Symbol', + 'HTMLDocument', + 'Window', + 'HTMLElement', + 'HTMLBodyElement', + 'Text', + 'DocumentFragment', + 'DOMStringList', + 'HTMLCollection' +].forEach(name => { + class2type['[object ' + name + ']'] = name.toLowerCase(); +}); +const type_type = (obj) => { + if (obj === null) { + return 'null'; + } + return typeof obj === 'object' || typeof obj === 'function' + ? class2type[type_toString.call(obj)] || 'object' + : typeof obj; +}; + +// CONCATENATED MODULE: ./src/modules/helpers/checker/isWindow.ts +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +const isWindow = (obj) => { + return obj !== null && obj === obj.window; +}; + +// CONCATENATED MODULE: ./src/modules/helpers/checker/isPlainObject.ts +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ + + +const isPlainObject = (obj) => { + if (typeof obj !== 'object' || obj.nodeType || isWindow(obj)) { + return false; + } + return !(obj.constructor && + !hasOwn.call(obj.constructor.prototype, 'isPrototypeOf')); +}; + +// CONCATENATED MODULE: ./src/modules/helpers/extend.ts +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ + + + + +function extend(...args) { + const length = args.length; + let options, name, src, copy, copyIsArray, clone, target = args[0] || {}, i = 1, j, keys, deep = false; + if (typeof target === 'boolean') { + deep = target; + target = args[i] || {}; + i += 1; + } + if (typeof target !== 'object' && type_type(target) === 'function') { + target = {}; + } + if (i === length) { + target = this; + i += 1; + } + for (i; i < length; i += 1) { + options = args[i]; + if (options !== null && options !== undefined) { + keys = Object.keys(options); + for (j = 0; j < keys.length; j += 1) { + name = keys[j]; + src = target[name]; + copy = options[name]; + if (target === copy) { + continue; + } + if (deep && + copy && + ((isPlainObject(copy) && !(copy instanceof JoditObject_JoditObject)) || + (Array.isArray(copy) && !(copy instanceof JoditArray_JoditArray)))) { + copyIsArray = Array.isArray(copy); + if (copyIsArray) { + copyIsArray = false; + clone = src && Array.isArray(src) ? src : []; + } + else { + clone = src && isPlainObject(src) ? src : {}; + } + target[name] = extend(deep, clone, copy); + } + else if (copy !== undefined) { + target[name] = copy; + } + } + } + } + return target; +} + +// CONCATENATED MODULE: ./src/modules/helpers/checker/hasBrowserColorPicker.ts +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +const hasBrowserColorPicker = () => { + let supportsColor = true; + try { + const a = document.createElement("input"); + a.type = "color"; + supportsColor = a.type === "color" && typeof a.selectionStart !== "number"; + } + catch (e) { + supportsColor = false; + } + return supportsColor; +}; + +// CONCATENATED MODULE: ./src/modules/helpers/checker/isFunction.ts +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +const isFunction = (value) => { + return typeof value === 'function'; +}; + +// CONCATENATED MODULE: ./src/modules/helpers/checker/isHTML.ts +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +const isHTML = (str) => /<([A-Za-z][A-Za-z0-9]*)\b[^>]*>(.*?)<\/\1>/m.test(str); + +// CONCATENATED MODULE: ./src/modules/helpers/checker/isHTMLFromWord.ts +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +const isHTMLFromWord = (data) => { + return (data.search(//) !== -1 || + data.search(//) !== -1 || + (data.search(/style="[^"]*mso-/) !== -1 && data.search(/ { + return value && isFunction(value.init); +}; +const isDestructable = (value) => { + return value && isFunction(value.destruct); +}; + +// CONCATENATED MODULE: ./src/modules/helpers/checker/isNumeric.ts +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +const isNumeric = (value) => { + if (typeof value === 'string') { + if (!value.match(/^([+\-])?[0-9]+(\.?)([0-9]+)?(e[0-9]+)?$/)) { + return false; + } + value = parseFloat(value); + } + return !isNaN(value) && isFinite(value); +}; + +// CONCATENATED MODULE: ./src/modules/helpers/checker/isInt.ts +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ + +const isInt = (value) => { + if (typeof value === 'string' && isNumeric(value)) { + value = parseFloat(value); + } + return typeof value === 'number' && Number.isFinite(value) && !(value % 1); +}; + +// CONCATENATED MODULE: ./src/modules/helpers/checker/isJoditObject.ts +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +const isJoditObject = (jodit) => { + if (jodit && + jodit instanceof Object && + typeof jodit.constructor === 'function' && + (jodit instanceof Jodit_Jodit || jodit.isJodit)) { + return true; + } + return false; +}; + + +// CONCATENATED MODULE: ./src/modules/helpers/checker/isLicense.ts +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +const isLicense = (license) => typeof license === 'string' && + license.length === 32 && + /^[a-z0-9]+$/.test(license); + +// CONCATENATED MODULE: ./src/modules/helpers/checker/isString.ts +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +const isString = (value) => { + return typeof value === 'string'; +}; + +// CONCATENATED MODULE: ./src/modules/helpers/checker/isURL.ts +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +const isURL = (str) => { + const pattern = new RegExp('^(https?:\\/\\/)' + + '((([a-z\\d]([a-z\\d-]*[a-z\\d])*)\\.?)+[a-z]{2,}|' + + '((\\d{1,3}\\.){3}\\d{1,3}))' + + '(\\:\\d+)?(\\/[-a-z\\d%_.~+]*)*' + + '(\\?[;&a-z\\d%_.~+=-]*)?' + + '(\\#[-a-z\\d_]*)?$', 'i'); + return pattern.test(str); +}; + +// CONCATENATED MODULE: ./src/modules/helpers/checker/isValidName.ts +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +const isValidName = (name) => { + if (!name.length) { + return false; + } + if (/[^0-9A-Za-zа-яА-ЯЁё\w\-_\.]/.test(name)) { + return false; + } + return true; +}; + +// CONCATENATED MODULE: ./src/modules/helpers/checker/index.ts +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ + + + + + + + + + + + + + + + +// CONCATENATED MODULE: ./src/modules/helpers/color/hexToRgb.ts +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +const hexToRgb = (hex) => { + const shorthandRegex = /^#?([a-f\d])([a-f\d])([a-f\d])$/i; + hex = hex.replace(shorthandRegex, (m, r, g, b) => { + return r + r + g + g + b + b; + }); + const result = /^#?([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})$/i.exec(hex); + return result + ? { + r: parseInt(result[1], 16), + g: parseInt(result[2], 16), + b: parseInt(result[3], 16), + } + : null; +}; + +// CONCATENATED MODULE: ./src/modules/helpers/color/colorToHex.ts +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +const colorToHex = (color) => { + if (color === 'rgba(0, 0, 0, 0)' || color === '') { + return false; + } + if (!color) { + return '#000000'; + } + if (color.substr(0, 1) === '#') { + return color; + } + const digits = /([\s\n\t\r]*?)rgb\((\d+), (\d+), (\d+)\)/.exec(color) || + /([\s\n\t\r]*?)rgba\((\d+), (\d+), (\d+), ([\d.]+)\)/.exec(color); + let hex, red, green, blue, rgb; + if (!digits) { + return '#000000'; + } + red = parseInt(digits[2], 10); + green = parseInt(digits[3], 10); + blue = parseInt(digits[4], 10); + rgb = blue | (green << 8) | (red << 16); + hex = rgb.toString(16).toUpperCase(); + while (hex.length < 6) { + hex = '0' + hex; + } + return digits[1] + '#' + hex; +}; + +// CONCATENATED MODULE: ./src/modules/helpers/color/index.ts +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ + + + +// CONCATENATED MODULE: ./src/modules/helpers/selector.ts +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ + +let $$temp = 1; +const $$ = (selector, root) => { + let result; + if (/:scope/.test(selector) && + IS_IE && + !(root && root.nodeType === Node.DOCUMENT_NODE)) { + const id = root.id, temp_id = id || + '_selector_id_' + ('' + Math.random()).slice(2) + $$temp++; + selector = selector.replace(/:scope/g, '#' + temp_id); + !id && root.setAttribute('id', temp_id); + result = root.parentNode.querySelectorAll(selector); + if (!id) { + root.removeAttribute('id'); + } + } + else { + result = root.querySelectorAll(selector); + } + return [].slice.call(result); +}; +const getXPathByElement = (element, root) => { + if (!element || element.nodeType !== 1) { + return ''; + } + if (!element.parentNode || root === element) { + return ''; + } + if (element.id) { + return "//*[@id='" + element.id + "']"; + } + const sames = [].filter.call(element.parentNode.childNodes, (x) => x.nodeName === element.nodeName); + return (getXPathByElement(element.parentNode, root) + + '/' + + element.nodeName.toLowerCase() + + (sames.length > 1 + ? '[' + (Array.from(sames).indexOf(element) + 1) + ']' + : '')); +}; + +// CONCATENATED MODULE: ./src/modules/helpers/html/applyStyles.ts +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ + + +const applyStyles = (html) => { + if (html.indexOf('') + ''.length); + const iframe = document.createElement('iframe'); + iframe.style.display = 'none'; + document.body.appendChild(iframe); + let convertedString = '', collection = [], rules = []; + try { + const iframeDoc = iframe.contentDocument || + (iframe.contentWindow ? iframe.contentWindow.document : null); + if (iframeDoc) { + iframeDoc.open(); + iframeDoc.write(html); + iframeDoc.close(); + if (iframeDoc.styleSheets.length) { + rules = iframeDoc.styleSheets[iframeDoc.styleSheets.length - 1].cssRules; + } + for (let idx = 0; idx < rules.length; idx += 1) { + if (rules[idx].selectorText === '') { + continue; + } + collection = $$(rules[idx].selectorText, iframeDoc.body); + collection.forEach((elm) => { + elm.style.cssText = rules[idx].style.cssText + .replace(/mso-[a-z\-]+:[\s]*[^;]+;/g, '') + .replace(/border[a-z\-]*:[\s]*[^;]+;/g, '') + elm.style.cssText; + }); + } + convertedString = iframeDoc.firstChild + ? iframeDoc.body.innerHTML + : ''; + } + } + catch (_a) { + } + finally { + Dom_Dom.safeRemove(iframe); + } + if (convertedString) { + html = convertedString; + } + return html + .replace(/<(\/)?(html|colgroup|col|o:p)[^>]*>/g, '') + .replace(//i); + if (start !== -1) { + html = html.substr(start + 20); + } + const end = html.search(//i); + if (end !== -1) { + html = html.substr(0, end); + } + return html; + }; + editor.events.on('paste', (event) => { + if (editor.events.fire('beforePaste', event) === false) { + event.preventDefault(); + return false; + } + const dt = getDataTransfer(event); + if (event && dt) { + const types = dt.types; + let types_str = ''; + if (Array.isArray(types) || type_type(types) === 'domstringlist') { + for (let i = 0; i < types.length; i += 1) { + types_str += types[i] + ';'; + } + } + else { + types_str = types.toString() + ';'; + } + const getText = () => { + if (/text\/html/i.test(types_str)) { + return dt.getData('text/html'); + } + if (/text\/rtf/i.test(types_str) && browser('safari')) { + return dt.getData('text/rtf'); + } + if (/text\/plain/i.test(types_str) && !browser('mozilla')) { + return dt.getData(TEXT_PLAIN); + } + if (/text/i.test(types_str) && IS_IE) { + return dt.getData(TEXT_PLAIN); + } + return ''; + }; + let clipboard_html = getText(); + if (Dom_Dom.isNode(clipboard_html, editor.editorWindow) || + trim(clipboard_html) !== '') { + clipboard_html = trimFragment(clipboard_html); + const buffer = editor.buffer.get(pluginKey); + if (buffer !== clipboard_html) { + clipboard_html = editor.events.fire('processPaste', event, clipboard_html, types_str); + } + if (typeof clipboard_html === 'string' || + Dom_Dom.isNode(clipboard_html, editor.editorWindow)) { + if (event.type === 'drop') { + editor.selection.insertCursorAtPoint(event.clientX, event.clientY); + } + insertByType(clipboard_html, editor.options.defaultActionOnPaste); + } + event.preventDefault(); + event.stopPropagation(); + } + } + if (editor.events.fire('afterPaste', event) === false) { + return false; + } + }); + if (editor.options.askBeforePasteHTML) { + editor.events.on('beforePaste', (event) => { + const dt = getDataTransfer(event); + if (event && dt && dt.getData(TEXT_PLAIN)) { + const html = dt.getData(TEXT_PLAIN); + return insertHTML(html, event); + } + }); + } + if (editor.options.askBeforePasteFromWord) { + editor.events.on('beforePaste', (event) => { + const dt = getDataTransfer(event); + if (event && dt && dt.getData && dt.getData(TEXT_HTML)) { + const processHTMLData = (html) => { + const buffer = editor.buffer.get(pluginKey); + if (isHTML(html) && buffer !== trimFragment(html)) { + if (isHTMLFromWord(html)) { + clearOrKeep(editor.i18n('The pasted content is coming from a Microsoft Word/Excel document. ' + + 'Do you want to keep the format or clean it up?'), editor.i18n('Word Paste Detected'), (agree) => { + if (agree === true) { + html = applyStyles(html); + if (editor.options.beautifyHTML && + editor.ownerWindow + .html_beautify) { + html = editor.ownerWindow.html_beautify(html); + } + } + if (agree === false) { + html = cleanFromWord(html); + } + if (agree === 0) { + html = stripTags(cleanFromWord(html)); + } + editor.selection.insertHTML(html); + editor.setEditorValue(); + }); + } + else { + insertHTML(html, event); + } + return false; + } + }; + if (dt.types && + Array.from(dt.types).indexOf('text/html') !== -1) { + const html = dt.getData(TEXT_HTML); + return processHTMLData(html); + } + if (event.type !== 'drop') { + const div = editor.create.div('', { + tabindex: -1, + contenteditable: true, + style: { + left: -9999, + top: 0, + width: 0, + height: '100%', + lineHeight: '140%', + overflow: 'hidden', + position: 'fixed', + zIndex: 2147483647, + wordBreak: 'break-all' + } + }); + editor.container.appendChild(div); + const selData = editor.selection.save(); + div.focus(); + let tick = 0; + const removeFakeFocus = () => { + Dom_Dom.safeRemove(div); + editor.selection && + editor.selection.restore(selData); + }; + const waitData = () => { + tick += 1; + if (div.childNodes && div.childNodes.length > 0) { + const pastedData = div.innerHTML; + removeFakeFocus(); + if (processHTMLData(pastedData) !== false) { + editor.selection.insertHTML(pastedData); + } + return; + } + if (tick < 5) { + setTimeout_setTimeout(waitData, 20); + } + else { + removeFakeFocus(); + } + }; + waitData(); + } + } + }); + } + if (editor.options.nl2brInPlainText) { + editor.events.on('processPaste', (event, text, type) => { + if (type === TEXT_PLAIN + ';' && !isHTML(text)) { + return nl2br(text); + } + }); + } +} + +// CONCATENATED MODULE: ./src/plugins/clipboard/cut.ts +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ + + + + +Config_Config.prototype.controls.cut = { + command: 'cut', + isDisable: (editor) => editor.selection.isCollapsed(), + tooltip: 'Cut selection' +}; +Config_Config.prototype.controls.copy = { + command: 'copy', + isDisable: (editor) => editor.selection.isCollapsed(), + tooltip: 'Copy selection' +}; +const pluginKey = 'clipboard'; +class cut_clipboard { + init(editor) { + editor.events + .on(`copy.${pluginKey} cut.${pluginKey}`, (event) => { + var _a, _b; + const selectedText = editor.selection.getHTML(); + const clipboardData = getDataTransfer(event) || + getDataTransfer(editor.editorWindow) || + getDataTransfer(event.originalEvent); + if (clipboardData) { + clipboardData.setData(TEXT_PLAIN, stripTags(selectedText)); + clipboardData.setData(TEXT_HTML, selectedText); + } + editor.buffer.set(pluginKey, selectedText); + if (event.type === 'cut') { + editor.selection.remove(); + editor.selection.focus(); + } + event.preventDefault(); + (_b = (_a = editor) === null || _a === void 0 ? void 0 : _a.events) === null || _b === void 0 ? void 0 : _b.fire('afterCopy', selectedText); + }); + } + destruct(editor) { + var _a, _b, _c, _d; + (_b = (_a = editor) === null || _a === void 0 ? void 0 : _a.buffer) === null || _b === void 0 ? void 0 : _b.set(pluginKey, ''); + (_d = (_c = editor) === null || _c === void 0 ? void 0 : _c.events) === null || _d === void 0 ? void 0 : _d.off('.' + pluginKey); + } +} + +// CONCATENATED MODULE: ./src/modules/Plugin.ts +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ + +class Plugin_Plugin extends Component_Component { + constructor(jodit) { + super(jodit); + this.destruct = this.destruct.bind(this, jodit); + jodit.events + .on('afterInit', this.afterInit.bind(this, jodit)) + .on('beforeDestruct', this.destruct); + } + init(jodit) { } + destruct() { + var _a, _b; + if (!this.isDestructed) { + (_b = (_a = this.jodit) === null || _a === void 0 ? void 0 : _a.events) === null || _b === void 0 ? void 0 : _b.off('beforeDestruct', this.destruct); + this.beforeDestruct(this.jodit); + super.destruct(); + } + } +} + +// CONCATENATED MODULE: ./src/plugins/clipboard/paste-storage.ts +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ + + + + + +class paste_storage_pasteStorage extends Plugin_Plugin { + constructor() { + super(...arguments); + this.currentIndex = 0; + this.list = []; + this.container = null; + this.listBox = null; + this.previewBox = null; + this.dialog = null; + this.paste = () => { + this.jodit.selection.focus(); + this.jodit.selection.insertHTML(this.list[this.currentIndex]); + if (this.currentIndex !== 0) { + const buffer = this.list[0]; + this.list[0] = this.list[this.currentIndex]; + this.list[this.currentIndex] = buffer; + } + this.dialog && this.dialog.close(); + this.jodit.setEditorValue(); + }; + this.onKeyDown = (e) => { + let index = this.currentIndex; + if ([KEY_UP, KEY_DOWN, KEY_ENTER].indexOf(e.which) === -1) { + return; + } + if (e.which === KEY_UP) { + if (index === 0) { + index = this.list.length - 1; + } + else { + index -= 1; + } + } + if (e.which === KEY_DOWN) { + if (index === this.list.length - 1) { + index = 0; + } + else { + index += 1; + } + } + if (e.which === KEY_ENTER) { + this.paste(); + return; + } + if (index !== this.currentIndex) { + this.selectIndex(index); + } + e.stopImmediatePropagation(); + e.preventDefault(); + }; + this.selectIndex = (index) => { + if (this.listBox) { + Array.from((this.listBox.childNodes)).forEach((a, i) => { + a.classList.remove('jodit_active'); + if (index === i && this.previewBox) { + a.classList.add('jodit_active'); + this.previewBox.innerHTML = this.list[index]; + a.focus(); + } + }); + } + this.currentIndex = index; + }; + this.showDialog = () => { + if (this.list.length < 2) { + return; + } + this.dialog || this.createDialog(); + if (this.listBox) { + this.listBox.innerHTML = ''; + } + if (this.previewBox) { + this.previewBox.innerHTML = ''; + } + this.list.forEach((html, index) => { + const a = this.jodit.ownerDocument.createElement('a'); + a.textContent = index + 1 + '. ' + html.replace(SPACE_REG_EXP, ''); + a.addEventListener('keydown', this.onKeyDown); + a.setAttribute('href', 'javascript:void(0)'); + a.setAttribute('data-index', index.toString()); + a.setAttribute('tab-index', '-1'); + this.listBox && this.listBox.appendChild(a); + }); + this.dialog && this.dialog.open(); + setTimeout_setTimeout(() => { + this.selectIndex(0); + }, 100); + }; + } + createDialog() { + this.dialog = new dialog_Dialog(this.jodit); + const pasteButton = this.jodit.create.fromHTML('' + + '' + + this.jodit.i18n('Paste') + + '' + + ''); + pasteButton.addEventListener('click', this.paste); + const cancelButton = this.jodit.create.fromHTML('' + + '' + + this.jodit.i18n('Cancel') + + '' + + ''); + cancelButton.addEventListener('click', this.dialog.close); + this.container = this.jodit.ownerDocument.createElement('div'); + this.container.classList.add('jodit_paste_storage'); + this.listBox = this.jodit.ownerDocument.createElement('div'); + this.previewBox = this.jodit.ownerDocument.createElement('div'); + this.container.appendChild(this.listBox); + this.container.appendChild(this.previewBox); + this.dialog.setTitle(this.jodit.i18n('Choose Content to Paste')); + this.dialog.setContent(this.container); + this.dialog.setFooter([pasteButton, cancelButton]); + this.jodit.events.on(this.listBox, 'click dblclick', (e) => { + const a = e.target; + if (a && a.nodeName === 'A' && a.hasAttribute('data-index')) { + this.selectIndex(parseInt(a.getAttribute('data-index') || '0', 10)); + } + if (e.type === 'dblclick') { + this.paste(); + } + return false; + }, 'a'); + } + afterInit() { + this.jodit.events.on('afterCopy', (html) => { + if (this.list.indexOf(html) !== -1) { + this.list.splice(this.list.indexOf(html), 1); + } + this.list.unshift(html); + if (this.list.length > 5) { + this.list.length = 5; + } + }); + this.jodit.registerCommand('showPasteStorage', { + exec: this.showDialog, + hotkeys: ['ctrl+shift+v', 'cmd+shift+v'] + }); + } + beforeDestruct() { + this.dialog && this.dialog.destruct(); + Dom_Dom.safeRemove(this.previewBox); + Dom_Dom.safeRemove(this.listBox); + Dom_Dom.safeRemove(this.container); + this.container = null; + this.listBox = null; + this.previewBox = null; + this.dialog = null; + this.list = []; + } +} + +// CONCATENATED MODULE: ./src/plugins/clipboard/copyformat.ts +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ + + + +const copyformat_pluginKey = 'copyformat'; +const copyStyles = [ + 'fontWeight', + 'fontStyle', + 'fontSize', + 'color', + 'margin', + 'padding', + 'borderWidth', + 'borderStyle', + 'borderColor', + 'borderRadius', + 'backgroundColor', + 'textDecorationLine', + 'fontFamily' +]; +const getStyle = (editor, key, box, defaultStyles) => { + let result = css_css(box, key); + if (result === defaultStyles[key]) { + if (box.parentNode && + box !== editor.editor && + box.parentNode !== editor.editor) { + result = getStyle(editor, key, box.parentNode, defaultStyles); + } + else { + result = undefined; + } + } + return result; +}; +const getStyles = (editor, box, defaultStyles) => { + const result = {}; + if (box) { + copyStyles.forEach((key) => { + result[key] = getStyle(editor, key, box, defaultStyles); + if (key.match(/border(Style|Color)/) && !result.borderWidth) { + result[key] = undefined; + } + }); + } + return result; +}; +Config_Config.prototype.controls.copyformat = { + exec: (editor, current) => { + if (current) { + if (editor.buffer.exists(copyformat_pluginKey)) { + editor.buffer.set(copyformat_pluginKey, false); + editor.events.off(editor.editor, 'mouseup.' + copyformat_pluginKey); + } + else { + const defaultStyles = {}, box = Dom_Dom.up(current, (elm) => elm && elm.nodeType !== Node.TEXT_NODE, editor.editor) || editor.editor; + const ideal = editor.create.inside.span(); + editor.editor.appendChild(ideal); + copyStyles.forEach((key) => { + defaultStyles[key] = css_css(ideal, key); + }); + if (ideal !== editor.editor) { + Dom_Dom.safeRemove(ideal); + } + const format = getStyles(editor, box, defaultStyles); + const onMouseDown = () => { + editor.buffer.set(copyformat_pluginKey, false); + const currentNode = editor.selection.current(); + if (currentNode) { + if (currentNode.nodeName === 'IMG') { + css_css(currentNode, format); + } + else { + editor.selection.applyCSS(format); + } + } + editor.events.off(editor.editor, 'mouseup.' + copyformat_pluginKey); + }; + editor.events.on(editor.editor, 'mouseup.' + copyformat_pluginKey, onMouseDown); + editor.buffer.set(copyformat_pluginKey, true); + } + } + }, + isActive: (editor) => !!editor.buffer.get(copyformat_pluginKey), + tooltip: 'Paint format' +}; + +// CONCATENATED MODULE: ./src/plugins/clipboard/index.ts + + + + + +// CONCATENATED MODULE: ./src/plugins/color.ts +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ + + +var color_TabsWidget = Widget_Widget.TabsWidget; +var ColorPickerWidget = Widget_Widget.ColorPickerWidget; + + +Config_Config.prototype.controls.brush = { + isActive: (editor, control, button) => { + if (!button) { + return true; + } + const current = editor.selection.current(), icon = button.container.querySelector('svg'); + if (icon && icon.style.fill) { + icon.style.removeProperty('fill'); + } + if (current && !button.isDisable()) { + const currentBpx = Dom_Dom.closest(current, elm => { + return (Dom_Dom.isBlock(elm, editor.editorWindow) || + (elm && + Dom_Dom.isNode(elm, editor.editorWindow) && + elm.nodeType === Node.ELEMENT_NODE)); + }, editor.editor) || editor.editor; + const colorHEX = css_css(currentBpx, 'color').toString(), bgHEX = css_css(currentBpx, 'background-color').toString(); + if (colorHEX !== css_css(editor.editor, 'color').toString()) { + icon && (icon.style.fill = colorHEX); + return true; + } + if (bgHEX !== css_css(editor.editor, 'background-color').toString()) { + icon && (icon.style.fill = bgHEX); + return true; + } + } + return false; + }, + popup: (editor, current, self, close) => { + let colorHEX = '', bg_color = '', tabs, currentElement = null; + if (current && + current !== editor.editor && + Dom_Dom.isNode(current, editor.editorWindow) && + current.nodeType === Node.ELEMENT_NODE) { + colorHEX = css_css(current, 'color').toString(); + bg_color = css_css(current, 'background-color').toString(); + currentElement = current; + } + const backgroundTag = ColorPickerWidget(editor, (value) => { + if (!currentElement) { + editor.execCommand('background', false, value); + } + else { + currentElement.style.backgroundColor = value; + } + close(); + }, bg_color); + const colorTab = ColorPickerWidget(editor, (value) => { + if (!currentElement) { + editor.execCommand('forecolor', false, value); + } + else { + currentElement.style.color = value; + } + close(); + }, colorHEX); + if (editor.options.colorPickerDefaultTab === 'background') { + tabs = { + Background: backgroundTag, + Text: colorTab + }; + } + else { + tabs = { + Text: colorTab, + Background: backgroundTag + }; + } + return color_TabsWidget(editor, tabs, currentElement); + }, + tooltip: 'Fill color or set the text color' +}; +function color_color(editor) { + const callback = (command, second, third) => { + const colorHEX = normalizeColor(third); + switch (command) { + case 'background': + editor.selection.applyCSS({ + backgroundColor: !colorHEX ? '' : colorHEX + }); + break; + case 'forecolor': + editor.selection.applyCSS({ + color: !colorHEX ? '' : colorHEX + }); + break; + } + editor.setEditorValue(); + return false; + }; + editor + .registerCommand('forecolor', callback) + .registerCommand('background', callback); +} + +// CONCATENATED MODULE: ./src/plugins/drag-and-drop.ts +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ + + + + +class drag_and_drop_DragAndDrop extends Plugin_Plugin { + constructor() { + super(...arguments); + this.isFragmentFromEditor = false; + this.isCopyMode = false; + this.startDragPoint = { x: 0, y: 0 }; + this.draggable = null; + this.bufferRange = null; + this.onDragEnd = () => { + if (this.draggable) { + Dom_Dom.safeRemove(this.draggable); + this.draggable = null; + } + this.isCopyMode = false; + }; + this.onDrag = (event) => { + if (this.draggable) { + if (!this.draggable.parentNode) { + this.jodit.ownerDocument.body.appendChild(this.draggable); + } + this.jodit.events.fire('hidePopup'); + css_css(this.draggable, { + left: event.clientX + 20, + top: event.clientY + 20 + }); + this.jodit.selection.insertCursorAtPoint(event.clientX, event.clientY); + event.preventDefault(); + event.stopPropagation(); + } + }; + this.onDrop = (event) => { + if (!event.dataTransfer || + !event.dataTransfer.files || + !event.dataTransfer.files.length) { + if (!this.isFragmentFromEditor && !this.draggable) { + this.jodit.events.fire('paste', event); + event.preventDefault(); + event.stopPropagation(); + return false; + } + const sel = this.jodit.selection.sel; + const range = this.bufferRange || + (sel && sel.rangeCount ? sel.getRangeAt(0) : null); + let fragment = null; + if (!this.draggable && range) { + fragment = this.isCopyMode + ? range.cloneContents() + : range.extractContents(); + } + else if (this.draggable) { + if (this.isCopyMode) { + const [tagName, attr] = this.draggable.getAttribute('data-is-file') === '1' + ? ['a', 'href'] + : ['img', 'src']; + fragment = this.jodit.editorDocument.createElement(tagName); + fragment.setAttribute(attr, this.draggable.getAttribute('data-src') || + this.draggable.getAttribute('src') || + ''); + if (tagName === 'a') { + fragment.textContent = fragment.getAttribute(attr) || ''; + } + } + else { + fragment = dataBind(this.draggable, 'target'); + } + } + else if (this.getText(event)) { + fragment = this.jodit.create.inside.fromHTML(this.getText(event)); + } + sel && sel.removeAllRanges(); + this.jodit.selection.insertCursorAtPoint(event.clientX, event.clientY); + if (fragment) { + this.jodit.selection.insertNode(fragment, false, false); + if (range && fragment.firstChild && fragment.lastChild) { + range.setStartBefore(fragment.firstChild); + range.setEndAfter(fragment.lastChild); + this.jodit.selection.selectRange(range); + this.jodit.events.fire('synchro'); + } + if (fragment.nodeName === 'IMG' && this.jodit.events) { + this.jodit.events.fire('afterInsertImage', fragment); + } + } + event.preventDefault(); + event.stopPropagation(); + } + this.isFragmentFromEditor = false; + }; + this.onDragStart = (event) => { + let target = event.target; + this.onDragEnd(); + this.isFragmentFromEditor = Dom_Dom.isOrContains(this.jodit.editor, target, true); + this.isCopyMode = this.isFragmentFromEditor ? ctrlKey(event) : true; + if (this.isFragmentFromEditor) { + const sel = this.jodit.selection.sel; + const range = sel && sel.rangeCount ? sel.getRangeAt(0) : null; + if (range) { + this.bufferRange = range.cloneRange(); + } + } + else { + this.bufferRange = null; + } + this.startDragPoint.x = event.clientX; + this.startDragPoint.y = event.clientY; + if (target.nodeType === Node.ELEMENT_NODE && + target.matches('.jodit_filebrowser_files_item')) { + target = target.querySelector('img'); + } + if (target.nodeName === 'IMG') { + this.draggable = target.cloneNode(true); + dataBind(this.draggable, 'target', target); + css_css(this.draggable, { + 'z-index': 100000000000000, + 'pointer-events': 'none', + position: 'fixed', + display: 'inlin-block', + left: this.startDragPoint.x, + top: this.startDragPoint.y, + width: target.offsetWidth, + height: target.offsetHeight + }); + } + }; + this.getDataTransfer = (event) => { + return event.dataTransfer || new DataTransfer(); + }; + this.getText = (event) => { + const dt = this.getDataTransfer(event); + return dt.getData(TEXT_HTML) || dt.getData(TEXT_PLAIN); + }; + } + afterInit() { + this.jodit.events + .on(window, 'dragover', this.onDrag) + .on([window, this.jodit.editorDocument, this.jodit.editor], 'dragstart', this.onDragStart) + .on('drop', this.onDrop) + .on(window, 'dragend drop mouseup', this.onDragEnd); + } + beforeDestruct() { + this.onDragEnd(); + } +} + +// CONCATENATED MODULE: ./src/plugins/drag-and-drop-element.ts +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ + + + + +Config_Config.prototype.draggableTags = ['img', 'a', 'jodit-media', 'jodit']; +class drag_and_drop_element_DragAndDropElement extends Plugin_Plugin { + constructor() { + super(...arguments); + this.dragList = []; + this.isCopyMode = false; + this.draggable = null; + this.wasMoved = false; + this.timeout = 0; + this.onDrag = throttle((event) => { + if (!this.draggable) { + return; + } + this.wasMoved = true; + this.jodit.events.fire('hidePopup hideResizer'); + if (!this.draggable.parentNode) { + this.jodit.ownerDocument.body.appendChild(this.draggable); + } + css_css(this.draggable, { + left: event.clientX + 20, + top: event.clientY + 20 + }); + this.jodit.selection.insertCursorAtPoint(event.clientX, event.clientY); + }, this.jodit.defaultTimeout); + this.onDragStart = (event) => { + let target = event.target, last = null; + if (!this.dragList.length) { + return; + } + do { + if (this.dragList.indexOf(target.nodeName.toLowerCase()) !== -1) { + if (!last || + (target.firstChild === last && target.lastChild === last)) { + last = target; + } + } + target = target.parentNode; + } while (target && target !== this.jodit.editor); + if (!last) { + return; + } + this.isCopyMode = ctrlKey(event); + this.onDragEnd(); + this.timeout = setTimeout_setTimeout((lastNode) => { + if (!lastNode) { + return; + } + this.draggable = lastNode.cloneNode(true); + dataBind(this.draggable, 'target', lastNode); + css_css(this.draggable, { + 'z-index': 100000000000000, + 'pointer-events': 'none', + position: 'fixed', + display: 'inlin-block', + left: event.clientX, + top: event.clientY, + width: lastNode.offsetWidth, + height: lastNode.offsetHeight + }); + }, this.jodit.defaultTimeout, last); + event.preventDefault(); + }; + this.onDragEnd = () => { + window.clearTimeout(this.timeout); + if (this.draggable) { + Dom_Dom.safeRemove(this.draggable); + this.draggable = null; + this.wasMoved = false; + } + }; + this.onDrop = () => { + if (!this.draggable || !this.wasMoved) { + this.onDragEnd(); + return; + } + let fragment = dataBind(this.draggable, 'target'); + this.onDragEnd(); + if (this.isCopyMode) { + fragment = fragment.cloneNode(true); + } + this.jodit.selection.insertNode(fragment, true, false); + if (fragment.nodeName === 'IMG' && this.jodit.events) { + this.jodit.events.fire('afterInsertImage', fragment); + } + this.jodit.events.fire('synchro'); + }; + } + afterInit() { + this.dragList = this.jodit.options.draggableTags + ? splitArray(this.jodit.options.draggableTags) + .filter(item => item) + .map((item) => item.toLowerCase()) + : []; + if (!this.dragList.length) { + return; + } + this.jodit.events + .on(this.jodit.editor, 'mousemove touchmove', this.onDrag) + .on(this.jodit.editor, 'mousedown touchstart dragstart', this.onDragStart) + .on('mouseup touchend', this.onDrop) + .on(window, 'mouseup touchend', this.onDragEnd); + } + beforeDestruct() { + this.onDragEnd(); + } +} + +// CONCATENATED MODULE: ./src/plugins/enter.ts +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ + + + +const insertParagraph = (editor, fake, wrapperTag, style) => { + const p = editor.create.inside.element(wrapperTag), helper_node = editor.create.inside.element('br'); + p.appendChild(helper_node); + if (style && style.cssText) { + p.setAttribute('style', style.cssText); + } + editor.selection.insertNode(p, false, false); + editor.selection.setCursorBefore(helper_node); + const range = editor.editorDocument.createRange(); + range.setStartBefore(wrapperTag.toLowerCase() !== 'br' ? helper_node : p); + range.collapse(true); + editor.selection.selectRange(range); + Dom_Dom.safeRemove(fake); + scrollIntoView(p, editor.editor, editor.editorDocument); + editor.events && editor.events.fire('synchro'); + return p; +}; +function enter_enter(editor) { + if (!editor.options.enterBlock) { + editor.options.enterBlock = + editor.options.enter.toLowerCase() === 'br' + ? PARAGRAPH + : editor.options.enter.toLowerCase(); + } + editor.events.on('keydown', (event) => { + if (event.which === KEY_ENTER) { + const beforeEnter = editor.events.fire('beforeEnter', event); + if (beforeEnter !== undefined) { + return beforeEnter; + } + if (!editor.selection.isCollapsed()) { + editor.execCommand('Delete'); + } + editor.selection.focus(); + let current = editor.selection.current(false); + const sel = editor.selection.sel; + let range = editor.selection.range; + if (!current || current === editor.editor) { + editor.selection.current(); + current = editor.create.inside.text(INVISIBLE_SPACE); + if (sel && sel.rangeCount) { + range.insertNode(current); + } + else { + editor.editor.appendChild(current); + } + range.selectNode(current); + range.collapse(false); + if (sel) { + sel.removeAllRanges(); + sel.addRange(range); + } + } + let currentBox = current + ? Dom_Dom.up(current, node => Dom_Dom.isBlock(node, editor.editorWindow), editor.editor) + : false; + const isLi = currentBox && currentBox.nodeName === 'LI'; + if (!isLi && + (editor.options.enter.toLowerCase() === + BR.toLowerCase() || + event.shiftKey || + Dom_Dom.closest(current, 'PRE|BLOCKQUOTE', editor.editor))) { + const br = editor.create.inside.element('br'); + editor.selection.insertNode(br, true); + scrollIntoView(br, editor.editor, editor.editorDocument); + return false; + } + if (!currentBox && + current && + !Dom_Dom.prev(current, (elm) => Dom_Dom.isBlock(elm, editor.editorWindow) || + (!!elm && Dom_Dom.isImage(elm, editor.editorWindow)), editor.editor)) { + let needWrap = current; + Dom_Dom.up(needWrap, node => { + if (node && + node.hasChildNodes() && + node !== editor.editor) { + needWrap = node; + } + }, editor.editor); + currentBox = Dom_Dom.wrapInline(needWrap, editor.options.enter, editor); + if (Dom_Dom.isEmpty(currentBox)) { + const helper_node = editor.editorDocument.createElement('br'); + currentBox.appendChild(helper_node); + editor.selection.setCursorBefore(helper_node); + } + range = + sel && sel.rangeCount + ? sel.getRangeAt(0) + : editor.editorDocument.createRange(); + } + let fake = false, insertNew = false; + if (currentBox) { + if (!Dom_Dom.canSplitBlock(currentBox, editor.editorWindow)) { + const br = editor.create.inside.element('br'); + editor.selection.insertNode(br, false); + editor.selection.setCursorAfter(br); + return false; + } + if (isLi) { + if (Dom_Dom.isEmpty(currentBox)) { + let fakeTextNode = false; + const ul = Dom_Dom.closest(currentBox, 'ol|ul', editor.editor); + if (!Dom_Dom.prev(currentBox, (elm) => elm && elm.nodeName === 'LI', ul)) { + fakeTextNode = editor.selection.setCursorBefore(ul); + } + else if (!Dom_Dom.next(currentBox, (elm) => elm && elm.nodeName === 'LI', ul)) { + fakeTextNode = editor.selection.setCursorAfter(ul); + } + else { + const leftRange = editor.editorDocument.createRange(); + leftRange.setStartBefore(ul); + leftRange.setEndAfter(currentBox); + const fragment = leftRange.extractContents(); + if (ul.parentNode) { + ul.parentNode.insertBefore(fragment, ul); + } + fakeTextNode = editor.selection.setCursorBefore(ul); + } + Dom_Dom.safeRemove(currentBox); + insertParagraph(editor, fakeTextNode, editor.options.enter); + if (!$$('li', ul).length) { + Dom_Dom.safeRemove(ul); + } + return false; + } + } + if (editor.selection.cursorInTheEdge(true, currentBox)) { + fake = editor.selection.setCursorBefore(currentBox); + insertParagraph(editor, fake, isLi ? 'li' : editor.options.enter, currentBox.style); + currentBox && + editor.selection.setCursorIn(currentBox, true); + return false; + } + if (editor.selection.cursorInTheEdge(false, currentBox) === + false) { + const leftRange = editor.editorDocument.createRange(); + leftRange.setStartBefore(currentBox); + leftRange.setEnd(range.startContainer, range.startOffset); + const fragment = leftRange.extractContents(); + if (currentBox.parentNode) { + currentBox.parentNode.insertBefore(fragment, currentBox); + } + editor.selection.setCursorIn(currentBox, true); + } + else { + fake = editor.selection.setCursorAfter(currentBox); + } + } + else { + insertNew = true; + } + if (insertNew || fake) { + insertParagraph(editor, fake, isLi ? 'li' : editor.options.enter, currentBox ? currentBox.style : void 0); + } + return false; + } + }); +} + +// CONCATENATED MODULE: ./src/plugins/error-messages.ts +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ + + + + +Config_Config.prototype.showMessageErrors = true; +Config_Config.prototype.showMessageErrorTime = 3000; +Config_Config.prototype.showMessageErrorOffsetPx = 3; +function errorMessages(editor) { + if (editor.options.showMessageErrors) { + let height; + const messagesBox = editor.create.div('jodit_error_box_for_messages'), recalcOffsets = () => { + height = 5; + Array.from((messagesBox.childNodes)).forEach((elm) => { + css_css(messagesBox, 'bottom', height + 'px'); + height += + elm.offsetWidth + + editor.options.showMessageErrorOffsetPx; + }); + }; + editor.workplace.appendChild(messagesBox); + editor.events + .on('beforeDestruct', () => { + Dom_Dom.safeRemove(messagesBox); + }) + .on('errorMessage', (message, className, timeout) => { + const newmessage = editor.create.div('active ' + (className || ''), message); + messagesBox.appendChild(newmessage); + recalcOffsets(); + setTimeout_setTimeout(() => { + newmessage.classList.remove('active'); + setTimeout_setTimeout(() => { + Dom_Dom.safeRemove(newmessage); + recalcOffsets(); + }, 300); + }, timeout || editor.options.showMessageErrorTime); + }); + } +} + +// CONCATENATED MODULE: ./src/plugins/font.ts +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ + + + +Config_Config.prototype.controls.fontsize = { + command: 'fontSize', + list: [ + '8', + '9', + '10', + '11', + '12', + '14', + '16', + '18', + '24', + '30', + '36', + '48', + '60', + '72', + '96' + ], + template: (editor, key, value) => value, + tooltip: 'Font size', + isActiveChild: (editor, control) => { + const current = editor.selection.current(); + if (current) { + const currentBpx = Dom_Dom.closest(current, elm => { + return (Dom_Dom.isBlock(elm, editor.editorWindow) || + (elm && + Dom_Dom.isNode(elm, editor.editorWindow) && + elm.nodeType === Node.ELEMENT_NODE)); + }, editor.editor) || editor.editor; + const fontSize = css_css(currentBpx, 'font-size'); + return Boolean(fontSize && + control.args && + control.args[1].toString() === fontSize.toString()); + } + return false; + }, + isActive: (editor) => { + const current = editor.selection.current(); + if (current) { + const currentBpx = Dom_Dom.closest(current, elm => { + return (Dom_Dom.isBlock(elm, editor.editorWindow) || + (elm && + Dom_Dom.isNode(elm, editor.editorWindow) && + elm.nodeType === Node.ELEMENT_NODE)); + }, editor.editor) || editor.editor; + return (css_css(currentBpx, 'font-size').toString() !== + css_css(editor.editor, 'font-size').toString()); + } + return false; + } +}; +Config_Config.prototype.controls.font = { + command: 'fontname', + exec: (editor, event, control) => { + editor.execCommand(control.command, false, control.args ? control.args[0] : undefined); + }, + list: { + 'Helvetica,sans-serif': 'Helvetica', + 'Arial,Helvetica,sans-serif': 'Arial', + 'Georgia,serif': 'Georgia', + 'Impact,Charcoal,sans-serif': 'Impact', + 'Tahoma,Geneva,sans-serif': 'Tahoma', + "'Times New Roman',Times,serif": 'Times New Roman', + 'Verdana,Geneva,sans-serif': 'Verdana' + }, + template: (editor, key, value) => { + return `${value}`; + }, + isActiveChild: (editor, control) => { + const current = editor.selection.current(), normFonts = (fontValue) => { + return fontValue + .toLowerCase() + .replace(/['"]+/g, '') + .replace(/[^a-z0-9]+/g, ','); + }; + if (current) { + const currentBpx = Dom_Dom.closest(current, elm => { + return (Dom_Dom.isBlock(elm, editor.editorWindow) || + (elm && + Dom_Dom.isNode(elm, editor.editorWindow) && + elm.nodeType === Node.ELEMENT_NODE)); + }, editor.editor) || editor.editor; + const fontFamily = css_css(currentBpx, 'font-family').toString(); + return Boolean(fontFamily && + control.args && + normFonts(control.args[0].toString()) === + normFonts(fontFamily)); + } + return false; + }, + isActive: (editor) => { + const current = editor.selection.current(); + if (current) { + const currentBpx = Dom_Dom.closest(current, (elm) => { + return (Dom_Dom.isBlock(elm, editor.editorWindow) || + (Dom_Dom.isNode(elm, editor.editorWindow) && + elm && + elm.nodeType === Node.ELEMENT_NODE)); + }, editor.editor) || editor.editor; + return (css_css(currentBpx, 'font-family').toString() !== + css_css(editor.editor, 'font-family').toString()); + } + return false; + }, + tooltip: 'Font family' +}; +function font_font(editor) { + const callback = (command, second, third) => { + switch (command) { + case 'fontsize': + editor.selection.applyCSS({ + fontSize: normalizeSize(third) + }); + break; + case 'fontname': + editor.selection.applyCSS({ + fontFamily: third + }); + break; + } + editor.events.fire('synchro'); + return false; + }; + editor + .registerCommand('fontsize', callback) + .registerCommand('fontname', callback); +} + +// CONCATENATED MODULE: ./src/plugins/format-block.ts +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ + + + +Config_Config.prototype.controls.paragraph = { + command: 'formatBlock', + getLabel: (editor, btn, button) => { + const current = editor.selection.current(); + if (current && editor.options.textIcons) { + const currentBox = Dom_Dom.closest(current, node => Dom_Dom.isBlock(node, editor.editorWindow), editor.editor) || editor.editor, currentValue = currentBox.nodeName.toLowerCase(), list = btn.list; + if (button && + btn.data && + btn.data.currentValue !== currentValue && + btn.list && + list[currentValue]) { + button.textBox.innerHTML = `${editor.i18n(list[currentValue])}`; + button.textBox.firstChild.classList.add('jodit_icon'); + btn.data.currentValue = currentValue; + } + } + return false; + }, + exec: (editor, event, control) => { + editor.execCommand(control.command, false, control.args ? control.args[0] : undefined); + }, + data: { + currentValue: 'left' + }, + list: { + p: 'Normal', + h1: 'Heading 1', + h2: 'Heading 2', + h3: 'Heading 3', + h4: 'Heading 4', + blockquote: 'Quote' + }, + isActiveChild: (editor, control) => { + const current = editor.selection.current(); + if (current) { + const currentBox = Dom_Dom.closest(current, node => Dom_Dom.isBlock(node, editor.editorWindow), editor.editor); + return (currentBox && + currentBox !== editor.editor && + control.args !== undefined && + currentBox.nodeName.toLowerCase() === control.args[0]); + } + return false; + }, + isActive: (editor, control) => { + const current = editor.selection.current(); + if (current) { + const currentBpx = Dom_Dom.closest(current, node => Dom_Dom.isBlock(node, editor.editorWindow), editor.editor); + return (currentBpx && + currentBpx !== editor.editor && + control.list !== undefined && + currentBpx.nodeName.toLowerCase() !== 'p' && + control.list[currentBpx.nodeName.toLowerCase()] !== undefined); + } + return false; + }, + template: (editor, key, value) => { + return ('<' + + key + + ' class="jodit_list_element">' + + editor.i18n(value) + + ''); + }, + tooltip: 'Insert format block' +}; +function formatBlock(editor) { + editor.registerCommand('formatblock', (command, second, third) => { + editor.selection.focus(); + let work = false; + editor.selection.eachSelection((current) => { + const selectionInfo = editor.selection.save(); + let currentBox = current + ? Dom_Dom.up(current, node => Dom_Dom.isBlock(node, editor.editorWindow), editor.editor) + : false; + if ((!currentBox || currentBox.nodeName === 'LI') && current) { + currentBox = Dom_Dom.wrapInline(current, editor.options.enter, editor); + } + if (!currentBox) { + editor.selection.restore(selectionInfo); + return; + } + if (!currentBox.tagName.match(/TD|TH|TBODY|TABLE|THEAD/i)) { + if (third === editor.options.enterBlock.toLowerCase() && + currentBox.parentNode && + currentBox.parentNode.nodeName === 'LI') { + Dom_Dom.unwrap(currentBox); + } + else { + Dom_Dom.replace(currentBox, third, true, false, editor.editorDocument); + } + } + else { + if (!editor.selection.isCollapsed()) { + editor.selection.applyCSS({}, third); + } + else { + Dom_Dom.wrapInline(current, third, editor); + } + } + work = true; + editor.selection.restore(selectionInfo); + }); + if (!work) { + const currentBox = editor.editorDocument.createElement(third); + currentBox.innerHTML = INVISIBLE_SPACE; + editor.selection.insertNode(currentBox, false); + editor.selection.setCursorIn(currentBox); + } + editor.setEditorValue(); + return false; + }); +} + +// CONCATENATED MODULE: ./src/plugins/fullsize.ts +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ + + + + +Config_Config.prototype.fullsize = false; +Config_Config.prototype.globalFullsize = true; +Config_Config.prototype.controls.fullsize = { + exec: (editor) => { + editor.toggleFullSize(); + }, + isActive: (editor) => editor.isFullSize(), + getLabel: (editor, btn, button) => { + const mode = editor.isFullSize() ? 'shrink' : 'fullsize'; + if (button) { + button.textBox.innerHTML = !editor.options.textIcons + ? ToolbarIcon.getIcon(mode) + : `${editor.i18n(mode)}`; + button.textBox.firstChild.classList.add('jodit_icon'); + } + }, + tooltip: 'Open editor in fullsize', + mode: MODE_SOURCE + MODE_WYSIWYG +}; +function fullsize(editor) { + let shown = false, oldHeight = 0, oldWidth = 0, wasToggled = false; + const resize = () => { + if (editor.events) { + if (shown) { + oldHeight = css_css(editor.container, 'height'); + oldWidth = css_css(editor.container, 'width'); + css_css(editor.container, { + height: editor.ownerWindow.innerHeight, + width: editor.ownerWindow.innerWidth + }); + wasToggled = true; + } + else if (wasToggled) { + css_css(editor.container, { + height: oldHeight || 'auto', + width: oldWidth || 'auto' + }); + } + } + }, toggle = (enable) => { + var _a, _b; + if (!editor.container) { + return; + } + if (enable === undefined) { + enable = !editor.container.classList.contains('jodit_fullsize'); + } + editor.options.fullsize = enable; + shown = enable; + editor.container.classList.toggle('jodit_fullsize', enable); + if (editor.toolbar) { + if (!enable) { + (_a = editor.toolbar.getParentContainer()) === null || _a === void 0 ? void 0 : _a.appendChild(editor.toolbar.container); + } + else { + (_b = editor.container.querySelector('.jodit_toolbar_container')) === null || _b === void 0 ? void 0 : _b.appendChild(editor.toolbar.container); + } + css_css(editor.toolbar.container, 'width', 'auto'); + } + if (editor.options.globalFullsize) { + let node = editor.container.parentNode; + while (node && node.nodeType !== Node.DOCUMENT_NODE) { + node.classList.toggle('jodit_fullsize_box', enable); + node = node.parentNode; + } + resize(); + } + editor.events.fire('afterResize'); + }; + if (editor.options.globalFullsize) { + editor.events.on(editor.ownerWindow, 'resize', resize); + } + editor.events + .on('afterInit afterOpen', () => { + var _a, _b; + editor.toggleFullSize((_b = (_a = editor) === null || _a === void 0 ? void 0 : _a.options) === null || _b === void 0 ? void 0 : _b.fullsize); + }) + .on('toggleFullSize', toggle) + .on('beforeDestruct beforeClose', () => { + toggle(false); + }) + .on('beforeDestruct', () => { + editor.events && + editor.events.off(editor.ownerWindow, 'resize', resize); + }); +} + +// CONCATENATED MODULE: ./src/plugins/hotkeys.ts +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ + + + +Config_Config.prototype.commandToHotkeys = { + removeFormat: ['ctrl+shift+m', 'cmd+shift+m'], + insertOrderedList: ['ctrl+shift+7', 'cmd+shift+7'], + insertUnorderedList: ['ctrl+shift+8, cmd+shift+8'], + selectall: ['ctrl+a', 'cmd+a'] +}; +class hotkeys_hotkeys extends Plugin_Plugin { + constructor() { + super(...arguments); + this.onKeyPress = (event) => { + const special = this.specialKeys[event.which], character = (event.key || String.fromCharCode(event.which)).toLowerCase(); + const modif = [special || character]; + ['alt', 'ctrl', 'shift', 'meta'].forEach(specialKey => { + if (event[specialKey + 'Key'] && special !== specialKey) { + modif.push(specialKey); + } + }); + return normalizeKeyAliases(modif.join('+')); + }; + this.specialKeys = { + 8: 'backspace', + 9: 'tab', + 10: 'return', + 13: 'return', + 16: 'shift', + 17: 'ctrl', + 18: 'alt', + 19: 'pause', + 20: 'capslock', + 27: 'esc', + 32: 'space', + 33: 'pageup', + 34: 'pagedown', + 35: 'end', + 36: 'home', + 37: 'left', + 38: 'up', + 39: 'right', + 40: 'down', + 45: 'insert', + 46: 'del', + 59: ';', + 61: '=', + 91: 'meta', + 96: '0', + 97: '1', + 98: '2', + 99: '3', + 100: '4', + 101: '5', + 102: '6', + 103: '7', + 104: '8', + 105: '9', + 106: '*', + 107: '+', + 109: '-', + 110: '.', + 111: '/', + 112: 'f1', + 113: 'f2', + 114: 'f3', + 115: 'f4', + 116: 'f5', + 117: 'f6', + 118: 'f7', + 119: 'f8', + 120: 'f9', + 121: 'f10', + 122: 'f11', + 123: 'f12', + 144: 'numlock', + 145: 'scroll', + 173: '-', + 186: ';', + 187: '=', + 188: ',', + 189: '-', + 190: '.', + 191: '/', + 192: '`', + 219: '[', + 220: '\\', + 221: ']', + 222: "'" + }; + } + afterInit(editor) { + const commands = Object.keys(editor.options.commandToHotkeys); + commands.forEach((commandName) => { + const shortcuts = editor.options.commandToHotkeys[commandName]; + if (shortcuts) { + editor.registerHotkeyToCommand(shortcuts, commandName); + } + }); + let itIsHotkey = false; + editor.events + .on('keydown.hotkeys', (event) => { + const shortcut = this.onKeyPress(event); + const resultOfFire = this.jodit.events.fire(shortcut + '.hotkey', event.type); + if (resultOfFire === false) { + itIsHotkey = true; + editor.events.stopPropagation('keydown'); + return false; + } + }, void 0, void 0, true) + .on('keyup.hotkeys', () => { + if (itIsHotkey) { + itIsHotkey = false; + editor.events.stopPropagation('keyup'); + return false; + } + }, void 0, void 0, true); + } + beforeDestruct(jodit) { + if (jodit.events) { + jodit.events.off('.hotkeys'); + } + } +} + +// CONCATENATED MODULE: ./src/plugins/iframe.ts +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ + + + + +Config_Config.prototype.iframeBaseUrl = ''; +Config_Config.prototype.iframeDefaultSrc = 'about:blank'; +Config_Config.prototype.iframeStyle = + 'html{' + + 'margin: 0px;' + + 'min-height: 100%;' + + '}' + + 'body{' + + 'box-sizing: border-box;' + + 'font-size: 13px;' + + ' line-height: 1.6;' + + 'padding:10px;' + + 'background:transparent;' + + 'color:#000;' + + 'position:' + + 'relative;' + + 'z-index: 2;' + + 'user-select:auto;' + + 'margin:0px;' + + 'overflow:auto;' + + '}' + + 'table{' + + 'width:100%;' + + 'border: none;' + + 'border-collapse:collapse;' + + 'empty-cells: show;' + + 'max-width: 100%;' + + '}' + + 'th,td{' + + 'padding: 2px 5px;' + + 'border:1px solid #ccc;' + + '-webkit-user-select:text;' + + '-moz-user-select:text;' + + '-ms-user-select:text;' + + 'user-select:text' + + '}' + + 'td[data-jodit-selected-cell],' + + 'th[data-jodit-selected-cell]{' + + 'border: 1px double #1e88e5' + + '}' + + 'p{' + + 'margin-top:0;' + + '}' + + '.jodit_editor .jodit_iframe_wrapper{' + + 'display: block;' + + 'clear: both;' + + 'user-select: none;' + + 'position: relative;' + + '}' + + '.jodit_editor .jodit_iframe_wrapper:after {' + + 'position:absolute;' + + 'content:"";' + + 'z-index:1;' + + 'top:0;' + + 'left:0;' + + 'right: 0;' + + 'bottom: 0;' + + 'cursor: pointer;' + + 'display: block;' + + 'background: rgba(0, 0, 0, 0);' + + '} ' + + '.jodit_disabled{' + + 'user-select: none;' + + '-o-user-select: none;' + + '-moz-user-select: none;' + + '-khtml-user-select: none;' + + '-webkit-user-select: none;' + + '-ms-user-select: none' + + '}'; +Config_Config.prototype.iframeCSSLinks = []; +function iframe_iframe(editor) { + editor.events + .on('afterSetMode', () => { + if (editor.isEditorMode()) { + editor.selection.focus(); + } + }) + .on('generateDocumentStructure.iframe', (__doc, jodit) => { + const doc = __doc || jodit.iframe.contentWindow.document; + doc.open(); + doc.write('' + + '' + + '' + + 'Jodit Editor' + + (jodit.options.iframeBaseUrl + ? '' + : '') + + '' + + '' + + ''); + doc.close(); + if (jodit.options.iframeCSSLinks) { + jodit.options.iframeCSSLinks.forEach(href => { + const link = doc.createElement('link'); + link.setAttribute('rel', 'stylesheet'); + link.setAttribute('href', href); + doc.head && doc.head.appendChild(link); + }); + } + if (jodit.options.iframeStyle) { + const style = doc.createElement('style'); + style.innerHTML = jodit.options.iframeStyle; + doc.head && doc.head.appendChild(style); + } + }) + .on('createEditor', async () => { + if (!editor.options.iframe) { + return; + } + delete editor.editor; + const iframe = editor.create.element('iframe'); + iframe.style.display = 'block'; + iframe.src = 'about:blank'; + iframe.className = 'jodit_wysiwyg_iframe'; + iframe.setAttribute('allowtransparency', 'true'); + iframe.setAttribute('tabindex', editor.options.tabIndex.toString()); + iframe.setAttribute('frameborder', '0'); + editor.workplace.appendChild(iframe); + editor.iframe = iframe; + await editor.events.fire('generateDocumentStructure.iframe', null, editor); + const doc = editor.iframe.contentWindow.document; + editor.editorDocument = doc; + editor.editorWindow = editor.iframe.contentWindow; + editor.create.inside.setDocument(doc); + editor.editor = doc.body; + if (editor.options.height === 'auto') { + doc.documentElement && + (doc.documentElement.style.overflowY = 'hidden'); + const resizeIframe = throttle(() => { + if (editor.editor && + editor.iframe && + editor.options.height === 'auto') { + css_css(editor.iframe, 'height', editor.editor.offsetHeight); + } + }, editor.defaultTimeout / 2); + editor.events + .on('change afterInit afterSetMode resize', resizeIframe) + .on([ + editor.iframe, + editor.editorWindow, + doc.documentElement + ], 'load', resizeIframe) + .on(doc, 'readystatechange DOMContentLoaded', resizeIframe); + } + (e => { + e.matches || (e.matches = Element.prototype.matches); + })(editor.editorWindow.Element.prototype); + if (editor.editorDocument.documentElement) { + editor.events + .on(editor.editorDocument.documentElement, 'mousedown touchend', () => { + if (!editor.selection.isFocused()) { + editor.selection.focus(); + editor.selection.setCursorIn(editor.editor); + } + }) + .on(editor.editorWindow, 'mousedown touchstart keydown keyup touchend click mouseup mousemove scroll', (e) => { + editor.events && + editor.events.fire && + editor.events.fire(editor.ownerWindow, e); + }); + } + return false; + }); +} + +// CONCATENATED MODULE: ./src/plugins/image-processor.ts +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ + +const JODIT_IMAGE_PROCESSOR_BINDED = '__jodit_imageprocessor_binded'; +function imageProcessor(editor) { + editor.events.on('change afterInit', debounce(() => { + if (editor.editor) { + $$('img', editor.editor).forEach((elm) => { + if (!elm[JODIT_IMAGE_PROCESSOR_BINDED]) { + elm[JODIT_IMAGE_PROCESSOR_BINDED] = true; + if (!elm.complete) { + elm.addEventListener('load', function ElementOnLoad() { + editor.events && + editor.events.fire && + editor.events.fire('resize'); + elm.removeEventListener('load', ElementOnLoad); + }); + } + editor.events.on(elm, 'mousedown touchstart', () => { + editor.selection.select(elm); + }); + } + }); + } + }, editor.defaultTimeout)); +} + +// CONCATENATED MODULE: ./src/plugins/image-properties.ts +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ + + + + + + +var image_properties_TabsWidget = Widget_Widget.TabsWidget; +var image_properties_FileSelectorWidget = Widget_Widget.FileSelectorWidget; + +Config_Config.prototype.image = { + openOnDblClick: true, + editSrc: true, + useImageEditor: true, + editTitle: true, + editAlt: true, + editLink: true, + editSize: true, + editBorderRadius: true, + editMargins: true, + editClass: true, + editStyle: true, + editId: true, + editAlign: true, + showPreview: true, + selectImageAfterClose: true +}; +function imageProperties(editor) { + const i18n = editor.i18n, gi = ToolbarIcon.getIcon.bind(ToolbarIcon), opt = editor.options, dom = editor.create.fromHTML.bind(editor.create); + const open = function (e) { + if (opt.readonly) { + return; + } + e && e.stopImmediatePropagation(); + const image = this, dialog = new dialog_Dialog(editor), buttons = { + check: dom(`${gi('check')}${i18n('Ok')}`), + cancel: dom(`${gi('cancel')}${i18n('Cancel')}`), + remove: dom(`${gi('bin')}${i18n('Delete')}`) + }, prop = dom(`
+
+
+
+
+ +
+
+ + ${gi('lock')} + +
+
+
+
+
+
`), positionTab = dom(`
+ +
+ + ${gi('lock')} + + + +
+
+
+ + +
+
+ + +
+
+ + +
+
+ + +
+
+ + +
`), hasFbUrl = opt.filebrowser.ajax.url || opt.uploader.url, hasEditor = opt.image.useImageEditor, mainTab = dom(`
+ + +
+
+ + +
+
+ + +
+
+ + +
+
+
+ + ${i18n('Open link in new tab')} +
+
`), ratio = image.naturalWidth / image.naturalHeight || 1, $w = prop.querySelector('.imageWidth'), $h = prop.querySelector('.imageHeight'), updateAlign = () => { + if (image.style.cssFloat && + ['left', 'right'].indexOf(image.style.cssFloat.toLowerCase()) !== -1) { + val_val(prop, '.align', css_css(image, 'float')); + } + else { + if (css_css(image, 'display') === 'block' && + image.style.marginLeft === 'auto' && + image.style.marginRight === 'auto') { + val_val(prop, '.align', 'center'); + } + } + }, updateBorderRadius = () => { + val_val(prop, '.border_radius', (parseInt(image.style.borderRadius || '0', 10) || '0').toString()); + }, updateId = () => { + val_val(prop, '.id', image.getAttribute('id') || ''); + }, updateStyle = () => { + val_val(prop, '.style', image.getAttribute('style') || ''); + }, updateClasses = () => { + val_val(prop, '.classes', (image.getAttribute('class') || '').replace(/jodit_focused_image[\s]*/, '')); + }, updateMargins = () => { + if (!opt.image.editMargins) { + return; + } + let notequal = false; + $$('.margins', prop).forEach((elm) => { + const id = elm.getAttribute('data-id') || ''; + let value = image.style[id]; + if (!value) { + return; + } + if (/^[0-9]+(px)?$/.test(value)) { + value = parseInt(value, 10); + } + elm.value = value.toString() || ''; + if (!notequal && + id !== 'marginTop' && + elm.value !== + val_val(prop, '.marginTop')) { + notequal = true; + } + }); + lockMargin = !notequal; + const lock_margin = prop.querySelector('.jodit_lock_margin'); + if (lock_margin) { + lock_margin.innerHTML = gi(lockMargin ? 'lock' : 'unlock'); + } + $$('.margins:not(.marginTop)', prop).forEach((elm) => !lockMargin + ? elm.removeAttribute('disabled') + : elm.setAttribute('disabled', 'true')); + }, updateSizes = () => { + $w.value = image.offsetWidth.toString(); + $h.value = image.offsetHeight.toString(); + }, updateText = () => { + if (image.hasAttribute('title')) { + val_val(prop, '.imageTitle', image.getAttribute('title') || ''); + } + if (image.hasAttribute('alt')) { + val_val(prop, '.imageAlt', image.getAttribute('alt') || ''); + } + const a = Dom_Dom.closest(image, 'a', editor.editor); + if (a) { + val_val(prop, '.imageLink', a.getAttribute('href') || ''); + prop.querySelector('.imageLinkOpenInNewTab').checked = + a.getAttribute('target') === '_blank'; + } + }, updateSrc = () => { + val_val(prop, '.imageSrc', image.getAttribute('src') || ''); + const imageViewSrc = prop.querySelector('.imageViewSrc'); + if (imageViewSrc) { + imageViewSrc.setAttribute('src', image.getAttribute('src') || ''); + } + }, update = () => { + updateSrc(); + updateText(); + updateSizes(); + updateMargins(); + updateClasses(); + updateId(); + updateBorderRadius(); + updateAlign(); + updateStyle(); + }; + let timer, lockSize = true, lockMargin = true; + const tabs = {}, tabsbox = prop.querySelector('.tabsbox'); + tabs['Image'] = mainTab; + tabs['Advanced'] = positionTab; + if (tabsbox) { + tabsbox.appendChild(image_properties_TabsWidget(editor, tabs)); + } + update(); + editor.events.on(dialog, 'afterClose', () => { + dialog.destruct(); + if (image.parentNode && opt.image.selectImageAfterClose) { + editor.selection.select(image); + } + }); + buttons.remove.addEventListener('click', () => { + Dom_Dom.safeRemove(image); + dialog.close(); + }); + if (opt.image.useImageEditor) { + $$('.jodit_use_image_editor', mainTab).forEach((btn) => { + editor.events.on(btn, 'mousedown touchstart', () => { + const url = image.getAttribute('src') || '', a = editor.create.element('a'), loadExternal = () => { + if (a.host !== location.host) { + Confirm(i18n('You can only edit your own images. Download this image on the host?'), (yes) => { + if (yes && editor.uploader) { + editor.uploader.uploadRemoteImage(a.href.toString(), (resp) => { + Alert(i18n('The image has been successfully uploaded to the host!'), () => { + if (typeof resp.newfilename === + 'string') { + image.setAttribute('src', resp.baseurl + + resp.newfilename); + updateSrc(); + } + }); + }, (error) => { + Alert(i18n('There was an error loading %s', error.message)); + }); + } + }); + return; + } + }; + a.href = url; + editor.getInstance('FileBrowser').dataProvider.getPathByUrl(a.href.toString(), (path, name, source) => { + editor.getInstance('FileBrowser').openImageEditor(a.href, name, path, source, () => { + const timestamp = new Date().getTime(); + image.setAttribute('src', url + + (url.indexOf('?') !== -1 + ? '' + : '?') + + '&_tmp=' + + timestamp.toString()); + updateSrc(); + }, (error) => { + Alert(error.message); + }); + }, (error) => { + Alert(error.message, loadExternal); + }); + }); + }); + } + $$('.jodit_rechange', mainTab).forEach((imagebtn) => { + imagebtn.addEventListener('mousedown', (event) => { + imagebtn.classList.toggle('active'); + const popup = new popup_Popup(editor, imagebtn); + popup.open(image_properties_FileSelectorWidget(editor, { + upload: (data) => { + if (data.files && data.files.length) { + image.setAttribute('src', data.baseurl + data.files[0]); + } + update(); + popup.close(); + }, + filebrowser: (data) => { + if (data && + data.files && + Array.isArray(data.files) && + data.files.length) { + image.setAttribute('src', data.files[0]); + popup.close(); + update(); + } + } + }, image, popup.close), true); + event.stopPropagation(); + }); + }); + const jodit_lock_size = prop.querySelector('.jodit_lock_helper.jodit_lock_size'), jodit_lock_margin = prop.querySelector('.jodit_lock_helper.jodit_lock_margin'); + if (jodit_lock_size) { + jodit_lock_size.addEventListener('click', function () { + lockSize = !lockSize; + this.innerHTML = gi(lockSize ? 'lock' : 'unlock'); + editor.events.fire($w, 'change'); + }); + } + if (jodit_lock_margin) { + jodit_lock_margin.addEventListener('click', function () { + lockMargin = !lockMargin; + this.innerHTML = gi(lockMargin ? 'lock' : 'unlock'); + if (!lockMargin) { + $$('.margins', prop).forEach(elm => { + if (!elm.matches('.marginTop')) { + elm.removeAttribute('disabled'); + } + }); + } + else { + $$('.margins', prop).forEach(elm => { + if (!elm.matches('.marginTop')) { + elm.setAttribute('disabled', 'true'); + } + }); + } + }); + } + const changeSizes = (event) => { + const w = parseInt($w.value, 10), h = parseInt($h.value, 10); + if (event.target === $w) { + $h.value = Math.round(w / ratio).toString(); + } + else { + $w.value = Math.round(h * ratio).toString(); + } + }; + editor.events.on([$w, $h], 'change keydown mousedown paste', (event) => { + if (!lockSize) { + return; + } + if (editor.defaultTimeout) { + clearTimeout(timer); + timer = setTimeout_setTimeout(changeSizes.bind(this, event), editor.defaultTimeout); + } + else { + changeSizes(event); + } + }); + dialog.setTitle(i18n('Image properties')); + dialog.setContent(prop); + buttons.check.addEventListener('click', () => { + if (opt.image.editStyle) { + if (val_val(prop, '.style')) { + image.setAttribute('style', val_val(prop, '.style')); + } + else { + image.removeAttribute('style'); + } + } + if (val_val(prop, '.imageSrc')) { + image.setAttribute('src', val_val(prop, '.imageSrc')); + } + else { + Dom_Dom.safeRemove(image); + dialog.close(); + return; + } + if (val_val(prop, '.border_radius') !== '0' && + /^[0-9]+$/.test(val_val(prop, '.border_radius'))) { + image.style.borderRadius = val_val(prop, '.border_radius') + 'px'; + } + else { + image.style.borderRadius = ''; + } + if (val_val(prop, '.imageTitle')) { + image.setAttribute('title', val_val(prop, '.imageTitle')); + } + else { + image.removeAttribute('title'); + } + if (val_val(prop, '.imageAlt')) { + image.setAttribute('alt', val_val(prop, '.imageAlt')); + } + else { + image.removeAttribute('alt'); + } + let link = Dom_Dom.closest(image, 'a', editor.editor); + if (val_val(prop, '.imageLink')) { + if (!link) { + link = Dom_Dom.wrap(image, 'a', editor); + } + link.setAttribute('href', val_val(prop, '.imageLink')); + if (prop.querySelector('.imageLinkOpenInNewTab').checked) { + link.setAttribute('target', '_blank'); + } + else { + link.removeAttribute('target'); + } + } + else { + if (link && link.parentNode) { + link.parentNode.replaceChild(image, link); + } + } + const normalSize = (value) => { + value = trim(value); + return /^[0-9]+$/.test(value) ? value + 'px' : value; + }; + if ($w.value !== image.offsetWidth.toString() || + $h.value !== image.offsetHeight.toString()) { + css_css(image, { + width: trim($w.value) ? normalSize($w.value) : null, + height: trim($h.value) ? normalSize($h.value) : null + }); + } + if (opt.image.editMargins) { + if (!lockMargin) { + $$('.margins', prop).forEach((margin) => { + const id = margin.getAttribute('data-id') || ''; + css_css(image, id, normalSize(margin.value)); + }); + } + else { + css_css(image, 'margin', normalSize(val_val(prop, '.marginTop'))); + } + } + if (opt.image.editClass) { + if (val_val(prop, '.classes')) { + image.setAttribute('class', val_val(prop, '.classes')); + } + else { + image.removeAttribute('class'); + } + } + if (opt.image.editId) { + if (val_val(prop, '.id')) { + image.setAttribute('id', val_val(prop, '.id')); + } + else { + image.removeAttribute('id'); + } + } + if (opt.image.editAlign) { + if (val_val(prop, '.align')) { + if (['right', 'left'].indexOf(val_val(prop, '.align').toLowerCase()) !== -1) { + css_css(image, 'float', val_val(prop, '.align')); + clearCenterAlign(image); + } + else { + css_css(image, 'float', ''); + css_css(image, { + display: 'block', + 'margin-left': 'auto', + 'margin-right': 'auto' + }); + } + } + else { + if (css_css(image, 'float') && + ['right', 'left'].indexOf(css_css(image, 'float') + .toString() + .toLowerCase()) !== -1) { + css_css(image, 'float', ''); + } + clearCenterAlign(image); + } + } + if (!image.getAttribute('style')) { + image.removeAttribute('style'); + } + editor.setEditorValue(); + dialog.close(); + }); + buttons.cancel.addEventListener('click', () => dialog.close()); + dialog.setFooter([[buttons.cancel, buttons.remove], buttons.check]); + dialog.setSize(500); + dialog.open(); + if (e) { + e.preventDefault(); + } + return false; + }; + editor.events + .on('afterInit', () => { + if (opt.image.openOnDblClick) { + editor.events.on(editor.editor, 'dblclick', open, 'img'); + } + else { + editor.events.on(editor.editor, 'dblclick', function (event) { + event.stopImmediatePropagation(); + editor.selection.select(this); + }, 'img'); + } + }) + .on('openImageProperties', (image) => { + open.call(image); + }); +} + +// CONCATENATED MODULE: ./src/plugins/indent.ts +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ + + + +Config_Config.prototype.controls.indent = { + tooltip: 'Increase Indent' +}; +Config_Config.prototype.controls.outdent = { + isDisable: (editor) => { + const current = editor.selection.current(); + if (current) { + const currentBox = Dom_Dom.closest(current, node => Dom_Dom.isBlock(node, editor.editorWindow), editor.editor); + if (currentBox && currentBox.style && currentBox.style.marginLeft) { + return parseInt(currentBox.style.marginLeft, 10) <= 0; + } + } + return true; + }, + tooltip: 'Decrease Indent' +}; +Config_Config.prototype.indentMargin = 10; +function indent(editor) { + const callback = (command) => { + const indentedBoxes = []; + editor.selection.eachSelection((current) => { + const selectionInfo = editor.selection.save(); + let currentBox = current + ? Dom_Dom.up(current, node => Dom_Dom.isBlock(node, editor.editorWindow), editor.editor) + : false; + const enter = editor.options.enter; + if (!currentBox && current) { + currentBox = Dom_Dom.wrapInline(current, enter !== BR ? enter : PARAGRAPH, editor); + } + if (!currentBox) { + editor.selection.restore(selectionInfo); + return false; + } + const alreadyIndented = indentedBoxes.indexOf(currentBox) !== -1; + if (currentBox && currentBox.style && !alreadyIndented) { + indentedBoxes.push(currentBox); + let marginLeft = currentBox.style.marginLeft + ? parseInt(currentBox.style.marginLeft, 10) + : 0; + marginLeft += + editor.options.indentMargin * + (command === 'outdent' ? -1 : 1); + currentBox.style.marginLeft = + marginLeft > 0 ? marginLeft + 'px' : ''; + if (!currentBox.getAttribute('style')) { + currentBox.removeAttribute('style'); + } + } + editor.selection.restore(selectionInfo); + }); + editor.setEditorValue(); + return false; + }; + editor.registerCommand('indent', { + exec: callback, + hotkeys: ['ctrl+]', 'cmd+]'] + }); + editor.registerCommand('outdent', { + exec: callback, + hotkeys: ['ctrl+[', 'cmd+['] + }); +} + +// CONCATENATED MODULE: ./src/modules/Table.ts +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ + + + +class Table_Table { + static addSelected(td) { + td.setAttribute(JODIT_SELECTED_CELL_MARKER, '1'); + } + static restoreSelection(td) { + td.removeAttribute(JODIT_SELECTED_CELL_MARKER); + } + static getAllSelectedCells(table) { + return table + ? $$(`td[${JODIT_SELECTED_CELL_MARKER}],th[${JODIT_SELECTED_CELL_MARKER}]`, table) + : []; + } + static getRowsCount(table) { + return table.rows.length; + } + static getColumnsCount(table) { + const matrix = Table_Table.formalMatrix(table); + return matrix.reduce((max_count, cells) => { + return Math.max(max_count, cells.length); + }, 0); + } + static formalMatrix(table, callback) { + const matrix = [[]]; + const rows = Array.prototype.slice.call(table.rows); + const setCell = (cell, i) => { + if (matrix[i] === undefined) { + matrix[i] = []; + } + const colSpan = cell.colSpan, rowSpan = cell.rowSpan; + let column, row, currentColumn = 0; + while (matrix[i][currentColumn]) { + currentColumn += 1; + } + for (row = 0; row < rowSpan; row += 1) { + for (column = 0; column < colSpan; column += 1) { + if (matrix[i + row] === undefined) { + matrix[i + row] = []; + } + if (callback && + callback(cell, i + row, currentColumn + column, colSpan, rowSpan) === false) { + return false; + } + matrix[i + row][currentColumn + column] = cell; + } + } + }; + for (let i = 0, j; i < rows.length; i += 1) { + const cells = Array.prototype.slice.call(rows[i].cells); + for (j = 0; j < cells.length; j += 1) { + if (setCell(cells[j], i) === false) { + return matrix; + } + } + } + return matrix; + } + static formalCoordinate(table, cell, max = false) { + let i = 0, j = 0, width = 1, height = 1; + Table_Table.formalMatrix(table, (td, ii, jj, colSpan, rowSpan) => { + if (cell === td) { + i = ii; + j = jj; + width = colSpan || 1; + height = rowSpan || 1; + if (max) { + j += (colSpan || 1) - 1; + i += (rowSpan || 1) - 1; + } + return false; + } + }); + return [i, j, width, height]; + } + static appendRow(table, line = false, after = true) { + const doc = table.ownerDocument || document, columnsCount = Table_Table.getColumnsCount(table), row = doc.createElement('tr'); + for (let j = 0; j < columnsCount; j += 1) { + row.appendChild(doc.createElement('td')); + } + if (after && line && line.nextSibling) { + line.parentNode && + line.parentNode.insertBefore(row, line.nextSibling); + } + else if (!after && line) { + line.parentNode && line.parentNode.insertBefore(row, line); + } + else { + ($$(':scope>tbody', table)[0] || table).appendChild(row); + } + } + static removeRow(table, rowIndex) { + const box = Table_Table.formalMatrix(table); + let dec; + const row = table.rows[rowIndex]; + each(box[rowIndex], (j, cell) => { + dec = false; + if (rowIndex - 1 >= 0 && box[rowIndex - 1][j] === cell) { + dec = true; + } + else if (box[rowIndex + 1] && box[rowIndex + 1][j] === cell) { + if (cell.parentNode === row && + cell.parentNode.nextSibling) { + dec = true; + let nextCell = j + 1; + while (box[rowIndex + 1][nextCell] === cell) { + nextCell += 1; + } + const nextRow = Dom_Dom.next(cell.parentNode, (elm) => elm && + elm.nodeType === Node.ELEMENT_NODE && + elm.nodeName === 'TR', table); + if (box[rowIndex + 1][nextCell]) { + nextRow.insertBefore(cell, box[rowIndex + 1][nextCell]); + } + else { + nextRow.appendChild(cell); + } + } + } + else { + Dom_Dom.safeRemove(cell); + } + if (dec && + (cell.parentNode === row || cell !== box[rowIndex][j - 1])) { + const rowSpan = cell.rowSpan; + if (rowSpan - 1 > 1) { + cell.setAttribute('rowspan', (rowSpan - 1).toString()); + } + else { + cell.removeAttribute('rowspan'); + } + } + }); + Dom_Dom.safeRemove(row); + } + static appendColumn(table, j, after = true) { + const box = Table_Table.formalMatrix(table); + let i; + if (j === undefined) { + j = Table_Table.getColumnsCount(table) - 1; + } + for (i = 0; i < box.length; i += 1) { + const cell = (table.ownerDocument || document).createElement('td'); + const td = box[i][j]; + let added = false; + if (after) { + if ((box[i] && td && j + 1 >= box[i].length) || + td !== box[i][j + 1]) { + if (td.nextSibling) { + td.parentNode && + td.parentNode.insertBefore(cell, td.nextSibling); + } + else { + td.parentNode && td.parentNode.appendChild(cell); + } + added = true; + } + } + else { + if (j - 1 < 0 || + (box[i][j] !== box[i][j - 1] && box[i][j].parentNode)) { + td.parentNode && + td.parentNode.insertBefore(cell, box[i][j]); + added = true; + } + } + if (!added) { + box[i][j].setAttribute('colspan', (parseInt(box[i][j].getAttribute('colspan') || '1', 10) + + 1).toString()); + } + } + } + static removeColumn(table, j) { + const box = Table_Table.formalMatrix(table); + let dec; + each(box, (i, cells) => { + const td = cells[j]; + dec = false; + if (j - 1 >= 0 && box[i][j - 1] === td) { + dec = true; + } + else if (j + 1 < cells.length && box[i][j + 1] === td) { + dec = true; + } + else { + Dom_Dom.safeRemove(td); + } + if (dec && (i - 1 < 0 || td !== box[i - 1][j])) { + const colSpan = td.colSpan; + if (colSpan - 1 > 1) { + td.setAttribute('colspan', (colSpan - 1).toString()); + } + else { + td.removeAttribute('colspan'); + } + } + }); + } + static getSelectedBound(table, selectedCells) { + const bound = [[Infinity, Infinity], [0, 0]]; + const box = Table_Table.formalMatrix(table); + let i, j, k; + for (i = 0; i < box.length; i += 1) { + for (j = 0; j < box[i].length; j += 1) { + if (selectedCells.indexOf(box[i][j]) !== -1) { + bound[0][0] = Math.min(i, bound[0][0]); + bound[0][1] = Math.min(j, bound[0][1]); + bound[1][0] = Math.max(i, bound[1][0]); + bound[1][1] = Math.max(j, bound[1][1]); + } + } + } + for (i = bound[0][0]; i <= bound[1][0]; i += 1) { + for (k = 1, j = bound[0][1]; j <= bound[1][1]; j += 1) { + while (box[i][j - k] && box[i][j] === box[i][j - k]) { + bound[0][1] = Math.min(j - k, bound[0][1]); + bound[1][1] = Math.max(j - k, bound[1][1]); + k += 1; + } + k = 1; + while (box[i][j + k] && box[i][j] === box[i][j + k]) { + bound[0][1] = Math.min(j + k, bound[0][1]); + bound[1][1] = Math.max(j + k, bound[1][1]); + k += 1; + } + k = 1; + while (box[i - k] && box[i][j] === box[i - k][j]) { + bound[0][0] = Math.min(i - k, bound[0][0]); + bound[1][0] = Math.max(i - k, bound[1][0]); + k += 1; + } + k = 1; + while (box[i + k] && box[i][j] === box[i + k][j]) { + bound[0][0] = Math.min(i + k, bound[0][0]); + bound[1][0] = Math.max(i + k, bound[1][0]); + k += 1; + } + } + } + return bound; + } + static normalizeTable(table) { + let i, j, min, not; + const __marked = [], box = Table_Table.formalMatrix(table); + for (j = 0; j < box[0].length; j += 1) { + min = 1000000; + not = false; + for (i = 0; i < box.length; i += 1) { + if (box[i][j] === undefined) { + continue; + } + if (box[i][j].colSpan < 2) { + not = true; + break; + } + min = Math.min(min, box[i][j].colSpan); + } + if (!not) { + for (i = 0; i < box.length; i += 1) { + if (box[i][j] === undefined) { + continue; + } + Table_Table.__mark(box[i][j], 'colspan', box[i][j].colSpan - min + 1, __marked); + } + } + } + for (i = 0; i < box.length; i += 1) { + min = 1000000; + not = false; + for (j = 0; j < box[i].length; j += 1) { + if (box[i][j] === undefined) { + continue; + } + if (box[i][j].rowSpan < 2) { + not = true; + break; + } + min = Math.min(min, box[i][j].rowSpan); + } + if (!not) { + for (j = 0; j < box[i].length; j += 1) { + if (box[i][j] === undefined) { + continue; + } + Table_Table.__mark(box[i][j], 'rowspan', box[i][j].rowSpan - min + 1, __marked); + } + } + } + for (i = 0; i < box.length; i += 1) { + for (j = 0; j < box[i].length; j += 1) { + if (box[i][j] === undefined) { + continue; + } + if (box[i][j].hasAttribute('rowspan') && + box[i][j].rowSpan === 1) { + box[i][j].removeAttribute('rowspan'); + } + if (box[i][j].hasAttribute('colspan') && + box[i][j].colSpan === 1) { + box[i][j].removeAttribute('colspan'); + } + if (box[i][j].hasAttribute('class') && + !box[i][j].getAttribute('class')) { + box[i][j].removeAttribute('class'); + } + } + } + Table_Table.__unmark(__marked); + } + static mergeSelected(table) { + const html = [], bound = Table_Table.getSelectedBound(table, Table_Table.getAllSelectedCells(table)); + let w = 0, first = null, first_j = 0, td, cols = 0, rows = 0; + const __marked = []; + if (bound && (bound[0][0] - bound[1][0] || bound[0][1] - bound[1][1])) { + Table_Table.formalMatrix(table, (cell, i, j, cs, rs) => { + if (i >= bound[0][0] && i <= bound[1][0]) { + if (j >= bound[0][1] && j <= bound[1][1]) { + td = cell; + if (td.__i_am_already_was) { + return; + } + td.__i_am_already_was = true; + if (i === bound[0][0] && td.style.width) { + w += td.offsetWidth; + } + if (trim(cell.innerHTML.replace(//g, '')) !== '') { + html.push(cell.innerHTML); + } + if (cs > 1) { + cols += cs - 1; + } + if (rs > 1) { + rows += rs - 1; + } + if (!first) { + first = cell; + first_j = j; + } + else { + Table_Table.__mark(td, 'remove', 1, __marked); + } + } + } + }); + cols = bound[1][1] - bound[0][1] + 1; + rows = bound[1][0] - bound[0][0] + 1; + if (first) { + if (cols > 1) { + Table_Table.__mark(first, 'colspan', cols, __marked); + } + if (rows > 1) { + Table_Table.__mark(first, 'rowspan', rows, __marked); + } + if (w) { + Table_Table.__mark(first, 'width', ((w / table.offsetWidth) * 100).toFixed(ACCURACY) + '%', __marked); + if (first_j) { + Table_Table.setColumnWidthByDelta(table, first_j, 0, true, __marked); + } + } + first.innerHTML = html.join('
'); + delete first.__i_am_already_was; + Table_Table.__unmark(__marked); + Table_Table.normalizeTable(table); + each(Array.from(table.rows), (index, tr) => { + if (!tr.cells.length) { + Dom_Dom.safeRemove(tr); + } + }); + } + } + } + static splitHorizontal(table) { + let coord, td, tr, parent, after; + const __marked = []; + const doc = table.ownerDocument || document; + Table_Table.getAllSelectedCells(table).forEach((cell) => { + td = doc.createElement('td'); + td.appendChild(doc.createElement('br')); + tr = doc.createElement('tr'); + coord = Table_Table.formalCoordinate(table, cell); + if (cell.rowSpan < 2) { + Table_Table.formalMatrix(table, (tdElm, i, j) => { + if (coord[0] === i && + coord[1] !== j && + tdElm !== cell) { + Table_Table.__mark(tdElm, 'rowspan', tdElm.rowSpan + 1, __marked); + } + }); + Dom_Dom.after(Dom_Dom.closest(cell, 'tr', table), tr); + tr.appendChild(td); + } + else { + Table_Table.__mark(cell, 'rowspan', cell.rowSpan - 1, __marked); + Table_Table.formalMatrix(table, (tdElm, i, j) => { + if (i > coord[0] && + i < coord[0] + cell.rowSpan && + coord[1] > j && + tdElm.parentNode + .rowIndex === i) { + after = tdElm; + } + if (coord[0] < i && tdElm === cell) { + parent = table.rows[i]; + } + }); + if (after) { + Dom_Dom.after(after, td); + } + else { + parent.insertBefore(td, parent.firstChild); + } + } + if (cell.colSpan > 1) { + Table_Table.__mark(td, 'colspan', cell.colSpan, __marked); + } + Table_Table.__unmark(__marked); + Table_Table.restoreSelection(cell); + }); + this.normalizeTable(table); + } + static splitVertical(table) { + let coord, td, percentage; + const __marked = []; + const doc = table.ownerDocument || document; + Table_Table.getAllSelectedCells(table).forEach((cell) => { + coord = Table_Table.formalCoordinate(table, cell); + if (cell.colSpan < 2) { + Table_Table.formalMatrix(table, (tdElm, i, j) => { + if (coord[1] === j && + coord[0] !== i && + tdElm !== cell) { + Table_Table.__mark(tdElm, 'colspan', tdElm.colSpan + 1, __marked); + } + }); + } + else { + Table_Table.__mark(cell, 'colspan', cell.colSpan - 1, __marked); + } + td = doc.createElement('td'); + td.appendChild(doc.createElement('br')); + if (cell.rowSpan > 1) { + Table_Table.__mark(td, 'rowspan', cell.rowSpan, __marked); + } + const oldWidth = cell.offsetWidth; + Dom_Dom.after(cell, td); + percentage = oldWidth / table.offsetWidth / 2; + Table_Table.__mark(cell, 'width', (percentage * 100).toFixed(ACCURACY) + '%', __marked); + Table_Table.__mark(td, 'width', (percentage * 100).toFixed(ACCURACY) + '%', __marked); + Table_Table.__unmark(__marked); + Table_Table.restoreSelection(cell); + }); + Table_Table.normalizeTable(table); + } + static setColumnWidthByDelta(table, j, delta, noUnmark, __marked) { + const box = Table_Table.formalMatrix(table); + let i, w, percent; + for (i = 0; i < box.length; i += 1) { + w = box[i][j].offsetWidth; + percent = ((w + delta) / table.offsetWidth) * 100; + Table_Table.__mark(box[i][j], 'width', percent.toFixed(ACCURACY) + '%', __marked); + } + if (!noUnmark) { + Table_Table.__unmark(__marked); + } + } + static __mark(cell, key, value, __marked) { + __marked.push(cell); + if (!cell.__marked_value) { + cell.__marked_value = {}; + } + cell.__marked_value[key] = value === undefined ? 1 : value; + } + static __unmark(__marked) { + __marked.forEach(cell => { + if (cell.__marked_value) { + each(cell.__marked_value, (key, value) => { + switch (key) { + case 'remove': + Dom_Dom.safeRemove(cell); + break; + case 'rowspan': + if (value > 1) { + cell.setAttribute('rowspan', value.toString()); + } + else { + cell.removeAttribute('rowspan'); + } + break; + case 'colspan': + if (value > 1) { + cell.setAttribute('colspan', value.toString()); + } + else { + cell.removeAttribute('colspan'); + } + break; + case 'width': + cell.style.width = value.toString(); + break; + } + delete cell.__marked_value[key]; + }); + delete cell.__marked_value; + } + }); + } +} + +// CONCATENATED MODULE: ./src/plugins/inline-popup.ts +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ + + +var inline_popup_ColorPickerWidget = Widget_Widget.ColorPickerWidget; +var inline_popup_TabsWidget = Widget_Widget.TabsWidget; + + + + + + +Config_Config.prototype.toolbarInline = true; +Config_Config.prototype.toolbarInlineDisableFor = []; +Config_Config.prototype.popup = { + a: [ + { + name: 'eye', + tooltip: 'Open link', + exec: (editor, current) => { + const href = current.getAttribute('href'); + if (current && href) { + editor.ownerWindow.open(href); + } + } + }, + { + name: 'link', + tooltip: 'Edit link', + icon: 'pencil' + }, + 'unlink', + 'brush', + 'file' + ], + jodit: [ + { + name: 'bin', + tooltip: 'Delete', + exec: (editor, image) => { + if (image.parentNode) { + Dom_Dom.safeRemove(image); + editor.events.fire('hidePopup'); + } + } + } + ], + 'jodit-media': [ + { + name: 'bin', + tooltip: 'Delete', + exec: (editor, image) => { + if (image.parentNode) { + Dom_Dom.safeRemove(image); + editor.events.fire('hidePopup'); + } + } + } + ], + img: [ + { + name: 'delete', + icon: 'bin', + tooltip: 'Delete', + exec: (editor, image) => { + if (image.parentNode) { + Dom_Dom.safeRemove(image); + editor.events.fire('hidePopup'); + } + } + }, + { + name: 'pencil', + exec(editor, current) { + const tagName = current.tagName.toLowerCase(); + if (tagName === 'img') { + editor.events.fire('openImageProperties', current); + } + }, + tooltip: 'Edit' + }, + { + name: 'valign', + list: ['Top', 'Middle', 'Bottom'], + tooltip: 'Vertical align', + exec: (editor, image, control) => { + const tagName = image.tagName.toLowerCase(); + if (tagName !== 'img') { + return; + } + const command = control.args && typeof control.args[1] === 'string' + ? control.args[1].toLowerCase() + : ''; + css_css(image, 'vertical-align', command); + editor.events.fire('recalcPositionPopup'); + } + }, + { + name: 'left', + list: ['Left', 'Right', 'Center', 'Normal'], + exec: (editor, image, control) => { + const tagName = image.tagName.toLowerCase(); + if (tagName !== 'img') { + return; + } + const command = control.args && typeof control.args[1] === 'string' + ? control.args[1].toLowerCase() + : ''; + if (command !== 'normal') { + if (['right', 'left'].indexOf(command) !== -1) { + css_css(image, 'float', command); + clearCenterAlign(image); + } + else { + css_css(image, 'float', ''); + css_css(image, { + display: 'block', + 'margin-left': 'auto', + 'margin-right': 'auto' + }); + } + } + else { + if (css_css(image, 'float') && + ['right', 'left'].indexOf(css_css(image, 'float').toLowerCase()) !== -1) { + css_css(image, 'float', ''); + } + clearCenterAlign(image); + } + editor.events.fire('recalcPositionPopup'); + }, + tooltip: 'Horizontal align' + } + ], + table: [ + { + name: 'brush', + popup: (editor, elm) => { + const selected = Table_Table.getAllSelectedCells(elm); + let $bg, $cl, $br, $tab, color, br_color, bg_color; + if (!selected.length) { + return false; + } + color = css_css(selected[0], 'color'); + bg_color = css_css(selected[0], 'background-color'); + br_color = css_css(selected[0], 'border-color'); + $bg = inline_popup_ColorPickerWidget(editor, (value) => { + selected.forEach((cell) => { + css_css(cell, 'background-color', value); + }); + editor.setEditorValue(); + }, bg_color); + $cl = inline_popup_ColorPickerWidget(editor, (value) => { + selected.forEach((cell) => { + css_css(cell, 'color', value); + }); + editor.setEditorValue(); + }, color); + $br = inline_popup_ColorPickerWidget(editor, (value) => { + selected.forEach((cell) => { + css_css(cell, 'border-color', value); + }); + editor.setEditorValue(); + }, br_color); + $tab = inline_popup_TabsWidget(editor, { + Background: $bg, + Text: $cl, + Border: $br + }); + return $tab; + }, + tooltip: 'Background' + }, + { + name: 'valign', + list: ['Top', 'Middle', 'Bottom'], + exec: (editor, table, control) => { + const command = control.args && typeof control.args[1] === 'string' + ? control.args[1].toLowerCase() + : ''; + Table_Table.getAllSelectedCells(table).forEach((cell) => { + css_css(cell, 'vertical-align', command); + }); + }, + tooltip: 'Vertical align' + }, + { + name: 'splitv', + list: { + tablesplitv: 'Split vertical', + tablesplitg: 'Split horizontal' + }, + tooltip: 'Split' + }, + { + name: 'align', + icon: 'left' + }, + '\n', + { + name: 'merge', + command: 'tablemerge', + tooltip: 'Merge' + }, + { + name: 'addcolumn', + list: { + tableaddcolumnbefore: 'Insert column before', + tableaddcolumnafter: 'Insert column after' + }, + exec: (editor, table, control) => { + const command = control.args && typeof control.args[0] === 'string' + ? control.args[0].toLowerCase() + : ''; + editor.execCommand(command, false, table); + }, + tooltip: 'Add column' + }, + { + name: 'addrow', + list: { + tableaddrowbefore: 'Insert row above', + tableaddrowafter: 'Insert row below' + }, + exec: (editor, table, control) => { + const command = control.args && typeof control.args[0] === 'string' + ? control.args[0].toLowerCase() + : ''; + editor.execCommand(command, false, table); + }, + tooltip: 'Add row' + }, + { + name: 'delete', + icon: 'bin', + list: { + tablebin: 'Delete table', + tablebinrow: 'Delete row', + tablebincolumn: 'Delete column', + tableempty: 'Empty cell' + }, + exec: (editor, table, control) => { + const command = control.args && typeof control.args[0] === 'string' + ? control.args[0].toLowerCase() + : ''; + editor.execCommand(command, false, table); + editor.events.fire('hidePopup'); + }, + tooltip: 'Delete' + } + ] +}; +class inline_popup_inlinePopup extends Plugin_Plugin { + constructor() { + super(...arguments); + this._hiddenClass = 'jodit_toolbar_popup-inline-target-hidden'; + this.isSelectionStarted = false; + this.onSelectionEnd = debounce(() => { + if (this.isDestructed || !this.jodit.isEditorMode()) { + return; + } + if (this.isSelectionStarted) { + if (!this.isTargetAction) { + this.onChangeSelection(); + } + } + this.isSelectionStarted = false; + this.isTargetAction = false; + }, this.jodit.defaultTimeout); + this.isTargetAction = false; + this.isSelectionPopup = false; + this.calcWindSizes = () => { + const win = this.jodit.ownerWindow; + const docElement = this.jodit.ownerDocument + .documentElement; + if (!docElement) { + return { + left: 0, + top: 0, + width: 0, + height: 0 + }; + } + const body = this.jodit.ownerDocument.body; + const scrollTop = win.pageYOffset || docElement.scrollTop || body.scrollTop; + const clientTop = docElement.clientTop || body.clientTop || 0; + const scrollLeft = win.pageXOffset || docElement.scrollLeft || body.scrollLeft; + const clientLeft = docElement.clientLeft || body.clientLeft || 0; + const windWidth = docElement.clientWidth + scrollLeft - clientLeft; + const windHeight = docElement.clientHeight + scrollTop - clientTop; + return { + left: clientLeft, + top: clientTop, + width: windWidth, + height: windHeight + }; + }; + this.calcPosition = (rect, windowSize) => { + if (this.isDestructed) { + return; + } + this.popup.target.classList.remove(this._hiddenClass); + const selectionCenterLeft = rect.left + rect.width / 2; + const workplacePosition = offset(this.jodit.workplace, this.jodit, this.jodit.ownerDocument, true); + let targetTop = rect.top + rect.height + 10; + const diff = 50; + this.target.style.left = selectionCenterLeft + 'px'; + this.target.style.top = targetTop + 'px'; + if (this.jodit.isFullSize()) { + this.target.style.zIndex = css_css(this.jodit.container, 'zIndex').toString(); + } + const halfWidthPopup = this.container.offsetWidth / 2; + let marginLeft = -halfWidthPopup; + this.popup.container.classList.remove('jodit_toolbar_popup-inline-top'); + if (targetTop + this.container.offsetHeight > windowSize.height) { + targetTop = rect.top - this.container.offsetHeight - 10; + this.target.style.top = targetTop + 'px'; + this.popup.container.classList.add('jodit_toolbar_popup-inline-top'); + } + if (selectionCenterLeft - halfWidthPopup < 0) { + marginLeft = -(rect.width / 2 + rect.left); + } + if (selectionCenterLeft + halfWidthPopup > windowSize.width) { + marginLeft = -(this.container.offsetWidth - + (windowSize.width - selectionCenterLeft)); + } + this.container.style.marginLeft = marginLeft + 'px'; + if (workplacePosition.top - targetTop > diff || + targetTop - (workplacePosition.top + workplacePosition.height) > + diff) { + this.popup.target.classList.add(this._hiddenClass); + } + }; + this.reCalcPosition = () => { + if (this.__getRect) { + this.calcPosition(this.__getRect(), this.calcWindSizes()); + } + }; + this.showPopup = (rect, type, elm) => { + if (!this.jodit.options.toolbarInline || + !this.jodit.options.popup[type.toLowerCase()]) { + return false; + } + if (this.isExcludedTarget(type)) { + return true; + } + this.isOpened = true; + this.isTargetAction = true; + const windSize = this.calcWindSizes(); + this.targetContainer.parentNode || + this.jodit.ownerDocument.body.appendChild(this.targetContainer); + this.toolbar.build(this.jodit.options.popup[type.toLowerCase()], this.container, elm); + this.popup.open(this.container, false, true); + this.__getRect = rect; + this.calcPosition(rect(), windSize); + return true; + }; + this.hidePopup = (root) => { + if (this.isDestructed) { + return; + } + if (root && + (Dom_Dom.isNode(root, this.jodit.editorWindow || window) || + root instanceof popup_Popup) && + Dom_Dom.isOrContains(this.target, root instanceof popup_Popup ? root.target : root)) { + return; + } + this.isTargetAction = false; + this.isOpened = false; + this.popup.close(); + Dom_Dom.safeRemove(this.targetContainer); + }; + this.onSelectionStart = (event) => { + if (this.isDestructed || !this.jodit.isEditorMode()) { + return; + } + this.isTargetAction = false; + this.isSelectionPopup = false; + if (!this.isSelectionStarted) { + const elements = Object.keys(this.jodit.options.popup).join('|'), target = event.target.nodeName === 'IMG' + ? event.target + : Dom_Dom.closest(event.target, elements, this.jodit.editor); + if (!target || + !this.showPopup(() => offset(target, this.jodit, this.jodit.editorDocument), target.nodeName, target)) { + this.isSelectionStarted = true; + } + } + }; + this.checkIsTargetEvent = () => { + if (!this.isTargetAction) { + this.hidePopup(); + } + else { + this.isTargetAction = false; + } + }; + this.isOpened = false; + this.onChangeSelection = () => { + if (!this.jodit.options.toolbarInline || !this.jodit.isEditorMode()) { + return; + } + if (this.hideIfCollapsed()) { + return; + } + if (this.jodit.options.popup.selection !== undefined) { + const sel = this.jodit.selection.sel; + if (sel && sel.rangeCount) { + this.isSelectionPopup = true; + const range = sel.getRangeAt(0); + this.showPopup(() => offset(range, this.jodit, this.jodit.editorDocument), 'selection'); + } + } + }; + } + isExcludedTarget(type) { + return (splitArray(this.jodit.options.toolbarInlineDisableFor) + .map(a => a.toLowerCase()) + .indexOf(type.toLowerCase()) !== -1); + } + hideIfCollapsed() { + if (this.jodit.selection.isCollapsed()) { + this.hidePopup(); + return true; + } + return false; + } + afterInit(editor) { + this.toolbar = joditToolbarCollection_JoditToolbarCollection.makeCollection(editor); + this.target = editor.create.div('jodit_toolbar_popup-inline-target'); + this.targetContainer = editor.create.div('jodit_toolbar_popup-inline-container', this.target); + this.container = editor.create.div(); + this.popup = new popup_Popup(editor, this.target, undefined, 'jodit_toolbar_popup-inline'); + editor.events + .on(this.target, 'mousedown keydown touchstart', (e) => { + e.stopPropagation(); + }) + .on('beforeOpenPopup hidePopup afterSetMode blur', this.hidePopup) + .on('recalcPositionPopup', this.reCalcPosition) + .on('getDiffButtons.mobile', (_toolbar) => { + if (this.toolbar === _toolbar) { + return splitArray(editor.options.buttons) + .filter(name => name !== '|' && name !== '\n') + .filter((name) => { + return (this.toolbar + .getButtonsList() + .indexOf(name) < 0); + }); + } + }) + .on('selectionchange', this.onChangeSelection) + .on('afterCommand afterExec', () => { + if (this.isOpened && this.isSelectionPopup) { + this.onChangeSelection(); + } + }) + .on('showPopup', (elm, rect) => { + const elementName = (typeof elm === 'string' + ? elm + : elm.nodeName).toLowerCase(); + this.isSelectionPopup = false; + this.showPopup(rect, elementName, typeof elm === 'string' ? undefined : elm); + }) + .on('mousedown keydown touchstart', this.onSelectionStart) + .on([editor.ownerWindow, editor.editor], 'scroll resize', this.reCalcPosition) + .on([editor.ownerWindow], 'mouseup keyup touchend', this.onSelectionEnd) + .on([editor.ownerWindow], 'mousedown keydown touchstart', this.checkIsTargetEvent); + } + beforeDestruct(editor) { + this.popup && this.popup.destruct(); + delete this.popup; + this.toolbar && this.toolbar.destruct(); + delete this.toolbar; + Dom_Dom.safeRemove(this.target); + Dom_Dom.safeRemove(this.container); + editor.events && + editor.events + .off([editor.ownerWindow], 'scroll resize', this.reCalcPosition) + .off([editor.ownerWindow], 'mouseup keyup touchend', this.onSelectionEnd) + .off([editor.ownerWindow], 'mousedown keydown touchstart', this.checkIsTargetEvent); + } +} + +// CONCATENATED MODULE: ./src/plugins/justify.ts +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ + + + + +Config_Config.prototype.controls.align = { + name: 'left', + tooltip: 'Align', + getLabel: (editor, btn, button) => { + const current = editor.selection.current(); + if (current) { + const currentBox = Dom_Dom.closest(current, node => Dom_Dom.isBlock(node, editor.editorWindow), editor.editor) || editor.editor; + let currentValue = css_css(currentBox, 'text-align').toString(); + if (btn.defaultValue && + btn.defaultValue.indexOf(currentValue) !== -1) { + currentValue = 'left'; + } + if (button && + btn.data && + btn.data.currentValue !== currentValue && + btn.list && + btn.list.indexOf(currentValue) !== -1) { + button.textBox.innerHTML = !editor.options.textIcons + ? ToolbarIcon.getIcon(currentValue, '') + : `${currentValue}`; + button.textBox.firstChild.classList.add('jodit_icon'); + btn.data.currentValue = currentValue; + } + } + return false; + }, + isActive: (editor, btn) => { + const current = editor.selection.current(); + if (current && btn.defaultValue) { + const currentBox = Dom_Dom.closest(current, node => Dom_Dom.isBlock(node, editor.editorWindow), editor.editor) || editor.editor; + return (btn.defaultValue.indexOf(css_css(currentBox, 'text-align').toString()) === -1); + } + return false; + }, + defaultValue: ['left', 'start', 'inherit'], + data: { + currentValue: 'left' + }, + list: ['center', 'left', 'right', 'justify'] +}; +Config_Config.prototype.controls.center = { + command: 'justifyCenter', + css: { + 'text-align': 'center' + }, + tooltip: 'Align Center' +}; +Config_Config.prototype.controls.justify = { + command: 'justifyFull', + css: { + 'text-align': 'justify' + }, + tooltip: 'Align Justify' +}; +Config_Config.prototype.controls.left = { + command: 'justifyLeft', + css: { + 'text-align': 'left' + }, + tooltip: 'Align Left' +}; +Config_Config.prototype.controls.right = { + command: 'justifyRight', + css: { + 'text-align': 'right' + }, + tooltip: 'Align Right' +}; +function justify(editor) { + const callback = (command) => { + const justifyElm = (box) => { + if (box instanceof editor.editorWindow.HTMLElement) { + switch (command.toLowerCase()) { + case 'justifyfull': + box.style.textAlign = 'justify'; + break; + case 'justifyright': + box.style.textAlign = 'right'; + break; + case 'justifyleft': + box.style.textAlign = 'left'; + break; + case 'justifycenter': + box.style.textAlign = 'center'; + break; + } + } + }; + editor.selection.focus(); + editor.selection.eachSelection((current) => { + if (!current) { + if (editor.editor.querySelector('.jodit_selected_cell')) { + $$('.jodit_selected_cell', editor.editor).forEach(justifyElm); + return false; + } + } + if (!(current instanceof editor.editorWindow.Node)) { + return; + } + let currentBox = current + ? Dom_Dom.up(current, node => Dom_Dom.isBlock(node, editor.editorWindow), editor.editor) + : false; + if (!currentBox && current) { + currentBox = Dom_Dom.wrapInline(current, editor.options.enterBlock, editor); + } + justifyElm(currentBox); + }); + return false; + }; + editor.registerCommand('justifyfull', callback); + editor.registerCommand('justifyright', callback); + editor.registerCommand('justifyleft', callback); + editor.registerCommand('justifycenter', callback); +} + +// CONCATENATED MODULE: ./src/plugins/limit.ts + + + + +Config_Config.prototype.limitWords = false; +Config_Config.prototype.limitChars = false; +Config_Config.prototype.limitHTML = false; +function limit(jodit) { + if (jodit && (jodit.options.limitWords || jodit.options.limitChars)) { + const callback = (event, inputText = '') => { + const text = inputText || + (jodit.options.limitHTML ? jodit.value : jodit.getEditorText()); + const words = text + .replace(INVISIBLE_SPACE_REG_EXP, '') + .split(SPACE_REG_EXP) + .filter((e) => e.length); + if (event && COMMAND_KEYS.indexOf(event.which) !== -1) { + return; + } + if (jodit.options.limitWords && + jodit.options.limitWords <= words.length) { + return jodit.options.limitWords === words.length; + } + if (jodit.options.limitChars && + jodit.options.limitChars <= words.join('').length) { + return jodit.options.limitChars === words.join('').length; + } + return; + }; + let snapshot = null; + jodit.events + .on('beforePaste', () => { + snapshot = jodit.observer.snapshot.make(); + }) + .on('keydown keyup beforeEnter beforePaste', (event) => { + if (callback(event) !== undefined) { + return false; + } + }) + .on('change', debounce((newValue, oldValue) => { + if (callback(null, jodit.options.limitHTML + ? newValue + : stripTags(newValue)) === false) { + jodit.value = oldValue; + } + }, jodit.defaultTimeout)) + .on('afterPaste', () => { + if (callback(null) === false && snapshot) { + jodit.observer.snapshot.restore(snapshot); + return false; + } + }); + } +} + +// CONCATENATED MODULE: ./src/plugins/link.ts +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ + + + +Config_Config.prototype.link = { + followOnDblClick: true, + processVideoLink: true, + processPastedLink: true, + removeLinkAfterFormat: true, + noFollowCheckbox: true, + openInNewTabCheckbox: true +}; +Config_Config.prototype.controls.unlink = { + exec: (editor, current) => { + const anchor = Dom_Dom.closest(current, 'A', editor.editor); + if (anchor) { + Dom_Dom.unwrap(anchor); + } + editor.events.fire('hidePopup'); + } +}; +Config_Config.prototype.controls.link = { + isActive: (editor) => { + const current = editor.selection.current(); + return current && Dom_Dom.closest(current, 'a', editor.editor) !== false; + }, + popup: (editor, current, self, close) => { + const sel = editor.selection.sel, form = editor.create.fromHTML('
' + + '
' + + '' + + '
' + + '
' + + '' + + '
' + + (editor.options.link.openInNewTabCheckbox + ? '' + : '') + + (editor.options.link.noFollowCheckbox + ? '' + : '') + + '
' + + '   ' + + '' + + '
' + + ''); + if (current && Dom_Dom.closest(current, 'A', editor.editor)) { + current = Dom_Dom.closest(current, 'A', editor.editor); + } + else { + current = false; + } + const lnk = form.querySelector('.jodit_link_insert_button'), unlink = form.querySelector('.jodit_unlink_button'); + if (current) { + val_val(form, 'input[name=url]', current.getAttribute('href') || ''); + val_val(form, 'input[name=text]', current.textContent || ''); + if (editor.options.link.openInNewTabCheckbox) { + form.querySelector('input[name=target]').checked = + current.getAttribute('target') === '_blank'; + } + if (editor.options.link.noFollowCheckbox) { + form.querySelector('input[name=nofollow]').checked = + current.getAttribute('rel') === 'nofollow'; + } + if (lnk) { + lnk.innerHTML = editor.i18n('Update'); + } + } + else { + if (unlink) { + unlink.style.display = 'none'; + } + val_val(form, 'input[name=text]', sel ? sel.toString() : ''); + if (lnk) { + lnk.innerHTML = editor.i18n('Insert'); + } + } + const selInfo = editor.selection.save(); + if (unlink) { + unlink.addEventListener('mousedown', (e) => { + if (current) { + Dom_Dom.unwrap(current); + } + editor.selection.restore(selInfo); + close(); + e.preventDefault(); + }); + } + form.addEventListener('submit', (event) => { + event.preventDefault(); + editor.selection.restore(selInfo); + const a = current || + editor.editorDocument.createElement('a'); + if (!val_val(form, 'input[name=url]')) { + form.querySelector('input[name=url]').focus(); + form.querySelector('input[name=url]').classList.add('jodit_error'); + return false; + } + a.setAttribute('href', val_val(form, 'input[name=url]')); + a.textContent = val_val(form, 'input[name=text]'); + if (editor.options.link.openInNewTabCheckbox) { + if (form.querySelector('input[name=target]').checked) { + a.setAttribute('target', '_blank'); + } + else { + a.removeAttribute('target'); + } + } + if (editor.options.link.noFollowCheckbox) { + if (form.querySelector('input[name=nofollow]').checked) { + a.setAttribute('rel', 'nofollow'); + } + else { + a.removeAttribute('rel'); + } + } + if (!current) { + editor.selection.insertNode(a); + } + close(); + return false; + }); + return form; + }, + tags: ['a'], + tooltip: 'Insert link' +}; +function link_link(jodit) { + if (jodit.options.link.followOnDblClick) { + jodit.events.on('afterInit', () => { + jodit.events.on(jodit.editor, 'dblclick', function (e) { + const href = this.getAttribute('href'); + if (href) { + location.href = href; + e.preventDefault(); + } + }, 'a'); + }); + } + if (jodit.options.link.processPastedLink) { + jodit.events.on('processPaste', (event, html) => { + if (isURL(html)) { + if (jodit.options.link.processVideoLink) { + const embed = convertMediaURLToVideoEmbed(html); + if (embed !== html) { + return jodit.create.inside.fromHTML(embed); + } + } + const a = jodit.create.inside.element('a'); + a.setAttribute('href', html); + a.textContent = html; + return a; + } + }); + } + if (jodit.options.link.removeLinkAfterFormat) { + jodit.events.on('afterCommand', (command) => { + const sel = jodit.selection; + let newtag, node; + if (command === 'removeFormat') { + node = sel.current(); + if (node && node.nodeName !== 'A') { + node = Dom_Dom.closest(node, 'A', jodit.editor); + } + if (node && node.nodeName === 'A') { + if (node.innerHTML === + node.textContent) { + newtag = jodit.editorDocument.createTextNode(node.innerHTML); + } + else { + newtag = jodit.editorDocument.createElement('span'); + newtag.innerHTML = node.innerHTML; + } + if (node.parentNode) { + node.parentNode.replaceChild(newtag, node); + jodit.selection.setCursorIn(newtag, true); + } + } + } + }); + } +} + +// CONCATENATED MODULE: ./src/plugins/media.ts +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ + + + + +Config_Config.prototype.mediaFakeTag = 'jodit-media'; +Config_Config.prototype.mediaInFakeBlock = true; +Config_Config.prototype.mediaBlocks = ['video', 'audio']; +function media(editor) { + const keyFake = 'jodit_fake_wrapper'; + const { mediaFakeTag, mediaBlocks, mediaInFakeBlock } = editor.options; + const wrap = (element) => { + if (element.parentNode && + element.parentNode.getAttribute('data-jodit_iframe_wrapper')) { + element = element.parentNode; + } + else { + let wrapper; + wrapper = editor.create.inside.fromHTML('<' + + mediaFakeTag + + ' data-jodit-temp="1" ' + + 'contenteditable="false" ' + + 'draggable="true" ' + + 'data-' + + keyFake + + '="1">' + + ''); + wrapper.style.display = + element.style.display === 'inline-block' + ? 'inline-block' + : 'block'; + wrapper.style.width = element.offsetWidth + 'px'; + wrapper.style.height = element.offsetHeight + 'px'; + if (element.parentNode) { + element.parentNode.insertBefore(wrapper, element); + } + wrapper.appendChild(element); + element = wrapper; + } + editor.events + .off(element, 'mousedown.select touchstart.select') + .on(element, 'mousedown.select touchstart.select', () => { + editor.selection.setCursorAfter(element); + }); + }; + if (mediaInFakeBlock) { + editor.events + .on('afterGetValueFromEditor', (data) => { + const rxp = new RegExp(`<${mediaFakeTag}[^>]+data-${keyFake}[^>]+>(.+?)`, 'ig'); + if (rxp.test(data.value)) { + data.value = data.value.replace(rxp, '$1'); + } + }) + .on('change afterInit afterSetMode', debounce(() => { + if (!editor.isDestructed && + editor.getMode() !== MODE_SOURCE) { + $$(mediaBlocks.join(','), editor.editor).forEach((elm) => { + if (!elm['__' + keyFake]) { + elm['__' + keyFake] = true; + wrap(elm); + } + }); + } + }, editor.defaultTimeout)); + } +} + +// CONCATENATED MODULE: ./src/plugins/mobile.ts +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ + + + + +Config_Config.prototype.mobileTapTimeout = 300; +Config_Config.prototype.toolbarAdaptive = true; +Config_Config.prototype.controls.dots = { + mode: MODE_SOURCE + MODE_WYSIWYG, + popup: (editor, current, control, close, button) => { + let store = control.data; + if (store === undefined) { + store = { + container: editor.create.div(), + toolbar: joditToolbarCollection_JoditToolbarCollection.makeCollection(editor), + rebuild: () => { + if (button) { + const buttons = editor.events.fire('getDiffButtons.mobile', button.parentToolbar); + if (buttons && store) { + store.toolbar.build(splitArray(buttons), store.container); + } + } + } + }; + let w = 32; + const size = editor.options.toolbarButtonSize; + if (size === 'large') { + w = 36; + } + else if (size === 'small') { + w = 24; + } + store.container.style.width = (w * 3) + 'px'; + control.data = store; + } + store.rebuild(); + return store.container; + } +}; +function mobile(editor) { + let timeout = 0, now, store = splitArray(editor.options.buttons); + editor.events + .on('touchend', (e) => { + if (e.changedTouches && e.changedTouches.length) { + now = new Date().getTime(); + if (now - timeout > editor.options.mobileTapTimeout) { + timeout = now; + editor.selection.insertCursorAtPoint(e.changedTouches[0].clientX, e.changedTouches[0].clientY); + } + } + }) + .on('getDiffButtons.mobile', (toolbar) => { + if (toolbar === editor.toolbar) { + return splitArray(editor.options.buttons).filter((i) => { + return store.indexOf(i) < 0; + }); + } + }); + if (editor.options.toolbarAdaptive) { + editor.events.on('resize afterInit', () => { + if (!editor.options.toolbar) { + return; + } + const width = editor.container.offsetWidth; + let newStore = []; + if (width >= editor.options.sizeLG) { + newStore = splitArray(editor.options.buttons); + } + else if (width >= editor.options.sizeMD) { + newStore = splitArray(editor.options.buttonsMD); + } + else if (width >= editor.options.sizeSM) { + newStore = splitArray(editor.options.buttonsSM); + } + else { + newStore = splitArray(editor.options.buttonsXS); + } + if (newStore.toString() !== store.toString()) { + store = newStore; + editor.toolbar.build(store.concat(editor.options.extraButtons), editor.toolbar.container.parentElement || editor.toolbar.getParentContainer()); + } + }); + } +} + +// CONCATENATED MODULE: ./src/plugins/orderedlist.ts +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ + + +Config_Config.prototype.controls.ul = { + command: 'insertUnorderedList', + controlName: 'ul', + tags: ['ul'], + tooltip: 'Insert Unordered List' +}; +Config_Config.prototype.controls.ol = { + command: 'insertOrderedList', + controlName: 'ol', + tags: ['ol'], + tooltip: 'Insert Ordered List' +}; +function orderedlist(editor) { + editor.events.on('afterCommand', (command) => { + if (/insert(un)?orderedlist/i.test(command)) { + const ul = Dom_Dom.up(editor.selection.current(), (tag) => tag && /^UL|OL$/i.test(tag.nodeName), editor.editor); + if (ul && ul.parentNode && ul.parentNode.nodeName === 'P') { + const selection = editor.selection.save(); + Dom_Dom.unwrap(ul.parentNode); + Array.from(ul.childNodes).forEach((li) => { + if (li.lastChild && + li.lastChild.nodeType === Node.ELEMENT_NODE && + li.lastChild.nodeName === 'BR') { + Dom_Dom.safeRemove(li.lastChild); + } + }); + editor.selection.restore(selection); + } + editor.setEditorValue(); + } + }); +} + +// CONCATENATED MODULE: ./src/plugins/placeholder.ts +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ + + + + + +Config_Config.prototype.showPlaceholder = true; +Config_Config.prototype.useInputsPlaceholder = true; +Config_Config.prototype.placeholder = 'Type something'; +function placeholder_placeholder(editor) { + if (!editor.options.showPlaceholder) { + return; + } + this.destruct = () => { + Dom_Dom.safeRemove(placeholderElm); + }; + const show = () => { + if (!placeholderElm.parentNode || editor.options.readonly) { + return; + } + let marginTop = 0, marginLeft = 0; + const style = editor.editorWindow.getComputedStyle(editor.editor); + if (editor.editor.firstChild && + editor.editor.firstChild.nodeType === Node.ELEMENT_NODE) { + const style2 = editor.editorWindow.getComputedStyle(editor.editor.firstChild); + marginTop = parseInt(style2.getPropertyValue('margin-top'), 10); + marginLeft = parseInt(style2.getPropertyValue('margin-left'), 10); + placeholderElm.style.fontSize = + parseInt(style2.getPropertyValue('font-size'), 10) + 'px'; + placeholderElm.style.lineHeight = style2.getPropertyValue('line-height'); + } + else { + placeholderElm.style.fontSize = + parseInt(style.getPropertyValue('font-size'), 10) + 'px'; + placeholderElm.style.lineHeight = style.getPropertyValue('line-height'); + } + css_css(placeholderElm, { + display: 'block', + marginTop: Math.max(parseInt(style.getPropertyValue('margin-top'), 10), marginTop), + marginLeft: Math.max(parseInt(style.getPropertyValue('margin-left'), 10), marginLeft) + }); + }, hide = () => { + if (placeholderElm.parentNode) { + placeholderElm.style.display = 'none'; + } + }, toggle = debounce(() => { + if (placeholderElm.parentNode === null) { + return; + } + if (!editor.editor) { + return; + } + if (editor.getRealMode() !== MODE_WYSIWYG) { + return hide(); + } + const value = editor.getEditorValue(); + if (value && !/^<(p|div|h[1-6])><\/\1>$/.test(value)) { + hide(); + } + else { + show(); + } + }, editor.defaultTimeout / 10); + const placeholderElm = editor.create.fromHTML(''); + if (editor.options.direction === 'rtl') { + placeholderElm.style.right = '0px'; + placeholderElm.style.direction = 'rtl'; + } + if (editor.options.useInputsPlaceholder && + editor.element.hasAttribute('placeholder')) { + placeholderElm.innerHTML = + editor.element.getAttribute('placeholder') || ''; + } + editor.events + .on('readonly', (isReadOnly) => { + if (isReadOnly) { + hide(); + } + else { + toggle(); + } + }) + .on('afterInit', () => { + editor.workplace.appendChild(placeholderElm); + toggle(); + editor.events.fire('placeholder', placeholderElm.innerHTML); + editor.events + .on('change keyup mouseup keydown mousedown afterSetMode', toggle) + .on(window, 'load', toggle); + }); +} + +// CONCATENATED MODULE: ./src/plugins/redoundo.ts +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ + + + +Config_Config.prototype.controls.redo = { + mode: MODE_SPLIT, + isDisable: (editor) => !editor.observer.stack.canRedo(), + tooltip: 'Redo' +}; +Config_Config.prototype.controls.undo = { + mode: MODE_SPLIT, + isDisable: (editor) => !editor.observer.stack.canUndo(), + tooltip: 'Undo' +}; +class redoundo_redoundo extends Plugin_Plugin { + beforeDestruct() { + } + afterInit(editor) { + const callback = (command) => { + if (editor.getRealMode() === MODE_WYSIWYG) { + editor.observer[command](); + } + return false; + }; + editor.registerCommand('redo', { + exec: callback, + hotkeys: ['ctrl+y', 'ctrl+shift+z', 'cmd+y', 'cmd+shift+z'] + }); + editor.registerCommand('undo', { + exec: callback, + hotkeys: ['ctrl+z', 'cmd+z'] + }); + } +} + +// CONCATENATED MODULE: ./src/plugins/resizer.ts +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ + + + + + + + + +Config_Config.prototype.useIframeResizer = true; +Config_Config.prototype.useTableResizer = true; +Config_Config.prototype.useImageResizer = true; +Config_Config.prototype.resizer = { + showSize: true, + hideSizeTimeout: 1000, + min_width: 10, + min_height: 10 +}; +function resizer(editor) { + const LOCK_KEY = 'resizer'; + let handle, currentElement, resizeElementClicked = false, isResizing = false, start_x, start_y, width, height, ratio, new_h, new_w, diff_x, diff_y, resizerIsVisible = false, timeoutSizeViewer = 0; + const resizerElm = editor.create.fromHTML(''), sizeViewer = resizerElm.getElementsByTagName('span')[0], hideResizer = () => { + isResizing = false; + resizerIsVisible = false; + currentElement = null; + resizerElm.style.display = 'none'; + }, hideSizeViewer = () => { + sizeViewer.style.opacity = '0'; + }, showSizeViewer = (w, h) => { + if (!editor.options.resizer.showSize) { + return; + } + if (w < sizeViewer.offsetWidth || h < sizeViewer.offsetHeight) { + hideSizeViewer(); + return; + } + sizeViewer.style.opacity = '1'; + sizeViewer.innerHTML = `${w} x ${h}`; + clearTimeout(timeoutSizeViewer); + timeoutSizeViewer = setTimeout_setTimeout(hideSizeViewer, editor.options.resizer.hideSizeTimeout); + }, updateSize = () => { + if (resizerIsVisible && currentElement && resizerElm) { + const workplacePosition = offset((resizerElm.parentNode || + editor.ownerDocument + .documentElement), editor, editor.ownerDocument, true), pos = offset(currentElement, editor, editor.editorDocument), left = parseInt(resizerElm.style.left || '0', 10), top = parseInt(resizerElm.style.top || '0', 10), w = resizerElm.offsetWidth, h = resizerElm.offsetHeight; + const newTop = pos.top - 1 - workplacePosition.top, newLeft = pos.left - 1 - workplacePosition.left; + if (top !== newTop || + left !== newLeft || + w !== currentElement.offsetWidth || + h !== currentElement.offsetHeight) { + resizerElm.style.top = newTop + 'px'; + resizerElm.style.left = newLeft + 'px'; + resizerElm.style.width = currentElement.offsetWidth + 'px'; + resizerElm.style.height = + currentElement.offsetHeight + 'px'; + if (editor.events) { + editor.events.fire(currentElement, 'changesize'); + if (!isNaN(left)) { + editor.events.fire('resize'); + } + } + } + } + }, showResizer = () => { + if (editor.options.readonly) { + return; + } + if (!resizerElm.parentNode) { + editor.workplace.appendChild(resizerElm); + } + resizerIsVisible = true; + resizerElm.style.display = 'block'; + if (editor.isFullSize()) { + resizerElm.style.zIndex = css_css(editor.container, 'zIndex').toString(); + } + updateSize(); + }, bind = (element) => { + let wrapper; + if (element.tagName === 'IFRAME') { + const iframe = element; + if (element.parentNode && + element.parentNode.getAttribute('data-jodit_iframe_wrapper')) { + element = element.parentNode; + } + else { + wrapper = editor.create.inside.fromHTML(''); + wrapper.style.display = + element.style.display === 'inline-block' + ? 'inline-block' + : 'block'; + wrapper.style.width = element.offsetWidth + 'px'; + wrapper.style.height = element.offsetHeight + 'px'; + if (element.parentNode) { + element.parentNode.insertBefore(wrapper, element); + } + wrapper.appendChild(element); + element = wrapper; + } + editor.events + .off(element, 'mousedown.select touchstart.select') + .on(element, 'mousedown.select touchstart.select', () => { + editor.selection.select(element); + }); + editor.events + .off(element, 'changesize') + .on(element, 'changesize', () => { + iframe.setAttribute('width', element.offsetWidth + 'px'); + iframe.setAttribute('height', element.offsetHeight + 'px'); + }); + } + let timer; + editor.events + .on(element, 'dragstart', hideResizer) + .on(element, 'mousedown', (event) => { + if (IS_IE && element.nodeName === 'IMG') { + event.preventDefault(); + } + }) + .on(element, 'mousedown touchstart', () => { + if (!resizeElementClicked) { + resizeElementClicked = true; + currentElement = element; + showResizer(); + if (currentElement.tagName === 'IMG' && + !currentElement.complete) { + currentElement.addEventListener('load', function ElementOnLoad() { + updateSize(); + if (currentElement) { + currentElement.removeEventListener('load', ElementOnLoad); + } + }); + } + clearTimeout(timer); + } + timer = setTimeout_setTimeout(() => { + resizeElementClicked = false; + }, 400); + }); + }; + $$('i', resizerElm).forEach((resizeHandle) => { + editor.events.on(resizeHandle, 'mousedown touchstart', (e) => { + if (!currentElement || !currentElement.parentNode) { + hideResizer(); + return false; + } + handle = resizeHandle; + e.preventDefault(); + e.stopImmediatePropagation(); + width = currentElement.offsetWidth; + height = currentElement.offsetHeight; + ratio = width / height; + isResizing = true; + start_x = e.clientX; + start_y = e.clientY; + editor.events.fire('hidePopup'); + editor.lock(LOCK_KEY); + }); + }); + editor.events + .on('readonly', (isReadOnly) => { + if (isReadOnly) { + hideResizer(); + } + }) + .on('beforeDestruct', () => { + Dom_Dom.safeRemove(resizerElm); + }) + .on('afterInit', () => { + editor.events + .on(editor.editor, 'keydown', (e) => { + if (resizerIsVisible && + e.which === KEY_DELETE && + currentElement && + currentElement.tagName.toLowerCase() !== 'table') { + if (currentElement.tagName !== 'JODIT') { + editor.selection.select(currentElement); + } + else { + Dom_Dom.safeRemove(currentElement); + hideResizer(); + e.preventDefault(); + } + } + }) + .on(editor.ownerWindow, 'mousemove touchmove', (e) => { + if (isResizing) { + diff_x = e.clientX - start_x; + diff_y = e.clientY - start_y; + if (!currentElement) { + return; + } + const className = handle.className; + if ('IMG' === currentElement.tagName) { + if (diff_x) { + new_w = + width + + (className.match(/left/) ? -1 : 1) * + diff_x; + new_h = Math.round(new_w / ratio); + } + else { + new_h = + height + + (className.match(/top/) ? -1 : 1) * + diff_y; + new_w = Math.round(new_h * ratio); + } + if (new_w > + innerWidth_innerWidth(editor.editor, editor.ownerWindow)) { + new_w = innerWidth_innerWidth(editor.editor, editor.ownerWindow); + new_h = Math.round(new_w / ratio); + } + } + else { + new_w = + width + + (className.match(/left/) ? -1 : 1) * diff_x; + new_h = + height + + (className.match(/top/) ? -1 : 1) * diff_y; + } + if (new_w > editor.options.resizer.min_width) { + if (new_w < + resizerElm.parentNode + .offsetWidth) { + currentElement.style.width = new_w + 'px'; + } + else { + currentElement.style.width = '100%'; + } + } + if (new_h > editor.options.resizer.min_height) { + currentElement.style.height = new_h + 'px'; + } + updateSize(); + showSizeViewer(currentElement.offsetWidth, currentElement.offsetHeight); + e.stopImmediatePropagation(); + } + }) + .on(editor.ownerWindow, 'resize', () => { + if (resizerIsVisible) { + updateSize(); + } + }) + .on(editor.ownerWindow, 'mouseup keydown touchend', (e) => { + if (resizerIsVisible && !resizeElementClicked) { + if (isResizing) { + editor.unlock(); + isResizing = false; + editor.setEditorValue(); + e.stopImmediatePropagation(); + } + else { + hideResizer(); + } + } + }) + .on([editor.ownerWindow, editor.editor], 'scroll', () => { + if (resizerIsVisible && !isResizing) { + hideResizer(); + } + }); + }) + .on('afterGetValueFromEditor', (data) => { + const rgx = /]+data-jodit_iframe_wrapper[^>]+>(.*?]+>[\s\n\r]*<\/iframe>.*?)<\/jodit>/gi; + if (rgx.test(data.value)) { + data.value = data.value.replace(rgx, '$1'); + } + }) + .on('hideResizer', hideResizer) + .on('change afterInit afterSetMode', debounce(() => { + if (resizerIsVisible) { + if (!currentElement || !currentElement.parentNode) { + hideResizer(); + } + else { + updateSize(); + } + } + if (!editor.isDestructed) { + $$('img, table, iframe', editor.editor).forEach((elm) => { + if (editor.getMode() === MODE_SOURCE) { + return; + } + if (!elm.__jodit_resizer_binded && + ((elm.tagName === 'IFRAME' && + editor.options.useIframeResizer) || + (elm.tagName === 'IMG' && + editor.options.useImageResizer) || + (elm.tagName === 'TABLE' && + editor.options.useTableResizer))) { + elm.__jodit_resizer_binded = true; + bind(elm); + } + }); + } + }, editor.defaultTimeout)); +} + +// CONCATENATED MODULE: ./src/plugins/search.ts +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ + + + + + + + + +Config_Config.prototype.useSearch = true; +class search_search extends Plugin_Plugin { + constructor() { + super(...arguments); + this.template = ''; + this.isOpened = false; + this.selInfo = null; + this.current = false; + this.eachMap = (node, callback, next) => { + Dom_Dom.findWithCurrent(node, (child) => { + return !!child && callback(child); + }, this.jodit.editor, next ? 'nextSibling' : 'previousSibling', next ? 'firstChild' : 'lastChild'); + }; + this.updateCounters = () => { + if (!this.isOpened) { + return; + } + this.counterBox.style.display = this.queryInput.value.length + ? 'inline-block' + : 'none'; + const range = this.jodit.selection.range, counts = this.calcCounts(this.queryInput.value, range); + this.counterBox.textContent = counts.join('/'); + }; + this.calcCounts = (query, current = false) => { + const bounds = []; + let currentIndex = 0, count = 0, bound = false, start = this.jodit.editor.firstChild; + while (start && query.length) { + bound = this.find(start, query, true, 0, bound || this.jodit.editorDocument.createRange()); + if (bound) { + if (this.boundAlreadyWas(bound, bounds)) { + break; + } + bounds.push(bound); + start = bound.startContainer; + count += 1; + if (current && this.boundAlreadyWas(current, [bound])) { + currentIndex = count; + } + } + else { + start = null; + } + } + return [currentIndex, count]; + }; + this.findAndReplace = (start, query) => { + const range = this.jodit.selection.range, bound = this.find(start, query, true, 0, range); + if (bound && bound.startContainer && bound.endContainer) { + const rng = this.jodit.editorDocument.createRange(); + try { + if (bound && bound.startContainer && bound.endContainer) { + rng.setStart(bound.startContainer, bound.startOffset); + rng.setEnd(bound.endContainer, bound.endOffset); + rng.deleteContents(); + const textNode = this.jodit.editorDocument.createTextNode(this.replaceInput.value); + rng.insertNode(textNode); + this.jodit.selection.select(textNode); + this.tryScrollToElement(textNode); + } + } + catch (_a) { } + return true; + } + return false; + }; + this.findAndSelect = (start, query, next) => { + const range = this.jodit.selection.range, bound = this.find(start, query, next, 0, range); + if (bound && bound.startContainer && bound.endContainer) { + const rng = this.jodit.editorDocument.createRange(); + try { + rng.setStart(bound.startContainer, bound.startOffset); + rng.setEnd(bound.endContainer, bound.endOffset); + this.jodit.selection.selectRange(rng); + } + catch (e) { } + this.tryScrollToElement(bound.startContainer); + this.current = bound.startContainer; + this.updateCounters(); + return true; + } + return false; + }; + this.find = (start, query, next, deep, range) => { + if (start && query.length) { + let sentence = '', bound = { + startContainer: null, + startOffset: null, + endContainer: null, + endOffset: null + }; + this.eachMap(start, (elm) => { + if (elm.nodeType === Node.TEXT_NODE && + elm.nodeValue !== null && + elm.nodeValue.length) { + let value = elm.nodeValue; + if (!next && elm === range.startContainer) { + value = !deep + ? value.substr(0, range.startOffset) + : value.substr(range.endOffset); + } + else if (next && elm === range.endContainer) { + value = !deep + ? value.substr(range.endOffset) + : value.substr(0, range.startOffset); + } + const tmpSentence = next + ? sentence + value + : value + sentence; + const part = search_search.findSomePartOfString(query, tmpSentence, next); + if (part !== false) { + let currentPart = search_search.findSomePartOfString(query, value, next); + if (currentPart === true) { + currentPart = trim(query); + } + else if (currentPart === false) { + currentPart = search_search.findSomePartOfString(value, query, next); + if (currentPart === true) { + currentPart = trim(value); + } + } + let currentPartIndex = search_search.getSomePartOfStringIndex(query, value, next) || 0; + if (((next && !deep) || (!next && deep)) && + elm.nodeValue.length - value.length > 0) { + currentPartIndex += + elm.nodeValue.length - value.length; + } + if (bound.startContainer === null) { + bound.startContainer = elm; + bound.startOffset = currentPartIndex; + } + if (part !== true) { + sentence = tmpSentence; + } + else { + bound.endContainer = elm; + bound.endOffset = currentPartIndex; + bound.endOffset += currentPart.length; + return true; + } + } + else { + sentence = ''; + bound = { + startContainer: null, + startOffset: null, + endContainer: null, + endOffset: null + }; + } + } + else if (Dom_Dom.isBlock(elm, this.jodit.editorWindow) && + sentence !== '') { + sentence = next ? sentence + ' ' : ' ' + sentence; + } + return false; + }, next); + if (bound.startContainer && bound.endContainer) { + return bound; + } + if (!deep) { + this.current = next + ? this.jodit.editor.firstChild + : this.jodit.editor.lastChild; + return this.find(this.current, query, next, deep + 1, range); + } + } + return false; + }; + this.open = (searchAndReplace = false) => { + if (!this.isOpened) { + this.searchBox.classList.add('jodit_search-active'); + this.isOpened = true; + } + this.jodit.events.fire('hidePopup'); + this.searchBox.classList.toggle('jodit_search-and-replace', searchAndReplace); + this.current = this.jodit.selection.current(); + this.selInfo = this.jodit.selection.save(); + const selStr = (this.jodit.selection.sel || '').toString(); + if (selStr) { + this.queryInput.value = selStr; + } + this.updateCounters(); + if (selStr) { + this.queryInput.select(); + } + else { + this.queryInput.focus(); + } + }; + this.close = () => { + if (!this.isOpened) { + return; + } + if (this.selInfo) { + this.jodit.selection.restore(this.selInfo); + this.selInfo = null; + } + this.searchBox.classList.remove('jodit_search-active'); + this.isOpened = false; + }; + } + static getSomePartOfStringIndex(needle, haystack, start = true) { + return this.findSomePartOfString(needle, haystack, start, true); + } + static findSomePartOfString(needle, haystack, start = true, getIndex = false) { + needle = trim(needle.toLowerCase().replace(SPACE_REG_EXP, ' ')); + haystack = haystack.toLowerCase(); + let i = start ? 0 : haystack.length - 1, needleStart = start ? 0 : needle.length - 1, tmpEqualLength = 0, startAtIndex = null; + const inc = start ? 1 : -1, tmp = []; + for (; haystack[i] !== undefined; i += inc) { + const some = needle[needleStart] === haystack[i]; + if (some || + (startAtIndex !== null && + SPACE_REG_EXP.test(haystack[i]))) { + if (startAtIndex === null || !start) { + startAtIndex = i; + } + tmp.push(haystack[i]); + if (some) { + tmpEqualLength += 1; + needleStart += inc; + } + } + else { + startAtIndex = null; + tmp.length = 0; + tmpEqualLength = 0; + needleStart = start ? 0 : needle.length - 1; + } + if (tmpEqualLength === needle.length) { + return getIndex ? startAtIndex : true; + } + } + if (getIndex) { + return (startAtIndex !== null && startAtIndex !== void 0 ? startAtIndex : false); + } + if (tmp.length) { + return start ? tmp.join('') : tmp.reverse().join(''); + } + return false; + } + boundAlreadyWas(current, bounds) { + return bounds.some((bound) => { + return (bound.startContainer === current.startContainer && + bound.endContainer === current.endContainer && + bound.startOffset === current.startOffset && + bound.endOffset === current.endOffset); + }, false); + } + tryScrollToElement(startContainer) { + let parentBox = Dom_Dom.closest(startContainer, elm => elm && elm.nodeType === Node.ELEMENT_NODE, this.jodit.editor); + if (!parentBox) { + parentBox = Dom_Dom.prev(startContainer, (elm) => elm && elm.nodeType === Node.ELEMENT_NODE, this.jodit.editor); + } + parentBox && + parentBox !== this.jodit.editor && + parentBox.scrollIntoView(); + } + afterInit(editor) { + if (editor.options.useSearch) { + const self = this; + self.searchBox = editor.create.fromHTML(self.template); + const qs = self.searchBox.querySelector.bind(self.searchBox); + self.queryInput = qs('input.jodit_search-query'); + self.replaceInput = qs('input.jodit_search-replace'); + self.closeButton = qs('.jodit_search_buttons-cancel'); + self.nextButton = qs('.jodit_search_buttons-next'); + self.prevButton = qs('.jodit_search_buttons-prev'); + self.replaceButton = qs('.jodit_search_buttons-replace'); + self.counterBox = qs('.jodit_search_counts span'); + editor.workplace.appendChild(this.searchBox); + editor.events + .on(self.closeButton, 'click', this.close) + .on(self.queryInput, 'mousedown', () => { + if (editor.selection.isFocused()) { + editor.selection.removeMarkers(); + self.selInfo = editor.selection.save(); + } + }) + .on(self.replaceButton, 'click', (e) => { + self.findAndReplace(editor.selection.current() || editor.editor.firstChild, self.queryInput.value); + this.updateCounters(); + e.preventDefault(); + e.stopImmediatePropagation(); + }) + .on([self.nextButton, self.prevButton], 'click', function (e) { + editor.events.fire(self.nextButton === this + ? 'searchNext' + : 'searchPrevious'); + e.preventDefault(); + e.stopImmediatePropagation(); + }) + .on(this.queryInput, 'keydown', debounce((e) => { + switch (e.which) { + case KEY_ENTER: + e.preventDefault(); + e.stopImmediatePropagation(); + if (editor.events.fire('searchNext')) { + this.close(); + } + break; + default: + this.updateCounters(); + break; + } + }, this.jodit.defaultTimeout)) + .on(this.jodit.container, 'keydown.search', (e) => { + if (editor.getRealMode() !== MODE_WYSIWYG) { + return; + } + switch (e.which) { + case KEY_ESC: + this.close(); + break; + case KEY_F3: + if (self.queryInput.value) { + editor.events.fire(!e.shiftKey + ? 'searchNext' + : 'searchPrevious'); + e.preventDefault(); + } + break; + } + }) + .on('beforeSetMode.search', () => { + this.close(); + }) + .on('keydown.search mousedown.search', () => { + if (this.selInfo) { + editor.selection.removeMarkers(); + this.selInfo = null; + } + if (this.isOpened) { + this.current = this.jodit.selection.current(); + this.updateCounters(); + } + }) + .on('searchNext.search searchPrevious.search', () => { + return self.findAndSelect(editor.selection.current() || editor.editor.firstChild, self.queryInput.value, editor.events.current[editor.events.current.length - 1] === 'searchNext'); + }) + .on('search.search', (value, next = true) => { + editor.execCommand('search', value, next); + }); + editor.registerCommand('search', { + exec: (command, value, next = true) => { + self.findAndSelect(editor.selection.current() || editor.editor.firstChild, value || '', next); + return false; + } + }); + editor.registerCommand('openSearchDialog', { + exec: () => { + self.open(); + return false; + }, + hotkeys: ['ctrl+f', 'cmd+f'] + }); + editor.registerCommand('openReplaceDialog', { + exec: () => { + if (!editor.options.readonly) { + self.open(true); + } + return false; + }, + hotkeys: ['ctrl+h', 'cmd+h'] + }); + } + } + beforeDestruct(jodit) { + Dom_Dom.safeRemove(this.searchBox); + jodit.events && jodit.events.off('.search'); + jodit.events && jodit.events.off(jodit.container, '.search'); + } +} + +// CONCATENATED MODULE: ./src/plugins/size.ts +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ + + + +Config_Config.prototype.allowResizeX = false; +Config_Config.prototype.allowResizeY = true; +function size_size(editor) { + const setHeight = (height) => { + css_css(editor.container, 'height', height); + if (editor.options.saveHeightInStorage) { + editor.storage.set('height', height); + } + }; + const setWidth = (width) => css_css(editor.container, 'width', width); + const setHeightWorkPlace = (height) => css_css(editor.workplace, 'height', height); + if (editor.options.height !== 'auto' && + (editor.options.allowResizeX || editor.options.allowResizeY)) { + const handle = editor.create.div('jodit_editor_resize', ''), start = { + x: 0, + y: 0, + w: 0, + h: 0 + }; + let isResized = false; + editor.events + .on(handle, 'mousedown touchstart', (e) => { + isResized = true; + start.x = e.clientX; + start.y = e.clientY; + start.w = editor.container.offsetWidth; + start.h = editor.container.offsetHeight; + editor.lock(); + e.preventDefault(); + }) + .on(editor.ownerWindow, 'mousemove touchmove', throttle((e) => { + if (isResized) { + if (editor.options.allowResizeY) { + setHeight(start.h + e.clientY - start.y); + } + if (editor.options.allowResizeX) { + setWidth(start.w + e.clientX - start.x); + } + resizeWorkspaceImd(); + editor.events.fire('resize'); + } + }, editor.defaultTimeout / 10)) + .on(editor.ownerWindow, 'mouseup touchsend', () => { + if (isResized) { + isResized = false; + editor.unlock(); + } + }) + .on('afterInit', () => { + editor.container.appendChild(handle); + }) + .on('toggleFullSize', (fullsize) => { + handle.style.display = fullsize ? 'none' : 'block'; + }); + } + const getNotWorkHeight = () => (editor.options.toolbar ? editor.toolbar.container.offsetHeight : 0) + + (editor.statusbar ? editor.statusbar.getHeight() : 0); + const calcMinHeightWorkspace = () => { + if (!editor.container || !editor.container.parentNode) { + return; + } + const minHeight = css_css(editor.container, 'minHeight') - getNotWorkHeight(); + [editor.workplace, editor.iframe, editor.editor].map(elm => { + const minHeightD = elm === editor.editor ? minHeight - 2 : minHeight; + elm && css_css(elm, 'minHeight', minHeightD); + editor.events.fire('setMinHeight', minHeightD); + }); + }; + const resizeWorkspaceImd = () => { + if (!editor || + editor.isDestructed || + !editor.options || + editor.options.inline) { + return; + } + calcMinHeightWorkspace(); + if (editor.container && + (editor.options.height !== 'auto' || editor.isFullSize())) { + setHeightWorkPlace(editor.container.offsetHeight - getNotWorkHeight()); + } + }; + const resizeWorkspace = debounce(resizeWorkspaceImd, editor.defaultTimeout); + editor.events + .on('toggleFullSize', (fullsize) => { + if (!fullsize && editor.options.height === 'auto') { + setHeightWorkPlace('auto'); + calcMinHeightWorkspace(); + } + }) + .on('afterInit', () => { + if (!editor.options.inline) { + css_css(editor.editor, { + minHeight: '100%' + }); + css_css(editor.container, { + minHeight: editor.options.minHeight, + minWidth: editor.options.minWidth, + maxWidth: editor.options.maxWidth + }); + } + let height = editor.options.height; + if (editor.options.saveHeightInStorage && height !== 'auto') { + const localHeight = editor.storage.get('height'); + if (localHeight) { + height = localHeight; + } + } + if (!editor.options.inline) { + setHeight(height); + setWidth(editor.options.width); + } + resizeWorkspaceImd(); + }, undefined, undefined, true) + .on(window, 'load', resizeWorkspace) + .on('afterInit resize updateToolbar scroll afterResize', resizeWorkspace); +} + +// CONCATENATED MODULE: ./src/plugins/source.ts +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ + + + + + + + + + +Config_Config.prototype.beautifyHTML = true; +Config_Config.prototype.useAceEditor = true; +Config_Config.prototype.sourceEditorNativeOptions = { + showGutter: true, + theme: 'ace/theme/idle_fingers', + mode: 'ace/mode/html', + wrap: true, + highlightActiveLine: true +}; +Config_Config.prototype.sourceEditorCDNUrlsJS = [ + 'https://cdnjs.cloudflare.com/ajax/libs/ace/1.4.5/ace.js' +]; +Config_Config.prototype.beautifyHTMLCDNUrlsJS = [ + 'https://cdnjs.cloudflare.com/ajax/libs/js-beautify/1.10.0/beautify.min.js', + 'https://cdnjs.cloudflare.com/ajax/libs/js-beautify/1.10.0/beautify-html.min.js' +]; +Config_Config.prototype.controls.source = { + mode: MODE_SPLIT, + exec: (editor) => { + editor.toggleMode(); + }, + isActive: (editor) => { + return editor.getRealMode() === MODE_SOURCE; + }, + tooltip: 'Change mode' +}; +class source_source extends Plugin_Plugin { + constructor() { + super(...arguments); + this.className = 'jodit_ace_editor'; + this.__lock = false; + this.__oldMirrorValue = ''; + this.autosize = debounce(() => { + this.mirror.style.height = 'auto'; + this.mirror.style.height = this.mirror.scrollHeight + 'px'; + }, this.jodit.defaultTimeout); + this.tempMarkerStart = '{start-jodit-selection}'; + this.tempMarkerStartReg = /{start-jodit-selection}/g; + this.tempMarkerEnd = '{end-jodit-selection}'; + this.tempMarkerEndReg = /{end-jodit-selection}/g; + this.selInfo = []; + this.lastTuple = null; + this.loadNext = (i, urls, eventOnFinalize = 'aceReady', className = this.className) => { + if (eventOnFinalize && urls[i] === undefined && !this.isDestructed) { + this.jodit && + this.jodit.events && + this.jodit.events.fire(eventOnFinalize); + this.jodit && + this.jodit.events && + this.jodit.events.fire(this.jodit.ownerWindow, eventOnFinalize); + return; + } + if (urls[i] !== undefined) { + if (this.lastTuple) { + this.lastTuple.element.removeEventListener('load', this.lastTuple.callback); + } + this.lastTuple = appendScript(urls[i], () => { + if (!this.isDestructed) { + this.loadNext(i + 1, urls, eventOnFinalize, className); + } + }, className, this.jodit.ownerDocument); + } + }; + this.insertHTML = (html) => { + if (this.mirror.selectionStart || this.mirror.selectionStart === 0) { + const startPos = this.mirror.selectionStart, endPos = this.mirror.selectionEnd; + this.mirror.value = + this.mirror.value.substring(0, startPos) + + html + + this.mirror.value.substring(endPos, this.mirror.value.length); + } + else { + this.mirror.value += this.mirror; + } + this.toWYSIWYG(); + }; + this.fromWYSIWYG = (force = false) => { + if (!this.__lock || force === true) { + this.__lock = true; + const new_value = this.jodit.getEditorValue(false); + if (new_value !== this.getMirrorValue()) { + this.setMirrorValue(new_value); + } + this.__lock = false; + } + }; + this.toWYSIWYG = () => { + if (this.__lock) { + return; + } + const value = this.getMirrorValue(); + if (value === this.__oldMirrorValue) { + return; + } + this.__lock = true; + this.jodit.setEditorValue(value); + this.__lock = false; + this.__oldMirrorValue = value; + }; + this.getNormalPosition = (pos, str) => { + let start = pos; + while (start > 0) { + start--; + if (str[start] === '<' && + str[start + 1] !== undefined && + str[start + 1].match(/[\w\/]+/i)) { + return start; + } + if (str[start] === '>') { + return pos; + } + } + return pos; + }; + this.__clear = (str) => str.replace(INVISIBLE_SPACE_REG_EXP, ''); + this.selectAll = () => { + this.mirror.select(); + }; + this.onSelectAll = (command) => { + if (command.toLowerCase() === 'selectall' && + this.jodit.getRealMode() === MODE_SOURCE) { + this.selectAll(); + return false; + } + }; + this.getSelectionStart = () => { + return this.mirror.selectionStart; + }; + this.getSelectionEnd = () => { + return this.mirror.selectionEnd; + }; + this.saveSelection = () => { + if (this.jodit.getRealMode() === MODE_WYSIWYG) { + this.selInfo = this.jodit.selection.save() || []; + this.jodit.setEditorValue(); + this.fromWYSIWYG(true); + } + else { + this.selInfo.length = 0; + const value = this.getMirrorValue(); + if (this.getSelectionStart() === this.getSelectionEnd()) { + const marker = this.jodit.selection.marker(true); + this.selInfo[0] = { + startId: marker.id, + collapsed: true, + startMarker: marker.outerHTML + }; + const selectionStart = this.getNormalPosition(this.getSelectionStart(), this.getMirrorValue()); + this.setMirrorValue(value.substr(0, selectionStart) + + this.__clear(this.selInfo[0].startMarker) + + value.substr(selectionStart)); + } + else { + const markerStart = this.jodit.selection.marker(true); + const markerEnd = this.jodit.selection.marker(false); + this.selInfo[0] = { + startId: markerStart.id, + endId: markerEnd.id, + collapsed: false, + startMarker: this.__clear(markerStart.outerHTML), + endMarker: this.__clear(markerEnd.outerHTML) + }; + const selectionStart = this.getNormalPosition(this.getSelectionStart(), value); + const selectionEnd = this.getNormalPosition(this.getSelectionEnd(), value); + this.setMirrorValue(value.substr(0, selectionStart) + + this.selInfo[0].startMarker + + value.substr(selectionStart, selectionEnd - selectionStart) + + this.selInfo[0].endMarker + + value.substr(selectionEnd)); + } + this.toWYSIWYG(); + } + }; + this.restoreSelection = () => { + if (!this.selInfo.length) { + return; + } + if (this.jodit.getRealMode() === MODE_WYSIWYG) { + this.__lock = true; + this.jodit.selection.restore(this.selInfo); + this.__lock = false; + return; + } + let value = this.getMirrorValue(); + let selectionStart = 0, selectionEnd = 0; + try { + if (this.selInfo[0].startMarker) { + value = value.replace(/]+data-jodit_selection_marker="start"[^>]*>[<>]*?<\/span>/gim, this.tempMarkerStart); + } + if (this.selInfo[0].endMarker) { + value = value.replace(/]+data-jodit_selection_marker="end"[^>]*>[<>]*?<\/span>/gim, this.tempMarkerEnd); + } + if (this.jodit.ownerWindow.html_beautify && + this.jodit.options.beautifyHTML) { + value = this.jodit.ownerWindow.html_beautify(value); + } + selectionStart = value.indexOf(this.tempMarkerStart); + selectionEnd = selectionStart; + value = value.replace(this.tempMarkerStartReg, ''); + if (!this.selInfo[0].collapsed || selectionStart === -1) { + selectionEnd = value.indexOf(this.tempMarkerEnd); + if (selectionStart === -1) { + selectionStart = selectionEnd; + } + } + value = value.replace(this.tempMarkerEndReg, ''); + } + finally { + value = value + .replace(this.tempMarkerEndReg, '') + .replace(this.tempMarkerStartReg, ''); + } + this.setMirrorValue(value); + this.setMirrorSelectionRange(selectionStart, selectionEnd); + this.toWYSIWYG(); + this.setFocusToMirror(); + }; + this.__proxyOnFocus = (e) => { + this.jodit.events.fire('focus', e); + }; + this.__proxyOnMouseDown = (e) => { + this.jodit.events.fire('mousedown', e); + }; + this.setMirrorSelectionRange = (start, end) => { + this.mirror.setSelectionRange(start, end); + }; + this.onReadonlyReact = () => { + const isReadOnly = this.jodit.options.readonly; + if (isReadOnly) { + this.mirror.setAttribute('readonly', 'true'); + } + else { + this.mirror.removeAttribute('readonly'); + } + if (this.aceEditor) { + this.aceEditor.setReadOnly(isReadOnly); + } + }; + } + getMirrorValue() { + return this.mirror.value; + } + setMirrorValue(value) { + this.mirror.value = value; + } + setFocusToMirror() { + this.mirror.focus(); + } + replaceMirrorToACE() { + const editor = this.jodit; + let aceEditor, undoManager; + const updateButtons = () => { + if (undoManager && + editor.getRealMode() === MODE_SOURCE) { + editor.events.fire('canRedo', undoManager.hasRedo()); + editor.events.fire('canUndo', undoManager.hasUndo()); + } + }, getLastColumnIndex = (row) => { + return aceEditor.session.getLine(row).length; + }, getLastColumnIndices = () => { + const rows = aceEditor.session.getLength(); + const lastColumnIndices = []; + let lastColIndex = 0; + for (let i = 0; i < rows; i++) { + lastColIndex += getLastColumnIndex(i); + if (i > 0) { + lastColIndex += 1; + } + lastColumnIndices[i] = lastColIndex; + } + return lastColumnIndices; + }, getRowColumnIndices = (characterIndex) => { + const lastColumnIndices = getLastColumnIndices(); + if (characterIndex <= lastColumnIndices[0]) { + return { row: 0, column: characterIndex }; + } + let row = 1; + for (let i = 1; i < lastColumnIndices.length; i++) { + if (characterIndex > lastColumnIndices[i]) { + row = i + 1; + } + } + const column = characterIndex - lastColumnIndices[row - 1] - 1; + return { row, column }; + }, setSelectionRangeIndices = (start, end) => { + const startRowColumn = getRowColumnIndices(start); + const endRowColumn = getRowColumnIndices(end); + aceEditor.getSelection().setSelectionRange({ + start: startRowColumn, + end: endRowColumn + }); + }, getIndexByRowColumn = (row, column) => { + const lastColumnIndices = getLastColumnIndices(); + return (lastColumnIndices[row] - getLastColumnIndex(row) + column); + }, tryInitAceEditor = () => { + if (aceEditor === undefined && + this.jodit.ownerWindow.ace !== undefined) { + this.jodit.events.off(this.jodit.ownerWindow, 'aceReady', tryInitAceEditor); + const fakeMirror = this.jodit.create.div('jodit_source_mirror-fake'); + this.mirrorContainer.insertBefore(fakeMirror, this.mirrorContainer.firstChild); + this.aceEditor = aceEditor = this.jodit + .ownerWindow.ace.edit(fakeMirror); + aceEditor.setTheme(editor.options.sourceEditorNativeOptions.theme); + aceEditor.renderer.setShowGutter(editor.options.sourceEditorNativeOptions.showGutter); + aceEditor + .getSession() + .setMode(editor.options.sourceEditorNativeOptions.mode); + aceEditor.setHighlightActiveLine(editor.options.sourceEditorNativeOptions + .highlightActiveLine); + aceEditor.getSession().setUseWrapMode(true); + aceEditor.setOption('indentedSoftWrap', false); + aceEditor.setOption('wrap', editor.options.sourceEditorNativeOptions.wrap); + aceEditor.getSession().setUseWorker(false); + aceEditor.$blockScrolling = Infinity; + aceEditor.setOptions({ + maxLines: Infinity + }); + aceEditor.on('change', this.toWYSIWYG); + aceEditor.on('focus', this.__proxyOnFocus); + aceEditor.on('mousedown', this.__proxyOnMouseDown); + this.mirror.style.display = 'none'; + undoManager = aceEditor.getSession().getUndoManager(); + this.setMirrorValue = (value) => { + if (editor.options.beautifyHTML && + editor.ownerWindow.html_beautify) { + aceEditor.setValue(editor.ownerWindow.html_beautify(value)); + } + else { + aceEditor.setValue(value); + } + aceEditor.clearSelection(); + updateButtons(); + }; + if (this.jodit.getRealMode() !== MODE_WYSIWYG) { + this.setMirrorValue(this.getMirrorValue()); + } + this.getMirrorValue = () => { + return aceEditor.getValue(); + }; + this.setFocusToMirror = () => { + aceEditor.focus(); + }; + this.getSelectionStart = () => { + const range = aceEditor.selection.getRange(); + return getIndexByRowColumn(range.start.row, range.start.column); + }; + this.getSelectionEnd = () => { + const range = aceEditor.selection.getRange(); + return getIndexByRowColumn(range.end.row, range.end.column); + }; + this.selectAll = () => { + aceEditor.selection.selectAll(); + }; + this.insertHTML = (html) => { + const start = aceEditor.selection.getCursor(), end = aceEditor.session.insert(start, html); + aceEditor.selection.setRange({ + start, + end + }, false); + }; + this.setMirrorSelectionRange = (start, end) => { + setSelectionRangeIndices(start, end); + }; + editor.events + .on('afterResize', () => { + aceEditor.resize(); + }) + .fire('aceInited', editor); + } + }; + editor.events + .on(this.jodit.ownerWindow, 'aceReady', tryInitAceEditor) + .on('aceReady', tryInitAceEditor) + .on('afterSetMode', () => { + if (editor.getRealMode() !== MODE_SOURCE && + editor.getMode() !== MODE_SPLIT) { + return; + } + this.fromWYSIWYG(); + tryInitAceEditor(); + }) + .on('beforeCommand', (command) => { + if (editor.getRealMode() !== MODE_WYSIWYG && + (command === 'redo' || command === 'undo') && + undoManager) { + if (undoManager['has' + + command.substr(0, 1).toUpperCase() + + command.substr(1)]) { + aceEditor[command](); + } + updateButtons(); + return false; + } + }); + tryInitAceEditor(); + if (this.jodit.ownerWindow.ace === undefined && + !$$('script.' + this.className, this.jodit.ownerDocument.body) + .length) { + this.loadNext(0, editor.options.sourceEditorCDNUrlsJS, 'aceReady', this.className); + } + } + afterInit(editor) { + this.mirrorContainer = editor.create.div('jodit_source'); + this.mirror = editor.create.fromHTML('\n\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t`),r={},a=t.selection.save(),l=e=>{t.selection.restore(a),t.selection.insertHTML(e),o()};return t.options.textIcons?(r[t.i18n("Link")]=s,r[t.i18n("Code")]=n):(r[Ce.getIcon("link")+" "+t.i18n("Link")]=s,r[Ce.getIcon("source")+" "+t.i18n("Code")]=n),n.addEventListener("submit",t=>(t.preventDefault(),Bt(je(n,"textarea[name=code]"))?(l(je(n,"textarea[name=code]")),!1):(n.querySelector("textarea[name=code]").focus(),n.querySelector("textarea[name=code]").classList.add("jodit_error"),!1))),s.addEventListener("submit",t=>(t.preventDefault(),Tt(je(s,"input[name=code]"))?(l(ue(je(s,"input[name=code]"))),!1):(s.querySelector("input[name=code]").focus(),s.querySelector("input[name=code]").classList.add("jodit_error"),!1))),Te(t,r)},tags:["iframe"],tooltip:"Insert youtube/vimeo video"}};class Ne{constructor(t){this.__isDestructed=!1,t&&t instanceof Ne&&(this.jodit=t,Ct(t)&&t.components.push(this))}get isDestructed(){return this.__isDestructed}destruct(){this.jodit&&(this.jodit=void 0),this.__isDestructed=!0}}class Me extends Ne{constructor(){super(...arguments),this.isBlocked=!1}static equal(t,e){return t.html===e.html&&JSON.stringify(t.range)===JSON.stringify(e.range)}static countNodesBeforeInParent(t){if(!t.parentNode)return 0;const e=t.parentNode.childNodes;let i,o=0,s=null;for(i=0;e.length>i;i+=1){if(!s||e[i].nodeType===Node.TEXT_NODE&&""===e[i].textContent||s.nodeType===Node.TEXT_NODE&&e[i].nodeType===Node.TEXT_NODE||(o+=1),e[i]===t)return o;s=e[i]}return 0}static strokeOffset(t,e){for(;t&&t.nodeType===Node.TEXT_NODE;)(t=t.previousSibling)&&t.nodeType===Node.TEXT_NODE&&null!==t.textContent&&(e+=t.textContent.length);return e}calcHierarchyLadder(t){const e=[];if(!t||!t.parentNode||!xe.isOrContains(this.jodit.editor,t))return[];for(;t&&t!==this.jodit.editor;)t&&e.push(Me.countNodesBeforeInParent(t)),t=t.parentNode;return e.reverse()}getElementByLadder(t){let e,i=this.jodit.editor;for(e=0;i&&t.length>e;e+=1)i=i.childNodes[t[e]];return i}make(){const t={html:"",range:{startContainer:[],startOffset:0,endContainer:[],endOffset:0}};t.html=this.jodit.getNativeEditorValue();const e=this.jodit.selection.sel;if(e&&e.rangeCount){const i=e.getRangeAt(0),o=this.calcHierarchyLadder(i.startContainer),s=this.calcHierarchyLadder(i.endContainer);let n=Me.strokeOffset(i.startContainer,i.startOffset),r=Me.strokeOffset(i.endContainer,i.endOffset);o.length||i.startContainer===this.jodit.editor||(n=0),s.length||i.endContainer===this.jodit.editor||(r=0),t.range={startContainer:o,startOffset:n,endContainer:s,endOffset:r}}return t}restore(t){this.isBlocked=!0,this.jodit.setEditorValue(t.html);try{if(t.range){const e=this.jodit.editorDocument.createRange();e.setStart(this.getElementByLadder(t.range.startContainer),t.range.startOffset),e.setEnd(this.getElementByLadder(t.range.endContainer),t.range.endOffset),this.jodit.selection.selectRange(e)}}catch(t){}this.isBlocked=!1}destruct(){this.isBlocked=!1,super.destruct()}}class Ae{constructor(){this.commands=[],this.stackPosition=-1}clearRedo(){this.commands.length=this.stackPosition+1}clear(){this.commands.length=0,this.stackPosition=-1}push(t){this.clearRedo(),this.commands.push(t),this.stackPosition+=1}undo(){return!!this.canUndo()&&(this.commands[this.stackPosition]&&this.commands[this.stackPosition].undo(),this.stackPosition-=1,!0)}redo(){return!!this.canRedo()&&(this.stackPosition+=1,this.commands[this.stackPosition]&&this.commands[this.stackPosition].redo(),!0)}canUndo(){return this.stackPosition>=0}canRedo(){return this.commands.length-1>this.stackPosition}}class Ie{constructor(t,e,i){this.observer=i,this.oldValue=t,this.newValue=e}undo(){this.observer.snapshot.restore(this.oldValue)}redo(){this.observer.snapshot.restore(this.newValue)}}qe.prototype.observer={timeout:100};class De extends Ne{constructor(t){super(t),this.onChangeStack=()=>{this.__newValue=this.snapshot.make(),Me.equal(this.__newValue,this.__startValue)||(this.stack.push(new Ie(this.__startValue,this.__newValue,this)),this.__startValue=this.__newValue,this.changeStack())},this.stack=new Ae,this.snapshot=new Me(t);const e=rt(this.onChangeStack,t.defaultTimeout);t.events.on("afterInit.observer",()=>{this.isDestructed||(this.__startValue=this.snapshot.make(),t.events.on("changeSelection.observer selectionstart.observer selectionchange.observer mousedown.observer mouseup.observer keydown.observer keyup.observer",()=>{this.__startValue.html===this.jodit.getNativeEditorValue()&&(this.__startValue=this.snapshot.make())}).on("change.observer",()=>{this.snapshot.isBlocked||e()}))})}redo(){this.stack.redo()&&(this.__startValue=this.snapshot.make(),this.changeStack())}undo(){this.stack.undo()&&(this.__startValue=this.snapshot.make(),this.changeStack())}clear(){this.__startValue=this.snapshot.make(),this.stack.clear(),this.changeStack()}changeStack(){this.jodit&&!this.jodit.isDestructed&&this.jodit.events&&this.jodit.events.fire("changeStack")}destruct(){this.jodit.events&&this.jodit.events.off(".observer"),this.snapshot.destruct(),delete this.snapshot,delete this.stack,super.destruct()}}class Re{constructor(t){this.jodit=t,this.isMarker=t=>xe.isNode(t,this.win)&&t.nodeType===Node.ELEMENT_NODE&&"SPAN"===t.nodeName&&t.hasAttribute("data-"+U),this.focus=()=>{var t,e;if(!this.isFocused()){this.jodit.iframe&&"complete"==this.doc.readyState&&this.jodit.iframe.focus(),this.win.focus(),this.area.focus();const i=this.sel,o=this.createRange();return!i||i.rangeCount&&this.current()||(o.setStart(this.area,0),o.collapse(!0),i.removeAllRanges(),i.addRange(o)),this.jodit.editorIsActive||null===(e=null===(t=this.jodit)||void 0===t?void 0:t.events)||void 0===e||e.fire("focus"),!0}return!1},this.eachSelection=t=>{const e=this.sel;if(e&&e.rangeCount){const i=e.getRangeAt(0),o=[],s=i.startOffset,n=this.area.childNodes.length,r=n>s?s:n-1,a=i.startContainer===this.area?this.area.childNodes[r]:i.startContainer,d=i.endContainer===this.area?this.area.childNodes[i.endOffset-1]:i.endContainer;xe.find(a,t=>(!t||t===this.area||xe.isEmptyTextNode(t)||this.isMarker(t)||o.push(t),t===d||t&&t.contains(d)),this.area,!0,"nextSibling",!1);const c=e=>{if(e.nodeName.match(/^(UL|OL)$/))return Array.from(e.childNodes).forEach(c);if("LI"===e.nodeName)if(e.firstChild)e=e.firstChild;else{const t=this.jodit.create.inside.text(l);e.appendChild(t),e=t}t(e)};0===o.length&&xe.isEmptyTextNode(a)&&o.push(a),o.forEach(c)}}}errorNode(t){if(!xe.isNode(t,this.win))throw Error("Parameter node must be instance of Node")}get area(){return this.jodit.editor}get win(){return this.jodit.editorWindow}get doc(){return this.jodit.editorDocument}get sel(){return this.win.getSelection()}get range(){const t=this.sel;return t&&t.rangeCount?t.getRangeAt(0):this.createRange()}createRange(){return this.doc.createRange()}remove(){const t=this.sel,e=this.current();if(t&&e)for(let e=0;t.rangeCount>e;e+=1)t.getRangeAt(e).deleteContents(),t.getRangeAt(e).collapse(!0)}insertCursorAtPoint(t,e){this.removeMarkers();try{let i=this.createRange();if(this.doc.caretPositionFromPoint){const o=this.doc.caretPositionFromPoint(t,e);i.setStart(o.offsetNode,o.offset)}else if(this.doc.caretRangeFromPoint){const o=this.doc.caretRangeFromPoint(t,e);i.setStart(o.startContainer,o.startOffset)}if(i){i.collapse(!0);const t=this.sel;t&&(t.removeAllRanges(),t.addRange(i))}else if(void 0!==this.doc.body.createTextRange){const i=this.doc.body.createTextRange();i.moveToPoint(t,e);const o=i.duplicate();o.moveToPoint(t,e),i.setEndPoint("EndToEnd",o),i.select()}return!0}catch(t){}return!1}removeMarkers(){Mt("span[data-"+U+"]",this.area).forEach(xe.safeRemove)}marker(t=!1,e){let i=null;e&&(i=e.cloneRange(),i.collapse(t));const o=this.jodit.create.inside.span();return o.id=U+"_"+ +new Date+"_"+(""+Math.random()).slice(2),o.style.lineHeight="0",o.style.display="none",o.setAttribute("data-"+U,t?"start":"end"),o.appendChild(this.jodit.create.inside.text(l)),i&&xe.isOrContains(this.area,t?i.startContainer:i.endContainer)&&i.insertNode(o),o}restore(t=[]){if(Array.isArray(t)){const e=this.sel;e&&e.removeAllRanges(),t.forEach(t=>{const i=this.createRange(),o=this.area.querySelector("#"+t.endId),s=this.area.querySelector("#"+t.startId);if(s){if(t.collapsed||!o){const t=s.previousSibling;t&&t.nodeType===Node.TEXT_NODE?i.setStart(t,t.nodeValue?t.nodeValue.length:0):i.setStartBefore(s),xe.safeRemove(s),i.collapse(!0)}else i.setStartAfter(s),xe.safeRemove(s),i.setEndBefore(o),xe.safeRemove(o);e&&e.addRange(i)}})}}save(){const t=this.sel;if(!t||!t.rangeCount)return[];const e=[],i=t.rangeCount,o=[];let s,n,r;for(s=0;i>s;s+=1)o[s]=t.getRangeAt(s),o[s].collapsed?(n=this.marker(!0,o[s]),e[s]={startId:n.id,collapsed:!0,startMarker:n.outerHTML}):(n=this.marker(!0,o[s]),r=this.marker(!1,o[s]),e[s]={startId:n.id,endId:r.id,collapsed:!1,startMarker:n.outerHTML,endMarker:r.outerHTML});for(t.removeAllRanges(),s=i-1;s>=0;--s){const i=this.doc.getElementById(e[s].startId);if(i)if(e[s].collapsed)o[s].setStartAfter(i),o[s].collapse(!0);else if(o[s].setStartBefore(i),e[s].endId){const t=this.doc.getElementById(e[s].endId);t&&o[s].setEndAfter(t)}try{t.addRange(o[s].cloneRange())}catch(t){}}return e}isCollapsed(){const t=this.sel;for(let e=0;t&&t.rangeCount>e;e+=1)if(!t.getRangeAt(e).collapsed)return!1;return!0}isFocused(){return this.doc.hasFocus&&this.doc.hasFocus()&&this.area===this.doc.activeElement}current(t=!0){if(this.jodit.getRealMode()===P){const e=this.sel;if(e&&e.rangeCount>0){const i=e.getRangeAt(0);let o=i.startContainer,s=!1;const n=t=>s?t.lastChild:t.firstChild;if(o.nodeType!==Node.TEXT_NODE){if(o=i.startContainer.childNodes[i.startOffset],o||(o=i.startContainer.childNodes[i.startOffset-1],s=!0),o&&e.isCollapsed&&o.nodeType!==Node.TEXT_NODE)if(!s&&o.previousSibling&&o.previousSibling.nodeType===Node.TEXT_NODE)o=o.previousSibling;else if(t){let t=n(o);for(;t;){if(t&&t.nodeType===Node.TEXT_NODE){o=t;break}t=n(t)}}if(o&&!e.isCollapsed&&o.nodeType!==Node.TEXT_NODE){let t=o,e=o;do{t=t.firstChild,e=e.lastChild}while(t&&e&&t.nodeType!==Node.TEXT_NODE);t===e&&t&&t.nodeType===Node.TEXT_NODE&&(o=t)}}if(o&&xe.isOrContains(this.area,o))return o}}return!1}insertNode(t,e=!0,i=!0){this.errorNode(t),this.focus();const o=this.sel;if(this.isCollapsed()||this.jodit.execCommand("Delete"),o&&o.rangeCount){const e=o.getRangeAt(0);xe.isOrContains(this.area,e.commonAncestorContainer)?(e.deleteContents(),e.insertNode(t)):this.area.appendChild(t)}else this.area.appendChild(t);e&&this.setCursorAfter(t),i&&this.jodit.events&&this.jodit.events.fire("synchro"),this.jodit.events&&this.jodit.events.fire("afterInsertNode",t)}insertHTML(t){if(""===t)return;const e=this.jodit.create.inside.div(),i=this.jodit.create.inside.fragment();let o,s;if(!this.isFocused()&&this.jodit.isEditorMode()&&this.focus(),xe.isNode(t,this.win)?e.appendChild(t):e.innerHTML=""+t,(this.jodit.isEditorMode()||!1!==this.jodit.events.fire("insertHTML",e.innerHTML))&&(o=e.lastChild,o)){for(;e.firstChild;)o=e.firstChild,i.appendChild(e.firstChild);for(this.insertNode(i,!1),o?this.setCursorAfter(o):this.setCursorIn(i),s=this.area.lastChild;s&&s.nodeType===Node.TEXT_NODE&&s.previousSibling&&s.nodeValue&&/^\s*$/.test(s.nodeValue);)s=s.previousSibling;o&&(s&&o===s&&o.nodeType===Node.ELEMENT_NODE&&this.area.appendChild(this.jodit.create.inside.element("br")),this.setCursorAfter(o))}}insertImage(t,e,i){const o="string"==typeof t?this.jodit.create.inside.element("img"):t;if("string"==typeof t&&o.setAttribute("src",t),null!==i){let t=""+i;t&&"auto"!==t&&0>(t+"").indexOf("px")&&0>(t+"").indexOf("%")&&(t+="px"),fe(o,"width",t)}e&&"object"==typeof e&&fe(o,e);const s=()=>{(o.offsetHeight>o.naturalHeight||o.offsetWidth>o.naturalWidth)&&(o.style.width="",o.style.height=""),o.removeEventListener("load",s)};o.addEventListener("load",s),o.complete&&s();const n=this.insertNode(o);return this.jodit.events.fire("afterInsertImage",o),n}setCursorAfter(t){if(this.errorNode(t),!xe.up(t,t=>t===this.area||t&&t.parentNode===this.area,this.area))throw Error("Node element must be in editor");const e=this.createRange();let i=!1;return t.nodeType!==Node.TEXT_NODE?(i=this.doc.createTextNode(l),e.setStartAfter(t),e.insertNode(i),e.selectNode(i)):e.setEnd(t,null!==t.nodeValue?t.nodeValue.length:0),e.collapse(!1),this.selectRange(e),i}cursorInTheEdge(t,e){const i=this.sel,o=i&&i.rangeCount?i.getRangeAt(0):null;if(!o)return null;const s=t?o.startContainer:o.endContainer,n=i=>t?xe.prev(i,t=>!!t,e):xe.next(i,t=>!!t,e),r=t=>{for(;t;)if((t=n(t))&&!xe.isEmptyTextNode(t)&&"BR"!==t.nodeName)return!1};if(s.nodeType===Node.TEXT_NODE){const e=s.nodeValue||"";if(t&&o.startOffset>e.length-e.replace(h,"").length)return!1;if(!t&&o.startOffsett===this.area||t&&t.parentNode===this.area,this.area))throw Error("Node element must be in editor");const e=this.createRange();let i=!1;return t.nodeType!==Node.TEXT_NODE?(i=this.doc.createTextNode(l),e.setStartBefore(t),e.collapse(!0),e.insertNode(i),e.selectNode(i)):e.setStart(t,null!==t.nodeValue?t.nodeValue.length:0),e.collapse(!0),this.selectRange(e),i}setCursorIn(t,e=!1){if(this.errorNode(t),!xe.up(t,t=>t===this.area||t&&t.parentNode===this.area,this.area))throw Error("Node element must be in editor");const i=this.createRange();let o=t,s=t;do{if(o.nodeType===Node.TEXT_NODE)break;s=o,o=e?o.firstChild:o.lastChild}while(o);if(!o){const t=this.doc.createTextNode(l);/^(img|br|input)$/i.test(s.nodeName)?o=s:(s.appendChild(t),s=t)}return i.selectNodeContents(o||s),i.collapse(e),this.selectRange(i),s}selectRange(t){const e=this.sel;e&&(e.removeAllRanges(),e.addRange(t)),this.jodit.events.fire("changeSelection")}select(t,e=!1){if(this.errorNode(t),!xe.up(t,t=>t===this.area||t&&t.parentNode===this.area,this.area))throw Error("Node element must be in editor");const i=this.createRange();i[e?"selectNodeContents":"selectNode"](t),this.selectRange(i)}getHTML(){const t=this.sel;if(t&&t.rangeCount>0){const e=t.getRangeAt(0).cloneContents(),i=this.jodit.create.inside.div();return i.appendChild(e),i.innerHTML}return""}applyCSS(t,e="span",i){let o;const s=t=>null!==t&&!xe.isEmptyTextNode(t)&&!this.isMarker(t),n=t=>"FONT"!==t.nodeName&&t.nodeType===Node.ELEMENT_NODE&&(mt(i)&&be(i,(e,i)=>{const o=fe(t,e,void 0,!0);return null!==o&&""!==o&&-1!==i.indexOf((""+o).toLowerCase())})||"function"==typeof i&&i(this.jodit,t)),r=t=>!!t&&(RegExp("^"+t.nodeName+"$","i").test(e)||!(!i||!n(t)))&&s(t),a=e=>{r(e)&&("SPAN"===e.nodeName&&t&&Object.keys(t).forEach(i=>{0===o||fe(e,i)===te(i,t[i])?(fe(e,i,""),void 0===o&&(o=0)):(fe(e,i,t[i]),void 0===o&&(o=1))}),xe.isBlock(e,this.win)||e.getAttribute("style")&&"SPAN"===e.nodeName||(xe.unwrap(e),void 0===o&&(o=0)))};if(this.isCollapsed()){let i=!1;if(this.current()&&xe.closest(this.current(),e,this.area)){i=!0;const t=xe.closest(this.current(),e,this.area);t&&this.setCursorAfter(t)}if("SPAN"===e.toUpperCase()||!i){const i=this.jodit.create.inside.element(e);i.appendChild(this.jodit.create.inside.text(l)),this.insertNode(i,!1,!1),"SPAN"===e.toUpperCase()&&t&&fe(i,t),this.setCursorIn(i)}}else{const i=this.save();Yt(this.area.firstChild),Mt("*[style*=font-size]",this.area).forEach(t=>{t.style&&t.style.fontSize&&t.setAttribute("data-font-size",""+t.style.fontSize)}),this.doc.execCommand("fontsize",!1,"7"),Mt("*[data-font-size]",this.area).forEach(t=>{const e=t.getAttribute("data-font-size");t.style&&e&&(t.style.fontSize=e,t.removeAttribute("data-font-size"))}),Mt('font[size="7"]',this.area).forEach(i=>{if(xe.next(i,s,i.parentNode)||xe.prev(i,s,i.parentNode)||!r(i.parentNode)||i.parentNode===this.area||xe.isBlock(i.parentNode,this.win)&&!m.test(e))if(i.firstChild&&!xe.next(i.firstChild,s,i)&&!xe.prev(i.firstChild,s,i)&&r(i.firstChild))a(i.firstChild);else if(xe.closest(i,r,this.area)){const t=this.createRange(),e=xe.closest(i,r,this.area);t.setStartBefore(e),t.setEndBefore(i);const o=t.extractContents();o.textContent&&Bt(o.textContent).length||!o.firstChild||xe.unwrap(o.firstChild),e.parentNode&&e.parentNode.insertBefore(o,e),t.setStartAfter(i),t.setEndAfter(e);const s=t.extractContents();s.textContent&&Bt(s.textContent).length||!s.firstChild||xe.unwrap(s.firstChild),xe.after(e,s),a(e)}else{const s=[];let n;i.firstChild&&xe.find(i.firstChild,t=>(t&&r(t)?(void 0===n&&(n=!0),s.push(t)):void 0===n&&(n=!1),!1),i,!0),s.forEach(xe.unwrap),n||(void 0===o&&(o=1),1===o&&fe(xe.replace(i,e,!1,!1,this.doc),t&&"SPAN"===e.toUpperCase()?t:{}))}else a(i.parentNode);i.parentNode&&xe.unwrap(i)}),this.restore(i)}}}class Be extends Ne{constructor(t,e){super(t),this.target=e,this.container=t.create.div("jodit_statusbar"),e.appendChild(this.container),this.hide()}hide(){this.container&&this.container.classList.add("jodit_hidden")}show(){this.container&&this.container.classList.remove("jodit_hidden")}getHeight(){return this.container.offsetHeight}append(t,e=!1){const i=this.jodit.create.div("jodit_statusbar_item");e&&i.classList.add("jodit_statusbar_item-right"),i.appendChild(t),this.container.appendChild(i),this.show(),this.jodit.events.fire("resize")}destruct(){xe.safeRemove(this.container),delete this.container,super.destruct()}}const Pe=(()=>{let t;return()=>(void 0===t&&(t=(()=>{const t="___Jodit___"+Math.random();try{localStorage.setItem(t,"1");const e="1"===localStorage.getItem(t);return localStorage.removeItem(t),e}catch(t){}return!1})()),t)})();class He{constructor(t){this.rootKey=t}set(t,e){try{const i=localStorage.getItem(this.rootKey),o=i?JSON.parse(i):{};o[t]=e,localStorage.setItem(this.rootKey,JSON.stringify(o))}catch(t){}}get(t){try{const e=localStorage.getItem(this.rootKey),i=e?JSON.parse(e):{};return void 0!==i[t]?i[t]:null}catch(t){}}exists(t){return null!==this.get(t)}clear(){try{localStorage.removeItem(this.rootKey)}catch(t){}}}class Oe{constructor(){this.data=new Map}set(t,e){this.data.set(t,e)}get(t){return this.data.get(t)}exists(t){return this.data.has(t)}clear(){this.data.clear()}}const We="Jodit_";class Fe{constructor(t,e){this.provider=t,this.prefix=We,e&&(this.prefix+=e)}set(t,e){this.provider.set(Dt(this.prefix+t),e)}get(t){return this.provider.get(Dt(this.prefix+t))}exists(t){return this.provider.exists(Dt(this.prefix+t))}clear(){return this.provider.clear()}static makeStorage(t=!1,e){let i;return t&&Pe()&&(i=new He(We+e)),i||(i=new Oe),new Fe(i,e)}}const Ve="JoditEventDefaultNamespace";class $e{constructor(){this.__store={}}get(t,e){if(void 0!==this.__store[e])return this.__store[e][t]}indexOf(t,e,i){const o=this.get(t,e);if(o)for(let t=0;o.length>t;t+=1)if(o[t].originalCallback===i)return t;return!1}namespaces(t=!1){const e=Object.keys(this.__store);return t?e.filter(t=>t!==Ve):e}events(t){return this.__store[t]?Object.keys(this.__store[t]):[]}set(t,e,i,o=!1){void 0===this.__store[e]&&(this.__store[e]={}),void 0===this.__store[e][t]&&(this.__store[e][t]=[]),o?this.__store[e][t].unshift(i):this.__store[e][t].push(i)}clear(){delete this.__store,this.__store={}}}class Ue{constructor(t){this.__key="__JoditEventsNativeNamespaces",this.doc=document,this.__stopped=[],this.prepareEvent=t=>{t.cancelBubble||(t.type.match(/^touch/)&&t.changedTouches&&t.changedTouches.length&&["clientX","clientY","pageX","pageY"].forEach(e=>{Object.defineProperty(t,e,{value:t.changedTouches[0][e],configurable:!0,enumerable:!0})}),t.originalEvent||(t.originalEvent=t),"paste"===t.type&&void 0===t.clipboardData&&this.doc.defaultView.clipboardData&&Object.defineProperty(t,"clipboardData",{get:()=>this.doc.defaultView.clipboardData,configurable:!0,enumerable:!0}))},this.current=[],this.isDestructed=!1,t&&(this.doc=t),this.__key+=(new Date).getTime()}eachEvent(t,e){t.split(/[\s,]+/).forEach(t=>{const i=t.split(".");e.call(this,i[0],i[1]||Ve)})}getStore(t){if(void 0===t[this.__key]){const e=new $e;Object.defineProperty(t,this.__key,{enumerable:!1,configurable:!0,value:e})}return t[this.__key]}clearStore(t){void 0!==t[this.__key]&&delete t[this.__key]}triggerNativeEvent(t,e){const i=this.doc.createEvent("HTMLEvents");"string"==typeof e?i.initEvent(e,!0,!0):(i.initEvent(e.type,e.bubbles,e.cancelable),["screenX","screenY","clientX","clientY","target","srcElement","currentTarget","timeStamp","which","keyCode"].forEach(t=>{Object.defineProperty(i,t,{value:e[t],enumerable:!0})}),Object.defineProperty(i,"originalEvent",{value:e,enumerable:!0})),t.dispatchEvent(i)}removeStop(t){if(t){const e=this.__stopped.indexOf(t);-1!==e&&this.__stopped.splice(e,1)}}isStopped(t){return void 0!==t&&-1!==this.__stopped.indexOf(t)}on(t,e,i,o,s=!1){const n="string"==typeof t?this:t,r="string"==typeof e?e:t;let a=i;void 0===a&&"function"==typeof e&&(a=e);const l=this.getStore(n);if("string"!=typeof r||""===r)throw Error("Need events names");if("function"!=typeof a)throw Error("Need event handler");if(Array.isArray(n))return n.forEach(t=>{this.on(t,r,a,o)}),this;const d="function"==typeof n.addEventListener,c=this;let h=function(t){return a&&a.apply(this,arguments)};return d&&(h=function(t){if(c.prepareEvent(t),a&&!1===a.call(this,t))return t.preventDefault(),t.stopImmediatePropagation(),!1},o&&(h=function(t){c.prepareEvent(t);let e=t.target;for(;e&&e!==this;){if(e.matches(o))return Object.defineProperty(t,"target",{value:e,configurable:!0,enumerable:!0}),a&&!1===a.call(e,t)?(t.preventDefault(),!1):void 0;e=e.parentNode}})),this.eachEvent(r,(t,e)=>{if(""===t)throw Error("Need event name");!1===l.indexOf(t,e,a)&&(l.set(t,e,{event:t,originalCallback:a,syntheticCallback:h},s),d&&n.addEventListener(t,h,!1))}),this}off(t,e,i){const o="string"==typeof t?this:t,s="string"==typeof e?e:t,n=this.getStore(o);let r=i;if("string"!=typeof s||!s)return n.namespaces().forEach(t=>{this.off(o,"."+t)}),this.clearStore(o),this;void 0===r&&"function"==typeof e&&(r=e);const a="function"==typeof o.removeEventListener,l=t=>{a&&o.removeEventListener(t.event,t.syntheticCallback,!1)},d=(t,e)=>{if(""!==t){const i=n.get(t,e);if(i&&i.length)if("function"!=typeof r)i.forEach(l),i.length=0;else{const o=n.indexOf(t,e,r);!1!==o&&(l(i[o]),i.splice(o,1))}}else n.events(e).forEach(t=>{""!==t&&d(t,e)})};return this.eachEvent(s,(t,e)=>{e===Ve?n.namespaces().forEach(e=>{d(t,e)}):d(t,e)}),this}stopPropagation(t,e){const i="string"==typeof t?this:t,o="string"==typeof t?t:e;if("string"!=typeof o)throw Error("Need event names");const s=this.getStore(i);this.eachEvent(o,(t,e)=>{const o=s.get(t,e);o&&this.__stopped.push(o),e===Ve&&s.namespaces(!0).forEach(e=>this.stopPropagation(i,t+"."+e))})}fire(t,e,...i){let o,s=void 0;const n="string"==typeof t?this:t,r="string"==typeof t?t:e,a="string"==typeof t?[e,...i]:i,l="function"==typeof n.dispatchEvent;if(!l&&"string"!=typeof r)throw Error("Need events names");const d=this.getStore(n);return"string"!=typeof r&&l?this.triggerNativeEvent(n,e):this.eachEvent(r,(t,e)=>{if(l)this.triggerNativeEvent(n,t);else{const i=d.get(t,e);if(i)try{i.every(e=>!this.isStopped(i)&&(this.current.push(t),o=e.syntheticCallback.apply(n,a),this.current.pop(),void 0!==o&&(s=o),!0))}finally{this.removeStop(i)}e!==Ve||l||d.namespaces().filter(t=>t!==e).forEach(e=>{const i=this.fire.call(this,n,t+"."+e,...a);void 0!==i&&(s=i)})}}),s}destruct(){this.isDestructed&&(this.isDestructed=!0,this.off(this),this.getStore(this).clear(),delete this[this.__key])}}class Ke{constructor(t,e){this.doc=t,null!==e&&(this.inside=e?new Ke(e):new Ke(t,null))}setDocument(t){this.doc=t}element(t,e,i){const o=this.doc.createElement(t.toLowerCase());return e&&(mt(e)?be(e,(t,e)=>{mt(e)&&"style"===t?fe(o,e):o.setAttribute(t,""+e)}):i=e),i&&it(i).forEach(t=>o.appendChild("string"==typeof t?this.fromHTML(t):t)),o}div(t,e,i){const o=this.element("div",e,i);return t&&(o.className=t),o}span(t,e,i){const o=this.element("span",e,i);return t&&(o.className=t),o}a(t,e,i){const o=this.element("a",e,i);return t&&(o.className=t),o}text(t){return this.doc.createTextNode(t)}fragment(){return this.doc.createDocumentFragment()}fromHTML(t){const e=this.div();e.innerHTML=""+t;const i=e.firstChild===e.lastChild&&e.firstChild?e.firstChild:e;return xe.safeRemove(i),i}}class Xe extends Ne{constructor(t){super(t),this.__whoLocked="",this.__isFullSize=!1,this.ownerDocument=document,this.ownerWindow=window,this.isLocked=()=>""!==this.__whoLocked,this.isLockedNotBy=t=>this.isLocked()&&this.__whoLocked!==t,this.isFullSize=()=>this.__isFullSize,t&&t.ownerDocument&&(this.ownerDocument=t.ownerDocument,this.ownerWindow=t.ownerWindow),this.create=new Ke(this.ownerDocument,Ct(t)?t.editorDocument:void 0),this.container=this.create.div()}destruct(){this.isDestructed&&(xe.safeRemove(this.container),delete this.container,super.destruct())}lock(t="any"){return!this.isLocked()&&(this.__whoLocked=t,!0)}unlock(){return!!this.isLocked()&&(this.__whoLocked="",!0)}toggleFullSize(t){void 0===t&&(t=!this.__isFullSize),t!==this.__isFullSize&&(this.__isFullSize=t)}}class Ye extends Xe{constructor(t,e){super(t),this.version="3.3.8",this.__modulesInstances={},this.buffer=Fe.makeStorage(),this.progress_bar=this.create.div("jodit_progress_bar",this.create.div()),this.options={removeButtons:[],zIndex:100002,fullsize:!1,showTooltip:!0,useNativeTooltip:!1,buttons:[],globalFullsize:!0},this.components=[],this.getVersion=()=>this.version,this.id=t&&t.id?t.id:""+(new Date).getTime(),this.jodit=t||this,this.events=t&&t.events?t.events:new Ue(this.ownerDocument),this.buffer=t&&t.buffer?t.buffer:Fe.makeStorage(),this.options={...this.options,...e}}get basePath(){return this.options.basePath?this.options.basePath:et}get defaultTimeout(){return 100}i18n(t,...e){var i;return Wt(t,e,(null===(i=null==this?void 0:this.jodit)||void 0===i?void 0:i.options)||(null==this?void 0:this.options))}toggleFullSize(t){super.toggleFullSize(t),this.events&&this.events.fire("toggleFullSize",t)}getInstance(t,e){if("function"!=typeof li.modules[t])throw Error("Need real module name");return void 0===this.__modulesInstances[t]&&(this.__modulesInstances[t]=new li.modules[t](this.jodit||this,e)),this.__modulesInstances[t]}destruct(){this.isDestructed||(this.events&&(this.events.destruct(),delete this.events),delete this.options,super.destruct())}}class Ge extends Ne{constructor(t,e="li",i="jodit_toolbar_btn"){t instanceof oi?(super(t.jodit),this.parentToolbar=t):super(t),this.container=this.jodit.create.element(e),this.container.classList.add(i)}focus(){this.container.focus()}destruct(){this.isDestructed||(xe.safeRemove(this.container),this.parentToolbar=void 0,super.destruct())}createIcon(t,e){const i=e?e.icon||e.name:t;if(!this.jodit.options.textIcons){let o,s=this.jodit.events.fire("getIcon",i,e,t);return e&&e.iconURL&&void 0===s?(o=this.jodit.create.element("i"),o.style.backgroundImage="url("+e.iconURL.replace("{basePath}",this.jodit.basePath)+")"):(void 0===s&&(s=Ce.exists(i)?Ce.getIcon(i):Ce.getIcon("empty")),o="string"==typeof s?this.jodit.create.fromHTML(Bt(s)):s),o.classList.add("jodit_icon","jodit_icon_"+t),o}return this.jodit.create.fromHTML(`${this.jodit.i18n(e?e.name:t)}`)}}class Je extends Ge{constructor(t){super(t),this.container.classList.add("jodit_toolbar_btn-break")}}class Ze extends Ne{constructor(t,e,i,o="jodit_toolbar_popup"){super(t),this.target=e,this.current=i,this.className=o,this.throttleCalcPosition=at(this.calcPosition,this.jodit.defaultTimeout),this.isOpened=!1,this.close=t=>{(this.isOpened||this.isDestructed)&&(t&&xe.isOrContains(this.container,t instanceof Ze?t.target:t)||(this.isOpened=!1,this.jodit.events.off("closeAllPopups",this.close),this.doClose(),xe.safeRemove(this.container),this.jodit.events.fire("removeMarkers"),this.jodit.events.fire(this,"afterClose")))},this.container=this.jodit.create.div(o,{"data-editor_id":t.id}),this.jodit.events.on(this.container,"mousedown touchstart touchend",t=>{t.stopPropagation()}).on([this.jodit.ownerWindow,this.jodit.events],"resize",this.throttleCalcPosition).on("afterInsertNode, afterInsertImage",this.close)}calcPosition(){if(!this.isOpened||this.isDestructed)return;const t=this.container,e=se(this.jodit.container,this.jodit,this.jodit.ownerDocument,!0),i=se(t,this.jodit,this.jodit.ownerDocument,!0),o=fe(t,"marginLeft")||0;i.left-=o;let s=o,n="auto";if(s=e.left>i.left?e.left-i.left:e.left+e.width>i.left+i.width?0:-(i.left+i.width-(e.left+e.width)),e.width>i.width||(s=e.left-i.left,n=e.width),s!==o)try{t.style.setProperty("margin-left",s+"px","important")}catch(e){t.style.marginLeft=s+"px"}const r=t.querySelector(".jodit_popup_triangle");r&&(r.style.marginLeft=-s+"px"),fe(t,"width",n)}doOpen(t){t&&(xe.detach(this.container),this.container.innerHTML='',this.container.appendChild(xe.isNode(t,this.jodit.ownerWindow)?t:this.jodit.create.fromHTML(""+t)),this.container.style.display="block",this.container.style.removeProperty("marginLeft"))}doClose(){}open(t,e,i=!1){li.fireEach("beforeOpenPopup closeAllPopups",this,t),i||this.jodit.events.on("closeAllPopups",this.close),this.container.classList.add(this.className+"-open"),this.doOpen(t),this.target.appendChild(this.container),this.jodit.options.textIcons&&this.firstInFocus(),void 0!==e&&this.container.classList.toggle("jodit_right",e),!i&&this.container.parentNode&&this.jodit.events.fire(this.container.parentNode,"afterOpenPopup",this.container),this.isOpened=!0,!i&&this.calcPosition()}firstInFocus(){}destruct(){this.isDestructed||(this.jodit.events.off([this.jodit.ownerWindow,this.jodit.events],"resize",this.throttleCalcPosition),xe.safeRemove(this.container),delete this.container,super.destruct())}}class Qe extends Ze{constructor(t,e,i,o="jodit_toolbar_list"){super(t,e,i,o),this.target=e,this.current=i,this.className=o,this.defaultControl={template:(t,e,i)=>this.jodit.i18n(i)}}doClose(){this.toolbar&&(this.toolbar.destruct(),delete this.toolbar)}doOpen(t){this.toolbar=si.makeCollection(this.jodit),be("string"==typeof t.list?t.list.split(/[\s,]+/):t.list,(e,i)=>{let o,s=this.jodit.options.controls,n=t=>s&&s[t];"string"==typeof i&&n(i)?o=new ei(this.toolbar,{name:""+i,...n(i)},this.current):"string"==typeof e&&n(e)&&"object"==typeof i?o=new ei(this.toolbar,{name:""+e,...n(e),...i},this.current):(o=new ei(this.toolbar,{name:""+e,exec:t.exec,command:t.command,isActive:t.isActiveChild,isDisable:t.isDisableChild,mode:t.mode,args:[t.args&&t.args[0]||e,t.args&&t.args[1]||i]},this.current),o.textBox.innerHTML=(t.template||this.defaultControl.template)(this.jodit,""+e,""+i)),this.toolbar.appendChild(o)}),this.container.appendChild(this.toolbar.container),this.container.style.removeProperty("marginLeft"),this.toolbar.checkActiveButtons()}firstInFocus(){this.toolbar.firstButton.focus()}destruct(){this.isDestructed||(this.doClose(),super.destruct())}}class ti extends Ge{constructor(t){super(t.parentToolbar||t.jodit,"div","jodit_tooltip"),this.button=t,this.timeout=0,this.show=()=>{const t=this.button.jodit.options.showTooltipDelay||10*this.button.jodit.defaultTimeout;this.button.jodit.events.fire("hideTooltip"),this.timeout=nt(()=>{this.button.container.appendChild(this.container),this.container.style.marginLeft=-(this.container.offsetWidth-this.button.container.offsetWidth)/2+"px"},t)},this.hide=()=>{window.clearTimeout(this.timeout),xe.safeRemove(this.container)},t.control.tooltip&&(this.container.innerHTML=t.tooltipText,t.jodit.events.on(t.anchor,"mouseenter",this.show).on(t.anchor,"mouseleave",this.hide).on("change updateToolbar scroll hidePopup closeAllPopups hideTooltip",this.hide))}destruct(){return this.hide(),this.jodit&&this.jodit.events&&this.jodit.events.off("change updateToolbar scroll hidePopup closeAllPopups hideTooltip",this.hide),super.destruct()}}class ei extends Ge{constructor(t,e,i){super(t),this.__disabled=!1,this.__actived=!1,this.onMouseDown=t=>{if("keydown"===t.type&&t.which!==w)return;if(t.stopImmediatePropagation(),t.preventDefault(),this.disable)return!1;const e=this.control,i=()=>this.parentToolbar&&this.parentToolbar.getTarget(this)||this.target||!1;if(e.list){const t=new Qe(this.jodit,this.container,this.target);t.open(e),this.jodit.events.fire("closeAllPopups",t.container),this.anchor.setAttribute("aria-expanded","true"),this.jodit.events.on(t,"afterClose",()=>{this.anchor.setAttribute("aria-expanded","false")})}else if(void 0!==e.exec&&"function"==typeof e.exec)e.exec(this.jodit,i(),e,t,this.container),this.jodit.events.fire("synchro"),this.parentToolbar&&this.parentToolbar.immediateCheckActiveButtons(),this.jodit.events.fire("closeAllPopups afterExec");else if(void 0!==e.popup&&"function"==typeof e.popup){const t=new Ze(this.jodit,this.container,this.target);if(!1!==this.jodit.events.fire(Dt(`before-${e.name}-OpenPopup`),i(),e,t)){const o=e.popup(this.jodit,i(),e,t.close,this);o&&t.open(o)}this.jodit.events.fire(Dt(`after-${e.name}-OpenPopup`)+" closeAllPopups",t.container)}else(e.command||e.name)&&(Ct(this.jodit)?this.jodit.execCommand(e.command||e.name,e.args&&e.args[0]||!1,e.args&&e.args[1]||null):this.jodit.ownerDocument.execCommand(e.command||e.name,e.args&&e.args[0]||!1,e.args&&e.args[1]||null),this.jodit.events.fire("closeAllPopups"))},this.control=e,this.target=i,this.anchor=this.jodit.create.element("a",{role:"button",href:"javascript:void(0)"});let o="-1";this.jodit.options.allowTabNavigation&&(o="0"),this.anchor.setAttribute("tabindex",o),this.container.appendChild(this.anchor),this.jodit.options.showTooltip&&e.tooltip&&(this.jodit.options.useNativeTooltip?this.anchor.setAttribute("title",this.tooltipText):this.tooltip=new ti(this),this.anchor.setAttribute("aria-label",this.tooltipText)),this.textBox=this.jodit.create.span(),this.anchor.appendChild(this.textBox);const s=e.name.replace(/[^a-zA-Z0-9]/g,"_");if(e.getContent&&"function"==typeof e.getContent){xe.detach(this.container);const t=e.getContent(this.jodit,e,this);this.container.appendChild("string"==typeof t?this.jodit.create.fromHTML(t):t)}else{if(e.list&&this.anchor){const t=this.jodit.create.fromHTML(Ce.getIcon("dropdown-arrow"));t.classList.add("jodit_with_dropdownlist-trigger"),this.container.classList.add("jodit_with_dropdownlist"),this.anchor.appendChild(t)}this.textBox.appendChild(this.createIcon(s,e))}if(this.container.classList.add("jodit_toolbar_btn-"+s),this.jodit.options.direction){const t=this.jodit.options.direction.toLowerCase();this.container.style.direction="rtl"===t?"rtl":"ltr"}e.isInput?this.container.classList.add("jodit_toolbar-input"):this.jodit.events.on(this.container,"mousedown touchend keydown",this.onMouseDown).on(`click-${s}-btn`,this.onMouseDown)}set disable(t){this.__disabled=t,this.container.classList.toggle("jodit_disabled",t),t?this.container.hasAttribute("disabled")||this.container.setAttribute("disabled","disabled"):this.container.hasAttribute("disabled")&&this.container.removeAttribute("disabled")}get disable(){return this.__disabled}set active(t){this.__actived=t,this.container.classList.toggle("jodit_active",t)}get active(){return this.__actived}isDisable(){return!(!this.parentToolbar||!this.parentToolbar.buttonIsDisabled(this))}isActive(){return!(!this.parentToolbar||!this.parentToolbar.buttonIsActive(this))}get tooltipText(){return this.control.tooltip?this.jodit.i18n(this.control.tooltip)+(this.control.hotkeys?"
"+it(this.control.hotkeys).join(" "):""):""}focus(){this.anchor.focus()}destruct(){this.isDestructed||(this.jodit&&this.jodit.events&&this.jodit.events.off(this.container),super.destruct(),this.tooltip&&(this.tooltip.destruct(),delete this.tooltip))}}class ii extends Ge{constructor(t){super(t),this.container.classList.add("jodit_toolbar_btn-separator")}}class oi extends Ne{constructor(t){super(t),this.__buttons=[],this.__getControlType=t=>{let e;const i=this.jodit.options.controls||qe.defaultOptions.controls;if("string"!=typeof t)e={name:"empty",...t},void 0!==i[e.name]&&(e={...i[e.name],...e});else{const o=t.split(/\./);let s=i;o.length>1&&void 0!==i[o[0]]&&(s=i[o[0]],t=o[1]),e=void 0!==s[t]?{name:t,...s[t]}:{name:t,command:t,tooltip:t}}return e},this.closeAll=()=>{this.jodit&&this.jodit.events&&this.jodit.events.fire("closeAllPopups")},this.initEvents=()=>{this.jodit.events.on(this.jodit.ownerWindow,"mousedown touchend",this.closeAll).on(this.listenEvents,this.checkActiveButtons).on("afterSetMode focus",this.immediateCheckActiveButtons)},this.listenEvents="changeStack mousedown mouseup keydown change afterInit readonly afterResize selectionchange changeSelection focus afterSetMode touchstart focus blur",this.immediateCheckActiveButtons=()=>{this.isDestructed||this.jodit.isLocked()||(this.__buttons.filter(t=>t instanceof ei).forEach(t=>{t.disable=t.isDisable(),t.disable||(t.active=t.isActive()),"function"==typeof t.control.getLabel&&t.control.getLabel(this.jodit,t.control,t)}),this.jodit.events&&this.jodit.events.fire("updateToolbar"))},this.checkActiveButtons=rt(this.immediateCheckActiveButtons,this.jodit.defaultTimeout),this.container=this.jodit.create.element("ul"),this.container.classList.add("jodit_toolbar"),this.initEvents()}getButtonsList(){return this.__buttons.map(t=>t instanceof ei?t.control.name:"").filter(t=>""!==t)}getParentContainer(){return this.__parentContainer}appendChild(t){this.__buttons.push(t),this.container.appendChild(t.container)}get firstButton(){return this.__buttons[0]}removeChild(t){const e=this.__buttons.indexOf(t);-1!==e&&(this.__buttons.splice(e,1),t.container.parentNode===this.container&&xe.safeRemove(t.container))}build(t,e,i){this.jodit.events.off("rebuildToolbar"),this.jodit.events.on("afterInit rebuildToolbar",()=>this.build(t,e,i)),this.__parentContainer=e;let o=!1;this.clear(),("string"==typeof t?t.split(/[,\s]+/):t).map(this.__getControlType).forEach(t=>{let e=null;if(-1===this.jodit.options.removeButtons.indexOf(t.name)){switch(t.name){case"\n":e=new Je(this);break;case"|":o||(o=!0,e=new ii(this));break;default:o=!1,e=new ei(this,t,i)}e&&this.appendChild(e)}}),this.container.parentNode!==e&&e.appendChild(this.container),this.immediateCheckActiveButtons()}clear(){[...this.__buttons].forEach(t=>{this.removeChild(t),t.destruct()}),this.__buttons.length=0}buttonIsActive(t){return!(Ct(this.jodit)&&!this.jodit.editorIsActive)&&("function"==typeof t.control.isActive?t.control.isActive(this.jodit,t.control,t):void 0)}buttonIsDisabled(t){if(this.jodit.options.disabled)return!0;if(this.jodit.options.readonly&&(!this.jodit.options.activeButtonsInReadOnly||-1===this.jodit.options.activeButtonsInReadOnly.indexOf(t.control.name)))return!0;let e;return"function"==typeof t.control.isDisable&&(e=t.control.isDisable(this.jodit,t.control,t)),e}getTarget(t){return t.target}setDirection(t){this.container.style.direction=t,this.container.setAttribute("dir",t)}destruct(){this.isDestructed||(this.jodit.events.off(this.jodit.ownerWindow,"mousedown touchstart",this.closeAll).off(this.listenEvents,this.checkActiveButtons).off("afterSetMode focus",this.immediateCheckActiveButtons),this.clear(),xe.safeRemove(this.container),delete this.container,super.destruct())}}class si extends oi{constructor(){super(...arguments),this.checkActiveStatus=(t,e)=>{let i=0,o=0;return Object.keys(t).forEach(s=>{const n=t[s];"function"==typeof n?n(this.jodit,""+fe(e,s))&&(i+=1):-1!==n.indexOf(""+fe(e,s))&&(i+=1),o+=1}),o===i}}buttonIsActive(t){const e=super.buttonIsActive(t);if(void 0!==e)return e;const i=!!this.jodit.selection&&this.jodit.selection.current();if(!i)return!1;let o,s,n;return!(!(t.control.tags||t.control.options&&t.control.options.tags)||(o=t.control.tags||t.control.options&&t.control.options.tags,s=i,!xe.up(s,t=>{if(t&&-1!==o.indexOf(t.nodeName.toLowerCase()))return!0},this.jodit.editor)))||!(!(t.control.css||t.control.options&&t.control.options.css)||(n=t.control.css||t.control.options&&t.control.options.css,s=i,!xe.up(s,t=>{if(t&&t.nodeType!==Node.TEXT_NODE)return this.checkActiveStatus(n,t)},this.jodit.editor)))}buttonIsDisabled(t){const e=super.buttonIsDisabled(t);if(void 0!==e)return e;const i=void 0===t.control||void 0===t.control.mode?P:t.control.mode;return!(i===O||i===this.jodit.getRealMode())}getTarget(t){return t.target||this.jodit.selection.current()||void 0}static makeCollection(t){const e=Ct(t)?new si(t):new oi(t);return t.options.textIcons&&e.container.classList.add("jodit_text_icons"),e}}class ni extends Ye{constructor(){super(...arguments),this.toolbar=si.makeCollection(this)}destruct(){this.toolbar.destruct(),delete this.toolbar,super.destruct()}}class ri{constructor(){this.items=new Map}add(t,e){this.items.set(t.toLowerCase(),e)}get(t){return this.items.get(t.toLowerCase())}remove(t){this.items.delete(t.toLowerCase())}async init(t){const e=t.options.extraPlugins.map(t=>Et(t)?{name:t.toLowerCase()}:t),i=st(t.options.disablePlugins).map(t=>t.toLowerCase()),o=[],s={},n=[],r={};if(e&&e.length)try{const i=e.filter(t=>!this.items.has(t.name));i.length&&await this.load(t,i)}catch(t){}this.items.forEach((e,a)=>{if(i.includes(a)||o.includes(a)||s[a])return;const l=ri.makePluginInstance(t,e);this.initOrWait(t,a,l,o,s),n.push(l),r[a]=l}),this.addListenerOnBeforeDestruct(t,n),t.__plugins=r}static makePluginInstance(t,e){return bt(e)?new e(t):e}initOrWait(t,e,i,o,s){const n=(e,i)=>{if(i.hasStyle&&ri.loadStyle(t,e),_t(i)){if(i.requires&&i.requires.length&&!i.requires.every(t=>o.includes(t)))return s[e]=i,!1;i.init(t),o.push(e)}else o.push(e);return!0};n(e,i),Object.keys(s).forEach(t=>{s[t]&&n(t,i)&&(s[t]=void 0,delete s[t])})}addListenerOnBeforeDestruct(t,e){t.events.on("beforeDestruct",()=>{e.forEach(e=>{kt(e)&&e.destruct(t)}),e.length=0,delete t.__plugins})}load(t,e){return Promise.all(e.map(e=>{const i=e.url||ri.getFullUrl(t,name,!0);return(t=>t.then(t=>({v:t,status:"fulfilled"}),t=>({e:t,status:"rejected"})))(de(i,t.ownerDocument))}))}static loadStyle(t,e){ce(ri.getFullUrl(t,e,!1),t.ownerDocument)}static getFullUrl(t,e,i){return t.basePath+"plugins/"+e+"/"+e+"."+(i?"js":"css")}}const ai=10;class li extends ni{constructor(t,e){super(),this.__defaultStyleDisplayKey="data-jodit-default-style-display",this.__defaultClassesKey="data-jodit-default-classes",this.commands={},this.__selectionLocked=null,this.__wasReadOnly=!1,this.storage=Fe.makeStorage(!0,this.id),this.editorIsActive=!1,this.iframe=null,this.mode=P,this.__callChangeCount=0,this.isInited=!1,this.options=new Le(e),this.editorDocument=this.options.ownerDocument,this.editorWindow=this.options.ownerWindow,this.ownerDocument=this.options.ownerDocument,this.ownerWindow=this.options.ownerWindow,this.element=this.resolveElement(t),this.element.attributes&&Array.from(this.element.attributes).forEach(t=>{const i=t.name;let o=t.value;void 0===li.defaultOptions[i]||e&&void 0!==e[i]||(-1!==["readonly","disabled"].indexOf(i)&&(o=""===o||"true"===o),/^[0-9]+(\.)?([0-9]+)?$/.test(""+o)&&(o=Number(o)),this.options[i]=o)}),this.options.events&&Object.keys(this.options.events).forEach(t=>{this.events.on(t,this.options.events[t])}),this.container.classList.add("jodit_container"),this.container.setAttribute("contenteditable","false"),this.selection=new Re(this),this.events.on("removeMarkers",()=>{this.selection&&this.selection.removeMarkers()}),this.observer=new De(this);let i=null;this.options.inline&&(-1===["TEXTAREA","INPUT"].indexOf(this.element.nodeName)&&(this.container=this.element,this.element.setAttribute(this.__defaultClassesKey,""+this.element.className),i=this.container.innerHTML,this.container.innerHTML=""),this.container.classList.add("jodit_inline"),this.container.classList.add("jodit_container")),this.element!==this.container&&(this.element.style.display&&this.element.setAttribute(this.__defaultStyleDisplayKey,this.element.style.display),this.element.style.display="none"),this.applyOptionsToToolbarContainer(this.container),this.workplace=this.create.div("jodit_workplace",{contenteditable:!1}),this.makeToolbar(),this.options.textIcons&&this.container.classList.add("jodit_text_icons"),this.events.on(this.ownerWindow,"resize",()=>{this.events&&this.events.fire("resize")}),this.container.appendChild(this.workplace),this.statusbar=new Be(this,this.container),this.workplace.appendChild(this.progress_bar),this.element.parentNode&&this.element!==this.container&&this.element.parentNode.insertBefore(this.container,this.element),this.id=this.element.getAttribute("id")||""+(new Date).getTime(),this.editor=this.create.div("jodit_wysiwyg",{contenteditable:!0,"aria-disabled":!1,tabindex:this.options.tabIndex}),this.workplace.appendChild(this.editor),this.setNativeEditorValue(this.getElementValue()),(async()=>{await this.beforeInitHook(),await this.events.fire("beforeInit",this);try{await li.plugins.init(this)}catch(t){}if(await this.__initEditor(i),this.isDestructed)return;const t=this.options;t.enableDragAndDropFileToEditor&&t.uploader&&(t.uploader.url||t.uploader.insertImageAsBase64URI)&&this.uploader.bind(this.editor),this.isInited=!0,this.events&&(await this.events.fire("afterInit",this),this.events.fire("afterConstructor",this)),await this.afterInitHook()})()}get isJodit(){return!0}get value(){return this.getEditorValue()}set value(t){this.setEditorValue(t)}get defaultTimeout(){return this.options&&this.options.observer?this.options.observer.timeout:li.defaultOptions.observer.timeout}static Array(t){return new dt(t)}static Object(t){return new lt(t)}static fireEach(t,...e){Object.keys(li.instances).forEach(i=>{const o=li.instances[i];!o.isDestructed&&o.events&&o.events.fire(t,...e)})}static make(t,e){return new li(t,e)}get uploader(){return this.getInstance("Uploader")}get filebrowser(){return this.getInstance("FileBrowser")}getElementValue(){return void 0!==this.element.value?this.element.value:this.element.innerHTML}getNativeEditorValue(){return this.editor?this.editor.innerHTML:this.getElementValue()}setNativeEditorValue(t){this.editor&&(this.editor.innerHTML=t)}getEditorValue(t=!0){let e;if(e=this.events.fire("beforeGetValueFromEditor"),void 0!==e)return e;e=this.getNativeEditorValue().replace(d,""),t&&(e=e.replace(/]+id="jodit_selection_marker_[^>]+><\/span>/g,"")),"
"===e&&(e="");const i={value:e};return this.events.fire("afterGetValueFromEditor",i),i.value}getEditorText(){if(this.editor)return this.editor.textContent||"";const t=this.create.inside.div();return t.innerHTML=this.getElementValue(),t.textContent||""}setElementValue(t){if("string"!=typeof t&&void 0!==t)throw Error("value must be string");void 0!==t?this.element!==this.container&&(void 0!==this.element.value?this.element.value=t:this.element.innerHTML=t):t=this.getElementValue(),t!==this.getEditorValue()&&this.setEditorValue(t)}setEditorValue(t){const e=this.events.fire("beforeSetValueToEditor",t);if(!1===e)return;if("string"==typeof e&&(t=e),!this.editor)return void(void 0!==t&&this.setElementValue(t));if("string"!=typeof t&&void 0!==t)throw Error("value must be string");void 0!==t&&this.editor.innerHTML!==t&&this.setNativeEditorValue(t);const i=this.getElementValue(),o=this.getEditorValue();if(i!==o&&ai>this.__callChangeCount){this.setElementValue(o),this.__callChangeCount+=1;try{this.events.fire("change",o,i)}finally{this.__callChangeCount=0}}}registerCommand(t,e){const i=t.toLowerCase();if(void 0===this.commands[i]&&(this.commands[i]=[]),this.commands[i].push(e),"function"!=typeof e){const o=this.options.commandToHotkeys[i]||this.options.commandToHotkeys[t]||e.hotkeys;o&&this.registerHotkeyToCommand(o,i)}return this}registerHotkeyToCommand(t,e){const i=it(t).map(Kt).map(t=>t+".hotkey").join(" ");this.events.off(i).on(i,()=>this.execCommand(e))}execCommand(t,e=!1,i=null){if(this.options.readonly&&"selectall"!==t)return;let o;if(t=t.toLowerCase(),o=this.events.fire("beforeCommand",t,e,i),!1!==o&&(o=this.execCustomCommands(t,e,i)),!1!==o)if(this.selection.focus(),"selectall"===t)this.selection.select(this.editor,!0);else try{o=this.editorDocument.execCommand(t,e,i)}catch(t){}return this.events.fire("afterCommand",t,e,i),this.setEditorValue(),o}execCustomCommands(t,e=!1,i=null){if(t=t.toLowerCase(),void 0!==this.commands[t]){let o;const s=s=>{let n;n="function"==typeof s?s:s.exec;const r=n.call(this,t,e,i);void 0!==r&&(o=r)};for(let e=0;this.commands[t].length>e;e+=1)s(this.commands[t][e]);return o}}lock(t="any"){return!!super.lock(t)&&(this.__selectionLocked=this.selection.save(),this.editor.classList.add("jodit_disabled"),!0)}unlock(){return!!super.unlock()&&(this.editor.classList.remove("jodit_disabled"),this.__selectionLocked&&this.selection.restore(this.__selectionLocked),!0)}getMode(){return this.mode}isEditorMode(){return this.getRealMode()===P}getRealMode(){if(this.getMode()!==O)return this.getMode();const t=this.ownerDocument.activeElement;return t&&(xe.isOrContains(this.editor,t)||xe.isOrContains(this.toolbar.container,t))?P:H}setMode(t){const e=this.getMode(),i={mode:parseInt(""+t,10)},o=["jodit_wysiwyg_mode","jodit_source_mode","jodit_split_mode"];!1!==this.events.fire("beforeSetMode",i)&&(this.mode=ot(i.mode,[H,P,O])?i.mode:P,this.options.saveModeInStorage&&this.storage.set("jodit_default_mode",this.mode),o.forEach(t=>{this.container.classList.remove(t)}),this.container.classList.add(o[this.mode-1]),e!==this.getMode()&&this.events.fire("afterSetMode"))}toggleMode(){let t=this.getMode();ot(t+1,[H,P,this.options.useSplitMode?O:9])?t+=1:t=P,this.setMode(t)}setDisabled(t){this.options.disabled=t;const e=this.__wasReadOnly;this.setReadOnly(t||e),this.__wasReadOnly=e,this.editor&&(this.editor.setAttribute("aria-disabled",""+t),this.container.classList.toggle("jodit_disabled",t),this.events.fire("disabled",t))}getDisabled(){return this.options.disabled}setReadOnly(t){this.__wasReadOnly!==t&&(this.__wasReadOnly=t,this.options.readonly=t,t?this.editor&&this.editor.removeAttribute("contenteditable"):this.editor&&this.editor.setAttribute("contenteditable","true"),this.events&&this.events.fire("readonly",t))}getReadOnly(){return this.options.readonly}beforeInitHook(){}afterInitHook(){}resolveElement(t){let e=t;if("string"==typeof t)try{e=this.ownerDocument.querySelector(t)}catch(e){throw Error('String "'+t+'" should be valid HTML selector')}if(!e||"object"!=typeof e||e.nodeType!==Node.ELEMENT_NODE||!e.cloneNode)throw Error('Element "'+t+'" should be string or HTMLElement instance');return e}makeToolbar(){if(!this.options.toolbar)return;let t=this.create.div("jodit_toolbar_container");this.container.appendChild(t),(this.options.toolbar instanceof HTMLElement||"string"==typeof this.options.toolbar)&&(t=this.resolveElement(this.options.toolbar)),this.applyOptionsToToolbarContainer(t),this.toolbar.build(st(this.options.buttons).concat(this.options.extraButtons),t);const e=this.options.toolbarButtonSize.toLowerCase();t.classList.add("jodit_toolbar_size-"+(-1!==["middle","large","small"].indexOf(e)?e:"middle"))}applyOptionsToToolbarContainer(t){t.classList.add("jodit_"+(this.options.theme||"default")+"_theme"),this.options.zIndex&&(t.style.zIndex=""+parseInt(""+this.options.zIndex,10))}async __initEditor(t){if(await this.__createEditor(),this.isDestructed)return;this.element!==this.container?this.setElementValue():null!==t&&this.setEditorValue(t),li.instances[this.id]=this;let e=this.options.defaultMode;if(this.options.saveModeInStorage){const t=this.storage.get("jodit_default_mode");"string"==typeof t&&(e=parseInt(t,10))}this.setMode(e),this.options.readonly&&this.setReadOnly(!0),this.options.disabled&&this.setDisabled(!0);try{this.editorDocument.execCommand("defaultParagraphSeparator",!1,this.options.enter.toLowerCase())}catch(t){}try{this.editorDocument.execCommand("enableObjectResizing",!1,"false")}catch(t){}try{this.editorDocument.execCommand("enableInlineTableEditing",!1,"false")}catch(t){}}async __createEditor(){const t=this.editor,e=await this.events.fire("createEditor",this);if(!this.isDestructed){if(!1===e&&xe.safeRemove(t),this.options.editorCssClass&&this.editor.classList.add(this.options.editorCssClass),this.options.style&&fe(this.editor,this.options.style),this.events.on("synchro",()=>{this.setEditorValue()}).on("focus",()=>this.editorIsActive=!0).on("blur",()=>this.editorIsActive=!1).on(this.editor,"selectionchange selectionstart keydown keyup keypress mousedown mouseup mousepress click copy cut dragstart drop dragover paste resize touchstart touchend focus blur",t=>{if(!this.options.readonly&&this.events&&this.events.fire){if(!1===this.events.fire(t.type,t))return!1;this.setEditorValue()}}),this.options.spellcheck&&this.editor.setAttribute("spellcheck","true"),this.options.direction){const t="rtl"===this.options.direction.toLowerCase()?"rtl":"ltr";this.editor.style.direction=t,this.container.style.direction=t,this.editor.setAttribute("dir",t),this.container.setAttribute("dir",t),this.toolbar.setDirection(t)}this.options.triggerChangeEvent&&this.events.on("change",rt(()=>{this.events&&this.events.fire(this.element,"change")},this.defaultTimeout))}}destruct(){if(this.isDestructed)return;if(!1===this.events.fire("beforeDestruct"))return;if(!this.editor)return;const t=this.getEditorValue();if(this.element!==this.container)if(this.element.hasAttribute(this.__defaultStyleDisplayKey)){const t=this.element.getAttribute(this.__defaultStyleDisplayKey);t&&(this.element.style.display=t,this.element.removeAttribute(this.__defaultStyleDisplayKey))}else this.element.style.display="";else this.element.hasAttribute(this.__defaultClassesKey)&&(this.element.className=this.element.getAttribute(this.__defaultClassesKey)||"",this.element.removeAttribute(this.__defaultClassesKey));this.element.hasAttribute("style")&&!this.element.getAttribute("style")&&this.element.removeAttribute("style"),this.observer.destruct(),this.statusbar.destruct(),delete this.observer,delete this.statusbar,delete this.storage,this.buffer.clear(),delete this.buffer,this.components.forEach(t=>{void 0===t.destruct||"function"!=typeof t.destruct||t.isDestructed||t.destruct()}),this.components.length=0,this.commands={},delete this.selection,this.__selectionLocked=null,this.events.off(this.ownerWindow),this.events.off(this.ownerDocument),this.events.off(this.ownerDocument.body),this.events.off(this.element),this.events.off(this.editor),xe.safeRemove(this.workplace),xe.safeRemove(this.editor),xe.safeRemove(this.progress_bar),xe.safeRemove(this.iframe),this.container!==this.element&&xe.safeRemove(this.container),delete this.workplace,delete this.editor,delete this.progress_bar,delete this.iframe,this.container===this.element&&(this.element.innerHTML=t),delete li.instances[this.id],super.destruct(),delete this.container}}li.plugins=new ri,li.modules={},li.instances={},li.lang={};var di=i(79),ci=i.n(di),hi=i(80),pi=i.n(hi),ui=i(81),fi=i.n(ui),mi=i(0),gi=i.n(mi),vi=i(82),bi=i.n(vi),yi=i(83),wi=i.n(yi),_i=i(84),ki=i.n(_i),ji=i(85),xi=i.n(ji),Ci=i(86),zi=i.n(Ci),Ei=i(87),Ti=i.n(Ei),Si=i(88),qi=i.n(Si),Li=i(89),Ni=i.n(Li),Mi=i(90),Ai=i.n(Mi),Ii=i(91),Di=i.n(Ii),Ri=i(92),Bi=i.n(Ri),Pi=i(93),Hi=i.n(Pi),Oi=i(94);const Wi={ar:ci.a,cs_cz:pi.a,de:fi.a,en:gi.a,es:bi.a,fr:wi.a,he:ki.a,hu:xi.a,id:zi.a,it:Ti.a,nl:qi.a,pl:Ni.a,pt_br:Ai.a,ru:Di.a,tr:Bi.a,zh_cn:Hi.a,zh_tw:i.n(Oi).a},Fi=t=>t.default||t,Vi={};Array.isArray(Fi(gi.a))&&Fi(gi.a).forEach((t,e)=>{Vi[e]=t}),Object.keys(Wi).forEach(t=>{const e=Fi(Wi[t]);Array.isArray(e)&&(Wi[t]={},e.forEach((e,i)=>{Wi[t][Vi[i]]=e}))});var $i=Wi;qe.prototype.defaultAjaxOptions={dataType:"json",method:"GET",url:"",data:null,contentType:"application/x-www-form-urlencoded; charset=UTF-8",headers:{"X-REQUESTED-WITH":"XMLHttpRequest"},withCredentials:!1,xhr:()=>new XMLHttpRequest};class Ui{constructor(t,e){this.success_response_codes=[200,201,202],this.jodit=t,this.options=gt(!0,{},qe.prototype.defaultAjaxOptions,e),this.options.xhr&&(this.xhr=this.options.xhr()),t&&t.events&&t.events.on("beforeDestruct",()=>{this.abort()})}__buildParams(t,e){return this.options.queryBuild&&"function"==typeof this.options.queryBuild?this.options.queryBuild.call(this,t,e):"string"==typeof t||this.jodit.ownerWindow.FormData&&t instanceof this.jodit.ownerWindow.FormData?t:we(t)}abort(){try{this.xhr.abort()}catch(t){}return this}send(){return new Promise((t,e)=>{const i=t=>{let e=null;if("json"===this.options.dataType&&(e=JSON.parse(t)),!e)throw Error("No JSON format");return e};this.xhr.onabort=()=>{e(Error(this.xhr.statusText))},this.xhr.onerror=()=>{e(Error(this.xhr.statusText))},this.xhr.ontimeout=()=>{e(Error(this.xhr.statusText))},this.xhr.onload=()=>{this.response=this.xhr.responseText,this.status=this.xhr.status,t.call(this.xhr,i(this.response)||{})},this.xhr.onreadystatechange=()=>{if(this.xhr.readyState===XMLHttpRequest.DONE){const o=this.xhr.responseText;this.response=o,this.status=this.xhr.status,this.success_response_codes.indexOf(this.xhr.status)>-1?t.call(this.xhr,i(o)):e.call(this.xhr,Error(this.xhr.statusText||this.jodit.i18n("Connection error!")))}},this.xhr.withCredentials=this.options.withCredentials||!1;const{url:o,data:s,method:n}=this.prepareRequest();this.xhr.open(n,o,!0),this.options.contentType&&this.xhr.setRequestHeader&&this.xhr.setRequestHeader("Content-type",this.options.contentType),this.options.headers&&this.xhr.setRequestHeader&&be(this.options.headers,(t,e)=>{this.xhr.setRequestHeader(t,e)}),setTimeout(()=>{this.xhr.send(s?this.__buildParams(s):void 0)},0)})}prepareRequest(){if(!this.options.url)throw Error("Need URL for AJAX request");let t=this.options.url;const e=this.options.data,i=(this.options.method||"get").toLowerCase();if("get"===i&&e&&mt(e)){const i=t.indexOf("?");if(-1!==i){const o=pe(t);t=t.substr(0,i)+"?"+we({...o,...e})}else t+="?"+we(this.options.data)}const o={url:t,method:i,data:e};return Ui.log.splice(100),Ui.log.push(o),o}}Ui.log=[];class Ki extends Ne{constructor(t){super(t),this.hide=()=>{this.context.classList.remove("jodit_context_menu-show"),this.jodit.ownerWindow.removeEventListener("mouseup",this.hide)},this.context=t.create.div("jodit_context_menu",{"data-editor_id":this.jodit.id}),t.ownerDocument.body.appendChild(this.context)}show(t,e,i,o){const s=this;Array.isArray(i)&&(o&&(this.context.style.zIndex=""+o),this.context.innerHTML="",i.forEach(t=>{if(!t)return;const e=s.jodit.i18n(t.title||""),i=this.jodit.create.fromHTML(``+(t.icon?Ce.getIcon(t.icon):"")+""),o=i.querySelector("span");i.addEventListener("click",e=>(t.exec&&t.exec.call(s,e),s.hide(),!1)),o.textContent=e,s.context.appendChild(i)}),fe(s.context,{left:t,top:e}),this.jodit.events.on(this.jodit.ownerWindow,"mouseup jodit_close_dialog",s.hide),this.context.classList.add("jodit_context_menu-show"))}destruct(){xe.safeRemove(this.context),delete this.context,this.jodit.events.off(this.jodit.ownerWindow,"mouseup",this.hide),super.destruct()}}function Xi(t){if(!t.options.addNewLine)return;const e=t.create.fromHTML('
'+Ce.getIcon("enter")+"
"),i=RegExp("^("+t.options.addNewLineTagsTriggers.join("|")+")$","i");let o,s,n=!1,r=!1,a=!1;const l=()=>{clearTimeout(o),a=!1,e.style.display="none",n=!0},d=e=>null!==e&&xe.isBlock(e,t.editorWindow)&&!/^(img|table|iframe|hr)$/i.test(e.nodeName),c=()=>{n||a||(clearTimeout(o),o=nt(l,500))};t.events.on("beforeDestruct",()=>{xe.safeRemove(e)}).on("afterInit",()=>{t.container.appendChild(e),t.events.on(e,"mousemove",t=>{t.stopPropagation()}).on(e,"mousedown touchstart",e=>{const i=t.editorDocument.createElement(t.options.enter);r&&s&&s.parentNode?s.parentNode.insertBefore(i,s):t.editor.appendChild(i),t.selection.setCursorIn(i),t.events.fire("synchro"),l(),e.preventDefault()})}).on("afterInit",()=>{t.events.on(t.editor,"scroll",()=>{l()}).on(t.container,"mouseleave",c).on(e,"mouseenter",()=>{clearTimeout(o),a=!0}).on(e,"mouseleave",()=>{a=!1}).on(t.editor,"dblclick",e=>{if(!t.options.readonly&&t.options.addNewLineOnDBLClick&&e.target===t.editor&&t.selection.isCollapsed()){const i=se(t.editor,t,t.editorDocument),o=e.pageY-t.editorWindow.pageYOffset,s=t.editorDocument.createElement(t.options.enter);Math.abs(o-(i.height+i.top))>Math.abs(o-i.top)&&t.editor.firstChild?t.editor.insertBefore(s,t.editor.firstChild):t.editor.appendChild(s),t.selection.setCursorIn(s),t.setEditorValue(),l(),e.preventDefault()}}).on(t.editor,"mousemove",rt(a=>{let l=t.editorDocument.elementFromPoint(a.pageX-t.editorWindow.pageXOffset,a.pageY-t.editorWindow.pageYOffset);if(l&&xe.isOrContains(e,l))return;if(!l||!xe.isOrContains(t.editor,l))return;if(!(l&&l.nodeName.match(i)&&xe.isOrContains(t.editor,l)||(l=xe.closest(l,i,t.editor),l)))return void c();if(i.test(l.nodeName)){const e=xe.up(l,e=>xe.isBlock(e,t.editorWindow),t.editor);e&&e!==t.editor&&(l=e)}const h=se(t.editor,t,t.editorDocument),p=se(l,t,t.editorDocument);let u=!1;10>Math.abs(a.pageY-p.top)&&(u=p.top,20>u-h.top||(u-=15),r=!0),10>Math.abs(a.pageY-(p.top+p.height))&&(u=p.top+p.height,25>h.top+h.height-u||(u+=15),r=!1),!1!==u&&(r&&!xe.prev(l,d,t.editor)||!r&&!xe.next(l,d,t.editor))?(e.style.top=u+"px",s=l,t.options.readonly||t.isLocked()||t.container.classList.contains("jodit_popup_active")||(clearTimeout(o),e.classList.toggle("jodit-add-new-line_after",!r),e.style.display="block",e.style.width=t.editor.clientWidth+"px",n=!1)):(s=!1,c())},t.defaultTimeout))})}function Yi(t){let e;t.events.on("afterInit",()=>{t.options.autofocus&&(t.defaultTimeout?e=nt(t.selection.focus,300):t.selection.focus())}).on("mousedown",e=>{t.isEditorMode()&&e.target&&xe.isBlock(e.target,t.editorWindow)&&!e.target.childNodes.length&&(t.editor===e.target?t.selection.focus():t.selection.setCursorIn(e.target))}).on("beforeDestruct",()=>{clearTimeout(e)})}function Gi(t){const e=e=>{let i,o=e;Yt(e);do{const s=o.innerHTML.replace(d,"");if(s.length&&"
"!==s||xe.isCell(o,t.editorWindow)||!o.parentNode||e===t.editor)break;i=o.parentNode,xe.safeRemove(o),o=i}while(o&&o!==t.editor)},i=(e,o,s)=>{if(e.node&&e.node.nodeType===Node.TEXT_NODE&&"string"==typeof e.node.nodeValue){let n=e.node.nodeValue,r=o?n.length:0;const a=o?-1:1,d=r;for(;r>=0&&n.length>=r&&n[r+(o?-1:0)]===l;)r+=a;r!==d&&(o?n=n.substr(0,r)+n.substr(d):(n=n.substr(0,d)+n.substr(r),r=d),e.node.nodeValue=n),s.setStart(e.node,r),s.collapse(!0),t.selection.selectRange(s);let c=xe.findInline(e.node,o,t.editor);if(n.length){let t=!1;if(o?r&&(t=!0):n.length>r&&(t=!0),t)return!0}else s.setStartBefore(e.node),s.collapse(!0),t.selection.selectRange(s),xe.safeRemove(e.node),e.node=c;if(c&&(xe.isInlineBlock(c)&&(c=o?c.lastChild:c.firstChild),c&&c.nodeType===Node.TEXT_NODE))return e.node=c,i(e,o,s)}},o=v,s=t=>{if(t&&o.test(t.nodeName))return xe.safeRemove(t),!1},n=(e,o,n)=>{if(e.node){const r=e.node;if(void 0!==i(e,o,n))return!0;if(e.node||(e.node=r.parentNode),e.node===t.editor)return!1;let a=e.node;if(!1===s(a))return!1;for(a&&(a=o?a.previousSibling:a.nextSibling);a&&a.nodeType===Node.TEXT_NODE&&a.nodeValue&&a.nodeValue.match(/^[\n\r]+$/);)a=o?a.previousSibling:a.nextSibling;return s(a)}},r=t=>null===t.nodeName.match(/^(TD|TH|TR|TABLE|LI)$/)&&(!(!xe.isEmpty(t)&&null===t.nodeName.match(o))||!(t.nodeType===Node.TEXT_NODE&&!xe.isEmptyTextNode(t))&&(!t.childNodes.length||Array.from(t.childNodes).every(r)));t.events.on("afterCommand",e=>{if("delete"===e){const e=t.selection.current();if(e&&e.firstChild&&"BR"===e.firstChild.nodeName&&xe.safeRemove(e.firstChild),!(Bt(t.editor.textContent||"")||t.editor.querySelector("img")||e&&xe.closest(e,"table",t.editor))){t.editor.innerHTML="";const e=t.selection.setCursorIn(t.editor);xe.safeRemove(e)}}}).on("keydown",i=>{if(i.which===b||i.which===z){const o=i.which===b;if(t.selection.isFocused()||t.selection.focus(),!t.selection.isCollapsed())return t.execCommand("Delete"),!1;const s=t.selection.sel,a=!(!s||!s.rangeCount)&&s.getRangeAt(0);if(!a)return!1;const d=t.ownerDocument.createTextNode(l),c=t.editorDocument.createElement("span");try{if(a.insertNode(d),!xe.isOrContains(t.editor,d))return!1;let i=xe.up(d,e=>xe.isBlock(e,t.editorWindow),t.editor);const s=xe.findInline(d,o,t.editor),h={node:s};let p;if(s?p=n(h,o,a):d.parentNode&&(p=n({node:o?d.parentNode.previousSibling:d.parentNode.nextSibling},o,a)),void 0!==p)return!!p&&void 0;if(i&&i.nodeName.match(/^(TD)$/))return!1;let u=o?xe.prev(h.node||d,e=>xe.isBlock(e,t.editorWindow),t.editor):xe.next(h.node||d,e=>xe.isBlock(e,t.editorWindow),t.editor);if(!u&&i&&i.parentNode){u=t.create.inside.element(t.options.enter);let e=i;for(;e&&e.parentNode&&e.parentNode!==t.editor;)e=e.parentNode;e.parentNode&&e.parentNode.insertBefore(u,e)}else if(u&&r(u))return xe.safeRemove(u),!1;if(u){const e=t.selection.setCursorIn(u,!o);t.selection.insertNode(c,!1,!1),e.nodeType===Node.TEXT_NODE&&e.nodeValue===l&&xe.safeRemove(e)}if(i){if(e(i),u&&i.parentNode&&(i.nodeName===u.nodeName&&i.parentNode&&u.parentNode&&i.parentNode!==t.editor&&u.parentNode!==t.editor&&i.parentNode!==u.parentNode&&i.parentNode.nodeName===u.parentNode.nodeName&&(i=i.parentNode,u=u.parentNode),xe.moveContent(i,u,!o),Yt(u)),u&&"LI"===u.nodeName){const e=xe.closest(u,"Ul|OL",t.editor);if(e){const t=e.nextSibling;t&&t.nodeName===e.nodeName&&e!==t&&(xe.moveContent(t,e,!o),xe.safeRemove(t))}}return e(i),!1}}finally{if(d.parentNode&&d.nodeValue===l){const e=d.parentNode;xe.safeRemove(d),!e.firstChild&&e.parentNode&&e!==t.editor&&xe.safeRemove(e)}if(c&&xe.isOrContains(t.editor,c,!0)){const e=t.selection.setCursorBefore(c);xe.safeRemove(c),e&&e.parentNode&&(xe.findInline(e,!0,e.parentNode)||xe.findInline(e,!0,e.parentNode))&&xe.safeRemove(e)}t.setEditorValue()}return!1}})}function Ji(t){const e=e=>{const i=qe.defaultOptions.controls[e],o={...i.css},s={};return Object.keys(o).forEach(t=>{s[t]=Array.isArray(o[t])?o[t][0]:o[t]}),t.selection.applyCSS(s,i.tags?i.tags[0]:void 0,i.css),t.events.fire("synchro"),!1};t.registerCommand("bold",{exec:e,hotkeys:["ctrl+b","cmd+b"]}).registerCommand("italic",{exec:e,hotkeys:["ctrl+i","cmd+i"]}).registerCommand("underline",{exec:e,hotkeys:["ctrl+u","cmd+u"]}).registerCommand("strikethrough",{exec:e})}function Zi(t){t.options.cleanHTML.cleanOnPaste&&t.events.on("processPaste",(t,e)=>Ft(e));const e=/([^\[]*)\[([^\]]+)]/,i=/[\s]*,[\s]*/,o=/^(.*)[\s]*=[\s]*(.*)$/,s=t=>{const s={};return"string"==typeof t?(t.split(i).map(t=>{t=Bt(t);const n=e.exec(t),r={},a=t=>{t=Bt(t);const e=o.exec(t);e?r[e[1]]=e[2]:r[t]=!0};if(n){const t=n[2].split(i);n[1]&&(t.forEach(a),s[n[1].toUpperCase()]=r)}else s[t.toUpperCase()]=!0}),s):!!t&&(Object.keys(t).forEach(e=>{s[e.toUpperCase()]=t[e]}),s)};let n;const r=s(t.options.cleanHTML.allowTags),a=s(t.options.cleanHTML.denyTags),l=(t,e=!1)=>{let i=e?t.nextSibling:t.previousSibling;for(;i;){if(i.nodeType===Node.ELEMENT_NODE||!xe.isEmptyTextNode(i))return!0;i=e?i.nextSibling:i.previousSibling}return!1};t.events.on("change afterSetMode afterInit mousedown keydown",rt(()=>{if(!t.isDestructed&&t.isEditorMode()&&t.selection){n=t.selection.current();let e=null,i=!1,o=0;const s=[],d=t.options.cleanHTML.replaceOldTags;if(d&&n){const e=Object.keys(d).join("|");if(t.selection.isCollapsed()){const i=xe.closest(n,e,t.editor);if(i){const e=t.selection.save(),o=d[i.nodeName.toLowerCase()]||d[i.nodeName];xe.replace(i,o,!0,!1,t.editorDocument),t.selection.restore(e)}}}const c=e=>{if(e){if((e=>!(e.nodeType===Node.TEXT_NODE||!(r&&!r[e.nodeName]||a&&a[e.nodeName]))||!(!n||"BR"!==e.nodeName||!l(e)||l(e,!0)||xe.up(e,e=>xe.isBlock(e,t.editorWindow),t.editor)===xe.up(n,e=>xe.isBlock(e,t.editorWindow),t.editor))||t.options.cleanHTML.removeEmptyElements&&!1!==n&&e.nodeType===Node.ELEMENT_NODE&&null!==e.nodeName.match(g)&&!t.selection.isMarker(e)&&0===Bt(e.innerHTML).length&&!xe.isOrContains(e,n))(e))return s.push(e),c(e.nextSibling);if(t.options.cleanHTML.fillEmptyParagraph&&xe.isBlock(e,t.editorWindow)&&xe.isEmpty(e,/^(img|svg|canvas|input|textarea|form|br)$/)){const i=t.create.inside.element("br");e.appendChild(i)}if(r&&!0!==r[e.nodeName]){const t=e.attributes;if(t&&t.length){const s=[];for(o=0;t.length>o;o+=1)(!r[e.nodeName][t[o].name]||!0!==r[e.nodeName][t[o].name]&&r[e.nodeName][t[o].name]!==t[o].value)&&s.push(t[o].name);s.length&&(i=!0),s.forEach(t=>{e.removeAttribute(t)})}}c(e.firstChild),c(e.nextSibling)}};t.editor.firstChild&&(e=t.editor.firstChild),c(e),s.forEach(xe.safeRemove),(s.length||i)&&t.events&&t.events.fire("syncho")}},t.options.cleanHTML.timeout)).on("keyup",()=>{if(t.options.readonly)return;const e=t.selection.current();if(e){const i=xe.up(e,e=>xe.isBlock(e,t.editorWindow),t.editor);i&&xe.all(i,i=>{i&&i.nodeType===Node.TEXT_NODE&&null!==i.nodeValue&&d.test(i.nodeValue)&&0!==i.nodeValue.replace(d,"").length&&(i.nodeValue=i.nodeValue.replace(d,""),i===e&&t.selection.isCollapsed()&&t.selection.setCursorAfter(i))})}}).on("afterCommand",e=>{const i=t.selection;let o,s;switch(e.toLowerCase()){case"inserthorizontalrule":o=t.editor.querySelector("hr[id=null]"),o&&(s=xe.next(o,e=>xe.isBlock(e,t.editorWindow),t.editor,!1),s||(s=t.create.inside.element(t.options.enter),s&&xe.after(o,s)),i.setCursorIn(s));break;case"removeformat":s=i.current();const e=i=>{switch(i.nodeType){case Node.ELEMENT_NODE:xe.each(i,e),"FONT"===i.nodeName?xe.unwrap(i):([].slice.call(i.attributes).forEach(t=>{-1===["src","href","rel","content"].indexOf(t.name.toLowerCase())&&i.removeAttribute(t.name)}),Yt(i));break;case Node.TEXT_NODE:t.options.cleanHTML.replaceNBSP&&i.nodeType===Node.TEXT_NODE&&null!==i.nodeValue&&i.nodeValue.match(p)&&(i.nodeValue=i.nodeValue.replace(p," "));break;default:xe.safeRemove(i)}};if(i.isCollapsed())for(;s&&s.nodeType!==Node.ELEMENT_NODE&&s!==t.editor;)e(s),s&&(s=s.parentNode);else t.selection.eachSelection(t=>{e(t)})}})}qe.prototype.addNewLine=!0,qe.prototype.addNewLineOnDBLClick=!0,qe.prototype.addNewLineTagsTriggers=["table","iframe","img","hr","jodit"],qe.prototype.autofocus=!1,qe.prototype.controls.subscript={tags:["sub"],tooltip:"subscript"},qe.prototype.controls.superscript={tags:["sup"],tooltip:"superscript"},qe.prototype.controls.bold={tagRegExp:/^(strong|b)$/i,tags:["strong","b"],css:{"font-weight":["bold","700"]},tooltip:"Bold"},qe.prototype.controls.italic={tagRegExp:/^(em|i)$/i,tags:["em","i"],css:{"font-style":"italic"},tooltip:"Italic"},qe.prototype.controls.underline={tagRegExp:/^(u)$/i,tags:["u"],css:{"text-decoration":"underline"},tooltip:"Underline"},qe.prototype.controls.strikethrough={tagRegExp:/^(s)$/i,tags:["s"],css:{"text-decoration":"line-through"},tooltip:"Strike through"},qe.prototype.cleanHTML={timeout:300,removeEmptyElements:!0,fillEmptyParagraph:!0,replaceNBSP:!0,cleanOnPaste:!0,replaceOldTags:{i:"em",b:"strong"},allowTags:!1,denyTags:!1},qe.prototype.controls.eraser={command:"removeFormat",tooltip:"Clear Formatting"};const Qi=t=>t.replace(/([^>])([\n\r]+)/g,"$1
$2");qe.prototype.askBeforePasteHTML=!0,qe.prototype.askBeforePasteFromWord=!0,qe.prototype.nl2brInPlainText=!0,qe.prototype.defaultActionOnPaste=Y;const to=t=>t.clipboardData?t.clipboardData:t.dataTransfer||new DataTransfer;function eo(t){const e=(e,i,o,s="Clean",n="Insert only Text")=>{if(t.events&&!1===t.events.fire("beforeOpenPasteDialog",e,i,o,s,n))return;const r=Jo(`
${e}
`,i,o);r.container.setAttribute("data-editor_id",t.id);const a=r.create.fromHTML(''+t.i18n("Keep")+""),l=r.create.fromHTML(''+t.i18n(s)+""),d=r.create.fromHTML(''+t.i18n(n)+""),c=r.create.fromHTML(''+t.i18n("Cancel")+"");return t.events.on(a,"click",()=>{r.close(),o&&o(!0)}),t.events.on(l,"click",()=>{r.close(),o&&o(!1)}),t.events.on(d,"click",()=>{r.close(),o&&o(0)}),t.events.on(c,"click",()=>{r.close()}),r.setFooter([a,l,n?d:"",c]),t.events&&t.events.fire("afterOpenPasteDialog",r,e,i,o,s,n),r},i=(e,i)=>{if("string"==typeof e)switch(i){case G:e=Ft(e);break;case Z:e=Ut(e);break;case J:e=$t(e)}"string"==typeof e&&t.buffer.set(io,e),t.selection.insertHTML(e)},o=(o,n)=>{const r=t.buffer.get(io);if(yt(o)&&r!==s(o))return t.events.stopPropagation("beforePaste"),o=s(o),e(t.i18n("Your code is similar to HTML. Keep as HTML?"),t.i18n("Paste as HTML"),e=>{let s=Y;!1===e&&(s=J),0===e&&(s=Z),"drop"===n.type&&t.selection.insertCursorAtPoint(n.clientX,n.clientY),i(o,s),t.setEditorValue()},"Insert as Text"),!1},s=t=>{const e=t.search(//i);-1!==e&&(t=t.substr(e+20));const i=t.search(//i);return-1!==i&&(t=t.substr(0,i)),t};t.events.on("paste",e=>{if(!1===t.events.fire("beforePaste",e))return e.preventDefault(),!1;const o=to(e);if(e&&o){const n=o.types;let r="";if(Array.isArray(n)||"domstringlist"===ut(n))for(let t=0;n.length>t;t+=1)r+=n[t]+";";else r=n+";";let a=(()=>/text\/html/i.test(r)?o.getData("text/html"):/text\/rtf/i.test(r)&&he("safari")?o.getData("text/rtf"):/text\/plain/i.test(r)&&!he("mozilla")?o.getData(V):/text/i.test(r)&&W?o.getData(V):"")();(xe.isNode(a,t.editorWindow)||""!==Bt(a))&&(a=s(a),t.buffer.get(io)!==a&&(a=t.events.fire("processPaste",e,a,r)),("string"==typeof a||xe.isNode(a,t.editorWindow))&&("drop"===e.type&&t.selection.insertCursorAtPoint(e.clientX,e.clientY),i(a,t.options.defaultActionOnPaste)),e.preventDefault(),e.stopPropagation())}return!1!==t.events.fire("afterPaste",e)&&void 0}),t.options.askBeforePasteHTML&&t.events.on("beforePaste",t=>{const e=to(t);if(t&&e&&e.getData(V)){const i=e.getData(V);return o(i,t)}}),t.options.askBeforePasteFromWord&&t.events.on("beforePaste",i=>{const n=to(i);if(i&&n&&n.getData&&n.getData($)){const r=n=>{const r=t.buffer.get(io);if(yt(n)&&r!==s(n))return wt(n)?e(t.i18n("The pasted content is coming from a Microsoft Word/Excel document. Do you want to keep the format or clean it up?"),t.i18n("Word Paste Detected"),e=>{!0===e&&(n=It(n),t.options.beautifyHTML&&t.ownerWindow.html_beautify&&(n=t.ownerWindow.html_beautify(n))),!1===e&&(n=Ft(n)),0===e&&(n=Ut(Ft(n))),t.selection.insertHTML(n),t.setEditorValue()}):o(n,i),!1};if(n.types&&-1!==Array.from(n.types).indexOf("text/html")){const t=n.getData($);return r(t)}if("drop"!==i.type){const e=t.create.div("",{tabindex:-1,contenteditable:!0,style:{left:-9999,top:0,width:0,height:"100%",lineHeight:"140%",overflow:"hidden",position:"fixed",zIndex:2147483647,wordBreak:"break-all"}});t.container.appendChild(e);const i=t.selection.save();e.focus();let o=0;const s=()=>{xe.safeRemove(e),t.selection&&t.selection.restore(i)},n=()=>{if(o+=1,e.childNodes&&e.childNodes.length>0){const i=e.innerHTML;return s(),void(!1!==r(i)&&t.selection.insertHTML(i))}5>o?nt(n,20):s()};n()}}}),t.options.nl2brInPlainText&&t.events.on("processPaste",(t,e,i)=>{if(i===V+";"&&!yt(e))return Qi(e)})}qe.prototype.controls.paste={tooltip:"Paste from clipboard",async exec(t){t.selection.focus();let e="",i=!0;if(i&&(e=t.buffer.get(io)||"",i=0===e.length),i&&navigator.clipboard){try{const t=await navigator.clipboard.read();if(t&&t.length){const i=await t[0].getType("text/plain");e=await new Response(i).text()}}catch(t){}if(i)try{e=await navigator.clipboard.readText(),i=!1}catch(t){}}if(i){const e=t.value;t.editorDocument.execCommand("paste"),i=e!==t.value}e?t.selection.insertHTML(e):i&&Yo(t.i18n("Your browser doesn't support direct access to the clipboard."),()=>{t.selection.focus()})}},qe.prototype.controls.cut={command:"cut",isDisable:t=>t.selection.isCollapsed(),tooltip:"Cut selection"},qe.prototype.controls.copy={command:"copy",isDisable:t=>t.selection.isCollapsed(),tooltip:"Copy selection"};const io="clipboard";class oo extends Ne{constructor(t){super(t),this.destruct=this.destruct.bind(this,t),t.events.on("afterInit",this.afterInit.bind(this,t)).on("beforeDestruct",this.destruct)}init(t){}destruct(){var t,e;this.isDestructed||(null===(e=null===(t=this.jodit)||void 0===t?void 0:t.events)||void 0===e||e.off("beforeDestruct",this.destruct),this.beforeDestruct(this.jodit),super.destruct())}}class so extends oo{constructor(){super(...arguments),this.currentIndex=0,this.list=[],this.container=null,this.listBox=null,this.previewBox=null,this.dialog=null,this.paste=()=>{if(this.jodit.selection.focus(),this.jodit.selection.insertHTML(this.list[this.currentIndex]),0!==this.currentIndex){const t=this.list[0];this.list[0]=this.list[this.currentIndex],this.list[this.currentIndex]=t}this.dialog&&this.dialog.close(),this.jodit.setEditorValue()},this.onKeyDown=t=>{let e=this.currentIndex;-1!==[j,C,w].indexOf(t.which)&&(t.which===j&&(0===e?e=this.list.length-1:e-=1),t.which===C&&(e===this.list.length-1?e=0:e+=1),t.which!==w?(e!==this.currentIndex&&this.selectIndex(e),t.stopImmediatePropagation(),t.preventDefault()):this.paste())},this.selectIndex=t=>{this.listBox&&Array.from(this.listBox.childNodes).forEach((e,i)=>{e.classList.remove("jodit_active"),t===i&&this.previewBox&&(e.classList.add("jodit_active"),this.previewBox.innerHTML=this.list[t],e.focus())}),this.currentIndex=t},this.showDialog=()=>{2>this.list.length||(this.dialog||this.createDialog(),this.listBox&&(this.listBox.innerHTML=""),this.previewBox&&(this.previewBox.innerHTML=""),this.list.forEach((t,e)=>{const i=this.jodit.ownerDocument.createElement("a");i.textContent=e+1+". "+t.replace(p,""),i.addEventListener("keydown",this.onKeyDown),i.setAttribute("href","javascript:void(0)"),i.setAttribute("data-index",""+e),i.setAttribute("tab-index","-1"),this.listBox&&this.listBox.appendChild(i)}),this.dialog&&this.dialog.open(),nt(()=>{this.selectIndex(0)},100))}}createDialog(){this.dialog=new Xo(this.jodit);const t=this.jodit.create.fromHTML(''+this.jodit.i18n("Paste")+"");t.addEventListener("click",this.paste);const e=this.jodit.create.fromHTML(''+this.jodit.i18n("Cancel")+"");e.addEventListener("click",this.dialog.close),this.container=this.jodit.ownerDocument.createElement("div"),this.container.classList.add("jodit_paste_storage"),this.listBox=this.jodit.ownerDocument.createElement("div"),this.previewBox=this.jodit.ownerDocument.createElement("div"),this.container.appendChild(this.listBox),this.container.appendChild(this.previewBox),this.dialog.setTitle(this.jodit.i18n("Choose Content to Paste")),this.dialog.setContent(this.container),this.dialog.setFooter([t,e]),this.jodit.events.on(this.listBox,"click dblclick",t=>{const e=t.target;return e&&"A"===e.nodeName&&e.hasAttribute("data-index")&&this.selectIndex(parseInt(e.getAttribute("data-index")||"0",10)),"dblclick"===t.type&&this.paste(),!1},"a")}afterInit(){this.jodit.events.on("afterCopy",t=>{-1!==this.list.indexOf(t)&&this.list.splice(this.list.indexOf(t),1),this.list.unshift(t),this.list.length>5&&(this.list.length=5)}),this.jodit.registerCommand("showPasteStorage",{exec:this.showDialog,hotkeys:["ctrl+shift+v","cmd+shift+v"]})}beforeDestruct(){this.dialog&&this.dialog.destruct(),xe.safeRemove(this.previewBox),xe.safeRemove(this.listBox),xe.safeRemove(this.container),this.container=null,this.listBox=null,this.previewBox=null,this.dialog=null,this.list=[]}}const no=["fontWeight","fontStyle","fontSize","color","margin","padding","borderWidth","borderStyle","borderColor","borderRadius","backgroundColor","textDecorationLine","fontFamily"],ro=(t,e,i,o)=>{let s=fe(i,e);return s===o[e]&&(s=i.parentNode&&i!==t.editor&&i.parentNode!==t.editor?ro(t,e,i.parentNode,o):void 0),s};qe.prototype.controls.copyformat={exec(t,e){if(e)if(t.buffer.exists("copyformat"))t.buffer.set("copyformat",!1),t.events.off(t.editor,"mouseup.copyformat");else{const i={},o=xe.up(e,t=>t&&t.nodeType!==Node.TEXT_NODE,t.editor)||t.editor,s=t.create.inside.span();t.editor.appendChild(s),no.forEach(t=>{i[t]=fe(s,t)}),s!==t.editor&&xe.safeRemove(s);const n=((t,e,i)=>{const o={};return e&&no.forEach(s=>{o[s]=ro(t,s,e,i),s.match(/border(Style|Color)/)&&!o.borderWidth&&(o[s]=void 0)}),o})(t,o,i),r=()=>{t.buffer.set("copyformat",!1);const e=t.selection.current();e&&("IMG"===e.nodeName?fe(e,n):t.selection.applyCSS(n)),t.events.off(t.editor,"mouseup.copyformat")};t.events.on(t.editor,"mouseup.copyformat",r),t.buffer.set("copyformat",!0)}},isActive:t=>!!t.buffer.get("copyformat"),tooltip:"Paint format"};var ao=ze.TabsWidget,lo=ze.ColorPickerWidget;function co(t){const e=(e,i,o)=>{const s=ee(o);switch(e){case"background":t.selection.applyCSS({backgroundColor:s||""});break;case"forecolor":t.selection.applyCSS({color:s||""})}return t.setEditorValue(),!1};t.registerCommand("forecolor",e).registerCommand("background",e)}qe.prototype.controls.brush={isActive(t,e,i){if(!i)return!0;const o=t.selection.current(),s=i.container.querySelector("svg");if(s&&s.style.fill&&s.style.removeProperty("fill"),o&&!i.isDisable()){const e=xe.closest(o,e=>xe.isBlock(e,t.editorWindow)||e&&xe.isNode(e,t.editorWindow)&&e.nodeType===Node.ELEMENT_NODE,t.editor)||t.editor,i=""+fe(e,"color"),n=""+fe(e,"background-color");if(i!==""+fe(t.editor,"color"))return s&&(s.style.fill=i),!0;if(n!==""+fe(t.editor,"background-color"))return s&&(s.style.fill=n),!0}return!1},popup(t,e,i,o){let s,n="",r="",a=null;e&&e!==t.editor&&xe.isNode(e,t.editorWindow)&&e.nodeType===Node.ELEMENT_NODE&&(n=""+fe(e,"color"),r=""+fe(e,"background-color"),a=e);const l=lo(t,e=>{a?a.style.backgroundColor=e:t.execCommand("background",!1,e),o()},r),d=lo(t,e=>{a?a.style.color=e:t.execCommand("forecolor",!1,e),o()},n);return s="background"===t.options.colorPickerDefaultTab?{Background:l,Text:d}:{Text:d,Background:l},ao(t,s,a)},tooltip:"Fill color or set the text color"};class ho extends oo{constructor(){super(...arguments),this.isFragmentFromEditor=!1,this.isCopyMode=!1,this.startDragPoint={x:0,y:0},this.draggable=null,this.bufferRange=null,this.onDragEnd=()=>{this.draggable&&(xe.safeRemove(this.draggable),this.draggable=null),this.isCopyMode=!1},this.onDrag=t=>{this.draggable&&(this.draggable.parentNode||this.jodit.ownerDocument.body.appendChild(this.draggable),this.jodit.events.fire("hidePopup"),fe(this.draggable,{left:t.clientX+20,top:t.clientY+20}),this.jodit.selection.insertCursorAtPoint(t.clientX,t.clientY),t.preventDefault(),t.stopPropagation())},this.onDrop=t=>{if(!t.dataTransfer||!t.dataTransfer.files||!t.dataTransfer.files.length){if(!this.isFragmentFromEditor&&!this.draggable)return this.jodit.events.fire("paste",t),t.preventDefault(),t.stopPropagation(),!1;const e=this.jodit.selection.sel,i=this.bufferRange||(e&&e.rangeCount?e.getRangeAt(0):null);let o=null;if(!this.draggable&&i)o=this.isCopyMode?i.cloneContents():i.extractContents();else if(this.draggable)if(this.isCopyMode){const[t,e]="1"===this.draggable.getAttribute("data-is-file")?["a","href"]:["img","src"];o=this.jodit.editorDocument.createElement(t),o.setAttribute(e,this.draggable.getAttribute("data-src")||this.draggable.getAttribute("src")||""),"a"===t&&(o.textContent=o.getAttribute(e)||"")}else o=ve(this.draggable,"target");else this.getText(t)&&(o=this.jodit.create.inside.fromHTML(this.getText(t)));e&&e.removeAllRanges(),this.jodit.selection.insertCursorAtPoint(t.clientX,t.clientY),o&&(this.jodit.selection.insertNode(o,!1,!1),i&&o.firstChild&&o.lastChild&&(i.setStartBefore(o.firstChild),i.setEndAfter(o.lastChild),this.jodit.selection.selectRange(i),this.jodit.events.fire("synchro")),"IMG"===o.nodeName&&this.jodit.events&&this.jodit.events.fire("afterInsertImage",o)),t.preventDefault(),t.stopPropagation()}this.isFragmentFromEditor=!1},this.onDragStart=t=>{let e=t.target;if(this.onDragEnd(),this.isFragmentFromEditor=xe.isOrContains(this.jodit.editor,e,!0),this.isCopyMode=!this.isFragmentFromEditor||ge(t),this.isFragmentFromEditor){const t=this.jodit.selection.sel,e=t&&t.rangeCount?t.getRangeAt(0):null;e&&(this.bufferRange=e.cloneRange())}else this.bufferRange=null;this.startDragPoint.x=t.clientX,this.startDragPoint.y=t.clientY,e.nodeType===Node.ELEMENT_NODE&&e.matches(".jodit_filebrowser_files_item")&&(e=e.querySelector("img")),"IMG"===e.nodeName&&(this.draggable=e.cloneNode(!0),ve(this.draggable,"target",e),fe(this.draggable,{"z-index":1e14,"pointer-events":"none",position:"fixed",display:"inlin-block",left:this.startDragPoint.x,top:this.startDragPoint.y,width:e.offsetWidth,height:e.offsetHeight}))},this.getDataTransfer=t=>t.dataTransfer||new DataTransfer,this.getText=t=>{const e=this.getDataTransfer(t);return e.getData($)||e.getData(V)}}afterInit(){this.jodit.events.on(window,"dragover",this.onDrag).on([window,this.jodit.editorDocument,this.jodit.editor],"dragstart",this.onDragStart).on("drop",this.onDrop).on(window,"dragend drop mouseup",this.onDragEnd)}beforeDestruct(){this.onDragEnd()}}qe.prototype.draggableTags=["img","a","jodit-media","jodit"];class po extends oo{constructor(){super(...arguments),this.dragList=[],this.isCopyMode=!1,this.draggable=null,this.wasMoved=!1,this.timeout=0,this.onDrag=at(t=>{this.draggable&&(this.wasMoved=!0,this.jodit.events.fire("hidePopup hideResizer"),this.draggable.parentNode||this.jodit.ownerDocument.body.appendChild(this.draggable),fe(this.draggable,{left:t.clientX+20,top:t.clientY+20}),this.jodit.selection.insertCursorAtPoint(t.clientX,t.clientY))},this.jodit.defaultTimeout),this.onDragStart=t=>{let e=t.target,i=null;if(this.dragList.length){do{-1!==this.dragList.indexOf(e.nodeName.toLowerCase())&&(!i||e.firstChild===i&&e.lastChild===i)&&(i=e),e=e.parentNode}while(e&&e!==this.jodit.editor);i&&(this.isCopyMode=ge(t),this.onDragEnd(),this.timeout=nt(e=>{e&&(this.draggable=e.cloneNode(!0),ve(this.draggable,"target",e),fe(this.draggable,{"z-index":1e14,"pointer-events":"none",position:"fixed",display:"inlin-block",left:t.clientX,top:t.clientY,width:e.offsetWidth,height:e.offsetHeight}))},this.jodit.defaultTimeout,i),t.preventDefault())}},this.onDragEnd=()=>{window.clearTimeout(this.timeout),this.draggable&&(xe.safeRemove(this.draggable),this.draggable=null,this.wasMoved=!1)},this.onDrop=()=>{if(!this.draggable||!this.wasMoved)return void this.onDragEnd();let t=ve(this.draggable,"target");this.onDragEnd(),this.isCopyMode&&(t=t.cloneNode(!0)),this.jodit.selection.insertNode(t,!0,!1),"IMG"===t.nodeName&&this.jodit.events&&this.jodit.events.fire("afterInsertImage",t),this.jodit.events.fire("synchro")}}afterInit(){this.dragList=this.jodit.options.draggableTags?st(this.jodit.options.draggableTags).filter(t=>t).map(t=>t.toLowerCase()):[],this.dragList.length&&this.jodit.events.on(this.jodit.editor,"mousemove touchmove",this.onDrag).on(this.jodit.editor,"mousedown touchstart dragstart",this.onDragStart).on("mouseup touchend",this.onDrop).on(window,"mouseup touchend",this.onDragEnd)}beforeDestruct(){this.onDragEnd()}}const uo=(t,e,i,o)=>{const s=t.create.inside.element(i),n=t.create.inside.element("br");s.appendChild(n),o&&o.cssText&&s.setAttribute("style",o.cssText),t.selection.insertNode(s,!1,!1),t.selection.setCursorBefore(n);const r=t.editorDocument.createRange();return r.setStartBefore("br"!==i.toLowerCase()?n:s),r.collapse(!0),t.selection.selectRange(r),xe.safeRemove(e),ke(s,t.editor,t.editorDocument),t.events&&t.events.fire("synchro"),s};function fo(t){t.options.enterBlock||(t.options.enterBlock="br"===t.options.enter.toLowerCase()?B:t.options.enter.toLowerCase()),t.events.on("keydown",e=>{if(e.which===w){const i=t.events.fire("beforeEnter",e);if(void 0!==i)return i;t.selection.isCollapsed()||t.execCommand("Delete"),t.selection.focus();let o=t.selection.current(!1);const s=t.selection.sel;let n=t.selection.range;o&&o!==t.editor||(t.selection.current(),o=t.create.inside.text(l),s&&s.rangeCount?n.insertNode(o):t.editor.appendChild(o),n.selectNode(o),n.collapse(!1),s&&(s.removeAllRanges(),s.addRange(n)));let r=!!o&&xe.up(o,e=>xe.isBlock(e,t.editorWindow),t.editor);const a=r&&"LI"===r.nodeName;if(!a&&(t.options.enter.toLowerCase()===R.toLowerCase()||e.shiftKey||xe.closest(o,"PRE|BLOCKQUOTE",t.editor))){const e=t.create.inside.element("br");return t.selection.insertNode(e,!0),ke(e,t.editor,t.editorDocument),!1}if(!r&&o&&!xe.prev(o,e=>xe.isBlock(e,t.editorWindow)||!!e&&xe.isImage(e,t.editorWindow),t.editor)){let e=o;if(xe.up(e,i=>{i&&i.hasChildNodes()&&i!==t.editor&&(e=i)},t.editor),r=xe.wrapInline(e,t.options.enter,t),xe.isEmpty(r)){const e=t.editorDocument.createElement("br");r.appendChild(e),t.selection.setCursorBefore(e)}n=s&&s.rangeCount?s.getRangeAt(0):t.editorDocument.createRange()}let d=!1,c=!1;if(r){if(!xe.canSplitBlock(r,t.editorWindow)){const e=t.create.inside.element("br");return t.selection.insertNode(e,!1),t.selection.setCursorAfter(e),!1}if(a&&xe.isEmpty(r)){let e=!1;const i=xe.closest(r,"ol|ul",t.editor);if(xe.prev(r,t=>t&&"LI"===t.nodeName,i))if(xe.next(r,t=>t&&"LI"===t.nodeName,i)){const o=t.editorDocument.createRange();o.setStartBefore(i),o.setEndAfter(r);const s=o.extractContents();i.parentNode&&i.parentNode.insertBefore(s,i),e=t.selection.setCursorBefore(i)}else e=t.selection.setCursorAfter(i);else e=t.selection.setCursorBefore(i);return xe.safeRemove(r),uo(t,e,t.options.enter),Mt("li",i).length||xe.safeRemove(i),!1}if(t.selection.cursorInTheEdge(!0,r))return d=t.selection.setCursorBefore(r),uo(t,d,a?"li":t.options.enter,r.style),r&&t.selection.setCursorIn(r,!0),!1;if(!1===t.selection.cursorInTheEdge(!1,r)){const e=t.editorDocument.createRange();e.setStartBefore(r),e.setEnd(n.startContainer,n.startOffset);const i=e.extractContents();r.parentNode&&r.parentNode.insertBefore(i,r),t.selection.setCursorIn(r,!0)}else d=t.selection.setCursorAfter(r)}else c=!0;return(c||d)&&uo(t,d,a?"li":t.options.enter,r?r.style:void 0),!1}})}function mo(t){if(t.options.showMessageErrors){let e;const i=t.create.div("jodit_error_box_for_messages"),o=()=>{e=5,Array.from(i.childNodes).forEach(o=>{fe(i,"bottom",e+"px"),e+=o.offsetWidth+t.options.showMessageErrorOffsetPx})};t.workplace.appendChild(i),t.events.on("beforeDestruct",()=>{xe.safeRemove(i)}).on("errorMessage",(e,s,n)=>{const r=t.create.div("active "+(s||""),e);i.appendChild(r),o(),nt(()=>{r.classList.remove("active"),nt(()=>{xe.safeRemove(r),o()},300)},n||t.options.showMessageErrorTime)})}}function go(t){const e=(e,i,o)=>{switch(e){case"fontsize":t.selection.applyCSS({fontSize:Zt(o)});break;case"fontname":t.selection.applyCSS({fontFamily:o})}return t.events.fire("synchro"),!1};t.registerCommand("fontsize",e).registerCommand("fontname",e)}function vo(t){t.registerCommand("formatblock",(e,i,o)=>{t.selection.focus();let s=!1;if(t.selection.eachSelection(e=>{const i=t.selection.save();let n=!!e&&xe.up(e,e=>xe.isBlock(e,t.editorWindow),t.editor);n&&"LI"!==n.nodeName||!e||(n=xe.wrapInline(e,t.options.enter,t)),n?(n.tagName.match(/TD|TH|TBODY|TABLE|THEAD/i)?t.selection.isCollapsed()?xe.wrapInline(e,o,t):t.selection.applyCSS({},o):o===t.options.enterBlock.toLowerCase()&&n.parentNode&&"LI"===n.parentNode.nodeName?xe.unwrap(n):xe.replace(n,o,!0,!1,t.editorDocument),s=!0,t.selection.restore(i)):t.selection.restore(i)}),!s){const e=t.editorDocument.createElement(o);e.innerHTML=l,t.selection.insertNode(e,!1),t.selection.setCursorIn(e)}return t.setEditorValue(),!1})}function bo(t){let e=!1,i=0,o=0,s=!1;const n=()=>{t.events&&(e?(i=fe(t.container,"height"),o=fe(t.container,"width"),fe(t.container,{height:t.ownerWindow.innerHeight,width:t.ownerWindow.innerWidth}),s=!0):s&&fe(t.container,{height:i||"auto",width:o||"auto"}))},r=i=>{var o,s;if(t.container){if(void 0===i&&(i=!t.container.classList.contains("jodit_fullsize")),t.options.fullsize=i,e=i,t.container.classList.toggle("jodit_fullsize",i),t.toolbar&&(i?null===(s=t.container.querySelector(".jodit_toolbar_container"))||void 0===s||s.appendChild(t.toolbar.container):null===(o=t.toolbar.getParentContainer())||void 0===o||o.appendChild(t.toolbar.container),fe(t.toolbar.container,"width","auto")),t.options.globalFullsize){let e=t.container.parentNode;for(;e&&e.nodeType!==Node.DOCUMENT_NODE;)e.classList.toggle("jodit_fullsize_box",i),e=e.parentNode;n()}t.events.fire("afterResize")}};t.options.globalFullsize&&t.events.on(t.ownerWindow,"resize",n),t.events.on("afterInit afterOpen",()=>{var e,i;t.toggleFullSize(null===(i=null===(e=t)||void 0===e?void 0:e.options)||void 0===i?void 0:i.fullsize)}).on("toggleFullSize",r).on("beforeDestruct beforeClose",()=>{r(!1)}).on("beforeDestruct",()=>{t.events&&t.events.off(t.ownerWindow,"resize",n)})}qe.prototype.showMessageErrors=!0,qe.prototype.showMessageErrorTime=3e3,qe.prototype.showMessageErrorOffsetPx=3,qe.prototype.controls.fontsize={command:"fontSize",list:["8","9","10","11","12","14","16","18","24","30","36","48","60","72","96"],template:(t,e,i)=>i,tooltip:"Font size",isActiveChild(t,e){const i=t.selection.current();if(i){const o=xe.closest(i,e=>xe.isBlock(e,t.editorWindow)||e&&xe.isNode(e,t.editorWindow)&&e.nodeType===Node.ELEMENT_NODE,t.editor)||t.editor,s=fe(o,"font-size");return!(!s||!e.args||""+e.args[1]!=""+s)}return!1},isActive(t){const e=t.selection.current();if(e){const i=xe.closest(e,e=>xe.isBlock(e,t.editorWindow)||e&&xe.isNode(e,t.editorWindow)&&e.nodeType===Node.ELEMENT_NODE,t.editor)||t.editor;return""+fe(i,"font-size")!=""+fe(t.editor,"font-size")}return!1}},qe.prototype.controls.font={command:"fontname",exec(t,e,i){t.execCommand(i.command,!1,i.args?i.args[0]:void 0)},list:{"Helvetica,sans-serif":"Helvetica","Arial,Helvetica,sans-serif":"Arial","Georgia,serif":"Georgia","Impact,Charcoal,sans-serif":"Impact","Tahoma,Geneva,sans-serif":"Tahoma","'Times New Roman',Times,serif":"Times New Roman","Verdana,Geneva,sans-serif":"Verdana"},template:(t,e,i)=>`${i}`,isActiveChild(t,e){const i=t.selection.current(),o=t=>t.toLowerCase().replace(/['"]+/g,"").replace(/[^a-z0-9]+/g,",");if(i){const s=xe.closest(i,e=>xe.isBlock(e,t.editorWindow)||e&&xe.isNode(e,t.editorWindow)&&e.nodeType===Node.ELEMENT_NODE,t.editor)||t.editor,n=""+fe(s,"font-family");return!(!n||!e.args||o(""+e.args[0])!==o(n))}return!1},isActive(t){const e=t.selection.current();if(e){const i=xe.closest(e,e=>xe.isBlock(e,t.editorWindow)||xe.isNode(e,t.editorWindow)&&e&&e.nodeType===Node.ELEMENT_NODE,t.editor)||t.editor;return""+fe(i,"font-family")!=""+fe(t.editor,"font-family")}return!1},tooltip:"Font family"},qe.prototype.controls.paragraph={command:"formatBlock",getLabel(t,e,i){const o=t.selection.current();if(o&&t.options.textIcons){const s=(xe.closest(o,e=>xe.isBlock(e,t.editorWindow),t.editor)||t.editor).nodeName.toLowerCase(),n=e.list;i&&e.data&&e.data.currentValue!==s&&e.list&&n[s]&&(i.textBox.innerHTML=`${t.i18n(n[s])}`,i.textBox.firstChild.classList.add("jodit_icon"),e.data.currentValue=s)}return!1},exec(t,e,i){t.execCommand(i.command,!1,i.args?i.args[0]:void 0)},data:{currentValue:"left"},list:{p:"Normal",h1:"Heading 1",h2:"Heading 2",h3:"Heading 3",h4:"Heading 4",blockquote:"Quote"},isActiveChild(t,e){const i=t.selection.current();if(i){const o=xe.closest(i,e=>xe.isBlock(e,t.editorWindow),t.editor);return o&&o!==t.editor&&void 0!==e.args&&o.nodeName.toLowerCase()===e.args[0]}return!1},isActive(t,e){const i=t.selection.current();if(i){const o=xe.closest(i,e=>xe.isBlock(e,t.editorWindow),t.editor);return o&&o!==t.editor&&void 0!==e.list&&"p"!==o.nodeName.toLowerCase()&&void 0!==e.list[o.nodeName.toLowerCase()]}return!1},template:(t,e,i)=>"<"+e+' class="jodit_list_element">'+t.i18n(i)+"",tooltip:"Insert format block"},qe.prototype.fullsize=!1,qe.prototype.globalFullsize=!0,qe.prototype.controls.fullsize={exec(t){t.toggleFullSize()},isActive:t=>t.isFullSize(),getLabel(t,e,i){const o=t.isFullSize()?"shrink":"fullsize";i&&(i.textBox.innerHTML=t.options.textIcons?`${t.i18n(o)}`:Ce.getIcon(o),i.textBox.firstChild.classList.add("jodit_icon"))},tooltip:"Open editor in fullsize",mode:H+P},qe.prototype.commandToHotkeys={removeFormat:["ctrl+shift+m","cmd+shift+m"],insertOrderedList:["ctrl+shift+7","cmd+shift+7"],insertUnorderedList:["ctrl+shift+8, cmd+shift+8"],selectall:["ctrl+a","cmd+a"]};class yo extends oo{constructor(){super(...arguments),this.onKeyPress=t=>{const e=this.specialKeys[t.which],i=(t.key||String.fromCharCode(t.which)).toLowerCase(),o=[e||i];return["alt","ctrl","shift","meta"].forEach(i=>{t[i+"Key"]&&e!==i&&o.push(i)}),Kt(o.join("+"))},this.specialKeys={8:"backspace",9:"tab",10:"return",13:"return",16:"shift",17:"ctrl",18:"alt",19:"pause",20:"capslock",27:"esc",32:"space",33:"pageup",34:"pagedown",35:"end",36:"home",37:"left",38:"up",39:"right",40:"down",45:"insert",46:"del",59:";",61:"=",91:"meta",96:"0",97:"1",98:"2",99:"3",100:"4",101:"5",102:"6",103:"7",104:"8",105:"9",106:"*",107:"+",109:"-",110:".",111:"/",112:"f1",113:"f2",114:"f3",115:"f4",116:"f5",117:"f6",118:"f7",119:"f8",120:"f9",121:"f10",122:"f11",123:"f12",144:"numlock",145:"scroll",173:"-",186:";",187:"=",188:",",189:"-",190:".",191:"/",192:"`",219:"[",220:"\\",221:"]",222:"'"}}afterInit(t){Object.keys(t.options.commandToHotkeys).forEach(e=>{const i=t.options.commandToHotkeys[e];i&&t.registerHotkeyToCommand(i,e)});let e=!1;t.events.on("keydown.hotkeys",i=>{const o=this.onKeyPress(i);if(!1===this.jodit.events.fire(o+".hotkey",i.type))return e=!0,t.events.stopPropagation("keydown"),!1},void 0,void 0,!0).on("keyup.hotkeys",()=>{if(e)return e=!1,t.events.stopPropagation("keyup"),!1},void 0,void 0,!0)}beforeDestruct(t){t.events&&t.events.off(".hotkeys")}}function wo(t){t.events.on("afterSetMode",()=>{t.isEditorMode()&&t.selection.focus()}).on("generateDocumentStructure.iframe",(t,e)=>{const i=t||e.iframe.contentWindow.document;if(i.open(),i.write('Jodit Editor'+(e.options.iframeBaseUrl?'':"")+''),i.close(),e.options.iframeCSSLinks&&e.options.iframeCSSLinks.forEach(t=>{const e=i.createElement("link");e.setAttribute("rel","stylesheet"),e.setAttribute("href",t),i.head&&i.head.appendChild(e)}),e.options.iframeStyle){const t=i.createElement("style");t.innerHTML=e.options.iframeStyle,i.head&&i.head.appendChild(t)}}).on("createEditor",async()=>{if(!t.options.iframe)return;delete t.editor;const e=t.create.element("iframe");e.style.display="block",e.src="about:blank",e.className="jodit_wysiwyg_iframe",e.setAttribute("allowtransparency","true"),e.setAttribute("tabindex",""+t.options.tabIndex),e.setAttribute("frameborder","0"),t.workplace.appendChild(e),t.iframe=e,await t.events.fire("generateDocumentStructure.iframe",null,t);const i=t.iframe.contentWindow.document;if(t.editorDocument=i,t.editorWindow=t.iframe.contentWindow,t.create.inside.setDocument(i),t.editor=i.body,"auto"===t.options.height){i.documentElement&&(i.documentElement.style.overflowY="hidden");const e=at(()=>{t.editor&&t.iframe&&"auto"===t.options.height&&fe(t.iframe,"height",t.editor.offsetHeight)},t.defaultTimeout/2);t.events.on("change afterInit afterSetMode resize",e).on([t.iframe,t.editorWindow,i.documentElement],"load",e).on(i,"readystatechange DOMContentLoaded",e)}return(t=>{t.matches||(t.matches=Element.prototype.matches)})(t.editorWindow.Element.prototype),t.editorDocument.documentElement&&t.events.on(t.editorDocument.documentElement,"mousedown touchend",()=>{t.selection.isFocused()||(t.selection.focus(),t.selection.setCursorIn(t.editor))}).on(t.editorWindow,"mousedown touchstart keydown keyup touchend click mouseup mousemove scroll",e=>{t.events&&t.events.fire&&t.events.fire(t.ownerWindow,e)}),!1})}qe.prototype.iframeBaseUrl="",qe.prototype.iframeDefaultSrc="about:blank",qe.prototype.iframeStyle='html{margin: 0px;min-height: 100%;}body{box-sizing: border-box;font-size: 13px; line-height: 1.6;padding:10px;background:transparent;color:#000;position:relative;z-index: 2;user-select:auto;margin:0px;overflow:auto;}table{width:100%;border: none;border-collapse:collapse;empty-cells: show;max-width: 100%;}th,td{padding: 2px 5px;border:1px solid #ccc;-webkit-user-select:text;-moz-user-select:text;-ms-user-select:text;user-select:text}td[data-jodit-selected-cell],th[data-jodit-selected-cell]{border: 1px double #1e88e5}p{margin-top:0;}.jodit_editor .jodit_iframe_wrapper{display: block;clear: both;user-select: none;position: relative;}.jodit_editor .jodit_iframe_wrapper:after {position:absolute;content:"";z-index:1;top:0;left:0;right: 0;bottom: 0;cursor: pointer;display: block;background: rgba(0, 0, 0, 0);} .jodit_disabled{user-select: none;-o-user-select: none;-moz-user-select: none;-khtml-user-select: none;-webkit-user-select: none;-ms-user-select: none}',qe.prototype.iframeCSSLinks=[];const _o="__jodit_imageprocessor_binded";function ko(t){t.events.on("change afterInit",rt(()=>{t.editor&&Mt("img",t.editor).forEach(e=>{e[_o]||(e[_o]=!0,e.complete||e.addEventListener("load",(function i(){t.events&&t.events.fire&&t.events.fire("resize"),e.removeEventListener("load",i)})),t.events.on(e,"mousedown touchstart",()=>{t.selection.select(e)}))})},t.defaultTimeout))}var jo=ze.TabsWidget,xo=ze.FileSelectorWidget;function Co(t){const e=t.i18n,i=Ce.getIcon.bind(Ce),o=t.options,s=t.create.fromHTML.bind(t.create),n=function(n){if(o.readonly)return;n&&n.stopImmediatePropagation();const r=this,a=new Xo(t),l={check:s(`${i("check")}${e("Ok")}`),cancel:s(`${i("cancel")}${e("Cancel")}`),remove:s(`${i("bin")}${e("Delete")}`)},d=s(`
\n\t\t\t\t\t\t\t\t
\n\t\t\t\t\t\t\t\t\t
\n\t\t\t\t\t\t\t\t\t\t
\n\t\t\t\t\t\t\t\t\t\t\t
\n\t\t\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\t\t
\n\t\t\t\t\t\t\t\t\t\t\t
\n\t\t\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\t\t\t${i("lock")}\n\t\t\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\t\t
\n\t\t\t\t\t\t\t\t\t\t
\n\t\t\t\t\t\t\t\t\t
\n\t\t\t\t\t\t\t\t\t
\n\t\t\t\t\t\t\t\t
\n\t\t\t\t\t\t\t
`),c=s(`
\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t
\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t${i("lock")}\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t
\n\t\t\t\t\t\t\t
\n\t\t\t\t\t\t\t
\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t
\n\t\t\t\t\t\t\t
\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t
\n\t\t\t\t\t\t\t
\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t
\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t`),h=o.filebrowser.ajax.url||o.uploader.url,p=o.image.useImageEditor,u=s(`
\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t
\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\t\t${i("image")}\n\t\t\t\t\t\t\t\t\t\t\t${i("crop")}\n\t\t\t\t\t\t\t\t\t
\n\t\t\t\t\t\t\t\t
\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t
\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t
\n\t\t\t\t\t\t\t
\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t
\n\t\t\t\t\t\t\t
\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t
\n\t\t\t\t\t\t\t
\n\t\t\t\t\t\t\t\t
\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t${e("Open link in new tab")}\n\t\t\t\t\t\t\t\t
\n\t\t\t\t\t\t\t
`),f=r.naturalWidth/r.naturalHeight||1,m=d.querySelector(".imageWidth"),g=d.querySelector(".imageHeight"),v=()=>{je(d,".imageSrc",r.getAttribute("src")||"");const t=d.querySelector(".imageViewSrc");t&&t.setAttribute("src",r.getAttribute("src")||"")},b=()=>{v(),(()=>{r.hasAttribute("title")&&je(d,".imageTitle",r.getAttribute("title")||""),r.hasAttribute("alt")&&je(d,".imageAlt",r.getAttribute("alt")||"");const e=xe.closest(r,"a",t.editor);e&&(je(d,".imageLink",e.getAttribute("href")||""),d.querySelector(".imageLinkOpenInNewTab").checked="_blank"===e.getAttribute("target"))})(),m.value=""+r.offsetWidth,g.value=""+r.offsetHeight,(()=>{if(!o.image.editMargins)return;let t=!1;Mt(".margins",d).forEach(e=>{const i=e.getAttribute("data-id")||"";let o=r.style[i];o&&(/^[0-9]+(px)?$/.test(o)&&(o=parseInt(o,10)),e.value=""+o||"",t||"marginTop"===i||e.value===je(d,".marginTop")||(t=!0))}),_=!t;const e=d.querySelector(".jodit_lock_margin");e&&(e.innerHTML=i(_?"lock":"unlock")),Mt(".margins:not(.marginTop)",d).forEach(t=>_?t.setAttribute("disabled","true"):t.removeAttribute("disabled"))})(),je(d,".classes",(r.getAttribute("class")||"").replace(/jodit_focused_image[\s]*/,"")),je(d,".id",r.getAttribute("id")||""),je(d,".border_radius",""+(parseInt(r.style.borderRadius||"0",10)||"0")),r.style.cssFloat&&-1!==["left","right"].indexOf(r.style.cssFloat.toLowerCase())?je(d,".align",fe(r,"float")):"block"===fe(r,"display")&&"auto"===r.style.marginLeft&&"auto"===r.style.marginRight&&je(d,".align","center"),je(d,".style",r.getAttribute("style")||"")};let y,w=!0,_=!0;const k={},j=d.querySelector(".tabsbox");k.Image=u,k.Advanced=c,j&&j.appendChild(jo(t,k)),b(),t.events.on(a,"afterClose",()=>{a.destruct(),r.parentNode&&o.image.selectImageAfterClose&&t.selection.select(r)}),l.remove.addEventListener("click",()=>{xe.safeRemove(r),a.close()}),o.image.useImageEditor&&Mt(".jodit_use_image_editor",u).forEach(i=>{t.events.on(i,"mousedown touchstart",()=>{const i=r.getAttribute("src")||"",o=t.create.element("a"),s=()=>{o.host===location.host||Jo(e("You can only edit your own images. Download this image on the host?"),i=>{i&&t.uploader&&t.uploader.uploadRemoteImage(""+o.href,t=>{Yo(e("The image has been successfully uploaded to the host!"),()=>{"string"==typeof t.newfilename&&(r.setAttribute("src",t.baseurl+t.newfilename),v())})},t=>{Yo(e("There was an error loading %s",t.message))})})};o.href=i,t.getInstance("FileBrowser").dataProvider.getPathByUrl(""+o.href,(e,s,n)=>{t.getInstance("FileBrowser").openImageEditor(o.href,s,e,n,()=>{const t=(new Date).getTime();r.setAttribute("src",i+(-1!==i.indexOf("?")?"":"?")+"&_tmp="+t),v()},t=>{Yo(t.message)})},t=>{Yo(t.message,s)})})}),Mt(".jodit_rechange",u).forEach(e=>{e.addEventListener("mousedown",i=>{e.classList.toggle("active");const o=new Ze(t,e);o.open(xo(t,{upload(t){t.files&&t.files.length&&r.setAttribute("src",t.baseurl+t.files[0]),b(),o.close()},filebrowser(t){t&&t.files&&Array.isArray(t.files)&&t.files.length&&(r.setAttribute("src",t.files[0]),o.close(),b())}},r,o.close),!0),i.stopPropagation()})});const x=d.querySelector(".jodit_lock_helper.jodit_lock_size"),C=d.querySelector(".jodit_lock_helper.jodit_lock_margin");x&&x.addEventListener("click",(function(){w=!w,this.innerHTML=i(w?"lock":"unlock"),t.events.fire(m,"change")})),C&&C.addEventListener("click",(function(){_=!_,this.innerHTML=i(_?"lock":"unlock"),_?Mt(".margins",d).forEach(t=>{t.matches(".marginTop")||t.setAttribute("disabled","true")}):Mt(".margins",d).forEach(t=>{t.matches(".marginTop")||t.removeAttribute("disabled")})}));const z=t=>{const e=parseInt(m.value,10),i=parseInt(g.value,10);t.target===m?g.value=""+Math.round(e/f):m.value=""+Math.round(i*f)};return t.events.on([m,g],"change keydown mousedown paste",e=>{w&&(t.defaultTimeout?(clearTimeout(y),y=nt(z.bind(this,e),t.defaultTimeout)):z(e))}),a.setTitle(e("Image properties")),a.setContent(d),l.check.addEventListener("click",()=>{if(o.image.editStyle&&(je(d,".style")?r.setAttribute("style",je(d,".style")):r.removeAttribute("style")),!je(d,".imageSrc"))return xe.safeRemove(r),void a.close();r.setAttribute("src",je(d,".imageSrc")),r.style.borderRadius="0"!==je(d,".border_radius")&&/^[0-9]+$/.test(je(d,".border_radius"))?je(d,".border_radius")+"px":"",je(d,".imageTitle")?r.setAttribute("title",je(d,".imageTitle")):r.removeAttribute("title"),je(d,".imageAlt")?r.setAttribute("alt",je(d,".imageAlt")):r.removeAttribute("alt");let e=xe.closest(r,"a",t.editor);je(d,".imageLink")?(e||(e=xe.wrap(r,"a",t)),e.setAttribute("href",je(d,".imageLink")),d.querySelector(".imageLinkOpenInNewTab").checked?e.setAttribute("target","_blank"):e.removeAttribute("target")):e&&e.parentNode&&e.parentNode.replaceChild(r,e);const i=t=>(t=Bt(t),/^[0-9]+$/.test(t)?t+"px":t);m.value===""+r.offsetWidth&&g.value===""+r.offsetHeight||fe(r,{width:Bt(m.value)?i(m.value):null,height:Bt(g.value)?i(g.value):null}),o.image.editMargins&&(_?fe(r,"margin",i(je(d,".marginTop"))):Mt(".margins",d).forEach(t=>{const e=t.getAttribute("data-id")||"";fe(r,e,i(t.value))})),o.image.editClass&&(je(d,".classes")?r.setAttribute("class",je(d,".classes")):r.removeAttribute("class")),o.image.editId&&(je(d,".id")?r.setAttribute("id",je(d,".id")):r.removeAttribute("id")),o.image.editAlign&&(je(d,".align")?-1!==["right","left"].indexOf(je(d,".align").toLowerCase())?(fe(r,"float",je(d,".align")),me(r)):(fe(r,"float",""),fe(r,{display:"block","margin-left":"auto","margin-right":"auto"})):(fe(r,"float")&&-1!==["right","left"].indexOf((""+fe(r,"float")).toLowerCase())&&fe(r,"float",""),me(r))),r.getAttribute("style")||r.removeAttribute("style"),t.setEditorValue(),a.close()}),l.cancel.addEventListener("click",()=>a.close()),a.setFooter([[l.cancel,l.remove],l.check]),a.setSize(500),a.open(),n&&n.preventDefault(),!1};t.events.on("afterInit",()=>{t.events.on(t.editor,"dblclick",o.image.openOnDblClick?n:function(e){e.stopImmediatePropagation(),t.selection.select(this)},"img")}).on("openImageProperties",t=>{n.call(t)})}function zo(t){const e=e=>{const i=[];return t.selection.eachSelection(o=>{const s=t.selection.save();let n=!!o&&xe.up(o,e=>xe.isBlock(e,t.editorWindow),t.editor);const r=t.options.enter;if(!n&&o&&(n=xe.wrapInline(o,r!==R?r:B,t)),!n)return t.selection.restore(s),!1;const a=-1!==i.indexOf(n);if(n&&n.style&&!a){i.push(n);let o=n.style.marginLeft?parseInt(n.style.marginLeft,10):0;o+=t.options.indentMargin*("outdent"===e?-1:1),n.style.marginLeft=o>0?o+"px":"",n.getAttribute("style")||n.removeAttribute("style")}t.selection.restore(s)}),t.setEditorValue(),!1};t.registerCommand("indent",{exec:e,hotkeys:["ctrl+]","cmd+]"]}),t.registerCommand("outdent",{exec:e,hotkeys:["ctrl+[","cmd+["]})}qe.prototype.image={openOnDblClick:!0,editSrc:!0,useImageEditor:!0,editTitle:!0,editAlt:!0,editLink:!0,editSize:!0,editBorderRadius:!0,editMargins:!0,editClass:!0,editStyle:!0,editId:!0,editAlign:!0,showPreview:!0,selectImageAfterClose:!0},qe.prototype.controls.indent={tooltip:"Increase Indent"},qe.prototype.controls.outdent={isDisable(t){const e=t.selection.current();if(e){const i=xe.closest(e,e=>xe.isBlock(e,t.editorWindow),t.editor);if(i&&i.style&&i.style.marginLeft)return 0>=parseInt(i.style.marginLeft,10)}return!0},tooltip:"Decrease Indent"},qe.prototype.indentMargin=10;class Eo{static addSelected(t){t.setAttribute(X,"1")}static restoreSelection(t){t.removeAttribute(X)}static getAllSelectedCells(t){return t?Mt(`td[${X}],th[${X}]`,t):[]}static getRowsCount(t){return t.rows.length}static getColumnsCount(t){return Eo.formalMatrix(t).reduce((t,e)=>Math.max(t,e.length),0)}static formalMatrix(t,e){const i=[[]],o=Array.prototype.slice.call(t.rows),s=(t,o)=>{void 0===i[o]&&(i[o]=[]);const s=t.colSpan,n=t.rowSpan;let r,a,l=0;for(;i[o][l];)l+=1;for(a=0;n>a;a+=1)for(r=0;s>r;r+=1){if(void 0===i[o+a]&&(i[o+a]=[]),e&&!1===e(t,o+a,l+r,s,n))return!1;i[o+a][l+r]=t}};for(let t,e=0;o.length>e;e+=1){const n=Array.prototype.slice.call(o[e].cells);for(t=0;n.length>t;t+=1)if(!1===s(n[t],e))return i}return i}static formalCoordinate(t,e,i=!1){let o=0,s=0,n=1,r=1;return Eo.formalMatrix(t,(t,a,l,d,c)=>{if(e===t)return o=a,s=l,n=d||1,r=c||1,i&&(s+=(d||1)-1,o+=(c||1)-1),!1}),[o,s,n,r]}static appendRow(t,e=!1,i=!0){const o=t.ownerDocument||document,s=Eo.getColumnsCount(t),n=o.createElement("tr");for(let t=0;s>t;t+=1)n.appendChild(o.createElement("td"));i&&e&&e.nextSibling?e.parentNode&&e.parentNode.insertBefore(n,e.nextSibling):!i&&e?e.parentNode&&e.parentNode.insertBefore(n,e):(Mt(":scope>tbody",t)[0]||t).appendChild(n)}static removeRow(t,e){const i=Eo.formalMatrix(t);let o;const s=t.rows[e];be(i[e],(n,r)=>{if(o=!1,0>e-1||i[e-1][n]!==r)if(i[e+1]&&i[e+1][n]===r){if(r.parentNode===s&&r.parentNode.nextSibling){o=!0;let s=n+1;for(;i[e+1][s]===r;)s+=1;const a=xe.next(r.parentNode,t=>t&&t.nodeType===Node.ELEMENT_NODE&&"TR"===t.nodeName,t);i[e+1][s]?a.insertBefore(r,i[e+1][s]):a.appendChild(r)}}else xe.safeRemove(r);else o=!0;if(o&&(r.parentNode===s||r!==i[e][n-1])){const t=r.rowSpan;t-1>1?r.setAttribute("rowspan",""+(t-1)):r.removeAttribute("rowspan")}}),xe.safeRemove(s)}static appendColumn(t,e,i=!0){const o=Eo.formalMatrix(t);let s;for(void 0===e&&(e=Eo.getColumnsCount(t)-1),s=0;o.length>s;s+=1){const n=(t.ownerDocument||document).createElement("td"),r=o[s][e];let a=!1;i?(o[s]&&r&&e+1>=o[s].length||r!==o[s][e+1])&&(r.nextSibling?r.parentNode&&r.parentNode.insertBefore(n,r.nextSibling):r.parentNode&&r.parentNode.appendChild(n),a=!0):(0>e-1||o[s][e]!==o[s][e-1]&&o[s][e].parentNode)&&(r.parentNode&&r.parentNode.insertBefore(n,o[s][e]),a=!0),a||o[s][e].setAttribute("colspan",""+(parseInt(o[s][e].getAttribute("colspan")||"1",10)+1))}}static removeColumn(t,e){const i=Eo.formalMatrix(t);let o;be(i,(t,s)=>{const n=s[e];if(o=!1,0>e-1||i[t][e-1]!==n?s.length>e+1&&i[t][e+1]===n?o=!0:xe.safeRemove(n):o=!0,o&&(0>t-1||n!==i[t-1][e])){const t=n.colSpan;t-1>1?n.setAttribute("colspan",""+(t-1)):n.removeAttribute("colspan")}})}static getSelectedBound(t,e){const i=[[1/0,1/0],[0,0]],o=Eo.formalMatrix(t);let s,n,r;for(s=0;o.length>s;s+=1)for(n=0;o[s].length>n;n+=1)-1!==e.indexOf(o[s][n])&&(i[0][0]=Math.min(s,i[0][0]),i[0][1]=Math.min(n,i[0][1]),i[1][0]=Math.max(s,i[1][0]),i[1][1]=Math.max(n,i[1][1]));for(s=i[0][0];i[1][0]>=s;s+=1)for(r=1,n=i[0][1];i[1][1]>=n;n+=1){for(;o[s][n-r]&&o[s][n]===o[s][n-r];)i[0][1]=Math.min(n-r,i[0][1]),i[1][1]=Math.max(n-r,i[1][1]),r+=1;for(r=1;o[s][n+r]&&o[s][n]===o[s][n+r];)i[0][1]=Math.min(n+r,i[0][1]),i[1][1]=Math.max(n+r,i[1][1]),r+=1;for(r=1;o[s-r]&&o[s][n]===o[s-r][n];)i[0][0]=Math.min(s-r,i[0][0]),i[1][0]=Math.max(s-r,i[1][0]),r+=1;for(r=1;o[s+r]&&o[s][n]===o[s+r][n];)i[0][0]=Math.min(s+r,i[0][0]),i[1][0]=Math.max(s+r,i[1][0]),r+=1}return i}static normalizeTable(t){let e,i,o,s;const n=[],r=Eo.formalMatrix(t);for(i=0;r[0].length>i;i+=1){for(o=1e6,s=!1,e=0;r.length>e;e+=1)if(void 0!==r[e][i]){if(2>r[e][i].colSpan){s=!0;break}o=Math.min(o,r[e][i].colSpan)}if(!s)for(e=0;r.length>e;e+=1)void 0!==r[e][i]&&Eo.__mark(r[e][i],"colspan",r[e][i].colSpan-o+1,n)}for(e=0;r.length>e;e+=1){for(o=1e6,s=!1,i=0;r[e].length>i;i+=1)if(void 0!==r[e][i]){if(2>r[e][i].rowSpan){s=!0;break}o=Math.min(o,r[e][i].rowSpan)}if(!s)for(i=0;r[e].length>i;i+=1)void 0!==r[e][i]&&Eo.__mark(r[e][i],"rowspan",r[e][i].rowSpan-o+1,n)}for(e=0;r.length>e;e+=1)for(i=0;r[e].length>i;i+=1)void 0!==r[e][i]&&(r[e][i].hasAttribute("rowspan")&&1===r[e][i].rowSpan&&r[e][i].removeAttribute("rowspan"),r[e][i].hasAttribute("colspan")&&1===r[e][i].colSpan&&r[e][i].removeAttribute("colspan"),r[e][i].hasAttribute("class")&&!r[e][i].getAttribute("class")&&r[e][i].removeAttribute("class"));Eo.__unmark(n)}static mergeSelected(t){const e=[],i=Eo.getSelectedBound(t,Eo.getAllSelectedCells(t));let o,s=0,n=null,r=0,a=0,l=0;const d=[];i&&(i[0][0]-i[1][0]||i[0][1]-i[1][1])&&(Eo.formalMatrix(t,(t,c,h,p,u)=>{if(!(i[0][0]>c||c>i[1][0]||i[0][1]>h||h>i[1][1])){if(o=t,o.__i_am_already_was)return;o.__i_am_already_was=!0,c===i[0][0]&&o.style.width&&(s+=o.offsetWidth),""!==Bt(t.innerHTML.replace(//g,""))&&e.push(t.innerHTML),p>1&&(a+=p-1),u>1&&(l+=u-1),n?Eo.__mark(o,"remove",1,d):(n=t,r=h)}}),a=i[1][1]-i[0][1]+1,l=i[1][0]-i[0][0]+1,n&&(a>1&&Eo.__mark(n,"colspan",a,d),l>1&&Eo.__mark(n,"rowspan",l,d),s&&(Eo.__mark(n,"width",(s/t.offsetWidth*100).toFixed(I)+"%",d),r&&Eo.setColumnWidthByDelta(t,r,0,!0,d)),n.innerHTML=e.join("
"),delete n.__i_am_already_was,Eo.__unmark(d),Eo.normalizeTable(t),be(Array.from(t.rows),(t,e)=>{e.cells.length||xe.safeRemove(e)})))}static splitHorizontal(t){let e,i,o,s,n;const r=[],a=t.ownerDocument||document;Eo.getAllSelectedCells(t).forEach(l=>{i=a.createElement("td"),i.appendChild(a.createElement("br")),o=a.createElement("tr"),e=Eo.formalCoordinate(t,l),2>l.rowSpan?(Eo.formalMatrix(t,(t,i,o)=>{e[0]===i&&e[1]!==o&&t!==l&&Eo.__mark(t,"rowspan",t.rowSpan+1,r)}),xe.after(xe.closest(l,"tr",t),o),o.appendChild(i)):(Eo.__mark(l,"rowspan",l.rowSpan-1,r),Eo.formalMatrix(t,(i,o,r)=>{o>e[0]&&e[0]+l.rowSpan>o&&e[1]>r&&i.parentNode.rowIndex===o&&(n=i),o>e[0]&&i===l&&(s=t.rows[o])}),n?xe.after(n,i):s.insertBefore(i,s.firstChild)),l.colSpan>1&&Eo.__mark(i,"colspan",l.colSpan,r),Eo.__unmark(r),Eo.restoreSelection(l)}),this.normalizeTable(t)}static splitVertical(t){let e,i,o;const s=[],n=t.ownerDocument||document;Eo.getAllSelectedCells(t).forEach(r=>{e=Eo.formalCoordinate(t,r),2>r.colSpan?Eo.formalMatrix(t,(t,i,o)=>{e[1]===o&&e[0]!==i&&t!==r&&Eo.__mark(t,"colspan",t.colSpan+1,s)}):Eo.__mark(r,"colspan",r.colSpan-1,s),i=n.createElement("td"),i.appendChild(n.createElement("br")),r.rowSpan>1&&Eo.__mark(i,"rowspan",r.rowSpan,s);const a=r.offsetWidth;xe.after(r,i),o=a/t.offsetWidth/2,Eo.__mark(r,"width",(100*o).toFixed(I)+"%",s),Eo.__mark(i,"width",(100*o).toFixed(I)+"%",s),Eo.__unmark(s),Eo.restoreSelection(r)}),Eo.normalizeTable(t)}static setColumnWidthByDelta(t,e,i,o,s){const n=Eo.formalMatrix(t);let r,a,l;for(r=0;n.length>r;r+=1)a=n[r][e].offsetWidth,l=(a+i)/t.offsetWidth*100,Eo.__mark(n[r][e],"width",l.toFixed(I)+"%",s);o||Eo.__unmark(s)}static __mark(t,e,i,o){o.push(t),t.__marked_value||(t.__marked_value={}),t.__marked_value[e]=void 0===i?1:i}static __unmark(t){t.forEach(t=>{t.__marked_value&&(be(t.__marked_value,(e,i)=>{switch(e){case"remove":xe.safeRemove(t);break;case"rowspan":i>1?t.setAttribute("rowspan",""+i):t.removeAttribute("rowspan");break;case"colspan":i>1?t.setAttribute("colspan",""+i):t.removeAttribute("colspan");break;case"width":t.style.width=""+i}delete t.__marked_value[e]}),delete t.__marked_value)})}}var To=ze.ColorPickerWidget,So=ze.TabsWidget;qe.prototype.toolbarInline=!0,qe.prototype.toolbarInlineDisableFor=[],qe.prototype.popup={a:[{name:"eye",tooltip:"Open link",exec(t,e){const i=e.getAttribute("href");e&&i&&t.ownerWindow.open(i)}},{name:"link",tooltip:"Edit link",icon:"pencil"},"unlink","brush","file"],jodit:[{name:"bin",tooltip:"Delete",exec(t,e){e.parentNode&&(xe.safeRemove(e),t.events.fire("hidePopup"))}}],"jodit-media":[{name:"bin",tooltip:"Delete",exec(t,e){e.parentNode&&(xe.safeRemove(e),t.events.fire("hidePopup"))}}],img:[{name:"delete",icon:"bin",tooltip:"Delete",exec(t,e){e.parentNode&&(xe.safeRemove(e),t.events.fire("hidePopup"))}},{name:"pencil",exec(t,e){"img"===e.tagName.toLowerCase()&&t.events.fire("openImageProperties",e)},tooltip:"Edit"},{name:"valign",list:["Top","Middle","Bottom"],tooltip:"Vertical align",exec(t,e,i){if("img"!==e.tagName.toLowerCase())return;const o=i.args&&"string"==typeof i.args[1]?i.args[1].toLowerCase():"";fe(e,"vertical-align",o),t.events.fire("recalcPositionPopup")}},{name:"left",list:["Left","Right","Center","Normal"],exec(t,e,i){if("img"!==e.tagName.toLowerCase())return;const o=i.args&&"string"==typeof i.args[1]?i.args[1].toLowerCase():"";"normal"!==o?-1!==["right","left"].indexOf(o)?(fe(e,"float",o),me(e)):(fe(e,"float",""),fe(e,{display:"block","margin-left":"auto","margin-right":"auto"})):(fe(e,"float")&&-1!==["right","left"].indexOf(fe(e,"float").toLowerCase())&&fe(e,"float",""),me(e)),t.events.fire("recalcPositionPopup")},tooltip:"Horizontal align"}],table:[{name:"brush",popup(t,e){const i=Eo.getAllSelectedCells(e);let o,s,n,r,a,l,d;return!!i.length&&(a=fe(i[0],"color"),d=fe(i[0],"background-color"),l=fe(i[0],"border-color"),o=To(t,e=>{i.forEach(t=>{fe(t,"background-color",e)}),t.setEditorValue()},d),s=To(t,e=>{i.forEach(t=>{fe(t,"color",e)}),t.setEditorValue()},a),n=To(t,e=>{i.forEach(t=>{fe(t,"border-color",e)}),t.setEditorValue()},l),r=So(t,{Background:o,Text:s,Border:n}),r)},tooltip:"Background"},{name:"valign",list:["Top","Middle","Bottom"],exec(t,e,i){const o=i.args&&"string"==typeof i.args[1]?i.args[1].toLowerCase():"";Eo.getAllSelectedCells(e).forEach(t=>{fe(t,"vertical-align",o)})},tooltip:"Vertical align"},{name:"splitv",list:{tablesplitv:"Split vertical",tablesplitg:"Split horizontal"},tooltip:"Split"},{name:"align",icon:"left"},"\n",{name:"merge",command:"tablemerge",tooltip:"Merge"},{name:"addcolumn",list:{tableaddcolumnbefore:"Insert column before",tableaddcolumnafter:"Insert column after"},exec(t,e,i){const o=i.args&&"string"==typeof i.args[0]?i.args[0].toLowerCase():"";t.execCommand(o,!1,e)},tooltip:"Add column"},{name:"addrow",list:{tableaddrowbefore:"Insert row above",tableaddrowafter:"Insert row below"},exec(t,e,i){const o=i.args&&"string"==typeof i.args[0]?i.args[0].toLowerCase():"";t.execCommand(o,!1,e)},tooltip:"Add row"},{name:"delete",icon:"bin",list:{tablebin:"Delete table",tablebinrow:"Delete row",tablebincolumn:"Delete column",tableempty:"Empty cell"},exec(t,e,i){const o=i.args&&"string"==typeof i.args[0]?i.args[0].toLowerCase():"";t.execCommand(o,!1,e),t.events.fire("hidePopup")},tooltip:"Delete"}]};class qo extends oo{constructor(){super(...arguments),this._hiddenClass="jodit_toolbar_popup-inline-target-hidden",this.isSelectionStarted=!1,this.onSelectionEnd=rt(()=>{!this.isDestructed&&this.jodit.isEditorMode()&&(this.isSelectionStarted&&(this.isTargetAction||this.onChangeSelection()),this.isSelectionStarted=!1,this.isTargetAction=!1)},this.jodit.defaultTimeout),this.isTargetAction=!1,this.isSelectionPopup=!1,this.calcWindSizes=()=>{const t=this.jodit.ownerWindow,e=this.jodit.ownerDocument.documentElement;if(!e)return{left:0,top:0,width:0,height:0};const i=this.jodit.ownerDocument.body,o=e.clientTop||i.clientTop||0,s=e.clientLeft||i.clientLeft||0;return{left:s,top:o,width:e.clientWidth+(t.pageXOffset||e.scrollLeft||i.scrollLeft)-s,height:e.clientHeight+(t.pageYOffset||e.scrollTop||i.scrollTop)-o}},this.calcPosition=(t,e)=>{if(this.isDestructed)return;this.popup.target.classList.remove(this._hiddenClass);const i=t.left+t.width/2,o=se(this.jodit.workplace,this.jodit,this.jodit.ownerDocument,!0);let s=t.top+t.height+10;this.target.style.left=i+"px",this.target.style.top=s+"px",this.jodit.isFullSize()&&(this.target.style.zIndex=""+fe(this.jodit.container,"zIndex"));const n=this.container.offsetWidth/2;let r=-n;this.popup.container.classList.remove("jodit_toolbar_popup-inline-top"),s+this.container.offsetHeight>e.height&&(s=t.top-this.container.offsetHeight-10,this.target.style.top=s+"px",this.popup.container.classList.add("jodit_toolbar_popup-inline-top")),0>i-n&&(r=-(t.width/2+t.left)),i+n>e.width&&(r=-(this.container.offsetWidth-(e.width-i))),this.container.style.marginLeft=r+"px",(o.top-s>50||s-(o.top+o.height)>50)&&this.popup.target.classList.add(this._hiddenClass)},this.reCalcPosition=()=>{this.__getRect&&this.calcPosition(this.__getRect(),this.calcWindSizes())},this.showPopup=(t,e,i)=>{if(!this.jodit.options.toolbarInline||!this.jodit.options.popup[e.toLowerCase()])return!1;if(this.isExcludedTarget(e))return!0;this.isOpened=!0,this.isTargetAction=!0;const o=this.calcWindSizes();return this.targetContainer.parentNode||this.jodit.ownerDocument.body.appendChild(this.targetContainer),this.toolbar.build(this.jodit.options.popup[e.toLowerCase()],this.container,i),this.popup.open(this.container,!1,!0),this.__getRect=t,this.calcPosition(t(),o),!0},this.hidePopup=t=>{this.isDestructed||t&&(xe.isNode(t,this.jodit.editorWindow||window)||t instanceof Ze)&&xe.isOrContains(this.target,t instanceof Ze?t.target:t)||(this.isTargetAction=!1,this.isOpened=!1,this.popup.close(),xe.safeRemove(this.targetContainer))},this.onSelectionStart=t=>{if(!this.isDestructed&&this.jodit.isEditorMode()&&(this.isTargetAction=!1,this.isSelectionPopup=!1,!this.isSelectionStarted)){const e=Object.keys(this.jodit.options.popup).join("|"),i="IMG"===t.target.nodeName?t.target:xe.closest(t.target,e,this.jodit.editor);i&&this.showPopup(()=>se(i,this.jodit,this.jodit.editorDocument),i.nodeName,i)||(this.isSelectionStarted=!0)}},this.checkIsTargetEvent=()=>{this.isTargetAction?this.isTargetAction=!1:this.hidePopup()},this.isOpened=!1,this.onChangeSelection=()=>{if(this.jodit.options.toolbarInline&&this.jodit.isEditorMode()&&!this.hideIfCollapsed()&&void 0!==this.jodit.options.popup.selection){const t=this.jodit.selection.sel;if(t&&t.rangeCount){this.isSelectionPopup=!0;const e=t.getRangeAt(0);this.showPopup(()=>se(e,this.jodit,this.jodit.editorDocument),"selection")}}}}isExcludedTarget(t){return-1!==st(this.jodit.options.toolbarInlineDisableFor).map(t=>t.toLowerCase()).indexOf(t.toLowerCase())}hideIfCollapsed(){return!!this.jodit.selection.isCollapsed()&&(this.hidePopup(),!0)}afterInit(t){this.toolbar=si.makeCollection(t),this.target=t.create.div("jodit_toolbar_popup-inline-target"),this.targetContainer=t.create.div("jodit_toolbar_popup-inline-container",this.target),this.container=t.create.div(),this.popup=new Ze(t,this.target,void 0,"jodit_toolbar_popup-inline"),t.events.on(this.target,"mousedown keydown touchstart",t=>{t.stopPropagation()}).on("beforeOpenPopup hidePopup afterSetMode blur",this.hidePopup).on("recalcPositionPopup",this.reCalcPosition).on("getDiffButtons.mobile",e=>{if(this.toolbar===e)return st(t.options.buttons).filter(t=>"|"!==t&&"\n"!==t).filter(t=>0>this.toolbar.getButtonsList().indexOf(t))}).on("selectionchange",this.onChangeSelection).on("afterCommand afterExec",()=>{this.isOpened&&this.isSelectionPopup&&this.onChangeSelection()}).on("showPopup",(t,e)=>{const i=("string"==typeof t?t:t.nodeName).toLowerCase();this.isSelectionPopup=!1,this.showPopup(e,i,"string"==typeof t?void 0:t)}).on("mousedown keydown touchstart",this.onSelectionStart).on([t.ownerWindow,t.editor],"scroll resize",this.reCalcPosition).on([t.ownerWindow],"mouseup keyup touchend",this.onSelectionEnd).on([t.ownerWindow],"mousedown keydown touchstart",this.checkIsTargetEvent)}beforeDestruct(t){this.popup&&this.popup.destruct(),delete this.popup,this.toolbar&&this.toolbar.destruct(),delete this.toolbar,xe.safeRemove(this.target),xe.safeRemove(this.container),t.events&&t.events.off([t.ownerWindow],"scroll resize",this.reCalcPosition).off([t.ownerWindow],"mouseup keyup touchend",this.onSelectionEnd).off([t.ownerWindow],"mousedown keydown touchstart",this.checkIsTargetEvent)}}function Lo(t){const e=e=>{const i=i=>{if(i instanceof t.editorWindow.HTMLElement)switch(e.toLowerCase()){case"justifyfull":i.style.textAlign="justify";break;case"justifyright":i.style.textAlign="right";break;case"justifyleft":i.style.textAlign="left";break;case"justifycenter":i.style.textAlign="center"}};return t.selection.focus(),t.selection.eachSelection(e=>{if(!e&&t.editor.querySelector(".jodit_selected_cell"))return Mt(".jodit_selected_cell",t.editor).forEach(i),!1;if(!(e instanceof t.editorWindow.Node))return;let o=!!e&&xe.up(e,e=>xe.isBlock(e,t.editorWindow),t.editor);!o&&e&&(o=xe.wrapInline(e,t.options.enterBlock,t)),i(o)}),!1};t.registerCommand("justifyfull",e),t.registerCommand("justifyright",e),t.registerCommand("justifyleft",e),t.registerCommand("justifycenter",e)}function No(t){if(t&&(t.options.limitWords||t.options.limitChars)){const e=(e,i="")=>{const o=(i||(t.options.limitHTML?t.value:t.getEditorText())).replace(d,"").split(p).filter(t=>t.length);if(!e||-1===D.indexOf(e.which))return t.options.limitWords&&o.length>=t.options.limitWords?t.options.limitWords===o.length:t.options.limitChars&&t.options.limitChars<=o.join("").length?t.options.limitChars===o.join("").length:void 0};let i=null;t.events.on("beforePaste",()=>{i=t.observer.snapshot.make()}).on("keydown keyup beforeEnter beforePaste",t=>{if(void 0!==e(t))return!1}).on("change",rt((i,o)=>{!1===e(null,t.options.limitHTML?i:Ut(i))&&(t.value=o)},t.defaultTimeout)).on("afterPaste",()=>{if(!1===e(null)&&i)return t.observer.snapshot.restore(i),!1})}}function Mo(t){t.options.link.followOnDblClick&&t.events.on("afterInit",()=>{t.events.on(t.editor,"dblclick",(function(t){const e=this.getAttribute("href");e&&(location.href=e,t.preventDefault())}),"a")}),t.options.link.processPastedLink&&t.events.on("processPaste",(e,i)=>{if(Tt(i)){if(t.options.link.processVideoLink){const e=ue(i);if(e!==i)return t.create.inside.fromHTML(e)}const e=t.create.inside.element("a");return e.setAttribute("href",i),e.textContent=i,e}}),t.options.link.removeLinkAfterFormat&&t.events.on("afterCommand",e=>{let i,o;"removeFormat"===e&&(o=t.selection.current(),o&&"A"!==o.nodeName&&(o=xe.closest(o,"A",t.editor)),o&&"A"===o.nodeName&&(o.innerHTML===o.textContent?i=t.editorDocument.createTextNode(o.innerHTML):(i=t.editorDocument.createElement("span"),i.innerHTML=o.innerHTML),o.parentNode&&(o.parentNode.replaceChild(i,o),t.selection.setCursorIn(i,!0))))})}function Ao(t){const e="jodit_fake_wrapper",{mediaFakeTag:i,mediaBlocks:o,mediaInFakeBlock:s}=t.options;s&&t.events.on("afterGetValueFromEditor",t=>{const o=RegExp(`<${i}[^>]+data-${e}[^>]+>(.+?)`,"ig");o.test(t.value)&&(t.value=t.value.replace(o,"$1"))}).on("change afterInit afterSetMode",rt(()=>{t.isDestructed||t.getMode()===H||Mt(o.join(","),t.editor).forEach(o=>{o["__"+e]||(o["__"+e]=!0,(o=>{if(o.parentNode&&o.parentNode.getAttribute("data-jodit_iframe_wrapper"))o=o.parentNode;else{let s;s=t.create.inside.fromHTML("<"+i+' data-jodit-temp="1" contenteditable="false" draggable="true" data-'+e+'="1">"),s.style.display="inline-block"===o.style.display?"inline-block":"block",s.style.width=o.offsetWidth+"px",s.style.height=o.offsetHeight+"px",o.parentNode&&o.parentNode.insertBefore(s,o),s.appendChild(o),o=s}t.events.off(o,"mousedown.select touchstart.select").on(o,"mousedown.select touchstart.select",()=>{t.selection.setCursorAfter(o)})})(o))})},t.defaultTimeout))}function Io(t){let e,i=0,o=st(t.options.buttons);t.events.on("touchend",o=>{o.changedTouches&&o.changedTouches.length&&(e=(new Date).getTime(),e-i>t.options.mobileTapTimeout&&(i=e,t.selection.insertCursorAtPoint(o.changedTouches[0].clientX,o.changedTouches[0].clientY)))}).on("getDiffButtons.mobile",e=>{if(e===t.toolbar)return st(t.options.buttons).filter(t=>0>o.indexOf(t))}),t.options.toolbarAdaptive&&t.events.on("resize afterInit",()=>{if(!t.options.toolbar)return;const e=t.container.offsetWidth;let i=[];i=st(t.options.sizeLG>e?t.options.sizeMD>e?t.options.sizeSM>e?t.options.buttonsXS:t.options.buttonsSM:t.options.buttonsMD:t.options.buttons),""+i!=""+o&&(o=i,t.toolbar.build(o.concat(t.options.extraButtons),t.toolbar.container.parentElement||t.toolbar.getParentContainer()))})}function Do(t){t.events.on("afterCommand",e=>{if(/insert(un)?orderedlist/i.test(e)){const e=xe.up(t.selection.current(),t=>t&&/^UL|OL$/i.test(t.nodeName),t.editor);if(e&&e.parentNode&&"P"===e.parentNode.nodeName){const i=t.selection.save();xe.unwrap(e.parentNode),Array.from(e.childNodes).forEach(t=>{t.lastChild&&t.lastChild.nodeType===Node.ELEMENT_NODE&&"BR"===t.lastChild.nodeName&&xe.safeRemove(t.lastChild)}),t.selection.restore(i)}t.setEditorValue()}})}function Ro(t){if(!t.options.showPlaceholder)return;this.destruct=()=>{xe.safeRemove(o)};const e=()=>{o.parentNode&&(o.style.display="none")},i=rt(()=>{if(null===o.parentNode)return;if(!t.editor)return;if(t.getRealMode()!==P)return e();const i=t.getEditorValue();i&&!/^<(p|div|h[1-6])><\/\1>$/.test(i)?e():(()=>{if(!o.parentNode||t.options.readonly)return;let e=0,i=0;const s=t.editorWindow.getComputedStyle(t.editor);if(t.editor.firstChild&&t.editor.firstChild.nodeType===Node.ELEMENT_NODE){const s=t.editorWindow.getComputedStyle(t.editor.firstChild);e=parseInt(s.getPropertyValue("margin-top"),10),i=parseInt(s.getPropertyValue("margin-left"),10),o.style.fontSize=parseInt(s.getPropertyValue("font-size"),10)+"px",o.style.lineHeight=s.getPropertyValue("line-height")}else o.style.fontSize=parseInt(s.getPropertyValue("font-size"),10)+"px",o.style.lineHeight=s.getPropertyValue("line-height");fe(o,{display:"block",marginTop:Math.max(parseInt(s.getPropertyValue("margin-top"),10),e),marginLeft:Math.max(parseInt(s.getPropertyValue("margin-left"),10),i)})})()},t.defaultTimeout/10),o=t.create.fromHTML('");"rtl"===t.options.direction&&(o.style.right="0px",o.style.direction="rtl"),t.options.useInputsPlaceholder&&t.element.hasAttribute("placeholder")&&(o.innerHTML=t.element.getAttribute("placeholder")||""),t.events.on("readonly",t=>{t?e():i()}).on("afterInit",()=>{t.workplace.appendChild(o),i(),t.events.fire("placeholder",o.innerHTML),t.events.on("change keyup mouseup keydown mousedown afterSetMode",i).on(window,"load",i)})}qe.prototype.controls.align={name:"left",tooltip:"Align",getLabel(t,e,i){const o=t.selection.current();if(o){const s=xe.closest(o,e=>xe.isBlock(e,t.editorWindow),t.editor)||t.editor;let n=""+fe(s,"text-align");e.defaultValue&&-1!==e.defaultValue.indexOf(n)&&(n="left"),i&&e.data&&e.data.currentValue!==n&&e.list&&-1!==e.list.indexOf(n)&&(i.textBox.innerHTML=t.options.textIcons?`${n}`:Ce.getIcon(n,""),i.textBox.firstChild.classList.add("jodit_icon"),e.data.currentValue=n)}return!1},isActive(t,e){const i=t.selection.current();if(i&&e.defaultValue){const o=xe.closest(i,e=>xe.isBlock(e,t.editorWindow),t.editor)||t.editor;return-1===e.defaultValue.indexOf(""+fe(o,"text-align"))}return!1},defaultValue:["left","start","inherit"],data:{currentValue:"left"},list:["center","left","right","justify"]},qe.prototype.controls.center={command:"justifyCenter",css:{"text-align":"center"},tooltip:"Align Center"},qe.prototype.controls.justify={command:"justifyFull",css:{"text-align":"justify"},tooltip:"Align Justify"},qe.prototype.controls.left={command:"justifyLeft",css:{"text-align":"left"},tooltip:"Align Left"},qe.prototype.controls.right={command:"justifyRight",css:{"text-align":"right"},tooltip:"Align Right"},qe.prototype.limitWords=!1,qe.prototype.limitChars=!1,qe.prototype.limitHTML=!1,qe.prototype.link={followOnDblClick:!0,processVideoLink:!0,processPastedLink:!0,removeLinkAfterFormat:!0,noFollowCheckbox:!0,openInNewTabCheckbox:!0},qe.prototype.controls.unlink={exec(t,e){const i=xe.closest(e,"A",t.editor);i&&xe.unwrap(i),t.events.fire("hidePopup")}},qe.prototype.controls.link={isActive(t){const e=t.selection.current();return e&&!1!==xe.closest(e,"a",t.editor)},popup(t,e,i,o){const s=t.selection.sel,n=t.create.fromHTML('
'+(t.options.link.openInNewTabCheckbox?'":"")+(t.options.link.noFollowCheckbox?'":"")+'
  
');e=!(!e||!xe.closest(e,"A",t.editor))&&xe.closest(e,"A",t.editor);const r=n.querySelector(".jodit_link_insert_button"),a=n.querySelector(".jodit_unlink_button");e?(je(n,"input[name=url]",e.getAttribute("href")||""),je(n,"input[name=text]",e.textContent||""),t.options.link.openInNewTabCheckbox&&(n.querySelector("input[name=target]").checked="_blank"===e.getAttribute("target")),t.options.link.noFollowCheckbox&&(n.querySelector("input[name=nofollow]").checked="nofollow"===e.getAttribute("rel")),r&&(r.innerHTML=t.i18n("Update"))):(a&&(a.style.display="none"),je(n,"input[name=text]",s?""+s:""),r&&(r.innerHTML=t.i18n("Insert")));const l=t.selection.save();return a&&a.addEventListener("mousedown",i=>{e&&xe.unwrap(e),t.selection.restore(l),o(),i.preventDefault()}),n.addEventListener("submit",i=>{i.preventDefault(),t.selection.restore(l);const s=e||t.editorDocument.createElement("a");return je(n,"input[name=url]")?(s.setAttribute("href",je(n,"input[name=url]")),s.textContent=je(n,"input[name=text]"),t.options.link.openInNewTabCheckbox&&(n.querySelector("input[name=target]").checked?s.setAttribute("target","_blank"):s.removeAttribute("target")),t.options.link.noFollowCheckbox&&(n.querySelector("input[name=nofollow]").checked?s.setAttribute("rel","nofollow"):s.removeAttribute("rel")),e||t.selection.insertNode(s),o(),!1):(n.querySelector("input[name=url]").focus(),n.querySelector("input[name=url]").classList.add("jodit_error"),!1)}),n},tags:["a"],tooltip:"Insert link"},qe.prototype.mediaFakeTag="jodit-media",qe.prototype.mediaInFakeBlock=!0,qe.prototype.mediaBlocks=["video","audio"],qe.prototype.mobileTapTimeout=300,qe.prototype.toolbarAdaptive=!0,qe.prototype.controls.dots={mode:H+P,popup(t,e,i,o,s){let n=i.data;if(void 0===n){n={container:t.create.div(),toolbar:si.makeCollection(t),rebuild(){if(s){const e=t.events.fire("getDiffButtons.mobile",s.parentToolbar);e&&n&&n.toolbar.build(st(e),n.container)}}};let e=32;const o=t.options.toolbarButtonSize;"large"===o?e=36:"small"===o&&(e=24),n.container.style.width=3*e+"px",i.data=n}return n.rebuild(),n.container}},qe.prototype.controls.ul={command:"insertUnorderedList",controlName:"ul",tags:["ul"],tooltip:"Insert Unordered List"},qe.prototype.controls.ol={command:"insertOrderedList",controlName:"ol",tags:["ol"],tooltip:"Insert Ordered List"},qe.prototype.showPlaceholder=!0,qe.prototype.useInputsPlaceholder=!0,qe.prototype.placeholder="Type something",qe.prototype.controls.redo={mode:O,isDisable:t=>!t.observer.stack.canRedo(),tooltip:"Redo"},qe.prototype.controls.undo={mode:O,isDisable:t=>!t.observer.stack.canUndo(),tooltip:"Undo"};class Bo extends oo{beforeDestruct(){}afterInit(t){const e=e=>(t.getRealMode()===P&&t.observer[e](),!1);t.registerCommand("redo",{exec:e,hotkeys:["ctrl+y","ctrl+shift+z","cmd+y","cmd+shift+z"]}),t.registerCommand("undo",{exec:e,hotkeys:["ctrl+z","cmd+z"]})}}function Po(t){let e,i,o,s,n,r,a,l,d,c,h,p=!1,u=!1,f=!1,m=0;const g=t.create.fromHTML(''),v=g.getElementsByTagName("span")[0],b=()=>{u=!1,f=!1,i=null,g.style.display="none"},y=()=>{v.style.opacity="0"},w=()=>{if(f&&i&&g){const e=se(g.parentNode||t.ownerDocument.documentElement,t,t.ownerDocument,!0),o=se(i,t,t.editorDocument),s=parseInt(g.style.left||"0",10),n=g.offsetWidth,r=g.offsetHeight,a=o.top-1-e.top,l=o.left-1-e.left;parseInt(g.style.top||"0",10)===a&&s===l&&n===i.offsetWidth&&r===i.offsetHeight||(g.style.top=a+"px",g.style.left=l+"px",g.style.width=i.offsetWidth+"px",g.style.height=i.offsetHeight+"px",t.events&&(t.events.fire(i,"changesize"),isNaN(s)||t.events.fire("resize")))}};Mt("i",g).forEach(l=>{t.events.on(l,"mousedown touchstart",d=>{if(!i||!i.parentNode)return b(),!1;e=l,d.preventDefault(),d.stopImmediatePropagation(),n=i.offsetWidth,r=i.offsetHeight,a=n/r,u=!0,o=d.clientX,s=d.clientY,t.events.fire("hidePopup"),t.lock("resizer")})}),t.events.on("readonly",t=>{t&&b()}).on("beforeDestruct",()=>{xe.safeRemove(g)}).on("afterInit",()=>{t.events.on(t.editor,"keydown",e=>{f&&e.which===z&&i&&"table"!==i.tagName.toLowerCase()&&("JODIT"!==i.tagName?t.selection.select(i):(xe.safeRemove(i),b(),e.preventDefault()))}).on(t.ownerWindow,"mousemove touchmove",p=>{if(u){if(c=p.clientX-o,h=p.clientY-s,!i)return;const u=e.className;"IMG"===i.tagName?(c?(d=n+(u.match(/left/)?-1:1)*c,l=Math.round(d/a)):(l=r+(u.match(/top/)?-1:1)*h,d=Math.round(l*a)),d>oe(t.editor,t.ownerWindow)&&(d=oe(t.editor,t.ownerWindow),l=Math.round(d/a))):(d=n+(u.match(/left/)?-1:1)*c,l=r+(u.match(/top/)?-1:1)*h),d>t.options.resizer.min_width&&(i.style.width=g.parentNode.offsetWidth>d?d+"px":"100%"),l>t.options.resizer.min_height&&(i.style.height=l+"px"),w(),((e,i)=>{t.options.resizer.showSize&&(v.offsetWidth>e||v.offsetHeight>i?y():(v.style.opacity="1",v.innerHTML=`${e} x ${i}`,clearTimeout(m),m=nt(y,t.options.resizer.hideSizeTimeout)))})(i.offsetWidth,i.offsetHeight),p.stopImmediatePropagation()}}).on(t.ownerWindow,"resize",()=>{f&&w()}).on(t.ownerWindow,"mouseup keydown touchend",e=>{f&&!p&&(u?(t.unlock(),u=!1,t.setEditorValue(),e.stopImmediatePropagation()):b())}).on([t.ownerWindow,t.editor],"scroll",()=>{f&&!u&&b()})}).on("afterGetValueFromEditor",t=>{const e=/]+data-jodit_iframe_wrapper[^>]+>(.*?]+>[\s\n\r]*<\/iframe>.*?)<\/jodit>/gi;e.test(t.value)&&(t.value=t.value.replace(e,"$1"))}).on("hideResizer",b).on("change afterInit afterSetMode",rt(()=>{f&&(i&&i.parentNode?w():b()),t.isDestructed||Mt("img, table, iframe",t.editor).forEach(e=>{t.getMode()!==H&&!e.__jodit_resizer_binded&&("IFRAME"===e.tagName&&t.options.useIframeResizer||"IMG"===e.tagName&&t.options.useImageResizer||"TABLE"===e.tagName&&t.options.useTableResizer)&&(e.__jodit_resizer_binded=!0,(e=>{let o,s;if("IFRAME"===e.tagName){const i=e;e.parentNode&&e.parentNode.getAttribute("data-jodit_iframe_wrapper")?e=e.parentNode:(o=t.create.inside.fromHTML(''),o.style.display="inline-block"===e.style.display?"inline-block":"block",o.style.width=e.offsetWidth+"px",o.style.height=e.offsetHeight+"px",e.parentNode&&e.parentNode.insertBefore(o,e),o.appendChild(e),e=o),t.events.off(e,"mousedown.select touchstart.select").on(e,"mousedown.select touchstart.select",()=>{t.selection.select(e)}),t.events.off(e,"changesize").on(e,"changesize",()=>{i.setAttribute("width",e.offsetWidth+"px"),i.setAttribute("height",e.offsetHeight+"px")})}t.events.on(e,"dragstart",b).on(e,"mousedown",t=>{W&&"IMG"===e.nodeName&&t.preventDefault()}).on(e,"mousedown touchstart",()=>{p||(p=!0,i=e,t.options.readonly||(g.parentNode||t.workplace.appendChild(g),f=!0,g.style.display="block",t.isFullSize()&&(g.style.zIndex=""+fe(t.container,"zIndex")),w()),"IMG"!==i.tagName||i.complete||i.addEventListener("load",(function t(){w(),i&&i.removeEventListener("load",t)})),clearTimeout(s)),s=nt(()=>{p=!1},400)})})(e))})},t.defaultTimeout))}qe.prototype.useIframeResizer=!0,qe.prototype.useTableResizer=!0,qe.prototype.useImageResizer=!0,qe.prototype.resizer={showSize:!0,hideSizeTimeout:1e3,min_width:10,min_height:10},qe.prototype.useSearch=!0;class Ho extends oo{constructor(){super(...arguments),this.template='",this.isOpened=!1,this.selInfo=null,this.current=!1,this.eachMap=(t,e,i)=>{xe.findWithCurrent(t,t=>!!t&&e(t),this.jodit.editor,i?"nextSibling":"previousSibling",i?"firstChild":"lastChild")},this.updateCounters=()=>{if(!this.isOpened)return;this.counterBox.style.display=this.queryInput.value.length?"inline-block":"none";const t=this.calcCounts(this.queryInput.value,this.jodit.selection.range);this.counterBox.textContent=t.join("/")},this.calcCounts=(t,e=!1)=>{const i=[];let o=0,s=0,n=!1,r=this.jodit.editor.firstChild;for(;r&&t.length;)if(n=this.find(r,t,!0,0,n||this.jodit.editorDocument.createRange()),n){if(this.boundAlreadyWas(n,i))break;i.push(n),r=n.startContainer,s+=1,e&&this.boundAlreadyWas(e,[n])&&(o=s)}else r=null;return[o,s]},this.findAndReplace=(t,e)=>{const i=this.find(t,e,!0,0,this.jodit.selection.range);if(i&&i.startContainer&&i.endContainer){const t=this.jodit.editorDocument.createRange();try{if(i&&i.startContainer&&i.endContainer){t.setStart(i.startContainer,i.startOffset),t.setEnd(i.endContainer,i.endOffset),t.deleteContents();const e=this.jodit.editorDocument.createTextNode(this.replaceInput.value);t.insertNode(e),this.jodit.selection.select(e),this.tryScrollToElement(e)}}catch(t){}return!0}return!1},this.findAndSelect=(t,e,i)=>{const o=this.find(t,e,i,0,this.jodit.selection.range);if(o&&o.startContainer&&o.endContainer){const t=this.jodit.editorDocument.createRange();try{t.setStart(o.startContainer,o.startOffset),t.setEnd(o.endContainer,o.endOffset),this.jodit.selection.selectRange(t)}catch(t){}return this.tryScrollToElement(o.startContainer),this.current=o.startContainer,this.updateCounters(),!0}return!1},this.find=(t,e,i,o,s)=>{if(t&&e.length){let n="",r={startContainer:null,startOffset:null,endContainer:null,endOffset:null};if(this.eachMap(t,t=>{if(t.nodeType===Node.TEXT_NODE&&null!==t.nodeValue&&t.nodeValue.length){let a=t.nodeValue;i||t!==s.startContainer?i&&t===s.endContainer&&(a=o?a.substr(0,s.startOffset):a.substr(s.endOffset)):a=o?a.substr(s.endOffset):a.substr(0,s.startOffset);const l=i?n+a:a+n,d=Ho.findSomePartOfString(e,l,i);if(!1!==d){let s=Ho.findSomePartOfString(e,a,i);!0===s?s=Bt(e):!1===s&&(s=Ho.findSomePartOfString(a,e,i),!0===s&&(s=Bt(a)));let c=Ho.getSomePartOfStringIndex(e,a,i)||0;if((i&&!o||!i&&o)&&t.nodeValue.length-a.length>0&&(c+=t.nodeValue.length-a.length),null===r.startContainer&&(r.startContainer=t,r.startOffset=c),!0===d)return r.endContainer=t,r.endOffset=c,r.endOffset+=s.length,!0;n=l}else n="",r={startContainer:null,startOffset:null,endContainer:null,endOffset:null}}else xe.isBlock(t,this.jodit.editorWindow)&&""!==n&&(n=i?n+" ":" "+n);return!1},i),r.startContainer&&r.endContainer)return r;if(!o)return this.current=i?this.jodit.editor.firstChild:this.jodit.editor.lastChild,this.find(this.current,e,i,o+1,s)}return!1},this.open=(t=!1)=>{this.isOpened||(this.searchBox.classList.add("jodit_search-active"),this.isOpened=!0),this.jodit.events.fire("hidePopup"),this.searchBox.classList.toggle("jodit_search-and-replace",t),this.current=this.jodit.selection.current(),this.selInfo=this.jodit.selection.save();const e=""+(this.jodit.selection.sel||"");e&&(this.queryInput.value=e),this.updateCounters(),e?this.queryInput.select():this.queryInput.focus()},this.close=()=>{this.isOpened&&(this.selInfo&&(this.jodit.selection.restore(this.selInfo),this.selInfo=null),this.searchBox.classList.remove("jodit_search-active"),this.isOpened=!1)}}static getSomePartOfStringIndex(t,e,i=!0){return this.findSomePartOfString(t,e,i,!0)}static findSomePartOfString(t,e,i=!0,o=!1){t=Bt(t.toLowerCase().replace(p," ")),e=e.toLowerCase();let s=i?0:e.length-1,n=i?0:t.length-1,r=0,a=null;const l=i?1:-1,d=[];for(;void 0!==e[s];s+=l){const c=t[n]===e[s];if(c||null!==a&&p.test(e[s])?(null!==a&&i||(a=s),d.push(e[s]),c&&(r+=1,n+=l)):(a=null,d.length=0,r=0,n=i?0:t.length-1),r===t.length)return!o||a}return o?null!=a&&a:!!d.length&&(i?d.join(""):d.reverse().join(""))}boundAlreadyWas(t,e){return e.some(e=>e.startContainer===t.startContainer&&e.endContainer===t.endContainer&&e.startOffset===t.startOffset&&e.endOffset===t.endOffset,!1)}tryScrollToElement(t){let e=xe.closest(t,t=>t&&t.nodeType===Node.ELEMENT_NODE,this.jodit.editor);e||(e=xe.prev(t,t=>t&&t.nodeType===Node.ELEMENT_NODE,this.jodit.editor)),e&&e!==this.jodit.editor&&e.scrollIntoView()}afterInit(t){if(t.options.useSearch){const e=this;e.searchBox=t.create.fromHTML(e.template);const i=e.searchBox.querySelector.bind(e.searchBox);e.queryInput=i("input.jodit_search-query"),e.replaceInput=i("input.jodit_search-replace"),e.closeButton=i(".jodit_search_buttons-cancel"),e.nextButton=i(".jodit_search_buttons-next"),e.prevButton=i(".jodit_search_buttons-prev"),e.replaceButton=i(".jodit_search_buttons-replace"),e.counterBox=i(".jodit_search_counts span"),t.workplace.appendChild(this.searchBox),t.events.on(e.closeButton,"click",this.close).on(e.queryInput,"mousedown",()=>{t.selection.isFocused()&&(t.selection.removeMarkers(),e.selInfo=t.selection.save())}).on(e.replaceButton,"click",i=>{e.findAndReplace(t.selection.current()||t.editor.firstChild,e.queryInput.value),this.updateCounters(),i.preventDefault(),i.stopImmediatePropagation()}).on([e.nextButton,e.prevButton],"click",(function(i){t.events.fire(e.nextButton===this?"searchNext":"searchPrevious"),i.preventDefault(),i.stopImmediatePropagation()})).on(this.queryInput,"keydown",rt(e=>{switch(e.which){case w:e.preventDefault(),e.stopImmediatePropagation(),t.events.fire("searchNext")&&this.close();break;default:this.updateCounters()}},this.jodit.defaultTimeout)).on(this.jodit.container,"keydown.search",i=>{if(t.getRealMode()===P)switch(i.which){case _:this.close();break;case M:e.queryInput.value&&(t.events.fire(i.shiftKey?"searchPrevious":"searchNext"),i.preventDefault())}}).on("beforeSetMode.search",()=>{this.close()}).on("keydown.search mousedown.search",()=>{this.selInfo&&(t.selection.removeMarkers(),this.selInfo=null),this.isOpened&&(this.current=this.jodit.selection.current(),this.updateCounters())}).on("searchNext.search searchPrevious.search",()=>e.findAndSelect(t.selection.current()||t.editor.firstChild,e.queryInput.value,"searchNext"===t.events.current[t.events.current.length-1])).on("search.search",(e,i=!0)=>{t.execCommand("search",e,i)}),t.registerCommand("search",{exec:(i,o,s=!0)=>(e.findAndSelect(t.selection.current()||t.editor.firstChild,o||"",s),!1)}),t.registerCommand("openSearchDialog",{exec:()=>(e.open(),!1),hotkeys:["ctrl+f","cmd+f"]}),t.registerCommand("openReplaceDialog",{exec:()=>(t.options.readonly||e.open(!0),!1),hotkeys:["ctrl+h","cmd+h"]})}}beforeDestruct(t){xe.safeRemove(this.searchBox),t.events&&t.events.off(".search"),t.events&&t.events.off(t.container,".search")}}function Oo(t){const e=e=>{fe(t.container,"height",e),t.options.saveHeightInStorage&&t.storage.set("height",e)},i=e=>fe(t.container,"width",e),o=e=>fe(t.workplace,"height",e);if("auto"!==t.options.height&&(t.options.allowResizeX||t.options.allowResizeY)){const o=t.create.div("jodit_editor_resize",''),s={x:0,y:0,w:0,h:0};let n=!1;t.events.on(o,"mousedown touchstart",e=>{n=!0,s.x=e.clientX,s.y=e.clientY,s.w=t.container.offsetWidth,s.h=t.container.offsetHeight,t.lock(),e.preventDefault()}).on(t.ownerWindow,"mousemove touchmove",at(o=>{n&&(t.options.allowResizeY&&e(s.h+o.clientY-s.y),t.options.allowResizeX&&i(s.w+o.clientX-s.x),r(),t.events.fire("resize"))},t.defaultTimeout/10)).on(t.ownerWindow,"mouseup touchsend",()=>{n&&(n=!1,t.unlock())}).on("afterInit",()=>{t.container.appendChild(o)}).on("toggleFullSize",t=>{o.style.display=t?"none":"block"})}const s=()=>(t.options.toolbar?t.toolbar.container.offsetHeight:0)+(t.statusbar?t.statusbar.getHeight():0),n=()=>{if(!t.container||!t.container.parentNode)return;const e=fe(t.container,"minHeight")-s();[t.workplace,t.iframe,t.editor].map(i=>{const o=i===t.editor?e-2:e;i&&fe(i,"minHeight",o),t.events.fire("setMinHeight",o)})},r=()=>{t&&!t.isDestructed&&t.options&&!t.options.inline&&(n(),t.container&&("auto"!==t.options.height||t.isFullSize())&&o(t.container.offsetHeight-s()))},a=rt(r,t.defaultTimeout);t.events.on("toggleFullSize",e=>{e||"auto"!==t.options.height||(o("auto"),n())}).on("afterInit",()=>{t.options.inline||(fe(t.editor,{minHeight:"100%"}),fe(t.container,{minHeight:t.options.minHeight,minWidth:t.options.minWidth,maxWidth:t.options.maxWidth}));let o=t.options.height;if(t.options.saveHeightInStorage&&"auto"!==o){const e=t.storage.get("height");e&&(o=e)}t.options.inline||(e(o),i(t.options.width)),r()},void 0,void 0,!0).on(window,"load",a).on("afterInit resize updateToolbar scroll afterResize",a)}qe.prototype.allowResizeX=!1,qe.prototype.allowResizeY=!0,qe.prototype.beautifyHTML=!0,qe.prototype.useAceEditor=!0,qe.prototype.sourceEditorNativeOptions={showGutter:!0,theme:"ace/theme/idle_fingers",mode:"ace/mode/html",wrap:!0,highlightActiveLine:!0},qe.prototype.sourceEditorCDNUrlsJS=["https://cdnjs.cloudflare.com/ajax/libs/ace/1.4.5/ace.js"],qe.prototype.beautifyHTMLCDNUrlsJS=["https://cdnjs.cloudflare.com/ajax/libs/js-beautify/1.10.0/beautify.min.js","https://cdnjs.cloudflare.com/ajax/libs/js-beautify/1.10.0/beautify-html.min.js"],qe.prototype.controls.source={mode:O,exec(t){t.toggleMode()},isActive:t=>t.getRealMode()===H,tooltip:"Change mode"};class Wo extends oo{constructor(){super(...arguments),this.className="jodit_ace_editor",this.__lock=!1,this.__oldMirrorValue="",this.autosize=rt(()=>{this.mirror.style.height="auto",this.mirror.style.height=this.mirror.scrollHeight+"px"},this.jodit.defaultTimeout),this.tempMarkerStart="{start-jodit-selection}",this.tempMarkerStartReg=/{start-jodit-selection}/g,this.tempMarkerEnd="{end-jodit-selection}",this.tempMarkerEndReg=/{end-jodit-selection}/g,this.selInfo=[],this.lastTuple=null,this.loadNext=(t,e,i="aceReady",o=this.className)=>{if(i&&void 0===e[t]&&!this.isDestructed)return this.jodit&&this.jodit.events&&this.jodit.events.fire(i),void(this.jodit&&this.jodit.events&&this.jodit.events.fire(this.jodit.ownerWindow,i));void 0!==e[t]&&(this.lastTuple&&this.lastTuple.element.removeEventListener("load",this.lastTuple.callback),this.lastTuple=le(e[t],()=>{this.isDestructed||this.loadNext(t+1,e,i,o)},o,this.jodit.ownerDocument))},this.insertHTML=t=>{if(this.mirror.selectionStart||0===this.mirror.selectionStart){const e=this.mirror.selectionEnd;this.mirror.value=this.mirror.value.substring(0,this.mirror.selectionStart)+t+this.mirror.value.substring(e,this.mirror.value.length)}else this.mirror.value+=this.mirror;this.toWYSIWYG()},this.fromWYSIWYG=(t=!1)=>{if(!this.__lock||!0===t){this.__lock=!0;const t=this.jodit.getEditorValue(!1);t!==this.getMirrorValue()&&this.setMirrorValue(t),this.__lock=!1}},this.toWYSIWYG=()=>{if(this.__lock)return;const t=this.getMirrorValue();t!==this.__oldMirrorValue&&(this.__lock=!0,this.jodit.setEditorValue(t),this.__lock=!1,this.__oldMirrorValue=t)},this.getNormalPosition=(t,e)=>{let i=t;for(;i>0;){if(i--,"<"===e[i]&&void 0!==e[i+1]&&e[i+1].match(/[\w\/]+/i))return i;if(">"===e[i])return t}return t},this.__clear=t=>t.replace(d,""),this.selectAll=()=>{this.mirror.select()},this.onSelectAll=t=>{if("selectall"===t.toLowerCase()&&this.jodit.getRealMode()===H)return this.selectAll(),!1},this.getSelectionStart=()=>this.mirror.selectionStart,this.getSelectionEnd=()=>this.mirror.selectionEnd,this.saveSelection=()=>{if(this.jodit.getRealMode()===P)this.selInfo=this.jodit.selection.save()||[],this.jodit.setEditorValue(),this.fromWYSIWYG(!0);else{this.selInfo.length=0;const t=this.getMirrorValue();if(this.getSelectionStart()===this.getSelectionEnd()){const e=this.jodit.selection.marker(!0);this.selInfo[0]={startId:e.id,collapsed:!0,startMarker:e.outerHTML};const i=this.getNormalPosition(this.getSelectionStart(),this.getMirrorValue());this.setMirrorValue(t.substr(0,i)+this.__clear(this.selInfo[0].startMarker)+t.substr(i))}else{const e=this.jodit.selection.marker(!0),i=this.jodit.selection.marker(!1);this.selInfo[0]={startId:e.id,endId:i.id,collapsed:!1,startMarker:this.__clear(e.outerHTML),endMarker:this.__clear(i.outerHTML)};const o=this.getNormalPosition(this.getSelectionStart(),t),s=this.getNormalPosition(this.getSelectionEnd(),t);this.setMirrorValue(t.substr(0,o)+this.selInfo[0].startMarker+t.substr(o,s-o)+this.selInfo[0].endMarker+t.substr(s))}this.toWYSIWYG()}},this.restoreSelection=()=>{if(!this.selInfo.length)return;if(this.jodit.getRealMode()===P)return this.__lock=!0,this.jodit.selection.restore(this.selInfo),void(this.__lock=!1);let t=this.getMirrorValue(),e=0,i=0;try{this.selInfo[0].startMarker&&(t=t.replace(/]+data-jodit_selection_marker="start"[^>]*>[<>]*?<\/span>/gim,this.tempMarkerStart)),this.selInfo[0].endMarker&&(t=t.replace(/]+data-jodit_selection_marker="end"[^>]*>[<>]*?<\/span>/gim,this.tempMarkerEnd)),this.jodit.ownerWindow.html_beautify&&this.jodit.options.beautifyHTML&&(t=this.jodit.ownerWindow.html_beautify(t)),e=t.indexOf(this.tempMarkerStart),i=e,t=t.replace(this.tempMarkerStartReg,""),this.selInfo[0].collapsed&&-1!==e||(i=t.indexOf(this.tempMarkerEnd),-1===e&&(e=i)),t=t.replace(this.tempMarkerEndReg,"")}finally{t=t.replace(this.tempMarkerEndReg,"").replace(this.tempMarkerStartReg,"")}this.setMirrorValue(t),this.setMirrorSelectionRange(e,i),this.toWYSIWYG(),this.setFocusToMirror()},this.__proxyOnFocus=t=>{this.jodit.events.fire("focus",t)},this.__proxyOnMouseDown=t=>{this.jodit.events.fire("mousedown",t)},this.setMirrorSelectionRange=(t,e)=>{this.mirror.setSelectionRange(t,e)},this.onReadonlyReact=()=>{const t=this.jodit.options.readonly;t?this.mirror.setAttribute("readonly","true"):this.mirror.removeAttribute("readonly"),this.aceEditor&&this.aceEditor.setReadOnly(t)}}getMirrorValue(){return this.mirror.value}setMirrorValue(t){this.mirror.value=t}setFocusToMirror(){this.mirror.focus()}replaceMirrorToACE(){const t=this.jodit;let e,i;const o=()=>{i&&t.getRealMode()===H&&(t.events.fire("canRedo",i.hasRedo()),t.events.fire("canUndo",i.hasUndo()))},s=t=>e.session.getLine(t).length,n=()=>{const t=e.session.getLength(),i=[];let o=0;for(let e=0;t>e;e++)o+=s(e),e>0&&(o+=1),i[e]=o;return i},r=t=>{const e=n();if(e[0]>=t)return{row:0,column:t};let i=1;for(let o=1;e.length>o;o++)t>e[o]&&(i=o+1);return{row:i,column:t-e[i-1]-1}},a=(t,e)=>n()[t]-s(t)+e,l=()=>{if(void 0===e&&void 0!==this.jodit.ownerWindow.ace){this.jodit.events.off(this.jodit.ownerWindow,"aceReady",l);const s=this.jodit.create.div("jodit_source_mirror-fake");this.mirrorContainer.insertBefore(s,this.mirrorContainer.firstChild),this.aceEditor=e=this.jodit.ownerWindow.ace.edit(s),e.setTheme(t.options.sourceEditorNativeOptions.theme),e.renderer.setShowGutter(t.options.sourceEditorNativeOptions.showGutter),e.getSession().setMode(t.options.sourceEditorNativeOptions.mode),e.setHighlightActiveLine(t.options.sourceEditorNativeOptions.highlightActiveLine),e.getSession().setUseWrapMode(!0),e.setOption("indentedSoftWrap",!1),e.setOption("wrap",t.options.sourceEditorNativeOptions.wrap),e.getSession().setUseWorker(!1),e.$blockScrolling=1/0,e.setOptions({maxLines:1/0}),e.on("change",this.toWYSIWYG),e.on("focus",this.__proxyOnFocus),e.on("mousedown",this.__proxyOnMouseDown),this.mirror.style.display="none",i=e.getSession().getUndoManager(),this.setMirrorValue=i=>{e.setValue(t.options.beautifyHTML&&t.ownerWindow.html_beautify?t.ownerWindow.html_beautify(i):i),e.clearSelection(),o()},this.jodit.getRealMode()!==P&&this.setMirrorValue(this.getMirrorValue()),this.getMirrorValue=()=>e.getValue(),this.setFocusToMirror=()=>{e.focus()},this.getSelectionStart=()=>{const t=e.selection.getRange();return a(t.start.row,t.start.column)},this.getSelectionEnd=()=>{const t=e.selection.getRange();return a(t.end.row,t.end.column)},this.selectAll=()=>{e.selection.selectAll()},this.insertHTML=t=>{const i=e.selection.getCursor(),o=e.session.insert(i,t);e.selection.setRange({start:i,end:o},!1)},this.setMirrorSelectionRange=(t,i)=>{((t,i)=>{const o=r(t),s=r(i);e.getSelection().setSelectionRange({start:o,end:s})})(t,i)},t.events.on("afterResize",()=>{e.resize()}).fire("aceInited",t)}};t.events.on(this.jodit.ownerWindow,"aceReady",l).on("aceReady",l).on("afterSetMode",()=>{t.getRealMode()!==H&&t.getMode()!==O||(this.fromWYSIWYG(),l())}).on("beforeCommand",s=>{if(t.getRealMode()!==P&&("redo"===s||"undo"===s)&&i)return i["has"+s.substr(0,1).toUpperCase()+s.substr(1)]&&e[s](),o(),!1}),l(),void 0!==this.jodit.ownerWindow.ace||Mt("script."+this.className,this.jodit.ownerDocument.body).length||this.loadNext(0,t.options.sourceEditorCDNUrlsJS,"aceReady",this.className)}afterInit(t){this.mirrorContainer=t.create.div("jodit_source"),this.mirror=t.create.fromHTML('\n\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t"), tab = {}, selinfo = editor.selection.save(), insertCode = function (code) { + editor.selection.restore(selinfo); + editor.selection.insertHTML(code); + close(); + }; + if (editor.options.textIcons) { + tab[editor.i18n('Link')] = bylink; + tab[editor.i18n('Code')] = bycode; + } + else { + tab[icon_1.ToolbarIcon.getIcon('link') + ' ' + editor.i18n('Link')] = bylink; + tab[icon_1.ToolbarIcon.getIcon('source') + + ' ' + + editor.i18n('Code')] = bycode; + } + bycode.addEventListener('submit', function (event) { + event.preventDefault(); + if (!helpers_1.trim(helpers_1.val(bycode, 'textarea[name=code]'))) { + bycode.querySelector('textarea[name=code]').focus(); + bycode.querySelector('textarea[name=code]').classList.add('jodit_error'); + return false; + } + insertCode(helpers_1.val(bycode, 'textarea[name=code]')); + return false; + }); + bylink.addEventListener('submit', function (event) { + event.preventDefault(); + if (!helpers_1.isURL(helpers_1.val(bylink, 'input[name=code]'))) { + bylink.querySelector('input[name=code]').focus(); + bylink.querySelector('input[name=code]').classList.add('jodit_error'); + return false; + } + insertCode(helpers_1.convertMediaURLToVideoEmbed(helpers_1.val(bylink, 'input[name=code]'))); + return false; + }); + return TabsWidget(editor, tab); + }, + tags: ['iframe'], + tooltip: 'Insert youtube/vimeo video' + } +}; + + +/***/ }), +/* 4 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +Object.defineProperty(exports, "__esModule", { value: true }); +var tslib_1 = __webpack_require__(1); +tslib_1.__exportStar(__webpack_require__(30), exports); +tslib_1.__exportStar(__webpack_require__(5), exports); +tslib_1.__exportStar(__webpack_require__(15), exports); +tslib_1.__exportStar(__webpack_require__(34), exports); +tslib_1.__exportStar(__webpack_require__(93), exports); +tslib_1.__exportStar(__webpack_require__(35), exports); +tslib_1.__exportStar(__webpack_require__(20), exports); +tslib_1.__exportStar(__webpack_require__(23), exports); +tslib_1.__exportStar(__webpack_require__(9), exports); +tslib_1.__exportStar(__webpack_require__(52), exports); +tslib_1.__exportStar(__webpack_require__(113), exports); +tslib_1.__exportStar(__webpack_require__(114), exports); +tslib_1.__exportStar(__webpack_require__(10), exports); +tslib_1.__exportStar(__webpack_require__(55), exports); +tslib_1.__exportStar(__webpack_require__(115), exports); +tslib_1.__exportStar(__webpack_require__(37), exports); +tslib_1.__exportStar(__webpack_require__(24), exports); +tslib_1.__exportStar(__webpack_require__(53), exports); +tslib_1.__exportStar(__webpack_require__(116), exports); +tslib_1.__exportStar(__webpack_require__(32), exports); +tslib_1.__exportStar(__webpack_require__(31), exports); +tslib_1.__exportStar(__webpack_require__(54), exports); +tslib_1.__exportStar(__webpack_require__(56), exports); +tslib_1.__exportStar(__webpack_require__(117), exports); +tslib_1.__exportStar(__webpack_require__(13), exports); +tslib_1.__exportStar(__webpack_require__(33), exports); +tslib_1.__exportStar(__webpack_require__(118), exports); + + +/***/ }), +/* 5 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +Object.defineProperty(exports, "__esModule", { value: true }); +var tslib_1 = __webpack_require__(1); +tslib_1.__exportStar(__webpack_require__(43), exports); +tslib_1.__exportStar(__webpack_require__(19), exports); +tslib_1.__exportStar(__webpack_require__(85), exports); + + +/***/ }), +/* 6 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +Object.defineProperty(exports, "__esModule", { value: true }); +var ToolbarIcon = (function () { + function ToolbarIcon() { + } + ToolbarIcon.get = function (name) { + return ToolbarIcon.icons[name] || + ToolbarIcon.icons[name.replace(/-/g, '_')] || + ToolbarIcon.icons[name.toLowerCase()]; + }; + ToolbarIcon.exists = function (name) { + return this.get(name) !== undefined; + }; + ToolbarIcon.getIcon = function (name, defaultValue) { + if (defaultValue === void 0) { defaultValue = ''; } + return this.get(name) || defaultValue; + }; + ToolbarIcon.setIcon = function (name, value) { + this.icons[name.replace('_', '-')] = value; + }; + ToolbarIcon.icons = {}; + return ToolbarIcon; +}()); +exports.ToolbarIcon = ToolbarIcon; + + +/***/ }), +/* 7 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +Object.defineProperty(exports, "__esModule", { value: true }); +var tslib_1 = __webpack_require__(1); +var Component_1 = __webpack_require__(8); +var Plugin = (function (_super) { + tslib_1.__extends(Plugin, _super); + function Plugin(jodit) { + var _this = _super.call(this, jodit) || this; + _this.destruct = _this.destruct.bind(_this, jodit); + jodit.events + .on('afterInit', _this.afterInit.bind(_this, jodit)) + .on('beforeDestruct', _this.destruct); + return _this; + } + Plugin.prototype.init = function (jodit) { }; + Plugin.prototype.destruct = function () { + var _a, _b; + if (!this.isDestructed) { + (_b = (_a = this.jodit) === null || _a === void 0 ? void 0 : _a.events) === null || _b === void 0 ? void 0 : _b.off('beforeDestruct', this.destruct); + this.beforeDestruct(this.jodit); + _super.prototype.destruct.call(this); + } + }; + return Plugin; +}(Component_1.Component)); +exports.Plugin = Plugin; + + +/***/ }), +/* 8 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +Object.defineProperty(exports, "__esModule", { value: true }); +var isJoditObject_1 = __webpack_require__(12); +var Component = (function () { + function Component(jodit) { + this.__isDestructed = false; + if (jodit && jodit instanceof Component) { + this.jodit = jodit; + if (isJoditObject_1.isJoditObject(jodit)) { + jodit.components.push(this); + } + } + } + Object.defineProperty(Component.prototype, "isDestructed", { + get: function () { + return this.__isDestructed; + }, + enumerable: true, + configurable: true + }); + Component.prototype.destruct = function () { + if (this.jodit) { + this.jodit = undefined; + } + this.__isDestructed = true; + }; + return Component; +}()); +exports.Component = Component; + + +/***/ }), +/* 9 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +Object.defineProperty(exports, "__esModule", { value: true }); +var tslib_1 = __webpack_require__(1); +tslib_1.__exportStar(__webpack_require__(49), exports); +tslib_1.__exportStar(__webpack_require__(50), exports); +tslib_1.__exportStar(__webpack_require__(36), exports); +tslib_1.__exportStar(__webpack_require__(97), exports); +tslib_1.__exportStar(__webpack_require__(98), exports); + + +/***/ }), +/* 10 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +Object.defineProperty(exports, "__esModule", { value: true }); +var isPlainObject_1 = __webpack_require__(21); +var isNumeric_1 = __webpack_require__(22); +var normilizeCSSValue_1 = __webpack_require__(51); +var camelCase_1 = __webpack_require__(49); +var fromCamelCase_1 = __webpack_require__(50); +exports.css = function (element, key, value, onlyStyleMode) { + if (onlyStyleMode === void 0) { onlyStyleMode = false; } + var numberFieldsReg = /^left|top|bottom|right|width|min|max|height|margin|padding|font-size/i; + if (isPlainObject_1.isPlainObject(key) || value !== undefined) { + var setValue = function (elm, _key, _value) { + if (_value !== undefined && + _value !== null && + numberFieldsReg.test(_key) && + isNumeric_1.isNumeric(_value.toString())) { + _value = parseInt(_value.toString(), 10) + 'px'; + } + if (_value !== undefined && + exports.css(elm, _key, undefined, true) !== normilizeCSSValue_1.normilizeCSSValue(_key, _value)) { + elm.style[_key] = _value; + } + }; + if (isPlainObject_1.isPlainObject(key)) { + var keys = Object.keys(key); + for (var j = 0; j < keys.length; j += 1) { + setValue(element, camelCase_1.camelCase(keys[j]), key[keys[j]]); + } + } + else { + setValue(element, camelCase_1.camelCase(key), value); + } + return ''; + } + var key2 = fromCamelCase_1.fromCamelCase(key), doc = element.ownerDocument || document, win = doc ? doc.defaultView || doc.parentWindow : false; + var currentValue = element.style[key]; + var result = ''; + if (currentValue !== undefined && currentValue !== '') { + result = currentValue; + } + else if (win && !onlyStyleMode) { + result = win.getComputedStyle(element).getPropertyValue(key2); + } + if (numberFieldsReg.test(key) && + /^[\-+]?[0-9.]+px$/.test(result.toString())) { + result = parseInt(result.toString(), 10); + } + return normilizeCSSValue_1.normilizeCSSValue(key, result); +}; +exports.clearCenterAlign = function (image) { + if (exports.css(image, 'display') === 'block') { + exports.css(image, 'display', ''); + } + if (image.style.marginLeft === 'auto' && + image.style.marginRight === 'auto') { + image.style.marginLeft = ''; + image.style.marginRight = ''; + } +}; + + +/***/ }), +/* 11 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +Object.defineProperty(exports, "__esModule", { value: true }); +var tslib_1 = __webpack_require__(1); +var Config_1 = __webpack_require__(3); +var consts = __webpack_require__(2); +var Dom_1 = __webpack_require__(0); +var helpers_1 = __webpack_require__(4); +var JoditArray_1 = __webpack_require__(32); +var JoditObject_1 = __webpack_require__(31); +var observer_1 = __webpack_require__(57); +var Selection_1 = __webpack_require__(60); +var StatusBar_1 = __webpack_require__(120); +var storage_1 = __webpack_require__(25); +var viewWithToolbar_1 = __webpack_require__(63); +var PluginSystem_1 = __webpack_require__(67); +var SAFE_COUNT_CHANGE_CALL = 10; +var Jodit = (function (_super) { + tslib_1.__extends(Jodit, _super); + function Jodit(element, options) { + var _this = _super.call(this) || this; + _this.__defaultStyleDisplayKey = 'data-jodit-default-style-display'; + _this.__defaultClassesKey = 'data-jodit-default-classes'; + _this.commands = {}; + _this.__selectionLocked = null; + _this.__wasReadOnly = false; + _this.storage = storage_1.Storage.makeStorage(true, _this.id); + _this.editorIsActive = false; + _this.iframe = null; + _this.mode = consts.MODE_WYSIWYG; + _this.__callChangeCount = 0; + _this.isInited = false; + _this.options = new Config_1.OptionsDefault(options); + _this.editorDocument = _this.options.ownerDocument; + _this.editorWindow = _this.options.ownerWindow; + _this.ownerDocument = _this.options.ownerDocument; + _this.ownerWindow = _this.options.ownerWindow; + _this.element = _this.resolveElement(element); + if (_this.element.attributes) { + Array.from(_this.element.attributes).forEach(function (attr) { + var name = attr.name; + var value = attr.value; + if (Jodit.defaultOptions[name] !== undefined && + (!options || options[name] === undefined)) { + if (['readonly', 'disabled'].indexOf(name) !== -1) { + value = value === '' || value === 'true'; + } + if (/^[0-9]+(\.)?([0-9]+)?$/.test(value.toString())) { + value = Number(value); + } + _this.options[name] = value; + } + }); + } + if (_this.options.events) { + Object.keys(_this.options.events).forEach(function (key) { + _this.events.on(key, _this.options.events[key]); + }); + } + _this.container.classList.add('jodit_container'); + _this.container.setAttribute('contenteditable', 'false'); + _this.selection = new Selection_1.Select(_this); + _this.events.on('removeMarkers', function () { + if (_this.selection) { + _this.selection.removeMarkers(); + } + }); + _this.observer = new observer_1.Observer(_this); + var buffer = null; + if (_this.options.inline) { + if (['TEXTAREA', 'INPUT'].indexOf(_this.element.nodeName) === -1) { + _this.container = _this.element; + _this.element.setAttribute(_this.__defaultClassesKey, _this.element.className.toString()); + buffer = _this.container.innerHTML; + _this.container.innerHTML = ''; + } + _this.container.classList.add('jodit_inline'); + _this.container.classList.add('jodit_container'); + } + if (_this.element !== _this.container) { + if (_this.element.style.display) { + _this.element.setAttribute(_this.__defaultStyleDisplayKey, _this.element.style.display); + } + _this.element.style.display = 'none'; + } + _this.applyOptionsToToolbarContainer(_this.container); + _this.workplace = _this.create.div('jodit_workplace', { + contenteditable: false + }); + _this.makeToolbar(); + if (_this.options.textIcons) { + _this.container.classList.add('jodit_text_icons'); + } + _this.events.on(_this.ownerWindow, 'resize', function () { + if (_this.events) { + _this.events.fire('resize'); + } + }); + _this.container.appendChild(_this.workplace); + _this.statusbar = new StatusBar_1.StatusBar(_this, _this.container); + _this.workplace.appendChild(_this.progress_bar); + if (_this.element.parentNode && _this.element !== _this.container) { + _this.element.parentNode.insertBefore(_this.container, _this.element); + } + _this.id = + _this.element.getAttribute('id') || new Date().getTime().toString(); + _this.editor = _this.create.div('jodit_wysiwyg', { + contenteditable: true, + 'aria-disabled': false, + tabindex: _this.options.tabIndex + }); + _this.workplace.appendChild(_this.editor); + _this.setNativeEditorValue(_this.getElementValue()); + (function () { return tslib_1.__awaiter(_this, void 0, void 0, function () { + var e_1, opt; + return tslib_1.__generator(this, function (_a) { + switch (_a.label) { + case 0: return [4, this.beforeInitHook()]; + case 1: + _a.sent(); + return [4, this.events.fire('beforeInit', this)]; + case 2: + _a.sent(); + _a.label = 3; + case 3: + _a.trys.push([3, 5, , 6]); + return [4, Jodit.plugins.init(this)]; + case 4: + _a.sent(); + return [3, 6]; + case 5: + e_1 = _a.sent(); + console.error(e_1); + return [3, 6]; + case 6: return [4, this.__initEditor(buffer)]; + case 7: + _a.sent(); + if (this.isDestructed) { + return [2]; + } + opt = this.options; + if (opt.enableDragAndDropFileToEditor && + opt.uploader && + (opt.uploader.url || opt.uploader.insertImageAsBase64URI)) { + this.uploader.bind(this.editor); + } + this.isInited = true; + if (!this.events) return [3, 9]; + return [4, this.events.fire('afterInit', this)]; + case 8: + _a.sent(); + this.events.fire('afterConstructor', this); + _a.label = 9; + case 9: return [4, this.afterInitHook()]; + case 10: + _a.sent(); + return [2]; + } + }); + }); })(); + return _this; + } + Object.defineProperty(Jodit.prototype, "isJodit", { + get: function () { + return true; + }, + enumerable: true, + configurable: true + }); + Object.defineProperty(Jodit.prototype, "value", { + get: function () { + return this.getEditorValue(); + }, + set: function (html) { + this.setEditorValue(html); + }, + enumerable: true, + configurable: true + }); + Object.defineProperty(Jodit.prototype, "defaultTimeout", { + get: function () { + return this.options && this.options.observer + ? this.options.observer.timeout + : Jodit.defaultOptions.observer.timeout; + }, + enumerable: true, + configurable: true + }); + Jodit.Array = function (array) { + return new JoditArray_1.JoditArray(array); + }; + Jodit.Object = function (object) { + return new JoditObject_1.JoditObject(object); + }; + Jodit.fireEach = function (events) { + var args = []; + for (var _i = 1; _i < arguments.length; _i++) { + args[_i - 1] = arguments[_i]; + } + Object.keys(Jodit.instances).forEach(function (key) { + var _a; + var editor = Jodit.instances[key]; + if (!editor.isDestructed && editor.events) { + (_a = editor.events).fire.apply(_a, tslib_1.__spreadArrays([events], args)); + } + }); + }; + Jodit.make = function (element, options) { + return new Jodit(element, options); + }; + Object.defineProperty(Jodit.prototype, "uploader", { + get: function () { + return this.getInstance('Uploader'); + }, + enumerable: true, + configurable: true + }); + Object.defineProperty(Jodit.prototype, "filebrowser", { + get: function () { + return this.getInstance('FileBrowser'); + }, + enumerable: true, + configurable: true + }); + Jodit.prototype.getElementValue = function () { + return this.element.value !== undefined + ? this.element.value + : this.element.innerHTML; + }; + Jodit.prototype.getNativeEditorValue = function () { + if (this.editor) { + return this.editor.innerHTML; + } + return this.getElementValue(); + }; + Jodit.prototype.setNativeEditorValue = function (value) { + if (this.editor) { + this.editor.innerHTML = value; + } + }; + Jodit.prototype.getEditorValue = function (removeSelectionMarkers) { + if (removeSelectionMarkers === void 0) { removeSelectionMarkers = true; } + var value; + value = this.events.fire('beforeGetValueFromEditor'); + if (value !== undefined) { + return value; + } + value = this.getNativeEditorValue().replace(consts.INVISIBLE_SPACE_REG_EXP, ''); + if (removeSelectionMarkers) { + value = value.replace(/]+id="jodit_selection_marker_[^>]+><\/span>/g, ''); + } + if (value === '
') { + value = ''; + } + var new_value = { value: value }; + this.events.fire('afterGetValueFromEditor', new_value); + return new_value.value; + }; + Jodit.prototype.getEditorText = function () { + if (this.editor) { + return this.editor.textContent || ''; + } + var div = this.create.inside.div(); + div.innerHTML = this.getElementValue(); + return div.textContent || ''; + }; + Jodit.prototype.setElementValue = function (value) { + if (typeof value !== 'string' && value !== undefined) { + throw new Error('value must be string'); + } + if (value !== undefined) { + if (this.element !== this.container) { + if (this.element.value !== undefined) { + this.element.value = value; + } + else { + this.element.innerHTML = value; + } + } + } + else { + value = this.getElementValue(); + } + if (value !== this.getEditorValue()) { + this.setEditorValue(value); + } + }; + Jodit.prototype.setEditorValue = function (value) { + var newValue = this.events.fire('beforeSetValueToEditor', value); + if (newValue === false) { + return; + } + if (typeof newValue === 'string') { + value = newValue; + } + if (!this.editor) { + if (value !== undefined) { + this.setElementValue(value); + } + return; + } + if (typeof value !== 'string' && value !== undefined) { + throw new Error('value must be string'); + } + if (value !== undefined && this.editor.innerHTML !== value) { + this.setNativeEditorValue(value); + } + var old_value = this.getElementValue(), new_value = this.getEditorValue(); + if (old_value !== new_value && + this.__callChangeCount < SAFE_COUNT_CHANGE_CALL) { + this.setElementValue(new_value); + this.__callChangeCount += 1; + try { + this.events.fire('change', new_value, old_value); + } + finally { + this.__callChangeCount = 0; + } + } + }; + Jodit.prototype.registerCommand = function (commandNameOriginal, command) { + var commandName = commandNameOriginal.toLowerCase(); + if (this.commands[commandName] === undefined) { + this.commands[commandName] = []; + } + this.commands[commandName].push(command); + if (typeof command !== 'function') { + var hotkeys = this.options.commandToHotkeys[commandName] || + this.options.commandToHotkeys[commandNameOriginal] || + command.hotkeys; + if (hotkeys) { + this.registerHotkeyToCommand(hotkeys, commandName); + } + } + return this; + }; + Jodit.prototype.registerHotkeyToCommand = function (hotkeys, commandName) { + var _this = this; + var shortcuts = helpers_1.asArray(hotkeys) + .map(helpers_1.normalizeKeyAliases) + .map(function (hotkey) { return hotkey + '.hotkey'; }) + .join(' '); + this.events.off(shortcuts).on(shortcuts, function () { + return _this.execCommand(commandName); + }); + }; + Jodit.prototype.execCommand = function (command, showUI, value) { + if (showUI === void 0) { showUI = false; } + if (value === void 0) { value = null; } + if (this.options.readonly && command !== 'selectall') { + return; + } + var result; + command = command.toLowerCase(); + result = this.events.fire('beforeCommand', command, showUI, value); + if (result !== false) { + result = this.execCustomCommands(command, showUI, value); + } + if (result !== false) { + this.selection.focus(); + if (command === 'selectall') { + this.selection.select(this.editor, true); + } + else { + try { + result = this.editorDocument.execCommand(command, showUI, value); + } + catch (_a) { } + } + } + this.events.fire('afterCommand', command, showUI, value); + this.setEditorValue(); + return result; + }; + Jodit.prototype.execCustomCommands = function (commandName, second, third) { + var _this = this; + if (second === void 0) { second = false; } + if (third === void 0) { third = null; } + commandName = commandName.toLowerCase(); + if (this.commands[commandName] !== undefined) { + var result_1; + var exec = function (command) { + var callback; + if (typeof command === 'function') { + callback = command; + } + else { + callback = command.exec; + } + var resultCurrent = callback.call(_this, commandName, second, third); + if (resultCurrent !== undefined) { + result_1 = resultCurrent; + } + }; + for (var i = 0; i < this.commands[commandName].length; i += 1) { + exec(this.commands[commandName][i]); + } + return result_1; + } + }; + Jodit.prototype.lock = function (name) { + if (name === void 0) { name = 'any'; } + if (_super.prototype.lock.call(this, name)) { + this.__selectionLocked = this.selection.save(); + this.editor.classList.add('jodit_disabled'); + return true; + } + return false; + }; + Jodit.prototype.unlock = function () { + if (_super.prototype.unlock.call(this)) { + this.editor.classList.remove('jodit_disabled'); + if (this.__selectionLocked) { + this.selection.restore(this.__selectionLocked); + } + return true; + } + return false; + }; + Jodit.prototype.getMode = function () { + return this.mode; + }; + Jodit.prototype.isEditorMode = function () { + return this.getRealMode() === consts.MODE_WYSIWYG; + }; + Jodit.prototype.getRealMode = function () { + if (this.getMode() !== consts.MODE_SPLIT) { + return this.getMode(); + } + var active = this.ownerDocument.activeElement; + if (active && + (Dom_1.Dom.isOrContains(this.editor, active) || + Dom_1.Dom.isOrContains(this.toolbar.container, active))) { + return consts.MODE_WYSIWYG; + } + return consts.MODE_SOURCE; + }; + Jodit.prototype.setMode = function (mode) { + var _this = this; + var oldmode = this.getMode(); + var data = { + mode: parseInt(mode.toString(), 10) + }, modeClasses = [ + 'jodit_wysiwyg_mode', + 'jodit_source_mode', + 'jodit_split_mode' + ]; + if (this.events.fire('beforeSetMode', data) === false) { + return; + } + this.mode = helpers_1.inArray(data.mode, [ + consts.MODE_SOURCE, + consts.MODE_WYSIWYG, + consts.MODE_SPLIT + ]) + ? data.mode + : consts.MODE_WYSIWYG; + if (this.options.saveModeInStorage) { + this.storage.set('jodit_default_mode', this.mode); + } + modeClasses.forEach(function (className) { + _this.container.classList.remove(className); + }); + this.container.classList.add(modeClasses[this.mode - 1]); + if (oldmode !== this.getMode()) { + this.events.fire('afterSetMode'); + } + }; + Jodit.prototype.toggleMode = function () { + var mode = this.getMode(); + if (helpers_1.inArray(mode + 1, [ + consts.MODE_SOURCE, + consts.MODE_WYSIWYG, + this.options.useSplitMode ? consts.MODE_SPLIT : 9 + ])) { + mode += 1; + } + else { + mode = consts.MODE_WYSIWYG; + } + this.setMode(mode); + }; + Jodit.prototype.setDisabled = function (isDisabled) { + this.options.disabled = isDisabled; + var readOnly = this.__wasReadOnly; + this.setReadOnly(isDisabled || readOnly); + this.__wasReadOnly = readOnly; + if (this.editor) { + this.editor.setAttribute('aria-disabled', isDisabled.toString()); + this.container.classList.toggle('jodit_disabled', isDisabled); + this.events.fire('disabled', isDisabled); + } + }; + Jodit.prototype.getDisabled = function () { + return this.options.disabled; + }; + Jodit.prototype.setReadOnly = function (isReadOnly) { + if (this.__wasReadOnly === isReadOnly) { + return; + } + this.__wasReadOnly = isReadOnly; + this.options.readonly = isReadOnly; + if (isReadOnly) { + this.editor && this.editor.removeAttribute('contenteditable'); + } + else { + this.editor && this.editor.setAttribute('contenteditable', 'true'); + } + this.events && this.events.fire('readonly', isReadOnly); + }; + Jodit.prototype.getReadOnly = function () { + return this.options.readonly; + }; + Jodit.prototype.beforeInitHook = function () { + }; + Jodit.prototype.afterInitHook = function () { + }; + Jodit.prototype.resolveElement = function (element) { + var resolved = element; + if (typeof element === 'string') { + try { + resolved = this.ownerDocument.querySelector(element); + } + catch (_a) { + throw new Error('String "' + element + '" should be valid HTML selector'); + } + } + if (!resolved || + typeof resolved !== 'object' || + resolved.nodeType !== Node.ELEMENT_NODE || + !resolved.cloneNode) { + throw new Error('Element "' + + element + + '" should be string or HTMLElement instance'); + } + return resolved; + }; + Jodit.prototype.makeToolbar = function () { + if (!this.options.toolbar) { + return; + } + var toolbarContainer = this.create.div('jodit_toolbar_container'); + this.container.appendChild(toolbarContainer); + if (this.options.toolbar instanceof HTMLElement || + typeof this.options.toolbar === 'string') { + toolbarContainer = this.resolveElement(this.options.toolbar); + } + this.applyOptionsToToolbarContainer(toolbarContainer); + this.toolbar.build(helpers_1.splitArray(this.options.buttons).concat(this.options.extraButtons), toolbarContainer); + var bs = this.options.toolbarButtonSize.toLowerCase(); + toolbarContainer.classList.add('jodit_toolbar_size-' + + (['middle', 'large', 'small'].indexOf(bs) !== -1 + ? bs + : 'middle')); + }; + Jodit.prototype.applyOptionsToToolbarContainer = function (element) { + element.classList.add('jodit_' + (this.options.theme || 'default') + '_theme'); + if (this.options.zIndex) { + element.style.zIndex = parseInt(this.options.zIndex.toString(), 10).toString(); + } + }; + Jodit.prototype.__initEditor = function (buffer) { + return tslib_1.__awaiter(this, void 0, void 0, function () { + var mode, localMode; + return tslib_1.__generator(this, function (_a) { + switch (_a.label) { + case 0: return [4, this.__createEditor()]; + case 1: + _a.sent(); + if (this.isDestructed) { + return [2]; + } + if (this.element !== this.container) { + this.setElementValue(); + } + else { + buffer !== null && this.setEditorValue(buffer); + } + Jodit.instances[this.id] = this; + mode = this.options.defaultMode; + if (this.options.saveModeInStorage) { + localMode = this.storage.get('jodit_default_mode'); + if (typeof localMode === 'string') { + mode = parseInt(localMode, 10); + } + } + this.setMode(mode); + if (this.options.readonly) { + this.setReadOnly(true); + } + if (this.options.disabled) { + this.setDisabled(true); + } + try { + this.editorDocument.execCommand('defaultParagraphSeparator', false, this.options.enter.toLowerCase()); + } + catch (_b) { } + try { + this.editorDocument.execCommand('enableObjectResizing', false, 'false'); + } + catch (_c) { } + try { + this.editorDocument.execCommand('enableInlineTableEditing', false, 'false'); + } + catch (_d) { } + return [2]; + } + }); + }); + }; + Jodit.prototype.__createEditor = function () { + return tslib_1.__awaiter(this, void 0, void 0, function () { + var defaultEditorAreae, stayDefault, direction; + var _this = this; + return tslib_1.__generator(this, function (_a) { + switch (_a.label) { + case 0: + defaultEditorAreae = this.editor; + return [4, this.events.fire('createEditor', this)]; + case 1: + stayDefault = _a.sent(); + if (this.isDestructed) { + return [2]; + } + if (stayDefault === false) { + Dom_1.Dom.safeRemove(defaultEditorAreae); + } + if (this.options.editorCssClass) { + this.editor.classList.add(this.options.editorCssClass); + } + if (this.options.style) { + helpers_1.css(this.editor, this.options.style); + } + this.events + .on('synchro', function () { + _this.setEditorValue(); + }) + .on('focus', function () { return (_this.editorIsActive = true); }) + .on('blur', function () { return (_this.editorIsActive = false); }) + .on(this.editor, 'selectionchange selectionstart keydown keyup keypress mousedown mouseup mousepress ' + + 'click copy cut dragstart drop dragover paste resize touchstart touchend focus blur', function (event) { + if (_this.options.readonly) { + return; + } + if (_this.events && _this.events.fire) { + if (_this.events.fire(event.type, event) === false) { + return false; + } + _this.setEditorValue(); + } + }); + if (this.options.spellcheck) { + this.editor.setAttribute('spellcheck', 'true'); + } + if (this.options.direction) { + direction = this.options.direction.toLowerCase() === 'rtl' ? 'rtl' : 'ltr'; + this.editor.style.direction = direction; + this.container.style.direction = direction; + this.editor.setAttribute('dir', direction); + this.container.setAttribute('dir', direction); + this.toolbar.setDirection(direction); + } + if (this.options.triggerChangeEvent) { + this.events.on('change', helpers_1.debounce(function () { + _this.events && _this.events.fire(_this.element, 'change'); + }, this.defaultTimeout)); + } + return [2]; + } + }); + }); + }; + Jodit.prototype.destruct = function () { + if (this.isDestructed) { + return; + } + if (this.events.fire('beforeDestruct') === false) { + return; + } + if (!this.editor) { + return; + } + var buffer = this.getEditorValue(); + if (this.element !== this.container) { + if (this.element.hasAttribute(this.__defaultStyleDisplayKey)) { + var attr = this.element.getAttribute(this.__defaultStyleDisplayKey); + if (attr) { + this.element.style.display = attr; + this.element.removeAttribute(this.__defaultStyleDisplayKey); + } + } + else { + this.element.style.display = ''; + } + } + else { + if (this.element.hasAttribute(this.__defaultClassesKey)) { + this.element.className = + this.element.getAttribute(this.__defaultClassesKey) || ''; + this.element.removeAttribute(this.__defaultClassesKey); + } + } + if (this.element.hasAttribute('style') && + !this.element.getAttribute('style')) { + this.element.removeAttribute('style'); + } + this.observer.destruct(); + this.statusbar.destruct(); + delete this.observer; + delete this.statusbar; + delete this.storage; + this.buffer.clear(); + delete this.buffer; + this.components.forEach(function (component) { + if (component.destruct !== undefined && + typeof component.destruct === 'function' && + !component.isDestructed) { + component.destruct(); + } + }); + this.components.length = 0; + this.commands = {}; + delete this.selection; + this.__selectionLocked = null; + this.events.off(this.ownerWindow); + this.events.off(this.ownerDocument); + this.events.off(this.ownerDocument.body); + this.events.off(this.element); + this.events.off(this.editor); + Dom_1.Dom.safeRemove(this.workplace); + Dom_1.Dom.safeRemove(this.editor); + Dom_1.Dom.safeRemove(this.progress_bar); + Dom_1.Dom.safeRemove(this.iframe); + if (this.container !== this.element) { + Dom_1.Dom.safeRemove(this.container); + } + delete this.workplace; + delete this.editor; + delete this.progress_bar; + delete this.iframe; + if (this.container === this.element) { + this.element.innerHTML = buffer; + } + delete Jodit.instances[this.id]; + _super.prototype.destruct.call(this); + delete this.container; + }; + Jodit.plugins = new PluginSystem_1.PluginSystem(); + Jodit.modules = {}; + Jodit.instances = {}; + Jodit.lang = {}; + return Jodit; +}(viewWithToolbar_1.ViewWithToolbar)); +exports.Jodit = Jodit; + + +/***/ }), +/* 12 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +Object.defineProperty(exports, "__esModule", { value: true }); +exports.isJoditObject = function (jodit) { + if (jodit && + jodit instanceof Object && + typeof jodit.constructor === 'function' && + (jodit instanceof Jodit_1.Jodit || jodit.isJodit)) { + return true; + } + return false; +}; +var Jodit_1 = __webpack_require__(11); + + +/***/ }), +/* 13 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +Object.defineProperty(exports, "__esModule", { value: true }); +var constants_1 = __webpack_require__(2); +var $$temp = 1; +exports.$$ = function (selector, root) { + var result; + if (/:scope/.test(selector) && + constants_1.IS_IE && + !(root && root.nodeType === Node.DOCUMENT_NODE)) { + var id = root.id, temp_id = id || + '_selector_id_' + ('' + Math.random()).slice(2) + $$temp++; + selector = selector.replace(/:scope/g, '#' + temp_id); + !id && root.setAttribute('id', temp_id); + result = root.parentNode.querySelectorAll(selector); + if (!id) { + root.removeAttribute('id'); + } + } + else { + result = root.querySelectorAll(selector); + } + return [].slice.call(result); +}; +exports.getXPathByElement = function (element, root) { + if (!element || element.nodeType !== 1) { + return ''; + } + if (!element.parentNode || root === element) { + return ''; + } + if (element.id) { + return "//*[@id='" + element.id + "']"; + } + var sames = [].filter.call(element.parentNode.childNodes, function (x) { return x.nodeName === element.nodeName; }); + return (exports.getXPathByElement(element.parentNode, root) + + '/' + + element.nodeName.toLowerCase() + + (sames.length > 1 + ? '[' + (Array.from(sames).indexOf(element) + 1) + ']' + : '')); +}; + + +/***/ }), +/* 14 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +Object.defineProperty(exports, "__esModule", { value: true }); +var dialog_1 = __webpack_require__(17); +exports.Dialog = dialog_1.Dialog; +var alert_1 = __webpack_require__(187); +exports.Alert = alert_1.Alert; +var promt_1 = __webpack_require__(72); +exports.Promt = promt_1.Promt; +var confirm_1 = __webpack_require__(73); +exports.Confirm = confirm_1.Confirm; + + +/***/ }), +/* 15 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +Object.defineProperty(exports, "__esModule", { value: true }); +var JoditObject_1 = __webpack_require__(31); +var JoditArray_1 = __webpack_require__(32); +var type_1 = __webpack_require__(33); +var isPlainObject_1 = __webpack_require__(21); +function extend() { + var args = []; + for (var _i = 0; _i < arguments.length; _i++) { + args[_i] = arguments[_i]; + } + var length = args.length; + var options, name, src, copy, copyIsArray, clone, target = args[0] || {}, i = 1, j, keys, deep = false; + if (typeof target === 'boolean') { + deep = target; + target = args[i] || {}; + i += 1; + } + if (typeof target !== 'object' && type_1.type(target) === 'function') { + target = {}; + } + if (i === length) { + target = this; + i += 1; + } + for (i; i < length; i += 1) { + options = args[i]; + if (options !== null && options !== undefined) { + keys = Object.keys(options); + for (j = 0; j < keys.length; j += 1) { + name = keys[j]; + src = target[name]; + copy = options[name]; + if (target === copy) { + continue; + } + if (deep && + copy && + ((isPlainObject_1.isPlainObject(copy) && !(copy instanceof JoditObject_1.JoditObject)) || + (Array.isArray(copy) && !(copy instanceof JoditArray_1.JoditArray)))) { + copyIsArray = Array.isArray(copy); + if (copyIsArray) { + copyIsArray = false; + clone = src && Array.isArray(src) ? src : []; + } + else { + clone = src && isPlainObject_1.isPlainObject(src) ? src : {}; + } + target[name] = extend(deep, clone, copy); + } + else if (copy !== undefined) { + target[name] = copy; + } + } + } + } + return target; +} +exports.extend = extend; + + +/***/ }), +/* 16 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +Object.defineProperty(exports, "__esModule", { value: true }); +var tslib_1 = __webpack_require__(1); +var collection_1 = __webpack_require__(38); +var Dom_1 = __webpack_require__(0); +var css_1 = __webpack_require__(10); +var consts = __webpack_require__(2); +var isJoditObject_1 = __webpack_require__(12); +var JoditToolbarCollection = (function (_super) { + tslib_1.__extends(JoditToolbarCollection, _super); + function JoditToolbarCollection() { + var _this = _super !== null && _super.apply(this, arguments) || this; + _this.checkActiveStatus = function (cssObject, node) { + var matches = 0, total = 0; + Object.keys(cssObject).forEach(function (cssProperty) { + var cssValue = cssObject[cssProperty]; + if (typeof cssValue === 'function') { + if (cssValue(_this.jodit, css_1.css(node, cssProperty).toString())) { + matches += 1; + } + } + else { + if (cssValue.indexOf(css_1.css(node, cssProperty).toString()) !== -1) { + matches += 1; + } + } + total += 1; + }); + return total === matches; + }; + return _this; + } + JoditToolbarCollection.prototype.buttonIsActive = function (button) { + var _this = this; + var active = _super.prototype.buttonIsActive.call(this, button); + if (active !== undefined) { + return active; + } + var element = this.jodit.selection + ? this.jodit.selection.current() + : false; + if (!element) { + return false; + } + var tags, elm, css; + if (button.control.tags || + (button.control.options && button.control.options.tags)) { + tags = + button.control.tags || + (button.control.options && button.control.options.tags); + elm = element; + if (Dom_1.Dom.up(elm, function (node) { + if (node && + tags.indexOf(node.nodeName.toLowerCase()) !== -1) { + return true; + } + }, this.jodit.editor)) { + return true; + } + } + if (button.control.css || + (button.control.options && button.control.options.css)) { + css = + button.control.css || + (button.control.options && button.control.options.css); + elm = element; + if (Dom_1.Dom.up(elm, function (node) { + if (node && node.nodeType !== Node.TEXT_NODE) { + return _this.checkActiveStatus(css, node); + } + }, this.jodit.editor)) { + return true; + } + } + return false; + }; + JoditToolbarCollection.prototype.buttonIsDisabled = function (button) { + var disabled = _super.prototype.buttonIsDisabled.call(this, button); + if (disabled !== undefined) { + return disabled; + } + var mode = button.control === undefined || button.control.mode === undefined + ? consts.MODE_WYSIWYG + : button.control.mode; + return !(mode === consts.MODE_SPLIT || mode === this.jodit.getRealMode()); + }; + JoditToolbarCollection.prototype.getTarget = function (button) { + return button.target || this.jodit.selection.current() || undefined; + }; + JoditToolbarCollection.makeCollection = function (jodit) { + var collection = isJoditObject_1.isJoditObject(jodit) + ? new JoditToolbarCollection(jodit) + : new collection_1.ToolbarCollection(jodit); + if (jodit.options.textIcons) { + collection.container.classList.add('jodit_text_icons'); + } + return collection; + }; + return JoditToolbarCollection; +}(collection_1.ToolbarCollection)); +exports.JoditToolbarCollection = JoditToolbarCollection; + + +/***/ }), +/* 17 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +Object.defineProperty(exports, "__esModule", { value: true }); +var tslib_1 = __webpack_require__(1); +var Config_1 = __webpack_require__(3); +var constants_1 = __webpack_require__(2); +var helpers_1 = __webpack_require__(4); +var view_1 = __webpack_require__(64); +var Dom_1 = __webpack_require__(0); +var isJoditObject_1 = __webpack_require__(12); +Config_1.Config.prototype.dialog = { + resizable: true, + draggable: true, + buttons: ['dialog.close'], + removeButtons: [] +}; +Config_1.Config.prototype.controls.dialog = { + close: { + icon: 'cancel', + exec: function (dialog) { + dialog.close(); + } + }, + fullsize: { + icon: 'fullsize', + getLabel: function (editor, btn, button) { + if (Config_1.Config.prototype.controls.fullsize && + Config_1.Config.prototype.controls.fullsize.getLabel && + typeof Config_1.Config.prototype.controls.fullsize.getLabel === + 'function') { + return Config_1.Config.prototype.controls.fullsize.getLabel(editor, btn, button); + } + return; + }, + exec: function (dialog) { + dialog.toggleFullSize(); + } + } +}; +var Dialog = (function (_super) { + tslib_1.__extends(Dialog, _super); + function Dialog(jodit, options) { + if (options === void 0) { options = Config_1.Config.prototype.dialog; } + var _this = _super.call(this, jodit, options) || this; + _this.destination = document.body; + _this.destroyAfterClose = false; + _this.moved = false; + _this.iSetMaximization = false; + _this.resizable = false; + _this.draggable = false; + _this.startX = 0; + _this.startY = 0; + _this.startPoint = { x: 0, y: 0, w: 0, h: 0 }; + _this.lockSelect = function () { + _this.container.classList.add('jodit_dialog_box-moved'); + }; + _this.unlockSelect = function () { + _this.container.classList.remove('jodit_dialog_box-moved'); + }; + _this.onMouseUp = function () { + if (_this.draggable || _this.resizable) { + _this.draggable = false; + _this.resizable = false; + _this.unlockSelect(); + if (_this.jodit && _this.jodit.events) { + _this.jodit.events.fire(_this, 'endResize endMove'); + } + } + }; + _this.onHeaderMouseDown = function (e) { + var target = e.target; + if (!_this.options.draggable || + (target && target.nodeName.match(/^(INPUT|SELECT)$/))) { + return; + } + _this.draggable = true; + _this.startX = e.clientX; + _this.startY = e.clientY; + _this.startPoint.x = helpers_1.css(_this.dialog, 'left'); + _this.startPoint.y = helpers_1.css(_this.dialog, 'top'); + _this.setMaxZIndex(); + e.preventDefault(); + _this.lockSelect(); + if (_this.jodit && _this.jodit.events) { + _this.jodit.events.fire(_this, 'startMove'); + } + }; + _this.onMouseMove = function (e) { + if (_this.draggable && _this.options.draggable) { + _this.setPosition(_this.startPoint.x + e.clientX - _this.startX, _this.startPoint.y + e.clientY - _this.startY); + if (_this.jodit && _this.jodit.events) { + _this.jodit.events.fire(_this, 'move', e.clientX - _this.startX, e.clientY - _this.startY); + } + e.stopImmediatePropagation(); + e.preventDefault(); + } + if (_this.resizable && _this.options.resizable) { + _this.setSize(_this.startPoint.w + e.clientX - _this.startX, _this.startPoint.h + e.clientY - _this.startY); + if (_this.jodit && _this.jodit.events) { + _this.jodit.events.fire(_this, 'resizeDialog', e.clientX - _this.startX, e.clientY - _this.startY); + } + e.stopImmediatePropagation(); + e.preventDefault(); + } + }; + _this.onKeyDown = function (e) { + if (_this.isOpened() && e.which === constants_1.KEY_ESC) { + var me = _this.getMaxZIndexDialog(); + if (me) { + me.close(); + } + else { + _this.close(); + } + e.stopImmediatePropagation(); + } + }; + _this.onResize = function () { + if (_this.options && + _this.options.resizable && + !_this.moved && + _this.isOpened() && + !_this.offsetX && + !_this.offsetY) { + _this.setPosition(); + } + }; + _this.document = document; + _this.window = window; + _this.close = function (e) { + if (_this.isDestructed) { + return; + } + if (e) { + e.stopImmediatePropagation(); + e.preventDefault(); + } + if (_this.jodit && _this.jodit.events) { + _this.jodit.events.fire('beforeClose', _this); + } + _this.container && + _this.container.classList && + _this.container.classList.remove('active'); + if (_this.iSetMaximization) { + _this.maximization(false); + } + if (_this.destroyAfterClose) { + _this.destruct(); + } + if (_this.jodit && _this.jodit.events) { + _this.jodit.events.fire(_this, 'afterClose'); + _this.jodit.events.fire(_this.ownerWindow, 'jodit_close_dialog'); + } + }; + if (isJoditObject_1.isJoditObject(jodit)) { + _this.window = jodit.ownerWindow; + _this.document = jodit.ownerDocument; + jodit.events.on('beforeDestruct', function () { + _this.destruct(); + }); + } + var self = _this; + var opt = jodit && jodit.options + ? jodit.options.dialog + : Config_1.Config.prototype.dialog; + self.options = tslib_1.__assign(tslib_1.__assign({}, opt), self.options); + self.container = _this.create.fromHTML('
' + + '
' + + '
' + + '
' + + '
' + + '
' + + '
' + + '
' + + '' + + (self.options.resizable + ? '
' + : '') + + '
' + + '
'); + if (jodit && jodit.id) { + self.container.setAttribute('data-editor_id', jodit.id); + } + Object.defineProperty(self.container, '__jodit_dialog', { + value: self + }); + self.dialog = self.container.querySelector('.jodit_dialog'); + self.resizer = self.container.querySelector('.jodit_dialog_resizer'); + if (self.jodit && self.jodit.options && self.jodit.options.textIcons) { + self.container.classList.add('jodit_text_icons'); + } + self.dialogbox_header = self.container.querySelector('.jodit_dialog_header>.jodit_dialog_header-title'); + self.dialogbox_content = self.container.querySelector('.jodit_dialog_content'); + self.dialogbox_footer = self.container.querySelector('.jodit_dialog_footer'); + self.dialogbox_toolbar = self.container.querySelector('.jodit_dialog_header>.jodit_dialog_header-toolbar'); + self.destination.appendChild(self.container); + self.container.addEventListener('close_dialog', self.close); + self.toolbar = joditToolbarCollection_1.JoditToolbarCollection.makeCollection(self); + self.toolbar.build(self.options.buttons, self.dialogbox_toolbar); + self.events + .on(_this.window, 'mousemove', self.onMouseMove) + .on(_this.window, 'mouseup', self.onMouseUp) + .on(_this.window, 'keydown', self.onKeyDown) + .on(_this.window, 'resize', self.onResize); + var headerBox = self.container.querySelector('.jodit_dialog_header'); + headerBox && + headerBox.addEventListener('mousedown', self.onHeaderMouseDown.bind(self)); + if (self.options.resizable) { + self.resizer.addEventListener('mousedown', self.onResizerMouseDown.bind(self)); + } + plugins_1.fullsize(self); + return _this; + } + Dialog.prototype.setElements = function (root, elements) { + var _this = this; + var elements_list = []; + helpers_1.asArray(elements).forEach(function (elm) { + if (Array.isArray(elm)) { + var div = _this.create.div('jodit_dialog_column'); + elements_list.push(div); + root.appendChild(div); + return _this.setElements(div, elm); + } + var element = typeof elm === 'string' ? _this.create.fromHTML(elm) : elm; + elements_list.push(element); + if (element.parentNode !== root) { + root.appendChild(element); + } + }); + Array.from(root.childNodes).forEach(function (elm) { + if (elements_list.indexOf(elm) === -1) { + root.removeChild(elm); + } + }); + }; + Dialog.prototype.onResizerMouseDown = function (e) { + this.resizable = true; + this.startX = e.clientX; + this.startY = e.clientY; + this.startPoint.w = this.dialog.offsetWidth; + this.startPoint.h = this.dialog.offsetHeight; + this.lockSelect(); + if (this.jodit.events) { + this.jodit.events.fire(this, 'startResize'); + } + }; + Dialog.prototype.setSize = function (w, h) { + if (w) { + helpers_1.css(this.dialog, 'width', w); + } + if (h) { + helpers_1.css(this.dialog, 'height', h); + } + }; + Dialog.prototype.setPosition = function (x, y) { + var w = this.window.innerWidth, h = this.window.innerHeight; + var left = w / 2 - this.dialog.offsetWidth / 2, top = h / 2 - this.dialog.offsetHeight / 2; + if (left < 0) { + left = 0; + } + if (top < 0) { + top = 0; + } + if (x !== undefined && y !== undefined) { + this.offsetX = x; + this.offsetY = y; + this.moved = Math.abs(x - left) > 100 || Math.abs(y - top) > 100; + } + this.dialog.style.left = (x || left) + 'px'; + this.dialog.style.top = (y || top) + 'px'; + }; + Dialog.prototype.setTitle = function (content) { + this.setElements(this.dialogbox_header, content); + }; + Dialog.prototype.setContent = function (content) { + this.setElements(this.dialogbox_content, content); + }; + Dialog.prototype.setFooter = function (content) { + this.setElements(this.dialogbox_footer, content); + this.dialog.classList.toggle('with_footer', !!content); + }; + Dialog.prototype.getZIndex = function () { + return parseInt(this.container.style.zIndex || '0', 10); + }; + Dialog.prototype.getMaxZIndexDialog = function () { + var maxzi = 0, dlg, zIndex, res = this; + helpers_1.$$('.jodit_dialog_box', this.destination).forEach(function (dialog) { + dlg = dialog.__jodit_dialog; + zIndex = parseInt(helpers_1.css(dialog, 'zIndex'), 10); + if (dlg.isOpened() && !isNaN(zIndex) && zIndex > maxzi) { + res = dlg; + maxzi = zIndex; + } + }); + return res; + }; + Dialog.prototype.setMaxZIndex = function () { + var maxzi = 0, zIndex = 0; + helpers_1.$$('.jodit_dialog_box', this.destination).forEach(function (dialog) { + zIndex = parseInt(helpers_1.css(dialog, 'zIndex'), 10); + maxzi = Math.max(isNaN(zIndex) ? 0 : zIndex, maxzi); + }); + this.container.style.zIndex = (maxzi + 1).toString(); + }; + Dialog.prototype.maximization = function (condition) { + if (typeof condition !== 'boolean') { + condition = !this.container.classList.contains('jodit_dialog_box-fullsize'); + } + this.container.classList.toggle('jodit_dialog_box-fullsize', condition); + [this.destination, this.destination.parentNode].forEach(function (box) { + box && + box.classList && + box.classList.toggle('jodit_fullsize_box', condition); + }); + this.iSetMaximization = condition; + return condition; + }; + Dialog.prototype.open = function (content, title, destroyAfter, modal) { + if (this.jodit && this.jodit.events) { + if (this.jodit.events.fire(this, 'beforeOpen') === false) { + return; + } + } + this.destroyAfterClose = destroyAfter === true; + if (title !== undefined) { + this.setTitle(title); + } + if (content) { + this.setContent(content); + } + this.container.classList.add('active'); + if (modal) { + this.container.classList.add('jodit_modal'); + } + this.setPosition(this.offsetX, this.offsetY); + this.setMaxZIndex(); + if (this.options.fullsize) { + this.maximization(true); + } + if (this.jodit && this.jodit.events) { + this.jodit.events.fire('afterOpen', this); + } + }; + Dialog.prototype.isOpened = function () { + return (!this.isDestructed && + this.container && + this.container.classList.contains('active')); + }; + Dialog.prototype.destruct = function () { + if (this.isDestructed) { + return; + } + if (this.toolbar) { + this.toolbar.destruct(); + delete this.toolbar; + } + if (this.events) { + this.events + .off(this.window, 'mousemove', this.onMouseMove) + .off(this.window, 'mouseup', this.onMouseUp) + .off(this.window, 'keydown', this.onKeyDown) + .off(this.window, 'resize', this.onResize); + } + if (!this.jodit && this.events) { + this.events.destruct(); + delete this.events; + } + if (this.container) { + Dom_1.Dom.safeRemove(this.container); + delete this.container; + } + _super.prototype.destruct.call(this); + }; + return Dialog; +}(view_1.View)); +exports.Dialog = Dialog; +var joditToolbarCollection_1 = __webpack_require__(16); +var plugins_1 = __webpack_require__(69); + + +/***/ }), +/* 18 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +Object.defineProperty(exports, "__esModule", { value: true }); +var Dom_1 = __webpack_require__(0); +var helpers_1 = __webpack_require__(4); +var icon_1 = __webpack_require__(6); +var Widget; +(function (Widget) { + Widget.ColorPickerWidget = function (editor, callback, coldColor) { + var valueHex = helpers_1.normalizeColor(coldColor), form = editor.create.div('jodit_colorpicker'), iconEye = editor.options.textIcons + ? '' + : icon_1.ToolbarIcon.getIcon('eye'), iconEraser = editor.options.textIcons + ? "" + editor.i18n('eraser') + "" + : icon_1.ToolbarIcon.getIcon('eraser'), iconPalette = editor.options.textIcons + ? "" + editor.i18n('palette') + "" + : icon_1.ToolbarIcon.getIcon('palette'), setColor = function (target, color) { + target.innerHTML = icon_1.ToolbarIcon.getIcon('eye'); + target.classList.add('active'); + var colorRGB = helpers_1.hexToRgb(color); + if (colorRGB) { + target.firstChild.style.fill = + 'rgb(' + + (255 - colorRGB.r) + + ',' + + (255 - colorRGB.g) + + ',' + + (255 - colorRGB.b) + + ')'; + } + }, eachColor = function (colors) { + var stack = []; + if (helpers_1.isPlainObject(colors)) { + Object.keys(colors).forEach(function (key) { + stack.push('
'); + stack.push(eachColor(colors[key])); + stack.push('
'); + }); + } + else if (Array.isArray(colors)) { + colors.forEach(function (color) { + stack.push('' + + (valueHex === color ? iconEye : '') + + ''); + }); + } + return stack.join(''); + }; + form.appendChild(editor.create.fromHTML('
' + eachColor(editor.options.colors) + '
')); + form.appendChild(editor.create.fromHTML('' + + iconEraser + + '')); + if (editor.options.showBrowserColorPicker && helpers_1.hasBrowserColorPicker()) { + form.appendChild(editor.create.fromHTML('' + + '' + + iconPalette + + '' + + '' + + '')); + editor.events.on(form, 'change', function (e) { + e.stopPropagation(); + var target = e.target; + if (!target || + !target.tagName || + target.tagName.toUpperCase() !== 'INPUT') { + return; + } + var color = target.value || ''; + if (color) { + setColor(target, color); + } + if (callback && typeof callback === 'function') { + callback(color); + } + e.preventDefault(); + }); + } + editor.events.on(form, 'mousedown touchend', function (e) { + e.stopPropagation(); + var target = e.target; + if ((!target || + !target.tagName || + target.tagName.toUpperCase() === 'SVG' || + target.tagName.toUpperCase() === 'PATH') && + target.parentNode) { + target = Dom_1.Dom.closest(target.parentNode, 'A', editor.editor); + } + if (target.tagName.toUpperCase() !== 'A') { + return; + } + var active = form.querySelector('a.active'); + if (active) { + active.classList.remove('active'); + active.innerHTML = ''; + } + var color = target.getAttribute('data-color') || ''; + if (color) { + setColor(target, color); + } + if (callback && typeof callback === 'function') { + callback(color); + } + e.preventDefault(); + }); + return form; + }; + Widget.TabsWidget = function (editor, tabs, state) { + var box = editor.create.div('jodit_tabs'), tabBox = editor.create.div('jodit_tabs_wrapper'), buttons = editor.create.div('jodit_tabs_buttons'), nameToTab = {}; + var firstTab = '', tabcount = 0; + box.appendChild(buttons); + box.appendChild(tabBox); + helpers_1.each(tabs, function (name, tabOptions) { + var tab = editor.create.div('jodit_tab'), button = editor.create.element('a', { + href: 'javascript:void(0);' + }); + if (!firstTab) { + firstTab = name.toString(); + } + button.innerHTML = /' + + ("" + editor.i18n(isImage ? 'Drop image' : 'Drop file') + "") + + ("
" + editor.i18n('or click') + "
") + + ("") + + ''); + editor.getInstance('Uploader').bind(dragbox, function (resp) { + var handler = helpers_1.isFunction(callbacks.upload) ? callbacks.upload : editor.options.uploader.defaultHandlerSuccess; + if (typeof handler === 'function') { + handler.call(editor, { + baseurl: resp.baseurl, + files: resp.files, + isImages: resp.isImages, + }); + } + }, function (error) { + editor.events.fire('errorMessage', error.message); + }); + var icon = editor.options.textIcons + ? '' + : icon_1.ToolbarIcon.getIcon('upload'); + tabs[icon + editor.i18n('Upload')] = dragbox; + } + if (callbacks.filebrowser) { + if (editor.options.filebrowser.ajax.url || + editor.options.filebrowser.items.url) { + var icon = editor.options.textIcons + ? '' + : icon_1.ToolbarIcon.getIcon('folder'); + tabs[icon + editor.i18n('Browse')] = function () { + close && close(); + if (callbacks.filebrowser) { + editor.getInstance('FileBrowser').open(callbacks.filebrowser, isImage); + } + }; + } + } + if (callbacks.url) { + var form_1 = editor.create.fromHTML("
\n\t\t\t\t\t\t
\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t
\n\t\t\t\t\t\t
\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t
\n\t\t\t\t\t\t
\n\t\t\t\t\t
"), button = form_1.querySelector('button'), url_1 = form_1.querySelector('input[name=url]'); + currentImage = null; + if (elm && + elm.nodeType !== Node.TEXT_NODE && + (elm.tagName === 'IMG' || helpers_1.$$('img', elm).length)) { + currentImage = elm.tagName === 'IMG' ? elm : helpers_1.$$('img', elm)[0]; + helpers_1.val(form_1, 'input[name=url]', currentImage.getAttribute('src')); + helpers_1.val(form_1, 'input[name=text]', currentImage.getAttribute('alt')); + button.textContent = editor.i18n('Update'); + } + if (elm && + elm.nodeType !== Node.TEXT_NODE && + elm.nodeName === 'A') { + helpers_1.val(form_1, 'input[name=url]', elm.getAttribute('href') || ''); + helpers_1.val(form_1, 'input[name=text]', elm.getAttribute('title') || ''); + button.textContent = editor.i18n('Update'); + } + form_1.addEventListener('submit', function (event) { + event.preventDefault(); + event.stopPropagation(); + if (!helpers_1.val(form_1, 'input[name=url]')) { + url_1.focus(); + url_1.classList.add('jodit_error'); + return false; + } + if (typeof callbacks.url === 'function') { + callbacks.url.call(editor, helpers_1.val(form_1, 'input[name=url]'), helpers_1.val(form_1, 'input[name=text]')); + } + return false; + }, false); + var icon = editor.options.textIcons + ? '' + : icon_1.ToolbarIcon.getIcon('link'); + tabs[icon + ' URL'] = form_1; + } + return Widget.TabsWidget(editor, tabs); + }; +})(Widget = exports.Widget || (exports.Widget = {})); + + +/***/ }), +/* 19 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +Object.defineProperty(exports, "__esModule", { value: true }); +exports.setTimeout = function (callback, timeout, a1, a2, a3) { + if (!timeout) { + callback.call(null, a1, a2, a3); + } + else { + return window.setTimeout.call(window, callback, timeout, a1, a2, a3); + } + return 0; +}; + + +/***/ }), +/* 20 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +Object.defineProperty(exports, "__esModule", { value: true }); +var tslib_1 = __webpack_require__(1); +tslib_1.__exportStar(__webpack_require__(102), exports); +tslib_1.__exportStar(__webpack_require__(103), exports); +tslib_1.__exportStar(__webpack_require__(104), exports); +tslib_1.__exportStar(__webpack_require__(105), exports); +tslib_1.__exportStar(__webpack_require__(106), exports); +tslib_1.__exportStar(__webpack_require__(107), exports); +tslib_1.__exportStar(__webpack_require__(108), exports); +tslib_1.__exportStar(__webpack_require__(51), exports); +tslib_1.__exportStar(__webpack_require__(109), exports); + + +/***/ }), +/* 21 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +Object.defineProperty(exports, "__esModule", { value: true }); +var isWindow_1 = __webpack_require__(44); +var type_1 = __webpack_require__(33); +exports.isPlainObject = function (obj) { + if (typeof obj !== 'object' || obj.nodeType || isWindow_1.isWindow(obj)) { + return false; + } + return !(obj.constructor && + !type_1.hasOwn.call(obj.constructor.prototype, 'isPrototypeOf')); +}; + + +/***/ }), +/* 22 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +Object.defineProperty(exports, "__esModule", { value: true }); +exports.isNumeric = function (value) { + if (typeof value === 'string') { + if (!value.match(/^([+\-])?[0-9]+(\.?)([0-9]+)?(e[0-9]+)?$/)) { + return false; + } + value = parseFloat(value); + } + return !isNaN(value) && isFinite(value); +}; + + +/***/ }), +/* 23 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +Object.defineProperty(exports, "__esModule", { value: true }); +var tslib_1 = __webpack_require__(1); +tslib_1.__exportStar(__webpack_require__(110), exports); +tslib_1.__exportStar(__webpack_require__(111), exports); +tslib_1.__exportStar(__webpack_require__(112), exports); + + +/***/ }), +/* 24 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +Object.defineProperty(exports, "__esModule", { value: true }); +function each(obj, callback) { + var length, keys, i; + if (Array.isArray(obj)) { + length = obj.length; + for (i = 0; i < length; i += 1) { + if (callback.call(obj[i], i, obj[i]) === false) { + return false; + } + } + } + else { + keys = Object.keys(obj); + for (i = 0; i < keys.length; i += 1) { + if (callback.call(obj[keys[i]], keys[i], obj[keys[i]]) === false) { + return false; + } + } + } + return true; +} +exports.each = each; + + +/***/ }), +/* 25 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +Object.defineProperty(exports, "__esModule", { value: true }); +var string_1 = __webpack_require__(9); +var localStorageProvider_1 = __webpack_require__(61); +var memoryStorageProvider_1 = __webpack_require__(62); +exports.StorageKey = 'Jodit_'; +var Storage = (function () { + function Storage(provider, suffix) { + this.provider = provider; + this.prefix = exports.StorageKey; + if (suffix) { + this.prefix += suffix; + } + } + Storage.prototype.set = function (key, value) { + this.provider.set(string_1.camelCase(this.prefix + key), value); + }; + Storage.prototype.get = function (key) { + return this.provider.get(string_1.camelCase(this.prefix + key)); + }; + Storage.prototype.exists = function (key) { + return this.provider.exists(string_1.camelCase(this.prefix + key)); + }; + Storage.prototype.clear = function () { + return this.provider.clear(); + }; + Storage.makeStorage = function (persistent, suffix) { + if (persistent === void 0) { persistent = false; } + var provider; + if (persistent && localStorageProvider_1.canUsePersistentStorage()) { + provider = new localStorageProvider_1.LocalStorageProvider(exports.StorageKey + suffix); + } + if (!provider) { + provider = new memoryStorageProvider_1.MemoryStorageProvider(); + } + return new Storage(provider, suffix); + }; + return Storage; +}()); +exports.Storage = Storage; + + +/***/ }), +/* 26 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +Object.defineProperty(exports, "__esModule", { value: true }); +var tslib_1 = __webpack_require__(1); +var Component_1 = __webpack_require__(8); +var collection_1 = __webpack_require__(38); +var icon_1 = __webpack_require__(6); +var Dom_1 = __webpack_require__(0); +var string_1 = __webpack_require__(9); +var ToolbarElement = (function (_super) { + tslib_1.__extends(ToolbarElement, _super); + function ToolbarElement(parentToolbarOrView, containerTag, containerClass) { + if (containerTag === void 0) { containerTag = 'li'; } + if (containerClass === void 0) { containerClass = 'jodit_toolbar_btn'; } + var _this = this; + if (parentToolbarOrView instanceof collection_1.ToolbarCollection) { + _this = _super.call(this, parentToolbarOrView.jodit) || this; + _this.parentToolbar = parentToolbarOrView; + } + else { + _this = _super.call(this, parentToolbarOrView) || this; + } + _this.container = _this.jodit.create.element(containerTag); + _this.container.classList.add(containerClass); + return _this; + } + ToolbarElement.prototype.focus = function () { + this.container.focus(); + }; + ToolbarElement.prototype.destruct = function () { + if (this.isDestructed) { + return; + } + Dom_1.Dom.safeRemove(this.container); + this.parentToolbar = undefined; + _super.prototype.destruct.call(this); + }; + ToolbarElement.prototype.createIcon = function (clearName, control) { + var icon = control ? control.icon || control.name : clearName; + if (!this.jodit.options.textIcons) { + var iconSVG = this.jodit.events.fire('getIcon', icon, control, clearName); + var iconElement = void 0; + if (control && control.iconURL && iconSVG === undefined) { + iconElement = this.jodit.create.element('i'); + iconElement.style.backgroundImage = + 'url(' + + control.iconURL.replace('{basePath}', this.jodit.basePath) + + ')'; + } + else { + if (iconSVG === undefined) { + if (icon_1.ToolbarIcon.exists(icon)) { + iconSVG = icon_1.ToolbarIcon.getIcon(icon); + } + else { + iconSVG = icon_1.ToolbarIcon.getIcon('empty'); + } + } + iconElement = + typeof iconSVG === 'string' + ? this.jodit.create.fromHTML(string_1.trim(iconSVG)) + : iconSVG; + } + iconElement.classList.add('jodit_icon', 'jodit_icon_' + clearName); + return iconElement; + } + return this.jodit.create.fromHTML("" + this.jodit.i18n(control ? control.name : clearName) + ""); + }; + return ToolbarElement; +}(Component_1.Component)); +exports.ToolbarElement = ToolbarElement; + + +/***/ }), +/* 27 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +Object.defineProperty(exports, "__esModule", { value: true }); +var tslib_1 = __webpack_require__(1); +var Dom_1 = __webpack_require__(0); +var helpers_1 = __webpack_require__(4); +var element_1 = __webpack_require__(26); +var list_1 = __webpack_require__(125); +var popup_1 = __webpack_require__(28); +var tooltip_1 = __webpack_require__(126); +var isJoditObject_1 = __webpack_require__(12); +var constants_1 = __webpack_require__(2); +var icon_1 = __webpack_require__(6); +var ToolbarButton = (function (_super) { + tslib_1.__extends(ToolbarButton, _super); + function ToolbarButton(parentToolbarOrView, control, target) { + var _this = _super.call(this, parentToolbarOrView) || this; + _this.__disabled = false; + _this.__actived = false; + _this.onMouseDown = function (originalEvent) { + if (originalEvent.type === 'keydown' && originalEvent.which !== constants_1.KEY_ENTER) { + return; + } + originalEvent.stopImmediatePropagation(); + originalEvent.preventDefault(); + if (_this.disable) { + return false; + } + var control = _this.control, getTarget = function () { + return (_this.parentToolbar && _this.parentToolbar.getTarget(_this)) || + _this.target || + false; + }; + if (control.list) { + var list = new list_1.PopupList(_this.jodit, _this.container, _this.target); + list.open(control); + _this.jodit.events.fire('closeAllPopups', list.container); + _this.anchor.setAttribute('aria-expanded', 'true'); + _this.jodit.events.on(list, 'afterClose', function () { + _this.anchor.setAttribute('aria-expanded', 'false'); + }); + } + else if (control.exec !== undefined && typeof control.exec === 'function') { + control.exec(_this.jodit, getTarget(), control, originalEvent, _this.container); + _this.jodit.events.fire('synchro'); + if (_this.parentToolbar) { + _this.parentToolbar.immediateCheckActiveButtons(); + } + _this.jodit.events.fire('closeAllPopups afterExec'); + } + else if (control.popup !== undefined && typeof control.popup === 'function') { + var popup = new popup_1.Popup(_this.jodit, _this.container, _this.target); + if (_this.jodit.events.fire(helpers_1.camelCase("before-" + control.name + "-OpenPopup"), getTarget(), control, popup) !== false) { + var popupElm = control.popup(_this.jodit, getTarget(), control, popup.close, _this); + if (popupElm) { + popup.open(popupElm); + } + } + _this.jodit.events.fire(helpers_1.camelCase("after-" + control.name + "-OpenPopup") + + ' closeAllPopups', popup.container); + } + else { + if (control.command || control.name) { + if (isJoditObject_1.isJoditObject(_this.jodit)) { + _this.jodit.execCommand(control.command || control.name, (control.args && control.args[0]) || false, (control.args && control.args[1]) || null); + } + else { + _this.jodit.ownerDocument.execCommand(control.command || control.name, (control.args && control.args[0]) || false, (control.args && control.args[1]) || null); + } + _this.jodit.events.fire('closeAllPopups'); + } + } + }; + _this.control = control; + _this.target = target; + _this.anchor = _this.jodit.create.element('a', { + "role": "button", + "href": "javascript:void(0)" + }); + var tabIndex = '-1'; + if (_this.jodit.options.allowTabNavigation) { + tabIndex = '0'; + } + _this.anchor.setAttribute('tabindex', tabIndex); + _this.container.appendChild(_this.anchor); + if (_this.jodit.options.showTooltip && control.tooltip) { + if (!_this.jodit.options.useNativeTooltip) { + _this.tooltip = new tooltip_1.ToolbarTooltip(_this); + } + else { + _this.anchor.setAttribute('title', _this.tooltipText); + } + _this.anchor.setAttribute('aria-label', _this.tooltipText); + } + _this.textBox = _this.jodit.create.span(); + _this.anchor.appendChild(_this.textBox); + var clearName = control.name.replace(/[^a-zA-Z0-9]/g, '_'); + if (control.getContent && typeof control.getContent === 'function') { + Dom_1.Dom.detach(_this.container); + var content = control.getContent(_this.jodit, control, _this); + _this.container.appendChild(typeof content === 'string' + ? _this.jodit.create.fromHTML(content) + : content); + } + else { + if (control.list && _this.anchor) { + var trigger = _this.jodit.create.fromHTML(icon_1.ToolbarIcon.getIcon('dropdown-arrow')); + trigger.classList.add('jodit_with_dropdownlist-trigger'); + _this.container.classList.add('jodit_with_dropdownlist'); + _this.anchor.appendChild(trigger); + } + _this.textBox.appendChild(_this.createIcon(clearName, control)); + } + _this.container.classList.add('jodit_toolbar_btn-' + clearName); + if (_this.jodit.options.direction) { + var direction = _this.jodit.options.direction.toLowerCase(); + _this.container.style.direction = direction === 'rtl' ? 'rtl' : 'ltr'; + } + if (control.isInput) { + _this.container.classList.add('jodit_toolbar-input'); + } + else { + _this.jodit.events + .on(_this.container, 'mousedown touchend keydown', _this.onMouseDown) + .on("click-" + clearName + "-btn", _this.onMouseDown); + } + return _this; + } + Object.defineProperty(ToolbarButton.prototype, "disable", { + get: function () { + return this.__disabled; + }, + set: function (disable) { + this.__disabled = disable; + this.container.classList.toggle('jodit_disabled', disable); + if (!disable) { + if (this.container.hasAttribute('disabled')) { + this.container.removeAttribute('disabled'); + } + } + else { + if (!this.container.hasAttribute('disabled')) { + this.container.setAttribute('disabled', 'disabled'); + } + } + }, + enumerable: true, + configurable: true + }); + Object.defineProperty(ToolbarButton.prototype, "active", { + get: function () { + return this.__actived; + }, + set: function (enable) { + this.__actived = enable; + this.container.classList.toggle('jodit_active', enable); + }, + enumerable: true, + configurable: true + }); + ToolbarButton.prototype.isDisable = function () { + return Boolean(this.parentToolbar && this.parentToolbar.buttonIsDisabled(this)); + }; + ToolbarButton.prototype.isActive = function () { + return Boolean(this.parentToolbar && this.parentToolbar.buttonIsActive(this)); + }; + Object.defineProperty(ToolbarButton.prototype, "tooltipText", { + get: function () { + if (!this.control.tooltip) { + return ''; + } + return this.jodit.i18n(this.control.tooltip) + + (this.control.hotkeys ? '
' + helpers_1.asArray(this.control.hotkeys).join(' ') : ''); + }, + enumerable: true, + configurable: true + }); + ToolbarButton.prototype.focus = function () { + this.anchor.focus(); + }; + ToolbarButton.prototype.destruct = function () { + if (this.isDestructed) { + return; + } + this.jodit && + this.jodit.events && + this.jodit.events.off(this.container); + _super.prototype.destruct.call(this); + if (this.tooltip) { + this.tooltip.destruct(); + delete this.tooltip; + } + }; + return ToolbarButton; +}(element_1.ToolbarElement)); +exports.ToolbarButton = ToolbarButton; + + +/***/ }), +/* 28 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license; + * Copyright 2013-2019 Valeriy Chupurnov https://xdsoft.net + */ +Object.defineProperty(exports, "__esModule", { value: true }); +var tslib_1 = __webpack_require__(1); +var Dom_1 = __webpack_require__(0); +var helpers_1 = __webpack_require__(4); +var Component_1 = __webpack_require__(8); +var Popup = (function (_super) { + tslib_1.__extends(Popup, _super); + function Popup(jodit, target, current, className) { + if (className === void 0) { className = 'jodit_toolbar_popup'; } + var _this = _super.call(this, jodit) || this; + _this.target = target; + _this.current = current; + _this.className = className; + _this.throttleCalcPosition = helpers_1.throttle(_this.calcPosition, _this.jodit.defaultTimeout); + _this.isOpened = false; + _this.close = function (current) { + if (!_this.isOpened && !_this.isDestructed) { + return; + } + if (!current || + !Dom_1.Dom.isOrContains(_this.container, current instanceof Popup ? current.target : current)) { + _this.isOpened = false; + _this.jodit.events.off('closeAllPopups', _this.close); + _this.doClose(); + Dom_1.Dom.safeRemove(_this.container); + _this.jodit.events.fire('removeMarkers'); + _this.jodit.events.fire(_this, 'afterClose'); + } + }; + _this.container = _this.jodit.create.div(className, { + 'data-editor_id': jodit.id + }); + _this.jodit.events + .on(_this.container, 'mousedown touchstart touchend', function (e) { + e.stopPropagation(); + }) + .on([_this.jodit.ownerWindow, _this.jodit.events], 'resize', _this.throttleCalcPosition) + .on('afterInsertNode, afterInsertImage', _this.close); + return _this; + } + Popup.prototype.calcPosition = function () { + if (!this.isOpened || this.isDestructed) { + return; + } + var popup = this.container; + var offsetContainer = helpers_1.offset(this.jodit.container, this.jodit, this.jodit.ownerDocument, true); + var offsetPopup = helpers_1.offset(popup, this.jodit, this.jodit.ownerDocument, true); + var marginLeft = helpers_1.css(popup, 'marginLeft') || 0; + offsetPopup.left -= marginLeft; + var diffLeft = marginLeft; + var width = 'auto'; + if (offsetPopup.left < offsetContainer.left) { + diffLeft = offsetContainer.left - offsetPopup.left; + } + else if (offsetPopup.left + offsetPopup.width >= + offsetContainer.left + offsetContainer.width) { + diffLeft = -(offsetPopup.left + + offsetPopup.width - + (offsetContainer.left + offsetContainer.width)); + } + else { + diffLeft = 0; + } + if (offsetPopup.width >= offsetContainer.width) { + diffLeft = offsetContainer.left - offsetPopup.left; + width = offsetContainer.width; + } + if (diffLeft !== marginLeft) { + try { + popup.style.setProperty('margin-left', diffLeft + 'px', 'important'); + } + catch (_a) { + popup.style.marginLeft = diffLeft + 'px'; + } + } + var triangle = popup.querySelector('.jodit_popup_triangle'); + if (triangle) { + triangle.style.marginLeft = -diffLeft + 'px'; + } + helpers_1.css(popup, 'width', width); + }; + Popup.prototype.doOpen = function (content) { + if (!content) { + return; + } + Dom_1.Dom.detach(this.container); + this.container.innerHTML = ''; + this.container.appendChild(Dom_1.Dom.isNode(content, this.jodit.ownerWindow) + ? content + : this.jodit.create.fromHTML(content.toString())); + this.container.style.display = 'block'; + this.container.style.removeProperty('marginLeft'); + }; + Popup.prototype.doClose = function () { + }; + Popup.prototype.open = function (content, rightAlign, noStandardActions) { + if (noStandardActions === void 0) { noStandardActions = false; } + Jodit_1.Jodit.fireEach('beforeOpenPopup closeAllPopups', this, content); + noStandardActions || this.jodit.events.on('closeAllPopups', this.close); + this.container.classList.add(this.className + '-open'); + this.doOpen(content); + this.target.appendChild(this.container); + if (this.jodit.options.textIcons) { + this.firstInFocus(); + } + if (rightAlign !== undefined) { + this.container.classList.toggle('jodit_right', rightAlign); + } + if (!noStandardActions && this.container.parentNode) { + this.jodit.events.fire(this.container.parentNode, 'afterOpenPopup', this.container); + } + this.isOpened = true; + !noStandardActions && this.calcPosition(); + }; + Popup.prototype.firstInFocus = function () { }; + Popup.prototype.destruct = function () { + if (this.isDestructed) { + return; + } + this.jodit.events.off([this.jodit.ownerWindow, this.jodit.events], 'resize', this.throttleCalcPosition); + Dom_1.Dom.safeRemove(this.container); + delete this.container; + _super.prototype.destruct.call(this); + }; + return Popup; +}(Component_1.Component)); +exports.Popup = Popup; +var Jodit_1 = __webpack_require__(11); + + +/***/ }), +/* 29 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +Object.defineProperty(exports, "__esModule", { value: true }); +var consts = __webpack_require__(2); +var Dom_1 = __webpack_require__(0); +var helpers_1 = __webpack_require__(4); +var Table = (function () { + function Table() { + } + Table.addSelected = function (td) { + td.setAttribute(consts.JODIT_SELECTED_CELL_MARKER, '1'); + }; + Table.restoreSelection = function (td) { + td.removeAttribute(consts.JODIT_SELECTED_CELL_MARKER); + }; + Table.getAllSelectedCells = function (table) { + return table + ? helpers_1.$$("td[" + consts.JODIT_SELECTED_CELL_MARKER + "],th[" + consts.JODIT_SELECTED_CELL_MARKER + "]", table) + : []; + }; + Table.getRowsCount = function (table) { + return table.rows.length; + }; + Table.getColumnsCount = function (table) { + var matrix = Table.formalMatrix(table); + return matrix.reduce(function (max_count, cells) { + return Math.max(max_count, cells.length); + }, 0); + }; + Table.formalMatrix = function (table, callback) { + var matrix = [[]]; + var rows = Array.prototype.slice.call(table.rows); + var setCell = function (cell, i) { + if (matrix[i] === undefined) { + matrix[i] = []; + } + var colSpan = cell.colSpan, rowSpan = cell.rowSpan; + var column, row, currentColumn = 0; + while (matrix[i][currentColumn]) { + currentColumn += 1; + } + for (row = 0; row < rowSpan; row += 1) { + for (column = 0; column < colSpan; column += 1) { + if (matrix[i + row] === undefined) { + matrix[i + row] = []; + } + if (callback && + callback(cell, i + row, currentColumn + column, colSpan, rowSpan) === false) { + return false; + } + matrix[i + row][currentColumn + column] = cell; + } + } + }; + for (var i = 0, j = void 0; i < rows.length; i += 1) { + var cells = Array.prototype.slice.call(rows[i].cells); + for (j = 0; j < cells.length; j += 1) { + if (setCell(cells[j], i) === false) { + return matrix; + } + } + } + return matrix; + }; + Table.formalCoordinate = function (table, cell, max) { + if (max === void 0) { max = false; } + var i = 0, j = 0, width = 1, height = 1; + Table.formalMatrix(table, function (td, ii, jj, colSpan, rowSpan) { + if (cell === td) { + i = ii; + j = jj; + width = colSpan || 1; + height = rowSpan || 1; + if (max) { + j += (colSpan || 1) - 1; + i += (rowSpan || 1) - 1; + } + return false; + } + }); + return [i, j, width, height]; + }; + Table.appendRow = function (table, line, after) { + if (line === void 0) { line = false; } + if (after === void 0) { after = true; } + var doc = table.ownerDocument || document, columnsCount = Table.getColumnsCount(table), row = doc.createElement('tr'); + for (var j = 0; j < columnsCount; j += 1) { + row.appendChild(doc.createElement('td')); + } + if (after && line && line.nextSibling) { + line.parentNode && + line.parentNode.insertBefore(row, line.nextSibling); + } + else if (!after && line) { + line.parentNode && line.parentNode.insertBefore(row, line); + } + else { + (helpers_1.$$(':scope>tbody', table)[0] || table).appendChild(row); + } + }; + Table.removeRow = function (table, rowIndex) { + var box = Table.formalMatrix(table); + var dec; + var row = table.rows[rowIndex]; + helpers_1.each(box[rowIndex], function (j, cell) { + dec = false; + if (rowIndex - 1 >= 0 && box[rowIndex - 1][j] === cell) { + dec = true; + } + else if (box[rowIndex + 1] && box[rowIndex + 1][j] === cell) { + if (cell.parentNode === row && + cell.parentNode.nextSibling) { + dec = true; + var nextCell = j + 1; + while (box[rowIndex + 1][nextCell] === cell) { + nextCell += 1; + } + var nextRow = Dom_1.Dom.next(cell.parentNode, function (elm) { + return elm && + elm.nodeType === Node.ELEMENT_NODE && + elm.nodeName === 'TR'; + }, table); + if (box[rowIndex + 1][nextCell]) { + nextRow.insertBefore(cell, box[rowIndex + 1][nextCell]); + } + else { + nextRow.appendChild(cell); + } + } + } + else { + Dom_1.Dom.safeRemove(cell); + } + if (dec && + (cell.parentNode === row || cell !== box[rowIndex][j - 1])) { + var rowSpan = cell.rowSpan; + if (rowSpan - 1 > 1) { + cell.setAttribute('rowspan', (rowSpan - 1).toString()); + } + else { + cell.removeAttribute('rowspan'); + } + } + }); + Dom_1.Dom.safeRemove(row); + }; + Table.appendColumn = function (table, j, after) { + if (after === void 0) { after = true; } + var box = Table.formalMatrix(table); + var i; + if (j === undefined) { + j = Table.getColumnsCount(table) - 1; + } + for (i = 0; i < box.length; i += 1) { + var cell = (table.ownerDocument || document).createElement('td'); + var td = box[i][j]; + var added = false; + if (after) { + if ((box[i] && td && j + 1 >= box[i].length) || + td !== box[i][j + 1]) { + if (td.nextSibling) { + td.parentNode && + td.parentNode.insertBefore(cell, td.nextSibling); + } + else { + td.parentNode && td.parentNode.appendChild(cell); + } + added = true; + } + } + else { + if (j - 1 < 0 || + (box[i][j] !== box[i][j - 1] && box[i][j].parentNode)) { + td.parentNode && + td.parentNode.insertBefore(cell, box[i][j]); + added = true; + } + } + if (!added) { + box[i][j].setAttribute('colspan', (parseInt(box[i][j].getAttribute('colspan') || '1', 10) + + 1).toString()); + } + } + }; + Table.removeColumn = function (table, j) { + var box = Table.formalMatrix(table); + var dec; + helpers_1.each(box, function (i, cells) { + var td = cells[j]; + dec = false; + if (j - 1 >= 0 && box[i][j - 1] === td) { + dec = true; + } + else if (j + 1 < cells.length && box[i][j + 1] === td) { + dec = true; + } + else { + Dom_1.Dom.safeRemove(td); + } + if (dec && (i - 1 < 0 || td !== box[i - 1][j])) { + var colSpan = td.colSpan; + if (colSpan - 1 > 1) { + td.setAttribute('colspan', (colSpan - 1).toString()); + } + else { + td.removeAttribute('colspan'); + } + } + }); + }; + Table.getSelectedBound = function (table, selectedCells) { + var bound = [[Infinity, Infinity], [0, 0]]; + var box = Table.formalMatrix(table); + var i, j, k; + for (i = 0; i < box.length; i += 1) { + for (j = 0; j < box[i].length; j += 1) { + if (selectedCells.indexOf(box[i][j]) !== -1) { + bound[0][0] = Math.min(i, bound[0][0]); + bound[0][1] = Math.min(j, bound[0][1]); + bound[1][0] = Math.max(i, bound[1][0]); + bound[1][1] = Math.max(j, bound[1][1]); + } + } + } + for (i = bound[0][0]; i <= bound[1][0]; i += 1) { + for (k = 1, j = bound[0][1]; j <= bound[1][1]; j += 1) { + while (box[i][j - k] && box[i][j] === box[i][j - k]) { + bound[0][1] = Math.min(j - k, bound[0][1]); + bound[1][1] = Math.max(j - k, bound[1][1]); + k += 1; + } + k = 1; + while (box[i][j + k] && box[i][j] === box[i][j + k]) { + bound[0][1] = Math.min(j + k, bound[0][1]); + bound[1][1] = Math.max(j + k, bound[1][1]); + k += 1; + } + k = 1; + while (box[i - k] && box[i][j] === box[i - k][j]) { + bound[0][0] = Math.min(i - k, bound[0][0]); + bound[1][0] = Math.max(i - k, bound[1][0]); + k += 1; + } + k = 1; + while (box[i + k] && box[i][j] === box[i + k][j]) { + bound[0][0] = Math.min(i + k, bound[0][0]); + bound[1][0] = Math.max(i + k, bound[1][0]); + k += 1; + } + } + } + return bound; + }; + Table.normalizeTable = function (table) { + var i, j, min, not; + var __marked = [], box = Table.formalMatrix(table); + for (j = 0; j < box[0].length; j += 1) { + min = 1000000; + not = false; + for (i = 0; i < box.length; i += 1) { + if (box[i][j] === undefined) { + continue; + } + if (box[i][j].colSpan < 2) { + not = true; + break; + } + min = Math.min(min, box[i][j].colSpan); + } + if (!not) { + for (i = 0; i < box.length; i += 1) { + if (box[i][j] === undefined) { + continue; + } + Table.__mark(box[i][j], 'colspan', box[i][j].colSpan - min + 1, __marked); + } + } + } + for (i = 0; i < box.length; i += 1) { + min = 1000000; + not = false; + for (j = 0; j < box[i].length; j += 1) { + if (box[i][j] === undefined) { + continue; + } + if (box[i][j].rowSpan < 2) { + not = true; + break; + } + min = Math.min(min, box[i][j].rowSpan); + } + if (!not) { + for (j = 0; j < box[i].length; j += 1) { + if (box[i][j] === undefined) { + continue; + } + Table.__mark(box[i][j], 'rowspan', box[i][j].rowSpan - min + 1, __marked); + } + } + } + for (i = 0; i < box.length; i += 1) { + for (j = 0; j < box[i].length; j += 1) { + if (box[i][j] === undefined) { + continue; + } + if (box[i][j].hasAttribute('rowspan') && + box[i][j].rowSpan === 1) { + box[i][j].removeAttribute('rowspan'); + } + if (box[i][j].hasAttribute('colspan') && + box[i][j].colSpan === 1) { + box[i][j].removeAttribute('colspan'); + } + if (box[i][j].hasAttribute('class') && + !box[i][j].getAttribute('class')) { + box[i][j].removeAttribute('class'); + } + } + } + Table.__unmark(__marked); + }; + Table.mergeSelected = function (table) { + var html = [], bound = Table.getSelectedBound(table, Table.getAllSelectedCells(table)); + var w = 0, first = null, first_j = 0, td, cols = 0, rows = 0; + var __marked = []; + if (bound && (bound[0][0] - bound[1][0] || bound[0][1] - bound[1][1])) { + Table.formalMatrix(table, function (cell, i, j, cs, rs) { + if (i >= bound[0][0] && i <= bound[1][0]) { + if (j >= bound[0][1] && j <= bound[1][1]) { + td = cell; + if (td.__i_am_already_was) { + return; + } + td.__i_am_already_was = true; + if (i === bound[0][0] && td.style.width) { + w += td.offsetWidth; + } + if (helpers_1.trim(cell.innerHTML.replace(//g, '')) !== '') { + html.push(cell.innerHTML); + } + if (cs > 1) { + cols += cs - 1; + } + if (rs > 1) { + rows += rs - 1; + } + if (!first) { + first = cell; + first_j = j; + } + else { + Table.__mark(td, 'remove', 1, __marked); + } + } + } + }); + cols = bound[1][1] - bound[0][1] + 1; + rows = bound[1][0] - bound[0][0] + 1; + if (first) { + if (cols > 1) { + Table.__mark(first, 'colspan', cols, __marked); + } + if (rows > 1) { + Table.__mark(first, 'rowspan', rows, __marked); + } + if (w) { + Table.__mark(first, 'width', ((w / table.offsetWidth) * 100).toFixed(consts.ACCURACY) + '%', __marked); + if (first_j) { + Table.setColumnWidthByDelta(table, first_j, 0, true, __marked); + } + } + first.innerHTML = html.join('
'); + delete first.__i_am_already_was; + Table.__unmark(__marked); + Table.normalizeTable(table); + helpers_1.each(Array.from(table.rows), function (index, tr) { + if (!tr.cells.length) { + Dom_1.Dom.safeRemove(tr); + } + }); + } + } + }; + Table.splitHorizontal = function (table) { + var coord, td, tr, parent, after; + var __marked = []; + var doc = table.ownerDocument || document; + Table.getAllSelectedCells(table).forEach(function (cell) { + td = doc.createElement('td'); + td.appendChild(doc.createElement('br')); + tr = doc.createElement('tr'); + coord = Table.formalCoordinate(table, cell); + if (cell.rowSpan < 2) { + Table.formalMatrix(table, function (tdElm, i, j) { + if (coord[0] === i && + coord[1] !== j && + tdElm !== cell) { + Table.__mark(tdElm, 'rowspan', tdElm.rowSpan + 1, __marked); + } + }); + Dom_1.Dom.after(Dom_1.Dom.closest(cell, 'tr', table), tr); + tr.appendChild(td); + } + else { + Table.__mark(cell, 'rowspan', cell.rowSpan - 1, __marked); + Table.formalMatrix(table, function (tdElm, i, j) { + if (i > coord[0] && + i < coord[0] + cell.rowSpan && + coord[1] > j && + tdElm.parentNode + .rowIndex === i) { + after = tdElm; + } + if (coord[0] < i && tdElm === cell) { + parent = table.rows[i]; + } + }); + if (after) { + Dom_1.Dom.after(after, td); + } + else { + parent.insertBefore(td, parent.firstChild); + } + } + if (cell.colSpan > 1) { + Table.__mark(td, 'colspan', cell.colSpan, __marked); + } + Table.__unmark(__marked); + Table.restoreSelection(cell); + }); + this.normalizeTable(table); + }; + Table.splitVertical = function (table) { + var coord, td, percentage; + var __marked = []; + var doc = table.ownerDocument || document; + Table.getAllSelectedCells(table).forEach(function (cell) { + coord = Table.formalCoordinate(table, cell); + if (cell.colSpan < 2) { + Table.formalMatrix(table, function (tdElm, i, j) { + if (coord[1] === j && + coord[0] !== i && + tdElm !== cell) { + Table.__mark(tdElm, 'colspan', tdElm.colSpan + 1, __marked); + } + }); + } + else { + Table.__mark(cell, 'colspan', cell.colSpan - 1, __marked); + } + td = doc.createElement('td'); + td.appendChild(doc.createElement('br')); + if (cell.rowSpan > 1) { + Table.__mark(td, 'rowspan', cell.rowSpan, __marked); + } + var oldWidth = cell.offsetWidth; + Dom_1.Dom.after(cell, td); + percentage = oldWidth / table.offsetWidth / 2; + Table.__mark(cell, 'width', (percentage * 100).toFixed(consts.ACCURACY) + '%', __marked); + Table.__mark(td, 'width', (percentage * 100).toFixed(consts.ACCURACY) + '%', __marked); + Table.__unmark(__marked); + Table.restoreSelection(cell); + }); + Table.normalizeTable(table); + }; + Table.setColumnWidthByDelta = function (table, j, delta, noUnmark, __marked) { + var box = Table.formalMatrix(table); + var i, w, percent; + for (i = 0; i < box.length; i += 1) { + w = box[i][j].offsetWidth; + percent = ((w + delta) / table.offsetWidth) * 100; + Table.__mark(box[i][j], 'width', percent.toFixed(consts.ACCURACY) + '%', __marked); + } + if (!noUnmark) { + Table.__unmark(__marked); + } + }; + Table.__mark = function (cell, key, value, __marked) { + __marked.push(cell); + if (!cell.__marked_value) { + cell.__marked_value = {}; + } + cell.__marked_value[key] = value === undefined ? 1 : value; + }; + Table.__unmark = function (__marked) { + __marked.forEach(function (cell) { + if (cell.__marked_value) { + helpers_1.each(cell.__marked_value, function (key, value) { + switch (key) { + case 'remove': + Dom_1.Dom.safeRemove(cell); + break; + case 'rowspan': + if (value > 1) { + cell.setAttribute('rowspan', value.toString()); + } + else { + cell.removeAttribute('rowspan'); + } + break; + case 'colspan': + if (value > 1) { + cell.setAttribute('colspan', value.toString()); + } + else { + cell.removeAttribute('colspan'); + } + break; + case 'width': + cell.style.width = value.toString(); + break; + } + delete cell.__marked_value[key]; + }); + delete cell.__marked_value; + } + }); + }; + return Table; +}()); +exports.Table = Table; + + +/***/ }), +/* 30 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +Object.defineProperty(exports, "__esModule", { value: true }); +var asArray_1 = __webpack_require__(42); +exports.asArray = asArray_1.asArray; +var inArray_1 = __webpack_require__(83); +exports.inArray = inArray_1.inArray; +var splitArray_1 = __webpack_require__(84); +exports.splitArray = splitArray_1.splitArray; + + +/***/ }), +/* 31 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +Object.defineProperty(exports, "__esModule", { value: true }); +var extend_1 = __webpack_require__(15); +var JoditObject = (function () { + function JoditObject(data) { + extend_1.extend(true, this, data); + } + return JoditObject; +}()); +exports.JoditObject = JoditObject; + + +/***/ }), +/* 32 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +Object.defineProperty(exports, "__esModule", { value: true }); +var extend_1 = __webpack_require__(15); +var JoditArray = (function () { + function JoditArray(data) { + var _this = this; + this.length = 0; + extend_1.extend(true, this, data); + this.length = data.length; + var proto = Array.prototype; + [ + 'map', + 'forEach', + 'reduce', + 'push', + 'pop', + 'shift', + 'unshift', + 'slice', + 'splice' + ].forEach(function (method) { + _this[method] = proto[method]; + }); + } + JoditArray.prototype.toString = function () { + var out = []; + for (var i = 0; i < this.length; i += 1) { + out[i] = this[i]; + } + return out.toString(); + }; + return JoditArray; +}()); +exports.JoditArray = JoditArray; + + +/***/ }), +/* 33 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +Object.defineProperty(exports, "__esModule", { value: true }); +var class2type = {}; +var toString = class2type.toString; +exports.hasOwn = class2type.hasOwnProperty; +[ + 'Boolean', + 'Number', + 'String', + 'Function', + 'Array', + 'Date', + 'RegExp', + 'Object', + 'Error', + 'Symbol', + 'HTMLDocument', + 'Window', + 'HTMLElement', + 'HTMLBodyElement', + 'Text', + 'DocumentFragment', + 'DOMStringList', + 'HTMLCollection' +].forEach(function (name) { + class2type['[object ' + name + ']'] = name.toLowerCase(); +}); +exports.type = function (obj) { + if (obj === null) { + return 'null'; + } + return typeof obj === 'object' || typeof obj === 'function' + ? class2type[toString.call(obj)] || 'object' + : typeof obj; +}; + + +/***/ }), +/* 34 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +Object.defineProperty(exports, "__esModule", { value: true }); +var tslib_1 = __webpack_require__(1); +tslib_1.__exportStar(__webpack_require__(86), exports); +tslib_1.__exportStar(__webpack_require__(45), exports); +tslib_1.__exportStar(__webpack_require__(87), exports); +tslib_1.__exportStar(__webpack_require__(88), exports); +tslib_1.__exportStar(__webpack_require__(89), exports); +tslib_1.__exportStar(__webpack_require__(90), exports); +tslib_1.__exportStar(__webpack_require__(12), exports); +tslib_1.__exportStar(__webpack_require__(91), exports); +tslib_1.__exportStar(__webpack_require__(22), exports); +tslib_1.__exportStar(__webpack_require__(21), exports); +tslib_1.__exportStar(__webpack_require__(92), exports); +tslib_1.__exportStar(__webpack_require__(46), exports); +tslib_1.__exportStar(__webpack_require__(47), exports); +tslib_1.__exportStar(__webpack_require__(44), exports); + + +/***/ }), +/* 35 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +Object.defineProperty(exports, "__esModule", { value: true }); +var tslib_1 = __webpack_require__(1); +tslib_1.__exportStar(__webpack_require__(95), exports); +tslib_1.__exportStar(__webpack_require__(96), exports); +tslib_1.__exportStar(__webpack_require__(99), exports); +tslib_1.__exportStar(__webpack_require__(100), exports); +tslib_1.__exportStar(__webpack_require__(101), exports); + + +/***/ }), +/* 36 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +Object.defineProperty(exports, "__esModule", { value: true }); +var constants_1 = __webpack_require__(2); +exports.trim = function (value) { + return value + .replace(constants_1.SPACE_REG_EXP_START, '') + .replace(constants_1.SPACE_REG_EXP_END, ''); +}; + + +/***/ }), +/* 37 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +Object.defineProperty(exports, "__esModule", { value: true }); +exports.defaultLanguage = function (language, defaultLanguage) { + if (defaultLanguage === void 0) { defaultLanguage = 'en'; } + if (language !== 'auto' && typeof language === 'string') { + return language; + } + if (document.documentElement && document.documentElement.lang) { + return document.documentElement.lang; + } + if (navigator.language) { + return navigator.language.substr(0, 2); + } + return defaultLanguage; +}; + + +/***/ }), +/* 38 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +Object.defineProperty(exports, "__esModule", { value: true }); +var tslib_1 = __webpack_require__(1); +var async_1 = __webpack_require__(5); +var break_1 = __webpack_require__(124); +var button_1 = __webpack_require__(27); +var separator_1 = __webpack_require__(127); +var Dom_1 = __webpack_require__(0); +var Component_1 = __webpack_require__(8); +var Config_1 = __webpack_require__(3); +var isJoditObject_1 = __webpack_require__(12); +var ToolbarCollection = (function (_super) { + tslib_1.__extends(ToolbarCollection, _super); + function ToolbarCollection(jodit) { + var _this = _super.call(this, jodit) || this; + _this.__buttons = []; + _this.__getControlType = function (button) { + var buttonControl; + var controls = _this.jodit.options.controls || Config_1.Config.defaultOptions.controls; + if (typeof button !== 'string') { + buttonControl = tslib_1.__assign({ name: 'empty' }, button); + if (controls[buttonControl.name] !== undefined) { + buttonControl = tslib_1.__assign(tslib_1.__assign({}, controls[buttonControl.name]), buttonControl); + } + } + else { + var list = button.split(/\./); + var store = controls; + if (list.length > 1) { + if (controls[list[0]] !== undefined) { + store = controls[list[0]]; + button = list[1]; + } + } + if (store[button] !== undefined) { + buttonControl = tslib_1.__assign({ name: button }, store[button]); + } + else { + buttonControl = { + name: button, + command: button, + tooltip: button + }; + } + } + return buttonControl; + }; + _this.closeAll = function () { + _this.jodit && + _this.jodit.events && + _this.jodit.events.fire('closeAllPopups'); + }; + _this.initEvents = function () { + _this.jodit.events + .on(_this.jodit.ownerWindow, 'mousedown touchend', _this.closeAll) + .on(_this.listenEvents, _this.checkActiveButtons) + .on('afterSetMode focus', _this.immediateCheckActiveButtons); + }; + _this.listenEvents = 'changeStack mousedown mouseup keydown change afterInit readonly afterResize ' + + 'selectionchange changeSelection focus afterSetMode touchstart focus blur'; + _this.immediateCheckActiveButtons = function () { + if (_this.isDestructed || _this.jodit.isLocked()) { + return; + } + _this.__buttons.filter(function (button) { return button instanceof button_1.ToolbarButton; }).forEach(function (button) { + button.disable = button.isDisable(); + if (!button.disable) { + button.active = button.isActive(); + } + if (typeof button.control.getLabel === 'function') { + button.control.getLabel(_this.jodit, button.control, button); + } + }); + _this.jodit.events && _this.jodit.events.fire('updateToolbar'); + }; + _this.checkActiveButtons = async_1.debounce(_this.immediateCheckActiveButtons, _this.jodit.defaultTimeout); + _this.container = _this.jodit.create.element('ul'); + _this.container.classList.add('jodit_toolbar'); + _this.initEvents(); + return _this; + } + ToolbarCollection.prototype.getButtonsList = function () { + return this.__buttons + .map(function (a) { + return a instanceof button_1.ToolbarButton ? a.control.name : ''; + }) + .filter(function (a) { return a !== ''; }); + }; + ToolbarCollection.prototype.getParentContainer = function () { + return this.__parentContainer; + }; + ToolbarCollection.prototype.appendChild = function (button) { + this.__buttons.push(button); + this.container.appendChild(button.container); + }; + Object.defineProperty(ToolbarCollection.prototype, "firstButton", { + get: function () { + return this.__buttons[0]; + }, + enumerable: true, + configurable: true + }); + ToolbarCollection.prototype.removeChild = function (button) { + var index = this.__buttons.indexOf(button); + if (index !== -1) { + this.__buttons.splice(index, 1); + if (button.container.parentNode === this.container) { + Dom_1.Dom.safeRemove(button.container); + } + } + }; + ToolbarCollection.prototype.build = function (buttons, parentContainer, target) { + var _this = this; + this.jodit.events.off('rebuildToolbar'); + this.jodit.events.on('afterInit rebuildToolbar', function () { return _this.build(buttons, parentContainer, target); }); + this.__parentContainer = parentContainer; + var lastBtnSeparator = false; + this.clear(); + var buttonsList = typeof buttons === 'string' ? buttons.split(/[,\s]+/) : buttons; + buttonsList + .map(this.__getControlType) + .forEach(function (buttonControl) { + var button = null; + if (_this.jodit.options.removeButtons.indexOf(buttonControl.name) !== -1) { + return; + } + switch (buttonControl.name) { + case '\n': + button = new break_1.ToolbarBreak(_this); + break; + case '|': + if (!lastBtnSeparator) { + lastBtnSeparator = true; + button = new separator_1.ToolbarSeparator(_this); + } + break; + default: + lastBtnSeparator = false; + button = new button_1.ToolbarButton(_this, buttonControl, target); + } + if (button) { + _this.appendChild(button); + } + }); + if (this.container.parentNode !== parentContainer) { + parentContainer.appendChild(this.container); + } + this.immediateCheckActiveButtons(); + }; + ToolbarCollection.prototype.clear = function () { + var _this = this; + tslib_1.__spreadArrays(this.__buttons).forEach(function (button) { + _this.removeChild(button); + button.destruct(); + }); + this.__buttons.length = 0; + }; + ToolbarCollection.prototype.buttonIsActive = function (button) { + if (isJoditObject_1.isJoditObject(this.jodit) && !this.jodit.editorIsActive) { + return false; + } + if (typeof button.control.isActive === 'function') { + return button.control.isActive(this.jodit, button.control, button); + } + }; + ToolbarCollection.prototype.buttonIsDisabled = function (button) { + if (this.jodit.options.disabled) { + return true; + } + if (this.jodit.options.readonly && + (!this.jodit.options.activeButtonsInReadOnly || + this.jodit.options.activeButtonsInReadOnly.indexOf(button.control.name) === -1)) { + return true; + } + var isDisabled; + if (typeof button.control.isDisable === 'function') { + isDisabled = button.control.isDisable(this.jodit, button.control, button); + } + return isDisabled; + }; + ToolbarCollection.prototype.getTarget = function (button) { + return button.target; + }; + ToolbarCollection.prototype.setDirection = function (direction) { + this.container.style.direction = direction; + this.container.setAttribute('dir', direction); + }; + ToolbarCollection.prototype.destruct = function () { + if (this.isDestructed) { + return; + } + this.jodit.events + .off(this.jodit.ownerWindow, 'mousedown touchstart', this.closeAll) + .off(this.listenEvents, this.checkActiveButtons) + .off('afterSetMode focus', this.immediateCheckActiveButtons); + this.clear(); + Dom_1.Dom.safeRemove(this.container); + delete this.container; + _super.prototype.destruct.call(this); + }; + return ToolbarCollection; +}(Component_1.Component)); +exports.ToolbarCollection = ToolbarCollection; + + +/***/ }), +/* 39 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +Object.defineProperty(exports, "__esModule", { value: true }); +var tslib_1 = __webpack_require__(1); +var Config_1 = __webpack_require__(3); +var helpers_1 = __webpack_require__(4); +var buildQuery_1 = __webpack_require__(56); +Config_1.Config.prototype.defaultAjaxOptions = { + dataType: 'json', + method: 'GET', + url: '', + data: null, + contentType: 'application/x-www-form-urlencoded; charset=UTF-8', + headers: { + 'X-REQUESTED-WITH': 'XMLHttpRequest' + }, + withCredentials: false, + xhr: function () { + return new XMLHttpRequest(); + } +}; +var Ajax = (function () { + function Ajax(editor, options) { + var _this = this; + this.success_response_codes = [200, 201, 202]; + this.jodit = editor; + this.options = helpers_1.extend(true, {}, Config_1.Config.prototype.defaultAjaxOptions, options); + if (this.options.xhr) { + this.xhr = this.options.xhr(); + } + editor && + editor.events && + editor.events.on('beforeDestruct', function () { + _this.abort(); + }); + } + Ajax.prototype.__buildParams = function (obj, prefix) { + if (this.options.queryBuild && + typeof this.options.queryBuild === 'function') { + return this.options.queryBuild.call(this, obj, prefix); + } + if (typeof obj === 'string' || + (this.jodit.ownerWindow.FormData && + obj instanceof this.jodit.ownerWindow.FormData)) { + return obj; + } + return buildQuery_1.buildQuery(obj); + }; + Ajax.prototype.abort = function () { + try { + this.xhr.abort(); + } + catch (_a) { } + return this; + }; + Ajax.prototype.send = function () { + var _this = this; + return new Promise(function (resolve, reject) { + var __parse = function (resp) { + var result = null; + if (_this.options.dataType === 'json') { + result = JSON.parse(resp); + } + if (!result) { + throw new Error('No JSON format'); + } + return result; + }; + _this.xhr.onabort = function () { + reject(new Error(_this.xhr.statusText)); + }; + _this.xhr.onerror = function () { + reject(new Error(_this.xhr.statusText)); + }; + _this.xhr.ontimeout = function () { + reject(new Error(_this.xhr.statusText)); + }; + _this.xhr.onload = function () { + _this.response = _this.xhr.responseText; + _this.status = _this.xhr.status; + resolve.call(_this.xhr, __parse(_this.response) || {}); + }; + _this.xhr.onreadystatechange = function () { + if (_this.xhr.readyState === XMLHttpRequest.DONE) { + var resp = _this.xhr.responseText; + _this.response = resp; + _this.status = _this.xhr.status; + if (_this.success_response_codes.indexOf(_this.xhr.status) > -1) { + resolve.call(_this.xhr, __parse(resp)); + } + else { + reject.call(_this.xhr, new Error(_this.xhr.statusText || + _this.jodit.i18n('Connection error!'))); + } + } + }; + _this.xhr.withCredentials = + _this.options.withCredentials || false; + var _a = _this.prepareRequest(), url = _a.url, data = _a.data, method = _a.method; + _this.xhr.open(method, url, true); + if (_this.options.contentType && _this.xhr.setRequestHeader) { + _this.xhr.setRequestHeader('Content-type', _this.options.contentType); + } + if (_this.options.headers && _this.xhr.setRequestHeader) { + helpers_1.each(_this.options.headers, function (key, value) { + _this.xhr.setRequestHeader(key, value); + }); + } + setTimeout(function () { + _this.xhr.send(data + ? _this.__buildParams(data) + : undefined); + }, 0); + }); + }; + Ajax.prototype.prepareRequest = function () { + if (!this.options.url) { + throw new Error('Need URL for AJAX request'); + } + var url = this.options.url; + var data = this.options.data; + var method = (this.options.method || 'get').toLowerCase(); + if (method === 'get' && data && helpers_1.isPlainObject(data)) { + var qIndex = url.indexOf('?'); + if (qIndex !== -1) { + var urlData = helpers_1.parseQuery(url); + url = url.substr(0, qIndex) + '?' + buildQuery_1.buildQuery(tslib_1.__assign(tslib_1.__assign({}, urlData), data)); + } + else { + url += '?' + buildQuery_1.buildQuery(this.options.data); + } + } + var request = { + url: url, + method: method, + data: data + }; + Ajax.log.splice(100); + Ajax.log.push(request); + return request; + }; + Ajax.log = []; + return Ajax; +}()); +exports.Ajax = Ajax; + + +/***/ }), +/* 40 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +Object.defineProperty(exports, "__esModule", { value: true }); +var tslib_1 = __webpack_require__(1); +var Component_1 = __webpack_require__(8); +var css_1 = __webpack_require__(10); +var icon_1 = __webpack_require__(6); +var Dom_1 = __webpack_require__(0); +var ContextMenu = (function (_super) { + tslib_1.__extends(ContextMenu, _super); + function ContextMenu(editor) { + var _this = _super.call(this, editor) || this; + _this.hide = function () { + _this.context.classList.remove('jodit_context_menu-show'); + _this.jodit.ownerWindow.removeEventListener('mouseup', _this.hide); + }; + _this.context = editor.create.div('jodit_context_menu', { + 'data-editor_id': _this.jodit.id + }); + editor.ownerDocument.body.appendChild(_this.context); + return _this; + } + ContextMenu.prototype.show = function (x, y, actions, zIndex) { + var _this = this; + var self = this; + if (!Array.isArray(actions)) { + return; + } + if (zIndex) { + this.context.style.zIndex = zIndex.toString(); + } + this.context.innerHTML = ''; + actions.forEach(function (item) { + if (!item) { + return; + } + var title = self.jodit.i18n(item.title || ''); + var action = _this.jodit.create.fromHTML("" + + (item.icon ? icon_1.ToolbarIcon.getIcon(item.icon) : '') + + ''); + var span = action.querySelector('span'); + action.addEventListener('click', function (e) { + item.exec && item.exec.call(self, e); + self.hide(); + return false; + }); + span.textContent = title; + self.context.appendChild(action); + }); + css_1.css(self.context, { + left: x, + top: y + }); + this.jodit.events.on(this.jodit.ownerWindow, 'mouseup jodit_close_dialog', self.hide); + this.context.classList.add('jodit_context_menu-show'); + }; + ContextMenu.prototype.destruct = function () { + Dom_1.Dom.safeRemove(this.context); + delete this.context; + this.jodit.events.off(this.jodit.ownerWindow, 'mouseup', this.hide); + _super.prototype.destruct.call(this); + }; + return ContextMenu; +}(Component_1.Component)); +exports.ContextMenu = ContextMenu; + + +/***/ }), +/* 41 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +Object.defineProperty(exports, "__esModule", { value: true }); +exports.F_CLASS = 'jodit_filebrowser'; +exports.ITEM_CLASS = exports.F_CLASS + '_files_item'; +exports.ICON_LOADER = ''; + + +/***/ }), +/* 42 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +Object.defineProperty(exports, "__esModule", { value: true }); +exports.asArray = function (a) { return (Array.isArray(a) ? a : [a]); }; + + +/***/ }), +/* 43 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +Object.defineProperty(exports, "__esModule", { value: true }); +var setTimeout_1 = __webpack_require__(19); +exports.debounce = function (fn, timeout, invokeAsap, ctx) { + if (arguments.length === 3 && typeof invokeAsap !== 'boolean') { + ctx = invokeAsap; + invokeAsap = false; + } + var timer = 0; + return function () { + var args = arguments; + var context = ctx || this; + if ((invokeAsap && !timer) || !timeout) { + fn.apply(context, args); + } + if (timeout) { + clearTimeout(timer); + timer = setTimeout_1.setTimeout(function () { + if (!invokeAsap) { + fn.apply(context, args); + } + timer = 0; + }, timeout); + } + }; +}; + + +/***/ }), +/* 44 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +Object.defineProperty(exports, "__esModule", { value: true }); +exports.isWindow = function (obj) { + return obj !== null && obj === obj.window; +}; + + +/***/ }), +/* 45 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +Object.defineProperty(exports, "__esModule", { value: true }); +exports.isFunction = function (value) { + return typeof value === 'function'; +}; + + +/***/ }), +/* 46 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +Object.defineProperty(exports, "__esModule", { value: true }); +exports.isURL = function (str) { + var pattern = new RegExp('^(https?:\\/\\/)' + + '((([a-z\\d]([a-z\\d-]*[a-z\\d])*)\\.?)+[a-z]{2,}|' + + '((\\d{1,3}\\.){3}\\d{1,3}))' + + '(\\:\\d+)?(\\/[-a-z\\d%_.~+]*)*' + + '(\\?[;&a-z\\d%_.~+=-]*)?' + + '(\\#[-a-z\\d_]*)?$', 'i'); + return pattern.test(str); +}; + + +/***/ }), +/* 47 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +Object.defineProperty(exports, "__esModule", { value: true }); +exports.isValidName = function (name) { + if (!name.length) { + return false; + } + if (/[^0-9A-Za-zа-яА-ЯЁё\w\-_\.]/.test(name)) { + return false; + } + return true; +}; + + +/***/ }), +/* 48 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +Object.defineProperty(exports, "__esModule", { value: true }); +exports.colorToHex = function (color) { + if (color === 'rgba(0, 0, 0, 0)' || color === '') { + return false; + } + if (!color) { + return '#000000'; + } + if (color.substr(0, 1) === '#') { + return color; + } + var digits = /([\s\n\t\r]*?)rgb\((\d+), (\d+), (\d+)\)/.exec(color) || + /([\s\n\t\r]*?)rgba\((\d+), (\d+), (\d+), ([\d.]+)\)/.exec(color); + var hex, red, green, blue, rgb; + if (!digits) { + return '#000000'; + } + red = parseInt(digits[2], 10); + green = parseInt(digits[3], 10); + blue = parseInt(digits[4], 10); + rgb = blue | (green << 8) | (red << 16); + hex = rgb.toString(16).toUpperCase(); + while (hex.length < 6) { + hex = '0' + hex; + } + return digits[1] + '#' + hex; +}; + + +/***/ }), +/* 49 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +Object.defineProperty(exports, "__esModule", { value: true }); +exports.camelCase = function (key) { + return key.replace(/([-_])(.)/g, function (m, code, letter) { + return letter.toUpperCase(); + }); +}; + + +/***/ }), +/* 50 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +Object.defineProperty(exports, "__esModule", { value: true }); +exports.fromCamelCase = function (key) { + return key.replace(/([A-Z]+)/g, function (m, letter) { + return '-' + letter.toLowerCase(); + }); +}; + + +/***/ }), +/* 51 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +Object.defineProperty(exports, "__esModule", { value: true }); +var isNumeric_1 = __webpack_require__(22); +exports.normilizeCSSValue = function (key, value) { + switch (key.toLowerCase()) { + case 'font-weight': + switch (value.toString().toLowerCase()) { + case 'bold': + return 700; + case 'normal': + return 400; + case 'heavy': + return 900; + } + return isNumeric_1.isNumeric(value) ? +value : value; + } + return value; +}; + + +/***/ }), +/* 52 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +Object.defineProperty(exports, "__esModule", { value: true }); +var completeUrl_1 = __webpack_require__(53); +var alreadyLoadedList = new Map(); +var cacheLoaders = function (loader) { + return function (url, doc) { + if (alreadyLoadedList.has(url)) { + return alreadyLoadedList.get(url); + } + var promise = loader(url, doc); + alreadyLoadedList.set(url, promise); + return promise; + }; +}; +exports.appendScript = function (url, callback, className, doc) { + var script = doc.createElement('script'); + script.className = className; + script.type = 'text/javascript'; + if (callback !== undefined) { + script.addEventListener('load', callback); + } + script.src = completeUrl_1.completeUrl(url); + doc.body.appendChild(script); + return { + callback: callback, + element: script + }; +}; +exports.appendScriptAsync = cacheLoaders(function (url, doc) { + if (doc === void 0) { doc = document; } + return new Promise(function (resolve, reject) { + var element = exports.appendScript(url, resolve, '', doc).element; + element.addEventListener('error', reject); + }); +}); +exports.appendStyleAsync = cacheLoaders(function (url, doc) { + if (doc === void 0) { doc = document; } + return new Promise(function (resolve, reject) { + var link = doc.createElement('link'); + link.rel = 'stylesheet'; + link.media = 'all'; + link.crossOrigin = 'anonymous'; + link.addEventListener('load', function () { return resolve(link); }); + link.addEventListener('error', reject); + link.href = completeUrl_1.completeUrl(url); + doc.body.appendChild(link); + }); +}); + + +/***/ }), +/* 53 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +Object.defineProperty(exports, "__esModule", { value: true }); +exports.completeUrl = function (url) { + if (window.location.protocol === 'file:' && /^\/\//.test(url)) { + url = 'https:' + url; + } + return url; +}; + + +/***/ }), +/* 54 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +Object.defineProperty(exports, "__esModule", { value: true }); +exports.parseQuery = function (queryString) { + var query = {}, a = queryString.substr(1).split('&'); + for (var i = 0; i < a.length; i += 1) { + var keyValue = a[i].split('='); + query[decodeURIComponent(keyValue[0])] = decodeURIComponent(keyValue[1] || ''); + } + return query; +}; + + +/***/ }), +/* 55 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +Object.defineProperty(exports, "__esModule", { value: true }); +exports.ctrlKey = function (e) { + if (typeof navigator !== 'undefined' && + navigator.userAgent.indexOf('Mac OS X') !== -1) { + if (e.metaKey && !e.altKey) { + return true; + } + } + else if (e.ctrlKey && !e.altKey) { + return true; + } + return false; +}; + + +/***/ }), +/* 56 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +Object.defineProperty(exports, "__esModule", { value: true }); +var checker_1 = __webpack_require__(34); +exports.buildQuery = function (data, prefix) { + var str = []; + var enc = encodeURIComponent; + for (var dataKey in data) { + if (data.hasOwnProperty(dataKey)) { + var k = prefix ? prefix + '[' + dataKey + ']' : dataKey; + var v = data[dataKey]; + str.push(checker_1.isPlainObject(v) ? exports.buildQuery(v, k) : enc(k) + '=' + enc(v)); + } + } + return str.join('&'); +}; + + +/***/ }), +/* 57 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +Object.defineProperty(exports, "__esModule", { value: true }); +var tslib_1 = __webpack_require__(1); +var Config_1 = __webpack_require__(3); +var Component_1 = __webpack_require__(8); +var async_1 = __webpack_require__(5); +var Snapshot_1 = __webpack_require__(58); +var Stack_1 = __webpack_require__(59); +var command_1 = __webpack_require__(119); +Config_1.Config.prototype.observer = { + timeout: 100 +}; +var Observer = (function (_super) { + tslib_1.__extends(Observer, _super); + function Observer(editor) { + var _this = _super.call(this, editor) || this; + _this.onChangeStack = function () { + _this.__newValue = _this.snapshot.make(); + if (!Snapshot_1.Snapshot.equal(_this.__newValue, _this.__startValue)) { + _this.stack.push(new command_1.Command(_this.__startValue, _this.__newValue, _this)); + _this.__startValue = _this.__newValue; + _this.changeStack(); + } + }; + _this.stack = new Stack_1.Stack(); + _this.snapshot = new Snapshot_1.Snapshot(editor); + var onChangeStack = async_1.debounce(_this.onChangeStack, editor.defaultTimeout); + editor.events.on('afterInit.observer', function () { + if (_this.isDestructed) { + return; + } + _this.__startValue = _this.snapshot.make(); + editor.events + .on('changeSelection.observer selectionstart.observer selectionchange.observer mousedown.observer mouseup.observer keydown.observer keyup.observer', function () { + if (_this.__startValue.html === + _this.jodit.getNativeEditorValue()) { + _this.__startValue = _this.snapshot.make(); + } + }) + .on('change.observer', function () { + if (!_this.snapshot.isBlocked) { + onChangeStack(); + } + }); + }); + return _this; + } + Observer.prototype.redo = function () { + if (this.stack.redo()) { + this.__startValue = this.snapshot.make(); + this.changeStack(); + } + }; + Observer.prototype.undo = function () { + if (this.stack.undo()) { + this.__startValue = this.snapshot.make(); + this.changeStack(); + } + }; + Observer.prototype.clear = function () { + this.__startValue = this.snapshot.make(); + this.stack.clear(); + this.changeStack(); + }; + Observer.prototype.changeStack = function () { + this.jodit && + !this.jodit.isDestructed && + this.jodit.events && + this.jodit.events.fire('changeStack'); + }; + Observer.prototype.destruct = function () { + if (this.jodit.events) { + this.jodit.events.off('.observer'); + } + this.snapshot.destruct(); + delete this.snapshot; + delete this.stack; + _super.prototype.destruct.call(this); + }; + return Observer; +}(Component_1.Component)); +exports.Observer = Observer; + + +/***/ }), +/* 58 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +Object.defineProperty(exports, "__esModule", { value: true }); +var tslib_1 = __webpack_require__(1); +var Component_1 = __webpack_require__(8); +var Dom_1 = __webpack_require__(0); +var Snapshot = (function (_super) { + tslib_1.__extends(Snapshot, _super); + function Snapshot() { + var _this = _super !== null && _super.apply(this, arguments) || this; + _this.isBlocked = false; + return _this; + } + Snapshot.equal = function (first, second) { + return (first.html === second.html && + JSON.stringify(first.range) === JSON.stringify(second.range)); + }; + Snapshot.countNodesBeforeInParent = function (elm) { + if (!elm.parentNode) { + return 0; + } + var elms = elm.parentNode.childNodes; + var count = 0, last = null, j; + for (j = 0; j < elms.length; j += 1) { + if (last && + (!(elms[j].nodeType === Node.TEXT_NODE && + elms[j].textContent === '') && + !(last.nodeType === Node.TEXT_NODE && + elms[j].nodeType === Node.TEXT_NODE))) { + count += 1; + } + if (elms[j] === elm) { + return count; + } + last = elms[j]; + } + return 0; + }; + Snapshot.strokeOffset = function (elm, offset) { + while (elm && elm.nodeType === Node.TEXT_NODE) { + elm = elm.previousSibling; + if (elm && + elm.nodeType === Node.TEXT_NODE && + elm.textContent !== null) { + offset += elm.textContent.length; + } + } + return offset; + }; + Snapshot.prototype.calcHierarchyLadder = function (elm) { + var counts = []; + if (!elm || + !elm.parentNode || + !Dom_1.Dom.isOrContains(this.jodit.editor, elm)) { + return []; + } + while (elm && elm !== this.jodit.editor) { + if (elm) { + counts.push(Snapshot.countNodesBeforeInParent(elm)); + } + elm = elm.parentNode; + } + return counts.reverse(); + }; + Snapshot.prototype.getElementByLadder = function (ladder) { + var n = this.jodit.editor, i; + for (i = 0; n && i < ladder.length; i += 1) { + n = n.childNodes[ladder[i]]; + } + return n; + }; + Snapshot.prototype.make = function () { + var snapshot = { + html: '', + range: { + startContainer: [], + startOffset: 0, + endContainer: [], + endOffset: 0 + } + }; + snapshot.html = this.jodit.getNativeEditorValue(); + var sel = this.jodit.selection.sel; + if (sel && sel.rangeCount) { + var range = sel.getRangeAt(0), startContainer = this.calcHierarchyLadder(range.startContainer), endContainer = this.calcHierarchyLadder(range.endContainer); + var startOffset = Snapshot.strokeOffset(range.startContainer, range.startOffset), endOffset = Snapshot.strokeOffset(range.endContainer, range.endOffset); + if (!startContainer.length && + range.startContainer !== this.jodit.editor) { + startOffset = 0; + } + if (!endContainer.length && + range.endContainer !== this.jodit.editor) { + endOffset = 0; + } + snapshot.range = { + startContainer: startContainer, + startOffset: startOffset, + endContainer: endContainer, + endOffset: endOffset + }; + } + return snapshot; + }; + Snapshot.prototype.restore = function (snapshot) { + this.isBlocked = true; + this.jodit.setEditorValue(snapshot.html); + try { + if (snapshot.range) { + var range = this.jodit.editorDocument.createRange(); + range.setStart(this.getElementByLadder(snapshot.range.startContainer), snapshot.range.startOffset); + range.setEnd(this.getElementByLadder(snapshot.range.endContainer), snapshot.range.endOffset); + this.jodit.selection.selectRange(range); + } + } + catch (__ignore) { + if (false) {} + } + this.isBlocked = false; + }; + Snapshot.prototype.destruct = function () { + this.isBlocked = false; + _super.prototype.destruct.call(this); + }; + return Snapshot; +}(Component_1.Component)); +exports.Snapshot = Snapshot; + + +/***/ }), +/* 59 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +Object.defineProperty(exports, "__esModule", { value: true }); +var Stack = (function () { + function Stack() { + this.commands = []; + this.stackPosition = -1; + } + Stack.prototype.clearRedo = function () { + this.commands.length = this.stackPosition + 1; + }; + Stack.prototype.clear = function () { + this.commands.length = 0; + this.stackPosition = -1; + }; + Stack.prototype.push = function (command) { + this.clearRedo(); + this.commands.push(command); + this.stackPosition += 1; + }; + Stack.prototype.undo = function () { + if (this.canUndo()) { + if (this.commands[this.stackPosition]) { + this.commands[this.stackPosition].undo(); + } + this.stackPosition -= 1; + return true; + } + return false; + }; + Stack.prototype.redo = function () { + if (this.canRedo()) { + this.stackPosition += 1; + if (this.commands[this.stackPosition]) { + this.commands[this.stackPosition].redo(); + } + return true; + } + return false; + }; + Stack.prototype.canUndo = function () { + return this.stackPosition >= 0; + }; + Stack.prototype.canRedo = function () { + return this.stackPosition < this.commands.length - 1; + }; + return Stack; +}()); +exports.Stack = Stack; + + +/***/ }), +/* 60 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +Object.defineProperty(exports, "__esModule", { value: true }); +var consts = __webpack_require__(2); +var constants_1 = __webpack_require__(2); +var Dom_1 = __webpack_require__(0); +var css_1 = __webpack_require__(10); +var normalize_1 = __webpack_require__(20); +var selector_1 = __webpack_require__(13); +var checker_1 = __webpack_require__(34); +var each_1 = __webpack_require__(24); +var string_1 = __webpack_require__(9); +var Select = (function () { + function Select(jodit) { + var _this = this; + this.jodit = jodit; + this.isMarker = function (elm) { + return Dom_1.Dom.isNode(elm, _this.win) && + elm.nodeType === Node.ELEMENT_NODE && + elm.nodeName === 'SPAN' && + elm.hasAttribute('data-' + consts.MARKER_CLASS); + }; + this.focus = function () { + var _a, _b; + if (!_this.isFocused()) { + if (_this.jodit.iframe) { + if (_this.doc.readyState == 'complete') { + _this.jodit.iframe.focus(); + } + } + _this.win.focus(); + _this.area.focus(); + var sel = _this.sel, range = _this.createRange(); + if (sel && (!sel.rangeCount || !_this.current())) { + range.setStart(_this.area, 0); + range.collapse(true); + sel.removeAllRanges(); + sel.addRange(range); + } + if (!_this.jodit.editorIsActive) { + (_b = (_a = _this.jodit) === null || _a === void 0 ? void 0 : _a.events) === null || _b === void 0 ? void 0 : _b.fire('focus'); + } + return true; + } + return false; + }; + this.eachSelection = function (callback) { + var sel = _this.sel; + if (sel && sel.rangeCount) { + var range = sel.getRangeAt(0); + var nodes_1 = [], startOffset = range.startOffset, length_1 = _this.area.childNodes.length, elementOffset = startOffset < length_1 ? startOffset : length_1 - 1, start = range.startContainer === _this.area + ? _this.area.childNodes[elementOffset] + : range.startContainer, end_1 = range.endContainer === _this.area + ? _this.area.childNodes[range.endOffset - 1] + : range.endContainer; + Dom_1.Dom.find(start, function (node) { + if (node && + node !== _this.area && + !Dom_1.Dom.isEmptyTextNode(node) && + !_this.isMarker(node)) { + nodes_1.push(node); + } + return node === end_1 || (node && node.contains(end_1)); + }, _this.area, true, 'nextSibling', false); + var forEvery_1 = function (current) { + if (current.nodeName.match(/^(UL|OL)$/)) { + return Array.from(current.childNodes).forEach(forEvery_1); + } + if (current.nodeName === 'LI') { + if (current.firstChild) { + current = current.firstChild; + } + else { + var currentB = _this.jodit.create.inside.text(constants_1.INVISIBLE_SPACE); + current.appendChild(currentB); + current = currentB; + } + } + callback(current); + }; + if (nodes_1.length === 0 && Dom_1.Dom.isEmptyTextNode(start)) { + nodes_1.push(start); + } + nodes_1.forEach(forEvery_1); + } + }; + } + Select.prototype.errorNode = function (node) { + if (!Dom_1.Dom.isNode(node, this.win)) { + throw new Error('Parameter node must be instance of Node'); + } + }; + Object.defineProperty(Select.prototype, "area", { + get: function () { + return this.jodit.editor; + }, + enumerable: true, + configurable: true + }); + Object.defineProperty(Select.prototype, "win", { + get: function () { + return this.jodit.editorWindow; + }, + enumerable: true, + configurable: true + }); + Object.defineProperty(Select.prototype, "doc", { + get: function () { + return this.jodit.editorDocument; + }, + enumerable: true, + configurable: true + }); + Object.defineProperty(Select.prototype, "sel", { + get: function () { + return this.win.getSelection(); + }, + enumerable: true, + configurable: true + }); + Object.defineProperty(Select.prototype, "range", { + get: function () { + var sel = this.sel; + return sel && sel.rangeCount ? sel.getRangeAt(0) : this.createRange(); + }, + enumerable: true, + configurable: true + }); + Select.prototype.createRange = function () { + return this.doc.createRange(); + }; + Select.prototype.remove = function () { + var sel = this.sel, current = this.current(); + if (sel && current) { + for (var i = 0; i < sel.rangeCount; i += 1) { + sel.getRangeAt(i).deleteContents(); + sel.getRangeAt(i).collapse(true); + } + } + }; + Select.prototype.insertCursorAtPoint = function (x, y) { + this.removeMarkers(); + try { + var rng = this.createRange(); + if (this.doc.caretPositionFromPoint) { + var caret = this + .doc.caretPositionFromPoint(x, y); + rng.setStart(caret.offsetNode, caret.offset); + } + else if (this.doc.caretRangeFromPoint) { + var caret = this.doc.caretRangeFromPoint(x, y); + rng.setStart(caret.startContainer, caret.startOffset); + } + if (rng) { + rng.collapse(true); + var sel = this.sel; + if (sel) { + sel.removeAllRanges(); + sel.addRange(rng); + } + } + else if (typeof this.doc.body.createTextRange !== 'undefined') { + var range = this.doc.body.createTextRange(); + range.moveToPoint(x, y); + var endRange = range.duplicate(); + endRange.moveToPoint(x, y); + range.setEndPoint('EndToEnd', endRange); + range.select(); + } + return true; + } + catch (_a) { } + return false; + }; + Select.prototype.removeMarkers = function () { + selector_1.$$('span[data-' + consts.MARKER_CLASS + ']', this.area).forEach(Dom_1.Dom.safeRemove); + }; + Select.prototype.marker = function (atStart, range) { + if (atStart === void 0) { atStart = false; } + var newRange = null; + if (range) { + newRange = range.cloneRange(); + newRange.collapse(atStart); + } + var marker = this.jodit.create.inside.span(); + marker.id = + consts.MARKER_CLASS + + '_' + + +new Date() + + '_' + + ('' + Math.random()).slice(2); + marker.style.lineHeight = '0'; + marker.style.display = 'none'; + marker.setAttribute('data-' + consts.MARKER_CLASS, atStart ? 'start' : 'end'); + marker.appendChild(this.jodit.create.inside.text(consts.INVISIBLE_SPACE)); + if (newRange) { + if (Dom_1.Dom.isOrContains(this.area, atStart ? newRange.startContainer : newRange.endContainer)) { + newRange.insertNode(marker); + } + } + return marker; + }; + Select.prototype.restore = function (selectionInfo) { + var _this = this; + if (selectionInfo === void 0) { selectionInfo = []; } + if (Array.isArray(selectionInfo)) { + var sel_1 = this.sel; + sel_1 && sel_1.removeAllRanges(); + selectionInfo.forEach(function (selection) { + var range = _this.createRange(), end = _this.area.querySelector('#' + selection.endId), start = _this.area.querySelector('#' + selection.startId); + if (!start) { + return; + } + if (selection.collapsed || !end) { + var previousNode = start.previousSibling; + if (previousNode && + previousNode.nodeType === Node.TEXT_NODE) { + range.setStart(previousNode, previousNode.nodeValue + ? previousNode.nodeValue.length + : 0); + } + else { + range.setStartBefore(start); + } + Dom_1.Dom.safeRemove(start); + range.collapse(true); + } + else { + range.setStartAfter(start); + Dom_1.Dom.safeRemove(start); + range.setEndBefore(end); + Dom_1.Dom.safeRemove(end); + } + sel_1 && sel_1.addRange(range); + }); + } + }; + Select.prototype.save = function () { + var sel = this.sel; + if (!sel || !sel.rangeCount) { + return []; + } + var info = [], length = sel.rangeCount, ranges = []; + var i, start, end; + for (i = 0; i < length; i += 1) { + ranges[i] = sel.getRangeAt(i); + if (ranges[i].collapsed) { + start = this.marker(true, ranges[i]); + info[i] = { + startId: start.id, + collapsed: true, + startMarker: start.outerHTML + }; + } + else { + start = this.marker(true, ranges[i]); + end = this.marker(false, ranges[i]); + info[i] = { + startId: start.id, + endId: end.id, + collapsed: false, + startMarker: start.outerHTML, + endMarker: end.outerHTML + }; + } + } + sel.removeAllRanges(); + for (i = length - 1; i >= 0; --i) { + var startElm = this.doc.getElementById(info[i].startId); + if (startElm) { + if (info[i].collapsed) { + ranges[i].setStartAfter(startElm); + ranges[i].collapse(true); + } + else { + ranges[i].setStartBefore(startElm); + if (info[i].endId) { + var endElm = this.doc.getElementById(info[i].endId); + if (endElm) { + ranges[i].setEndAfter(endElm); + } + } + } + } + try { + sel.addRange(ranges[i].cloneRange()); + } + catch (_a) { } + } + return info; + }; + Select.prototype.isCollapsed = function () { + var sel = this.sel; + for (var r = 0; sel && r < sel.rangeCount; r += 1) { + if (!sel.getRangeAt(r).collapsed) { + return false; + } + } + return true; + }; + Select.prototype.isFocused = function () { + return (this.doc.hasFocus && + this.doc.hasFocus() && + this.area === this.doc.activeElement); + }; + Select.prototype.current = function (checkChild) { + if (checkChild === void 0) { checkChild = true; } + if (this.jodit.getRealMode() === consts.MODE_WYSIWYG) { + var sel = this.sel; + if (sel && sel.rangeCount > 0) { + var range = sel.getRangeAt(0); + var node = range.startContainer, rightMode_1 = false; + var child = function (nd) { + return rightMode_1 ? nd.lastChild : nd.firstChild; + }; + if (node.nodeType !== Node.TEXT_NODE) { + node = range.startContainer.childNodes[range.startOffset]; + if (!node) { + node = + range.startContainer.childNodes[range.startOffset - 1]; + rightMode_1 = true; + } + if (node && + sel.isCollapsed && + node.nodeType !== Node.TEXT_NODE) { + if (!rightMode_1 && + node.previousSibling && + node.previousSibling.nodeType === Node.TEXT_NODE) { + node = node.previousSibling; + } + else if (checkChild) { + var current = child(node); + while (current) { + if (current && + current.nodeType === Node.TEXT_NODE) { + node = current; + break; + } + current = child(current); + } + } + } + if (node && + !sel.isCollapsed && + node.nodeType !== Node.TEXT_NODE) { + var leftChild = node, rightChild = node; + do { + leftChild = leftChild.firstChild; + rightChild = rightChild.lastChild; + } while (leftChild && + rightChild && + leftChild.nodeType !== Node.TEXT_NODE); + if (leftChild === rightChild && + leftChild && + leftChild.nodeType === Node.TEXT_NODE) { + node = leftChild; + } + } + } + if (node && Dom_1.Dom.isOrContains(this.area, node)) { + return node; + } + } + } + return false; + }; + Select.prototype.insertNode = function (node, insertCursorAfter, fireChange) { + if (insertCursorAfter === void 0) { insertCursorAfter = true; } + if (fireChange === void 0) { fireChange = true; } + this.errorNode(node); + this.focus(); + var sel = this.sel; + if (!this.isCollapsed()) { + this.jodit.execCommand('Delete'); + } + if (sel && sel.rangeCount) { + var range = sel.getRangeAt(0); + if (Dom_1.Dom.isOrContains(this.area, range.commonAncestorContainer)) { + range.deleteContents(); + range.insertNode(node); + } + else { + this.area.appendChild(node); + } + } + else { + this.area.appendChild(node); + } + if (insertCursorAfter) { + this.setCursorAfter(node); + } + if (fireChange && this.jodit.events) { + this.jodit.events.fire('synchro'); + } + if (this.jodit.events) { + this.jodit.events.fire('afterInsertNode', node); + } + }; + Select.prototype.insertHTML = function (html) { + if (html === '') { + return; + } + var node = this.jodit.create.inside.div(), fragment = this.jodit.create.inside.fragment(); + var lastChild, lastEditorElement; + if (!this.isFocused() && this.jodit.isEditorMode()) { + this.focus(); + } + if (!Dom_1.Dom.isNode(html, this.win)) { + node.innerHTML = html.toString(); + } + else { + node.appendChild(html); + } + if (!this.jodit.isEditorMode() && + this.jodit.events.fire('insertHTML', node.innerHTML) === false) { + return; + } + lastChild = node.lastChild; + if (!lastChild) { + return; + } + while (node.firstChild) { + lastChild = node.firstChild; + fragment.appendChild(node.firstChild); + } + this.insertNode(fragment, false); + if (lastChild) { + this.setCursorAfter(lastChild); + } + else { + this.setCursorIn(fragment); + } + lastEditorElement = this.area.lastChild; + while (lastEditorElement && + lastEditorElement.nodeType === Node.TEXT_NODE && + lastEditorElement.previousSibling && + lastEditorElement.nodeValue && + /^\s*$/.test(lastEditorElement.nodeValue)) { + lastEditorElement = lastEditorElement.previousSibling; + } + if (lastChild) { + if (lastEditorElement && + lastChild === lastEditorElement && + lastChild.nodeType === Node.ELEMENT_NODE) { + this.area.appendChild(this.jodit.create.inside.element('br')); + } + this.setCursorAfter(lastChild); + } + }; + Select.prototype.insertImage = function (url, styles, defaultWidth) { + var image = typeof url === 'string' + ? this.jodit.create.inside.element('img') + : url; + if (typeof url === 'string') { + image.setAttribute('src', url); + } + if (defaultWidth !== null) { + var dw = defaultWidth.toString(); + if (dw && + 'auto' !== dw && + String(dw).indexOf('px') < 0 && + String(dw).indexOf('%') < 0) { + dw += 'px'; + } + css_1.css(image, 'width', dw); + } + if (styles && typeof styles === 'object') { + css_1.css(image, styles); + } + var onload = function () { + if (image.naturalHeight < image.offsetHeight || + image.naturalWidth < image.offsetWidth) { + image.style.width = ''; + image.style.height = ''; + } + image.removeEventListener('load', onload); + }; + image.addEventListener('load', onload); + if (image.complete) { + onload(); + } + var result = this.insertNode(image); + this.jodit.events.fire('afterInsertImage', image); + return result; + }; + Select.prototype.setCursorAfter = function (node) { + var _this = this; + this.errorNode(node); + if (!Dom_1.Dom.up(node, function (elm) { + return elm === _this.area || (elm && elm.parentNode === _this.area); + }, this.area)) { + throw new Error('Node element must be in editor'); + } + var range = this.createRange(); + var fakeNode = false; + if (node.nodeType !== Node.TEXT_NODE) { + fakeNode = this.doc.createTextNode(consts.INVISIBLE_SPACE); + range.setStartAfter(node); + range.insertNode(fakeNode); + range.selectNode(fakeNode); + } + else { + range.setEnd(node, node.nodeValue !== null ? node.nodeValue.length : 0); + } + range.collapse(false); + this.selectRange(range); + return fakeNode; + }; + Select.prototype.cursorInTheEdge = function (start, parentBlock) { + var sel = this.sel, range = sel && sel.rangeCount ? sel.getRangeAt(0) : null; + if (!range) { + return null; + } + var container = start ? range.startContainer : range.endContainer, sibling = function (node) { + return start + ? Dom_1.Dom.prev(node, function (elm) { return !!elm; }, parentBlock) + : Dom_1.Dom.next(node, function (elm) { return !!elm; }, parentBlock); + }, checkSiblings = function (next) { + while (next) { + next = sibling(next); + if (next && + !Dom_1.Dom.isEmptyTextNode(next) && + next.nodeName !== 'BR') { + return false; + } + } + }; + if (container.nodeType === Node.TEXT_NODE) { + var value = container.nodeValue || ''; + if (start && + range.startOffset > + value.length - + value.replace(constants_1.INVISIBLE_SPACE_REG_EXP_START, '').length) { + return false; + } + if (!start && + range.startOffset < + value.replace(constants_1.INVISIBLE_SPACE_REG_EXP_END, '').length) { + return false; + } + if (checkSiblings(container) === false) { + return false; + } + } + var current = this.current(false); + if (!current || !Dom_1.Dom.isOrContains(parentBlock, current, true)) { + return null; + } + if (!start && range.startContainer.childNodes[range.startOffset]) { + if (current && !Dom_1.Dom.isEmptyTextNode(current)) { + return false; + } + } + return checkSiblings(current) !== false; + }; + Select.prototype.setCursorBefore = function (node) { + var _this = this; + this.errorNode(node); + if (!Dom_1.Dom.up(node, function (elm) { + return elm === _this.area || (elm && elm.parentNode === _this.area); + }, this.area)) { + throw new Error('Node element must be in editor'); + } + var range = this.createRange(); + var fakeNode = false; + if (node.nodeType !== Node.TEXT_NODE) { + fakeNode = this.doc.createTextNode(consts.INVISIBLE_SPACE); + range.setStartBefore(node); + range.collapse(true); + range.insertNode(fakeNode); + range.selectNode(fakeNode); + } + else { + range.setStart(node, node.nodeValue !== null ? node.nodeValue.length : 0); + } + range.collapse(true); + this.selectRange(range); + return fakeNode; + }; + Select.prototype.setCursorIn = function (node, inStart) { + var _this = this; + if (inStart === void 0) { inStart = false; } + this.errorNode(node); + if (!Dom_1.Dom.up(node, function (elm) { + return elm === _this.area || (elm && elm.parentNode === _this.area); + }, this.area)) { + throw new Error('Node element must be in editor'); + } + var range = this.createRange(); + var start = node, last = node; + do { + if (start.nodeType === Node.TEXT_NODE) { + break; + } + last = start; + start = inStart ? start.firstChild : start.lastChild; + } while (start); + if (!start) { + var fakeNode = this.doc.createTextNode(consts.INVISIBLE_SPACE); + if (!/^(img|br|input)$/i.test(last.nodeName)) { + last.appendChild(fakeNode); + last = fakeNode; + } + else { + start = last; + } + } + range.selectNodeContents(start || last); + range.collapse(inStart); + this.selectRange(range); + return last; + }; + Select.prototype.selectRange = function (range) { + var sel = this.sel; + if (sel) { + sel.removeAllRanges(); + sel.addRange(range); + } + this.jodit.events.fire('changeSelection'); + }; + Select.prototype.select = function (node, inward) { + var _this = this; + if (inward === void 0) { inward = false; } + this.errorNode(node); + if (!Dom_1.Dom.up(node, function (elm) { + return elm === _this.area || (elm && elm.parentNode === _this.area); + }, this.area)) { + throw new Error('Node element must be in editor'); + } + var range = this.createRange(); + range[inward ? 'selectNodeContents' : 'selectNode'](node); + this.selectRange(range); + }; + Select.prototype.getHTML = function () { + var sel = this.sel; + if (sel && sel.rangeCount > 0) { + var range = sel.getRangeAt(0); + var clonedSelection = range.cloneContents(); + var div = this.jodit.create.inside.div(); + div.appendChild(clonedSelection); + return div.innerHTML; + } + return ''; + }; + Select.prototype.applyCSS = function (cssRules, nodeName, options) { + var _this = this; + if (nodeName === void 0) { nodeName = 'span'; } + var WRAP = 1, UNWRAP = 0, defaultTag = 'SPAN', FONT = 'FONT'; + var mode; + var findNextCondition = function (elm) { + return elm !== null && + !Dom_1.Dom.isEmptyTextNode(elm) && + !_this.isMarker(elm); + }; + var checkCssRulesFor = function (elm) { + return (elm.nodeName !== FONT && + elm.nodeType === Node.ELEMENT_NODE && + ((checker_1.isPlainObject(options) && + each_1.each(options, function (cssPropertyKey, cssPropertyValues) { + var value = css_1.css(elm, cssPropertyKey, undefined, true); + return (value !== null && + value !== '' && + cssPropertyValues.indexOf(value.toString().toLowerCase()) !== -1); + })) || + (typeof options === 'function' && options(_this.jodit, elm)))); + }; + var isSuitElement = function (elm) { + if (!elm) { + return false; + } + var reg = new RegExp('^' + elm.nodeName + '$', 'i'); + return ((reg.test(nodeName) || + !!(options && checkCssRulesFor(elm))) && + findNextCondition(elm)); + }; + var toggleStyles = function (elm) { + if (isSuitElement(elm)) { + if (elm.nodeName === defaultTag && cssRules) { + Object.keys(cssRules).forEach(function (rule) { + if (mode === UNWRAP || + css_1.css(elm, rule) === + normalize_1.normilizeCSSValue(rule, cssRules[rule])) { + css_1.css(elm, rule, ''); + if (mode === undefined) { + mode = UNWRAP; + } + } + else { + css_1.css(elm, rule, cssRules[rule]); + if (mode === undefined) { + mode = WRAP; + } + } + }); + } + if (!Dom_1.Dom.isBlock(elm, _this.win) && + (!elm.getAttribute('style') || elm.nodeName !== defaultTag)) { + Dom_1.Dom.unwrap(elm); + if (mode === undefined) { + mode = UNWRAP; + } + } + } + }; + if (!this.isCollapsed()) { + var selInfo = this.save(); + normalize_1.normalizeNode(this.area.firstChild); + selector_1.$$('*[style*=font-size]', this.area).forEach(function (elm) { + elm.style && + elm.style.fontSize && + elm.setAttribute('data-font-size', elm.style.fontSize.toString()); + }); + this.doc.execCommand('fontsize', false, '7'); + selector_1.$$('*[data-font-size]', this.area).forEach(function (elm) { + var fontSize = elm.getAttribute('data-font-size'); + if (elm.style && fontSize) { + elm.style.fontSize = fontSize; + elm.removeAttribute('data-font-size'); + } + }); + selector_1.$$('font[size="7"]', this.area).forEach(function (font) { + if (!Dom_1.Dom.next(font, findNextCondition, font.parentNode) && + !Dom_1.Dom.prev(font, findNextCondition, font.parentNode) && + isSuitElement(font.parentNode) && + font.parentNode !== _this.area && + (!Dom_1.Dom.isBlock(font.parentNode, _this.win) || + consts.IS_BLOCK.test(nodeName))) { + toggleStyles(font.parentNode); + } + else if (font.firstChild && + !Dom_1.Dom.next(font.firstChild, findNextCondition, font) && + !Dom_1.Dom.prev(font.firstChild, findNextCondition, font) && + isSuitElement(font.firstChild)) { + toggleStyles(font.firstChild); + } + else if (Dom_1.Dom.closest(font, isSuitElement, _this.area)) { + var leftRange = _this.createRange(), wrapper = Dom_1.Dom.closest(font, isSuitElement, _this.area); + leftRange.setStartBefore(wrapper); + leftRange.setEndBefore(font); + var leftFragment = leftRange.extractContents(); + if ((!leftFragment.textContent || + !string_1.trim(leftFragment.textContent).length) && + leftFragment.firstChild) { + Dom_1.Dom.unwrap(leftFragment.firstChild); + } + if (wrapper.parentNode) { + wrapper.parentNode.insertBefore(leftFragment, wrapper); + } + leftRange.setStartAfter(font); + leftRange.setEndAfter(wrapper); + var rightFragment = leftRange.extractContents(); + if ((!rightFragment.textContent || + !string_1.trim(rightFragment.textContent).length) && + rightFragment.firstChild) { + Dom_1.Dom.unwrap(rightFragment.firstChild); + } + Dom_1.Dom.after(wrapper, rightFragment); + toggleStyles(wrapper); + } + else { + var needUnwrap_1 = []; + var firstElementSuit_1; + if (font.firstChild) { + Dom_1.Dom.find(font.firstChild, function (elm) { + if (elm && isSuitElement(elm)) { + if (firstElementSuit_1 === undefined) { + firstElementSuit_1 = true; + } + needUnwrap_1.push(elm); + } + else { + if (firstElementSuit_1 === undefined) { + firstElementSuit_1 = false; + } + } + return false; + }, font, true); + } + needUnwrap_1.forEach(Dom_1.Dom.unwrap); + if (!firstElementSuit_1) { + if (mode === undefined) { + mode = WRAP; + } + if (mode === WRAP) { + css_1.css(Dom_1.Dom.replace(font, nodeName, false, false, _this.doc), cssRules && + nodeName.toUpperCase() === defaultTag + ? cssRules + : {}); + } + } + } + if (font.parentNode) { + Dom_1.Dom.unwrap(font); + } + }); + this.restore(selInfo); + } + else { + var clearStyle = false; + if (this.current() && + Dom_1.Dom.closest(this.current(), nodeName, this.area)) { + clearStyle = true; + var closest = Dom_1.Dom.closest(this.current(), nodeName, this.area); + if (closest) { + this.setCursorAfter(closest); + } + } + if (nodeName.toUpperCase() === defaultTag || !clearStyle) { + var node = this.jodit.create.inside.element(nodeName); + node.appendChild(this.jodit.create.inside.text(consts.INVISIBLE_SPACE)); + this.insertNode(node, false, false); + if (nodeName.toUpperCase() === defaultTag && cssRules) { + css_1.css(node, cssRules); + } + this.setCursorIn(node); + } + } + }; + return Select; +}()); +exports.Select = Select; + + +/***/ }), +/* 61 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +Object.defineProperty(exports, "__esModule", { value: true }); +exports.canUsePersistentStorage = (function () { + var canUse = function () { + var tmpKey = '___Jodit___' + Math.random().toString(); + try { + localStorage.setItem(tmpKey, '1'); + var result_1 = localStorage.getItem(tmpKey) === '1'; + localStorage.removeItem(tmpKey); + return result_1; + } + catch (_a) { } + return false; + }; + var result; + return function () { + if (result === undefined) { + result = canUse(); + } + return result; + }; +})(); +var LocalStorageProvider = (function () { + function LocalStorageProvider(rootKey) { + this.rootKey = rootKey; + } + LocalStorageProvider.prototype.set = function (key, value) { + try { + var buffer = localStorage.getItem(this.rootKey); + var json = buffer ? JSON.parse(buffer) : {}; + json[key] = value; + localStorage.setItem(this.rootKey, JSON.stringify(json)); + } + catch (_a) { } + }; + LocalStorageProvider.prototype.get = function (key) { + try { + var buffer = localStorage.getItem(this.rootKey); + var json = buffer ? JSON.parse(buffer) : {}; + return json[key] !== undefined ? json[key] : null; + } + catch (_a) { } + }; + LocalStorageProvider.prototype.exists = function (key) { + return this.get(key) !== null; + }; + LocalStorageProvider.prototype.clear = function () { + try { + localStorage.removeItem(this.rootKey); + } + catch (_a) { } + }; + return LocalStorageProvider; +}()); +exports.LocalStorageProvider = LocalStorageProvider; + + +/***/ }), +/* 62 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +Object.defineProperty(exports, "__esModule", { value: true }); +var MemoryStorageProvider = (function () { + function MemoryStorageProvider() { + this.data = new Map(); + } + MemoryStorageProvider.prototype.set = function (key, value) { + this.data.set(key, value); + }; + MemoryStorageProvider.prototype.get = function (key) { + return this.data.get(key); + }; + MemoryStorageProvider.prototype.exists = function (key) { + return this.data.has(key); + }; + MemoryStorageProvider.prototype.clear = function () { + this.data.clear(); + }; + return MemoryStorageProvider; +}()); +exports.MemoryStorageProvider = MemoryStorageProvider; + + +/***/ }), +/* 63 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +Object.defineProperty(exports, "__esModule", { value: true }); +var tslib_1 = __webpack_require__(1); +var view_1 = __webpack_require__(64); +var ViewWithToolbar = (function (_super) { + tslib_1.__extends(ViewWithToolbar, _super); + function ViewWithToolbar() { + var _this = _super !== null && _super.apply(this, arguments) || this; + _this.toolbar = joditToolbarCollection_1.JoditToolbarCollection.makeCollection(_this); + return _this; + } + ViewWithToolbar.prototype.destruct = function () { + this.toolbar.destruct(); + delete this.toolbar; + _super.prototype.destruct.call(this); + }; + return ViewWithToolbar; +}(view_1.View)); +exports.ViewWithToolbar = ViewWithToolbar; +var joditToolbarCollection_1 = __webpack_require__(16); + + +/***/ }), +/* 64 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +Object.defineProperty(exports, "__esModule", { value: true }); +var tslib_1 = __webpack_require__(1); +var eventsNative_1 = __webpack_require__(65); +var panel_1 = __webpack_require__(122); +var storage_1 = __webpack_require__(123); +var helpers_1 = __webpack_require__(4); +var View = (function (_super) { + tslib_1.__extends(View, _super); + function View(jodit, options) { + var _this = _super.call(this, jodit) || this; + _this.version = "3.3.8"; + _this.__modulesInstances = {}; + _this.buffer = storage_1.Storage.makeStorage(); + _this.progress_bar = _this.create.div('jodit_progress_bar', _this.create.div()); + _this.options = { + removeButtons: [], + zIndex: 100002, + fullsize: false, + showTooltip: true, + useNativeTooltip: false, + buttons: [], + globalFullsize: true + }; + _this.components = []; + _this.getVersion = function () { + return _this.version; + }; + _this.id = + jodit && jodit.id ? jodit.id : new Date().getTime().toString(); + _this.jodit = jodit || _this; + _this.events = + jodit && jodit.events + ? jodit.events + : new eventsNative_1.EventsNative(_this.ownerDocument); + _this.buffer = jodit && jodit.buffer ? jodit.buffer : storage_1.Storage.makeStorage(); + _this.options = tslib_1.__assign(tslib_1.__assign({}, _this.options), options); + return _this; + } + Object.defineProperty(View.prototype, "basePath", { + get: function () { + if (this.options.basePath) { + return this.options.basePath; + } + return constants_1.BASE_PATH; + }, + enumerable: true, + configurable: true + }); + Object.defineProperty(View.prototype, "defaultTimeout", { + get: function () { + return 100; + }, + enumerable: true, + configurable: true + }); + View.prototype.i18n = function (text) { + var params = []; + for (var _i = 1; _i < arguments.length; _i++) { + params[_i - 1] = arguments[_i]; + } + var _a, _b, _c; + return helpers_1.i18n(text, params, ((_b = (_a = this) === null || _a === void 0 ? void 0 : _a.jodit) === null || _b === void 0 ? void 0 : _b.options) || ((_c = this) === null || _c === void 0 ? void 0 : _c.options)); + }; + View.prototype.toggleFullSize = function (isFullSize) { + _super.prototype.toggleFullSize.call(this, isFullSize); + if (this.events) { + this.events.fire('toggleFullSize', isFullSize); + } + }; + View.prototype.getInstance = function (moduleName, options) { + if (typeof Jodit_1.Jodit.modules[moduleName] !== 'function') { + throw new Error('Need real module name'); + } + if (this.__modulesInstances[moduleName] === undefined) { + this.__modulesInstances[moduleName] = new Jodit_1.Jodit.modules[moduleName](this.jodit || this, options); + } + return this.__modulesInstances[moduleName]; + }; + View.prototype.destruct = function () { + if (this.isDestructed) { + return; + } + if (this.events) { + this.events.destruct(); + delete this.events; + } + delete this.options; + _super.prototype.destruct.call(this); + }; + return View; +}(panel_1.Panel)); +exports.View = View; +var Jodit_1 = __webpack_require__(11); +var constants_1 = __webpack_require__(2); + + +/***/ }), +/* 65 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * License GNU General License version 2 or later; + * Copyright 2013-2019 Valeriy Chupurnov https://xdsoft.net + */ +Object.defineProperty(exports, "__esModule", { value: true }); +var tslib_1 = __webpack_require__(1); +var store_1 = __webpack_require__(121); +var EventsNative = (function () { + function EventsNative(doc) { + var _this = this; + this.__key = '__JoditEventsNativeNamespaces'; + this.doc = document; + this.__stopped = []; + this.prepareEvent = function (event) { + if (event.cancelBubble) { + return; + } + if (event.type.match(/^touch/) && + event.changedTouches && + event.changedTouches.length) { + ['clientX', 'clientY', 'pageX', 'pageY'].forEach(function (key) { + Object.defineProperty(event, key, { + value: event.changedTouches[0][key], + configurable: true, + enumerable: true + }); + }); + } + if (!event.originalEvent) { + event.originalEvent = event; + } + if (event.type === 'paste' && + event.clipboardData === undefined && + _this.doc.defaultView.clipboardData) { + Object.defineProperty(event, 'clipboardData', { + get: function () { + return _this.doc.defaultView.clipboardData; + }, + configurable: true, + enumerable: true + }); + } + }; + this.current = []; + this.isDestructed = false; + if (doc) { + this.doc = doc; + } + this.__key += new Date().getTime(); + } + EventsNative.prototype.eachEvent = function (events, callback) { + var _this = this; + var eventParts = events.split(/[\s,]+/); + eventParts.forEach(function (eventNameSpace) { + var eventAndNameSpace = eventNameSpace.split('.'); + var namespace = eventAndNameSpace[1] || store_1.defaultNameSpace; + callback.call(_this, eventAndNameSpace[0], namespace); + }); + }; + EventsNative.prototype.getStore = function (subject) { + if (subject[this.__key] === undefined) { + var store = new store_1.EventHandlersStore(); + Object.defineProperty(subject, this.__key, { + enumerable: false, + configurable: true, + value: store + }); + } + return subject[this.__key]; + }; + EventsNative.prototype.clearStore = function (subject) { + if (subject[this.__key] !== undefined) { + delete subject[this.__key]; + } + }; + EventsNative.prototype.triggerNativeEvent = function (element, event) { + var evt = this.doc.createEvent('HTMLEvents'); + if (typeof event === 'string') { + evt.initEvent(event, true, true); + } + else { + evt.initEvent(event.type, event.bubbles, event.cancelable); + [ + 'screenX', + 'screenY', + 'clientX', + 'clientY', + 'target', + 'srcElement', + 'currentTarget', + 'timeStamp', + 'which', + 'keyCode' + ].forEach(function (property) { + Object.defineProperty(evt, property, { + value: event[property], + enumerable: true + }); + }); + Object.defineProperty(evt, 'originalEvent', { + value: event, + enumerable: true + }); + } + element.dispatchEvent(evt); + }; + EventsNative.prototype.removeStop = function (currentBlocks) { + if (currentBlocks) { + var index = this.__stopped.indexOf(currentBlocks); + index !== -1 && this.__stopped.splice(index, 1); + } + }; + EventsNative.prototype.isStopped = function (currentBlocks) { + return (currentBlocks !== undefined && + this.__stopped.indexOf(currentBlocks) !== -1); + }; + EventsNative.prototype.on = function (subjectOrEvents, eventsOrCallback, handlerOrSelector, selector, onTop) { + var _this = this; + if (onTop === void 0) { onTop = false; } + var subject = typeof subjectOrEvents === 'string' ? this : subjectOrEvents; + var events = typeof eventsOrCallback === 'string' + ? eventsOrCallback + : subjectOrEvents; + var callback = handlerOrSelector; + if (callback === undefined && typeof eventsOrCallback === 'function') { + callback = eventsOrCallback; + } + var store = this.getStore(subject); + if (typeof events !== 'string' || events === '') { + throw new Error('Need events names'); + } + if (typeof callback !== 'function') { + throw new Error('Need event handler'); + } + if (Array.isArray(subject)) { + subject.forEach(function (subj) { + _this.on(subj, events, callback, selector); + }); + return this; + } + var isDOMElement = typeof subject.addEventListener === 'function', self = this; + var syntheticCallback = function (event) { + return callback && callback.apply(this, arguments); + }; + if (isDOMElement) { + syntheticCallback = function (event) { + self.prepareEvent(event); + if (callback && callback.call(this, event) === false) { + event.preventDefault(); + event.stopImmediatePropagation(); + return false; + } + return; + }; + if (selector) { + syntheticCallback = function (event) { + self.prepareEvent(event); + var node = event.target; + while (node && node !== this) { + if (node.matches(selector)) { + Object.defineProperty(event, 'target', { + value: node, + configurable: true, + enumerable: true + }); + if (callback && + callback.call(node, event) === false) { + event.preventDefault(); + return false; + } + return; + } + node = node.parentNode; + } + }; + } + } + this.eachEvent(events, function (event, namespace) { + if (event === '') { + throw new Error('Need event name'); + } + if (store.indexOf(event, namespace, callback) === false) { + var block = { + event: event, + originalCallback: callback, + syntheticCallback: syntheticCallback + }; + store.set(event, namespace, block, onTop); + if (isDOMElement) { + subject.addEventListener(event, syntheticCallback, false); + } + } + }); + return this; + }; + EventsNative.prototype.off = function (subjectOrEvents, eventsOrCallback, handler) { + var _this = this; + var subject = typeof subjectOrEvents === 'string' ? this : subjectOrEvents; + var events = typeof eventsOrCallback === 'string' + ? eventsOrCallback + : subjectOrEvents; + var store = this.getStore(subject); + var callback = handler; + if (typeof events !== 'string' || !events) { + store.namespaces().forEach(function (namespace) { + _this.off(subject, '.' + namespace); + }); + this.clearStore(subject); + return this; + } + if (callback === undefined && typeof eventsOrCallback === 'function') { + callback = eventsOrCallback; + } + var isDOMElement = typeof subject.removeEventListener === 'function', removeEventListener = function (block) { + if (isDOMElement) { + subject.removeEventListener(block.event, block.syntheticCallback, false); + } + }, removeCallbackFromNameSpace = function (event, namespace) { + if (event !== '') { + var blocks = store.get(event, namespace); + if (blocks && blocks.length) { + if (typeof callback !== 'function') { + blocks.forEach(removeEventListener); + blocks.length = 0; + } + else { + var index = store.indexOf(event, namespace, callback); + if (index !== false) { + removeEventListener(blocks[index]); + blocks.splice(index, 1); + } + } + } + } + else { + store.events(namespace).forEach(function (eventName) { + if (eventName !== '') { + removeCallbackFromNameSpace(eventName, namespace); + } + }); + } + }; + this.eachEvent(events, function (event, namespace) { + if (namespace === store_1.defaultNameSpace) { + store.namespaces().forEach(function (name) { + removeCallbackFromNameSpace(event, name); + }); + } + else { + removeCallbackFromNameSpace(event, namespace); + } + }); + return this; + }; + EventsNative.prototype.stopPropagation = function (subjectOrEvents, eventsList) { + var _this = this; + var subject = typeof subjectOrEvents === 'string' ? this : subjectOrEvents; + var events = typeof subjectOrEvents === 'string' + ? subjectOrEvents + : eventsList; + if (typeof events !== 'string') { + throw new Error('Need event names'); + } + var store = this.getStore(subject); + this.eachEvent(events, function (event, namespace) { + var blocks = store.get(event, namespace); + if (blocks) { + _this.__stopped.push(blocks); + } + if (namespace === store_1.defaultNameSpace) { + store + .namespaces(true) + .forEach(function (ns) { + return _this.stopPropagation(subject, event + '.' + ns); + }); + } + }); + }; + EventsNative.prototype.fire = function (subjectOrEvents, eventsList) { + var _this = this; + var args = []; + for (var _i = 2; _i < arguments.length; _i++) { + args[_i - 2] = arguments[_i]; + } + var result = undefined, result_value; + var subject = typeof subjectOrEvents === 'string' ? this : subjectOrEvents; + var events = typeof subjectOrEvents === 'string' + ? subjectOrEvents + : eventsList; + var argumentsList = typeof subjectOrEvents === 'string' ? tslib_1.__spreadArrays([eventsList], args) : args; + var isDOMElement = typeof subject.dispatchEvent === 'function'; + if (!isDOMElement && typeof events !== 'string') { + throw new Error('Need events names'); + } + var store = this.getStore(subject); + if (typeof events !== 'string' && isDOMElement) { + this.triggerNativeEvent(subject, eventsList); + } + else { + this.eachEvent(events, function (event, namespace) { + if (isDOMElement) { + _this.triggerNativeEvent(subject, event); + } + else { + var blocks_1 = store.get(event, namespace); + if (blocks_1) { + try { + blocks_1.every(function (block) { + if (_this.isStopped(blocks_1)) { + return false; + } + _this.current.push(event); + result_value = block.syntheticCallback.apply(subject, argumentsList); + _this.current.pop(); + if (result_value !== undefined) { + result = result_value; + } + return true; + }); + } + finally { + _this.removeStop(blocks_1); + } + } + if (namespace === store_1.defaultNameSpace && !isDOMElement) { + store + .namespaces() + .filter(function (ns) { return ns !== namespace; }) + .forEach(function (ns) { + var result_second = _this.fire.apply(_this, tslib_1.__spreadArrays([ + subject, + event + '.' + ns + ], argumentsList)); + if (result_second !== undefined) { + result = result_second; + } + }); + } + } + }); + } + return result; + }; + EventsNative.prototype.destruct = function () { + if (!this.isDestructed) { + return; + } + this.isDestructed = true; + this.off(this); + this.getStore(this).clear(); + delete this[this.__key]; + }; + return EventsNative; +}()); +exports.EventsNative = EventsNative; + + +/***/ }), +/* 66 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +Object.defineProperty(exports, "__esModule", { value: true }); +var isPlainObject_1 = __webpack_require__(21); +var each_1 = __webpack_require__(24); +var asArray_1 = __webpack_require__(42); +var Dom_1 = __webpack_require__(0); +var helpers_1 = __webpack_require__(4); +var Create = (function () { + function Create(ownerDocument, editorDocument) { + this.doc = ownerDocument; + if (editorDocument !== null) { + this.inside = editorDocument + ? new Create(editorDocument) + : new Create(ownerDocument, null); + } + } + Create.prototype.setDocument = function (doc) { + this.doc = doc; + }; + Create.prototype.element = function (tagName, childrenOrAttributes, children) { + var _this = this; + var elm = this.doc.createElement(tagName.toLowerCase()); + if (childrenOrAttributes) { + if (isPlainObject_1.isPlainObject(childrenOrAttributes)) { + each_1.each(childrenOrAttributes, function (key, value) { + if (isPlainObject_1.isPlainObject(value) && key === 'style') { + helpers_1.css(elm, value); + } + else { + elm.setAttribute(key, value.toString()); + } + }); + } + else { + children = childrenOrAttributes; + } + } + if (children) { + asArray_1.asArray(children).forEach(function (child) { + return elm.appendChild(typeof child === 'string' ? _this.fromHTML(child) : child); + }); + } + return elm; + }; + Create.prototype.div = function (className, childrenOrAttributes, children) { + var div = this.element('div', childrenOrAttributes, children); + if (className) { + div.className = className; + } + return div; + }; + Create.prototype.span = function (className, childrenOrAttributes, children) { + var span = this.element('span', childrenOrAttributes, children); + if (className) { + span.className = className; + } + return span; + }; + Create.prototype.a = function (className, childrenOrAttributes, children) { + var a = this.element('a', childrenOrAttributes, children); + if (className) { + a.className = className; + } + return a; + }; + Create.prototype.text = function (value) { + return this.doc.createTextNode(value); + }; + Create.prototype.fragment = function () { + return this.doc.createDocumentFragment(); + }; + Create.prototype.fromHTML = function (html) { + var div = this.div(); + div.innerHTML = html.toString(); + var child = div.firstChild !== div.lastChild || !div.firstChild + ? div + : div.firstChild; + Dom_1.Dom.safeRemove(child); + return child; + }; + return Create; +}()); +exports.Create = Create; + + +/***/ }), +/* 67 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +Object.defineProperty(exports, "__esModule", { value: true }); +var tslib_1 = __webpack_require__(1); +var helpers_1 = __webpack_require__(4); +var PluginSystem = (function () { + function PluginSystem() { + this.items = new Map(); + } + PluginSystem.prototype.add = function (name, plugin) { + this.items.set(name.toLowerCase(), plugin); + }; + PluginSystem.prototype.get = function (name) { + return this.items.get(name.toLowerCase()); + }; + PluginSystem.prototype.remove = function (name) { + this.items.delete(name.toLowerCase()); + }; + PluginSystem.prototype.init = function (jodit) { + return tslib_1.__awaiter(this, void 0, void 0, function () { + var extrasList, disableList, doneList, promiseList, plugins, pluginsMap, makeAndInit, needLoadExtras, e_1; + var _this = this; + return tslib_1.__generator(this, function (_a) { + switch (_a.label) { + case 0: + extrasList = jodit.options.extraPlugins.map(function (s) { + return helpers_1.isString(s) ? { name: s.toLowerCase() } : s; + }), disableList = helpers_1.splitArray(jodit.options.disablePlugins).map(function (s) { + return s.toLowerCase(); + }), doneList = [], promiseList = {}, plugins = [], pluginsMap = {}, makeAndInit = function (plugin, name) { + if (disableList.includes(name) || + doneList.includes(name) || + promiseList[name]) { + return; + } + var instance = PluginSystem.makePluginInstance(jodit, plugin); + _this.initOrWait(jodit, name, instance, doneList, promiseList); + plugins.push(instance); + pluginsMap[name] = instance; + }; + if (!(extrasList && extrasList.length)) return [3, 5]; + _a.label = 1; + case 1: + _a.trys.push([1, 4, , 5]); + needLoadExtras = extrasList.filter(function (extra) { return !_this.items.has(extra.name); }); + if (!needLoadExtras.length) return [3, 3]; + return [4, this.load(jodit, needLoadExtras)]; + case 2: + _a.sent(); + _a.label = 3; + case 3: return [3, 5]; + case 4: + e_1 = _a.sent(); + console.log(e_1); + return [3, 5]; + case 5: + this.items.forEach(makeAndInit); + this.addListenerOnBeforeDestruct(jodit, plugins); + jodit.__plugins = pluginsMap; + return [2]; + } + }); + }); + }; + PluginSystem.makePluginInstance = function (jodit, plugin) { + return helpers_1.isFunction(plugin) ? new plugin(jodit) : plugin; + }; + PluginSystem.prototype.initOrWait = function (jodit, pluginName, instance, doneList, promiseList) { + var initPlugin = function (name, plugin) { + if (plugin.hasStyle) { + PluginSystem.loadStyle(jodit, name); + } + if (helpers_1.isInitable(plugin)) { + if (!plugin.requires || + !plugin.requires.length || + plugin.requires.every(function (name) { return doneList.includes(name); })) { + plugin.init(jodit); + doneList.push(name); + } + else { + promiseList[name] = plugin; + return false; + } + } + else { + doneList.push(name); + } + return true; + }; + initPlugin(pluginName, instance); + Object.keys(promiseList).forEach(function (name) { + var plugin = promiseList[name]; + if (!plugin) { + return; + } + if (initPlugin(name, instance)) { + promiseList[name] = undefined; + delete promiseList[name]; + } + }); + }; + PluginSystem.prototype.addListenerOnBeforeDestruct = function (jodit, plugins) { + jodit.events.on('beforeDestruct', function () { + plugins.forEach(function (instance) { + if (helpers_1.isDestructable(instance)) { + instance.destruct(jodit); + } + }); + plugins.length = 0; + delete jodit.__plugins; + }); + }; + PluginSystem.prototype.load = function (jodit, pluginList) { + var reflect = function (p) { + return p.then(function (v) { return ({ v: v, status: 'fulfilled' }); }, function (e) { return ({ e: e, status: 'rejected' }); }); + }; + return Promise.all(pluginList.map(function (extra) { + var url = extra.url || PluginSystem.getFullUrl(jodit, name, true); + return reflect(helpers_1.appendScriptAsync(url, jodit.ownerDocument)); + })); + }; + PluginSystem.loadStyle = function (jodit, pluginName) { + helpers_1.appendStyleAsync(PluginSystem.getFullUrl(jodit, pluginName, false), jodit.ownerDocument); + }; + PluginSystem.getFullUrl = function (jodit, name, js) { + return (jodit.basePath + + 'plugins/' + + name + + '/' + + name + + '.' + + (js ? 'js' : 'css')); + }; + return PluginSystem; +}()); +exports.PluginSystem = PluginSystem; + + +/***/ }), +/* 68 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +Object.defineProperty(exports, "__esModule", { value: true }); +var Ajax_1 = __webpack_require__(39); +exports.Ajax = Ajax_1.Ajax; +var eventsNative_1 = __webpack_require__(65); +exports.EventsNative = eventsNative_1.EventsNative; +var Component_1 = __webpack_require__(8); +exports.Component = Component_1.Component; +var ContextMenu_1 = __webpack_require__(40); +exports.ContextMenu = ContextMenu_1.ContextMenu; +var dialog_1 = __webpack_require__(14); +exports.Alert = dialog_1.Alert; +exports.Confirm = dialog_1.Confirm; +exports.Promt = dialog_1.Promt; +exports.Dialog = dialog_1.Dialog; +var Dom_1 = __webpack_require__(0); +exports.Dom = Dom_1.Dom; +var Plugin_1 = __webpack_require__(7); +exports.Plugin = Plugin_1.Plugin; +var Create_1 = __webpack_require__(66); +exports.Create = Create_1.Create; +var fileBrowser_1 = __webpack_require__(188); +exports.FileBrowser = fileBrowser_1.FileBrowser; +var Helpers = __webpack_require__(4); +exports.Helpers = Helpers; +var ImageEditor_1 = __webpack_require__(194); +exports.ImageEditor = ImageEditor_1.ImageEditor; +var observer_1 = __webpack_require__(57); +exports.Observer = observer_1.Observer; +var Selection_1 = __webpack_require__(60); +exports.Select = Selection_1.Select; +var storage_1 = __webpack_require__(25); +exports.Storage = storage_1.Storage; +var Snapshot_1 = __webpack_require__(58); +exports.Snapshot = Snapshot_1.Snapshot; +var Table_1 = __webpack_require__(29); +exports.Table = Table_1.Table; +var icon_1 = __webpack_require__(6); +exports.ToolbarIcon = icon_1.ToolbarIcon; +var joditToolbarCollection_1 = __webpack_require__(16); +exports.JoditToolbarCollection = joditToolbarCollection_1.JoditToolbarCollection; +var collection_1 = __webpack_require__(38); +exports.ToolbarCollection = collection_1.ToolbarCollection; +var button_1 = __webpack_require__(27); +exports.ToolbarButton = button_1.ToolbarButton; +var Stack_1 = __webpack_require__(59); +exports.Stack = Stack_1.Stack; +var Widget_1 = __webpack_require__(18); +exports.Widget = Widget_1.Widget; +var Uploader_1 = __webpack_require__(195); +exports.Uploader = Uploader_1.Uploader; +var PluginSystem_1 = __webpack_require__(67); +exports.PluginSystem = PluginSystem_1.PluginSystem; + + +/***/ }), +/* 69 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +Object.defineProperty(exports, "__esModule", { value: true }); +var add_new_line_1 = __webpack_require__(146); +exports.addNewLine = add_new_line_1.addNewLine; +var autofocus_1 = __webpack_require__(147); +exports.autofocus = autofocus_1.autofocus; +var backspace_1 = __webpack_require__(148); +exports.backspace = backspace_1.backspace; +var bold_1 = __webpack_require__(149); +exports.bold = bold_1.bold; +var clean_html_1 = __webpack_require__(150); +exports.cleanHtml = clean_html_1.cleanHtml; +var clipboard_1 = __webpack_require__(151); +exports.clipboard = clipboard_1.clipboard; +exports.paste = clipboard_1.paste; +exports.pasteStorage = clipboard_1.pasteStorage; +var color_1 = __webpack_require__(155); +exports.color = color_1.color; +var drag_and_drop_1 = __webpack_require__(156); +exports.DragAndDrop = drag_and_drop_1.DragAndDrop; +var drag_and_drop_element_1 = __webpack_require__(157); +exports.DragAndDropElement = drag_and_drop_element_1.DragAndDropElement; +var enter_1 = __webpack_require__(158); +exports.enter = enter_1.enter; +var error_messages_1 = __webpack_require__(159); +exports.errorMessages = error_messages_1.errorMessages; +var font_1 = __webpack_require__(160); +exports.font = font_1.font; +var format_block_1 = __webpack_require__(161); +exports.formatBlock = format_block_1.formatBlock; +var fullsize_1 = __webpack_require__(162); +exports.fullsize = fullsize_1.fullsize; +var hotkeys_1 = __webpack_require__(163); +exports.hotkeys = hotkeys_1.hotkeys; +var iframe_1 = __webpack_require__(164); +exports.iframe = iframe_1.iframe; +var image_processor_1 = __webpack_require__(165); +exports.imageProcessor = image_processor_1.imageProcessor; +var image_properties_1 = __webpack_require__(166); +exports.imageProperties = image_properties_1.imageProperties; +var indent_1 = __webpack_require__(167); +exports.indent = indent_1.indent; +var inline_popup_1 = __webpack_require__(168); +exports.inlinePopup = inline_popup_1.inlinePopup; +var justify_1 = __webpack_require__(169); +exports.justify = justify_1.justify; +var limit_1 = __webpack_require__(170); +exports.limit = limit_1.limit; +var link_1 = __webpack_require__(171); +exports.link = link_1.link; +var media_1 = __webpack_require__(172); +exports.media = media_1.media; +var mobile_1 = __webpack_require__(173); +exports.mobile = mobile_1.mobile; +var orderedlist_1 = __webpack_require__(174); +exports.orderedlist = orderedlist_1.orderedlist; +var placeholder_1 = __webpack_require__(175); +exports.placeholder = placeholder_1.placeholder; +var redoundo_1 = __webpack_require__(176); +exports.redoundo = redoundo_1.redoundo; +var resizer_1 = __webpack_require__(177); +exports.resizer = resizer_1.resizer; +var search_1 = __webpack_require__(178); +exports.search = search_1.search; +var size_1 = __webpack_require__(179); +exports.size = size_1.size; +var source_1 = __webpack_require__(180); +exports.source = source_1.source; +var stat_1 = __webpack_require__(181); +exports.stat = stat_1.stat; +var sticky_1 = __webpack_require__(182); +exports.sticky = sticky_1.sticky; +var symbols_1 = __webpack_require__(183); +exports.symbols = symbols_1.symbols; +var table_keyboard_navigation_1 = __webpack_require__(184); +exports.tableKeyboardNavigation = table_keyboard_navigation_1.tableKeyboardNavigation; +var table_1 = __webpack_require__(185); +exports.table = table_1.TableProcessor; +var xpath_1 = __webpack_require__(186); +exports.xpath = xpath_1.xpath; + + +/***/ }), +/* 70 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +Object.defineProperty(exports, "__esModule", { value: true }); +var Config_1 = __webpack_require__(3); +var constants_1 = __webpack_require__(2); +var html_1 = __webpack_require__(35); +var paste_1 = __webpack_require__(71); +Config_1.Config.prototype.controls.cut = { + command: 'cut', + isDisable: function (editor) { return editor.selection.isCollapsed(); }, + tooltip: 'Cut selection' +}; +Config_1.Config.prototype.controls.copy = { + command: 'copy', + isDisable: function (editor) { return editor.selection.isCollapsed(); }, + tooltip: 'Copy selection' +}; +exports.pluginKey = 'clipboard'; +var clipboard = (function () { + function clipboard() { + } + clipboard.prototype.init = function (editor) { + editor.events + .on("copy." + exports.pluginKey + " cut." + exports.pluginKey, function (event) { + var _a, _b; + var selectedText = editor.selection.getHTML(); + var clipboardData = paste_1.getDataTransfer(event) || + paste_1.getDataTransfer(editor.editorWindow) || + paste_1.getDataTransfer(event.originalEvent); + if (clipboardData) { + clipboardData.setData(constants_1.TEXT_PLAIN, html_1.stripTags(selectedText)); + clipboardData.setData(constants_1.TEXT_HTML, selectedText); + } + editor.buffer.set(exports.pluginKey, selectedText); + if (event.type === 'cut') { + editor.selection.remove(); + editor.selection.focus(); + } + event.preventDefault(); + (_b = (_a = editor) === null || _a === void 0 ? void 0 : _a.events) === null || _b === void 0 ? void 0 : _b.fire('afterCopy', selectedText); + }); + }; + clipboard.prototype.destruct = function (editor) { + var _a, _b, _c, _d; + (_b = (_a = editor) === null || _a === void 0 ? void 0 : _a.buffer) === null || _b === void 0 ? void 0 : _b.set(exports.pluginKey, ''); + (_d = (_c = editor) === null || _c === void 0 ? void 0 : _c.events) === null || _d === void 0 ? void 0 : _d.off('.' + exports.pluginKey); + }; + return clipboard; +}()); +exports.clipboard = clipboard; + + +/***/ }), +/* 71 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +Object.defineProperty(exports, "__esModule", { value: true }); +var tslib_1 = __webpack_require__(1); +var Config_1 = __webpack_require__(3); +var constants_1 = __webpack_require__(2); +var dialog_1 = __webpack_require__(14); +var helpers_1 = __webpack_require__(4); +var Dom_1 = __webpack_require__(0); +var nl2br_1 = __webpack_require__(152); +var cut_1 = __webpack_require__(70); +Config_1.Config.prototype.askBeforePasteHTML = true; +Config_1.Config.prototype.askBeforePasteFromWord = true; +Config_1.Config.prototype.nl2brInPlainText = true; +Config_1.Config.prototype.defaultActionOnPaste = constants_1.INSERT_AS_HTML; +exports.getDataTransfer = function (event) { + if (event.clipboardData) { + return event.clipboardData; + } + return event.dataTransfer || new DataTransfer(); +}; +Config_1.Config.prototype.controls.paste = { + tooltip: 'Paste from clipboard', + exec: function (editor) { + return tslib_1.__awaiter(this, void 0, void 0, function () { + var text, error, items, textBlob, _a, _b, value; + return tslib_1.__generator(this, function (_c) { + switch (_c.label) { + case 0: + editor.selection.focus(); + text = '', error = true; + if (error) { + text = editor.buffer.get(cut_1.pluginKey) || ''; + error = text.length === 0; + } + if (!(error && navigator.clipboard)) return [3, 11]; + _c.label = 1; + case 1: + _c.trys.push([1, 6, , 7]); + return [4, navigator.clipboard.read()]; + case 2: + items = _c.sent(); + if (!(items && items.length)) return [3, 5]; + return [4, items[0].getType('text/plain')]; + case 3: + textBlob = _c.sent(); + return [4, new Response(textBlob).text()]; + case 4: + text = _c.sent(); + _c.label = 5; + case 5: return [3, 7]; + case 6: + _a = _c.sent(); + return [3, 7]; + case 7: + if (!error) return [3, 11]; + _c.label = 8; + case 8: + _c.trys.push([8, 10, , 11]); + return [4, navigator.clipboard.readText()]; + case 9: + text = _c.sent(); + error = false; + return [3, 11]; + case 10: + _b = _c.sent(); + return [3, 11]; + case 11: + if (error) { + value = editor.value; + editor.editorDocument.execCommand('paste'); + error = value !== editor.value; + } + if (text) { + editor.selection.insertHTML(text); + } + else { + if (error) { + dialog_1.Alert(editor.i18n("Your browser doesn't support direct access to the clipboard."), function () { + editor.selection.focus(); + }); + } + } + return [2]; + } + }); + }); + } +}; +function paste(editor) { + var clearOrKeep = function (msg, title, callback, clearButton, clear2Button) { + if (clearButton === void 0) { clearButton = 'Clean'; } + if (clear2Button === void 0) { clear2Button = 'Insert only Text'; } + if (editor.events && + editor.events.fire('beforeOpenPasteDialog', msg, title, callback, clearButton, clear2Button) === false) { + return; + } + var dialog = dialog_1.Confirm("
" + msg + "
", title, callback); + dialog.container.setAttribute('data-editor_id', editor.id); + var keep = dialog.create.fromHTML('' + + '' + + editor.i18n('Keep') + + '' + + ''); + var clear = dialog.create.fromHTML('' + + '' + + editor.i18n(clearButton) + + '' + + ''); + var clear2 = dialog.create.fromHTML('' + + '' + + editor.i18n(clear2Button) + + '' + + ''); + var cancel = dialog.create.fromHTML('' + + '' + + editor.i18n('Cancel') + + '' + + ''); + editor.events.on(keep, 'click', function () { + dialog.close(); + callback && callback(true); + }); + editor.events.on(clear, 'click', function () { + dialog.close(); + callback && callback(false); + }); + editor.events.on(clear2, 'click', function () { + dialog.close(); + callback && callback(0); + }); + editor.events.on(cancel, 'click', function () { + dialog.close(); + }); + dialog.setFooter([keep, clear, clear2Button ? clear2 : '', cancel]); + editor.events && + editor.events.fire('afterOpenPasteDialog', dialog, msg, title, callback, clearButton, clear2Button); + return dialog; + }; + var insertByType = function (html, subtype) { + if (typeof html === 'string') { + switch (subtype) { + case constants_1.INSERT_CLEAR_HTML: + html = helpers_1.cleanFromWord(html); + break; + case constants_1.INSERT_ONLY_TEXT: + html = helpers_1.stripTags(html); + break; + case constants_1.INSERT_AS_TEXT: + html = helpers_1.htmlspecialchars(html); + break; + default: + } + } + if (typeof html === 'string') { + editor.buffer.set(cut_1.pluginKey, html); + } + editor.selection.insertHTML(html); + }; + var insertHTML = function (html, event) { + var buffer = editor.buffer.get(cut_1.pluginKey); + if (helpers_1.isHTML(html) && buffer !== trimFragment(html)) { + editor.events.stopPropagation('beforePaste'); + html = trimFragment(html); + clearOrKeep(editor.i18n('Your code is similar to HTML. Keep as HTML?'), editor.i18n('Paste as HTML'), function (agree) { + var insertType = constants_1.INSERT_AS_HTML; + if (agree === false) { + insertType = constants_1.INSERT_AS_TEXT; + } + if (agree === 0) { + insertType = constants_1.INSERT_ONLY_TEXT; + } + if (event.type === 'drop') { + editor.selection.insertCursorAtPoint(event.clientX, event.clientY); + } + insertByType(html, insertType); + editor.setEditorValue(); + }, 'Insert as Text'); + return false; + } + }; + var trimFragment = function (html) { + var start = html.search(//i); + if (start !== -1) { + html = html.substr(start + 20); + } + var end = html.search(//i); + if (end !== -1) { + html = html.substr(0, end); + } + return html; + }; + editor.events.on('paste', function (event) { + if (editor.events.fire('beforePaste', event) === false) { + event.preventDefault(); + return false; + } + var dt = exports.getDataTransfer(event); + if (event && dt) { + var types = dt.types; + var types_str_1 = ''; + if (Array.isArray(types) || helpers_1.type(types) === 'domstringlist') { + for (var i = 0; i < types.length; i += 1) { + types_str_1 += types[i] + ';'; + } + } + else { + types_str_1 = types.toString() + ';'; + } + var getText = function () { + if (/text\/html/i.test(types_str_1)) { + return dt.getData('text/html'); + } + if (/text\/rtf/i.test(types_str_1) && helpers_1.browser('safari')) { + return dt.getData('text/rtf'); + } + if (/text\/plain/i.test(types_str_1) && !helpers_1.browser('mozilla')) { + return dt.getData(constants_1.TEXT_PLAIN); + } + if (/text/i.test(types_str_1) && constants_1.IS_IE) { + return dt.getData(constants_1.TEXT_PLAIN); + } + return ''; + }; + var clipboard_html = getText(); + if (Dom_1.Dom.isNode(clipboard_html, editor.editorWindow) || + helpers_1.trim(clipboard_html) !== '') { + clipboard_html = trimFragment(clipboard_html); + var buffer = editor.buffer.get(cut_1.pluginKey); + if (buffer !== clipboard_html) { + clipboard_html = editor.events.fire('processPaste', event, clipboard_html, types_str_1); + } + if (typeof clipboard_html === 'string' || + Dom_1.Dom.isNode(clipboard_html, editor.editorWindow)) { + if (event.type === 'drop') { + editor.selection.insertCursorAtPoint(event.clientX, event.clientY); + } + insertByType(clipboard_html, editor.options.defaultActionOnPaste); + } + event.preventDefault(); + event.stopPropagation(); + } + } + if (editor.events.fire('afterPaste', event) === false) { + return false; + } + }); + if (editor.options.askBeforePasteHTML) { + editor.events.on('beforePaste', function (event) { + var dt = exports.getDataTransfer(event); + if (event && dt && dt.getData(constants_1.TEXT_PLAIN)) { + var html = dt.getData(constants_1.TEXT_PLAIN); + return insertHTML(html, event); + } + }); + } + if (editor.options.askBeforePasteFromWord) { + editor.events.on('beforePaste', function (event) { + var dt = exports.getDataTransfer(event); + if (event && dt && dt.getData && dt.getData(constants_1.TEXT_HTML)) { + var processHTMLData_1 = function (html) { + var buffer = editor.buffer.get(cut_1.pluginKey); + if (helpers_1.isHTML(html) && buffer !== trimFragment(html)) { + if (helpers_1.isHTMLFromWord(html)) { + clearOrKeep(editor.i18n('The pasted content is coming from a Microsoft Word/Excel document. ' + + 'Do you want to keep the format or clean it up?'), editor.i18n('Word Paste Detected'), function (agree) { + if (agree === true) { + html = helpers_1.applyStyles(html); + if (editor.options.beautifyHTML && + editor.ownerWindow + .html_beautify) { + html = editor.ownerWindow.html_beautify(html); + } + } + if (agree === false) { + html = helpers_1.cleanFromWord(html); + } + if (agree === 0) { + html = helpers_1.stripTags(helpers_1.cleanFromWord(html)); + } + editor.selection.insertHTML(html); + editor.setEditorValue(); + }); + } + else { + insertHTML(html, event); + } + return false; + } + }; + if (dt.types && + Array.from(dt.types).indexOf('text/html') !== -1) { + var html = dt.getData(constants_1.TEXT_HTML); + return processHTMLData_1(html); + } + if (event.type !== 'drop') { + var div_1 = editor.create.div('', { + tabindex: -1, + contenteditable: true, + style: { + left: -9999, + top: 0, + width: 0, + height: '100%', + lineHeight: '140%', + overflow: 'hidden', + position: 'fixed', + zIndex: 2147483647, + wordBreak: 'break-all' + } + }); + editor.container.appendChild(div_1); + var selData_1 = editor.selection.save(); + div_1.focus(); + var tick_1 = 0; + var removeFakeFocus_1 = function () { + Dom_1.Dom.safeRemove(div_1); + editor.selection && + editor.selection.restore(selData_1); + }; + var waitData_1 = function () { + tick_1 += 1; + if (div_1.childNodes && div_1.childNodes.length > 0) { + var pastedData = div_1.innerHTML; + removeFakeFocus_1(); + if (processHTMLData_1(pastedData) !== false) { + editor.selection.insertHTML(pastedData); + } + return; + } + if (tick_1 < 5) { + helpers_1.setTimeout(waitData_1, 20); + } + else { + removeFakeFocus_1(); + } + }; + waitData_1(); + } + } + }); + } + if (editor.options.nl2brInPlainText) { + editor.events.on('processPaste', function (event, text, type) { + if (type === constants_1.TEXT_PLAIN + ';' && !helpers_1.isHTML(text)) { + return nl2br_1.nl2br(text); + } + }); + } +} +exports.paste = paste; + + +/***/ }), +/* 72 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +Object.defineProperty(exports, "__esModule", { value: true }); +var dialog_1 = __webpack_require__(17); +var icon_1 = __webpack_require__(6); +exports.Promt = function (msg, title, callback, placeholder, defaultValue) { + var dialog = new dialog_1.Dialog(), cancelButton = dialog.create.fromHTML('' + + icon_1.ToolbarIcon.getIcon('cancel') + + '' + + Jodit_1.Jodit.prototype.i18n('Cancel') + + ''), okButton = dialog.create.fromHTML('' + + icon_1.ToolbarIcon.getIcon('check') + + '' + + Jodit_1.Jodit.prototype.i18n('Ok') + + ''), form = dialog.create.element('form', { + class: 'jodit_promt' + }), inputElement = dialog.create.element('input', { + autofocus: true, + class: 'jodit_input' + }), labelElement = dialog.create.element('label'); + if (typeof title === 'function') { + callback = title; + title = undefined; + } + if (placeholder) { + inputElement.setAttribute('placeholder', placeholder); + } + labelElement.appendChild(dialog.create.text(msg)); + form.appendChild(labelElement); + form.appendChild(inputElement); + cancelButton.addEventListener('click', dialog.close, false); + var onclick = function () { + if (!callback || + typeof callback !== 'function' || + callback(inputElement.value) !== false) { + dialog.close(); + } + }; + okButton.addEventListener('click', onclick); + form.addEventListener('submit', function () { + onclick(); + return false; + }); + dialog.setFooter([okButton, cancelButton]); + dialog.open(form, title || ' ', true, true); + inputElement.focus(); + if (defaultValue !== undefined && defaultValue.length) { + inputElement.value = defaultValue; + inputElement.select(); + } + return dialog; +}; +var Jodit_1 = __webpack_require__(11); + + +/***/ }), +/* 73 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +Object.defineProperty(exports, "__esModule", { value: true }); +var dialog_1 = __webpack_require__(17); +var icon_1 = __webpack_require__(6); +exports.Confirm = function (msg, title, callback) { + var dialog = new dialog_1.Dialog(), $div = dialog.create.fromHTML('
'), $label = dialog.create.element('label'); + if (typeof title === 'function') { + callback = title; + title = undefined; + } + $label.appendChild(dialog.create.fromHTML(msg)); + $div.appendChild($label); + var $cancel = dialog.create.fromHTML('' + + icon_1.ToolbarIcon.getIcon('cancel') + + '' + + Jodit_1.Jodit.prototype.i18n('Cancel') + + '' + + ''); + $cancel.addEventListener('click', function () { + if (callback) { + callback(false); + } + dialog.close(); + }); + var onok = function () { + if (callback) { + callback(true); + } + dialog.close(); + }; + var $ok = dialog.create.fromHTML('' + + icon_1.ToolbarIcon.getIcon('check') + + '' + + Jodit_1.Jodit.prototype.i18n('Yes') + + '' + + ''); + $ok.addEventListener('click', onok); + $div.addEventListener('submit', function () { + onok(); + return false; + }); + dialog.setFooter([$ok, $cancel]); + dialog.open($div, title || ' ', true, true); + $ok.focus(); + return dialog; +}; +var Jodit_1 = __webpack_require__(11); + + +/***/ }), +/* 74 */ +/***/ (function(module, exports, __webpack_require__) { + +module.exports = __webpack_require__(75); + + +/***/ }), +/* 75 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +Object.defineProperty(exports, "__esModule", { value: true }); +__webpack_require__(76); +if ( true && typeof window !== 'undefined') { + __webpack_require__(77); +} +var Jodit_1 = __webpack_require__(11); +var index_1 = __webpack_require__(128); +var consts = __webpack_require__(2); +var Modules = __webpack_require__(68); +var Plugins = __webpack_require__(69); +var Icons = __webpack_require__(196); +var Config_1 = __webpack_require__(3); +var icon_1 = __webpack_require__(6); +Object.keys(consts).forEach(function (key) { + Jodit_1.Jodit[key] = consts[key]; +}); +var esFilter = function (key) { return key !== '__esModule'; }; +Object.keys(Icons) + .filter(esFilter) + .forEach(function (key) { + icon_1.ToolbarIcon.setIcon(key.replace('_', '-'), Icons[key]); +}); +Object.keys(Modules) + .filter(esFilter) + .forEach(function (key) { + Jodit_1.Jodit.modules[key] = Modules[key]; +}); +['Confirm', 'Alert', 'Promt'].forEach(function (key) { + Jodit_1.Jodit[key] = Modules[key]; +}); +Object.keys(Plugins) + .filter(esFilter) + .forEach(function (key) { + Jodit_1.Jodit.plugins.add(key, Plugins[key]); +}); +Object.keys(index_1.default) + .filter(esFilter) + .forEach(function (key) { + Jodit_1.Jodit.lang[key] = index_1.default[key]; +}); +Jodit_1.Jodit.defaultOptions = Config_1.Config.defaultOptions; +Config_1.OptionsDefault.prototype = Jodit_1.Jodit.defaultOptions; +exports.Jodit = Jodit_1.Jodit; +exports.default = Jodit_1.Jodit; + + +/***/ }), +/* 76 */ +/***/ (function(module, exports, __webpack_require__) { + +// extracted by mini-css-extract-plugin + +/***/ }), +/* 77 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +Object.defineProperty(exports, "__esModule", { value: true }); +__webpack_require__(78); +__webpack_require__(79); +(function (e) { + e.matches || + (e.matches = + e.matchesSelector !== undefined + ? e.matchesSelector + : function (selector) { + if (!this.ownerDocument) { + return []; + } + var matches = this.ownerDocument.querySelectorAll(selector), th = this; + return Array.prototype.some.call(matches, function (elm) { + return elm === th; + }); + }); +})(Element.prototype); +if (!Array.from) { + Array.from = function (object) { + 'use strict'; + return [].slice.call(object); + }; +} +if (!Array.prototype.includes) { + Array.prototype.includes = function (value) { + return this.indexOf(value) > -1; + }; +} + + +/***/ }), +/* 78 */ +/***/ (function(module, exports) { + +/* + * classList.js: Cross-browser full element.classList implementation. + * 1.1.20170427 + * + * By Eli Grey, http://eligrey.com + * License: Dedicated to the public domain. + * See https://github.com/eligrey/classList.js/blob/master/LICENSE.md + */ + +/*global self, document, DOMException */ + +/*! @source http://purl.eligrey.com/github/classList.js/blob/master/classList.js */ + +if ("document" in window.self) { + +// Full polyfill for browsers with no classList support +// Including IE < Edge missing SVGElement.classList +if (!("classList" in document.createElement("_")) + || document.createElementNS && !("classList" in document.createElementNS("http://www.w3.org/2000/svg","g"))) { + +(function (view) { + +"use strict"; + +if (!('Element' in view)) return; + +var + classListProp = "classList" + , protoProp = "prototype" + , elemCtrProto = view.Element[protoProp] + , objCtr = Object + , strTrim = String[protoProp].trim || function () { + return this.replace(/^\s+|\s+$/g, ""); + } + , arrIndexOf = Array[protoProp].indexOf || function (item) { + var + i = 0 + , len = this.length + ; + for (; i < len; i++) { + if (i in this && this[i] === item) { + return i; + } + } + return -1; + } + // Vendors: please allow content code to instantiate DOMExceptions + , DOMEx = function (type, message) { + this.name = type; + this.code = DOMException[type]; + this.message = message; + } + , checkTokenAndGetIndex = function (classList, token) { + if (token === "") { + throw new DOMEx( + "SYNTAX_ERR" + , "An invalid or illegal string was specified" + ); + } + if (/\s/.test(token)) { + throw new DOMEx( + "INVALID_CHARACTER_ERR" + , "String contains an invalid character" + ); + } + return arrIndexOf.call(classList, token); + } + , ClassList = function (elem) { + var + trimmedClasses = strTrim.call(elem.getAttribute("class") || "") + , classes = trimmedClasses ? trimmedClasses.split(/\s+/) : [] + , i = 0 + , len = classes.length + ; + for (; i < len; i++) { + this.push(classes[i]); + } + this._updateClassName = function () { + elem.setAttribute("class", this.toString()); + }; + } + , classListProto = ClassList[protoProp] = [] + , classListGetter = function () { + return new ClassList(this); + } +; +// Most DOMException implementations don't allow calling DOMException's toString() +// on non-DOMExceptions. Error's toString() is sufficient here. +DOMEx[protoProp] = Error[protoProp]; +classListProto.item = function (i) { + return this[i] || null; +}; +classListProto.contains = function (token) { + token += ""; + return checkTokenAndGetIndex(this, token) !== -1; +}; +classListProto.add = function () { + var + tokens = arguments + , i = 0 + , l = tokens.length + , token + , updated = false + ; + do { + token = tokens[i] + ""; + if (checkTokenAndGetIndex(this, token) === -1) { + this.push(token); + updated = true; + } + } + while (++i < l); + + if (updated) { + this._updateClassName(); + } +}; +classListProto.remove = function () { + var + tokens = arguments + , i = 0 + , l = tokens.length + , token + , updated = false + , index + ; + do { + token = tokens[i] + ""; + index = checkTokenAndGetIndex(this, token); + while (index !== -1) { + this.splice(index, 1); + updated = true; + index = checkTokenAndGetIndex(this, token); + } + } + while (++i < l); + + if (updated) { + this._updateClassName(); + } +}; +classListProto.toggle = function (token, force) { + token += ""; + + var + result = this.contains(token) + , method = result ? + force !== true && "remove" + : + force !== false && "add" + ; + + if (method) { + this[method](token); + } + + if (force === true || force === false) { + return force; + } else { + return !result; + } +}; +classListProto.toString = function () { + return this.join(" "); +}; + +if (objCtr.defineProperty) { + var classListPropDesc = { + get: classListGetter + , enumerable: true + , configurable: true + }; + try { + objCtr.defineProperty(elemCtrProto, classListProp, classListPropDesc); + } catch (ex) { // IE 8 doesn't support enumerable:true + // adding undefined to fight this issue https://github.com/eligrey/classList.js/issues/36 + // modernie IE8-MSW7 machine has IE8 8.0.6001.18702 and is affected + if (ex.number === undefined || ex.number === -0x7FF5EC54) { + classListPropDesc.enumerable = false; + objCtr.defineProperty(elemCtrProto, classListProp, classListPropDesc); + } + } +} else if (objCtr[protoProp].__defineGetter__) { + elemCtrProto.__defineGetter__(classListProp, classListGetter); +} + +}(window.self)); + +} + +// There is full or partial native classList support, so just check if we need +// to normalize the add/remove and toggle APIs. + +(function () { + "use strict"; + + var testElement = document.createElement("_"); + + testElement.classList.add("c1", "c2"); + + // Polyfill for IE 10/11 and Firefox <26, where classList.add and + // classList.remove exist but support only one argument at a time. + if (!testElement.classList.contains("c2")) { + var createMethod = function(method) { + var original = DOMTokenList.prototype[method]; + + DOMTokenList.prototype[method] = function(token) { + var i, len = arguments.length; + + for (i = 0; i < len; i++) { + token = arguments[i]; + original.call(this, token); + } + }; + }; + createMethod('add'); + createMethod('remove'); + } + + testElement.classList.toggle("c3", false); + + // Polyfill for IE 10 and Firefox <24, where classList.toggle does not + // support the second argument. + if (testElement.classList.contains("c3")) { + var _toggle = DOMTokenList.prototype.toggle; + + DOMTokenList.prototype.toggle = function(token, force) { + if (1 in arguments && !this.contains(token) === !force) { + return force; + } else { + return _toggle.call(this, token); + } + }; + + } + + testElement = null; +}()); + +} + + +/***/ }), +/* 79 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; +// This file can be required in Browserify and Node.js for automatic polyfill +// To use it: require('es6-promise/auto'); + +module.exports = __webpack_require__(80).polyfill(); + + +/***/ }), +/* 80 */ +/***/ (function(module, exports, __webpack_require__) { + +/* WEBPACK VAR INJECTION */(function(process, global) {/*! + * @overview es6-promise - a tiny implementation of Promises/A+. + * @copyright Copyright (c) 2014 Yehuda Katz, Tom Dale, Stefan Penner and contributors (Conversion to ES6 API by Jake Archibald) + * @license Licensed under MIT license + * See https://raw.githubusercontent.com/stefanpenner/es6-promise/master/LICENSE + * @version v4.2.8+1e68dce6 + */ + +(function (global, factory) { + true ? module.exports = factory() : + undefined; +}(this, (function () { 'use strict'; + +function objectOrFunction(x) { + var type = typeof x; + return x !== null && (type === 'object' || type === 'function'); +} + +function isFunction(x) { + return typeof x === 'function'; +} + + + +var _isArray = void 0; +if (Array.isArray) { + _isArray = Array.isArray; +} else { + _isArray = function (x) { + return Object.prototype.toString.call(x) === '[object Array]'; + }; +} + +var isArray = _isArray; + +var len = 0; +var vertxNext = void 0; +var customSchedulerFn = void 0; + +var asap = function asap(callback, arg) { + queue[len] = callback; + queue[len + 1] = arg; + len += 2; + if (len === 2) { + // If len is 2, that means that we need to schedule an async flush. + // If additional callbacks are queued before the queue is flushed, they + // will be processed by this flush that we are scheduling. + if (customSchedulerFn) { + customSchedulerFn(flush); + } else { + scheduleFlush(); + } + } +}; + +function setScheduler(scheduleFn) { + customSchedulerFn = scheduleFn; +} + +function setAsap(asapFn) { + asap = asapFn; +} + +var browserWindow = typeof window !== 'undefined' ? window : undefined; +var browserGlobal = browserWindow || {}; +var BrowserMutationObserver = browserGlobal.MutationObserver || browserGlobal.WebKitMutationObserver; +var isNode = typeof self === 'undefined' && typeof process !== 'undefined' && {}.toString.call(process) === '[object process]'; + +// test for web worker but not in IE10 +var isWorker = typeof Uint8ClampedArray !== 'undefined' && typeof importScripts !== 'undefined' && typeof MessageChannel !== 'undefined'; + +// node +function useNextTick() { + // node version 0.10.x displays a deprecation warning when nextTick is used recursively + // see https://github.com/cujojs/when/issues/410 for details + return function () { + return process.nextTick(flush); + }; +} + +// vertx +function useVertxTimer() { + if (typeof vertxNext !== 'undefined') { + return function () { + vertxNext(flush); + }; + } + + return useSetTimeout(); +} + +function useMutationObserver() { + var iterations = 0; + var observer = new BrowserMutationObserver(flush); + var node = document.createTextNode(''); + observer.observe(node, { characterData: true }); + + return function () { + node.data = iterations = ++iterations % 2; + }; +} + +// web worker +function useMessageChannel() { + var channel = new MessageChannel(); + channel.port1.onmessage = flush; + return function () { + return channel.port2.postMessage(0); + }; +} + +function useSetTimeout() { + // Store setTimeout reference so es6-promise will be unaffected by + // other code modifying setTimeout (like sinon.useFakeTimers()) + var globalSetTimeout = setTimeout; + return function () { + return globalSetTimeout(flush, 1); + }; +} + +var queue = new Array(1000); +function flush() { + for (var i = 0; i < len; i += 2) { + var callback = queue[i]; + var arg = queue[i + 1]; + + callback(arg); + + queue[i] = undefined; + queue[i + 1] = undefined; + } + + len = 0; +} + +function attemptVertx() { + try { + var vertx = Function('return this')().require('vertx'); + vertxNext = vertx.runOnLoop || vertx.runOnContext; + return useVertxTimer(); + } catch (e) { + return useSetTimeout(); + } +} + +var scheduleFlush = void 0; +// Decide what async method to use to triggering processing of queued callbacks: +if (isNode) { + scheduleFlush = useNextTick(); +} else if (BrowserMutationObserver) { + scheduleFlush = useMutationObserver(); +} else if (isWorker) { + scheduleFlush = useMessageChannel(); +} else if (browserWindow === undefined && "function" === 'function') { + scheduleFlush = attemptVertx(); +} else { + scheduleFlush = useSetTimeout(); +} + +function then(onFulfillment, onRejection) { + var parent = this; + + var child = new this.constructor(noop); + + if (child[PROMISE_ID] === undefined) { + makePromise(child); + } + + var _state = parent._state; + + + if (_state) { + var callback = arguments[_state - 1]; + asap(function () { + return invokeCallback(_state, child, callback, parent._result); + }); + } else { + subscribe(parent, child, onFulfillment, onRejection); + } + + return child; +} + +/** + `Promise.resolve` returns a promise that will become resolved with the + passed `value`. It is shorthand for the following: + + ```javascript + let promise = new Promise(function(resolve, reject){ + resolve(1); + }); + + promise.then(function(value){ + // value === 1 + }); + ``` + + Instead of writing the above, your code now simply becomes the following: + + ```javascript + let promise = Promise.resolve(1); + + promise.then(function(value){ + // value === 1 + }); + ``` + + @method resolve + @static + @param {Any} value value that the returned promise will be resolved with + Useful for tooling. + @return {Promise} a promise that will become fulfilled with the given + `value` +*/ +function resolve$1(object) { + /*jshint validthis:true */ + var Constructor = this; + + if (object && typeof object === 'object' && object.constructor === Constructor) { + return object; + } + + var promise = new Constructor(noop); + resolve(promise, object); + return promise; +} + +var PROMISE_ID = Math.random().toString(36).substring(2); + +function noop() {} + +var PENDING = void 0; +var FULFILLED = 1; +var REJECTED = 2; + +function selfFulfillment() { + return new TypeError("You cannot resolve a promise with itself"); +} + +function cannotReturnOwn() { + return new TypeError('A promises callback cannot return that same promise.'); +} + +function tryThen(then$$1, value, fulfillmentHandler, rejectionHandler) { + try { + then$$1.call(value, fulfillmentHandler, rejectionHandler); + } catch (e) { + return e; + } +} + +function handleForeignThenable(promise, thenable, then$$1) { + asap(function (promise) { + var sealed = false; + var error = tryThen(then$$1, thenable, function (value) { + if (sealed) { + return; + } + sealed = true; + if (thenable !== value) { + resolve(promise, value); + } else { + fulfill(promise, value); + } + }, function (reason) { + if (sealed) { + return; + } + sealed = true; + + reject(promise, reason); + }, 'Settle: ' + (promise._label || ' unknown promise')); + + if (!sealed && error) { + sealed = true; + reject(promise, error); + } + }, promise); +} + +function handleOwnThenable(promise, thenable) { + if (thenable._state === FULFILLED) { + fulfill(promise, thenable._result); + } else if (thenable._state === REJECTED) { + reject(promise, thenable._result); + } else { + subscribe(thenable, undefined, function (value) { + return resolve(promise, value); + }, function (reason) { + return reject(promise, reason); + }); + } +} + +function handleMaybeThenable(promise, maybeThenable, then$$1) { + if (maybeThenable.constructor === promise.constructor && then$$1 === then && maybeThenable.constructor.resolve === resolve$1) { + handleOwnThenable(promise, maybeThenable); + } else { + if (then$$1 === undefined) { + fulfill(promise, maybeThenable); + } else if (isFunction(then$$1)) { + handleForeignThenable(promise, maybeThenable, then$$1); + } else { + fulfill(promise, maybeThenable); + } + } +} + +function resolve(promise, value) { + if (promise === value) { + reject(promise, selfFulfillment()); + } else if (objectOrFunction(value)) { + var then$$1 = void 0; + try { + then$$1 = value.then; + } catch (error) { + reject(promise, error); + return; + } + handleMaybeThenable(promise, value, then$$1); + } else { + fulfill(promise, value); + } +} + +function publishRejection(promise) { + if (promise._onerror) { + promise._onerror(promise._result); + } + + publish(promise); +} + +function fulfill(promise, value) { + if (promise._state !== PENDING) { + return; + } + + promise._result = value; + promise._state = FULFILLED; + + if (promise._subscribers.length !== 0) { + asap(publish, promise); + } +} + +function reject(promise, reason) { + if (promise._state !== PENDING) { + return; + } + promise._state = REJECTED; + promise._result = reason; + + asap(publishRejection, promise); +} + +function subscribe(parent, child, onFulfillment, onRejection) { + var _subscribers = parent._subscribers; + var length = _subscribers.length; + + + parent._onerror = null; + + _subscribers[length] = child; + _subscribers[length + FULFILLED] = onFulfillment; + _subscribers[length + REJECTED] = onRejection; + + if (length === 0 && parent._state) { + asap(publish, parent); + } +} + +function publish(promise) { + var subscribers = promise._subscribers; + var settled = promise._state; + + if (subscribers.length === 0) { + return; + } + + var child = void 0, + callback = void 0, + detail = promise._result; + + for (var i = 0; i < subscribers.length; i += 3) { + child = subscribers[i]; + callback = subscribers[i + settled]; + + if (child) { + invokeCallback(settled, child, callback, detail); + } else { + callback(detail); + } + } + + promise._subscribers.length = 0; +} + +function invokeCallback(settled, promise, callback, detail) { + var hasCallback = isFunction(callback), + value = void 0, + error = void 0, + succeeded = true; + + if (hasCallback) { + try { + value = callback(detail); + } catch (e) { + succeeded = false; + error = e; + } + + if (promise === value) { + reject(promise, cannotReturnOwn()); + return; + } + } else { + value = detail; + } + + if (promise._state !== PENDING) { + // noop + } else if (hasCallback && succeeded) { + resolve(promise, value); + } else if (succeeded === false) { + reject(promise, error); + } else if (settled === FULFILLED) { + fulfill(promise, value); + } else if (settled === REJECTED) { + reject(promise, value); + } +} + +function initializePromise(promise, resolver) { + try { + resolver(function resolvePromise(value) { + resolve(promise, value); + }, function rejectPromise(reason) { + reject(promise, reason); + }); + } catch (e) { + reject(promise, e); + } +} + +var id = 0; +function nextId() { + return id++; +} + +function makePromise(promise) { + promise[PROMISE_ID] = id++; + promise._state = undefined; + promise._result = undefined; + promise._subscribers = []; +} + +function validationError() { + return new Error('Array Methods must be provided an Array'); +} + +var Enumerator = function () { + function Enumerator(Constructor, input) { + this._instanceConstructor = Constructor; + this.promise = new Constructor(noop); + + if (!this.promise[PROMISE_ID]) { + makePromise(this.promise); + } + + if (isArray(input)) { + this.length = input.length; + this._remaining = input.length; + + this._result = new Array(this.length); + + if (this.length === 0) { + fulfill(this.promise, this._result); + } else { + this.length = this.length || 0; + this._enumerate(input); + if (this._remaining === 0) { + fulfill(this.promise, this._result); + } + } + } else { + reject(this.promise, validationError()); + } + } + + Enumerator.prototype._enumerate = function _enumerate(input) { + for (var i = 0; this._state === PENDING && i < input.length; i++) { + this._eachEntry(input[i], i); + } + }; + + Enumerator.prototype._eachEntry = function _eachEntry(entry, i) { + var c = this._instanceConstructor; + var resolve$$1 = c.resolve; + + + if (resolve$$1 === resolve$1) { + var _then = void 0; + var error = void 0; + var didError = false; + try { + _then = entry.then; + } catch (e) { + didError = true; + error = e; + } + + if (_then === then && entry._state !== PENDING) { + this._settledAt(entry._state, i, entry._result); + } else if (typeof _then !== 'function') { + this._remaining--; + this._result[i] = entry; + } else if (c === Promise$1) { + var promise = new c(noop); + if (didError) { + reject(promise, error); + } else { + handleMaybeThenable(promise, entry, _then); + } + this._willSettleAt(promise, i); + } else { + this._willSettleAt(new c(function (resolve$$1) { + return resolve$$1(entry); + }), i); + } + } else { + this._willSettleAt(resolve$$1(entry), i); + } + }; + + Enumerator.prototype._settledAt = function _settledAt(state, i, value) { + var promise = this.promise; + + + if (promise._state === PENDING) { + this._remaining--; + + if (state === REJECTED) { + reject(promise, value); + } else { + this._result[i] = value; + } + } + + if (this._remaining === 0) { + fulfill(promise, this._result); + } + }; + + Enumerator.prototype._willSettleAt = function _willSettleAt(promise, i) { + var enumerator = this; + + subscribe(promise, undefined, function (value) { + return enumerator._settledAt(FULFILLED, i, value); + }, function (reason) { + return enumerator._settledAt(REJECTED, i, reason); + }); + }; + + return Enumerator; +}(); + +/** + `Promise.all` accepts an array of promises, and returns a new promise which + is fulfilled with an array of fulfillment values for the passed promises, or + rejected with the reason of the first passed promise to be rejected. It casts all + elements of the passed iterable to promises as it runs this algorithm. + + Example: + + ```javascript + let promise1 = resolve(1); + let promise2 = resolve(2); + let promise3 = resolve(3); + let promises = [ promise1, promise2, promise3 ]; + + Promise.all(promises).then(function(array){ + // The array here would be [ 1, 2, 3 ]; + }); + ``` + + If any of the `promises` given to `all` are rejected, the first promise + that is rejected will be given as an argument to the returned promises's + rejection handler. For example: + + Example: + + ```javascript + let promise1 = resolve(1); + let promise2 = reject(new Error("2")); + let promise3 = reject(new Error("3")); + let promises = [ promise1, promise2, promise3 ]; + + Promise.all(promises).then(function(array){ + // Code here never runs because there are rejected promises! + }, function(error) { + // error.message === "2" + }); + ``` + + @method all + @static + @param {Array} entries array of promises + @param {String} label optional string for labeling the promise. + Useful for tooling. + @return {Promise} promise that is fulfilled when all `promises` have been + fulfilled, or rejected if any of them become rejected. + @static +*/ +function all(entries) { + return new Enumerator(this, entries).promise; +} + +/** + `Promise.race` returns a new promise which is settled in the same way as the + first passed promise to settle. + + Example: + + ```javascript + let promise1 = new Promise(function(resolve, reject){ + setTimeout(function(){ + resolve('promise 1'); + }, 200); + }); + + let promise2 = new Promise(function(resolve, reject){ + setTimeout(function(){ + resolve('promise 2'); + }, 100); + }); + + Promise.race([promise1, promise2]).then(function(result){ + // result === 'promise 2' because it was resolved before promise1 + // was resolved. + }); + ``` + + `Promise.race` is deterministic in that only the state of the first + settled promise matters. For example, even if other promises given to the + `promises` array argument are resolved, but the first settled promise has + become rejected before the other promises became fulfilled, the returned + promise will become rejected: + + ```javascript + let promise1 = new Promise(function(resolve, reject){ + setTimeout(function(){ + resolve('promise 1'); + }, 200); + }); + + let promise2 = new Promise(function(resolve, reject){ + setTimeout(function(){ + reject(new Error('promise 2')); + }, 100); + }); + + Promise.race([promise1, promise2]).then(function(result){ + // Code here never runs + }, function(reason){ + // reason.message === 'promise 2' because promise 2 became rejected before + // promise 1 became fulfilled + }); + ``` + + An example real-world use case is implementing timeouts: + + ```javascript + Promise.race([ajax('foo.json'), timeout(5000)]) + ``` + + @method race + @static + @param {Array} promises array of promises to observe + Useful for tooling. + @return {Promise} a promise which settles in the same way as the first passed + promise to settle. +*/ +function race(entries) { + /*jshint validthis:true */ + var Constructor = this; + + if (!isArray(entries)) { + return new Constructor(function (_, reject) { + return reject(new TypeError('You must pass an array to race.')); + }); + } else { + return new Constructor(function (resolve, reject) { + var length = entries.length; + for (var i = 0; i < length; i++) { + Constructor.resolve(entries[i]).then(resolve, reject); + } + }); + } +} + +/** + `Promise.reject` returns a promise rejected with the passed `reason`. + It is shorthand for the following: + + ```javascript + let promise = new Promise(function(resolve, reject){ + reject(new Error('WHOOPS')); + }); + + promise.then(function(value){ + // Code here doesn't run because the promise is rejected! + }, function(reason){ + // reason.message === 'WHOOPS' + }); + ``` + + Instead of writing the above, your code now simply becomes the following: + + ```javascript + let promise = Promise.reject(new Error('WHOOPS')); + + promise.then(function(value){ + // Code here doesn't run because the promise is rejected! + }, function(reason){ + // reason.message === 'WHOOPS' + }); + ``` + + @method reject + @static + @param {Any} reason value that the returned promise will be rejected with. + Useful for tooling. + @return {Promise} a promise rejected with the given `reason`. +*/ +function reject$1(reason) { + /*jshint validthis:true */ + var Constructor = this; + var promise = new Constructor(noop); + reject(promise, reason); + return promise; +} + +function needsResolver() { + throw new TypeError('You must pass a resolver function as the first argument to the promise constructor'); +} + +function needsNew() { + throw new TypeError("Failed to construct 'Promise': Please use the 'new' operator, this object constructor cannot be called as a function."); +} + +/** + Promise objects represent the eventual result of an asynchronous operation. The + primary way of interacting with a promise is through its `then` method, which + registers callbacks to receive either a promise's eventual value or the reason + why the promise cannot be fulfilled. + + Terminology + ----------- + + - `promise` is an object or function with a `then` method whose behavior conforms to this specification. + - `thenable` is an object or function that defines a `then` method. + - `value` is any legal JavaScript value (including undefined, a thenable, or a promise). + - `exception` is a value that is thrown using the throw statement. + - `reason` is a value that indicates why a promise was rejected. + - `settled` the final resting state of a promise, fulfilled or rejected. + + A promise can be in one of three states: pending, fulfilled, or rejected. + + Promises that are fulfilled have a fulfillment value and are in the fulfilled + state. Promises that are rejected have a rejection reason and are in the + rejected state. A fulfillment value is never a thenable. + + Promises can also be said to *resolve* a value. If this value is also a + promise, then the original promise's settled state will match the value's + settled state. So a promise that *resolves* a promise that rejects will + itself reject, and a promise that *resolves* a promise that fulfills will + itself fulfill. + + + Basic Usage: + ------------ + + ```js + let promise = new Promise(function(resolve, reject) { + // on success + resolve(value); + + // on failure + reject(reason); + }); + + promise.then(function(value) { + // on fulfillment + }, function(reason) { + // on rejection + }); + ``` + + Advanced Usage: + --------------- + + Promises shine when abstracting away asynchronous interactions such as + `XMLHttpRequest`s. + + ```js + function getJSON(url) { + return new Promise(function(resolve, reject){ + let xhr = new XMLHttpRequest(); + + xhr.open('GET', url); + xhr.onreadystatechange = handler; + xhr.responseType = 'json'; + xhr.setRequestHeader('Accept', 'application/json'); + xhr.send(); + + function handler() { + if (this.readyState === this.DONE) { + if (this.status === 200) { + resolve(this.response); + } else { + reject(new Error('getJSON: `' + url + '` failed with status: [' + this.status + ']')); + } + } + }; + }); + } + + getJSON('/posts.json').then(function(json) { + // on fulfillment + }, function(reason) { + // on rejection + }); + ``` + + Unlike callbacks, promises are great composable primitives. + + ```js + Promise.all([ + getJSON('/posts'), + getJSON('/comments') + ]).then(function(values){ + values[0] // => postsJSON + values[1] // => commentsJSON + + return values; + }); + ``` + + @class Promise + @param {Function} resolver + Useful for tooling. + @constructor +*/ + +var Promise$1 = function () { + function Promise(resolver) { + this[PROMISE_ID] = nextId(); + this._result = this._state = undefined; + this._subscribers = []; + + if (noop !== resolver) { + typeof resolver !== 'function' && needsResolver(); + this instanceof Promise ? initializePromise(this, resolver) : needsNew(); + } + } + + /** + The primary way of interacting with a promise is through its `then` method, + which registers callbacks to receive either a promise's eventual value or the + reason why the promise cannot be fulfilled. + ```js + findUser().then(function(user){ + // user is available + }, function(reason){ + // user is unavailable, and you are given the reason why + }); + ``` + Chaining + -------- + The return value of `then` is itself a promise. This second, 'downstream' + promise is resolved with the return value of the first promise's fulfillment + or rejection handler, or rejected if the handler throws an exception. + ```js + findUser().then(function (user) { + return user.name; + }, function (reason) { + return 'default name'; + }).then(function (userName) { + // If `findUser` fulfilled, `userName` will be the user's name, otherwise it + // will be `'default name'` + }); + findUser().then(function (user) { + throw new Error('Found user, but still unhappy'); + }, function (reason) { + throw new Error('`findUser` rejected and we're unhappy'); + }).then(function (value) { + // never reached + }, function (reason) { + // if `findUser` fulfilled, `reason` will be 'Found user, but still unhappy'. + // If `findUser` rejected, `reason` will be '`findUser` rejected and we're unhappy'. + }); + ``` + If the downstream promise does not specify a rejection handler, rejection reasons will be propagated further downstream. + ```js + findUser().then(function (user) { + throw new PedagogicalException('Upstream error'); + }).then(function (value) { + // never reached + }).then(function (value) { + // never reached + }, function (reason) { + // The `PedgagocialException` is propagated all the way down to here + }); + ``` + Assimilation + ------------ + Sometimes the value you want to propagate to a downstream promise can only be + retrieved asynchronously. This can be achieved by returning a promise in the + fulfillment or rejection handler. The downstream promise will then be pending + until the returned promise is settled. This is called *assimilation*. + ```js + findUser().then(function (user) { + return findCommentsByAuthor(user); + }).then(function (comments) { + // The user's comments are now available + }); + ``` + If the assimliated promise rejects, then the downstream promise will also reject. + ```js + findUser().then(function (user) { + return findCommentsByAuthor(user); + }).then(function (comments) { + // If `findCommentsByAuthor` fulfills, we'll have the value here + }, function (reason) { + // If `findCommentsByAuthor` rejects, we'll have the reason here + }); + ``` + Simple Example + -------------- + Synchronous Example + ```javascript + let result; + try { + result = findResult(); + // success + } catch(reason) { + // failure + } + ``` + Errback Example + ```js + findResult(function(result, err){ + if (err) { + // failure + } else { + // success + } + }); + ``` + Promise Example; + ```javascript + findResult().then(function(result){ + // success + }, function(reason){ + // failure + }); + ``` + Advanced Example + -------------- + Synchronous Example + ```javascript + let author, books; + try { + author = findAuthor(); + books = findBooksByAuthor(author); + // success + } catch(reason) { + // failure + } + ``` + Errback Example + ```js + function foundBooks(books) { + } + function failure(reason) { + } + findAuthor(function(author, err){ + if (err) { + failure(err); + // failure + } else { + try { + findBoooksByAuthor(author, function(books, err) { + if (err) { + failure(err); + } else { + try { + foundBooks(books); + } catch(reason) { + failure(reason); + } + } + }); + } catch(error) { + failure(err); + } + // success + } + }); + ``` + Promise Example; + ```javascript + findAuthor(). + then(findBooksByAuthor). + then(function(books){ + // found books + }).catch(function(reason){ + // something went wrong + }); + ``` + @method then + @param {Function} onFulfilled + @param {Function} onRejected + Useful for tooling. + @return {Promise} + */ + + /** + `catch` is simply sugar for `then(undefined, onRejection)` which makes it the same + as the catch block of a try/catch statement. + ```js + function findAuthor(){ + throw new Error('couldn't find that author'); + } + // synchronous + try { + findAuthor(); + } catch(reason) { + // something went wrong + } + // async with promises + findAuthor().catch(function(reason){ + // something went wrong + }); + ``` + @method catch + @param {Function} onRejection + Useful for tooling. + @return {Promise} + */ + + + Promise.prototype.catch = function _catch(onRejection) { + return this.then(null, onRejection); + }; + + /** + `finally` will be invoked regardless of the promise's fate just as native + try/catch/finally behaves + + Synchronous example: + + ```js + findAuthor() { + if (Math.random() > 0.5) { + throw new Error(); + } + return new Author(); + } + + try { + return findAuthor(); // succeed or fail + } catch(error) { + return findOtherAuther(); + } finally { + // always runs + // doesn't affect the return value + } + ``` + + Asynchronous example: + + ```js + findAuthor().catch(function(reason){ + return findOtherAuther(); + }).finally(function(){ + // author was either found, or not + }); + ``` + + @method finally + @param {Function} callback + @return {Promise} + */ + + + Promise.prototype.finally = function _finally(callback) { + var promise = this; + var constructor = promise.constructor; + + if (isFunction(callback)) { + return promise.then(function (value) { + return constructor.resolve(callback()).then(function () { + return value; + }); + }, function (reason) { + return constructor.resolve(callback()).then(function () { + throw reason; + }); + }); + } + + return promise.then(callback, callback); + }; + + return Promise; +}(); + +Promise$1.prototype.then = then; +Promise$1.all = all; +Promise$1.race = race; +Promise$1.resolve = resolve$1; +Promise$1.reject = reject$1; +Promise$1._setScheduler = setScheduler; +Promise$1._setAsap = setAsap; +Promise$1._asap = asap; + +/*global self*/ +function polyfill() { + var local = void 0; + + if (typeof global !== 'undefined') { + local = global; + } else if (typeof self !== 'undefined') { + local = self; + } else { + try { + local = Function('return this')(); + } catch (e) { + throw new Error('polyfill failed because global object is unavailable in this environment'); + } + } + + var P = local.Promise; + + if (P) { + var promiseToString = null; + try { + promiseToString = Object.prototype.toString.call(P.resolve()); + } catch (e) { + // silently ignored + } + + if (promiseToString === '[object Promise]' && !P.cast) { + return; + } + } + + local.Promise = Promise$1; +} + +// Strange compat.. +Promise$1.polyfill = polyfill; +Promise$1.Promise = Promise$1; + +return Promise$1; + +}))); + + + +//# sourceMappingURL=es6-promise.map + +/* WEBPACK VAR INJECTION */}.call(this, __webpack_require__(81), __webpack_require__(82))) + +/***/ }), +/* 81 */ +/***/ (function(module, exports) { + +// shim for using process in browser +var process = module.exports = {}; + +// cached from whatever global is present so that test runners that stub it +// don't break things. But we need to wrap it in a try catch in case it is +// wrapped in strict mode code which doesn't define any globals. It's inside a +// function because try/catches deoptimize in certain engines. + +var cachedSetTimeout; +var cachedClearTimeout; + +function defaultSetTimout() { + throw new Error('setTimeout has not been defined'); +} +function defaultClearTimeout () { + throw new Error('clearTimeout has not been defined'); +} +(function () { + try { + if (typeof setTimeout === 'function') { + cachedSetTimeout = setTimeout; + } else { + cachedSetTimeout = defaultSetTimout; + } + } catch (e) { + cachedSetTimeout = defaultSetTimout; + } + try { + if (typeof clearTimeout === 'function') { + cachedClearTimeout = clearTimeout; + } else { + cachedClearTimeout = defaultClearTimeout; + } + } catch (e) { + cachedClearTimeout = defaultClearTimeout; + } +} ()) +function runTimeout(fun) { + if (cachedSetTimeout === setTimeout) { + //normal enviroments in sane situations + return setTimeout(fun, 0); + } + // if setTimeout wasn't available but was latter defined + if ((cachedSetTimeout === defaultSetTimout || !cachedSetTimeout) && setTimeout) { + cachedSetTimeout = setTimeout; + return setTimeout(fun, 0); + } + try { + // when when somebody has screwed with setTimeout but no I.E. maddness + return cachedSetTimeout(fun, 0); + } catch(e){ + try { + // When we are in I.E. but the script has been evaled so I.E. doesn't trust the global object when called normally + return cachedSetTimeout.call(null, fun, 0); + } catch(e){ + // same as above but when it's a version of I.E. that must have the global object for 'this', hopfully our context correct otherwise it will throw a global error + return cachedSetTimeout.call(this, fun, 0); + } + } + + +} +function runClearTimeout(marker) { + if (cachedClearTimeout === clearTimeout) { + //normal enviroments in sane situations + return clearTimeout(marker); + } + // if clearTimeout wasn't available but was latter defined + if ((cachedClearTimeout === defaultClearTimeout || !cachedClearTimeout) && clearTimeout) { + cachedClearTimeout = clearTimeout; + return clearTimeout(marker); + } + try { + // when when somebody has screwed with setTimeout but no I.E. maddness + return cachedClearTimeout(marker); + } catch (e){ + try { + // When we are in I.E. but the script has been evaled so I.E. doesn't trust the global object when called normally + return cachedClearTimeout.call(null, marker); + } catch (e){ + // same as above but when it's a version of I.E. that must have the global object for 'this', hopfully our context correct otherwise it will throw a global error. + // Some versions of I.E. have different rules for clearTimeout vs setTimeout + return cachedClearTimeout.call(this, marker); + } + } + + + +} +var queue = []; +var draining = false; +var currentQueue; +var queueIndex = -1; + +function cleanUpNextTick() { + if (!draining || !currentQueue) { + return; + } + draining = false; + if (currentQueue.length) { + queue = currentQueue.concat(queue); + } else { + queueIndex = -1; + } + if (queue.length) { + drainQueue(); + } +} + +function drainQueue() { + if (draining) { + return; + } + var timeout = runTimeout(cleanUpNextTick); + draining = true; + + var len = queue.length; + while(len) { + currentQueue = queue; + queue = []; + while (++queueIndex < len) { + if (currentQueue) { + currentQueue[queueIndex].run(); + } + } + queueIndex = -1; + len = queue.length; + } + currentQueue = null; + draining = false; + runClearTimeout(timeout); +} + +process.nextTick = function (fun) { + var args = new Array(arguments.length - 1); + if (arguments.length > 1) { + for (var i = 1; i < arguments.length; i++) { + args[i - 1] = arguments[i]; + } + } + queue.push(new Item(fun, args)); + if (queue.length === 1 && !draining) { + runTimeout(drainQueue); + } +}; + +// v8 likes predictible objects +function Item(fun, array) { + this.fun = fun; + this.array = array; +} +Item.prototype.run = function () { + this.fun.apply(null, this.array); +}; +process.title = 'browser'; +process.browser = true; +process.env = {}; +process.argv = []; +process.version = ''; // empty string to avoid regexp issues +process.versions = {}; + +function noop() {} + +process.on = noop; +process.addListener = noop; +process.once = noop; +process.off = noop; +process.removeListener = noop; +process.removeAllListeners = noop; +process.emit = noop; +process.prependListener = noop; +process.prependOnceListener = noop; + +process.listeners = function (name) { return [] } + +process.binding = function (name) { + throw new Error('process.binding is not supported'); +}; + +process.cwd = function () { return '/' }; +process.chdir = function (dir) { + throw new Error('process.chdir is not supported'); +}; +process.umask = function() { return 0; }; + + +/***/ }), +/* 82 */ +/***/ (function(module, exports) { + +var g; + +// This works in non-strict mode +g = (function() { + return this; +})(); + +try { + // This works if eval is allowed (see CSP) + g = g || new Function("return this")(); +} catch (e) { + // This works if the window reference is available + if (typeof window === "object") g = window; +} + +// g can still be undefined, but nothing to do about it... +// We return undefined, instead of nothing here, so it's +// easier to handle this case. if(!global) { ...} + +module.exports = g; + + +/***/ }), +/* 83 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +Object.defineProperty(exports, "__esModule", { value: true }); +exports.inArray = function (needle, haystack) { return haystack.indexOf(needle) !== -1; }; + + +/***/ }), +/* 84 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +Object.defineProperty(exports, "__esModule", { value: true }); +exports.splitArray = function (a) { + return typeof a === 'string' ? a.split(/[,\s]+/) : a; +}; + + +/***/ }), +/* 85 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +Object.defineProperty(exports, "__esModule", { value: true }); +var setTimeout_1 = __webpack_require__(19); +exports.throttle = function (fn, timeout, ctx) { + var timer = null, args, needInvoke, callee; + return function () { + args = arguments; + needInvoke = true; + var context = ctx || this; + if (!timeout) { + fn.apply(context, args); + return; + } + if (!timer) { + callee = function () { + if (needInvoke) { + fn.apply(context, args); + needInvoke = false; + timer = setTimeout_1.setTimeout(callee, timeout); + } + else { + timer = null; + } + }; + callee(); + } + }; +}; + + +/***/ }), +/* 86 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +Object.defineProperty(exports, "__esModule", { value: true }); +exports.hasBrowserColorPicker = function () { + var supportsColor = true; + try { + var a = document.createElement("input"); + a.type = "color"; + supportsColor = a.type === "color" && typeof a.selectionStart !== "number"; + } + catch (e) { + supportsColor = false; + } + return supportsColor; +}; + + +/***/ }), +/* 87 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +Object.defineProperty(exports, "__esModule", { value: true }); +exports.isHTML = function (str) { + return /<([A-Za-z][A-Za-z0-9]*)\b[^>]*>(.*?)<\/\1>/m.test(str); +}; + + +/***/ }), +/* 88 */ +/***/ (function(module, exports, __webpack_require__) { + +"use strict"; + +/*! + * Jodit Editor (https://xdsoft.net/jodit/) + * Licensed under GNU General Public License version 2 or later or a commercial license or MIT; + * For GPL see LICENSE-GPL.txt in the project root for license information. + * For MIT see LICENSE-MIT.txt in the project root for license information. + * For commercial licenses see https://xdsoft.net/jodit/commercial/ + * Copyright (c) 2013-2019 Valeriy Chupurnov. All rights reserved. https://xdsoft.net + */ +Object.defineProperty(exports, "__esModule", { value: true }); +exports.isHTMLFromWord = function (data) { + return (data.search(//) !== -1 || + data.search(//) !== -1 || + (data.search(/style="[^"]*mso-/) !== -1 && data.search(/') + ''.length); + var iframe = document.createElement('iframe'); + iframe.style.display = 'none'; + document.body.appendChild(iframe); + var convertedString = '', collection = [], rules = []; + try { + var iframeDoc = iframe.contentDocument || + (iframe.contentWindow ? iframe.contentWindow.document : null); + if (iframeDoc) { + iframeDoc.open(); + iframeDoc.write(html); + iframeDoc.close(); + if (iframeDoc.styleSheets.length) { + rules = iframeDoc.styleSheets[iframeDoc.styleSheets.length - 1].cssRules; + } + var _loop_1 = function (idx) { + if (rules[idx].selectorText === '') { + return "continue"; + } + collection = selector_1.$$(rules[idx].selectorText, iframeDoc.body); + collection.forEach(function (elm) { + elm.style.cssText = rules[idx].style.cssText + .replace(/mso-[a-z\-]+:[\s]*[^;]+;/g, '') + .replace(/border[a-z\-]*:[\s]*[^;]+;/g, '') + elm.style.cssText; + }); + }; + for (var idx = 0; idx < rules.length; idx += 1) { + _loop_1(idx); + } + convertedString = iframeDoc.firstChild + ? iframeDoc.body.innerHTML + : ''; + } + } + catch (_a) { + } + finally { + Dom_1.Dom.safeRemove(iframe); + } + if (convertedString) { + html = convertedString; + } + return html + .replace(/<(\/)?(html|colgroup|col|o:p)[^>]*>/g, '') + .replace(//i);-1!==t&&(e=e.substr(t+20));var o=e.search(//i);return-1!==o&&(e=e.substr(0,o)),e};e.events.on("paste",(function(o){if(!1===e.events.fire("beforePaste",o))return o.preventDefault(),!1;var i=t.getDataTransfer(o);if(o&&i){var a=i.types,c="";if(Array.isArray(a)||"domstringlist"===s.type(a))for(var p=0;a.length>p;p+=1)c+=a[p]+";";else c=a.toString()+";";var f=/text\/html/i.test(c)?i.getData("text/html"):/text\/rtf/i.test(c)&&s.browser("safari")?i.getData("text/rtf"):/text\/plain/i.test(c)&&!s.browser("mozilla")?i.getData(r.TEXT_PLAIN):/text/i.test(c)&&r.IS_IE?i.getData(r.TEXT_PLAIN):"";(l.Dom.isNode(f,e.editorWindow)||""!==s.trim(f))&&(f=u(f),e.buffer.get(d.pluginKey)!==f&&(f=e.events.fire("processPaste",o,f,c)),("string"==typeof f||l.Dom.isNode(f,e.editorWindow))&&("drop"===o.type&&e.selection.insertCursorAtPoint(o.clientX,o.clientY),n(f,e.options.defaultActionOnPaste)),o.preventDefault(),o.stopPropagation())}return!1!==e.events.fire("afterPaste",o)&&void 0})),e.options.askBeforePasteHTML&&e.events.on("beforePaste",(function(e){var o=t.getDataTransfer(e);if(e&&o&&o.getData(r.TEXT_PLAIN)){var n=o.getData(r.TEXT_PLAIN);return i(n,e)}})),e.options.askBeforePasteFromWord&&e.events.on("beforePaste",(function(n){var a=t.getDataTransfer(n);if(n&&a&&a.getData&&a.getData(r.TEXT_HTML)){var c=function(t){var r=e.buffer.get(d.pluginKey);if(s.isHTML(t)&&r!==u(t))return s.isHTMLFromWord(t)?o(e.i18n("The pasted content is coming from a Microsoft Word/Excel document. Do you want to keep the format or clean it up?"),e.i18n("Word Paste Detected"),(function(o){!0===o&&(t=s.applyStyles(t),e.options.beautifyHTML&&e.ownerWindow.html_beautify&&(t=e.ownerWindow.html_beautify(t))),!1===o&&(t=s.cleanFromWord(t)),0===o&&(t=s.stripTags(s.cleanFromWord(t))),e.selection.insertHTML(t),e.setEditorValue()})):i(t,n),!1};if(a.types&&-1!==Array.from(a.types).indexOf("text/html")){var p=a.getData(r.TEXT_HTML);return c(p)}if("drop"!==n.type){var f=e.create.div("",{tabindex:-1,contenteditable:!0,style:{left:-9999,top:0,width:0,height:"100%",lineHeight:"140%",overflow:"hidden",position:"fixed",zIndex:2147483647,wordBreak:"break-all"}});e.container.appendChild(f);var h=e.selection.save();f.focus();var v=0,m=function(){l.Dom.safeRemove(f),e.selection&&e.selection.restore(h)},g=function(){if(v+=1,f.childNodes&&f.childNodes.length>0){var t=f.innerHTML;return m(),void(!1!==c(t)&&e.selection.insertHTML(t))}5>v?s.setTimeout(g,20):m()};g()}}})),e.options.nl2brInPlainText&&e.events.on("processPaste",(function(e,t,o){if(o===r.TEXT_PLAIN+";"&&!s.isHTML(t))return c.nl2br(t)}))}},function(e,t,o){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=o(17),i=o(6);t.Promt=function(e,t,o,a,s){var l=new n.Dialog,c=l.create.fromHTML(''+i.ToolbarIcon.getIcon("cancel")+""+r.Jodit.prototype.i18n("Cancel")+""),d=l.create.fromHTML(''+i.ToolbarIcon.getIcon("check")+""+r.Jodit.prototype.i18n("Ok")+""),u=l.create.element("form",{class:"jodit_promt"}),p=l.create.element("input",{autofocus:!0,class:"jodit_input"}),f=l.create.element("label");"function"==typeof t&&(o=t,t=void 0),a&&p.setAttribute("placeholder",a),f.appendChild(l.create.text(e)),u.appendChild(f),u.appendChild(p),c.addEventListener("click",l.close,!1);var h=function(){o&&"function"==typeof o&&!1===o(p.value)||l.close()};return d.addEventListener("click",h),u.addEventListener("submit",(function(){return h(),!1})),l.setFooter([d,c]),l.open(u,t||" ",!0,!0),p.focus(),void 0!==s&&s.length&&(p.value=s,p.select()),l};var r=o(11)},function(e,t,o){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=o(17),i=o(6);t.Confirm=function(e,t,o){var a=new n.Dialog,s=a.create.fromHTML('
'),l=a.create.element("label");"function"==typeof t&&(o=t,t=void 0),l.appendChild(a.create.fromHTML(e)),s.appendChild(l);var c=a.create.fromHTML(''+i.ToolbarIcon.getIcon("cancel")+""+r.Jodit.prototype.i18n("Cancel")+"");c.addEventListener("click",(function(){o&&o(!1),a.close()}));var d=function(){o&&o(!0),a.close()},u=a.create.fromHTML(''+i.ToolbarIcon.getIcon("check")+""+r.Jodit.prototype.i18n("Yes")+"");return u.addEventListener("click",d),s.addEventListener("submit",(function(){return d(),!1})),a.setFooter([u,c]),a.open(s,t||" ",!0,!0),u.focus(),a};var r=o(11)},function(e,t,o){e.exports=o(75)},function(e,t,o){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),o(76),"undefined"!=typeof window&&o(77);var n=o(11),i=o(128),r=o(2),a=o(68),s=o(69),l=o(196),c=o(3),d=o(6);Object.keys(r).forEach((function(e){n.Jodit[e]=r[e]}));var u=function(e){return"__esModule"!==e};Object.keys(l).filter(u).forEach((function(e){d.ToolbarIcon.setIcon(e.replace("_","-"),l[e])})),Object.keys(a).filter(u).forEach((function(e){n.Jodit.modules[e]=a[e]})),["Confirm","Alert","Promt"].forEach((function(e){n.Jodit[e]=a[e]})),Object.keys(s).filter(u).forEach((function(e){n.Jodit.plugins.add(e,s[e])})),Object.keys(i.default).filter(u).forEach((function(e){n.Jodit.lang[e]=i.default[e]})),n.Jodit.defaultOptions=c.Config.defaultOptions,c.OptionsDefault.prototype=n.Jodit.defaultOptions,t.Jodit=n.Jodit,t.default=n.Jodit},function(e,t,o){},function(e,t,o){"use strict";var n;Object.defineProperty(t,"__esModule",{value:!0}),o(78),o(79),(n=Element.prototype).matches||(n.matches=void 0!==n.matchesSelector?n.matchesSelector:function(e){if(!this.ownerDocument)return[];var t=this.ownerDocument.querySelectorAll(e),o=this;return Array.prototype.some.call(t,(function(e){return e===o}))}),Array.from||(Array.from=function(e){return[].slice.call(e)}),Array.prototype.includes||(Array.prototype.includes=function(e){return this.indexOf(e)>-1})},function(e,t){"document"in window.self&&("classList"in document.createElement("_")&&(!document.createElementNS||"classList"in document.createElementNS("http://www.w3.org/2000/svg","g"))||function(e){"use strict";if("Element"in e){var t=e.Element.prototype,o=Object,n=String.prototype.trim||function(){return this.replace(/^\s+|\s+$/g,"")},i=Array.prototype.indexOf||function(e){for(var t=0,o=this.length;o>t;t++)if(t in this&&this[t]===e)return t;return-1},r=function(e,t){this.name=e,this.code=DOMException[e],this.message=t},a=function(e,t){if(""===t)throw new r("SYNTAX_ERR","An invalid or illegal string was specified");if(/\s/.test(t))throw new r("INVALID_CHARACTER_ERR","String contains an invalid character");return i.call(e,t)},s=function(e){for(var t=n.call(e.getAttribute("class")||""),o=t?t.split(/\s+/):[],i=0,r=o.length;r>i;i++)this.push(o[i]);this._updateClassName=function(){e.setAttribute("class",this.toString())}},l=s.prototype=[],c=function(){return new s(this)};if(r.prototype=Error.prototype,l.item=function(e){return this[e]||null},l.contains=function(e){return-1!==a(this,e+="")},l.add=function(){var e,t=arguments,o=0,n=t.length,i=!1;do{-1===a(this,e=t[o]+"")&&(this.push(e),i=!0)}while(++oo;o++)t.call(this,e=arguments[o])}};t("add"),t("remove")}if(e.classList.toggle("c3",!1),e.classList.contains("c3")){var o=DOMTokenList.prototype.toggle;DOMTokenList.prototype.toggle=function(e,t){return 1 in arguments&&!this.contains(e)==!t?t:o.call(this,e)}}e=null}())},function(e,t,o){"use strict";e.exports=o(80).polyfill()},function(e,t,o){(function(t,o){e.exports=function(){"use strict";function e(e){return"function"==typeof e}var n=Array.isArray?Array.isArray:function(e){return"[object Array]"===Object.prototype.toString.call(e)},i=0,r=void 0,a=void 0,s=function(e,t){h[i]=e,h[i+1]=t,2===(i+=2)&&(a?a(v):y())},l="undefined"!=typeof window?window:void 0,c=l||{},d=c.MutationObserver||c.WebKitMutationObserver,u="undefined"==typeof self&&void 0!==t&&"[object process]"==={}.toString.call(t),p="undefined"!=typeof Uint8ClampedArray&&"undefined"!=typeof importScripts&&"undefined"!=typeof MessageChannel;function f(){var e=setTimeout;return function(){return e(v,1)}}var h=new Array(1e3);function v(){for(var e=0;i>e;e+=2)(0,h[e])(h[e+1]),h[e]=void 0,h[e+1]=void 0;i=0}var m,g,b,_,y=void 0;function w(e,t){var o=this,n=new this.constructor(j);void 0===n[S]&&N(n);var i=o._state;if(i){var r=arguments[i-1];s((function(){return q(i,n,r,o._result)}))}else A(o,n,e,t);return n}function C(e){if(e&&"object"==typeof e&&e.constructor===this)return e;var t=new this(j);return z(t,e),t}u?y=function(){return t.nextTick(v)}:d?(g=0,b=new d(v),_=document.createTextNode(""),b.observe(_,{characterData:!0}),y=function(){_.data=g=++g%2}):p?((m=new MessageChannel).port1.onmessage=v,y=function(){return m.port2.postMessage(0)}):y=void 0===l?function(){try{var e=Function("return this")().require("vertx");return void 0!==(r=e.runOnLoop||e.runOnContext)?function(){r(v)}:f()}catch(e){return f()}}():f();var S=Math.random().toString(36).substring(2);function j(){}var E=void 0,k=1,T=2;function x(t,o,n){o.constructor===t.constructor&&n===w&&o.constructor.resolve===C?function(e,t){t._state===k?D(e,t._result):t._state===T?M(e,t._result):A(t,void 0,(function(t){return z(e,t)}),(function(t){return M(e,t)}))}(t,o):void 0===n?D(t,o):e(n)?function(e,t,o){s((function(e){var n=!1,i=function(o,i,r,a){try{o.call(i,(function(o){n||(n=!0,t!==o?z(e,o):D(e,o))}),(function(t){n||(n=!0,M(e,t))}))}catch(e){return e}}(o,t);!n&&i&&(n=!0,M(e,i))}),e)}(t,o,n):D(t,o)}function z(e,t){if(e===t)M(e,new TypeError("You cannot resolve a promise with itself"));else if(i=typeof(n=t),null===n||"object"!==i&&"function"!==i)D(e,t);else{var o=void 0;try{o=t.then}catch(t){return void M(e,t)}x(e,t,o)}var n,i}function L(e){e._onerror&&e._onerror(e._result),I(e)}function D(e,t){e._state===E&&(e._result=t,e._state=k,0!==e._subscribers.length&&s(I,e))}function M(e,t){e._state===E&&(e._state=T,e._result=t,s(L,e))}function A(e,t,o,n){var i=e._subscribers,r=i.length;e._onerror=null,i[r]=t,i[r+k]=o,i[r+T]=n,0===r&&e._state&&s(I,e)}function I(e){var t=e._subscribers,o=e._state;if(0!==t.length){for(var n=void 0,i=void 0,r=e._result,a=0;t.length>a;a+=3)i=t[a+o],(n=t[a])?q(o,n,i,r):i(r);e._subscribers.length=0}}function q(t,o,n,i){var r=e(n),a=void 0,s=void 0,l=!0;if(r){try{a=n(i)}catch(e){l=!1,s=e}if(o===a)return void M(o,new TypeError("A promises callback cannot return that same promise."))}else a=i;o._state!==E||(r&&l?z(o,a):!1===l?M(o,s):t===k?D(o,a):t===T&&M(o,a))}var P=0;function N(e){e[S]=P++,e._state=void 0,e._result=void 0,e._subscribers=[]}var O=function(){function e(e,t){this._instanceConstructor=e,this.promise=new e(j),this.promise[S]||N(this.promise),n(t)?(this.length=t.length,this._remaining=t.length,this._result=new Array(this.length),0===this.length?D(this.promise,this._result):(this.length=this.length||0,this._enumerate(t),0===this._remaining&&D(this.promise,this._result))):M(this.promise,new Error("Array Methods must be provided an Array"))}return e.prototype._enumerate=function(e){for(var t=0;this._state===E&&e.length>t;t++)this._eachEntry(e[t],t)},e.prototype._eachEntry=function(e,t){var o=this._instanceConstructor,n=o.resolve;if(n===C){var i=void 0,r=void 0,a=!1;try{i=e.then}catch(e){a=!0,r=e}if(i===w&&e._state!==E)this._settledAt(e._state,t,e._result);else if("function"!=typeof i)this._remaining--,this._result[t]=e;else if(o===R){var s=new o(j);a?M(s,r):x(s,e,i),this._willSettleAt(s,t)}else this._willSettleAt(new o((function(t){return t(e)})),t)}else this._willSettleAt(n(e),t)},e.prototype._settledAt=function(e,t,o){var n=this.promise;n._state===E&&(this._remaining--,e===T?M(n,o):this._result[t]=o),0===this._remaining&&D(n,this._result)},e.prototype._willSettleAt=function(e,t){var o=this;A(e,void 0,(function(e){return o._settledAt(k,t,e)}),(function(e){return o._settledAt(T,t,e)}))},e}(),R=function(){function t(e){this[S]=P++,this._result=this._state=void 0,this._subscribers=[],j!==e&&("function"!=typeof e&&function(){throw new TypeError("You must pass a resolver function as the first argument to the promise constructor")}(),this instanceof t?function(e,t){try{t((function(t){z(e,t)}),(function(t){M(e,t)}))}catch(t){M(e,t)}}(this,e):function(){throw new TypeError("Failed to construct 'Promise': Please use the 'new' operator, this object constructor cannot be called as a function.")}())}return t.prototype.catch=function(e){return this.then(null,e)},t.prototype.finally=function(t){var o=this.constructor;return e(t)?this.then((function(e){return o.resolve(t()).then((function(){return e}))}),(function(e){return o.resolve(t()).then((function(){throw e}))})):this.then(t,t)},t}();return R.prototype.then=w,R.all=function(e){return new O(this,e).promise},R.race=function(e){var t=this;return n(e)?new t((function(o,n){for(var i=e.length,r=0;i>r;r++)t.resolve(e[r]).then(o,n)})):new t((function(e,t){return t(new TypeError("You must pass an array to race."))}))},R.resolve=C,R.reject=function(e){var t=new this(j);return M(t,e),t},R._setScheduler=function(e){a=e},R._setAsap=function(e){s=e},R._asap=s,R.polyfill=function(){var e=void 0;if(void 0!==o)e=o;else if("undefined"!=typeof self)e=self;else try{e=Function("return this")()}catch(e){throw new Error("polyfill failed because global object is unavailable in this environment")}var t=e.Promise;if(t){var n=null;try{n=Object.prototype.toString.call(t.resolve())}catch(e){}if("[object Promise]"===n&&!t.cast)return}e.Promise=R},R.Promise=R,R}()}).call(this,o(81),o(82))},function(e,t){var o,n,i=e.exports={};function r(){throw new Error("setTimeout has not been defined")}function a(){throw new Error("clearTimeout has not been defined")}function s(e){if(o===setTimeout)return setTimeout(e,0);if((o===r||!o)&&setTimeout)return o=setTimeout,setTimeout(e,0);try{return o(e,0)}catch(t){try{return o.call(null,e,0)}catch(t){return o.call(this,e,0)}}}!function(){try{o="function"==typeof setTimeout?setTimeout:r}catch(e){o=r}try{n="function"==typeof clearTimeout?clearTimeout:a}catch(e){n=a}}();var l,c=[],d=!1,u=-1;function p(){d&&l&&(d=!1,l.length?c=l.concat(c):u=-1,c.length&&f())}function f(){if(!d){var e=s(p);d=!0;for(var t=c.length;t;){for(l=c,c=[];++u1)for(var o=1;arguments.length>o;o++)t[o-1]=arguments[o];c.push(new h(e,t)),1!==c.length||d||s(f)},h.prototype.run=function(){this.fun.apply(null,this.array)},i.title="browser",i.browser=!0,i.env={},i.argv=[],i.version="",i.versions={},i.on=v,i.addListener=v,i.once=v,i.off=v,i.removeListener=v,i.removeAllListeners=v,i.emit=v,i.prependListener=v,i.prependOnceListener=v,i.listeners=function(e){return[]},i.binding=function(e){throw new Error("process.binding is not supported")},i.cwd=function(){return"/"},i.chdir=function(e){throw new Error("process.chdir is not supported")},i.umask=function(){return 0}},function(e,t){var o;o=function(){return this}();try{o=o||new Function("return this")()}catch(e){"object"==typeof window&&(o=window)}e.exports=o},function(e,t,o){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.inArray=function(e,t){return-1!==t.indexOf(e)}},function(e,t,o){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.splitArray=function(e){return"string"==typeof e?e.split(/[,\s]+/):e}},function(e,t,o){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=o(19);t.throttle=function(e,t,o){var i,r,a,s=null;return function(){i=arguments,r=!0;var l=o||this;t?s||(a=function(){r?(e.apply(l,i),r=!1,s=n.setTimeout(a,t)):s=null})():e.apply(l,i)}}},function(e,t,o){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.hasBrowserColorPicker=function(){var e=!0;try{var t=document.createElement("input");t.type="color",e="color"===t.type&&"number"!=typeof t.selectionStart}catch(t){e=!1}return e}},function(e,t,o){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.isHTML=function(e){return/<([A-Za-z][A-Za-z0-9]*)\b[^>]*>(.*?)<\/\1>/m.test(e)}},function(e,t,o){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.isHTMLFromWord=function(e){return-1!==e.search(//)||-1!==e.search(//)||-1!==e.search(/style="[^"]*mso-/)&&-1!==e.search(/")+"".length);var t=document.createElement("iframe");t.style.display="none",document.body.appendChild(t);var o="",r=[];try{var a=t.contentDocument||(t.contentWindow?t.contentWindow.document:null);if(a){a.open(),a.write(e),a.close(),a.styleSheets.length&&(r=a.styleSheets[a.styleSheets.length-1].cssRules);for(var s=function(e){if(""===r[e].selectorText)return"continue";i.$$(r[e].selectorText,a.body).forEach((function(t){t.style.cssText=r[e].style.cssText.replace(/mso-[a-z\-]+:[\s]*[^;]+;/g,"").replace(/border[a-z\-]*:[\s]*[^;]+;/g,"")+t.style.cssText}))},l=0;r.length>l;l+=1)s(l);o=a.firstChild?a.body.innerHTML:""}}catch(e){}finally{n.Dom.safeRemove(t)}return o&&(e=o),e.replace(/<(\/)?(html|colgroup|col|o:p)[^>]*>/g,"").replace(/