Add localization for notification descriptions

This commit is contained in:
advplyr 2024-10-12 15:22:21 -05:00
parent 8a20510cde
commit df6afc957f
3 changed files with 15 additions and 1 deletions

View file

@ -77,7 +77,13 @@ export default {
return this.notificationData.events || []
},
eventOptions() {
return this.notificationEvents.map((e) => ({ value: e.name, text: e.name, subtext: e.description }))
return this.notificationEvents.map((e) => {
return {
value: e.name,
text: e.name,
subtext: this.$strings[e.descriptionKey] || e.description
}
})
},
selectedEventData() {
return this.notificationEvents.find((e) => e.name === this.newNotification.eventName)