diff options
Diffstat (limited to 'viewer/src/@types')
-rw-r--r-- | viewer/src/@types/gallery/index.d.ts | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/viewer/src/@types/gallery/index.d.ts b/viewer/src/@types/gallery/index.d.ts index 2dd11fb..b47c812 100644 --- a/viewer/src/@types/gallery/index.d.ts +++ b/viewer/src/@types/gallery/index.d.ts | |||
@@ -1,4 +1,10 @@ | |||
1 | declare namespace Gallery { | 1 | declare namespace Gallery { |
2 | interface Image extends Item { | ||
3 | properties: ImageProperties, | ||
4 | } | ||
5 | interface Directory extends Item { | ||
6 | properties: DirectoryProperties, | ||
7 | } | ||
2 | interface Item { | 8 | interface Item { |
3 | title: string, | 9 | title: string, |
4 | date: string, | 10 | date: string, |
@@ -8,9 +14,9 @@ declare namespace Gallery { | |||
8 | thumbnail: { | 14 | thumbnail: { |
9 | path: string, | 15 | path: string, |
10 | }, | 16 | }, |
11 | properties: Image | Directory, | 17 | properties: ImageProperties | DirectoryProperties, |
12 | } | 18 | } |
13 | interface Image { | 19 | interface ImageProperties { |
14 | type: "image", | 20 | type: "image", |
15 | filesize: number, | 21 | filesize: number, |
16 | resolution: { | 22 | resolution: { |
@@ -18,7 +24,7 @@ declare namespace Gallery { | |||
18 | height: number, | 24 | height: number, |
19 | } | 25 | } |
20 | } | 26 | } |
21 | interface Directory { | 27 | interface DirectoryProperties { |
22 | type: "directory", | 28 | type: "directory", |
23 | items: Item[] | 29 | items: Item[] |
24 | } | 30 | } |