Making WordPress.org

Changeset 2229


Ignore:
Timestamp:
12/28/2015 01:20:10 PM (11 years ago)
Author:
ocean90
Message:

WP i18n teams: Improve layout of the teams table on narrow screens.

Props ramiy, deconf.
Fixes #1481.

Location:
sites/trunk/wordpress.org/public_html/wp-content/plugins/wp-i18n-teams
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • sites/trunk/wordpress.org/public_html/wp-content/plugins/wp-i18n-teams/css/i18n-teams.css

    r2200 r2229  
    7575        border: 1px solid #E3E3E3;
    7676        border-radius: 4px;
    77         box-shadow: 0px 1px 1px rgba(0, 0, 0, 0.05) inset;
     77        box-shadow: 0 1px 1px rgba(0, 0, 0, 0.05) inset;
    7878}
    7979#locale-header ul,
     
    192192        padding: 6px 15px;
    193193}
     194
     195@media (max-width: 768px) {
     196        .i18n-filter {
     197                line-height: 2;
     198                padding: 0 3px;
     199        }
     200
     201        .show-all tbody tr,
     202        .translators-info.show-latest tbody tr.latest,
     203        .translators-info.show-minor-behind tbody tr.minor-behind,
     204        .translators-info.show-major-behind-one tbody tr.major-behind-one,
     205        .translators-info.show-major-behind-many tbody tr.major-behind-many,
     206        .translators-info.show-no-releases tbody tr.no-releases,
     207        .translators-info.show-no-site tbody tr.no-site,
     208        .translators-info.show-translated-100 tbody tr.translated-100,
     209        .translators-info.show-translated-95 tbody tr.translated-95,
     210        .translators-info.show-translated-90 tbody tr.translated-90,
     211        .translators-info.show-translated-50-less tbody tr.translated-50-less,
     212        .translators-info.show-translated-50 tbody tr.translated-50 {
     213                display: block;
     214        }
     215
     216        .translators-info table thead th {
     217                display: none;
     218        }
     219
     220        .translators-info table {
     221                border: none !important;
     222        }
     223
     224        .translators-info table td {
     225                border-width: 0 0 1px 0 !important;
     226        }
     227
     228        .translators-info table tr {
     229                border: 1px solid #ccc !important;
     230        }
     231
     232        .translators-info table tbody th,
     233        .translators-info table tbody td {
     234                display: block;
     235                text-align: left;
     236        }
     237
     238        .translators-info table tbody tr {
     239                margin-top: 20px;
     240        }
     241
     242        .translators-info table tbody td {
     243                padding: 6px 10px;
     244                position: relative;
     245                padding-left: 40%;
     246        }
     247
     248        .translators-info table tbody td:before {
     249                content: attr(data-column-title);
     250                position: absolute;
     251                left: 10px;
     252                width: 50%;
     253                font-weight: bold;
     254        }
     255
     256        .translators-info table tbody td:nth-of-type(1) {
     257                display: inline-block;
     258                padding-left: 40%;
     259                padding-right: 5px;
     260                width: 30%;
     261                border-bottom: none !important;
     262        }
     263
     264        .translators-info table tbody td:nth-of-type(2) {
     265                display: inline-block;
     266                padding-left: 0;
     267                width: 23%;
     268                border-bottom: none !important;
     269        }
     270
     271        .translators-info table tbody td:nth-of-type(3) {
     272                border-top: 1px solid #ccc !important;
     273        }
     274
     275        .translators-info table tbody td:nth-of-type(5) {
     276                display: inline-block;
     277                padding-left: 40%;
     278                width: 30%;
     279                border-bottom: none !important;
     280        }
     281
     282        .translators-info table tbody td:nth-of-type(6) {
     283                display: inline-block;
     284                padding-left: 0;
     285                width: 23%;
     286                border-bottom: none !important;
     287        }
     288
     289        .translators-info table tbody td:nth-of-type(7) {
     290                border-top: 1px solid #ccc !important;
     291                border-bottom: none !important;
     292                padding-right: none;
     293        }
     294}
  • sites/trunk/wordpress.org/public_html/wp-content/plugins/wp-i18n-teams/views/all-locales.php

    r1911 r2229  
    6161                                ?>
    6262                                <tr class="<?php echo trim( $classes ); ?>">
    63                                         <td class="no-right-border">
     63                                        <td data-column-title="<?php esc_attr_e( 'Locale', 'wporg' ); ?>" class="no-right-border">
    6464                                                <?php if ( $locale_data[ $locale->wp_locale ]['rosetta_site_url'] ) : ?>
    6565                                                        <a href="<?php echo esc_url( $locale_data[ $locale->wp_locale ]['rosetta_site_url'] ); ?>">
     
    7272                                        <td class="no-left-border"><?php echo esc_html( $locale->native_name ); ?></td>
    7373
    74                                         <td><?php echo esc_html( $locale->wp_locale ); ?></td>
     74                                        <td data-column-title="<?php esc_attr_e( 'WP Locale', 'wporg' ); ?>"><?php echo esc_html( $locale->wp_locale ); ?></td>
    7575
    76                                         <td>
     76                                        <td data-column-title="<?php esc_attr_e( 'Version', 'wporg' ); ?>">
    7777                                                <?php
    7878                                                        if ( $locale_data[ $locale->wp_locale ]['rosetta_site_url'] ) {
     
    8787                                                ?>
    8888                                        </td>
    89                                         <td class="right no-right-border">
     89                                        <td data-column-title="<?php esc_attr_e( 'GlotPress', 'wporg' ); ?>" class="right no-right-border">
    9090                                                <a href="https://translate.wordpress.org/locale/<?php echo $locale->slug; ?>">
    9191                                                        <?php echo ( isset( $percentages[ $locale->wp_locale ] ) ) ? $percentages[ $locale->wp_locale ] . '%' : '&mdash;'; ?>
  • sites/trunk/wordpress.org/public_html/wp-content/plugins/wp-i18n-teams/wp-i18n-teams.php

    r2200 r2229  
    2828        public function enqueue_assets() {
    2929                if ( is_singular() && false !== strpos( get_post()->post_content, '[wp-locales' ) ) {
    30                         wp_enqueue_style( 'wp-i18n-teams', plugins_url( 'css/i18n-teams.css', __FILE__ ), array(), 3 );
     30                        wp_enqueue_style( 'wp-i18n-teams', plugins_url( 'css/i18n-teams.css', __FILE__ ), array(), 4 );
    3131                        wp_enqueue_script( 'wp-i18n-teams', plugins_url( 'js/i18n-teams.js', __FILE__ ), array( 'jquery' ), 2 );
    3232                }
Note: See TracChangeset for help on using the changeset viewer.