Add vform format to HTMLForm, use in PasswordReset
This adds a new 'vform' display format to HTMLForm which styles forms
using it in the new compact stacked vertical format:
* Applies class mw-ui-vform to the form.
* Gives Submit button 'mw-ui-{button,big,block,primary}' classes and
spaced block styling.
* Styles the error class.
* HTMLForm divs are too nested to get styling "for free", so add
.mw-ui-vform-div selector to Agora CSS and apply this class to form
divs (maybe not ideal fix).
* HTMLCheckField nests the checkbox inside label.
* Add method to setShowEmptyLabel(); vform format sets this false as it
doesn't want generated HTML for empty labels adding vertical space.
In FormSpecialPage, don't set the wrapper legend with its old-school
line around the form if in vform style.
Build new mediawiki.ui CSS with the .mw-ui-vform-div styling
Special:PasswordReset requests the new styling with setDisplayFormat( 'vform' )
and turns off the wrapper legend.
(This version of the patch doesn't switch the default format of HTMLForm,
individual forms have to choose it.)
Notes are at
https://www.mediawiki.org/wiki/Agora/Engineering#HTMLForm_Issues
Change-Id: Id03d185bbee990595bfc469a61163cc598fc3441