Skip to content

Commit

Permalink
Fix some typos in contrast docs (#216)
Browse files Browse the repository at this point in the history
  • Loading branch information
xi authored Sep 10, 2022
1 parent 74da04a commit bdf68c7
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions docs/contrast.md
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ It is commonly used in lighting design,
and also to examine small, sharp edged symbols and text
on larger, uniformly-colored backgrounds.

> WC = Y<sub>max</sub> - Y<sub>min</sub> / Y<sub>min</sub>
> WC = (Y<sub>max</sub> - Y<sub>min</sub>) / Y<sub>min</sub>
Any two colors can be used,
and this formula does not care which is the text color and which is the background.
Expand All @@ -85,7 +85,7 @@ Weber contrast is typically used with printed test charts
with positive polarity (black text, white background).
The formula thus can be expressed as:

> WC<sub>pp</sub> = Y<sub>background</sub> - Y<sub>text</sub> / Y<sub>text</sub>
> WC<sub>pp</sub> = (Y<sub>background</sub> - Y<sub>text</sub>) / Y<sub>text</sub>
Hwang and Peli used a modified Weber contrast for
tablet-based, negative polarity testing (white text on black background),
Expand All @@ -95,7 +95,7 @@ and wrote:
The formula for negative polarity is

> WC<sub>np</sub> = Y<sub>text</sub> - Y<sub>background</sub> / Y<sub>text</sub>
> WC<sub>np</sub> = (Y<sub>text</sub> - Y<sub>background</sub>) / Y<sub>text</sub>

## Michelson Contrast
Expand Down Expand Up @@ -209,7 +209,7 @@ _This value is much higher than that in the sRGB standard,
which puts white at 80 cd/m2 and black at 0.2cd/m2,
a relative luminance boost of 0.0025._

> WCAG21 = = (Y<sub>max</sub> + 0.05) / (Y<sub>min</sub> + 0.05)
> WCAG21 = (Y<sub>max</sub> + 0.05) / (Y<sub>min</sub> + 0.05)
Because of it's widespread use,
color.js provides this method, mainly to aid comparison.
Expand Down

0 comments on commit bdf68c7

Please sign in to comment.