Make WordPress Core

Ticket #37188: 37188.diff

File 37188.diff, 3.8 KB (added by afercia, 7 years ago)
  • src/wp-admin/css/media.css

     
    526526        left: auto;
    527527        bottom: auto;
    528528        padding-top: 0;
    529         margin-top: 0;
     529        margin-top: 20px;
    530530        border: 4px dashed #b4b9be;
    531531}
    532532
  • src/wp-admin/upload.php

     
    7777
    7878                <?php
    7979                if ( current_user_can( 'upload_files' ) ) { ?>
    80                         <a href="<?php echo admin_url( 'media-new.php' ); ?>" class="page-title-action"><?php echo esc_html_x( 'Add New', 'file' ); ?></a><?php
     80                        <a href="<?php echo admin_url( 'media-new.php' ); ?>" class="page-title-action aria-button-if-js"><?php echo esc_html_x( 'Add New', 'file' ); ?></a><?php
    8181                }
    8282                ?>
    8383
  • src/wp-includes/js/media/views/attachments/browser.js

     
    4040
    4141                this.controller.on( 'toggle:upload:attachment', this.toggleUploader, this );
    4242                this.controller.on( 'edit:selection', this.editSelection );
     43                this.createUploader();
    4344                this.createToolbar();
    44                 this.createUploader();
    4545                this.createAttachments();
    4646                if ( this.options.sidebar ) {
    4747                        this.createSidebar();
  • src/wp-includes/js/media/views/frame/manage.js

     
    3838                this.$body = $( document.body );
    3939                this.$window = $( window );
    4040                this.$adminBar = $( '#wpadminbar' );
     41                this.$toggleBtn = $( '.page-title-action' );
     42                this.$toggleBtn.attr( 'aria-expanded', 'false' );
    4143                this.$window.on( 'scroll resize', _.debounce( _.bind( this.fixPosition, this ), 15 ) );
    4244                $( document ).on( 'click', '.page-title-action', _.bind( this.addNewClickHandler, this ) );
    4345
     
    188190         */
    189191        addNewClickHandler: function( event ) {
    190192                event.preventDefault();
     193                this.$toggleBtn.attr( 'aria-expanded', $( '.uploader-inline').hasClass( 'hidden' ) );
    191194                this.trigger( 'toggle:upload:attachment' );
    192195
    193196                if ( this.uploader ) {
  • src/wp-includes/js/media-grid.js

     
    623623                this.$body = $( document.body );
    624624                this.$window = $( window );
    625625                this.$adminBar = $( '#wpadminbar' );
     626                this.$toggleBtn = $( '.page-title-action' );
     627                this.$toggleBtn.attr( 'aria-expanded', 'false' );
    626628                this.$window.on( 'scroll resize', _.debounce( _.bind( this.fixPosition, this ), 15 ) );
    627629                $( document ).on( 'click', '.page-title-action', _.bind( this.addNewClickHandler, this ) );
    628630
     
    773775         */
    774776        addNewClickHandler: function( event ) {
    775777                event.preventDefault();
     778                this.$toggleBtn.attr( 'aria-expanded', $( '.uploader-inline').hasClass( 'hidden' ) );
    776779                this.trigger( 'toggle:upload:attachment' );
    777780
    778781                if ( this.uploader ) {
  • src/wp-includes/js/media-views.js

     
    37713771
    37723772                this.controller.on( 'toggle:upload:attachment', this.toggleUploader, this );
    37733773                this.controller.on( 'edit:selection', this.editSelection );
     3774                this.createUploader();
    37743775                this.createToolbar();
    3775                 this.createUploader();
    37763776                this.createAttachments();
    37773777                if ( this.options.sidebar ) {
    37783778                        this.createSidebar();