UNPKG

@atlaskit/editor-plugin-user-intent

Version:

UserIntent plugin for @atlaskit/editor-core

15 lines (14 loc) 579 B
import type { EditorCommand, NextEditorPlugin } from '@atlaskit/editor-common/types'; import type { UserIntent } from './pm-plugins/types'; export type UserIntentPlugin = NextEditorPlugin<'userIntent', { sharedState: { currentUserIntent: UserIntent; } | undefined; commands: { /** * @param newCurrentUserIntent the new current user intent to set - once set it will need to be updated once that intention has changed * @returns */ setCurrentUserIntent: (newCurrentUserIntent: UserIntent) => EditorCommand; }; }>;