Right now all of this logic is done through direct editing of the template, which causes problems with the image modal because its now bound to localized text, and it also makes some of the text in the modals un-localizable. We should change this logic:
To instead of directly using addClass, removeClass, and text, it should set some variables on the view so these can be handled in the respective image-upload.hbs and file-upload.hbs files. This should also let us make the "Drop FIles" and "Select from Desktop" strings localizable.
Right now all of this logic is done through direct editing of the template, which causes problems with the image modal because its now bound to localized text, and it also makes some of the text in the modals un-localizable. We should change this logic:
https://github.com/webhook/webhook-cms/blob/master/app/components/file-upload.js#L67-96
To instead of directly using
addClass
,removeClass
, andtext
, it should set some variables on the view so these can be handled in the respectiveimage-upload.hbs
andfile-upload.hbs
files. This should also let us make the "Drop FIles" and "Select from Desktop" strings localizable.