Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Handle user-group renames in rendering @-mentions #1259

Open
gnprice opened this issue Jan 7, 2025 · 0 comments
Open

Handle user-group renames in rendering @-mentions #1259

gnprice opened this issue Jan 7, 2025 · 0 comments
Labels
a-content Parsing and rendering Zulip HTML content, notably message contents
Milestone

Comments

@gnprice
Copy link
Member

gnprice commented Jan 7, 2025

Currently we render @-mentions of user groups using the group's name as recorded in the HTML. If the mentioned group has been renamed since the message was sent (or was last edited), this will be its old name. Instead, we should show the mentioned group's current name.

To do this we'll use the mentioned group's ID, which is also encoded in the HTML of the @-mention. Then we can look that up in our user-groups data, once we have that (#662). If the group is unknown, we can fall back to the name that's in the HTML.

This behavior is specified in docs just written today: https://zulip.com/api/message-formatting#mentions (or maybe this link; added in zulip/zulip@3aa2671), but I believe it's been the web app's behavior for a long time.

Related issues

@gnprice gnprice added the a-content Parsing and rendering Zulip HTML content, notably message contents label Jan 7, 2025
@gnprice gnprice added this to the M7: Future milestone Jan 7, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
a-content Parsing and rendering Zulip HTML content, notably message contents
Projects
Status: No status
Development

No branches or pull requests

1 participant