-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathtypes.ts
More file actions
27 lines (24 loc) · 793 Bytes
/
types.ts
File metadata and controls
27 lines (24 loc) · 793 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
export type Point3D = {
x: number;
y: number;
z: number;
};
export type ShapeType = 'SPHERE' | 'HEART' | 'FLOWER' | 'SATURN' | 'ZEN' | 'FIREWORKS' | 'AI_GENERATED';
export interface ParticleState {
expansion: number; // Controlled by hand distance
isHandsDetected: boolean;
gravityPoint: { x: number; y: number } | null; // Controlled by pinch
}
export interface AppState {
currentShape: ShapeType;
particleColor: string;
particleCount: number;
aiPrompt: string;
isGenerating: boolean;
aiShapeCode: string | null; // Stored function body for AI shapes
setShape: (shape: ShapeType) => void;
setColor: (color: string) => void;
setAiPrompt: (prompt: string) => void;
setGenerating: (loading: boolean) => void;
setAiShapeCode: (code: string | null) => void;
}