@blockly/keyboard-navigation
Version:
A plugin for keyboard navigation.
39 lines • 1.15 kB
TypeScript
/**
* @license
* Copyright 2025 Google LLC
* SPDX-License-Identifier: Apache-2.0
*/
import { BlockSvg, WorkspaceSvg } from 'blockly';
import { Mover } from './mover';
/**
* Actions for moving blocks with keyboard shortcuts.
*/
export declare class MoveActions {
private mover;
constructor(mover: Mover);
private shortcutNames;
private menuItemNames;
private registerShortcuts;
private registerMenuItems;
/**
* Install the actions as both keyboard shortcuts and (where
* applicable) context menu items.
*/
install(): void;
/**
* Uninstall these actions.
*/
uninstall(): void;
/**
* Get the source block for the cursor location, or undefined if no
* source block can be found.
* If the cursor is on a shadow block, walks up the tree until it finds
* a non-shadow block to drag.
*
* @param workspace The workspace to inspect for a cursor.
* @returns The source block, or undefined if no appropriate block
* could be found.
*/
getCurrentBlock(workspace: WorkspaceSvg): BlockSvg | undefined;
}
//# sourceMappingURL=move.d.ts.map