Alex Monk has uploaded a new change for review.
https://gerrit.wikimedia.org/r/49494
Change subject: Set initial focus on some special pages
......................................................................
Set initial focus on some special pages
* Special:BookSources - ISBN
* Special:Undelete - search prefix and reason
* Special:Userrights - username
Change-Id: Idda08ffb3ca3d84d2adb89e5bc5f8e494d491486
---
M includes/specials/SpecialBooksources.php
M includes/specials/SpecialUndelete.php
M includes/specials/SpecialUserrights.php
3 files changed, 5 insertions(+), 4 deletions(-)
git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core
refs/changes/94/49494/1
diff --git a/includes/specials/SpecialBooksources.php
b/includes/specials/SpecialBooksources.php
index 255b1b6..60ce2c0 100644
--- a/includes/specials/SpecialBooksources.php
+++ b/includes/specials/SpecialBooksources.php
@@ -119,7 +119,7 @@
$form = '<fieldset><legend>' . $this->msg(
'booksources-search-legend' )->escaped() . '</legend>';
$form .= Xml::openElement( 'form', array( 'method' => 'get',
'action' => $wgScript ) );
$form .= Html::hidden( 'title',
$this->getTitle()->getPrefixedText() );
- $form .= '<p>' . Xml::inputLabel( $this->msg(
'booksources-isbn' )->text(), 'isbn', 'isbn', 20, $this->isbn );
+ $form .= '<p>' . Xml::inputLabel( $this->msg(
'booksources-isbn' )->text(), 'isbn', 'isbn', 20, $this->isbn, array(
'autofocus' => true ) );
$form .= ' ' . Xml::submitButton( $this->msg(
'booksources-go' )->text() ) . '</p>';
$form .= Xml::closeElement( 'form' );
$form .= '</fieldset>';
diff --git a/includes/specials/SpecialUndelete.php
b/includes/specials/SpecialUndelete.php
index afc41bf..4800dc1 100644
--- a/includes/specials/SpecialUndelete.php
+++ b/includes/specials/SpecialUndelete.php
@@ -786,7 +786,8 @@
$this->getTitle()->getPrefixedDbKey() ) .
Xml::inputLabel( $this->msg( 'undelete-search-prefix'
)->text(),
'prefix', 'prefix', 20,
- $this->mSearchPrefix ) . ' ' .
+ $this->mSearchPrefix,
+ array( 'autofocus' => true ) ) . ' ' .
Xml::submitButton( $this->msg( 'undelete-search-submit'
)->text() ) .
Xml::closeElement( 'fieldset' ) .
Xml::closeElement( 'form' )
@@ -1213,7 +1214,7 @@
Xml::label( $this->msg(
'undeletecomment' )->text(), 'wpComment' ) .
"</td>
<td class='mw-input'>" .
- Xml::input(
'wpComment', 50, $this->mComment, array( 'id' => 'wpComment' ) ) .
+ Xml::input(
'wpComment', 50, $this->mComment, array( 'id' => 'wpComment', 'autofocus' =>
true ) ) .
"</td>
</tr>
<tr>
diff --git a/includes/specials/SpecialUserrights.php
b/includes/specials/SpecialUserrights.php
index 4d43baf..68b247f 100644
--- a/includes/specials/SpecialUserrights.php
+++ b/includes/specials/SpecialUserrights.php
@@ -381,7 +381,7 @@
Html::openElement( 'form', array( 'method' => 'get',
'action' => $wgScript, 'name' => 'uluser', 'id' => 'mw-userrights-form1' ) ) .
Html::hidden( 'title',
$this->getTitle()->getPrefixedText() ) .
Xml::fieldset( $this->msg( 'userrights-lookup-user'
)->text() ) .
- Xml::inputLabel( $this->msg( 'userrights-user-editname'
)->text(), 'user', 'username', 30, str_replace( '_', ' ', $this->mTarget ) ) .
' ' .
+ Xml::inputLabel( $this->msg( 'userrights-user-editname'
)->text(), 'user', 'username', 30, str_replace( '_', ' ', $this->mTarget ),
array( 'autofocus' => true ) ) . ' ' .
Xml::submitButton( $this->msg( 'editusergroup'
)->text() ) .
Html::closeElement( 'fieldset' ) .
Html::closeElement( 'form' ) . "\n"
--
To view, visit https://gerrit.wikimedia.org/r/49494
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings
Gerrit-MessageType: newchange
Gerrit-Change-Id: Idda08ffb3ca3d84d2adb89e5bc5f8e494d491486
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/core
Gerrit-Branch: master
Gerrit-Owner: Alex Monk <[email protected]>
_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits