mirror of
https://github.com/gitbucket/gitbucket.git
synced 2025-11-08 22:45:51 +01:00
Fix label text color
This commit is contained in:
@@ -29,9 +29,9 @@ case class Label(
|
||||
val b = color.substring(4, 6)
|
||||
|
||||
if(Integer.parseInt(r, 16) + Integer.parseInt(g, 16) + Integer.parseInt(b, 16) > 408){
|
||||
"black"
|
||||
"000000"
|
||||
} else {
|
||||
"white"
|
||||
"ffffff"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -10,8 +10,8 @@
|
||||
<div class="span8">
|
||||
<div style="margin-top: 6px">
|
||||
<a href="@url(repository)/issues?labels=@urlEncode(label.labelName)" id="label-row-content-@label.labelId">
|
||||
<span style="background-color: #@label.color; color: @label.fontColor; padding: 8px; font-size: 120%; border-radius: 4px;">
|
||||
<img src="@assets/common/images/label_@(label.fontColor).png" style="width: 12px;"/>
|
||||
<span style="background-color: #@label.color; color: #@label.fontColor; padding: 8px; font-size: 120%; border-radius: 4px;">
|
||||
<img src="@assets/common/images/label_@(if(label.fontColor == "ffffff") "white" else "black").png" style="width: 12px;"/>
|
||||
@label.labelName
|
||||
</span>
|
||||
</a>
|
||||
|
||||
Reference in New Issue
Block a user