UNPKG

@reactodia/workspace

Version:

Reactodia Workspace -- library for visual interaction with graphs in a form of a diagram.

10 lines 661 B
import * as React from 'react'; import { type HotkeyString } from '../coreUtils/hotkey'; import { type CanvasWidgetDescription } from './canvasApi'; export declare function defineCanvasWidget<P>(type: React.ComponentType<P>, metadataOf: (element: React.ReactElement<P>) => CanvasWidgetDescription): void; export declare function extractCanvasWidget(element: React.ReactElement): CanvasWidgetDescription | undefined; export interface CanvasHotkey { readonly text: string; } export declare function useCanvasHotkey(hotkey: HotkeyString | undefined | null, action: (() => void) | undefined): CanvasHotkey | undefined; //# sourceMappingURL=canvasWidget.d.ts.map