composebox_typeahead: Replace parentheses around pronouns with comma.

Currently, we show pronouns inside parentheses just after name in
@-mention typeaheads.

This commit changes it by removing parentheses and adding comma if
more info is present after pronouns. The pronouns also have the same
styles as that of the user emails.

Fixes part of zulip#31245.
This commit is contained in:
Pratik Chanda 2024-08-26 22:12:06 +05:30 committed by Tim Abbott
parent 203315958b
commit f3432b731f
2 changed files with 7 additions and 2 deletions

View File

@ -84,17 +84,22 @@
} }
} }
.pronouns,
.autocomplete_secondary { .autocomplete_secondary {
align-self: end; align-self: end;
opacity: 0.8; opacity: 0.8;
font-size: 85%; font-size: 85%;
flex: 1 1 0;
overflow: hidden; overflow: hidden;
text-overflow: ellipsis; text-overflow: ellipsis;
position: relative; position: relative;
top: -1px; top: -1px;
} }
.autocomplete_secondary {
flex: 1 1 0;
}
.active .pronouns,
.active .autocomplete_secondary { .active .autocomplete_secondary {
opacity: 1; opacity: 1;
} }

View File

@ -26,7 +26,7 @@
{{~/if~}} {{~/if~}}
</strong> </strong>
{{~#if has_pronouns}} {{~#if has_pronouns}}
<span class="pronouns">({{pronouns}})</span> <span class="pronouns">{{pronouns}}{{#if (or has_secondary_html has_secondary)}},{{/if}}</span>
{{~/if}} {{~/if}}
{{~#if should_add_guest_user_indicator}} {{~#if should_add_guest_user_indicator}}
<i>({{t 'guest'}})</i> <i>({{t 'guest'}})</i>