@atlaskit/editor-plugin-collab-edit 2.1.6 → 2.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,19 @@
|
|
|
1
1
|
# @atlaskit/editor-plugin-collab-edit
|
|
2
2
|
|
|
3
|
+
## 2.2.0
|
|
4
|
+
|
|
5
|
+
### Minor Changes
|
|
6
|
+
|
|
7
|
+
- [#104960](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/104960)
|
|
8
|
+
[`9ef5570fb870f`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/9ef5570fb870f) -
|
|
9
|
+
Adding fg platform_editor_selection_without_left_shift to fix the editor selection issue
|
|
10
|
+
|
|
11
|
+
### Patch Changes
|
|
12
|
+
|
|
13
|
+
- [#104870](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/104870)
|
|
14
|
+
[`79e0bedfbaf1f`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/79e0bedfbaf1f) -
|
|
15
|
+
EDF-2202 copy ai-proactive from editor-plugin-ai to editor-plugin-ai-proactive
|
|
16
|
+
|
|
3
17
|
## 2.1.6
|
|
4
18
|
|
|
5
19
|
### Patch Changes
|
|
@@ -12,6 +12,7 @@ var _browser = require("@atlaskit/editor-common/browser");
|
|
|
12
12
|
var _collab = require("@atlaskit/editor-common/collab");
|
|
13
13
|
var _state = require("@atlaskit/editor-prosemirror/state");
|
|
14
14
|
var _view = require("@atlaskit/editor-prosemirror/view");
|
|
15
|
+
var _platformFeatureFlags = require("@atlaskit/platform-feature-flags");
|
|
15
16
|
var _participants = require("../participants");
|
|
16
17
|
var _utils = require("../utils");
|
|
17
18
|
/**
|
|
@@ -134,7 +135,11 @@ var PluginState = exports.PluginState = /*#__PURE__*/function () {
|
|
|
134
135
|
var from = 1;
|
|
135
136
|
var to = 1;
|
|
136
137
|
try {
|
|
137
|
-
|
|
138
|
+
if ((0, _platformFeatureFlags.fg)('platform_editor_selection_without_left_shift')) {
|
|
139
|
+
from = getValidPos(tr, isSelection ? Math.max(rawFrom, 0) : rawFrom);
|
|
140
|
+
} else {
|
|
141
|
+
from = getValidPos(tr, isSelection ? Math.max(rawFrom - 1, 0) : rawFrom);
|
|
142
|
+
}
|
|
138
143
|
to = isSelection ? getValidPos(tr, rawTo) : from;
|
|
139
144
|
} catch (err) {
|
|
140
145
|
this.onError(err);
|
|
@@ -3,6 +3,7 @@ import { browser } from '@atlaskit/editor-common/browser';
|
|
|
3
3
|
import { TELEPOINTER_DIM_CLASS } from '@atlaskit/editor-common/collab';
|
|
4
4
|
import { Selection } from '@atlaskit/editor-prosemirror/state';
|
|
5
5
|
import { DecorationSet } from '@atlaskit/editor-prosemirror/view';
|
|
6
|
+
import { fg } from '@atlaskit/platform-feature-flags';
|
|
6
7
|
import { Participants } from '../participants';
|
|
7
8
|
import { createTelepointers, findPointers, getPositionOfTelepointer, isReplaceStep } from '../utils';
|
|
8
9
|
|
|
@@ -111,7 +112,11 @@ export class PluginState {
|
|
|
111
112
|
let from = 1;
|
|
112
113
|
let to = 1;
|
|
113
114
|
try {
|
|
114
|
-
|
|
115
|
+
if (fg('platform_editor_selection_without_left_shift')) {
|
|
116
|
+
from = getValidPos(tr, isSelection ? Math.max(rawFrom, 0) : rawFrom);
|
|
117
|
+
} else {
|
|
118
|
+
from = getValidPos(tr, isSelection ? Math.max(rawFrom - 1, 0) : rawFrom);
|
|
119
|
+
}
|
|
115
120
|
to = isSelection ? getValidPos(tr, rawTo) : from;
|
|
116
121
|
} catch (err) {
|
|
117
122
|
this.onError(err);
|
|
@@ -5,6 +5,7 @@ import { browser } from '@atlaskit/editor-common/browser';
|
|
|
5
5
|
import { TELEPOINTER_DIM_CLASS } from '@atlaskit/editor-common/collab';
|
|
6
6
|
import { Selection } from '@atlaskit/editor-prosemirror/state';
|
|
7
7
|
import { DecorationSet } from '@atlaskit/editor-prosemirror/view';
|
|
8
|
+
import { fg } from '@atlaskit/platform-feature-flags';
|
|
8
9
|
import { Participants } from '../participants';
|
|
9
10
|
import { createTelepointers, findPointers, getPositionOfTelepointer, isReplaceStep } from '../utils';
|
|
10
11
|
|
|
@@ -128,7 +129,11 @@ export var PluginState = /*#__PURE__*/function () {
|
|
|
128
129
|
var from = 1;
|
|
129
130
|
var to = 1;
|
|
130
131
|
try {
|
|
131
|
-
|
|
132
|
+
if (fg('platform_editor_selection_without_left_shift')) {
|
|
133
|
+
from = getValidPos(tr, isSelection ? Math.max(rawFrom, 0) : rawFrom);
|
|
134
|
+
} else {
|
|
135
|
+
from = getValidPos(tr, isSelection ? Math.max(rawFrom - 1, 0) : rawFrom);
|
|
136
|
+
}
|
|
132
137
|
to = isSelection ? getValidPos(tr, rawTo) : from;
|
|
133
138
|
} catch (err) {
|
|
134
139
|
this.onError(err);
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/editor-plugin-collab-edit",
|
|
3
|
-
"version": "2.
|
|
3
|
+
"version": "2.2.0",
|
|
4
4
|
"description": "Collab Edit plugin for @atlaskit/editor-core",
|
|
5
5
|
"author": "Atlassian Pty Ltd",
|
|
6
6
|
"license": "Apache-2.0",
|
|
@@ -108,6 +108,9 @@
|
|
|
108
108
|
},
|
|
109
109
|
"platform_editor_merge_unconfirmed_steps": {
|
|
110
110
|
"type": "boolean"
|
|
111
|
+
},
|
|
112
|
+
"platform_editor_selection_without_left_shift": {
|
|
113
|
+
"type": "boolean"
|
|
111
114
|
}
|
|
112
115
|
}
|
|
113
116
|
}
|