feat(wormhole): Jump to replied message button on relayed replies #4

Merged
everestmcarthur merged 1 commit from feat/enhanced-reply-buttons into main 2026-05-14 11:15:39 -04:00
everestmcarthur commented 2026-05-14 11:14:42 -04:00 (Migrated from github.com)

What changed

When a reply is relayed across servers, each copy now includes a "↩ Jump to replied message" URL button underneath the quoted reply text.

Smart per-server linking

  • If the referenced message has a relayed copy in the target channel → button links to the local copy (user stays in their own server)
  • If no local copy exists → falls back to the original message URL

How it works

  1. When a reply is detected, the code looks up the referenced message in msg_map to find all relayed copies across channels
  2. For each relay target, it builds a discord.ui.View with a single URL button pointing to the best available message link
  3. The view is passed to wh.send() / ch.send() in all relay modes (webhook, embed, compact)

URL buttons (ButtonStyle.link) work natively with webhooks — no persistent interaction handler needed.

Non-reply messages

When a message is not a reply, no button is added — behavior is unchanged.

Version bump: 3.4.2 → 3.4.3

## What changed When a reply is relayed across servers, each copy now includes a **"↩ Jump to replied message"** URL button underneath the quoted reply text. ### Smart per-server linking - If the referenced message has a relayed copy in the target channel → button links to the **local copy** (user stays in their own server) - If no local copy exists → falls back to the **original message URL** ### How it works 1. When a reply is detected, the code looks up the referenced message in `msg_map` to find all relayed copies across channels 2. For each relay target, it builds a `discord.ui.View` with a single URL button pointing to the best available message link 3. The view is passed to `wh.send()` / `ch.send()` in all relay modes (webhook, embed, compact) URL buttons (`ButtonStyle.link`) work natively with webhooks — no persistent interaction handler needed. ### Non-reply messages When a message is not a reply, no button is added — behavior is unchanged. **Version bump:** 3.4.2 → 3.4.3
Sign in to join this conversation.
No description provided.