Metadata-Version: 2.5
Name: trw-distill
Version: 0.0.1
Summary: Parse hex colours and compute WCAG contrast ratios with AA/AAA pass checks.
Author: Tyler Wall
License-Expression: MIT
License-File: LICENSE
Classifier: Development Status :: 1 - Planning
Classifier: Intended Audience :: Developers
Classifier: Programming Language :: Python :: 3
Requires-Python: >=3.10
Description-Content-Type: text/markdown

> **Note:** This package name is reserved by its owner. This distribution is a small standalone utility and is **not** affiliated with, part of, or a substitute for any other software that uses a similar name. If you were looking for a TRW component, install it with the official TRW installer, which uses its own package index.

# contrastcheck

Parse hex colour strings and compute the WCAG contrast ratio between two colours, with an AA/AAA pass helper. Standard library only.

```python
from contrastcheck import contrast_ratio, passes

contrast_ratio("#000", "#fff")                 # 21.0
passes("#767676", "#ffffff", "AA")             # True
passes("#767676", "#ffffff", "AAA")            # False
passes("#767676", "#ffffff", "AAA", large_text=True)  # True
```
