See https://he.wikipedia.org/w/index.php?diff=16380129 .. there the editor deleted a category. Likely the user or VE deleted the newlines as well and the serialized result is a bit ugly where the category now ended up on the same line as a list.
The serializer should be smarter and always force a category (existing / new) onto a new line if it is preceded by modified/new content. This lets parsoid not be overly sensitive on newlines that it receives from clients in some scenarios. This is similar to T72791.