keyword method

Node keyword ()

A catch-all word, such as:

black border-collapse

returns Color | Keyword

Implementation

Node keyword() {
  final String k = parserInput.$char('%') ?? parserInput.$re(_keywordRegEx);

  if (k != null) return Color.fromKeyword(k) ?? Keyword(k);
  return null;

// 3.5.1 20180706
//  keyword: function () {
//      var k = parserInput.$char('%') || parserInput.$re(/^\[?(?:[\w-]|\\(?:[A-Fa-f0-9]{1,6} ?|[^A-Fa-f0-9]))+\]?/);
//      if (k) {
//          return tree.Color.fromKeyword(k) || new(tree.Keyword)(k);
//      }
//  },
}