Use "escaped" mentions without notification to create user directories

Our community should be able to create directories about which people could be contacted for what reason.

The implementation should be as user-friendly as possible so that non-technical people can easily add or change information.

I’m hoping to make use of the benefits of the mentions-UI, like (a) opening the search box after typing @ and (b) linking to the user card from this entry, but without sending a notification to every listed user.

Currently I use [User Name](/u/login) without any of the above features.

I was thinking about something like

  • [user-directory] … a lot of mentions in Tables … [/user-directory]
  • [user]login[/user]
  • some kind of escaped @@login

How could this be realized?

2 Likes

I’ve used this before and it seems to work: Firepup650
Raw:

<a class="mention" href="/u/firepup650">Firepup650</a>

Do note that opening in a new tab references the href, vs clicking on the mention itself has different behavior, EX: Firepup650
Raw:

<a class="mention" href="/u/thoka">Firepup650</a>
3 Likes
https://meta.discourse.org/u/thoka

https://meta.discourse.org/u/Firepup650

https://meta.discourse.org/u/Heliosurge
1 Like

That works too, but it doesn’t provide the user-card UI on click (which is what I inferred the OP wanted).

2 Likes

Re reading the the Op statement. They mention contact. So it might even be a simple url to send a pm/dm by clicking on a username in a list as well.

ie

Support Team List
Clickable members names that starts a pm/dm fir a particular user clicked.


However your solution would be more eloquent as the user could see full card and choose to message or chat. So your method demoed seems like best solution.

1 Like

Would making a category that had notifications set to default-ignore and putting the directory into that category suit?

4 Likes

Great idea.
The disadvantage would be that conversations about the directory (metacommunication) would then not be announced.

1 Like

Hm. This is the cooked version of @Firepup650, and, to my understanding of the source code, should fire notifications.

Second: both versions link to your profile.
Your second example was meant to open my user card?

My current way of thinking is to add [user-directory][/user-directory] , remove generated mentions inside via

and change the shown usernames to full names in addition.

I forgot to describe an additional requirement: allow non-techies to add / change information easily.
This makes the use of raw HTML not suitable.

Currently I use handwritten [Thomas Kalka](/u/thoka).
This should be understandable by a medium experienced forum user.

Another approach would be to write a plugin which changes user full names in topics with a #user-directory tag into these links.

I’ve tried it before, and I don’t think it should. To be sure, here’s one: thoka

They only both link to my user card if you just click on them. If you instead copy the link they point to, the first is my profile, the second is yours.