12 {name: "data", tag: null, allowHtml: true},
13 {classes: "info", components: [
14 {tag: null, content: "Posted "},
15 {name: "date", tag: null},
16 {tag: null, content: ". "},
17 {name: "permalink", kind: "blerg.Link", content: "[permalink]"},
18 {tag: null, content: " "},
19 {name: "reply", kind: "blerg.Link", content: "[reply]", onNavigate: "postPopup"}
23 this.inherited(arguments);
25 this.timestampChanged();
28 dataChanged: function() {
29 this.$.data.setContent(blerg.Util.blergFormat(this.data));
31 timestampChanged: function() {
32 this.$.date.setContent(new Date(this.timestamp * 1000).toString());
34 authorChanged: function() {
37 recordChanged: function() {
40 updateLinks: function() {
41 this.$.permalink.setHref(baseURL + enyo.macroize("/#{$author}/{$record}", this));
43 postPopup: function() {
44 this.bubble('onPostVisibility', {
46 data: enyo.macroize("@{$author}/{$record}: ", this),
47 replyto: this.$.data.getContent()
54 name: "blerg.TagRecord",
57 {name: "data", tag: null, allowHtml: true},
58 {classes: "info", components: [
59 {tag: null, content: "Posted by "},
60 {name: "author", kind: "blerg.Link", classes: "author ref"},
61 {tag: null, content: " at "},
62 {name: "date", tag: null},
63 {tag: null, content: ". "},
64 {name: "permalink", kind: "blerg.Link", content: "[permalink]"},
65 {tag: null, content: " "},
66 {name: "reply", kind: "blerg.Link", content: "[reply]", onNavigate: "postPopup"}
69 updateLinks: function() {
70 this.inherited(arguments);
71 this.$.author.setContent('@' + this.author);
72 this.$.author.setHref('/#' + this.author);
77 name: "blerg.BriefRecord",
80 {name: "authorlink", kind: "blerg.Link", classes: "author ref"},
81 {tag: null, content: " "},
82 {name: "data", tag: null}
84 dataChanged: function() {
85 var d = this.data.replace(/&/g, '&').replace(/</g, '<').replace(/>/g, '>');
86 this.$.data.setContent(d);
88 timestampChanged: function() { },
89 updateLinks: function() {
90 this.$.authorlink.setHref(baseURL + '/#' + this.author);
91 this.$.authorlink.setContent('@' + this.author);