X-Git-Url: https://git.heureux-cyclage.org/?a=blobdiff_plain;f=includes%2Fhtmlform%2FHTMLInfoField.php;h=a667653a199b409c4919c117f3e1d5a8c71f009a;hb=a2ea9f8b9289f197844e3282c2ac39e59c549996;hp=cff82025be5234e489bde42d21bf4c42a47b05b6;hpb=e92d87c26c408441d8c229fc1e9c7e0bcd93898a;p=lhc%2Fweb%2Fwiklou.git diff --git a/includes/htmlform/HTMLInfoField.php b/includes/htmlform/HTMLInfoField.php index cff82025be..a667653a19 100644 --- a/includes/htmlform/HTMLInfoField.php +++ b/includes/htmlform/HTMLInfoField.php @@ -14,6 +14,16 @@ class HTMLInfoField extends HTMLFormField { return !empty( $this->mParams['raw'] ) ? $value : htmlspecialchars( $value ); } + public function getInputOOUI( $value ) { + if ( !empty( $this->mParams['raw'] ) ) { + $value = new OOUI\HtmlSnippet( $value ); + } + + return new OOUI\LabelWidget( array( + 'label' => $value, + ) ); + } + public function getTableRow( $value ) { if ( !empty( $this->mParams['rawrow'] ) ) { return $value; @@ -23,6 +33,8 @@ class HTMLInfoField extends HTMLFormField { } /** + * @param string $value + * @return string * @since 1.20 */ public function getDiv( $value ) { @@ -34,6 +46,8 @@ class HTMLInfoField extends HTMLFormField { } /** + * @param string $value + * @return string * @since 1.20 */ public function getRaw( $value ) {