Skip to content

Commit

Permalink
fix(item): center content if no desc
Browse files Browse the repository at this point in the history
Signed-off-by: Innei <i@innei.in>
  • Loading branch information
Innei committed Sep 16, 2024
1 parent aff559a commit 18e26a4
Showing 1 changed file with 11 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -70,13 +70,20 @@ export function Component() {
target="_blank"
>
<FeedIcon fallback feed={subscription.feeds} size={22} className="mr-3" />
<div className={cn("w-0 flex-1 grow", "group-hover:grow-[0.85]")}>
<div
className={cn(
"flex w-0 flex-1 grow flex-col justify-center",
"group-hover:grow-[0.85]",
)}
>
<div className="truncate font-medium leading-none">
{subscription.feeds?.title}
</div>
<div className="mt-1 line-clamp-1 text-xs text-zinc-500">
{subscription.feeds?.description}
</div>
{subscription.feeds?.description && (
<div className="mt-1 line-clamp-1 text-xs text-zinc-500">
{subscription.feeds.description}
</div>
)}
</div>
</a>
<span className="center absolute inset-y-0 right-0 opacity-0 transition-opacity group-hover:opacity-100">
Expand Down

0 comments on commit 18e26a4

Please sign in to comment.