- Issue created by @rex.barkdoll
This would be helpful for me too. Thanks for your great work on this module!
I'm trying to use the grid feature, which is really nice and convenient. The issue is that there are times where I need to put certain USWDS elements inside a grid column and it unwraps them upon saving the page and editing it again. The elements are placed outside the column, but are left inside the grid row and the parent-most element (usually a Div) has been removed while all child elements of the parent element are still there. In the example below, the usa-card element is removed while the usa-card__header and usa-card__body remain
Also note, the only 2 Content Editor filters that we have turned on are Display embedded paragraphs and Display embedded entities, no other HTML correction or anything is enabled.
Step 1, use the USWDS Grid button to insert a 2 (or any #) column grid.
Step 2: Insert a USWDS element, like a card. Note that the card doesn't need to be the first element within a column for the unwrapping to occur. It's now time to save the page, you'll notice that the page looks correct, no change to the code has taken place.
Step 3: Edit the page and now you'll notice that the WYSYWIG editor looks drastically different, switch to code view and you'll see that the card element's top div was removed, the remaining elements have been moved out of their column and into the grid-row container
I'm not sure why this is happening. One thing I have found is that if I remove the top ck-widget element and remove the data elements and ck-widget class from the grid-row - it stops breaking things, however, I lose the nice WYSYWIG ability to modify the grid.
I'm not sure what suggestions to make, hopefully this is enough information to identify the issue and find a path to resolving it.
Active
2.0
Code
This would be helpful for me too. Thanks for your great work on this module!