1
0
Fork 0
mirror of https://github.com/em-squared/5e-drs.git synced 2025-10-29 20:54:19 +00:00

ajout de feedback sur les ajouts/suppressions dans les bibliothèques et consolidation. see #20

This commit is contained in:
Maxime Moraine 2020-05-23 11:17:42 +02:00
parent 183c7fcaa5
commit dfb0967b07
16 changed files with 105 additions and 27 deletions

View file

@ -292,8 +292,12 @@ export default {
toggleSpellInSpellBook (spell) {
if (this.isSpellInSpellBook(spell)) {
this.$store.commit('mySpells/removeSpell', spell)
this.$store.commit('setSnackbarText', "Le sort " + spell.title + " a été supprimé de votre grimoire")
this.$store.commit('setIsOpenSnackbar', true)
} else {
this.$store.commit('mySpells/addSpell', spell)
this.$store.commit('setSnackbarText', "Le sort " + spell.title + " a été ajouté à votre grimoire")
this.$store.commit('setIsOpenSnackbar', true)
}
},