@atlaskit/editor-plugin-collab-edit 6.1.0 → 6.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,24 @@
1
1
  # @atlaskit/editor-plugin-collab-edit
2
2
 
3
+ ## 6.2.0
4
+
5
+ ### Minor Changes
6
+
7
+ - [`b367661ba720e`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/b367661ba720e) -
8
+ EDITOR-1562 bump adf-schema for afm
9
+
10
+ ### Patch Changes
11
+
12
+ - Updated dependencies
13
+
14
+ ## 6.1.1
15
+
16
+ ### Patch Changes
17
+
18
+ - [`ec9911563263e`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/ec9911563263e) -
19
+ Mark transactions that add a localId attribute as a non-organic change in collab.
20
+ - Updated dependencies
21
+
3
22
  ## 6.1.0
4
23
 
5
24
  ### Minor Changes
@@ -210,6 +210,12 @@ var isOrganicChange = exports.isOrganicChange = function isOrganicChange(tr) {
210
210
  if (step instanceof _steps.AnalyticsStep) {
211
211
  return false;
212
212
  }
213
+
214
+ // editor-plugin-local-id uses AttrStep to set the localId attribute
215
+ if (step instanceof _transform.AttrStep && step.attr === 'localId') {
216
+ return false;
217
+ }
218
+
213
219
  // If a step is not an instance of SetAttrsStep, it is considered organic
214
220
  if (!(step instanceof _steps.SetAttrsStep)) {
215
221
  return true;
@@ -4,7 +4,7 @@ import { TELEPOINTER_DATA_SESSION_ID_ATTR, TELEPOINTER_PULSE_DURING_TR_CLASS, TE
4
4
  import { processRawValueWithoutValidation } from '@atlaskit/editor-common/process-raw-value';
5
5
  import { ZERO_WIDTH_JOINER } from '@atlaskit/editor-common/whitespace';
6
6
  import { Transaction, Selection, TextSelection } from '@atlaskit/editor-prosemirror/state';
7
- import { ReplaceStep } from '@atlaskit/editor-prosemirror/transform';
7
+ import { AttrStep, ReplaceStep } from '@atlaskit/editor-prosemirror/transform';
8
8
  import { Decoration } from '@atlaskit/editor-prosemirror/view';
9
9
  import { getParticipantColor } from '@atlaskit/editor-shared-styles';
10
10
  export const findPointers = (id, decorations) => decorations.find().reduce((arr, deco) => deco.spec.pointer.presenceId === id ? arr.concat(deco) : arr, []);
@@ -198,6 +198,12 @@ export const isOrganicChange = tr => {
198
198
  if (step instanceof AnalyticsStep) {
199
199
  return false;
200
200
  }
201
+
202
+ // editor-plugin-local-id uses AttrStep to set the localId attribute
203
+ if (step instanceof AttrStep && step.attr === 'localId') {
204
+ return false;
205
+ }
206
+
201
207
  // If a step is not an instance of SetAttrsStep, it is considered organic
202
208
  if (!(step instanceof SetAttrsStep)) {
203
209
  return true;
@@ -5,7 +5,7 @@ import { TELEPOINTER_DATA_SESSION_ID_ATTR, TELEPOINTER_PULSE_DURING_TR_CLASS, TE
5
5
  import { processRawValueWithoutValidation } from '@atlaskit/editor-common/process-raw-value';
6
6
  import { ZERO_WIDTH_JOINER } from '@atlaskit/editor-common/whitespace';
7
7
  import { Transaction, Selection, TextSelection } from '@atlaskit/editor-prosemirror/state';
8
- import { ReplaceStep } from '@atlaskit/editor-prosemirror/transform';
8
+ import { AttrStep, ReplaceStep } from '@atlaskit/editor-prosemirror/transform';
9
9
  import { Decoration } from '@atlaskit/editor-prosemirror/view';
10
10
  import { getParticipantColor } from '@atlaskit/editor-shared-styles';
11
11
  export var findPointers = function findPointers(id, decorations) {
@@ -202,6 +202,12 @@ export var isOrganicChange = function isOrganicChange(tr) {
202
202
  if (step instanceof AnalyticsStep) {
203
203
  return false;
204
204
  }
205
+
206
+ // editor-plugin-local-id uses AttrStep to set the localId attribute
207
+ if (step instanceof AttrStep && step.attr === 'localId') {
208
+ return false;
209
+ }
210
+
205
211
  // If a step is not an instance of SetAttrsStep, it is considered organic
206
212
  if (!(step instanceof SetAttrsStep)) {
207
213
  return true;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atlaskit/editor-plugin-collab-edit",
3
- "version": "6.1.0",
3
+ "version": "6.2.0",
4
4
  "description": "Collab Edit plugin for @atlaskit/editor-core",
5
5
  "author": "Atlassian Pty Ltd",
6
6
  "license": "Apache-2.0",
@@ -27,10 +27,10 @@
27
27
  "sideEffects": false,
28
28
  "atlaskit:src": "src/index.ts",
29
29
  "dependencies": {
30
- "@atlaskit/adf-schema": "^51.1.1",
31
- "@atlaskit/custom-steps": "^0.12.0",
32
- "@atlaskit/editor-json-transformer": "^8.28.0",
33
- "@atlaskit/editor-plugin-analytics": "^5.1.0",
30
+ "@atlaskit/adf-schema": "^51.1.2",
31
+ "@atlaskit/custom-steps": "^0.13.0",
32
+ "@atlaskit/editor-json-transformer": "^8.29.0",
33
+ "@atlaskit/editor-plugin-analytics": "^5.2.0",
34
34
  "@atlaskit/editor-plugin-connectivity": "^5.0.0",
35
35
  "@atlaskit/editor-plugin-editor-viewmode": "^7.0.0",
36
36
  "@atlaskit/editor-plugin-feature-flags": "^4.0.0",
@@ -38,23 +38,23 @@
38
38
  "@atlaskit/editor-shared-styles": "^3.6.0",
39
39
  "@atlaskit/frontend-utilities": "^3.1.0",
40
40
  "@atlaskit/platform-feature-flags": "^1.1.0",
41
- "@atlaskit/prosemirror-collab": "^0.18.0",
42
- "@atlaskit/tmp-editor-statsig": "^12.14.0",
41
+ "@atlaskit/prosemirror-collab": "^0.19.0",
42
+ "@atlaskit/tmp-editor-statsig": "^12.18.0",
43
43
  "@babel/runtime": "^7.0.0",
44
44
  "memoize-one": "^6.0.0"
45
45
  },
46
46
  "peerDependencies": {
47
- "@atlaskit/editor-common": "^109.3.0",
47
+ "@atlaskit/editor-common": "^109.5.0",
48
48
  "react": "^18.2.0",
49
49
  "react-dom": "^18.2.0"
50
50
  },
51
51
  "devDependencies": {
52
52
  "@af/integration-testing": "workspace:^",
53
53
  "@af/visual-regression": "workspace:^",
54
- "@atlaskit/editor-plugin-mentions": "^7.1.0",
55
- "@atlaskit/editor-plugin-text-formatting": "^5.1.0",
56
- "@atlaskit/editor-plugin-type-ahead": "^5.1.0",
57
- "@atlaskit/editor-plugin-unsupported-content": "^5.1.0",
54
+ "@atlaskit/editor-plugin-mentions": "^7.2.0",
55
+ "@atlaskit/editor-plugin-text-formatting": "^5.2.0",
56
+ "@atlaskit/editor-plugin-type-ahead": "^5.2.0",
57
+ "@atlaskit/editor-plugin-unsupported-content": "^5.2.0",
58
58
  "@atlaskit/editor-test-helpers": "workspace:^",
59
59
  "@atlaskit/ssr": "workspace:^",
60
60
  "@atlaskit/synchrony-test-helpers": "workspace:^",