@atlaskit/editor-plugin-block-controls 13.3.2 → 13.3.3

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 CHANGED
@@ -1,5 +1,11 @@
1
1
  # @atlaskit/editor-plugin-block-controls
2
2
 
3
+ ## 13.3.3
4
+
5
+ ### Patch Changes
6
+
7
+ - Updated dependencies
8
+
3
9
  ## 13.3.2
4
10
 
5
11
  ### Patch Changes
@@ -1,5 +1,5 @@
1
1
  import type { IntlShape } from 'react-intl';
2
2
  import { type Command, type EditorCommand, type ExtractInjectionAPI, DIRECTION } from '@atlaskit/editor-common/types';
3
3
  import type { BlockControlsPlugin, MoveNodeMethod } from '../blockControlsPluginType';
4
- export declare const moveNodeViaShortcut: (api: ExtractInjectionAPI<BlockControlsPlugin> | undefined, direction: DIRECTION, formatMessage?: IntlShape["formatMessage"]) => Command;
5
- export declare const moveNode: (api?: ExtractInjectionAPI<BlockControlsPlugin>) => (start: number, to: number, inputMethod?: MoveNodeMethod, formatMessage?: IntlShape["formatMessage"]) => EditorCommand;
4
+ export declare const moveNodeViaShortcut: (api: ExtractInjectionAPI<BlockControlsPlugin> | undefined, direction: DIRECTION, formatMessage?: IntlShape['formatMessage']) => Command;
5
+ export declare const moveNode: (api?: ExtractInjectionAPI<BlockControlsPlugin>) => (start: number, to: number, inputMethod?: MoveNodeMethod, formatMessage?: IntlShape['formatMessage']) => EditorCommand;
@@ -7,7 +7,7 @@ import type { Decoration } from '@atlaskit/editor-prosemirror/view';
7
7
  import type { ActiveDropTargetNode, ActiveNode, BlockControlsPlugin } from '../blockControlsPluginType';
8
8
  import type { AnchorRectCache } from './utils/anchor-utils';
9
9
  export declare const canMoveNodeOrSliceToPos: (state: EditorState, node: PMNode, parent: PMNode, index: number, $toPos: ResolvedPos, activeNode?: ActiveNode) => boolean | null;
10
- export declare const getActiveDropTargetDecorations: (activeDropTargetNode: ActiveDropTargetNode, state: EditorState, api: ExtractInjectionAPI<BlockControlsPlugin>, existingDecs: Decoration[], formatMessage: IntlShape["formatMessage"], nodeViewPortalProviderAPI: PortalProviderAPI, activeNode?: ActiveNode, anchorRectCache?: AnchorRectCache) => {
10
+ export declare const getActiveDropTargetDecorations: (activeDropTargetNode: ActiveDropTargetNode, state: EditorState, api: ExtractInjectionAPI<BlockControlsPlugin>, existingDecs: Decoration[], formatMessage: IntlShape['formatMessage'], nodeViewPortalProviderAPI: PortalProviderAPI, activeNode?: ActiveNode, anchorRectCache?: AnchorRectCache) => {
11
11
  decsToAdd: Decoration[];
12
12
  decsToRemove: Decoration[];
13
13
  };
@@ -16,6 +16,6 @@ import type { AnchorRectCache } from './utils/anchor-utils';
16
16
  * @returns
17
17
  */
18
18
  export declare const findDropTargetDecs: (decorations: DecorationSet, from?: number, to?: number) => Decoration[];
19
- export declare const createDropTargetDecoration: (pos: number, props: Omit<DropTargetProps, "getPos">, nodeViewPortalProviderAPI: PortalProviderAPI, side?: number, anchorRectCache?: AnchorRectCache, isSameLayout?: boolean) => Decoration;
20
- export declare const createLayoutDropTargetDecoration: (pos: number, props: Omit<DropTargetLayoutProps, "getPos">, nodeViewPortalProviderAPI: PortalProviderAPI, anchorRectCache?: AnchorRectCache) => Decoration;
21
- export declare const dropTargetDecorations: (newState: EditorState, api: ExtractInjectionAPI<BlockControlsPlugin>, formatMessage: IntlShape["formatMessage"], nodeViewPortalProviderAPI: PortalProviderAPI, activeNode?: ActiveNode, anchorRectCache?: AnchorRectCache, from?: number, to?: number) => Decoration[];
19
+ export declare const createDropTargetDecoration: (pos: number, props: Omit<DropTargetProps, 'getPos'>, nodeViewPortalProviderAPI: PortalProviderAPI, side?: number, anchorRectCache?: AnchorRectCache, isSameLayout?: boolean) => Decoration;
20
+ export declare const createLayoutDropTargetDecoration: (pos: number, props: Omit<DropTargetLayoutProps, 'getPos'>, nodeViewPortalProviderAPI: PortalProviderAPI, anchorRectCache?: AnchorRectCache) => Decoration;
21
+ export declare const dropTargetDecorations: (newState: EditorState, api: ExtractInjectionAPI<BlockControlsPlugin>, formatMessage: IntlShape['formatMessage'], nodeViewPortalProviderAPI: PortalProviderAPI, activeNode?: ActiveNode, anchorRectCache?: AnchorRectCache, from?: number, to?: number) => Decoration[];
@@ -3,5 +3,5 @@ export declare const stopEditing: (view: EditorView) => void;
3
3
  export declare const startEditing: (view: EditorView) => void;
4
4
  export declare const mouseLeave: (view: EditorView) => void;
5
5
  export declare const mouseEnter: (view: EditorView) => void;
6
- export declare const setHoverSide: (view: EditorView, side: "left" | "right") => void;
6
+ export declare const setHoverSide: (view: EditorView, side: 'left' | 'right') => void;
7
7
  export declare const clearHoverSide: (view: EditorView) => void;
@@ -12,7 +12,7 @@ export interface FlagType {
12
12
  toolbarFlagsEnabled: boolean;
13
13
  }
14
14
  export declare const getDecorations: (state: EditorState) => DecorationSet | undefined;
15
- export declare const apply: (api: ExtractInjectionAPI<BlockControlsPlugin> | undefined, formatMessage: IntlShape["formatMessage"], tr: ReadonlyTransaction, currentState: PluginState, newState: EditorState, flags: FlagType, nodeViewPortalProviderAPI: PortalProviderAPI, nodeDecorationRegistry: NodeDecorationFactory[], rightSideControlsEnabled?: boolean, quickInsertButtonEnabled?: boolean, anchorRectCache?: AnchorRectCache, resizeObserverWidth?: ResizeObserver, pragmaticCleanup?: (() => void) | null) => PluginState | {
15
+ export declare const apply: (api: ExtractInjectionAPI<BlockControlsPlugin> | undefined, formatMessage: IntlShape['formatMessage'], tr: ReadonlyTransaction, currentState: PluginState, newState: EditorState, flags: FlagType, nodeViewPortalProviderAPI: PortalProviderAPI, nodeDecorationRegistry: NodeDecorationFactory[], rightSideControlsEnabled?: boolean, quickInsertButtonEnabled?: boolean, anchorRectCache?: AnchorRectCache, resizeObserverWidth?: ResizeObserver, pragmaticCleanup?: (() => void) | null) => PluginState | {
16
16
  activeDropTargetNode: ActiveDropTargetNode | undefined;
17
17
  activeNode: any;
18
18
  blockMenuOptions: {
@@ -39,7 +39,7 @@ export declare const QUICK_INSERT_DIMENSIONS: {
39
39
  export declare const QUICK_INSERT_LEFT_OFFSET = 16;
40
40
  export declare const dragHandleGap: (nodeType: string, parentNodeType?: string) => number;
41
41
  export declare const rootElementGap: (nodeType: string) => number;
42
- export declare const getNestedNodeLeftPaddingMargin: (nodeType?: string) => "24px" | "8px" | "16px" | "20px" | "28px" | "40px";
42
+ export declare const getNestedNodeLeftPaddingMargin: (nodeType?: string) => '24px' | '8px' | '16px' | '20px' | '28px' | '40px';
43
43
  export declare const topPositionAdjustment: (nodeType: string, layout?: string) => number;
44
44
  export declare const dropTargetMarginMap: {
45
45
  [key: number]: string;
@@ -3,5 +3,5 @@ import type { AnchorRectCache } from '../pm-plugins/utils/anchor-utils';
3
3
  import type { DropTargetProps } from './drop-target';
4
4
  export declare const InlineDropTarget: ({ api, nextNode, position, anchorRectCache, getPos, }: DropTargetProps & {
5
5
  anchorRectCache?: AnchorRectCache;
6
- position: "left" | "right";
6
+ position: 'left' | 'right';
7
7
  }) => jsx.JSX.Element;
@@ -1,5 +1,5 @@
1
1
  export declare const NODE_ANCHOR_ATTR_NAME = "data-node-anchor";
2
2
  export declare const NODE_NODE_TYPE_ATTR_NAME = "data-prosemirror-node-name";
3
- export declare const getAnchorAttrName: () => "data-drag-handler-anchor-name" | "data-node-anchor";
4
- export declare const getTypeNameAttrName: () => "data-drag-handler-node-type" | "data-prosemirror-node-name";
3
+ export declare const getAnchorAttrName: () => 'data-drag-handler-anchor-name' | 'data-node-anchor';
4
+ export declare const getTypeNameAttrName: () => 'data-drag-handler-node-type' | 'data-prosemirror-node-name';
5
5
  export declare const getTypeNameFromDom: (element?: Element | null) => string;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atlaskit/editor-plugin-block-controls",
3
- "version": "13.3.2",
3
+ "version": "13.3.3",
4
4
  "description": "Block controls plugin for @atlaskit/editor-core",
5
5
  "author": "Atlassian Pty Ltd",
6
6
  "license": "Apache-2.0",
@@ -48,9 +48,9 @@
48
48
  "@atlaskit/pragmatic-drag-and-drop-react-drop-indicator": "^4.1.0",
49
49
  "@atlaskit/primitives": "^22.2.0",
50
50
  "@atlaskit/theme": "^26.1.0",
51
- "@atlaskit/tmp-editor-statsig": "^134.0.0",
51
+ "@atlaskit/tmp-editor-statsig": "^135.0.0",
52
52
  "@atlaskit/tokens": "^16.3.0",
53
- "@atlaskit/tooltip": "^23.1.0",
53
+ "@atlaskit/tooltip": "^23.2.0",
54
54
  "@babel/runtime": "^7.0.0",
55
55
  "@emotion/react": "^11.7.1",
56
56
  "bind-event-listener": "^3.0.0",
@@ -59,7 +59,7 @@
59
59
  "uuid": "^3.1.0"
60
60
  },
61
61
  "peerDependencies": {
62
- "@atlaskit/editor-common": "^116.40.0",
62
+ "@atlaskit/editor-common": "^116.41.0",
63
63
  "react": "^18.2.0",
64
64
  "react-dom": "^18.2.0",
65
65
  "react-intl": "^5.25.1 || ^6.0.0 || ^7.0.0"