import { EventBus } from '../core/EventBus';
import type { Locale } from '../i18n/I18n';
export interface WizardChoice {
    id: string;
    /** Emoji icon shown to the child. */
    icon: string;
    /** Localized label. */
    label: Record<string, string>;
    /** Localized description (shown on hover / under the button). */
    description: Record<string, string>;
    /** Where this choice leads: 'template' applies a game template, 'wizard-step' goes to another step. */
    action: 'template' | 'wizard-step' | 'tutorial' | 'open-project';
    /** For 'template': template ID to apply. */
    templateId?: string;
    /** For 'wizard-step': next step ID. */
    nextStepId?: string;
    /** For 'tutorial': tutorial ID. */
    tutorialId?: string;
    /** Age group filter (show only for this age range). */
    minAge?: number;
    maxAge?: number;
}
export interface WizardStep {
    id: string;
    /** Localized question/prompt. */
    question: Record<string, string>;
    /** Available choices. */
    choices: WizardChoice[];
    /** Whether to show a "back" button. */
    showBack?: boolean;
}
export interface WizardResult {
    /** All choices made, in order. */
    choicePath: string[];
    /** Final action. */
    finalAction: 'template' | 'tutorial' | 'open-project';
    /** Template ID (if applicable). */
    templateId?: string;
    /** Tutorial ID (if applicable). */
    tutorialId?: string;
}
export declare class GuidedWizard {
    readonly events: EventBus;
    private steps;
    private startStepId;
    private currentStepId;
    private choicePath;
    private locale;
    constructor(locale?: Locale);
    /** Set display locale. */
    setLocale(locale: Locale): void;
    /** Get the current step. */
    getCurrentStep(): WizardStep | undefined;
    /** Get choices for the current step, filtered by age. */
    getChoices(playerAge?: number): WizardChoice[];
    /** Select a choice. Returns a WizardResult if the wizard is complete, null otherwise. */
    select(choiceId: string): WizardResult | null;
    /** Go back to the previous step. */
    back(): void;
    /** Reset wizard to initial state. */
    reset(): void;
    /** Register a custom wizard step. */
    registerStep(step: WizardStep): void;
    /** Get the localized question for the current step. */
    getQuestion(): string;
}
export type BlockShape = 'statement' | 'expression' | 'condition' | 'event' | 'loop';
export interface DragBlock {
    id: string;
    /** The visual block this represents (from KidMode.VISUAL_BLOCKS). */
    blockType: string;
    /** Instance values (filled in by the child). */
    values: Record<string, string | number | boolean>;
    /** Position on the canvas. */
    x: number;
    y: number;
    /** Connected blocks (snap below). */
    nextBlockId?: string;
    /** For conditions/loops: inner blocks. */
    innerBlockId?: string;
    /** Parent block that contains this one. */
    parentBlockId?: string;
}
export interface BlockPalette {
    category: string;
    icon: string;
    label: Record<string, string>;
    blocks: string[];
}
export interface DragDropState {
    /** All blocks on the canvas. */
    blocks: Map<string, DragBlock>;
    /** Currently dragged block ID (or null). */
    dragging: string | null;
    /** Snap preview target (if hovering near a snap point). */
    snapPreview: {
        targetBlockId: string;
        position: 'below' | 'inside';
    } | null;
    /** Currently selected block (for value editing). */
    selected: string | null;
}
export declare class BlockEditor {
    readonly events: EventBus;
    private state;
    private nextBlockId;
    private snapDistance;
    /** Add a new block to the canvas at position (x, y). */
    addBlock(blockType: string, x: number, y: number, values?: Record<string, string | number | boolean>): string;
    /** Remove a block (and unsnap from neighbors). */
    removeBlock(id: string): void;
    /** Start dragging a block. */
    startDrag(id: string): void;
    /** Move the dragged block. */
    moveDrag(x: number, y: number): void;
    /** End dragging — snap if near a target. */
    endDrag(): void;
    /** Select a block for value editing. */
    selectBlock(id: string): void;
    /** Update a block's value. */
    setBlockValue(id: string, key: string, value: string | number | boolean): void;
    /** Get all blocks. */
    getAllBlocks(): DragBlock[];
    /** Get the block chain starting from a root block. */
    getChain(startId: string): DragBlock[];
    /** Get all root blocks (blocks with no parent). */
    getRootBlocks(): DragBlock[];
    /** Convert the block program to a simple code representation. */
    toCode(startId: string, indent?: number): string;
    /** Clear all blocks. */
    clear(): void;
    private findSnapTarget;
    private snapBlock;
}
export declare const KID_BLOCK_PALETTES: BlockPalette[];
