diff --git a/SCHEMA.md b/SCHEMA.md index a3177a9..df7acb6 100644 --- a/SCHEMA.md +++ b/SCHEMA.md @@ -107,7 +107,7 @@ into this... | key | value | description | | ---------------- | :------ | :--------------------------------------------------------------------------------------------- | -| geometry | string | geometry type MapCSS is intended to match | +| geometry | array | geometry type MapCSS is intended to match | | equals | object | object with key/value pair MapCSS is intended to match | | notEqual | string | object with key/value pair MapCSS is not intended to match | | presence | string | tag key MapCSS is intended to match | diff --git a/dist/classes/regexType/geometry/constants.js b/dist/classes/regexType/geometry/constants.js index 2e386a9..35bf141 100644 --- a/dist/classes/regexType/geometry/constants.js +++ b/dist/classes/regexType/geometry/constants.js @@ -1 +1 @@ -/* --- GEOMETRY --- */var _NODE='node',_WAY='way',_CLOSEDWAY=':closed',_CLOSEDWAY_FULL='closedway';exports.NODE=/node/,exports.WAY=/way/,exports.CLOSEDWAY=/:closed/,exports.CLOSEDWAY_FULL=/closedway/,exports.GEOMETRY_GROUPS=_NODE+'|'+_WAY+'|'+_CLOSEDWAY,exports.GEOMETRY=/^node$|^way$|^:closed$/i,exports.GEOMETRY_SCHEMA=/^node$|^way$|^closedway$/i; \ No newline at end of file +/* --- GEOMETRY --- */var _NODE='node',_WAY='way',_CLOSEDWAY=':closed',_CLOSEDWAY_FULL='closedway',_WILDCARD='\\*';exports.NODE=/node/,exports.WAY=/way/,exports.CLOSEDWAY=/:closed/,exports.CLOSEDWAY_FULL=/closedway/,exports.WILDCARD=/\*/,exports.GEOMETRY_GROUPS=_NODE+'|'+_WAY+'|'+_CLOSEDWAY+'|'+_WILDCARD,exports.GEOMETRY=/^node$|^way$|^:closed$|^\*$/i,exports.GEOMETRY_SCHEMA=/^node$|^way$|^closedway$|^\*$/i; \ No newline at end of file diff --git a/dist/classes/regexType/geometry/index.js b/dist/classes/regexType/geometry/index.js index b070930..9260b1d 100644 --- a/dist/classes/regexType/geometry/index.js +++ b/dist/classes/regexType/geometry/index.js @@ -1 +1 @@ -var _createClass=function(){function a(a,b){for(var c,d=0;d { expect(helpers.geometryTypeFromSource(':closed')).to.eql('closedway'); expect(helpers.geometryTypeFromSource('node')).to.eql('node'); expect(helpers.geometryTypeFromSource('way')).to.eql('way'); + expect(helpers.geometryTypeFromSource('*')).to.eql('*'); }); }); }); diff --git a/testData/test.mapcss b/testData/test.mapcss index 2b8bd1e..29df6e6 100644 --- a/testData/test.mapcss +++ b/testData/test.mapcss @@ -30,4 +30,7 @@ way[amenity=school]{ } way[building][height=1] { throwError: "..." +} +*[amenity][!name] { + throwError: "name required on any amenity" } \ No newline at end of file