@atlaskit/editor-core 188.12.0 → 188.12.1

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.
Files changed (71) hide show
  1. package/CHANGELOG.md +9 -0
  2. package/dist/cjs/labs/next/presets/universal.js +12 -1
  3. package/dist/cjs/plugins/annotation/index.js +12 -1
  4. package/dist/cjs/plugins/annotation/pm-plugins/inline-comment.js +2 -1
  5. package/dist/cjs/plugins/annotation/pm-plugins/plugin-factory.js +5 -0
  6. package/dist/cjs/plugins/annotation/pm-plugins/reducer.js +2 -1
  7. package/dist/cjs/plugins/annotation/toolbar.js +2 -156
  8. package/dist/cjs/plugins/insert-block/ui/ToolbarInsertBlock/index.js +33 -31
  9. package/dist/cjs/plugins/layout/actions.js +20 -17
  10. package/dist/cjs/plugins/layout/index.js +6 -2
  11. package/dist/cjs/plugins/panel/index.js +1 -1
  12. package/dist/cjs/plugins/panel/toolbar.js +9 -7
  13. package/dist/cjs/plugins/paste/pm-plugins/analytics.js +0 -6
  14. package/dist/cjs/plugins/rank.js +1 -1
  15. package/dist/cjs/plugins/tasks-and-decisions/index.js +1 -1
  16. package/dist/cjs/plugins/tasks-and-decisions/pm-plugins/keymaps.js +104 -90
  17. package/dist/cjs/plugins/toolbar-lists-indentation/ui/onItemActivated.js +4 -2
  18. package/dist/cjs/version-wrapper.js +1 -1
  19. package/dist/es2019/labs/next/presets/universal.js +12 -1
  20. package/dist/es2019/plugins/annotation/index.js +14 -1
  21. package/dist/es2019/plugins/annotation/pm-plugins/inline-comment.js +2 -1
  22. package/dist/es2019/plugins/annotation/pm-plugins/plugin-factory.js +6 -0
  23. package/dist/es2019/plugins/annotation/pm-plugins/reducer.js +2 -1
  24. package/dist/es2019/plugins/annotation/toolbar.js +1 -156
  25. package/dist/es2019/plugins/insert-block/ui/ToolbarInsertBlock/index.js +4 -3
  26. package/dist/es2019/plugins/layout/actions.js +4 -3
  27. package/dist/es2019/plugins/layout/index.js +63 -57
  28. package/dist/es2019/plugins/panel/index.js +1 -1
  29. package/dist/es2019/plugins/panel/toolbar.js +9 -7
  30. package/dist/es2019/plugins/paste/pm-plugins/analytics.js +1 -4
  31. package/dist/es2019/plugins/rank.js +1 -1
  32. package/dist/es2019/plugins/tasks-and-decisions/index.js +1 -1
  33. package/dist/es2019/plugins/tasks-and-decisions/pm-plugins/keymaps.js +22 -14
  34. package/dist/es2019/plugins/toolbar-lists-indentation/ui/onItemActivated.js +4 -2
  35. package/dist/es2019/version-wrapper.js +1 -1
  36. package/dist/esm/labs/next/presets/universal.js +12 -1
  37. package/dist/esm/plugins/annotation/index.js +12 -1
  38. package/dist/esm/plugins/annotation/pm-plugins/inline-comment.js +2 -1
  39. package/dist/esm/plugins/annotation/pm-plugins/plugin-factory.js +5 -0
  40. package/dist/esm/plugins/annotation/pm-plugins/reducer.js +2 -1
  41. package/dist/esm/plugins/annotation/toolbar.js +1 -156
  42. package/dist/esm/plugins/insert-block/ui/ToolbarInsertBlock/index.js +33 -31
  43. package/dist/esm/plugins/layout/actions.js +15 -12
  44. package/dist/esm/plugins/layout/index.js +7 -3
  45. package/dist/esm/plugins/panel/index.js +1 -1
  46. package/dist/esm/plugins/panel/toolbar.js +9 -7
  47. package/dist/esm/plugins/paste/pm-plugins/analytics.js +1 -6
  48. package/dist/esm/plugins/rank.js +1 -1
  49. package/dist/esm/plugins/tasks-and-decisions/index.js +1 -1
  50. package/dist/esm/plugins/tasks-and-decisions/pm-plugins/keymaps.js +104 -90
  51. package/dist/esm/plugins/toolbar-lists-indentation/ui/onItemActivated.js +4 -2
  52. package/dist/esm/version-wrapper.js +1 -1
  53. package/dist/types/plugins/annotation/pm-plugins/types.d.ts +1 -0
  54. package/dist/types/plugins/insert-block/types.d.ts +3 -1
  55. package/dist/types/plugins/layout/actions.d.ts +2 -1
  56. package/dist/types/plugins/layout/index.d.ts +4 -0
  57. package/dist/types/plugins/panel/index.d.ts +2 -2
  58. package/dist/types/plugins/panel/toolbar.d.ts +5 -3
  59. package/dist/types/plugins/paste/pm-plugins/analytics.d.ts +0 -1
  60. package/dist/types/plugins/tasks-and-decisions/pm-plugins/keymaps.d.ts +7 -4
  61. package/dist/types/plugins/tasks-and-decisions/types.d.ts +5 -1
  62. package/dist/types-ts4.5/plugins/annotation/pm-plugins/types.d.ts +1 -0
  63. package/dist/types-ts4.5/plugins/insert-block/types.d.ts +3 -1
  64. package/dist/types-ts4.5/plugins/layout/actions.d.ts +2 -1
  65. package/dist/types-ts4.5/plugins/layout/index.d.ts +4 -0
  66. package/dist/types-ts4.5/plugins/panel/index.d.ts +2 -2
  67. package/dist/types-ts4.5/plugins/panel/toolbar.d.ts +5 -3
  68. package/dist/types-ts4.5/plugins/paste/pm-plugins/analytics.d.ts +0 -1
  69. package/dist/types-ts4.5/plugins/tasks-and-decisions/pm-plugins/keymaps.d.ts +7 -4
  70. package/dist/types-ts4.5/plugins/tasks-and-decisions/types.d.ts +3 -1
  71. package/package.json +6 -2
@@ -21,7 +21,6 @@ import ToolbarButton from '../../../../ui/ToolbarButton';
21
21
  import { separatorStyles, buttonGroupStyle, wrapperStyle } from '@atlaskit/editor-common/styles';
22
22
  import { akEditorMenuZIndex } from '@atlaskit/editor-shared-styles';
23
23
  import { showPlaceholderFloatingToolbar } from '../../../placeholder-text/actions';
24
- import { insertLayoutColumnsWithAnalytics } from '../../../layout/actions';
25
24
  import { insertTaskDecisionCommand } from '../../../tasks-and-decisions/commands';
26
25
  import { insertExpand } from '../../../expand/commands';
27
26
  import { ACTION, ACTION_SUBJECT, ACTION_SUBJECT_ID, EVENT_TYPE, INPUT_METHOD } from '@atlaskit/editor-common/analytics';
@@ -210,21 +209,24 @@ export var ToolbarInsertBlock = /*#__PURE__*/function (_React$PureComponent) {
210
209
  return true;
211
210
  });
212
211
  _defineProperty(_assertThisInitialized(_this), "insertLayoutColumns", function (inputMethod) {
213
- var editorView = _this.props.editorView;
214
- insertLayoutColumnsWithAnalytics(inputMethod)(editorView.state, editorView.dispatch);
212
+ var _pluginInjectionApi$l;
213
+ var _this$props3 = _this.props,
214
+ editorView = _this$props3.editorView,
215
+ pluginInjectionApi = _this$props3.pluginInjectionApi;
216
+ pluginInjectionApi === null || pluginInjectionApi === void 0 || (_pluginInjectionApi$l = pluginInjectionApi.layout) === null || _pluginInjectionApi$l === void 0 || _pluginInjectionApi$l.actions.insertLayoutColumns(inputMethod)(editorView.state, editorView.dispatch);
215
217
  return true;
216
218
  });
217
219
  _defineProperty(_assertThisInitialized(_this), "createStatus", function (inputMethod) {
218
220
  var _pluginInjectionApi$s, _pluginInjectionApi$s2;
219
- var _this$props3 = _this.props,
220
- pluginInjectionApi = _this$props3.pluginInjectionApi,
221
- editorView = _this$props3.editorView;
221
+ var _this$props4 = _this.props,
222
+ pluginInjectionApi = _this$props4.pluginInjectionApi,
223
+ editorView = _this$props4.editorView;
222
224
  return (_pluginInjectionApi$s = pluginInjectionApi === null || pluginInjectionApi === void 0 || (_pluginInjectionApi$s2 = pluginInjectionApi.status) === null || _pluginInjectionApi$s2 === void 0 || (_pluginInjectionApi$s2 = _pluginInjectionApi$s2.actions) === null || _pluginInjectionApi$s2 === void 0 ? void 0 : _pluginInjectionApi$s2.updateStatus(inputMethod)(editorView.state, editorView.dispatch)) !== null && _pluginInjectionApi$s !== void 0 ? _pluginInjectionApi$s : false;
223
225
  });
224
226
  _defineProperty(_assertThisInitialized(_this), "openMediaPicker", function (inputMethod) {
225
- var _this$props4 = _this.props,
226
- onShowMediaPicker = _this$props4.onShowMediaPicker,
227
- dispatchAnalyticsEvent = _this$props4.dispatchAnalyticsEvent;
227
+ var _this$props5 = _this.props,
228
+ onShowMediaPicker = _this$props5.onShowMediaPicker,
229
+ dispatchAnalyticsEvent = _this$props5.dispatchAnalyticsEvent;
228
230
  if (onShowMediaPicker) {
229
231
  onShowMediaPicker();
230
232
  if (dispatchAnalyticsEvent) {
@@ -252,11 +254,11 @@ export var ToolbarInsertBlock = /*#__PURE__*/function (_React$PureComponent) {
252
254
  });
253
255
  _defineProperty(_assertThisInitialized(_this), "insertHorizontalRule", function (inputMethod) {
254
256
  var _pluginInjectionApi$r, _pluginInjectionApi$r2;
255
- var _this$props5 = _this.props,
256
- _this$props5$editorVi = _this$props5.editorView,
257
- state = _this$props5$editorVi.state,
258
- dispatch = _this$props5$editorVi.dispatch,
259
- pluginInjectionApi = _this$props5.pluginInjectionApi;
257
+ var _this$props6 = _this.props,
258
+ _this$props6$editorVi = _this$props6.editorView,
259
+ state = _this$props6$editorVi.state,
260
+ dispatch = _this$props6$editorVi.dispatch,
261
+ pluginInjectionApi = _this$props6.pluginInjectionApi;
260
262
  return (_pluginInjectionApi$r = pluginInjectionApi === null || pluginInjectionApi === void 0 || (_pluginInjectionApi$r2 = pluginInjectionApi.rule) === null || _pluginInjectionApi$r2 === void 0 ? void 0 : _pluginInjectionApi$r2.actions.insertHorizontalRule(inputMethod)(state, dispatch)) !== null && _pluginInjectionApi$r !== void 0 ? _pluginInjectionApi$r : false;
261
263
  });
262
264
  _defineProperty(_assertThisInitialized(_this), "insertExpand", function () {
@@ -267,9 +269,9 @@ export var ToolbarInsertBlock = /*#__PURE__*/function (_React$PureComponent) {
267
269
  });
268
270
  _defineProperty(_assertThisInitialized(_this), "insertBlockType", function (itemName) {
269
271
  return function () {
270
- var _this$props6 = _this.props,
271
- editorView = _this$props6.editorView,
272
- onInsertBlockType = _this$props6.onInsertBlockType;
272
+ var _this$props7 = _this.props,
273
+ editorView = _this$props7.editorView,
274
+ onInsertBlockType = _this$props7.onInsertBlockType;
273
275
  var state = editorView.state,
274
276
  dispatch = editorView.dispatch;
275
277
  onInsertBlockType(itemName)(state, dispatch);
@@ -292,11 +294,11 @@ export var ToolbarInsertBlock = /*#__PURE__*/function (_React$PureComponent) {
292
294
  _defineProperty(_assertThisInitialized(_this), "onItemActivated", function (_ref2) {
293
295
  var item = _ref2.item,
294
296
  inputMethod = _ref2.inputMethod;
295
- var _this$props7 = _this.props,
296
- editorView = _this$props7.editorView,
297
- editorActions = _this$props7.editorActions,
298
- handleImageUpload = _this$props7.handleImageUpload,
299
- expandEnabled = _this$props7.expandEnabled;
297
+ var _this$props8 = _this.props,
298
+ editorView = _this$props8.editorView,
299
+ editorActions = _this$props8.editorActions,
300
+ handleImageUpload = _this$props8.handleImageUpload,
301
+ expandEnabled = _this$props8.expandEnabled;
300
302
 
301
303
  // need to do this before inserting nodes so scrollIntoView works properly
302
304
  if (!editorView.hasFocus()) {
@@ -412,12 +414,12 @@ export var ToolbarInsertBlock = /*#__PURE__*/function (_React$PureComponent) {
412
414
  key: "renderPopup",
413
415
  value: function renderPopup() {
414
416
  var emojiPickerOpen = this.state.emojiPickerOpen;
415
- var _this$props8 = this.props,
416
- popupsMountPoint = _this$props8.popupsMountPoint,
417
- popupsBoundariesElement = _this$props8.popupsBoundariesElement,
418
- popupsScrollableElement = _this$props8.popupsScrollableElement,
419
- emojiProvider = _this$props8.emojiProvider,
420
- replacePlusMenuWithElementBrowser = _this$props8.replacePlusMenuWithElementBrowser;
417
+ var _this$props9 = this.props,
418
+ popupsMountPoint = _this$props9.popupsMountPoint,
419
+ popupsBoundariesElement = _this$props9.popupsBoundariesElement,
420
+ popupsScrollableElement = _this$props9.popupsScrollableElement,
421
+ emojiProvider = _this$props9.emojiProvider,
422
+ replacePlusMenuWithElementBrowser = _this$props9.replacePlusMenuWithElementBrowser;
421
423
  var dropdownEmoji = this.state.dropdownItems.some(function (_ref4) {
422
424
  var name = _ref4.value.name;
423
425
  return name === 'emoji';
@@ -454,9 +456,9 @@ export var ToolbarInsertBlock = /*#__PURE__*/function (_React$PureComponent) {
454
456
  buttons = _this$state.buttons,
455
457
  dropdownItems = _this$state.dropdownItems,
456
458
  emojiPickerOpen = _this$state.emojiPickerOpen;
457
- var _this$props9 = this.props,
458
- isDisabled = _this$props9.isDisabled,
459
- isReducedSpacing = _this$props9.isReducedSpacing;
459
+ var _this$props10 = this.props,
460
+ isDisabled = _this$props10.isDisabled,
461
+ isReducedSpacing = _this$props10.isReducedSpacing;
460
462
  if (buttons.length === 0 && dropdownItems.length === 0) {
461
463
  return null;
462
464
  }
@@ -6,8 +6,9 @@ import { Fragment, Slice } from '@atlaskit/editor-prosemirror/model';
6
6
  import { TextSelection, NodeSelection } from '@atlaskit/editor-prosemirror/state';
7
7
  import { flatmap, mapChildren } from '../../utils/slice';
8
8
  import { getStepRange, isEmptyDocument } from '@atlaskit/editor-common/utils';
9
- import { ACTION, ACTION_SUBJECT, ACTION_SUBJECT_ID, EVENT_TYPE } from '../analytics/types/enums';
10
- import { addAnalytics, withAnalytics } from '../analytics/utils';
9
+ import { ACTION, ACTION_SUBJECT, ACTION_SUBJECT_ID, EVENT_TYPE } from '@atlaskit/editor-common/analytics';
10
+ import { addAnalytics } from '../analytics/utils';
11
+ import { withAnalytics } from '@atlaskit/editor-common/editor-analytics';
11
12
  import { LAYOUT_TYPE } from '../analytics/types/node-events';
12
13
  import { pluginKey } from './pm-plugins/plugin-key';
13
14
  export var ONE_COL_LAYOUTS = ['single'];
@@ -79,16 +80,18 @@ export var insertLayoutColumns = function insertLayoutColumns(state, dispatch) {
79
80
  }
80
81
  return true;
81
82
  };
82
- export var insertLayoutColumnsWithAnalytics = function insertLayoutColumnsWithAnalytics(inputMethod) {
83
- return withAnalytics({
84
- action: ACTION.INSERTED,
85
- actionSubject: ACTION_SUBJECT.DOCUMENT,
86
- actionSubjectId: ACTION_SUBJECT_ID.LAYOUT,
87
- attributes: {
88
- inputMethod: inputMethod
89
- },
90
- eventType: EVENT_TYPE.TRACK
91
- })(insertLayoutColumns);
83
+ export var insertLayoutColumnsWithAnalytics = function insertLayoutColumnsWithAnalytics(editorAnalyticsAPI) {
84
+ return function (inputMethod) {
85
+ return withAnalytics(editorAnalyticsAPI, {
86
+ action: ACTION.INSERTED,
87
+ actionSubject: ACTION_SUBJECT.DOCUMENT,
88
+ actionSubjectId: ACTION_SUBJECT_ID.LAYOUT,
89
+ attributes: {
90
+ inputMethod: inputMethod
91
+ },
92
+ eventType: EVENT_TYPE.TRACK
93
+ })(insertLayoutColumns);
94
+ };
92
95
  };
93
96
 
94
97
  /**
@@ -2,13 +2,14 @@ import React from 'react';
2
2
  import { layoutColumn, layoutSection } from '@atlaskit/adf-schema';
3
3
  import { default as createLayoutPlugin } from './pm-plugins/main';
4
4
  import { buildToolbar } from './toolbar';
5
- import { createDefaultLayoutSection } from './actions';
5
+ import { createDefaultLayoutSection, insertLayoutColumnsWithAnalytics } from './actions';
6
6
  import { IconLayout } from '@atlaskit/editor-common/quick-insert';
7
7
  import { ACTION, ACTION_SUBJECT, ACTION_SUBJECT_ID, EVENT_TYPE, INPUT_METHOD } from '@atlaskit/editor-common/analytics';
8
8
  import { messages } from '../insert-block/ui/ToolbarInsertBlock/messages';
9
9
  import { pluginKey } from './pm-plugins/plugin-key';
10
10
  export { pluginKey };
11
11
  var layoutPlugin = function layoutPlugin(_ref) {
12
+ var _api$analytics;
12
13
  var _ref$config = _ref.config,
13
14
  options = _ref$config === void 0 ? {} : _ref$config,
14
15
  api = _ref.api;
@@ -31,6 +32,9 @@ var layoutPlugin = function layoutPlugin(_ref) {
31
32
  }
32
33
  }];
33
34
  },
35
+ actions: {
36
+ insertLayoutColumns: insertLayoutColumnsWithAnalytics(api === null || api === void 0 || (_api$analytics = api.analytics) === null || _api$analytics === void 0 ? void 0 : _api$analytics.actions)
37
+ },
34
38
  pluginsOptions: {
35
39
  floatingToolbar: function floatingToolbar(state, intl) {
36
40
  var _ref2 = pluginKey.getState(state),
@@ -56,9 +60,9 @@ var layoutPlugin = function layoutPlugin(_ref) {
56
60
  return /*#__PURE__*/React.createElement(IconLayout, null);
57
61
  },
58
62
  action: function action(insert, state) {
59
- var _api$analytics;
63
+ var _api$analytics2;
60
64
  var tr = insert(createDefaultLayoutSection(state));
61
- api === null || api === void 0 || (_api$analytics = api.analytics) === null || _api$analytics === void 0 || (_api$analytics = _api$analytics.actions) === null || _api$analytics === void 0 || _api$analytics.attachAnalyticsEvent({
65
+ api === null || api === void 0 || (_api$analytics2 = api.analytics) === null || _api$analytics2 === void 0 || (_api$analytics2 = _api$analytics2.actions) === null || _api$analytics2 === void 0 || _api$analytics2.attachAnalyticsEvent({
62
66
  action: ACTION.INSERTED,
63
67
  actionSubject: ACTION_SUBJECT.DOCUMENT,
64
68
  actionSubjectId: ACTION_SUBJECT_ID.LAYOUT,
@@ -158,7 +158,7 @@ var panelPlugin = function panelPlugin(_ref) {
158
158
  return quickInsertOptions;
159
159
  },
160
160
  floatingToolbar: function floatingToolbar(state, intl, providerFactory) {
161
- return getToolbarConfig(state, intl, options, providerFactory, api === null || api === void 0 ? void 0 : api.decorations.actions.hoverDecoration);
161
+ return getToolbarConfig(state, intl, options, providerFactory, api);
162
162
  }
163
163
  }
164
164
  };
@@ -17,7 +17,8 @@ import { findPanel } from './utils';
17
17
  import { findDomRefAtPos } from '@atlaskit/editor-prosemirror/utils';
18
18
  import { DEFAULT_BORDER_COLOR } from '@atlaskit/editor-common/ui-color';
19
19
  import { PanelType } from '@atlaskit/adf-schema';
20
- import { ACTION, ACTION_SUBJECT, EVENT_TYPE, ACTION_SUBJECT_ID, withAnalytics } from '../analytics';
20
+ import { ACTION, ACTION_SUBJECT, EVENT_TYPE, ACTION_SUBJECT_ID } from '@atlaskit/editor-common/analytics';
21
+ import { withAnalytics } from '@atlaskit/editor-common/editor-analytics';
21
22
  import { messages } from './message';
22
23
  export var panelIconMap = (_panelIconMap = {}, _defineProperty(_panelIconMap, PanelType.INFO, {
23
24
  shortName: ':info:',
@@ -38,7 +39,7 @@ export var panelIconMap = (_panelIconMap = {}, _defineProperty(_panelIconMap, Pa
38
39
  shortName: ':tip:',
39
40
  id: 'atlassian-tip'
40
41
  }), _panelIconMap);
41
- export var getToolbarItems = function getToolbarItems(formatMessage, panelNodeType, isCustomPanelEnabled, isCustomPanelEditable, providerFactory, hoverDecoration, activePanelType, activePanelColor, activePanelIcon, state) {
42
+ export var getToolbarItems = function getToolbarItems(formatMessage, panelNodeType, isCustomPanelEnabled, isCustomPanelEditable, providerFactory, hoverDecoration, editorAnalyticsAPI, activePanelType, activePanelColor, activePanelIcon, state) {
42
43
  // TODO: ED-14403 investigate why these titles are not getting translated for the tooltips
43
44
  var items = [{
44
45
  id: 'editor.panel.info',
@@ -111,7 +112,7 @@ export var getToolbarItems = function getToolbarItems(formatMessage, panelNodeTy
111
112
  },
112
113
  eventType: EVENT_TYPE.TRACK
113
114
  };
114
- withAnalytics(payload)(changePanelType(PanelType.CUSTOM, _objectSpread({
115
+ withAnalytics(editorAnalyticsAPI, payload)(changePanelType(PanelType.CUSTOM, _objectSpread({
115
116
  color: color
116
117
  }, previousEmoji), isCustomPanelEnabled))(state, dispatch);
117
118
  return false;
@@ -142,7 +143,7 @@ export var getToolbarItems = function getToolbarItems(formatMessage, panelNodeTy
142
143
  },
143
144
  eventType: EVENT_TYPE.TRACK
144
145
  };
145
- withAnalytics(payload)(changePanelType(PanelType.CUSTOM, {
146
+ withAnalytics(editorAnalyticsAPI, payload)(changePanelType(PanelType.CUSTOM, {
146
147
  emoji: emoji.shortName,
147
148
  emojiId: emoji.id,
148
149
  emojiText: emoji.fallback
@@ -168,7 +169,7 @@ export var getToolbarItems = function getToolbarItems(formatMessage, panelNodeTy
168
169
  },
169
170
  eventType: EVENT_TYPE.TRACK
170
171
  };
171
- withAnalytics(payload)(changePanelType(PanelType.CUSTOM, {
172
+ withAnalytics(editorAnalyticsAPI, payload)(changePanelType(PanelType.CUSTOM, {
172
173
  emoji: undefined,
173
174
  emojiId: undefined,
174
175
  emojiText: undefined
@@ -253,10 +254,11 @@ export var getToolbarItems = function getToolbarItems(formatMessage, panelNodeTy
253
254
  export var getToolbarConfig = function getToolbarConfig(state, intl) {
254
255
  var options = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : {};
255
256
  var providerFactory = arguments.length > 3 ? arguments[3] : undefined;
256
- var hoverDecoration = arguments.length > 4 ? arguments[4] : undefined;
257
+ var api = arguments.length > 4 ? arguments[4] : undefined;
257
258
  var formatMessage = intl.formatMessage;
258
259
  var panelObject = findPanel(state);
259
260
  if (panelObject) {
261
+ var _api$analytics;
260
262
  var nodeType = state.schema.nodes.panel;
261
263
  var _panelObject$node$att = panelObject.node.attrs,
262
264
  panelType = _panelObject$node$att.panelType,
@@ -267,7 +269,7 @@ export var getToolbarConfig = function getToolbarConfig(state, intl) {
267
269
  };
268
270
 
269
271
  // force toolbar to be turned on
270
- var items = getToolbarItems(formatMessage, nodeType, options.allowCustomPanel || false, options.allowCustomPanel && options.allowCustomPanelEdit || false, providerFactory, hoverDecoration, panelType, options.allowCustomPanel ? panelColor : undefined, options.allowCustomPanel ? panelIcon || isStandardPanel(panelType) : undefined, state);
272
+ var items = getToolbarItems(formatMessage, nodeType, options.allowCustomPanel || false, options.allowCustomPanel && options.allowCustomPanelEdit || false, providerFactory, api === null || api === void 0 ? void 0 : api.decorations.actions.hoverDecoration, api === null || api === void 0 || (_api$analytics = api.analytics) === null || _api$analytics === void 0 ? void 0 : _api$analytics.actions, panelType, options.allowCustomPanel ? panelColor : undefined, options.allowCustomPanel ? panelIcon || isStandardPanel(panelType) : undefined, state);
271
273
  var getDomRef = function getDomRef(editorView) {
272
274
  var domAtPos = editorView.domAtPos.bind(editorView);
273
275
  var element = findDomRefAtPos(panelObject.pos, domAtPos);
@@ -2,7 +2,7 @@ import _toConsumableArray from "@babel/runtime/helpers/toConsumableArray";
2
2
  import _defineProperty from "@babel/runtime/helpers/defineProperty";
3
3
  function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
4
4
  function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
5
- import { ACTION, INPUT_METHOD, EVENT_TYPE, ACTION_SUBJECT, ACTION_SUBJECT_ID, addAnalytics, PasteTypes, PasteContents, withAnalytics } from '../../analytics';
5
+ import { ACTION, INPUT_METHOD, EVENT_TYPE, ACTION_SUBJECT, ACTION_SUBJECT_ID, addAnalytics, PasteTypes, PasteContents } from '../../analytics';
6
6
  import { getPasteSource } from '../util';
7
7
  import { handlePasteAsPlainText, handlePasteIntoTaskOrDecisionOrPanel, handleCodeBlock, handleMediaSingle, handlePastePreservingMarks, handleMarkdown, handleRichText, handleExpandPasteInTable, handleSelectedTable, handlePasteLinkOnSelectedText, handlePasteIntoCaption, handlePastePanelOrDecisionContentIntoList, handlePasteNonNestableBlockNodesIntoList } from '../handlers';
8
8
  import { findParentNode } from '@atlaskit/editor-prosemirror/utils';
@@ -212,11 +212,6 @@ export function sendPasteAnalyticsEvent(view, event, slice, pasteContext) {
212
212
  var payload = createPasteAnalyticsPayload(view, event, slice, pasteContext);
213
213
  view.dispatch(addAnalytics(view.state, view.state.tr, payload));
214
214
  }
215
- export function pasteCommandWithAnalytics(view, event, slice, pasteContext) {
216
- return withAnalytics(function () {
217
- return createPasteAnalyticsPayload(view, event, slice, pasteContext);
218
- });
219
- }
220
215
  export var handlePasteAsPlainTextWithAnalytics = function handlePasteAsPlainTextWithAnalytics(view, event, slice) {
221
216
  return injectAnalyticsPayloadBeforeCommand(createPasteAnalyticsPayloadBySelection(event, slice, {
222
217
  type: PasteTypes.plain,
@@ -13,7 +13,7 @@ export default {
13
13
  'mediaKeymap',
14
14
  // selection keymap needs to be above gap cursor keymap so it can set node selections from
15
15
  // left/right arrows
16
- 'selectionKeymap', 'gapCursorKeymap', 'gapCursor', 'syncUrlText', 'fakeCursorToolbarPlugin', 'hyperLink', 'table', 'tableDecorations', 'hyperlinkInputRule', 'tablePMColResizing', 'hyperlinkKeymap', 'tableColResizing', 'undoRedoKeyMap', 'blockTypeKeyMap', 'tableEditing', 'filterStepsPlugin', 'pmCollab', 'collab', 'ruleInputRule', 'ruleKeymap', 'panel', 'media', 'mediaSingleKeymap', 'mediaEditor', 'unsupportedContent', 'jiraIssue', 'fakeTextCursor', 'helpDialog', 'helpDialogKeymap', 'macro', 'expand', 'extension', 'layout', 'contextPanel', 'floatingToolbar', 'clearMarksOnChange', 'reactNodeView', 'history', 'undoRedoPlugin', 'codeBlockIndent', 'placeholder', 'width', 'maxContentSize', 'multilineContent', 'grid', 'mobileDimensions', 'scrollGutterPlugin', 'analytics', 'findReplace', 'selection', 'avatarGroup', 'viewUpdateSubscription', 'beforePrimaryToolbar', 'inlineCode'],
16
+ 'selectionKeymap', 'gapCursorKeymap', 'gapCursor', 'syncUrlText', 'fakeCursorToolbarPlugin', 'hyperLink', 'table', 'tableDecorations', 'hyperlinkInputRule', 'tablePMColResizing', 'hyperlinkKeymap', 'tableColResizing', 'undoRedoKeyMap', 'blockTypeKeyMap', 'tableEditing', 'filterStepsPlugin', 'pmCollab', 'collab', 'ruleInputRule', 'ruleKeymap', 'panel', 'media', 'mediaSingleKeymap', 'mediaEditor', 'unsupportedContent', 'jiraIssue', 'fakeTextCursor', 'helpDialog', 'helpDialogKeymap', 'macro', 'expand', 'extension', 'layout', 'contextPanel', 'selectionToolbar', 'floatingToolbar', 'clearMarksOnChange', 'reactNodeView', 'history', 'undoRedoPlugin', 'codeBlockIndent', 'placeholder', 'width', 'maxContentSize', 'multilineContent', 'grid', 'mobileDimensions', 'scrollGutterPlugin', 'analytics', 'findReplace', 'selection', 'avatarGroup', 'viewUpdateSubscription', 'beforePrimaryToolbar', 'inlineCode'],
17
17
  nodes: ['doc', 'paragraph', 'text', 'bulletList', 'orderedList', 'listItem', 'heading', 'blockquote', 'codeBlock', 'rule', 'panel', 'mention', 'confluenceUnsupportedBlock', 'confluenceUnsupportedInline', 'unsupportedBlock', 'unsupportedInline', 'confluenceJiraIssue', 'hardBreak', 'emoji', 'placeholder', 'mediaSingle', 'mediaGroup', 'table', 'expand', 'nestedExpand', 'media', 'tableHeader', 'decisionList', 'tableRow', 'decisionItem', 'tableCell', 'taskList', 'taskItem', 'extension', 'bodiedExtension', 'inlineExtension', 'layoutSection', 'layoutColumn', 'inlineCard', 'blockCard', 'embedCard'],
18
18
  marks: [
19
19
  // Fragment mark is both for inline and block elements
@@ -72,7 +72,7 @@ var tasksAndDecisionsPlugin = function tasksAndDecisionsPlugin(_ref2) {
72
72
  name: 'tasksAndDecisionsKeyMap',
73
73
  plugin: function plugin(_ref5) {
74
74
  var schema = _ref5.schema;
75
- return keymap(schema, allowNestedTasks, consumeTabs);
75
+ return keymap(schema, api, allowNestedTasks, consumeTabs);
76
76
  }
77
77
  } // Needs to be after "save-on-enter"
78
78
  ];
@@ -9,7 +9,8 @@ import { SetAttrsStep } from '@atlaskit/adf-schema/steps';
9
9
  import { findParentNodeOfType, findParentNodeOfTypeClosestToPos } from '@atlaskit/editor-prosemirror/utils';
10
10
  import { uuid } from '@atlaskit/adf-schema';
11
11
  import { filterCommand as filter, isEmptySelectionAtStart, isEmptySelectionAtEnd, deleteEmptyParagraphAndMoveBlockUp } from '@atlaskit/editor-common/utils';
12
- import { ACTION, ACTION_SUBJECT, ACTION_SUBJECT_ID, EVENT_TYPE, INDENT_DIRECTION, INDENT_TYPE, INPUT_METHOD, withAnalytics } from '../../analytics';
12
+ import { ACTION, ACTION_SUBJECT, ACTION_SUBJECT_ID, EVENT_TYPE, INDENT_DIRECTION, INDENT_TYPE, INPUT_METHOD } from '@atlaskit/editor-common/analytics';
13
+ import { withAnalytics } from '@atlaskit/editor-common/editor-analytics';
13
14
  import { insertTaskDecisionWithAnalytics } from '../commands';
14
15
  import { joinAtCut, liftSelection, wrapSelectionInTaskList } from './commands';
15
16
  import { getBlockRange, getCurrentIndentLevel, isActionOrDecisionItem, isActionOrDecisionList, isEmptyTaskDecision, isInsideTask, isInsideTaskOrDecisionItem, liftBlock, walkOut, getTaskItemIndex, isInsideDecision, isTable } from './helpers';
@@ -88,16 +89,18 @@ var joinTaskDecisionFollowing = function joinTaskDecisionFollowing(state, dispat
88
89
  }
89
90
  return false;
90
91
  };
91
- export var getUnindentCommand = function getUnindentCommand() {
92
- var inputMethod = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : INPUT_METHOD.KEYBOARD;
93
- return filter(isInsideTask, function (state, dispatch) {
94
- var normalizedSelection = normalizeTaskItemsSelection(state.selection);
95
- var curIndentLevel = getCurrentIndentLevel(normalizedSelection);
96
- if (!curIndentLevel || curIndentLevel === 1) {
97
- return false;
98
- }
99
- return withAnalytics(indentationAnalytics(curIndentLevel, INDENT_DIRECTION.OUTDENT, inputMethod))(autoJoin(liftSelection, ['taskList']))(state, dispatch);
100
- });
92
+ export var getUnindentCommand = function getUnindentCommand(editorAnalyticsAPI) {
93
+ return function () {
94
+ var inputMethod = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : INPUT_METHOD.KEYBOARD;
95
+ return filter(isInsideTask, function (state, dispatch) {
96
+ var normalizedSelection = normalizeTaskItemsSelection(state.selection);
97
+ var curIndentLevel = getCurrentIndentLevel(normalizedSelection);
98
+ if (!curIndentLevel || curIndentLevel === 1) {
99
+ return false;
100
+ }
101
+ return withAnalytics(editorAnalyticsAPI, indentationAnalytics(curIndentLevel, INDENT_DIRECTION.OUTDENT, inputMethod))(autoJoin(liftSelection, ['taskList']))(state, dispatch);
102
+ });
103
+ };
101
104
  };
102
105
 
103
106
  // if selection is decision item or first action item in table cell
@@ -114,53 +117,59 @@ var shouldLetTabThroughInTable = function shouldLetTabThroughInTable(state) {
114
117
  }
115
118
  return false;
116
119
  };
117
- export var getIndentCommand = function getIndentCommand() {
118
- var inputMethod = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : INPUT_METHOD.KEYBOARD;
119
- return filter(isInsideTask, function (state, dispatch) {
120
- var normalizedSelection = normalizeTaskItemsSelection(state.selection);
121
- var curIndentLevel = getCurrentIndentLevel(normalizedSelection);
122
- if (!curIndentLevel || curIndentLevel >= 6) {
123
- return true;
124
- }
125
- return withAnalytics(indentationAnalytics(curIndentLevel, INDENT_DIRECTION.INDENT, inputMethod))(autoJoin(wrapSelectionInTaskList, ['taskList']))(state, dispatch);
126
- });
120
+ export var getIndentCommand = function getIndentCommand(editorAnalyticsAPI) {
121
+ return function () {
122
+ var inputMethod = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : INPUT_METHOD.KEYBOARD;
123
+ return filter(isInsideTask, function (state, dispatch) {
124
+ var normalizedSelection = normalizeTaskItemsSelection(state.selection);
125
+ var curIndentLevel = getCurrentIndentLevel(normalizedSelection);
126
+ if (!curIndentLevel || curIndentLevel >= 6) {
127
+ return true;
128
+ }
129
+ return withAnalytics(editorAnalyticsAPI, indentationAnalytics(curIndentLevel, INDENT_DIRECTION.INDENT, inputMethod))(autoJoin(wrapSelectionInTaskList, ['taskList']))(state, dispatch);
130
+ });
131
+ };
127
132
  };
128
- var backspaceFrom = function backspaceFrom($from) {
129
- return function (state, dispatch) {
130
- // previous was empty, just delete backwards
131
- var taskBefore = $from.doc.resolve($from.before());
132
- if (taskBefore.nodeBefore && isActionOrDecisionItem(taskBefore.nodeBefore) && taskBefore.nodeBefore.nodeSize === 2) {
133
- return false;
134
- }
133
+ var backspaceFrom = function backspaceFrom(editorAnalyticsAPI) {
134
+ return function ($from) {
135
+ return function (state, dispatch) {
136
+ // previous was empty, just delete backwards
137
+ var taskBefore = $from.doc.resolve($from.before());
138
+ if (taskBefore.nodeBefore && isActionOrDecisionItem(taskBefore.nodeBefore) && taskBefore.nodeBefore.nodeSize === 2) {
139
+ return false;
140
+ }
135
141
 
136
- // if nested, just unindent
137
- var _state$schema$nodes3 = state.schema.nodes,
138
- taskList = _state$schema$nodes3.taskList,
139
- paragraph = _state$schema$nodes3.paragraph;
140
- if ($from.node($from.depth - 2).type === taskList) {
141
- return getUnindentCommand()(state, dispatch);
142
- }
142
+ // if nested, just unindent
143
+ var _state$schema$nodes3 = state.schema.nodes,
144
+ taskList = _state$schema$nodes3.taskList,
145
+ paragraph = _state$schema$nodes3.paragraph;
146
+ if ($from.node($from.depth - 2).type === taskList) {
147
+ return getUnindentCommand(editorAnalyticsAPI)()(state, dispatch);
148
+ }
143
149
 
144
- // bottom level, should "unwrap" taskItem contents into paragraph
145
- // we achieve this by slicing the content out, and replacing
146
- if (actionDecisionFollowsOrNothing($from)) {
147
- if (dispatch) {
148
- var taskContent = state.doc.slice($from.start(), $from.end()).content;
150
+ // bottom level, should "unwrap" taskItem contents into paragraph
151
+ // we achieve this by slicing the content out, and replacing
152
+ if (actionDecisionFollowsOrNothing($from)) {
153
+ if (dispatch) {
154
+ var taskContent = state.doc.slice($from.start(), $from.end()).content;
149
155
 
150
- // might be end of document after
151
- var slice = taskContent.size ? paragraph.createChecked(undefined, taskContent) : paragraph.createChecked();
152
- dispatch(splitListItemWith(state.tr, slice, $from, true));
156
+ // might be end of document after
157
+ var slice = taskContent.size ? paragraph.createChecked(undefined, taskContent) : paragraph.createChecked();
158
+ dispatch(splitListItemWith(state.tr, slice, $from, true));
159
+ }
160
+ return true;
153
161
  }
154
- return true;
155
- }
156
- return false;
162
+ return false;
163
+ };
157
164
  };
158
165
  };
159
- var backspace = filter(isEmptySelectionAtStart, autoJoin(chainCommands(function (state, dispatch) {
160
- return joinAtCut(state.selection.$from)(state, dispatch);
161
- }, filter(isInsideTaskOrDecisionItem, function (state, dispatch) {
162
- return backspaceFrom(state.selection.$from)(state, dispatch);
163
- })), ['taskList', 'decisionList']));
166
+ var backspace = function backspace(editorAnalyticsAPI) {
167
+ return filter(isEmptySelectionAtStart, autoJoin(chainCommands(function (state, dispatch) {
168
+ return joinAtCut(state.selection.$from)(state, dispatch);
169
+ }, filter(isInsideTaskOrDecisionItem, function (state, dispatch) {
170
+ return backspaceFrom(editorAnalyticsAPI)(state.selection.$from)(state, dispatch);
171
+ })), ['taskList', 'decisionList']));
172
+ };
164
173
  var unindentTaskOrUnwrapTaskDecisionFollowing = function unindentTaskOrUnwrapTaskDecisionFollowing(state, dispatch) {
165
174
  var $from = state.selection.$from,
166
175
  _state$schema$nodes4 = state.schema.nodes,
@@ -270,42 +279,44 @@ var splitListItem = function splitListItem(state, dispatch) {
270
279
  }
271
280
  return false;
272
281
  };
273
- var enter = filter(isInsideTaskOrDecisionItem, chainCommands(filter(isEmptyTaskDecision, chainCommands(getUnindentCommand(), splitListItem)), function (state, dispatch) {
274
- var selection = state.selection,
275
- schema = state.schema;
276
- var taskItem = schema.nodes.taskItem;
277
- var $from = selection.$from,
278
- $to = selection.$to;
279
- var node = $from.node($from.depth);
280
- var nodeType = node && node.type;
281
- var listType = nodeType === taskItem ? 'taskList' : 'decisionList';
282
- var addItem = function addItem(_ref) {
283
- var tr = _ref.tr,
284
- itemLocalId = _ref.itemLocalId;
285
- // ED-8932: When cursor is at the beginning of a task item, instead of split, we insert above.
286
- if ($from.pos === $to.pos && $from.parentOffset === 0) {
287
- var newTask = nodeType.createAndFill({
288
- localId: itemLocalId
289
- });
290
- if (newTask) {
291
- // Current position will point to text node, but we want to insert above the taskItem node
292
- return tr.insert($from.pos - 1, newTask);
282
+ var enter = function enter(editorAnalyticsAPI) {
283
+ return filter(isInsideTaskOrDecisionItem, chainCommands(filter(isEmptyTaskDecision, chainCommands(getUnindentCommand(editorAnalyticsAPI)(), splitListItem)), function (state, dispatch) {
284
+ var selection = state.selection,
285
+ schema = state.schema;
286
+ var taskItem = schema.nodes.taskItem;
287
+ var $from = selection.$from,
288
+ $to = selection.$to;
289
+ var node = $from.node($from.depth);
290
+ var nodeType = node && node.type;
291
+ var listType = nodeType === taskItem ? 'taskList' : 'decisionList';
292
+ var addItem = function addItem(_ref) {
293
+ var tr = _ref.tr,
294
+ itemLocalId = _ref.itemLocalId;
295
+ // ED-8932: When cursor is at the beginning of a task item, instead of split, we insert above.
296
+ if ($from.pos === $to.pos && $from.parentOffset === 0) {
297
+ var newTask = nodeType.createAndFill({
298
+ localId: itemLocalId
299
+ });
300
+ if (newTask) {
301
+ // Current position will point to text node, but we want to insert above the taskItem node
302
+ return tr.insert($from.pos - 1, newTask);
303
+ }
293
304
  }
305
+ return tr.split($from.pos, 1, [{
306
+ type: nodeType,
307
+ attrs: {
308
+ localId: itemLocalId
309
+ }
310
+ }]);
311
+ };
312
+ var insertTr = insertTaskDecisionWithAnalytics(state, listType, INPUT_METHOD.KEYBOARD, addItem);
313
+ if (insertTr && dispatch) {
314
+ insertTr.scrollIntoView();
315
+ dispatch(insertTr);
294
316
  }
295
- return tr.split($from.pos, 1, [{
296
- type: nodeType,
297
- attrs: {
298
- localId: itemLocalId
299
- }
300
- }]);
301
- };
302
- var insertTr = insertTaskDecisionWithAnalytics(state, listType, INPUT_METHOD.KEYBOARD, addItem);
303
- if (insertTr && dispatch) {
304
- insertTr.scrollIntoView();
305
- dispatch(insertTr);
306
- }
307
- return true;
308
- }));
317
+ return true;
318
+ }));
319
+ };
309
320
  var cmdOptEnter = filter(isInsideTaskOrDecisionItem, function (state, dispatch) {
310
321
  var selection = state.selection,
311
322
  schema = state.schema;
@@ -326,17 +337,20 @@ var cmdOptEnter = filter(isInsideTaskOrDecisionItem, function (state, dispatch)
326
337
  }
327
338
  return true;
328
339
  });
329
- export function keymapPlugin(schema, allowNestedTasks, consumeTabs) {
340
+ export function keymapPlugin(schema, api, allowNestedTasks, consumeTabs) {
341
+ var _api$analytics3, _api$analytics4;
330
342
  var indentHandlers = {
331
343
  'Shift-Tab': filter([isInsideTaskOrDecisionItem, function (state) {
332
344
  return !shouldLetTabThroughInTable(state);
333
345
  }], function (state, dispatch) {
334
- return getUnindentCommand(INPUT_METHOD.KEYBOARD)(state, dispatch) || !!consumeTabs;
346
+ var _api$analytics;
347
+ return getUnindentCommand(api === null || api === void 0 || (_api$analytics = api.analytics) === null || _api$analytics === void 0 ? void 0 : _api$analytics.actions)(INPUT_METHOD.KEYBOARD)(state, dispatch) || !!consumeTabs;
335
348
  }),
336
349
  Tab: filter([isInsideTaskOrDecisionItem, function (state) {
337
350
  return !shouldLetTabThroughInTable(state);
338
351
  }], function (state, dispatch) {
339
- return getIndentCommand(INPUT_METHOD.KEYBOARD)(state, dispatch) || !!consumeTabs;
352
+ var _api$analytics2;
353
+ return getIndentCommand(api === null || api === void 0 || (_api$analytics2 = api.analytics) === null || _api$analytics2 === void 0 ? void 0 : _api$analytics2.actions)(INPUT_METHOD.KEYBOARD)(state, dispatch) || !!consumeTabs;
340
354
  })
341
355
  };
342
356
  var defaultHandlers = consumeTabs ? {
@@ -344,10 +358,10 @@ export function keymapPlugin(schema, allowNestedTasks, consumeTabs) {
344
358
  Tab: isInsideTaskOrDecisionItem
345
359
  } : {};
346
360
  var keymaps = _objectSpread(_defineProperty({
347
- Backspace: backspace,
361
+ Backspace: backspace(api === null || api === void 0 || (_api$analytics3 = api.analytics) === null || _api$analytics3 === void 0 ? void 0 : _api$analytics3.actions),
348
362
  Delete: deleteForwards,
349
363
  'Ctrl-d': deleteForwards,
350
- Enter: enter
364
+ Enter: enter(api === null || api === void 0 || (_api$analytics4 = api.analytics) === null || _api$analytics4 === void 0 ? void 0 : _api$analytics4.actions)
351
365
  }, toggleTaskItemCheckbox.common, cmdOptEnter), allowNestedTasks ? indentHandlers : defaultHandlers);
352
366
  return keymap(keymaps);
353
367
  }
@@ -24,7 +24,8 @@ export var onItemActivated = function onItemActivated(pluginInjectionApi) {
24
24
  pluginInjectionApi === null || pluginInjectionApi === void 0 || pluginInjectionApi.core.actions.execute(pluginInjectionApi === null || pluginInjectionApi === void 0 ? void 0 : pluginInjectionApi.list.commands.indentList(INPUT_METHOD.TOOLBAR));
25
25
  }
26
26
  if (node === 'taskList') {
27
- indentTaskList(INPUT_METHOD.TOOLBAR)(editorView.state, editorView.dispatch);
27
+ var _pluginInjectionApi$a;
28
+ indentTaskList(pluginInjectionApi === null || pluginInjectionApi === void 0 || (_pluginInjectionApi$a = pluginInjectionApi.analytics) === null || _pluginInjectionApi$a === void 0 ? void 0 : _pluginInjectionApi$a.actions)(INPUT_METHOD.TOOLBAR)(editorView.state, editorView.dispatch);
28
29
  }
29
30
  break;
30
31
  }
@@ -39,7 +40,8 @@ export var onItemActivated = function onItemActivated(pluginInjectionApi) {
39
40
  pluginInjectionApi === null || pluginInjectionApi === void 0 || pluginInjectionApi.core.actions.execute(pluginInjectionApi === null || pluginInjectionApi === void 0 ? void 0 : pluginInjectionApi.list.commands.outdentList(INPUT_METHOD.TOOLBAR));
40
41
  }
41
42
  if (_node === 'taskList') {
42
- outdentTaskList(INPUT_METHOD.TOOLBAR)(editorView.state, editorView.dispatch);
43
+ var _pluginInjectionApi$a2;
44
+ outdentTaskList(pluginInjectionApi === null || pluginInjectionApi === void 0 || (_pluginInjectionApi$a2 = pluginInjectionApi.analytics) === null || _pluginInjectionApi$a2 === void 0 ? void 0 : _pluginInjectionApi$a2.actions)(INPUT_METHOD.TOOLBAR)(editorView.state, editorView.dispatch);
43
45
  }
44
46
  break;
45
47
  }
@@ -1,5 +1,5 @@
1
1
  export var name = "@atlaskit/editor-core";
2
- export var version = "188.12.0";
2
+ export var version = "188.12.1";
3
3
  export var nextMajorVersion = function nextMajorVersion() {
4
4
  return [Number(version.split('.')[0]) + 1, 0, 0].join('.');
5
5
  };
@@ -71,4 +71,5 @@ export type InlineCommentPluginState = {
71
71
  bookmark?: SelectionBookmark;
72
72
  disallowOnWhitespace: boolean;
73
73
  isVisible: boolean;
74
+ skipSelectionHandling: boolean;
74
75
  };