Files
gnommoplayer/dist/glitch/glitch_lightlane/hostBridge.d.ts
T
2026-04-11 09:21:22 +02:00

18 lines
1.0 KiB
TypeScript

import type { GlitchHostBridge } from './types';
export declare const HOST_SOUND_EVENT = "glitch:play-sound";
export declare const HOST_STOP_SOUND_EVENT = "glitch:stop-sound";
export declare const HOST_EMIT_PREFIX = "glitch:host:";
export declare const SOUND_IDS: {
readonly click: "ui.button_click";
readonly hover: "ui.button_hover";
readonly computeStart: "machine.compute_start";
readonly computeStep: "machine.compute_step";
readonly computeDone: "machine.compute_done";
readonly verdictStable: "machine.verdict_stable";
readonly verdictAlert: "machine.verdict_alert";
};
export type SoundId = (typeof SOUND_IDS)[keyof typeof SOUND_IDS];
export declare function safePlaySound(host: GlitchHostBridge | undefined, id: string, payload?: Record<string, unknown>): void;
export declare function safeStopSound(host: GlitchHostBridge | undefined, id: string, payload?: Record<string, unknown>): void;
export declare function safeEmit(host: GlitchHostBridge | undefined, type: string, payload?: unknown): void;