- var toret = [];
- this.getAttrs().forEach(function(attr) {
- if(isMetaAttribute(attr.name)) {
- toret.push({name: attr.name.substr(5), value: attr.value});
+ var toret = new AttributesList(),
+ classParts = [''].concat(this.getClass().split('.')),
+ classCurrent, classDesc;
+
+ classParts.forEach(function(part) {
+ classCurrent = classCurrent ? classCurrent + '.' + part : part;
+ classDesc = this.document.options.wlxmlClasses[classCurrent];
+ if(classDesc) {
+ _.keys(classDesc.attrs).forEach(function(attrName) {
+ toret[attrName] = _.extend({value: this.getAttr('meta-' + attrName)}, classDesc.attrs[attrName]);
+ }.bind(this));