mirror of
https://github.com/discourse/discourse.git
synced 2025-03-11 15:35:44 +08:00
UX: Don't display an empty participants section.
This commit is contained in:
parent
4c6a0a4046
commit
657c8a013a
@ -222,10 +222,14 @@ createWidget("topic-map-expanded", {
|
|||||||
},
|
},
|
||||||
|
|
||||||
html(attrs, state) {
|
html(attrs, state) {
|
||||||
const avatars = h("section.avatars.clearfix", [
|
let avatars;
|
||||||
|
|
||||||
|
if (attrs.participants && attrs.participants.length > 0) {
|
||||||
|
avatars = h("section.avatars.clearfix", [
|
||||||
h("h3", I18n.t("topic_map.participants_title")),
|
h("h3", I18n.t("topic_map.participants_title")),
|
||||||
renderParticipants.call(this, attrs.userFilters, attrs.participants)
|
renderParticipants.call(this, attrs.userFilters, attrs.participants)
|
||||||
]);
|
]);
|
||||||
|
}
|
||||||
|
|
||||||
const result = [avatars];
|
const result = [avatars];
|
||||||
if (attrs.topicLinks) {
|
if (attrs.topicLinks) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user