@atlaskit/editor-core 185.2.24 → 185.2.25
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 +7 -0
- package/dist/cjs/labs/next/presets/universal.js +6 -5
- package/dist/cjs/plugins/extension/actions.js +6 -4
- package/dist/cjs/plugins/extension/commands.js +19 -16
- package/dist/cjs/plugins/extension/context-panel.js +4 -4
- package/dist/cjs/plugins/extension/extension-api.js +1 -1
- package/dist/cjs/plugins/extension/index.js +11 -4
- package/dist/cjs/plugins/extension/pm-plugins/keymap.js +2 -2
- package/dist/cjs/plugins/extension/pm-plugins/main.js +10 -5
- package/dist/cjs/plugins/extension/toolbar.js +8 -6
- package/dist/cjs/plugins/floating-toolbar/ui/ExtensionsPlaceholder.js +11 -6
- package/dist/cjs/plugins/floating-toolbar/ui/Toolbar.js +5 -2
- package/dist/cjs/plugins/index.js +0 -7
- package/dist/cjs/ui/ContextPanel/index.js +9 -2
- package/dist/cjs/utils/action.js +1 -1
- package/dist/cjs/version-wrapper.js +1 -1
- package/dist/cjs/version.json +1 -1
- package/dist/es2019/labs/next/presets/universal.js +7 -6
- package/dist/es2019/plugins/extension/actions.js +6 -4
- package/dist/es2019/plugins/extension/commands.js +6 -7
- package/dist/es2019/plugins/extension/context-panel.js +4 -4
- package/dist/es2019/plugins/extension/extension-api.js +1 -1
- package/dist/es2019/plugins/extension/index.js +11 -4
- package/dist/es2019/plugins/extension/pm-plugins/keymap.js +2 -2
- package/dist/es2019/plugins/extension/pm-plugins/main.js +10 -5
- package/dist/es2019/plugins/extension/toolbar.js +8 -4
- package/dist/es2019/plugins/floating-toolbar/ui/ExtensionsPlaceholder.js +11 -6
- package/dist/es2019/plugins/floating-toolbar/ui/Toolbar.js +5 -2
- package/dist/es2019/plugins/index.js +0 -1
- package/dist/es2019/ui/ContextPanel/index.js +8 -1
- package/dist/es2019/utils/action.js +1 -1
- package/dist/es2019/version-wrapper.js +1 -1
- package/dist/es2019/version.json +1 -1
- package/dist/esm/labs/next/presets/universal.js +7 -6
- package/dist/esm/plugins/extension/actions.js +6 -4
- package/dist/esm/plugins/extension/commands.js +18 -15
- package/dist/esm/plugins/extension/context-panel.js +4 -4
- package/dist/esm/plugins/extension/extension-api.js +1 -1
- package/dist/esm/plugins/extension/index.js +11 -4
- package/dist/esm/plugins/extension/pm-plugins/keymap.js +2 -2
- package/dist/esm/plugins/extension/pm-plugins/main.js +10 -5
- package/dist/esm/plugins/extension/toolbar.js +8 -6
- package/dist/esm/plugins/floating-toolbar/ui/ExtensionsPlaceholder.js +11 -6
- package/dist/esm/plugins/floating-toolbar/ui/Toolbar.js +5 -2
- package/dist/esm/plugins/index.js +0 -1
- package/dist/esm/ui/ContextPanel/index.js +8 -1
- package/dist/esm/utils/action.js +1 -1
- package/dist/esm/version-wrapper.js +1 -1
- package/dist/esm/version.json +1 -1
- package/dist/types/labs/next/presets/cxhtml.d.ts +18 -2
- package/dist/types/labs/next/presets/default.d.ts +36 -4
- package/dist/types/labs/next/presets/mobile.d.ts +18 -2
- package/dist/types/plugins/extension/actions.d.ts +2 -1
- package/dist/types/plugins/extension/commands.d.ts +4 -3
- package/dist/types/plugins/extension/context-panel.d.ts +2 -1
- package/dist/types/plugins/extension/extension-api.d.ts +2 -0
- package/dist/types/plugins/extension/index.d.ts +4 -2
- package/dist/types/plugins/extension/pm-plugins/keymap.d.ts +2 -1
- package/dist/types/plugins/extension/pm-plugins/main.d.ts +3 -1
- package/dist/types/plugins/extension/toolbar.d.ts +8 -1
- package/dist/types/plugins/extension/types.d.ts +2 -0
- package/dist/types/plugins/floating-toolbar/ui/ExtensionsPlaceholder.d.ts +2 -0
- package/dist/types/plugins/floating-toolbar/ui/Toolbar.d.ts +7 -3
- package/dist/types/plugins/index.d.ts +0 -1
- package/dist/types-ts4.5/labs/next/presets/cxhtml.d.ts +20 -2
- package/dist/types-ts4.5/labs/next/presets/default.d.ts +40 -4
- package/dist/types-ts4.5/labs/next/presets/mobile.d.ts +20 -2
- package/dist/types-ts4.5/plugins/extension/actions.d.ts +2 -1
- package/dist/types-ts4.5/plugins/extension/commands.d.ts +4 -3
- package/dist/types-ts4.5/plugins/extension/context-panel.d.ts +2 -1
- package/dist/types-ts4.5/plugins/extension/extension-api.d.ts +2 -0
- package/dist/types-ts4.5/plugins/extension/index.d.ts +4 -2
- package/dist/types-ts4.5/plugins/extension/pm-plugins/keymap.d.ts +2 -1
- package/dist/types-ts4.5/plugins/extension/pm-plugins/main.d.ts +3 -1
- package/dist/types-ts4.5/plugins/extension/toolbar.d.ts +8 -1
- package/dist/types-ts4.5/plugins/extension/types.d.ts +2 -0
- package/dist/types-ts4.5/plugins/floating-toolbar/ui/ExtensionsPlaceholder.d.ts +2 -0
- package/dist/types-ts4.5/plugins/floating-toolbar/ui/Toolbar.d.ts +7 -3
- package/dist/types-ts4.5/plugins/index.d.ts +0 -1
- package/package.json +2 -1
- package/dist/cjs/plugins/context-panel/index.js +0 -66
- package/dist/cjs/plugins/context-panel/transforms.js +0 -13
- package/dist/cjs/plugins/context-panel/types.js +0 -5
- package/dist/es2019/plugins/context-panel/index.js +0 -45
- package/dist/es2019/plugins/context-panel/transforms.js +0 -4
- package/dist/es2019/plugins/context-panel/types.js +0 -1
- package/dist/esm/plugins/context-panel/index.js +0 -57
- package/dist/esm/plugins/context-panel/transforms.js +0 -6
- package/dist/esm/plugins/context-panel/types.js +0 -1
- package/dist/types/plugins/context-panel/index.d.ts +0 -11
- package/dist/types/plugins/context-panel/transforms.d.ts +0 -2
- package/dist/types/plugins/context-panel/types.d.ts +0 -1
- package/dist/types-ts4.5/plugins/context-panel/index.d.ts +0 -11
- package/dist/types-ts4.5/plugins/context-panel/transforms.d.ts +0 -2
- package/dist/types-ts4.5/plugins/context-panel/types.d.ts +0 -1
|
@@ -45,7 +45,8 @@ var resolveExtensionIcon = /*#__PURE__*/function () {
|
|
|
45
45
|
var ExtensionButton = function ExtensionButton(props) {
|
|
46
46
|
var item = props.item,
|
|
47
47
|
node = props.node,
|
|
48
|
-
editorView = props.editorView
|
|
48
|
+
editorView = props.editorView,
|
|
49
|
+
applyChangeToContextPanel = props.applyChangeToContextPanel;
|
|
49
50
|
var ButtonIcon = React.useMemo(function () {
|
|
50
51
|
return item.icon ? Loadable({
|
|
51
52
|
loader: function () {
|
|
@@ -74,7 +75,8 @@ var ExtensionButton = function ExtensionButton(props) {
|
|
|
74
75
|
}
|
|
75
76
|
var targetNodeAdf = nodeToJSON(node);
|
|
76
77
|
var api = createExtensionAPI({
|
|
77
|
-
editorView: editorView
|
|
78
|
+
editorView: editorView,
|
|
79
|
+
applyChange: applyChangeToContextPanel
|
|
78
80
|
});
|
|
79
81
|
item.action(targetNodeAdf, api);
|
|
80
82
|
};
|
|
@@ -93,7 +95,8 @@ export var ExtensionsPlaceholder = function ExtensionsPlaceholder(props) {
|
|
|
93
95
|
var node = props.node,
|
|
94
96
|
editorView = props.editorView,
|
|
95
97
|
extensionProvider = props.extensionProvider,
|
|
96
|
-
separator = props.separator
|
|
98
|
+
separator = props.separator,
|
|
99
|
+
applyChangeToContextPanel = props.applyChangeToContextPanel;
|
|
97
100
|
var _useState = useState([]),
|
|
98
101
|
_useState2 = _slicedToArray(_useState, 2),
|
|
99
102
|
extensions = _useState2[0],
|
|
@@ -131,9 +134,10 @@ export var ExtensionsPlaceholder = function ExtensionsPlaceholder(props) {
|
|
|
131
134
|
}, [node]);
|
|
132
135
|
var extensionItems = React.useMemo(function () {
|
|
133
136
|
return getContextualToolbarItemsFromModule(extensions, nodeAdf, createExtensionAPI({
|
|
134
|
-
editorView: editorView
|
|
137
|
+
editorView: editorView,
|
|
138
|
+
applyChange: applyChangeToContextPanel
|
|
135
139
|
}));
|
|
136
|
-
}, [extensions, nodeAdf, editorView]);
|
|
140
|
+
}, [extensions, nodeAdf, editorView, applyChangeToContextPanel]);
|
|
137
141
|
if (!extensionItems.length) {
|
|
138
142
|
return null;
|
|
139
143
|
}
|
|
@@ -148,7 +152,8 @@ export var ExtensionsPlaceholder = function ExtensionsPlaceholder(props) {
|
|
|
148
152
|
children.push( /*#__PURE__*/React.createElement(ExtensionButton, {
|
|
149
153
|
node: node,
|
|
150
154
|
item: item,
|
|
151
|
-
editorView: editorView
|
|
155
|
+
editorView: editorView,
|
|
156
|
+
applyChangeToContextPanel: applyChangeToContextPanel
|
|
152
157
|
}));
|
|
153
158
|
if (index < extensionItems.length - 1) {
|
|
154
159
|
children.push( /*#__PURE__*/React.createElement(Separator, null));
|
|
@@ -51,7 +51,8 @@ var ToolbarItems = /*#__PURE__*/React.memo(function (_ref) {
|
|
|
51
51
|
node = _ref.node,
|
|
52
52
|
setDisableScroll = _ref.setDisableScroll,
|
|
53
53
|
mountRef = _ref.mountRef,
|
|
54
|
-
featureFlags = _ref.featureFlags
|
|
54
|
+
featureFlags = _ref.featureFlags,
|
|
55
|
+
api = _ref.api;
|
|
55
56
|
var emojiAndColourPickerMountPoint = scrollable ? popupsMountPoint || (editorView === null || editorView === void 0 ? void 0 : editorView.dom.closest('.fabric-editor-popup-scroll-parent')) || (editorView === null || editorView === void 0 ? void 0 : editorView.dom.closest('.ak-editor-content-area')) || undefined : popupsMountPoint;
|
|
56
57
|
var _ref2 = featureFlags || {
|
|
57
58
|
useSomewhatSemanticTextColorNames: false
|
|
@@ -60,6 +61,7 @@ var ToolbarItems = /*#__PURE__*/React.memo(function (_ref) {
|
|
|
60
61
|
return jsx(ButtonGroup, null, items.filter(function (item) {
|
|
61
62
|
return !item.hidden;
|
|
62
63
|
}).map(function (item, idx) {
|
|
64
|
+
var _api$dependencies$con;
|
|
63
65
|
switch (item.type) {
|
|
64
66
|
case 'button':
|
|
65
67
|
var ButtonIcon = item.icon;
|
|
@@ -230,7 +232,8 @@ var ToolbarItems = /*#__PURE__*/React.memo(function (_ref) {
|
|
|
230
232
|
node: node,
|
|
231
233
|
editorView: editorView,
|
|
232
234
|
extensionProvider: extensionsProvider,
|
|
233
|
-
separator: item.separator
|
|
235
|
+
separator: item.separator,
|
|
236
|
+
applyChangeToContextPanel: api === null || api === void 0 ? void 0 : (_api$dependencies$con = api.dependencies.contextPanel) === null || _api$dependencies$con === void 0 ? void 0 : _api$dependencies$con.actions.applyChange
|
|
234
237
|
});
|
|
235
238
|
case 'separator':
|
|
236
239
|
return jsx(Separator, {
|
|
@@ -52,7 +52,6 @@ export { default as expandPlugin, isExpandInsertionEnabled } from './expand';
|
|
|
52
52
|
export { default as scrollIntoViewPlugin } from './scroll-into-view';
|
|
53
53
|
export { default as mobileDimensionsPlugin } from './mobile-dimensions';
|
|
54
54
|
export { default as findReplacePlugin } from './find-replace';
|
|
55
|
-
export { default as contextPanelPlugin } from './context-panel';
|
|
56
55
|
export { default as selectionPlugin } from './selection';
|
|
57
56
|
export { default as mobileSelectionPlugin } from './mobile-selection';
|
|
58
57
|
export { default as clipboardPlugin } from './clipboard';
|
|
@@ -22,7 +22,6 @@ import { N30 } from '@atlaskit/theme/colors';
|
|
|
22
22
|
import { akEditorSwoopCubicBezier, akEditorDefaultLayoutWidth, akEditorWideLayoutWidth, akEditorBreakoutPadding, akEditorContextPanelWidth, ATLASSIAN_NAVIGATION_HEIGHT } from '@atlaskit/editor-shared-styles';
|
|
23
23
|
import { ContextPanelConsumer } from '@atlaskit/editor-common/ui';
|
|
24
24
|
import WithPluginState from '../WithPluginState';
|
|
25
|
-
import { pluginKey as contextPanelPluginKey } from '../../plugins/context-panel';
|
|
26
25
|
import WithEditorActions from '../WithEditorActions';
|
|
27
26
|
import { getChildBreakoutModes } from '../../utils/document';
|
|
28
27
|
import { WidthContext } from '@atlaskit/editor-common/ui';
|
|
@@ -170,6 +169,14 @@ var widthPluginKey = {
|
|
|
170
169
|
return state['widthPlugin$'];
|
|
171
170
|
}
|
|
172
171
|
};
|
|
172
|
+
|
|
173
|
+
// @ts-ignore
|
|
174
|
+
var contextPanelPluginKey = {
|
|
175
|
+
key: 'contextPanelPluginKey$',
|
|
176
|
+
getState: function getState(state) {
|
|
177
|
+
return state['contextPanelPluginKey$'];
|
|
178
|
+
}
|
|
179
|
+
};
|
|
173
180
|
function ContextPanelWithActions(_ref2) {
|
|
174
181
|
var actions = _ref2.actions,
|
|
175
182
|
props = _objectWithoutProperties(_ref2, _excluded);
|
package/dist/esm/utils/action.js
CHANGED
|
@@ -20,7 +20,7 @@ function _temporaryFixForConfigPanel() {
|
|
|
20
20
|
}
|
|
21
21
|
_context.next = 4;
|
|
22
22
|
return new Promise(function (resolve) {
|
|
23
|
-
forceAutoSave(resolve)(editorView.state, editorView.dispatch);
|
|
23
|
+
forceAutoSave(extensionPluginState.applyChangeToContextPanel)(resolve)(editorView.state, editorView.dispatch);
|
|
24
24
|
});
|
|
25
25
|
case 4:
|
|
26
26
|
case "end":
|
package/dist/esm/version.json
CHANGED
|
@@ -117,7 +117,15 @@ export declare function useCXHTMLPreset({ mentionProvider, mediaProvider, placeh
|
|
|
117
117
|
hoverDecoration: (nodeType: import("prosemirror-model").NodeType<any> | import("prosemirror-model").NodeType<any>[], add: boolean, className?: string | undefined) => import("@atlaskit/editor-common/types").Command;
|
|
118
118
|
removeDecoration: import("@atlaskit/editor-common/types").Command;
|
|
119
119
|
};
|
|
120
|
-
}
|
|
120
|
+
}>, import("@atlaskit/editor-common/types").OptionalPlugin<(config?: undefined, api?: import("@atlaskit/editor-common/types").PluginInjectionAPI<"contextPanel", {
|
|
121
|
+
actions: {
|
|
122
|
+
applyChange: (tr: import("prosemirror-state").Transaction<any>) => import("prosemirror-state").Transaction<any>;
|
|
123
|
+
};
|
|
124
|
+
}> | undefined) => import("@atlaskit/editor-common/types").DefaultEditorPlugin<"contextPanel", {
|
|
125
|
+
actions: {
|
|
126
|
+
applyChange: (tr: import("prosemirror-state").Transaction<any>) => import("prosemirror-state").Transaction<any>;
|
|
127
|
+
};
|
|
128
|
+
}>>];
|
|
121
129
|
actions: {
|
|
122
130
|
forceFocusSelector: import("@atlaskit/editor-plugin-floating-toolbar").ForceFocusSelector;
|
|
123
131
|
};
|
|
@@ -140,7 +148,15 @@ export declare function useCXHTMLPreset({ mentionProvider, mediaProvider, placeh
|
|
|
140
148
|
hoverDecoration: (nodeType: import("prosemirror-model").NodeType<any> | import("prosemirror-model").NodeType<any>[], add: boolean, className?: string | undefined) => import("@atlaskit/editor-common/types").Command;
|
|
141
149
|
removeDecoration: import("@atlaskit/editor-common/types").Command;
|
|
142
150
|
};
|
|
143
|
-
}
|
|
151
|
+
}>, import("@atlaskit/editor-common/types").OptionalPlugin<(config?: undefined, api?: import("@atlaskit/editor-common/types").PluginInjectionAPI<"contextPanel", {
|
|
152
|
+
actions: {
|
|
153
|
+
applyChange: (tr: import("prosemirror-state").Transaction<any>) => import("prosemirror-state").Transaction<any>;
|
|
154
|
+
};
|
|
155
|
+
}> | undefined) => import("@atlaskit/editor-common/types").DefaultEditorPlugin<"contextPanel", {
|
|
156
|
+
actions: {
|
|
157
|
+
applyChange: (tr: import("prosemirror-state").Transaction<any>) => import("prosemirror-state").Transaction<any>;
|
|
158
|
+
};
|
|
159
|
+
}>>];
|
|
144
160
|
actions: {
|
|
145
161
|
forceFocusSelector: import("@atlaskit/editor-plugin-floating-toolbar").ForceFocusSelector;
|
|
146
162
|
};
|
|
@@ -146,7 +146,15 @@ export declare function createDefaultPreset(options: EditorPresetProps & Default
|
|
|
146
146
|
hoverDecoration: (nodeType: import("prosemirror-model").NodeType<any> | import("prosemirror-model").NodeType<any>[], add: boolean, className?: string | undefined) => import("@atlaskit/editor-common/types").Command;
|
|
147
147
|
removeDecoration: import("@atlaskit/editor-common/types").Command;
|
|
148
148
|
};
|
|
149
|
-
}
|
|
149
|
+
}>, import("@atlaskit/editor-common/types").OptionalPlugin<(config?: undefined, api?: import("@atlaskit/editor-common/types").PluginInjectionAPI<"contextPanel", {
|
|
150
|
+
actions: {
|
|
151
|
+
applyChange: (tr: import("prosemirror-state").Transaction<any>) => import("prosemirror-state").Transaction<any>;
|
|
152
|
+
};
|
|
153
|
+
}> | undefined) => import("@atlaskit/editor-common/types").DefaultEditorPlugin<"contextPanel", {
|
|
154
|
+
actions: {
|
|
155
|
+
applyChange: (tr: import("prosemirror-state").Transaction<any>) => import("prosemirror-state").Transaction<any>;
|
|
156
|
+
};
|
|
157
|
+
}>>];
|
|
150
158
|
actions: {
|
|
151
159
|
forceFocusSelector: import("@atlaskit/editor-plugin-floating-toolbar").ForceFocusSelector;
|
|
152
160
|
};
|
|
@@ -169,7 +177,15 @@ export declare function createDefaultPreset(options: EditorPresetProps & Default
|
|
|
169
177
|
hoverDecoration: (nodeType: import("prosemirror-model").NodeType<any> | import("prosemirror-model").NodeType<any>[], add: boolean, className?: string | undefined) => import("@atlaskit/editor-common/types").Command;
|
|
170
178
|
removeDecoration: import("@atlaskit/editor-common/types").Command;
|
|
171
179
|
};
|
|
172
|
-
}
|
|
180
|
+
}>, import("@atlaskit/editor-common/types").OptionalPlugin<(config?: undefined, api?: import("@atlaskit/editor-common/types").PluginInjectionAPI<"contextPanel", {
|
|
181
|
+
actions: {
|
|
182
|
+
applyChange: (tr: import("prosemirror-state").Transaction<any>) => import("prosemirror-state").Transaction<any>;
|
|
183
|
+
};
|
|
184
|
+
}> | undefined) => import("@atlaskit/editor-common/types").DefaultEditorPlugin<"contextPanel", {
|
|
185
|
+
actions: {
|
|
186
|
+
applyChange: (tr: import("prosemirror-state").Transaction<any>) => import("prosemirror-state").Transaction<any>;
|
|
187
|
+
};
|
|
188
|
+
}>>];
|
|
173
189
|
actions: {
|
|
174
190
|
forceFocusSelector: import("@atlaskit/editor-plugin-floating-toolbar").ForceFocusSelector;
|
|
175
191
|
};
|
|
@@ -381,7 +397,15 @@ export declare function useDefaultPreset(props: EditorPresetProps & DefaultPrese
|
|
|
381
397
|
hoverDecoration: (nodeType: import("prosemirror-model").NodeType<any> | import("prosemirror-model").NodeType<any>[], add: boolean, className?: string | undefined) => import("@atlaskit/editor-common/types").Command;
|
|
382
398
|
removeDecoration: import("@atlaskit/editor-common/types").Command;
|
|
383
399
|
};
|
|
384
|
-
}
|
|
400
|
+
}>, import("@atlaskit/editor-common/types").OptionalPlugin<(config?: undefined, api?: import("@atlaskit/editor-common/types").PluginInjectionAPI<"contextPanel", {
|
|
401
|
+
actions: {
|
|
402
|
+
applyChange: (tr: import("prosemirror-state").Transaction<any>) => import("prosemirror-state").Transaction<any>;
|
|
403
|
+
};
|
|
404
|
+
}> | undefined) => import("@atlaskit/editor-common/types").DefaultEditorPlugin<"contextPanel", {
|
|
405
|
+
actions: {
|
|
406
|
+
applyChange: (tr: import("prosemirror-state").Transaction<any>) => import("prosemirror-state").Transaction<any>;
|
|
407
|
+
};
|
|
408
|
+
}>>];
|
|
385
409
|
actions: {
|
|
386
410
|
forceFocusSelector: import("@atlaskit/editor-plugin-floating-toolbar").ForceFocusSelector;
|
|
387
411
|
};
|
|
@@ -404,7 +428,15 @@ export declare function useDefaultPreset(props: EditorPresetProps & DefaultPrese
|
|
|
404
428
|
hoverDecoration: (nodeType: import("prosemirror-model").NodeType<any> | import("prosemirror-model").NodeType<any>[], add: boolean, className?: string | undefined) => import("@atlaskit/editor-common/types").Command;
|
|
405
429
|
removeDecoration: import("@atlaskit/editor-common/types").Command;
|
|
406
430
|
};
|
|
407
|
-
}
|
|
431
|
+
}>, import("@atlaskit/editor-common/types").OptionalPlugin<(config?: undefined, api?: import("@atlaskit/editor-common/types").PluginInjectionAPI<"contextPanel", {
|
|
432
|
+
actions: {
|
|
433
|
+
applyChange: (tr: import("prosemirror-state").Transaction<any>) => import("prosemirror-state").Transaction<any>;
|
|
434
|
+
};
|
|
435
|
+
}> | undefined) => import("@atlaskit/editor-common/types").DefaultEditorPlugin<"contextPanel", {
|
|
436
|
+
actions: {
|
|
437
|
+
applyChange: (tr: import("prosemirror-state").Transaction<any>) => import("prosemirror-state").Transaction<any>;
|
|
438
|
+
};
|
|
439
|
+
}>>];
|
|
408
440
|
actions: {
|
|
409
441
|
forceFocusSelector: import("@atlaskit/editor-plugin-floating-toolbar").ForceFocusSelector;
|
|
410
442
|
};
|
|
@@ -120,7 +120,15 @@ export declare function useMobilePreset({ media, placeholder, maxContentSize, cr
|
|
|
120
120
|
hoverDecoration: (nodeType: import("prosemirror-model").NodeType<any> | import("prosemirror-model").NodeType<any>[], add: boolean, className?: string | undefined) => import("@atlaskit/editor-common/types").Command;
|
|
121
121
|
removeDecoration: import("@atlaskit/editor-common/types").Command;
|
|
122
122
|
};
|
|
123
|
-
}
|
|
123
|
+
}>, import("@atlaskit/editor-common/types").OptionalPlugin<(config?: undefined, api?: import("@atlaskit/editor-common/types").PluginInjectionAPI<"contextPanel", {
|
|
124
|
+
actions: {
|
|
125
|
+
applyChange: (tr: import("prosemirror-state").Transaction<any>) => import("prosemirror-state").Transaction<any>;
|
|
126
|
+
};
|
|
127
|
+
}> | undefined) => import("@atlaskit/editor-common/types").DefaultEditorPlugin<"contextPanel", {
|
|
128
|
+
actions: {
|
|
129
|
+
applyChange: (tr: import("prosemirror-state").Transaction<any>) => import("prosemirror-state").Transaction<any>;
|
|
130
|
+
};
|
|
131
|
+
}>>];
|
|
124
132
|
actions: {
|
|
125
133
|
forceFocusSelector: import("@atlaskit/editor-plugin-floating-toolbar").ForceFocusSelector;
|
|
126
134
|
};
|
|
@@ -143,7 +151,15 @@ export declare function useMobilePreset({ media, placeholder, maxContentSize, cr
|
|
|
143
151
|
hoverDecoration: (nodeType: import("prosemirror-model").NodeType<any> | import("prosemirror-model").NodeType<any>[], add: boolean, className?: string | undefined) => import("@atlaskit/editor-common/types").Command;
|
|
144
152
|
removeDecoration: import("@atlaskit/editor-common/types").Command;
|
|
145
153
|
};
|
|
146
|
-
}
|
|
154
|
+
}>, import("@atlaskit/editor-common/types").OptionalPlugin<(config?: undefined, api?: import("@atlaskit/editor-common/types").PluginInjectionAPI<"contextPanel", {
|
|
155
|
+
actions: {
|
|
156
|
+
applyChange: (tr: import("prosemirror-state").Transaction<any>) => import("prosemirror-state").Transaction<any>;
|
|
157
|
+
};
|
|
158
|
+
}> | undefined) => import("@atlaskit/editor-common/types").DefaultEditorPlugin<"contextPanel", {
|
|
159
|
+
actions: {
|
|
160
|
+
applyChange: (tr: import("prosemirror-state").Transaction<any>) => import("prosemirror-state").Transaction<any>;
|
|
161
|
+
};
|
|
162
|
+
}>>];
|
|
147
163
|
actions: {
|
|
148
164
|
forceFocusSelector: import("@atlaskit/editor-plugin-floating-toolbar").ForceFocusSelector;
|
|
149
165
|
};
|
|
@@ -6,6 +6,7 @@ import { MacroProvider } from '@atlaskit/editor-common/provider-factory';
|
|
|
6
6
|
export { transformSliceToRemoveOpenBodiedExtension } from '@atlaskit/editor-common/transforms';
|
|
7
7
|
import { Command, CommandDispatch } from '../../types';
|
|
8
8
|
import EditorActions from '../../actions';
|
|
9
|
+
import type { ApplyChangeHandler } from '@atlaskit/editor-plugin-context-panel';
|
|
9
10
|
export declare const buildExtensionNode: <S extends Schema<any, any>>(type: 'inlineExtension' | 'extension' | 'bodiedExtension', schema: S, attrs: object, content?: Fragment, marks?: Mark<S>[] | undefined) => PmNode<Schema<any, any>>;
|
|
10
11
|
export declare const performNodeUpdate: (type: 'inlineExtension' | 'extension' | 'bodiedExtension', newAttrs: object, content: Fragment<any>, marks: Mark[], shouldScrollIntoView: boolean) => Command;
|
|
11
12
|
export declare const updateExtensionParams: (updateExtension: UpdateExtension<object>, node: {
|
|
@@ -13,4 +14,4 @@ export declare const updateExtensionParams: (updateExtension: UpdateExtension<ob
|
|
|
13
14
|
pos: number;
|
|
14
15
|
}, actions: ExtensionAPI) => (state: EditorState, dispatch?: CommandDispatch, view?: EditorView) => Promise<boolean>;
|
|
15
16
|
export declare const editSelectedExtension: (editorActions: EditorActions) => boolean;
|
|
16
|
-
export declare const editExtension: (macroProvider: MacroProvider | null, updateExtension?: Promise<UpdateExtension<object> | void>) => Command;
|
|
17
|
+
export declare const editExtension: (macroProvider: MacroProvider | null, applyChangeToContextPanel: ApplyChangeHandler | undefined, updateExtension?: Promise<UpdateExtension<object> | void>) => Command;
|
|
@@ -2,10 +2,11 @@ import { ExtensionLayout } from '@atlaskit/adf-schema';
|
|
|
2
2
|
import { Node as PMNode } from 'prosemirror-model';
|
|
3
3
|
import { ExtensionState } from './types';
|
|
4
4
|
import { Parameters, TransformBefore, TransformAfter } from '@atlaskit/editor-common/src/extensions';
|
|
5
|
+
import type { ApplyChangeHandler } from '@atlaskit/editor-plugin-context-panel';
|
|
5
6
|
export declare function updateState(state: Partial<ExtensionState>): import("@atlaskit/editor-common/types").Command;
|
|
6
|
-
export declare function setEditingContextToContextPanel<T extends Parameters = Parameters>(processParametersBefore: TransformBefore<T>, processParametersAfter: TransformAfter<T
|
|
7
|
-
export declare const clearEditingContext: import("@atlaskit/editor-common/types").Command;
|
|
8
|
-
export declare const forceAutoSave: (resolve: () => void, reject?: ((reason?: any) => void) | undefined) => import("@atlaskit/editor-common/types").Command;
|
|
7
|
+
export declare function setEditingContextToContextPanel<T extends Parameters = Parameters>(processParametersBefore: TransformBefore<T>, processParametersAfter: TransformAfter<T>, applyChangeToContextPanel: ApplyChangeHandler | undefined): import("@atlaskit/editor-common/types").Command;
|
|
8
|
+
export declare const clearEditingContext: (applyChangeToContextPanel: ApplyChangeHandler | undefined) => import("@atlaskit/editor-common/types").Command;
|
|
9
|
+
export declare const forceAutoSave: (applyChangeToContextPanel: ApplyChangeHandler | undefined) => (resolve: () => void, reject?: ((reason?: any) => void) | undefined) => import("@atlaskit/editor-common/types").Command;
|
|
9
10
|
export declare const updateExtensionLayout: (layout: ExtensionLayout) => import("@atlaskit/editor-common/types").Command;
|
|
10
11
|
export declare const removeExtension: () => import("@atlaskit/editor-common/types").Command;
|
|
11
12
|
export declare const removeDescendantNodes: (sourceNode?: PMNode) => import("@atlaskit/editor-common/types").Command;
|
|
@@ -3,5 +3,6 @@ import { EditorState } from 'prosemirror-state';
|
|
|
3
3
|
import { FeatureFlags } from '@atlaskit/editor-common/types';
|
|
4
4
|
import type { EditorView } from 'prosemirror-view';
|
|
5
5
|
import type { ContentNodeWithPos } from 'prosemirror-utils';
|
|
6
|
-
|
|
6
|
+
import type { ApplyChangeHandler } from '@atlaskit/editor-plugin-context-panel';
|
|
7
|
+
export declare const getContextPanel: (allowAutoSave?: boolean, featureFlags?: FeatureFlags, applyChange?: ApplyChangeHandler) => (state: EditorState) => JSX.Element | undefined;
|
|
7
8
|
export declare function onChangeAction(editorView: EditorView, updatedParameters: object | undefined, oldParameters: object | undefined, nodeWithPos: ContentNodeWithPos, onSaving?: () => void): Promise<void>;
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { ExtensionAPI } from '@atlaskit/editor-common/extensions';
|
|
2
2
|
import type { EditorView } from 'prosemirror-view';
|
|
3
3
|
import { MacroProvider } from '../macro';
|
|
4
|
+
import type { ApplyChangeHandler } from '@atlaskit/editor-plugin-context-panel';
|
|
4
5
|
interface EditInLegacyMacroBrowserArgs {
|
|
5
6
|
view: EditorView;
|
|
6
7
|
macroProvider?: MacroProvider;
|
|
@@ -8,6 +9,7 @@ interface EditInLegacyMacroBrowserArgs {
|
|
|
8
9
|
export declare const getEditInLegacyMacroBrowser: ({ view, macroProvider, }: EditInLegacyMacroBrowserArgs) => () => void;
|
|
9
10
|
interface CreateExtensionAPIOptions {
|
|
10
11
|
editorView: EditorView;
|
|
12
|
+
applyChange: ApplyChangeHandler | undefined;
|
|
11
13
|
editInLegacyMacroBrowser?: () => void;
|
|
12
14
|
}
|
|
13
15
|
export declare const createExtensionAPI: (options: CreateExtensionAPIOptions) => ExtensionAPI;
|
|
@@ -1,9 +1,10 @@
|
|
|
1
1
|
import { ExtensionHandlers } from '@atlaskit/editor-common/extensions';
|
|
2
2
|
import type featureFlagsPlugin from '@atlaskit/editor-plugin-feature-flags';
|
|
3
|
-
import { NextEditorPlugin, EditorAppearance } from '
|
|
3
|
+
import { NextEditorPlugin, EditorAppearance, OptionalPlugin } from '@atlaskit/editor-common/types';
|
|
4
4
|
import { LongPressSelectionPluginOptions } from '../selection/types';
|
|
5
5
|
import type { widthPlugin } from '@atlaskit/editor-plugin-width';
|
|
6
6
|
import type { decorationsPlugin } from '@atlaskit/editor-plugin-decorations';
|
|
7
|
+
import type { contextPanelPlugin } from '@atlaskit/editor-plugin-context-panel';
|
|
7
8
|
interface ExtensionPluginOptions extends LongPressSelectionPluginOptions {
|
|
8
9
|
allowAutoSave?: boolean;
|
|
9
10
|
breakoutEnabled?: boolean;
|
|
@@ -15,7 +16,8 @@ declare const extensionPlugin: NextEditorPlugin<'extension', {
|
|
|
15
16
|
dependencies: [
|
|
16
17
|
typeof featureFlagsPlugin,
|
|
17
18
|
typeof widthPlugin,
|
|
18
|
-
typeof decorationsPlugin
|
|
19
|
+
typeof decorationsPlugin,
|
|
20
|
+
OptionalPlugin<typeof contextPanelPlugin>
|
|
19
21
|
];
|
|
20
22
|
}>;
|
|
21
23
|
export default extensionPlugin;
|
|
@@ -1,2 +1,3 @@
|
|
|
1
1
|
import { SafePlugin } from '@atlaskit/editor-common/safe-plugin';
|
|
2
|
-
|
|
2
|
+
import type { ApplyChangeHandler } from '@atlaskit/editor-plugin-context-panel';
|
|
3
|
+
export default function keymapPlugin(applyChange: ApplyChangeHandler | undefined): SafePlugin;
|
|
@@ -11,13 +11,15 @@ import { PortalProviderAPI } from '../../../ui/PortalProvider';
|
|
|
11
11
|
import { getPluginState, createCommand } from '../plugin-factory';
|
|
12
12
|
import { pluginKey } from '../plugin-key';
|
|
13
13
|
import type extensionPlugin from '../index';
|
|
14
|
+
import type { ApplyChangeHandler } from '@atlaskit/editor-plugin-context-panel';
|
|
14
15
|
export declare const createExtensionProviderHandler: (view: EditorView) => (name: string, provider?: Promise<ExtensionProvider>) => Promise<void>;
|
|
15
16
|
export declare const createContextIdentifierProviderHandler: (view: EditorView) => (name: string, provider?: Promise<ContextIdentifierProvider>) => Promise<void>;
|
|
16
|
-
export declare const handleUpdate: ({ view, prevState, domAtPos, extensionHandlers, }: {
|
|
17
|
+
export declare const handleUpdate: ({ view, prevState, domAtPos, extensionHandlers, applyChange, }: {
|
|
17
18
|
view: EditorView;
|
|
18
19
|
prevState: EditorState;
|
|
19
20
|
domAtPos: EditorView['domAtPos'];
|
|
20
21
|
extensionHandlers: ExtensionHandlers;
|
|
22
|
+
applyChange: ApplyChangeHandler | undefined;
|
|
21
23
|
}) => true | undefined;
|
|
22
24
|
declare const createPlugin: (dispatch: Dispatch, providerFactory: ProviderFactory, extensionHandlers: ExtensionHandlers, portalProviderAPI: PortalProviderAPI, eventDispatcher: EventDispatcher, pluginInjectionApi: ExtractInjectionAPI<typeof extensionPlugin> | undefined, useLongPressSelection?: boolean, options?: {
|
|
23
25
|
appearance?: EditorAppearance;
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { FloatingToolbarHandler } from '../floating-toolbar/types';
|
|
2
2
|
import type { HoverDecorationHandler } from '@atlaskit/editor-plugin-decorations';
|
|
3
|
+
import type { ApplyChangeHandler } from '@atlaskit/editor-plugin-context-panel';
|
|
3
4
|
export declare const messages: {
|
|
4
5
|
edit: {
|
|
5
6
|
id: string;
|
|
@@ -32,4 +33,10 @@ export declare const messages: {
|
|
|
32
33
|
description: string;
|
|
33
34
|
};
|
|
34
35
|
};
|
|
35
|
-
|
|
36
|
+
interface GetToolbarConfigProps {
|
|
37
|
+
breakoutEnabled: boolean | undefined;
|
|
38
|
+
hoverDecoration: HoverDecorationHandler | undefined;
|
|
39
|
+
applyChangeToContextPanel: ApplyChangeHandler | undefined;
|
|
40
|
+
}
|
|
41
|
+
export declare const getToolbarConfig: ({ breakoutEnabled, hoverDecoration, applyChangeToContextPanel, }: GetToolbarConfigProps) => FloatingToolbarHandler;
|
|
42
|
+
export {};
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import type { ContextIdentifierProvider } from '@atlaskit/editor-common/provider-factory';
|
|
2
2
|
import { UpdateExtension, ExtensionProvider, Parameters, TransformBefore, TransformAfter } from '@atlaskit/editor-common/extensions';
|
|
3
|
+
import type { ApplyChangeHandler } from '@atlaskit/editor-plugin-context-panel';
|
|
3
4
|
export type ExtensionState<T extends Parameters = Parameters> = {
|
|
4
5
|
localId?: string;
|
|
5
6
|
autoSaveResolve?: () => void;
|
|
@@ -13,6 +14,7 @@ export type ExtensionState<T extends Parameters = Parameters> = {
|
|
|
13
14
|
processParametersBefore?: TransformBefore<T>;
|
|
14
15
|
processParametersAfter?: TransformAfter<T>;
|
|
15
16
|
positions?: Record<number, number>;
|
|
17
|
+
applyChangeToContextPanel: ApplyChangeHandler | undefined;
|
|
16
18
|
};
|
|
17
19
|
export type ExtensionAction<T extends Parameters = Parameters> = {
|
|
18
20
|
type: 'UPDATE_STATE';
|
|
@@ -2,11 +2,13 @@
|
|
|
2
2
|
import { Node as PMNode } from 'prosemirror-model';
|
|
3
3
|
import { EditorView } from 'prosemirror-view';
|
|
4
4
|
import type { ExtensionProvider } from '@atlaskit/editor-common/extensions';
|
|
5
|
+
import type { ApplyChangeHandler } from '@atlaskit/editor-plugin-context-panel';
|
|
5
6
|
interface Props {
|
|
6
7
|
node: PMNode;
|
|
7
8
|
extensionProvider: ExtensionProvider;
|
|
8
9
|
editorView: EditorView;
|
|
9
10
|
separator?: 'start' | 'end' | 'both';
|
|
11
|
+
applyChangeToContextPanel: ApplyChangeHandler | undefined;
|
|
10
12
|
}
|
|
11
13
|
export declare const ExtensionsPlaceholder: (props: Props) => JSX.Element | null;
|
|
12
14
|
export {};
|
|
@@ -7,8 +7,9 @@ import { ProviderFactory } from '@atlaskit/editor-common/provider-factory';
|
|
|
7
7
|
import type { DispatchAnalyticsEvent } from '@atlaskit/editor-common/analytics';
|
|
8
8
|
import { FloatingToolbarItem } from '../types';
|
|
9
9
|
import { WrappedComponentProps } from 'react-intl-next';
|
|
10
|
-
import { FeatureFlags,
|
|
11
|
-
import { decorationsPlugin } from '@atlaskit/editor-plugin-decorations';
|
|
10
|
+
import { FeatureFlags, PluginInjectionAPIWithDependencies, OptionalPlugin } from '@atlaskit/editor-common/types';
|
|
11
|
+
import type { decorationsPlugin } from '@atlaskit/editor-plugin-decorations';
|
|
12
|
+
import type { contextPanelPlugin } from '@atlaskit/editor-plugin-context-panel';
|
|
12
13
|
export type Item = FloatingToolbarItem<Function>;
|
|
13
14
|
export interface Props {
|
|
14
15
|
items: Array<Item>;
|
|
@@ -26,7 +27,10 @@ export interface Props {
|
|
|
26
27
|
extensionsProvider?: ExtensionProvider;
|
|
27
28
|
scrollable?: boolean;
|
|
28
29
|
featureFlags: FeatureFlags;
|
|
29
|
-
api:
|
|
30
|
+
api: PluginInjectionAPIWithDependencies<[
|
|
31
|
+
typeof decorationsPlugin,
|
|
32
|
+
OptionalPlugin<typeof contextPanelPlugin>
|
|
33
|
+
]> | undefined;
|
|
30
34
|
}
|
|
31
35
|
export declare const isSameItem: (leftItem: Item, rightItem: Item) => boolean;
|
|
32
36
|
export declare const areSameItems: (leftArr?: Array<Item>, rightArr?: Array<Item>) => boolean;
|
|
@@ -53,7 +53,6 @@ export { default as expandPlugin, isExpandInsertionEnabled } from './expand';
|
|
|
53
53
|
export { default as scrollIntoViewPlugin } from './scroll-into-view';
|
|
54
54
|
export { default as mobileDimensionsPlugin } from './mobile-dimensions';
|
|
55
55
|
export { default as findReplacePlugin } from './find-replace';
|
|
56
|
-
export { default as contextPanelPlugin } from './context-panel';
|
|
57
56
|
export { default as selectionPlugin } from './selection';
|
|
58
57
|
export { default as mobileSelectionPlugin } from './mobile-selection';
|
|
59
58
|
export { default as clipboardPlugin } from './clipboard';
|
|
@@ -150,7 +150,16 @@ export declare function useCXHTMLPreset({ mentionProvider, mediaProvider, placeh
|
|
|
150
150
|
hoverDecoration: (nodeType: import("prosemirror-model").NodeType<any> | import("prosemirror-model").NodeType<any>[], add: boolean, className?: string | undefined) => import("@atlaskit/editor-common/types").Command;
|
|
151
151
|
removeDecoration: import("@atlaskit/editor-common/types").Command;
|
|
152
152
|
};
|
|
153
|
-
}
|
|
153
|
+
}>,
|
|
154
|
+
import("@atlaskit/editor-common/types").OptionalPlugin<(config?: undefined, api?: import("@atlaskit/editor-common/types").PluginInjectionAPI<"contextPanel", {
|
|
155
|
+
actions: {
|
|
156
|
+
applyChange: (tr: import("prosemirror-state").Transaction<any>) => import("prosemirror-state").Transaction<any>;
|
|
157
|
+
};
|
|
158
|
+
}> | undefined) => import("@atlaskit/editor-common/types").DefaultEditorPlugin<"contextPanel", {
|
|
159
|
+
actions: {
|
|
160
|
+
applyChange: (tr: import("prosemirror-state").Transaction<any>) => import("prosemirror-state").Transaction<any>;
|
|
161
|
+
};
|
|
162
|
+
}>>
|
|
154
163
|
];
|
|
155
164
|
actions: {
|
|
156
165
|
forceFocusSelector: import("@atlaskit/editor-plugin-floating-toolbar").ForceFocusSelector;
|
|
@@ -176,7 +185,16 @@ export declare function useCXHTMLPreset({ mentionProvider, mediaProvider, placeh
|
|
|
176
185
|
hoverDecoration: (nodeType: import("prosemirror-model").NodeType<any> | import("prosemirror-model").NodeType<any>[], add: boolean, className?: string | undefined) => import("@atlaskit/editor-common/types").Command;
|
|
177
186
|
removeDecoration: import("@atlaskit/editor-common/types").Command;
|
|
178
187
|
};
|
|
179
|
-
}
|
|
188
|
+
}>,
|
|
189
|
+
import("@atlaskit/editor-common/types").OptionalPlugin<(config?: undefined, api?: import("@atlaskit/editor-common/types").PluginInjectionAPI<"contextPanel", {
|
|
190
|
+
actions: {
|
|
191
|
+
applyChange: (tr: import("prosemirror-state").Transaction<any>) => import("prosemirror-state").Transaction<any>;
|
|
192
|
+
};
|
|
193
|
+
}> | undefined) => import("@atlaskit/editor-common/types").DefaultEditorPlugin<"contextPanel", {
|
|
194
|
+
actions: {
|
|
195
|
+
applyChange: (tr: import("prosemirror-state").Transaction<any>) => import("prosemirror-state").Transaction<any>;
|
|
196
|
+
};
|
|
197
|
+
}>>
|
|
180
198
|
];
|
|
181
199
|
actions: {
|
|
182
200
|
forceFocusSelector: import("@atlaskit/editor-plugin-floating-toolbar").ForceFocusSelector;
|
|
@@ -179,7 +179,16 @@ export declare function createDefaultPreset(options: EditorPresetProps & Default
|
|
|
179
179
|
hoverDecoration: (nodeType: import("prosemirror-model").NodeType<any> | import("prosemirror-model").NodeType<any>[], add: boolean, className?: string | undefined) => import("@atlaskit/editor-common/types").Command;
|
|
180
180
|
removeDecoration: import("@atlaskit/editor-common/types").Command;
|
|
181
181
|
};
|
|
182
|
-
}
|
|
182
|
+
}>,
|
|
183
|
+
import("@atlaskit/editor-common/types").OptionalPlugin<(config?: undefined, api?: import("@atlaskit/editor-common/types").PluginInjectionAPI<"contextPanel", {
|
|
184
|
+
actions: {
|
|
185
|
+
applyChange: (tr: import("prosemirror-state").Transaction<any>) => import("prosemirror-state").Transaction<any>;
|
|
186
|
+
};
|
|
187
|
+
}> | undefined) => import("@atlaskit/editor-common/types").DefaultEditorPlugin<"contextPanel", {
|
|
188
|
+
actions: {
|
|
189
|
+
applyChange: (tr: import("prosemirror-state").Transaction<any>) => import("prosemirror-state").Transaction<any>;
|
|
190
|
+
};
|
|
191
|
+
}>>
|
|
183
192
|
];
|
|
184
193
|
actions: {
|
|
185
194
|
forceFocusSelector: import("@atlaskit/editor-plugin-floating-toolbar").ForceFocusSelector;
|
|
@@ -205,7 +214,16 @@ export declare function createDefaultPreset(options: EditorPresetProps & Default
|
|
|
205
214
|
hoverDecoration: (nodeType: import("prosemirror-model").NodeType<any> | import("prosemirror-model").NodeType<any>[], add: boolean, className?: string | undefined) => import("@atlaskit/editor-common/types").Command;
|
|
206
215
|
removeDecoration: import("@atlaskit/editor-common/types").Command;
|
|
207
216
|
};
|
|
208
|
-
}
|
|
217
|
+
}>,
|
|
218
|
+
import("@atlaskit/editor-common/types").OptionalPlugin<(config?: undefined, api?: import("@atlaskit/editor-common/types").PluginInjectionAPI<"contextPanel", {
|
|
219
|
+
actions: {
|
|
220
|
+
applyChange: (tr: import("prosemirror-state").Transaction<any>) => import("prosemirror-state").Transaction<any>;
|
|
221
|
+
};
|
|
222
|
+
}> | undefined) => import("@atlaskit/editor-common/types").DefaultEditorPlugin<"contextPanel", {
|
|
223
|
+
actions: {
|
|
224
|
+
applyChange: (tr: import("prosemirror-state").Transaction<any>) => import("prosemirror-state").Transaction<any>;
|
|
225
|
+
};
|
|
226
|
+
}>>
|
|
209
227
|
];
|
|
210
228
|
actions: {
|
|
211
229
|
forceFocusSelector: import("@atlaskit/editor-plugin-floating-toolbar").ForceFocusSelector;
|
|
@@ -476,7 +494,16 @@ export declare function useDefaultPreset(props: EditorPresetProps & DefaultPrese
|
|
|
476
494
|
hoverDecoration: (nodeType: import("prosemirror-model").NodeType<any> | import("prosemirror-model").NodeType<any>[], add: boolean, className?: string | undefined) => import("@atlaskit/editor-common/types").Command;
|
|
477
495
|
removeDecoration: import("@atlaskit/editor-common/types").Command;
|
|
478
496
|
};
|
|
479
|
-
}
|
|
497
|
+
}>,
|
|
498
|
+
import("@atlaskit/editor-common/types").OptionalPlugin<(config?: undefined, api?: import("@atlaskit/editor-common/types").PluginInjectionAPI<"contextPanel", {
|
|
499
|
+
actions: {
|
|
500
|
+
applyChange: (tr: import("prosemirror-state").Transaction<any>) => import("prosemirror-state").Transaction<any>;
|
|
501
|
+
};
|
|
502
|
+
}> | undefined) => import("@atlaskit/editor-common/types").DefaultEditorPlugin<"contextPanel", {
|
|
503
|
+
actions: {
|
|
504
|
+
applyChange: (tr: import("prosemirror-state").Transaction<any>) => import("prosemirror-state").Transaction<any>;
|
|
505
|
+
};
|
|
506
|
+
}>>
|
|
480
507
|
];
|
|
481
508
|
actions: {
|
|
482
509
|
forceFocusSelector: import("@atlaskit/editor-plugin-floating-toolbar").ForceFocusSelector;
|
|
@@ -502,7 +529,16 @@ export declare function useDefaultPreset(props: EditorPresetProps & DefaultPrese
|
|
|
502
529
|
hoverDecoration: (nodeType: import("prosemirror-model").NodeType<any> | import("prosemirror-model").NodeType<any>[], add: boolean, className?: string | undefined) => import("@atlaskit/editor-common/types").Command;
|
|
503
530
|
removeDecoration: import("@atlaskit/editor-common/types").Command;
|
|
504
531
|
};
|
|
505
|
-
}
|
|
532
|
+
}>,
|
|
533
|
+
import("@atlaskit/editor-common/types").OptionalPlugin<(config?: undefined, api?: import("@atlaskit/editor-common/types").PluginInjectionAPI<"contextPanel", {
|
|
534
|
+
actions: {
|
|
535
|
+
applyChange: (tr: import("prosemirror-state").Transaction<any>) => import("prosemirror-state").Transaction<any>;
|
|
536
|
+
};
|
|
537
|
+
}> | undefined) => import("@atlaskit/editor-common/types").DefaultEditorPlugin<"contextPanel", {
|
|
538
|
+
actions: {
|
|
539
|
+
applyChange: (tr: import("prosemirror-state").Transaction<any>) => import("prosemirror-state").Transaction<any>;
|
|
540
|
+
};
|
|
541
|
+
}>>
|
|
506
542
|
];
|
|
507
543
|
actions: {
|
|
508
544
|
forceFocusSelector: import("@atlaskit/editor-plugin-floating-toolbar").ForceFocusSelector;
|
|
@@ -153,7 +153,16 @@ export declare function useMobilePreset({ media, placeholder, maxContentSize, cr
|
|
|
153
153
|
hoverDecoration: (nodeType: import("prosemirror-model").NodeType<any> | import("prosemirror-model").NodeType<any>[], add: boolean, className?: string | undefined) => import("@atlaskit/editor-common/types").Command;
|
|
154
154
|
removeDecoration: import("@atlaskit/editor-common/types").Command;
|
|
155
155
|
};
|
|
156
|
-
}
|
|
156
|
+
}>,
|
|
157
|
+
import("@atlaskit/editor-common/types").OptionalPlugin<(config?: undefined, api?: import("@atlaskit/editor-common/types").PluginInjectionAPI<"contextPanel", {
|
|
158
|
+
actions: {
|
|
159
|
+
applyChange: (tr: import("prosemirror-state").Transaction<any>) => import("prosemirror-state").Transaction<any>;
|
|
160
|
+
};
|
|
161
|
+
}> | undefined) => import("@atlaskit/editor-common/types").DefaultEditorPlugin<"contextPanel", {
|
|
162
|
+
actions: {
|
|
163
|
+
applyChange: (tr: import("prosemirror-state").Transaction<any>) => import("prosemirror-state").Transaction<any>;
|
|
164
|
+
};
|
|
165
|
+
}>>
|
|
157
166
|
];
|
|
158
167
|
actions: {
|
|
159
168
|
forceFocusSelector: import("@atlaskit/editor-plugin-floating-toolbar").ForceFocusSelector;
|
|
@@ -179,7 +188,16 @@ export declare function useMobilePreset({ media, placeholder, maxContentSize, cr
|
|
|
179
188
|
hoverDecoration: (nodeType: import("prosemirror-model").NodeType<any> | import("prosemirror-model").NodeType<any>[], add: boolean, className?: string | undefined) => import("@atlaskit/editor-common/types").Command;
|
|
180
189
|
removeDecoration: import("@atlaskit/editor-common/types").Command;
|
|
181
190
|
};
|
|
182
|
-
}
|
|
191
|
+
}>,
|
|
192
|
+
import("@atlaskit/editor-common/types").OptionalPlugin<(config?: undefined, api?: import("@atlaskit/editor-common/types").PluginInjectionAPI<"contextPanel", {
|
|
193
|
+
actions: {
|
|
194
|
+
applyChange: (tr: import("prosemirror-state").Transaction<any>) => import("prosemirror-state").Transaction<any>;
|
|
195
|
+
};
|
|
196
|
+
}> | undefined) => import("@atlaskit/editor-common/types").DefaultEditorPlugin<"contextPanel", {
|
|
197
|
+
actions: {
|
|
198
|
+
applyChange: (tr: import("prosemirror-state").Transaction<any>) => import("prosemirror-state").Transaction<any>;
|
|
199
|
+
};
|
|
200
|
+
}>>
|
|
183
201
|
];
|
|
184
202
|
actions: {
|
|
185
203
|
forceFocusSelector: import("@atlaskit/editor-plugin-floating-toolbar").ForceFocusSelector;
|