Merge "HTMLForm: Remove parameters 'notice', 'notice-messages', 'notice-message'"
[lhc/web/wiklou.git] / includes / htmlform / HTMLForm.php
index 0fa0406..c6882c4 100644 (file)
@@ -57,10 +57,12 @@ use Wikimedia\ObjectFactory;
  *    'cssclass'            -- CSS class
  *    'csshelpclass'        -- CSS class used to style help text
  *    'dir'                 -- Direction of the element.
- *    'options'             -- associative array mapping labels to values.
+ *    'options'             -- associative array mapping raw text labels to values.
  *                             Some field types support multi-level arrays.
+ *                             Overwrites 'options-message'.
  *    'options-messages'    -- associative array mapping message keys to values.
  *                             Some field types support multi-level arrays.
+ *                             Overwrites 'options' and 'options-message'.
  *    'options-message'     -- message key or object to be parsed to extract the list of
  *                             options (like 'ipbreason-dropdown').
  *    'label-message'       -- message key or object for a message to use as the label.
@@ -79,11 +81,6 @@ use Wikimedia\ObjectFactory;
  *    'help-inline'         -- Whether help text (defined using options above) will be shown
  *                             inline after the input field, rather than in a popup.
  *                             Defaults to true. Only used by OOUI form fields.
- *    'notice'              -- message text for a message to use as a notice in the field.
- *                             Currently used by OOUI form fields only.
- *    'notice-messages'     -- array of message keys/objects to use for notice.
- *                             Overrides 'notice'.
- *    'notice-message'      -- message key or object to use as a notice.
  *    'required'            -- passed through to the object, indicating that it
  *                             is a required field.
  *    'size'                -- the length of text fields
@@ -175,6 +172,7 @@ class HTMLForm extends ContextSource {
                'title' => HTMLTitleTextField::class,
                'user' => HTMLUserTextField::class,
                'usersmultiselect' => HTMLUsersMultiselectField::class,
+               'titlesmultiselect' => HTMLTitlesMultiselectField::class,
        ];
 
        public $mFieldData;
@@ -1029,6 +1027,7 @@ class HTMLForm extends ContextSource {
         * @param bool|string|array|Status $submitResult Output from HTMLForm::trySubmit()
         *
         * @return string HTML
+        * @return-taint escaped
         */
        public function getHTML( $submitResult ) {
                # For good measure (it is the default)
@@ -1832,7 +1831,7 @@ class HTMLForm extends ContextSource {
         *
         * @param string $key
         *
-        * @return string
+        * @return string Plain text (not HTML-escaped)
         */
        public function getLegend( $key ) {
                return $this->msg( "{$this->mMessagePrefix}-$key" )->text();