kopia lustrzana https://github.com/Tldraw/Tldraw
21 wiersze
572 B
TypeScript
21 wiersze
572 B
TypeScript
import { HistoryEntry } from '@tldraw/store'
|
|
import { TLPageId, TLRecord } from '@tldraw/tlschema'
|
|
import { TLEventInfo } from './event-types'
|
|
|
|
/** @public */
|
|
export interface TLEventMap {
|
|
// Lifecycle / Internal
|
|
mount: []
|
|
'max-shapes': [{ name: string; pageId: TLPageId; count: number }]
|
|
change: [HistoryEntry<TLRecord>]
|
|
crash: [{ error: unknown }]
|
|
'stop-camera-animation': []
|
|
'stop-following': []
|
|
event: [TLEventInfo]
|
|
tick: [number]
|
|
frame: [number]
|
|
}
|
|
|
|
/** @public */
|
|
export type TLEventMapHandler<T extends keyof TLEventMap> = (...args: TLEventMap[T]) => void
|