summaryrefslogtreecommitdiffstats
path: root/web
diff options
context:
space:
mode:
authorElias Nahum <nahumhbl@gmail.com>2016-02-01 17:52:43 -0300
committerElias Nahum <nahumhbl@gmail.com>2016-02-01 17:52:43 -0300
commite7f409a3c7a92d50cf857b808b61f4d5aadea8c3 (patch)
tree30e65cff9d06664690623df1d0c54526e0c24171 /web
parent3f91bc2df2c6f9d8437f258233609e9801b7f8f6 (diff)
downloadchat-e7f409a3c7a92d50cf857b808b61f4d5aadea8c3.tar.gz
chat-e7f409a3c7a92d50cf857b808b61f4d5aadea8c3.tar.bz2
chat-e7f409a3c7a92d50cf857b808b61f4d5aadea8c3.zip
fix hour12 React warning for FormattedDate
Diffstat (limited to 'web')
-rw-r--r--web/react/components/file_upload.jsx6
-rw-r--r--web/react/components/rhs_comment.jsx2
-rw-r--r--web/react/components/rhs_root_post.jsx2
-rw-r--r--web/react/components/search_results_item.jsx2
-rw-r--r--web/static/i18n/en.json1
-rw-r--r--web/static/i18n/es.json2
6 files changed, 10 insertions, 5 deletions
diff --git a/web/react/components/file_upload.jsx b/web/react/components/file_upload.jsx
index 2f9146193..626dbc5b3 100644
--- a/web/react/components/file_upload.jsx
+++ b/web/react/components/file_upload.jsx
@@ -20,6 +20,10 @@ const holders = defineMessages({
fileAbove: {
id: 'file_upload.fileAbove',
defaultMessage: 'File above {max}MB could not be uploaded: {filename}'
+ },
+ pasted: {
+ id: 'file_upload.pasted',
+ defaultMessage: 'Image Pasted at '
}
});
@@ -237,7 +241,7 @@ class FileUpload extends React.Component {
min = String(d.getMinutes());
}
- var name = 'Image Pasted at ' + d.getFullYear() + '-' + d.getMonth() + '-' + d.getDate() + ' ' + hour + '-' + min + '.' + ext;
+ var name = formatMessage(holders.pasted) + d.getFullYear() + '-' + d.getMonth() + '-' + d.getDate() + ' ' + hour + '-' + min + '.' + ext;
formData.append('files', file, name);
formData.append('client_ids', clientId);
diff --git a/web/react/components/rhs_comment.jsx b/web/react/components/rhs_comment.jsx
index 1dd8354d7..1addebbe4 100644
--- a/web/react/components/rhs_comment.jsx
+++ b/web/react/components/rhs_comment.jsx
@@ -231,7 +231,7 @@ class RhsComment extends React.Component {
day='numeric'
month='long'
year='numeric'
- hour12='true'
+ hour12={true}
hour='2-digit'
minute='2-digit'
/>
diff --git a/web/react/components/rhs_root_post.jsx b/web/react/components/rhs_root_post.jsx
index bc772aaa5..f9f7f8f81 100644
--- a/web/react/components/rhs_root_post.jsx
+++ b/web/react/components/rhs_root_post.jsx
@@ -223,7 +223,7 @@ export default class RhsRootPost extends React.Component {
day='numeric'
month='long'
year='numeric'
- hour12='true'
+ hour12={true}
hour='2-digit'
minute='2-digit'
/>
diff --git a/web/react/components/search_results_item.jsx b/web/react/components/search_results_item.jsx
index a0b252d25..0ad091d5b 100644
--- a/web/react/components/search_results_item.jsx
+++ b/web/react/components/search_results_item.jsx
@@ -81,7 +81,7 @@ export default class SearchResultsItem extends React.Component {
day='numeric'
month='long'
year='numeric'
- hour12='true'
+ hour12={true}
hour='2-digit'
minute='2-digit'
/>
diff --git a/web/static/i18n/en.json b/web/static/i18n/en.json
index 78e4c625d..d6401ab6e 100644
--- a/web/static/i18n/en.json
+++ b/web/static/i18n/en.json
@@ -513,6 +513,7 @@
"file_upload.limited": "Uploads limited to {count} files maximum. Please use additional posts for more files.",
"file_upload.filesAbove": "Files above {max}MB could not be uploaded: {filenames}",
"file_upload.fileAbove": "File above {max}MB could not be uploaded: {filename}",
+ "file_upload.pasted": "Image Pasted at ",
"find_team.submitError": "Please enter a valid email address",
"find_team.placeholder": "you@domain.com",
"find_team.findTitle": "Find Your Team",
diff --git a/web/static/i18n/es.json b/web/static/i18n/es.json
index 6b5eee94a..cb3e8a199 100644
--- a/web/static/i18n/es.json
+++ b/web/static/i18n/es.json
@@ -545,7 +545,7 @@
"file_upload.fileAbove": "No se puede subir un archivo que pesa más de {max}MB: {filename}",
"file_upload.filesAbove": "No se pueden subir archivos de más de {max}MB: {filenames}",
"file_upload.limited": "Se pueden subir un máximo de {count} archivos. Por favor envía otros mensajes para adjuntar más archivos.",
- "file_upload.pasted": "Imagen Pegada en ",
+ "file_upload.pasted": "Imagen Pegada el ",
"find_team.email": "Correo electrónico",
"find_team.findDescription": "Enviamos un correo electrónico con los equipos a los que perteneces.",
"find_team.findTitle": "Encuentra tu equipo",