-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathschema.ts
73 lines (58 loc) · 1.48 KB
/
schema.ts
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
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
export interface BrandingOptions {
appName: string;
appIconsPath: string;
}
export interface Category {
id: string;
name: string;
colors: {
light: string;
dark: string;
};
/** Defaults to `"other"`. */
markerIcon?: string;
parentId?: string;
}
export interface Range {
id: string;
name: string;
description?: string;
/** Defaults to `15`. */
zoom?: number;
/** Defaults to `[11, 18]`. */
zooms?: [number, number];
branding?: Partial<BrandingOptions>;
parentId?: string;
/** Defaults to `false`. */
showChildren?: boolean;
}
export interface Place {
location: [number, number];
name: string;
originalName?: string;
rangeId: Range["id"];
categoryId: Category["id"];
description?: string;
coverImage?: `/images/${string}/cover.${string}`;
signatureDishes?: {
name: string;
originalName?: string;
price?: number;
image: `/images/${string}/${number}.${string}`;
}[];
streetViewUrl?:
| `https://map.baidu.com/#panoid=${string}&panotype=street&heading=${number}&pitch=${number}&l=${number}&psp=%7B%22PanoModule%22%3A%7B%22markerUid%22%3A%22${string}%22%7D%7D`
| `https://map.baidu.com/#panoid=${string}&panotype=street&heading=${number}&pitch=${number}&l=${number}`;
authors?: string | string[];
}
export interface Activity {
id: string;
name: string;
categoryIds?: Category["id"][];
placeLocations?: [number, number][];
vocab?: {
name: string;
chinese: string;
pinyin: string;
}[];
}