Make WordPress Themes

Changeset 188114


Ignore:
Timestamp:
03/29/2023 07:15:37 PM (3 years ago)
Author:
themedropbox
Message:

New version of Twenty Fourteen - 3.6

Location:
twentyfourteen/3.6
Files:
25 added
10 edited
1 copied

Legend:

Unmodified
Added
Removed
  • twentyfourteen/3.6/comments.php

    r161206 r188114  
    4848        <?php if ( get_comment_pages_count() > 1 && get_option( 'page_comments' ) ) : ?>
    4949    <nav id="comment-nav-above" class="navigation comment-navigation">
    50         <h1 class="screen-reader-text"><?php _e( 'Comment navigation', 'twentyfourteen' ); ?></h1>
     50        <h1 class="screen-reader-text">
     51            <?php
     52            /* translators: Hidden accessibility text. */
     53            _e( 'Comment navigation', 'twentyfourteen' );
     54            ?>
     55        </h1>
    5156        <div class="nav-previous"><?php previous_comments_link( __( '&larr; Older Comments', 'twentyfourteen' ) ); ?></div>
    5257        <div class="nav-next"><?php next_comments_link( __( 'Newer Comments &rarr;', 'twentyfourteen' ) ); ?></div>
     
    6873        <?php if ( get_comment_pages_count() > 1 && get_option( 'page_comments' ) ) : ?>
    6974    <nav id="comment-nav-below" class="navigation comment-navigation">
    70         <h1 class="screen-reader-text"><?php _e( 'Comment navigation', 'twentyfourteen' ); ?></h1>
     75        <h1 class="screen-reader-text">
     76            <?php
     77            /* translators: Hidden accessibility text. */
     78            _e( 'Comment navigation', 'twentyfourteen' );
     79            ?>
     80        </h1>
    7181        <div class="nav-previous"><?php previous_comments_link( __( '&larr; Older Comments', 'twentyfourteen' ) ); ?></div>
    7282        <div class="nav-next"><?php next_comments_link( __( 'Newer Comments &rarr;', 'twentyfourteen' ) ); ?></div>
  • twentyfourteen/3.6/css/blocks.css

    r151902 r188114  
    188188}
    189189
     190.wp-block-pullquote.has-text-color blockquote,
     191.wp-block-pullquote.has-background blockquote,
     192.has-background .wp-block-pullquote blockquote,
     193.wp-block-pullquote.has-text-color cite,
     194.has-background .wp-block-pullquote cite,
     195.has-text-color .wp-block-pullquote__citation {
     196    color: inherit;
     197}
     198
    190199.wp-block-pullquote.alignleft {
    191200    margin-right: 1em;
     
    262271}
    263272
    264 .wp-block-separator.is-style-wide {
     273.wp-block-separator.is-style-wide,
     274.wp-block-separator.is-style-dots {
    265275    max-width: 100%;
    266276}
  • twentyfourteen/3.6/css/editor-blocks.css

    r151902 r188114  
    365365
    366366.wp-block-pullquote {
     367    margin: 0;
     368}
     369
     370.editor-styles-wrapper .wp-block-pullquote {
    367371    border: 0;
    368     margin: 0;
    369372}
    370373
     
    377380}
    378381
     382.wp-block-pullquote.has-text-color blockquote,
     383.wp-block-pullquote.has-background blockquote,
     384.has-background .wp-block-pullquote blockquote,
     385.wp-block-pullquote.has-text-color cite,
     386.has-background .wp-block-pullquote cite,
     387.has-text-color .wp-block-pullquote__citation {
     388    color: inherit;
     389}
     390
    379391.wp-block-pullquote.alignleft blockquote > .editor-rich-text p,
    380392.wp-block-pullquote.alignright blockquote > .editor-rich-text p {
  • twentyfourteen/3.6/functions.php

    r178726 r188114  
    6868        load_theme_textdomain( 'twentyfourteen' );
    6969
    70         // This theme styles the visual editor to resemble the theme style.
    71         add_editor_style( array( 'css/editor-style.css', twentyfourteen_font_url(), 'genericons/genericons.css' ) );
     70        /*
     71         * This theme styles the visual editor to resemble the theme style.
     72         * When fonts are self-hosted, the theme directory needs to be removed first.
     73         */
     74        $font_stylesheet = str_replace(
     75            array( get_template_directory_uri() . '/', get_stylesheet_directory_uri() . '/' ),
     76            '',
     77            twentyfourteen_font_url()
     78        );
     79        add_editor_style( array( 'css/editor-style.css', $font_stylesheet, 'genericons/genericons.css' ) );
    7280
    7381        // Load regular editor styles into the new block-based editor.
     
    153161        /*
    154162         * Enable support for Post Formats.
    155          * See https://wordpress.org/support/article/post-formats/
     163         * See https://wordpress.org/documentation/article/post-formats/
    156164         */
    157165        add_theme_support(
     
    294302add_action( 'widgets_init', 'twentyfourteen_widgets_init' );
    295303
    296 /**
    297  * Register Lato Google font for Twenty Fourteen.
    298  *
    299  * @since Twenty Fourteen 1.0
    300  *
    301  * @return string
    302  */
    303 function twentyfourteen_font_url() {
    304     $font_url = '';
    305     /*
    306      * translators: If there are characters in your language that are not supported
    307      * by Lato, translate this to 'off'. Do not translate into your own language.
     304if ( ! function_exists( 'twentyfourteen_font_url' ) ) :
     305    /**
     306     * Register Lato font for Twenty Fourteen.
     307     *
     308     * @since Twenty Fourteen 1.0
     309     * @since Twenty Fourteen 3.6 Replaced Google URL with self-hosted fonts.
     310     *
     311     * @return string
    308312     */
    309     if ( 'off' !== _x( 'on', 'Lato font: on or off', 'twentyfourteen' ) ) {
    310         $query_args = array(
    311             'family'  => urlencode( 'Lato:300,400,700,900,300italic,400italic,700italic' ),
    312             'subset'  => urlencode( 'latin,latin-ext' ),
    313             'display' => urlencode( 'fallback' ),
    314         );
    315         $font_url   = add_query_arg( $query_args, 'https://fonts.googleapis.com/css' );
    316     }
    317 
    318     return $font_url;
    319 }
     313    function twentyfourteen_font_url() {
     314        $font_url = '';
     315        /*
     316         * translators: If there are characters in your language that are not supported
     317         * by Lato, translate this to 'off'. Do not translate into your own language.
     318         */
     319        if ( 'off' !== _x( 'on', 'Lato font: on or off', 'twentyfourteen' ) ) {
     320            $font_url = get_template_directory_uri() . '/fonts/font-lato.css';
     321        }
     322
     323        return $font_url;
     324    }
     325endif;
    320326
    321327/**
     
    326332function twentyfourteen_scripts() {
    327333    // Add Lato font, used in the main stylesheet.
    328     wp_enqueue_style( 'twentyfourteen-lato', twentyfourteen_font_url(), array(), null );
     334    $font_version = ( 0 === strpos( (string) twentyfourteen_font_url(), get_template_directory_uri() . '/' ) ) ? '20230328' : null;
     335    wp_enqueue_style( 'twentyfourteen-lato', twentyfourteen_font_url(), array(), $font_version );
    329336
    330337    // Add Genericons font, used in the main stylesheet.
     
    332339
    333340    // Load our main stylesheet.
    334     wp_enqueue_style( 'twentyfourteen-style', get_stylesheet_uri(), array(), '20221101' );
     341    wp_enqueue_style( 'twentyfourteen-style', get_stylesheet_uri(), array(), '20230328' );
    335342
    336343    // Theme block stylesheet.
    337     wp_enqueue_style( 'twentyfourteen-block-style', get_template_directory_uri() . '/css/blocks.css', array( 'twentyfourteen-style' ), '20210622' );
     344    wp_enqueue_style( 'twentyfourteen-block-style', get_template_directory_uri() . '/css/blocks.css', array( 'twentyfourteen-style' ), '20230206' );
    338345
    339346    // Load the Internet Explorer specific stylesheet.
     
    370377
    371378/**
    372  * Enqueue Google fonts style to admin screen for custom header display.
     379 * Enqueue font stylesheet to admin screen for custom header display.
    373380 *
    374381 * @since Twenty Fourteen 1.0
    375382 */
    376383function twentyfourteen_admin_fonts() {
    377     wp_enqueue_style( 'twentyfourteen-lato', twentyfourteen_font_url(), array(), null );
     384    $font_version = ( 0 === strpos( (string) twentyfourteen_font_url(), get_template_directory_uri() . '/' ) ) ? '20230328' : null;
     385    wp_enqueue_style( 'twentyfourteen-lato', twentyfourteen_font_url(), array(), $font_version );
    378386}
    379387add_action( 'admin_print_scripts-appearance_page_custom-header', 'twentyfourteen_admin_fonts' );
     
    383391 *
    384392 * @since Twenty Fourteen 1.9
     393 * @deprecated Twenty Fourteen 3.6 Disabled filter because, by default, fonts are self-hosted.
    385394 *
    386395 * @param array   $urls          URLs to print for resource hints.
     
    402411    return $urls;
    403412}
    404 add_filter( 'wp_resource_hints', 'twentyfourteen_resource_hints', 10, 2 );
     413// add_filter( 'wp_resource_hints', 'twentyfourteen_resource_hints', 10, 2 );
    405414
    406415/**
     
    411420function twentyfourteen_block_editor_styles() {
    412421    // Block styles.
    413     wp_enqueue_style( 'twentyfourteen-block-editor-style', get_template_directory_uri() . '/css/editor-blocks.css', array(), '20210216' );
     422    wp_enqueue_style( 'twentyfourteen-block-editor-style', get_template_directory_uri() . '/css/editor-blocks.css', array(), '20230206' );
    414423    // Add custom fonts.
    415     wp_enqueue_style( 'twentyfourteen-fonts', twentyfourteen_font_url(), array(), null );
     424    $font_version = ( 0 === strpos( (string) twentyfourteen_font_url(), get_template_directory_uri() . '/' ) ) ? '20230328' : null;
     425    wp_enqueue_style( 'twentyfourteen-fonts', twentyfourteen_font_url(), array(), $font_version );
    416426}
    417427add_action( 'enqueue_block_editor_assets', 'twentyfourteen_block_editor_styles' );
     
    462472        if ( count( $attachment_ids ) > 1 ) {
    463473            foreach ( $attachment_ids as $idx => $attachment_id ) {
    464                 if ( $attachment_id == $post->ID ) {
     474                if ( $attachment_id === $post->ID ) {
    465475                    $next_id = $attachment_ids[ ( $idx + 1 ) % count( $attachment_ids ) ];
    466476                    break;
     
    712722 * Enables installing Twenty Fourteen in WordPress versions before 4.0.0 when the
    713723 * `is_customize_preview` function was introduced.
     724 *
     725 * @global WP_Customize_Manager $wp_customize Customizer object.
    714726 */
    715727if ( ! function_exists( 'is_customize_preview' ) ) :
  • twentyfourteen/3.6/header.php

    r178726 r188114  
    4747
    4848            <div class="search-toggle">
    49                 <a href="#search-container" class="screen-reader-text" aria-expanded="false" aria-controls="search-container"><?php _e( 'Search', 'twentyfourteen' ); ?></a>
     49                <a href="#search-container" class="screen-reader-text" aria-expanded="false" aria-controls="search-container">
     50                    <?php
     51                    /* translators: Hidden accessibility text. */
     52                    _e( 'Search', 'twentyfourteen' );
     53                    ?>
     54                </a>
    5055            </div>
    5156
    5257            <nav id="primary-navigation" class="site-navigation primary-navigation">
    5358                <button class="menu-toggle"><?php _e( 'Primary Menu', 'twentyfourteen' ); ?></button>
    54                 <a class="screen-reader-text skip-link" href="#content"><?php _e( 'Skip to content', 'twentyfourteen' ); ?></a>
     59                <a class="screen-reader-text skip-link" href="#content">
     60                    <?php
     61                    /* translators: Hidden accessibility text. */
     62                    _e( 'Skip to content', 'twentyfourteen' );
     63                    ?>
     64                </a>
    5565                <?php
    5666                wp_nav_menu(
  • twentyfourteen/3.6/inc/custom-header.php

    r161206 r188114  
    8383            <?php
    8484            // If the user has set a custom color for the text, use that.
    85         elseif ( get_theme_support( 'custom-header', 'default-text-color' ) != $text_color ) :
     85        elseif ( get_theme_support( 'custom-header', 'default-text-color' ) !== $text_color ) :
    8686            ?>
    8787        .site-title a {
  • twentyfourteen/3.6/inc/featured-content.php

    r151902 r188114  
    263263        $settings = self::get_setting();
    264264
    265         if ( empty( $settings['tag-id'] ) || $tag_id != $settings['tag-id'] ) {
     265        if ( empty( $settings['tag-id'] ) || $tag_id !== $settings['tag-id'] ) {
    266266            return;
    267267        }
     
    435435     */
    436436    public static function enqueue_scripts() {
    437         wp_enqueue_script( 'featured-content-suggest', get_template_directory_uri() . '/js/featured-content-admin.js', array( 'jquery', 'suggest' ), '20131205', true );
     437        wp_enqueue_script( 'featured-content-suggest', get_template_directory_uri() . '/js/featured-content-admin.js', array( 'jquery', 'suggest' ), '20211130', true );
    438438    }
    439439
  • twentyfourteen/3.6/inc/template-tags.php

    r168444 r188114  
    5858            ?>
    5959        <nav class="navigation paging-navigation">
    60         <h1 class="screen-reader-text"><?php _e( 'Posts navigation', 'twentyfourteen' ); ?></h1>
     60        <h1 class="screen-reader-text">
     61            <?php
     62            /* translators: Hidden accessibility text. */
     63            _e( 'Posts navigation', 'twentyfourteen' );
     64            ?>
     65        </h1>
    6166        <div class="pagination loop-pagination">
    6267            <?php echo $links; ?>
     
    8590        ?>
    8691        <nav class="navigation post-navigation">
    87         <h1 class="screen-reader-text"><?php _e( 'Post navigation', 'twentyfourteen' ); ?></h1>
     92        <h1 class="screen-reader-text">
     93            <?php
     94            /* translators: Hidden accessibility text. */
     95            _e( 'Post navigation', 'twentyfourteen' );
     96            ?>
     97        </h1>
    8898        <div class="nav-links">
    8999            <?php
  • twentyfourteen/3.6/readme.txt

    r178726 r188114  
    22Contributors: wordpressdotorg
    33Requires at least: WordPress 3.6
    4 Tested up to: 6.1
    5 Stable tag: 3.5
     4Tested up to: 6.2
     5Stable tag: 3.6
    66License: GPLv2 or later
    77License URI: http://www.gnu.org/licenses/gpl-2.0.html
     
    2323== Copyright ==
    2424
    25 Twenty Fourteen WordPress Theme, Copyright 2013-2022 WordPress.org & Automattic.com
     25Twenty Fourteen WordPress Theme, Copyright 2013-2023 WordPress.org & Automattic.com
    2626Twenty Fourteen is Distributed under the terms of the GNU GPL
    2727
     
    4949Source: http://www.genericons.com
    5050
     51Lato Font
     52Copyright (c) 2010-2011 by tyPoland Lukasz Dziedzic (team@latofonts.com) with Reserved Font Name "Lato".
     53License: SIL Open Font License, 1.1, https://opensource.org/licenses/OFL-1.1
     54Source: https://fontsource.org/fonts/lato
     55
    5156Photos from Stocksnap, used in block patterns.
    5257License: CC0
     
    5863
    5964== Changelog ==
     65
     66= 3.6 =
     67* Released: March 28, 2023
     68
     69https://codex.wordpress.org/Twenty_Fourteen_Theme_Changelog#Version_3.6
    6070
    6171= 3.5 =
  • twentyfourteen/3.6/style.css

    r178726 r188114  
    55Author URI: https://wordpress.org/
    66Description: In 2014, our default theme lets you create a responsive magazine website with a sleek, modern design. Feature your favorite homepage content in either a grid or a slider. Use the three widget areas to customize your website, and change your content's layout with a full-width page template and a contributor page to show off your authors. Creating a magazine website with WordPress has never been easier.
    7 Version: 3.5
    8 Tested up to: 6.1
     7Version: 3.6
     8Tested up to: 6.2
    99Requires PHP: 5.2.4
    1010License: GNU General Public License v2 or later
Note: See TracChangeset for help on using the changeset viewer.