@atlaskit/editor-core 188.7.6 → 188.9.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 +23 -0
- package/dist/cjs/composable-editor/editor-internal.js +2 -2
- package/dist/cjs/create-editor/ReactEditorView.js +796 -8
- package/dist/cjs/labs/next/presets/universal.js +7 -4
- package/dist/cjs/plugins/index.js +0 -21
- package/dist/cjs/plugins/type-ahead/index.js +4 -372
- package/dist/cjs/plugins/type-ahead/plugin.js +382 -0
- package/dist/cjs/plugins/view-update-subscription/subscribe/toolbarAndPickerUpdates.js +17 -8
- package/dist/cjs/version-wrapper.js +1 -1
- package/dist/es2019/composable-editor/editor-internal.js +1 -1
- package/dist/es2019/create-editor/ReactEditorView.js +753 -2
- package/dist/es2019/labs/next/presets/universal.js +4 -1
- package/dist/es2019/plugins/index.js +0 -3
- package/dist/es2019/plugins/type-ahead/index.js +2 -375
- package/dist/es2019/plugins/type-ahead/plugin.js +381 -0
- package/dist/es2019/plugins/view-update-subscription/subscribe/toolbarAndPickerUpdates.js +17 -8
- package/dist/es2019/version-wrapper.js +1 -1
- package/dist/esm/composable-editor/editor-internal.js +1 -1
- package/dist/esm/create-editor/ReactEditorView.js +797 -8
- package/dist/esm/labs/next/presets/universal.js +4 -1
- package/dist/esm/plugins/index.js +0 -3
- package/dist/esm/plugins/type-ahead/index.js +2 -368
- package/dist/esm/plugins/type-ahead/plugin.js +374 -0
- package/dist/esm/plugins/view-update-subscription/subscribe/toolbarAndPickerUpdates.js +17 -8
- package/dist/esm/version-wrapper.js +1 -1
- package/dist/types/create-editor/ReactEditorView.d.ts +119 -5
- package/dist/types/labs/next/presets/default.d.ts +30 -12
- package/dist/types/plugins/index.d.ts +0 -3
- package/dist/types/plugins/insert-block/types.d.ts +1 -1
- package/dist/types/plugins/type-ahead/index.d.ts +3 -14
- package/dist/types/plugins/type-ahead/plugin.d.ts +10 -0
- package/dist/types/plugins/type-ahead/types.d.ts +51 -6
- package/dist/types/plugins/view-update-subscription/subscribe/toolbarAndPickerUpdates.d.ts +1 -1
- package/dist/types-ts4.5/create-editor/ReactEditorView.d.ts +119 -5
- package/dist/types-ts4.5/labs/next/presets/default.d.ts +30 -12
- package/dist/types-ts4.5/plugins/index.d.ts +0 -3
- package/dist/types-ts4.5/plugins/insert-block/types.d.ts +1 -1
- package/dist/types-ts4.5/plugins/type-ahead/index.d.ts +3 -14
- package/dist/types-ts4.5/plugins/type-ahead/plugin.d.ts +10 -0
- package/dist/types-ts4.5/plugins/type-ahead/types.d.ts +53 -6
- package/dist/types-ts4.5/plugins/view-update-subscription/subscribe/toolbarAndPickerUpdates.d.ts +1 -1
- package/package.json +6 -4
- package/dist/cjs/create-editor/ReactEditorViewInternal.js +0 -812
- package/dist/cjs/create-editor/ReactEditorViewNext.js +0 -15
- package/dist/cjs/plugins/save-on-enter/index.js +0 -70
- package/dist/cjs/plugins/scroll-into-view/index.js +0 -55
- package/dist/cjs/plugins/status/actions.js +0 -158
- package/dist/cjs/plugins/status/analytics.js +0 -31
- package/dist/cjs/plugins/status/index.js +0 -143
- package/dist/cjs/plugins/status/keymap.js +0 -22
- package/dist/cjs/plugins/status/nodeviews/status.js +0 -58
- package/dist/cjs/plugins/status/plugin-key.js +0 -9
- package/dist/cjs/plugins/status/plugin.js +0 -133
- package/dist/cjs/plugins/status/types.js +0 -5
- package/dist/cjs/plugins/status/ui/statusPicker.js +0 -314
- package/dist/cjs/plugins/status/utils.js +0 -22
- package/dist/cjs/plugins/view-update-subscription/subscribe/type-ahead-updates.js +0 -33
- package/dist/es2019/create-editor/ReactEditorViewInternal.js +0 -753
- package/dist/es2019/create-editor/ReactEditorViewNext.js +0 -7
- package/dist/es2019/plugins/save-on-enter/index.js +0 -63
- package/dist/es2019/plugins/scroll-into-view/index.js +0 -44
- package/dist/es2019/plugins/status/actions.js +0 -144
- package/dist/es2019/plugins/status/analytics.js +0 -18
- package/dist/es2019/plugins/status/index.js +0 -135
- package/dist/es2019/plugins/status/keymap.js +0 -13
- package/dist/es2019/plugins/status/nodeviews/status.js +0 -60
- package/dist/es2019/plugins/status/plugin-key.js +0 -3
- package/dist/es2019/plugins/status/plugin.js +0 -113
- package/dist/es2019/plugins/status/types.js +0 -1
- package/dist/es2019/plugins/status/ui/statusPicker.js +0 -293
- package/dist/es2019/plugins/status/utils.js +0 -12
- package/dist/es2019/plugins/view-update-subscription/subscribe/type-ahead-updates.js +0 -28
- package/dist/esm/create-editor/ReactEditorViewInternal.js +0 -806
- package/dist/esm/create-editor/ReactEditorViewNext.js +0 -7
- package/dist/esm/plugins/save-on-enter/index.js +0 -63
- package/dist/esm/plugins/scroll-into-view/index.js +0 -50
- package/dist/esm/plugins/status/actions.js +0 -151
- package/dist/esm/plugins/status/analytics.js +0 -24
- package/dist/esm/plugins/status/index.js +0 -136
- package/dist/esm/plugins/status/keymap.js +0 -15
- package/dist/esm/plugins/status/nodeviews/status.js +0 -51
- package/dist/esm/plugins/status/plugin-key.js +0 -3
- package/dist/esm/plugins/status/plugin.js +0 -115
- package/dist/esm/plugins/status/types.js +0 -1
- package/dist/esm/plugins/status/ui/statusPicker.js +0 -308
- package/dist/esm/plugins/status/utils.js +0 -16
- package/dist/esm/plugins/view-update-subscription/subscribe/type-ahead-updates.js +0 -27
- package/dist/types/create-editor/ReactEditorViewInternal.d.ts +0 -119
- package/dist/types/create-editor/ReactEditorViewNext.d.ts +0 -8
- package/dist/types/plugins/save-on-enter/index.d.ts +0 -10
- package/dist/types/plugins/scroll-into-view/index.d.ts +0 -14
- package/dist/types/plugins/status/actions.d.ts +0 -16
- package/dist/types/plugins/status/analytics.d.ts +0 -4
- package/dist/types/plugins/status/index.d.ts +0 -15
- package/dist/types/plugins/status/keymap.d.ts +0 -3
- package/dist/types/plugins/status/nodeviews/status.d.ts +0 -25
- package/dist/types/plugins/status/plugin-key.d.ts +0 -4
- package/dist/types/plugins/status/plugin.d.ts +0 -7
- package/dist/types/plugins/status/types.d.ts +0 -18
- package/dist/types/plugins/status/ui/statusPicker.d.ts +0 -63
- package/dist/types/plugins/status/utils.d.ts +0 -5
- package/dist/types/plugins/view-update-subscription/subscribe/type-ahead-updates.d.ts +0 -9
- package/dist/types-ts4.5/create-editor/ReactEditorViewInternal.d.ts +0 -119
- package/dist/types-ts4.5/create-editor/ReactEditorViewNext.d.ts +0 -8
- package/dist/types-ts4.5/plugins/save-on-enter/index.d.ts +0 -10
- package/dist/types-ts4.5/plugins/scroll-into-view/index.d.ts +0 -14
- package/dist/types-ts4.5/plugins/status/actions.d.ts +0 -16
- package/dist/types-ts4.5/plugins/status/analytics.d.ts +0 -4
- package/dist/types-ts4.5/plugins/status/index.d.ts +0 -17
- package/dist/types-ts4.5/plugins/status/keymap.d.ts +0 -3
- package/dist/types-ts4.5/plugins/status/nodeviews/status.d.ts +0 -25
- package/dist/types-ts4.5/plugins/status/plugin-key.d.ts +0 -4
- package/dist/types-ts4.5/plugins/status/plugin.d.ts +0 -7
- package/dist/types-ts4.5/plugins/status/types.d.ts +0 -18
- package/dist/types-ts4.5/plugins/status/ui/statusPicker.d.ts +0 -63
- package/dist/types-ts4.5/plugins/status/utils.d.ts +0 -5
- package/dist/types-ts4.5/plugins/view-update-subscription/subscribe/type-ahead-updates.d.ts +0 -9
|
@@ -1,15 +1,4 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import type { TypeAheadPluginOptions, TypeAheadPlugin } from '@atlaskit/editor-plugin-type-ahead';
|
|
3
|
-
export type { TypeAheadPluginOptions, TypeAheadPlugin };
|
|
4
|
-
/**
|
|
5
|
-
*
|
|
6
|
-
* Revamped typeahead using decorations instead of the `typeAheadQuery` mark
|
|
7
|
-
*
|
|
8
|
-
* https://product-fabric.atlassian.net/wiki/spaces/E/pages/2992177582/Technical+TypeAhead+Data+Flow
|
|
9
|
-
*
|
|
10
|
-
*
|
|
11
|
-
*/
|
|
12
|
-
declare const typeAheadPlugin: TypeAheadPlugin;
|
|
1
|
+
import { typeAheadPlugin } from './plugin';
|
|
13
2
|
export default typeAheadPlugin;
|
|
14
|
-
export {
|
|
15
|
-
export type { TypeAheadHandler, TypeAheadPluginState } from './types';
|
|
3
|
+
export { typeAheadPlugin };
|
|
4
|
+
export type { TypeAheadHandler, TypeAheadInputMethod, TypeAheadPlugin, TypeAheadPluginOptions, TypeAheadPluginState, } from './types';
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import type { TypeAheadPlugin } from './types';
|
|
2
|
+
/**
|
|
3
|
+
*
|
|
4
|
+
* Revamped typeahead using decorations instead of the `typeAheadQuery` mark
|
|
5
|
+
*
|
|
6
|
+
* https://product-fabric.atlassian.net/wiki/spaces/E/pages/2992177582/Technical+TypeAhead+Data+Flow
|
|
7
|
+
*
|
|
8
|
+
*
|
|
9
|
+
*/
|
|
10
|
+
export declare const typeAheadPlugin: TypeAheadPlugin;
|
|
@@ -1,11 +1,12 @@
|
|
|
1
|
+
import type { CreateUIAnalyticsEvent } from '@atlaskit/analytics-next';
|
|
2
|
+
import type { INPUT_METHOD } from '@atlaskit/editor-common/analytics';
|
|
3
|
+
import type { SelectItemMode } from '@atlaskit/editor-common/type-ahead';
|
|
4
|
+
import type { Command, NextEditorPlugin, OptionalPlugin, TypeAheadForceSelect, TypeAheadHandler, TypeAheadInsert, TypeAheadItem, TypeAheadItemRenderProps, TypeAheadSelectItem, TypeAheadStats, UiComponentFactoryParams } from '@atlaskit/editor-common/types';
|
|
5
|
+
import type { AnalyticsPlugin } from '@atlaskit/editor-plugin-analytics';
|
|
6
|
+
import type { EditorState, ReadonlyTransaction, Transaction } from '@atlaskit/editor-prosemirror/state';
|
|
1
7
|
import type { DecorationSet } from '@atlaskit/editor-prosemirror/view';
|
|
2
|
-
import type { EditorState, Transaction, ReadonlyTransaction } from '@atlaskit/editor-prosemirror/state';
|
|
3
8
|
import type { CloseSelectionOptions } from './constants';
|
|
4
|
-
|
|
5
|
-
import type { SelectItemMode } from '@atlaskit/editor-common/type-ahead';
|
|
6
|
-
import type { TypeAheadStats, TypeAheadItemRenderProps, TypeAheadInsert, TypeAheadSelectItem, TypeAheadItem, TypeAheadForceSelect, TypeAheadHandler } from '@atlaskit/editor-common/types';
|
|
7
|
-
import type { TypeAheadInputMethod } from '@atlaskit/editor-plugin-type-ahead';
|
|
8
|
-
export type { TypeAheadStats, TypeAheadItemRenderProps, TypeAheadInsert, TypeAheadSelectItem, TypeAheadItem, TypeAheadForceSelect, TypeAheadHandler, TypeAheadInputMethod, };
|
|
9
|
+
export type { TypeAheadStats, TypeAheadItemRenderProps, TypeAheadInsert, TypeAheadSelectItem, TypeAheadItem, TypeAheadForceSelect, TypeAheadHandler, };
|
|
9
10
|
export type OnSelectItem = (props: {
|
|
10
11
|
index: number;
|
|
11
12
|
item: TypeAheadItem;
|
|
@@ -62,3 +63,49 @@ export type CreateTypeAheadDecorations = (tr: ReadonlyTransaction, options: {
|
|
|
62
63
|
stats: TypeAheadStatsSerializable | null;
|
|
63
64
|
};
|
|
64
65
|
export type RemoveTypeAheadDecorations = (decorationSet?: DecorationSet) => boolean;
|
|
66
|
+
export type TypeAheadInputMethod = INPUT_METHOD.INSERT_MENU | INPUT_METHOD.KEYBOARD | INPUT_METHOD.QUICK_INSERT | INPUT_METHOD.TOOLBAR;
|
|
67
|
+
export type TypeAheadPluginOptions = {
|
|
68
|
+
isMobile?: boolean;
|
|
69
|
+
createAnalyticsEvent?: CreateUIAnalyticsEvent;
|
|
70
|
+
};
|
|
71
|
+
type OpenTypeAheadProps = {
|
|
72
|
+
triggerHandler: TypeAheadHandler;
|
|
73
|
+
inputMethod: TypeAheadInputMethod;
|
|
74
|
+
query?: string;
|
|
75
|
+
};
|
|
76
|
+
type InsertTypeAheadItemProps = {
|
|
77
|
+
triggerHandler: TypeAheadHandler;
|
|
78
|
+
contentItem: TypeAheadItem;
|
|
79
|
+
query: string;
|
|
80
|
+
sourceListItem: TypeAheadItem[];
|
|
81
|
+
mode?: SelectItemMode;
|
|
82
|
+
};
|
|
83
|
+
type CloseTypeAheadProps = {
|
|
84
|
+
insertCurrentQueryAsRawText: boolean;
|
|
85
|
+
attachCommand?: Command;
|
|
86
|
+
};
|
|
87
|
+
/**
|
|
88
|
+
* Type ahead plugin to be added to an `EditorPresetBuilder` and used with `ComposableEditor`
|
|
89
|
+
* from `@atlaskit/editor-core`.
|
|
90
|
+
*/
|
|
91
|
+
export type TypeAheadPlugin = NextEditorPlugin<'typeAhead', {
|
|
92
|
+
pluginConfiguration: TypeAheadPluginOptions | undefined;
|
|
93
|
+
dependencies: [
|
|
94
|
+
OptionalPlugin<AnalyticsPlugin>
|
|
95
|
+
];
|
|
96
|
+
sharedState: {
|
|
97
|
+
query: string;
|
|
98
|
+
isOpen: boolean;
|
|
99
|
+
isAllowed: boolean;
|
|
100
|
+
currentHandler?: TypeAheadHandler;
|
|
101
|
+
};
|
|
102
|
+
actions: {
|
|
103
|
+
isOpen: (editorState: EditorState) => boolean;
|
|
104
|
+
isAllowed: (editorState: EditorState) => boolean;
|
|
105
|
+
insert: (props: InsertTypeAheadItemProps) => boolean;
|
|
106
|
+
findHandlerByTrigger: (trigger: string) => TypeAheadHandler | null;
|
|
107
|
+
open: (props: OpenTypeAheadProps) => boolean;
|
|
108
|
+
close: (props: CloseTypeAheadProps) => boolean;
|
|
109
|
+
openAtTransaction: (props: OpenTypeAheadProps) => (tr: Transaction) => boolean;
|
|
110
|
+
};
|
|
111
|
+
}>;
|
package/dist/types-ts4.5/plugins/view-update-subscription/subscribe/toolbarAndPickerUpdates.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import type { EditorView } from '@atlaskit/editor-prosemirror/view';
|
|
2
2
|
import type { DatePluginSharedState } from '../../date';
|
|
3
3
|
import type { ConfigWithNodeInfo } from '@atlaskit/editor-plugin-floating-toolbar';
|
|
4
|
-
import type { StatusState } from '
|
|
4
|
+
import type { StatusState } from '@atlaskit/editor-plugin-status';
|
|
5
5
|
type SubscribeToToolbarAndPickerUpdatesCallbackArgs = {
|
|
6
6
|
dateState?: DatePluginSharedState;
|
|
7
7
|
statusState?: StatusState;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/editor-core",
|
|
3
|
-
"version": "188.
|
|
3
|
+
"version": "188.9.0",
|
|
4
4
|
"description": "A package contains Atlassian editor core functionality",
|
|
5
5
|
"publishConfig": {
|
|
6
6
|
"registry": "https://registry.npmjs.org/"
|
|
@@ -87,10 +87,13 @@
|
|
|
87
87
|
"@atlaskit/editor-plugin-placeholder": "^0.1.0",
|
|
88
88
|
"@atlaskit/editor-plugin-quick-insert": "^0.2.0",
|
|
89
89
|
"@atlaskit/editor-plugin-rule": "^0.1.0",
|
|
90
|
+
"@atlaskit/editor-plugin-save-on-enter": "^0.1.0",
|
|
91
|
+
"@atlaskit/editor-plugin-scroll-into-view": "^0.1.0",
|
|
90
92
|
"@atlaskit/editor-plugin-selection": "^0.1.0",
|
|
93
|
+
"@atlaskit/editor-plugin-status": "^0.1.0",
|
|
91
94
|
"@atlaskit/editor-plugin-table": "^5.2.0",
|
|
92
95
|
"@atlaskit/editor-plugin-text-formatting": "^0.4.0",
|
|
93
|
-
"@atlaskit/editor-plugin-type-ahead": "^0.
|
|
96
|
+
"@atlaskit/editor-plugin-type-ahead": "^0.6.0",
|
|
94
97
|
"@atlaskit/editor-plugin-unsupported-content": "^0.2.0",
|
|
95
98
|
"@atlaskit/editor-plugin-width": "^0.2.0",
|
|
96
99
|
"@atlaskit/editor-prosemirror": "1.1.0",
|
|
@@ -116,7 +119,6 @@
|
|
|
116
119
|
"@atlaskit/smart-card": "^26.34.0",
|
|
117
120
|
"@atlaskit/smart-user-picker": "^6.3.0",
|
|
118
121
|
"@atlaskit/spinner": "^15.6.0",
|
|
119
|
-
"@atlaskit/status": "^1.4.0",
|
|
120
122
|
"@atlaskit/tabs": "^13.4.0",
|
|
121
123
|
"@atlaskit/task-decision": "^17.9.0",
|
|
122
124
|
"@atlaskit/textarea": "^4.7.0",
|
|
@@ -155,7 +157,7 @@
|
|
|
155
157
|
"@af/integration-testing": "*",
|
|
156
158
|
"@af/visual-regression": "*",
|
|
157
159
|
"@atlaskit/collab-provider": "9.15.1",
|
|
158
|
-
"@atlaskit/dropdown-menu": "^12.
|
|
160
|
+
"@atlaskit/dropdown-menu": "^12.1.0",
|
|
159
161
|
"@atlaskit/editor-extension-dropbox": "^0.4.0",
|
|
160
162
|
"@atlaskit/flag": "^15.2.0",
|
|
161
163
|
"@atlaskit/icon-object": "^6.3.0",
|