terry-staging #4

Merged
terry merged 2 commits from terry-staging into main 2026-05-27 05:18:47 +00:00
Showing only changes of commit 565784b4bb - Show all commits

View File

@@ -27,11 +27,18 @@ export function MessageBubble({ post }: { post: Post }) {
const { lang } = useI18n(); const { lang } = useI18n();
const Bubble = pickBubble(post); const Bubble = pickBubble(post);
const isTextOnly = post.attachments.length === 0; const isTextOnly = post.attachments.length === 0;
const isVisual = post.attachments.some(
(a) => a.kind === "image" || a.kind === "video",
);
return ( return (
<article <article
id={`post-${post.id}`} id={`post-${post.id}`}
className={`relative mx-auto w-full max-w-[380px] rounded-2xl bg-ark-panel text-left shadow-sm md:max-w-[680px] lg:max-w-[900px] xl:max-w-[1120px] ${isTextOnly ? "px-3 py-2" : "p-2"}`} className={`relative rounded-2xl bg-ark-panel text-left shadow-sm ${
isVisual
? "mx-auto w-full max-w-[380px] md:max-w-[680px] lg:max-w-[900px] xl:max-w-[1120px]"
: "self-start w-fit max-w-[92%] md:max-w-[680px] lg:max-w-[760px] xl:max-w-[820px]"
} ${isTextOnly ? "px-3 py-2" : "p-2"}`}
> >
<Bubble post={post} /> <Bubble post={post} />
<time <time