@atlaskit/editor-core 195.5.1 → 195.6.1

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 (112) hide show
  1. package/.eslintrc.js +2 -0
  2. package/CHANGELOG.md +16 -0
  3. package/codemods/migrates/next-remove-allow-more-text-colors-prop.ts +1 -1
  4. package/codemods/migrates/remove-config-panel-width-prop.ts +1 -1
  5. package/codemods/migrates/rename-editor-to-editor-migration-component.ts +1 -1
  6. package/codemods/migrates/rename-smartlinks-prop.ts +1 -1
  7. package/codemods/utils.ts +11 -4
  8. package/dist/cjs/CollapsedEditor/index.js +1 -0
  9. package/dist/cjs/actions/index.js +6 -1
  10. package/dist/cjs/composable-editor/editor-internal.js +6 -2
  11. package/dist/cjs/create-editor/ReactEditorView.js +1 -0
  12. package/dist/cjs/create-editor/create-plugins-list.js +3 -1
  13. package/dist/cjs/create-editor/create-universal-preset.js +3 -1
  14. package/dist/cjs/presets/context.js +3 -0
  15. package/dist/cjs/presets/universal.js +2 -2
  16. package/dist/cjs/test-utils.js +3 -1
  17. package/dist/cjs/ui/ContextPanel/index.js +2 -0
  18. package/dist/cjs/ui/Toolbar/ToolbarInner.js +3 -4
  19. package/dist/cjs/ui/ToolbarFeedback/index.js +1 -0
  20. package/dist/cjs/ui/WithHelpTrigger/index.js +2 -0
  21. package/dist/cjs/use-preset.js +2 -0
  22. package/dist/cjs/utils/action.js +1 -0
  23. package/dist/cjs/utils/deprecation-warnings.js +2 -2
  24. package/dist/cjs/utils/performance/instrumented-plugin.js +2 -0
  25. package/dist/cjs/version-wrapper.js +1 -1
  26. package/dist/es2019/CollapsedEditor/index.js +3 -0
  27. package/dist/es2019/actions/index.js +6 -1
  28. package/dist/es2019/composable-editor/editor-internal.js +6 -2
  29. package/dist/es2019/create-editor/ReactEditorView.js +1 -0
  30. package/dist/es2019/create-editor/create-plugins-list.js +3 -1
  31. package/dist/es2019/create-editor/create-universal-preset.js +3 -1
  32. package/dist/es2019/presets/context.js +4 -0
  33. package/dist/es2019/presets/universal.js +2 -1
  34. package/dist/es2019/test-utils.js +3 -1
  35. package/dist/es2019/ui/Appearance/Mobile.js +1 -0
  36. package/dist/es2019/ui/ContextPanel/index.js +2 -0
  37. package/dist/es2019/ui/Toolbar/ToolbarInner.js +3 -4
  38. package/dist/es2019/ui/ToolbarFeedback/index.js +1 -0
  39. package/dist/es2019/ui/WithHelpTrigger/index.js +2 -0
  40. package/dist/es2019/use-preset.js +3 -0
  41. package/dist/es2019/utils/action.js +1 -0
  42. package/dist/es2019/utils/deprecation-warnings.js +2 -2
  43. package/dist/es2019/utils/performance/instrumented-plugin.js +2 -0
  44. package/dist/es2019/version-wrapper.js +1 -1
  45. package/dist/esm/CollapsedEditor/index.js +2 -0
  46. package/dist/esm/actions/index.js +6 -1
  47. package/dist/esm/composable-editor/editor-internal.js +6 -2
  48. package/dist/esm/create-editor/ReactEditorView.js +1 -0
  49. package/dist/esm/create-editor/create-plugins-list.js +3 -1
  50. package/dist/esm/create-editor/create-universal-preset.js +3 -1
  51. package/dist/esm/presets/context.js +4 -0
  52. package/dist/esm/presets/universal.js +2 -2
  53. package/dist/esm/test-utils.js +3 -1
  54. package/dist/esm/ui/ContextPanel/index.js +2 -0
  55. package/dist/esm/ui/Toolbar/ToolbarInner.js +3 -4
  56. package/dist/esm/ui/ToolbarFeedback/index.js +1 -0
  57. package/dist/esm/ui/WithHelpTrigger/index.js +2 -0
  58. package/dist/esm/use-preset.js +3 -0
  59. package/dist/esm/utils/action.js +1 -0
  60. package/dist/esm/utils/deprecation-warnings.js +2 -2
  61. package/dist/esm/utils/performance/instrumented-plugin.js +2 -0
  62. package/dist/esm/version-wrapper.js +1 -1
  63. package/dist/types/CollapsedEditor/index.d.ts +7 -7
  64. package/dist/types/EditorWithActions/index.d.ts +1 -6
  65. package/dist/types/create-editor/create-universal-preset.d.ts +154 -2
  66. package/dist/types/create-editor/get-plugins.d.ts +4 -2
  67. package/dist/types/presets/default.d.ts +150 -2
  68. package/dist/types/presets/universal.d.ts +162 -3
  69. package/dist/types/presets/useUniversalPreset.d.ts +154 -2
  70. package/dist/types/types/editor-props.d.ts +1 -1
  71. package/dist/types/ui/Addon/ClickAreaBlock/index.d.ts +6 -1
  72. package/dist/types/ui/Addon/ClickAreaMobile/index.d.ts +1 -1
  73. package/dist/types/ui/Addon/Dropdown/index.d.ts +1 -1
  74. package/dist/types/ui/Addon/click-area-helper.d.ts +1 -1
  75. package/dist/types/ui/Addon/types.d.ts +3 -3
  76. package/dist/types/ui/Appearance/Chromeless.d.ts +1 -1
  77. package/dist/types/ui/Appearance/FullPage/BeforeWrapper.d.ts +1 -1
  78. package/dist/types/ui/Appearance/FullPage/StyledComponents.d.ts +2 -2
  79. package/dist/types/ui/CollapsedEditor/index.d.ts +2 -2
  80. package/dist/types/ui/ContentStyles/index.d.ts +2 -1
  81. package/dist/types/ui/PluginSlot/index.d.ts +1 -1
  82. package/dist/types/ui/WithEditorActions/index.d.ts +2 -2
  83. package/dist/types/ui/WithFlash/index.d.ts +1 -1
  84. package/dist/types/ui/WithHelpTrigger/index.d.ts +1 -1
  85. package/dist/types/use-preset.d.ts +2 -1
  86. package/dist/types/utils/deprecation-warnings.d.ts +3 -3
  87. package/dist/types-ts4.5/CollapsedEditor/index.d.ts +7 -7
  88. package/dist/types-ts4.5/EditorWithActions/index.d.ts +1 -6
  89. package/dist/types-ts4.5/create-editor/create-universal-preset.d.ts +178 -2
  90. package/dist/types-ts4.5/create-editor/get-plugins.d.ts +4 -2
  91. package/dist/types-ts4.5/presets/default.d.ts +174 -2
  92. package/dist/types-ts4.5/presets/universal.d.ts +186 -3
  93. package/dist/types-ts4.5/presets/useUniversalPreset.d.ts +178 -2
  94. package/dist/types-ts4.5/types/editor-props.d.ts +1 -1
  95. package/dist/types-ts4.5/ui/Addon/ClickAreaBlock/index.d.ts +6 -1
  96. package/dist/types-ts4.5/ui/Addon/ClickAreaMobile/index.d.ts +1 -1
  97. package/dist/types-ts4.5/ui/Addon/Dropdown/index.d.ts +1 -1
  98. package/dist/types-ts4.5/ui/Addon/click-area-helper.d.ts +1 -1
  99. package/dist/types-ts4.5/ui/Addon/types.d.ts +3 -3
  100. package/dist/types-ts4.5/ui/Appearance/Chromeless.d.ts +1 -1
  101. package/dist/types-ts4.5/ui/Appearance/FullPage/BeforeWrapper.d.ts +1 -1
  102. package/dist/types-ts4.5/ui/Appearance/FullPage/StyledComponents.d.ts +2 -2
  103. package/dist/types-ts4.5/ui/CollapsedEditor/index.d.ts +2 -2
  104. package/dist/types-ts4.5/ui/ContentStyles/index.d.ts +2 -1
  105. package/dist/types-ts4.5/ui/PluginSlot/index.d.ts +1 -1
  106. package/dist/types-ts4.5/ui/WithEditorActions/index.d.ts +2 -2
  107. package/dist/types-ts4.5/ui/WithFlash/index.d.ts +1 -1
  108. package/dist/types-ts4.5/ui/WithHelpTrigger/index.d.ts +1 -1
  109. package/dist/types-ts4.5/use-preset.d.ts +2 -1
  110. package/dist/types-ts4.5/utils/deprecation-warnings.d.ts +3 -3
  111. package/docs/4-annotations.tsx +1 -0
  112. package/package.json +6 -6
@@ -1,16 +1,16 @@
1
1
  /// <reference types="react" />
2
2
  import type EditorActions from '../../actions';
3
- export type RenderOnClickHandler = (editorActions: EditorActions, closePopup: () => void) => React.ReactElement<any>;
3
+ export type RenderOnClickHandler = (editorActions: EditorActions, closePopup: () => void) => React.ReactElement;
4
4
  export interface AddonActions {
5
5
  actionOnClick?: (editorActions: EditorActions) => void;
6
6
  renderOnClick?: RenderOnClickHandler;
7
7
  }
8
8
  export interface AddonCommonProps extends AddonActions {
9
- icon: React.ReactElement<any>;
9
+ icon: React.ReactElement;
10
10
  }
11
11
  export interface AddonProps extends AddonCommonProps {
12
12
  onClick?: (actions: AddonActions) => void;
13
- children?: React.ReactElement<any>[];
13
+ children?: React.ReactElement[];
14
14
  }
15
15
  export interface AddonConfiguration extends AddonCommonProps {
16
16
  text: string;
@@ -8,7 +8,7 @@ import { type OptionalPlugin } from '@atlaskit/editor-common/types';
8
8
  import type { MaxContentSizePlugin } from '@atlaskit/editor-plugins/max-content-size';
9
9
  import type { EditorAppearanceComponentProps } from '../../types';
10
10
  type AppearanceProps = EditorAppearanceComponentProps<[OptionalPlugin<MaxContentSizePlugin>]>;
11
- export default class Editor extends React.Component<AppearanceProps, any> {
11
+ export default class Editor extends React.Component<AppearanceProps> {
12
12
  static displayName: string;
13
13
  private appearance;
14
14
  private containerElement;
@@ -4,7 +4,7 @@
4
4
  */
5
5
  import type { ReactElement } from 'react';
6
6
  import { jsx } from '@emotion/react';
7
- type ReactComponents = ReactElement<any> | ReactElement<any>[];
7
+ type ReactComponents = ReactElement | ReactElement[];
8
8
  export declare const BeforePrimaryToolbarWrapper: (props: {
9
9
  beforePrimaryToolbarComponents: ReactComponents | undefined;
10
10
  }) => jsx.JSX.Element;
@@ -1,12 +1,12 @@
1
1
  /// <reference types="react" />
2
2
  export declare const fullPageEditorWrapper: import("@emotion/react").SerializedStyles;
3
3
  export declare const ScrollContainer: import("react").ForwardRefExoticComponent<Pick<{
4
- theme?: any;
4
+ theme?: import("@emotion/react").Theme | undefined;
5
5
  colorMode?: "light" | "dark" | undefined;
6
6
  featureFlags?: import("@atlaskit/editor-common/types").FeatureFlags | undefined;
7
7
  viewMode?: "view" | "edit" | undefined;
8
8
  } & import("react").HTMLProps<HTMLDivElement>, "headers" | "method" | "id" | "default" | "cite" | "data" | "form" | "label" | "slot" | "span" | "style" | "summary" | "title" | "pattern" | "children" | "key" | "name" | "width" | "property" | "type" | "content" | "disabled" | "defaultValue" | "onChange" | "placeholder" | "media" | "value" | "list" | "open" | "accessKey" | "dir" | "className" | "role" | "start" | "action" | "step" | "wrap" | "color" | "height" | "translate" | "hidden" | keyof {
9
- theme?: any;
9
+ theme?: import("@emotion/react").Theme | undefined;
10
10
  colorMode?: "light" | "dark" | undefined;
11
11
  featureFlags?: import("@atlaskit/editor-common/types").FeatureFlags | undefined;
12
12
  viewMode?: "view" | "edit" | undefined;
@@ -1,5 +1,5 @@
1
1
  import React from 'react';
2
- import Editor from '../../editor';
2
+ import type Editor from '../../editor';
3
3
  export interface Props {
4
4
  placeholder?: string;
5
5
  children?: any;
@@ -14,6 +14,6 @@ export default class CollapsedEditor extends React.Component<Props, State> {
14
14
  previouslyExpanded?: boolean;
15
15
  functionalEditor?: boolean;
16
16
  componentDidUpdate(): void;
17
- handleEditorRef: (editorRef?: Editor, editorRefCallback?: any) => void;
17
+ handleEditorRef: (editorRef?: Editor, editorRefCallback?: ((editor: Editor | undefined) => void) | undefined) => void;
18
18
  render(): any;
19
19
  }
@@ -4,10 +4,11 @@
4
4
  */
5
5
  import React from 'react';
6
6
  import type { SerializedStyles } from '@emotion/react';
7
+ import { type Theme } from '@emotion/react';
7
8
  import type { FeatureFlags } from '../../types/feature-flags';
8
9
  export declare const linkStyles: SerializedStyles;
9
10
  type ContentStylesProps = {
10
- theme?: any;
11
+ theme?: Theme;
11
12
  colorMode?: 'light' | 'dark';
12
13
  featureFlags?: FeatureFlags;
13
14
  viewMode?: 'view' | 'edit';
@@ -28,7 +28,7 @@ export interface Props {
28
28
  contentArea?: HTMLElement;
29
29
  wrapperElement: HTMLElement | null;
30
30
  }
31
- export default class PluginSlot extends React.Component<Props, any> {
31
+ export default class PluginSlot extends React.Component<Props> {
32
32
  static displayName: string;
33
33
  transitionEvent: "transitionend" | undefined;
34
34
  shouldComponentUpdate(nextProps: Props): boolean;
@@ -2,9 +2,9 @@ import React from 'react';
2
2
  import PropTypes from 'prop-types';
3
3
  import type EditorActions from '../../actions';
4
4
  export interface WithEditorActionsProps {
5
- render(actions: EditorActions): React.ReactElement<any> | null;
5
+ render(actions: EditorActions): React.ReactElement | null;
6
6
  }
7
- export default class WithEditorActions extends React.Component<WithEditorActionsProps, any> {
7
+ export default class WithEditorActions extends React.Component<WithEditorActionsProps> {
8
8
  static contextTypes: {
9
9
  editorActions: PropTypes.Validator<object>;
10
10
  };
@@ -6,7 +6,7 @@ import React from 'react';
6
6
  import { jsx } from '@emotion/react';
7
7
  export interface Props {
8
8
  animate: boolean;
9
- children?: any;
9
+ children?: React.ReactNode;
10
10
  }
11
11
  export default class WithFlash extends React.Component<Props> {
12
12
  private toggle;
@@ -4,7 +4,7 @@ import type EditorActions from '../../actions';
4
4
  interface WithHelpTriggerProps {
5
5
  render: (openHelp: () => void) => React.ReactNode;
6
6
  }
7
- export default class WithHelpTrigger extends React.Component<WithHelpTriggerProps, any> {
7
+ export default class WithHelpTrigger extends React.Component<WithHelpTriggerProps> {
8
8
  static contextTypes: {
9
9
  editorActions: PropTypes.Validator<object>;
10
10
  };
@@ -1,7 +1,8 @@
1
1
  import type { DependencyList } from 'react';
2
2
  import { type AllEditorPresetPluginTypes, EditorPresetBuilder, type ExtractPresetAPI } from '@atlaskit/editor-common/preset';
3
3
  interface PresetAPI<Preset extends EditorPresetBuilder<any, any>> {
4
- editorApi: (Preset extends EditorPresetBuilder<any, any> ? ExtractPresetAPI<Preset> : never) | undefined;
4
+ editorApi: // eslint-disable-next-line @typescript-eslint/no-explicit-any
5
+ (Preset extends EditorPresetBuilder<any, any> ? ExtractPresetAPI<Preset> : never) | undefined;
5
6
  preset: Preset;
6
7
  }
7
8
  /**
@@ -1,8 +1,8 @@
1
- export interface DeprecationWarning {
1
+ export interface DeprecationWarning<Props> {
2
2
  property: string;
3
3
  description?: string;
4
4
  type?: string;
5
- condition?: (props: any) => boolean;
5
+ condition?: (props: Props) => boolean;
6
6
  }
7
- declare const deprecationWarnings: (className: string, props: any, deprecations: Array<DeprecationWarning>) => void;
7
+ declare function deprecationWarnings<Props extends object>(className: string, props: Props, deprecations: Array<DeprecationWarning<Props>>): void;
8
8
  export default deprecationWarnings;
@@ -1,11 +1,12 @@
1
1
  import React from 'react';
2
2
  import type * as EditorImports from '../index';
3
+ type EditorModules = {
4
+ [x: string]: any;
5
+ };
3
6
  export type EditorModule = {
4
7
  EditorContext: typeof EditorImports.EditorContext;
5
8
  WithEditorActions: typeof EditorImports.WithEditorActions;
6
- } & {
7
- [x: string]: any;
8
- };
9
+ } & EditorModules;
9
10
  export interface Props {
10
11
  placeholder?: string;
11
12
  isExpanded?: boolean;
@@ -13,14 +14,13 @@ export interface Props {
13
14
  renderEditor: (Editor: typeof EditorImports.Editor, modules: EditorModule) => JSX.Element;
14
15
  }
15
16
  export interface State {
16
- editorModules?: {
17
- [x: string]: any;
18
- };
17
+ editorModules?: EditorModules;
19
18
  }
20
19
  export default class CollapsedEditor extends React.Component<Props, State> {
21
- static editorModules: any;
20
+ static editorModules: EditorModules;
22
21
  state: State;
23
22
  componentDidMount(): void;
24
23
  loadEditorModules(): void;
25
24
  render(): JSX.Element;
26
25
  }
26
+ export {};
@@ -2,12 +2,7 @@ import React from 'react';
2
2
  import PropTypes from 'prop-types';
3
3
  import type EditorActions from '../actions';
4
4
  import type { EditorProps } from '../editor';
5
- export interface EditorWithActionsPropsOverride extends EditorProps {
6
- onSave?: any;
7
- onChange?: any;
8
- onCancel?: any;
9
- }
10
- export interface EditorWithActionsProps extends EditorWithActionsPropsOverride {
5
+ export interface EditorWithActionsProps extends Omit<EditorProps, 'onSave' | 'onChange' | 'onCancel'> {
11
6
  onSave?: (actions: EditorActions) => void;
12
7
  onChange?: (actions: EditorActions) => void;
13
8
  onCancel?: (actions: EditorActions) => void;
@@ -935,7 +935,93 @@ export declare function createUniversalPreset({ props, prevProps, initialPluginC
935
935
  setInlineCommentDraftState: (drafting: boolean, inputMethod: import("@atlaskit/editor-plugin-annotation").InlineCommentInputMethod, targetType?: import("@atlaskit/editor-plugin-annotation").TargetType | undefined, isCommentOnMediaOn?: boolean | undefined, targetNodeId?: string | undefined) => import("@atlaskit/editor-common/types").Command;
936
936
  showCommentForBlockNode: (node: import("prosemirror-model").Node | null, viewMethod?: import("@atlaskit/editor-common/analytics").VIEW_METHOD | undefined) => import("@atlaskit/editor-common/types").Command;
937
937
  };
938
- }, import("@atlaskit/editor-plugin-annotation").AnnotationProviders | undefined>>
938
+ }, import("@atlaskit/editor-plugin-annotation").AnnotationProviders | undefined>>,
939
+ import("@atlaskit/editor-common/types").OptionalPlugin<import("@atlaskit/editor-common/types").NextEditorPluginFunctionOptionalConfigDefinition<"mention", {
940
+ pluginConfiguration: import("@atlaskit/editor-plugin-mentions").MentionPluginOptions | undefined;
941
+ dependencies: [
942
+ import("@atlaskit/editor-common/types").OptionalPlugin<import("@atlaskit/editor-common/types").NextEditorPluginFunctionOptionalConfigDefinition<"analytics", {
943
+ pluginConfiguration: import("@atlaskit/editor-plugin-analytics").AnalyticsPluginOptions;
944
+ sharedState: {
945
+ createAnalyticsEvent: import("@atlaskit/analytics-next").CreateUIAnalyticsEvent | null;
946
+ attachAnalyticsEvent: import("@atlaskit/editor-plugin-analytics").CreateAttachPayloadIntoTransaction | null;
947
+ performanceTracking: import("@atlaskit/editor-common/types").PerformanceTracking | undefined;
948
+ };
949
+ dependencies: [
950
+ import("@atlaskit/editor-common/types").OptionalPlugin<import("@atlaskit/editor-common/types").NextEditorPluginFunctionOptionalConfigDefinition<"featureFlags", {
951
+ pluginConfiguration: import("@atlaskit/editor-common/types").FeatureFlags;
952
+ sharedState: import("@atlaskit/editor-common/types").FeatureFlags;
953
+ }, import("@atlaskit/editor-common/types").FeatureFlags>>
954
+ ];
955
+ actions: import("@atlaskit/editor-common/analytics").EditorAnalyticsAPI;
956
+ }, import("@atlaskit/editor-plugin-analytics").AnalyticsPluginOptions>>,
957
+ import("@atlaskit/editor-common/types").NextEditorPluginFunctionOptionalConfigDefinition<"typeAhead", {
958
+ pluginConfiguration: import("@atlaskit/editor-plugin-type-ahead").TypeAheadPluginOptions | undefined;
959
+ dependencies: [
960
+ import("@atlaskit/editor-common/types").OptionalPlugin<import("@atlaskit/editor-common/types").NextEditorPluginFunctionOptionalConfigDefinition<"analytics", {
961
+ pluginConfiguration: import("@atlaskit/editor-plugin-analytics").AnalyticsPluginOptions;
962
+ sharedState: {
963
+ createAnalyticsEvent: import("@atlaskit/analytics-next").CreateUIAnalyticsEvent | null;
964
+ attachAnalyticsEvent: import("@atlaskit/editor-plugin-analytics").CreateAttachPayloadIntoTransaction | null;
965
+ performanceTracking: import("@atlaskit/editor-common/types").PerformanceTracking | undefined;
966
+ };
967
+ dependencies: [
968
+ import("@atlaskit/editor-common/types").OptionalPlugin<import("@atlaskit/editor-common/types").NextEditorPluginFunctionOptionalConfigDefinition<"featureFlags", {
969
+ pluginConfiguration: import("@atlaskit/editor-common/types").FeatureFlags;
970
+ sharedState: import("@atlaskit/editor-common/types").FeatureFlags;
971
+ }, import("@atlaskit/editor-common/types").FeatureFlags>>
972
+ ];
973
+ actions: import("@atlaskit/editor-common/analytics").EditorAnalyticsAPI;
974
+ }, import("@atlaskit/editor-plugin-analytics").AnalyticsPluginOptions>>,
975
+ import("@atlaskit/editor-common/types").OptionalPlugin<import("@atlaskit/editor-common/types").NextEditorPluginFunctionOptionalConfigDefinition<"featureFlags", {
976
+ pluginConfiguration: import("@atlaskit/editor-common/types").FeatureFlags;
977
+ sharedState: import("@atlaskit/editor-common/types").FeatureFlags;
978
+ }, import("@atlaskit/editor-common/types").FeatureFlags>>
979
+ ];
980
+ sharedState: import("@atlaskit/editor-plugin-type-ahead").TypeAheadPluginSharedState;
981
+ actions: {
982
+ isOpen: (editorState: import("prosemirror-state").EditorState) => boolean;
983
+ isAllowed: (editorState: import("prosemirror-state").EditorState) => boolean;
984
+ insert: (props: {
985
+ triggerHandler: import("@atlaskit/editor-common/types").TypeAheadHandler;
986
+ contentItem: import("@atlaskit/editor-common/types").TypeAheadItem;
987
+ query: string;
988
+ sourceListItem: import("@atlaskit/editor-common/types").TypeAheadItem[];
989
+ mode?: import("@atlaskit/editor-common/type-ahead").SelectItemMode | undefined;
990
+ }) => boolean;
991
+ findHandlerByTrigger: (trigger: string) => import("@atlaskit/editor-common/types").TypeAheadHandler | null;
992
+ open: (props: {
993
+ triggerHandler: import("@atlaskit/editor-common/types").TypeAheadHandler;
994
+ inputMethod: import("@atlaskit/editor-plugin-type-ahead").TypeAheadInputMethod;
995
+ query?: string | undefined;
996
+ }) => boolean;
997
+ close: (props: {
998
+ insertCurrentQueryAsRawText: boolean;
999
+ attachCommand?: import("@atlaskit/editor-common/types").Command | undefined;
1000
+ }) => boolean;
1001
+ openAtTransaction: (props: {
1002
+ triggerHandler: import("@atlaskit/editor-common/types").TypeAheadHandler;
1003
+ inputMethod: import("@atlaskit/editor-plugin-type-ahead").TypeAheadInputMethod;
1004
+ query?: string | undefined;
1005
+ }) => (tr: import("prosemirror-state").Transaction) => boolean;
1006
+ };
1007
+ }, import("@atlaskit/editor-plugin-type-ahead").TypeAheadPluginOptions | undefined>,
1008
+ import("@atlaskit/editor-common/types").OptionalPlugin<import("@atlaskit/editor-common/types").NextEditorPluginFunctionOptionalConfigDefinition<"contextIdentifier", {
1009
+ pluginConfiguration: import("@atlaskit/editor-plugin-context-identifier").PluginConfiguration | undefined;
1010
+ sharedState: import("@atlaskit/editor-plugin-context-identifier").ContextIdentifierConfiguration | undefined;
1011
+ commands: {
1012
+ setProvider: (config: import("@atlaskit/editor-plugin-context-identifier").ContextIdentifierConfiguration) => import("@atlaskit/editor-common/types").EditorCommand;
1013
+ };
1014
+ }, import("@atlaskit/editor-plugin-context-identifier").PluginConfiguration | undefined>>
1015
+ ];
1016
+ sharedState: import("@atlaskit/editor-plugin-mentions").MentionSharedState | undefined;
1017
+ actions: {
1018
+ openTypeAhead: (inputMethod: import("@atlaskit/editor-plugin-type-ahead").TypeAheadInputMethod) => boolean;
1019
+ announceMentionsInsertion: (mentionIds: {
1020
+ localId: string;
1021
+ id: string;
1022
+ }[]) => void;
1023
+ };
1024
+ }, import("@atlaskit/editor-plugin-mentions").MentionPluginOptions | undefined>>
939
1025
  ];
940
1026
  sharedState: {
941
1027
  lastContentPasted: import("@atlaskit/editor-plugin-paste").LastContentPasted | null;
@@ -2813,6 +2899,10 @@ export declare function createUniversalPreset({ props, prevProps, initialPluginC
2813
2899
  sharedState: import("@atlaskit/editor-plugin-mentions").MentionSharedState | undefined;
2814
2900
  actions: {
2815
2901
  openTypeAhead: (inputMethod: import("@atlaskit/editor-plugin-type-ahead").TypeAheadInputMethod) => boolean;
2902
+ announceMentionsInsertion: (mentionIds: {
2903
+ localId: string;
2904
+ id: string;
2905
+ }[]) => void;
2816
2906
  };
2817
2907
  }, import("@atlaskit/editor-plugin-mentions").MentionPluginOptions | undefined> | undefined,
2818
2908
  import("@atlaskit/editor-common/types").NextEditorPluginFunctionOptionalConfigDefinition<"caption", {
@@ -6127,7 +6217,93 @@ export declare function createUniversalPreset({ props, prevProps, initialPluginC
6127
6217
  setInlineCommentDraftState: (drafting: boolean, inputMethod: import("@atlaskit/editor-plugin-annotation").InlineCommentInputMethod, targetType?: import("@atlaskit/editor-plugin-annotation").TargetType | undefined, isCommentOnMediaOn?: boolean | undefined, targetNodeId?: string | undefined) => import("@atlaskit/editor-common/types").Command;
6128
6218
  showCommentForBlockNode: (node: import("prosemirror-model").Node | null, viewMethod?: import("@atlaskit/editor-common/analytics").VIEW_METHOD | undefined) => import("@atlaskit/editor-common/types").Command;
6129
6219
  };
6130
- }, import("@atlaskit/editor-plugin-annotation").AnnotationProviders | undefined>>
6220
+ }, import("@atlaskit/editor-plugin-annotation").AnnotationProviders | undefined>>,
6221
+ import("@atlaskit/editor-common/types").OptionalPlugin<import("@atlaskit/editor-common/types").NextEditorPluginFunctionOptionalConfigDefinition<"mention", {
6222
+ pluginConfiguration: import("@atlaskit/editor-plugin-mentions").MentionPluginOptions | undefined;
6223
+ dependencies: [
6224
+ import("@atlaskit/editor-common/types").OptionalPlugin<import("@atlaskit/editor-common/types").NextEditorPluginFunctionOptionalConfigDefinition<"analytics", {
6225
+ pluginConfiguration: import("@atlaskit/editor-plugin-analytics").AnalyticsPluginOptions;
6226
+ sharedState: {
6227
+ createAnalyticsEvent: import("@atlaskit/analytics-next").CreateUIAnalyticsEvent | null;
6228
+ attachAnalyticsEvent: import("@atlaskit/editor-plugin-analytics").CreateAttachPayloadIntoTransaction | null;
6229
+ performanceTracking: import("@atlaskit/editor-common/types").PerformanceTracking | undefined;
6230
+ };
6231
+ dependencies: [
6232
+ import("@atlaskit/editor-common/types").OptionalPlugin<import("@atlaskit/editor-common/types").NextEditorPluginFunctionOptionalConfigDefinition<"featureFlags", {
6233
+ pluginConfiguration: import("@atlaskit/editor-common/types").FeatureFlags;
6234
+ sharedState: import("@atlaskit/editor-common/types").FeatureFlags;
6235
+ }, import("@atlaskit/editor-common/types").FeatureFlags>>
6236
+ ];
6237
+ actions: import("@atlaskit/editor-common/analytics").EditorAnalyticsAPI;
6238
+ }, import("@atlaskit/editor-plugin-analytics").AnalyticsPluginOptions>>,
6239
+ import("@atlaskit/editor-common/types").NextEditorPluginFunctionOptionalConfigDefinition<"typeAhead", {
6240
+ pluginConfiguration: import("@atlaskit/editor-plugin-type-ahead").TypeAheadPluginOptions | undefined;
6241
+ dependencies: [
6242
+ import("@atlaskit/editor-common/types").OptionalPlugin<import("@atlaskit/editor-common/types").NextEditorPluginFunctionOptionalConfigDefinition<"analytics", {
6243
+ pluginConfiguration: import("@atlaskit/editor-plugin-analytics").AnalyticsPluginOptions;
6244
+ sharedState: {
6245
+ createAnalyticsEvent: import("@atlaskit/analytics-next").CreateUIAnalyticsEvent | null;
6246
+ attachAnalyticsEvent: import("@atlaskit/editor-plugin-analytics").CreateAttachPayloadIntoTransaction | null;
6247
+ performanceTracking: import("@atlaskit/editor-common/types").PerformanceTracking | undefined;
6248
+ };
6249
+ dependencies: [
6250
+ import("@atlaskit/editor-common/types").OptionalPlugin<import("@atlaskit/editor-common/types").NextEditorPluginFunctionOptionalConfigDefinition<"featureFlags", {
6251
+ pluginConfiguration: import("@atlaskit/editor-common/types").FeatureFlags;
6252
+ sharedState: import("@atlaskit/editor-common/types").FeatureFlags;
6253
+ }, import("@atlaskit/editor-common/types").FeatureFlags>>
6254
+ ];
6255
+ actions: import("@atlaskit/editor-common/analytics").EditorAnalyticsAPI;
6256
+ }, import("@atlaskit/editor-plugin-analytics").AnalyticsPluginOptions>>,
6257
+ import("@atlaskit/editor-common/types").OptionalPlugin<import("@atlaskit/editor-common/types").NextEditorPluginFunctionOptionalConfigDefinition<"featureFlags", {
6258
+ pluginConfiguration: import("@atlaskit/editor-common/types").FeatureFlags;
6259
+ sharedState: import("@atlaskit/editor-common/types").FeatureFlags;
6260
+ }, import("@atlaskit/editor-common/types").FeatureFlags>>
6261
+ ];
6262
+ sharedState: import("@atlaskit/editor-plugin-type-ahead").TypeAheadPluginSharedState;
6263
+ actions: {
6264
+ isOpen: (editorState: import("prosemirror-state").EditorState) => boolean;
6265
+ isAllowed: (editorState: import("prosemirror-state").EditorState) => boolean;
6266
+ insert: (props: {
6267
+ triggerHandler: import("@atlaskit/editor-common/types").TypeAheadHandler;
6268
+ contentItem: import("@atlaskit/editor-common/types").TypeAheadItem;
6269
+ query: string;
6270
+ sourceListItem: import("@atlaskit/editor-common/types").TypeAheadItem[];
6271
+ mode?: import("@atlaskit/editor-common/type-ahead").SelectItemMode | undefined;
6272
+ }) => boolean;
6273
+ findHandlerByTrigger: (trigger: string) => import("@atlaskit/editor-common/types").TypeAheadHandler | null;
6274
+ open: (props: {
6275
+ triggerHandler: import("@atlaskit/editor-common/types").TypeAheadHandler;
6276
+ inputMethod: import("@atlaskit/editor-plugin-type-ahead").TypeAheadInputMethod;
6277
+ query?: string | undefined;
6278
+ }) => boolean;
6279
+ close: (props: {
6280
+ insertCurrentQueryAsRawText: boolean;
6281
+ attachCommand?: import("@atlaskit/editor-common/types").Command | undefined;
6282
+ }) => boolean;
6283
+ openAtTransaction: (props: {
6284
+ triggerHandler: import("@atlaskit/editor-common/types").TypeAheadHandler;
6285
+ inputMethod: import("@atlaskit/editor-plugin-type-ahead").TypeAheadInputMethod;
6286
+ query?: string | undefined;
6287
+ }) => (tr: import("prosemirror-state").Transaction) => boolean;
6288
+ };
6289
+ }, import("@atlaskit/editor-plugin-type-ahead").TypeAheadPluginOptions | undefined>,
6290
+ import("@atlaskit/editor-common/types").OptionalPlugin<import("@atlaskit/editor-common/types").NextEditorPluginFunctionOptionalConfigDefinition<"contextIdentifier", {
6291
+ pluginConfiguration: import("@atlaskit/editor-plugin-context-identifier").PluginConfiguration | undefined;
6292
+ sharedState: import("@atlaskit/editor-plugin-context-identifier").ContextIdentifierConfiguration | undefined;
6293
+ commands: {
6294
+ setProvider: (config: import("@atlaskit/editor-plugin-context-identifier").ContextIdentifierConfiguration) => import("@atlaskit/editor-common/types").EditorCommand;
6295
+ };
6296
+ }, import("@atlaskit/editor-plugin-context-identifier").PluginConfiguration | undefined>>
6297
+ ];
6298
+ sharedState: import("@atlaskit/editor-plugin-mentions").MentionSharedState | undefined;
6299
+ actions: {
6300
+ openTypeAhead: (inputMethod: import("@atlaskit/editor-plugin-type-ahead").TypeAheadInputMethod) => boolean;
6301
+ announceMentionsInsertion: (mentionIds: {
6302
+ localId: string;
6303
+ id: string;
6304
+ }[]) => void;
6305
+ };
6306
+ }, import("@atlaskit/editor-plugin-mentions").MentionPluginOptions | undefined>>
6131
6307
  ];
6132
6308
  sharedState: {
6133
6309
  lastContentPasted: import("@atlaskit/editor-plugin-paste").LastContentPasted | null;
@@ -1,4 +1,6 @@
1
1
  import type { IntlShape } from 'react-intl-next';
2
+ import type { DispatchAnalyticsEvent } from '@atlaskit/editor-common/analytics';
3
+ import { type PortalProviderAPI } from '@atlaskit/editor-common/portal';
2
4
  import type { ProviderFactory } from '@atlaskit/editor-common/provider-factory';
3
5
  import type { SafePlugin } from '@atlaskit/editor-common/safe-plugin';
4
6
  import type { ReactHookFactory, UIComponentFactory } from '@atlaskit/editor-common/types';
@@ -15,9 +17,9 @@ export type LightPMPluginFactoryParams = {
15
17
  providerFactory: ProviderFactory;
16
18
  props: {};
17
19
  prevProps?: {};
18
- portalProviderAPI: any;
20
+ portalProviderAPI: PortalProviderAPI;
19
21
  reactContext: () => EditorReactContext;
20
- dispatchAnalyticsEvent: any;
22
+ dispatchAnalyticsEvent: DispatchAnalyticsEvent;
21
23
  featureFlags: FeatureFlags;
22
24
  getIntl: () => IntlShape;
23
25
  };