From c4e801852fef03348d098c2df85c7c066a555235 Mon Sep 17 00:00:00 2001 From: Penar Musaraj Date: Fri, 4 Jun 2021 13:28:18 -0400 Subject: [PATCH] A11Y: Improve topic details toggle button label (#13287) --- app/assets/javascripts/discourse/app/widgets/topic-map.js | 4 +++- config/locales/client.en.yml | 3 ++- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/app/assets/javascripts/discourse/app/widgets/topic-map.js b/app/assets/javascripts/discourse/app/widgets/topic-map.js index 5db917edc74..7427717a801 100644 --- a/app/assets/javascripts/discourse/app/widgets/topic-map.js +++ b/app/assets/javascripts/discourse/app/widgets/topic-map.js @@ -246,7 +246,9 @@ createWidget("topic-map-summary", { const nav = h( "nav.buttons", this.attach("button", { - title: "topic.toggle_information", + title: state.collapsed + ? "topic.expand_details" + : "topic.collapse_details", icon: state.collapsed ? "chevron-down" : "chevron-up", action: "toggleMap", className: "btn", diff --git a/config/locales/client.en.yml b/config/locales/client.en.yml index d11b7600869..518ded4e2cc 100644 --- a/config/locales/client.en.yml +++ b/config/locales/client.en.yml @@ -2471,7 +2471,8 @@ en: back_to_list: "Back to Topic List" options: "Topic Options" show_links: "show links within this topic" - toggle_information: "toggle topic details" + collapse_details: "collapse topic details" + expand_details: "expand topic details" read_more_in_category: "Want to read more? Browse other topics in %{catLink} or %{latestLink}." read_more: "Want to read more? %{catLink} or %{latestLink}." unread_indicator: "No member has read the last post of this topic yet."