From 0f2adcad14b6a8a8ddfa1c39b7ca90d7252e5b01 Mon Sep 17 00:00:00 2001 From: K Bell Date: Tue, 6 Jan 2015 11:44:44 -0500 Subject: [PATCH 1/3] highlight spell item when it has class of 'active' --- public/css/items.styl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/public/css/items.styl b/public/css/items.styl index 213e499835..166ab09321 100644 --- a/public/css/items.styl +++ b/public/css/items.styl @@ -18,7 +18,7 @@ background-color: $better color: #555 - &:hover, &:focus + &:hover, &:focus, &.active background-color: $bad text-decoration: none From d6dc2119cb98785d1209cbccc9521c60ddb4a8a2 Mon Sep 17 00:00:00 2001 From: K Bell Date: Thu, 8 Jan 2015 19:55:49 -0500 Subject: [PATCH 2/3] add active class to spell item when it is selected --- views/shared/tasks/lists.jade | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/views/shared/tasks/lists.jade b/views/shared/tasks/lists.jade index 0333238b2d..0250e0435b 100644 --- a/views/shared/tasks/lists.jade +++ b/views/shared/tasks/lists.jade @@ -128,7 +128,7 @@ script(id='templates/habitrpg-tasks.html', type="text/ng-template") span.glyphicon.glyphicon-comment //left-hand size commands .task-controls.task-primary - a.money.btn-buy.item-btn(ng-click='castStart(skill)') + a.money.btn-buy.item-btn(ng-click='castStart(skill)', ng-class='{active: skill.key == spell.key}') span.reward-cost strong {{skill.mana}} =env.t('mp') From 22446a5ddbee4a1f00f90aab7312d881b8551f90 Mon Sep 17 00:00:00 2001 From: "K. Belardinelli" Date: Sat, 10 Jan 2015 11:06:39 -0500 Subject: [PATCH 3/3] apply active class to special spells too --- views/shared/tasks/lists.jade | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/views/shared/tasks/lists.jade b/views/shared/tasks/lists.jade index 0250e0435b..e02ef29de3 100644 --- a/views/shared/tasks/lists.jade +++ b/views/shared/tasks/lists.jade @@ -104,7 +104,7 @@ script(id='templates/habitrpg-tasks.html', type="text/ng-template") span.glyphicon.glyphicon-comment //left-hand size commands .task-controls.task-primary - a.money.btn-buy.item-btn(ng-click='castStart(Content.spells.special.#{k})') + a.money.btn-buy.item-btn(ng-click='castStart(Content.spells.special.#{k})', ng-class='{active: Content.spells.special.#{k}.key == spell.key}') if canceler span.shop_gold span.reward-cost {{Content.spells.special.#{k}.value}}