�PNG  IHDR��;���IDATx��ܻn�0���K�� �)(�pA��� ���7�LeG{�� �§㻢|��ذaÆ 6lذaÆ 6lذaÆ 6lom��$^�y���ذag�5bÆ 6lذaÆ 6lذa{���� 6lذaÆ �`����}H�Fkm�,�m����Ӫ���ô�ô!� �x�|'ܢ˟;�E:���9�&ᶒ�}�{�v]�n&�6� �h��_��t�ڠ͵-ҫ���Z;��Z$�.�P���k�ž)�!��o���>}l�eQfJ�T��u і���چ��\��X=8��Rن4`Vw�l�>����n�G�^��i�s��"ms�$�u��i��?w�bs[m�6�K4���O���.�4��%����/����b�C%��t ��M�ז� �-l�G6�mrz2���s�%�9��s@���-�k�9�=���)������k�B5����\��+͂�Zsٲ ��Rn��~G���R���C����� �wIcI��n7jJ���hۛNCS|���j0��8y�iHKֶۛ�k�Ɉ+;Sz������L/��F�*\��Ԕ�#"5��m�2��[S��������=�g��n�a�P�e�ғ�L�� lذaÆ 6l�^k��̱aÆ 6lذaÆ 6lذa;���� �_��ذaÆ 6lذaÆ 6lذaÆ ���R���IEND�B` 'use strict' let { cyan, gray, green, yellow, magenta } = require('colorette') let tokenizer = require('./tokenize') let Input function registerInput(dependant) { Input = dependant } const HIGHLIGHT_THEME = { 'brackets': cyan, 'at-word': cyan, 'comment': gray, 'string': green, 'class': yellow, 'hash': magenta, 'call': cyan, '(': cyan, ')': cyan, '{': yellow, '}': yellow, '[': yellow, ']': yellow, ':': yellow, ';': yellow } function getTokenType([type, value], processor) { if (type === 'word') { if (value[0] === '.') { return 'class' } if (value[0] === '#') { return 'hash' } } if (!processor.endOfFile()) { let next = processor.nextToken() processor.back(next) if (next[0] === 'brackets' || next[0] === '(') return 'call' } return type } function terminalHighlight(css) { let processor = tokenizer(new Input(css), { ignoreErrors: true }) let result = '' while (!processor.endOfFile()) { let token = processor.nextToken() let color = HIGHLIGHT_THEME[getTokenType(token, processor)] if (color) { result += token[1] .split(/\r?\n/) .map(i => color(i)) .join('\n') } else { result += token[1] } } return result } terminalHighlight.registerInput = registerInput module.exports = terminalHighlight