Skip to content

Commit a121778

Browse files
committed
(chore) Dependency: Bump version to 0.1.1
Fixes: #43 Signed-off-by: Progyan Bhattacharya <[email protected]>
1 parent 30fc181 commit a121778

File tree

4 files changed

+33
-29
lines changed

4 files changed

+33
-29
lines changed

CHANGELOG.md

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,13 @@ Good to have: commit or PR links.
2222
2323
-->
2424

25+
## v0.3.1 [#44](https://github.com/interviewstreet/firepad-x/pull/44)
26+
27+
### Changed
28+
29+
- Bump version of `@operational-transformation` packages to `v0.1.1`.
30+
- This fixes [issue](https://github.com/interviewstreet/firepad-x/issues/43) with Universal Application building using this library.
31+
2532
## v0.3.0 [#42](https://github.com/interviewstreet/firepad-x/pull/42)
2633

2734
### Changed

package.json

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"name": "@hackerrank/firepad",
33
"description": "Collaborative text editing powered by Firebase",
4-
"version": "0.3.0",
4+
"version": "0.3.1",
55
"author": {
66
"email": "[email protected]",
77
"name": "Progyan Bhattacharya",
@@ -59,9 +59,9 @@
5959
"monaco-editor": "0.18.1"
6060
},
6161
"dependencies": {
62-
"@operational-transformation/plaintext": "0.1.0",
63-
"@operational-transformation/plaintext-editor": "0.1.0",
64-
"@operational-transformation/state-machine": "0.1.0",
62+
"@operational-transformation/plaintext": "0.1.1",
63+
"@operational-transformation/plaintext-editor": "0.1.1",
64+
"@operational-transformation/state-machine": "0.1.1",
6565
"mitt": "3.0.0",
6666
"uuid": "8.3.2"
6767
},

src/monaco-adapter.ts

Lines changed: 9 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -609,7 +609,7 @@ export class MonacoAdapter implements IEditorAdapter {
609609

610610
/** If no change information received */
611611
if (!ev.changes || ev.changes.length === 0) {
612-
const op = new TextOperation().retain(contentLength, null);
612+
const op = new TextOperation().retain(contentLength);
613613
this._trigger(EditorAdapterEvent.Change, {
614614
operation: op,
615615
inverse: op,
@@ -705,8 +705,8 @@ export class MonacoAdapter implements IEditorAdapter {
705705
const retain = rangeOffset - skippedChars;
706706

707707
try {
708-
mainOp = mainOp.retain(retain, null);
709-
reverseOp = reverseOp.retain(retain, null);
708+
mainOp = mainOp.retain(retain);
709+
reverseOp = reverseOp.retain(retain);
710710
} catch (err) {
711711
this._trigger(EditorAdapterEvent.Error, {
712712
err,
@@ -718,26 +718,23 @@ export class MonacoAdapter implements IEditorAdapter {
718718

719719
if (!text && !range.isEmpty()) {
720720
mainOp = mainOp.delete(rangeLength);
721-
reverseOp = reverseOp.insert(
722-
this._getPreviousContentInRange(range),
723-
null
724-
);
721+
reverseOp = reverseOp.insert(this._getPreviousContentInRange(range));
725722
} else if (text && !range.isEmpty()) {
726-
mainOp = mainOp.delete(rangeLength).insert(text, null);
723+
mainOp = mainOp.delete(rangeLength).insert(text);
727724
reverseOp = reverseOp
728-
.insert(this._getPreviousContentInRange(range), null)
725+
.insert(this._getPreviousContentInRange(range))
729726
.delete(text);
730727
} else {
731-
mainOp = mainOp.insert(text, null);
728+
mainOp = mainOp.insert(text);
732729
reverseOp = reverseOp.delete(text);
733730
}
734731

735732
skippedChars = skippedChars + retain + rangeLength;
736733
}
737734

738735
try {
739-
mainOp = mainOp.retain(contentLength - skippedChars, null);
740-
reverseOp = reverseOp.retain(contentLength - skippedChars, null);
736+
mainOp = mainOp.retain(contentLength - skippedChars);
737+
reverseOp = reverseOp.retain(contentLength - skippedChars);
741738
} catch (err) {
742739
this._trigger(EditorAdapterEvent.Error, {
743740
err,

yarn.lock

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1445,23 +1445,23 @@
14451445
"@types/yargs" "^16.0.0"
14461446
chalk "^4.0.0"
14471447

1448-
"@operational-transformation/[email protected].0":
1449-
version "0.1.0"
1450-
resolved "https://registry.yarnpkg.com/@operational-transformation/plaintext-editor/-/plaintext-editor-0.1.0.tgz#0c7fc3253b9917bb95ba65134f4e07006cba8fd6"
1451-
integrity sha512-1o7XR/DbOyY0CkSnPRyLsXHanVBq4XwLIKyPkTvlwHVFn2NuxkpAL/3tlwhIKA1fRd06pxxe+Dhzprf1yaTW4g==
1448+
"@operational-transformation/[email protected].1":
1449+
version "0.1.1"
1450+
resolved "https://registry.yarnpkg.com/@operational-transformation/plaintext-editor/-/plaintext-editor-0.1.1.tgz#6523a7b52fe619c96b72f026fa157a3b1486fe25"
1451+
integrity sha512-2vQEItOulQeQp7lOu4rLCSd9H1Liq/arv26I88JfnhnPD1IFGEvrFJjHfgOoJSghMvNV/HxrpojOnRneRvdMXw==
14521452
dependencies:
1453-
"@operational-transformation/state-machine" "0.1.0"
1453+
"@operational-transformation/state-machine" "0.1.1"
14541454
mitt "3.0.0"
14551455

1456-
"@operational-transformation/[email protected].0":
1457-
version "0.1.0"
1458-
resolved "https://registry.yarnpkg.com/@operational-transformation/plaintext/-/plaintext-0.1.0.tgz#2d7469b7bf886e7345fcbbb300afe45827ba990b"
1459-
integrity sha512-Kg0sU5+7+Fi0p9b2F558tioeInlPzlWhgSQRt4I6xwMNQAu6jpWTbnvEhGc8jAh5kaVjNYPQhzvpdZHnmDeX0g==
1456+
"@operational-transformation/[email protected].1":
1457+
version "0.1.1"
1458+
resolved "https://registry.yarnpkg.com/@operational-transformation/plaintext/-/plaintext-0.1.1.tgz#22bbb4f4eacdb63a90f3557adeb9d438c91b4617"
1459+
integrity sha512-90vZeG74f0Ruz2avG8jDj7y4w1LxxTuSGNwAht9vWzNl8U01JEP1rcIDZ/jhQGL9yZFWTZY4mwPSUJuMZks7Bg==
14601460

1461-
"@operational-transformation/[email protected].0":
1462-
version "0.1.0"
1463-
resolved "https://registry.yarnpkg.com/@operational-transformation/state-machine/-/state-machine-0.1.0.tgz#92096618e9747d94b9f6f12afe76a6a4b58177c1"
1464-
integrity sha512-fcttrjExFey5noy4eFQUXecK/YPqyINkS5GifMHirTw2cJGX8+oDosroFW+RnflS7lnSxuNq+M2S40at75B+mg==
1461+
"@operational-transformation/[email protected].1":
1462+
version "0.1.1"
1463+
resolved "https://registry.yarnpkg.com/@operational-transformation/state-machine/-/state-machine-0.1.1.tgz#ef13979993c41a32eacd1a0bae4e40b3998ada37"
1464+
integrity sha512-2Get0p4quTXts5JzroPs7Ry1zu2bjD1R/oMjBRI4YgRRshRfDSOrxvfHsN2R+wNM1akfGfLgVKgxh8sLKR5ZSw==
14651465

14661466
"@protobufjs/aspromise@^1.1.1", "@protobufjs/aspromise@^1.1.2":
14671467
version "1.1.2"

0 commit comments

Comments
 (0)