shellscape / postcss-values-parser

A CSS property value parser for PostCSS
Mozilla Public License 2.0
59 stars 29 forks source link

isColor does not detect capitalized color keywords #67

Closed bartveneman closed 5 years ago

bartveneman commented 5 years ago

How Do We Reproduce?

const {parse} = require('postcss-values-parser')

;['Red', 'GREEN', 'whiteSmoke'].forEach(color => {
  parse(color, {loose: true}).walk(node => {
    console.log(node.isColor)
  })
})

Expected Behavior

Expected isColor to be true for all of these cases

Actual Behavior

isColor is false for all of these cases

Related issues and code

shellscape commented 5 years ago

Good catch. Should be an easy fix.

shellscape commented 5 years ago

Fixed and released in v3.0.0 proper. We're out of beta. Thank you for your help in adopting the beta!

bartveneman commented 5 years ago

Whoo! 🎉