Skip to content

Commit e123cdb

Browse files
authored
Fix the aria label for search result grid (#4301)
* Fix the aria label for search result grid Signed-off-by: Olga Bulat <obulat@gmail.com> * Add comment Signed-off-by: Olga Bulat <obulat@gmail.com> --------- Signed-off-by: Olga Bulat <obulat@gmail.com>
1 parent 125c65e commit e123cdb

File tree

2 files changed

+11
-1
lines changed

2 files changed

+11
-1
lines changed

frontend/src/components/VSearchResultsGrid/VSearchResults.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -102,7 +102,7 @@ export default defineComponent({
102102
103103
const collectionLabel = computed(() => {
104104
return i18n
105-
.t(`browsePage.aria.results.${props.results.type}`, {
105+
.t(`browsePage.aria.resultsLabel.${props.results.type}`, {
106106
query: props.searchTerm,
107107
})
108108
.toString()

frontend/src/locales/scripts/en.json5

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -685,6 +685,16 @@
685685
creator: "search by creator",
686686
imageTitle: "Image: {title}",
687687
audioTitle: "Audio track: {title}",
688+
/**
689+
* These strings are used as aria-label of the list of the search results.
690+
* The number of results is given in `results.mediaType`, so is not
691+
* needed here.
692+
*/
693+
resultsLabel: {
694+
all: "All results for {query}",
695+
image: "Image results for {query}",
696+
audio: "Audio tracks for {query}",
697+
},
688698
results: {
689699
/**
690700
* "imageResults" and "audioResults" are interpolated from the strings under

0 commit comments

Comments
 (0)