Themes: Remove the "Featured" tab on Add Themes screen.

Themes displayed in this tab were actually random, and have not been selected to be featured to new WordPress users.

The tab had already been removed from the Theme Directory, and with this change, the options in the admin area and in the directory will match again.

The "Popular" tab is now displayed instead as the default view.

Props poena, kjellr, celloexpressions.
Fixes #49487. See #meta5044.
Built from https://develop.svn.wordpress.org/trunk@50813


git-svn-id: http://core.svn.wordpress.org/trunk@50422 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
Sergey Biryukov 2021-05-05 15:54:59 +00:00
parent 960952fd9b
commit e21dfba663
4 changed files with 7 additions and 8 deletions

View File

@ -1965,7 +1965,7 @@ themes.RunInstaller = {
// Set up the view.
// Passes the default 'section' as an option.
this.view = new themes.view.Installer({
section: 'featured',
section: 'popular',
SearchView: themes.view.InstallerSearch
});
@ -2032,12 +2032,12 @@ themes.RunInstaller = {
/*
* Handles sorting / browsing routes.
* Also handles the root URL triggering a sort request
* for `featured`, the default view.
* for `popular`, the default view.
*/
themes.router.on( 'route:sort', function( sort ) {
if ( ! sort ) {
sort = 'featured';
themes.router.navigate( themes.router.baseUrl( '?browse=featured' ), { replace: true } );
sort = 'popular';
themes.router.navigate( themes.router.baseUrl( '?browse=popular' ), { replace: true } );
}
self.view.sort( sort );

File diff suppressed because one or more lines are too long

View File

@ -107,7 +107,7 @@ $help_overview =
__( 'https://wordpress.org/themes/' )
) . '</p>' .
'<p>' . __( 'You can Search for themes by keyword, author, or tag, or can get more specific and search by criteria listed in the feature filter.' ) . ' <span id="live-search-desc">' . __( 'The search results will be updated as you type.' ) . '</span></p>' .
'<p>' . __( 'Alternately, you can browse the themes that are Featured, Popular, or Latest. When you find a theme you like, you can preview it or install it.' ) . '</p>' .
'<p>' . __( 'Alternately, you can browse the themes that are Popular or Latest. When you find a theme you like, you can preview it or install it.' ) . '</p>' .
'<p>' . sprintf(
/* translators: %s: /wp-content/themes */
__( 'You can Upload a theme manually if you have already downloaded its ZIP archive onto your computer (make sure it is from a trusted and original source). You can also do it the old-fashioned way and copy a downloaded theme&#8217;s folder via FTP into your %s directory.' ),
@ -181,7 +181,6 @@ require_once ABSPATH . 'wp-admin/admin-header.php';
</div>
<ul class="filter-links">
<li><a href="#" data-sort="featured"><?php _ex( 'Featured', 'themes' ); ?></a></li>
<li><a href="#" data-sort="popular"><?php _ex( 'Popular', 'themes' ); ?></a></li>
<li><a href="#" data-sort="new"><?php _ex( 'Latest', 'themes' ); ?></a></li>
<li><a href="#" data-sort="favorites"><?php _ex( 'Favorites', 'themes' ); ?></a></li>

View File

@ -13,7 +13,7 @@
*
* @global string $wp_version
*/
$wp_version = '5.8-alpha-50812';
$wp_version = '5.8-alpha-50813';
/**
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.