Skip to content

Commit 8564e3a

Browse files
committed
Plugin installer: Minor adjustments to aid with discovery.
fixes #29387. git-svn-id: https://develop.svn.wordpress.org/trunk@29636 602fd350-edb4-49c9-b593-d223f7449a82
1 parent e334539 commit 8564e3a

File tree

4 files changed

+8
-9
lines changed

4 files changed

+8
-9
lines changed

src/wp-admin/css/edit.css

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1091,7 +1091,6 @@ input.newtag:focus ~ div.taghint {
10911091
p.popular-tags {
10921092
border: none;
10931093
line-height: 2em;
1094-
max-width: 1000px;
10951094
padding: 8px 12px 12px;
10961095
text-align: justify;
10971096
}

src/wp-admin/css/list-tables.css

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1241,7 +1241,6 @@ tr.active + tr.plugin-update-tr .plugin-update .update-message {
12411241
margin-top: 1.5em;
12421242
}
12431243

1244-
.plugin-group:first-of-type,
12451244
.plugin-group h3 {
12461245
margin-top: 0;
12471246
}

src/wp-admin/includes/class-wp-plugin-install-list-table.php

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,6 @@ public function prepare_items() {
6464
$tabs['search'] = __( 'Search Results' );
6565
$tabs['featured'] = _x( 'Featured', 'Plugin Installer' );
6666
$tabs['popular'] = _x( 'Popular', 'Plugin Installer' );
67-
$tabs['new'] = _x( 'Newest', 'Plugin Installer' );
6867
$tabs['favorites'] = _x( 'Favorites', 'Plugin Installer' );
6968
if ( $tab === 'beta' || false !== strpos( $GLOBALS['wp_version'], '-' ) ) {
7069
$tabs['beta'] = _x( 'Beta Testing', 'Plugin Installer' );
@@ -273,6 +272,10 @@ public function display() {
273272
}
274273

275274
protected function display_tablenav( $which ) {
275+
if ( $GLOBALS['tab'] === 'featured' ) {
276+
return;
277+
}
278+
276279
if ( 'top' == $which ) { ?>
277280
<div class="tablenav top">
278281
<div class="alignleft actions">

src/wp-admin/includes/plugin-install.php

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -128,11 +128,10 @@ function install_dashboard() {
128128
?>
129129
<p><?php printf( __( 'Plugins extend and expand the functionality of WordPress. You may automatically install plugins from the <a href="%1$s">WordPress Plugin Directory</a> or upload a plugin in .zip format via <a href="%2$s">this page</a>.' ), 'https://wordpress.org/plugins/', self_admin_url( 'plugin-install.php?tab=upload' ) ); ?></p>
130130

131-
<h4><?php _e('Search') ?></h4>
132-
<?php install_search_form( false ); ?>
131+
<?php display_plugins_table(); ?>
133132

134-
<h4><?php _e('Popular tags') ?></h4>
135-
<p class="install-help"><?php _e('You may also browse based on the most popular tags in the Plugin Directory:') ?></p>
133+
<h3><?php _e( 'Popular tags' ) ?></h3>
134+
<p><?php _e( 'You may also browse based on the most popular tags in the Plugin Directory:' ) ?></p>
136135
<?php
137136

138137
$api_tags = install_popular_tags();
@@ -153,7 +152,7 @@ function install_dashboard() {
153152
}
154153
echo '</p><br class="clear" />';
155154
}
156-
add_action('install_plugins_dashboard', 'install_dashboard');
155+
add_action( 'install_plugins_featured', 'install_dashboard' );
157156

158157
/**
159158
* Display search form for searching plugins.
@@ -242,7 +241,6 @@ function display_plugins_table() {
242241
$wp_list_table->display();
243242
}
244243
add_action( 'install_plugins_search', 'display_plugins_table' );
245-
add_action( 'install_plugins_featured', 'display_plugins_table' );
246244
add_action( 'install_plugins_popular', 'display_plugins_table' );
247245
add_action( 'install_plugins_new', 'display_plugins_table' );
248246
add_action( 'install_plugins_beta', 'display_plugins_table' );

0 commit comments

Comments
 (0)