FEATURE: decorate username in email-group-user-chooser-row

We are allowing plugins to decorate username selector:

1f1aa6a0d8/app/assets/javascripts/discourse/app/lib/plugin-api.js (L1154)

1472e47aae/app/assets/javascripts/discourse/app/templates/user-selector-autocomplete.hbr (L9)

The same decoration can be beneficial for email-group-user-chooser-row. An example use case is to show the icon that a user is on holiday when assigning a user to post/topic.
This commit is contained in:
Krzysztof Kotlarek 2022-01-10 10:12:10 +01:00 committed by Alan Guo Xiang Tan
parent ab2c17236a
commit 22249806a8
1 changed files with 1 additions and 0 deletions

View File

@ -2,6 +2,7 @@
{{avatar item imageSize="tiny"}}
<span class="identifier">{{format-username item.id}}</span>
<span class="name">{{item.name}}</span>
{{decorate-username-selector item.id}}
{{else if item.isGroup}}
{{d-icon "users"}}
<span class="identifier">{{item.id}}</span>