mediawiki-extensions-Visual.../modules/ve-mw/tests/dm
Máté Szabó d127dc48b7 ve.dm.MWTemplateModel: Don't add spurious empty parameters
Make ve.dm.MWTemplateModel#serialize ignore empty parameters if they were not
present in the transclusion before the edit. This avoids dirty diffs where an
user edits a template transclusion via VisualEditor, and the editor adds all
available template parameters to the edit wikitext, even if they were not
changed during the edit.

This logic was ported from the old Wikia-WMF VisualEditor project.[1]

Additionally, add tests for ve.dm.MWTemplateModel serialization.

---
[1] https://github.com/Wikia/app/pull/6450/commits/858eaa9

Bug: T101075
Change-Id: I35f8812724658904d30034db4e4684193a661c1e
2020-11-16 19:54:44 +01:00
..
nodes doc: Bump copyright year for 2020 2020-01-08 09:13:24 -08:00
ve.dm.Converter.test.js doc: Bump copyright year for 2020 2020-01-08 09:13:24 -08:00
ve.dm.Document.test.js doc: Bump copyright year for 2020 2020-01-08 09:13:24 -08:00
ve.dm.mwExample.js French spacing (mw:DisplaySpace) doesn't have mw:Placeholder any more 2020-07-15 20:14:30 +00:00
ve.dm.MWImageModel.test.js doc: Bump copyright year for 2020 2020-01-08 09:13:24 -08:00
ve.dm.MWInternalLinkAnnotation.test.js Treat links to diffs and history pages as external links 2020-04-17 22:48:14 +05:30
ve.dm.MWTemplateModel.test.js ve.dm.MWTemplateModel: Don't add spurious empty parameters 2020-11-16 19:54:44 +01:00
ve.dm.MWTransclusionModel.test.js Use autogenerated parameter info for templates without TemplateData 2020-01-31 13:43:56 +01:00
ve.dm.SurfaceFragment.test.js doc: Bump copyright year for 2020 2020-01-08 09:13:24 -08:00