fnp
/
fnpeditor.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
refactor
[fnpeditor.git]
/
src
/
editor
/
modules
/
nodePane
/
metaWidget
/
metaWidget.js
diff --git
a/src/editor/modules/nodePane/metaWidget/metaWidget.js
b/src/editor/modules/nodePane/metaWidget/metaWidget.js
index
14ba7b6
..
7561acd
100644
(file)
--- a/
src/editor/modules/nodePane/metaWidget/metaWidget.js
+++ b/
src/editor/modules/nodePane/metaWidget/metaWidget.js
@@
-11,9
+11,9
@@
var templates = {
string: _.template(stringFieldTpl)
};
string: _.template(stringFieldTpl)
};
-var getAttrElement = function(attr) {
+var getAttrElement = function(attr
Name, attr
) {
var toret = $('<div>');
var toret = $('<div>');
- toret.append(templates.string({name: attr
.n
ame, value: attr.value}));
+ toret.append(templates.string({name: attr
N
ame, value: attr.value}));
return toret;
};
return toret;
};
@@
-23,9
+23,9
@@
var MetaWidget = Backbone.View.extend({
},
initialize: function() {
var view = this;
},
initialize: function() {
var view = this;
-
this.options.attrs.forEach(function(attr
) {
- view.$el.append(getAttrElement(attr));
- });
+
_.keys(this.options.attrs).forEach(function(attrName
) {
+ view.$el.append(getAttrElement(attr
Name, this.options.attrs[attrName]
));
+ }
.bind(this)
);
},
onMetaFieldChange: function(e) {
var target = $(e.target);
},
onMetaFieldChange: function(e) {
var target = $(e.target);