Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

draft-js-plugins-editor

Package Overview
Dependencies
Maintainers
2
Versions
36
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

draft-js-plugins-editor - npm Package Compare versions

Comparing version 2.1.0 to 2.1.1

yarn-error.log

3

CHANGELOG.md

@@ -6,2 +6,5 @@ # Change Log

## 2.1.1
- Use only part of RichUtils.handleKeyCommand, since we don't want to automatically assume that code, bold, italic and the likes are included in an editor
## 2.1.0

@@ -8,0 +11,0 @@ - Add defaultKeyCommands

@@ -10,6 +10,22 @@ 'use strict';

exports.default = {
// handle delete commands
handleKeyCommand: function handleKeyCommand(command, editorState, _ref) {
var setEditorState = _ref.setEditorState;
var newState = _draftJs.RichUtils.handleKeyCommand(editorState, command);
var newState = void 0;
switch (command) {
case 'backspace':
case 'backspace-word':
case 'backspace-to-start-of-line':
newState = _draftJs.RichUtils.onBackspace(editorState);
break;
case 'delete':
case 'delete-word':
case 'delete-to-end-of-block':
newState = _draftJs.RichUtils.onDelete(editorState);
break;
default:
return 'not-handled';
}
if (newState != null) {

@@ -19,4 +35,5 @@ setEditorState(newState);

}
return 'not-handled';
}
};

2

package.json
{
"name": "draft-js-plugins-editor",
"version": "2.1.0",
"version": "2.1.1",
"description": "Editor for DraftJS Plugins",

@@ -5,0 +5,0 @@ "author": {

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc