- Issue created by @jessebaker
- Assigned to hemanshu_412
- 🇧🇪Belgium wim leers Ghent 🇧🇪🇪🇺
🐛 `Duplicate` action does not generate new UUIDs for components in slots, resulting in duplicate UUIDs Fixed landed and expanded the test coverage already, which should help make this issue a bit simpler :)
- Merge request !328#3472089: Improve/Refactor replaceUUIDsAndUpdateModel() and insertMultipleNodes() → (Open) created by hemanshu_412
1. Refactored the replaceUUIDsAndUpdateModel() and insertMultipleNodes() code, Converted them into a utility function and Wrote unit tests for the same.
2. As for combining insertMultipleNodes() and insertNode(), I tried multiple approaches, and some approaches and none of them approach worked properly from my end as single and multiple nodes were working, but editing the component threw errors every time when we tried to combine them.
- 🇧🇪Belgium wim leers Ghent 🇧🇪🇪🇺
Thanks!
The
UI eslint
CI job is failing though, so this is not quite ready for review yet. There are a lot of unnecessary comments on the MR.Can you delete them if you think a line of code is trivial and can be understood easily?
Also i found there are some unnecessary empty line additions in the code, you can remove them as well.Marking this needs work again.- First commit to issue fork.
- 🇮🇳India deepakkm
Just going through the cypress code and i thought i can do these changes for this ticket to get merged.
- 🇬🇧United Kingdom jessebaker
Reviewed, but further changes/refactor needed, thank you.
- 🇬🇧United Kingdom jessebaker
Taking this on as I need to use replaceUUIDsAndUpdateModel in the work on Copy/Paste that I'm doing.
- 🇬🇧United Kingdom jessebaker
Closing - the improvements to these functions was adapted and included as part of ✨ Allow copy pasting components with CTRL+C and CTRL+V Active which already landed.