Fix ID coloring style
Add 'border-radius' and 'padding' to IDs with black colored text.
This commit is contained in:
parent
ecdd13f9b0
commit
63daa91521
@ -29,7 +29,7 @@ IDColor =
|
|||||||
|
|
||||||
apply: ->
|
apply: ->
|
||||||
rgb = IDColor.ids[@] or IDColor.compute @
|
rgb = IDColor.ids[@] or IDColor.compute @
|
||||||
"background-color: rgb(#{rgb[0]},#{rgb[1]},#{rgb[2]}); color: " + if rgb[3] then "black;" else "white; border-radius: 3px; padding: 0px 2px;"
|
"background-color: rgb(#{rgb[0]},#{rgb[1]},#{rgb[2]}); color: " + if rgb[3] then "black; border-radius: 3px; padding: 0px 2px;" else "white; border-radius: 3px; padding: 0px 2px;"
|
||||||
|
|
||||||
hash: (str) ->
|
hash: (str) ->
|
||||||
msg = 0
|
msg = 0
|
||||||
@ -38,4 +38,4 @@ IDColor =
|
|||||||
while i < j
|
while i < j
|
||||||
msg = ((msg << 5) - msg) + str.charCodeAt i
|
msg = ((msg << 5) - msg) + str.charCodeAt i
|
||||||
++i
|
++i
|
||||||
msg
|
msg
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user