Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
node_modules
coverage
.DS_Store
.idea
1 change: 1 addition & 0 deletions index.js
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,7 @@ function parse(code, done) {
if (subResult.log) {
subResult.log.line = declaration.position.start.line
subResult.log.column = declaration.position.start.column
subResult.log.selectors = rule.selectors.join(', ')
ruleLog.push(subResult.log)
}
})
Expand Down
5 changes: 3 additions & 2 deletions lib/validator.js
Original file line number Diff line number Diff line change
Expand Up @@ -172,7 +172,7 @@ var EXTENDED_COLOR_KEYWORDS = {
}

var LENGTH_REGEXP = /^[-+]?\d*\.?\d+(\S*)$/
var SUPPORT_CSS_UNIT = ['pt', 'wx']
var SUPPORT_CSS_UNIT = ['pt', 'wx', 'px']
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Weex uses px as default unit and will convert it to number format. No need to add this.


/**
* the values below is valid
Expand Down Expand Up @@ -517,7 +517,8 @@ var PROP_NAME_GROUPS = {
fontStyle: genEnumValidator(['normal', 'italic']),
fontWeight: genEnumValidator(['normal', 'bold', '100', '200', '300', '400', '500', '600', '700', '800', '900']),
textDecoration: genEnumValidator(['none', 'underline', 'line-through']),
textAlign: genEnumValidator(['left', 'center', 'right'])
textAlign: genEnumValidator(['left', 'center', 'right']),
lineHeight: LENGTH_VALIDATOR
},
transition: {
transitionProperty: TRANSITION_PROPERTY_VALIDATOR,
Expand Down