Downcast one element and its attributes into multiple elements, or dataDowncast version of upcastDispatcher.on('element:xx') #16793
Labels
type:question
This issue asks a question (how to...).
📝 Ask a question
Hello we have an input item structure that looks like this where the dts are used for numbering and the dd is the content.
We needed to upcast a dt if it exists and the following dd, otherwise just the dd. We have this part working using the updastDispatcher.on('element:dt') and handling it all in there with our own logic.
This gets turned into an internal model like:
edit downcast works fine since each element can be downcast to its own element but for data downcast we need to go back to the original format meaning that each bar element needs to be turned into either one or two elements that are siblings depending on its attributes.
After looking through all the documentation I cannot find a similar way to do the dataDowcast like we did the upcast using a dispatcher and handling all the logic for all elements inside the foo element and just converting the entire section at once, or a way to turn the bar element into potentially two sibling elements.
Am I missing something, is there a way to accomplish this?
Thank you!
The text was updated successfully, but these errors were encountered: