mirror of
https://github.com/simon987/sist2.git
synced 2025-12-19 02:09:06 +00:00
Rework duration/resolution badge style
This commit is contained in:
@@ -61,6 +61,7 @@ export interface EsHit {
|
||||
isAudio: boolean
|
||||
hasThumbnail: boolean
|
||||
hasVidPreview: boolean
|
||||
imageAspectRatio: number
|
||||
/** Number of thumbnails available */
|
||||
tnNum: number
|
||||
}
|
||||
@@ -155,6 +156,9 @@ class Sist2Api {
|
||||
&& hit._source.videoc !== "raw" && hit._source.videoc !== "ppm") {
|
||||
hit._props.isPlayableImage = true;
|
||||
}
|
||||
if ("width" in hit._source && "height" in hit._source) {
|
||||
hit._props.imageAspectRatio = hit._source.width / hit._source.height;
|
||||
}
|
||||
break;
|
||||
case "video":
|
||||
if ("videoc" in hit._source) {
|
||||
|
||||
Reference in New Issue
Block a user