@atlaskit/editor-core 204.4.7 → 204.4.8

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,18 @@
1
1
  # @atlaskit/editor-core
2
2
 
3
+ ## 204.4.8
4
+
5
+ ### Patch Changes
6
+
7
+ - [#124114](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/pull-requests/124114)
8
+ [`a0b9383dc1bf3`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/a0b9383dc1bf3) -
9
+ CEPS-362: add reason to getResolvedEditorState call chain, to allow collab provider/NCS to
10
+ differentiate between draft sync and publish use cases
11
+ - [#125450](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/pull-requests/125450)
12
+ [`e3e99633b852e`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/e3e99633b852e) -
13
+ [ux] ED-26944 fix indentation in list for non macro bodied extension
14
+ - Updated dependencies
15
+
3
16
  ## 204.4.7
4
17
 
5
18
  ### Patch Changes
@@ -55,50 +55,55 @@ var EditorActions = exports.default = /*#__PURE__*/function () {
55
55
  * refers to the latest state of editor with confirmed
56
56
  * steps.
57
57
  */
58
- (0, _defineProperty2.default)(this, "getResolvedEditorState", /*#__PURE__*/(0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee() {
59
- var _this$getFeatureFlags, useNativeCollabPlugin, editorValue, editorView, collabEditState;
60
- return _regenerator.default.wrap(function _callee$(_context) {
61
- while (1) switch (_context.prev = _context.next) {
62
- case 0:
63
- _this$getFeatureFlags = _this.getFeatureFlags(), useNativeCollabPlugin = _this$getFeatureFlags.useNativeCollabPlugin;
64
- if (_this.editorView) {
65
- _context.next = 3;
66
- break;
67
- }
68
- throw new Error('Called getResolvedEditorState before editorView is ready');
69
- case 3:
70
- if (useNativeCollabPlugin) {
71
- _context.next = 10;
72
- break;
73
- }
74
- _context.next = 6;
75
- return _this.getValue();
76
- case 6:
77
- editorValue = _context.sent;
78
- if (editorValue) {
79
- _context.next = 9;
80
- break;
81
- }
82
- throw new Error('editorValue is undefined');
83
- case 9:
84
- return _context.abrupt("return", {
85
- content: editorValue,
86
- title: null,
87
- stepVersion: -1
88
- });
89
- case 10:
90
- editorView = _this.editorView;
91
- _context.next = 13;
92
- return (0, _action.getEditorValueWithMedia)(editorView);
93
- case 13:
94
- collabEditState = fakePluginKey.getState(editorView.state);
95
- return _context.abrupt("return", collabEditState === null || collabEditState === void 0 ? void 0 : collabEditState.getFinalAcknowledgedState());
96
- case 15:
97
- case "end":
98
- return _context.stop();
99
- }
100
- }, _callee);
101
- })));
58
+ (0, _defineProperty2.default)(this, "getResolvedEditorState", /*#__PURE__*/function () {
59
+ var _ref = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee(reason) {
60
+ var _this$getFeatureFlags, useNativeCollabPlugin, editorValue, editorView, collabEditState;
61
+ return _regenerator.default.wrap(function _callee$(_context) {
62
+ while (1) switch (_context.prev = _context.next) {
63
+ case 0:
64
+ _this$getFeatureFlags = _this.getFeatureFlags(), useNativeCollabPlugin = _this$getFeatureFlags.useNativeCollabPlugin;
65
+ if (_this.editorView) {
66
+ _context.next = 3;
67
+ break;
68
+ }
69
+ throw new Error('Called getResolvedEditorState before editorView is ready');
70
+ case 3:
71
+ if (useNativeCollabPlugin) {
72
+ _context.next = 10;
73
+ break;
74
+ }
75
+ _context.next = 6;
76
+ return _this.getValue();
77
+ case 6:
78
+ editorValue = _context.sent;
79
+ if (editorValue) {
80
+ _context.next = 9;
81
+ break;
82
+ }
83
+ throw new Error('editorValue is undefined');
84
+ case 9:
85
+ return _context.abrupt("return", {
86
+ content: editorValue,
87
+ title: null,
88
+ stepVersion: -1
89
+ });
90
+ case 10:
91
+ editorView = _this.editorView;
92
+ _context.next = 13;
93
+ return (0, _action.getEditorValueWithMedia)(editorView);
94
+ case 13:
95
+ collabEditState = fakePluginKey.getState(editorView.state);
96
+ return _context.abrupt("return", collabEditState === null || collabEditState === void 0 ? void 0 : collabEditState.getFinalAcknowledgedState(reason));
97
+ case 15:
98
+ case "end":
99
+ return _context.stop();
100
+ }
101
+ }, _callee);
102
+ }));
103
+ return function (_x) {
104
+ return _ref.apply(this, arguments);
105
+ };
106
+ }());
102
107
  }
103
108
  return (0, _createClass2.default)(EditorActions, [{
104
109
  key: "_privateGetEditorView",
@@ -5,4 +5,4 @@ Object.defineProperty(exports, "__esModule", {
5
5
  });
6
6
  exports.version = exports.name = void 0;
7
7
  var name = exports.name = "@atlaskit/editor-core";
8
- var version = exports.version = "204.4.7";
8
+ var version = exports.version = "204.4.8";
@@ -43,7 +43,7 @@ export default class EditorActions {
43
43
  * refers to the latest state of editor with confirmed
44
44
  * steps.
45
45
  */
46
- _defineProperty(this, "getResolvedEditorState", async () => {
46
+ _defineProperty(this, "getResolvedEditorState", async reason => {
47
47
  const {
48
48
  useNativeCollabPlugin
49
49
  } = this.getFeatureFlags();
@@ -64,7 +64,7 @@ export default class EditorActions {
64
64
  const editorView = this.editorView;
65
65
  await getEditorValueWithMedia(editorView);
66
66
  const collabEditState = fakePluginKey.getState(editorView.state);
67
- return collabEditState === null || collabEditState === void 0 ? void 0 : collabEditState.getFinalAcknowledgedState();
67
+ return collabEditState === null || collabEditState === void 0 ? void 0 : collabEditState.getFinalAcknowledgedState(reason);
68
68
  });
69
69
  }
70
70
  static from(view, eventDispatcher, transformer) {
@@ -1,2 +1,2 @@
1
1
  export const name = "@atlaskit/editor-core";
2
- export const version = "204.4.7";
2
+ export const version = "204.4.8";
@@ -49,50 +49,55 @@ var EditorActions = /*#__PURE__*/function () {
49
49
  * refers to the latest state of editor with confirmed
50
50
  * steps.
51
51
  */
52
- _defineProperty(this, "getResolvedEditorState", /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee() {
53
- var _this$getFeatureFlags, useNativeCollabPlugin, editorValue, editorView, collabEditState;
54
- return _regeneratorRuntime.wrap(function _callee$(_context) {
55
- while (1) switch (_context.prev = _context.next) {
56
- case 0:
57
- _this$getFeatureFlags = _this.getFeatureFlags(), useNativeCollabPlugin = _this$getFeatureFlags.useNativeCollabPlugin;
58
- if (_this.editorView) {
59
- _context.next = 3;
60
- break;
61
- }
62
- throw new Error('Called getResolvedEditorState before editorView is ready');
63
- case 3:
64
- if (useNativeCollabPlugin) {
65
- _context.next = 10;
66
- break;
67
- }
68
- _context.next = 6;
69
- return _this.getValue();
70
- case 6:
71
- editorValue = _context.sent;
72
- if (editorValue) {
73
- _context.next = 9;
74
- break;
75
- }
76
- throw new Error('editorValue is undefined');
77
- case 9:
78
- return _context.abrupt("return", {
79
- content: editorValue,
80
- title: null,
81
- stepVersion: -1
82
- });
83
- case 10:
84
- editorView = _this.editorView;
85
- _context.next = 13;
86
- return getEditorValueWithMedia(editorView);
87
- case 13:
88
- collabEditState = fakePluginKey.getState(editorView.state);
89
- return _context.abrupt("return", collabEditState === null || collabEditState === void 0 ? void 0 : collabEditState.getFinalAcknowledgedState());
90
- case 15:
91
- case "end":
92
- return _context.stop();
93
- }
94
- }, _callee);
95
- })));
52
+ _defineProperty(this, "getResolvedEditorState", /*#__PURE__*/function () {
53
+ var _ref = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee(reason) {
54
+ var _this$getFeatureFlags, useNativeCollabPlugin, editorValue, editorView, collabEditState;
55
+ return _regeneratorRuntime.wrap(function _callee$(_context) {
56
+ while (1) switch (_context.prev = _context.next) {
57
+ case 0:
58
+ _this$getFeatureFlags = _this.getFeatureFlags(), useNativeCollabPlugin = _this$getFeatureFlags.useNativeCollabPlugin;
59
+ if (_this.editorView) {
60
+ _context.next = 3;
61
+ break;
62
+ }
63
+ throw new Error('Called getResolvedEditorState before editorView is ready');
64
+ case 3:
65
+ if (useNativeCollabPlugin) {
66
+ _context.next = 10;
67
+ break;
68
+ }
69
+ _context.next = 6;
70
+ return _this.getValue();
71
+ case 6:
72
+ editorValue = _context.sent;
73
+ if (editorValue) {
74
+ _context.next = 9;
75
+ break;
76
+ }
77
+ throw new Error('editorValue is undefined');
78
+ case 9:
79
+ return _context.abrupt("return", {
80
+ content: editorValue,
81
+ title: null,
82
+ stepVersion: -1
83
+ });
84
+ case 10:
85
+ editorView = _this.editorView;
86
+ _context.next = 13;
87
+ return getEditorValueWithMedia(editorView);
88
+ case 13:
89
+ collabEditState = fakePluginKey.getState(editorView.state);
90
+ return _context.abrupt("return", collabEditState === null || collabEditState === void 0 ? void 0 : collabEditState.getFinalAcknowledgedState(reason));
91
+ case 15:
92
+ case "end":
93
+ return _context.stop();
94
+ }
95
+ }, _callee);
96
+ }));
97
+ return function (_x) {
98
+ return _ref.apply(this, arguments);
99
+ };
100
+ }());
96
101
  }
97
102
  return _createClass(EditorActions, [{
98
103
  key: "_privateGetEditorView",
@@ -1,2 +1,2 @@
1
1
  export var name = "@atlaskit/editor-core";
2
- export var version = "204.4.7";
2
+ export var version = "204.4.8";
@@ -1,7 +1,7 @@
1
1
  import type { AnalyticsEventPayload } from '@atlaskit/analytics-next/AnalyticsEvent';
2
2
  import type { ResolvedEditorState } from '@atlaskit/editor-common/collab';
3
3
  import type { EventDispatcher } from '@atlaskit/editor-common/event-dispatcher';
4
- import type { ContextUpdateHandler, EditorActionsOptions, FeatureFlags, ReplaceRawValue, Transformer } from '@atlaskit/editor-common/types';
4
+ import type { ContextUpdateHandler, EditorActionsOptions, FeatureFlags, ReplaceRawValue, GetResolvedEditorStateReason, Transformer } from '@atlaskit/editor-common/types';
5
5
  import { Node } from '@atlaskit/editor-prosemirror/model';
6
6
  import type { EditorView } from '@atlaskit/editor-prosemirror/view';
7
7
  export default class EditorActions<T = any> implements EditorActionsOptions<T> {
@@ -64,5 +64,5 @@ export default class EditorActions<T = any> implements EditorActionsOptions<T> {
64
64
  * refers to the latest state of editor with confirmed
65
65
  * steps.
66
66
  */
67
- getResolvedEditorState: () => Promise<ResolvedEditorState | undefined>;
67
+ getResolvedEditorState: (reason: GetResolvedEditorStateReason) => Promise<ResolvedEditorState | undefined>;
68
68
  }
@@ -1,7 +1,7 @@
1
1
  import type { AnalyticsEventPayload } from '@atlaskit/analytics-next/AnalyticsEvent';
2
2
  import type { ResolvedEditorState } from '@atlaskit/editor-common/collab';
3
3
  import type { EventDispatcher } from '@atlaskit/editor-common/event-dispatcher';
4
- import type { ContextUpdateHandler, EditorActionsOptions, FeatureFlags, ReplaceRawValue, Transformer } from '@atlaskit/editor-common/types';
4
+ import type { ContextUpdateHandler, EditorActionsOptions, FeatureFlags, ReplaceRawValue, GetResolvedEditorStateReason, Transformer } from '@atlaskit/editor-common/types';
5
5
  import { Node } from '@atlaskit/editor-prosemirror/model';
6
6
  import type { EditorView } from '@atlaskit/editor-prosemirror/view';
7
7
  export default class EditorActions<T = any> implements EditorActionsOptions<T> {
@@ -64,5 +64,5 @@ export default class EditorActions<T = any> implements EditorActionsOptions<T> {
64
64
  * refers to the latest state of editor with confirmed
65
65
  * steps.
66
66
  */
67
- getResolvedEditorState: () => Promise<ResolvedEditorState | undefined>;
67
+ getResolvedEditorState: (reason: GetResolvedEditorStateReason) => Promise<ResolvedEditorState | undefined>;
68
68
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atlaskit/editor-core",
3
- "version": "204.4.7",
3
+ "version": "204.4.8",
4
4
  "description": "A package contains Atlassian editor core functionality",
5
5
  "publishConfig": {
6
6
  "registry": "https://registry.npmjs.org/"
@@ -59,7 +59,7 @@
59
59
  "@atlaskit/mention": "^24.1.0",
60
60
  "@atlaskit/platform-feature-flags": "^1.1.0",
61
61
  "@atlaskit/react-ufo": "^3.4.0",
62
- "@atlaskit/task-decision": "^19.0.0",
62
+ "@atlaskit/task-decision": "^19.1.0",
63
63
  "@atlaskit/tmp-editor-statsig": "^3.6.0",
64
64
  "@atlaskit/tokens": "^4.4.0",
65
65
  "@atlaskit/tooltip": "^20.0.0",
@@ -539,6 +539,10 @@
539
539
  "type": "boolean",
540
540
  "referenceOnly": true
541
541
  },
542
+ "platform_editor_non_macros_list_indent_fix": {
543
+ "type": "boolean",
544
+ "referenceOnly": true
545
+ },
542
546
  "platform_editor_remove_drag_handle_fix": {
543
547
  "type": "boolean",
544
548
  "referenceOnly": true