Skip to content

Commit

Permalink
fix: Translate Delete Observation menu item
Browse files Browse the repository at this point in the history
  • Loading branch information
gmaclennan committed Nov 18, 2019
1 parent 5e8090c commit 9faeec9
Show file tree
Hide file tree
Showing 6 changed files with 22 additions and 3 deletions.
3 changes: 2 additions & 1 deletion .prettierrc
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
{
"singleQuote": true,
"semi": false,
"jsxBracketSameLine": true
"jsxBracketSameLine": true,
"trailingComma": "none"
}
4 changes: 4 additions & 0 deletions messages/ObservationDialog/en.json
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,10 @@
"ObservationDialog.ObservationDialog.confirmDeleteTitle": {
"message": "Delete observation?"
},
"ObservationDialog.ObservationDialog.deleteObservationMenuItem": {
"description": "Menu item to delete an observation",
"message": "Delete observation"
},
"ObservationDialog.ObservationDialog.detailsHeader": {
"description": "Header for section that includes the additional details for an observation",
"message": "Details"
Expand Down
4 changes: 4 additions & 0 deletions messages/ObservationDialog/es.json
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,10 @@
"ObservationDialog.ObservationDialog.confirmDeleteTitle": {
"message": "¿Borrar Observación?"
},
"ObservationDialog.ObservationDialog.deleteObservationMenuItem": {
"description": "Menu item to delete an observation",
"message": "Borrar Observación"
},
"ObservationDialog.ObservationDialog.detailsHeader": {
"description": "Header for section that includes the additional details for an observation",
"message": "Detalles"
Expand Down
4 changes: 4 additions & 0 deletions messages/ObservationDialog/fr.json
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,10 @@
"ObservationDialog.ObservationDialog.confirmDeleteTitle": {
"message": ""
},
"ObservationDialog.ObservationDialog.deleteObservationMenuItem": {
"description": "Menu item to delete an observation",
"message": ""
},
"ObservationDialog.ObservationDialog.detailsHeader": {
"description": "Header for section that includes the additional details for an observation",
"message": ""
Expand Down
4 changes: 4 additions & 0 deletions messages/ObservationDialog/pt.json
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,10 @@
"ObservationDialog.ObservationDialog.confirmDeleteTitle": {
"message": ""
},
"ObservationDialog.ObservationDialog.deleteObservationMenuItem": {
"description": "Menu item to delete an observation",
"message": ""
},
"ObservationDialog.ObservationDialog.detailsHeader": {
"description": "Header for section that includes the additional details for an observation",
"message": ""
Expand Down
6 changes: 4 additions & 2 deletions src/ObservationDialog/ObservationDialog.js
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,9 @@ const m = defineMessages({
// Cancel button once observation has been edited
cancelEditButton: 'Cancel',
// Save edit button
saveEditButton: 'Save'
saveEditButton: 'Save',
// Menu item to delete an observation
deleteObservationMenuItem: 'Delete observation'
})

type ImageMediaItem = {
Expand Down Expand Up @@ -223,7 +225,7 @@ const ObservationActions = ({ onDeleteClick }) => {
open={Boolean(anchorEl)}
onClose={handleClose}>
<MenuItem onClick={createHandleItemClick(onDeleteClick)}>
Delete Observation
<FormattedMessage {...m.deleteObservationMenuItem} />
</MenuItem>
</Menu>
<ConfirmDeleteDialog
Expand Down

0 comments on commit 9faeec9

Please sign in to comment.