Tracks color in all events takes background into account.
It uses https://github.com/openSUSE/osem/pull/1044 to select black or white color for the track text depending on what of them contrast more with the track background.
This commit is contained in:
parent
70f30fcb1f
commit
818c55df5a
1 changed files with 1 additions and 1 deletions
|
|
@ -29,5 +29,5 @@
|
||||||
- if event.track
|
- if event.track
|
||||||
%span.track
|
%span.track
|
||||||
%span.fa.fa-road
|
%span.fa.fa-road
|
||||||
%span.label{ style: "background-color: #{event.track.color}" }
|
%span.label{ style: "background-color: #{event.track.color}; color: #{ contrast_color(event.track.color) }" }
|
||||||
= event.track.name
|
= event.track.name
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue