Verified Commit fd41a57a authored by Dave Long's avatar Dave Long
Browse files

fix: #3591974 Update import paths for CKEditor 5 v48

By: pameeela
By: godotislate
By: smustgrave
By: longwave
By: amitgoyal
parent 22c7a860
Loading
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
!function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t(require("CKEDITOR")):"function"==typeof define&&define.amd?define(["CKEDITOR"],t):"object"==typeof exports?exports.CKEditor5=t(require("CKEDITOR")):(e.CKEditor5=e.CKEditor5||{},e.CKEditor5.drupalEmphasis=t(e.CKEDITOR))}(globalThis,(e=>(()=>{"use strict";var t={"ckeditor5/src/core":t=>{t.exports=e}},r={};function o(e){var i=r[e];if(void 0!==i)return i.exports;var s=r[e]={exports:{}};return t[e](s,s.exports,o),s.exports}o.d=(e,t)=>{for(var r in t)o.o(t,r)&&!o.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:t[r]})},o.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t);var i={};o.d(i,{default:()=>p});var s=o("ckeditor5/src/core");class n extends s.Plugin{static get pluginName(){return"DrupalEmphasisEditing"}init(){this.editor.conversion.for("downcast").attributeToElement({model:"italic",view:"em",converterPriority:"high"})}}const a=n;class c extends s.Plugin{static get requires(){return[a]}static get pluginName(){return"DrupalEmphasis"}}const p={DrupalEmphasis:c};return i=i.default})()));
 No newline at end of file
!function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t(require("CKEDITOR")):"function"==typeof define&&define.amd?define(["CKEDITOR"],t):"object"==typeof exports?exports.CKEditor5=t(require("CKEDITOR")):(e.CKEditor5=e.CKEditor5||{},e.CKEditor5.drupalEmphasis=t(e.CKEDITOR))}(globalThis,(e=>(()=>{"use strict";var t={ckeditor5:t=>{t.exports=e}},r={};function o(e){var i=r[e];if(void 0!==i)return i.exports;var s=r[e]={exports:{}};return t[e](s,s.exports,o),s.exports}o.d=(e,t)=>{for(var r in t)o.o(t,r)&&!o.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:t[r]})},o.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t);var i={};o.d(i,{default:()=>u});var s=o("ckeditor5");class n extends s.Plugin{static get pluginName(){return"DrupalEmphasisEditing"}init(){this.editor.conversion.for("downcast").attributeToElement({model:"italic",view:"em",converterPriority:"high"})}}const a=n;class p extends s.Plugin{static get requires(){return[a]}static get pluginName(){return"DrupalEmphasis"}}const u={DrupalEmphasis:p};return i=i.default})()));
 No newline at end of file
+1 −1
Original line number Diff line number Diff line
!function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t(require("CKEDITOR")):"function"==typeof define&&define.amd?define(["CKEDITOR"],t):"object"==typeof exports?exports.CKEditor5=t(require("CKEDITOR")):(e.CKEditor5=e.CKEditor5||{},e.CKEditor5.drupalHtmlEngine=t(e.CKEDITOR))}(globalThis,(e=>(()=>{"use strict";var t={"ckeditor5/src/core":t=>{t.exports=e}},n={};function p(e){var r=n[e];if(void 0!==r)return r.exports;var a=n[e]={exports:{}};return t[e](a,a.exports,p),a.exports}p.d=(e,t)=>{for(var n in t)p.o(t,n)&&!p.o(e,n)&&Object.defineProperty(e,n,{enumerable:!0,get:t[n]})},p.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t);var r={};p.d(r,{default:()=>d});var a=p("ckeditor5/src/core");class s{constructor(){this.chunks=[],this.selfClosingTags=["area","base","br","col","embed","hr","img","input","link","meta","param","source","track","wbr"],this.rawTags=["script","style"]}build(){return this.chunks.join("")}appendNode(e){e.nodeType===Node.TEXT_NODE?this._appendText(e):e.nodeType===Node.ELEMENT_NODE?this._appendElement(e):e.nodeType===Node.DOCUMENT_FRAGMENT_NODE?this._appendChildren(e):e.nodeType===Node.COMMENT_NODE&&this._appendComment(e)}_appendElement(e){const t=e.nodeName.toLowerCase();this._append("<"),this._append(t),this._appendAttributes(e),this._append(">"),this.selfClosingTags.includes(t)||(this._appendChildren(e),this._append("</"),this._append(t),this._append(">"))}_appendChildren(e){Object.keys(e.childNodes).forEach((t=>{this.appendNode(e.childNodes[t])}))}_appendAttributes(e){Object.keys(e.attributes).forEach((t=>{this._append(" "),this._append(e.attributes[t].name),this._append('="'),this._append(this.constructor._escapeAttribute(e.attributes[t].value)),this._append('"')}))}_appendText(e){const t=document.implementation.createHTMLDocument("").createElement("p");t.textContent=e.textContent,e.parentElement&&this.rawTags.includes(e.parentElement.tagName.toLowerCase())?this._append(t.textContent):this._append(t.innerHTML)}_appendComment(e){this._append("\x3c!--"),this._append(e.textContent),this._append("--\x3e")}_append(e){this.chunks.push(e)}static _escapeAttribute(e){return e.replace(/&/g,"&amp;").replace(/'/g,"&apos;").replace(/"/g,"&quot;").replace(/</g,"&lt;").replace(/>/g,"&gt;").replace(/\r\n/g,"&#13;").replace(/[\r\n]/g,"&#13;")}}class i{getHtml(e){const t=new s;return t.appendNode(e),t.build()}}class o extends a.Plugin{init(){this.editor.data.processor.htmlWriter=new i}static get pluginName(){return"DrupalHtmlEngine"}}const d={DrupalHtmlEngine:o};return r=r.default})()));
 No newline at end of file
!function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t(require("CKEDITOR")):"function"==typeof define&&define.amd?define(["CKEDITOR"],t):"object"==typeof exports?exports.CKEditor5=t(require("CKEDITOR")):(e.CKEditor5=e.CKEditor5||{},e.CKEditor5.drupalHtmlEngine=t(e.CKEDITOR))}(globalThis,(e=>(()=>{"use strict";var t={ckeditor5:t=>{t.exports=e}},n={};function p(e){var r=n[e];if(void 0!==r)return r.exports;var a=n[e]={exports:{}};return t[e](a,a.exports,p),a.exports}p.d=(e,t)=>{for(var n in t)p.o(t,n)&&!p.o(e,n)&&Object.defineProperty(e,n,{enumerable:!0,get:t[n]})},p.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t);var r={};p.d(r,{default:()=>d});var a=p("ckeditor5");class s{constructor(){this.chunks=[],this.selfClosingTags=["area","base","br","col","embed","hr","img","input","link","meta","param","source","track","wbr"],this.rawTags=["script","style"]}build(){return this.chunks.join("")}appendNode(e){e.nodeType===Node.TEXT_NODE?this._appendText(e):e.nodeType===Node.ELEMENT_NODE?this._appendElement(e):e.nodeType===Node.DOCUMENT_FRAGMENT_NODE?this._appendChildren(e):e.nodeType===Node.COMMENT_NODE&&this._appendComment(e)}_appendElement(e){const t=e.nodeName.toLowerCase();this._append("<"),this._append(t),this._appendAttributes(e),this._append(">"),this.selfClosingTags.includes(t)||(this._appendChildren(e),this._append("</"),this._append(t),this._append(">"))}_appendChildren(e){Object.keys(e.childNodes).forEach((t=>{this.appendNode(e.childNodes[t])}))}_appendAttributes(e){Object.keys(e.attributes).forEach((t=>{this._append(" "),this._append(e.attributes[t].name),this._append('="'),this._append(this.constructor._escapeAttribute(e.attributes[t].value)),this._append('"')}))}_appendText(e){const t=document.implementation.createHTMLDocument("").createElement("p");t.textContent=e.textContent,e.parentElement&&this.rawTags.includes(e.parentElement.tagName.toLowerCase())?this._append(t.textContent):this._append(t.innerHTML)}_appendComment(e){this._append("\x3c!--"),this._append(e.textContent),this._append("--\x3e")}_append(e){this.chunks.push(e)}static _escapeAttribute(e){return e.replace(/&/g,"&amp;").replace(/'/g,"&apos;").replace(/"/g,"&quot;").replace(/</g,"&lt;").replace(/>/g,"&gt;").replace(/\r\n/g,"&#13;").replace(/[\r\n]/g,"&#13;")}}class i{getHtml(e){const t=new s;return t.appendNode(e),t.build()}}class o extends a.Plugin{init(){this.editor.data.processor.htmlWriter=new i}static get pluginName(){return"DrupalHtmlEngine"}}const d={DrupalHtmlEngine:o};return r=r.default})()));
 No newline at end of file
+1 −1

File changed.

Preview size limit exceeded, changes collapsed.

+1 −1

File changed.

Preview size limit exceeded, changes collapsed.

+1 −1
Original line number Diff line number Diff line
/* eslint-disable import/no-extraneous-dependencies */
// cspell:ignore drupalemphasisediting

import { Plugin } from 'ckeditor5/src/core';
import { Plugin } from 'ckeditor5';
import DrupalEmphasisEditing from './drupalemphasisediting';

/**
Loading