@ckeditor/ckeditor5-engine
Advanced tools
Comparing version 31.1.0 to 32.0.0
@@ -5,3 +5,3 @@ Software License Agreement | ||
**CKEditor 5 editing engine** – https://github.com/ckeditor/ckeditor5-engine <br> | ||
Copyright (c) 2003-2021, [CKSource](http://cksource.com) Frederico Knabben. All rights reserved. | ||
Copyright (c) 2003-2022, [CKSource](http://cksource.com) Holding sp. z o.o. All rights reserved. | ||
@@ -18,2 +18,2 @@ Licensed under the terms of [GNU General Public License Version 2 or later](http://www.gnu.org/licenses/gpl.html). | ||
**CKEditor** is a trademark of [CKSource](http://cksource.com) Frederico Knabben. All other brand and product names are trademarks, registered trademarks or service marks of their respective holders. | ||
**CKEditor** is a trademark of [CKSource](http://cksource.com) Holding sp. z o.o. All other brand and product names are trademarks, registered trademarks or service marks of their respective holders. |
{ | ||
"name": "@ckeditor/ckeditor5-engine", | ||
"version": "31.1.0", | ||
"version": "32.0.0", | ||
"description": "The editing engine of CKEditor 5 – the best browser-based rich text editor.", | ||
@@ -26,31 +26,31 @@ "keywords": [ | ||
"dependencies": { | ||
"@ckeditor/ckeditor5-utils": "^31.1.0", | ||
"@ckeditor/ckeditor5-utils": "^32.0.0", | ||
"lodash-es": "^4.17.15" | ||
}, | ||
"devDependencies": { | ||
"@ckeditor/ckeditor5-basic-styles": "^31.1.0", | ||
"@ckeditor/ckeditor5-block-quote": "^31.1.0", | ||
"@ckeditor/ckeditor5-clipboard": "^31.1.0", | ||
"@ckeditor/ckeditor5-cloud-services": "^31.1.0", | ||
"@ckeditor/ckeditor5-core": "^31.1.0", | ||
"@ckeditor/ckeditor5-editor-classic": "^31.1.0", | ||
"@ckeditor/ckeditor5-enter": "^31.1.0", | ||
"@ckeditor/ckeditor5-essentials": "^31.1.0", | ||
"@ckeditor/ckeditor5-heading": "^31.1.0", | ||
"@ckeditor/ckeditor5-image": "^31.1.0", | ||
"@ckeditor/ckeditor5-link": "^31.1.0", | ||
"@ckeditor/ckeditor5-list": "^31.1.0", | ||
"@ckeditor/ckeditor5-mention": "^31.1.0", | ||
"@ckeditor/ckeditor5-paragraph": "^31.1.0", | ||
"@ckeditor/ckeditor5-table": "^31.1.0", | ||
"@ckeditor/ckeditor5-theme-lark": "^31.1.0", | ||
"@ckeditor/ckeditor5-typing": "^31.1.0", | ||
"@ckeditor/ckeditor5-ui": "^31.1.0", | ||
"@ckeditor/ckeditor5-undo": "^31.1.0", | ||
"@ckeditor/ckeditor5-widget": "^31.1.0", | ||
"webpack": "^4.43.0", | ||
"webpack-cli": "^3.3.11" | ||
"@ckeditor/ckeditor5-basic-styles": "^32.0.0", | ||
"@ckeditor/ckeditor5-block-quote": "^32.0.0", | ||
"@ckeditor/ckeditor5-clipboard": "^32.0.0", | ||
"@ckeditor/ckeditor5-cloud-services": "^32.0.0", | ||
"@ckeditor/ckeditor5-core": "^32.0.0", | ||
"@ckeditor/ckeditor5-editor-classic": "^32.0.0", | ||
"@ckeditor/ckeditor5-enter": "^32.0.0", | ||
"@ckeditor/ckeditor5-essentials": "^32.0.0", | ||
"@ckeditor/ckeditor5-heading": "^32.0.0", | ||
"@ckeditor/ckeditor5-image": "^32.0.0", | ||
"@ckeditor/ckeditor5-link": "^32.0.0", | ||
"@ckeditor/ckeditor5-list": "^32.0.0", | ||
"@ckeditor/ckeditor5-mention": "^32.0.0", | ||
"@ckeditor/ckeditor5-paragraph": "^32.0.0", | ||
"@ckeditor/ckeditor5-table": "^32.0.0", | ||
"@ckeditor/ckeditor5-theme-lark": "^32.0.0", | ||
"@ckeditor/ckeditor5-typing": "^32.0.0", | ||
"@ckeditor/ckeditor5-ui": "^32.0.0", | ||
"@ckeditor/ckeditor5-undo": "^32.0.0", | ||
"@ckeditor/ckeditor5-widget": "^32.0.0", | ||
"webpack": "^5.58.1", | ||
"webpack-cli": "^4.9.0" | ||
}, | ||
"engines": { | ||
"node": ">=12.0.0", | ||
"node": ">=14.0.0", | ||
"npm": ">=5.7.1" | ||
@@ -57,0 +57,0 @@ }, |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -159,3 +159,3 @@ */ | ||
this.on( 'ready', () => { | ||
this.model.enqueueChange( 'transparent', autoParagraphEmptyRoots ); | ||
this.model.enqueueChange( { isUndoable: false }, autoParagraphEmptyRoots ); | ||
}, { priority: 'lowest' } ); | ||
@@ -327,3 +327,3 @@ } | ||
this.model.enqueueChange( 'transparent', writer => { | ||
this.model.enqueueChange( { isUndoable: false }, writer => { | ||
for ( const rootName of Object.keys( initialData ) ) { | ||
@@ -355,5 +355,5 @@ const modelRoot = this.model.document.getRoot( rootName ); | ||
* | ||
* To set the data with preserved undo stacks and set the current change to this stack, use the `{ batchType: 'default' }` option. | ||
* To set the data with preserved undo stack and add the change to the undo stack, set `{ isUndoable: true }` as `batchType` option. | ||
* | ||
* dataController.set( '<p>Foo</p>', { batchType: 'default' } ); // Sets data as a new change. | ||
* dataController.set( '<p>Foo</p>', { batchType: { isUndoable: true } } ); | ||
* | ||
@@ -364,5 +364,6 @@ * @fires set | ||
* @param {Object} [options={}] Options for setting data. | ||
* @param {'default'|'transparent'} [options.batchType='default'] The batch type that will be used to create a batch for the changes. | ||
* When set to `default`, the undo and redo stacks will be preserved. Note that when not set, the undo feature (when present) will | ||
* override it to `transparent` and all undo steps will be lost. | ||
* @param {Object} [options.batchType] The batch type that will be used to create a batch for the changes applied by this method. | ||
* By default, the batch will be set as {@link module:engine/model/batch~Batch#isUndoable not undoable} and the undo stack will be | ||
* cleared after the new data is applied (all undo steps will be removed). If batch type `isUndoable` flag will be set to `true`, | ||
* the undo stack will be preserved. | ||
*/ | ||
@@ -393,5 +394,3 @@ set( data, options = {} ) { | ||
const batchType = options.batchType || 'default'; | ||
this.model.enqueueChange( batchType, writer => { | ||
this.model.enqueueChange( options.batchType || {}, writer => { | ||
writer.setSelection( null ); | ||
@@ -398,0 +397,0 @@ writer.removeSelectionAttribute( this.model.document.selection.getAttributeKeys() ); |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -10,3 +10,3 @@ */ | ||
/* globals document, DOMParser, Node */ | ||
/* globals document, DOMParser */ | ||
@@ -118,33 +118,11 @@ import BasicHtmlWriter from './basichtmlwriter'; | ||
_toDom( data ) { | ||
// Wrap data with a <body> so leading non-layout nodes (like <script>, <style>, HTML comment) | ||
// will be preserved in the body collection. | ||
// Do it only for data that is not a full HTML document. | ||
if ( !data.match( /<(?:html|body|head|meta)(?:\s[^>]*)?>/i ) ) { | ||
data = `<body>${ data }</body>`; | ||
} | ||
const document = this.domParser.parseFromString( data, 'text/html' ); | ||
const fragment = document.createDocumentFragment(); | ||
// The rules for parsing an HTML string can be read on https://html.spec.whatwg.org/multipage/parsing.html#parsing-main-inhtml. | ||
// | ||
// In short, parsing tokens in an HTML string starts with the so-called "initial" insertion mode. When a DOM parser is in this | ||
// state and encounters a comment node, it inserts this comment node as the last child of the newly-created `HTMLDocument` object. | ||
// The parser then proceeds to successive insertion modes during parsing subsequent tokens and appends in the `HTMLDocument` object | ||
// other nodes (like <html>, <head>, <body>). This causes that the first leading comments from HTML string become the first nodes | ||
// in the `HTMLDocument` object, but not in the <body> collection, because they are ultimately located before the <html> element. | ||
// | ||
// Therefore, so that such leading comments do not disappear, they all are moved from the `HTMLDocument` object to the document | ||
// fragment, until the <html> element is encountered. | ||
// | ||
// See: https://github.com/ckeditor/ckeditor5/issues/9861. | ||
let documentChildNode = document.firstChild; | ||
while ( !documentChildNode.isSameNode( document.documentElement ) ) { | ||
const node = documentChildNode; | ||
documentChildNode = documentChildNode.nextSibling; | ||
// It seems that `DOMParser#parseFromString()` adds only comment nodes directly to the `HTMLDocument` object, before the <html> | ||
// node. The condition below is just to be sure we are moving only comment nodes. | ||
/* istanbul ignore else */ | ||
if ( node.nodeType == Node.COMMENT_NODE ) { | ||
fragment.appendChild( node ); | ||
} | ||
} | ||
const bodyChildNodes = document.body.childNodes; | ||
@@ -151,0 +129,0 @@ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -105,3 +105,3 @@ */ | ||
* @param {Boolean} [options.lastRangeBackward=false] If set to `true`, the last range will be added as backward. | ||
* @param {String} [options.batchType='default'] Batch type used for inserting elements. | ||
* @param {Object} [options.batchType] Batch type used for inserting elements. See {@link module:engine/model/batch~Batch#constructor}. | ||
* See {@link module:engine/model/batch~Batch#type}. | ||
@@ -132,3 +132,3 @@ */ | ||
if ( typeof options.batchType === 'string' ) { | ||
if ( options.batchType !== undefined ) { | ||
model.enqueueChange( options.batchType, writeToModel ); | ||
@@ -135,0 +135,0 @@ } else { |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -10,2 +10,4 @@ */ | ||
import { logWarning } from '@ckeditor/ckeditor5-utils/src/ckeditorerror'; | ||
/** | ||
@@ -29,5 +31,26 @@ * A batch instance groups model changes ({@link module:engine/model/operation/operation~Operation operations}). All operations | ||
* @see module:engine/model/model~Model#change | ||
* @param {'transparent'|'default'} [type='default'] The type of the batch. | ||
* @param {Object} [type] Set of flags that specifies the type of the batch. Batch type can alter how some of the features work when | ||
* encountering given `Batch` instance (for example, when a feature listens to applied operations). | ||
* @param {Boolean} [type.isUndoable=true] Whether batch can be undone through undo feature. | ||
* @param {Boolean} [type.isLocal=true] Whether batch includes operations created locally (`true`) or operations created on | ||
* other, remote editors (`false`). | ||
* @param {Boolean} [type.isUndo=false] Whether batch was created by the undo feature and undoes other operations. | ||
* @param {Boolean} [type.isTyping=false] Whether batch includes operations connected with typing action. | ||
*/ | ||
constructor( type = 'default' ) { | ||
constructor( type = {} ) { | ||
if ( typeof type === 'string' ) { | ||
type = type === 'transparent' ? { isUndoable: false } : {}; | ||
/** | ||
* The string value for `type` property of the `Batch` constructor has been deprecated and will be removed in the near future. | ||
* Please refer to the {@link module:engine/model/batch~Batch#constructor `Batch` constructor API documentation} for more | ||
* information. | ||
* | ||
* @error batch-constructor-deprecated-string-type | ||
*/ | ||
logWarning( 'batch-constructor-deprecated-string-type' ); | ||
} | ||
const { isUndoable = true, isLocal = true, isUndo = false, isTyping = false } = type; | ||
/** | ||
@@ -42,16 +65,60 @@ * An array of operations that compose this batch. | ||
/** | ||
* The type of the batch. | ||
* Whether batch can be undone through the undo feature. | ||
* | ||
* It can be one of the following values: | ||
* * `'default'` – All "normal" batches. This is the most commonly used type. | ||
* * `'transparent'` – A batch that should be ignored by other features, i.e. an initial batch or collaborative editing | ||
* changes. | ||
* @readonly | ||
* @type {Boolean} | ||
*/ | ||
this.isUndoable = isUndoable; | ||
/** | ||
* Whether batch includes operations created locally (`true`) or operations created on other, remote editors (`false`). | ||
* | ||
* @readonly | ||
* @type {'transparent'|'default'} | ||
* @type {Boolean} | ||
*/ | ||
this.type = type; | ||
this.isLocal = isLocal; | ||
/** | ||
* Whether batch was created by the undo feature and undoes other operations. | ||
* | ||
* @readonly | ||
* @type {Boolean} | ||
*/ | ||
this.isUndo = isUndo; | ||
/** | ||
* Whether batch includes operations connected with typing. | ||
* | ||
* @readonly | ||
* @type {Boolean} | ||
*/ | ||
this.isTyping = isTyping; | ||
} | ||
/** | ||
* The type of the batch. | ||
* | ||
* **This property has been deprecated and is always set to `'default'` value.** | ||
* | ||
* It can be one of the following values: | ||
* * `'default'` – All "normal" batches. This is the most commonly used type. | ||
* * `'transparent'` – A batch that should be ignored by other features, i.e. an initial batch or collaborative editing | ||
* changes. | ||
* | ||
* @deprecated | ||
* @type {'default'} | ||
*/ | ||
get type() { | ||
/** | ||
* The {@link module:engine/model/batch~Batch#type `Batch#type` } property has been deprecated and will be removed in the near | ||
* future. Use `Batch#isLocal`, `Batch#isUndoable`, `Batch#isUndo` and `Batch#isTyping` instead. | ||
* | ||
* @error batch-type-deprecated | ||
*/ | ||
logWarning( 'batch-type-deprecated' ); | ||
return 'default'; | ||
} | ||
/** | ||
* Returns the base version of this batch, which is equal to the base version of the first operation in the batch. | ||
@@ -58,0 +125,0 @@ * If there are no operations in the batch or neither operation has the base version set, it returns `null`. |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -217,5 +217,10 @@ */ | ||
* Second, it lets you define the {@link module:engine/model/batch~Batch} into which you want to add your changes. | ||
* By default, a new batch is created. In the sample above, `change` and `enqueueChange` blocks use a different | ||
* batch (and different {@link module:engine/model/writer~Writer} since each of them operates on the separate batch). | ||
* By default, a new batch with the default {@link module:engine/model/batch~Batch#constructor batch type} is created. | ||
* In the sample above, `change` and `enqueueChange` blocks will use a different batch (and a different | ||
* {@link module:engine/model/writer~Writer} instance since each of them operates on a separate batch). | ||
* | ||
* model.enqueueChange( { isUndoable: false }, writer => { | ||
* writer.insertText( 'foo', paragraph, 'end' ); | ||
* } ); | ||
* | ||
* When using the `enqueueChange()` block you can also add some changes to the batch you used before. | ||
@@ -230,4 +235,5 @@ * | ||
* | ||
* @param {module:engine/model/batch~Batch|'transparent'|'default'} batchOrType Batch or batch type should be used in the callback. | ||
* If not defined, a new batch will be created. | ||
* @param {module:engine/model/batch~Batch|Object} [batchOrType] A batch or a | ||
* {@link module:engine/model/batch~Batch#constructor batch type} that should be used in the callback. If not defined, a new batch with | ||
* the default type will be created. | ||
* @param {Function} callback Callback function which may modify the model. | ||
@@ -237,7 +243,9 @@ */ | ||
try { | ||
if ( typeof batchOrType === 'string' ) { | ||
batchOrType = new Batch( batchOrType ); | ||
} else if ( typeof batchOrType == 'function' ) { | ||
if ( !batchOrType ) { | ||
batchOrType = new Batch(); | ||
} else if ( typeof batchOrType === 'function' ) { | ||
callback = batchOrType; | ||
batchOrType = new Batch(); | ||
} else if ( !( batchOrType instanceof Batch ) ) { | ||
batchOrType = new Batch( batchOrType ); | ||
} | ||
@@ -797,3 +805,3 @@ | ||
* | ||
* @param {'transparent'|'default'} [type='default'] The type of the batch. | ||
* @param {Object} [type] {@link module:engine/model/batch~Batch#constructor The type} of the batch. | ||
* @returns {module:engine/model/batch~Batch} | ||
@@ -800,0 +808,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -31,2 +31,3 @@ */ | ||
import isText from '@ckeditor/ckeditor5-utils/src/dom/istext'; | ||
import isComment from '@ckeditor/ckeditor5-utils/src/dom/iscomment'; | ||
@@ -428,4 +429,4 @@ const BR_FILLER_REF = BR_FILLER( document ); // eslint-disable-line new-cap | ||
* @param {HTMLElement} domElement The DOM element the attribute should be set on. | ||
* @param {String} key The name of the attribute | ||
* @param {String} value The value of the attribute | ||
* @param {String} key The name of the attribute. | ||
* @param {String} value The value of the attribute. | ||
* @param {module:engine/view/element~Element} [relatedViewElement] The view element related to the `domElement` (if there is any). | ||
@@ -622,3 +623,3 @@ * It helps decide whether the attribute set is unsafe. For instance, view elements created via | ||
if ( this.isComment( domNode ) && options.skipComments ) { | ||
if ( isComment( domNode ) && options.skipComments ) { | ||
return null; | ||
@@ -668,4 +669,4 @@ } | ||
// Comment node is also treated as an element with raw data. | ||
if ( this._isViewElementWithRawContent( viewElement, options ) || this.isComment( domNode ) ) { | ||
const rawContent = this.isComment( domNode ) ? domNode.data : domNode.innerHTML; | ||
if ( this._isViewElementWithRawContent( viewElement, options ) || isComment( domNode ) ) { | ||
const rawContent = isComment( domNode ) ? domNode.data : domNode.innerHTML; | ||
@@ -1040,12 +1041,2 @@ viewElement._setCustomProperty( '$rawContent', rawContent ); | ||
/** | ||
* Returns `true` when `node.nodeType` equals `Node.COMMENT_NODE`. | ||
* | ||
* @param {Node} node Node to check. | ||
* @returns {Boolean} | ||
*/ | ||
isComment( node ) { | ||
return node && node.nodeType == Node.COMMENT_NODE; | ||
} | ||
/** | ||
* Checks if the node is an instance of the block filler for this DOM converter. | ||
@@ -1534,3 +1525,3 @@ * | ||
_createViewElement( node, options ) { | ||
if ( this.isComment( node ) ) { | ||
if ( isComment( node ) ) { | ||
return new ViewUIElement( this.document, '$comment' ); | ||
@@ -1537,0 +1528,0 @@ } |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -5,0 +5,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md. | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -23,2 +23,3 @@ */ | ||
import isText from '@ckeditor/ckeditor5-utils/src/dom/istext'; | ||
import isComment from '@ckeditor/ckeditor5-utils/src/dom/iscomment'; | ||
import isNode from '@ckeditor/ckeditor5-utils/src/dom/isnode'; | ||
@@ -993,3 +994,3 @@ import fastDiff from '@ckeditor/ckeditor5-utils/src/fastdiff'; | ||
!isText( node1 ) && !isText( node2 ) && | ||
node1.nodeType !== Node.COMMENT_NODE && node2.nodeType !== Node.COMMENT_NODE && | ||
!isComment( node1 ) && !isComment( node2 ) && | ||
node1.tagName.toLowerCase() === node2.tagName.toLowerCase(); | ||
@@ -996,0 +997,0 @@ } |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
/** | ||
* @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved. | ||
* @license Copyright (c) 2003-2022, CKSource Holding sp. z o.o. All rights reserved. | ||
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license | ||
@@ -4,0 +4,0 @@ */ |
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
1759715
41938
+ Added@ckeditor/ckeditor5-utils@32.0.0(transitive)
- Removed@ckeditor/ckeditor5-utils@31.1.0(transitive)