@atlaskit/editor-core 187.6.0 → 187.6.10
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 +13 -0
- package/dist/cjs/plugins/expand/commands.js +2 -1
- package/dist/cjs/plugins/expand/index.js +1 -1
- package/dist/cjs/plugins/insert-block/index.js +7 -10
- package/dist/cjs/plugins/insert-block/ui/ToolbarInsertBlock/create-items.js +2 -1
- package/dist/cjs/plugins/insert-block/ui/ToolbarInsertBlock/index.js +40 -32
- package/dist/cjs/plugins/mentions/index.js +11 -0
- package/dist/cjs/plugins/mentions/pm-plugins/main.js +24 -9
- package/dist/cjs/plugins/mentions/pm-plugins/utils.js +15 -1
- package/dist/cjs/ui/Appearance/FullPage/MainToolbar.js +1 -1
- package/dist/cjs/version-wrapper.js +1 -1
- package/dist/cjs/version.json +1 -1
- package/dist/es2019/plugins/expand/commands.js +2 -1
- package/dist/es2019/plugins/expand/index.js +1 -1
- package/dist/es2019/plugins/insert-block/index.js +4 -7
- package/dist/es2019/plugins/insert-block/ui/ToolbarInsertBlock/create-items.js +2 -1
- package/dist/es2019/plugins/insert-block/ui/ToolbarInsertBlock/index.js +11 -4
- package/dist/es2019/plugins/mentions/index.js +11 -0
- package/dist/es2019/plugins/mentions/pm-plugins/main.js +25 -9
- package/dist/es2019/plugins/mentions/pm-plugins/utils.js +11 -1
- package/dist/es2019/ui/Appearance/FullPage/MainToolbar.js +2 -2
- package/dist/es2019/version-wrapper.js +1 -1
- package/dist/es2019/version.json +1 -1
- package/dist/esm/plugins/expand/commands.js +2 -1
- package/dist/esm/plugins/expand/index.js +1 -1
- package/dist/esm/plugins/insert-block/index.js +5 -8
- package/dist/esm/plugins/insert-block/ui/ToolbarInsertBlock/create-items.js +2 -1
- package/dist/esm/plugins/insert-block/ui/ToolbarInsertBlock/index.js +40 -32
- package/dist/esm/plugins/mentions/index.js +11 -0
- package/dist/esm/plugins/mentions/pm-plugins/main.js +24 -9
- package/dist/esm/plugins/mentions/pm-plugins/utils.js +13 -1
- package/dist/esm/ui/Appearance/FullPage/MainToolbar.js +2 -2
- package/dist/esm/version-wrapper.js +1 -1
- package/dist/esm/version.json +1 -1
- package/dist/types/plugins/insert-block/index.d.ts +5 -3
- package/dist/types/plugins/insert-block/ui/ToolbarInsertBlock/create-items.d.ts +7 -6
- package/dist/types/plugins/insert-block/ui/ToolbarInsertBlock/types.d.ts +10 -9
- package/dist/types/plugins/mentions/index.d.ts +3 -2
- package/dist/types/plugins/mentions/pm-plugins/utils.d.ts +3 -2
- package/dist/types/plugins/mentions/types.d.ts +1 -0
- package/dist/types-ts4.5/plugins/insert-block/index.d.ts +5 -3
- package/dist/types-ts4.5/plugins/insert-block/ui/ToolbarInsertBlock/create-items.d.ts +7 -6
- package/dist/types-ts4.5/plugins/insert-block/ui/ToolbarInsertBlock/types.d.ts +10 -9
- package/dist/types-ts4.5/plugins/mentions/index.d.ts +3 -2
- package/dist/types-ts4.5/plugins/mentions/pm-plugins/utils.d.ts +3 -2
- package/dist/types-ts4.5/plugins/mentions/types.d.ts +1 -0
- package/package.json +6 -6
- package/report.api.md +1 -0
- package/tmp/api-report-tmp.d.ts +1 -0
|
@@ -1,10 +1,11 @@
|
|
|
1
|
-
import { NextEditorPlugin, OptionalPlugin } from '@atlaskit/editor-common/types';
|
|
1
|
+
import type { NextEditorPlugin, OptionalPlugin } from '@atlaskit/editor-common/types';
|
|
2
2
|
import type { ImageUploadPlugin } from '../image-upload';
|
|
3
3
|
import type datePlugin from '../date';
|
|
4
|
-
import { tablesPlugin } from '@atlaskit/editor-plugin-table';
|
|
4
|
+
import type { tablesPlugin } from '@atlaskit/editor-plugin-table';
|
|
5
5
|
import type { hyperlinkPlugin } from '@atlaskit/editor-plugin-hyperlink';
|
|
6
6
|
import type featureFlagsPlugin from '@atlaskit/editor-plugin-feature-flags';
|
|
7
7
|
import type { analyticsPlugin } from '@atlaskit/editor-plugin-analytics';
|
|
8
|
+
import type mentionsPlugin from '../mentions';
|
|
8
9
|
export interface InsertBlockOptions {
|
|
9
10
|
allowTables?: boolean;
|
|
10
11
|
allowExpand?: boolean;
|
|
@@ -22,7 +23,8 @@ declare const insertBlockPlugin: NextEditorPlugin<'insertBlock', {
|
|
|
22
23
|
OptionalPlugin<typeof hyperlinkPlugin>,
|
|
23
24
|
OptionalPlugin<typeof datePlugin>,
|
|
24
25
|
OptionalPlugin<typeof analyticsPlugin>,
|
|
25
|
-
OptionalPlugin<ImageUploadPlugin
|
|
26
|
+
OptionalPlugin<ImageUploadPlugin>,
|
|
27
|
+
OptionalPlugin<typeof mentionsPlugin>
|
|
26
28
|
];
|
|
27
29
|
}>;
|
|
28
30
|
export default insertBlockPlugin;
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
-
import { WrappedComponentProps } from 'react-intl-next';
|
|
3
|
-
import { Schema } from 'prosemirror-model';
|
|
4
|
-
import { EmojiProvider } from '@atlaskit/emoji/resource';
|
|
5
|
-
import { BlockType } from '../../../block-type/types';
|
|
6
|
-
import { MenuItem } from '../../../../ui/DropdownMenu/types';
|
|
7
|
-
import { MacroProvider } from '../../../macro';
|
|
2
|
+
import type { WrappedComponentProps } from 'react-intl-next';
|
|
3
|
+
import type { Schema } from 'prosemirror-model';
|
|
4
|
+
import type { EmojiProvider } from '@atlaskit/emoji/resource';
|
|
5
|
+
import type { BlockType } from '../../../block-type/types';
|
|
6
|
+
import type { MenuItem } from '../../../../ui/DropdownMenu/types';
|
|
7
|
+
import type { MacroProvider } from '../../../macro';
|
|
8
8
|
export interface CreateItemsConfig {
|
|
9
9
|
isTypeAheadAllowed?: boolean;
|
|
10
10
|
tableSupported?: boolean;
|
|
@@ -13,6 +13,7 @@ export interface CreateItemsConfig {
|
|
|
13
13
|
imageUploadSupported?: boolean;
|
|
14
14
|
imageUploadEnabled?: boolean;
|
|
15
15
|
mentionsSupported?: boolean;
|
|
16
|
+
mentionsDisabled?: boolean;
|
|
16
17
|
availableWrapperBlockTypes?: BlockType[];
|
|
17
18
|
actionSupported?: boolean;
|
|
18
19
|
decisionSupported?: boolean;
|
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import { INPUT_METHOD, DispatchAnalyticsEvent } from '@atlaskit/editor-common/analytics';
|
|
2
|
-
import { EditorView } from 'prosemirror-view';
|
|
3
|
-
import { EditorActionsOptions as EditorActions, FeatureFlags, ExtractInjectionAPI, ImageUploadPluginReferenceEvent, Command } from '@atlaskit/editor-common/types';
|
|
4
|
-
import { EmojiProvider } from '@atlaskit/emoji';
|
|
5
|
-
import { BlockType } from '../../../block-type/types';
|
|
6
|
-
import { MacroProvider } from '@atlaskit/editor-common/provider-factory';
|
|
7
|
-
import { MenuItem } from '../../../../ui/DropdownMenu/types';
|
|
8
|
-
import { Node as PMNode } from 'prosemirror-model';
|
|
9
|
-
import { BlockMenuItem } from './create-items';
|
|
1
|
+
import type { INPUT_METHOD, DispatchAnalyticsEvent } from '@atlaskit/editor-common/analytics';
|
|
2
|
+
import type { EditorView } from 'prosemirror-view';
|
|
3
|
+
import type { EditorActionsOptions as EditorActions, FeatureFlags, ExtractInjectionAPI, ImageUploadPluginReferenceEvent, Command } from '@atlaskit/editor-common/types';
|
|
4
|
+
import type { EmojiProvider } from '@atlaskit/emoji';
|
|
5
|
+
import type { BlockType } from '../../../block-type/types';
|
|
6
|
+
import type { MacroProvider } from '@atlaskit/editor-common/provider-factory';
|
|
7
|
+
import type { MenuItem } from '../../../../ui/DropdownMenu/types';
|
|
8
|
+
import type { Node as PMNode } from 'prosemirror-model';
|
|
9
|
+
import type { BlockMenuItem } from './create-items';
|
|
10
10
|
import type insertBlockPlugin from '../../index';
|
|
11
11
|
export interface Props {
|
|
12
12
|
buttons: number;
|
|
@@ -49,6 +49,7 @@ export interface Props {
|
|
|
49
49
|
dispatchAnalyticsEvent?: DispatchAnalyticsEvent;
|
|
50
50
|
featureFlags: FeatureFlags;
|
|
51
51
|
pluginInjectionApi?: ExtractInjectionAPI<typeof insertBlockPlugin>;
|
|
52
|
+
mentionsDisabled?: boolean;
|
|
52
53
|
}
|
|
53
54
|
export interface State {
|
|
54
55
|
isPlusMenuOpen: boolean;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { NextEditorPlugin, OptionalPlugin } from '@atlaskit/editor-common/types';
|
|
2
|
-
import { MentionPluginOptions } from './types';
|
|
1
|
+
import type { NextEditorPlugin, OptionalPlugin } from '@atlaskit/editor-common/types';
|
|
2
|
+
import type { MentionPluginOptions, MentionPluginState } from './types';
|
|
3
3
|
import { mentionPluginKey } from './pm-plugins/key';
|
|
4
4
|
import type { analyticsPlugin } from '@atlaskit/editor-plugin-analytics';
|
|
5
5
|
export { mentionPluginKey };
|
|
@@ -8,5 +8,6 @@ declare const mentionsPlugin: NextEditorPlugin<'mention', {
|
|
|
8
8
|
dependencies: [
|
|
9
9
|
OptionalPlugin<typeof analyticsPlugin>
|
|
10
10
|
];
|
|
11
|
+
sharedState: MentionPluginState | undefined;
|
|
11
12
|
}>;
|
|
12
13
|
export default mentionsPlugin;
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
-
import { EditorState } from 'prosemirror-state';
|
|
2
|
-
import { MentionPluginState } from '../types';
|
|
1
|
+
import type { EditorState } from 'prosemirror-state';
|
|
2
|
+
import type { MentionPluginState } from '../types';
|
|
3
3
|
export declare function getMentionPluginState(state: EditorState): MentionPluginState;
|
|
4
|
+
export declare const canMentionBeCreatedInRange: (from: number, to: number) => (state: EditorState) => boolean;
|
|
@@ -19,5 +19,6 @@ export type MentionPluginState = {
|
|
|
19
19
|
mentionProvider?: MentionProvider;
|
|
20
20
|
contextIdentifierProvider?: ContextIdentifierProvider;
|
|
21
21
|
mentions?: Array<MentionDescription>;
|
|
22
|
+
canInsertMention?: boolean;
|
|
22
23
|
};
|
|
23
24
|
export type FireElementsChannelEvent = <T extends AnalyticsEventPayload>(payload: T) => void;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/editor-core",
|
|
3
|
-
"version": "187.6.
|
|
3
|
+
"version": "187.6.10",
|
|
4
4
|
"description": "A package contains Atlassian editor core functionality",
|
|
5
5
|
"publishConfig": {
|
|
6
6
|
"registry": "https://registry.npmjs.org/"
|
|
@@ -55,7 +55,7 @@
|
|
|
55
55
|
"@atlaskit/code": "^14.6.0",
|
|
56
56
|
"@atlaskit/date": "^0.10.0",
|
|
57
57
|
"@atlaskit/datetime-picker": "^12.7.0",
|
|
58
|
-
"@atlaskit/editor-common": "^74.
|
|
58
|
+
"@atlaskit/editor-common": "^74.28.0",
|
|
59
59
|
"@atlaskit/editor-json-transformer": "^8.10.0",
|
|
60
60
|
"@atlaskit/editor-markdown-transformer": "^5.2.5",
|
|
61
61
|
"@atlaskit/editor-palette": "1.5.1",
|
|
@@ -69,7 +69,7 @@
|
|
|
69
69
|
"@atlaskit/editor-plugin-grid": "^0.1.0",
|
|
70
70
|
"@atlaskit/editor-plugin-guideline": "^0.3.4",
|
|
71
71
|
"@atlaskit/editor-plugin-hyperlink": "^0.2.0",
|
|
72
|
-
"@atlaskit/editor-plugin-table": "^2.
|
|
72
|
+
"@atlaskit/editor-plugin-table": "^2.6.0",
|
|
73
73
|
"@atlaskit/editor-plugin-width": "^0.1.0",
|
|
74
74
|
"@atlaskit/editor-shared-styles": "^2.5.0",
|
|
75
75
|
"@atlaskit/editor-tables": "^2.3.0",
|
|
@@ -95,7 +95,7 @@
|
|
|
95
95
|
"@atlaskit/radio": "^5.6.0",
|
|
96
96
|
"@atlaskit/section-message": "^6.4.0",
|
|
97
97
|
"@atlaskit/select": "^16.5.0",
|
|
98
|
-
"@atlaskit/smart-card": "^26.
|
|
98
|
+
"@atlaskit/smart-card": "^26.12.0",
|
|
99
99
|
"@atlaskit/smart-user-picker": "^6.1.0",
|
|
100
100
|
"@atlaskit/spinner": "^15.5.0",
|
|
101
101
|
"@atlaskit/status": "^1.3.0",
|
|
@@ -149,14 +149,14 @@
|
|
|
149
149
|
"@atlaskit/collab-provider": "9.7.3",
|
|
150
150
|
"@atlaskit/dropdown-menu": "^11.11.0",
|
|
151
151
|
"@atlaskit/editor-extension-dropbox": "^0.4.0",
|
|
152
|
-
"@atlaskit/editor-plugin-table": "^2.
|
|
152
|
+
"@atlaskit/editor-plugin-table": "^2.6.0",
|
|
153
153
|
"@atlaskit/editor-test-helpers": "^18.10.0",
|
|
154
154
|
"@atlaskit/flag": "^15.2.0",
|
|
155
155
|
"@atlaskit/icon-object": "^6.3.0",
|
|
156
156
|
"@atlaskit/inline-dialog": "^13.6.0",
|
|
157
157
|
"@atlaskit/link-analytics": "^8.2.0",
|
|
158
158
|
"@atlaskit/link-provider": "^1.6.0",
|
|
159
|
-
"@atlaskit/link-test-helpers": "^
|
|
159
|
+
"@atlaskit/link-test-helpers": "^6.0.0",
|
|
160
160
|
"@atlaskit/media-core": "^34.1.0",
|
|
161
161
|
"@atlaskit/media-integration-test-helpers": "^3.0.0",
|
|
162
162
|
"@atlaskit/media-test-helpers": "^33.0.0",
|
package/report.api.md
CHANGED
|
@@ -1635,6 +1635,7 @@ export type MentionPluginState = {
|
|
|
1635
1635
|
mentionProvider?: MentionProvider_2;
|
|
1636
1636
|
contextIdentifierProvider?: ContextIdentifierProvider;
|
|
1637
1637
|
mentions?: Array<MentionDescription>;
|
|
1638
|
+
canInsertMention?: boolean;
|
|
1638
1639
|
};
|
|
1639
1640
|
|
|
1640
1641
|
export { MentionProvider };
|
package/tmp/api-report-tmp.d.ts
CHANGED
|
@@ -1467,6 +1467,7 @@ export type MentionPluginState = {
|
|
|
1467
1467
|
mentionProvider?: MentionProvider_2;
|
|
1468
1468
|
contextIdentifierProvider?: ContextIdentifierProvider;
|
|
1469
1469
|
mentions?: Array<MentionDescription>;
|
|
1470
|
+
canInsertMention?: boolean;
|
|
1470
1471
|
};
|
|
1471
1472
|
|
|
1472
1473
|
export { MentionProvider }
|