From 1cbbe5f31fb7ba7acf208759387e210284870dba Mon Sep 17 00:00:00 2001 From: YaoiFangirl420 <48789208+YaoiFangirl420@users.noreply.github.com> Date: Thu, 4 Apr 2019 02:26:58 -0700 Subject: [PATCH] Add i18n and fix method declaration Add i18n entries for rotating images; fix the way `getName` is defined Signed-off-by: YaoiFangirl420 <48789208+YaoiFangirl420@users.noreply.github.com> --- src/components/views/elements/ImageView.js | 8 ++++---- src/i18n/strings/en_EN.json | 2 ++ 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/src/components/views/elements/ImageView.js b/src/components/views/elements/ImageView.js index 83f07df34e..0eb0f75c1f 100644 --- a/src/components/views/elements/ImageView.js +++ b/src/components/views/elements/ImageView.js @@ -88,13 +88,13 @@ export default class ImageView extends React.Component { }); }; - getName = () => { + getName() { let name = this.props.name; if (name && this.props.link) { name = { name }; } return name; - }; + } rotateCounterClockwise = () => { const cur = this.state.rotationDegrees; @@ -196,10 +196,10 @@ export default class ImageView extends React.Component {
- { + { - { + { { diff --git a/src/i18n/strings/en_EN.json b/src/i18n/strings/en_EN.json index 7dea247a7e..3dcc1691b8 100644 --- a/src/i18n/strings/en_EN.json +++ b/src/i18n/strings/en_EN.json @@ -958,6 +958,8 @@ "Home": "Home", "You cannot delete this image. (%(code)s)": "You cannot delete this image. (%(code)s)", "Uploaded on %(date)s by %(user)s": "Uploaded on %(date)s by %(user)s", + "Rotate counter-clockwise": "Rotate counter-clockwise", + "Rotate clockwise": "Rotate clockwise", "Download this file": "Download this file", "Integrations Error": "Integrations Error", "Manage Integrations": "Manage Integrations",