diff --git a/app/components/contributor-list/component.js b/app/components/contributor-list/component.js index a9ae31e6..a5b42fd5 100644 --- a/app/components/contributor-list/component.js +++ b/app/components/contributor-list/component.js @@ -7,7 +7,7 @@ export default Component.extend({ tagName: 'table', classNames: 'contributor-list', - selectedContributor: null, + selectedContributorId: null, actions: { diff --git a/app/components/contributor-list/template.hbs b/app/components/contributor-list/template.hbs index 63c962b0..e187a2ae 100644 --- a/app/components/contributor-list/template.hbs +++ b/app/components/contributor-list/template.hbs @@ -1,6 +1,8 @@ {{#each contributorList as |c|}} - + {{user-avatar contributor=c.contributor}} {{c.contributor.name}} diff --git a/app/controllers/dashboard.js b/app/controllers/dashboard.js index caccbb63..28c183f7 100644 --- a/app/controllers/dashboard.js +++ b/app/controllers/dashboard.js @@ -7,6 +7,7 @@ export default Controller.extend({ kredits: service(), showDetailsPane: false, + selectedContributorId: null, currentBlock: alias('kredits.currentBlock'), diff --git a/app/routes/dashboard/contributors/show.js b/app/routes/dashboard/contributors/show.js index b301518e..c7e5d3b5 100644 --- a/app/routes/dashboard/contributors/show.js +++ b/app/routes/dashboard/contributors/show.js @@ -11,14 +11,22 @@ export default Route.extend({ return this.contributors.findBy('id', params.id); }, - activate () { + setupController (controller, model) { + this._super(controller, model); + this.controllerFor('dashboard') - .set('showDetailsPane', true); + .setProperties({ + showDetailsPane: true, + selectedContributorId: model.id + }); }, deactivate () { this.controllerFor('dashboard') - .set('showDetailsPane', false); + .setProperties({ + showDetailsPane: false, + selectedContributorId: null + }); } }); diff --git a/app/styles/components/_contributor-list.scss b/app/styles/components/_contributor-list.scss index 0a94414e..e35419d6 100644 --- a/app/styles/components/_contributor-list.scss +++ b/app/styles/components/_contributor-list.scss @@ -4,56 +4,20 @@ table.contributor-list { margin-bottom: 1.5rem; tr { + background-color: rgba(255,255,255,0.1); border-bottom: 1px solid rgba(255,255,255,0.2); + cursor: pointer; + &:first-of-type { border-top: 1px solid rgba(255,255,255,0.2); } - background-color: rgba(255,255,255,0.1); - &.current-user { + &.selected { background-color: rgba(255,255,255,0.2); } - &.metadata { - height: 0; - visibility: hidden; - - &:not(.visible) { - border-bottom: none; - } - - td { - padding: 0 1.2rem; - } - - a { - color: $primary-color; - &:hover, &:active { - color: #fff; - } - } - - ul { - list-style: none; - display: block; - overflow: hidden; - height: 0; - - li { - display: inline; - &+li { - margin-left: 1rem; - } - } - } - - &.visible { - height: auto; - visibility: visible; - ul { - height: auto; - } - } + &.current-user { + font-weight: 500; } td { @@ -71,20 +35,17 @@ table.contributor-list { &.kredits { text-align: right; + .amount { font-size: 1.2rem; font-weight: 500; } + .symbol { font-size: 0.8rem; padding-left: 0.2rem; } } - - pre { - line-height: 1rem; - padding-bottom: 1rem; - } } } } diff --git a/app/templates/dashboard.hbs b/app/templates/dashboard.hbs index ba85e937..3ed82d90 100644 --- a/app/templates/dashboard.hbs +++ b/app/templates/dashboard.hbs @@ -12,7 +12,8 @@
{{contributor-list contributorList=kreditsToplist - showUnconfirmedKredits=showUnconfirmedKredits}} + showUnconfirmedKredits=showUnconfirmedKredits + selectedContributorId=selectedContributorId}}

{{await kredits.totalKreditsEarned}} kredits confirmed and issued to