From bdd4bb00032bfc47e366f68d637959be108484ab Mon Sep 17 00:00:00 2001 From: Baris Soner Usakli Date: Fri, 31 Jan 2014 11:59:35 -0500 Subject: [PATCH 1/2] closes #920' --- public/language/en_GB/global.json | 7 ++++++- public/language/en_GB/topic.json | 1 - public/language/en_GB/user.json | 3 ++- public/src/forum/accountheader.js | 21 ++++++++++++--------- public/templates/account.tpl | 6 +++--- 5 files changed, 23 insertions(+), 15 deletions(-) diff --git a/public/language/en_GB/global.json b/public/language/en_GB/global.json index 2796b08ed0..93df8c550b 100644 --- a/public/language/en_GB/global.json +++ b/public/language/en_GB/global.json @@ -51,5 +51,10 @@ "alert.follow": "You are now following %1!", "posts": "Posts", - "views": "Views" + "views": "Views", + + "posted": "posted", + "in": "in", + + "recentposts": "Recent Posts" } diff --git a/public/language/en_GB/topic.json b/public/language/en_GB/topic.json index 09a9eda671..a37a4a791f 100644 --- a/public/language/en_GB/topic.json +++ b/public/language/en_GB/topic.json @@ -41,7 +41,6 @@ "favourites.not_logged_in.message": "Please log in in order to favourite this post", "favourites.has_no_favourites": "You don't have any favourites, favourite some posts to see them here!", - "posted_by": "posted by", "loading_more_posts": "Loading More Posts", "move_topic": "Move Topic", "move_post": "Move Post", diff --git a/public/language/en_GB/user.json b/public/language/en_GB/user.json index dc7412735a..0bf297ce54 100644 --- a/public/language/en_GB/user.json +++ b/public/language/en_GB/user.json @@ -12,6 +12,7 @@ "profile_views": "Profile views", "reputation": "Reputation", "posts": "Posts", + "favourites":"Favourites", "followers": "Followers", "following": "Following", "signature": "Signature", @@ -30,7 +31,7 @@ "upload_a_picture": "Upload a picture", "image_spec": "You may only upload PNG, JPG, or GIF files under 256kb.", - "settings": "settings", + "settings": "Settings", "show_email": "Show My Email", "has_no_follower": "This user doesn't have any followers :(", diff --git a/public/src/forum/accountheader.js b/public/src/forum/accountheader.js index 14719d03f2..1f5c552783 100644 --- a/public/src/forum/accountheader.js +++ b/public/src/forum/accountheader.js @@ -28,15 +28,18 @@ define(function() { AccountHeader.createMenu = function() { var userslug = $('.account-username-box').attr('data-userslug'); - var links = $(''); - - $('.account-username-box').append(links); + + var html = '' + + translator.translate(html, function(translatedHtml) { + $('.account-username-box').append(translatedHtml); + }); } return AccountHeader; diff --git a/public/templates/account.tpl b/public/templates/account.tpl index 98cab8d066..c457b7fd90 100644 --- a/public/templates/account.tpl +++ b/public/templates/account.tpl @@ -110,7 +110,7 @@
-

Recent Posts

+

[[global:recentposts]]

@@ -118,8 +118,8 @@

{posts.content}

- posted - in + [[global:posted]] + [[global:in]] {posts.categoryName} From c122492470706243cc5e5d0879740e6a662b41bb Mon Sep 17 00:00:00 2001 From: Baris Soner Usakli Date: Fri, 31 Jan 2014 12:11:49 -0500 Subject: [PATCH 2/2] added back the template if --- public/templates/topic.tpl | 5 +++-- src/topics.js | 2 +- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/public/templates/topic.tpl b/public/templates/topic.tpl index 51a1d6da32..dd4d539786 100644 --- a/public/templates/topic.tpl +++ b/public/templates/topic.tpl @@ -111,8 +111,9 @@ - - + + +
diff --git a/src/topics.js b/src/topics.js index 99fa141625..e609889058 100644 --- a/src/topics.js +++ b/src/topics.js @@ -381,7 +381,7 @@ var async = require('async'), var pid = postData[i].pid; postData[i].favourited = fav_data[pid]; postData[i].display_moderator_tools = (current_user != 0) && privileges[pid].editable; - postData[i].display_move_tools = privileges[pid].move ? '' : 'hidden'; + postData[i].display_move_tools = privileges[pid].move; if(parseInt(postData[i].deleted, 10) === 1 && !privileges[pid].view_deleted) { postData[i].content = 'This post is deleted!'; }