WordPress.org

Make WordPress Core

Ticket #38375: 38375.1.diff

File 38375.1.diff, 13.3 KB (added by bronsonquick, 5 years ago)
  • src/wp-content/themes/twentyseventeen/archive.php

    diff --git a/src/wp-content/themes/twentyseventeen/archive.php b/src/wp-content/themes/twentyseventeen/archive.php
    index 8aa139f..6623321 100644
    a b get_header(); ?> 
    3737                                 * If you want to override this in a child theme, then include a file
    3838                                 * called content-___.php (where ___ is the Post Format name) and that will be used instead.
    3939                                 */
    40                                 get_template_part( 'components/post/content', get_post_format() );
     40                                get_template_part( 'template-parts/post/content', get_post_format() );
    4141
    4242                        endwhile;
    4343
    get_header(); ?> 
    4949
    5050                else :
    5151
    52                         get_template_part( 'components/post/content', 'none' );
     52                        get_template_part( 'template-parts/post/content', 'none' );
    5353
    5454                endif; ?>
    5555
  • src/wp-content/themes/twentyseventeen/footer.php

    diff --git a/src/wp-content/themes/twentyseventeen/footer.php b/src/wp-content/themes/twentyseventeen/footer.php
    index e911c1a..2d72029 100644
    a b  
    1919        <footer id="colophon" class="site-footer" role="contentinfo">
    2020                <div class="wrap">
    2121                        <?php
    22                         get_template_part( 'components/footer/footer', 'widgets' );
     22                        get_template_part( 'template-parts/footer/footer', 'widgets' );
    2323
    2424                        if ( has_nav_menu( 'social' ) ) : ?>
    2525                                <nav class="social-navigation" role="navigation" aria-label="<?php _e( 'Footer Social Links Menu', 'twentyseventeen' ); ?>">
     
    3535                                </nav><!-- .social-navigation -->
    3636                        <?php endif;
    3737
    38                         get_template_part( 'components/footer/site', 'info' );
     38                        get_template_part( 'template-parts/footer/site', 'info' );
    3939                        ?>
    4040                </div><!-- .wrap -->
    4141        </footer><!-- #colophon -->
  • src/wp-content/themes/twentyseventeen/front-page.php

    diff --git a/src/wp-content/themes/twentyseventeen/front-page.php b/src/wp-content/themes/twentyseventeen/front-page.php
    index ea4ddc9..5556888 100644
    a b get_header(); ?> 
    2020                <?php // Show the selected frontpage content.
    2121                if ( have_posts() ) :
    2222                        while ( have_posts() ) : the_post();
    23                                 get_template_part( 'components/page/content', 'front-page' );
     23                                get_template_part( 'template-parts/page/content', 'front-page' );
    2424                        endwhile;
    2525                else : // I'm not sure it's possible to have no posts when this page is shown, but WTH.
    26                         get_template_part( 'components/post/content', 'none' );
     26                        get_template_part( 'template-parts/post/content', 'none' );
    2727                endif; ?>
    2828
    2929                <?php
    get_header(); ?> 
    3131                $panels = array( '1', '2', '3', '4' );
    3232                $titles = array();
    3333
    34                 global $twentyseventeencounter; // Used in components/page/content-front-page-panels.php file.
     34                global $twentyseventeencounter; // Used in template-parts/page/content-front-page-panels.php file.
    3535
    3636                if ( 0 !== twentyseventeen_panel_count() || is_customize_preview() ) : // If we have pages to show.
    3737
    get_header(); ?> 
    4444                                        set_query_var( 'panel', $panel );
    4545
    4646                                        $titles[] = get_the_title(); // Put page titles in an array for use in navigation.
    47                                         get_template_part( 'components/page/content', 'front-page-panels' );
     47                                        get_template_part( 'template-parts/page/content', 'front-page-panels' );
    4848
    4949                                        wp_reset_postdata();
    5050                                else :
  • src/wp-content/themes/twentyseventeen/header.php

    diff --git a/src/wp-content/themes/twentyseventeen/header.php b/src/wp-content/themes/twentyseventeen/header.php
    index f76bbf3..dc173d6 100644
    a b  
    2828
    2929        <header id="masthead" class="site-header" role="banner">
    3030
    31                 <?php get_template_part( 'components/header/header', 'image' ); ?>
     31                <?php get_template_part( 'template-parts/header/header', 'image' ); ?>
    3232
    3333                <?php if ( has_nav_menu( 'top' ) ) : ?>
    3434                        <div class="navigation-top">
    3535                                <div class="wrap">
    36                                         <?php get_template_part( 'components/navigation/navigation', 'top' ); ?>
     36                                        <?php get_template_part( 'template-parts/navigation/navigation', 'top' ); ?>
    3737                                </div><!-- .wrap -->
    3838                        </div><!-- .navigation-top -->
    3939                <?php endif; ?>
  • src/wp-content/themes/twentyseventeen/index.php

    diff --git a/src/wp-content/themes/twentyseventeen/index.php b/src/wp-content/themes/twentyseventeen/index.php
    index 144ef9a..4e1186b 100644
    a b get_header(); ?> 
    4242                                         * If you want to override this in a child theme, then include a file
    4343                                         * called content-___.php (where ___ is the Post Format name) and that will be used instead.
    4444                                         */
    45                                         get_template_part( 'components/post/content', get_post_format() );
     45                                        get_template_part( 'template-parts/post/content', get_post_format() );
    4646
    4747                                endwhile;
    4848
    get_header(); ?> 
    5454
    5555                        else :
    5656
    57                                 get_template_part( 'components/post/content', 'none' );
     57                                get_template_part( 'template-parts/post/content', 'none' );
    5858
    5959                        endif;
    6060                        ?>
  • src/wp-content/themes/twentyseventeen/page.php

    diff --git a/src/wp-content/themes/twentyseventeen/page.php b/src/wp-content/themes/twentyseventeen/page.php
    index 850b2ba..96211f4 100644
    a b get_header(); ?> 
    2424                        <?php
    2525                        while ( have_posts() ) : the_post();
    2626
    27                                 get_template_part( 'components/page/content', 'page' );
     27                                get_template_part( 'template-parts/page/content', 'page' );
    2828
    2929                                // If comments are open or we have at least one comment, load up the comment template.
    3030                                if ( comments_open() || get_comments_number() ) :
  • src/wp-content/themes/twentyseventeen/search.php

    diff --git a/src/wp-content/themes/twentyseventeen/search.php b/src/wp-content/themes/twentyseventeen/search.php
    index 6a22181..a521e4b 100644
    a b get_header(); ?> 
    3535                                 * If you want to overload this in a child theme then include a file
    3636                                 * called content-search.php and that will be used instead.
    3737                                 */
    38                                 get_template_part( 'components/post/content', 'excerpt' );
     38                                get_template_part( 'template-parts/post/content', 'excerpt' );
    3939
    4040                        endwhile; // End of the loop.
    4141
  • src/wp-content/themes/twentyseventeen/single.php

    diff --git a/src/wp-content/themes/twentyseventeen/single.php b/src/wp-content/themes/twentyseventeen/single.php
    index f1b3721..704560b 100644
    a b get_header(); ?> 
    2020                                /* Start the Loop */
    2121                                while ( have_posts() ) : the_post();
    2222
    23                                         get_template_part( 'components/post/content', get_post_format() );
     23                                        get_template_part( 'template-parts/post/content', get_post_format() );
    2424
    2525                                        // If comments are open or we have at least one comment, load up the comment template.
    2626                                        if ( comments_open() || get_comments_number() ) :
  • header/header-image.php

    diff --git a/src/wp-content/themes/twentyseventeen/components/footer/footer-widgets.php b/src/wp-content/themes/twentyseventeen/template-parts/footer/footer-widgets.php
    similarity index 100%
    rename from src/wp-content/themes/twentyseventeen/components/footer/footer-widgets.php
    rename to src/wp-content/themes/twentyseventeen/template-parts/footer/footer-widgets.php
    diff --git a/src/wp-content/themes/twentyseventeen/components/footer/site-info.php b/src/wp-content/themes/twentyseventeen/template-parts/footer/site-info.php
    similarity index 100%
    rename from src/wp-content/themes/twentyseventeen/components/footer/site-info.php
    rename to src/wp-content/themes/twentyseventeen/template-parts/footer/site-info.php
    diff --git a/src/wp-content/themes/twentyseventeen/components/header/header-image.php b/src/wp-content/themes/twentyseventeen/template-parts/header/header-image.php
    similarity index 79%
    rename from src/wp-content/themes/twentyseventeen/components/header/header-image.php
    rename to src/wp-content/themes/twentyseventeen/template-parts/header/header-image.php
    index 102456d..2c4b0f8 100644
    old new  
    1717        if ( ! empty( $header_image ) ) : ?>
    1818
    1919                <div class="custom-header-image" style="background-image: url(<?php echo esc_url( $header_image ); ?>)"></div>
    20                 <?php get_template_part( 'components/header/site', 'branding' ); ?>
     20                <?php get_template_part( 'template-parts/header/site', 'branding' ); ?>
    2121
    2222        <?php else : ?>
    2323                <?php // Otherwise, show a blank header. ?>
    2424                <div class="custom-header-simple">
    25                         <?php get_template_part( 'components/header/site', 'branding' ); ?>
     25                        <?php get_template_part( 'template-parts/header/site', 'branding' ); ?>
    2626                </div><!-- .custom-header-simple -->
    2727
    2828        <?php endif; ?>
  • page/content-front-page-panels.php

    diff --git a/src/wp-content/themes/twentyseventeen/components/header/site-branding.php b/src/wp-content/themes/twentyseventeen/template-parts/header/site-branding.php
    similarity index 100%
    rename from src/wp-content/themes/twentyseventeen/components/header/site-branding.php
    rename to src/wp-content/themes/twentyseventeen/template-parts/header/site-branding.php
    diff --git a/src/wp-content/themes/twentyseventeen/components/navigation/navigation-top.php b/src/wp-content/themes/twentyseventeen/template-parts/navigation/navigation-top.php
    similarity index 100%
    rename from src/wp-content/themes/twentyseventeen/components/navigation/navigation-top.php
    rename to src/wp-content/themes/twentyseventeen/template-parts/navigation/navigation-top.php
    diff --git a/src/wp-content/themes/twentyseventeen/components/page/content-front-page-panels.php b/src/wp-content/themes/twentyseventeen/template-parts/page/content-front-page-panels.php
    similarity index 97%
    rename from src/wp-content/themes/twentyseventeen/components/page/content-front-page-panels.php
    rename to src/wp-content/themes/twentyseventeen/template-parts/page/content-front-page-panels.php
    index aa45a2b..9e0ffff 100644
    old new global $twentyseventeencounter; 
    7373
    7474                                                <?php
    7575                                                while ( $recent_posts->have_posts() ) : $recent_posts->the_post();
    76                                                         get_template_part( 'components/post/content', 'excerpt' );
     76                                                        get_template_part( 'template-parts/post/content', 'excerpt' );
    7777                                                endwhile;
    7878                                                wp_reset_postdata();
    7979                                                ?>