'use strict';

Object.defineProperty(exports, '__esModule', { value: true });

var index$1 = require('../utils/index.js');
var index = require('../color/index.js');

/* IMPORT */
/* MAIN */
//SOURCE: https://planetcalc.com/7779
const luminance = (color) => {
    const { r, g, b } = index.default.parse(color);
    const luminance = .2126 * index$1.default.channel.toLinear(r) + .7152 * index$1.default.channel.toLinear(g) + .0722 * index$1.default.channel.toLinear(b);
    return index$1.default.lang.round(luminance);
};

exports.default = luminance;
