-
Notifications
You must be signed in to change notification settings - Fork 12
Expand file tree
/
Copy pathfireworks.d.ts
More file actions
36 lines (32 loc) · 748 Bytes
/
fireworks.d.ts
File metadata and controls
36 lines (32 loc) · 748 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
declare type Point = {
x: number
y: number
}
declare class Fireworks {
constructor(container: HTMLElement, options?: Fireworks.FireworksOptions)
destroy(): void
start(): () => void
stop(): void
kill(): void
fire(): void
update(): void
setSize(width: number, height: number): void
resetSize(): void
onFinish(cb: () => void): void
}
declare namespace Fireworks {
export type FireworksOptions = {
maxRockets?: number
numParticles?: number
explosionMinHeight?: number
explosionMaxHeight?: number
explosionChance?: number
rocketSpawnInterval?: number
rocketInitialPoint?: number
cannons?: Point[]
width?: number
height?: number
}
}
export = Fireworks
export as namespace Fireworks