FIX: Missing translations for agree/disagree details

FIX: Missing translations for agree/disagree details

diff --git a/app/assets/javascripts/admin/components/user-flag-percentage.js.es6 b/app/assets/javascripts/admin/components/user-flag-percentage.js.es6
deleted file mode 100644
index cad6cd8..0000000
--- a/app/assets/javascripts/admin/components/user-flag-percentage.js.es6
+++ /dev/null
@@ -1,53 +0,0 @@
-import computed from "ember-addons/ember-computed-decorators";
-
-export default Ember.Component.extend({
-  tagName: "",
-
-  @computed("percentage")
-  showPercentage(percentage) {
-    return percentage.total >= 3;
-  },
-
-  // We do a little logic to choose which icon to display and which text
-  @computed("agreed", "disagreed", "ignored")
-  percentage(agreed, disagreed, ignored) {
-    let total = agreed + disagreed + ignored;
-    let result = { total };
-
-    if (total > 0) {
-      result.agreed = Math.round((agreed / total) * 100);
-      result.disagreed = Math.round((disagreed / total) * 100);
-      result.ignored = Math.round((ignored / total) * 100);
-    }
-
-    let highest = Math.max(agreed, disagreed, ignored);
-    if (highest === agreed) {
-      result.icon = "thumbs-up";
-      result.className = "agreed";
-      result.label = `${result.agreed}%`;
-    } else if (highest === disagreed) {
-      result.icon = "thumbs-down";
-      result.className = "disagreed";
-      result.label = `${result.disagreed}%`;
-    } else {
-      result.icon = "external-link-alt";
-      result.className = "ignored";
-      result.label = `${result.ignored}%`;
-    }
-
-    result.title = I18n.t("admin.flags.user_percentage.summary", {
-      agreed: I18n.t("admin.flags.user_percentage.agreed", {
-        count: result.agreed
-      }),
-      disagreed: I18n.t("admin.flags.user_percentage.disagreed", {
-        count: result.disagreed
-      }),
-      ignored: I18n.t("admin.flags.user_percentage.ignored", {
-        count: result.ignored
-      }),
-      count: total
-    });
-
-    return result;
-  }
-});
diff --git a/app/assets/javascripts/admin/templates/components/user-flag-percentage.hbs b/app/assets/javascripts/admin/templates/components/user-flag-percentage.hbs
deleted file mode 100644
index b358f96..0000000
--- a/app/assets/javascripts/admin/templates/components/user-flag-percentage.hbs
+++ /dev/null
@@ -1,6 +0,0 @@
-{{#if showPercentage}}
-  <div class='user-flag-percentage' title={{percentage.title}}>
-    <span class="percentage-label {{percentage.className}}">{{percentage.label}}</span>
-    {{d-icon percentage.icon}}
-  </div>
-{{/if}}
diff --git a/app/assets/javascripts/discourse/components/user-flag-percentage.js.es6 b/app/assets/javascripts/discourse/components/user-flag-percentage.js.es6
new file mode 100644
index 0000000..874f19c7bb
--- /dev/null
+++ b/app/assets/javascripts/discourse/components/user-flag-percentage.js.es6
@@ -0,0 +1,53 @@
+import computed from "ember-addons/ember-computed-decorators";
+
+export default Ember.Component.extend({
+  tagName: "",
+
+  @computed("percentage")
+  showPercentage(percentage) {
+    return percentage.total >= 3;
+  },
+
+  // We do a little logic to choose which icon to display and which text
+  @computed("agreed", "disagreed", "ignored")
+  percentage(agreed, disagreed, ignored) {
+    let total = agreed + disagreed + ignored;
+    let result = { total };
+
+    if (total > 0) {
+      result.agreed = Math.round((agreed / total) * 100);
+      result.disagreed = Math.round((disagreed / total) * 100);
+      result.ignored = Math.round((ignored / total) * 100);
+    }
+
+    let highest = Math.max(agreed, disagreed, ignored);
+    if (highest === agreed) {
+      result.icon = "thumbs-up";
+      result.className = "agreed";
+      result.label = `${result.agreed}%`;
+    } else if (highest === disagreed) {
+      result.icon = "thumbs-down";
+      result.className = "disagreed";
+      result.label = `${result.disagreed}%`;
+    } else {
+      result.icon = "external-link-alt";
+      result.className = "ignored";
+      result.label = `${result.ignored}%`;
+    }
+
+    result.title = I18n.t("review.user_percentage.summary", {
+      agreed: I18n.t("review.user_percentage.agreed", {
+        count: result.agreed
+      }),
+      disagreed: I18n.t("review.user_percentage.disagreed", {
+        count: result.disagreed
+      }),
+      ignored: I18n.t("review.user_percentage.ignored", {
+        count: result.ignored
+      }),
+      count: total
+    });
+
+    return result;
+  }
+});
diff --git a/app/assets/javascripts/discourse/templates/components/user-flag-percentage.hbs b/app/assets/javascripts/discourse/templates/components/user-flag-percentage.hbs
new file mode 100644
index 0000000..b358f96
--- /dev/null
+++ b/app/assets/javascripts/discourse/templates/components/user-flag-percentage.hbs
@@ -0,0 +1,6 @@
+{{#if showPercentage}}
+  <div class='user-flag-percentage' title={{percentage.title}}>
+    <span class="percentage-label {{percentage.className}}">{{percentage.label}}</span>
+    {{d-icon percentage.icon}}
+  </div>
+{{/if}}
diff --git a/config/locales/client.en.yml b/config/locales/client.en.yml
index 720664b..0faff4e 100644
--- a/config/locales/client.en.yml
+++ b/config/locales/client.en.yml
@@ -372,6 +372,19 @@ en:
       filtered_topic: "You have filtered to reviewable content in a single topic."
       filtered_user: "User:"
       show_all_topics: "show all topics"
+      user_percentage:
+        summary:
+          one: "{{agreed}}, {{disagreed}}, {{ignored}} ({{count}} total flag)"
+          other: "{{agreed}}, {{disagreed}}, {{ignored}} ({{count}} total flags)"
+        agreed:
+          one: "{{count}}% agree"
+          other: "{{count}}% agree"
+        disagreed:
+          one: "{{count}}% disagree"
+          other: "{{count}}% disagree"
+        ignored:
+          one: "{{count}}% ignore"
+          other: "{{count}}% ignore"
       topics:
         topic: "Topic"
         reviewable_count: "Reviewable Count"

GitHub sha: 67454c71

This commit has been mentioned on Discourse Meta. There might be relevant details there: