Comparing version 1.0.0-alpha11 to 1.0.0-alpha12
@@ -0,1 +1,6 @@ | ||
## 1.0.0-alpha12 (January 19, 2017) | ||
- Fixed `Syntax#matchProperty()` method to always return a positive result for custom properties since syntax is never defined for them (#31) | ||
- Implemented `fromPlainObject()` and `toPlainObject()` to convert plain object to AST or AST to plain object (currently converts `List` <-> `Array`) | ||
## 1.0.0-alpha11 (January 18, 2017) | ||
@@ -2,0 +7,0 @@ |
@@ -16,2 +16,4 @@ 'use strict'; | ||
clone: require('./utils/clone'), | ||
fromPlainObject: require('./utils/convert').fromPlainObject, | ||
toPlainObject: require('./utils/convert').toPlainObject, | ||
@@ -18,0 +20,0 @@ walk: walkers.all, |
@@ -164,2 +164,11 @@ 'use strict'; | ||
var property = names.property(propertyName); | ||
// don't match syntax for a custom property | ||
if (propertyName[0] === '-' && propertyName[1] === '-') { | ||
return { | ||
type: 'NoMatch', | ||
comment: 'Syntax matching doesn\'t applicable for custom properties' | ||
}; | ||
} | ||
var propertySyntax = property.vendor | ||
@@ -166,0 +175,0 @@ ? this.getProperty(property.vendor + property.name) || this.getProperty(property.name) |
{ | ||
"name": "css-tree", | ||
"version": "1.0.0-alpha11", | ||
"version": "1.0.0-alpha12", | ||
"description": "Fast detailed CSS parser", | ||
@@ -5,0 +5,0 @@ "keywords": [ |
@@ -48,4 +48,4 @@ <img align="right" width="111" height="111" | ||
// Rule | ||
// SelectorList | ||
// Selector | ||
// SimpleSelector | ||
// Class | ||
@@ -81,4 +81,4 @@ // Block | ||
- `ruleset` – rule (e.g. `.foo, .bar:hover { color: red; border: 1px solid black; }`) | ||
- `selector` – selector group (`.foo, .bar:hover` for ruleset example) | ||
- `simpleSelector` – selector (`.foo` or `.bar:hover` for ruleset example) | ||
- `selectorList` – selector group (`.foo, .bar:hover` for ruleset example) | ||
- `selector` – selector (`.foo` or `.bar:hover` for ruleset example) | ||
- `block` – block content w/o curly braces (`color: red; border: 1px solid black;` for ruleset example) | ||
@@ -156,3 +156,3 @@ - `declaration` – declaration (`color: red` or `border: 1px solid black` for ruleset example) | ||
- `ruleset` – refers to `Rule` node if current node inside a ruleset | ||
- `selector` – refers to `Selector` node if current node inside a selector | ||
- `selector` – refers to `SelectorList` node if current node inside a selector list | ||
- `declaration` – refers to `Declaration` node if current node inside a declaration | ||
@@ -200,4 +200,4 @@ - `function` – refers to closest `Function` or `FunctionalPseudo` node if current node inside one of them | ||
// Rule | ||
// SelectorList | ||
// Selector | ||
// SimpleSelector | ||
// Class | ||
@@ -213,4 +213,4 @@ // Block | ||
// Class | ||
// SimpleSelector | ||
// Selector | ||
// SelectorList | ||
// Identifier | ||
@@ -217,0 +217,0 @@ // Value |
Sorry, the diff of this file is too big to display
547353
34
12477