diff options
| author | MohamedBassem <me@mbassem.com> | 2024-02-29 12:50:42 +0000 |
|---|---|---|
| committer | MohamedBassem <me@mbassem.com> | 2024-02-29 12:50:42 +0000 |
| commit | f8cef28758a2b331a8acad499dfbd92e9794fcc5 (patch) | |
| tree | ef3104dcd96294f2f6f0cd681ef3dfcaadd05b60 /packages/web/app/dashboard/bookmarks/components/TextCard.tsx | |
| parent | 045c09bed91170920b33eaecfef9a6a49a4ec4ad (diff) | |
| download | karakeep-f8cef28758a2b331a8acad499dfbd92e9794fcc5.tar.zst | |
fix: Fix the look of the grid view and allowing notes to have variable size
Diffstat (limited to 'packages/web/app/dashboard/bookmarks/components/TextCard.tsx')
| -rw-r--r-- | packages/web/app/dashboard/bookmarks/components/TextCard.tsx | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/packages/web/app/dashboard/bookmarks/components/TextCard.tsx b/packages/web/app/dashboard/bookmarks/components/TextCard.tsx index 1d3fad3a..29d22352 100644 --- a/packages/web/app/dashboard/bookmarks/components/TextCard.tsx +++ b/packages/web/app/dashboard/bookmarks/components/TextCard.tsx @@ -32,8 +32,6 @@ export default function TextCard({ throw new Error("Unexpected bookmark type"); } - const numWords = bookmarkedText.text.split(" ").length; - return ( <> <BookmarkedTextViewer @@ -45,15 +43,14 @@ export default function TextCard({ className={cn( className, cn( - "flex flex-col gap-y-1 overflow-hidden rounded-lg p-2 shadow-md", - numWords > 12 ? "row-span-2 h-96" : "row-span-1 h-40", + "flex h-min max-h-96 flex-col gap-y-1 overflow-hidden rounded-lg p-2 shadow-md", ), )} > <Markdown className="prose grow overflow-hidden"> {bookmarkedText.text} </Markdown> - <div className="flex flex-none flex-wrap gap-1 overflow-hidden"> + <div className="mt-4 flex flex-none flex-wrap gap-1 overflow-hidden"> <TagList bookmark={bookmark} /> </div> <div className="flex w-full justify-between"> |
