UX: don't show an empty list when all extensions are authorized

This commit is contained in:
Régis Hanol 2015-10-22 20:11:17 +02:00
parent 6c29781687
commit 0ea54e9255
2 changed files with 5 additions and 5 deletions

View file

@ -27,9 +27,9 @@ export default ModalBodyView.extend({
},
tip: function() {
const source = this.get("controller.local") ? "local" : "remote",
opts = { authorized_extensions: Discourse.Utilities.authorizedExtensions() };
return uploadTranslate(source + "_tip", opts);
const source = this.get("controller.local") ? "local" : "remote";
const authorized_extensions = Discourse.Utilities.authorizesAllExtensions() ? "" : `(${Discourse.Utilities.authorizedExtensions()})`;
return uploadTranslate(source + "_tip", { authorized_extensions });
}.property("controller.local"),
hint: function() {

View file

@ -967,9 +967,9 @@ en:
from_my_computer: "From my device"
from_the_web: "From the web"
remote_tip: "link to image"
remote_tip_with_attachments: "link to image or file ({{authorized_extensions}})"
remote_tip_with_attachments: "link to image or file {{authorized_extensions}}"
local_tip: "select images from your device"
local_tip_with_attachments: "select images or files from your device ({{authorized_extensions}})"
local_tip_with_attachments: "select images or files from your device {{authorized_extensions}}"
hint: "(you can also drag & drop into the editor to upload them)"
hint_for_supported_browsers: "you can also drag and drop or paste images into the editor"
uploading: "Uploading"