add translatable string for artist>subscribers

This commit is contained in:
vrifox 2023-07-18 15:05:55 +02:00
parent bb61809785
commit f638ebbdb8
No known key found for this signature in database
GPG key ID: D40098E5B60B2197
3 changed files with 13 additions and 8 deletions

View file

@ -3,11 +3,14 @@ import { ref } from 'vue';
import Btn from './Btn.vue'; import Btn from './Btn.vue';
import { useStore } from '@/scripts/util.js'; import { useStore } from '@/scripts/util.js';
import { useResults, useArtist } from '@/stores/results.js'; import { useResults, useArtist } from '@/stores/results.js';
import { useI18n } from '@/stores/misc.js';
const artist = useArtist(), const artist = useArtist(),
results = useResults(), results = useResults(),
store = useStore(); store = useStore(),
{ t } = useI18n();
const subs = JSON.parse(store.subs ? store.subs : '[]'), const subs = JSON.parse(store.subs ? store.subs : '[]'),
hash = artist.state.hash, hash = artist.state.hash,
@ -43,9 +46,9 @@ function Sub() {
@click=" @click="
results.getAlbum('/playlist?list=' + artist.state.playlistId) results.getAlbum('/playlist?list=' + artist.state.playlistId)
" /> " />
<span class="us-box subs" :data-active="isSub" @click="Sub">{{ <span class="us-box subs" :data-active="isSub" @click="Sub">
artist.state.subscriberCount || 0 {{ artist.state.subscriberCount || 0 }} {{ t('artist.subscribers') }}
}}</span> </span>
</div> </div>
</div> </div>
</div> </div>
@ -106,10 +109,6 @@ p.more {
.subs { .subs {
transition: background-color 0.4s ease, color 0.4s ease; transition: background-color 0.4s ease, color 0.4s ease;
} }
.subs::after {
content: ' Subscribers';
font-weight: bold;
}
.subs:hover, .subs:hover,
.subs[data-active='true'] { .subs[data-active='true'] {
background-color: var(--color-foreground); background-color: var(--color-foreground);

View file

@ -37,6 +37,9 @@
"sync": "Wiedergabelisten synchronisieren", "sync": "Wiedergabelisten synchronisieren",
"select": "Hinzufügende Wiedergabeliste auswählen" "select": "Hinzufügende Wiedergabeliste auswählen"
}, },
"artist": {
"subscribers": "Abonnenten"
},
"pref": { "pref": {
"worst": "am Schlechten", "worst": "am Schlechten",
"theme": "Farbschema", "theme": "Farbschema",

View file

@ -37,6 +37,9 @@
"sync": "Sync playlists", "sync": "Sync playlists",
"select": "Select Playlist to Add" "select": "Select Playlist to Add"
}, },
"artist": {
"subscribers": "Subscribers"
},
"pref": { "pref": {
"theme": "Theme", "theme": "Theme",
"dark": "Dark (Default)", "dark": "Dark (Default)",