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

quill-delta

Package Overview
Dependencies
Maintainers
1
Versions
19
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

quill-delta - npm Package Compare versions

Comparing version 4.0.1 to 4.1.0

4

CHANGELOG.md

@@ -0,1 +1,5 @@

## v4.1.0
- Use fast-diff 1.2.0 in `diff()`, so that diffs do not split Unicode surrogate pairs
## v4.0.1

@@ -2,0 +6,0 @@

3

dist/Delta.d.ts

@@ -0,1 +1,2 @@

import diff from 'fast-diff';
import AttributeMap from './AttributeMap';

@@ -25,3 +26,3 @@ import Op from './Op';

concat(other: Delta): Delta;
diff(other: Delta, index?: number): Delta;
diff(other: Delta, cursor?: number | diff.CursorInfo): Delta;
eachLine(predicate: (line: Delta, attributes: AttributeMap, index: number) => boolean | void, newline?: string): void;

@@ -28,0 +29,0 @@ transform(index: number, priority?: boolean): number;

@@ -234,3 +234,3 @@ "use strict";

};
Delta.prototype.diff = function (other, index) {
Delta.prototype.diff = function (other, cursor) {
if (this.ops === other.ops) {

@@ -251,3 +251,3 @@ return new Delta();

var retDelta = new Delta();
var diffResult = fast_diff_1.default(strings[0], strings[1], index);
var diffResult = fast_diff_1.default(strings[0], strings[1], cursor);
var thisIter = Op_1.default.iterator(this.ops);

@@ -254,0 +254,0 @@ var otherIter = Op_1.default.iterator(other.ops);

{
"name": "quill-delta",
"version": "4.0.1",
"version": "4.1.0",
"description": "Format for representing rich text documents and changes.",

@@ -11,3 +11,3 @@ "author": "Jason Chen <jhchen7@gmail.com>",

"extend": "^3.0.2",
"fast-diff": "1.1.2"
"fast-diff": "1.2.0"
},

@@ -17,3 +17,2 @@ "devDependencies": {

"@types/extend": "^3.0.0",
"@types/fast-diff": "^1.1.0",
"coveralls": "^3.0.2",

@@ -20,0 +19,0 @@ "istanbul": "~0.4.5",

@@ -267,3 +267,3 @@ import equal from 'deep-equal';

diff(other: Delta, index?: number): Delta {
diff(other: Delta, cursor?: number | diff.CursorInfo): Delta {
if (this.ops === other.ops) {

@@ -284,3 +284,3 @@ return new Delta();

const retDelta = new Delta();
const diffResult = diff(strings[0], strings[1], index);
const diffResult = diff(strings[0], strings[1], cursor);
const thisIter = Op.iterator(this.ops);

@@ -287,0 +287,0 @@ const otherIter = Op.iterator(other.ops);

Sorry, the diff of this file is not supported yet

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