@atlaskit/editor-core 187.31.7 → 187.32.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.
- package/CHANGELOG.md +40 -0
- package/dist/cjs/create-editor/ReactEditorViewInternal.js +1 -1
- package/dist/cjs/plugins/analytics/plugin.js +14 -12
- package/dist/cjs/plugins/annotation/index.js +15 -13
- package/dist/cjs/plugins/avatar-group/index.js +16 -14
- package/dist/cjs/plugins/base/plugin.js +12 -10
- package/dist/cjs/plugins/before-primaryToolbar/index.js +3 -2
- package/dist/cjs/plugins/block-type/index.js +32 -30
- package/dist/cjs/plugins/breakout/index.js +10 -8
- package/dist/cjs/plugins/caption/index.js +7 -6
- package/dist/cjs/plugins/caption/pm-plugins/main.js +2 -2
- package/dist/cjs/plugins/code-bidi-warning/index.js +2 -4
- package/dist/cjs/plugins/code-block/index.js +14 -11
- package/dist/cjs/plugins/code-block/pm-plugins/ide-ux.js +2 -2
- package/dist/cjs/plugins/collab-edit/index.js +16 -14
- package/dist/cjs/plugins/collab-edit/plugin.js +5 -5
- package/dist/cjs/plugins/date/index.js +18 -17
- package/dist/cjs/plugins/emoji/index.js +35 -33
- package/dist/cjs/plugins/expand/index.js +14 -13
- package/dist/cjs/plugins/extension/index.js +16 -15
- package/dist/cjs/plugins/extension/pm-plugins/main.js +4 -4
- package/dist/cjs/plugins/feedback-dialog/index.js +5 -4
- package/dist/cjs/plugins/find-replace/index.js +17 -15
- package/dist/cjs/plugins/floating-toolbar/index.js +31 -30
- package/dist/cjs/plugins/floating-toolbar/ui/ScrollButtons.js +29 -24
- package/dist/cjs/plugins/floating-toolbar/ui/Toolbar.js +5 -5
- package/dist/cjs/plugins/help-dialog/index.js +18 -17
- package/dist/cjs/plugins/insert-block/index.js +52 -51
- package/dist/cjs/plugins/insert-block/ui/ToolbarInsertBlock/index.js +11 -11
- package/dist/cjs/plugins/layout/index.js +15 -14
- package/dist/cjs/plugins/max-content-size/index.js +4 -3
- package/dist/cjs/plugins/media/index.js +49 -47
- package/dist/cjs/plugins/media/nodeviews/mediaSingle.js +2 -2
- package/dist/cjs/plugins/media/pm-plugins/main.js +7 -7
- package/dist/cjs/plugins/media/toolbar/index.js +29 -24
- package/dist/cjs/plugins/media/toolbar/linking.js +4 -4
- package/dist/cjs/plugins/media/toolbar/utils.js +22 -2
- package/dist/cjs/plugins/media/ui/ResizableMediaSingle/ResizableMediaSingleNext.js +4 -4
- package/dist/cjs/plugins/media/ui/ResizableMediaSingle/index.js +2 -2
- package/dist/cjs/plugins/media/utils/media-single.js +19 -4
- package/dist/cjs/plugins/mentions/index.js +17 -15
- package/dist/cjs/plugins/panel/index.js +13 -12
- package/dist/cjs/plugins/paste/index.js +13 -10
- package/dist/cjs/plugins/paste/pm-plugins/analytics.js +8 -8
- package/dist/cjs/plugins/paste/pm-plugins/main.js +10 -10
- package/dist/cjs/plugins/placeholder/index.js +9 -7
- package/dist/cjs/plugins/placeholder-text/index.js +23 -16
- package/dist/cjs/plugins/quick-insert/index.js +13 -12
- package/dist/cjs/plugins/rule/index.js +8 -7
- package/dist/cjs/plugins/save-on-enter/index.js +4 -3
- package/dist/cjs/plugins/selection/index.js +5 -4
- package/dist/cjs/plugins/status/index.js +20 -14
- package/dist/cjs/plugins/submit-editor/index.js +4 -3
- package/dist/cjs/plugins/tasks-and-decisions/index.js +6 -5
- package/dist/cjs/plugins/text-color/index.js +17 -15
- package/dist/cjs/plugins/toolbar-lists-indentation/index.js +31 -26
- package/dist/cjs/plugins/toolbar-lists-indentation/pm-plugins/indentation-buttons.js +1 -1
- package/dist/cjs/plugins/toolbar-lists-indentation/ui/onItemActivated.js +4 -4
- package/dist/cjs/plugins/type-ahead/index.js +21 -20
- package/dist/cjs/ui/ElementBrowser/InsertMenu.js +11 -11
- package/dist/cjs/ui/ToolbarFeedback/index.js +1 -1
- package/dist/cjs/use-preset.js +2 -2
- package/dist/cjs/version-wrapper.js +1 -1
- package/dist/es2019/create-editor/ReactEditorViewInternal.js +1 -1
- package/dist/es2019/plugins/analytics/plugin.js +11 -8
- package/dist/es2019/plugins/annotation/index.js +4 -1
- package/dist/es2019/plugins/avatar-group/index.js +8 -5
- package/dist/es2019/plugins/base/plugin.js +6 -3
- package/dist/es2019/plugins/before-primaryToolbar/index.js +4 -2
- package/dist/es2019/plugins/block-type/index.js +14 -11
- package/dist/es2019/plugins/breakout/index.js +6 -3
- package/dist/es2019/plugins/caption/index.js +3 -1
- package/dist/es2019/plugins/caption/pm-plugins/main.js +2 -2
- package/dist/es2019/plugins/code-bidi-warning/index.js +2 -4
- package/dist/es2019/plugins/code-block/index.js +15 -9
- package/dist/es2019/plugins/code-block/pm-plugins/ide-ux.js +2 -2
- package/dist/es2019/plugins/collab-edit/index.js +9 -6
- package/dist/es2019/plugins/collab-edit/plugin.js +5 -5
- package/dist/es2019/plugins/date/index.js +6 -3
- package/dist/es2019/plugins/emoji/index.js +16 -13
- package/dist/es2019/plugins/expand/index.js +7 -4
- package/dist/es2019/plugins/extension/index.js +11 -8
- package/dist/es2019/plugins/extension/pm-plugins/main.js +4 -4
- package/dist/es2019/plugins/feedback-dialog/index.js +4 -2
- package/dist/es2019/plugins/find-replace/index.js +8 -5
- package/dist/es2019/plugins/floating-toolbar/index.js +6 -4
- package/dist/es2019/plugins/floating-toolbar/ui/ScrollButtons.js +9 -4
- package/dist/es2019/plugins/floating-toolbar/ui/Toolbar.js +4 -4
- package/dist/es2019/plugins/help-dialog/index.js +9 -6
- package/dist/es2019/plugins/insert-block/index.js +12 -9
- package/dist/es2019/plugins/insert-block/ui/ToolbarInsertBlock/index.js +11 -11
- package/dist/es2019/plugins/layout/index.js +8 -5
- package/dist/es2019/plugins/max-content-size/index.js +3 -1
- package/dist/es2019/plugins/media/index.js +14 -10
- package/dist/es2019/plugins/media/nodeviews/mediaSingle.js +2 -2
- package/dist/es2019/plugins/media/pm-plugins/main.js +7 -7
- package/dist/es2019/plugins/media/toolbar/index.js +29 -25
- package/dist/es2019/plugins/media/toolbar/linking.js +4 -4
- package/dist/es2019/plugins/media/toolbar/utils.js +18 -0
- package/dist/es2019/plugins/media/ui/ResizableMediaSingle/ResizableMediaSingleNext.js +4 -4
- package/dist/es2019/plugins/media/ui/ResizableMediaSingle/index.js +2 -2
- package/dist/es2019/plugins/media/utils/media-single.js +22 -4
- package/dist/es2019/plugins/mentions/index.js +9 -6
- package/dist/es2019/plugins/panel/index.js +5 -2
- package/dist/es2019/plugins/paste/index.js +9 -5
- package/dist/es2019/plugins/paste/pm-plugins/analytics.js +8 -8
- package/dist/es2019/plugins/paste/pm-plugins/main.js +10 -10
- package/dist/es2019/plugins/placeholder/index.js +10 -7
- package/dist/es2019/plugins/placeholder-text/index.js +12 -4
- package/dist/es2019/plugins/quick-insert/index.js +3 -1
- package/dist/es2019/plugins/rule/index.js +5 -3
- package/dist/es2019/plugins/save-on-enter/index.js +3 -1
- package/dist/es2019/plugins/selection/index.js +3 -1
- package/dist/es2019/plugins/status/index.js +11 -3
- package/dist/es2019/plugins/submit-editor/index.js +3 -1
- package/dist/es2019/plugins/tasks-and-decisions/index.js +6 -4
- package/dist/es2019/plugins/text-color/index.js +6 -3
- package/dist/es2019/plugins/toolbar-lists-indentation/index.js +9 -5
- package/dist/es2019/plugins/toolbar-lists-indentation/pm-plugins/indentation-buttons.js +1 -1
- package/dist/es2019/plugins/toolbar-lists-indentation/ui/onItemActivated.js +4 -4
- package/dist/es2019/plugins/type-ahead/index.js +3 -1
- package/dist/es2019/ui/ElementBrowser/InsertMenu.js +11 -11
- package/dist/es2019/ui/ToolbarFeedback/index.js +1 -1
- package/dist/es2019/use-preset.js +2 -2
- package/dist/es2019/version-wrapper.js +1 -1
- package/dist/esm/create-editor/ReactEditorViewInternal.js +1 -1
- package/dist/esm/plugins/analytics/plugin.js +14 -12
- package/dist/esm/plugins/annotation/index.js +15 -13
- package/dist/esm/plugins/avatar-group/index.js +16 -14
- package/dist/esm/plugins/base/plugin.js +12 -10
- package/dist/esm/plugins/before-primaryToolbar/index.js +3 -2
- package/dist/esm/plugins/block-type/index.js +32 -30
- package/dist/esm/plugins/breakout/index.js +10 -8
- package/dist/esm/plugins/caption/index.js +7 -6
- package/dist/esm/plugins/caption/pm-plugins/main.js +2 -2
- package/dist/esm/plugins/code-bidi-warning/index.js +2 -4
- package/dist/esm/plugins/code-block/index.js +14 -11
- package/dist/esm/plugins/code-block/pm-plugins/ide-ux.js +2 -2
- package/dist/esm/plugins/collab-edit/index.js +16 -14
- package/dist/esm/plugins/collab-edit/plugin.js +5 -5
- package/dist/esm/plugins/date/index.js +18 -17
- package/dist/esm/plugins/emoji/index.js +35 -33
- package/dist/esm/plugins/expand/index.js +14 -13
- package/dist/esm/plugins/extension/index.js +16 -15
- package/dist/esm/plugins/extension/pm-plugins/main.js +4 -4
- package/dist/esm/plugins/feedback-dialog/index.js +5 -4
- package/dist/esm/plugins/find-replace/index.js +17 -15
- package/dist/esm/plugins/floating-toolbar/index.js +31 -30
- package/dist/esm/plugins/floating-toolbar/ui/ScrollButtons.js +28 -23
- package/dist/esm/plugins/floating-toolbar/ui/Toolbar.js +4 -4
- package/dist/esm/plugins/help-dialog/index.js +18 -17
- package/dist/esm/plugins/insert-block/index.js +52 -51
- package/dist/esm/plugins/insert-block/ui/ToolbarInsertBlock/index.js +11 -11
- package/dist/esm/plugins/layout/index.js +15 -14
- package/dist/esm/plugins/max-content-size/index.js +4 -3
- package/dist/esm/plugins/media/index.js +49 -47
- package/dist/esm/plugins/media/nodeviews/mediaSingle.js +2 -2
- package/dist/esm/plugins/media/pm-plugins/main.js +7 -7
- package/dist/esm/plugins/media/toolbar/index.js +30 -25
- package/dist/esm/plugins/media/toolbar/linking.js +4 -4
- package/dist/esm/plugins/media/toolbar/utils.js +19 -0
- package/dist/esm/plugins/media/ui/ResizableMediaSingle/ResizableMediaSingleNext.js +4 -4
- package/dist/esm/plugins/media/ui/ResizableMediaSingle/index.js +2 -2
- package/dist/esm/plugins/media/utils/media-single.js +19 -4
- package/dist/esm/plugins/mentions/index.js +17 -15
- package/dist/esm/plugins/panel/index.js +13 -12
- package/dist/esm/plugins/paste/index.js +13 -10
- package/dist/esm/plugins/paste/pm-plugins/analytics.js +8 -8
- package/dist/esm/plugins/paste/pm-plugins/main.js +10 -10
- package/dist/esm/plugins/placeholder/index.js +9 -7
- package/dist/esm/plugins/placeholder-text/index.js +23 -16
- package/dist/esm/plugins/quick-insert/index.js +13 -12
- package/dist/esm/plugins/rule/index.js +8 -7
- package/dist/esm/plugins/save-on-enter/index.js +4 -3
- package/dist/esm/plugins/selection/index.js +5 -4
- package/dist/esm/plugins/status/index.js +20 -14
- package/dist/esm/plugins/submit-editor/index.js +4 -3
- package/dist/esm/plugins/tasks-and-decisions/index.js +6 -5
- package/dist/esm/plugins/text-color/index.js +17 -15
- package/dist/esm/plugins/toolbar-lists-indentation/index.js +31 -26
- package/dist/esm/plugins/toolbar-lists-indentation/pm-plugins/indentation-buttons.js +1 -1
- package/dist/esm/plugins/toolbar-lists-indentation/ui/onItemActivated.js +4 -4
- package/dist/esm/plugins/type-ahead/index.js +21 -20
- package/dist/esm/ui/ElementBrowser/InsertMenu.js +11 -11
- package/dist/esm/ui/ToolbarFeedback/index.js +1 -1
- package/dist/esm/use-preset.js +2 -2
- package/dist/esm/version-wrapper.js +1 -1
- package/dist/types/labs/next/presets/default.d.ts +62 -618
- package/dist/types/plugins/avatar-group/index.d.ts +1 -1
- package/dist/types/plugins/before-primaryToolbar/index.d.ts +1 -1
- package/dist/types/plugins/caption/index.d.ts +1 -1
- package/dist/types/plugins/floating-toolbar/ui/ScrollButtons.d.ts +3 -3
- package/dist/types/plugins/floating-toolbar/ui/Toolbar.d.ts +1 -2
- package/dist/types/plugins/media/toolbar/utils.d.ts +2 -1
- package/dist/types/plugins/media/types.d.ts +1 -0
- package/dist/types/plugins/selection/index.d.ts +2 -2
- package/dist/types/plugins/text-color/index.d.ts +3 -2
- package/dist/types/use-preset.d.ts +2 -2
- package/dist/types-ts4.5/labs/next/presets/default.d.ts +96 -716
- package/dist/types-ts4.5/plugins/avatar-group/index.d.ts +1 -1
- package/dist/types-ts4.5/plugins/before-primaryToolbar/index.d.ts +1 -1
- package/dist/types-ts4.5/plugins/caption/index.d.ts +1 -1
- package/dist/types-ts4.5/plugins/floating-toolbar/ui/ScrollButtons.d.ts +3 -3
- package/dist/types-ts4.5/plugins/floating-toolbar/ui/Toolbar.d.ts +1 -2
- package/dist/types-ts4.5/plugins/media/toolbar/utils.d.ts +2 -1
- package/dist/types-ts4.5/plugins/media/types.d.ts +1 -0
- package/dist/types-ts4.5/plugins/selection/index.d.ts +2 -2
- package/dist/types-ts4.5/plugins/text-color/index.d.ts +3 -2
- package/dist/types-ts4.5/use-preset.d.ts +2 -2
- package/package.json +3 -3
|
@@ -10,7 +10,8 @@ import { keymapPlugin } from './keymap';
|
|
|
10
10
|
import createStatusPlugin from './plugin';
|
|
11
11
|
import { pluginKey } from './plugin-key';
|
|
12
12
|
import StatusPicker from './ui/statusPicker';
|
|
13
|
-
var baseStatusPlugin = function baseStatusPlugin(
|
|
13
|
+
var baseStatusPlugin = function baseStatusPlugin(_ref) {
|
|
14
|
+
var options = _ref.config;
|
|
14
15
|
return {
|
|
15
16
|
name: 'status',
|
|
16
17
|
nodes: function nodes() {
|
|
@@ -30,19 +31,19 @@ var baseStatusPlugin = function baseStatusPlugin(options) {
|
|
|
30
31
|
plugin: keymapPlugin
|
|
31
32
|
}];
|
|
32
33
|
},
|
|
33
|
-
contentComponent: function contentComponent(
|
|
34
|
-
var editorView =
|
|
35
|
-
popupsMountPoint =
|
|
36
|
-
popupsBoundariesElement =
|
|
37
|
-
popupsScrollableElement =
|
|
34
|
+
contentComponent: function contentComponent(_ref2) {
|
|
35
|
+
var editorView = _ref2.editorView,
|
|
36
|
+
popupsMountPoint = _ref2.popupsMountPoint,
|
|
37
|
+
popupsBoundariesElement = _ref2.popupsBoundariesElement,
|
|
38
|
+
popupsScrollableElement = _ref2.popupsScrollableElement;
|
|
38
39
|
var domAtPos = editorView.domAtPos.bind(editorView);
|
|
39
40
|
return /*#__PURE__*/React.createElement(WithPluginState, {
|
|
40
41
|
plugins: {
|
|
41
42
|
statusState: pluginKey
|
|
42
43
|
},
|
|
43
|
-
render: function render(
|
|
44
|
-
var
|
|
45
|
-
statusState =
|
|
44
|
+
render: function render(_ref3) {
|
|
45
|
+
var _ref3$statusState = _ref3.statusState,
|
|
46
|
+
statusState = _ref3$statusState === void 0 ? {} : _ref3$statusState;
|
|
46
47
|
var showStatusPickerAt = statusState.showStatusPickerAt;
|
|
47
48
|
if (typeof showStatusPickerAt !== 'number') {
|
|
48
49
|
return null;
|
|
@@ -84,12 +85,12 @@ var baseStatusPlugin = function baseStatusPlugin(options) {
|
|
|
84
85
|
};
|
|
85
86
|
};
|
|
86
87
|
var decorateWithPluginOptions = function decorateWithPluginOptions(plugin, options) {
|
|
87
|
-
if (options.menuDisabled === true) {
|
|
88
|
+
if ((options === null || options === void 0 ? void 0 : options.menuDisabled) === true) {
|
|
88
89
|
return plugin;
|
|
89
90
|
}
|
|
90
91
|
plugin.pluginsOptions = {
|
|
91
|
-
quickInsert: function quickInsert(
|
|
92
|
-
var formatMessage =
|
|
92
|
+
quickInsert: function quickInsert(_ref4) {
|
|
93
|
+
var formatMessage = _ref4.formatMessage;
|
|
93
94
|
return [{
|
|
94
95
|
id: 'status',
|
|
95
96
|
title: formatMessage(messages.status),
|
|
@@ -115,7 +116,12 @@ var decorateWithPluginOptions = function decorateWithPluginOptions(plugin, optio
|
|
|
115
116
|
};
|
|
116
117
|
return plugin;
|
|
117
118
|
};
|
|
118
|
-
var statusPlugin = function statusPlugin(
|
|
119
|
-
|
|
119
|
+
var statusPlugin = function statusPlugin(_ref5) {
|
|
120
|
+
var options = _ref5.config,
|
|
121
|
+
api = _ref5.api;
|
|
122
|
+
return decorateWithPluginOptions(baseStatusPlugin({
|
|
123
|
+
config: options,
|
|
124
|
+
api: api
|
|
125
|
+
}), options);
|
|
120
126
|
};
|
|
121
127
|
export default statusPlugin;
|
|
@@ -37,14 +37,15 @@ var analyticsPayload = function analyticsPayload(state) {
|
|
|
37
37
|
}
|
|
38
38
|
};
|
|
39
39
|
};
|
|
40
|
-
var submitEditorPlugin = function submitEditorPlugin(
|
|
40
|
+
var submitEditorPlugin = function submitEditorPlugin(_ref) {
|
|
41
|
+
var onSave = _ref.config;
|
|
41
42
|
return {
|
|
42
43
|
name: 'submitEditor',
|
|
43
44
|
pmPlugins: function pmPlugins() {
|
|
44
45
|
return [{
|
|
45
46
|
name: 'submitEditor',
|
|
46
|
-
plugin: function plugin(
|
|
47
|
-
var dispatch =
|
|
47
|
+
plugin: function plugin(_ref2) {
|
|
48
|
+
var dispatch = _ref2.dispatch;
|
|
48
49
|
return createPlugin(dispatch, onSave);
|
|
49
50
|
}
|
|
50
51
|
}];
|
|
@@ -27,11 +27,12 @@ var addItem = function addItem(insert, listType, schema) {
|
|
|
27
27
|
})));
|
|
28
28
|
};
|
|
29
29
|
};
|
|
30
|
-
var tasksAndDecisionsPlugin = function tasksAndDecisionsPlugin() {
|
|
31
|
-
var _ref2 =
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
30
|
+
var tasksAndDecisionsPlugin = function tasksAndDecisionsPlugin(_ref2) {
|
|
31
|
+
var _ref2$config = _ref2.config,
|
|
32
|
+
_ref2$config2 = _ref2$config === void 0 ? {} : _ref2$config,
|
|
33
|
+
allowNestedTasks = _ref2$config2.allowNestedTasks,
|
|
34
|
+
consumeTabs = _ref2$config2.consumeTabs,
|
|
35
|
+
useLongPressSelection = _ref2$config2.useLongPressSelection;
|
|
35
36
|
return {
|
|
36
37
|
name: 'taskDecision',
|
|
37
38
|
nodes: function nodes() {
|
|
@@ -9,9 +9,11 @@ var pluginConfig = function pluginConfig(textColorConfig) {
|
|
|
9
9
|
}
|
|
10
10
|
return textColorConfig;
|
|
11
11
|
};
|
|
12
|
-
var textColorPlugin = function textColorPlugin(
|
|
13
|
-
var _api$
|
|
14
|
-
var
|
|
12
|
+
var textColorPlugin = function textColorPlugin(_ref) {
|
|
13
|
+
var _api$featureFlags;
|
|
14
|
+
var textColorConfig = _ref.config,
|
|
15
|
+
api = _ref.api;
|
|
16
|
+
var featureFlags = (api === null || api === void 0 ? void 0 : (_api$featureFlags = api.featureFlags) === null || _api$featureFlags === void 0 ? void 0 : _api$featureFlags.sharedState.currentState()) || {};
|
|
15
17
|
return {
|
|
16
18
|
name: 'textColor',
|
|
17
19
|
marks: function marks() {
|
|
@@ -23,26 +25,26 @@ var textColorPlugin = function textColorPlugin(textColorConfig, api) {
|
|
|
23
25
|
pmPlugins: function pmPlugins() {
|
|
24
26
|
return [{
|
|
25
27
|
name: 'textColor',
|
|
26
|
-
plugin: function plugin(
|
|
27
|
-
var dispatch =
|
|
28
|
+
plugin: function plugin(_ref2) {
|
|
29
|
+
var dispatch = _ref2.dispatch;
|
|
28
30
|
return createPlugin(dispatch, pluginConfig(textColorConfig));
|
|
29
31
|
}
|
|
30
32
|
}];
|
|
31
33
|
},
|
|
32
|
-
primaryToolbarComponent: function primaryToolbarComponent(
|
|
33
|
-
var editorView =
|
|
34
|
-
popupsMountPoint =
|
|
35
|
-
popupsBoundariesElement =
|
|
36
|
-
popupsScrollableElement =
|
|
37
|
-
isToolbarReducedSpacing =
|
|
38
|
-
dispatchAnalyticsEvent =
|
|
39
|
-
disabled =
|
|
34
|
+
primaryToolbarComponent: function primaryToolbarComponent(_ref3) {
|
|
35
|
+
var editorView = _ref3.editorView,
|
|
36
|
+
popupsMountPoint = _ref3.popupsMountPoint,
|
|
37
|
+
popupsBoundariesElement = _ref3.popupsBoundariesElement,
|
|
38
|
+
popupsScrollableElement = _ref3.popupsScrollableElement,
|
|
39
|
+
isToolbarReducedSpacing = _ref3.isToolbarReducedSpacing,
|
|
40
|
+
dispatchAnalyticsEvent = _ref3.dispatchAnalyticsEvent,
|
|
41
|
+
disabled = _ref3.disabled;
|
|
40
42
|
return /*#__PURE__*/React.createElement(WithPluginState, {
|
|
41
43
|
plugins: {
|
|
42
44
|
textColor: textColorPluginKey
|
|
43
45
|
},
|
|
44
|
-
render: function render(
|
|
45
|
-
var textColor =
|
|
46
|
+
render: function render(_ref4) {
|
|
47
|
+
var textColor = _ref4.textColor;
|
|
46
48
|
return /*#__PURE__*/React.createElement(ToolbarTextColor, {
|
|
47
49
|
pluginState: textColor,
|
|
48
50
|
isReducedSpacing: isToolbarReducedSpacing,
|
|
@@ -4,11 +4,16 @@ import ToolbarListsIndentation from './ui';
|
|
|
4
4
|
import { ToolbarSize } from '../../ui/Toolbar/types';
|
|
5
5
|
import { createPlugin as indentationButtonsPlugin } from './pm-plugins/indentation-buttons';
|
|
6
6
|
import { pluginKey as indentationButtonPluginKey } from './pm-plugins/indentation-buttons';
|
|
7
|
-
var toolbarListsIndentationPlugin = function toolbarListsIndentationPlugin(_ref
|
|
8
|
-
var _api$
|
|
9
|
-
var
|
|
10
|
-
|
|
11
|
-
var
|
|
7
|
+
var toolbarListsIndentationPlugin = function toolbarListsIndentationPlugin(_ref) {
|
|
8
|
+
var _api$featureFlags;
|
|
9
|
+
var config = _ref.config,
|
|
10
|
+
api = _ref.api;
|
|
11
|
+
var _ref2 = config !== null && config !== void 0 ? config : {},
|
|
12
|
+
_ref2$showIndentation = _ref2.showIndentationButtons,
|
|
13
|
+
showIndentationButtons = _ref2$showIndentation === void 0 ? false : _ref2$showIndentation,
|
|
14
|
+
_ref2$allowHeadingAnd = _ref2.allowHeadingAndParagraphIndentation,
|
|
15
|
+
allowHeadingAndParagraphIndentation = _ref2$allowHeadingAnd === void 0 ? false : _ref2$allowHeadingAnd;
|
|
16
|
+
var featureFlags = (api === null || api === void 0 ? void 0 : (_api$featureFlags = api.featureFlags) === null || _api$featureFlags === void 0 ? void 0 : _api$featureFlags.sharedState.currentState()) || {};
|
|
12
17
|
return {
|
|
13
18
|
name: 'toolbarListsIndentation',
|
|
14
19
|
getSharedState: function getSharedState(editorState) {
|
|
@@ -20,8 +25,8 @@ var toolbarListsIndentationPlugin = function toolbarListsIndentationPlugin(_ref,
|
|
|
20
25
|
pmPlugins: function pmPlugins() {
|
|
21
26
|
return [{
|
|
22
27
|
name: 'indentationButtons',
|
|
23
|
-
plugin: function plugin(
|
|
24
|
-
var dispatch =
|
|
28
|
+
plugin: function plugin(_ref3) {
|
|
29
|
+
var dispatch = _ref3.dispatch;
|
|
25
30
|
return indentationButtonsPlugin({
|
|
26
31
|
dispatch: dispatch,
|
|
27
32
|
showIndentationButtons: showIndentationButtons,
|
|
@@ -31,14 +36,14 @@ var toolbarListsIndentationPlugin = function toolbarListsIndentationPlugin(_ref,
|
|
|
31
36
|
}
|
|
32
37
|
}];
|
|
33
38
|
},
|
|
34
|
-
primaryToolbarComponent: function primaryToolbarComponent(
|
|
35
|
-
var editorView =
|
|
36
|
-
popupsMountPoint =
|
|
37
|
-
popupsBoundariesElement =
|
|
38
|
-
popupsScrollableElement =
|
|
39
|
-
toolbarSize =
|
|
40
|
-
disabled =
|
|
41
|
-
isToolbarReducedSpacing =
|
|
39
|
+
primaryToolbarComponent: function primaryToolbarComponent(_ref4) {
|
|
40
|
+
var editorView = _ref4.editorView,
|
|
41
|
+
popupsMountPoint = _ref4.popupsMountPoint,
|
|
42
|
+
popupsBoundariesElement = _ref4.popupsBoundariesElement,
|
|
43
|
+
popupsScrollableElement = _ref4.popupsScrollableElement,
|
|
44
|
+
toolbarSize = _ref4.toolbarSize,
|
|
45
|
+
disabled = _ref4.disabled,
|
|
46
|
+
isToolbarReducedSpacing = _ref4.isToolbarReducedSpacing;
|
|
42
47
|
var isSmall = toolbarSize < ToolbarSize.L;
|
|
43
48
|
return /*#__PURE__*/React.createElement(PrimaryToolbarComponent, {
|
|
44
49
|
featureFlags: featureFlags,
|
|
@@ -55,17 +60,17 @@ var toolbarListsIndentationPlugin = function toolbarListsIndentationPlugin(_ref,
|
|
|
55
60
|
}
|
|
56
61
|
};
|
|
57
62
|
};
|
|
58
|
-
function PrimaryToolbarComponent(
|
|
59
|
-
var featureFlags =
|
|
60
|
-
popupsMountPoint =
|
|
61
|
-
popupsBoundariesElement =
|
|
62
|
-
popupsScrollableElement =
|
|
63
|
-
isSmall =
|
|
64
|
-
isToolbarReducedSpacing =
|
|
65
|
-
disabled =
|
|
66
|
-
editorView =
|
|
67
|
-
showIndentationButtons =
|
|
68
|
-
pluginInjectionApi =
|
|
63
|
+
function PrimaryToolbarComponent(_ref5) {
|
|
64
|
+
var featureFlags = _ref5.featureFlags,
|
|
65
|
+
popupsMountPoint = _ref5.popupsMountPoint,
|
|
66
|
+
popupsBoundariesElement = _ref5.popupsBoundariesElement,
|
|
67
|
+
popupsScrollableElement = _ref5.popupsScrollableElement,
|
|
68
|
+
isSmall = _ref5.isSmall,
|
|
69
|
+
isToolbarReducedSpacing = _ref5.isToolbarReducedSpacing,
|
|
70
|
+
disabled = _ref5.disabled,
|
|
71
|
+
editorView = _ref5.editorView,
|
|
72
|
+
showIndentationButtons = _ref5.showIndentationButtons,
|
|
73
|
+
pluginInjectionApi = _ref5.pluginInjectionApi;
|
|
69
74
|
var _useSharedPluginState = useSharedPluginState(pluginInjectionApi, ['list', 'toolbarListsIndentation']),
|
|
70
75
|
listState = _useSharedPluginState.listState,
|
|
71
76
|
toolbarListsIndentationState = _useSharedPluginState.toolbarListsIndentationState;
|
|
@@ -19,7 +19,7 @@ function getIndentationButtonsState(editorState, allowHeadingAndParagraphIndenta
|
|
|
19
19
|
// not use the indentation mark.
|
|
20
20
|
// Check for lists before paragraphs and headings in case
|
|
21
21
|
// the selection is in a list nested in a layout column.
|
|
22
|
-
if (api !== null && api !== void 0 && api.
|
|
22
|
+
if (api !== null && api !== void 0 && api.list.actions.isInsideListItem(editorState.tr)) {
|
|
23
23
|
var _getListItemAttribute = getListItemAttributes(selection.$head),
|
|
24
24
|
indentLevel = _getListItemAttribute.indentLevel,
|
|
25
25
|
itemIndex = _getListItemAttribute.itemIndex;
|
|
@@ -8,10 +8,10 @@ export var onItemActivated = function onItemActivated(pluginInjectionApi) {
|
|
|
8
8
|
editorView = _ref.editorView;
|
|
9
9
|
switch (buttonName) {
|
|
10
10
|
case 'bullet_list':
|
|
11
|
-
pluginInjectionApi === null || pluginInjectionApi === void 0 ? void 0 : pluginInjectionApi.
|
|
11
|
+
pluginInjectionApi === null || pluginInjectionApi === void 0 ? void 0 : pluginInjectionApi.core.actions.execute(pluginInjectionApi === null || pluginInjectionApi === void 0 ? void 0 : pluginInjectionApi.list.commands.toggleBulletList(INPUT_METHOD.TOOLBAR));
|
|
12
12
|
break;
|
|
13
13
|
case 'ordered_list':
|
|
14
|
-
pluginInjectionApi === null || pluginInjectionApi === void 0 ? void 0 : pluginInjectionApi.
|
|
14
|
+
pluginInjectionApi === null || pluginInjectionApi === void 0 ? void 0 : pluginInjectionApi.core.actions.execute(pluginInjectionApi === null || pluginInjectionApi === void 0 ? void 0 : pluginInjectionApi.list.commands.toggleOrderedList(INPUT_METHOD.TOOLBAR));
|
|
15
15
|
break;
|
|
16
16
|
case 'indent':
|
|
17
17
|
{
|
|
@@ -21,7 +21,7 @@ export var onItemActivated = function onItemActivated(pluginInjectionApi) {
|
|
|
21
21
|
indentParagraphOrHeading(INPUT_METHOD.TOOLBAR)(editorView.state, editorView.dispatch);
|
|
22
22
|
}
|
|
23
23
|
if (node === 'list') {
|
|
24
|
-
pluginInjectionApi === null || pluginInjectionApi === void 0 ? void 0 : pluginInjectionApi.
|
|
24
|
+
pluginInjectionApi === null || pluginInjectionApi === void 0 ? 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
27
|
indentTaskList(INPUT_METHOD.TOOLBAR)(editorView.state, editorView.dispatch);
|
|
@@ -36,7 +36,7 @@ export var onItemActivated = function onItemActivated(pluginInjectionApi) {
|
|
|
36
36
|
outdentParagraphOrHeading(INPUT_METHOD.TOOLBAR)(editorView.state, editorView.dispatch);
|
|
37
37
|
}
|
|
38
38
|
if (_node === 'list') {
|
|
39
|
-
pluginInjectionApi === null || pluginInjectionApi === void 0 ? void 0 : pluginInjectionApi.
|
|
39
|
+
pluginInjectionApi === null || pluginInjectionApi === void 0 ? void 0 : pluginInjectionApi.core.actions.execute(pluginInjectionApi === null || pluginInjectionApi === void 0 ? void 0 : pluginInjectionApi.list.commands.outdentList(INPUT_METHOD.TOOLBAR));
|
|
40
40
|
}
|
|
41
41
|
if (_node === 'taskList') {
|
|
42
42
|
outdentTaskList(INPUT_METHOD.TOOLBAR)(editorView.state, editorView.dispatch);
|
|
@@ -113,7 +113,8 @@ var TypeAheadMenu = /*#__PURE__*/React.memo(function (_ref) {
|
|
|
113
113
|
*
|
|
114
114
|
*
|
|
115
115
|
*/
|
|
116
|
-
var typeAheadPlugin = function typeAheadPlugin(
|
|
116
|
+
var typeAheadPlugin = function typeAheadPlugin(_ref4) {
|
|
117
|
+
var options = _ref4.config;
|
|
117
118
|
var fireAnalyticsCallback = fireAnalyticsEvent(options === null || options === void 0 ? void 0 : options.createAnalyticsEvent);
|
|
118
119
|
var popupMountRef = {
|
|
119
120
|
current: null
|
|
@@ -132,9 +133,9 @@ var typeAheadPlugin = function typeAheadPlugin(options) {
|
|
|
132
133
|
var typeAhead = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : [];
|
|
133
134
|
return [{
|
|
134
135
|
name: 'typeAhead',
|
|
135
|
-
plugin: function plugin(
|
|
136
|
-
var dispatch =
|
|
137
|
-
getIntl =
|
|
136
|
+
plugin: function plugin(_ref5) {
|
|
137
|
+
var dispatch = _ref5.dispatch,
|
|
138
|
+
getIntl = _ref5.getIntl;
|
|
138
139
|
return createPlugin({
|
|
139
140
|
getIntl: getIntl,
|
|
140
141
|
popupMountRef: popupMountRef,
|
|
@@ -148,9 +149,9 @@ var typeAheadPlugin = function typeAheadPlugin(options) {
|
|
|
148
149
|
plugin: createInsertItemPlugin
|
|
149
150
|
}, {
|
|
150
151
|
name: 'typeAheadInputRule',
|
|
151
|
-
plugin: function plugin(
|
|
152
|
-
var schema =
|
|
153
|
-
featureFlags =
|
|
152
|
+
plugin: function plugin(_ref6) {
|
|
153
|
+
var schema = _ref6.schema,
|
|
154
|
+
featureFlags = _ref6.featureFlags;
|
|
154
155
|
return inputRulePlugin(schema, typeAhead, featureFlags);
|
|
155
156
|
}
|
|
156
157
|
}];
|
|
@@ -158,13 +159,13 @@ var typeAheadPlugin = function typeAheadPlugin(options) {
|
|
|
158
159
|
commands: {
|
|
159
160
|
openTypeAheadAtCursor: openTypeAheadAtCursor
|
|
160
161
|
},
|
|
161
|
-
contentComponent: function contentComponent(
|
|
162
|
-
var editorView =
|
|
163
|
-
containerElement =
|
|
164
|
-
popupsMountPoint =
|
|
165
|
-
popupsBoundariesElement =
|
|
166
|
-
popupsScrollableElement =
|
|
167
|
-
wrapperElement =
|
|
162
|
+
contentComponent: function contentComponent(_ref7) {
|
|
163
|
+
var editorView = _ref7.editorView,
|
|
164
|
+
containerElement = _ref7.containerElement,
|
|
165
|
+
popupsMountPoint = _ref7.popupsMountPoint,
|
|
166
|
+
popupsBoundariesElement = _ref7.popupsBoundariesElement,
|
|
167
|
+
popupsScrollableElement = _ref7.popupsScrollableElement,
|
|
168
|
+
wrapperElement = _ref7.wrapperElement;
|
|
168
169
|
popupMountRef.current = {
|
|
169
170
|
popupsMountPoint: popupsMountPoint || wrapperElement || undefined,
|
|
170
171
|
popupsBoundariesElement: popupsBoundariesElement,
|
|
@@ -174,8 +175,8 @@ var typeAheadPlugin = function typeAheadPlugin(options) {
|
|
|
174
175
|
plugins: {
|
|
175
176
|
typeAheadState: typeAheadPluginKey
|
|
176
177
|
},
|
|
177
|
-
render: function render(
|
|
178
|
-
var typeAheadState =
|
|
178
|
+
render: function render(_ref8) {
|
|
179
|
+
var typeAheadState = _ref8.typeAheadState;
|
|
179
180
|
if (!typeAheadState) {
|
|
180
181
|
return null;
|
|
181
182
|
}
|
|
@@ -188,10 +189,10 @@ var typeAheadPlugin = function typeAheadPlugin(options) {
|
|
|
188
189
|
}
|
|
189
190
|
});
|
|
190
191
|
},
|
|
191
|
-
onEditorViewStateUpdated: function onEditorViewStateUpdated(
|
|
192
|
-
var originalTransaction =
|
|
193
|
-
oldEditorState =
|
|
194
|
-
newEditorState =
|
|
192
|
+
onEditorViewStateUpdated: function onEditorViewStateUpdated(_ref9) {
|
|
193
|
+
var originalTransaction = _ref9.originalTransaction,
|
|
194
|
+
oldEditorState = _ref9.oldEditorState,
|
|
195
|
+
newEditorState = _ref9.newEditorState;
|
|
195
196
|
var oldPluginState = getPluginState(oldEditorState);
|
|
196
197
|
var newPluginState = getPluginState(newEditorState);
|
|
197
198
|
if (!oldPluginState || !newPluginState) {
|
|
@@ -18,7 +18,7 @@ import withOuterListeners from '../with-outer-listeners';
|
|
|
18
18
|
import ElementBrowser from './components/ElementBrowserLoader';
|
|
19
19
|
import { ELEMENT_ITEM_HEIGHT } from './constants';
|
|
20
20
|
var InsertMenu = function InsertMenu(_ref) {
|
|
21
|
-
var _pluginInjectionApi$
|
|
21
|
+
var _pluginInjectionApi$q10, _pluginInjectionApi$q11, _pluginInjectionApi$q12, _pluginInjectionApi$q13;
|
|
22
22
|
var editorView = _ref.editorView,
|
|
23
23
|
dropdownItems = _ref.dropdownItems,
|
|
24
24
|
showElementBrowserLink = _ref.showElementBrowserLink,
|
|
@@ -56,12 +56,12 @@ var InsertMenu = function InsertMenu(_ref) {
|
|
|
56
56
|
var quickInsertDropdownItems = dropdownItems.map(transform);
|
|
57
57
|
var viewMoreItem = showElementBrowserLink ? quickInsertDropdownItems.pop() : undefined;
|
|
58
58
|
var onInsertItem = useCallback(function (item) {
|
|
59
|
-
var _pluginInjectionApi$
|
|
59
|
+
var _pluginInjectionApi$q;
|
|
60
60
|
toggleVisiblity();
|
|
61
61
|
if (!editorView.hasFocus()) {
|
|
62
62
|
editorView.focus();
|
|
63
63
|
}
|
|
64
|
-
pluginInjectionApi === null || pluginInjectionApi === void 0 ? void 0 : (_pluginInjectionApi$
|
|
64
|
+
pluginInjectionApi === null || pluginInjectionApi === void 0 ? void 0 : (_pluginInjectionApi$q = pluginInjectionApi.quickInsert) === null || _pluginInjectionApi$q === void 0 ? void 0 : _pluginInjectionApi$q.actions.insertItem(item)(editorView.state, editorView.dispatch);
|
|
65
65
|
}, [editorView, toggleVisiblity, pluginInjectionApi]);
|
|
66
66
|
var getItems = useCallback(function (query, category) {
|
|
67
67
|
var result;
|
|
@@ -72,25 +72,25 @@ var InsertMenu = function InsertMenu(_ref) {
|
|
|
72
72
|
* @see above transform function for more details.
|
|
73
73
|
*/
|
|
74
74
|
if (query) {
|
|
75
|
-
var _pluginInjectionApi$
|
|
76
|
-
pluginInjectionApi === null || pluginInjectionApi === void 0 ? void 0 : pluginInjectionApi.
|
|
75
|
+
var _pluginInjectionApi$q2, _pluginInjectionApi$q3, _pluginInjectionApi$q4, _pluginInjectionApi$q5;
|
|
76
|
+
pluginInjectionApi === null || pluginInjectionApi === void 0 ? void 0 : pluginInjectionApi.core.actions.execute(pluginInjectionApi === null || pluginInjectionApi === void 0 ? void 0 : (_pluginInjectionApi$q2 = pluginInjectionApi.quickInsert) === null || _pluginInjectionApi$q2 === void 0 ? void 0 : _pluginInjectionApi$q2.commands.search({
|
|
77
77
|
query: query,
|
|
78
78
|
category: category
|
|
79
79
|
}));
|
|
80
|
-
result = (_pluginInjectionApi$
|
|
80
|
+
result = (_pluginInjectionApi$q3 = pluginInjectionApi === null || pluginInjectionApi === void 0 ? void 0 : (_pluginInjectionApi$q4 = pluginInjectionApi.quickInsert) === null || _pluginInjectionApi$q4 === void 0 ? void 0 : (_pluginInjectionApi$q5 = _pluginInjectionApi$q4.sharedState.currentState()) === null || _pluginInjectionApi$q5 === void 0 ? void 0 : _pluginInjectionApi$q5.suggestions) !== null && _pluginInjectionApi$q3 !== void 0 ? _pluginInjectionApi$q3 : [];
|
|
81
81
|
} else {
|
|
82
|
-
var _pluginInjectionApi$
|
|
83
|
-
pluginInjectionApi === null || pluginInjectionApi === void 0 ? void 0 : pluginInjectionApi.
|
|
82
|
+
var _pluginInjectionApi$q6, _pluginInjectionApi$q7, _pluginInjectionApi$q8, _pluginInjectionApi$q9;
|
|
83
|
+
pluginInjectionApi === null || pluginInjectionApi === void 0 ? void 0 : pluginInjectionApi.core.actions.execute(pluginInjectionApi === null || pluginInjectionApi === void 0 ? void 0 : (_pluginInjectionApi$q6 = pluginInjectionApi.quickInsert) === null || _pluginInjectionApi$q6 === void 0 ? void 0 : _pluginInjectionApi$q6.commands.search({
|
|
84
84
|
category: category,
|
|
85
85
|
featuredItems: true
|
|
86
86
|
}));
|
|
87
|
-
var featuredQuickInsertSuggestions = (_pluginInjectionApi$
|
|
87
|
+
var featuredQuickInsertSuggestions = (_pluginInjectionApi$q7 = pluginInjectionApi === null || pluginInjectionApi === void 0 ? void 0 : (_pluginInjectionApi$q8 = pluginInjectionApi.quickInsert) === null || _pluginInjectionApi$q8 === void 0 ? void 0 : (_pluginInjectionApi$q9 = _pluginInjectionApi$q8.sharedState.currentState()) === null || _pluginInjectionApi$q9 === void 0 ? void 0 : _pluginInjectionApi$q9.suggestions) !== null && _pluginInjectionApi$q7 !== void 0 ? _pluginInjectionApi$q7 : [];
|
|
88
88
|
result = quickInsertDropdownItems.concat(featuredQuickInsertSuggestions);
|
|
89
89
|
}
|
|
90
90
|
setItemCount(result.length);
|
|
91
91
|
return result;
|
|
92
|
-
}, [pluginInjectionApi === null || pluginInjectionApi === void 0 ? void 0 : pluginInjectionApi.
|
|
93
|
-
var emptyStateHandler = pluginInjectionApi === null || pluginInjectionApi === void 0 ? void 0 : (_pluginInjectionApi$
|
|
92
|
+
}, [pluginInjectionApi === null || pluginInjectionApi === void 0 ? void 0 : pluginInjectionApi.core.actions, pluginInjectionApi === null || pluginInjectionApi === void 0 ? void 0 : (_pluginInjectionApi$q10 = pluginInjectionApi.quickInsert) === null || _pluginInjectionApi$q10 === void 0 ? void 0 : _pluginInjectionApi$q10.commands, pluginInjectionApi === null || pluginInjectionApi === void 0 ? void 0 : (_pluginInjectionApi$q11 = pluginInjectionApi.quickInsert) === null || _pluginInjectionApi$q11 === void 0 ? void 0 : _pluginInjectionApi$q11.sharedState, quickInsertDropdownItems]);
|
|
93
|
+
var emptyStateHandler = pluginInjectionApi === null || pluginInjectionApi === void 0 ? void 0 : (_pluginInjectionApi$q12 = pluginInjectionApi.quickInsert) === null || _pluginInjectionApi$q12 === void 0 ? void 0 : (_pluginInjectionApi$q13 = _pluginInjectionApi$q12.sharedState.currentState()) === null || _pluginInjectionApi$q13 === void 0 ? void 0 : _pluginInjectionApi$q13.emptyStateHandler;
|
|
94
94
|
return jsx("div", {
|
|
95
95
|
css: function css(theme) {
|
|
96
96
|
return insertMenuWrapper(theme, itemCount);
|
|
@@ -102,7 +102,7 @@ var ToolbarFeedbackInternal = /*#__PURE__*/function (_PureComponent) {
|
|
|
102
102
|
jiraIssueCollectorScriptLoading: true,
|
|
103
103
|
showOptOutOption: false
|
|
104
104
|
});
|
|
105
|
-
basePluginState = (_this$props$api = _this.props.api) === null || _this$props$api === void 0 ? void 0 : _this$props$api.
|
|
105
|
+
basePluginState = (_this$props$api = _this.props.api) === null || _this$props$api === void 0 ? void 0 : _this$props$api.base.sharedState.currentState();
|
|
106
106
|
sessionId = (_window$localStorage$ = window.localStorage.getItem('awc.session.id')) === null || _window$localStorage$ === void 0 ? void 0 : _window$localStorage$.toString();
|
|
107
107
|
contentId = basePluginState === null || basePluginState === void 0 ? void 0 : (_basePluginState$cont = basePluginState.contextIdentifier) === null || _basePluginState$cont === void 0 ? void 0 : _basePluginState$cont.objectId;
|
|
108
108
|
tabId = window.sessionStorage['awc.tab.id'];
|
package/dist/esm/use-preset.js
CHANGED
|
@@ -21,8 +21,8 @@ import { usePresetContext } from './presets/context';
|
|
|
21
21
|
* , []);
|
|
22
22
|
*
|
|
23
23
|
* // Can execute typesafe commands based on plugin1 or 2
|
|
24
|
-
* const runCommand = () => editorApi.
|
|
25
|
-
* editorApi.
|
|
24
|
+
* const runCommand = () => editorApi.core.actions.execute(
|
|
25
|
+
* editorApi.plugin1.commands.doSomething()
|
|
26
26
|
* )
|
|
27
27
|
* return (
|
|
28
28
|
* <>
|