@atlaskit/editor-plugin-block-controls
Version:
Block controls plugin for @atlaskit/editor-core
33 lines (32 loc) • 1.44 kB
TypeScript
/**
* @jsxRuntime classic
* @jsx jsx
*/
import { jsx } from '@emotion/react';
import type { IntlShape } from 'react-intl';
import type { ExtractInjectionAPI } from '@atlaskit/editor-common/types';
import type { EditorView } from '@atlaskit/editor-prosemirror/view';
import type { BlockControlsPlugin } from '../blockControlsPluginType';
import type { AnchorRectCache } from '../pm-plugins/utils/anchor-utils';
type Props = {
anchorName: string;
anchorRectCache?: AnchorRectCache;
api: ExtractInjectionAPI<BlockControlsPlugin>;
formatMessage: IntlShape['formatMessage'];
getPos: () => number | undefined;
nodeType: string;
rootAnchorName?: string;
rootNodeType: string;
view: EditorView;
};
/**
* Legacy widget-decoration Quick Insert implementation.
*
* Its behavior is intentionally duplicated by the registry-backed control in
* `editor-plugin-quick-insert`. Remove this implementation when
* `platform_editor_block_control_migration` is cleaned up; until then this path remains unchanged
* for users outside the experiment.
*/
export declare const TypeAheadControl: ({ view, api, formatMessage, getPos, anchorName, rootAnchorName, rootNodeType, anchorRectCache, }: Props) => jsx.JSX.Element;
export declare const QuickInsertWithVisibility: ({ view, api, formatMessage, getPos, nodeType, anchorName, rootAnchorName, rootNodeType, anchorRectCache, }: Props) => jsx.JSX.Element;
export {};