Highlight the search term on no results#28644
Highlight the search term on no results#28644TSI-kavitasonawane wants to merge 2 commits intonextcloud:masterfrom
Conversation
core/src/views/UnifiedSearch.vue
Outdated
|
|
||
| <EmptyContent v-else-if="isValidQuery" icon="icon-search"> | ||
| {{ t('core', 'No results for {query}', {query}) }} | ||
| {{ t('core', 'No results for') }} <strong>{{ t('query', query) }}</strong> |
There was a problem hiding this comment.
This approach might not work with all languages. The query parameter should stay part of the translate t() function so it can be embedded into the translated sentence as needed in the target language. Also the content in your strong tag would always just print "query" instead of the actual search term.
In order to highlight something within a full text string, you can use the Highlight component from our shared components library. https://nextcloud-vue-components.netlify.app/#/Components/Highlight
There was a problem hiding this comment.
@juliushaertl I have done the changes as you mentioned in the comment. Please check it.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
|
Please also make sure here to only include the required commit in the branch without the unrelated s3 changes |
Signed-off-by: Kavita Sonawane <kavita.sonawane@t-systems.com>
6e448c8 to
6d83632
Compare
|
I wanted to push a fix, but you disabled users from editing your pull request @TSI-kavitasonawane Feel free to close this one |
Signed-off-by: Kavita Sonawane <kavita.sonawane@t-systems.com>
|
Done in #28682 |
NMC-464: We applied a strong tag for user input on the "no results" screen within the search function.