diff --git a/LOTUS_TODO.md b/LOTUS_TODO.md index c20a291d6..91ad2d7dc 100644 --- a/LOTUS_TODO.md +++ b/LOTUS_TODO.md @@ -436,14 +436,13 @@ Themes: ## 🚀 Features to Add - [ ] **Mobile Audit:** Comprehensive audit of all features in LOTUS_FEATURES.md for mobile PWA usability and layout responsiveness. -- [ ] **Remind Me Later:** Slack-style reminders for messages (ping user at a set time, add to bookmarks). - - **Root Cause:** Feature does not exist. Reminders require persistence in Matrix account data and a background worker to trigger notifications. - - **Approach:** Expand `useReminders.ts` to include `removeReminder`. Add a "Remind me" menu item to `Message.tsx` that triggers a `DatePicker`/`TimePicker` modal (reusing logic from `JumpToTime.tsx`). Implement a `ReminderMonitor` in `ClientNonUIFeatures.tsx` that polls active reminders from `io.lotus.reminders` and pushes to `toastQueueAtom` in `state/toast.ts` when due. - - **Complexity:** Medium. -- [ ] **Mobile Bookmarks:** Fix visibility issue where bookmarks do not show up when selected via PWA on mobile. - - **Root Cause:** `ClientLayout.tsx` explicitly restricts `BookmarksPanel` rendering to `ScreenSize.Desktop` (lines 51-56). - - **Approach:** Update `ClientLayout.tsx` to remove the `ScreenSize.Desktop` restriction. Pass `isMobile={screenSize !== ScreenSize.Desktop}` to `BookmarksPanel`. `BookmarksPanel.tsx` already supports this prop (line 127) to enable full-screen absolute positioning and reactive layout. - - **Complexity:** Low. +- [x] **Remind Me Later:** Slack-style reminders for messages — fully implemented ⚠️ UNTESTED end-to-end + - **Storage:** `useReminders.ts` — persists to `io.lotus.reminders` account data with `addReminder` / `removeReminder` / `getReminders` + - **UI:** `RemindMeDialog.tsx` — 4 presets (20 min, 1 hr, 3 hr, tomorrow 9am); wired into `Message.tsx` context menu via `remindOpen` state; `useModalStyle(320)` for mobile fullscreen + - **Monitor:** `ReminderMonitor` in `ClientNonUIFeatures.tsx` — polls every 30s + on tab visibility; fires Lotus toast when due and calls `removeReminder` +- [x] **Mobile Bookmarks:** Fixed ⚠️ UNTESTED — bookmarks now accessible from within any room on mobile + - **Root Cause:** `BookmarksPanel` renders correctly on mobile but `BookmarksTab` lives in `SidebarNav`, which is hidden when inside a room on mobile (`MobileFriendlyClientNav` returns `null`). No trigger existed. + - **Fix:** Added "Saved Messages" `MenuItem` to the `RoomMenu` (···More Options) in `RoomViewHeader.tsx`. Toggles `bookmarksPanelAtom` and closes the menu. Works on all screen sizes — desktop users see it as a duplicate of the sidebar star, mobile users now have their only in-room access point. --- diff --git a/src/app/features/room/RoomViewHeader.tsx b/src/app/features/room/RoomViewHeader.tsx index 183fee06a..65c74c4a0 100644 --- a/src/app/features/room/RoomViewHeader.tsx +++ b/src/app/features/room/RoomViewHeader.tsx @@ -74,6 +74,8 @@ import { useLivekitSupport } from '../../hooks/useLivekitSupport'; import { webRTCSupported } from '../../utils/rtc'; import { MediaGallery } from './MediaGallery'; import { usePendingKnocks } from '../../hooks/usePendingKnocks'; +import { useAtom } from 'jotai'; +import { bookmarksPanelAtom } from '../../state/bookmarksPanel'; type RoomMenuProps = { room: Room; @@ -96,6 +98,7 @@ const RoomMenu = forwardRef(({ room, requestClose const [invitePrompt, setInvitePrompt] = useState(false); const [reportRoomOpen, setReportRoomOpen] = useState(false); + const [bookmarksOpen, setBookmarksOpen] = useAtom(bookmarksPanelAtom); const handleMarkAsRead = () => { markAsRead(mx, room.roomId, hideActivity); @@ -169,6 +172,20 @@ const RoomMenu = forwardRef(({ room, requestClose + { + setBookmarksOpen((v) => !v); + requestClose(); + }} + size="300" + after={} + radii="300" + aria-pressed={bookmarksOpen} + > + + Saved Messages + + {!isServerNotice && (