-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathtypes.ts
More file actions
37 lines (32 loc) · 735 Bytes
/
types.ts
File metadata and controls
37 lines (32 loc) · 735 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
37
/**
* @license
* SPDX-License-Identifier: Apache-2.0
*/
export interface Asset {
id: string;
type: 'logo' | 'product';
name: string;
data: string; // Base64
mimeType: string;
}
export interface PlacedLayer {
uid: string; // unique instance id
assetId: string;
x: number; // percentage 0-100
y: number; // percentage 0-100
scale: number; // 1 = 100%
rotation: number;
}
export interface GeneratedMockup {
id: string;
imageUrl: string;
prompt: string;
createdAt: number;
layers?: PlacedLayer[]; // Store layout used
productId?: string;
}
export type AppView = 'dashboard' | 'assets' | 'studio' | 'gallery' | 'try-on';
export interface LoadingState {
isGenerating: boolean;
message: string;
}