Related in spirit to this feature request, I would like to be able to target elements of the topic map through CSS.
This is another place where CSS can’t individually target elements:
The elements in this section are not uniquely accessible.
If anybody would find this helpful, I made the following changes to topic-map.hbs:
<section {{bind-attr class=":map mapCollapsed"}}>
<ul class="clearfix">
<li class='topic-map-created'>
<a href='{{unbound topic.url}}'>
<h4>{{i18n 'created_lowercase'}}</h4>
{{avatar details.created_by imageSize="tiny"}}
{{format-date topic.created_at}}
</a>
</li>
<li class='topic-map-lastpost'>
<a {{bind-attr href="topic.lastPostUrl"}}>
<h4>{{i18n 'last_reply_lowercase'}}</h4>
{{avatar details.last_poster imageSize="tiny"}}
{{format-date topic.last_posted_at}}
</a>
</li>
<li>
{{number topic.replyCount}}
<h4>{{i18n 'replies_lowercase' count=topic.replyCount}}</h4>
</li>
<li class='secondary topic-map-views'>
{{number topic.views class=topic.viewsHeat}}
<h4>{{i18n 'views_lowercase' count=topic.views}}</h4>
</li>
<li class='secondary topic-map-participants'>
{{number topic.participant_count}}
<h4>{{i18n 'users_lowercase' count=topic.participant_count}}</h4>
</li>
{{#if topic.like_count}}
<li class='secondary topic-map-likes'>
{{number topic.like_count}}
<h4>{{i18n 'likes_lowercase' count=topic.like_count}}</h4>
</li>
{{/if}}
{{#if details.links.length}}
<li class='secondary topic-map-links'>
{{number details.links.length}}
<h4>{{i18n 'links_lowercase' count=details.links.length}}</h4>
</li>
{{/if}}
{{#if showPosterAvatar}}
<li {{bind-attr class=":avatars mapCollapsed::hidden"}}>
{{#each p in details.fewParticipants}}
{{topic-participant participant=p}}
{{/each}}
</li>
{{/if}}
</ul>
</section>
I added a unique class name to each of the elements/list items. This lets you target individual elements in the topic map for styling with CSS.
If the Discourse team finds this useful, I can contribute this change myself, or if anybody else wants to run with it, feel free to take it.
It would be very helpful, as a general development principle, to make sure to add unique classes or ids to HTML elements whenever possible.