import { Workspace, Block } from '@kano/kwc-blockly/blockly.js';
import { IDisposable } from '@kano/common/index.js';
export declare function onDidCreateBlockType(workspace: Workspace, type: string, cb: (e: any) => void): IDisposable;
/**
 * Walk a Block tree upwards. Returns null if reached the top. Returns whatever non-false value the visitor returned
 * @param block A blockly block
 * @param cb A function that will be called on every block up the tree. Return false to continue walking
 */
export declare function walkUpstream<T>(block: Block, cb: (block: Block) => T | false): T | null;
