WordPress.org

Make WordPress Core

Changeset 43669


Ignore:
Timestamp:
10/02/2018 08:06:37 PM (12 months ago)
Author:
pento
Message:

Plugin Installer: Allow 4 columns of search results on wide screens.

For screens wider than 2300px, show 4 colums of search results, as 3 columns looked quite stretched out.

This change also increases the default number of search results from 30 to 36, so that the columns have an even number of results, regardless of whether there are 2, 3, or 4 of them.

Props nielslange.
Fixes #43573.

Location:
trunk/src/wp-admin
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-admin/css/list-tables.css

    r43436 r43669  
    13991399}
    14001400
     1401@media screen and ( min-width: 2300px ) {
     1402    .plugin-card {
     1403        width: 25%;
     1404        width: calc( 25% - 12px );
     1405    }
     1406
     1407    .plugin-card:nth-child(odd) {
     1408        clear: none;
     1409        margin-left: 8px;
     1410    }
     1411
     1412    .plugin-card:nth-child(even) {
     1413        margin-right: 8px;
     1414    }
     1415
     1416    .plugin-card:nth-child(4n+1) {
     1417        clear: both;
     1418        margin-left: 0;
     1419    }
     1420
     1421    .plugin-card:nth-child(4n) {
     1422        margin-right: 0;
     1423    }
     1424}
     1425
    14011426.plugin-card-top {
    14021427    position: relative;
  • trunk/src/wp-admin/includes/class-wp-plugin-install-list-table.php

    r43571 r43669  
    9494        $paged = $this->get_pagenum();
    9595
    96         $per_page = 30;
     96        $per_page = 36;
    9797
    9898        // These are the tabs which are shown on the page
Note: See TracChangeset for help on using the changeset viewer.