mirror of
https://github.com/advplyr/audiobookshelf.git
synced 2025-07-24 04:44:57 +02:00
parent
8512d5e693
commit
1dec8ae122
13 changed files with 213 additions and 83 deletions
|
@ -89,10 +89,10 @@ Vue.prototype.$strings = { ...enUsStrings }
|
|||
* Get string and substitute
|
||||
*
|
||||
* @param {string} key
|
||||
* @param {string[]} subs
|
||||
* @param {string[]} [subs=[]]
|
||||
* @returns {string}
|
||||
*/
|
||||
Vue.prototype.$getString = (key, subs) => {
|
||||
Vue.prototype.$getString = (key, subs = []) => {
|
||||
if (!Vue.prototype.$strings[key]) return ''
|
||||
if (subs?.length && Array.isArray(subs)) {
|
||||
return supplant(Vue.prototype.$strings[key], subs)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue