@ckeditor/ckeditor5-undo
Advanced tools
Comparing version 28.0.0 to 29.0.0
{ | ||
"name": "@ckeditor/ckeditor5-undo", | ||
"version": "28.0.0", | ||
"version": "29.0.0", | ||
"description": "Undo manager for CKEditor 5.", | ||
@@ -15,16 +15,16 @@ "keywords": [ | ||
"dependencies": { | ||
"@ckeditor/ckeditor5-core": "^28.0.0", | ||
"@ckeditor/ckeditor5-engine": "^28.0.0", | ||
"@ckeditor/ckeditor5-ui": "^28.0.0" | ||
"@ckeditor/ckeditor5-core": "^29.0.0", | ||
"@ckeditor/ckeditor5-engine": "^29.0.0", | ||
"@ckeditor/ckeditor5-ui": "^29.0.0" | ||
}, | ||
"devDependencies": { | ||
"@ckeditor/ckeditor5-basic-styles": "^28.0.0", | ||
"@ckeditor/ckeditor5-clipboard": "^28.0.0", | ||
"@ckeditor/ckeditor5-editor-classic": "^28.0.0", | ||
"@ckeditor/ckeditor5-enter": "^28.0.0", | ||
"@ckeditor/ckeditor5-heading": "^28.0.0", | ||
"@ckeditor/ckeditor5-paragraph": "^28.0.0", | ||
"@ckeditor/ckeditor5-typing": "^28.0.0", | ||
"@ckeditor/ckeditor5-table": "^28.0.0", | ||
"@ckeditor/ckeditor5-utils": "^28.0.0" | ||
"@ckeditor/ckeditor5-basic-styles": "^29.0.0", | ||
"@ckeditor/ckeditor5-clipboard": "^29.0.0", | ||
"@ckeditor/ckeditor5-editor-classic": "^29.0.0", | ||
"@ckeditor/ckeditor5-enter": "^29.0.0", | ||
"@ckeditor/ckeditor5-heading": "^29.0.0", | ||
"@ckeditor/ckeditor5-paragraph": "^29.0.0", | ||
"@ckeditor/ckeditor5-typing": "^29.0.0", | ||
"@ckeditor/ckeditor5-table": "^29.0.0", | ||
"@ckeditor/ckeditor5-utils": "^29.0.0" | ||
}, | ||
@@ -31,0 +31,0 @@ "engines": { |
@@ -5,4 +5,4 @@ CKEditor 5 undo feature | ||
[![npm version](https://badge.fury.io/js/%40ckeditor%2Fckeditor5-undo.svg)](https://www.npmjs.com/package/@ckeditor/ckeditor5-undo) | ||
[![Dependency Status](https://david-dm.org/ckeditor/ckeditor5-undo/status.svg)](https://david-dm.org/ckeditor/ckeditor5-undo) | ||
[![devDependency Status](https://david-dm.org/ckeditor/ckeditor5-undo/dev-status.svg)](https://david-dm.org/ckeditor/ckeditor5-undo?type=dev) | ||
[![Coverage Status](https://coveralls.io/repos/github/ckeditor/ckeditor5/badge.svg?branch=master)](https://coveralls.io/github/ckeditor/ckeditor5?branch=master) | ||
[![Build Status](https://travis-ci.com/ckeditor/ckeditor5.svg?branch=master)](https://travis-ci.com/ckeditor/ckeditor5) | ||
@@ -9,0 +9,0 @@ This package implements undo support for CKEditor 5. |
@@ -45,3 +45,28 @@ /** | ||
this.listenTo( editor.data, 'set', () => this.clearStack() ); | ||
// Set the transparent batch for the `editor.data.set()` call if the | ||
// batch type is not set already. | ||
this.listenTo( editor.data, 'set', ( evt, data ) => { | ||
// Create a shallow copy of the options to not change the original args. | ||
// And make sure that an object is assigned to data[ 1 ]. | ||
data[ 1 ] = { ...data[ 1 ] }; | ||
const options = data[ 1 ]; | ||
if ( options.batchType ) { | ||
return; | ||
} | ||
options.batchType = 'transparent'; | ||
}, { priority: 'high' } ); | ||
// Clear the stack for the `transparent` batches. | ||
this.listenTo( editor.data, 'set', ( evt, data ) => { | ||
// We can assume that the object exists - it was ensured | ||
// with the high priority listener before. | ||
const options = data[ 1 ]; | ||
if ( options.batchType === 'transparent' ) { | ||
this.clearStack(); | ||
} | ||
} ); | ||
} | ||
@@ -48,0 +73,0 @@ |
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
90208
573
+ Added@ckeditor/ckeditor5-clipboard@29.2.0(transitive)
+ Added@ckeditor/ckeditor5-core@29.2.0(transitive)
+ Added@ckeditor/ckeditor5-engine@29.2.0(transitive)
+ Added@ckeditor/ckeditor5-enter@29.2.0(transitive)
+ Added@ckeditor/ckeditor5-paragraph@29.2.0(transitive)
+ Added@ckeditor/ckeditor5-select-all@29.2.0(transitive)
+ Added@ckeditor/ckeditor5-typing@29.2.0(transitive)
+ Added@ckeditor/ckeditor5-ui@29.2.0(transitive)
+ Added@ckeditor/ckeditor5-undo@29.2.0(transitive)
+ Added@ckeditor/ckeditor5-upload@29.2.0(transitive)
+ Added@ckeditor/ckeditor5-utils@29.2.0(transitive)
+ Added@ckeditor/ckeditor5-widget@29.2.0(transitive)
+ Addedckeditor5@29.2.0(transitive)
- Removed@ckeditor/ckeditor5-clipboard@28.0.0(transitive)
- Removed@ckeditor/ckeditor5-core@28.0.0(transitive)
- Removed@ckeditor/ckeditor5-engine@28.0.0(transitive)
- Removed@ckeditor/ckeditor5-enter@28.0.0(transitive)
- Removed@ckeditor/ckeditor5-paragraph@28.0.0(transitive)
- Removed@ckeditor/ckeditor5-select-all@28.0.0(transitive)
- Removed@ckeditor/ckeditor5-typing@28.0.0(transitive)
- Removed@ckeditor/ckeditor5-ui@28.0.0(transitive)
- Removed@ckeditor/ckeditor5-upload@28.0.0(transitive)
- Removed@ckeditor/ckeditor5-utils@28.0.0(transitive)
- Removed@ckeditor/ckeditor5-widget@28.0.0(transitive)
- Removedckeditor5@28.0.0(transitive)