UNPKG

@atlaskit/editor-plugin-panel

Version:

Panel plugin for @atlaskit/editor-core.

18 lines (17 loc) • 1.73 kB
import type { IntlShape } from 'react-intl'; import { PanelType } from '@atlaskit/adf-schema/panel'; import type { EditorAnalyticsAPI } from '@atlaskit/editor-common/analytics/api'; import type ProviderFactory from '@atlaskit/editor-common/provider-factory/provider-factory'; import type { Command } from '@atlaskit/editor-common/types/command'; import type { FloatingToolbarConfig, FloatingToolbarItem } from '@atlaskit/editor-common/types/floating-toolbar'; import type { ExtractInjectionAPI } from '@atlaskit/editor-common/types/next-editor-plugin'; import type { HoverDecorationHandler } from '@atlaskit/editor-plugin-decorations/main'; import type { NodeType } from '@atlaskit/editor-prosemirror/model'; import type { EditorState } from '@atlaskit/editor-prosemirror/state'; import type { PanelPlugin } from '../index'; import type { EmojiInfo, PanelPluginOptions } from '../panelPluginType'; export declare const panelIconMap: { [key in Exclude<PanelType, PanelType.CUSTOM>]: EmojiInfo; }; export declare const getToolbarItems: (formatMessage: IntlShape['formatMessage'], panelNodeType: NodeType, isCustomPanelEnabled: boolean, isCustomPanelEditable: boolean, providerFactory: ProviderFactory, hoverDecoration: HoverDecorationHandler | undefined, editorAnalyticsAPI: EditorAnalyticsAPI | undefined, activePanelType?: string, activePanelColor?: string, activePanelIcon?: string, state?: EditorState, api?: ExtractInjectionAPI<PanelPlugin>) => FloatingToolbarItem<Command>[]; export declare const getToolbarConfig: (state: EditorState, intl: IntlShape, options: PanelPluginOptions | undefined, providerFactory: ProviderFactory, api: ExtractInjectionAPI<PanelPlugin> | undefined) => FloatingToolbarConfig | undefined;