summaryrefslogtreecommitdiff
path: root/public/assets/js/lib/views/details
diff options
context:
space:
mode:
Diffstat (limited to 'public/assets/js/lib/views/details')
-rw-r--r--public/assets/js/lib/views/details/comments.js8
-rw-r--r--public/assets/js/lib/views/details/files.js5
2 files changed, 9 insertions, 4 deletions
diff --git a/public/assets/js/lib/views/details/comments.js b/public/assets/js/lib/views/details/comments.js
index b1c86bb..1e8d127 100644
--- a/public/assets/js/lib/views/details/comments.js
+++ b/public/assets/js/lib/views/details/comments.js
@@ -14,8 +14,8 @@ var CommentsView = FormView.extend({
this.$formRow = this.$("#comment_form")
},
- load: function(comments, thread){
-console.log(comments)
+ load: function(comments, thread) {
+ // console.log(comments)
thread = this.thread = thread || this.thread
if (thread.settings.hootbox) {
comments
@@ -35,13 +35,13 @@ console.log(comments)
}
},
- parse: function(comment){
+ parse: function(comment) {
if (! comment.comment.length) return $('')
var datetime = verbose_date(comment.date, true)
var t = this.template.replace(/{{image}}/g, profile_image(comment.username))
.replace(/{{username}}/g, comment.username)
.replace(/{{id}}/g, comment.id)
- .replace(/{{comment}}/g, tidy_urls(comment.comment))
+ .replace(/{{comment}}/g, function(){ return tidy_urls(comment.comment) })
.replace(/{{date}}/g, datetime[0])
.replace(/{{time}}/g, datetime[1])
var $t = $(t)
diff --git a/public/assets/js/lib/views/details/files.js b/public/assets/js/lib/views/details/files.js
index 44c65c4..98b9350 100644
--- a/public/assets/js/lib/views/details/files.js
+++ b/public/assets/js/lib/views/details/files.js
@@ -171,10 +171,15 @@ var FilesView = FormView.extend({
if (dateClass && this.reverse) {
dateClass += ' italic'
}
+ var sizeClass = this.sort === 'size' ? 'bold' : ''
+ if (sizeClass && this.reverse) {
+ sizeClass += ' italic'
+ }
var t = this.templateTotal.replace(/{{size_class}}/g, size[0])
.replace(/{{size}}/g, size[1])
.replace(/{{nameClass}}/g, nameClass)
.replace(/{{dateClass}}/g, dateClass)
+ .replace(/{{sizeClass}}/g, sizeClass)
this.$el.append(t)
},