User story: As a Commons user, when I submit structured data for a file and the process fails, I need to see an informative error message so I can fix the problem.
We have this: When the submit() method of the StatementWidget fails, an error message is posted to the DOM for a split second then is removed before the user can read it and the offending element is removed from the page.
We want this: When submit fails, the offending element should remain in place and an error message should be shown to the user explaining what happened and, if applicable, how they can fix it. For the time being, we can show a standard error message above the Publish button as depicted here:
- When the API call to Wikibase fails on publish, the user is informed about what happened and what they should do (come back later, contact someone, fix an error, etc.)
During development, please test the following:
- Test this feature while logged in AND logged out
- Test this feature on at least one mobile browser
- Test that this feature works on the file page only