alan-turing-institute / AssurancePlatform

Project to facilitate creation of Assurance Cases
MIT License
17 stars 6 forks source link

[Bug]: Revise the modal that shows when user clicks outside of edit panel #471

Closed kallewesterling closed 2 days ago

kallewesterling commented 1 month ago

Revise the modal that shows when user clicks outside of edit panel:

RichGriff commented 2 weeks ago

@kallewesterling I can easily change the text no problem. However, reversing the buttons doesnt look as good.

Current position

Screenshot 2024-06-20 at 15 32 05

New position

Screenshot 2024-06-20 at 15 33 34

Also the position will effect other places we use this modal - i.e when deleting a node or case

RichGriff commented 1 week ago

This is now in staging awaiting feedback from @kallewesterling and @chrisdburr

chrisdburr commented 1 week ago

Hmmm. I'm a little torn now.

I've done a quick search on Google to see what the common design pattern is for this, and you are right @RichGriff that the current position is the default in terms of ordering and colouring.

The only other thing I've come across is to use less ambiguous language, such as with the following example:

Screenshot 2024-06-24 at 14 52 42

So, perhaps it's best to keep the original ordering, but revise the text a little to help clarify the actions.

RichGriff commented 1 week ago

@chrisdburr @kallewesterling so the button has changed to Discard Changes - is this ok to close or do you want to change this?

chrisdburr commented 1 week ago

Please update the text for this editing modal to the following:

Screenshot 2024-06-25 at 13 40 11

Are you sure? You have changes that have not been updated, would you like to discard these changes?

And, please also add a modal for when there are unsaved changes for new elements, as there is currently no pop-up (see video).

https://github.com/alan-turing-institute/AssurancePlatform/assets/63010234/9a4b8f9a-599d-4375-8a8a-a511b444c14f

And, for consistency, please update this other modal when deleting an element (and its children). There used to be a warning about deleting all elements, but it appears to have been removed:

Screenshot 2024-06-25 at 13 40 22

Are you sure? Deleting this element will also remove all of the connected child elements. This cannot be undone.

We will need to update the text for the latter when we have addressed issue #475.

RichGriff commented 1 week ago

I have updated the Alert that pops up when editing but also the one when deleting an element - as they were in the same place. @chrisdburr just need a bug/issue raised for the alert when creating an element.

RichGriff commented 1 week ago

PR https://github.com/alan-turing-institute/AssurancePlatform/pull/512

RichGriff commented 1 week ago

Now in staging to be reviewed

RichGriff commented 1 week ago

@chrisdburr can you review this when you have some time, thanks.

chrisdburr commented 1 week ago

Thanks, @RichGriff.

I overlooked my bad grammar in one of the modals. Sorry. Please could you update the editing warning text to the following:

You have changes that have not been updated. Would you like to discard these changes?

RichGriff commented 4 days ago

In staging - @chrisdburr please review

chrisdburr commented 2 days ago

Thanks. All good.