Vulcan/packages/telescope-posts/lib/client/templates/post_item.js

21 lines
523 B
JavaScript
Raw Normal View History

2014-07-04 14:07:50 +09:00
var post = {};
Template.post_item.created = function () {
2014-07-04 14:07:50 +09:00
post = this.data;
2013-10-28 13:35:20 +09:00
};
Template.post_item.helpers({
2014-07-08 09:06:49 +09:00
moduleContext: function () { // not used for now
var module = this;
module.templateClass = Telescope.utils.camelToDash(this.template) + ' ' + this.position + ' cell';
2014-07-08 09:06:49 +09:00
module.post = post;
return module;
2014-07-07 11:51:59 +09:00
},
postClass: function () {
var post = this;
var postClass = "author-"+post.author;
postClass = Telescope.callbacks.run("postClass", postClass);
return postClass;
}
2012-10-01 14:52:32 +09:00
});