====Background
In the story viewer, readers currently see a black screen when the image is no longer available in Commons. This results in a problematic story.
- https://id.wikipedia.org/wiki/Story:Sekilas_tentang_Uang
- https://id.wikipedia.org/wiki/Story:Sejarah_Museum_Monumen_Yogya_Kembali
====Steps:
- Check for the image status in Commons (make an call API to check that image is deleted)
>(option 1) can be triggered when story viewer is opened > taking this as the technical approach; if the story viewer happens to be opened more than once, it shouldn't send multiple triggers.
>(option 2) or when the story is not in cache
- Notify editor that the image is no longer available
- Add a CTA the directs the editor to the story builder to replace the image
====Description/User story
As a wikistory editor/ watcher,
I want to know when a story that I'm watching is now missing an image from Commons,
So that I can replace it with an alternative image.
====Design
- We will have different notifications for single and multiple image deletion scenarios.
- For single image deletion, include the image file name and the story name in the notification message.
- For multiple image deletion, create a bundled notification with a general message, followed by a dropdown icon and a "View deleted
images" copy. When expanded, display individual messages for each deleted image.
- Implement text truncation with ellipsis for long image and story names, allowing a maximum of 50 characters including the file name
extension. Introduce truncation when the limit is exceeded, and include a space between the ellipsis and the file extension to avoid
confusion with four consecutive periods.
- Make entire notification serve as primary link which opens story page with deleted image on story builder.
- For Single image deletion, Tap/Click on Replace image also opens story page with deleted image on story builder.
====Acceptance Criteria
- Editor gets a notification and is able to click on it to go to the story builder & replace the image.
- Watcher gets a notification and is able to click on it to go to the story builder & replace the image.
- If the story viewer is opened multiple times, there shouldn't be multiple API calls.
- If multiple images are missing, the editor should be nudged on the story builder to replace all the images before publishing.
====Test Scenarios
====Open questions
We could:
- Detect this automatically on the story viewer and prompt the story editor on Recent changes
- OR detect this automatically on the story viewer and automatically categorise it as a problematic story to have it corrected.