* @param HTMLForm $form
*/
protected function alterForm( HTMLForm $form ) {
- $form->setWrapperLegendMsg( 'blockip-legend' );
$form->setHeaderText( '' );
$form->setSubmitDestructive();
}
}
+ protected function getDisplayFormat() {
+ return 'ooui';
+ }
+
/**
* Get the HTMLForm descriptor array for the block form
* @return array
$a = [
'Target' => [
- 'type' => 'text',
+ 'type' => 'user',
+ 'ipallowed' => true,
+ 'iprange' => true,
'label-message' => 'ipaddressorusername',
'id' => 'mw-bi-target',
'size' => '45',
'autofocus' => true,
'required' => true,
'validation-callback' => [ __CLASS__, 'validateTargetField' ],
- 'cssclass' => 'mw-autocomplete-user', // used by mediawiki.userSuggest
],
'Expiry' => [
'type' => !count( $suggestedDurations ) ? 'text' : 'selectorother',
'type' => 'hidden',
'default' => '',
'label-message' => 'ipb-confirm',
+ 'cssclass' => 'mw-block-confirm',
];
$this->maybeAlterFormDefaults( $a );
* @return string
*/
protected function preText() {
- $this->getOutput()->addModules( [ 'mediawiki.special.block', 'mediawiki.userSuggest' ] );
+ $this->getOutput()->addModules( [ 'mediawiki.special.block' ] );
$blockCIDRLimit = $this->getConfig()->get( 'BlockCIDRLimit' );
$text = $this->msg( 'blockiptext', $blockCIDRLimit['IPv4'], $blockCIDRLimit['IPv6'] )->parse();