fix(messaging): render markdown and tappable mention/channel chips together#106
Merged
Conversation
…gether Message content previously fell back to an inline-span renderer whenever a chip-eligible token was present, which silently dropped all markdown (so `**bold**` showed its literal asterisks) and rendered mention/channel pills that weren't tappable. Re-implement Accord's inline tokens (`@user`/`@role`/`@everyone`/`#channel` chips, custom `:emoji:`, `||spoiler||`, `__underline__`) as markdown_viewer syntax extensions + element builders so they render *alongside* the standard markdown stack instead of replacing it. Mention/channel chips are now wired to open the member popout / focus the channel tab. - Promote dart_markdown + source_span to direct deps (define custom syntaxes). - Add accord_message_markup.dart: AccordMarkupContext + buildAccordMarkup(). - Forward syntaxExtensions/elementBuilders through AccordMarkdownBox. - Rewrite AccordMessageContent to always use the markdown box and resolve handles against the space's caches. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
krazyjakee
added a commit
that referenced
this pull request
Jun 10, 2026
… markup, resizable channel column & space settings (#100) * feat(channels): add channel & category context menus Long-press (touch) and right-click (onSecondaryTap, desktop) on a channel row or category header now open a context menu, mirroring the existing space-rail menu pattern. - Channel menu: Mark as read (when unread), Mute/Unmute (server-side via client.channels.mute/unmute), and — with manage_channels — Edit and Delete. - Category menu: Expand/Collapse, and — with manage_channels — Create channel here, Edit, and Delete. Reuses the existing edit/create dialogs and the header bell's mute pattern; factors the delete confirmation into a shared confirmAndDeleteChannel helper. Threads canManageChannels/spaceId into _ChannelTile and _CategoryHeader (the latter is now a ConsumerWidget). Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com> * feat(ui): resizable channel column, anchored context menus, message actions & two-column space settings - Resizable left channel column with width persisted across restarts (new channelListWidth setting + drag handle) - Hover tooltip on message timestamps showing full date/time - Mobile/desktop message actions menu via long-press / right-click, with multi-select demoted to a menu entry - Shared showAccordContextMenu helper: anchored popups on desktop, bottom sheets on touch, applied across spaces/folders/members/ channels/categories - Two-column space settings layout on desktop, single column on mobile Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com> * fix(messaging): use server-keyed read-state provider in mention tap The markup channel-mention tap was kept from #106 during the master merge, but #100 keys readStateControllerProvider by serverKey. Pass the active key and refresh codegen so the family signature resolves. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com> --------- Co-authored-by: Claude Opus 4.7 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
**bold**showed literal asterisks) and rendered mention/channel pills that weren't tappable.@user/@role/@everyone/#channelchips, custom:emoji:,||spoiler||,__underline__) asmarkdown_viewersyntax extensions + element builders, so they render alongside the standard markdown stack instead of replacing it.Changes
pubspec.yaml— promotedart_markdown+source_spanfrom transitive to direct deps so message rendering can define custom inline syntaxes.accord_message_markup.dart(new) —AccordMarkupContext+buildAccordMarkup(): five inline syntaxes/builders plus the tappable chip / emoji-image / spoiler widgets. Unresolved#channel/@handletokens (and email-likeemail@host) stay plain text.accord_markdown_box.dart— forwardsyntaxExtensions/elementBuildersthrough toMarkdownViewer.accord_message_content.dart— rewritten to always use the markdown box, resolving handles against the space's member/role/channel/emoji caches and wiring the tap callbacks.Notes
Test plan
flutter analyze --no-fatal-infos— clean (only pre-existing infos in unrelated files)flutter test— 132/132 pass, including 3 new widget tests intest/features/messaging/accord_message_markup_test.dart:#channelchip render together; the chip is tappable@everyonechips whileemail@hoststays plain text#channelstays plain text (no chip)🤖 Generated with Claude Code