@textbus/collaborate 3.0.0-alpha.53 → 3.0.0-alpha.55
Sign up to get free protection for your applications and to get access to all the features.
- package/bundles/index.esm.js +2 -3
- package/bundles/index.js +2 -3
- package/package.json +3 -3
package/bundles/index.esm.js
CHANGED
@@ -353,7 +353,7 @@ let Collaborate = class Collaborate {
|
|
353
353
|
this.syncComponentState(sharedComponent, component);
|
354
354
|
slot.insert(component);
|
355
355
|
}
|
356
|
-
if (this.selection.isSelected) {
|
356
|
+
if (this.selection.isSelected && tr.origin !== this.manager) {
|
357
357
|
if (slot === this.selection.anchorSlot && this.selection.anchorOffset > index) {
|
358
358
|
this.selection.setAnchor(slot, this.selection.anchorOffset + length);
|
359
359
|
}
|
@@ -364,9 +364,8 @@ let Collaborate = class Collaborate {
|
|
364
364
|
}
|
365
365
|
else if (action.delete) {
|
366
366
|
const index = slot.index;
|
367
|
-
slot.retain(slot.index);
|
368
367
|
slot.delete(action.delete);
|
369
|
-
if (this.selection.isSelected) {
|
368
|
+
if (this.selection.isSelected && tr.origin !== this.manager) {
|
370
369
|
if (slot === this.selection.anchorSlot && this.selection.anchorOffset >= index) {
|
371
370
|
this.selection.setAnchor(slot, this.selection.startOffset - action.delete);
|
372
371
|
}
|
package/bundles/index.js
CHANGED
@@ -355,7 +355,7 @@ exports.Collaborate = class Collaborate {
|
|
355
355
|
this.syncComponentState(sharedComponent, component);
|
356
356
|
slot.insert(component);
|
357
357
|
}
|
358
|
-
if (this.selection.isSelected) {
|
358
|
+
if (this.selection.isSelected && tr.origin !== this.manager) {
|
359
359
|
if (slot === this.selection.anchorSlot && this.selection.anchorOffset > index) {
|
360
360
|
this.selection.setAnchor(slot, this.selection.anchorOffset + length);
|
361
361
|
}
|
@@ -366,9 +366,8 @@ exports.Collaborate = class Collaborate {
|
|
366
366
|
}
|
367
367
|
else if (action.delete) {
|
368
368
|
const index = slot.index;
|
369
|
-
slot.retain(slot.index);
|
370
369
|
slot.delete(action.delete);
|
371
|
-
if (this.selection.isSelected) {
|
370
|
+
if (this.selection.isSelected && tr.origin !== this.manager) {
|
372
371
|
if (slot === this.selection.anchorSlot && this.selection.anchorOffset >= index) {
|
373
372
|
this.selection.setAnchor(slot, this.selection.startOffset - action.delete);
|
374
373
|
}
|
package/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "@textbus/collaborate",
|
3
|
-
"version": "3.0.0-alpha.
|
3
|
+
"version": "3.0.0-alpha.55",
|
4
4
|
"description": "Textbus is a rich text editor and framework that is highly customizable and extensible to achieve rich wysiwyg effects.",
|
5
5
|
"main": "./bundles/index.js",
|
6
6
|
"module": "./bundles/index.esm.js",
|
@@ -27,7 +27,7 @@
|
|
27
27
|
"dependencies": {
|
28
28
|
"@tanbo/di": "^1.1.4",
|
29
29
|
"@tanbo/stream": "^1.1.9",
|
30
|
-
"@textbus/core": "^3.0.0-alpha.
|
30
|
+
"@textbus/core": "^3.0.0-alpha.55",
|
31
31
|
"reflect-metadata": "^0.1.13",
|
32
32
|
"y-protocols": "^1.0.5",
|
33
33
|
"yjs": "^13.5.39"
|
@@ -50,5 +50,5 @@
|
|
50
50
|
"bugs": {
|
51
51
|
"url": "https://github.com/textbus/textbus.git/issues"
|
52
52
|
},
|
53
|
-
"gitHead": "
|
53
|
+
"gitHead": "35c8c2c109ddd83cdad80a4871531d9f9a8f8b78"
|
54
54
|
}
|