Allow templating with the link widget

And add some documentation
This commit is contained in:
Jeremy Ruston
2013-03-04 11:13:10 +00:00
parent 79bb082b92
commit fc79db53ab
3 changed files with 60 additions and 17 deletions
@@ -269,6 +269,20 @@ ElementRenderer.prototype.getContextScopeId = function() {
return guidBits.join("");
};
/*
Find a named macro definition
*/
ElementRenderer.prototype.findMacroDefinition = function(name) {
var context = this.renderContext;
while(context) {
if(context.macroDefinitions && context.macroDefinitions[name]) {
return context.macroDefinitions[name];
}
context = context.parentContext;
}
return undefined;
};
exports.element = ElementRenderer
})();