import p5 from 'p5'; import { Component } from './Component'; import { InputManager } from './InputManager'; import type { Class } from '../types/class'; import type { DropFirst } from '../types/dropFirst'; import { ExtendedP5 } from './ExtendedP5'; type CanvasColor = { r: number; g: number; b: number; a?: number; }; export interface SketchOptions { divId?: string; fullscreen?: boolean; canvasColor?: CanvasColor | null; size: { w: number | string | (() => number); h: number | string | (() => number); }; } interface SketchClass extends Partial> { addComponent: >(component: T, ...args: DropFirst>) => InstanceType; sketch: ExtendedP5; options: SketchOptions; inputManager: InputManager; } export declare class Sketch implements SketchClass { sketch: ExtendedP5; options: SketchOptions; inputManager: InputManager; constructor(sketch: (p: p5) => void, options?: Partial); addComponent>(component: T, ...args: DropFirst>): InstanceType; private initialiseFunctions; private onWindowResize; private setCanvasColor; } export {};