Add @mention with deep-link to node detail

Open
#1,242 2 comments 0 reactions 0 assignees View on GitHub

Maintainers usually reply within 1 day

Nobody has claimed this yet.

Assessment

Difficulty
4/5
Estimated time
3-5 days
Newbie friendliness
18/100
Issue type
Feature
Clarity
Mostly clear
Activity status
Quiet
Tech stack
react, typescript
Domain
frontend

Research direction

Start with the send path in packages/sdk/src/features/chat/application/SendTextUseCase.ts to see how outgoing text is built, then the compose input in apps/web/src/pages/Messages.tsx for the @ autocomplete. Received messages render in apps/web/src/components/PageComponents/Messages/MessageItem.tsx, which should parse @!<hex-id> tokens and resolve the current name from the node store. Done when typing @ offers matching nodes, the sent text carries the hex ID, and a received mention links to the node detail page. The self-mention notification rules need agreement with iOS and Android before coding that part.

Written by the indexing model from the issue text.

Description

feature request help wanted parity

What

Per meshtastic/design#21, add @mention support to messaging: typing @ in the compose field should offer an autocomplete of nearby/known nodes (matched by long name, short name, or user ID), and a received message containing a mention should render it as tappable text that deep-links to that node's detail page.

No implementation exists on any platform today — this is a from-scratch feature, not a fix. There's a general tracking issue for messaging improvements at meshtastic/web#280, but nothing specific to @mentions.

Wire format (must match iOS/Android exactly — this is the cross-platform contract)

The message text payload packages a mention as the literal string @!<hex-id> (e.g. @!ffccee11) — the node's numeric ID, hex-encoded, not the display name. This is required so the mention stays valid and correctly resolvable even if the mentioned node's long/short name changes later, and so all three clients parse the exact same wire format regardless of which one composed the message.

Compose side

  • In the message compose input (near apps/web/src/pages/Messages.tsx / wherever the text entry for a conversation lives), detect @ typed in the field and show an autocomplete list of known nodes, filterable by long name, short name, or user ID.
  • On selection, insert @!<hex-id> into the underlying text that gets sent (not the display name) — but the input should still show the friendly name to the user while typing, with the hex form being what actually goes out via the SDK's send-text use case (packages/sdk/src/features/chat/application/SendTextUseCase.ts).

Render side

  • In apps/web/src/components/PageComponents/Messages/MessageItem.tsx (where message text currently renders as a plain whitespace-pre-wrap node — see meshtastic/design#21's audit findings), detect @!<hex-id> tokens and render each as tappable text showing the current display name resolved live from the node store — a name change should update the mention's displayed text without needing to re-send anything; only the hex ID is stable/stored.
  • Clicking a mention should navigate to that node's detail page, consistent with existing node-click navigation elsewhere in the app.

Notification behavior

When the local node's own ID is mentioned in a channel broadcast, that should be treated at least as prominently as a direct message for notification purposes — e.g. still notify even if channel notifications are otherwise muted, since a mention is a targeted ping within an otherwise-broadcast conversation. Coordinate the exact behavior with the iOS/Android implementations so all three treat a self-mention consistently.

Reference

Cross-platform alignment tracking issue: meshtastic/design#21.

Dominant language
TypeScript
Stars
861
Forks
316
Avg merge
2d 10h
Merged PRs (30d)
18

Getting set up

Open in Codespaces

Starts the project's dev container in your browser, under your own GitHub account.

  • No Dockerfile or Docker Compose file
  • Has a pull request template
  • No contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from meshtastic/web

All issues in meshtastic/web

Similar issues

More TypeScript issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.