From 99ddf40208d8b53a0a7f4899dfe91b0a72da9e26 Mon Sep 17 00:00:00 2001 From: yashar Date: Fri, 9 Jun 2017 20:03:55 +0430 Subject: [PATCH 1/5] Add md-primary class to the vote checkboxes in delegates components --- src/components/delegates/delegates.pug | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/components/delegates/delegates.pug b/src/components/delegates/delegates.pug index 10d4f99b0..e03228e33 100644 --- a/src/components/delegates/delegates.pug +++ b/src/components/delegates/delegates.pug @@ -63,7 +63,7 @@ div.offline-hide td(md-cell, colspan='6') No delegates found tr(md-row, ng-repeat="delegate in ($ctrl.filteredDelegates = ($ctrl.delegates | filter : {username: search} )) | limitTo : $ctrl.delegatesDisplayedCount", ng-class='{"downvote": delegate.status.voted && !delegate.status.selected, "upvote": !delegate.status.voted && delegate.status.selected, "pending": delegate.status.pending}') td(md-cell) - md-checkbox(ng-model='delegate.status.selected', ng-change='$ctrl.selectionChange(delegate)', ng-disabled='delegate.status.pending', aria-label='delegate selected for voting') + md-checkbox.md-primary(ng-model='delegate.status.selected', ng-change='$ctrl.selectionChange(delegate)', ng-disabled='delegate.status.pending', aria-label='delegate selected for voting') td(md-cell, ng-bind='delegate.rank') td(md-cell, ng-bind='delegate.username') td(md-cell, ng-bind='delegate.address') From 50328b70fa750a2646393e10dfc6b87928aaab70 Mon Sep 17 00:00:00 2001 From: yashar Date: Fri, 9 Jun 2017 20:04:48 +0430 Subject: [PATCH 2/5] Highlight voted delegate row in blue --- src/components/delegates/delegates.less | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/components/delegates/delegates.less b/src/components/delegates/delegates.less index 1ecd6fd3e..fba4d9a38 100644 --- a/src/components/delegates/delegates.less +++ b/src/components/delegates/delegates.less @@ -34,7 +34,7 @@ delegates { background-color: rgb(255, 228, 220); } .pending { - background-color: #eaeae9; + background-color: rgb(204, 231, 236); } md-card-title { From 1b14fc526a18df553be2f8643522640be5428959 Mon Sep 17 00:00:00 2001 From: yashar Date: Fri, 9 Jun 2017 20:06:10 +0430 Subject: [PATCH 3/5] Change 'Confirm vote' to 'Confirm' in vote dialog button --- src/components/delegates/vote.pug | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/components/delegates/vote.pug b/src/components/delegates/vote.pug index 9be065eaf..bb3726275 100644 --- a/src/components/delegates/vote.pug +++ b/src/components/delegates/vote.pug @@ -36,4 +36,4 @@ div.dialog-vote(aria-label='Vote for delegates') md-dialog-actions(layout='row') md-button(ng-click="$ctrl.$mdDialog.cancel()") Cancel span(flex) - md-button.md-primary.md-raised.submit-button(ng-disabled='!$ctrl.canVote()', ng-click="$ctrl.vote()") {{$ctrl.votingInProgress ? 'Voting...' : 'Confirm vote'}} + md-button.md-primary.md-raised.submit-button(ng-disabled='!$ctrl.canVote()', ng-click="$ctrl.vote()") {{$ctrl.votingInProgress ? 'Voting...' : 'Confirm'}} From e37af2bffb483f960c52182115b5c4c58ffb8561 Mon Sep 17 00:00:00 2001 From: yashar Date: Mon, 12 Jun 2017 18:45:20 +0430 Subject: [PATCH 4/5] Fix a minor bug in delegate component --- src/components/delegates/delegates.less | 5 ++++- src/components/delegates/delegates.pug | 2 +- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/src/components/delegates/delegates.less b/src/components/delegates/delegates.less index fba4d9a38..1f80b19e2 100644 --- a/src/components/delegates/delegates.less +++ b/src/components/delegates/delegates.less @@ -34,7 +34,10 @@ delegates { background-color: rgb(255, 228, 220); } .pending { - background-color: rgb(204, 231, 236); + background-color: #eaeae9; + } + .voted{ + background-color: #d6f0ff; } md-card-title { diff --git a/src/components/delegates/delegates.pug b/src/components/delegates/delegates.pug index e03228e33..8ae53307e 100644 --- a/src/components/delegates/delegates.pug +++ b/src/components/delegates/delegates.pug @@ -61,7 +61,7 @@ div.offline-hide tbody(md-body, infinite-scroll='$ctrl.showMore()', infinite-scroll-distance='1') tr(md-row, ng-if='!$ctrl.filteredDelegates.length && !$ctrl.loading') td(md-cell, colspan='6') No delegates found - tr(md-row, ng-repeat="delegate in ($ctrl.filteredDelegates = ($ctrl.delegates | filter : {username: search} )) | limitTo : $ctrl.delegatesDisplayedCount", ng-class='{"downvote": delegate.status.voted && !delegate.status.selected, "upvote": !delegate.status.voted && delegate.status.selected, "pending": delegate.status.pending}') + tr(md-row, ng-repeat="delegate in ($ctrl.filteredDelegates = ($ctrl.delegates | filter : {username: search} )) | limitTo : $ctrl.delegatesDisplayedCount", ng-class='{"downvote": delegate.status.voted && !delegate.status.selected, "upvote": !delegate.status.voted && delegate.status.selected, "pending": delegate.status.pending, "voted": delegate.status.voted && delegate.status.selected}') td(md-cell) md-checkbox.md-primary(ng-model='delegate.status.selected', ng-change='$ctrl.selectionChange(delegate)', ng-disabled='delegate.status.pending', aria-label='delegate selected for voting') td(md-cell, ng-bind='delegate.rank') From 4faa4e19d8a5a14daefbbff76c0799ef11c0be18 Mon Sep 17 00:00:00 2001 From: yashar Date: Mon, 12 Jun 2017 19:13:19 +0430 Subject: [PATCH 5/5] Reorder some classes in delegates.less to fix a bug --- src/components/delegates/delegates.less | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/components/delegates/delegates.less b/src/components/delegates/delegates.less index 1f80b19e2..ce119f5bd 100644 --- a/src/components/delegates/delegates.less +++ b/src/components/delegates/delegates.less @@ -33,12 +33,12 @@ delegates { .downvote { background-color: rgb(255, 228, 220); } - .pending { - background-color: #eaeae9; - } .voted{ background-color: #d6f0ff; } + .pending { + background-color: #eaeae9; + } md-card-title { md-input-container {