gameflow-deck/src/mainview/types.d.ts
Simeon Radivoev 813785f4f3
feat: Bundled NW.js with appimages
feat: Implemented self update
feat: Added rclone saves for emulators
fix: Fixed auto focus in builds
feat: Added helper cards on empty library
2026-04-26 03:26:15 +03:00

77 lines
No EOL
1.6 KiB
TypeScript

declare const __HOST__: string;
declare const __PUBLIC__: boolean;
declare const __FLATPAK__: boolean;
declare const __EMULATORS__: Record<string, string>;
declare module "@emulators" {
const data: Record<string, string>;
export default data;
}
declare global
{
module "react" {
interface HTMLAttributes<T> extends AriaAttributes, DOMAttributes<T>
{
// extends React's HTMLAttributes
"save-child-focus"?: SaveFocusType;
"save-scroll"?: boolean;
}
}
module "@noriginmedia/norigin-spatial-navigation" {
declare interface FocusDetails
{
instant?: boolean;
sound?: string;
}
}
module "@tanstack/react-router" {
declare interface HistoryState
{
eventType?: string;
}
}
}
declare interface FocusEventDetails
{
focusKey: string;
instant?: boolean;
sound?: string;
nativeEvent?: any;
event?: Event;
node: HTMLElement | undefined;
focusKeyChanged: boolean;
}
declare interface FocusParams
{
onFocus?: (focusKey: string, node: HTMLElement, details: Record<string, any>) => void;
}
declare interface InteractParamsArgs
{
event?: Event,
focusKey?: string;
}
declare interface InteractParams
{
onAction?: (ctx: InteractParamsArgs) => void;
}
declare interface FilterOption extends FocusParams, InteractParams
{
label: string;
selected: boolean;
icon?: any;
}
declare type EmulatorJsMessage = { type: 'restart'; } |
{ type: 'pause'; paused: boolean; } |
{ type: 'exit'; save?: File; } |
{ type: 'save', save: File, screenshot?: File, type: string; } |
{ type: 'loaded'; } |
{ type: 'requestSave'; };