fixed colors

This commit is contained in:
Antelle 2015-10-23 23:11:28 +03:00
parent ad89a502d8
commit b2d32971b6
3 changed files with 18 additions and 12 deletions

View File

@ -4,12 +4,21 @@ var Colors = {
AllColors: ['yellow', 'green', 'red', 'orange', 'blue', 'violet'],
ColorsValues: {
yellow: 'ff0',
green: '0f0',
red: 'f00',
orange: 'f80',
blue: '00f',
violet: 'f0f'
yellow: 'ffff00',
green: '00ff00',
red: 'ff0000',
orange: 'ff8800',
blue: '0000ff',
violet: 'ff00ff'
},
BgColors: {
yellow: 'ffff88',
green: '88ff88',
red: 'ff8888',
orange: 'ffcc88',
blue: '8888ff',
violet: 'ff88ff'
}
};

View File

@ -41,7 +41,7 @@ Color.prototype.setHsl = function() {
};
Color.prototype.toHex = function() {
return '#' + hex(this.r) + hex(this.g) + (this.b);
return '#' + hex(this.r) + hex(this.g) + hex(this.b);
};
Color.prototype.distanceTo = function(color) {
@ -65,10 +65,7 @@ Color.getNearest = function(colorStr) {
};
Color.getKnownBgColor = function(knownColor) {
var color = KnownColors[knownColor];
if (color) {
return color.toHex();
}
return Colors.BgColors[knownColor] ? '#' + Colors.BgColors[knownColor] : undefined;
};
_.forEach(Colors.ColorsValues, function(val, name) {

View File

@ -1,7 +1,7 @@
$themes: map-merge($themes, (
wh: (
background-color: #FAFAFA,
medium-color: #424243,
medium-color: #050505,
text-color: #424243,
action-color: #475FD7,
error-color: #E75675,