@atlaskit/editor-common 76.34.0 → 76.36.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +53 -1
- package/dist/cjs/collab/index.js +27 -2
- package/dist/cjs/core-utils/document-logger.js +171 -0
- package/dist/cjs/core-utils/index.js +8 -1
- package/dist/cjs/extensibility/Extension/Extension/index.js +151 -0
- package/dist/cjs/extensibility/Extension/Extension/styles.js +17 -0
- package/dist/cjs/extensibility/Extension/InlineExtension/index.js +50 -0
- package/dist/cjs/extensibility/Extension/InlineExtension/styles.js +12 -0
- package/dist/cjs/extensibility/Extension/Lozenge.js +95 -0
- package/dist/cjs/extensibility/Extension/styles.js +30 -0
- package/dist/cjs/extensibility/Extension.js +79 -0
- package/dist/cjs/extensibility/ExtensionComponent.js +252 -0
- package/dist/cjs/extensibility/ExtensionNodeWrapper.js +21 -0
- package/dist/cjs/extensibility/MultiBodiedExtension/index.js +264 -0
- package/dist/cjs/extensibility/extensionNodeView.js +91 -0
- package/dist/cjs/extensibility/index.js +42 -0
- package/dist/cjs/extensibility/types.js +5 -0
- package/dist/cjs/i18n/cs.js +5 -2
- package/dist/cjs/i18n/da.js +5 -2
- package/dist/cjs/i18n/de.js +5 -2
- package/dist/cjs/i18n/en.js +7 -1
- package/dist/cjs/i18n/en_GB.js +8 -2
- package/dist/cjs/i18n/en_ZZ.js +8 -2
- package/dist/cjs/i18n/es.js +5 -2
- package/dist/cjs/i18n/fi.js +5 -2
- package/dist/cjs/i18n/fr.js +5 -2
- package/dist/cjs/i18n/hu.js +5 -2
- package/dist/cjs/i18n/it.js +5 -2
- package/dist/cjs/i18n/ja.js +1 -2
- package/dist/cjs/i18n/ko.js +5 -2
- package/dist/cjs/i18n/nb.js +1 -2
- package/dist/cjs/i18n/nl.js +5 -2
- package/dist/cjs/i18n/pl.js +5 -2
- package/dist/cjs/i18n/pt_BR.js +5 -2
- package/dist/cjs/i18n/ru.js +5 -2
- package/dist/cjs/i18n/sv.js +5 -2
- package/dist/cjs/i18n/th.js +5 -2
- package/dist/cjs/i18n/tr.js +5 -2
- package/dist/cjs/i18n/uk.js +5 -2
- package/dist/cjs/i18n/vi.js +5 -2
- package/dist/cjs/i18n/zh.js +5 -2
- package/dist/cjs/i18n/zh_TW.js +5 -2
- package/dist/cjs/link/LinkPicker/HyperlinkAddToolbar/HyperlinkAddToolbar.js +2 -1
- package/dist/cjs/link/LinkPicker/HyperlinkAddToolbar/index.js +1 -2
- package/dist/cjs/monitoring/error.js +3 -2
- package/dist/cjs/ui/DropList/index.js +1 -1
- package/dist/es2019/collab/index.js +54 -1
- package/dist/es2019/core-utils/document-logger.js +161 -0
- package/dist/es2019/core-utils/index.js +2 -1
- package/dist/es2019/extensibility/Extension/Extension/index.js +155 -0
- package/dist/es2019/extensibility/Extension/Extension/styles.js +42 -0
- package/dist/es2019/extensibility/Extension/InlineExtension/index.js +26 -0
- package/dist/es2019/extensibility/Extension/InlineExtension/styles.js +26 -0
- package/dist/es2019/extensibility/Extension/Lozenge.js +71 -0
- package/dist/es2019/extensibility/Extension/styles.js +62 -0
- package/dist/es2019/extensibility/Extension.js +52 -0
- package/dist/es2019/extensibility/ExtensionComponent.js +204 -0
- package/dist/es2019/extensibility/ExtensionNodeWrapper.js +13 -0
- package/dist/es2019/extensibility/MultiBodiedExtension/index.js +283 -0
- package/dist/es2019/extensibility/extensionNodeView.js +62 -0
- package/dist/es2019/extensibility/index.js +4 -0
- package/dist/es2019/extensibility/types.js +1 -0
- package/dist/es2019/i18n/cs.js +5 -2
- package/dist/es2019/i18n/da.js +5 -2
- package/dist/es2019/i18n/de.js +5 -2
- package/dist/es2019/i18n/en.js +7 -1
- package/dist/es2019/i18n/en_GB.js +8 -2
- package/dist/es2019/i18n/en_ZZ.js +8 -2
- package/dist/es2019/i18n/es.js +5 -2
- package/dist/es2019/i18n/fi.js +5 -2
- package/dist/es2019/i18n/fr.js +5 -2
- package/dist/es2019/i18n/hu.js +5 -2
- package/dist/es2019/i18n/it.js +5 -2
- package/dist/es2019/i18n/ja.js +1 -2
- package/dist/es2019/i18n/ko.js +5 -2
- package/dist/es2019/i18n/nb.js +1 -2
- package/dist/es2019/i18n/nl.js +5 -2
- package/dist/es2019/i18n/pl.js +5 -2
- package/dist/es2019/i18n/pt_BR.js +5 -2
- package/dist/es2019/i18n/ru.js +5 -2
- package/dist/es2019/i18n/sv.js +5 -2
- package/dist/es2019/i18n/th.js +5 -2
- package/dist/es2019/i18n/tr.js +5 -2
- package/dist/es2019/i18n/uk.js +5 -2
- package/dist/es2019/i18n/vi.js +5 -2
- package/dist/es2019/i18n/zh.js +5 -2
- package/dist/es2019/i18n/zh_TW.js +5 -2
- package/dist/es2019/link/LinkPicker/HyperlinkAddToolbar/HyperlinkAddToolbar.js +2 -1
- package/dist/es2019/link/LinkPicker/HyperlinkAddToolbar/index.js +1 -4
- package/dist/es2019/monitoring/error.js +3 -2
- package/dist/es2019/ui/DropList/index.js +1 -1
- package/dist/esm/collab/index.js +23 -1
- package/dist/esm/core-utils/document-logger.js +165 -0
- package/dist/esm/core-utils/index.js +2 -1
- package/dist/esm/extensibility/Extension/Extension/index.js +146 -0
- package/dist/esm/extensibility/Extension/Extension/styles.js +10 -0
- package/dist/esm/extensibility/Extension/InlineExtension/index.js +43 -0
- package/dist/esm/extensibility/Extension/InlineExtension/styles.js +5 -0
- package/dist/esm/extensibility/Extension/Lozenge.js +90 -0
- package/dist/esm/extensibility/Extension/styles.js +11 -0
- package/dist/esm/extensibility/Extension.js +69 -0
- package/dist/esm/extensibility/ExtensionComponent.js +243 -0
- package/dist/esm/extensibility/ExtensionNodeWrapper.js +14 -0
- package/dist/esm/extensibility/MultiBodiedExtension/index.js +257 -0
- package/dist/esm/extensibility/extensionNodeView.js +83 -0
- package/dist/esm/extensibility/index.js +4 -0
- package/dist/esm/extensibility/types.js +1 -0
- package/dist/esm/i18n/cs.js +5 -2
- package/dist/esm/i18n/da.js +5 -2
- package/dist/esm/i18n/de.js +5 -2
- package/dist/esm/i18n/en.js +7 -1
- package/dist/esm/i18n/en_GB.js +8 -2
- package/dist/esm/i18n/en_ZZ.js +8 -2
- package/dist/esm/i18n/es.js +5 -2
- package/dist/esm/i18n/fi.js +5 -2
- package/dist/esm/i18n/fr.js +5 -2
- package/dist/esm/i18n/hu.js +5 -2
- package/dist/esm/i18n/it.js +5 -2
- package/dist/esm/i18n/ja.js +1 -2
- package/dist/esm/i18n/ko.js +5 -2
- package/dist/esm/i18n/nb.js +1 -2
- package/dist/esm/i18n/nl.js +5 -2
- package/dist/esm/i18n/pl.js +5 -2
- package/dist/esm/i18n/pt_BR.js +5 -2
- package/dist/esm/i18n/ru.js +5 -2
- package/dist/esm/i18n/sv.js +5 -2
- package/dist/esm/i18n/th.js +5 -2
- package/dist/esm/i18n/tr.js +5 -2
- package/dist/esm/i18n/uk.js +5 -2
- package/dist/esm/i18n/vi.js +5 -2
- package/dist/esm/i18n/zh.js +5 -2
- package/dist/esm/i18n/zh_TW.js +5 -2
- package/dist/esm/link/LinkPicker/HyperlinkAddToolbar/HyperlinkAddToolbar.js +2 -1
- package/dist/esm/link/LinkPicker/HyperlinkAddToolbar/index.js +1 -2
- package/dist/esm/monitoring/error.js +3 -2
- package/dist/esm/ui/DropList/index.js +1 -1
- package/dist/types/collab/index.d.ts +7 -0
- package/dist/types/core-utils/document-logger.d.ts +6 -0
- package/dist/types/core-utils/index.d.ts +1 -0
- package/dist/types/extensibility/Extension/Extension/index.d.ts +108 -0
- package/dist/types/extensibility/Extension/Extension/styles.d.ts +5 -0
- package/dist/types/extensibility/Extension/InlineExtension/index.d.ts +12 -0
- package/dist/types/extensibility/Extension/InlineExtension/styles.d.ts +1 -0
- package/dist/types/extensibility/Extension/Lozenge.d.ts +14 -0
- package/dist/types/extensibility/Extension/styles.d.ts +7 -0
- package/dist/types/extensibility/Extension.d.ts +29 -0
- package/dist/types/extensibility/ExtensionComponent.d.ts +53 -0
- package/dist/types/extensibility/ExtensionNodeWrapper.d.ts +14 -0
- package/dist/types/extensibility/MultiBodiedExtension/index.d.ts +26 -0
- package/dist/types/extensibility/extensionNodeView.d.ts +31 -0
- package/dist/types/extensibility/index.d.ts +4 -0
- package/dist/types/extensibility/types.d.ts +6 -0
- package/dist/types/i18n/cs.d.ts +5 -2
- package/dist/types/i18n/da.d.ts +5 -2
- package/dist/types/i18n/de.d.ts +5 -2
- package/dist/types/i18n/en.d.ts +7 -1
- package/dist/types/i18n/en_GB.d.ts +7 -1
- package/dist/types/i18n/en_ZZ.d.ts +7 -1
- package/dist/types/i18n/es.d.ts +5 -2
- package/dist/types/i18n/fi.d.ts +5 -2
- package/dist/types/i18n/fr.d.ts +5 -2
- package/dist/types/i18n/hu.d.ts +5 -2
- package/dist/types/i18n/it.d.ts +5 -2
- package/dist/types/i18n/ja.d.ts +1 -2
- package/dist/types/i18n/ko.d.ts +5 -2
- package/dist/types/i18n/nb.d.ts +1 -2
- package/dist/types/i18n/nl.d.ts +5 -2
- package/dist/types/i18n/pl.d.ts +5 -2
- package/dist/types/i18n/pt_BR.d.ts +5 -2
- package/dist/types/i18n/ru.d.ts +5 -2
- package/dist/types/i18n/sv.d.ts +5 -2
- package/dist/types/i18n/th.d.ts +5 -2
- package/dist/types/i18n/tr.d.ts +5 -2
- package/dist/types/i18n/uk.d.ts +5 -2
- package/dist/types/i18n/vi.d.ts +5 -2
- package/dist/types/i18n/zh.d.ts +5 -2
- package/dist/types/i18n/zh_TW.d.ts +5 -2
- package/dist/types/link/LinkPicker/HyperlinkAddToolbar/index.d.ts +7 -7
- package/dist/types/types/floating-toolbar.d.ts +1 -1
- package/dist/types/types/hyperlink.d.ts +1 -0
- package/dist/types/types/index.d.ts +1 -1
- package/dist/types/types/next-editor-plugin.d.ts +0 -1
- package/dist/types/ui/DropList/index.d.ts +1 -1
- package/dist/types/ui/OverflowShadow/index.d.ts +1 -1
- package/dist/types/ui/with-outer-listeners.d.ts +2 -2
- package/dist/types/ui-menu/ColorPickerButton/index.d.ts +1 -1
- package/dist/types/ui-menu/ToolbarButton/index.d.ts +1 -1
- package/dist/types/ui-react/with-react-editor-view-outer-listeners.d.ts +2 -2
- package/dist/types-ts4.5/collab/index.d.ts +7 -0
- package/dist/types-ts4.5/core-utils/document-logger.d.ts +6 -0
- package/dist/types-ts4.5/core-utils/index.d.ts +1 -0
- package/dist/types-ts4.5/extensibility/Extension/Extension/index.d.ts +108 -0
- package/dist/types-ts4.5/extensibility/Extension/Extension/styles.d.ts +5 -0
- package/dist/types-ts4.5/extensibility/Extension/InlineExtension/index.d.ts +12 -0
- package/dist/types-ts4.5/extensibility/Extension/InlineExtension/styles.d.ts +1 -0
- package/dist/types-ts4.5/extensibility/Extension/Lozenge.d.ts +14 -0
- package/dist/types-ts4.5/extensibility/Extension/styles.d.ts +7 -0
- package/dist/types-ts4.5/extensibility/Extension.d.ts +29 -0
- package/dist/types-ts4.5/extensibility/ExtensionComponent.d.ts +53 -0
- package/dist/types-ts4.5/extensibility/ExtensionNodeWrapper.d.ts +14 -0
- package/dist/types-ts4.5/extensibility/MultiBodiedExtension/index.d.ts +26 -0
- package/dist/types-ts4.5/extensibility/extensionNodeView.d.ts +31 -0
- package/dist/types-ts4.5/extensibility/index.d.ts +4 -0
- package/dist/types-ts4.5/extensibility/types.d.ts +8 -0
- package/dist/types-ts4.5/i18n/cs.d.ts +5 -2
- package/dist/types-ts4.5/i18n/da.d.ts +5 -2
- package/dist/types-ts4.5/i18n/de.d.ts +5 -2
- package/dist/types-ts4.5/i18n/en.d.ts +7 -1
- package/dist/types-ts4.5/i18n/en_GB.d.ts +7 -1
- package/dist/types-ts4.5/i18n/en_ZZ.d.ts +7 -1
- package/dist/types-ts4.5/i18n/es.d.ts +5 -2
- package/dist/types-ts4.5/i18n/fi.d.ts +5 -2
- package/dist/types-ts4.5/i18n/fr.d.ts +5 -2
- package/dist/types-ts4.5/i18n/hu.d.ts +5 -2
- package/dist/types-ts4.5/i18n/it.d.ts +5 -2
- package/dist/types-ts4.5/i18n/ja.d.ts +1 -2
- package/dist/types-ts4.5/i18n/ko.d.ts +5 -2
- package/dist/types-ts4.5/i18n/nb.d.ts +1 -2
- package/dist/types-ts4.5/i18n/nl.d.ts +5 -2
- package/dist/types-ts4.5/i18n/pl.d.ts +5 -2
- package/dist/types-ts4.5/i18n/pt_BR.d.ts +5 -2
- package/dist/types-ts4.5/i18n/ru.d.ts +5 -2
- package/dist/types-ts4.5/i18n/sv.d.ts +5 -2
- package/dist/types-ts4.5/i18n/th.d.ts +5 -2
- package/dist/types-ts4.5/i18n/tr.d.ts +5 -2
- package/dist/types-ts4.5/i18n/uk.d.ts +5 -2
- package/dist/types-ts4.5/i18n/vi.d.ts +5 -2
- package/dist/types-ts4.5/i18n/zh.d.ts +5 -2
- package/dist/types-ts4.5/i18n/zh_TW.d.ts +5 -2
- package/dist/types-ts4.5/link/LinkPicker/HyperlinkAddToolbar/index.d.ts +7 -7
- package/dist/types-ts4.5/types/floating-toolbar.d.ts +1 -1
- package/dist/types-ts4.5/types/hyperlink.d.ts +1 -0
- package/dist/types-ts4.5/types/index.d.ts +1 -1
- package/dist/types-ts4.5/types/next-editor-plugin.d.ts +0 -3
- package/dist/types-ts4.5/ui/DropList/index.d.ts +1 -1
- package/dist/types-ts4.5/ui/OverflowShadow/index.d.ts +1 -1
- package/dist/types-ts4.5/ui/with-outer-listeners.d.ts +2 -2
- package/dist/types-ts4.5/ui-menu/ColorPickerButton/index.d.ts +1 -1
- package/dist/types-ts4.5/ui-menu/ToolbarButton/index.d.ts +1 -1
- package/dist/types-ts4.5/ui-react/with-react-editor-view-outer-listeners.d.ts +2 -2
- package/extensibility/package.json +15 -0
- package/package.json +8 -7
|
@@ -7,7 +7,9 @@
|
|
|
7
7
|
declare const _default: {
|
|
8
8
|
'fabric.editor.action': string;
|
|
9
9
|
'fabric.editor.action.description': string;
|
|
10
|
+
'fabric.editor.addColumn': string;
|
|
10
11
|
'fabric.editor.addMediaFiles': string;
|
|
12
|
+
'fabric.editor.addRow': string;
|
|
11
13
|
'fabric.editor.alignCenter': string;
|
|
12
14
|
'fabric.editor.alignImageCenter': string;
|
|
13
15
|
'fabric.editor.alignImageLeft': string;
|
|
@@ -15,6 +17,7 @@ declare const _default: {
|
|
|
15
17
|
'fabric.editor.alignLeft': string;
|
|
16
18
|
'fabric.editor.alignRight': string;
|
|
17
19
|
'fabric.editor.annotationToolbar': string;
|
|
20
|
+
'fabric.editor.backgroundColor': string;
|
|
18
21
|
'fabric.editor.blockCardUnavailable': string;
|
|
19
22
|
'fabric.editor.blockDescription': string;
|
|
20
23
|
'fabric.editor.blockTitle': string;
|
|
@@ -136,7 +139,6 @@ declare const _default: {
|
|
|
136
139
|
'fabric.editor.infoPanel': string;
|
|
137
140
|
'fabric.editor.infoPanel.description': string;
|
|
138
141
|
'fabric.editor.inlineDescription': string;
|
|
139
|
-
'fabric.editor.inlineOverlay': string;
|
|
140
142
|
'fabric.editor.inlineTitle': string;
|
|
141
143
|
'fabric.editor.insertColumn': string;
|
|
142
144
|
'fabric.editor.insertColumnDrag': string;
|
|
@@ -209,7 +211,8 @@ declare const _default: {
|
|
|
209
211
|
'fabric.editor.table': string;
|
|
210
212
|
'fabric.editor.table.description': string;
|
|
211
213
|
'fabric.editor.tableOptions': string;
|
|
212
|
-
'fabric.editor.
|
|
214
|
+
'fabric.editor.tableResizeDecreaseScreenReaderInformation': string;
|
|
215
|
+
'fabric.editor.tableResizeIncreaseScreenReaderInformation': string;
|
|
213
216
|
'fabric.editor.tables.adjustColumn': string;
|
|
214
217
|
'fabric.editor.tables.confirmDeleteLinkedModalMessage': string;
|
|
215
218
|
'fabric.editor.tables.confirmDeleteLinkedModalOKButton': string;
|
|
@@ -1,21 +1,21 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
-
import { UIAnalyticsEvent } from '@atlaskit/analytics-next';
|
|
3
|
-
import { EditorView } from '@atlaskit/editor-prosemirror/view';
|
|
2
|
+
import type { UIAnalyticsEvent } from '@atlaskit/analytics-next';
|
|
3
|
+
import type { EditorView } from '@atlaskit/editor-prosemirror/view';
|
|
4
4
|
import type { HyperlinkState } from '../../../link';
|
|
5
|
-
import { ProviderFactory } from '../../../provider-factory';
|
|
6
|
-
import type { Command,
|
|
7
|
-
import { EditorLinkPickerProps } from '../EditorLinkPicker';
|
|
5
|
+
import type { ProviderFactory } from '../../../provider-factory';
|
|
6
|
+
import type { Command, LinkInputType, LinkPickerOptions } from '../../../types';
|
|
7
|
+
import type { EditorLinkPickerProps } from '../EditorLinkPicker';
|
|
8
8
|
export interface HyperlinkAddToolbarProps extends Pick<EditorLinkPickerProps, 'onCancel' | 'invokeMethod' | 'onClose'> {
|
|
9
9
|
view: EditorView;
|
|
10
10
|
providerFactory: ProviderFactory;
|
|
11
11
|
onSubmit: (href: string, title: string | undefined, displayText: string | undefined, inputMethod: LinkInputType, analytic?: UIAnalyticsEvent | null | undefined) => void;
|
|
12
|
-
|
|
12
|
+
lpLinkPicker: boolean;
|
|
13
13
|
linkPickerOptions?: LinkPickerOptions;
|
|
14
14
|
displayText?: string;
|
|
15
15
|
displayUrl?: string;
|
|
16
16
|
onEscapeCallback?: Command;
|
|
17
17
|
onClickAwayCallback?: Command;
|
|
18
18
|
}
|
|
19
|
-
export declare function HyperlinkAddToolbar({ linkPickerOptions, onSubmit, displayText, displayUrl, providerFactory, view, onCancel, invokeMethod,
|
|
19
|
+
export declare function HyperlinkAddToolbar({ linkPickerOptions, onSubmit, displayText, displayUrl, providerFactory, view, onCancel, invokeMethod, lpLinkPicker, onClose, onEscapeCallback, onClickAwayCallback, hyperlinkPluginState, }: HyperlinkAddToolbarProps & {
|
|
20
20
|
hyperlinkPluginState: HyperlinkState | undefined;
|
|
21
21
|
}): JSX.Element;
|
|
@@ -143,7 +143,7 @@ export type FloatingToolbarCustom<T extends {}> = {
|
|
|
143
143
|
*/
|
|
144
144
|
disableArrowNavigation?: boolean;
|
|
145
145
|
fallback: Array<FloatingToolbarFallbackItem<T>>;
|
|
146
|
-
render: (view?: EditorView, idx?: number, dispatchAnalyticsEvent?: DispatchAnalyticsEvent) => React.ComponentClass | React.
|
|
146
|
+
render: (view?: EditorView, idx?: number, dispatchAnalyticsEvent?: DispatchAnalyticsEvent) => React.ComponentClass | React.FC | React.ReactElement<any> | null;
|
|
147
147
|
hidden?: boolean;
|
|
148
148
|
};
|
|
149
149
|
type FloatingToolbarSelectBase<T extends {}, V = SelectOption> = {
|
|
@@ -28,7 +28,7 @@ export type { EditorReactContext } from './editor-react-context';
|
|
|
28
28
|
export type { PMPluginFactoryParams, PMPluginFactory, PMPlugin, } from './plugin-factory';
|
|
29
29
|
export type { NodeConfig, MarkConfig, NodeViewConfig, } from './prosemirror-config';
|
|
30
30
|
export type { PluginsOptions, EditorPlugin, getPosHandler, getPosHandlerNode, } from './editor-plugin';
|
|
31
|
-
export type { NextEditorPlugin, AllEditorPresetPluginTypes, PluginDependenciesAPI, ExtractPluginNameFromAllBuilderPlugins, SafePresetCheck, DefaultEditorPlugin, OptionalPlugin, PluginInjectionAPI, CreatePluginDependenciesAPI, NextEditorPluginMetadata, ExtractInjectionAPI, ExtractPluginActions,
|
|
31
|
+
export type { NextEditorPlugin, AllEditorPresetPluginTypes, PluginDependenciesAPI, ExtractPluginNameFromAllBuilderPlugins, SafePresetCheck, DefaultEditorPlugin, OptionalPlugin, PluginInjectionAPI, CreatePluginDependenciesAPI, NextEditorPluginMetadata, ExtractInjectionAPI, ExtractPluginActions, PluginInjectionAPIWithDependencies, PublicPluginAPI, NextEditorPluginFunctionOptionalConfigDefinition, ExtractNextEditorPlugins, } from './next-editor-plugin';
|
|
32
32
|
export type { ExtractPublicEditorAPI } from './editor-public-api';
|
|
33
33
|
export type { EditorCommand, EditorCommandWithMetadata, } from './editor-command';
|
|
34
34
|
export type IconProps = {
|
|
@@ -46,7 +46,6 @@ export type PluginInjectionAPI<Name extends string, Metadata extends NextEditorP
|
|
|
46
46
|
...ExtractPluginDependenciesFromMetadata<Metadata>
|
|
47
47
|
]>;
|
|
48
48
|
};
|
|
49
|
-
export type PluginInjectionAPIWithDependency<Plugin extends NextEditorPlugin<any, any>> = PublicPluginAPI<[Plugin]>;
|
|
50
49
|
export type PluginInjectionAPIWithDependencies<Plugins extends NextEditorPlugin<any, any>[]> = PublicPluginAPI<Plugins>;
|
|
51
50
|
export type NextEditorPluginFunctionOptionalConfigDefinition<Name extends string, Metadata extends NextEditorPluginMetadata, Configuration = undefined> = (props: {
|
|
52
51
|
config: Configuration;
|
|
@@ -17,5 +17,5 @@ export type OpenChangedEvent = {
|
|
|
17
17
|
isOpen: boolean;
|
|
18
18
|
event: MouseEvent | KeyboardEvent;
|
|
19
19
|
};
|
|
20
|
-
declare const _default: import("react").ForwardRefExoticComponent<Pick<Omit<Props, keyof WithAnalyticsEventsProps> & import("react").RefAttributes<any> & import("@atlaskit/analytics-next").WithContextProps, "
|
|
20
|
+
declare const _default: import("react").ForwardRefExoticComponent<Pick<Omit<Props, keyof WithAnalyticsEventsProps> & import("react").RefAttributes<any> & import("@atlaskit/analytics-next").WithContextProps, "position" | "key" | "id" | "children" | "testId" | "analyticsContext" | "shouldFitContainer" | "onPositioned" | "isOpen" | "trigger" | "onOpenChange"> & import("react").RefAttributes<any>>;
|
|
21
21
|
export default _default;
|
|
@@ -16,7 +16,7 @@ export interface OverflowShadowOptions {
|
|
|
16
16
|
overflowSelector: string;
|
|
17
17
|
useShadowObserver?: boolean;
|
|
18
18
|
}
|
|
19
|
-
export default function overflowShadow<P>(Component: React.ComponentType<P & OverflowShadowProps> | React.
|
|
19
|
+
export default function overflowShadow<P>(Component: React.ComponentType<P & OverflowShadowProps> | React.FunctionComponent<P & OverflowShadowProps>, options: OverflowShadowOptions): {
|
|
20
20
|
new (props: P | Readonly<P>): {
|
|
21
21
|
overflowContainer?: HTMLElement | null | undefined;
|
|
22
22
|
container?: HTMLElement | undefined;
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { ComponentClass,
|
|
1
|
+
import type { ComponentClass, FunctionComponent } from 'react';
|
|
2
2
|
type SimpleEventHandler<T> = (event: T) => void;
|
|
3
3
|
export interface WithOutsideClickProps {
|
|
4
4
|
handleClickOutside?: SimpleEventHandler<MouseEvent>;
|
|
5
5
|
handleEscapeKeydown?: SimpleEventHandler<KeyboardEvent>;
|
|
6
6
|
}
|
|
7
|
-
export default function withOuterListeners<P>(Component: ComponentClass<P> |
|
|
7
|
+
export default function withOuterListeners<P>(Component: ComponentClass<P> | FunctionComponent<P>): ComponentClass<P & WithOutsideClickProps>;
|
|
8
8
|
export {};
|
|
@@ -26,5 +26,5 @@ type Props = WithAnalyticsEventsProps & {
|
|
|
26
26
|
skipFocusButtonAfterPick?: boolean;
|
|
27
27
|
absoluteOffset?: PopupPosition;
|
|
28
28
|
};
|
|
29
|
-
declare const _default: React.ForwardRefExoticComponent<Pick<Omit<Props, keyof WithAnalyticsEventsProps> & React.RefAttributes<any> & import("@atlaskit/analytics-next").WithContextProps, "
|
|
29
|
+
declare const _default: React.ForwardRefExoticComponent<Pick<Omit<Props, keyof WithAnalyticsEventsProps> & React.RefAttributes<any> & import("@atlaskit/analytics-next").WithContextProps, "size" | "currentColor" | "onChange" | "title" | "key" | "placement" | "alignX" | "absoluteOffset" | "analyticsContext" | "cols" | "hexToPaletteColor" | "paletteColorTooltipMessages" | "colorPalette" | "mountPoint" | "setDisableParentScroll" | "skipFocusButtonAfterPick"> & React.RefAttributes<any>>;
|
|
30
30
|
export default _default;
|
|
@@ -42,7 +42,7 @@ declare const ToolbarButton: React.ForwardRefExoticComponent<{
|
|
|
42
42
|
onItemClick?: ((item: MenuItem) => void) | undefined;
|
|
43
43
|
onKeyDown?: ((event: React.KeyboardEvent<HTMLElement>) => void) | undefined;
|
|
44
44
|
selected?: boolean | undefined;
|
|
45
|
-
spacing?: "
|
|
45
|
+
spacing?: "none" | "default" | "compact" | undefined;
|
|
46
46
|
target?: string | undefined;
|
|
47
47
|
title?: React.ReactNode;
|
|
48
48
|
titlePosition?: PositionType | undefined;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { ComponentClass,
|
|
1
|
+
import type { ComponentClass, FunctionComponent } from 'react';
|
|
2
2
|
import React from 'react';
|
|
3
3
|
type SimpleEventHandler<T> = (event: T) => void;
|
|
4
4
|
export interface WithOutsideClickProps {
|
|
@@ -8,5 +8,5 @@ export interface WithOutsideClickProps {
|
|
|
8
8
|
targetRef?: any;
|
|
9
9
|
closeOnTab?: boolean;
|
|
10
10
|
}
|
|
11
|
-
export default function withReactEditorViewOuterListeners<P extends {}>(Component: ComponentClass<P> |
|
|
11
|
+
export default function withReactEditorViewOuterListeners<P extends {}>(Component: ComponentClass<P> | FunctionComponent<P>): React.FC<P & WithOutsideClickProps>;
|
|
12
12
|
export {};
|
|
@@ -376,4 +376,11 @@ export interface CollabAnalyticsProps {
|
|
|
376
376
|
export interface CollabEventLocalStepData {
|
|
377
377
|
steps: Array<Step>;
|
|
378
378
|
}
|
|
379
|
+
export interface Color {
|
|
380
|
+
solid: string;
|
|
381
|
+
selection: string;
|
|
382
|
+
}
|
|
383
|
+
export declare const colors: Color[];
|
|
384
|
+
export declare const TELEPOINTER_DIM_CLASS = "telepointer-dim";
|
|
385
|
+
export declare const telepointerStyle: import("@emotion/react").SerializedStyles;
|
|
379
386
|
export {};
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import type { Node as PMNode } from '@atlaskit/editor-prosemirror/model';
|
|
2
|
+
import type { SimplifiedNode } from '../analytics';
|
|
3
|
+
export type { SimplifiedNode };
|
|
4
|
+
export declare const getDocStructure: (doc: PMNode, options?: {
|
|
5
|
+
compact?: boolean;
|
|
6
|
+
}) => SimplifiedNode | string;
|
|
@@ -0,0 +1,108 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import type { Node as PmNode } from '@atlaskit/editor-prosemirror/model';
|
|
3
|
+
import type { EditorView } from '@atlaskit/editor-prosemirror/view';
|
|
4
|
+
import type { ExtensionProvider, ReferenceEntity } from '../../../extensions';
|
|
5
|
+
import type { ProsemirrorGetPosHandler } from '../../../react-node-view';
|
|
6
|
+
import type { EditorAppearance } from '../../../types';
|
|
7
|
+
import type { ExtensionsPluginInjectionAPI } from '../../types';
|
|
8
|
+
export interface Props {
|
|
9
|
+
node: PmNode;
|
|
10
|
+
getPos: ProsemirrorGetPosHandler;
|
|
11
|
+
view: EditorView;
|
|
12
|
+
extensionProvider?: ExtensionProvider;
|
|
13
|
+
handleContentDOMRef: (node: HTMLElement | null) => void;
|
|
14
|
+
children?: React.ReactNode;
|
|
15
|
+
references?: ReferenceEntity[];
|
|
16
|
+
hideFrame?: boolean;
|
|
17
|
+
editorAppearance?: EditorAppearance;
|
|
18
|
+
pluginInjectionApi: ExtensionsPluginInjectionAPI;
|
|
19
|
+
}
|
|
20
|
+
/**
|
|
21
|
+
* End workaround
|
|
22
|
+
*/
|
|
23
|
+
declare const _default: {
|
|
24
|
+
new (props: Props | Readonly<Props>): {
|
|
25
|
+
overflowContainer?: HTMLElement | null | undefined;
|
|
26
|
+
container?: HTMLElement | undefined;
|
|
27
|
+
shadowObserver?: import("../../../ui").ShadowObserver | undefined;
|
|
28
|
+
overflowContainerWidth: number;
|
|
29
|
+
scrollable?: NodeList | undefined;
|
|
30
|
+
diff?: number | undefined;
|
|
31
|
+
state: {
|
|
32
|
+
showLeftShadow: boolean;
|
|
33
|
+
showRightShadow: boolean;
|
|
34
|
+
};
|
|
35
|
+
componentWillUnmount(): void;
|
|
36
|
+
componentDidUpdate(): void;
|
|
37
|
+
handleScroll: (event: Event) => void;
|
|
38
|
+
updateShadows: () => void;
|
|
39
|
+
showLeftShadow: (overflowContainer: HTMLElement | null | undefined) => boolean;
|
|
40
|
+
calcOverflowDiff: () => number;
|
|
41
|
+
calcScrollableWidth: () => number;
|
|
42
|
+
handleContainer: (container: HTMLElement | null) => void;
|
|
43
|
+
initShadowObserver(): void;
|
|
44
|
+
render(): JSX.Element;
|
|
45
|
+
context: any;
|
|
46
|
+
setState<K extends keyof import("../../../ui").OverflowShadowState>(state: import("../../../ui").OverflowShadowState | ((prevState: Readonly<import("../../../ui").OverflowShadowState>, props: Readonly<Props>) => import("../../../ui").OverflowShadowState | Pick<import("../../../ui").OverflowShadowState, K> | null) | Pick<import("../../../ui").OverflowShadowState, K> | null, callback?: (() => void) | undefined): void;
|
|
47
|
+
forceUpdate(callback?: (() => void) | undefined): void;
|
|
48
|
+
readonly props: Readonly<Props> & Readonly<{
|
|
49
|
+
children?: React.ReactNode;
|
|
50
|
+
}>;
|
|
51
|
+
refs: {
|
|
52
|
+
[key: string]: React.ReactInstance;
|
|
53
|
+
};
|
|
54
|
+
componentDidMount?(): void;
|
|
55
|
+
shouldComponentUpdate?(nextProps: Readonly<Props>, nextState: Readonly<import("../../../ui").OverflowShadowState>, nextContext: any): boolean;
|
|
56
|
+
componentDidCatch?(error: Error, errorInfo: React.ErrorInfo): void;
|
|
57
|
+
getSnapshotBeforeUpdate?(prevProps: Readonly<Props>, prevState: Readonly<import("../../../ui").OverflowShadowState>): any;
|
|
58
|
+
componentWillMount?(): void;
|
|
59
|
+
UNSAFE_componentWillMount?(): void;
|
|
60
|
+
componentWillReceiveProps?(nextProps: Readonly<Props>, nextContext: any): void;
|
|
61
|
+
UNSAFE_componentWillReceiveProps?(nextProps: Readonly<Props>, nextContext: any): void;
|
|
62
|
+
componentWillUpdate?(nextProps: Readonly<Props>, nextState: Readonly<import("../../../ui").OverflowShadowState>, nextContext: any): void;
|
|
63
|
+
UNSAFE_componentWillUpdate?(nextProps: Readonly<Props>, nextState: Readonly<import("../../../ui").OverflowShadowState>, nextContext: any): void;
|
|
64
|
+
};
|
|
65
|
+
new (props: Props, context: any): {
|
|
66
|
+
overflowContainer?: HTMLElement | null | undefined;
|
|
67
|
+
container?: HTMLElement | undefined;
|
|
68
|
+
shadowObserver?: import("../../../ui").ShadowObserver | undefined;
|
|
69
|
+
overflowContainerWidth: number;
|
|
70
|
+
scrollable?: NodeList | undefined;
|
|
71
|
+
diff?: number | undefined;
|
|
72
|
+
state: {
|
|
73
|
+
showLeftShadow: boolean;
|
|
74
|
+
showRightShadow: boolean;
|
|
75
|
+
};
|
|
76
|
+
componentWillUnmount(): void;
|
|
77
|
+
componentDidUpdate(): void;
|
|
78
|
+
handleScroll: (event: Event) => void;
|
|
79
|
+
updateShadows: () => void;
|
|
80
|
+
showLeftShadow: (overflowContainer: HTMLElement | null | undefined) => boolean;
|
|
81
|
+
calcOverflowDiff: () => number;
|
|
82
|
+
calcScrollableWidth: () => number;
|
|
83
|
+
handleContainer: (container: HTMLElement | null) => void;
|
|
84
|
+
initShadowObserver(): void;
|
|
85
|
+
render(): JSX.Element;
|
|
86
|
+
context: any;
|
|
87
|
+
setState<K extends keyof import("../../../ui").OverflowShadowState>(state: import("../../../ui").OverflowShadowState | ((prevState: Readonly<import("../../../ui").OverflowShadowState>, props: Readonly<Props>) => import("../../../ui").OverflowShadowState | Pick<import("../../../ui").OverflowShadowState, K> | null) | Pick<import("../../../ui").OverflowShadowState, K> | null, callback?: (() => void) | undefined): void;
|
|
88
|
+
forceUpdate(callback?: (() => void) | undefined): void;
|
|
89
|
+
readonly props: Readonly<Props> & Readonly<{
|
|
90
|
+
children?: React.ReactNode;
|
|
91
|
+
}>;
|
|
92
|
+
refs: {
|
|
93
|
+
[key: string]: React.ReactInstance;
|
|
94
|
+
};
|
|
95
|
+
componentDidMount?(): void;
|
|
96
|
+
shouldComponentUpdate?(nextProps: Readonly<Props>, nextState: Readonly<import("../../../ui").OverflowShadowState>, nextContext: any): boolean;
|
|
97
|
+
componentDidCatch?(error: Error, errorInfo: React.ErrorInfo): void;
|
|
98
|
+
getSnapshotBeforeUpdate?(prevProps: Readonly<Props>, prevState: Readonly<import("../../../ui").OverflowShadowState>): any;
|
|
99
|
+
componentWillMount?(): void;
|
|
100
|
+
UNSAFE_componentWillMount?(): void;
|
|
101
|
+
componentWillReceiveProps?(nextProps: Readonly<Props>, nextContext: any): void;
|
|
102
|
+
UNSAFE_componentWillReceiveProps?(nextProps: Readonly<Props>, nextContext: any): void;
|
|
103
|
+
componentWillUpdate?(nextProps: Readonly<Props>, nextState: Readonly<import("../../../ui").OverflowShadowState>, nextContext: any): void;
|
|
104
|
+
UNSAFE_componentWillUpdate?(nextProps: Readonly<Props>, nextState: Readonly<import("../../../ui").OverflowShadowState>, nextContext: any): void;
|
|
105
|
+
};
|
|
106
|
+
contextType?: React.Context<any> | undefined;
|
|
107
|
+
};
|
|
108
|
+
export default _default;
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
export declare const widerLayoutClassName = "wider-layout";
|
|
2
|
+
export declare const wrapperStyle: import("@emotion/react").SerializedStyles;
|
|
3
|
+
export declare const header: import("@emotion/react").SerializedStyles;
|
|
4
|
+
export declare const content: import("@emotion/react").SerializedStyles;
|
|
5
|
+
export declare const contentWrapper: import("@emotion/react").SerializedStyles;
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
/** @jsx jsx */
|
|
2
|
+
import React from 'react';
|
|
3
|
+
import { Component } from 'react';
|
|
4
|
+
import { jsx } from '@emotion/react';
|
|
5
|
+
import type { Node as PmNode } from '@atlaskit/editor-prosemirror/model';
|
|
6
|
+
export interface Props {
|
|
7
|
+
node: PmNode;
|
|
8
|
+
children?: React.ReactNode;
|
|
9
|
+
}
|
|
10
|
+
export default class InlineExtension extends Component<Props, any> {
|
|
11
|
+
render(): jsx.JSX.Element;
|
|
12
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const wrapperStyle: import("@emotion/react").SerializedStyles;
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
/** @jsx jsx */
|
|
2
|
+
import { Component } from 'react';
|
|
3
|
+
import { jsx } from '@emotion/react';
|
|
4
|
+
import type { Node as PmNode } from '@atlaskit/editor-prosemirror/model';
|
|
5
|
+
export declare const capitalizeFirstLetter: (str: string) => string;
|
|
6
|
+
export interface Props {
|
|
7
|
+
node: PmNode;
|
|
8
|
+
}
|
|
9
|
+
export declare const ICON_SIZE = 24;
|
|
10
|
+
export default class ExtensionLozenge extends Component<Props, any> {
|
|
11
|
+
render(): jsx.JSX.Element;
|
|
12
|
+
private renderImage;
|
|
13
|
+
private renderFallback;
|
|
14
|
+
}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { BODIED_EXT_PADDING, EXTENSION_PADDING } from '../../styles';
|
|
2
|
+
export { EXTENSION_PADDING as padding, BODIED_EXT_PADDING };
|
|
3
|
+
export declare const wrapperDefault: import("@emotion/react").SerializedStyles;
|
|
4
|
+
export declare const overlay: import("@emotion/react").SerializedStyles;
|
|
5
|
+
export declare const placeholderFallback: import("@emotion/react").SerializedStyles;
|
|
6
|
+
export declare const placeholderFallbackParams: import("@emotion/react").SerializedStyles;
|
|
7
|
+
export declare const styledImage: import("@emotion/react").SerializedStyles;
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import { Component } from 'react';
|
|
2
|
+
import type { Node as PMNode } from '@atlaskit/editor-prosemirror/model';
|
|
3
|
+
import type { EditorView } from '@atlaskit/editor-prosemirror/view';
|
|
4
|
+
import type { EventDispatcher } from '../event-dispatcher';
|
|
5
|
+
import type { ExtensionHandlers, ReferenceEntity } from '../extensions';
|
|
6
|
+
import { ProviderFactory } from '../provider-factory';
|
|
7
|
+
import type { ProsemirrorGetPosHandler } from '../react-node-view';
|
|
8
|
+
import type { EditorAppearance } from '../types';
|
|
9
|
+
import type { ExtensionsPluginInjectionAPI } from './types';
|
|
10
|
+
export interface Props {
|
|
11
|
+
editorView: EditorView;
|
|
12
|
+
node: PMNode;
|
|
13
|
+
getPos: ProsemirrorGetPosHandler;
|
|
14
|
+
providerFactory?: ProviderFactory;
|
|
15
|
+
handleContentDOMRef: (node: HTMLElement | null) => void;
|
|
16
|
+
extensionHandlers: ExtensionHandlers;
|
|
17
|
+
references?: ReferenceEntity[];
|
|
18
|
+
editorAppearance?: EditorAppearance;
|
|
19
|
+
pluginInjectionApi: ExtensionsPluginInjectionAPI;
|
|
20
|
+
eventDispatcher?: EventDispatcher;
|
|
21
|
+
}
|
|
22
|
+
export declare class Extension extends Component<Props, any> {
|
|
23
|
+
static displayName: string;
|
|
24
|
+
private providerFactory;
|
|
25
|
+
constructor(props: Props);
|
|
26
|
+
componentWillUnmount(): void;
|
|
27
|
+
private renderWithProvider;
|
|
28
|
+
render(): JSX.Element;
|
|
29
|
+
}
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
import { Component } from 'react';
|
|
2
|
+
import type { Node as PMNode } from '@atlaskit/editor-prosemirror/model';
|
|
3
|
+
import type { EditorView } from '@atlaskit/editor-prosemirror/view';
|
|
4
|
+
import type { EventDispatcher } from '../event-dispatcher';
|
|
5
|
+
import { getExtensionModuleNodePrivateProps, getNodeRenderer } from '../extensions';
|
|
6
|
+
import type { ExtensionHandlers, ExtensionProvider, ReferenceEntity } from '../extensions';
|
|
7
|
+
import type { ProsemirrorGetPosHandler } from '../react-node-view';
|
|
8
|
+
import type { EditorAppearance } from '../types';
|
|
9
|
+
import type { ExtensionsPluginInjectionAPI } from './types';
|
|
10
|
+
export interface Props {
|
|
11
|
+
editorView: EditorView;
|
|
12
|
+
node: PMNode;
|
|
13
|
+
getPos: ProsemirrorGetPosHandler;
|
|
14
|
+
handleContentDOMRef: (node: HTMLElement | null) => void;
|
|
15
|
+
extensionHandlers: ExtensionHandlers;
|
|
16
|
+
extensionProvider?: Promise<ExtensionProvider>;
|
|
17
|
+
references?: ReferenceEntity[];
|
|
18
|
+
editorAppearance?: EditorAppearance;
|
|
19
|
+
pluginInjectionApi: ExtensionsPluginInjectionAPI;
|
|
20
|
+
eventDispatcher?: EventDispatcher;
|
|
21
|
+
}
|
|
22
|
+
export interface State {
|
|
23
|
+
extensionProvider?: ExtensionProvider;
|
|
24
|
+
extensionHandlersFromProvider?: ExtensionHandlers;
|
|
25
|
+
_privateProps?: {
|
|
26
|
+
__hideFrame?: boolean;
|
|
27
|
+
};
|
|
28
|
+
activeChildIndex?: number;
|
|
29
|
+
}
|
|
30
|
+
export declare class ExtensionComponent extends Component<Props, State> {
|
|
31
|
+
private privatePropsParsed;
|
|
32
|
+
state: State;
|
|
33
|
+
mounted: boolean;
|
|
34
|
+
UNSAFE_componentWillMount(): void;
|
|
35
|
+
componentDidMount(): void;
|
|
36
|
+
componentDidUpdate(): void;
|
|
37
|
+
componentWillUnmount(): void;
|
|
38
|
+
UNSAFE_componentWillReceiveProps(nextProps: Props): void;
|
|
39
|
+
getNodeRenderer: import("memoize-one").MemoizedFn<typeof getNodeRenderer>;
|
|
40
|
+
getExtensionModuleNodePrivateProps: import("memoize-one").MemoizedFn<typeof getExtensionModuleNodePrivateProps>;
|
|
41
|
+
render(): JSX.Element | null;
|
|
42
|
+
private setStateFromPromise;
|
|
43
|
+
/**
|
|
44
|
+
* Parses any private nodes once an extension provider is available.
|
|
45
|
+
*
|
|
46
|
+
* We do this separately from resolving a node renderer component since the
|
|
47
|
+
* private props come from extension provider, rather than an extension
|
|
48
|
+
* handler which only handles `render`/component concerns.
|
|
49
|
+
*/
|
|
50
|
+
private parsePrivateNodePropsIfNeeded;
|
|
51
|
+
private tryExtensionHandler;
|
|
52
|
+
private handleExtension;
|
|
53
|
+
}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
type Props = {
|
|
3
|
+
children: React.ReactNode;
|
|
4
|
+
nodeType: string;
|
|
5
|
+
};
|
|
6
|
+
/**
|
|
7
|
+
* If inlineExtension, add zero width space to the end of the nodes and wrap with span;
|
|
8
|
+
* else wrap with a div (for multi bodied extensions)
|
|
9
|
+
*
|
|
10
|
+
* @param param0
|
|
11
|
+
* @returns
|
|
12
|
+
*/
|
|
13
|
+
export declare const ExtensionNodeWrapper: ({ children, nodeType }: Props) => JSX.Element;
|
|
14
|
+
export {};
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
/** @jsx jsx */
|
|
2
|
+
import React from 'react';
|
|
3
|
+
import { jsx } from '@emotion/react';
|
|
4
|
+
import type { Node as PmNode } from '@atlaskit/editor-prosemirror/model';
|
|
5
|
+
import type { EditorView } from '@atlaskit/editor-prosemirror/view';
|
|
6
|
+
import type { EventDispatcher } from '../../event-dispatcher';
|
|
7
|
+
import type { MultiBodiedExtensionActions } from '../../extensions';
|
|
8
|
+
import type { EditorAppearance } from '../../types';
|
|
9
|
+
import type { OverflowShadowProps } from '../../ui';
|
|
10
|
+
import type { ExtensionsPluginInjectionAPI } from '../types';
|
|
11
|
+
export type TryExtensionHandlerType = (actions: MultiBodiedExtensionActions | undefined) => React.ReactElement | null;
|
|
12
|
+
type Props = {
|
|
13
|
+
node: PmNode;
|
|
14
|
+
handleContentDOMRef: (node: HTMLElement | null) => void;
|
|
15
|
+
editorView: EditorView;
|
|
16
|
+
getPos: () => number | undefined;
|
|
17
|
+
tryExtensionHandler: TryExtensionHandlerType;
|
|
18
|
+
eventDispatcher?: EventDispatcher;
|
|
19
|
+
pluginInjectionApi?: ExtensionsPluginInjectionAPI;
|
|
20
|
+
editorAppearance?: EditorAppearance;
|
|
21
|
+
};
|
|
22
|
+
declare const MultiBodiedExtension: (props: Props & OverflowShadowProps) => jsx.JSX.Element;
|
|
23
|
+
/**
|
|
24
|
+
* End workaround
|
|
25
|
+
*/
|
|
26
|
+
export default MultiBodiedExtension;
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import type { Node as PmNode } from '@atlaskit/editor-prosemirror/model';
|
|
3
|
+
import type { EditorView, NodeView } from '@atlaskit/editor-prosemirror/view';
|
|
4
|
+
import type { EventDispatcher } from '../event-dispatcher';
|
|
5
|
+
import type { ExtensionHandlers } from '../extensions';
|
|
6
|
+
import type { ProviderFactory } from '../provider-factory';
|
|
7
|
+
import type { ForwardRef, getPosHandler } from '../react-node-view';
|
|
8
|
+
import ReactNodeView from '../react-node-view';
|
|
9
|
+
import type { EditorAppearance } from '../types';
|
|
10
|
+
import type { PortalProviderAPI } from '../ui/PortalProvider';
|
|
11
|
+
import type { ExtensionsPluginInjectionAPI } from './types';
|
|
12
|
+
interface ExtensionNodeViewOptions {
|
|
13
|
+
appearance?: EditorAppearance;
|
|
14
|
+
}
|
|
15
|
+
export declare class ExtensionNode extends ReactNodeView {
|
|
16
|
+
ignoreMutation(mutation: MutationRecord | {
|
|
17
|
+
type: 'selection';
|
|
18
|
+
target: Element;
|
|
19
|
+
}): boolean;
|
|
20
|
+
getContentDOM(): {
|
|
21
|
+
dom: HTMLDivElement;
|
|
22
|
+
} | undefined;
|
|
23
|
+
render(props: {
|
|
24
|
+
providerFactory: ProviderFactory;
|
|
25
|
+
extensionHandlers: ExtensionHandlers;
|
|
26
|
+
extensionNodeViewOptions?: ExtensionNodeViewOptions;
|
|
27
|
+
pluginInjectionApi: ExtensionsPluginInjectionAPI;
|
|
28
|
+
}, forwardRef: ForwardRef): JSX.Element;
|
|
29
|
+
}
|
|
30
|
+
export default function ExtensionNodeView(portalProviderAPI: PortalProviderAPI, eventDispatcher: EventDispatcher, providerFactory: ProviderFactory, extensionHandlers: ExtensionHandlers, extensionNodeViewOptions: ExtensionNodeViewOptions, pluginInjectionApi: ExtensionsPluginInjectionAPI): (node: PmNode, view: EditorView, getPos: getPosHandler) => NodeView;
|
|
31
|
+
export {};
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import type { EditorContainerWidth, NextEditorPlugin, PublicPluginAPI } from '../types';
|
|
2
|
+
type WidthPluginType = NextEditorPlugin<'width', {
|
|
3
|
+
sharedState: EditorContainerWidth | undefined;
|
|
4
|
+
}>;
|
|
5
|
+
export type ExtensionsPluginInjectionAPI = PublicPluginAPI<[
|
|
6
|
+
WidthPluginType
|
|
7
|
+
]> | undefined;
|
|
8
|
+
export {};
|
|
@@ -7,7 +7,9 @@
|
|
|
7
7
|
declare const _default: {
|
|
8
8
|
'fabric.editor.action': string;
|
|
9
9
|
'fabric.editor.action.description': string;
|
|
10
|
+
'fabric.editor.addColumn': string;
|
|
10
11
|
'fabric.editor.addMediaFiles': string;
|
|
12
|
+
'fabric.editor.addRow': string;
|
|
11
13
|
'fabric.editor.alignCenter': string;
|
|
12
14
|
'fabric.editor.alignImageCenter': string;
|
|
13
15
|
'fabric.editor.alignImageLeft': string;
|
|
@@ -15,6 +17,7 @@ declare const _default: {
|
|
|
15
17
|
'fabric.editor.alignLeft': string;
|
|
16
18
|
'fabric.editor.alignRight': string;
|
|
17
19
|
'fabric.editor.annotationToolbar': string;
|
|
20
|
+
'fabric.editor.backgroundColor': string;
|
|
18
21
|
'fabric.editor.blockCardUnavailable': string;
|
|
19
22
|
'fabric.editor.blockDescription': string;
|
|
20
23
|
'fabric.editor.blockTitle': string;
|
|
@@ -136,7 +139,6 @@ declare const _default: {
|
|
|
136
139
|
'fabric.editor.infoPanel': string;
|
|
137
140
|
'fabric.editor.infoPanel.description': string;
|
|
138
141
|
'fabric.editor.inlineDescription': string;
|
|
139
|
-
'fabric.editor.inlineOverlay': string;
|
|
140
142
|
'fabric.editor.inlineTitle': string;
|
|
141
143
|
'fabric.editor.insertColumn': string;
|
|
142
144
|
'fabric.editor.insertColumnDrag': string;
|
|
@@ -209,7 +211,8 @@ declare const _default: {
|
|
|
209
211
|
'fabric.editor.table': string;
|
|
210
212
|
'fabric.editor.table.description': string;
|
|
211
213
|
'fabric.editor.tableOptions': string;
|
|
212
|
-
'fabric.editor.
|
|
214
|
+
'fabric.editor.tableResizeDecreaseScreenReaderInformation': string;
|
|
215
|
+
'fabric.editor.tableResizeIncreaseScreenReaderInformation': string;
|
|
213
216
|
'fabric.editor.tables.adjustColumn': string;
|
|
214
217
|
'fabric.editor.tables.confirmDeleteLinkedModalMessage': string;
|
|
215
218
|
'fabric.editor.tables.confirmDeleteLinkedModalOKButton': string;
|
|
@@ -7,7 +7,9 @@
|
|
|
7
7
|
declare const _default: {
|
|
8
8
|
'fabric.editor.action': string;
|
|
9
9
|
'fabric.editor.action.description': string;
|
|
10
|
+
'fabric.editor.addColumn': string;
|
|
10
11
|
'fabric.editor.addMediaFiles': string;
|
|
12
|
+
'fabric.editor.addRow': string;
|
|
11
13
|
'fabric.editor.alignCenter': string;
|
|
12
14
|
'fabric.editor.alignImageCenter': string;
|
|
13
15
|
'fabric.editor.alignImageLeft': string;
|
|
@@ -15,6 +17,7 @@ declare const _default: {
|
|
|
15
17
|
'fabric.editor.alignLeft': string;
|
|
16
18
|
'fabric.editor.alignRight': string;
|
|
17
19
|
'fabric.editor.annotationToolbar': string;
|
|
20
|
+
'fabric.editor.backgroundColor': string;
|
|
18
21
|
'fabric.editor.blockCardUnavailable': string;
|
|
19
22
|
'fabric.editor.blockDescription': string;
|
|
20
23
|
'fabric.editor.blockTitle': string;
|
|
@@ -136,7 +139,6 @@ declare const _default: {
|
|
|
136
139
|
'fabric.editor.infoPanel': string;
|
|
137
140
|
'fabric.editor.infoPanel.description': string;
|
|
138
141
|
'fabric.editor.inlineDescription': string;
|
|
139
|
-
'fabric.editor.inlineOverlay': string;
|
|
140
142
|
'fabric.editor.inlineTitle': string;
|
|
141
143
|
'fabric.editor.insertColumn': string;
|
|
142
144
|
'fabric.editor.insertColumnDrag': string;
|
|
@@ -209,7 +211,8 @@ declare const _default: {
|
|
|
209
211
|
'fabric.editor.table': string;
|
|
210
212
|
'fabric.editor.table.description': string;
|
|
211
213
|
'fabric.editor.tableOptions': string;
|
|
212
|
-
'fabric.editor.
|
|
214
|
+
'fabric.editor.tableResizeDecreaseScreenReaderInformation': string;
|
|
215
|
+
'fabric.editor.tableResizeIncreaseScreenReaderInformation': string;
|
|
213
216
|
'fabric.editor.tables.adjustColumn': string;
|
|
214
217
|
'fabric.editor.tables.confirmDeleteLinkedModalMessage': string;
|
|
215
218
|
'fabric.editor.tables.confirmDeleteLinkedModalOKButton': string;
|
|
@@ -7,7 +7,9 @@
|
|
|
7
7
|
declare const _default: {
|
|
8
8
|
'fabric.editor.action': string;
|
|
9
9
|
'fabric.editor.action.description': string;
|
|
10
|
+
'fabric.editor.addColumn': string;
|
|
10
11
|
'fabric.editor.addMediaFiles': string;
|
|
12
|
+
'fabric.editor.addRow': string;
|
|
11
13
|
'fabric.editor.alignCenter': string;
|
|
12
14
|
'fabric.editor.alignImageCenter': string;
|
|
13
15
|
'fabric.editor.alignImageLeft': string;
|
|
@@ -15,6 +17,7 @@ declare const _default: {
|
|
|
15
17
|
'fabric.editor.alignLeft': string;
|
|
16
18
|
'fabric.editor.alignRight': string;
|
|
17
19
|
'fabric.editor.annotationToolbar': string;
|
|
20
|
+
'fabric.editor.backgroundColor': string;
|
|
18
21
|
'fabric.editor.blockCardUnavailable': string;
|
|
19
22
|
'fabric.editor.blockDescription': string;
|
|
20
23
|
'fabric.editor.blockTitle': string;
|
|
@@ -136,7 +139,6 @@ declare const _default: {
|
|
|
136
139
|
'fabric.editor.infoPanel': string;
|
|
137
140
|
'fabric.editor.infoPanel.description': string;
|
|
138
141
|
'fabric.editor.inlineDescription': string;
|
|
139
|
-
'fabric.editor.inlineOverlay': string;
|
|
140
142
|
'fabric.editor.inlineTitle': string;
|
|
141
143
|
'fabric.editor.insertColumn': string;
|
|
142
144
|
'fabric.editor.insertColumnDrag': string;
|
|
@@ -209,7 +211,8 @@ declare const _default: {
|
|
|
209
211
|
'fabric.editor.table': string;
|
|
210
212
|
'fabric.editor.table.description': string;
|
|
211
213
|
'fabric.editor.tableOptions': string;
|
|
212
|
-
'fabric.editor.
|
|
214
|
+
'fabric.editor.tableResizeDecreaseScreenReaderInformation': string;
|
|
215
|
+
'fabric.editor.tableResizeIncreaseScreenReaderInformation': string;
|
|
213
216
|
'fabric.editor.tables.adjustColumn': string;
|
|
214
217
|
'fabric.editor.tables.confirmDeleteLinkedModalMessage': string;
|
|
215
218
|
'fabric.editor.tables.confirmDeleteLinkedModalOKButton': string;
|