added warning colors to stars

This commit is contained in:
Faraphel 2022-07-21 15:55:08 +02:00
parent 2bb04dd97c
commit ab64541b91
2 changed files with 2 additions and 2 deletions

View file

@ -6,7 +6,7 @@
"layers": [ "layers": [
{ {
"mode": "ctfile", "mode": "ctfile",
"template": "{{ ('\\c{YOR2}\\x'+hex(65296+getattr(track, 'score'))[2:]+'\\c{off} ') if hasattr(track, 'score') else '' }}{{ (prefix+' ') if prefix else '' }}{{ getattr(track, 'name', '') }}{{ (' ('+suffix +')') if suffix else '' }}" "template": "{{ ('\\c{' + ['YOR2', 'YOR4', 'YOR6', 'blue1'][getattr(track, 'warning', 0)] +'}\\x'+hex(65296+getattr(track, 'score'))[2:]+'\\c{off} ') if hasattr(track, 'score') else '' }}{{ (prefix+' ') if prefix else '' }}{{ getattr(track, 'name', '') }}{{ (' ('+suffix +')') if suffix else '' }}"
}, },
{ {
"mode": "format-original-track", "mode": "format-original-track",

View file

@ -6,7 +6,7 @@
"layers": [ "layers": [
{ {
"mode": "ctfile", "mode": "ctfile",
"template": "{{ ('\\c{YOR2}\\x'+hex(65296+getattr(track, 'score'))[2:]+'\\c{off} ') if hasattr(track, 'score') else '' }}{{ (prefix+' ') if prefix else '' }}{{ getattr(track, 'name', '') }}{{ (' ('+suffix +')') if suffix else '' }}\n{{ '\\n'.join(getattr(track, 'author')) if isinstance(getattr(track, 'author', ''), list) else getattr(track, 'author', '/') }}" "template": "{{ ('\\c{' + ['YOR2', 'YOR4', 'YOR6', 'blue1'][getattr(track, 'warning', 0)] +'}\\x'+hex(65296+getattr(track, 'score'))[2:]+'\\c{off} ') if hasattr(track, 'score') else '' }}{{ (prefix+' ') if prefix else '' }}{{ getattr(track, 'name', '') }}{{ (' ('+suffix +')') if suffix else '' }}\n{{ '\\n'.join(getattr(track, 'author')) if isinstance(getattr(track, 'author', ''), list) else getattr(track, 'author', '/') }}"
}, },
{ {
"mode": "format-original-track", "mode": "format-original-track",