@atlaskit/editor-core 189.3.26 → 189.3.27

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.
Files changed (49) hide show
  1. package/CHANGELOG.md +8 -0
  2. package/dist/cjs/plugins/insert-block/ui/ToolbarInsertBlock/index.js +37 -38
  3. package/dist/cjs/plugins/paste/pm-plugins/main.js +25 -8
  4. package/dist/cjs/plugins/tasks-and-decisions/index.js +16 -7
  5. package/dist/cjs/plugins/tasks-and-decisions/ui/ToolbarDecision/index.js +3 -3
  6. package/dist/cjs/plugins/tasks-and-decisions/ui/ToolbarTask/index.js +3 -3
  7. package/dist/cjs/plugins/toolbar-lists-indentation/ui/onItemActivated.js +4 -5
  8. package/dist/cjs/ui/ContentStyles/index.js +2 -2
  9. package/dist/cjs/version-wrapper.js +1 -1
  10. package/dist/es2019/plugins/insert-block/ui/ToolbarInsertBlock/index.js +6 -6
  11. package/dist/es2019/plugins/paste/pm-plugins/main.js +25 -8
  12. package/dist/es2019/plugins/tasks-and-decisions/index.js +115 -107
  13. package/dist/es2019/plugins/tasks-and-decisions/pm-plugins/input-rules.js +1 -2
  14. package/dist/es2019/plugins/tasks-and-decisions/ui/ToolbarDecision/index.js +1 -1
  15. package/dist/es2019/plugins/tasks-and-decisions/ui/ToolbarTask/index.js +1 -1
  16. package/dist/es2019/plugins/toolbar-lists-indentation/ui/onItemActivated.js +4 -5
  17. package/dist/es2019/ui/ContentStyles/index.js +1 -1
  18. package/dist/es2019/version-wrapper.js +1 -1
  19. package/dist/esm/plugins/insert-block/ui/ToolbarInsertBlock/index.js +37 -38
  20. package/dist/esm/plugins/paste/pm-plugins/main.js +25 -8
  21. package/dist/esm/plugins/tasks-and-decisions/index.js +14 -8
  22. package/dist/esm/plugins/tasks-and-decisions/pm-plugins/input-rules.js +1 -2
  23. package/dist/esm/plugins/tasks-and-decisions/ui/ToolbarDecision/index.js +1 -1
  24. package/dist/esm/plugins/tasks-and-decisions/ui/ToolbarTask/index.js +1 -1
  25. package/dist/esm/plugins/toolbar-lists-indentation/ui/onItemActivated.js +4 -5
  26. package/dist/esm/ui/ContentStyles/index.js +1 -1
  27. package/dist/esm/version-wrapper.js +1 -1
  28. package/dist/types/plugins/insert-block/types.d.ts +3 -1
  29. package/dist/types/plugins/tasks-and-decisions/commands.d.ts +1 -2
  30. package/dist/types/plugins/tasks-and-decisions/pm-plugins/helpers.d.ts +3 -3
  31. package/dist/types/plugins/tasks-and-decisions/pm-plugins/keymaps.d.ts +3 -3
  32. package/dist/types/plugins/tasks-and-decisions/types.d.ts +7 -0
  33. package/dist/types/plugins/tasks-and-decisions/ui/Decision/index.d.ts +1 -1
  34. package/dist/types/plugins/tasks-and-decisions/ui/Task/index.d.ts +4 -3
  35. package/dist/types/plugins/tasks-and-decisions/ui/Task/task-item-with-providers.d.ts +3 -2
  36. package/dist/types-ts4.5/plugins/insert-block/types.d.ts +3 -1
  37. package/dist/types-ts4.5/plugins/tasks-and-decisions/commands.d.ts +1 -2
  38. package/dist/types-ts4.5/plugins/tasks-and-decisions/pm-plugins/helpers.d.ts +3 -3
  39. package/dist/types-ts4.5/plugins/tasks-and-decisions/pm-plugins/keymaps.d.ts +3 -3
  40. package/dist/types-ts4.5/plugins/tasks-and-decisions/types.d.ts +7 -0
  41. package/dist/types-ts4.5/plugins/tasks-and-decisions/ui/Decision/index.d.ts +1 -1
  42. package/dist/types-ts4.5/plugins/tasks-and-decisions/ui/Task/index.d.ts +4 -3
  43. package/dist/types-ts4.5/plugins/tasks-and-decisions/ui/Task/task-item-with-providers.d.ts +3 -2
  44. package/package.json +6 -6
  45. /package/dist/cjs/{plugins/tasks-and-decisions/styles.js → ui/ContentStyles/tasks-and-decisions.js} +0 -0
  46. /package/dist/es2019/{plugins/tasks-and-decisions/styles.js → ui/ContentStyles/tasks-and-decisions.js} +0 -0
  47. /package/dist/esm/{plugins/tasks-and-decisions/styles.js → ui/ContentStyles/tasks-and-decisions.js} +0 -0
  48. /package/dist/types/{plugins/tasks-and-decisions/styles.d.ts → ui/ContentStyles/tasks-and-decisions.d.ts} +0 -0
  49. /package/dist/types-ts4.5/{plugins/tasks-and-decisions/styles.d.ts → ui/ContentStyles/tasks-and-decisions.d.ts} +0 -0
@@ -1,2 +1,2 @@
1
1
  export var name = "@atlaskit/editor-core";
2
- export var version = "189.3.26";
2
+ export var version = "189.3.27";
@@ -19,6 +19,7 @@ import type { MentionsPlugin } from '@atlaskit/editor-plugin-mentions';
19
19
  import type { StatusPlugin } from '@atlaskit/editor-plugin-status';
20
20
  import type { PlaceholderTextPlugin } from '@atlaskit/editor-plugin-placeholder-text';
21
21
  import type { ExpandPlugin } from '@atlaskit/editor-plugin-expand';
22
+ import type { TaskAndDecisionsPlugin } from '../tasks-and-decisions/types';
22
23
  export type InsertBlockPluginDependencies = [
23
24
  FeatureFlagsPlugin,
24
25
  TypeAheadPlugin,
@@ -39,5 +40,6 @@ export type InsertBlockPluginDependencies = [
39
40
  OptionalPlugin<LayoutPlugin>,
40
41
  OptionalPlugin<ExpandPlugin>,
41
42
  OptionalPlugin<PlaceholderTextPlugin>,
42
- OptionalPlugin<ExtensionPlugin>
43
+ OptionalPlugin<ExtensionPlugin>,
44
+ OptionalPlugin<TaskAndDecisionsPlugin>
43
45
  ];
@@ -1,9 +1,8 @@
1
1
  import type { NodeType, ResolvedPos, Schema } from '@atlaskit/editor-prosemirror/model';
2
2
  import type { EditorState, Selection, Transaction } from '@atlaskit/editor-prosemirror/state';
3
- import type { Command } from '../../types';
4
3
  import type { EditorAnalyticsAPI } from '@atlaskit/editor-common/analytics';
5
4
  import { INPUT_METHOD } from '@atlaskit/editor-common/analytics';
6
- import type { TOOLBAR_MENU_TYPE } from '@atlaskit/editor-common/types';
5
+ import type { TOOLBAR_MENU_TYPE, Command } from '@atlaskit/editor-common/types';
7
6
  import type { AddItemAttrs, AddItemTransactionCreator, TaskDecisionInputMethod, TaskDecisionListType } from './types';
8
7
  export declare const getListTypes: (listType: TaskDecisionListType, schema: Schema) => {
9
8
  list: NodeType;
@@ -1,13 +1,13 @@
1
1
  import type { Node, NodeType, ResolvedPos } from '@atlaskit/editor-prosemirror/model';
2
- import { EditorState, Selection, Transaction } from '@atlaskit/editor-prosemirror/state';
2
+ import type { EditorState, Selection, Transaction } from '@atlaskit/editor-prosemirror/state';
3
3
  import type { EditorView } from '@atlaskit/editor-prosemirror/view';
4
- import { TaskItemData } from './types';
4
+ import type { TaskItemData } from './types';
5
5
  export declare const isInsideTaskOrDecisionItem: (state: EditorState) => boolean;
6
6
  export declare const isActionOrDecisionList: (node: Node) => boolean;
7
7
  export declare const isActionOrDecisionItem: (node: Node) => boolean;
8
8
  export declare const isInsideTask: (state: EditorState) => boolean;
9
9
  export declare const isInsideDecision: (state: EditorState) => boolean;
10
- export declare const isTable: (node?: Node | null) => Boolean;
10
+ export declare const isTable: (node?: Node | null) => boolean;
11
11
  /**
12
12
  * Creates a NodeRange around the given taskItem and the following
13
13
  * ("nested") taskList, if one exists.
@@ -1,11 +1,11 @@
1
1
  import type { Schema } from '@atlaskit/editor-prosemirror/model';
2
2
  import type { SafePlugin } from '@atlaskit/editor-common/safe-plugin';
3
- import type { ExtractInjectionAPI } from '@atlaskit/editor-common/types';
3
+ import type { ExtractInjectionAPI, Command } from '@atlaskit/editor-common/types';
4
4
  import type { EditorAnalyticsAPI } from '@atlaskit/editor-common/analytics';
5
5
  import { INPUT_METHOD } from '@atlaskit/editor-common/analytics';
6
6
  import type { TaskAndDecisionsPlugin } from '../types';
7
7
  type IndentationInputMethod = INPUT_METHOD.KEYBOARD | INPUT_METHOD.TOOLBAR;
8
- export declare const getUnindentCommand: (editorAnalyticsAPI: EditorAnalyticsAPI | undefined) => (inputMethod?: IndentationInputMethod) => import("@atlaskit/editor-common/types").Command;
9
- export declare const getIndentCommand: (editorAnalyticsAPI: EditorAnalyticsAPI | undefined) => (inputMethod?: IndentationInputMethod) => import("@atlaskit/editor-common/types").Command;
8
+ export declare const getUnindentCommand: (editorAnalyticsAPI: EditorAnalyticsAPI | undefined) => (inputMethod?: IndentationInputMethod) => Command;
9
+ export declare const getIndentCommand: (editorAnalyticsAPI: EditorAnalyticsAPI | undefined) => (inputMethod?: IndentationInputMethod) => Command;
10
10
  export declare function keymapPlugin(schema: Schema, api: ExtractInjectionAPI<TaskAndDecisionsPlugin> | undefined, allowNestedTasks?: boolean, consumeTabs?: boolean): SafePlugin | undefined;
11
11
  export default keymapPlugin;
@@ -5,6 +5,8 @@ import type { INPUT_METHOD, USER_CONTEXT } from '@atlaskit/editor-common/analyti
5
5
  import type { NextEditorPlugin, OptionalPlugin, LongPressSelectionPluginOptions } from '@atlaskit/editor-common/types';
6
6
  import type { TypeAheadPlugin } from '@atlaskit/editor-plugin-type-ahead';
7
7
  import type { AnalyticsPlugin } from '@atlaskit/editor-plugin-analytics';
8
+ import type { insertTaskDecisionCommand } from './commands';
9
+ import type { getIndentCommand, getUnindentCommand } from './pm-plugins/keymaps';
8
10
  export type TaskDecisionListType = 'taskList' | 'decisionList';
9
11
  export type TaskDecisionInputMethod = INPUT_METHOD.TOOLBAR | INPUT_METHOD.INSERT_MENU | INPUT_METHOD.QUICK_INSERT | INPUT_METHOD.FORMATTING | INPUT_METHOD.KEYBOARD;
10
12
  export type ContextData = {
@@ -39,4 +41,9 @@ export type TaskAndDecisionsPlugin = NextEditorPlugin<'taskDecision', {
39
41
  OptionalPlugin<TypeAheadPlugin>,
40
42
  OptionalPlugin<AnalyticsPlugin>
41
43
  ];
44
+ actions: {
45
+ insertTaskDecision: ReturnType<typeof insertTaskDecisionCommand>;
46
+ indentTaskList: ReturnType<typeof getIndentCommand>;
47
+ outdentTaskList: ReturnType<typeof getUnindentCommand>;
48
+ };
42
49
  }>;
@@ -1,5 +1,5 @@
1
1
  import React from 'react';
2
- import { WrappedComponentProps } from 'react-intl-next';
2
+ import type { WrappedComponentProps } from 'react-intl-next';
3
3
  interface Props {
4
4
  contentRef: any;
5
5
  showPlaceholder?: boolean;
@@ -1,7 +1,8 @@
1
- import React, { PureComponent, ReactElement } from 'react';
2
- import { WrappedComponentProps } from 'react-intl-next';
1
+ import type { ReactElement } from 'react';
2
+ import React, { PureComponent } from 'react';
3
+ import type { WrappedComponentProps } from 'react-intl-next';
3
4
  import { ProviderFactory } from '@atlaskit/editor-common/provider-factory';
4
- import { ContentRef } from '@atlaskit/task-decision';
5
+ import type { ContentRef } from '@atlaskit/task-decision';
5
6
  export interface TaskProps {
6
7
  taskId: string;
7
8
  isDone: boolean;
@@ -1,6 +1,7 @@
1
- import { Component, ReactElement } from 'react';
1
+ import type { ReactElement } from 'react';
2
+ import { Component } from 'react';
2
3
  import type { ContextIdentifierProvider } from '@atlaskit/editor-common/provider-factory';
3
- import { ContentRef, TaskDecisionProvider } from '@atlaskit/task-decision';
4
+ import type { ContentRef, TaskDecisionProvider } from '@atlaskit/task-decision';
4
5
  export interface Props {
5
6
  taskId: string;
6
7
  isDone: boolean;
@@ -19,6 +19,7 @@ import type { MentionsPlugin } from '@atlaskit/editor-plugin-mentions';
19
19
  import type { StatusPlugin } from '@atlaskit/editor-plugin-status';
20
20
  import type { PlaceholderTextPlugin } from '@atlaskit/editor-plugin-placeholder-text';
21
21
  import type { ExpandPlugin } from '@atlaskit/editor-plugin-expand';
22
+ import type { TaskAndDecisionsPlugin } from '../tasks-and-decisions/types';
22
23
  export type InsertBlockPluginDependencies = [
23
24
  FeatureFlagsPlugin,
24
25
  TypeAheadPlugin,
@@ -39,5 +40,6 @@ export type InsertBlockPluginDependencies = [
39
40
  OptionalPlugin<LayoutPlugin>,
40
41
  OptionalPlugin<ExpandPlugin>,
41
42
  OptionalPlugin<PlaceholderTextPlugin>,
42
- OptionalPlugin<ExtensionPlugin>
43
+ OptionalPlugin<ExtensionPlugin>,
44
+ OptionalPlugin<TaskAndDecisionsPlugin>
43
45
  ];
@@ -1,9 +1,8 @@
1
1
  import type { NodeType, ResolvedPos, Schema } from '@atlaskit/editor-prosemirror/model';
2
2
  import type { EditorState, Selection, Transaction } from '@atlaskit/editor-prosemirror/state';
3
- import type { Command } from '../../types';
4
3
  import type { EditorAnalyticsAPI } from '@atlaskit/editor-common/analytics';
5
4
  import { INPUT_METHOD } from '@atlaskit/editor-common/analytics';
6
- import type { TOOLBAR_MENU_TYPE } from '@atlaskit/editor-common/types';
5
+ import type { TOOLBAR_MENU_TYPE, Command } from '@atlaskit/editor-common/types';
7
6
  import type { AddItemAttrs, AddItemTransactionCreator, TaskDecisionInputMethod, TaskDecisionListType } from './types';
8
7
  export declare const getListTypes: (listType: TaskDecisionListType, schema: Schema) => {
9
8
  list: NodeType;
@@ -1,13 +1,13 @@
1
1
  import type { Node, NodeType, ResolvedPos } from '@atlaskit/editor-prosemirror/model';
2
- import { EditorState, Selection, Transaction } from '@atlaskit/editor-prosemirror/state';
2
+ import type { EditorState, Selection, Transaction } from '@atlaskit/editor-prosemirror/state';
3
3
  import type { EditorView } from '@atlaskit/editor-prosemirror/view';
4
- import { TaskItemData } from './types';
4
+ import type { TaskItemData } from './types';
5
5
  export declare const isInsideTaskOrDecisionItem: (state: EditorState) => boolean;
6
6
  export declare const isActionOrDecisionList: (node: Node) => boolean;
7
7
  export declare const isActionOrDecisionItem: (node: Node) => boolean;
8
8
  export declare const isInsideTask: (state: EditorState) => boolean;
9
9
  export declare const isInsideDecision: (state: EditorState) => boolean;
10
- export declare const isTable: (node?: Node | null) => Boolean;
10
+ export declare const isTable: (node?: Node | null) => boolean;
11
11
  /**
12
12
  * Creates a NodeRange around the given taskItem and the following
13
13
  * ("nested") taskList, if one exists.
@@ -1,11 +1,11 @@
1
1
  import type { Schema } from '@atlaskit/editor-prosemirror/model';
2
2
  import type { SafePlugin } from '@atlaskit/editor-common/safe-plugin';
3
- import type { ExtractInjectionAPI } from '@atlaskit/editor-common/types';
3
+ import type { ExtractInjectionAPI, Command } from '@atlaskit/editor-common/types';
4
4
  import type { EditorAnalyticsAPI } from '@atlaskit/editor-common/analytics';
5
5
  import { INPUT_METHOD } from '@atlaskit/editor-common/analytics';
6
6
  import type { TaskAndDecisionsPlugin } from '../types';
7
7
  type IndentationInputMethod = INPUT_METHOD.KEYBOARD | INPUT_METHOD.TOOLBAR;
8
- export declare const getUnindentCommand: (editorAnalyticsAPI: EditorAnalyticsAPI | undefined) => (inputMethod?: IndentationInputMethod) => import("@atlaskit/editor-common/types").Command;
9
- export declare const getIndentCommand: (editorAnalyticsAPI: EditorAnalyticsAPI | undefined) => (inputMethod?: IndentationInputMethod) => import("@atlaskit/editor-common/types").Command;
8
+ export declare const getUnindentCommand: (editorAnalyticsAPI: EditorAnalyticsAPI | undefined) => (inputMethod?: IndentationInputMethod) => Command;
9
+ export declare const getIndentCommand: (editorAnalyticsAPI: EditorAnalyticsAPI | undefined) => (inputMethod?: IndentationInputMethod) => Command;
10
10
  export declare function keymapPlugin(schema: Schema, api: ExtractInjectionAPI<TaskAndDecisionsPlugin> | undefined, allowNestedTasks?: boolean, consumeTabs?: boolean): SafePlugin | undefined;
11
11
  export default keymapPlugin;
@@ -5,6 +5,8 @@ import type { INPUT_METHOD, USER_CONTEXT } from '@atlaskit/editor-common/analyti
5
5
  import type { NextEditorPlugin, OptionalPlugin, LongPressSelectionPluginOptions } from '@atlaskit/editor-common/types';
6
6
  import type { TypeAheadPlugin } from '@atlaskit/editor-plugin-type-ahead';
7
7
  import type { AnalyticsPlugin } from '@atlaskit/editor-plugin-analytics';
8
+ import type { insertTaskDecisionCommand } from './commands';
9
+ import type { getIndentCommand, getUnindentCommand } from './pm-plugins/keymaps';
8
10
  export type TaskDecisionListType = 'taskList' | 'decisionList';
9
11
  export type TaskDecisionInputMethod = INPUT_METHOD.TOOLBAR | INPUT_METHOD.INSERT_MENU | INPUT_METHOD.QUICK_INSERT | INPUT_METHOD.FORMATTING | INPUT_METHOD.KEYBOARD;
10
12
  export type ContextData = {
@@ -39,4 +41,9 @@ export type TaskAndDecisionsPlugin = NextEditorPlugin<'taskDecision', {
39
41
  OptionalPlugin<TypeAheadPlugin>,
40
42
  OptionalPlugin<AnalyticsPlugin>
41
43
  ];
44
+ actions: {
45
+ insertTaskDecision: ReturnType<typeof insertTaskDecisionCommand>;
46
+ indentTaskList: ReturnType<typeof getIndentCommand>;
47
+ outdentTaskList: ReturnType<typeof getUnindentCommand>;
48
+ };
42
49
  }>;
@@ -1,5 +1,5 @@
1
1
  import React from 'react';
2
- import { WrappedComponentProps } from 'react-intl-next';
2
+ import type { WrappedComponentProps } from 'react-intl-next';
3
3
  interface Props {
4
4
  contentRef: any;
5
5
  showPlaceholder?: boolean;
@@ -1,7 +1,8 @@
1
- import React, { PureComponent, ReactElement } from 'react';
2
- import { WrappedComponentProps } from 'react-intl-next';
1
+ import type { ReactElement } from 'react';
2
+ import React, { PureComponent } from 'react';
3
+ import type { WrappedComponentProps } from 'react-intl-next';
3
4
  import { ProviderFactory } from '@atlaskit/editor-common/provider-factory';
4
- import { ContentRef } from '@atlaskit/task-decision';
5
+ import type { ContentRef } from '@atlaskit/task-decision';
5
6
  export interface TaskProps {
6
7
  taskId: string;
7
8
  isDone: boolean;
@@ -1,6 +1,7 @@
1
- import { Component, ReactElement } from 'react';
1
+ import type { ReactElement } from 'react';
2
+ import { Component } from 'react';
2
3
  import type { ContextIdentifierProvider } from '@atlaskit/editor-common/provider-factory';
3
- import { ContentRef, TaskDecisionProvider } from '@atlaskit/task-decision';
4
+ import type { ContentRef, TaskDecisionProvider } from '@atlaskit/task-decision';
4
5
  export interface Props {
5
6
  taskId: string;
6
7
  isDone: boolean;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atlaskit/editor-core",
3
- "version": "189.3.26",
3
+ "version": "189.3.27",
4
4
  "description": "A package contains Atlassian editor core functionality",
5
5
  "publishConfig": {
6
6
  "registry": "https://registry.npmjs.org/"
@@ -124,15 +124,15 @@
124
124
  "@atlaskit/platform-feature-flags": "^0.2.0",
125
125
  "@atlaskit/prosemirror-collab": "^0.2.0",
126
126
  "@atlaskit/prosemirror-input-rules": "^2.4.0",
127
- "@atlaskit/radio": "^5.6.0",
127
+ "@atlaskit/radio": "^6.0.0",
128
128
  "@atlaskit/section-message": "^6.4.0",
129
- "@atlaskit/select": "^16.7.0",
129
+ "@atlaskit/select": "^17.0.0",
130
130
  "@atlaskit/smart-card": "^26.42.0",
131
131
  "@atlaskit/smart-user-picker": "^6.3.0",
132
- "@atlaskit/spinner": "^15.6.0",
133
- "@atlaskit/tabs": "^13.4.0",
132
+ "@atlaskit/spinner": "^16.0.0",
133
+ "@atlaskit/tabs": "^14.0.0",
134
134
  "@atlaskit/task-decision": "^17.9.0",
135
- "@atlaskit/textarea": "^4.7.0",
135
+ "@atlaskit/textarea": "^5.0.0",
136
136
  "@atlaskit/textfield": "^5.6.0",
137
137
  "@atlaskit/theme": "^12.6.0",
138
138
  "@atlaskit/toggle": "^13.0.0",