HTMLForm: Add documentation for sections and subsections

Change-Id: I6cc496476e980f0ee0dfd5d6c15e59ef9eb14aa0
This commit is contained in:
Thalia 2021-01-04 18:15:32 +00:00
parent fd4b04e08b
commit 10e043b9c7

View file

@ -115,6 +115,13 @@ use MediaWiki\HookContainer\ProtectedHookAccessorTrait;
* The expressions will be given to a JavaScript frontend
* module which will continually update the field's
* visibility.
* 'section' -- A string name for the section of the form to which the field
* belongs. Subsections may be added using the separator '/', e.g.:
* 'section' => 'section1/subsection1'
* More levels may be added, e.g.:
* 'section' => 'section1/subsection2/subsubsection1'
* The message key for a section or subsection header is built from
* its name and the form's message prefix (if present).
*
* Since 1.20, you can chain mutators to ease the form generation:
* @par Example:
@ -129,8 +136,6 @@ use MediaWiki\HookContainer\ProtectedHookAccessorTrait;
* method calls done after that would simply not be part of the form :(
*
* @stable to extend
*
* @todo Document 'section' / 'subsection' stuff
*/
class HTMLForm extends ContextSource {
use ProtectedHookAccessorTrait;