@ckeditor/ckeditor5-editor-classic 41.1.0 → 41.3.0-alpha.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/build/editor-classic.js +1 -1
- package/dist/content-index.css +4 -0
- package/dist/editor-index.css +10 -0
- package/dist/index.css +22 -0
- package/dist/index.css.map +1 -0
- package/dist/index.js +446 -0
- package/dist/index.js.map +1 -0
- package/dist/types/classiceditor.d.ts +180 -0
- package/dist/types/classiceditorui.d.ts +75 -0
- package/dist/types/classiceditoruiview.d.ts +47 -0
- package/dist/types/index.d.ts +8 -0
- package/package.json +3 -2
- package/src/classiceditor.d.ts +1 -1
- package/src/classiceditor.js +2 -2
package/build/editor-classic.js
CHANGED
@@ -1,4 +1,4 @@
|
|
1
1
|
/*!
|
2
2
|
* @license Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.
|
3
3
|
* For licensing, see LICENSE.md.
|
4
|
-
*/(()=>{var t={400:(t,e,o)=>{"use strict";o.d(e,{c:()=>n});var i=o(849),r=o.n(i)()((function(t){return t[1]}));r.push([t.id,".ck.ck-editor{position:relative}.ck.ck-editor .ck-editor__top .ck-sticky-panel .ck-toolbar{z-index:var(--ck-z-panel)}.ck.ck-editor__top .ck-sticky-panel .ck-toolbar{border-radius:0}.ck-rounded-corners .ck.ck-editor__top .ck-sticky-panel .ck-toolbar,.ck.ck-editor__top .ck-sticky-panel .ck-toolbar.ck-rounded-corners{border-radius:var(--ck-border-radius);border-bottom-left-radius:0;border-bottom-right-radius:0}.ck.ck-editor__top .ck-sticky-panel .ck-toolbar{border-bottom-width:0}.ck.ck-editor__top .ck-sticky-panel .ck-sticky-panel__content_sticky .ck-toolbar{border-bottom-width:1px;border-radius:0}.ck-rounded-corners .ck.ck-editor__top .ck-sticky-panel .ck-sticky-panel__content_sticky .ck-toolbar,.ck.ck-editor__top .ck-sticky-panel .ck-sticky-panel__content_sticky .ck-toolbar.ck-rounded-corners{border-radius:var(--ck-border-radius);border-radius:0}.ck.ck-editor__main>.ck-editor__editable{background:var(--ck-color-base-background);border-radius:0}.ck-rounded-corners .ck.ck-editor__main>.ck-editor__editable,.ck.ck-editor__main>.ck-editor__editable.ck-rounded-corners{border-radius:var(--ck-border-radius);border-top-left-radius:0;border-top-right-radius:0}.ck.ck-editor__main>.ck-editor__editable:not(.ck-focused){border-color:var(--ck-color-base-border)}",""]);const n=r},849:t=>{"use strict";t.exports=function(t){var e=[];return e.toString=function(){return this.map((function(e){var o=t(e);return e[2]?"@media ".concat(e[2]," {").concat(o,"}"):o})).join("")},e.i=function(t,o,i){"string"==typeof t&&(t=[[null,t,""]]);var r={};if(i)for(var n=0;n<this.length;n++){var c=this[n][0];null!=c&&(r[c]=!0)}for(var a=0;a<t.length;a++){var s=[].concat(t[a]);i&&r[s[0]]||(o&&(s[2]?s[2]="".concat(o," and ").concat(s[2]):s[2]=o),e.push(s))}},e}},108:(t,e,o)=>{"use strict";var i,r=function(){return void 0===i&&(i=Boolean(window&&document&&document.all&&!window.atob)),i},n=function(){var t={};return function(e){if(void 0===t[e]){var o=document.querySelector(e);if(window.HTMLIFrameElement&&o instanceof window.HTMLIFrameElement)try{o=o.contentDocument.head}catch(t){o=null}t[e]=o}return t[e]}}(),c=[];function a(t){for(var e=-1,o=0;o<c.length;o++)if(c[o].identifier===t){e=o;break}return e}function s(t,e){for(var o={},i=[],r=0;r<t.length;r++){var n=t[r],s=e.base?n[0]+e.base:n[0],l=o[s]||0,d="".concat(s," ").concat(l);o[s]=l+1;var u=a(d),h={css:n[1],media:n[2],sourceMap:n[3]};-1!==u?(c[u].references++,c[u].updater(h)):c.push({identifier:d,updater:k(h,e),references:1}),i.push(d)}return i}function l(t){var e=document.createElement("style"),i=t.attributes||{};if(void 0===i.nonce){var r=o.nc;r&&(i.nonce=r)}if(Object.keys(i).forEach((function(t){e.setAttribute(t,i[t])})),"function"==typeof t.insert)t.insert(e);else{var c=n(t.insert||"head");if(!c)throw new Error("Couldn't find a style target. This probably means that the value for the 'insert' parameter is invalid.");c.appendChild(e)}return e}var d,u=(d=[],function(t,e){return d[t]=e,d.filter(Boolean).join("\n")});function h(t,e,o,i){var r=o?"":i.media?"@media ".concat(i.media," {").concat(i.css,"}"):i.css;if(t.styleSheet)t.styleSheet.cssText=u(e,r);else{var n=document.createTextNode(r),c=t.childNodes;c[e]&&t.removeChild(c[e]),c.length?t.insertBefore(n,c[e]):t.appendChild(n)}}function f(t,e,o){var i=o.css,r=o.media,n=o.sourceMap;if(r?t.setAttribute("media",r):t.removeAttribute("media"),n&&"undefined"!=typeof btoa&&(i+="\n/*# sourceMappingURL=data:application/json;base64,".concat(btoa(unescape(encodeURIComponent(JSON.stringify(n))))," */")),t.styleSheet)t.styleSheet.cssText=i;else{for(;t.firstChild;)t.removeChild(t.firstChild);t.appendChild(document.createTextNode(i))}}var p=null,b=0;function k(t,e){var o,i,r;if(e.singleton){var n=b++;o=p||(p=l(e)),i=h.bind(null,o,n,!1),r=h.bind(null,o,n,!0)}else o=l(e),i=f.bind(null,o,e),r=function(){!function(t){if(null===t.parentNode)return!1;t.parentNode.removeChild(t)}(o)};return i(t),function(e){if(e){if(e.css===t.css&&e.media===t.media&&e.sourceMap===t.sourceMap)return;i(t=e)}else r()}}t.exports=function(t,e){(e=e||{}).singleton||"boolean"==typeof e.singleton||(e.singleton=r());var o=s(t=t||[],e);return function(t){if(t=t||[],"[object Array]"===Object.prototype.toString.call(t)){for(var i=0;i<o.length;i++){var r=a(o[i]);c[r].references--}for(var n=s(t,e),l=0;l<o.length;l++){var d=a(o[l]);0===c[d].references&&(c[d].updater(),c.splice(d,1))}o=n}}}},968:(t,e,o)=>{t.exports=o(672)("./src/core.js")},684:(t,e,o)=>{t.exports=o(672)("./src/engine.js")},348:(t,e,o)=>{t.exports=o(672)("./src/ui.js")},316:(t,e,o)=>{t.exports=o(672)("./src/utils.js")},344:(t,e,o)=>{t.exports=o(672)("./src/watchdog.js")},672:t=>{"use strict";t.exports=CKEditor5.dll}},e={};function o(i){var r=e[i];if(void 0!==r)return r.exports;var n=e[i]={id:i,exports:{}};return t[i](n,n.exports,o),n.exports}o.n=t=>{var e=t&&t.__esModule?()=>t.default:()=>t;return o.d(e,{a:e}),e},o.d=(t,e)=>{for(var i in e)o.o(e,i)&&!o.o(t,i)&&Object.defineProperty(t,i,{enumerable:!0,get:e[i]})},o.o=(t,e)=>Object.prototype.hasOwnProperty.call(t,e),o.r=t=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},o.nc=void 0;var i={};(()=>{"use strict";o.r(i),o.d(i,{ClassicEditor:()=>N});var t=o(348),e=o(684),r=o(316);class n extends t.EditorUI{constructor(e,o){super(e),this.view=o,this._toolbarConfig=(0,t.normalizeToolbarConfig)(e.config.get("toolbar")),this._elementReplacer=new r.ElementReplacer,this.listenTo(e.editing.view,"scrollToTheSelection",this._handleScrollToTheSelectionWithStickyPanel.bind(this))}get element(){return this.view.element}init(t){const e=this.editor,o=this.view,i=e.editing.view,r=o.editable,n=i.document.getRoot();r.name=n.rootName,o.render();const c=r.element;this.setEditableElement(r.name,c),o.editable.bind("isFocused").to(this.focusTracker),i.attachDomRoot(c),t&&this._elementReplacer.replace(t,this.element),this._initPlaceholder(),this._initToolbar(),this._initDialogPluginIntegration(),this.fire("ready")}destroy(){super.destroy();const t=this.view,e=this.editor.editing.view;this._elementReplacer.restore(),e.detachDomRoot(t.editable.name),t.destroy()}_initToolbar(){const t=this.view;t.stickyPanel.bind("isActive").to(this.focusTracker,"isFocused"),t.stickyPanel.limiterElement=t.element,t.stickyPanel.bind("viewportTopOffset").to(this,"viewportOffset",(({top:t})=>t||0)),t.toolbar.fillFromConfig(this._toolbarConfig,this.componentFactory),this.addToolbar(t.toolbar)}_initPlaceholder(){const t=this.editor,o=t.editing.view,i=o.document.getRoot(),r=t.sourceElement;let n;const c=t.config.get("placeholder");c&&(n="string"==typeof c?c:c[this.view.editable.name]),!n&&r&&"textarea"===r.tagName.toLowerCase()&&(n=r.getAttribute("placeholder")),n&&(i.placeholder=n),(0,e.enablePlaceholder)({view:o,element:i,isDirectHost:!1,keepOnFocus:!0})}_handleScrollToTheSelectionWithStickyPanel(t,e,o){const i=this.view.stickyPanel;if(i.isSticky){const t=new r.Rect(i.element).height;e.viewportOffset.top+=t}else{const t=()=>{this.editor.editing.view.scrollToTheSelection(o)};this.listenTo(i,"change:isSticky",t),setTimeout((()=>{this.stopListening(i,"change:isSticky",t)}),20)}}_initDialogPluginIntegration(){if(!this.editor.plugins.has("Dialog"))return;const e=this.view.stickyPanel,o=this.editor.plugins.get("Dialog");o.on("show",(()=>{const i=o.view;i.on("moveTo",((o,n)=>{if(!e.isSticky||i.wasMoved)return;const c=new r.Rect(e.contentPanelElement);n[1]<c.bottom+t.DialogView.defaultOffset&&(n[1]=c.bottom+t.DialogView.defaultOffset)}),{priority:"high"})}),{priority:"low"})}}var c=o(108),a=o.n(c),s=o(400),l={injectType:"singletonStyleTag",attributes:{"data-cke":!0},insert:"head",singleton:!0};a()(s.c,l);s.c.locals;class d extends t.BoxedEditorUIView{constructor(e,o,i={}){super(e),this.stickyPanel=new t.StickyPanelView(e),this.toolbar=new t.ToolbarView(e,{shouldGroupWhenFull:i.shouldToolbarGroupWhenFull}),this.editable=new t.InlineEditableUIView(e,o)}render(){super.render(),this.stickyPanel.content.add(this.toolbar),this.top.add(this.stickyPanel),this.main.add(this.editable)}}var u=o(968),h=o(344);const f=function(t){return null!=t&&"object"==typeof t};const p="object"==typeof global&&global&&global.Object===Object&&global;var b="object"==typeof self&&self&&self.Object===Object&&self;const k=(p||b||Function("return this")()).Symbol;var v=Object.prototype,g=v.hasOwnProperty,m=v.toString,y=k?k.toStringTag:void 0;const w=function(t){var e=g.call(t,y),o=t[y];try{t[y]=void 0;var i=!0}catch(t){}var r=m.call(t);return i&&(e?t[y]=o:delete t[y]),r};var _=Object.prototype.toString;const T=function(t){return _.call(t)};var j=k?k.toStringTag:void 0;const S=function(t){return null==t?void 0===t?"[object Undefined]":"[object Null]":j&&j in Object(t)?w(t):T(t)};const x=function(t,e){return function(o){return t(e(o))}}(Object.getPrototypeOf,Object);var O=Function.prototype,E=Object.prototype,P=O.toString,C=E.hasOwnProperty,D=P.call(Object);const F=function(t){if(!f(t)||"[object Object]"!=S(t))return!1;var e=x(t);if(null===e)return!0;var o=C.call(e,"constructor")&&e.constructor;return"function"==typeof o&&o instanceof o&&P.call(o)==D};const M=function(t){return f(t)&&1===t.nodeType&&!F(t)};class R extends((0,u.DataApiMixin)((0,u.ElementApiMixin)(u.Editor))){constructor(t,e={}){if(!W(t)&&void 0!==e.initialData)throw new r.CKEditorError("editor-create-initial-data",null);super(e),void 0===this.config.get("initialData")&&this.config.set("initialData",function(t){return W(t)?(0,r.getDataFromElement)(t):t}(t)),W(t)&&(this.sourceElement=t),this.model.document.createRoot();const o=!this.config.get("toolbar.shouldNotGroupWhenFull"),i=new d(this.locale,this.editing.view,{shouldToolbarGroupWhenFull:o});this.ui=new n(this,i),(0,u.attachToForm)(this)}destroy(){return this.sourceElement&&this.updateSourceElement(),this.ui.destroy(),super.destroy()}static create(t,e={}){return new Promise((o=>{const i=new this(t,e);o(i.initPlugins().then((()=>i.ui.init(W(t)?t:null))).then((()=>i.data.init(i.config.get("initialData")))).then((()=>i.fire("ready"))).then((()=>i)))}))}}R.Context=u.Context,R.EditorWatchdog=h.EditorWatchdog,R.ContextWatchdog=h.ContextWatchdog;const N=R;function W(t){return M(t)}})(),(window.CKEditor5=window.CKEditor5||{}).editorClassic=i})();
|
4
|
+
*/(()=>{var t={662:(t,e,o)=>{"use strict";o.d(e,{A:()=>n});var i=o(935),r=o.n(i)()((function(t){return t[1]}));r.push([t.id,".ck.ck-editor{position:relative}.ck.ck-editor .ck-editor__top .ck-sticky-panel .ck-toolbar{z-index:var(--ck-z-panel)}.ck.ck-editor__top .ck-sticky-panel .ck-toolbar{border-radius:0}.ck-rounded-corners .ck.ck-editor__top .ck-sticky-panel .ck-toolbar,.ck.ck-editor__top .ck-sticky-panel .ck-toolbar.ck-rounded-corners{border-radius:var(--ck-border-radius);border-bottom-left-radius:0;border-bottom-right-radius:0}.ck.ck-editor__top .ck-sticky-panel .ck-toolbar{border-bottom-width:0}.ck.ck-editor__top .ck-sticky-panel .ck-sticky-panel__content_sticky .ck-toolbar{border-bottom-width:1px;border-radius:0}.ck-rounded-corners .ck.ck-editor__top .ck-sticky-panel .ck-sticky-panel__content_sticky .ck-toolbar,.ck.ck-editor__top .ck-sticky-panel .ck-sticky-panel__content_sticky .ck-toolbar.ck-rounded-corners{border-radius:var(--ck-border-radius);border-radius:0}.ck.ck-editor__main>.ck-editor__editable{background:var(--ck-color-base-background);border-radius:0}.ck-rounded-corners .ck.ck-editor__main>.ck-editor__editable,.ck.ck-editor__main>.ck-editor__editable.ck-rounded-corners{border-radius:var(--ck-border-radius);border-top-left-radius:0;border-top-right-radius:0}.ck.ck-editor__main>.ck-editor__editable:not(.ck-focused){border-color:var(--ck-color-base-border)}",""]);const n=r},935:t=>{"use strict";t.exports=function(t){var e=[];return e.toString=function(){return this.map((function(e){var o=t(e);return e[2]?"@media ".concat(e[2]," {").concat(o,"}"):o})).join("")},e.i=function(t,o,i){"string"==typeof t&&(t=[[null,t,""]]);var r={};if(i)for(var n=0;n<this.length;n++){var c=this[n][0];null!=c&&(r[c]=!0)}for(var a=0;a<t.length;a++){var s=[].concat(t[a]);i&&r[s[0]]||(o&&(s[2]?s[2]="".concat(o," and ").concat(s[2]):s[2]=o),e.push(s))}},e}},591:(t,e,o)=>{"use strict";var i,r=function(){return void 0===i&&(i=Boolean(window&&document&&document.all&&!window.atob)),i},n=function(){var t={};return function(e){if(void 0===t[e]){var o=document.querySelector(e);if(window.HTMLIFrameElement&&o instanceof window.HTMLIFrameElement)try{o=o.contentDocument.head}catch(t){o=null}t[e]=o}return t[e]}}(),c=[];function a(t){for(var e=-1,o=0;o<c.length;o++)if(c[o].identifier===t){e=o;break}return e}function s(t,e){for(var o={},i=[],r=0;r<t.length;r++){var n=t[r],s=e.base?n[0]+e.base:n[0],l=o[s]||0,d="".concat(s," ").concat(l);o[s]=l+1;var u=a(d),h={css:n[1],media:n[2],sourceMap:n[3]};-1!==u?(c[u].references++,c[u].updater(h)):c.push({identifier:d,updater:k(h,e),references:1}),i.push(d)}return i}function l(t){var e=document.createElement("style"),i=t.attributes||{};if(void 0===i.nonce){var r=o.nc;r&&(i.nonce=r)}if(Object.keys(i).forEach((function(t){e.setAttribute(t,i[t])})),"function"==typeof t.insert)t.insert(e);else{var c=n(t.insert||"head");if(!c)throw new Error("Couldn't find a style target. This probably means that the value for the 'insert' parameter is invalid.");c.appendChild(e)}return e}var d,u=(d=[],function(t,e){return d[t]=e,d.filter(Boolean).join("\n")});function h(t,e,o,i){var r=o?"":i.media?"@media ".concat(i.media," {").concat(i.css,"}"):i.css;if(t.styleSheet)t.styleSheet.cssText=u(e,r);else{var n=document.createTextNode(r),c=t.childNodes;c[e]&&t.removeChild(c[e]),c.length?t.insertBefore(n,c[e]):t.appendChild(n)}}function f(t,e,o){var i=o.css,r=o.media,n=o.sourceMap;if(r?t.setAttribute("media",r):t.removeAttribute("media"),n&&"undefined"!=typeof btoa&&(i+="\n/*# sourceMappingURL=data:application/json;base64,".concat(btoa(unescape(encodeURIComponent(JSON.stringify(n))))," */")),t.styleSheet)t.styleSheet.cssText=i;else{for(;t.firstChild;)t.removeChild(t.firstChild);t.appendChild(document.createTextNode(i))}}var p=null,b=0;function k(t,e){var o,i,r;if(e.singleton){var n=b++;o=p||(p=l(e)),i=h.bind(null,o,n,!1),r=h.bind(null,o,n,!0)}else o=l(e),i=f.bind(null,o,e),r=function(){!function(t){if(null===t.parentNode)return!1;t.parentNode.removeChild(t)}(o)};return i(t),function(e){if(e){if(e.css===t.css&&e.media===t.media&&e.sourceMap===t.sourceMap)return;i(t=e)}else r()}}t.exports=function(t,e){(e=e||{}).singleton||"boolean"==typeof e.singleton||(e.singleton=r());var o=s(t=t||[],e);return function(t){if(t=t||[],"[object Array]"===Object.prototype.toString.call(t)){for(var i=0;i<o.length;i++){var r=a(o[i]);c[r].references--}for(var n=s(t,e),l=0;l<o.length;l++){var d=a(o[l]);0===c[d].references&&(c[d].updater(),c.splice(d,1))}o=n}}}},782:(t,e,o)=>{t.exports=o(237)("./src/core.js")},783:(t,e,o)=>{t.exports=o(237)("./src/engine.js")},311:(t,e,o)=>{t.exports=o(237)("./src/ui.js")},584:(t,e,o)=>{t.exports=o(237)("./src/utils.js")},602:(t,e,o)=>{t.exports=o(237)("./src/watchdog.js")},237:t=>{"use strict";t.exports=CKEditor5.dll}},e={};function o(i){var r=e[i];if(void 0!==r)return r.exports;var n=e[i]={id:i,exports:{}};return t[i](n,n.exports,o),n.exports}o.n=t=>{var e=t&&t.__esModule?()=>t.default:()=>t;return o.d(e,{a:e}),e},o.d=(t,e)=>{for(var i in e)o.o(e,i)&&!o.o(t,i)&&Object.defineProperty(t,i,{enumerable:!0,get:e[i]})},o.o=(t,e)=>Object.prototype.hasOwnProperty.call(t,e),o.r=t=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},o.nc=void 0;var i={};(()=>{"use strict";o.r(i),o.d(i,{ClassicEditor:()=>A});var t=o(311),e=o(783),r=o(584);class n extends t.EditorUI{constructor(e,o){super(e),this.view=o,this._toolbarConfig=(0,t.normalizeToolbarConfig)(e.config.get("toolbar")),this._elementReplacer=new r.ElementReplacer,this.listenTo(e.editing.view,"scrollToTheSelection",this._handleScrollToTheSelectionWithStickyPanel.bind(this))}get element(){return this.view.element}init(t){const e=this.editor,o=this.view,i=e.editing.view,r=o.editable,n=i.document.getRoot();r.name=n.rootName,o.render();const c=r.element;this.setEditableElement(r.name,c),o.editable.bind("isFocused").to(this.focusTracker),i.attachDomRoot(c),t&&this._elementReplacer.replace(t,this.element),this._initPlaceholder(),this._initToolbar(),this._initDialogPluginIntegration(),this.fire("ready")}destroy(){super.destroy();const t=this.view,e=this.editor.editing.view;this._elementReplacer.restore(),e.detachDomRoot(t.editable.name),t.destroy()}_initToolbar(){const t=this.view;t.stickyPanel.bind("isActive").to(this.focusTracker,"isFocused"),t.stickyPanel.limiterElement=t.element,t.stickyPanel.bind("viewportTopOffset").to(this,"viewportOffset",(({top:t})=>t||0)),t.toolbar.fillFromConfig(this._toolbarConfig,this.componentFactory),this.addToolbar(t.toolbar)}_initPlaceholder(){const t=this.editor,o=t.editing.view,i=o.document.getRoot(),r=t.sourceElement;let n;const c=t.config.get("placeholder");c&&(n="string"==typeof c?c:c[this.view.editable.name]),!n&&r&&"textarea"===r.tagName.toLowerCase()&&(n=r.getAttribute("placeholder")),n&&(i.placeholder=n),(0,e.enablePlaceholder)({view:o,element:i,isDirectHost:!1,keepOnFocus:!0})}_handleScrollToTheSelectionWithStickyPanel(t,e,o){const i=this.view.stickyPanel;if(i.isSticky){const t=new r.Rect(i.element).height;e.viewportOffset.top+=t}else{const t=()=>{this.editor.editing.view.scrollToTheSelection(o)};this.listenTo(i,"change:isSticky",t),setTimeout((()=>{this.stopListening(i,"change:isSticky",t)}),20)}}_initDialogPluginIntegration(){if(!this.editor.plugins.has("Dialog"))return;const e=this.view.stickyPanel,o=this.editor.plugins.get("Dialog");o.on("show",(()=>{const i=o.view;i.on("moveTo",((o,n)=>{if(!e.isSticky||i.wasMoved)return;const c=new r.Rect(e.contentPanelElement);n[1]<c.bottom+t.DialogView.defaultOffset&&(n[1]=c.bottom+t.DialogView.defaultOffset)}),{priority:"high"})}),{priority:"low"})}}var c=o(591),a=o.n(c),s=o(662),l={injectType:"singletonStyleTag",attributes:{"data-cke":!0},insert:"head",singleton:!0};a()(s.A,l);s.A.locals;class d extends t.BoxedEditorUIView{constructor(e,o,i={}){super(e),this.stickyPanel=new t.StickyPanelView(e),this.toolbar=new t.ToolbarView(e,{shouldGroupWhenFull:i.shouldToolbarGroupWhenFull}),this.editable=new t.InlineEditableUIView(e,o)}render(){super.render(),this.stickyPanel.content.add(this.toolbar),this.top.add(this.stickyPanel),this.main.add(this.editable)}}var u=o(782),h=o(602);const f=function(t){return null!=t&&"object"==typeof t};const p="object"==typeof global&&global&&global.Object===Object&&global;var b="object"==typeof self&&self&&self.Object===Object&&self;const k=(p||b||Function("return this")()).Symbol;var v=Object.prototype,g=v.hasOwnProperty,m=v.toString,y=k?k.toStringTag:void 0;const w=function(t){var e=g.call(t,y),o=t[y];try{t[y]=void 0;var i=!0}catch(t){}var r=m.call(t);return i&&(e?t[y]=o:delete t[y]),r};var _=Object.prototype.toString;const T=function(t){return _.call(t)};var j=k?k.toStringTag:void 0;const S=function(t){return null==t?void 0===t?"[object Undefined]":"[object Null]":j&&j in Object(t)?w(t):T(t)};const O=function(t,e){return function(o){return t(e(o))}}(Object.getPrototypeOf,Object);var x=Function.prototype,E=Object.prototype,P=x.toString,C=E.hasOwnProperty,D=P.call(Object);const F=function(t){if(!f(t)||"[object Object]"!=S(t))return!1;var e=O(t);if(null===e)return!0;var o=C.call(e,"constructor")&&e.constructor;return"function"==typeof o&&o instanceof o&&P.call(o)==D};const R=function(t){return f(t)&&1===t.nodeType&&!F(t)};class M extends((0,u.ElementApiMixin)(u.Editor)){constructor(t,e={}){if(!N(t)&&void 0!==e.initialData)throw new r.CKEditorError("editor-create-initial-data",null);super(e),void 0===this.config.get("initialData")&&this.config.set("initialData",function(t){return N(t)?(0,r.getDataFromElement)(t):t}(t)),N(t)&&(this.sourceElement=t),this.model.document.createRoot();const o=!this.config.get("toolbar.shouldNotGroupWhenFull"),i=new d(this.locale,this.editing.view,{shouldToolbarGroupWhenFull:o});this.ui=new n(this,i),(0,u.attachToForm)(this)}destroy(){return this.sourceElement&&this.updateSourceElement(),this.ui.destroy(),super.destroy()}static create(t,e={}){return new Promise((o=>{const i=new this(t,e);o(i.initPlugins().then((()=>i.ui.init(N(t)?t:null))).then((()=>i.data.init(i.config.get("initialData")))).then((()=>i.fire("ready"))).then((()=>i)))}))}}M.Context=u.Context,M.EditorWatchdog=h.EditorWatchdog,M.ContextWatchdog=h.ContextWatchdog;const A=M;function N(t){return R(t)}})(),(window.CKEditor5=window.CKEditor5||{}).editorClassic=i})();
|
@@ -0,0 +1,10 @@
|
|
1
|
+
/**
|
2
|
+
* @license Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.
|
3
|
+
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
|
4
|
+
*/
|
5
|
+
.ck.ck-editor {
|
6
|
+
position: relative;
|
7
|
+
}
|
8
|
+
.ck.ck-editor .ck-editor__top .ck-sticky-panel .ck-toolbar {
|
9
|
+
z-index: var(--ck-z-panel);
|
10
|
+
}
|
package/dist/index.css
ADDED
@@ -0,0 +1,22 @@
|
|
1
|
+
/**
|
2
|
+
* @license Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.
|
3
|
+
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
|
4
|
+
*/
|
5
|
+
/*
|
6
|
+
* Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.
|
7
|
+
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
|
8
|
+
*/
|
9
|
+
|
10
|
+
.ck.ck-editor {
|
11
|
+
/* All the elements within `.ck-editor` are positioned relatively to it.
|
12
|
+
If any element needs to be positioned with respect to the <body>, etc.,
|
13
|
+
it must land outside of the `.ck-editor` in DOM. */
|
14
|
+
position: relative;
|
15
|
+
}
|
16
|
+
|
17
|
+
.ck.ck-editor .ck-editor__top .ck-sticky-panel .ck-toolbar {
|
18
|
+
/* https://github.com/ckeditor/ckeditor5-editor-classic/issues/62 */
|
19
|
+
z-index: var(--ck-z-panel);
|
20
|
+
}
|
21
|
+
|
22
|
+
/*# sourceMappingURL=index.css.map */
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"sources":["../theme/classiceditor.css","index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A,EAAA,CAAA,MAAA,CAAA,KAAA,CAAA,CAAA,EAAA,CAAA,OAAA,CAAA,CAAA;ACED,CAAC,CDDC,CAAA,CAAA,CAAA,KAAA,CAAA,CAAA,CAAA,MAAA,CAAA,GAAA,CAAA,QAAA,CAAA,SAAA,CAAA,MAAA,CAAA,OAAA,CAAA,MAAA,CAAA,EAAA,CAAA,CAAmE,CAAA;ACErE,CAAC,CDDC,CAAA,CAAA,KAAA,CAAA,CAAA,GAAA,CAAA,CAAA,CAAA,EAAA,CAAA,CAAA,CAAA,KAAA,CAA0B,CAAA;ACE5B,CDDC,CAAA;ACED;AACA,CAAC,CAAC,CAAC,CAAC,gBAAgB,CAAC,KAAK,CAAC,GAAG,CAAC,GAAG,CAAC,CAAC","file":"index.css.map","sourcesContent":["/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n.ck.ck-editor {\n\t/* All the elements within `.ck-editor` are positioned relatively to it.\n\t If any element needs to be positioned with respect to the <body>, etc.,\n\t it must land outside of the `.ck-editor` in DOM. */\n\tposition: relative;\n\n\t& .ck-editor__top .ck-sticky-panel .ck-toolbar {\n\t\t/* https://github.com/ckeditor/ckeditor5-editor-classic/issues/62 */\n\t\tz-index: var(--ck-z-panel);\n\t}\n}\n","/*\n * Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n.ck.ck-editor {\n\t/* All the elements within `.ck-editor` are positioned relatively to it.\n\t If any element needs to be positioned with respect to the <body>, etc.,\n\t it must land outside of the `.ck-editor` in DOM. */\n\tposition: relative;\n}\n\n.ck.ck-editor .ck-editor__top .ck-sticky-panel .ck-toolbar {\n\t\t/* https://github.com/ckeditor/ckeditor5-editor-classic/issues/62 */\n\t\tz-index: var(--ck-z-panel);\n\t}\n\n/*# sourceMappingURL=index.css.map */"]}
|
package/dist/index.js
ADDED
@@ -0,0 +1,446 @@
|
|
1
|
+
/**
|
2
|
+
* @license Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.
|
3
|
+
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
|
4
|
+
*/
|
5
|
+
import { EditorUI, normalizeToolbarConfig, DialogView, BoxedEditorUIView, StickyPanelView, ToolbarView, InlineEditableUIView } from '@ckeditor/ckeditor5-ui/dist/index.js';
|
6
|
+
import { enablePlaceholder } from '@ckeditor/ckeditor5-engine/dist/index.js';
|
7
|
+
import { ElementReplacer, Rect, CKEditorError, getDataFromElement } from '@ckeditor/ckeditor5-utils/dist/index.js';
|
8
|
+
import { ElementApiMixin, Editor, attachToForm, Context } from '@ckeditor/ckeditor5-core/dist/index.js';
|
9
|
+
import { EditorWatchdog, ContextWatchdog } from '@ckeditor/ckeditor5-watchdog/dist/index.js';
|
10
|
+
import { isElement as isElement$1 } from 'lodash-es';
|
11
|
+
|
12
|
+
/**
|
13
|
+
* @license Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.
|
14
|
+
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
|
15
|
+
*/
|
16
|
+
/**
|
17
|
+
* The classic editor UI class.
|
18
|
+
*/
|
19
|
+
class ClassicEditorUI extends EditorUI {
|
20
|
+
/**
|
21
|
+
* Creates an instance of the classic editor UI class.
|
22
|
+
*
|
23
|
+
* @param editor The editor instance.
|
24
|
+
* @param view The view of the UI.
|
25
|
+
*/
|
26
|
+
constructor(editor, view) {
|
27
|
+
super(editor);
|
28
|
+
this.view = view;
|
29
|
+
this._toolbarConfig = normalizeToolbarConfig(editor.config.get('toolbar'));
|
30
|
+
this._elementReplacer = new ElementReplacer();
|
31
|
+
this.listenTo(editor.editing.view, 'scrollToTheSelection', this._handleScrollToTheSelectionWithStickyPanel.bind(this));
|
32
|
+
}
|
33
|
+
/**
|
34
|
+
* @inheritDoc
|
35
|
+
*/
|
36
|
+
get element() {
|
37
|
+
return this.view.element;
|
38
|
+
}
|
39
|
+
/**
|
40
|
+
* Initializes the UI.
|
41
|
+
*
|
42
|
+
* @param replacementElement The DOM element that will be the source for the created editor.
|
43
|
+
*/
|
44
|
+
init(replacementElement) {
|
45
|
+
const editor = this.editor;
|
46
|
+
const view = this.view;
|
47
|
+
const editingView = editor.editing.view;
|
48
|
+
const editable = view.editable;
|
49
|
+
const editingRoot = editingView.document.getRoot();
|
50
|
+
// The editable UI and editing root should share the same name. Then name is used
|
51
|
+
// to recognize the particular editable, for instance in ARIA attributes.
|
52
|
+
editable.name = editingRoot.rootName;
|
53
|
+
view.render();
|
54
|
+
// The editable UI element in DOM is available for sure only after the editor UI view has been rendered.
|
55
|
+
// But it can be available earlier if a DOM element has been passed to BalloonEditor.create().
|
56
|
+
const editableElement = editable.element;
|
57
|
+
// Register the editable UI view in the editor. A single editor instance can aggregate multiple
|
58
|
+
// editable areas (roots) but the classic editor has only one.
|
59
|
+
this.setEditableElement(editable.name, editableElement);
|
60
|
+
// Let the editable UI element respond to the changes in the global editor focus
|
61
|
+
// tracker. It has been added to the same tracker a few lines above but, in reality, there are
|
62
|
+
// many focusable areas in the editor, like balloons, toolbars or dropdowns and as long
|
63
|
+
// as they have focus, the editable should act like it is focused too (although technically
|
64
|
+
// it isn't), e.g. by setting the proper CSS class, visually announcing focus to the user.
|
65
|
+
// Doing otherwise will result in editable focus styles disappearing, once e.g. the
|
66
|
+
// toolbar gets focused.
|
67
|
+
view.editable.bind('isFocused').to(this.focusTracker);
|
68
|
+
// Bind the editable UI element to the editing view, making it an end– and entry–point
|
69
|
+
// of the editor's engine. This is where the engine meets the UI.
|
70
|
+
editingView.attachDomRoot(editableElement);
|
71
|
+
// If an element containing the initial data of the editor was provided, replace it with
|
72
|
+
// an editor instance's UI in DOM until the editor is destroyed. For instance, a <textarea>
|
73
|
+
// can be such element.
|
74
|
+
if (replacementElement) {
|
75
|
+
this._elementReplacer.replace(replacementElement, this.element);
|
76
|
+
}
|
77
|
+
this._initPlaceholder();
|
78
|
+
this._initToolbar();
|
79
|
+
this._initDialogPluginIntegration();
|
80
|
+
this.fire('ready');
|
81
|
+
}
|
82
|
+
/**
|
83
|
+
* @inheritDoc
|
84
|
+
*/
|
85
|
+
destroy() {
|
86
|
+
super.destroy();
|
87
|
+
const view = this.view;
|
88
|
+
const editingView = this.editor.editing.view;
|
89
|
+
this._elementReplacer.restore();
|
90
|
+
editingView.detachDomRoot(view.editable.name);
|
91
|
+
view.destroy();
|
92
|
+
}
|
93
|
+
/**
|
94
|
+
* Initializes the editor toolbar.
|
95
|
+
*/
|
96
|
+
_initToolbar() {
|
97
|
+
const view = this.view;
|
98
|
+
// Set–up the sticky panel with toolbar.
|
99
|
+
view.stickyPanel.bind('isActive').to(this.focusTracker, 'isFocused');
|
100
|
+
view.stickyPanel.limiterElement = view.element;
|
101
|
+
view.stickyPanel.bind('viewportTopOffset').to(this, 'viewportOffset', ({ top }) => top || 0);
|
102
|
+
view.toolbar.fillFromConfig(this._toolbarConfig, this.componentFactory);
|
103
|
+
// Register the toolbar so it becomes available for Alt+F10 and Esc navigation.
|
104
|
+
this.addToolbar(view.toolbar);
|
105
|
+
}
|
106
|
+
/**
|
107
|
+
* Enable the placeholder text on the editing root.
|
108
|
+
*/
|
109
|
+
_initPlaceholder() {
|
110
|
+
const editor = this.editor;
|
111
|
+
const editingView = editor.editing.view;
|
112
|
+
const editingRoot = editingView.document.getRoot();
|
113
|
+
const sourceElement = editor.sourceElement;
|
114
|
+
let placeholderText;
|
115
|
+
const placeholder = editor.config.get('placeholder');
|
116
|
+
if (placeholder) {
|
117
|
+
placeholderText = typeof placeholder === 'string' ? placeholder : placeholder[this.view.editable.name];
|
118
|
+
}
|
119
|
+
if (!placeholderText && sourceElement && sourceElement.tagName.toLowerCase() === 'textarea') {
|
120
|
+
placeholderText = sourceElement.getAttribute('placeholder');
|
121
|
+
}
|
122
|
+
if (placeholderText) {
|
123
|
+
editingRoot.placeholder = placeholderText;
|
124
|
+
}
|
125
|
+
enablePlaceholder({
|
126
|
+
view: editingView,
|
127
|
+
element: editingRoot,
|
128
|
+
isDirectHost: false,
|
129
|
+
keepOnFocus: true
|
130
|
+
});
|
131
|
+
}
|
132
|
+
/**
|
133
|
+
* Provides an integration between the sticky toolbar and {@link module:utils/dom/scroll~scrollViewportToShowTarget}.
|
134
|
+
* It allows the UI-agnostic engine method to consider the geometry of the
|
135
|
+
* {@link module:editor-classic/classiceditoruiview~ClassicEditorUIView#stickyPanel} that pins to the
|
136
|
+
* edge of the viewport and can obscure the user caret after scrolling the window.
|
137
|
+
*
|
138
|
+
* @param evt The `scrollToTheSelection` event info.
|
139
|
+
* @param data The payload carried by the `scrollToTheSelection` event.
|
140
|
+
* @param originalArgs The original arguments passed to `scrollViewportToShowTarget()` method (see implementation to learn more).
|
141
|
+
*/
|
142
|
+
_handleScrollToTheSelectionWithStickyPanel(evt, data, originalArgs) {
|
143
|
+
const stickyPanel = this.view.stickyPanel;
|
144
|
+
if (stickyPanel.isSticky) {
|
145
|
+
const stickyPanelHeight = new Rect(stickyPanel.element).height;
|
146
|
+
data.viewportOffset.top += stickyPanelHeight;
|
147
|
+
}
|
148
|
+
else {
|
149
|
+
const scrollViewportOnPanelGettingSticky = () => {
|
150
|
+
this.editor.editing.view.scrollToTheSelection(originalArgs);
|
151
|
+
};
|
152
|
+
this.listenTo(stickyPanel, 'change:isSticky', scrollViewportOnPanelGettingSticky);
|
153
|
+
// This works as a post-scroll-fixer because it's impossible predict whether the panel will be sticky after scrolling or not.
|
154
|
+
// Listen for a short period of time only and if the toolbar does not become sticky very soon, cancel the listener.
|
155
|
+
setTimeout(() => {
|
156
|
+
this.stopListening(stickyPanel, 'change:isSticky', scrollViewportOnPanelGettingSticky);
|
157
|
+
}, 20);
|
158
|
+
}
|
159
|
+
}
|
160
|
+
/**
|
161
|
+
* Provides an integration between the sticky toolbar and {@link module:ui/dialog/dialog the Dialog plugin}.
|
162
|
+
*
|
163
|
+
* It moves the dialog down to ensure that the
|
164
|
+
* {@link module:editor-classic/classiceditoruiview~ClassicEditorUIView#stickyPanel sticky panel}
|
165
|
+
* used by the editor UI will not get obscured by the dialog when the dialog uses one of its automatic positions.
|
166
|
+
*/
|
167
|
+
_initDialogPluginIntegration() {
|
168
|
+
if (!this.editor.plugins.has('Dialog')) {
|
169
|
+
return;
|
170
|
+
}
|
171
|
+
const stickyPanel = this.view.stickyPanel;
|
172
|
+
const dialogPlugin = this.editor.plugins.get('Dialog');
|
173
|
+
dialogPlugin.on('show', () => {
|
174
|
+
const dialogView = dialogPlugin.view;
|
175
|
+
dialogView.on('moveTo', (evt, data) => {
|
176
|
+
// Engage only when the panel is sticky, and the dialog is using one of default positions.
|
177
|
+
if (!stickyPanel.isSticky || dialogView.wasMoved) {
|
178
|
+
return;
|
179
|
+
}
|
180
|
+
const stickyPanelContentRect = new Rect(stickyPanel.contentPanelElement);
|
181
|
+
if (data[1] < stickyPanelContentRect.bottom + DialogView.defaultOffset) {
|
182
|
+
data[1] = stickyPanelContentRect.bottom + DialogView.defaultOffset;
|
183
|
+
}
|
184
|
+
}, { priority: 'high' });
|
185
|
+
}, { priority: 'low' });
|
186
|
+
}
|
187
|
+
}
|
188
|
+
|
189
|
+
/**
|
190
|
+
* @license Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.
|
191
|
+
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
|
192
|
+
*/
|
193
|
+
/**
|
194
|
+
* @module editor-classic/classiceditoruiview
|
195
|
+
*/
|
196
|
+
/**
|
197
|
+
* Classic editor UI view. Uses an inline editable and a sticky toolbar, all
|
198
|
+
* enclosed in a boxed UI view.
|
199
|
+
*/
|
200
|
+
class ClassicEditorUIView extends BoxedEditorUIView {
|
201
|
+
/**
|
202
|
+
* Creates an instance of the classic editor UI view.
|
203
|
+
*
|
204
|
+
* @param locale The {@link module:core/editor/editor~Editor#locale} instance.
|
205
|
+
* @param editingView The editing view instance this view is related to.
|
206
|
+
* @param options Configuration options for the view instance.
|
207
|
+
* @param options.shouldToolbarGroupWhenFull When set `true` enables automatic items grouping
|
208
|
+
* in the main {@link module:editor-classic/classiceditoruiview~ClassicEditorUIView#toolbar toolbar}.
|
209
|
+
* See {@link module:ui/toolbar/toolbarview~ToolbarOptions#shouldGroupWhenFull} to learn more.
|
210
|
+
*/
|
211
|
+
constructor(locale, editingView, options = {}) {
|
212
|
+
super(locale);
|
213
|
+
this.stickyPanel = new StickyPanelView(locale);
|
214
|
+
this.toolbar = new ToolbarView(locale, {
|
215
|
+
shouldGroupWhenFull: options.shouldToolbarGroupWhenFull
|
216
|
+
});
|
217
|
+
this.editable = new InlineEditableUIView(locale, editingView);
|
218
|
+
}
|
219
|
+
/**
|
220
|
+
* @inheritDoc
|
221
|
+
*/
|
222
|
+
render() {
|
223
|
+
super.render();
|
224
|
+
// Set toolbar as a child of a stickyPanel and makes toolbar sticky.
|
225
|
+
this.stickyPanel.content.add(this.toolbar);
|
226
|
+
this.top.add(this.stickyPanel);
|
227
|
+
this.main.add(this.editable);
|
228
|
+
}
|
229
|
+
}
|
230
|
+
|
231
|
+
/**
|
232
|
+
* @license Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.
|
233
|
+
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
|
234
|
+
*/
|
235
|
+
/**
|
236
|
+
* @module editor-classic/classiceditor
|
237
|
+
*/
|
238
|
+
/**
|
239
|
+
* The {@glink installation/getting-started/predefined-builds#classic-editor classic editor} implementation.
|
240
|
+
* It uses an inline editable and a sticky toolbar, all enclosed in a boxed UI.
|
241
|
+
* See the {@glink examples/builds/classic-editor demo}.
|
242
|
+
*
|
243
|
+
* In order to create a classic editor instance, use the static
|
244
|
+
* {@link module:editor-classic/classiceditor~ClassicEditor.create `ClassicEditor.create()`} method.
|
245
|
+
*
|
246
|
+
* # Classic editor and classic build
|
247
|
+
*
|
248
|
+
* The classic editor can be used directly from source (if you installed the
|
249
|
+
* [`@ckeditor/ckeditor5-editor-classic/dist/index.js`](https://www.npmjs.com/package/@ckeditor/ckeditor5-editor-classic/dist/index.js) package)
|
250
|
+
* but it is also available in the {@glink installation/getting-started/predefined-builds#classic-editor classic build}.
|
251
|
+
*
|
252
|
+
* {@glink installation/getting-started/predefined-builds Builds}
|
253
|
+
* are ready-to-use editors with plugins bundled in. When using the editor from
|
254
|
+
* source you need to take care of loading all plugins by yourself
|
255
|
+
* (through the {@link module:core/editor/editorconfig~EditorConfig#plugins `config.plugins`} option).
|
256
|
+
* Using the editor from source gives much better flexibility and allows easier customization.
|
257
|
+
*
|
258
|
+
* Read more about initializing the editor from source or as a build in
|
259
|
+
* {@link module:editor-classic/classiceditor~ClassicEditor.create `ClassicEditor.create()`}.
|
260
|
+
*/
|
261
|
+
class ClassicEditor extends ElementApiMixin(Editor) {
|
262
|
+
/**
|
263
|
+
* Creates an instance of the classic editor.
|
264
|
+
*
|
265
|
+
* **Note:** do not use the constructor to create editor instances. Use the static
|
266
|
+
* {@link module:editor-classic/classiceditor~ClassicEditor.create `ClassicEditor.create()`} method instead.
|
267
|
+
*
|
268
|
+
* @param sourceElementOrData The DOM element that will be the source for the created editor
|
269
|
+
* or the editor's initial data. For more information see
|
270
|
+
* {@link module:editor-classic/classiceditor~ClassicEditor.create `ClassicEditor.create()`}.
|
271
|
+
* @param config The editor configuration.
|
272
|
+
*/
|
273
|
+
constructor(sourceElementOrData, config = {}) {
|
274
|
+
// If both `config.initialData` is set and initial data is passed as the constructor parameter, then throw.
|
275
|
+
if (!isElement(sourceElementOrData) && config.initialData !== undefined) {
|
276
|
+
// Documented in core/editor/editorconfig.jsdoc.
|
277
|
+
// eslint-disable-next-line ckeditor5-rules/ckeditor-error-message
|
278
|
+
throw new CKEditorError('editor-create-initial-data', null);
|
279
|
+
}
|
280
|
+
super(config);
|
281
|
+
if (this.config.get('initialData') === undefined) {
|
282
|
+
this.config.set('initialData', getInitialData(sourceElementOrData));
|
283
|
+
}
|
284
|
+
if (isElement(sourceElementOrData)) {
|
285
|
+
this.sourceElement = sourceElementOrData;
|
286
|
+
}
|
287
|
+
this.model.document.createRoot();
|
288
|
+
const shouldToolbarGroupWhenFull = !this.config.get('toolbar.shouldNotGroupWhenFull');
|
289
|
+
const view = new ClassicEditorUIView(this.locale, this.editing.view, {
|
290
|
+
shouldToolbarGroupWhenFull
|
291
|
+
});
|
292
|
+
this.ui = new ClassicEditorUI(this, view);
|
293
|
+
attachToForm(this);
|
294
|
+
}
|
295
|
+
/**
|
296
|
+
* Destroys the editor instance, releasing all resources used by it.
|
297
|
+
*
|
298
|
+
* Updates the original editor element with the data if the
|
299
|
+
* {@link module:core/editor/editorconfig~EditorConfig#updateSourceElementOnDestroy `updateSourceElementOnDestroy`}
|
300
|
+
* configuration option is set to `true`.
|
301
|
+
*/
|
302
|
+
destroy() {
|
303
|
+
if (this.sourceElement) {
|
304
|
+
this.updateSourceElement();
|
305
|
+
}
|
306
|
+
this.ui.destroy();
|
307
|
+
return super.destroy();
|
308
|
+
}
|
309
|
+
/**
|
310
|
+
* Creates a new classic editor instance.
|
311
|
+
*
|
312
|
+
* There are three ways how the editor can be initialized.
|
313
|
+
*
|
314
|
+
* # Replacing a DOM element (and loading data from it)
|
315
|
+
*
|
316
|
+
* You can initialize the editor using an existing DOM element:
|
317
|
+
*
|
318
|
+
* ```ts
|
319
|
+
* ClassicEditor
|
320
|
+
* .create( document.querySelector( '#editor' ) )
|
321
|
+
* .then( editor => {
|
322
|
+
* console.log( 'Editor was initialized', editor );
|
323
|
+
* } )
|
324
|
+
* .catch( err => {
|
325
|
+
* console.error( err.stack );
|
326
|
+
* } );
|
327
|
+
* ```
|
328
|
+
*
|
329
|
+
* The element's content will be used as the editor data and the element will be replaced by the editor UI.
|
330
|
+
*
|
331
|
+
* # Creating a detached editor
|
332
|
+
*
|
333
|
+
* Alternatively, you can initialize the editor by passing the initial data directly as a string.
|
334
|
+
* In this case, the editor will render an element that must be inserted into the DOM:
|
335
|
+
*
|
336
|
+
* ```ts
|
337
|
+
* ClassicEditor
|
338
|
+
* .create( '<p>Hello world!</p>' )
|
339
|
+
* .then( editor => {
|
340
|
+
* console.log( 'Editor was initialized', editor );
|
341
|
+
*
|
342
|
+
* // Initial data was provided so the editor UI element needs to be added manually to the DOM.
|
343
|
+
* document.body.appendChild( editor.ui.element );
|
344
|
+
* } )
|
345
|
+
* .catch( err => {
|
346
|
+
* console.error( err.stack );
|
347
|
+
* } );
|
348
|
+
* ```
|
349
|
+
*
|
350
|
+
* This lets you dynamically append the editor to your web page whenever it is convenient for you. You may use this method if your
|
351
|
+
* web page content is generated on the client side and the DOM structure is not ready at the moment when you initialize the editor.
|
352
|
+
*
|
353
|
+
* # Replacing a DOM element (and data provided in `config.initialData`)
|
354
|
+
*
|
355
|
+
* You can also mix these two ways by providing a DOM element to be used and passing the initial data through the configuration:
|
356
|
+
*
|
357
|
+
* ```ts
|
358
|
+
* ClassicEditor
|
359
|
+
* .create( document.querySelector( '#editor' ), {
|
360
|
+
* initialData: '<h2>Initial data</h2><p>Foo bar.</p>'
|
361
|
+
* } )
|
362
|
+
* .then( editor => {
|
363
|
+
* console.log( 'Editor was initialized', editor );
|
364
|
+
* } )
|
365
|
+
* .catch( err => {
|
366
|
+
* console.error( err.stack );
|
367
|
+
* } );
|
368
|
+
* ```
|
369
|
+
*
|
370
|
+
* This method can be used to initialize the editor on an existing element with the specified content in case if your integration
|
371
|
+
* makes it difficult to set the content of the source element.
|
372
|
+
*
|
373
|
+
* Note that an error will be thrown if you pass the initial data both as the first parameter and also in the configuration.
|
374
|
+
*
|
375
|
+
* # Configuring the editor
|
376
|
+
*
|
377
|
+
* See the {@link module:core/editor/editorconfig~EditorConfig editor configuration documentation} to learn more about
|
378
|
+
* customizing plugins, toolbar and more.
|
379
|
+
*
|
380
|
+
* # Using the editor from source
|
381
|
+
*
|
382
|
+
* The code samples listed in the previous sections of this documentation assume that you are using an
|
383
|
+
* {@glink installation/getting-started/predefined-builds editor build} (for example – `@ckeditor/ckeditor5-build-classic/dist/index.js`).
|
384
|
+
*
|
385
|
+
* If you want to use the classic editor from source (`@ckeditor/ckeditor5-editor-classic/dist/index.js`),
|
386
|
+
* you need to define the list of
|
387
|
+
* {@link module:core/editor/editorconfig~EditorConfig#plugins plugins to be initialized} and
|
388
|
+
* {@link module:core/editor/editorconfig~EditorConfig#toolbar toolbar items}. Read more about using the editor from
|
389
|
+
* source in the {@glink installation/advanced/alternative-setups/integrating-from-source-webpack dedicated guide}.
|
390
|
+
*
|
391
|
+
* @param sourceElementOrData The DOM element that will be the source for the created editor
|
392
|
+
* or the editor's initial data.
|
393
|
+
*
|
394
|
+
* If a DOM element is passed, its content will be automatically loaded to the editor upon initialization
|
395
|
+
* and the {@link module:editor-classic/classiceditorui~ClassicEditorUI#element editor element} will replace the passed element
|
396
|
+
* in the DOM (the original one will be hidden and the editor will be injected next to it).
|
397
|
+
*
|
398
|
+
* If the {@link module:core/editor/editorconfig~EditorConfig#updateSourceElementOnDestroy updateSourceElementOnDestroy}
|
399
|
+
* option is set to `true`, the editor data will be set back to the original element once the editor is destroyed and when a form,
|
400
|
+
* in which this element is contained, is submitted (if the original element is a `<textarea>`). This ensures seamless integration
|
401
|
+
* with native web forms.
|
402
|
+
*
|
403
|
+
* If the initial data is passed, a detached editor will be created. In this case you need to insert it into the DOM manually.
|
404
|
+
* It is available under the {@link module:editor-classic/classiceditorui~ClassicEditorUI#element `editor.ui.element`} property.
|
405
|
+
*
|
406
|
+
* @param config The editor configuration.
|
407
|
+
* @returns A promise resolved once the editor is ready. The promise resolves with the created editor instance.
|
408
|
+
*/
|
409
|
+
static create(sourceElementOrData, config = {}) {
|
410
|
+
return new Promise(resolve => {
|
411
|
+
const editor = new this(sourceElementOrData, config);
|
412
|
+
resolve(editor.initPlugins()
|
413
|
+
.then(() => editor.ui.init(isElement(sourceElementOrData) ? sourceElementOrData : null))
|
414
|
+
.then(() => editor.data.init(editor.config.get('initialData')))
|
415
|
+
.then(() => editor.fire('ready'))
|
416
|
+
.then(() => editor));
|
417
|
+
});
|
418
|
+
}
|
419
|
+
}
|
420
|
+
/**
|
421
|
+
* The {@link module:core/context~Context} class.
|
422
|
+
*
|
423
|
+
* Exposed as static editor field for easier access in editor builds.
|
424
|
+
*/
|
425
|
+
ClassicEditor.Context = Context;
|
426
|
+
/**
|
427
|
+
* The {@link module:watchdog/editorwatchdog~EditorWatchdog} class.
|
428
|
+
*
|
429
|
+
* Exposed as static editor field for easier access in editor builds.
|
430
|
+
*/
|
431
|
+
ClassicEditor.EditorWatchdog = EditorWatchdog;
|
432
|
+
/**
|
433
|
+
* The {@link module:watchdog/contextwatchdog~ContextWatchdog} class.
|
434
|
+
*
|
435
|
+
* Exposed as static editor field for easier access in editor builds.
|
436
|
+
*/
|
437
|
+
ClassicEditor.ContextWatchdog = ContextWatchdog;
|
438
|
+
function getInitialData(sourceElementOrData) {
|
439
|
+
return isElement(sourceElementOrData) ? getDataFromElement(sourceElementOrData) : sourceElementOrData;
|
440
|
+
}
|
441
|
+
function isElement(value) {
|
442
|
+
return isElement$1(value);
|
443
|
+
}
|
444
|
+
|
445
|
+
export { ClassicEditor };
|
446
|
+
//# sourceMappingURL=index.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"sources":["index.js","../src/classiceditorui.ts","../src/classiceditoruiview.ts","../src/classiceditor.ts"],"names":["_isElement"],"mappings":";;;;AAAA,MAAM,CAAC,CAAC,CAAC,QAAQ,CAAC,CAAC,sBAAsB,CAAC,CAAC,UAAU,CAAC,CAAC,iBAAiB,CAAC,CAAC,eAAe,CAAC,CAAC,WAAW,CAAC,CAAC,oBAAoB,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,QAAQ,CAAC,SAAS,CAAC,EAAE,CAAC,IAAI,CAAC,KAAK,CAAC,EAAE,CAAC,CAAC;AAC3K,MAAM,CAAC,CAAC,CAAC,iBAAiB,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC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,CAAC,EAAE,CAAC,MAAM,CAAC,MAAM,CAAC,KAAK,CAAC,GAAG,CAAC,MAAM,CAAC,MAAM,CAAC,EAAE,CAAC,MAAM,CAAC,MAAM,CAAC;AG1LjE,CAAA,CAAA,CAAA;AACW,aAAc,CAAA,cAAA,CAAG,CAAA,CAAA,cAAc,CAAC;AAE9C,CAAA,CAAA,CAAA;AH2LD,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,IAAI,CAAC,MAAM,CAAC,QAAQ,CAAC,eAAe,CAAC,eAAe,CAAC,CAAC,KAAK,CAAC;AACrE,CAAC,CAAC;AACF,CAAC,CAAC,CAAC,OAAO,CAAC,EAAE,CAAC,MAAM,CAAC,MAAM,CAAC,KAAK,CAAC,GAAG,CAAC,MAAM,CAAC,MAAM,CAAC,EAAE,CAAC,MAAM,CAAC,MAAM,CAAC;AGzLjE,CAAA,CAAA,CAAA;AACW,aAAe,CAAA,eAAA,CAAG,CAAA,CAAA,eAAe,CAAC;AAGjD,QAAS,CAAA,cAAc,CAAE,mBAAyC,CAAA,CAAA,CAAA;AACjE,CAAA,CAAA,CAAA,CAAA,MAAO,CAAA,SAAS,CAAE,mBAAmB,CAAE,CAAA,CAAA,CAAG,kBAAkB,CAAE,mBAAmB,CAAE,CAAG,CAAA,CAAA,mBAAmB,CAAC;AAC3G,CAAC;AAED,QAAS,CAAA,SAAS,CAAE,KAAU,CAAA,CAAA,CAAA;AAC7B,CAAA,CAAA,CAAA,CAAA,MAAOA,CAAAA,SAAAA,CAAAA,CAAU,CAAE,KAAK,CAAE,CAAC;AAC5B,CAAA;AHwLA;AACA,MAAM,CAAC,CAAC,CAAC,aAAa,CAAC,CAAC,CAAC;AACzB,CAAC,CAAC,CAAC,CAAC,gBAAgB,CAAC,KAAK,CAAC,EAAE,CAAC,GAAG","file":"index.js.map","sourcesContent":["import { EditorUI, normalizeToolbarConfig, DialogView, BoxedEditorUIView, StickyPanelView, ToolbarView, InlineEditableUIView } from '@ckeditor/ckeditor5-ui/dist/index.js';\nimport { enablePlaceholder } from '@ckeditor/ckeditor5-engine/dist/index.js';\nimport { ElementReplacer, Rect, CKEditorError, getDataFromElement } from '@ckeditor/ckeditor5-utils/dist/index.js';\nimport { ElementApiMixin, Editor, attachToForm, Context } from '@ckeditor/ckeditor5-core/dist/index.js';\nimport { EditorWatchdog, ContextWatchdog } from '@ckeditor/ckeditor5-watchdog/dist/index.js';\nimport { isElement as isElement$1 } from 'lodash-es';\n\n/**\n * @license Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n/**\n * The classic editor UI class.\n */\nclass ClassicEditorUI extends EditorUI {\n /**\n * Creates an instance of the classic editor UI class.\n *\n * @param editor The editor instance.\n * @param view The view of the UI.\n */\n constructor(editor, view) {\n super(editor);\n this.view = view;\n this._toolbarConfig = normalizeToolbarConfig(editor.config.get('toolbar'));\n this._elementReplacer = new ElementReplacer();\n this.listenTo(editor.editing.view, 'scrollToTheSelection', this._handleScrollToTheSelectionWithStickyPanel.bind(this));\n }\n /**\n * @inheritDoc\n */\n get element() {\n return this.view.element;\n }\n /**\n * Initializes the UI.\n *\n * @param replacementElement The DOM element that will be the source for the created editor.\n */\n init(replacementElement) {\n const editor = this.editor;\n const view = this.view;\n const editingView = editor.editing.view;\n const editable = view.editable;\n const editingRoot = editingView.document.getRoot();\n // The editable UI and editing root should share the same name. Then name is used\n // to recognize the particular editable, for instance in ARIA attributes.\n editable.name = editingRoot.rootName;\n view.render();\n // The editable UI element in DOM is available for sure only after the editor UI view has been rendered.\n // But it can be available earlier if a DOM element has been passed to BalloonEditor.create().\n const editableElement = editable.element;\n // Register the editable UI view in the editor. A single editor instance can aggregate multiple\n // editable areas (roots) but the classic editor has only one.\n this.setEditableElement(editable.name, editableElement);\n // Let the editable UI element respond to the changes in the global editor focus\n // tracker. It has been added to the same tracker a few lines above but, in reality, there are\n // many focusable areas in the editor, like balloons, toolbars or dropdowns and as long\n // as they have focus, the editable should act like it is focused too (although technically\n // it isn't), e.g. by setting the proper CSS class, visually announcing focus to the user.\n // Doing otherwise will result in editable focus styles disappearing, once e.g. the\n // toolbar gets focused.\n view.editable.bind('isFocused').to(this.focusTracker);\n // Bind the editable UI element to the editing view, making it an end– and entry–point\n // of the editor's engine. This is where the engine meets the UI.\n editingView.attachDomRoot(editableElement);\n // If an element containing the initial data of the editor was provided, replace it with\n // an editor instance's UI in DOM until the editor is destroyed. For instance, a <textarea>\n // can be such element.\n if (replacementElement) {\n this._elementReplacer.replace(replacementElement, this.element);\n }\n this._initPlaceholder();\n this._initToolbar();\n this._initDialogPluginIntegration();\n this.fire('ready');\n }\n /**\n * @inheritDoc\n */\n destroy() {\n super.destroy();\n const view = this.view;\n const editingView = this.editor.editing.view;\n this._elementReplacer.restore();\n editingView.detachDomRoot(view.editable.name);\n view.destroy();\n }\n /**\n * Initializes the editor toolbar.\n */\n _initToolbar() {\n const view = this.view;\n // Set–up the sticky panel with toolbar.\n view.stickyPanel.bind('isActive').to(this.focusTracker, 'isFocused');\n view.stickyPanel.limiterElement = view.element;\n view.stickyPanel.bind('viewportTopOffset').to(this, 'viewportOffset', ({ top }) => top || 0);\n view.toolbar.fillFromConfig(this._toolbarConfig, this.componentFactory);\n // Register the toolbar so it becomes available for Alt+F10 and Esc navigation.\n this.addToolbar(view.toolbar);\n }\n /**\n * Enable the placeholder text on the editing root.\n */\n _initPlaceholder() {\n const editor = this.editor;\n const editingView = editor.editing.view;\n const editingRoot = editingView.document.getRoot();\n const sourceElement = editor.sourceElement;\n let placeholderText;\n const placeholder = editor.config.get('placeholder');\n if (placeholder) {\n placeholderText = typeof placeholder === 'string' ? placeholder : placeholder[this.view.editable.name];\n }\n if (!placeholderText && sourceElement && sourceElement.tagName.toLowerCase() === 'textarea') {\n placeholderText = sourceElement.getAttribute('placeholder');\n }\n if (placeholderText) {\n editingRoot.placeholder = placeholderText;\n }\n enablePlaceholder({\n view: editingView,\n element: editingRoot,\n isDirectHost: false,\n keepOnFocus: true\n });\n }\n /**\n * Provides an integration between the sticky toolbar and {@link module:utils/dom/scroll~scrollViewportToShowTarget}.\n * It allows the UI-agnostic engine method to consider the geometry of the\n * {@link module:editor-classic/classiceditoruiview~ClassicEditorUIView#stickyPanel} that pins to the\n * edge of the viewport and can obscure the user caret after scrolling the window.\n *\n * @param evt The `scrollToTheSelection` event info.\n * @param data The payload carried by the `scrollToTheSelection` event.\n * @param originalArgs The original arguments passed to `scrollViewportToShowTarget()` method (see implementation to learn more).\n */\n _handleScrollToTheSelectionWithStickyPanel(evt, data, originalArgs) {\n const stickyPanel = this.view.stickyPanel;\n if (stickyPanel.isSticky) {\n const stickyPanelHeight = new Rect(stickyPanel.element).height;\n data.viewportOffset.top += stickyPanelHeight;\n }\n else {\n const scrollViewportOnPanelGettingSticky = () => {\n this.editor.editing.view.scrollToTheSelection(originalArgs);\n };\n this.listenTo(stickyPanel, 'change:isSticky', scrollViewportOnPanelGettingSticky);\n // This works as a post-scroll-fixer because it's impossible predict whether the panel will be sticky after scrolling or not.\n // Listen for a short period of time only and if the toolbar does not become sticky very soon, cancel the listener.\n setTimeout(() => {\n this.stopListening(stickyPanel, 'change:isSticky', scrollViewportOnPanelGettingSticky);\n }, 20);\n }\n }\n /**\n * Provides an integration between the sticky toolbar and {@link module:ui/dialog/dialog the Dialog plugin}.\n *\n * It moves the dialog down to ensure that the\n * {@link module:editor-classic/classiceditoruiview~ClassicEditorUIView#stickyPanel sticky panel}\n * used by the editor UI will not get obscured by the dialog when the dialog uses one of its automatic positions.\n */\n _initDialogPluginIntegration() {\n if (!this.editor.plugins.has('Dialog')) {\n return;\n }\n const stickyPanel = this.view.stickyPanel;\n const dialogPlugin = this.editor.plugins.get('Dialog');\n dialogPlugin.on('show', () => {\n const dialogView = dialogPlugin.view;\n dialogView.on('moveTo', (evt, data) => {\n // Engage only when the panel is sticky, and the dialog is using one of default positions.\n if (!stickyPanel.isSticky || dialogView.wasMoved) {\n return;\n }\n const stickyPanelContentRect = new Rect(stickyPanel.contentPanelElement);\n if (data[1] < stickyPanelContentRect.bottom + DialogView.defaultOffset) {\n data[1] = stickyPanelContentRect.bottom + DialogView.defaultOffset;\n }\n }, { priority: 'high' });\n }, { priority: 'low' });\n }\n}\n\n/**\n * @license Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n/**\n * @module editor-classic/classiceditoruiview\n */\n/**\n * Classic editor UI view. Uses an inline editable and a sticky toolbar, all\n * enclosed in a boxed UI view.\n */\nclass ClassicEditorUIView extends BoxedEditorUIView {\n /**\n * Creates an instance of the classic editor UI view.\n *\n * @param locale The {@link module:core/editor/editor~Editor#locale} instance.\n * @param editingView The editing view instance this view is related to.\n * @param options Configuration options for the view instance.\n * @param options.shouldToolbarGroupWhenFull When set `true` enables automatic items grouping\n * in the main {@link module:editor-classic/classiceditoruiview~ClassicEditorUIView#toolbar toolbar}.\n * See {@link module:ui/toolbar/toolbarview~ToolbarOptions#shouldGroupWhenFull} to learn more.\n */\n constructor(locale, editingView, options = {}) {\n super(locale);\n this.stickyPanel = new StickyPanelView(locale);\n this.toolbar = new ToolbarView(locale, {\n shouldGroupWhenFull: options.shouldToolbarGroupWhenFull\n });\n this.editable = new InlineEditableUIView(locale, editingView);\n }\n /**\n * @inheritDoc\n */\n render() {\n super.render();\n // Set toolbar as a child of a stickyPanel and makes toolbar sticky.\n this.stickyPanel.content.add(this.toolbar);\n this.top.add(this.stickyPanel);\n this.main.add(this.editable);\n }\n}\n\n/**\n * @license Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n/**\n * @module editor-classic/classiceditor\n */\n/**\n * The {@glink installation/getting-started/predefined-builds#classic-editor classic editor} implementation.\n * It uses an inline editable and a sticky toolbar, all enclosed in a boxed UI.\n * See the {@glink examples/builds/classic-editor demo}.\n *\n * In order to create a classic editor instance, use the static\n * {@link module:editor-classic/classiceditor~ClassicEditor.create `ClassicEditor.create()`} method.\n *\n * # Classic editor and classic build\n *\n * The classic editor can be used directly from source (if you installed the\n * [`@ckeditor/ckeditor5-editor-classic/dist/index.js`](https://www.npmjs.com/package/@ckeditor/ckeditor5-editor-classic/dist/index.js) package)\n * but it is also available in the {@glink installation/getting-started/predefined-builds#classic-editor classic build}.\n *\n * {@glink installation/getting-started/predefined-builds Builds}\n * are ready-to-use editors with plugins bundled in. When using the editor from\n * source you need to take care of loading all plugins by yourself\n * (through the {@link module:core/editor/editorconfig~EditorConfig#plugins `config.plugins`} option).\n * Using the editor from source gives much better flexibility and allows easier customization.\n *\n * Read more about initializing the editor from source or as a build in\n * {@link module:editor-classic/classiceditor~ClassicEditor.create `ClassicEditor.create()`}.\n */\nclass ClassicEditor extends ElementApiMixin(Editor) {\n /**\n * Creates an instance of the classic editor.\n *\n * **Note:** do not use the constructor to create editor instances. Use the static\n * {@link module:editor-classic/classiceditor~ClassicEditor.create `ClassicEditor.create()`} method instead.\n *\n * @param sourceElementOrData The DOM element that will be the source for the created editor\n * or the editor's initial data. For more information see\n * {@link module:editor-classic/classiceditor~ClassicEditor.create `ClassicEditor.create()`}.\n * @param config The editor configuration.\n */\n constructor(sourceElementOrData, config = {}) {\n // If both `config.initialData` is set and initial data is passed as the constructor parameter, then throw.\n if (!isElement(sourceElementOrData) && config.initialData !== undefined) {\n // Documented in core/editor/editorconfig.jsdoc.\n // eslint-disable-next-line ckeditor5-rules/ckeditor-error-message\n throw new CKEditorError('editor-create-initial-data', null);\n }\n super(config);\n if (this.config.get('initialData') === undefined) {\n this.config.set('initialData', getInitialData(sourceElementOrData));\n }\n if (isElement(sourceElementOrData)) {\n this.sourceElement = sourceElementOrData;\n }\n this.model.document.createRoot();\n const shouldToolbarGroupWhenFull = !this.config.get('toolbar.shouldNotGroupWhenFull');\n const view = new ClassicEditorUIView(this.locale, this.editing.view, {\n shouldToolbarGroupWhenFull\n });\n this.ui = new ClassicEditorUI(this, view);\n attachToForm(this);\n }\n /**\n * Destroys the editor instance, releasing all resources used by it.\n *\n * Updates the original editor element with the data if the\n * {@link module:core/editor/editorconfig~EditorConfig#updateSourceElementOnDestroy `updateSourceElementOnDestroy`}\n * configuration option is set to `true`.\n */\n destroy() {\n if (this.sourceElement) {\n this.updateSourceElement();\n }\n this.ui.destroy();\n return super.destroy();\n }\n /**\n * Creates a new classic editor instance.\n *\n * There are three ways how the editor can be initialized.\n *\n * # Replacing a DOM element (and loading data from it)\n *\n * You can initialize the editor using an existing DOM element:\n *\n * ```ts\n * ClassicEditor\n * \t.create( document.querySelector( '#editor' ) )\n * \t.then( editor => {\n * \t\tconsole.log( 'Editor was initialized', editor );\n * \t} )\n * \t.catch( err => {\n * \t\tconsole.error( err.stack );\n * \t} );\n * ```\n *\n * The element's content will be used as the editor data and the element will be replaced by the editor UI.\n *\n * # Creating a detached editor\n *\n * Alternatively, you can initialize the editor by passing the initial data directly as a string.\n * In this case, the editor will render an element that must be inserted into the DOM:\n *\n * ```ts\n * ClassicEditor\n * \t.create( '<p>Hello world!</p>' )\n * \t.then( editor => {\n * \t\tconsole.log( 'Editor was initialized', editor );\n *\n * \t\t// Initial data was provided so the editor UI element needs to be added manually to the DOM.\n * \t\tdocument.body.appendChild( editor.ui.element );\n * \t} )\n * \t.catch( err => {\n * \t\tconsole.error( err.stack );\n * \t} );\n * ```\n *\n * This lets you dynamically append the editor to your web page whenever it is convenient for you. You may use this method if your\n * web page content is generated on the client side and the DOM structure is not ready at the moment when you initialize the editor.\n *\n * # Replacing a DOM element (and data provided in `config.initialData`)\n *\n * You can also mix these two ways by providing a DOM element to be used and passing the initial data through the configuration:\n *\n * ```ts\n * ClassicEditor\n * \t.create( document.querySelector( '#editor' ), {\n * \t\tinitialData: '<h2>Initial data</h2><p>Foo bar.</p>'\n * \t} )\n * \t.then( editor => {\n * \t\tconsole.log( 'Editor was initialized', editor );\n * \t} )\n * \t.catch( err => {\n * \t\tconsole.error( err.stack );\n * \t} );\n * ```\n *\n * This method can be used to initialize the editor on an existing element with the specified content in case if your integration\n * makes it difficult to set the content of the source element.\n *\n * Note that an error will be thrown if you pass the initial data both as the first parameter and also in the configuration.\n *\n * # Configuring the editor\n *\n * See the {@link module:core/editor/editorconfig~EditorConfig editor configuration documentation} to learn more about\n * customizing plugins, toolbar and more.\n *\n * # Using the editor from source\n *\n * The code samples listed in the previous sections of this documentation assume that you are using an\n * {@glink installation/getting-started/predefined-builds editor build} (for example – `@ckeditor/ckeditor5-build-classic/dist/index.js`).\n *\n * If you want to use the classic editor from source (`@ckeditor/ckeditor5-editor-classic/dist/index.js`),\n * you need to define the list of\n * {@link module:core/editor/editorconfig~EditorConfig#plugins plugins to be initialized} and\n * {@link module:core/editor/editorconfig~EditorConfig#toolbar toolbar items}. Read more about using the editor from\n * source in the {@glink installation/advanced/alternative-setups/integrating-from-source-webpack dedicated guide}.\n *\n * @param sourceElementOrData The DOM element that will be the source for the created editor\n * or the editor's initial data.\n *\n * If a DOM element is passed, its content will be automatically loaded to the editor upon initialization\n * and the {@link module:editor-classic/classiceditorui~ClassicEditorUI#element editor element} will replace the passed element\n * in the DOM (the original one will be hidden and the editor will be injected next to it).\n *\n * If the {@link module:core/editor/editorconfig~EditorConfig#updateSourceElementOnDestroy updateSourceElementOnDestroy}\n * option is set to `true`, the editor data will be set back to the original element once the editor is destroyed and when a form,\n * in which this element is contained, is submitted (if the original element is a `<textarea>`). This ensures seamless integration\n * with native web forms.\n *\n * If the initial data is passed, a detached editor will be created. In this case you need to insert it into the DOM manually.\n * It is available under the {@link module:editor-classic/classiceditorui~ClassicEditorUI#element `editor.ui.element`} property.\n *\n * @param config The editor configuration.\n * @returns A promise resolved once the editor is ready. The promise resolves with the created editor instance.\n */\n static create(sourceElementOrData, config = {}) {\n return new Promise(resolve => {\n const editor = new this(sourceElementOrData, config);\n resolve(editor.initPlugins()\n .then(() => editor.ui.init(isElement(sourceElementOrData) ? sourceElementOrData : null))\n .then(() => editor.data.init(editor.config.get('initialData')))\n .then(() => editor.fire('ready'))\n .then(() => editor));\n });\n }\n}\n/**\n * The {@link module:core/context~Context} class.\n *\n * Exposed as static editor field for easier access in editor builds.\n */\nClassicEditor.Context = Context;\n/**\n * The {@link module:watchdog/editorwatchdog~EditorWatchdog} class.\n *\n * Exposed as static editor field for easier access in editor builds.\n */\nClassicEditor.EditorWatchdog = EditorWatchdog;\n/**\n * The {@link module:watchdog/contextwatchdog~ContextWatchdog} class.\n *\n * Exposed as static editor field for easier access in editor builds.\n */\nClassicEditor.ContextWatchdog = ContextWatchdog;\nfunction getInitialData(sourceElementOrData) {\n return isElement(sourceElementOrData) ? getDataFromElement(sourceElementOrData) : sourceElementOrData;\n}\nfunction isElement(value) {\n return isElement$1(value);\n}\n\nexport { ClassicEditor };\n//# sourceMappingURL=index.js.map\n","/**\n * @license Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n/**\n * @module editor-classic/classiceditorui\n */\n\nimport type { Editor, ElementApi } from 'ckeditor5/src/core.js';\nimport {\n\tEditorUI,\n\tnormalizeToolbarConfig,\n\tDialogView,\n\ttype EditorUIReadyEvent,\n\ttype DialogViewMoveToEvent,\n\ttype Dialog\n} from 'ckeditor5/src/ui.js';\nimport {\n\tenablePlaceholder,\n\ttype ViewScrollToTheSelectionEvent\n} from 'ckeditor5/src/engine.js';\nimport { ElementReplacer, Rect, type EventInfo } from 'ckeditor5/src/utils.js';\nimport type ClassicEditorUIView from './classiceditoruiview.js';\n\n/**\n * The classic editor UI class.\n */\nexport default class ClassicEditorUI extends EditorUI {\n\t/**\n\t * The main (top–most) view of the editor UI.\n\t */\n\tpublic readonly view: ClassicEditorUIView;\n\n\t/**\n\t * A normalized `config.toolbar` object.\n\t */\n\tprivate readonly _toolbarConfig: ReturnType<typeof normalizeToolbarConfig>;\n\n\t/**\n\t * The element replacer instance used to hide the editor's source element.\n\t */\n\tprivate readonly _elementReplacer: ElementReplacer;\n\n\t/**\n\t * Creates an instance of the classic editor UI class.\n\t *\n\t * @param editor The editor instance.\n\t * @param view The view of the UI.\n\t */\n\tconstructor( editor: Editor, view: ClassicEditorUIView ) {\n\t\tsuper( editor );\n\n\t\tthis.view = view;\n\t\tthis._toolbarConfig = normalizeToolbarConfig( editor.config.get( 'toolbar' ) );\n\t\tthis._elementReplacer = new ElementReplacer();\n\n\t\tthis.listenTo<ViewScrollToTheSelectionEvent>(\n\t\t\teditor.editing.view, 'scrollToTheSelection', this._handleScrollToTheSelectionWithStickyPanel.bind( this ) );\n\t}\n\n\t/**\n\t * @inheritDoc\n\t */\n\tpublic override get element(): HTMLElement | null {\n\t\treturn this.view.element;\n\t}\n\n\t/**\n\t * Initializes the UI.\n\t *\n\t * @param replacementElement The DOM element that will be the source for the created editor.\n\t */\n\tpublic init( replacementElement: HTMLElement | null ): void {\n\t\tconst editor = this.editor;\n\t\tconst view = this.view;\n\t\tconst editingView = editor.editing.view;\n\t\tconst editable = view.editable;\n\t\tconst editingRoot = editingView.document.getRoot()!;\n\n\t\t// The editable UI and editing root should share the same name. Then name is used\n\t\t// to recognize the particular editable, for instance in ARIA attributes.\n\t\teditable.name = editingRoot.rootName;\n\n\t\tview.render();\n\n\t\t// The editable UI element in DOM is available for sure only after the editor UI view has been rendered.\n\t\t// But it can be available earlier if a DOM element has been passed to BalloonEditor.create().\n\t\tconst editableElement = editable.element!;\n\n\t\t// Register the editable UI view in the editor. A single editor instance can aggregate multiple\n\t\t// editable areas (roots) but the classic editor has only one.\n\t\tthis.setEditableElement( editable.name, editableElement );\n\n\t\t// Let the editable UI element respond to the changes in the global editor focus\n\t\t// tracker. It has been added to the same tracker a few lines above but, in reality, there are\n\t\t// many focusable areas in the editor, like balloons, toolbars or dropdowns and as long\n\t\t// as they have focus, the editable should act like it is focused too (although technically\n\t\t// it isn't), e.g. by setting the proper CSS class, visually announcing focus to the user.\n\t\t// Doing otherwise will result in editable focus styles disappearing, once e.g. the\n\t\t// toolbar gets focused.\n\t\tview.editable.bind( 'isFocused' ).to( this.focusTracker );\n\n\t\t// Bind the editable UI element to the editing view, making it an end– and entry–point\n\t\t// of the editor's engine. This is where the engine meets the UI.\n\t\teditingView.attachDomRoot( editableElement );\n\n\t\t// If an element containing the initial data of the editor was provided, replace it with\n\t\t// an editor instance's UI in DOM until the editor is destroyed. For instance, a <textarea>\n\t\t// can be such element.\n\t\tif ( replacementElement ) {\n\t\t\tthis._elementReplacer.replace( replacementElement, this.element as HTMLElement | undefined );\n\t\t}\n\n\t\tthis._initPlaceholder();\n\t\tthis._initToolbar();\n\t\tthis._initDialogPluginIntegration();\n\t\tthis.fire<EditorUIReadyEvent>( 'ready' );\n\t}\n\n\t/**\n\t * @inheritDoc\n\t */\n\tpublic override destroy(): void {\n\t\tsuper.destroy();\n\n\t\tconst view = this.view;\n\t\tconst editingView = this.editor.editing.view;\n\n\t\tthis._elementReplacer.restore();\n\t\teditingView.detachDomRoot( view.editable.name! );\n\t\tview.destroy();\n\t}\n\n\t/**\n\t * Initializes the editor toolbar.\n\t */\n\tprivate _initToolbar(): void {\n\t\tconst view = this.view;\n\n\t\t// Set–up the sticky panel with toolbar.\n\t\tview.stickyPanel.bind( 'isActive' ).to( this.focusTracker, 'isFocused' );\n\t\tview.stickyPanel.limiterElement = view.element;\n\t\tview.stickyPanel.bind( 'viewportTopOffset' ).to( this, 'viewportOffset', ( { top } ) => top || 0 );\n\n\t\tview.toolbar.fillFromConfig( this._toolbarConfig, this.componentFactory );\n\n\t\t// Register the toolbar so it becomes available for Alt+F10 and Esc navigation.\n\t\tthis.addToolbar( view.toolbar );\n\t}\n\n\t/**\n\t * Enable the placeholder text on the editing root.\n\t */\n\tprivate _initPlaceholder(): void {\n\t\tconst editor = this.editor;\n\t\tconst editingView = editor.editing.view;\n\t\tconst editingRoot = editingView.document.getRoot()!;\n\t\tconst sourceElement = ( editor as Editor & ElementApi ).sourceElement;\n\n\t\tlet placeholderText;\n\t\tconst placeholder = editor.config.get( 'placeholder' );\n\n\t\tif ( placeholder ) {\n\t\t\tplaceholderText = typeof placeholder === 'string' ? placeholder : placeholder[ this.view.editable.name! ];\n\t\t}\n\n\t\tif ( !placeholderText && sourceElement && sourceElement.tagName.toLowerCase() === 'textarea' ) {\n\t\t\tplaceholderText = sourceElement.getAttribute( 'placeholder' );\n\t\t}\n\n\t\tif ( placeholderText ) {\n\t\t\teditingRoot.placeholder = placeholderText;\n\t\t}\n\n\t\tenablePlaceholder( {\n\t\t\tview: editingView,\n\t\t\telement: editingRoot,\n\t\t\tisDirectHost: false,\n\t\t\tkeepOnFocus: true\n\t\t} );\n\t}\n\n\t/**\n\t * Provides an integration between the sticky toolbar and {@link module:utils/dom/scroll~scrollViewportToShowTarget}.\n\t * It allows the UI-agnostic engine method to consider the geometry of the\n\t * {@link module:editor-classic/classiceditoruiview~ClassicEditorUIView#stickyPanel} that pins to the\n\t * edge of the viewport and can obscure the user caret after scrolling the window.\n\t *\n\t * @param evt The `scrollToTheSelection` event info.\n\t * @param data The payload carried by the `scrollToTheSelection` event.\n\t * @param originalArgs The original arguments passed to `scrollViewportToShowTarget()` method (see implementation to learn more).\n\t */\n\tprivate _handleScrollToTheSelectionWithStickyPanel(\n\t\tevt: EventInfo<'scrollToTheSelection'>,\n\t\tdata: ViewScrollToTheSelectionEvent[ 'args' ][ 0 ],\n\t\toriginalArgs: ViewScrollToTheSelectionEvent[ 'args' ][ 1 ]\n\t): void {\n\t\tconst stickyPanel = this.view.stickyPanel;\n\n\t\tif ( stickyPanel.isSticky ) {\n\t\t\tconst stickyPanelHeight = new Rect( stickyPanel.element! ).height;\n\n\t\t\tdata.viewportOffset.top += stickyPanelHeight;\n\t\t} else {\n\t\t\tconst scrollViewportOnPanelGettingSticky = () => {\n\t\t\t\tthis.editor.editing.view.scrollToTheSelection( originalArgs );\n\t\t\t};\n\n\t\t\tthis.listenTo( stickyPanel, 'change:isSticky', scrollViewportOnPanelGettingSticky );\n\n\t\t\t// This works as a post-scroll-fixer because it's impossible predict whether the panel will be sticky after scrolling or not.\n\t\t\t// Listen for a short period of time only and if the toolbar does not become sticky very soon, cancel the listener.\n\t\t\tsetTimeout( () => {\n\t\t\t\tthis.stopListening( stickyPanel, 'change:isSticky', scrollViewportOnPanelGettingSticky );\n\t\t\t}, 20 );\n\t\t}\n\t}\n\n\t/**\n\t * Provides an integration between the sticky toolbar and {@link module:ui/dialog/dialog the Dialog plugin}.\n\t *\n\t * It moves the dialog down to ensure that the\n\t * {@link module:editor-classic/classiceditoruiview~ClassicEditorUIView#stickyPanel sticky panel}\n\t * used by the editor UI will not get obscured by the dialog when the dialog uses one of its automatic positions.\n\t */\n\tprivate _initDialogPluginIntegration(): void {\n\t\tif ( !this.editor.plugins.has( 'Dialog' ) ) {\n\t\t\treturn;\n\t\t}\n\n\t\tconst stickyPanel = this.view.stickyPanel;\n\t\tconst dialogPlugin: Dialog = this.editor.plugins.get( 'Dialog' );\n\n\t\tdialogPlugin.on( 'show', () => {\n\t\t\tconst dialogView = dialogPlugin.view!;\n\n\t\t\tdialogView.on<DialogViewMoveToEvent>( 'moveTo', ( evt, data ) => {\n\t\t\t\t// Engage only when the panel is sticky, and the dialog is using one of default positions.\n\t\t\t\tif ( !stickyPanel.isSticky || dialogView.wasMoved ) {\n\t\t\t\t\treturn;\n\t\t\t\t}\n\n\t\t\t\tconst stickyPanelContentRect = new Rect( stickyPanel.contentPanelElement );\n\n\t\t\t\tif ( data[ 1 ] < stickyPanelContentRect.bottom + DialogView.defaultOffset ) {\n\t\t\t\t\tdata[ 1 ] = stickyPanelContentRect.bottom + DialogView.defaultOffset;\n\t\t\t\t}\n\t\t\t}, { priority: 'high' } );\n\t\t}, { priority: 'low' } );\n\t}\n}\n\n","/**\n * @license Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n/**\n * @module editor-classic/classiceditoruiview\n */\n\nimport { BoxedEditorUIView, InlineEditableUIView, StickyPanelView, ToolbarView } from 'ckeditor5/src/ui.js';\nimport type { Locale } from 'ckeditor5/src/utils.js';\nimport type { EditingView } from 'ckeditor5/src/engine.js';\n\nimport '../theme/classiceditor.css';\n\n/**\n * Classic editor UI view. Uses an inline editable and a sticky toolbar, all\n * enclosed in a boxed UI view.\n */\nexport default class ClassicEditorUIView extends BoxedEditorUIView {\n\t/**\n\t * Sticky panel view instance. This is a parent view of a {@link #toolbar}\n\t * that makes toolbar sticky.\n\t */\n\tpublic readonly stickyPanel: StickyPanelView;\n\n\t/**\n\t * Toolbar view instance.\n\t */\n\tpublic readonly toolbar: ToolbarView;\n\n\t/**\n\t * Editable UI view.\n\t */\n\tpublic readonly editable: InlineEditableUIView;\n\n\t/**\n\t * Creates an instance of the classic editor UI view.\n\t *\n\t * @param locale The {@link module:core/editor/editor~Editor#locale} instance.\n\t * @param editingView The editing view instance this view is related to.\n\t * @param options Configuration options for the view instance.\n\t * @param options.shouldToolbarGroupWhenFull When set `true` enables automatic items grouping\n\t * in the main {@link module:editor-classic/classiceditoruiview~ClassicEditorUIView#toolbar toolbar}.\n\t * See {@link module:ui/toolbar/toolbarview~ToolbarOptions#shouldGroupWhenFull} to learn more.\n\t */\n\tconstructor(\n\t\tlocale: Locale,\n\t\teditingView: EditingView,\n\t\toptions: {\n\t\t\tshouldToolbarGroupWhenFull?: boolean;\n\t\t} = {}\n\t) {\n\t\tsuper( locale );\n\n\t\tthis.stickyPanel = new StickyPanelView( locale );\n\n\t\tthis.toolbar = new ToolbarView( locale, {\n\t\t\tshouldGroupWhenFull: options.shouldToolbarGroupWhenFull\n\t\t} );\n\n\t\tthis.editable = new InlineEditableUIView( locale, editingView );\n\t}\n\n\t/**\n\t * @inheritDoc\n\t */\n\tpublic override render(): void {\n\t\tsuper.render();\n\n\t\t// Set toolbar as a child of a stickyPanel and makes toolbar sticky.\n\t\tthis.stickyPanel.content.add( this.toolbar );\n\n\t\tthis.top.add( this.stickyPanel );\n\t\tthis.main.add( this.editable );\n\t}\n}\n","/**\n * @license Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.\n * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license\n */\n\n/**\n * @module editor-classic/classiceditor\n */\n\nimport ClassicEditorUI from './classiceditorui.js';\nimport ClassicEditorUIView from './classiceditoruiview.js';\n\nimport {\n\tEditor,\n\tContext,\n\tElementApiMixin,\n\tattachToForm,\n\ttype EditorConfig,\n\ttype EditorReadyEvent\n} from 'ckeditor5/src/core.js';\nimport { getDataFromElement, CKEditorError } from 'ckeditor5/src/utils.js';\n\nimport { ContextWatchdog, EditorWatchdog } from 'ckeditor5/src/watchdog.js';\n\nimport { isElement as _isElement } from 'lodash-es';\n\n/**\n * The {@glink installation/getting-started/predefined-builds#classic-editor classic editor} implementation.\n * It uses an inline editable and a sticky toolbar, all enclosed in a boxed UI.\n * See the {@glink examples/builds/classic-editor demo}.\n *\n * In order to create a classic editor instance, use the static\n * {@link module:editor-classic/classiceditor~ClassicEditor.create `ClassicEditor.create()`} method.\n *\n * # Classic editor and classic build\n *\n * The classic editor can be used directly from source (if you installed the\n * [`@ckeditor/ckeditor5-editor-classic`](https://www.npmjs.com/package/@ckeditor/ckeditor5-editor-classic) package)\n * but it is also available in the {@glink installation/getting-started/predefined-builds#classic-editor classic build}.\n *\n * {@glink installation/getting-started/predefined-builds Builds}\n * are ready-to-use editors with plugins bundled in. When using the editor from\n * source you need to take care of loading all plugins by yourself\n * (through the {@link module:core/editor/editorconfig~EditorConfig#plugins `config.plugins`} option).\n * Using the editor from source gives much better flexibility and allows easier customization.\n *\n * Read more about initializing the editor from source or as a build in\n * {@link module:editor-classic/classiceditor~ClassicEditor.create `ClassicEditor.create()`}.\n */\nexport default class ClassicEditor extends ElementApiMixin( Editor ) {\n\t/**\n\t * @inheritDoc\n\t */\n\tpublic readonly ui: ClassicEditorUI;\n\n\t/**\n\t * Creates an instance of the classic editor.\n\t *\n\t * **Note:** do not use the constructor to create editor instances. Use the static\n\t * {@link module:editor-classic/classiceditor~ClassicEditor.create `ClassicEditor.create()`} method instead.\n\t *\n\t * @param sourceElementOrData The DOM element that will be the source for the created editor\n\t * or the editor's initial data. For more information see\n\t * {@link module:editor-classic/classiceditor~ClassicEditor.create `ClassicEditor.create()`}.\n\t * @param config The editor configuration.\n\t */\n\tprotected constructor( sourceElementOrData: HTMLElement | string, config: EditorConfig = {} ) {\n\t\t// If both `config.initialData` is set and initial data is passed as the constructor parameter, then throw.\n\t\tif ( !isElement( sourceElementOrData ) && config.initialData !== undefined ) {\n\t\t\t// Documented in core/editor/editorconfig.jsdoc.\n\t\t\t// eslint-disable-next-line ckeditor5-rules/ckeditor-error-message\n\t\t\tthrow new CKEditorError( 'editor-create-initial-data', null );\n\t\t}\n\n\t\tsuper( config );\n\n\t\tif ( this.config.get( 'initialData' ) === undefined ) {\n\t\t\tthis.config.set( 'initialData', getInitialData( sourceElementOrData ) );\n\t\t}\n\n\t\tif ( isElement( sourceElementOrData ) ) {\n\t\t\tthis.sourceElement = sourceElementOrData;\n\t\t}\n\n\t\tthis.model.document.createRoot();\n\n\t\tconst shouldToolbarGroupWhenFull = !this.config.get( 'toolbar.shouldNotGroupWhenFull' );\n\t\tconst view = new ClassicEditorUIView( this.locale, this.editing.view, {\n\t\t\tshouldToolbarGroupWhenFull\n\t\t} );\n\n\t\tthis.ui = new ClassicEditorUI( this, view );\n\n\t\tattachToForm( this );\n\t}\n\n\t/**\n\t * Destroys the editor instance, releasing all resources used by it.\n\t *\n\t * Updates the original editor element with the data if the\n\t * {@link module:core/editor/editorconfig~EditorConfig#updateSourceElementOnDestroy `updateSourceElementOnDestroy`}\n\t * configuration option is set to `true`.\n\t */\n\tpublic override destroy(): Promise<unknown> {\n\t\tif ( this.sourceElement ) {\n\t\t\tthis.updateSourceElement();\n\t\t}\n\n\t\tthis.ui.destroy();\n\n\t\treturn super.destroy();\n\t}\n\n\t/**\n\t * Creates a new classic editor instance.\n\t *\n\t * There are three ways how the editor can be initialized.\n\t *\n\t * # Replacing a DOM element (and loading data from it)\n\t *\n\t * You can initialize the editor using an existing DOM element:\n\t *\n\t * ```ts\n\t * ClassicEditor\n\t * \t.create( document.querySelector( '#editor' ) )\n\t * \t.then( editor => {\n\t * \t\tconsole.log( 'Editor was initialized', editor );\n\t * \t} )\n\t * \t.catch( err => {\n\t * \t\tconsole.error( err.stack );\n\t * \t} );\n\t * ```\n\t *\n\t * The element's content will be used as the editor data and the element will be replaced by the editor UI.\n\t *\n\t * # Creating a detached editor\n\t *\n\t * Alternatively, you can initialize the editor by passing the initial data directly as a string.\n\t * In this case, the editor will render an element that must be inserted into the DOM:\n\t *\n\t * ```ts\n\t * ClassicEditor\n\t * \t.create( '<p>Hello world!</p>' )\n\t * \t.then( editor => {\n\t * \t\tconsole.log( 'Editor was initialized', editor );\n\t *\n\t * \t\t// Initial data was provided so the editor UI element needs to be added manually to the DOM.\n\t * \t\tdocument.body.appendChild( editor.ui.element );\n\t * \t} )\n\t * \t.catch( err => {\n\t * \t\tconsole.error( err.stack );\n\t * \t} );\n\t * ```\n\t *\n\t * This lets you dynamically append the editor to your web page whenever it is convenient for you. You may use this method if your\n\t * web page content is generated on the client side and the DOM structure is not ready at the moment when you initialize the editor.\n\t *\n\t * # Replacing a DOM element (and data provided in `config.initialData`)\n\t *\n\t * You can also mix these two ways by providing a DOM element to be used and passing the initial data through the configuration:\n\t *\n\t * ```ts\n\t * ClassicEditor\n\t * \t.create( document.querySelector( '#editor' ), {\n\t * \t\tinitialData: '<h2>Initial data</h2><p>Foo bar.</p>'\n\t * \t} )\n\t * \t.then( editor => {\n\t * \t\tconsole.log( 'Editor was initialized', editor );\n\t * \t} )\n\t * \t.catch( err => {\n\t * \t\tconsole.error( err.stack );\n\t * \t} );\n\t * ```\n\t *\n\t * This method can be used to initialize the editor on an existing element with the specified content in case if your integration\n\t * makes it difficult to set the content of the source element.\n\t *\n\t * Note that an error will be thrown if you pass the initial data both as the first parameter and also in the configuration.\n\t *\n\t * # Configuring the editor\n\t *\n\t * See the {@link module:core/editor/editorconfig~EditorConfig editor configuration documentation} to learn more about\n\t * customizing plugins, toolbar and more.\n\t *\n\t * # Using the editor from source\n\t *\n\t * The code samples listed in the previous sections of this documentation assume that you are using an\n\t * {@glink installation/getting-started/predefined-builds editor build} (for example – `@ckeditor/ckeditor5-build-classic`).\n\t *\n\t * If you want to use the classic editor from source (`@ckeditor/ckeditor5-editor-classic/src/classiceditor`),\n\t * you need to define the list of\n\t * {@link module:core/editor/editorconfig~EditorConfig#plugins plugins to be initialized} and\n\t * {@link module:core/editor/editorconfig~EditorConfig#toolbar toolbar items}. Read more about using the editor from\n\t * source in the {@glink installation/advanced/alternative-setups/integrating-from-source-webpack dedicated guide}.\n\t *\n\t * @param sourceElementOrData The DOM element that will be the source for the created editor\n\t * or the editor's initial data.\n\t *\n\t * If a DOM element is passed, its content will be automatically loaded to the editor upon initialization\n\t * and the {@link module:editor-classic/classiceditorui~ClassicEditorUI#element editor element} will replace the passed element\n\t * in the DOM (the original one will be hidden and the editor will be injected next to it).\n\t *\n\t * If the {@link module:core/editor/editorconfig~EditorConfig#updateSourceElementOnDestroy updateSourceElementOnDestroy}\n\t * option is set to `true`, the editor data will be set back to the original element once the editor is destroyed and when a form,\n\t * in which this element is contained, is submitted (if the original element is a `<textarea>`). This ensures seamless integration\n\t * with native web forms.\n\t *\n\t * If the initial data is passed, a detached editor will be created. In this case you need to insert it into the DOM manually.\n\t * It is available under the {@link module:editor-classic/classiceditorui~ClassicEditorUI#element `editor.ui.element`} property.\n\t *\n\t * @param config The editor configuration.\n\t * @returns A promise resolved once the editor is ready. The promise resolves with the created editor instance.\n\t */\n\tpublic static override create( sourceElementOrData: HTMLElement | string, config: EditorConfig = {} ): Promise<ClassicEditor> {\n\t\treturn new Promise( resolve => {\n\t\t\tconst editor = new this( sourceElementOrData, config );\n\n\t\t\tresolve(\n\t\t\t\teditor.initPlugins()\n\t\t\t\t\t.then( () => editor.ui.init( isElement( sourceElementOrData ) ? sourceElementOrData : null ) )\n\t\t\t\t\t.then( () => editor.data.init( editor.config.get( 'initialData' )! ) )\n\t\t\t\t\t.then( () => editor.fire<EditorReadyEvent>( 'ready' ) )\n\t\t\t\t\t.then( () => editor )\n\t\t\t);\n\t\t} );\n\t}\n\n\t/**\n\t * The {@link module:core/context~Context} class.\n\t *\n\t * Exposed as static editor field for easier access in editor builds.\n\t */\n\tpublic static Context = Context;\n\n\t/**\n\t * The {@link module:watchdog/editorwatchdog~EditorWatchdog} class.\n\t *\n\t * Exposed as static editor field for easier access in editor builds.\n\t */\n\tpublic static EditorWatchdog = EditorWatchdog;\n\n\t/**\n\t * The {@link module:watchdog/contextwatchdog~ContextWatchdog} class.\n\t *\n\t * Exposed as static editor field for easier access in editor builds.\n\t */\n\tpublic static ContextWatchdog = ContextWatchdog;\n}\n\nfunction getInitialData( sourceElementOrData: HTMLElement | string ): string {\n\treturn isElement( sourceElementOrData ) ? getDataFromElement( sourceElementOrData ) : sourceElementOrData;\n}\n\nfunction isElement( value: any ): value is Element {\n\treturn _isElement( value );\n}\n"]}
|
@@ -0,0 +1,180 @@
|
|
1
|
+
/**
|
2
|
+
* @license Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.
|
3
|
+
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
|
4
|
+
*/
|
5
|
+
/**
|
6
|
+
* @module editor-classic/classiceditor
|
7
|
+
*/
|
8
|
+
import ClassicEditorUI from './classiceditorui.js';
|
9
|
+
import { Editor, Context, type EditorConfig } from 'ckeditor5/src/core.js';
|
10
|
+
import { ContextWatchdog, EditorWatchdog } from 'ckeditor5/src/watchdog.js';
|
11
|
+
declare const ClassicEditor_base: import("ckeditor5/src/utils.js").Mixed<typeof Editor, import("ckeditor5/src/core.js").ElementApi>;
|
12
|
+
/**
|
13
|
+
* The {@glink installation/getting-started/predefined-builds#classic-editor classic editor} implementation.
|
14
|
+
* It uses an inline editable and a sticky toolbar, all enclosed in a boxed UI.
|
15
|
+
* See the {@glink examples/builds/classic-editor demo}.
|
16
|
+
*
|
17
|
+
* In order to create a classic editor instance, use the static
|
18
|
+
* {@link module:editor-classic/classiceditor~ClassicEditor.create `ClassicEditor.create()`} method.
|
19
|
+
*
|
20
|
+
* # Classic editor and classic build
|
21
|
+
*
|
22
|
+
* The classic editor can be used directly from source (if you installed the
|
23
|
+
* [`@ckeditor/ckeditor5-editor-classic`](https://www.npmjs.com/package/@ckeditor/ckeditor5-editor-classic) package)
|
24
|
+
* but it is also available in the {@glink installation/getting-started/predefined-builds#classic-editor classic build}.
|
25
|
+
*
|
26
|
+
* {@glink installation/getting-started/predefined-builds Builds}
|
27
|
+
* are ready-to-use editors with plugins bundled in. When using the editor from
|
28
|
+
* source you need to take care of loading all plugins by yourself
|
29
|
+
* (through the {@link module:core/editor/editorconfig~EditorConfig#plugins `config.plugins`} option).
|
30
|
+
* Using the editor from source gives much better flexibility and allows easier customization.
|
31
|
+
*
|
32
|
+
* Read more about initializing the editor from source or as a build in
|
33
|
+
* {@link module:editor-classic/classiceditor~ClassicEditor.create `ClassicEditor.create()`}.
|
34
|
+
*/
|
35
|
+
export default class ClassicEditor extends ClassicEditor_base {
|
36
|
+
/**
|
37
|
+
* @inheritDoc
|
38
|
+
*/
|
39
|
+
readonly ui: ClassicEditorUI;
|
40
|
+
/**
|
41
|
+
* Creates an instance of the classic editor.
|
42
|
+
*
|
43
|
+
* **Note:** do not use the constructor to create editor instances. Use the static
|
44
|
+
* {@link module:editor-classic/classiceditor~ClassicEditor.create `ClassicEditor.create()`} method instead.
|
45
|
+
*
|
46
|
+
* @param sourceElementOrData The DOM element that will be the source for the created editor
|
47
|
+
* or the editor's initial data. For more information see
|
48
|
+
* {@link module:editor-classic/classiceditor~ClassicEditor.create `ClassicEditor.create()`}.
|
49
|
+
* @param config The editor configuration.
|
50
|
+
*/
|
51
|
+
protected constructor(sourceElementOrData: HTMLElement | string, config?: EditorConfig);
|
52
|
+
/**
|
53
|
+
* Destroys the editor instance, releasing all resources used by it.
|
54
|
+
*
|
55
|
+
* Updates the original editor element with the data if the
|
56
|
+
* {@link module:core/editor/editorconfig~EditorConfig#updateSourceElementOnDestroy `updateSourceElementOnDestroy`}
|
57
|
+
* configuration option is set to `true`.
|
58
|
+
*/
|
59
|
+
destroy(): Promise<unknown>;
|
60
|
+
/**
|
61
|
+
* Creates a new classic editor instance.
|
62
|
+
*
|
63
|
+
* There are three ways how the editor can be initialized.
|
64
|
+
*
|
65
|
+
* # Replacing a DOM element (and loading data from it)
|
66
|
+
*
|
67
|
+
* You can initialize the editor using an existing DOM element:
|
68
|
+
*
|
69
|
+
* ```ts
|
70
|
+
* ClassicEditor
|
71
|
+
* .create( document.querySelector( '#editor' ) )
|
72
|
+
* .then( editor => {
|
73
|
+
* console.log( 'Editor was initialized', editor );
|
74
|
+
* } )
|
75
|
+
* .catch( err => {
|
76
|
+
* console.error( err.stack );
|
77
|
+
* } );
|
78
|
+
* ```
|
79
|
+
*
|
80
|
+
* The element's content will be used as the editor data and the element will be replaced by the editor UI.
|
81
|
+
*
|
82
|
+
* # Creating a detached editor
|
83
|
+
*
|
84
|
+
* Alternatively, you can initialize the editor by passing the initial data directly as a string.
|
85
|
+
* In this case, the editor will render an element that must be inserted into the DOM:
|
86
|
+
*
|
87
|
+
* ```ts
|
88
|
+
* ClassicEditor
|
89
|
+
* .create( '<p>Hello world!</p>' )
|
90
|
+
* .then( editor => {
|
91
|
+
* console.log( 'Editor was initialized', editor );
|
92
|
+
*
|
93
|
+
* // Initial data was provided so the editor UI element needs to be added manually to the DOM.
|
94
|
+
* document.body.appendChild( editor.ui.element );
|
95
|
+
* } )
|
96
|
+
* .catch( err => {
|
97
|
+
* console.error( err.stack );
|
98
|
+
* } );
|
99
|
+
* ```
|
100
|
+
*
|
101
|
+
* This lets you dynamically append the editor to your web page whenever it is convenient for you. You may use this method if your
|
102
|
+
* web page content is generated on the client side and the DOM structure is not ready at the moment when you initialize the editor.
|
103
|
+
*
|
104
|
+
* # Replacing a DOM element (and data provided in `config.initialData`)
|
105
|
+
*
|
106
|
+
* You can also mix these two ways by providing a DOM element to be used and passing the initial data through the configuration:
|
107
|
+
*
|
108
|
+
* ```ts
|
109
|
+
* ClassicEditor
|
110
|
+
* .create( document.querySelector( '#editor' ), {
|
111
|
+
* initialData: '<h2>Initial data</h2><p>Foo bar.</p>'
|
112
|
+
* } )
|
113
|
+
* .then( editor => {
|
114
|
+
* console.log( 'Editor was initialized', editor );
|
115
|
+
* } )
|
116
|
+
* .catch( err => {
|
117
|
+
* console.error( err.stack );
|
118
|
+
* } );
|
119
|
+
* ```
|
120
|
+
*
|
121
|
+
* This method can be used to initialize the editor on an existing element with the specified content in case if your integration
|
122
|
+
* makes it difficult to set the content of the source element.
|
123
|
+
*
|
124
|
+
* Note that an error will be thrown if you pass the initial data both as the first parameter and also in the configuration.
|
125
|
+
*
|
126
|
+
* # Configuring the editor
|
127
|
+
*
|
128
|
+
* See the {@link module:core/editor/editorconfig~EditorConfig editor configuration documentation} to learn more about
|
129
|
+
* customizing plugins, toolbar and more.
|
130
|
+
*
|
131
|
+
* # Using the editor from source
|
132
|
+
*
|
133
|
+
* The code samples listed in the previous sections of this documentation assume that you are using an
|
134
|
+
* {@glink installation/getting-started/predefined-builds editor build} (for example – `@ckeditor/ckeditor5-build-classic`).
|
135
|
+
*
|
136
|
+
* If you want to use the classic editor from source (`@ckeditor/ckeditor5-editor-classic/src/classiceditor`),
|
137
|
+
* you need to define the list of
|
138
|
+
* {@link module:core/editor/editorconfig~EditorConfig#plugins plugins to be initialized} and
|
139
|
+
* {@link module:core/editor/editorconfig~EditorConfig#toolbar toolbar items}. Read more about using the editor from
|
140
|
+
* source in the {@glink installation/advanced/alternative-setups/integrating-from-source-webpack dedicated guide}.
|
141
|
+
*
|
142
|
+
* @param sourceElementOrData The DOM element that will be the source for the created editor
|
143
|
+
* or the editor's initial data.
|
144
|
+
*
|
145
|
+
* If a DOM element is passed, its content will be automatically loaded to the editor upon initialization
|
146
|
+
* and the {@link module:editor-classic/classiceditorui~ClassicEditorUI#element editor element} will replace the passed element
|
147
|
+
* in the DOM (the original one will be hidden and the editor will be injected next to it).
|
148
|
+
*
|
149
|
+
* If the {@link module:core/editor/editorconfig~EditorConfig#updateSourceElementOnDestroy updateSourceElementOnDestroy}
|
150
|
+
* option is set to `true`, the editor data will be set back to the original element once the editor is destroyed and when a form,
|
151
|
+
* in which this element is contained, is submitted (if the original element is a `<textarea>`). This ensures seamless integration
|
152
|
+
* with native web forms.
|
153
|
+
*
|
154
|
+
* If the initial data is passed, a detached editor will be created. In this case you need to insert it into the DOM manually.
|
155
|
+
* It is available under the {@link module:editor-classic/classiceditorui~ClassicEditorUI#element `editor.ui.element`} property.
|
156
|
+
*
|
157
|
+
* @param config The editor configuration.
|
158
|
+
* @returns A promise resolved once the editor is ready. The promise resolves with the created editor instance.
|
159
|
+
*/
|
160
|
+
static create(sourceElementOrData: HTMLElement | string, config?: EditorConfig): Promise<ClassicEditor>;
|
161
|
+
/**
|
162
|
+
* The {@link module:core/context~Context} class.
|
163
|
+
*
|
164
|
+
* Exposed as static editor field for easier access in editor builds.
|
165
|
+
*/
|
166
|
+
static Context: typeof Context;
|
167
|
+
/**
|
168
|
+
* The {@link module:watchdog/editorwatchdog~EditorWatchdog} class.
|
169
|
+
*
|
170
|
+
* Exposed as static editor field for easier access in editor builds.
|
171
|
+
*/
|
172
|
+
static EditorWatchdog: typeof EditorWatchdog;
|
173
|
+
/**
|
174
|
+
* The {@link module:watchdog/contextwatchdog~ContextWatchdog} class.
|
175
|
+
*
|
176
|
+
* Exposed as static editor field for easier access in editor builds.
|
177
|
+
*/
|
178
|
+
static ContextWatchdog: typeof ContextWatchdog;
|
179
|
+
}
|
180
|
+
export {};
|
@@ -0,0 +1,75 @@
|
|
1
|
+
/**
|
2
|
+
* @license Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.
|
3
|
+
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
|
4
|
+
*/
|
5
|
+
/**
|
6
|
+
* @module editor-classic/classiceditorui
|
7
|
+
*/
|
8
|
+
import type { Editor } from 'ckeditor5/src/core.js';
|
9
|
+
import { EditorUI } from 'ckeditor5/src/ui.js';
|
10
|
+
import type ClassicEditorUIView from './classiceditoruiview.js';
|
11
|
+
/**
|
12
|
+
* The classic editor UI class.
|
13
|
+
*/
|
14
|
+
export default class ClassicEditorUI extends EditorUI {
|
15
|
+
/**
|
16
|
+
* The main (top–most) view of the editor UI.
|
17
|
+
*/
|
18
|
+
readonly view: ClassicEditorUIView;
|
19
|
+
/**
|
20
|
+
* A normalized `config.toolbar` object.
|
21
|
+
*/
|
22
|
+
private readonly _toolbarConfig;
|
23
|
+
/**
|
24
|
+
* The element replacer instance used to hide the editor's source element.
|
25
|
+
*/
|
26
|
+
private readonly _elementReplacer;
|
27
|
+
/**
|
28
|
+
* Creates an instance of the classic editor UI class.
|
29
|
+
*
|
30
|
+
* @param editor The editor instance.
|
31
|
+
* @param view The view of the UI.
|
32
|
+
*/
|
33
|
+
constructor(editor: Editor, view: ClassicEditorUIView);
|
34
|
+
/**
|
35
|
+
* @inheritDoc
|
36
|
+
*/
|
37
|
+
get element(): HTMLElement | null;
|
38
|
+
/**
|
39
|
+
* Initializes the UI.
|
40
|
+
*
|
41
|
+
* @param replacementElement The DOM element that will be the source for the created editor.
|
42
|
+
*/
|
43
|
+
init(replacementElement: HTMLElement | null): void;
|
44
|
+
/**
|
45
|
+
* @inheritDoc
|
46
|
+
*/
|
47
|
+
destroy(): void;
|
48
|
+
/**
|
49
|
+
* Initializes the editor toolbar.
|
50
|
+
*/
|
51
|
+
private _initToolbar;
|
52
|
+
/**
|
53
|
+
* Enable the placeholder text on the editing root.
|
54
|
+
*/
|
55
|
+
private _initPlaceholder;
|
56
|
+
/**
|
57
|
+
* Provides an integration between the sticky toolbar and {@link module:utils/dom/scroll~scrollViewportToShowTarget}.
|
58
|
+
* It allows the UI-agnostic engine method to consider the geometry of the
|
59
|
+
* {@link module:editor-classic/classiceditoruiview~ClassicEditorUIView#stickyPanel} that pins to the
|
60
|
+
* edge of the viewport and can obscure the user caret after scrolling the window.
|
61
|
+
*
|
62
|
+
* @param evt The `scrollToTheSelection` event info.
|
63
|
+
* @param data The payload carried by the `scrollToTheSelection` event.
|
64
|
+
* @param originalArgs The original arguments passed to `scrollViewportToShowTarget()` method (see implementation to learn more).
|
65
|
+
*/
|
66
|
+
private _handleScrollToTheSelectionWithStickyPanel;
|
67
|
+
/**
|
68
|
+
* Provides an integration between the sticky toolbar and {@link module:ui/dialog/dialog the Dialog plugin}.
|
69
|
+
*
|
70
|
+
* It moves the dialog down to ensure that the
|
71
|
+
* {@link module:editor-classic/classiceditoruiview~ClassicEditorUIView#stickyPanel sticky panel}
|
72
|
+
* used by the editor UI will not get obscured by the dialog when the dialog uses one of its automatic positions.
|
73
|
+
*/
|
74
|
+
private _initDialogPluginIntegration;
|
75
|
+
}
|
@@ -0,0 +1,47 @@
|
|
1
|
+
/**
|
2
|
+
* @license Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.
|
3
|
+
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
|
4
|
+
*/
|
5
|
+
/**
|
6
|
+
* @module editor-classic/classiceditoruiview
|
7
|
+
*/
|
8
|
+
import { BoxedEditorUIView, InlineEditableUIView, StickyPanelView, ToolbarView } from 'ckeditor5/src/ui.js';
|
9
|
+
import type { Locale } from 'ckeditor5/src/utils.js';
|
10
|
+
import type { EditingView } from 'ckeditor5/src/engine.js';
|
11
|
+
import '../theme/classiceditor.css';
|
12
|
+
/**
|
13
|
+
* Classic editor UI view. Uses an inline editable and a sticky toolbar, all
|
14
|
+
* enclosed in a boxed UI view.
|
15
|
+
*/
|
16
|
+
export default class ClassicEditorUIView extends BoxedEditorUIView {
|
17
|
+
/**
|
18
|
+
* Sticky panel view instance. This is a parent view of a {@link #toolbar}
|
19
|
+
* that makes toolbar sticky.
|
20
|
+
*/
|
21
|
+
readonly stickyPanel: StickyPanelView;
|
22
|
+
/**
|
23
|
+
* Toolbar view instance.
|
24
|
+
*/
|
25
|
+
readonly toolbar: ToolbarView;
|
26
|
+
/**
|
27
|
+
* Editable UI view.
|
28
|
+
*/
|
29
|
+
readonly editable: InlineEditableUIView;
|
30
|
+
/**
|
31
|
+
* Creates an instance of the classic editor UI view.
|
32
|
+
*
|
33
|
+
* @param locale The {@link module:core/editor/editor~Editor#locale} instance.
|
34
|
+
* @param editingView The editing view instance this view is related to.
|
35
|
+
* @param options Configuration options for the view instance.
|
36
|
+
* @param options.shouldToolbarGroupWhenFull When set `true` enables automatic items grouping
|
37
|
+
* in the main {@link module:editor-classic/classiceditoruiview~ClassicEditorUIView#toolbar toolbar}.
|
38
|
+
* See {@link module:ui/toolbar/toolbarview~ToolbarOptions#shouldGroupWhenFull} to learn more.
|
39
|
+
*/
|
40
|
+
constructor(locale: Locale, editingView: EditingView, options?: {
|
41
|
+
shouldToolbarGroupWhenFull?: boolean;
|
42
|
+
});
|
43
|
+
/**
|
44
|
+
* @inheritDoc
|
45
|
+
*/
|
46
|
+
render(): void;
|
47
|
+
}
|
@@ -0,0 +1,8 @@
|
|
1
|
+
/**
|
2
|
+
* @license Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.
|
3
|
+
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
|
4
|
+
*/
|
5
|
+
/**
|
6
|
+
* @module editor-classic
|
7
|
+
*/
|
8
|
+
export { default as ClassicEditor } from './classiceditor.js';
|
package/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "@ckeditor/ckeditor5-editor-classic",
|
3
|
-
"version": "41.
|
3
|
+
"version": "41.3.0-alpha.0",
|
4
4
|
"description": "Classic editor implementation for CKEditor 5.",
|
5
5
|
"keywords": [
|
6
6
|
"ckeditor",
|
@@ -12,7 +12,7 @@
|
|
12
12
|
"type": "module",
|
13
13
|
"main": "src/index.js",
|
14
14
|
"dependencies": {
|
15
|
-
"ckeditor5": "41.
|
15
|
+
"ckeditor5": "41.3.0-alpha.0",
|
16
16
|
"lodash-es": "4.17.21"
|
17
17
|
},
|
18
18
|
"author": "CKSource (http://cksource.com/)",
|
@@ -25,6 +25,7 @@
|
|
25
25
|
"directory": "packages/ckeditor5-editor-classic"
|
26
26
|
},
|
27
27
|
"files": [
|
28
|
+
"dist",
|
28
29
|
"lang",
|
29
30
|
"src/**/*.js",
|
30
31
|
"src/**/*.d.ts",
|
package/src/classiceditor.d.ts
CHANGED
@@ -8,7 +8,7 @@
|
|
8
8
|
import ClassicEditorUI from './classiceditorui.js';
|
9
9
|
import { Editor, Context, type EditorConfig } from 'ckeditor5/src/core.js';
|
10
10
|
import { ContextWatchdog, EditorWatchdog } from 'ckeditor5/src/watchdog.js';
|
11
|
-
declare const ClassicEditor_base: import("ckeditor5/src/utils.js").Mixed<
|
11
|
+
declare const ClassicEditor_base: import("ckeditor5/src/utils.js").Mixed<typeof Editor, import("ckeditor5/src/core.js").ElementApi>;
|
12
12
|
/**
|
13
13
|
* The {@glink installation/getting-started/predefined-builds#classic-editor classic editor} implementation.
|
14
14
|
* It uses an inline editable and a sticky toolbar, all enclosed in a boxed UI.
|
package/src/classiceditor.js
CHANGED
@@ -7,7 +7,7 @@
|
|
7
7
|
*/
|
8
8
|
import ClassicEditorUI from './classiceditorui.js';
|
9
9
|
import ClassicEditorUIView from './classiceditoruiview.js';
|
10
|
-
import { Editor, Context,
|
10
|
+
import { Editor, Context, ElementApiMixin, attachToForm } from 'ckeditor5/src/core.js';
|
11
11
|
import { getDataFromElement, CKEditorError } from 'ckeditor5/src/utils.js';
|
12
12
|
import { ContextWatchdog, EditorWatchdog } from 'ckeditor5/src/watchdog.js';
|
13
13
|
import { isElement as _isElement } from 'lodash-es';
|
@@ -34,7 +34,7 @@ import { isElement as _isElement } from 'lodash-es';
|
|
34
34
|
* Read more about initializing the editor from source or as a build in
|
35
35
|
* {@link module:editor-classic/classiceditor~ClassicEditor.create `ClassicEditor.create()`}.
|
36
36
|
*/
|
37
|
-
class ClassicEditor extends
|
37
|
+
class ClassicEditor extends ElementApiMixin(Editor) {
|
38
38
|
/**
|
39
39
|
* Creates an instance of the classic editor.
|
40
40
|
*
|