Make WordPress Core

Ticket #47650: 47650.diff

File 47650.diff, 1.9 KB (added by pedromendonca, 6 years ago)

Patch to add hooks to themes.php screen

  • wp-admin/themes.php

    diff --git a/wp-admin/themes.php b/wp-admin/themes.php
    index ec85f3ed4ef..f3a0cbf86f9 100644
    a b  
    564564                                <# if ( data.tags ) { #>
    565565                                        <p class="theme-tags"><span><?php _e( 'Tags:' ); ?></span> {{{ data.tags }}}</p>
    566566                                <# } #>
     567                                <?php
     568                                /**
     569                                 * Fires after all the theme info on the theme details modal.
     570                                 *
     571                                 * @since 5.3.0
     572                                */
     573                                do_action( 'after_theme_info' );
     574                                ?>
    567575                        </div>
    568576                </div>
    569577
    570578                <div class="theme-actions">
    571579                        <div class="active-theme">
    572580                                <a href="{{{ data.actions.customize }}}" class="button button-primary customize load-customize hide-if-no-customize"><?php _e( 'Customize' ); ?></a>
    573                                 <?php echo implode( ' ', $current_theme_actions ); ?>
     581                                <?php echo implode( ' ', apply_filters( 'current_theme_actions', $current_theme_actions ) ); ?>
     582                                <?php
     583                                /**
     584                                 * Fires after active theme actions in theme details.
     585                                 *
     586                                 * @since 5.3.0
     587                                */
     588                                do_action( 'after_active_theme_actions' );
     589                                ?>
    574590                        </div>
    575591                        <div class="inactive-theme">
    576592                                <?php
     
    581597                                        <a href="{{{ data.actions.activate }}}" class="button activate" aria-label="<?php echo $aria_label; ?>"><?php _e( 'Activate' ); ?></a>
    582598                                <# } #>
    583599                                <a href="{{{ data.actions.customize }}}" class="button button-primary load-customize hide-if-no-customize"><?php _e( 'Live Preview' ); ?></a>
     600                                <?php
     601                                /**
     602                                 * Fires after inactive theme actions in theme details.
     603                                 *
     604                                 * @since 5.3.0
     605                                */
     606                                do_action( 'after_inactive_theme_actions' );
     607                                ?>
    584608                        </div>
     609                        <?php
     610                        /**
     611                         * Fires after active theme actions in theme details.
     612                         *
     613                         * @since 5.3.0
     614                        */
     615                        do_action( 'after_theme_actions' );
     616                        ?>
    585617
    586618                        <# if ( ! data.active && data.actions['delete'] ) { #>
    587619                                <a href="{{{ data.actions['delete'] }}}" class="button delete-theme"><?php _e( 'Delete' ); ?></a>