import React__default, { RefObject } from 'react';

type MikuFusionGameStatus = 'ready' | 'playing' | 'paused' | 'gameOver';
type OrbImageMapping = Partial<Record<number, string>>;
interface FusionOrb {
    id: string;
    x: number;
    y: number;
    vx: number;
    vy: number;
    radius: number;
    level: number;
    age: number;
}
interface MikuFusionTheme {
    backgroundTop: string;
    backgroundBottom: string;
    aimLine: string;
    lossLine: string;
    orbColors: string[];
}
interface MikuFusionGameConfig {
    width: number;
    height: number;
    gravity: number;
    damping: number;
    collisionDamping: number;
    spawnY: number;
    lossLineY: number;
    maxLevel: number;
    maxOrbs: number;
    maxMergesPerTick: number;
    gameOverAgeThreshold: number;
    spawnWeights: number[];
    theme: MikuFusionTheme;
}
interface MikuFusionGameCallbacks {
    onScoreChange?: (score: number) => void;
    onGameOver?: (score: number, bestScore: number) => void;
}
interface MergeResult {
    orbs: FusionOrb[];
    scoreGain: number;
    mergeCount: number;
}

interface MikuFusionGameProps extends Partial<MikuFusionGameConfig>, MikuFusionGameCallbacks {
    className?: string;
    storageKey?: string;
    orbImageStorageKey?: string;
    enableImageConfigPanel?: boolean;
    presetOrbImageMapping?: OrbImageMapping;
}
declare function MikuFusionGame({ className, storageKey, orbImageStorageKey, enableImageConfigPanel, presetOrbImageMapping, ...options }: MikuFusionGameProps): React__default.JSX.Element;

interface UseMikuFusionGameOptions extends Partial<MikuFusionGameConfig>, MikuFusionGameCallbacks {
    storageKey?: string;
    orbImageMapping?: OrbImageMapping;
}
interface UseMikuFusionGameResult {
    canvasRef: RefObject<HTMLCanvasElement>;
    status: MikuFusionGameStatus;
    score: number;
    bestScore: number;
    nextLevel: number;
    config: MikuFusionGameConfig;
    setAimFromClientX: (clientX: number, rect: DOMRect) => void;
    handleDrop: (clientX: number, rect: DOMRect) => void;
    togglePause: () => void;
    restart: () => void;
}
declare function useMikuFusionGame(options?: UseMikuFusionGameOptions): UseMikuFusionGameResult;

interface ResponsiveSize {
    displayWidth: number;
    displayHeight: number;
    scale: number;
}
declare function useResponsiveCanvas(logicalWidth: number, logicalHeight: number, containerRef: RefObject<HTMLElement>): ResponsiveSize;

interface ProducerPack {
    id: string;
    name: string;
    passiveDescription: string;
    themeColor?: string;
}
interface SongPack {
    id: string;
    name: string;
    bpm?: number;
    difficultyHint?: string;
}
interface ThemePack {
    id: string;
    name: string;
    orbColors: string[];
    backgroundTop: string;
    backgroundBottom: string;
}
interface MikuFusionContentRegistry {
    producers: ProducerPack[];
    songs: SongPack[];
    themes: ThemePack[];
}

/**
 * 仅作为未来内容包化扩展占位。
 * 当前基础玩法不会消费这些数据。
 */
declare const defaultContentRegistry: MikuFusionContentRegistry;

declare const BASE_RADIUS = 22;
declare const RADIUS_STEP = 4;
declare const LEVEL_LABEL_PREFIX = "M";
declare const DEFAULT_MIKU_FUSION_CONFIG: MikuFusionGameConfig;

export { BASE_RADIUS, DEFAULT_MIKU_FUSION_CONFIG, type FusionOrb, LEVEL_LABEL_PREFIX, type MergeResult, type MikuFusionContentRegistry, MikuFusionGame, type MikuFusionGameCallbacks, type MikuFusionGameConfig, type MikuFusionGameProps, type MikuFusionGameStatus, type MikuFusionTheme, type OrbImageMapping, type ProducerPack, RADIUS_STEP, type SongPack, type ThemePack, type UseMikuFusionGameOptions, type UseMikuFusionGameResult, defaultContentRegistry, useMikuFusionGame, useResponsiveCanvas };
