Added translation support for toast messages
This commit is contained in:
@@ -4,6 +4,7 @@
|
||||
class="tab_hidden"
|
||||
@transitionend="$refs.container.style.transition = ''"
|
||||
ref="container"
|
||||
:data-label="$t('downloads')"
|
||||
>
|
||||
<div id="download_tab_drag_handler" @mousedown.prevent="startDrag" ref="dragHandler"></div>
|
||||
<i
|
||||
@@ -187,7 +188,7 @@ export default {
|
||||
}
|
||||
|
||||
if (!queueItem.init) {
|
||||
toast(`${queueItem.title} added to queue`, 'playlist_add_check')
|
||||
toast(this.$t('toasts.addedToQueue', [queueItem.title]), 'playlist_add_check')
|
||||
}
|
||||
},
|
||||
updateQueue(update) {
|
||||
@@ -280,7 +281,7 @@ export default {
|
||||
},
|
||||
finishDownload(uuid) {
|
||||
if (this.queue.indexOf(uuid) > -1) {
|
||||
toast(`${this.queueList[uuid].title} finished downloading.`, 'done')
|
||||
toast(this.$t('toasts.finishDownload', [this.queueList[uuid].title]), 'done')
|
||||
|
||||
$('#bar_' + uuid).css('width', '100%')
|
||||
|
||||
@@ -311,7 +312,7 @@ export default {
|
||||
}
|
||||
|
||||
if (this.queue.length <= 0) {
|
||||
toast('All downloads completed!', 'done_all')
|
||||
toast(this.$t('toasts.allDownloaded'), 'done_all')
|
||||
}
|
||||
}
|
||||
},
|
||||
@@ -348,4 +349,4 @@ export default {
|
||||
</script>
|
||||
|
||||
<style>
|
||||
</style>
|
||||
</style>
|
||||
|
||||
@@ -303,7 +303,7 @@ export default {
|
||||
'animationiteration',
|
||||
() => {
|
||||
this.$refs.reloadButton.classList.remove('spin')
|
||||
toast('Refresh completed!', 'done', true)
|
||||
toast(this.$t('toasts.refreshFavs'), 'done', true)
|
||||
},
|
||||
{ once: true }
|
||||
)
|
||||
|
||||
@@ -1,10 +1,8 @@
|
||||
<template>
|
||||
<div id="search_tab" class="main_tabcontent" @click="handleSearchTabClick">
|
||||
<div :class="{ hide: results.query != '' }">
|
||||
<h2>Start searching!</h2>
|
||||
<p>
|
||||
You can search a track, a whole album, an artist, a playlist.... everything! You can also paste a Deezer link
|
||||
</p>
|
||||
<h2>{{ $t('search.startSearching') }}</h2>
|
||||
<p>{{ $t('search.description') }}</p>
|
||||
</div>
|
||||
<div v-show="results.query !== ''">
|
||||
<ul class="section-tabs">
|
||||
|
||||
Reference in New Issue
Block a user