-
Notifications
You must be signed in to change notification settings - Fork 83
Labels
Description
Quick summary
In some of the ActivityPub representations, we display mentions as <a rel="mention" class="u-url mention" href="https://instance.tld/@example">@<span>example</span></a>. In others, we display the full account name: <a rel="mention" class="u-url mention" href="https://instance.tld/@example">@example@instance.tld</a>. It would be nice if we were consistent in all our implementations.
Similarly, in some situations we include the mention in the ActivityPub representation, but not on the site.
References
| return \sprintf( '<a rel="mention" class="u-url mention" href="%s">@<span>%s</span></a>', esc_url( $url ), esc_html( $username ) ); |
wordpress-activitypub/includes/transformer/class-comment.php
Lines 124 to 126 in a920b1d
| foreach ( $this->extract_reply_context() as $acct => $url ) { | |
| $mentions .= sprintf( | |
| '<a rel="mention" class="u-url mention" href="%s">%s</a> ', |
Steps to reproduce
- Write a new post, where you'll mention someone:
@pfefferle@mastodon.social hello there.- On the site, the mention will be displayed as
<a rel="mention" class="u-url mention" href="https://mastodon.social/@pfefferle">@<span>pfefferle</span></a>
- On the site, the mention will be displayed as
- Have that person reply to you ; their reply will appear as a comment.
- From your site's frontend, reply to them ; do not include any mention in the body of your comment.
- You will not see any mention in the comment displayed on your site
- The ActivityPub representation, however, will display
<a rel="mention" class="u-url mention" href="https://mastodon.social/@pfefferle">@pfefferle@mastodon.social</a>
Site owner impact
Between 20% and 60% of the total website/platform users
Severity
Minor
What other impact(s) does this issue have?
No revenue impact
If a workaround is available, please outline it here.
It would be nice if:
- When a mention is included in the ActivityPub representation, it should also be visible on the site.
- All mentions follow the same standard display. imo it should be
<a rel="mention" class="u-url mention" href="https://mastodon.social/@pfefferle">@<span>pfefferle</span></a>, where the instance name is not displayed. This is the standard in use on Mastodon for example.