Add album title #8
This commit is contained in:
+9
-1
@@ -49,9 +49,17 @@ class Render {
|
||||
}
|
||||
res.render('gallery', {
|
||||
items,
|
||||
openItem
|
||||
openItem,
|
||||
title: this.title(share)
|
||||
})
|
||||
}
|
||||
|
||||
/**
|
||||
* Attempt to get a title from the link description or the album title
|
||||
*/
|
||||
title (share: SharedLink) {
|
||||
return share.description || share?.album?.albumName || ''
|
||||
}
|
||||
}
|
||||
|
||||
const render = new Render()
|
||||
|
||||
@@ -14,9 +14,11 @@ export interface Asset {
|
||||
export interface SharedLink {
|
||||
key: string;
|
||||
type: string;
|
||||
description?: string;
|
||||
assets: Asset[];
|
||||
album?: {
|
||||
id: string;
|
||||
albumName?: string;
|
||||
}
|
||||
expiresAt: string | null;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user