diff options
| author | Mohamed Bassem <me@mbassem.com> | 2025-12-25 20:23:48 +0000 |
|---|---|---|
| committer | Mohamed Bassem <me@mbassem.com> | 2025-12-25 20:23:48 +0000 |
| commit | ecb7a710ca7ec22aa3304b8d1f6b603bb60874bc (patch) | |
| tree | 2e6274cd9f021ee7758288bbd6f49c3d098d0937 | |
| parent | 0efffdcc834c43710deecde431c7d50f666f21ba (diff) | |
| download | karakeep-ecb7a710ca7ec22aa3304b8d1f6b603bb60874bc.tar.zst | |
feat: add notes to the bookmark edit dialog
| -rw-r--r-- | apps/web/components/dashboard/bookmarks/EditBookmarkDialog.tsx | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/apps/web/components/dashboard/bookmarks/EditBookmarkDialog.tsx b/apps/web/components/dashboard/bookmarks/EditBookmarkDialog.tsx index 76208158..49d27eaa 100644 --- a/apps/web/components/dashboard/bookmarks/EditBookmarkDialog.tsx +++ b/apps/web/components/dashboard/bookmarks/EditBookmarkDialog.tsx @@ -78,6 +78,7 @@ export function EditBookmarkDialog({ const bookmarkToDefault = (bookmark: ZBookmark) => ({ bookmarkId: bookmark.id, summary: bookmark.summary, + note: bookmark.note === null ? undefined : bookmark.note, title: getBookmarkTitle(bookmark), createdAt: bookmark.createdAt ?? new Date(), // Link specific defaults (only if bookmark is a link) @@ -196,6 +197,26 @@ export function EditBookmarkDialog({ /> )} + { + <FormField + control={form.control} + name="note" + render={({ field }) => ( + <FormItem> + <FormLabel>{t("common.note")}</FormLabel> + <FormControl> + <Textarea + placeholder="Bookmark notes" + {...field} + value={field.value ?? ""} + /> + </FormControl> + <FormMessage /> + </FormItem> + )} + /> + } + {isLink && ( <FormField control={form.control} |
