ve.dm.MWBlockImageNode: Make toDomElements add more information to its output so round-tripping can work properly.

Change-Id: Ieacf9187371a1687869bcb4bb0244f1bc251a803
Merge "ve.dm.MWBlockImageNode: Make toDomElements add more information to its output so round-tripping can work properly."