mirror of
https://github.com/discourse/discourse.git
synced 2025-02-25 18:55:32 -06:00
UX: gives aria-label to topics count in category-row (#7307)
This commit is contained in:
parent
e77b1cf7ff
commit
d8dd130477
@ -75,7 +75,7 @@ export default SelectKitRowComponent.extend({
|
|||||||
"options.countSubcategories"
|
"options.countSubcategories"
|
||||||
)
|
)
|
||||||
topicCount(totalCount, topicCount, countSubcats) {
|
topicCount(totalCount, topicCount, countSubcats) {
|
||||||
return `× ${countSubcats ? totalCount : topicCount}`.htmlSafe();
|
return countSubcats ? totalCount : topicCount;
|
||||||
},
|
},
|
||||||
|
|
||||||
@computed("displayCategoryDescription", "category.description")
|
@computed("displayCategoryDescription", "category.description")
|
||||||
|
@ -5,12 +5,16 @@
|
|||||||
{{badgeForParentCategory}}
|
{{badgeForParentCategory}}
|
||||||
{{/unless}}
|
{{/unless}}
|
||||||
{{badgeForCategory}}
|
{{badgeForCategory}}
|
||||||
<span class="topic-count">{{topicCount}}</span>
|
<span class="topic-count" aria-label={{i18n "category_row.topic_count" count=topicCount}}>
|
||||||
|
× {{topicCount}}
|
||||||
|
</span>
|
||||||
</div>
|
</div>
|
||||||
{{else}}
|
{{else}}
|
||||||
<div class="category-status">
|
<div class="category-status">
|
||||||
{{badgeForCategory}}
|
{{badgeForCategory}}
|
||||||
<span class="topic-count">{{topicCount}}</span>
|
<span class="topic-count" aria-label={{i18n "category_row.topic_count" count=topicCount}}>
|
||||||
|
× {{topicCount}}
|
||||||
|
</span>
|
||||||
</div>
|
</div>
|
||||||
{{/if}}
|
{{/if}}
|
||||||
|
|
||||||
|
@ -1429,6 +1429,9 @@ en:
|
|||||||
conditional_loading_section:
|
conditional_loading_section:
|
||||||
loading: Loading...
|
loading: Loading...
|
||||||
|
|
||||||
|
category_row:
|
||||||
|
topic_count: "{{count}} topics in this category"
|
||||||
|
|
||||||
select_kit:
|
select_kit:
|
||||||
default_header_text: Select...
|
default_header_text: Select...
|
||||||
no_content: No matches found
|
no_content: No matches found
|
||||||
|
Loading…
Reference in New Issue
Block a user