DM is an environment for the study and annotation of images and texts. It is a suite of tools, enabling scholars to gather and organize the evidence necessary to support arguments based in digitized resources.
Adds error reporting for text resources when a save request is unsuccessful. In the event of a save failure, an alert will appear encouraging the user to refresh their browser window, and the text resource's status bar will read "Save failed" instead of "Saved."
What issues does it address?
Closes #153
How to test
On staging, open a project with a text resource and make some changes to its text. Confirm that the status bar at the bottom of the text resource viewer reads "Saving..." after a change is made and then "Saved" after a moment.
Break the connection between the front-end and the server by turning off your internet connection. Then add more text to the same resource. An alert should fire telling you there's been a save error.
Close the alert and check that the text resource's status bar now reads "Save failed"
Instead of refreshing your browser window, turn your internet connection back on. Make another change to the resource's text. The status bar should return to its "Saving..." / "Saved" display.
What does this PR do?
Adds error reporting for text resources when a save request is unsuccessful. In the event of a save failure, an alert will appear encouraging the user to refresh their browser window, and the text resource's status bar will read "Save failed" instead of "Saved."
What issues does it address?
Closes #153
How to test