Skip to content

Commit

Permalink
maxLines -> lineClamp
Browse files Browse the repository at this point in the history
  • Loading branch information
Southclaws committed Dec 10, 2023
1 parent 83f2d90 commit 0670dc0
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 6 deletions.
2 changes: 1 addition & 1 deletion web/src/components/feed/common/PostRef/PostRef.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ export function PostRef({ kind, item }: Props) {
</Heading>
</Flex>

<styled.p maxLines={3}>{data.short}</styled.p>
<styled.p lineClamp={3}>{data.short}</styled.p>

<Flex justifyContent="space-between">
<Byline
Expand Down
2 changes: 1 addition & 1 deletion web/src/components/feed/text/TextPost.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ export function TextPost(props: Props) {
</Heading>
</Flex>

<styled.p maxLines={3}>{props.thread.short}</styled.p>
<styled.p lineClamp={3}>{props.thread.short}</styled.p>

<Flex justifyContent="space-between">
<Byline
Expand Down
6 changes: 2 additions & 4 deletions web/src/components/thread/LinkView/LinkView.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -40,10 +40,8 @@ export function LinkView({ link, asset }: Props) {
{link.title}
</LinkOverlay>
</styled.h2>
<Box maxLines={1} overflow="hidden">
<styled.p maxLines={2} lineClamp={2}>
{link.description}
</styled.p>
<Box lineClamp={1} overflow="hidden">
<styled.p lineClamp={2}>{link.description}</styled.p>
<br />
</Box>
</VStack>
Expand Down

2 comments on commit 0670dc0

@vercel
Copy link

@vercel vercel bot commented on 0670dc0 Dec 10, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@vercel
Copy link

@vercel vercel bot commented on 0670dc0 Dec 10, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.