diff options
author | Wouter Admiraal <wouter.admiraal@sonarsource.com> | 2022-09-01 11:11:45 +0200 |
---|---|---|
committer | sonartech <sonartech@sonarsource.com> | 2022-09-02 20:02:50 +0000 |
commit | cfb2e265481817c41725eb6b6f6f4e915d4ba7a0 (patch) | |
tree | 27b1e18ae96ead1fb3fcf44becb6bd2e6cdcc0ee /server/sonar-web/src/main/js/helpers | |
parent | 783cf30f44627303c845dfbc42f040d39d153620 (diff) | |
download | sonarqube-cfb2e265481817c41725eb6b6f6f4e915d4ba7a0.tar.gz sonarqube-cfb2e265481817c41725eb6b6f6f4e915d4ba7a0.zip |
SONAR-16894 SONAR-16899 [892238] [892241]
* [892238] Link or button text lacks 4.5:1 contrast ratio on hover or focus
* [892241] An icon lacks 3 to 1 contrast ratio
Diffstat (limited to 'server/sonar-web/src/main/js/helpers')
-rw-r--r-- | server/sonar-web/src/main/js/helpers/constants.ts | 34 |
1 files changed, 13 insertions, 21 deletions
diff --git a/server/sonar-web/src/main/js/helpers/constants.ts b/server/sonar-web/src/main/js/helpers/constants.ts index 48588f4f2b1..568d943c5e0 100644 --- a/server/sonar-web/src/main/js/helpers/constants.ts +++ b/server/sonar-web/src/main/js/helpers/constants.ts @@ -38,28 +38,20 @@ export const SOURCE_SCOPES = [ export const RULE_TYPES: RuleType[] = ['BUG', 'VULNERABILITY', 'CODE_SMELL', 'SECURITY_HOTSPOT']; export const RULE_STATUSES = ['READY', 'BETA', 'DEPRECATED']; -export const CHART_COLORS_RANGE_PERCENT = [ - colors.green, - colors.lightGreen, - colors.yellow, - colors.orange, - colors.red -]; - -export const CHART_REVERSED_COLORS_RANGE_PERCENT = [ - colors.red, - colors.orange, - colors.yellow, - colors.lightGreen, - colors.green -]; - export const RATING_COLORS = [ - colors.green, - colors.lightGreen, - colors.yellow, - colors.orange, - colors.red + { fill: colors.success500, fillTransparent: colors.success500a20, stroke: colors.success500 }, + { + fill: colors.successVariant, + fillTransparent: colors.successVarianta20, + stroke: colors.successVariant + }, + { + fill: colors.warningVariant, + fillTransparent: colors.warningVarianta20, + stroke: colors.warningVariantDark + }, + { fill: colors.warningAccent, fillTransparent: colors.warningAccenta20, stroke: colors.warning }, + { fill: colors.error500, fillTransparent: colors.error500a20, stroke: colors.error500 } ]; export const PROJECT_KEY_MAX_LEN = 400; |