Putting widgets after content wrapper makes sure the whole node wrapper,
when displayed inline, starts on the same line as its first real content.
Without this change, the zero length widgets wrapper could land at the
end of one line while content wrapper landed on the next one. This caused
the whole node wrapper to start above real content making widgets
positioning invalid.
contentContainer = $('<div>')
.attr('document-element-content', '');
- wrapper.append(widgetsContainer, contentContainer);
+ wrapper.append(contentContainer, widgetsContainer);
widgetsContainer.find('*').add(widgetsContainer).attr('tabindex', -1);
return wrapper;
},