Update plugin card when CRC value changes

This commit is contained in:
Oliver Hamlet
2016-01-08 19:00:27 +00:00
parent b128025c6a
commit 6e9eff0bda
@@ -217,6 +217,7 @@ loot-clear-metadata
data: undefined,
observe: {
'data.crc': 'onCrcChange',
'data.tags': 'onTagsChange',
'data.messages': 'onMessagesChange',
'data.userlist': 'onUserlistChange',
@@ -278,6 +279,12 @@ loot-clear-metadata
}
},
onCrcChange: function(oldValue, newValue) {
if (this.data) {
this.getElementsByClassName('crc')[0].textContent = this.data.getCardContent(loot.filters).crc;
}
},
onTagsChange: function(oldValue, newValue) {
if (this.data) {
var cardContent = this.data.getCardContent(loot.filters);