From 99324e9e4018c3dbd7a90ffe53261f2b78aecadf Mon Sep 17 00:00:00 2001 From: Surya Shukla Date: Thu, 7 Dec 2023 17:07:05 +0530 Subject: [PATCH 1/3] issue number 2074 resolved --- .../contentcuration/frontend/shared/views/LanguageDropdown.vue | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/contentcuration/contentcuration/frontend/shared/views/LanguageDropdown.vue b/contentcuration/contentcuration/frontend/shared/views/LanguageDropdown.vue index c2af3b154e..a94930393d 100644 --- a/contentcuration/contentcuration/frontend/shared/views/LanguageDropdown.vue +++ b/contentcuration/contentcuration/frontend/shared/views/LanguageDropdown.vue @@ -106,7 +106,7 @@ }, methods: { languageText(item) { - return this.$tr('languageItemText', { language: item.native_name, code: item.id }); + return this.$tr('languageItemText', { language: item.first_native_name, code: item.id }); }, }, $trs: { From eb36e5fc8c614c4e84624e4f7921c96320fff168 Mon Sep 17 00:00:00 2001 From: Surya Shukla Date: Wed, 13 Dec 2023 00:20:04 +0530 Subject: [PATCH 2/3] changes as suggested by the maintainers --- .../contentcuration/frontend/shared/views/LanguageDropdown.vue | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/contentcuration/contentcuration/frontend/shared/views/LanguageDropdown.vue b/contentcuration/contentcuration/frontend/shared/views/LanguageDropdown.vue index a94930393d..1a95aed4e6 100644 --- a/contentcuration/contentcuration/frontend/shared/views/LanguageDropdown.vue +++ b/contentcuration/contentcuration/frontend/shared/views/LanguageDropdown.vue @@ -106,7 +106,8 @@ }, methods: { languageText(item) { - return this.$tr('languageItemText', { language: item.first_native_name, code: item.id }); + const firstNativeName = item.native_name.split(',')[0].trim() + return this.$tr('languageItemText', { language: firstNativeName, code: item.id }); }, }, $trs: { From 9bafc01b2393844db047b8645ad20c2a714990ce Mon Sep 17 00:00:00 2001 From: Surya Shukla Date: Sun, 17 Dec 2023 08:18:23 +0530 Subject: [PATCH 3/3] lint test --- .../contentcuration/frontend/shared/views/LanguageDropdown.vue | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/contentcuration/contentcuration/frontend/shared/views/LanguageDropdown.vue b/contentcuration/contentcuration/frontend/shared/views/LanguageDropdown.vue index 1a95aed4e6..02a1075f18 100644 --- a/contentcuration/contentcuration/frontend/shared/views/LanguageDropdown.vue +++ b/contentcuration/contentcuration/frontend/shared/views/LanguageDropdown.vue @@ -106,7 +106,7 @@ }, methods: { languageText(item) { - const firstNativeName = item.native_name.split(',')[0].trim() + const firstNativeName = item.native_name.split(',')[0].trim(); return this.$tr('languageItemText', { language: firstNativeName, code: item.id }); }, },