Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Page add block modal cancel button #3235

Open
Katrienvh opened this issue Nov 23, 2020 · 9 comments
Open

Page add block modal cancel button #3235

Katrienvh opened this issue Nov 23, 2020 · 9 comments
Labels
Feature Restructure Core Issues related to the restructure core branch

Comments

@Katrienvh
Copy link
Contributor

Feature Request

Q A
New Feature no
RFC no
BC Break no

Summary

Before the upgrade to this modal with the new editor it was possible to cancel the modal or close it with the icon at the top. The cancel button and the close icon should cancel the actions. Now we only can 'save'. There is no other action.

We need a close/cancel button again.

@Katrienvh Katrienvh added Feature Restructure Core Issues related to the restructure core branch labels Nov 23, 2020
@carakas
Copy link
Member

carakas commented Nov 23, 2020

The reason why there isn't one at the moment is that you are working directly in the form. If you make a close button you'll need to write extra js to make sure the content that was there before you made changes is placed back

@Katrienvh
Copy link
Contributor Author

Well that's not a great reason to not add it I my eyes? Now it's not use friendly that there is no possibility to go back, cancel or close.

@carakas
Copy link
Member

carakas commented Nov 23, 2020

I didn't say it shouldn't be there.
I didn't add it while making it because there was no time left to implement this properly. Adding a close button that will still save the content of that part of the page would have been even more confusing

@Katrienvh
Copy link
Contributor Author

I see, it was not clear to me whether it was an argument for or against the issue. So you agree that it should be added?

@carakas
Copy link
Member

carakas commented Nov 23, 2020

I just added that comment there to prevent somebody just adding a close button without the extra functionality that is needed.
Yes, I think it would indeed be more user-friendly to add that

@carakas carakas added this to the Restructure Core milestone Nov 23, 2020
@carakas carakas added this to To do in Restructure Core via automation Nov 23, 2020
@tijsverkoyen tijsverkoyen moved this from To be discussed to To Do in Restructure Core Feb 9, 2021
@tijsverkoyen
Copy link
Member

@sanderdlm
Copy link
Contributor

@carakas I haven't been able to find a good solution for this. My idea was to hook into the Bootstrap modal shown event, use the save method of the editor inside the modal to get the initial JSON data and store it in a variable. On cancel/close, the JSON inside that variable could be restored instead of whatever the actual editor output is. I wasted quite a bit of time trying to work with the editor and new blocks system, but I haven't been able to get it all to work. Maybe we should have a call about this so you can show me around in the editor code?

@sanderdlm
Copy link
Contributor

@carakas have you been able to take a look at this? Do you think it should still be on the roadmap for restructure core?

@carakas
Copy link
Member

carakas commented Feb 9, 2022

Not my priority now, currently focused on symfony 6

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Feature Restructure Core Issues related to the restructure core branch
Projects
Development

No branches or pull requests

4 participants