WordPress.org

Make WordPress Core

Ticket #37246: 37246.5.diff

File 37246.5.diff, 6.2 KB (added by ocean90, 3 years ago)
  • src/wp-admin/about.php

     
    99/** WordPress Administration Bootstrap */
    1010require_once( dirname( __FILE__ ) . '/admin.php' );
    1111
    12 if ( current_user_can( 'customize' ) ) {
    13         wp_enqueue_script( 'customize-loader' );
     12if ( ! wp_is_mobile() ) {
     13        wp_enqueue_style( 'wp-mediaelement' );
     14        wp_enqueue_script( 'wp-mediaelement' );
     15        wp_localize_script( 'mediaelement', '_wpmejsSettings', array(
     16                'pluginPath'        => includes_url( 'js/mediaelement/', 'relative' ),
     17                'pauseOtherPlayers' => '',
     18        ) );
    1419}
    1520
     21
     22/**
     23 * Replaces the height and width attributes with values for full size.
     24 *
     25 * wp_video_shortcode() limits the width to 640px.
     26 *
     27 * @since 4.6.0
     28 * @ignore
     29 *
     30 * @param $output Video shortcode HTML output.
     31 * @return string Filtered HTML content to display video.
     32 */
     33function _wp_override_admin_video_size_limit( $output ) {
     34        return str_replace( array( '640', '384' ), array( '1050', '630' ), $output );
     35}
     36
    1637$video_url = 'https://videopress.com/embed/scFdjVo6?hd=true';
    1738$locale    = str_replace( '_', '-', get_locale() );
    1839list( $locale ) = explode( '-', $locale );
     
    5071                <div class="streamlined-updates feature-section one-col">
    5172                        <h2><?php echo( 'Streamlined Updates' ); ?></h2>
    5273                        <p><?php echo( 'Inline Updates replaces progress updates with a simpler and more straight forward experience when installing, updating, and deleting plugins and themes.' ); ?></p>
    53                         <div class="streamlined-updates-demo">
    54                                 <!-- Interactive Demo goes here -->
    55                         </div>
     74                        <?php
     75                        if ( ! wp_is_mobile() ) {
     76                                add_filter( 'wp_video_shortcode', '_wp_override_admin_video_size_limit' );
     77                                echo wp_video_shortcode( array(
     78                                        'mp4'      => 'https://cldup.com/NlOEbKLT_6.mp4',
     79                                        'ogv'      => 'https://cldup.com/0XzDZMlYwb.ogv',
     80                                        'webm'     => 'https://cldup.com/ngOx9w9VlE.webm',
     81                                        'poster'   => 'https://cldup.com/c0kfjoVcFo.png',
     82                                        'loop'     => true,
     83                                        'autoplay' => true,
     84                                        'width'    => 1050,
     85                                        'height'   => 630,
     86                                        'class'    => 'wp-video-shortcode feature-video',
     87                                ) );
     88                                remove_filter( 'wp_video_shortcode', '_wp_override_admin_video_size_limit' );
     89                        } else {
     90                                echo '<img src="https://cldup.com/c0kfjoVcFo.png" alt="" srcset=""/>';
     91                        }
     92                        ?>
    5693                </div>
    5794
    5895                <hr />
     
    6097                <div class="native-fonts feature-section one-col">
    6198                        <h2><?php echo( 'Native Fonts' ); ?></h2>
    6299                        <p><?php echo( 'The WordPress dashboard now uses the fonts that come with your device, allowing it to load faster and feel more like a native application.' ); ?></p>
    63                         <img src="https://cldup.com/B4PdQgrZzH.png" alt="" srcset=""/>
     100                        <img src="https://cldup.com/bCuNzRdtHm.png" alt="" srcset=""/>
    64101                </div>
    65102
    66103                <hr>
     
    68105                <div class="feature-section two-col">
    69106                        <h2><?php echo( 'Editor Improvements' ); ?></h2>
    70107                        <div class="col">
    71                                 <img src="https://cldup.com/43RWsTMoXS.png" alt="" srcset="https://cldup.com/43RWsTMoXS.png 1000w, https://cldup.com/43RWsTMoXS.png 800w, https://cldup.com/43RWsTMoXS.png 680w, https://cldup.com/43RWsTMoXS.png 560w, https://cldup.com/43RWsTMoXS.png 400w, https://cldup.com/43RWsTMoXS.png 280w" sizes="(max-width: 500px) calc(100vw - 40px), (max-width: 781px) calc((100vw - 70px) * .466), (max-width: 959px) calc((100vw - 116px) * .469), (max-width: 1290px) calc((100vw - 240px) * .472), 496px"/>
     108                                <img src="https://cldup.com/Kz3FL4I9iB.png" alt="" srcset="https://cldup.com/Kz3FL4I9iB.png 1000w, https://cldup.com/Kz3FL4I9iB.png 800w, https://cldup.com/Kz3FL4I9iB.png 680w, https://cldup.com/Kz3FL4I9iB.png 560w, https://cldup.com/Kz3FL4I9iB.png 400w, https://cldup.com/Kz3FL4I9iB.png 280w" sizes="(max-width: 500px) calc(100vw - 40px), (max-width: 781px) calc((100vw - 70px) * .466), (max-width: 959px) calc((100vw - 116px) * .469), (max-width: 1290px) calc((100vw - 240px) * .472), 496px"/>
    72109                                <h3><?php echo( 'Broken Link Checker' ); ?></h3>
    73110                                <p><?php echo( 'Links are the foundation of the Internet&colon; when they break, so does the web. Now when you edit a post, you instantly see when a link you add is broken.' ); ?></p>
    74111                        </div>
    75112                        <div class="col">
    76                                 <img src="https://cldup.com/1r4sPoCL8d.png" alt="" srcset="https://cldup.com/1r4sPoCL8d.png 1000w, https://cldup.com/1r4sPoCL8d.png 800w, https://cldup.com/1r4sPoCL8d.png 680w, https://cldup.com/1r4sPoCL8d.png 560w, https://cldup.com/1r4sPoCL8d.png 400w, https://cldup.com/1r4sPoCL8d.png 280w" sizes="(max-width: 500px) calc(100vw - 40px), (max-width: 781px) calc((100vw - 70px) * .466), (max-width: 959px) calc((100vw - 116px) * .469), (max-width: 1290px) calc((100vw - 240px) * .472), 496px"/>
    77                                 <h3><?php echo( 'Simplified Disaster Recovery' ); ?></h3>
     113                                <img src="https://cldup.com/fxzqZFrDxo.png" alt="" srcset="https://cldup.com/fxzqZFrDxo.png 1000w, https://cldup.com/fxzqZFrDxo.png 800w, https://cldup.com/fxzqZFrDxo.png 680w, https://cldup.com/fxzqZFrDxo.png 560w, https://cldup.com/fxzqZFrDxo.png 400w, https://cldup.com/fxzqZFrDxo.png 280w" sizes="(max-width: 500px) calc(100vw - 40px), (max-width: 781px) calc((100vw - 70px) * .466), (max-width: 959px) calc((100vw - 116px) * .469), (max-width: 1290px) calc((100vw - 240px) * .472), 496px"/>
     114                                <h3><?php echo( 'Content Recovery' ); ?></h3>
    78115                                <p><?php echo( 'As you type, WordPress saves your content to the browser. Recovering saved content is even easier with WordPress 4.6.' ); ?></p>
    79116                        </div>
    80117                </div>
  • src/wp-admin/css/about.css

     
    9090.about-wrap p {
    9191        line-height: 1.5;
    9292        font-size: 14px;
     93}
     94
     95.about-wrap .feature-section p {
    9396        max-width: 38em;
    9497        margin-left: auto;
    9598        margin-right: auto;
    9699}
    97100
    98 .about-wrap .changelog p {
    99         max-width: 100%;
    100         margin-left: 0;
    101         margin-right: 0;
    102 }
    103 
    104101.about-wrap h1 {
    105102        margin: 0.2em 200px 0 0;
    106103        padding: 0;
     
    201198        margin-top: 3em;
    202199}
    203200
     201.about-wrap .feature-video .mejs-controls {
     202        display: none !important;
     203}
     204
     205.about-wrap .feature-video .mejs-overlay-loading span {
     206        background: transparent; /* Hide loading.gif */
     207}
     208
    204209/* 1.3 - Point Releases */
    205210
    206211.about-wrap .point-releases {