diff --git a/src/pages/catchup.jsx b/src/pages/catchup.jsx index 72081c0d..f2336be1 100644 --- a/src/pages/catchup.jsx +++ b/src/pages/catchup.jsx @@ -32,12 +32,12 @@ import { oklab2rgb, rgb2oklab } from '../utils/color-utils'; import db from '../utils/db'; import emojifyText from '../utils/emojify-text'; import { isFiltered } from '../utils/filters'; -import getHTMLText from '../utils/getHTMLText'; import htmlContentLength from '../utils/html-content-length'; import niceDateTime from '../utils/nice-date-time'; import shortenNumber from '../utils/shorten-number'; import showToast from '../utils/show-toast'; import states, { statusKey } from '../utils/states'; +import statusPeek from '../utils/status-peek'; import store from '../utils/store'; import { getCurrentAccountNS } from '../utils/store-utils'; import { assignFollowedTags } from '../utils/timeline-utils'; @@ -1484,7 +1484,7 @@ function PostPeek({ post, filterInfo }) { const isThread = (inReplyToId && inReplyToAccountId === account.id) || !!_thread; const showMedia = !spoilerText && !sensitive; - const postText = content ? getHTMLText(content) : ''; + const postText = content ? statusPeek(post) : ''; return (
@@ -1518,19 +1518,27 @@ function PostPeek({ post, filterInfo }) { Thread{' '} )} - {content ? ( + {!!content && (
- ) : mediaAttachments?.length === 1 && - mediaAttachments[0].description ? ( - <> - ALT{' '} -
{mediaAttachments[0].description}
- - ) : null} + )} + {!!poll?.options?.length && + poll.options.map((o) => ( +
+ {poll.multiple ? '▪️' : '•'} {o.title} +
+ ))} + {!content && + mediaAttachments?.length === 1 && + mediaAttachments[0].description && ( + <> + ALT{' '} +
{mediaAttachments[0].description}
+ + )}
)} diff --git a/src/utils/status-peek.jsx b/src/utils/status-peek.jsx index 6d9bd3ff..9a9388e4 100644 --- a/src/utils/status-peek.jsx +++ b/src/utils/status-peek.jsx @@ -9,8 +9,10 @@ function statusPeek(status) { text += getHTMLText(content); } text = text.trim(); - if (poll) { - text += ' 📊'; + if (poll?.options?.length) { + text += `\n\n📊:\n${poll.options + .map((o) => `${poll.multiple ? '▪️' : '•'} ${o.title}`) + .join('\n')}`; } if (mediaAttachments?.length) { text +=