From 0300da59e28d54447278439c0107f892f059020b Mon Sep 17 00:00:00 2001 From: Arpit Jalan Date: Fri, 7 Aug 2015 22:55:49 +0530 Subject: [PATCH] UX: simplify composer title --- app/assets/javascripts/discourse/models/composer.js.es6 | 6 ++++-- config/locales/client.en.yml | 4 ++-- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/app/assets/javascripts/discourse/models/composer.js.es6 b/app/assets/javascripts/discourse/models/composer.js.es6 index edde5df3c68..18378f9aeed 100644 --- a/app/assets/javascripts/discourse/models/composer.js.es6 +++ b/app/assets/javascripts/discourse/models/composer.js.es6 @@ -101,12 +101,13 @@ const Composer = RestModel.extend({ actionTitle: function() { const topic = this.get('topic'); - let postLink, topicLink; + let postLink, topicLink, usernameLink; if (topic) { const postNumber = this.get('post.post_number'); postLink = "" + I18n.t("post.post_number", { number: postNumber }) + ""; topicLink = " " + (Handlebars.Utils.escapeExpression(topic.get('title'))) + ""; + usernameLink = "" + this.get('post.username') + ""; } let postDescription; @@ -116,7 +117,8 @@ const Composer = RestModel.extend({ postDescription = I18n.t('post.' + this.get('action'), { link: postLink, replyAvatar: Discourse.Utilities.tinyAvatar(post.get('avatar_template')), - username: this.get('post.username') + username: this.get('post.username'), + usernameLink }); if (!Discourse.Mobile.mobileView) { diff --git a/config/locales/client.en.yml b/config/locales/client.en.yml index 844729482e3..a08fb767b3c 100644 --- a/config/locales/client.en.yml +++ b/config/locales/client.en.yml @@ -1251,8 +1251,8 @@ en: other: "You have selected {{count}} posts." post: - reply: "Replying to {{link}} {{replyAvatar}} {{username}}" - reply_topic: "Reply to {{link}}" + reply: " {{replyAvatar}} {{usernameLink}}" + reply_topic: " {{link}}" quote_reply: "quote reply" edit: "Editing {{link}} {{replyAvatar}} {{username}}" edit_reason: "Reason: "