Page MenuHomePhabricator

VisualEditor: Paragraph generated for an empty document should not be unwrapped on the way out
Closed, ResolvedPublic


Currently, the DOM->data converter generates an empty paragraph if the input is an empty string. This paragraph is marked with .internal.generated=='wrapper', so it's unwrapped on the way out. This is bad because we lose change markers that way, and have no way to propagate them.

Instead, it should use another generated marker which causes the paragraph to be unwrapped only if it is empty, and be preserved if it's not empty.

Version: unspecified
Severity: normal