Add autosave on design notes
What does this MR do and why?
This change leverages localStorage autosave on design notes to save comments locally before they're posted to permit getting back to it easily and avoid losing content.
Comments are saved, one per existing thread and one new comment per design.
Screenshots or screen recordings
Before | After |
---|---|
Design_autosave_-_Before | Design_autosave_-_After |
How to set up and validate locally
- Visit an issue with a design or upload a design (image) to an issue
- Open the design
- Click somewhere on the image to start a discussion
- Type a comment without submitting it
- Reload the page or close the tab and reopen it
- When attempting to start a discussion, the previously non submitted comment should be loaded in the textarea field.
- Start multiple discussion threads and repeat the above steps under each thread.
- When reloading an attempting to reply to a thread, each textarea field should load the corresponding non submitted comment to each thread.
- Same with a new comment. The data is separate from an existing discussion thread.
MR acceptance checklist
This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.
-
I have evaluated the MR acceptance checklist for this MR.
Related to #55677 (closed)
Edited by Florie Guibert