class Crass::Parser

def consume_component_value(input = @tokens)

Experimental RBS support (using type sampling data from the type_fusion project).

def consume_component_value: (?Crass::TokenScanner input) -> nil

This signature was generated using 2 samples from 1 application.

5.4.6. http://dev.w3.org/csswg/css-syntax-3/#consume-a-component-value

tokens.
Consumes a component value and returns it, or `nil` if there are no more
def consume_component_value(input = @tokens)
  return nil unless token = input.consume
  case token[:node]
  when :'{', :'[', :'('
    consume_simple_block(input)
  when :function
    if token.key?(:name)
      # This is a parsed function, not a function token. This step isn't
      # mentioned in the spec, but it's necessary to avoid re-parsing
      # functions that have already been parsed.
      token
    else
      consume_function(input)
    end
  else
    token
  end
end