Commit Graph

17 Commits

Author SHA1 Message Date
Derek Ross 003cc21ade Fix NoteMoreMenu: copy naddr/nevent IDs, add report modal (NIP-56), implement mention action
- Copy Event ID now copies naddr1 for addressable events or nevent1 for
  others, instead of raw hex
- Add ReportDialog component with NIP-56 kind 1984 reporting (7 report
  types, optional details textarea, scrollable on small screens)
- Wire report dialog into both NoteMoreMenu (post reports) and
  ProfileMoreMenu (profile reports)
- Mention action opens compose modal with nostr:npub pre-filled
- Fix dialog lifecycle: report/mention state lives in outer component to
  survive menu unmount
2026-03-03 16:31:41 -05:00
Chad Curtis 8032ac585d Use StickyNote icon for view post details menu item 2026-03-03 05:46:24 -06:00
Chad Curtis fc7f6a45c1 Add 'View post details' option to NoteMoreMenu 2026-03-03 05:43:29 -06:00
Mary Kate Fain f729b07202 Fix NoteMoreMenu dialog overflowing viewport on long posts
Cap the dialog at 85dvh with overflow-y-auto so it scrolls when
content is tall. Also add a hard max-h on the post preview text
to prevent line-clamp-3 failures with nested block elements from
NoteContent.
2026-03-01 14:05:34 -06:00
Chad Curtis 6f5a07c0a9 Render images inline at their position in post content
- Images now render inline via NoteContent at the position of their URL
  rather than collected into a gallery block below the text
- Clicking an inline image opens a full lightbox with navigation across
  all images in the post; lightbox index is tracked by position so
  duplicate URLs open at the correct index
- Removed separate ImageGallery/extractImages from NoteCard,
  PostDetailPage, and ComposeBox to prevent double-rendering
- Added disableEmbeds to NoteMoreMenu clamped preview to avoid block
  embeds inside a line-clamp-3 container
- Fixed hasPreviewableContent in ComposeBox to detect image-only posts
  so the Preview tab appears correctly
- Removed mp3/ogg/wav/pdf from MEDIA_URL_REGEX suppression list; those
  URLs now render as clickable links instead of being silently dropped
- Added avif to IMAGE_URL_REGEX; added cursor-pointer to InlineImage
2026-02-26 04:35:03 -06:00
Chad Curtis ea0f01da98 Optimize profile page load performance and reduce relay queries
- Defer bookmark/pin queries in NoteMoreMenu until menu is opened
- Move RightSidebar outside Suspense to prevent default sidebar queries on profile pages
- Split profile metadata: kind 0 piggybacked on feed query, kind 3+10001 fetched separately
- Share single feed query across posts/replies/media tabs (filter client-side)
- Reduce feed page size from 60 to 15 to match main feed
- Fix pagination using raw event count instead of filtered count
- Remove duplicate pinned events query from usePinnedNotes
- Add staleTime to useMuteList to prevent refetch on every navigation
- Add skeleton loading for banner, avatar, name, and pinned posts
- Stabilize streak calculation to use raw feed data across all tabs
2026-02-22 01:26:47 -06:00
Chad Curtis 900608c265 Add post deletion support (NIP-09) with confirmation dialog and feed filtering 2026-02-21 04:35:47 -06:00
Chad Curtis fe6e2065bc Implement mute user/conversation actions and apply mute filtering across all feeds
Wire up the previously stubbed 'Mute @user' and 'Mute Conversation' menu
actions in NoteMoreMenu and ProfilePage to call useMuteList().addMute,
with toggle support for unmuting. Apply mute filtering (via isEventMuted
from muteHelpers) across all feed surfaces: main feed, profile feed,
notifications, post detail replies, search/explore stream, hashtag page,
domain feed, trending posts, and right sidebar.
2026-02-21 03:57:59 -06:00
Alex Gleason 77ff88c2f6 Render NIP-30 custom emoji in all remaining display name locations
Apply EmojifiedText to mentions inside embedded/quote posts,
embedded note author names, and all other secondary UI locations
where display names were still rendered as plain text.
2026-02-19 21:43:56 -06:00
Alex Gleason 6180bbf0c3 Fix 30 ESLint errors: remove unused imports/variables, replace any types, use const 2026-02-19 20:14:01 -06:00
shakespeare.diy 48a5dedb45 Fix post menu to hide mute/mention/report options on own posts
- Wrapped mute conversation, mention, mute user, and report options with !isOwnPost checks
- Only show these options when viewing someone else's post
- Pin to profile option remains available only on own posts
- Fixes issue where inappropriate moderation options were shown on user's own content

Co-authored-by: shakespeare.diy <assistant@shakespeare.diy>
2026-02-19 06:04:58 -06:00
Chad Curtis 427aa2dab4 Use FileDigit icon for Copy Event ID 2026-02-19 05:30:09 -06:00
Chad Curtis cdf38328d5 Update post detail menu: remove 'View Details', add copy event ID and JSON
- Removed 'Show Post Details' option (redundant on detail page)
- Added 'Copy Event ID' to copy hex event ID
- Added 'Copy Event JSON' to copy full event as formatted JSON
- Replaced ArrowUpDown icon with FileJson for JSON copy option
2026-02-19 05:28:39 -06:00
shakespeare.diy 3dd3511f73 Add following count, following list modal, pinned posts, and pin/unpin menu option
- Created usePinnedNotes hook for NIP-51 kind 10001 pinned notes management
- Created useProfileFollowing hook to fetch any profile's follow list and count
- Added following count (with Users icon) to the left of the post streak on profiles
- Clicking following count opens a scrollable modal listing all followed users
- Pinned posts now display at the top of the Posts tab with a pin indicator
- Added "Pin on profile" / "Unpin from profile" option to the post "..." menu
  (only visible for user's own posts)

Co-authored-by: shakespeare.diy <assistant@shakespeare.diy>
2026-02-17 04:33:05 -06:00
shakespeare.diy 3fa066bd46 Add post detail page with replies and reply composer
- Create PostDetailPage with expanded post view showing author info,
  full content, images, stats (reposts, likes, zap amount), full date,
  action buttons, and inline reply composer
- Create useEvent hook for fetching single events by hex ID
- Create useReplies hook for fetching kind:1 replies to an event
- Update NIP19Page to render PostDetailPage for note1/nevent1 identifiers
- Make NoteCard clickable to navigate to post detail via nevent1 URL
- Fix NoteMoreMenu to use React Router navigate instead of window.location.href

Co-authored-by: shakespeare.diy <assistant@shakespeare.diy>
2026-02-16 21:24:01 -06:00
shakespeare.diy 858ec3beaa Add post preview to More menu, blur modal backdrops, polish compose modal
- NoteMoreMenu now shows a compact post preview at the top (avatar,
  author name, timestamp, and 3-line-clamped content) before menu items
- Dialog overlay updated globally: bg-black/60 + backdrop-blur-sm for a
  frosted-glass effect behind all modals
- FloatingComposeButton modal reworked to match the same presentation
  pattern: rounded-2xl, hidden default close button replaced with a
  centered header (X / "New post" title), separator, compose area

Co-authored-by: shakespeare.diy <assistant@shakespeare.diy>
2026-02-16 17:50:46 -06:00
shakespeare.diy 6e92ff3468 Add More menu dialog to NoteCard (Ditto-style)
- Created NoteMoreMenu component as a centered dialog with grouped actions:
  - Show Post Details, Copy Link to Post, View on njump.me, Bookmark
  - Mute Conversation, Mention @user
  - Mute @user, Report @user (destructive)
  - Close button
- Added the ⋯ More button back to NoteCard action bar alongside Bookmark
- Menu items show the author's display name dynamically
- Copy Link copies nevent-based URL to clipboard with toast feedback
- Bookmark option in the menu toggles bookmark state via useBookmarks hook

Co-authored-by: shakespeare.diy <assistant@shakespeare.diy>
2026-02-16 17:48:48 -06:00