mirror of
https://github.com/HabitRPG/habitica.git
synced 2025-12-19 15:48:04 +01:00
classes: header z-index:100, generalized shop_money classes, only show
owned gear if == true
This commit is contained in:
@@ -3,7 +3,7 @@
|
||||
.header-wrap
|
||||
width: 100% // this is for the sticky
|
||||
padding: 0
|
||||
z-index: 1
|
||||
z-index: 100
|
||||
background: #f5f5f5
|
||||
border-bottom: 1px solid rgba(0,0,0,0.2)
|
||||
// margin-top: -1px
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
line-height: 1.5em
|
||||
padding-left: 0.75em
|
||||
|
||||
[class^="shop_"]
|
||||
.shop_gold, .shop_silver, .shop_copper
|
||||
vertical-align: top
|
||||
display: inline-block
|
||||
|
||||
|
||||
@@ -22,12 +22,13 @@ habitrpg.controller("InventoryCtrl", ['$rootScope', '$scope', 'User', 'API_URL',
|
||||
$scope.gear = {
|
||||
base: _.where(Content.gear.flat, {klass: 'base'})
|
||||
};
|
||||
_.each(gear.owned, function(bool,key){
|
||||
_.each(gear.owned, function(v,key){
|
||||
if (v === false) return;
|
||||
var item = Content.gear.flat[key];
|
||||
if (!$scope.gear[item.klass]) $scope.gear[item.klass] = [];
|
||||
$scope.gear[item.klass].push(item);
|
||||
})
|
||||
}, true)
|
||||
}, true);
|
||||
|
||||
$scope.chooseEgg = function(egg){
|
||||
if ($scope.selectedEgg && $scope.selectedEgg.name == egg) {
|
||||
|
||||
Reference in New Issue
Block a user