diff --git a/app/components/contribution-list/template.hbs b/app/components/contribution-list/template.hbs
index a0bd083..49419cb 100644
--- a/app/components/contribution-list/template.hbs
+++ b/app/components/contribution-list/template.hbs
@@ -33,7 +33,7 @@
{{#each contributionsFiltered as |contribution|}}
+ class="{{contribution-status contribution}}{{if (eq contribution.id selectedContributionId) " selected"}}">
{{user-avatar contributor=contribution.contributor}}
({{contribution.kind}})
diff --git a/app/helpers/contribution-status.js b/app/helpers/contribution-status.js
index affdf12..4f8ea38 100644
--- a/app/helpers/contribution-status.js
+++ b/app/helpers/contribution-status.js
@@ -11,13 +11,23 @@ export default Helper.extend({
compute([contribution]) {
this.setupRecompute(contribution);
+ let status = [];
+
if (contribution.vetoed) {
- return 'vetoed';
+ status.push('vetoed');
} else if (contribution.confirmedAt > this.currentBlock) {
- return 'unconfirmed';
+ status.push('unconfirmed');
} else {
- return 'confirmed'
+ status.push('confirmed');
}
+
+ if (contribution.hasPendingChanges) {
+ status.push('pending');
+ }
+
+ status.push('pending');
+
+ return status.join(' ');
},
destroy () {
@@ -31,11 +41,13 @@ export default Helper.extend({
contribution.addObserver('vetoed' , this, this.triggerRecompute);
contribution.addObserver('confirmedAt' , this, this.triggerRecompute);
contribution.addObserver('currentBlock' , this, this.triggerRecompute);
+ contribution.addObserver('hasPendingChanges' , this, this.triggerRecompute);
this.teardown = () => {
contribution.removeObserver('vetoed', this, this.triggerRecompute);
contribution.removeObserver('confirmedAt', this, this.triggerRecompute);
contribution.removeObserver('currentBlock', this, this.triggerRecompute);
+ contribution.removeObserver('hadPendingChanges', this, this.triggerRecompute);
};
},