1 | "use strict";
|
2 |
|
3 | exports.__esModule = true;
|
4 | exports["default"] = meetsContrastGuidelines;
|
5 | var _getContrast = _interopRequireDefault(require("./getContrast"));
|
6 | function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
7 |
|
8 |
|
9 |
|
10 |
|
11 |
|
12 |
|
13 |
|
14 | function meetsContrastGuidelines(color1, color2) {
|
15 | var contrastRatio = (0, _getContrast["default"])(color1, color2);
|
16 | return {
|
17 | AA: contrastRatio >= 4.5,
|
18 | AALarge: contrastRatio >= 3,
|
19 | AAA: contrastRatio >= 7,
|
20 | AAALarge: contrastRatio >= 4.5
|
21 | };
|
22 | }
|
23 | module.exports = exports.default; |
\ | No newline at end of file |