fix(ui): use correct url for timeline image srcset (#296)
parent
d17994338d
commit
2a84bbb3d6
|
@ -9,7 +9,7 @@ const { attachment } = defineProps<{
|
||||||
|
|
||||||
const src = $computed(() => attachment.previewUrl || attachment.url || attachment.remoteUrl!)
|
const src = $computed(() => attachment.previewUrl || attachment.url || attachment.remoteUrl!)
|
||||||
const srcset = $computed(() => [
|
const srcset = $computed(() => [
|
||||||
[src, attachment.meta?.original?.width],
|
[attachment.url, attachment.meta?.original?.width],
|
||||||
[attachment.previewUrl, attachment.meta?.small?.width],
|
[attachment.previewUrl, attachment.meta?.small?.width],
|
||||||
].filter(([url]) => url).map(([url, size]) => `${url} ${size}w`).join(', '))
|
].filter(([url]) => url).map(([url, size]) => `${url} ${size}w`).join(', '))
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue