Make WordPress Core

Ticket #56403: 56403.2.diff

File 56403.2.diff, 1.4 KB (added by alireyad, 3 years ago)

Updated patch file. It also will match with themes page.

  • src/wp-admin/theme-install.php

    diff --git a/src/wp-admin/theme-install.php b/src/wp-admin/theme-install.php
    index 1fd5a6739b..2806725d94 100644
    a b if ( $tab ) { 
    293293                <div class="theme-screenshot blank"></div>
    294294        <# } #>
    295295
    296         <# if ( data.installed ) { #>
     296        <# if ( data.active ) { #>
     297                <div class="notice notice-success notice-alt"><p><?php _ex( 'Activated', 'theme' ); ?></p></div>
     298        <# } else if ( data.installed ) { #>
    297299                <div class="notice notice-success notice-alt"><p><?php _ex( 'Installed', 'theme' ); ?></p></div>
    298300        <# } #>
    299301
    if ( $tab ) { 
    370372                                        /* translators: %s: Theme name. */
    371373                                        $aria_label = sprintf( _x( 'Activate %s', 'theme' ), '{{ data.name }}' );
    372374                                        ?>
    373                                         <# if ( data.activate_url ) { #>
    374                                                 <# if ( ! data.active ) { #>
    375                                                         <a class="button button-primary activate" href="{{ data.activate_url }}" aria-label="<?php echo esc_attr( $aria_label ); ?>"><?php _e( 'Activate' ); ?></a>
    376                                                 <# } else { #>
    377                                                         <button class="button button-primary disabled"><?php _ex( 'Activated', 'theme' ); ?></button>
    378                                                 <# } #>
     375                                        <# if ( data.activate_url && ! data.active ) { #>
     376                                                <a class="button button-primary activate" href="{{ data.activate_url }}" aria-label="<?php echo esc_attr( $aria_label ); ?>"><?php _e( 'Activate' ); ?></a>
    379377                                        <# } #>
    380378                                        <# if ( data.customize_url ) { #>
    381379                                                <# if ( ! data.active ) { #>