Skip to content

Commit

Permalink
fix(color-contrast): add px unit to error messages (#1634)
Browse files Browse the repository at this point in the history
* fix(color-contrast): add px unit to error messages

* change to show px in parenthesis
  • Loading branch information
straker authored and WilcoFiers committed Jul 22, 2019
1 parent 287ef9c commit 36089c9
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/checks/color/color-contrast.js
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ const data = {
fgColor: fgColor ? fgColor.toHexString() : undefined,
bgColor: bgColor ? bgColor.toHexString() : undefined,
contrastRatio: cr ? truncatedResult : undefined,
fontSize: ((fontSize * 72) / 96).toFixed(1) + 'pt',
fontSize: `${((fontSize * 72) / 96).toFixed(1)}pt (${fontSize}px)`,
fontWeight: bold ? 'bold' : 'normal',
missingData: missing,
expectedContrastRatio: cr.expectedContrastRatio + ':1'
Expand Down

0 comments on commit 36089c9

Please sign in to comment.