alerta / alerta-webui

Alerta Web UI 7.0
https://try.alerta.io
Apache License 2.0
109 stars 55 forks source link

Problem text color when using black color alarm with normal theme and dark theme #505

Closed oijkn closed 2 years ago

oijkn commented 2 years ago

Issue Summary If I set color alarm to black with normal theme, the text is not readable. If I set color alarm to white with dark theme, the text is not readable.

Environment

To Reproduce Steps to reproduce the behavior:

  1. Set color alarm to black
  2. Click on alerts menu

Expected behavior A white text over black color

Screenshots image image

satterly commented 2 years ago

The previous version (in AngularJS) had the following ...

    <tr ng-repeat="alert in alerts | filter:filter | orderBy:predicate:reverse | limitTo:alertLimit"
        ng-style="{ 'color':  colors.severity[alert.severity] == 'black' ? 'white' : colors.text, 'background-color': (bulkAlerts.indexOf(alert.id) > -1) ? colors.highlight : colors.severity[alert.severity] || 'silver' }"
        ng-click="click($event,alert);">

https://github.com/alerta/angular-alerta-webui/blob/4d0b6327cd3bcde44df6a3db9ad961a92e080748/app/partials/alert-list.html#L48-L50