Comparing version 0.4.2 to 0.4.3
# Changes | ||
## 0.4.3 | ||
- Fixes a pattern matching bug causing some issues with namespaces. Note that | ||
this is related to an undocumented feature which might be dropped in a future | ||
major version. | ||
## 0.4.2 | ||
- Fixes a bug where bindings on attributes are ignoring specific value types set on those attributes | ||
- Fixes a bug where bindings on attributes are ignoring specific value types set on those attributes. | ||
## 0.4.1 | ||
- Fix a number of issues with RelaxNG generation and namespaces | ||
- Fix a number of issues with RelaxNG generation and namespaces. | ||
## 0.4.0 | ||
- Add support for capturing an entire nodeset | ||
- Produce sensible RelaxNG grammars for captures | ||
- Add support for capturing an entire nodeset. | ||
- Produce sensible RelaxNG grammars for captures. | ||
## 0.3.5 | ||
- Fix a RelaxNG generation issue | ||
- Fix a RelaxNG generation issue. | ||
## 0.3.4 | ||
- Add CDATA support | ||
- Add CDATA support. | ||
@@ -24,0 +30,0 @@ ## 0.3.3 |
@@ -78,7 +78,7 @@ // Generated by CoffeeScript 2.5.1 | ||
definedOn: function(elem) { | ||
if (meta.ns != null) { | ||
return elem.hasAttributeNS(meta.name) && ((meta.bind != null) || elem.getAttributeNS(meta.name) === meta.value); | ||
} else { | ||
return elem.hasAttribute(meta.name) && ((meta.bind != null) || elem.getAttribute(meta.name) === meta.value); | ||
} | ||
var localName, result; | ||
// Another hack. We need to start remembering the prefix and local name during parsing. | ||
localName = _.last(meta.name.split(':')); | ||
result = meta.ns != null ? elem.hasAttributeNS(meta.ns, localName) && ((meta.bind != null) || elem.getAttributeNS(meta.ns, localName) === meta.value) : elem.hasAttribute(meta.name) && ((meta.bind != null) || elem.getAttribute(meta.name) === meta.value); | ||
return result; | ||
}, | ||
@@ -85,0 +85,0 @@ relaxng: function(ctx) { |
{ | ||
"name": "cruftless", | ||
"version": "0.4.2", | ||
"version": "0.4.3", | ||
"description": "Yet another simple way to parse and generate XML", | ||
@@ -5,0 +5,0 @@ "main": "lib/cruftless.js", |
61071