From 4a392641880f6fc0c4e44cf3e83490ef0445f373 Mon Sep 17 00:00:00 2001 From: Josh Perez <60019601+josh-signal@users.noreply.github.com> Date: Fri, 29 Jul 2022 13:13:01 -0400 Subject: [PATCH] Use video screenshot as background blur in story viewer --- ts/util/getStoryBackground.ts | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/ts/util/getStoryBackground.ts b/ts/util/getStoryBackground.ts index 53fb02dc160..93cd02b2eba 100644 --- a/ts/util/getStoryBackground.ts +++ b/ts/util/getStoryBackground.ts @@ -33,6 +33,10 @@ export function getStoryBackground(attachment?: AttachmentType): string { return getBackgroundColor(attachment.textAttachment); } + if (attachment.screenshot && attachment.screenshot.url) { + return `url("${attachment.screenshot.url}")`; + } + if (attachment.url) { return `url("${attachment.url}")`; }