|
|
|
|
@ -1,5 +1,4 @@
@@ -1,5 +1,4 @@
|
|
|
|
|
import { Card, CardContent, CardHeader } from '@/components/ui/card' |
|
|
|
|
import { Button } from '@/components/ui/button' |
|
|
|
|
import { Badge } from '@/components/ui/badge' |
|
|
|
|
import { Clock, Hash, Server } from 'lucide-react' |
|
|
|
|
import { NostrEvent } from 'nostr-tools' |
|
|
|
|
@ -69,7 +68,8 @@ export default function ThreadCard({ thread, onThreadClick, className }: ThreadC
@@ -69,7 +68,8 @@ export default function ThreadCard({ thread, onThreadClick, className }: ThreadC
|
|
|
|
|
onClick={onThreadClick} |
|
|
|
|
> |
|
|
|
|
<CardHeader className="pb-3"> |
|
|
|
|
<div className="flex items-start gap-3"> |
|
|
|
|
<div className="flex items-start justify-between gap-3"> |
|
|
|
|
<div className="flex items-start gap-3 flex-1 min-w-0"> |
|
|
|
|
<VoteButtons event={thread} /> |
|
|
|
|
<div className="flex-1 min-w-0"> |
|
|
|
|
<div className="flex items-center gap-2 mb-2"> |
|
|
|
|
@ -95,15 +95,7 @@ export default function ThreadCard({ thread, onThreadClick, className }: ThreadC
@@ -95,15 +95,7 @@ export default function ThreadCard({ thread, onThreadClick, className }: ThreadC
|
|
|
|
|
</div> |
|
|
|
|
</div> |
|
|
|
|
</div> |
|
|
|
|
</CardHeader> |
|
|
|
|
|
|
|
|
|
<CardContent className="pt-0"> |
|
|
|
|
<div className="text-sm text-muted-foreground leading-relaxed"> |
|
|
|
|
{contentPreview} |
|
|
|
|
</div> |
|
|
|
|
|
|
|
|
|
<div className="flex items-center justify-between mt-3 pt-3 border-t"> |
|
|
|
|
<div className="flex items-center gap-2 text-sm text-muted-foreground"> |
|
|
|
|
<div className="flex items-center gap-2 text-sm text-muted-foreground shrink-0"> |
|
|
|
|
<UserAvatar userId={thread.pubkey} size="xSmall" /> |
|
|
|
|
<Username
|
|
|
|
|
userId={thread.pubkey}
|
|
|
|
|
@ -111,9 +103,12 @@ export default function ThreadCard({ thread, onThreadClick, className }: ThreadC
@@ -111,9 +103,12 @@ export default function ThreadCard({ thread, onThreadClick, className }: ThreadC
|
|
|
|
|
skeletonClassName="h-4 w-20" |
|
|
|
|
/> |
|
|
|
|
</div> |
|
|
|
|
<Button variant="ghost" size="sm" className="h-8 px-2"> |
|
|
|
|
{t('Read more')} |
|
|
|
|
</Button> |
|
|
|
|
</div> |
|
|
|
|
</CardHeader> |
|
|
|
|
|
|
|
|
|
<CardContent className="pt-0"> |
|
|
|
|
<div className="text-sm text-muted-foreground leading-relaxed"> |
|
|
|
|
{contentPreview} |
|
|
|
|
</div> |
|
|
|
|
</CardContent> |
|
|
|
|
</Card> |
|
|
|
|
|