Skip to content

feat: Posts composer — free text, @mention (incl. @all), multi-opportunity picker, emoji picker #961

Description

@arturasmckwcz

Context

Base composer for the Posts page rebuild (fe#892 updated per prototype proposal + amendment). Not blocked on any new backend work — uses the existing POST /post endpoint (be#680).

Scope

  • Textarea composer, anchored at the bottom of the feed (per the amendment — supersedes feat: Posts page — NGO/Coordinator feed with posting, @mention tagging, and linking own opportunities #892's original top-composer assumption)
  • Same composer component is reused for replies (see feat: threaded replies UI — inline replies, grouped replies-to-replies, collapsed older replies #964) — switches into reply mode showing the target's author, timestamp, and original-message context
  • @mention: reuse Autocomplete/useCommentTag from the Comments section (no rebuild) — live suggestions as the user types @, including a special @all entry, used consistently; mentions insert at the current cursor position, including into existing or pasted text
  • Opportunity linking: search-driven picker, multiple opportunities selectable per post (the Post entity's linkedOpportunities is already a m2m, so no BE change needed here). Picker stays open while selecting, closes via a "Done" action or on leaving it; selected opportunities shown as removable chips
  • Emoji picker inserted directly into the composer (amendment added this on top of the original proposal)
  • useCreatePost hook wrapping useMutationQuery, POSTing to /post

Acceptance criteria

  • Composer sits at the bottom of the feed
  • Typing @ surfaces user suggestions incl. @all; selecting one tags them; mentions insert at the cursor position, including into existing/pasted text
  • Multiple opportunities can be attached via a picker that stays open during selection and closes on "Done" or on leaving it; selections shown as removable chips
  • Emoji picker inserts an emoji into the composer text
  • Submitting creates a post via POST /post and it appears in the feed

Part of Epic: #969 (see Round 3 corrections, 2026-09-01, points 1, 7, 8)

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions