Update themes

This commit is contained in:
Oliver Davies 2019-05-08 08:07:01 +01:00
parent e00f87f2f5
commit 168d1a5ee7
98 changed files with 6532 additions and 2223 deletions

View file

@ -33,7 +33,6 @@ class TwentyNineteen_Walker_Comment extends Walker_Comment {
<footer class="comment-meta"> <footer class="comment-meta">
<div class="comment-author vcard"> <div class="comment-author vcard">
<?php <?php
$comment_author_link = get_comment_author_link( $comment );
$comment_author_url = get_comment_author_url( $comment ); $comment_author_url = get_comment_author_url( $comment );
$comment_author = get_comment_author( $comment ); $comment_author = get_comment_author( $comment );
$avatar = get_avatar( $comment, $args['avatar_size'] ); $avatar = get_avatar( $comment, $args['avatar_size'] );
@ -53,6 +52,14 @@ class TwentyNineteen_Walker_Comment extends Walker_Comment {
printf( '<span class="post-author-badge" aria-hidden="true">%s</span>', twentynineteen_get_icon_svg( 'check', 24 ) ); printf( '<span class="post-author-badge" aria-hidden="true">%s</span>', twentynineteen_get_icon_svg( 'check', 24 ) );
} }
/*
* Using the `check` icon instead of `check_circle`, since we can't add a
* fill color to the inner check shape when in circle form.
*/
if ( twentynineteen_is_comment_by_post_author( $comment ) ) {
printf( '<span class="post-author-badge" aria-hidden="true">%s</span>', twentynineteen_get_icon_svg( 'check', 24 ) );
}
printf( printf(
/* translators: %s: comment author link */ /* translators: %s: comment author link */
wp_kses( wp_kses(
@ -63,7 +70,7 @@ class TwentyNineteen_Walker_Comment extends Walker_Comment {
), ),
) )
), ),
'<b class="fn">' . get_comment_author_link( $comment ) . '</b>' '<b class="fn">' . $comment_author . '</b>'
); );
if ( ! empty( $comment_author_url ) ) { if ( ! empty( $comment_author_url ) ) {

View file

@ -20,6 +20,7 @@
</head> </head>
<body <?php body_class(); ?>> <body <?php body_class(); ?>>
<?php wp_body_open(); ?>
<div id="page" class="site"> <div id="page" class="site">
<a class="skip-link screen-reader-text" href="#content"><?php _e( 'Skip to content', 'twentynineteen' ); ?></a> <a class="skip-link screen-reader-text" href="#content"><?php _e( 'Skip to content', 'twentynineteen' ); ?></a>
@ -27,7 +28,7 @@
<div class="site-branding-container"> <div class="site-branding-container">
<?php get_template_part( 'template-parts/header/site', 'branding' ); ?> <?php get_template_part( 'template-parts/header/site', 'branding' ); ?>
</div><!-- .layout-wrap --> </div><!-- .site-branding-container -->
<?php if ( is_singular() && twentynineteen_can_show_post_thumbnail() ) : ?> <?php if ( is_singular() && twentynineteen_can_show_post_thumbnail() ) : ?>
<div class="site-featured-image"> <div class="site-featured-image">

View file

@ -78,7 +78,7 @@ get_header();
<?php twentynineteen_entry_footer(); ?> <?php twentynineteen_entry_footer(); ?>
</footer><!-- .entry-footer --> </footer><!-- .entry-footer -->
</article><!-- #post-## --> </article><!-- #post-<?php the_ID(); ?> -->
<?php <?php
// Parent post navigation. // Parent post navigation.

View file

@ -132,20 +132,14 @@ function twentynineteen_custom_colors_css() {
} }
/* /*
* Set left border color for: * Set border color for:
* wp block quote * wp block quote
* :focus
*/ */
blockquote, blockquote,
.entry .entry-content blockquote, .entry .entry-content blockquote,
.entry .entry-content .wp-block-quote:not(.is-large), .entry .entry-content .wp-block-quote:not(.is-large),
.entry .entry-content .wp-block-quote:not(.is-style-large) { .entry .entry-content .wp-block-quote:not(.is-style-large),
border-left-color: hsl( ' . $primary_color . ', ' . $saturation . ', ' . $lightness . ' ); /* base: #0073a8; */
}
/*
* Set border color for:
* :focus
*/
input[type="text"]:focus, input[type="text"]:focus,
input[type="email"]:focus, input[type="email"]:focus,
input[type="url"]:focus, input[type="url"]:focus,
@ -231,7 +225,7 @@ function twentynineteen_custom_colors_css() {
.editor-block-list__layout .editor-block-list__block .wp-block-quote:not(.is-large):not(.is-style-large), .editor-block-list__layout .editor-block-list__block .wp-block-quote:not(.is-large):not(.is-style-large),
.editor-styles-wrapper .editor-block-list__layout .wp-block-freeform blockquote { .editor-styles-wrapper .editor-block-list__layout .wp-block-freeform blockquote {
border-left: 2px solid hsl( ' . $primary_color . ', ' . $saturation . ', ' . $lightness . ' ); /* base: #0073a8; */ border-color: hsl( ' . $primary_color . ', ' . $saturation . ', ' . $lightness . ' ); /* base: #0073a8; */
} }
.editor-block-list__layout .editor-block-list__block .wp-block-pullquote.is-style-solid-color:not(.has-background-color) { .editor-block-list__layout .editor-block-list__block .wp-block-pullquote.is-style-solid-color:not(.has-background-color) {

View file

@ -238,3 +238,21 @@ if ( ! function_exists( 'twentynineteen_the_posts_navigation' ) ) :
); );
} }
endif; endif;
if ( ! function_exists( 'wp_body_open' ) ) :
/**
* Fire the wp_body_open action.
*
* Added for backwards compatibility to support pre 5.2.0 WordPress versions.
*
* @since Twenty Nineteen 1.4
*/
function wp_body_open() {
/**
* Triggered after the opening <body> tag.
*
* @since Twenty Nineteen 1.4
*/
do_action( 'wp_body_open' );
}
endif;

View file

@ -1,4 +1,3 @@
@charset "UTF-8";
/* /*
Theme Name: Twenty Nineteen Theme Name: Twenty Nineteen
@ -9,7 +8,7 @@ Andreas Hecht in https://www.jotform.com/blog/css-perfect-print-stylesheet-98272
>>> TABLE OF CONTENTS: >>> TABLE OF CONTENTS:
---------------------------------------------------------------- ----------------------------------------------------------------
# Margins # Margins
# Typography÷ # Typography
# Page breaks # Page breaks
# Links # Links
# Visibility # Visibility

View file

@ -9,7 +9,7 @@ Andreas Hecht in https://www.jotform.com/blog/css-perfect-print-stylesheet-98272
>>> TABLE OF CONTENTS: >>> TABLE OF CONTENTS:
---------------------------------------------------------------- ----------------------------------------------------------------
# Margins # Margins
# Typography÷ # Typography
# Page breaks # Page breaks
# Links # Links
# Visibility # Visibility

View file

@ -1,9 +1,10 @@
=== Twenty Nineteen === === Twenty Nineteen ===
Contributors: the WordPress team Contributors: wordpressdotorg
Tags: one-column, flexible-header, accessibility-ready, custom-colors, custom-menu, custom-logo, editor-style, featured-images, footer-widgets, rtl-language-support, sticky-post, threaded-comments, translation-ready Tags: one-column, flexible-header, accessibility-ready, custom-colors, custom-menu, custom-logo, editor-style, featured-images, footer-widgets, rtl-language-support, sticky-post, threaded-comments, translation-ready
Requires at least: 4.9.6 Requires at least: 4.9.6
Tested up to: WordPress 5.0 Tested up to: WordPress 5.0
Stable tag: 1.2 Requires PHP: 5.2.4
Stable tag: 1.4
License: GPLv2 or later License: GPLv2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html License URI: http://www.gnu.org/licenses/gpl-2.0.html
@ -14,6 +15,16 @@ Our 2019 default theme is designed to show off the power of the block editor. It
== Changelog == == Changelog ==
= 1.4 =
* Released: May 7, 2019
https://codex.wordpress.org/Twenty_Nineteen_Theme_Changelog#Version_1.4
= 1.3 =
* Released: February 21, 2019
https://codex.wordpress.org/Twenty_Nineteen_Theme_Changelog#Version_1.3
= 1.2 = = 1.2 =
* Released: January 9, 2019 * Released: January 9, 2019

View file

@ -160,7 +160,7 @@
@include button-transition; @include button-transition;
border: none; border: none;
font-size: $font__size-sm; font-size: $font__size-sm;
font-family: $font__heading; @include font-family( $font__heading );
line-height: $font__line-height-heading; line-height: $font__line-height-heading;
box-sizing: border-box; box-sizing: border-box;
font-weight: bold; font-weight: bold;
@ -230,7 +230,7 @@
li { li {
color: $color__text-light; color: $color__text-light;
font-family: $font__heading; @include font-family( $font__heading );
font-size: calc(#{$font__size_base} * #{$font__size-ratio}); font-size: calc(#{$font__size_base} * #{$font__size-ratio});
font-weight: bold; font-weight: bold;
line-height: $font__line-height-heading; line-height: $font__line-height-heading;
@ -299,7 +299,7 @@
//! Verse //! Verse
.wp-block-verse { .wp-block-verse {
font-family: $font__body; @include font-family( $font__body );
font-size: $font__size_base; font-size: $font__size_base;
line-height: 1.8; line-height: 1.8;
} }
@ -307,7 +307,7 @@
//! Paragraphs //! Paragraphs
.has-drop-cap { .has-drop-cap {
&:not(:focus):first-letter { &:not(:focus):first-letter {
font-family: $font__heading; @include font-family( $font__heading );
font-size: $font__size-xxxl; font-size: $font__size-xxxl;
line-height: 1; line-height: 1;
font-weight: bold; font-weight: bold;
@ -348,7 +348,7 @@
cite { cite {
display: inline-block; display: inline-block;
font-family: $font__heading; @include font-family( $font__heading );
line-height: 1.6; line-height: 1.6;
text-transform: none; text-transform: none;
color: $color__text-light; color: $color__text-light;
@ -452,7 +452,8 @@
&:not(.is-large), &:not(.is-large),
&:not(.is-style-large) { &:not(.is-style-large) {
border-left: 2px solid $color__link; border-width: 2px;
border-color: $color__link;
padding-top: 0; padding-top: 0;
padding-bottom: 0; padding-bottom: 0;
} }
@ -559,7 +560,7 @@
.wp-block-cover-image-text, .wp-block-cover-image-text,
.wp-block-cover-text, .wp-block-cover-text,
h2 { h2 {
font-family: $font__heading; @include font-family( $font__heading );
font-size: $font__size-lg; font-size: $font__size-lg;
font-weight: bold; font-weight: bold;
line-height: 1.25; line-height: 1.25;
@ -624,7 +625,7 @@
.wp-block-gallery .blocks-gallery-image figcaption, .wp-block-gallery .blocks-gallery-image figcaption,
.wp-block-gallery .blocks-gallery-item figcaption { .wp-block-gallery .blocks-gallery-item figcaption {
font-size: $font__size-xs; font-size: $font__size-xs;
font-family: $font__heading; @include font-family( $font__heading );
line-height: $font__line-height-pre; line-height: $font__line-height-pre;
margin: 0; margin: 0;
padding: ( $size__spacing-unit * .5 ); padding: ( $size__spacing-unit * .5 );
@ -690,7 +691,7 @@
//! File //! File
.wp-block-file { .wp-block-file {
font-family: $font__heading; @include font-family( $font__heading );
.wp-block-file__button { .wp-block-file__button {
display: table; display: table;
@ -699,7 +700,7 @@
border-radius: 5px; border-radius: 5px;
background: $color__background-button; background: $color__background-button;
font-size: $font__size-base; font-size: $font__size-base;
font-family: $font__heading; @include font-family( $font__heading );
line-height: $font__line-height-heading; line-height: $font__line-height-heading;
text-decoration: none; text-decoration: none;
font-weight: bold; font-weight: bold;
@ -740,16 +741,6 @@
//! Columns //! Columns
.wp-block-columns { .wp-block-columns {
&.alignfull {
padding-left: $size__spacing-unit;
padding-right: $size__spacing-unit;
}
@include media(mobile) {
flex-wrap: nowrap;
}
@include media(tablet) {
.wp-block-column > * { .wp-block-column > * {
&:first-child { &:first-child {
@ -761,18 +752,11 @@
} }
} }
&[class*='has-'] > * { @include media(tablet) {
margin-right: $size__spacing-unit; flex-wrap: nowrap;
&:last-child { .wp-block-column:not(:first-child) {
margin-right: 0; margin-left: 32px;
}
}
&.alignfull,
&.alignfull .wp-block-column {
padding-left: calc(2 * #{$size__spacing-unit});
padding-right: calc(2 * #{$size__spacing-unit});
} }
} }
} }
@ -781,7 +765,7 @@
.wp-block-latest-comments { .wp-block-latest-comments {
.wp-block-latest-comments__comment-meta { .wp-block-latest-comments__comment-meta {
font-family: $font__heading; @include font-family( $font__heading );
font-weight: bold; font-weight: bold;
.wp-block-latest-comments__comment-date { .wp-block-latest-comments__comment-date {
@ -837,14 +821,14 @@
// Use white text against these backgrounds by default. // Use white text against these backgrounds by default.
color: $color__background-body; color: $color__background-body;
p, > p,
h1, > h1,
h2, > h2,
h3, > h3,
h4, > h4,
h5, > h5,
h6, > h6,
a { > a {
color: $color__background-body; color: $color__background-body;
} }
} }
@ -853,14 +837,14 @@
color: $color__text-main; color: $color__text-main;
// Use dark gray text against this background by default. // Use dark gray text against this background by default.
p, > p,
h1, > h1,
h2, > h2,
h3, > h3,
h4, > h4,
h5, > h5,
h6, > h6,
a { > a {
color: $color__text-main; color: $color__text-main;
} }
} }
@ -893,25 +877,25 @@
//! Custom foreground colors //! Custom foreground colors
.has-primary-color, .has-primary-color,
.wp-block-pullquote.is-style-solid-color blockquote.has-primary-color, .wp-block-pullquote.is-style-solid-color blockquote.has-primary-color,
.wp-block-pullquote.is-style-solid-color blockquote.has-primary-color p { .wp-block-pullquote.is-style-solid-color blockquote.has-primary-color > p {
color: $color__link; color: $color__link;
} }
.has-secondary-color, .has-secondary-color,
.wp-block-pullquote.is-style-solid-color blockquote.has-secondary-color, .wp-block-pullquote.is-style-solid-color blockquote.has-secondary-color,
.wp-block-pullquote.is-style-solid-color blockquote.has-secondary-color p { .wp-block-pullquote.is-style-solid-color blockquote.has-secondary-color > p {
color: $color__border-link-hover; color: $color__border-link-hover;
} }
.has-dark-gray-color, .has-dark-gray-color,
.wp-block-pullquote.is-style-solid-color blockquote.has-dark-gray-color, .wp-block-pullquote.is-style-solid-color blockquote.has-dark-gray-color,
.wp-block-pullquote.is-style-solid-color blockquote.has-dark-gray-color p { .wp-block-pullquote.is-style-solid-color blockquote.has-dark-gray-color > p {
color: $color__text-main; color: $color__text-main;
} }
.has-light-gray-color, .has-light-gray-color,
.wp-block-pullquote.is-style-solid-color blockquote.has-light-gray-color, .wp-block-pullquote.is-style-solid-color blockquote.has-light-gray-color,
.wp-block-pullquote.is-style-solid-color blockquote.has-light-gray-color p { .wp-block-pullquote.is-style-solid-color blockquote.has-light-gray-color > p {
color: $color__text-light; color: $color__text-light;
} }

View file

@ -2,7 +2,7 @@ table {
margin: 0 0 $size__spacing-unit; margin: 0 0 $size__spacing-unit;
border-collapse: collapse; border-collapse: collapse;
width: 100%; width: 100%;
font-family: $font__heading; @include font-family( $font__heading );
td, td,
th { th {

View file

@ -10,7 +10,7 @@ input[type="submit"] {
border-radius: 5px; border-radius: 5px;
box-sizing: border-box; box-sizing: border-box;
color: $color__background-body; color: $color__background-body;
font-family: $font__heading; @include font-family( $font__heading );
font-size: $font__size-sm; font-size: $font__size-sm;
font-weight: 700; font-weight: 700;
line-height: $font__line-height-heading; line-height: $font__line-height-heading;

View file

@ -24,7 +24,7 @@
.wp-caption-text { .wp-caption-text {
color: $color__text-light; color: $color__text-light;
font-size: $font__size-xs; font-size: $font__size-xs;
font-family: $font__heading; @include font-family( $font__heading );
line-height: $font__line-height-pre; line-height: $font__line-height-pre;
margin: 0; margin: 0;
padding: ( $size__spacing-unit * .5 ); padding: ( $size__spacing-unit * .5 );

View file

@ -32,7 +32,7 @@
.gallery-caption { .gallery-caption {
display: block; display: block;
font-size: $font__size-xs; font-size: $font__size-xs;
font-family: $font__heading; @include font-family( $font__heading );
line-height: $font__line-height-pre; line-height: $font__line-height-pre;
margin: 0; margin: 0;
padding: ( $size__spacing-unit * .5 ); padding: ( $size__spacing-unit * .5 );

View file

@ -87,94 +87,6 @@
0 0 1px 0 rgba( $color__text-light, 0.7 ); // Antialiasing, outer edge. 0 0 1px 0 rgba( $color__text-light, 0.7 ); // Antialiasing, outer edge.
} }
/* Fallback for non-latin fonts */
@mixin non-latin-fonts( $wrapper_classname: '.site' ) {
/* Arabic */
html[lang="ar"] #{$wrapper_classname} *,
html[lang="ary"] #{$wrapper_classname} *,
html[lang="azb"] #{$wrapper_classname} *,
html[lang="ckb"] #{$wrapper_classname} *,
html[lang="fa-IR"] #{$wrapper_classname} *,
html[lang="haz"] #{$wrapper_classname} *,
html[lang="ps"] #{$wrapper_classname} * {
font-family: Tahoma, Arial, sans-serif !important;
}
/* Cyrillic */
html[lang="be"] #{$wrapper_classname} *,
html[lang="bg-BG"] #{$wrapper_classname} *,
html[lang="kk"] #{$wrapper_classname} *,
html[lang="mk-MK"] #{$wrapper_classname} *,
html[lang="mn"] #{$wrapper_classname} *,
html[lang="ru-RU"] #{$wrapper_classname} *,
html[lang="sah"] #{$wrapper_classname} *,
html[lang="sr-RS"] #{$wrapper_classname} *,
html[lang="tt-RU"] #{$wrapper_classname} *,
html[lang="uk"] #{$wrapper_classname} * {
font-family: 'Helvetica Neue', Helvetica, 'Segoe UI', Arial, sans-serif !important;
}
/* Chinese (Hong Kong) */
html[lang="zh-HK"] #{$wrapper_classname} * {
font-family: -apple-system, BlinkMacSystemFont, 'PingFang HK', 'Helvetica Neue', "Microsoft YaHei New", STHeiti Light, sans-serif !important;
}
/* Chinese (Taiwan) */
html[lang="zh-TW"] #{$wrapper_classname} * {
font-family: -apple-system, BlinkMacSystemFont, 'PingFang TC', 'Helvetica Neue', "Microsoft YaHei New", STHeiti Light, sans-serif !important;
}
/* Chinese (China) */
html[lang="zh-CN"] #{$wrapper_classname} * {
font-family: -apple-system, BlinkMacSystemFont, 'PingFang SC', 'Helvetica Neue', "Microsoft YaHei New", STHeiti Light, sans-serif !important;
}
/* Devanagari */
html[lang="bn-BD"] #{$wrapper_classname} *,
html[lang="hi-IN"] #{$wrapper_classname} *,
html[lang="mr"] #{$wrapper_classname} *,
html[lang="ne-NP"] #{$wrapper_classname} * {
font-family: Arial, sans-serif !important;
}
/* Greek */
html[lang="el"] #{$wrapper_classname} * {
font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif !important;
}
/* Gujarati */
html[lang="gu"] #{$wrapper_classname} * {
font-family: Arial, sans-serif !important;
}
/* Hebrew */
html[lang="he-IL"] #{$wrapper_classname} * {
font-family: 'Arial Hebrew', Arial, sans-serif !important;
}
/* Japanese */
html[lang="ja"] #{$wrapper_classname} * {
font-family: -apple-system, BlinkMacSystemFont, "Hiragino Sans", Meiryo, "Helvetica Neue", sans-serif !important;
}
/* Korean */
html[lang="ko-KR"] #{$wrapper_classname} * {
font-family: 'Apple SD Gothic Neo', 'Malgun Gothic', 'Nanum Gothic', Dotum, sans-serif !important;
}
/* Thai */
html[lang="th"] #{$wrapper_classname} * {
font-family: 'Sukhumvit Set', 'Helvetica Neue', helvetica, arial, sans-serif !important;
}
/* Vietnamese */
html[lang="vi"] #{$wrapper_classname} * {
font-family: 'Libre Franklin', sans-serif !important;
}
}
/* Calculates maximum width for post content */ /* Calculates maximum width for post content */
@mixin postContentMaxWidth() { @mixin postContentMaxWidth() {
@ -202,4 +114,19 @@
} }
} }
/* Ensure all font family declarations come with non-latin fallbacks */
@mixin font-family( $font_family: $font__body ) {
font-family: $font_family;
@extend %non-latin-fonts;
}
/* Build our non-latin font styles */
%non-latin-fonts {
@each $lang, $font__fallback in $font__fallbacks {
&:lang(#{$lang}) {
font-family: unquote( $font__fallback );
}
}
}
@import "utilities"; @import "utilities";

View file

@ -26,7 +26,8 @@
background: transparent; background: transparent;
color: inherit; color: inherit;
cursor: pointer; cursor: pointer;
transition: background 250ms ease-in-out, transition:
background 250ms ease-in-out,
transform 150ms ease; transform 150ms ease;
-webkit-appearance: none; -webkit-appearance: none;
-moz-appearance: none; -moz-appearance: none;

View file

@ -176,7 +176,7 @@
.nav-next { .nav-next {
min-width: 50%; min-width: 50%;
width: 100%; width: 100%;
font-family: $font__heading; @include font-family( $font__heading );
font-weight: bold; font-weight: bold;
.secondary-text { .secondary-text {

View file

@ -15,7 +15,12 @@
display: flex; display: flex;
flex-wrap: wrap; flex-wrap: wrap;
.widget { .widget {
-webkit-hyphens: auto;
-moz-hyphens: auto;
-ms-hyphens: auto;
hyphens: auto;
width: 100%; width: 100%;
word-wrap: break-word;
@include media(desktop) { @include media(desktop) {
margin-right: calc(3 * #{$size__spacing-unit}); margin-right: calc(3 * #{$size__spacing-unit});
width: calc(50% - (3 * #{$size__spacing-unit})); width: calc(50% - (3 * #{$size__spacing-unit}));
@ -25,6 +30,11 @@
.site-info { .site-info {
color: $color__text-light; color: $color__text-light;
-webkit-hyphens: auto;
-moz-hyphens: auto;
-ms-hyphens: auto;
hyphens: auto;
word-wrap: break-word;
a { a {
color: inherit; color: inherit;

View file

@ -30,7 +30,12 @@
.site-branding { .site-branding {
color: $color__text-light; color: $color__text-light;
-webkit-hyphens: auto;
-moz-hyphens: auto;
-ms-hyphens: auto;
hyphens: auto;
position: relative; position: relative;
word-wrap: break-word;
@include media(tablet) { @include media(tablet) {
margin: 0 $size__site-margins; margin: 0 $size__site-margins;

View file

@ -50,6 +50,7 @@
.error-404.not-found, .error-404.not-found,
.no-results.not-found { .no-results.not-found {
.page-title,
.page-content { .page-content {
margin: calc(3 * #{$size__spacing-unit}) #{$size__spacing-unit}; margin: calc(3 * #{$size__spacing-unit}) #{$size__spacing-unit};

View file

@ -7,7 +7,12 @@
} }
.comments-area { .comments-area {
-webkit-hyphens: auto;
-moz-hyphens: auto;
-ms-hyphens: auto;
hyphens: auto;
margin: calc(2 * #{$size__spacing-unit}) $size__spacing-unit; margin: calc(2 * #{$size__spacing-unit}) $size__spacing-unit;
word-wrap: break-word;
@include postContentMaxWidth(); @include postContentMaxWidth();
@include media(tablet) { @include media(tablet) {
@ -127,7 +132,7 @@
.comment-body { .comment-body {
color: $color__text-light; color: $color__text-light;
font-family: $font__heading; @include font-family( $font__heading );
font-size: $font__size-xs; font-size: $font__size-xs;
font-weight: 500; font-weight: 500;
margin-top: $size__spacing-unit; margin-top: $size__spacing-unit;
@ -143,7 +148,7 @@
.comment-edit-link { .comment-edit-link {
color: $color__text-light; color: $color__text-light;
font-family: $font__heading; @include font-family( $font__heading );
font-weight: 500; font-weight: 500;
} }
} }
@ -372,7 +377,7 @@
.comment-notes, .comment-notes,
label { label {
font-family: $font__heading; @include font-family( $font__heading );
font-size: $font__size-xs; font-size: $font__size-xs;
color: $color__text-light; color: $color__text-light;
} }

View file

@ -30,7 +30,7 @@
li { li {
color: $color__text-light; color: $color__text-light;
font-family: $font__heading; @include font-family( $font__heading );
font-size: calc(#{$font__size_base} * #{$font__size-ratio}); font-size: calc(#{$font__size_base} * #{$font__size-ratio});
font-weight: 700; font-weight: 700;
line-height: $font__line-height-heading; line-height: $font__line-height-heading;
@ -45,7 +45,7 @@
.widget_tag_cloud { .widget_tag_cloud {
.tagcloud { .tagcloud {
font-family: $font__heading; @include font-family( $font__heading );
font-weight: 700; font-weight: 700;
} }
} }

View file

@ -15,7 +15,7 @@ blockquote {
cite { cite {
font-size: $font__size-xs; font-size: $font__size-xs;
font-style: normal; font-style: normal;
font-family: $font__heading; @include font-family( $font__heading );
} }
} }

View file

@ -18,14 +18,13 @@
.site-title, .site-title,
.site-info, .site-info,
#cancel-comment-reply-link, #cancel-comment-reply-link,
img:after,
h1, h1,
h2, h2,
h3, h3,
h4, h4,
h5, h5,
h6 { h6 {
font-family: $font__heading; @include font-family( $font__heading );
} }
.main-navigation, .main-navigation,
@ -53,7 +52,7 @@ h6 {
} }
.page-title { .page-title {
font-family: $font__body; @include font-family( $font__body );
} }
.site-branding, .site-branding,
@ -146,13 +145,20 @@ h6 {
.error-404 .page-title, .error-404 .page-title,
.comments-title, .comments-title,
blockquote { blockquote {
-webkit-hyphens: auto;
-moz-hyphens: auto;
-ms-hyphens: auto;
hyphens: auto; hyphens: auto;
word-break: break-word; word-break: break-word;
word-wrap: break-word;
} }
/* Do not hyphenate entry title on tablet view and bigger. */ /* Do not hyphenate entry title on tablet view and bigger. */
.entry-title { .entry-title {
@include media(tablet) { @include media(tablet) {
-webkit-hyphens: none;
-moz-hyphens: none;
-ms-hyphens: none;
hyphens: none; hyphens: none;
} }
} }

View file

@ -7,7 +7,7 @@ body {
-webkit-font-smoothing: antialiased; -webkit-font-smoothing: antialiased;
-moz-osx-font-smoothing: grayscale; -moz-osx-font-smoothing: grayscale;
color: $color__text-main; color: $color__text-main;
font-family: $font__body; @include font-family( $font__body );
font-weight: 400; font-weight: 400;
font-size: 1em; font-size: 1em;
line-height: $font__line-height-body; line-height: $font__line-height-body;
@ -21,7 +21,7 @@ select,
optgroup, optgroup,
textarea { textarea {
color: $color__text-main; color: $color__text-main;
font-family: $font__body; @include font-family( $font__body );
font-weight: 400; font-weight: 400;
line-height: $font__line-height-body; line-height: $font__line-height-body;
text-rendering: optimizeLegibility; text-rendering: optimizeLegibility;
@ -30,5 +30,3 @@ textarea {
@import "headings"; @import "headings";
@import "copy"; @import "copy";
@include non-latin-fonts();

View file

@ -16,6 +16,52 @@
$font__body: "NonBreakingSpaceOverride", "Hoefler Text", "Baskerville Old Face", Garamond, "Times New Roman", serif; $font__body: "NonBreakingSpaceOverride", "Hoefler Text", "Baskerville Old Face", Garamond, "Times New Roman", serif;
$font__heading: -apple-system, BlinkMacSystemFont, "Segoe UI", "Roboto", "Oxygen", "Ubuntu", "Cantarell", "Fira Sans", "Droid Sans", "Helvetica Neue", sans-serif; $font__heading: -apple-system, BlinkMacSystemFont, "Segoe UI", "Roboto", "Oxygen", "Ubuntu", "Cantarell", "Fira Sans", "Droid Sans", "Helvetica Neue", sans-serif;
$font__fallbacks: (
/* Arabic */
ar: 'Tahoma, Arial, sans-serif',
ary: 'Tahoma, Arial, sans-serif',
azb: 'Tahoma, Arial, sans-serif',
ckb: 'Tahoma, Arial, sans-serif',
fa-IR: 'Tahoma, Arial, sans-serif',
haz: 'Tahoma, Arial, sans-serif',
ps: 'Tahoma, Arial, sans-serif',
/* Cyrillic */
be: '"Helvetica Neue", Helvetica, "Segoe UI", Arial, sans-serif',
bg-BG: '"Helvetica Neue", Helvetica, "Segoe UI", Arial, sans-serif',
kk: '"Helvetica Neue", Helvetica, "Segoe UI", Arial, sans-serif',
mk-MK: '"Helvetica Neue", Helvetica, "Segoe UI", Arial, sans-serif',
mn: '"Helvetica Neue", Helvetica, "Segoe UI", Arial, sans-serif',
ru-RU: '"Helvetica Neue", Helvetica, "Segoe UI", Arial, sans-serif',
sah: '"Helvetica Neue", Helvetica, "Segoe UI", Arial, sans-serif',
sr-RS: '"Helvetica Neue", Helvetica, "Segoe UI", Arial, sans-serif',
tt-RU: '"Helvetica Neue", Helvetica, "Segoe UI", Arial, sans-serif',
uk: '"Helvetica Neue", Helvetica, "Segoe UI", Arial, sans-serif',
/* Chinese (Hong Kong) */
zh-HK: '-apple-system, BlinkMacSystemFont, "PingFang HK", "Helvetica Neue", "Microsoft YaHei New", STHeiti Light, sans-serif',
/* Chinese (Taiwan) */
zh-TW: '-apple-system, BlinkMacSystemFont, "PingFang TC", "Helvetica Neue", "Microsoft YaHei New", STHeiti Light, sans-serif',
/* Chinese (China) */
zh-CN: '-apple-system, BlinkMacSystemFont, "PingFang SC", "Helvetica Neue", "Microsoft YaHei New", STHeiti Light, sans-serif',
/* Devanagari */
bn-BD: 'Arial, sans-serif',
hi-IN: 'Arial, sans-serif',
mr: 'Arial, sans-serif',
ne-NP: 'Arial, sans-serif',
/* Greek */
el: '"Helvetica Neue", Helvetica, Arial, sans-serif',
/* Gujarati */
gu: 'Arial, sans-serif',
/* Hebrew */
he-IL: '"Arial Hebrew", Arial, sans-serif',
/* Japanese */
ja: '-apple-system, BlinkMacSystemFont, "Hiragino Sans", Meiryo, "Helvetica Neue", sans-serif',
/* Korean */
ko-KR: '"Apple SD Gothic Neo", "Malgun Gothic", "Nanum Gothic", Dotum, sans-serif',
/* Thai */
th: '"Sukhumvit Set", "Helvetica Neue", helvetica, arial, sans-serif',
/* Vietnamese */
vi: '"Libre Franklin", sans-serif',
);
$font__code: Menlo, monaco, Consolas, Lucida Console, monospace; $font__code: Menlo, monaco, Consolas, Lucida Console, monospace;
$font__pre: "Courier 10 Pitch", Courier, monospace; $font__pre: "Courier 10 Pitch", Courier, monospace;

View file

@ -1,95 +1,5 @@
/*! /*!
Twenty Nineteen Customizer Styles & Non-latin Font Fallbacks Twenty Nineteen Customizer Styles
NOTE: This file is automatically populated with additional styles if the user selects a custom primary color in the customzier. NOTE: This file is automatically populated with styles if the user selects a custom primary color in the customzier.
*/ */
/** === Includes === */
/* If we add the border using a regular CSS border, it won't look good on non-retina devices,
* since its edges can look jagged due to lack of antialiasing. In this case, we are several
* layers of box-shadow to add the border visually, which will render the border smoother. */
/* Fallback for non-latin fonts */
/* Calculates maximum width for post content */
/* Nested sub-menu padding: 10 levels deep */
/** === Non-Latin font fallbacks === */
/* Arabic */
html[lang="ar"] .wp-block *,
html[lang="ary"] .wp-block *,
html[lang="azb"] .wp-block *,
html[lang="ckb"] .wp-block *,
html[lang="fa-IR"] .wp-block *,
html[lang="haz"] .wp-block *,
html[lang="ps"] .wp-block * {
font-family: Tahoma, Arial, sans-serif !important;
}
/* Cyrillic */
html[lang="be"] .wp-block *,
html[lang="bg-BG"] .wp-block *,
html[lang="kk"] .wp-block *,
html[lang="mk-MK"] .wp-block *,
html[lang="mn"] .wp-block *,
html[lang="ru-RU"] .wp-block *,
html[lang="sah"] .wp-block *,
html[lang="sr-RS"] .wp-block *,
html[lang="tt-RU"] .wp-block *,
html[lang="uk"] .wp-block * {
font-family: 'Helvetica Neue', Helvetica, 'Segoe UI', Arial, sans-serif !important;
}
/* Chinese (Hong Kong) */
html[lang="zh-HK"] .wp-block * {
font-family: -apple-system, BlinkMacSystemFont, 'PingFang HK', 'Helvetica Neue', "Microsoft YaHei New", STHeiti Light, sans-serif !important;
}
/* Chinese (Taiwan) */
html[lang="zh-TW"] .wp-block * {
font-family: -apple-system, BlinkMacSystemFont, 'PingFang TC', 'Helvetica Neue', "Microsoft YaHei New", STHeiti Light, sans-serif !important;
}
/* Chinese (China) */
html[lang="zh-CN"] .wp-block * {
font-family: -apple-system, BlinkMacSystemFont, 'PingFang SC', 'Helvetica Neue', "Microsoft YaHei New", STHeiti Light, sans-serif !important;
}
/* Devanagari */
html[lang="bn-BD"] .wp-block *,
html[lang="hi-IN"] .wp-block *,
html[lang="mr"] .wp-block *,
html[lang="ne-NP"] .wp-block * {
font-family: Arial, sans-serif !important;
}
/* Greek */
html[lang="el"] .wp-block * {
font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif !important;
}
/* Gujarati */
html[lang="gu"] .wp-block * {
font-family: Arial, sans-serif !important;
}
/* Hebrew */
html[lang="he-IL"] .wp-block * {
font-family: 'Arial Hebrew', Arial, sans-serif !important;
}
/* Japanese */
html[lang="ja"] .wp-block * {
font-family: -apple-system, BlinkMacSystemFont, "Hiragino Sans", Meiryo, "Helvetica Neue", sans-serif !important;
}
/* Korean */
html[lang="ko-KR"] .wp-block * {
font-family: 'Apple SD Gothic Neo', 'Malgun Gothic', 'Nanum Gothic', Dotum, sans-serif !important;
}
/* Thai */
html[lang="th"] .wp-block * {
font-family: 'Sukhumvit Set', 'Helvetica Neue', helvetica, arial, sans-serif !important;
}
/* Vietnamese */
html[lang="vi"] .wp-block * {
font-family: 'Libre Franklin', sans-serif !important;
}

View file

@ -1,13 +1,5 @@
/*! /*!
Twenty Nineteen Customizer Styles & Non-latin Font Fallbacks Twenty Nineteen Customizer Styles
NOTE: This file is automatically populated with additional styles if the user selects a custom primary color in the customzier. NOTE: This file is automatically populated with styles if the user selects a custom primary color in the customzier.
*/ */
/** === Includes === */
@import "sass/mixins/mixins-master";
/** === Non-Latin font fallbacks === */
@include non-latin-fonts( '.wp-block' );

View file

@ -18,9 +18,537 @@ Twenty Nineteen Editor Styles
/* If we add the border using a regular CSS border, it won't look good on non-retina devices, /* If we add the border using a regular CSS border, it won't look good on non-retina devices,
* since its edges can look jagged due to lack of antialiasing. In this case, we are several * since its edges can look jagged due to lack of antialiasing. In this case, we are several
* layers of box-shadow to add the border visually, which will render the border smoother. */ * layers of box-shadow to add the border visually, which will render the border smoother. */
/* Fallback for non-latin fonts */
/* Calculates maximum width for post content */ /* Calculates maximum width for post content */
/* Nested sub-menu padding: 10 levels deep */ /* Nested sub-menu padding: 10 levels deep */
/* Ensure all font family declarations come with non-latin fallbacks */
/* Build our non-latin font styles */
body:lang(ar), h1:lang(ar),
h2:lang(ar),
h3:lang(ar),
h4:lang(ar),
h5:lang(ar),
h6:lang(ar), figcaption:lang(ar),
.gallery-caption:lang(ar), .editor-post-title__block .editor-post-title__input:lang(ar), .editor-default-block-appender .editor-default-block-appender__content:lang(ar), .wp-block-paragraph.has-drop-cap:lang(ar):not(:focus)::first-letter, .wp-block-table:lang(ar), .wp-block-cover h2:lang(ar),
.wp-block-cover .wp-block-cover-text:lang(ar), .wp-block-button .wp-block-button__link:lang(ar), .wp-block-quote cite:lang(ar),
.wp-block-quote footer:lang(ar),
.wp-block-quote .wp-block-quote__citation:lang(ar), .wp-block[data-type="core/pullquote"] .wp-block-pullquote__citation:lang(ar),
.wp-block[data-type="core/pullquote"][data-align="left"] .wp-block-pullquote__citation:lang(ar),
.wp-block[data-type="core/pullquote"][data-align="right"] .wp-block-pullquote__citation:lang(ar), .wp-block-file:lang(ar), ul.wp-block-archives li:lang(ar),
.wp-block-categories li:lang(ar),
.wp-block-latest-posts li:lang(ar), .wp-block-latest-comments .wp-block-latest-comments__comment-meta:lang(ar), .wp-caption dd:lang(ar), .wp-block-freeform blockquote cite:lang(ar) {
font-family: Tahoma, Arial, sans-serif;
}
body:lang(ary), h1:lang(ary),
h2:lang(ary),
h3:lang(ary),
h4:lang(ary),
h5:lang(ary),
h6:lang(ary), figcaption:lang(ary),
.gallery-caption:lang(ary), .editor-post-title__block .editor-post-title__input:lang(ary), .editor-default-block-appender .editor-default-block-appender__content:lang(ary), .wp-block-paragraph.has-drop-cap:lang(ary):not(:focus)::first-letter, .wp-block-table:lang(ary), .wp-block-cover h2:lang(ary),
.wp-block-cover .wp-block-cover-text:lang(ary), .wp-block-button .wp-block-button__link:lang(ary), .wp-block-quote cite:lang(ary),
.wp-block-quote footer:lang(ary),
.wp-block-quote .wp-block-quote__citation:lang(ary), .wp-block[data-type="core/pullquote"] .wp-block-pullquote__citation:lang(ary),
.wp-block[data-type="core/pullquote"][data-align="left"] .wp-block-pullquote__citation:lang(ary),
.wp-block[data-type="core/pullquote"][data-align="right"] .wp-block-pullquote__citation:lang(ary), .wp-block-file:lang(ary), ul.wp-block-archives li:lang(ary),
.wp-block-categories li:lang(ary),
.wp-block-latest-posts li:lang(ary), .wp-block-latest-comments .wp-block-latest-comments__comment-meta:lang(ary), .wp-caption dd:lang(ary), .wp-block-freeform blockquote cite:lang(ary) {
font-family: Tahoma, Arial, sans-serif;
}
body:lang(azb), h1:lang(azb),
h2:lang(azb),
h3:lang(azb),
h4:lang(azb),
h5:lang(azb),
h6:lang(azb), figcaption:lang(azb),
.gallery-caption:lang(azb), .editor-post-title__block .editor-post-title__input:lang(azb), .editor-default-block-appender .editor-default-block-appender__content:lang(azb), .wp-block-paragraph.has-drop-cap:lang(azb):not(:focus)::first-letter, .wp-block-table:lang(azb), .wp-block-cover h2:lang(azb),
.wp-block-cover .wp-block-cover-text:lang(azb), .wp-block-button .wp-block-button__link:lang(azb), .wp-block-quote cite:lang(azb),
.wp-block-quote footer:lang(azb),
.wp-block-quote .wp-block-quote__citation:lang(azb), .wp-block[data-type="core/pullquote"] .wp-block-pullquote__citation:lang(azb),
.wp-block[data-type="core/pullquote"][data-align="left"] .wp-block-pullquote__citation:lang(azb),
.wp-block[data-type="core/pullquote"][data-align="right"] .wp-block-pullquote__citation:lang(azb), .wp-block-file:lang(azb), ul.wp-block-archives li:lang(azb),
.wp-block-categories li:lang(azb),
.wp-block-latest-posts li:lang(azb), .wp-block-latest-comments .wp-block-latest-comments__comment-meta:lang(azb), .wp-caption dd:lang(azb), .wp-block-freeform blockquote cite:lang(azb) {
font-family: Tahoma, Arial, sans-serif;
}
body:lang(ckb), h1:lang(ckb),
h2:lang(ckb),
h3:lang(ckb),
h4:lang(ckb),
h5:lang(ckb),
h6:lang(ckb), figcaption:lang(ckb),
.gallery-caption:lang(ckb), .editor-post-title__block .editor-post-title__input:lang(ckb), .editor-default-block-appender .editor-default-block-appender__content:lang(ckb), .wp-block-paragraph.has-drop-cap:lang(ckb):not(:focus)::first-letter, .wp-block-table:lang(ckb), .wp-block-cover h2:lang(ckb),
.wp-block-cover .wp-block-cover-text:lang(ckb), .wp-block-button .wp-block-button__link:lang(ckb), .wp-block-quote cite:lang(ckb),
.wp-block-quote footer:lang(ckb),
.wp-block-quote .wp-block-quote__citation:lang(ckb), .wp-block[data-type="core/pullquote"] .wp-block-pullquote__citation:lang(ckb),
.wp-block[data-type="core/pullquote"][data-align="left"] .wp-block-pullquote__citation:lang(ckb),
.wp-block[data-type="core/pullquote"][data-align="right"] .wp-block-pullquote__citation:lang(ckb), .wp-block-file:lang(ckb), ul.wp-block-archives li:lang(ckb),
.wp-block-categories li:lang(ckb),
.wp-block-latest-posts li:lang(ckb), .wp-block-latest-comments .wp-block-latest-comments__comment-meta:lang(ckb), .wp-caption dd:lang(ckb), .wp-block-freeform blockquote cite:lang(ckb) {
font-family: Tahoma, Arial, sans-serif;
}
body:lang(fa-IR), h1:lang(fa-IR),
h2:lang(fa-IR),
h3:lang(fa-IR),
h4:lang(fa-IR),
h5:lang(fa-IR),
h6:lang(fa-IR), figcaption:lang(fa-IR),
.gallery-caption:lang(fa-IR), .editor-post-title__block .editor-post-title__input:lang(fa-IR), .editor-default-block-appender .editor-default-block-appender__content:lang(fa-IR), .wp-block-paragraph.has-drop-cap:lang(fa-IR):not(:focus)::first-letter, .wp-block-table:lang(fa-IR), .wp-block-cover h2:lang(fa-IR),
.wp-block-cover .wp-block-cover-text:lang(fa-IR), .wp-block-button .wp-block-button__link:lang(fa-IR), .wp-block-quote cite:lang(fa-IR),
.wp-block-quote footer:lang(fa-IR),
.wp-block-quote .wp-block-quote__citation:lang(fa-IR), .wp-block[data-type="core/pullquote"] .wp-block-pullquote__citation:lang(fa-IR),
.wp-block[data-type="core/pullquote"][data-align="left"] .wp-block-pullquote__citation:lang(fa-IR),
.wp-block[data-type="core/pullquote"][data-align="right"] .wp-block-pullquote__citation:lang(fa-IR), .wp-block-file:lang(fa-IR), ul.wp-block-archives li:lang(fa-IR),
.wp-block-categories li:lang(fa-IR),
.wp-block-latest-posts li:lang(fa-IR), .wp-block-latest-comments .wp-block-latest-comments__comment-meta:lang(fa-IR), .wp-caption dd:lang(fa-IR), .wp-block-freeform blockquote cite:lang(fa-IR) {
font-family: Tahoma, Arial, sans-serif;
}
body:lang(haz), h1:lang(haz),
h2:lang(haz),
h3:lang(haz),
h4:lang(haz),
h5:lang(haz),
h6:lang(haz), figcaption:lang(haz),
.gallery-caption:lang(haz), .editor-post-title__block .editor-post-title__input:lang(haz), .editor-default-block-appender .editor-default-block-appender__content:lang(haz), .wp-block-paragraph.has-drop-cap:lang(haz):not(:focus)::first-letter, .wp-block-table:lang(haz), .wp-block-cover h2:lang(haz),
.wp-block-cover .wp-block-cover-text:lang(haz), .wp-block-button .wp-block-button__link:lang(haz), .wp-block-quote cite:lang(haz),
.wp-block-quote footer:lang(haz),
.wp-block-quote .wp-block-quote__citation:lang(haz), .wp-block[data-type="core/pullquote"] .wp-block-pullquote__citation:lang(haz),
.wp-block[data-type="core/pullquote"][data-align="left"] .wp-block-pullquote__citation:lang(haz),
.wp-block[data-type="core/pullquote"][data-align="right"] .wp-block-pullquote__citation:lang(haz), .wp-block-file:lang(haz), ul.wp-block-archives li:lang(haz),
.wp-block-categories li:lang(haz),
.wp-block-latest-posts li:lang(haz), .wp-block-latest-comments .wp-block-latest-comments__comment-meta:lang(haz), .wp-caption dd:lang(haz), .wp-block-freeform blockquote cite:lang(haz) {
font-family: Tahoma, Arial, sans-serif;
}
body:lang(ps), h1:lang(ps),
h2:lang(ps),
h3:lang(ps),
h4:lang(ps),
h5:lang(ps),
h6:lang(ps), figcaption:lang(ps),
.gallery-caption:lang(ps), .editor-post-title__block .editor-post-title__input:lang(ps), .editor-default-block-appender .editor-default-block-appender__content:lang(ps), .wp-block-paragraph.has-drop-cap:lang(ps):not(:focus)::first-letter, .wp-block-table:lang(ps), .wp-block-cover h2:lang(ps),
.wp-block-cover .wp-block-cover-text:lang(ps), .wp-block-button .wp-block-button__link:lang(ps), .wp-block-quote cite:lang(ps),
.wp-block-quote footer:lang(ps),
.wp-block-quote .wp-block-quote__citation:lang(ps), .wp-block[data-type="core/pullquote"] .wp-block-pullquote__citation:lang(ps),
.wp-block[data-type="core/pullquote"][data-align="left"] .wp-block-pullquote__citation:lang(ps),
.wp-block[data-type="core/pullquote"][data-align="right"] .wp-block-pullquote__citation:lang(ps), .wp-block-file:lang(ps), ul.wp-block-archives li:lang(ps),
.wp-block-categories li:lang(ps),
.wp-block-latest-posts li:lang(ps), .wp-block-latest-comments .wp-block-latest-comments__comment-meta:lang(ps), .wp-caption dd:lang(ps), .wp-block-freeform blockquote cite:lang(ps) {
font-family: Tahoma, Arial, sans-serif;
}
body:lang(be), h1:lang(be),
h2:lang(be),
h3:lang(be),
h4:lang(be),
h5:lang(be),
h6:lang(be), figcaption:lang(be),
.gallery-caption:lang(be), .editor-post-title__block .editor-post-title__input:lang(be), .editor-default-block-appender .editor-default-block-appender__content:lang(be), .wp-block-paragraph.has-drop-cap:lang(be):not(:focus)::first-letter, .wp-block-table:lang(be), .wp-block-cover h2:lang(be),
.wp-block-cover .wp-block-cover-text:lang(be), .wp-block-button .wp-block-button__link:lang(be), .wp-block-quote cite:lang(be),
.wp-block-quote footer:lang(be),
.wp-block-quote .wp-block-quote__citation:lang(be), .wp-block[data-type="core/pullquote"] .wp-block-pullquote__citation:lang(be),
.wp-block[data-type="core/pullquote"][data-align="left"] .wp-block-pullquote__citation:lang(be),
.wp-block[data-type="core/pullquote"][data-align="right"] .wp-block-pullquote__citation:lang(be), .wp-block-file:lang(be), ul.wp-block-archives li:lang(be),
.wp-block-categories li:lang(be),
.wp-block-latest-posts li:lang(be), .wp-block-latest-comments .wp-block-latest-comments__comment-meta:lang(be), .wp-caption dd:lang(be), .wp-block-freeform blockquote cite:lang(be) {
font-family: "Helvetica Neue", Helvetica, "Segoe UI", Arial, sans-serif;
}
body:lang(bg-BG), h1:lang(bg-BG),
h2:lang(bg-BG),
h3:lang(bg-BG),
h4:lang(bg-BG),
h5:lang(bg-BG),
h6:lang(bg-BG), figcaption:lang(bg-BG),
.gallery-caption:lang(bg-BG), .editor-post-title__block .editor-post-title__input:lang(bg-BG), .editor-default-block-appender .editor-default-block-appender__content:lang(bg-BG), .wp-block-paragraph.has-drop-cap:lang(bg-BG):not(:focus)::first-letter, .wp-block-table:lang(bg-BG), .wp-block-cover h2:lang(bg-BG),
.wp-block-cover .wp-block-cover-text:lang(bg-BG), .wp-block-button .wp-block-button__link:lang(bg-BG), .wp-block-quote cite:lang(bg-BG),
.wp-block-quote footer:lang(bg-BG),
.wp-block-quote .wp-block-quote__citation:lang(bg-BG), .wp-block[data-type="core/pullquote"] .wp-block-pullquote__citation:lang(bg-BG),
.wp-block[data-type="core/pullquote"][data-align="left"] .wp-block-pullquote__citation:lang(bg-BG),
.wp-block[data-type="core/pullquote"][data-align="right"] .wp-block-pullquote__citation:lang(bg-BG), .wp-block-file:lang(bg-BG), ul.wp-block-archives li:lang(bg-BG),
.wp-block-categories li:lang(bg-BG),
.wp-block-latest-posts li:lang(bg-BG), .wp-block-latest-comments .wp-block-latest-comments__comment-meta:lang(bg-BG), .wp-caption dd:lang(bg-BG), .wp-block-freeform blockquote cite:lang(bg-BG) {
font-family: "Helvetica Neue", Helvetica, "Segoe UI", Arial, sans-serif;
}
body:lang(kk), h1:lang(kk),
h2:lang(kk),
h3:lang(kk),
h4:lang(kk),
h5:lang(kk),
h6:lang(kk), figcaption:lang(kk),
.gallery-caption:lang(kk), .editor-post-title__block .editor-post-title__input:lang(kk), .editor-default-block-appender .editor-default-block-appender__content:lang(kk), .wp-block-paragraph.has-drop-cap:lang(kk):not(:focus)::first-letter, .wp-block-table:lang(kk), .wp-block-cover h2:lang(kk),
.wp-block-cover .wp-block-cover-text:lang(kk), .wp-block-button .wp-block-button__link:lang(kk), .wp-block-quote cite:lang(kk),
.wp-block-quote footer:lang(kk),
.wp-block-quote .wp-block-quote__citation:lang(kk), .wp-block[data-type="core/pullquote"] .wp-block-pullquote__citation:lang(kk),
.wp-block[data-type="core/pullquote"][data-align="left"] .wp-block-pullquote__citation:lang(kk),
.wp-block[data-type="core/pullquote"][data-align="right"] .wp-block-pullquote__citation:lang(kk), .wp-block-file:lang(kk), ul.wp-block-archives li:lang(kk),
.wp-block-categories li:lang(kk),
.wp-block-latest-posts li:lang(kk), .wp-block-latest-comments .wp-block-latest-comments__comment-meta:lang(kk), .wp-caption dd:lang(kk), .wp-block-freeform blockquote cite:lang(kk) {
font-family: "Helvetica Neue", Helvetica, "Segoe UI", Arial, sans-serif;
}
body:lang(mk-MK), h1:lang(mk-MK),
h2:lang(mk-MK),
h3:lang(mk-MK),
h4:lang(mk-MK),
h5:lang(mk-MK),
h6:lang(mk-MK), figcaption:lang(mk-MK),
.gallery-caption:lang(mk-MK), .editor-post-title__block .editor-post-title__input:lang(mk-MK), .editor-default-block-appender .editor-default-block-appender__content:lang(mk-MK), .wp-block-paragraph.has-drop-cap:lang(mk-MK):not(:focus)::first-letter, .wp-block-table:lang(mk-MK), .wp-block-cover h2:lang(mk-MK),
.wp-block-cover .wp-block-cover-text:lang(mk-MK), .wp-block-button .wp-block-button__link:lang(mk-MK), .wp-block-quote cite:lang(mk-MK),
.wp-block-quote footer:lang(mk-MK),
.wp-block-quote .wp-block-quote__citation:lang(mk-MK), .wp-block[data-type="core/pullquote"] .wp-block-pullquote__citation:lang(mk-MK),
.wp-block[data-type="core/pullquote"][data-align="left"] .wp-block-pullquote__citation:lang(mk-MK),
.wp-block[data-type="core/pullquote"][data-align="right"] .wp-block-pullquote__citation:lang(mk-MK), .wp-block-file:lang(mk-MK), ul.wp-block-archives li:lang(mk-MK),
.wp-block-categories li:lang(mk-MK),
.wp-block-latest-posts li:lang(mk-MK), .wp-block-latest-comments .wp-block-latest-comments__comment-meta:lang(mk-MK), .wp-caption dd:lang(mk-MK), .wp-block-freeform blockquote cite:lang(mk-MK) {
font-family: "Helvetica Neue", Helvetica, "Segoe UI", Arial, sans-serif;
}
body:lang(mn), h1:lang(mn),
h2:lang(mn),
h3:lang(mn),
h4:lang(mn),
h5:lang(mn),
h6:lang(mn), figcaption:lang(mn),
.gallery-caption:lang(mn), .editor-post-title__block .editor-post-title__input:lang(mn), .editor-default-block-appender .editor-default-block-appender__content:lang(mn), .wp-block-paragraph.has-drop-cap:lang(mn):not(:focus)::first-letter, .wp-block-table:lang(mn), .wp-block-cover h2:lang(mn),
.wp-block-cover .wp-block-cover-text:lang(mn), .wp-block-button .wp-block-button__link:lang(mn), .wp-block-quote cite:lang(mn),
.wp-block-quote footer:lang(mn),
.wp-block-quote .wp-block-quote__citation:lang(mn), .wp-block[data-type="core/pullquote"] .wp-block-pullquote__citation:lang(mn),
.wp-block[data-type="core/pullquote"][data-align="left"] .wp-block-pullquote__citation:lang(mn),
.wp-block[data-type="core/pullquote"][data-align="right"] .wp-block-pullquote__citation:lang(mn), .wp-block-file:lang(mn), ul.wp-block-archives li:lang(mn),
.wp-block-categories li:lang(mn),
.wp-block-latest-posts li:lang(mn), .wp-block-latest-comments .wp-block-latest-comments__comment-meta:lang(mn), .wp-caption dd:lang(mn), .wp-block-freeform blockquote cite:lang(mn) {
font-family: "Helvetica Neue", Helvetica, "Segoe UI", Arial, sans-serif;
}
body:lang(ru-RU), h1:lang(ru-RU),
h2:lang(ru-RU),
h3:lang(ru-RU),
h4:lang(ru-RU),
h5:lang(ru-RU),
h6:lang(ru-RU), figcaption:lang(ru-RU),
.gallery-caption:lang(ru-RU), .editor-post-title__block .editor-post-title__input:lang(ru-RU), .editor-default-block-appender .editor-default-block-appender__content:lang(ru-RU), .wp-block-paragraph.has-drop-cap:lang(ru-RU):not(:focus)::first-letter, .wp-block-table:lang(ru-RU), .wp-block-cover h2:lang(ru-RU),
.wp-block-cover .wp-block-cover-text:lang(ru-RU), .wp-block-button .wp-block-button__link:lang(ru-RU), .wp-block-quote cite:lang(ru-RU),
.wp-block-quote footer:lang(ru-RU),
.wp-block-quote .wp-block-quote__citation:lang(ru-RU), .wp-block[data-type="core/pullquote"] .wp-block-pullquote__citation:lang(ru-RU),
.wp-block[data-type="core/pullquote"][data-align="left"] .wp-block-pullquote__citation:lang(ru-RU),
.wp-block[data-type="core/pullquote"][data-align="right"] .wp-block-pullquote__citation:lang(ru-RU), .wp-block-file:lang(ru-RU), ul.wp-block-archives li:lang(ru-RU),
.wp-block-categories li:lang(ru-RU),
.wp-block-latest-posts li:lang(ru-RU), .wp-block-latest-comments .wp-block-latest-comments__comment-meta:lang(ru-RU), .wp-caption dd:lang(ru-RU), .wp-block-freeform blockquote cite:lang(ru-RU) {
font-family: "Helvetica Neue", Helvetica, "Segoe UI", Arial, sans-serif;
}
body:lang(sah), h1:lang(sah),
h2:lang(sah),
h3:lang(sah),
h4:lang(sah),
h5:lang(sah),
h6:lang(sah), figcaption:lang(sah),
.gallery-caption:lang(sah), .editor-post-title__block .editor-post-title__input:lang(sah), .editor-default-block-appender .editor-default-block-appender__content:lang(sah), .wp-block-paragraph.has-drop-cap:lang(sah):not(:focus)::first-letter, .wp-block-table:lang(sah), .wp-block-cover h2:lang(sah),
.wp-block-cover .wp-block-cover-text:lang(sah), .wp-block-button .wp-block-button__link:lang(sah), .wp-block-quote cite:lang(sah),
.wp-block-quote footer:lang(sah),
.wp-block-quote .wp-block-quote__citation:lang(sah), .wp-block[data-type="core/pullquote"] .wp-block-pullquote__citation:lang(sah),
.wp-block[data-type="core/pullquote"][data-align="left"] .wp-block-pullquote__citation:lang(sah),
.wp-block[data-type="core/pullquote"][data-align="right"] .wp-block-pullquote__citation:lang(sah), .wp-block-file:lang(sah), ul.wp-block-archives li:lang(sah),
.wp-block-categories li:lang(sah),
.wp-block-latest-posts li:lang(sah), .wp-block-latest-comments .wp-block-latest-comments__comment-meta:lang(sah), .wp-caption dd:lang(sah), .wp-block-freeform blockquote cite:lang(sah) {
font-family: "Helvetica Neue", Helvetica, "Segoe UI", Arial, sans-serif;
}
body:lang(sr-RS), h1:lang(sr-RS),
h2:lang(sr-RS),
h3:lang(sr-RS),
h4:lang(sr-RS),
h5:lang(sr-RS),
h6:lang(sr-RS), figcaption:lang(sr-RS),
.gallery-caption:lang(sr-RS), .editor-post-title__block .editor-post-title__input:lang(sr-RS), .editor-default-block-appender .editor-default-block-appender__content:lang(sr-RS), .wp-block-paragraph.has-drop-cap:lang(sr-RS):not(:focus)::first-letter, .wp-block-table:lang(sr-RS), .wp-block-cover h2:lang(sr-RS),
.wp-block-cover .wp-block-cover-text:lang(sr-RS), .wp-block-button .wp-block-button__link:lang(sr-RS), .wp-block-quote cite:lang(sr-RS),
.wp-block-quote footer:lang(sr-RS),
.wp-block-quote .wp-block-quote__citation:lang(sr-RS), .wp-block[data-type="core/pullquote"] .wp-block-pullquote__citation:lang(sr-RS),
.wp-block[data-type="core/pullquote"][data-align="left"] .wp-block-pullquote__citation:lang(sr-RS),
.wp-block[data-type="core/pullquote"][data-align="right"] .wp-block-pullquote__citation:lang(sr-RS), .wp-block-file:lang(sr-RS), ul.wp-block-archives li:lang(sr-RS),
.wp-block-categories li:lang(sr-RS),
.wp-block-latest-posts li:lang(sr-RS), .wp-block-latest-comments .wp-block-latest-comments__comment-meta:lang(sr-RS), .wp-caption dd:lang(sr-RS), .wp-block-freeform blockquote cite:lang(sr-RS) {
font-family: "Helvetica Neue", Helvetica, "Segoe UI", Arial, sans-serif;
}
body:lang(tt-RU), h1:lang(tt-RU),
h2:lang(tt-RU),
h3:lang(tt-RU),
h4:lang(tt-RU),
h5:lang(tt-RU),
h6:lang(tt-RU), figcaption:lang(tt-RU),
.gallery-caption:lang(tt-RU), .editor-post-title__block .editor-post-title__input:lang(tt-RU), .editor-default-block-appender .editor-default-block-appender__content:lang(tt-RU), .wp-block-paragraph.has-drop-cap:lang(tt-RU):not(:focus)::first-letter, .wp-block-table:lang(tt-RU), .wp-block-cover h2:lang(tt-RU),
.wp-block-cover .wp-block-cover-text:lang(tt-RU), .wp-block-button .wp-block-button__link:lang(tt-RU), .wp-block-quote cite:lang(tt-RU),
.wp-block-quote footer:lang(tt-RU),
.wp-block-quote .wp-block-quote__citation:lang(tt-RU), .wp-block[data-type="core/pullquote"] .wp-block-pullquote__citation:lang(tt-RU),
.wp-block[data-type="core/pullquote"][data-align="left"] .wp-block-pullquote__citation:lang(tt-RU),
.wp-block[data-type="core/pullquote"][data-align="right"] .wp-block-pullquote__citation:lang(tt-RU), .wp-block-file:lang(tt-RU), ul.wp-block-archives li:lang(tt-RU),
.wp-block-categories li:lang(tt-RU),
.wp-block-latest-posts li:lang(tt-RU), .wp-block-latest-comments .wp-block-latest-comments__comment-meta:lang(tt-RU), .wp-caption dd:lang(tt-RU), .wp-block-freeform blockquote cite:lang(tt-RU) {
font-family: "Helvetica Neue", Helvetica, "Segoe UI", Arial, sans-serif;
}
body:lang(uk), h1:lang(uk),
h2:lang(uk),
h3:lang(uk),
h4:lang(uk),
h5:lang(uk),
h6:lang(uk), figcaption:lang(uk),
.gallery-caption:lang(uk), .editor-post-title__block .editor-post-title__input:lang(uk), .editor-default-block-appender .editor-default-block-appender__content:lang(uk), .wp-block-paragraph.has-drop-cap:lang(uk):not(:focus)::first-letter, .wp-block-table:lang(uk), .wp-block-cover h2:lang(uk),
.wp-block-cover .wp-block-cover-text:lang(uk), .wp-block-button .wp-block-button__link:lang(uk), .wp-block-quote cite:lang(uk),
.wp-block-quote footer:lang(uk),
.wp-block-quote .wp-block-quote__citation:lang(uk), .wp-block[data-type="core/pullquote"] .wp-block-pullquote__citation:lang(uk),
.wp-block[data-type="core/pullquote"][data-align="left"] .wp-block-pullquote__citation:lang(uk),
.wp-block[data-type="core/pullquote"][data-align="right"] .wp-block-pullquote__citation:lang(uk), .wp-block-file:lang(uk), ul.wp-block-archives li:lang(uk),
.wp-block-categories li:lang(uk),
.wp-block-latest-posts li:lang(uk), .wp-block-latest-comments .wp-block-latest-comments__comment-meta:lang(uk), .wp-caption dd:lang(uk), .wp-block-freeform blockquote cite:lang(uk) {
font-family: "Helvetica Neue", Helvetica, "Segoe UI", Arial, sans-serif;
}
body:lang(zh-HK), h1:lang(zh-HK),
h2:lang(zh-HK),
h3:lang(zh-HK),
h4:lang(zh-HK),
h5:lang(zh-HK),
h6:lang(zh-HK), figcaption:lang(zh-HK),
.gallery-caption:lang(zh-HK), .editor-post-title__block .editor-post-title__input:lang(zh-HK), .editor-default-block-appender .editor-default-block-appender__content:lang(zh-HK), .wp-block-paragraph.has-drop-cap:lang(zh-HK):not(:focus)::first-letter, .wp-block-table:lang(zh-HK), .wp-block-cover h2:lang(zh-HK),
.wp-block-cover .wp-block-cover-text:lang(zh-HK), .wp-block-button .wp-block-button__link:lang(zh-HK), .wp-block-quote cite:lang(zh-HK),
.wp-block-quote footer:lang(zh-HK),
.wp-block-quote .wp-block-quote__citation:lang(zh-HK), .wp-block[data-type="core/pullquote"] .wp-block-pullquote__citation:lang(zh-HK),
.wp-block[data-type="core/pullquote"][data-align="left"] .wp-block-pullquote__citation:lang(zh-HK),
.wp-block[data-type="core/pullquote"][data-align="right"] .wp-block-pullquote__citation:lang(zh-HK), .wp-block-file:lang(zh-HK), ul.wp-block-archives li:lang(zh-HK),
.wp-block-categories li:lang(zh-HK),
.wp-block-latest-posts li:lang(zh-HK), .wp-block-latest-comments .wp-block-latest-comments__comment-meta:lang(zh-HK), .wp-caption dd:lang(zh-HK), .wp-block-freeform blockquote cite:lang(zh-HK) {
font-family: -apple-system, BlinkMacSystemFont, "PingFang HK", "Helvetica Neue", "Microsoft YaHei New", STHeiti Light, sans-serif;
}
body:lang(zh-TW), h1:lang(zh-TW),
h2:lang(zh-TW),
h3:lang(zh-TW),
h4:lang(zh-TW),
h5:lang(zh-TW),
h6:lang(zh-TW), figcaption:lang(zh-TW),
.gallery-caption:lang(zh-TW), .editor-post-title__block .editor-post-title__input:lang(zh-TW), .editor-default-block-appender .editor-default-block-appender__content:lang(zh-TW), .wp-block-paragraph.has-drop-cap:lang(zh-TW):not(:focus)::first-letter, .wp-block-table:lang(zh-TW), .wp-block-cover h2:lang(zh-TW),
.wp-block-cover .wp-block-cover-text:lang(zh-TW), .wp-block-button .wp-block-button__link:lang(zh-TW), .wp-block-quote cite:lang(zh-TW),
.wp-block-quote footer:lang(zh-TW),
.wp-block-quote .wp-block-quote__citation:lang(zh-TW), .wp-block[data-type="core/pullquote"] .wp-block-pullquote__citation:lang(zh-TW),
.wp-block[data-type="core/pullquote"][data-align="left"] .wp-block-pullquote__citation:lang(zh-TW),
.wp-block[data-type="core/pullquote"][data-align="right"] .wp-block-pullquote__citation:lang(zh-TW), .wp-block-file:lang(zh-TW), ul.wp-block-archives li:lang(zh-TW),
.wp-block-categories li:lang(zh-TW),
.wp-block-latest-posts li:lang(zh-TW), .wp-block-latest-comments .wp-block-latest-comments__comment-meta:lang(zh-TW), .wp-caption dd:lang(zh-TW), .wp-block-freeform blockquote cite:lang(zh-TW) {
font-family: -apple-system, BlinkMacSystemFont, "PingFang TC", "Helvetica Neue", "Microsoft YaHei New", STHeiti Light, sans-serif;
}
body:lang(zh-CN), h1:lang(zh-CN),
h2:lang(zh-CN),
h3:lang(zh-CN),
h4:lang(zh-CN),
h5:lang(zh-CN),
h6:lang(zh-CN), figcaption:lang(zh-CN),
.gallery-caption:lang(zh-CN), .editor-post-title__block .editor-post-title__input:lang(zh-CN), .editor-default-block-appender .editor-default-block-appender__content:lang(zh-CN), .wp-block-paragraph.has-drop-cap:lang(zh-CN):not(:focus)::first-letter, .wp-block-table:lang(zh-CN), .wp-block-cover h2:lang(zh-CN),
.wp-block-cover .wp-block-cover-text:lang(zh-CN), .wp-block-button .wp-block-button__link:lang(zh-CN), .wp-block-quote cite:lang(zh-CN),
.wp-block-quote footer:lang(zh-CN),
.wp-block-quote .wp-block-quote__citation:lang(zh-CN), .wp-block[data-type="core/pullquote"] .wp-block-pullquote__citation:lang(zh-CN),
.wp-block[data-type="core/pullquote"][data-align="left"] .wp-block-pullquote__citation:lang(zh-CN),
.wp-block[data-type="core/pullquote"][data-align="right"] .wp-block-pullquote__citation:lang(zh-CN), .wp-block-file:lang(zh-CN), ul.wp-block-archives li:lang(zh-CN),
.wp-block-categories li:lang(zh-CN),
.wp-block-latest-posts li:lang(zh-CN), .wp-block-latest-comments .wp-block-latest-comments__comment-meta:lang(zh-CN), .wp-caption dd:lang(zh-CN), .wp-block-freeform blockquote cite:lang(zh-CN) {
font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Helvetica Neue", "Microsoft YaHei New", STHeiti Light, sans-serif;
}
body:lang(bn-BD), h1:lang(bn-BD),
h2:lang(bn-BD),
h3:lang(bn-BD),
h4:lang(bn-BD),
h5:lang(bn-BD),
h6:lang(bn-BD), figcaption:lang(bn-BD),
.gallery-caption:lang(bn-BD), .editor-post-title__block .editor-post-title__input:lang(bn-BD), .editor-default-block-appender .editor-default-block-appender__content:lang(bn-BD), .wp-block-paragraph.has-drop-cap:lang(bn-BD):not(:focus)::first-letter, .wp-block-table:lang(bn-BD), .wp-block-cover h2:lang(bn-BD),
.wp-block-cover .wp-block-cover-text:lang(bn-BD), .wp-block-button .wp-block-button__link:lang(bn-BD), .wp-block-quote cite:lang(bn-BD),
.wp-block-quote footer:lang(bn-BD),
.wp-block-quote .wp-block-quote__citation:lang(bn-BD), .wp-block[data-type="core/pullquote"] .wp-block-pullquote__citation:lang(bn-BD),
.wp-block[data-type="core/pullquote"][data-align="left"] .wp-block-pullquote__citation:lang(bn-BD),
.wp-block[data-type="core/pullquote"][data-align="right"] .wp-block-pullquote__citation:lang(bn-BD), .wp-block-file:lang(bn-BD), ul.wp-block-archives li:lang(bn-BD),
.wp-block-categories li:lang(bn-BD),
.wp-block-latest-posts li:lang(bn-BD), .wp-block-latest-comments .wp-block-latest-comments__comment-meta:lang(bn-BD), .wp-caption dd:lang(bn-BD), .wp-block-freeform blockquote cite:lang(bn-BD) {
font-family: Arial, sans-serif;
}
body:lang(hi-IN), h1:lang(hi-IN),
h2:lang(hi-IN),
h3:lang(hi-IN),
h4:lang(hi-IN),
h5:lang(hi-IN),
h6:lang(hi-IN), figcaption:lang(hi-IN),
.gallery-caption:lang(hi-IN), .editor-post-title__block .editor-post-title__input:lang(hi-IN), .editor-default-block-appender .editor-default-block-appender__content:lang(hi-IN), .wp-block-paragraph.has-drop-cap:lang(hi-IN):not(:focus)::first-letter, .wp-block-table:lang(hi-IN), .wp-block-cover h2:lang(hi-IN),
.wp-block-cover .wp-block-cover-text:lang(hi-IN), .wp-block-button .wp-block-button__link:lang(hi-IN), .wp-block-quote cite:lang(hi-IN),
.wp-block-quote footer:lang(hi-IN),
.wp-block-quote .wp-block-quote__citation:lang(hi-IN), .wp-block[data-type="core/pullquote"] .wp-block-pullquote__citation:lang(hi-IN),
.wp-block[data-type="core/pullquote"][data-align="left"] .wp-block-pullquote__citation:lang(hi-IN),
.wp-block[data-type="core/pullquote"][data-align="right"] .wp-block-pullquote__citation:lang(hi-IN), .wp-block-file:lang(hi-IN), ul.wp-block-archives li:lang(hi-IN),
.wp-block-categories li:lang(hi-IN),
.wp-block-latest-posts li:lang(hi-IN), .wp-block-latest-comments .wp-block-latest-comments__comment-meta:lang(hi-IN), .wp-caption dd:lang(hi-IN), .wp-block-freeform blockquote cite:lang(hi-IN) {
font-family: Arial, sans-serif;
}
body:lang(mr), h1:lang(mr),
h2:lang(mr),
h3:lang(mr),
h4:lang(mr),
h5:lang(mr),
h6:lang(mr), figcaption:lang(mr),
.gallery-caption:lang(mr), .editor-post-title__block .editor-post-title__input:lang(mr), .editor-default-block-appender .editor-default-block-appender__content:lang(mr), .wp-block-paragraph.has-drop-cap:lang(mr):not(:focus)::first-letter, .wp-block-table:lang(mr), .wp-block-cover h2:lang(mr),
.wp-block-cover .wp-block-cover-text:lang(mr), .wp-block-button .wp-block-button__link:lang(mr), .wp-block-quote cite:lang(mr),
.wp-block-quote footer:lang(mr),
.wp-block-quote .wp-block-quote__citation:lang(mr), .wp-block[data-type="core/pullquote"] .wp-block-pullquote__citation:lang(mr),
.wp-block[data-type="core/pullquote"][data-align="left"] .wp-block-pullquote__citation:lang(mr),
.wp-block[data-type="core/pullquote"][data-align="right"] .wp-block-pullquote__citation:lang(mr), .wp-block-file:lang(mr), ul.wp-block-archives li:lang(mr),
.wp-block-categories li:lang(mr),
.wp-block-latest-posts li:lang(mr), .wp-block-latest-comments .wp-block-latest-comments__comment-meta:lang(mr), .wp-caption dd:lang(mr), .wp-block-freeform blockquote cite:lang(mr) {
font-family: Arial, sans-serif;
}
body:lang(ne-NP), h1:lang(ne-NP),
h2:lang(ne-NP),
h3:lang(ne-NP),
h4:lang(ne-NP),
h5:lang(ne-NP),
h6:lang(ne-NP), figcaption:lang(ne-NP),
.gallery-caption:lang(ne-NP), .editor-post-title__block .editor-post-title__input:lang(ne-NP), .editor-default-block-appender .editor-default-block-appender__content:lang(ne-NP), .wp-block-paragraph.has-drop-cap:lang(ne-NP):not(:focus)::first-letter, .wp-block-table:lang(ne-NP), .wp-block-cover h2:lang(ne-NP),
.wp-block-cover .wp-block-cover-text:lang(ne-NP), .wp-block-button .wp-block-button__link:lang(ne-NP), .wp-block-quote cite:lang(ne-NP),
.wp-block-quote footer:lang(ne-NP),
.wp-block-quote .wp-block-quote__citation:lang(ne-NP), .wp-block[data-type="core/pullquote"] .wp-block-pullquote__citation:lang(ne-NP),
.wp-block[data-type="core/pullquote"][data-align="left"] .wp-block-pullquote__citation:lang(ne-NP),
.wp-block[data-type="core/pullquote"][data-align="right"] .wp-block-pullquote__citation:lang(ne-NP), .wp-block-file:lang(ne-NP), ul.wp-block-archives li:lang(ne-NP),
.wp-block-categories li:lang(ne-NP),
.wp-block-latest-posts li:lang(ne-NP), .wp-block-latest-comments .wp-block-latest-comments__comment-meta:lang(ne-NP), .wp-caption dd:lang(ne-NP), .wp-block-freeform blockquote cite:lang(ne-NP) {
font-family: Arial, sans-serif;
}
body:lang(el), h1:lang(el),
h2:lang(el),
h3:lang(el),
h4:lang(el),
h5:lang(el),
h6:lang(el), figcaption:lang(el),
.gallery-caption:lang(el), .editor-post-title__block .editor-post-title__input:lang(el), .editor-default-block-appender .editor-default-block-appender__content:lang(el), .wp-block-paragraph.has-drop-cap:lang(el):not(:focus)::first-letter, .wp-block-table:lang(el), .wp-block-cover h2:lang(el),
.wp-block-cover .wp-block-cover-text:lang(el), .wp-block-button .wp-block-button__link:lang(el), .wp-block-quote cite:lang(el),
.wp-block-quote footer:lang(el),
.wp-block-quote .wp-block-quote__citation:lang(el), .wp-block[data-type="core/pullquote"] .wp-block-pullquote__citation:lang(el),
.wp-block[data-type="core/pullquote"][data-align="left"] .wp-block-pullquote__citation:lang(el),
.wp-block[data-type="core/pullquote"][data-align="right"] .wp-block-pullquote__citation:lang(el), .wp-block-file:lang(el), ul.wp-block-archives li:lang(el),
.wp-block-categories li:lang(el),
.wp-block-latest-posts li:lang(el), .wp-block-latest-comments .wp-block-latest-comments__comment-meta:lang(el), .wp-caption dd:lang(el), .wp-block-freeform blockquote cite:lang(el) {
font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
}
body:lang(gu), h1:lang(gu),
h2:lang(gu),
h3:lang(gu),
h4:lang(gu),
h5:lang(gu),
h6:lang(gu), figcaption:lang(gu),
.gallery-caption:lang(gu), .editor-post-title__block .editor-post-title__input:lang(gu), .editor-default-block-appender .editor-default-block-appender__content:lang(gu), .wp-block-paragraph.has-drop-cap:lang(gu):not(:focus)::first-letter, .wp-block-table:lang(gu), .wp-block-cover h2:lang(gu),
.wp-block-cover .wp-block-cover-text:lang(gu), .wp-block-button .wp-block-button__link:lang(gu), .wp-block-quote cite:lang(gu),
.wp-block-quote footer:lang(gu),
.wp-block-quote .wp-block-quote__citation:lang(gu), .wp-block[data-type="core/pullquote"] .wp-block-pullquote__citation:lang(gu),
.wp-block[data-type="core/pullquote"][data-align="left"] .wp-block-pullquote__citation:lang(gu),
.wp-block[data-type="core/pullquote"][data-align="right"] .wp-block-pullquote__citation:lang(gu), .wp-block-file:lang(gu), ul.wp-block-archives li:lang(gu),
.wp-block-categories li:lang(gu),
.wp-block-latest-posts li:lang(gu), .wp-block-latest-comments .wp-block-latest-comments__comment-meta:lang(gu), .wp-caption dd:lang(gu), .wp-block-freeform blockquote cite:lang(gu) {
font-family: Arial, sans-serif;
}
body:lang(he-IL), h1:lang(he-IL),
h2:lang(he-IL),
h3:lang(he-IL),
h4:lang(he-IL),
h5:lang(he-IL),
h6:lang(he-IL), figcaption:lang(he-IL),
.gallery-caption:lang(he-IL), .editor-post-title__block .editor-post-title__input:lang(he-IL), .editor-default-block-appender .editor-default-block-appender__content:lang(he-IL), .wp-block-paragraph.has-drop-cap:lang(he-IL):not(:focus)::first-letter, .wp-block-table:lang(he-IL), .wp-block-cover h2:lang(he-IL),
.wp-block-cover .wp-block-cover-text:lang(he-IL), .wp-block-button .wp-block-button__link:lang(he-IL), .wp-block-quote cite:lang(he-IL),
.wp-block-quote footer:lang(he-IL),
.wp-block-quote .wp-block-quote__citation:lang(he-IL), .wp-block[data-type="core/pullquote"] .wp-block-pullquote__citation:lang(he-IL),
.wp-block[data-type="core/pullquote"][data-align="left"] .wp-block-pullquote__citation:lang(he-IL),
.wp-block[data-type="core/pullquote"][data-align="right"] .wp-block-pullquote__citation:lang(he-IL), .wp-block-file:lang(he-IL), ul.wp-block-archives li:lang(he-IL),
.wp-block-categories li:lang(he-IL),
.wp-block-latest-posts li:lang(he-IL), .wp-block-latest-comments .wp-block-latest-comments__comment-meta:lang(he-IL), .wp-caption dd:lang(he-IL), .wp-block-freeform blockquote cite:lang(he-IL) {
font-family: "Arial Hebrew", Arial, sans-serif;
}
body:lang(ja), h1:lang(ja),
h2:lang(ja),
h3:lang(ja),
h4:lang(ja),
h5:lang(ja),
h6:lang(ja), figcaption:lang(ja),
.gallery-caption:lang(ja), .editor-post-title__block .editor-post-title__input:lang(ja), .editor-default-block-appender .editor-default-block-appender__content:lang(ja), .wp-block-paragraph.has-drop-cap:lang(ja):not(:focus)::first-letter, .wp-block-table:lang(ja), .wp-block-cover h2:lang(ja),
.wp-block-cover .wp-block-cover-text:lang(ja), .wp-block-button .wp-block-button__link:lang(ja), .wp-block-quote cite:lang(ja),
.wp-block-quote footer:lang(ja),
.wp-block-quote .wp-block-quote__citation:lang(ja), .wp-block[data-type="core/pullquote"] .wp-block-pullquote__citation:lang(ja),
.wp-block[data-type="core/pullquote"][data-align="left"] .wp-block-pullquote__citation:lang(ja),
.wp-block[data-type="core/pullquote"][data-align="right"] .wp-block-pullquote__citation:lang(ja), .wp-block-file:lang(ja), ul.wp-block-archives li:lang(ja),
.wp-block-categories li:lang(ja),
.wp-block-latest-posts li:lang(ja), .wp-block-latest-comments .wp-block-latest-comments__comment-meta:lang(ja), .wp-caption dd:lang(ja), .wp-block-freeform blockquote cite:lang(ja) {
font-family: -apple-system, BlinkMacSystemFont, "Hiragino Sans", Meiryo, "Helvetica Neue", sans-serif;
}
body:lang(ko-KR), h1:lang(ko-KR),
h2:lang(ko-KR),
h3:lang(ko-KR),
h4:lang(ko-KR),
h5:lang(ko-KR),
h6:lang(ko-KR), figcaption:lang(ko-KR),
.gallery-caption:lang(ko-KR), .editor-post-title__block .editor-post-title__input:lang(ko-KR), .editor-default-block-appender .editor-default-block-appender__content:lang(ko-KR), .wp-block-paragraph.has-drop-cap:lang(ko-KR):not(:focus)::first-letter, .wp-block-table:lang(ko-KR), .wp-block-cover h2:lang(ko-KR),
.wp-block-cover .wp-block-cover-text:lang(ko-KR), .wp-block-button .wp-block-button__link:lang(ko-KR), .wp-block-quote cite:lang(ko-KR),
.wp-block-quote footer:lang(ko-KR),
.wp-block-quote .wp-block-quote__citation:lang(ko-KR), .wp-block[data-type="core/pullquote"] .wp-block-pullquote__citation:lang(ko-KR),
.wp-block[data-type="core/pullquote"][data-align="left"] .wp-block-pullquote__citation:lang(ko-KR),
.wp-block[data-type="core/pullquote"][data-align="right"] .wp-block-pullquote__citation:lang(ko-KR), .wp-block-file:lang(ko-KR), ul.wp-block-archives li:lang(ko-KR),
.wp-block-categories li:lang(ko-KR),
.wp-block-latest-posts li:lang(ko-KR), .wp-block-latest-comments .wp-block-latest-comments__comment-meta:lang(ko-KR), .wp-caption dd:lang(ko-KR), .wp-block-freeform blockquote cite:lang(ko-KR) {
font-family: "Apple SD Gothic Neo", "Malgun Gothic", "Nanum Gothic", Dotum, sans-serif;
}
body:lang(th), h1:lang(th),
h2:lang(th),
h3:lang(th),
h4:lang(th),
h5:lang(th),
h6:lang(th), figcaption:lang(th),
.gallery-caption:lang(th), .editor-post-title__block .editor-post-title__input:lang(th), .editor-default-block-appender .editor-default-block-appender__content:lang(th), .wp-block-paragraph.has-drop-cap:lang(th):not(:focus)::first-letter, .wp-block-table:lang(th), .wp-block-cover h2:lang(th),
.wp-block-cover .wp-block-cover-text:lang(th), .wp-block-button .wp-block-button__link:lang(th), .wp-block-quote cite:lang(th),
.wp-block-quote footer:lang(th),
.wp-block-quote .wp-block-quote__citation:lang(th), .wp-block[data-type="core/pullquote"] .wp-block-pullquote__citation:lang(th),
.wp-block[data-type="core/pullquote"][data-align="left"] .wp-block-pullquote__citation:lang(th),
.wp-block[data-type="core/pullquote"][data-align="right"] .wp-block-pullquote__citation:lang(th), .wp-block-file:lang(th), ul.wp-block-archives li:lang(th),
.wp-block-categories li:lang(th),
.wp-block-latest-posts li:lang(th), .wp-block-latest-comments .wp-block-latest-comments__comment-meta:lang(th), .wp-caption dd:lang(th), .wp-block-freeform blockquote cite:lang(th) {
font-family: "Sukhumvit Set", "Helvetica Neue", helvetica, arial, sans-serif;
}
body:lang(vi), h1:lang(vi),
h2:lang(vi),
h3:lang(vi),
h4:lang(vi),
h5:lang(vi),
h6:lang(vi), figcaption:lang(vi),
.gallery-caption:lang(vi), .editor-post-title__block .editor-post-title__input:lang(vi), .editor-default-block-appender .editor-default-block-appender__content:lang(vi), .wp-block-paragraph.has-drop-cap:lang(vi):not(:focus)::first-letter, .wp-block-table:lang(vi), .wp-block-cover h2:lang(vi),
.wp-block-cover .wp-block-cover-text:lang(vi), .wp-block-button .wp-block-button__link:lang(vi), .wp-block-quote cite:lang(vi),
.wp-block-quote footer:lang(vi),
.wp-block-quote .wp-block-quote__citation:lang(vi), .wp-block[data-type="core/pullquote"] .wp-block-pullquote__citation:lang(vi),
.wp-block[data-type="core/pullquote"][data-align="left"] .wp-block-pullquote__citation:lang(vi),
.wp-block[data-type="core/pullquote"][data-align="right"] .wp-block-pullquote__citation:lang(vi), .wp-block-file:lang(vi), ul.wp-block-archives li:lang(vi),
.wp-block-categories li:lang(vi),
.wp-block-latest-posts li:lang(vi), .wp-block-latest-comments .wp-block-latest-comments__comment-meta:lang(vi), .wp-caption dd:lang(vi), .wp-block-freeform blockquote cite:lang(vi) {
font-family: "Libre Franklin", sans-serif;
}
/** === Editor Frame === */ /** === Editor Frame === */
body .wp-block[data-align="full"] { body .wp-block[data-align="full"] {
width: 100%; width: 100%;
@ -412,7 +940,8 @@ figcaption,
/** === Blockquote === */ /** === Blockquote === */
.wp-block-quote:not(.is-large):not(.is-style-large) { .wp-block-quote:not(.is-large):not(.is-style-large) {
border-left: 2px solid #0073aa; border-width: 2px;
border-color: #0073aa;
} }
.wp-block-quote.is-large, .wp-block-quote.is-style-large { .wp-block-quote.is-large, .wp-block-quote.is-style-large {
@ -764,8 +1293,3 @@ ul.wp-block-archives li ul,
line-height: 1.6; line-height: 1.6;
color: #767676; color: #767676;
} }
/* Make sure our non-latin font overrides don't overwrite the iconfont used in the classic editor toolbar */
.wp-block[data-type="core/freeform"] .mce-btn i {
font-family: dashicons !important;
}

View file

@ -78,7 +78,7 @@ body {
body { body {
font-size: $font__size_base; font-size: $font__size_base;
font-family: $font__body; @include font-family( $font__body );
line-height: $font__line-height-body; line-height: $font__line-height-body;
color: $color__text-main; color: $color__text-main;
} }
@ -93,7 +93,7 @@ h3,
h4, h4,
h5, h5,
h6 { h6 {
font-family: $font__heading; @include font-family( $font__heading );
font-weight: 700; font-weight: 700;
} }
@ -189,7 +189,7 @@ a {
figcaption, figcaption,
.gallery-caption { .gallery-caption {
font-family: $font__heading; @include font-family( $font__heading );
font-size: $font__size-xs; font-size: $font__size-xs;
line-height: 1.6; line-height: 1.6;
color: $color__text-light; color: $color__text-light;
@ -210,7 +210,7 @@ figcaption,
} }
.editor-post-title__input { .editor-post-title__input {
font-family: $font__heading; @include font-family( $font__heading );
font-size: $font__size-xxl; font-size: $font__size-xxl;
font-weight: 700; font-weight: 700;
} }
@ -219,7 +219,7 @@ figcaption,
/** === Default Appender === */ /** === Default Appender === */
.editor-default-block-appender .editor-default-block-appender__content { .editor-default-block-appender .editor-default-block-appender__content {
font-family: $font__body; @include font-family( $font__body );
font-size: $font__size_base; font-size: $font__size_base;
} }
@ -235,7 +235,7 @@ figcaption,
.wp-block-paragraph { .wp-block-paragraph {
&.has-drop-cap:not(:focus)::first-letter { &.has-drop-cap:not(:focus)::first-letter {
font-family: $font__heading; @include font-family( $font__heading );
font-size: $font__size-xxxl; font-size: $font__size-xxxl;
line-height: 1; line-height: 1;
font-weight: bold; font-weight: bold;
@ -246,7 +246,7 @@ figcaption,
/** === Table === */ /** === Table === */
.wp-block-table { .wp-block-table {
font-family: $font__heading; @include font-family( $font__heading );
} }
/** === Cover === */ /** === Cover === */
@ -255,7 +255,7 @@ figcaption,
h2, h2,
.wp-block-cover-text { .wp-block-cover-text {
font-family: $font__heading; @include font-family( $font__heading );
font-size: $font__size-lg; font-size: $font__size-lg;
font-weight: bold; font-weight: bold;
line-height: 1.4; line-height: 1.4;
@ -356,7 +356,7 @@ figcaption,
.wp-block-button__link { .wp-block-button__link {
line-height: 1.8; line-height: 1.8;
font-family: $font__heading; @include font-family( $font__heading );
font-size: $font__size-sm; font-size: $font__size-sm;
font-weight: bold; font-weight: bold;
} }
@ -391,7 +391,8 @@ figcaption,
.wp-block-quote { .wp-block-quote {
&:not(.is-large):not(.is-style-large) { &:not(.is-large):not(.is-style-large) {
border-left: 2px solid $color__link; border-width: 2px;
border-color: $color__link;
} }
&.is-large, &.is-large,
@ -411,7 +412,7 @@ figcaption,
cite, cite,
footer, footer,
.wp-block-quote__citation { .wp-block-quote__citation {
font-family: $font__heading; @include font-family( $font__heading );
font-size: $font__size-xs; font-size: $font__size-xs;
line-height: 1.6; line-height: 1.6;
color: $color__text-light; color: $color__text-light;
@ -482,7 +483,7 @@ figcaption,
} }
.wp-block-pullquote__citation { .wp-block-pullquote__citation {
font-family: $font__heading; @include font-family( $font__heading );
font-size: $font__size-xs; font-size: $font__size-xs;
line-height: 1.6; line-height: 1.6;
text-transform: none; text-transform: none;
@ -531,7 +532,7 @@ figcaption,
/** === File === */ /** === File === */
.wp-block-file { .wp-block-file {
font-family: $font__heading; @include font-family( $font__heading );
.wp-block-file__textlink { .wp-block-file__textlink {
text-decoration: underline; text-decoration: underline;
@ -625,7 +626,7 @@ ul.wp-block-archives,
li { li {
color: $color__text-light; color: $color__text-light;
font-family: $font__heading; @include font-family( $font__heading );
font-size: calc(#{$font__size_base} * #{$font__size-ratio}); font-size: calc(#{$font__size_base} * #{$font__size-ratio});
font-weight: bold; font-weight: bold;
line-height: $font__line-height-heading; line-height: $font__line-height-heading;
@ -686,7 +687,7 @@ ul.wp-block-archives,
.wp-block-latest-comments { .wp-block-latest-comments {
.wp-block-latest-comments__comment-meta { .wp-block-latest-comments__comment-meta {
font-family: $font__heading; @include font-family( $font__heading );
font-weight: bold; font-weight: bold;
.wp-block-latest-comments__comment-date { .wp-block-latest-comments__comment-date {
@ -712,7 +713,7 @@ ul.wp-block-archives,
dd { dd {
color: $color__text-light; color: $color__text-light;
font-size: $font__size-xs; font-size: $font__size-xs;
font-family: $font__heading; @include font-family( $font__heading );
line-height: $font__line-height-pre; line-height: $font__line-height-pre;
margin: 0; margin: 0;
padding: ( $size__spacing-unit * .5 ); padding: ( $size__spacing-unit * .5 );
@ -730,7 +731,7 @@ ul.wp-block-archives,
border-left: 2px solid $color__link; border-left: 2px solid $color__link;
cite { cite {
font-family: $font__heading; @include font-family( $font__heading );
font-size: $font__size-xs; font-size: $font__size-xs;
font-style: normal; font-style: normal;
line-height: 1.6; line-height: 1.6;
@ -738,8 +739,3 @@ ul.wp-block-archives,
} }
} }
} }
/* Make sure our non-latin font overrides don't overwrite the iconfont used in the classic editor toolbar */
.wp-block[data-type="core/freeform"] .mce-btn i {
font-family: dashicons !important;
}

File diff suppressed because it is too large Load diff

File diff suppressed because it is too large Load diff

File diff suppressed because one or more lines are too long

View file

@ -1,11 +1,11 @@
/* /*
Theme Name: Twenty Nineteen Theme Name: Twenty Nineteen
Theme URI: https://github.com/WordPress/twentynineteen Theme URI: https://wordpress.org/themes/twentynineteen/
Author: the WordPress team Author: the WordPress team
Author URI: https://wordpress.org/ Author URI: https://wordpress.org/
Description: Our 2019 default theme is designed to show off the power of the block editor. It features custom styles for all the default blocks, and is built so that what you see in the editor looks like what you'll see on your website. Twenty Nineteen is designed to be adaptable to a wide range of websites, whether youre running a photo blog, launching a new business, or supporting a non-profit. Featuring ample whitespace and modern sans-serif headlines paired with classic serif body text, it's built to be beautiful on all screen sizes. Description: Our 2019 default theme is designed to show off the power of the block editor. It features custom styles for all the default blocks, and is built so that what you see in the editor looks like what you'll see on your website. Twenty Nineteen is designed to be adaptable to a wide range of websites, whether youre running a photo blog, launching a new business, or supporting a non-profit. Featuring ample whitespace and modern sans-serif headlines paired with classic serif body text, it's built to be beautiful on all screen sizes.
Requires at least: WordPress 4.9.6 Requires at least: WordPress 4.9.6
Version: 1.2 Version: 1.4
License: GNU General Public License v2 or later License: GNU General Public License v2 or later
License URI: LICENSE License URI: LICENSE
Text Domain: twentynineteen Text Domain: twentynineteen

View file

@ -30,4 +30,4 @@
<footer class="entry-footer"> <footer class="entry-footer">
<?php twentynineteen_entry_footer(); ?> <?php twentynineteen_entry_footer(); ?>
</footer><!-- .entry-footer --> </footer><!-- .entry-footer -->
</article><!-- #post-${ID} --> </article><!-- #post-<?php the_ID(); ?> -->

View file

@ -52,4 +52,4 @@
<?php get_template_part( 'template-parts/post/author', 'bio' ); ?> <?php get_template_part( 'template-parts/post/author', 'bio' ); ?>
<?php endif; ?> <?php endif; ?>
</article><!-- #post-${ID} --> </article><!-- #post-<?php the_ID(); ?> -->

View file

@ -56,4 +56,4 @@
<footer class="entry-footer"> <footer class="entry-footer">
<?php twentynineteen_entry_footer(); ?> <?php twentynineteen_entry_footer(); ?>
</footer><!-- .entry-footer --> </footer><!-- .entry-footer -->
</article><!-- #post-${ID} --> </article><!-- #post-<?php the_ID(); ?> -->

View file

@ -42,5 +42,5 @@ $discussion = ! is_page() && twentynineteen_can_show_post_thumbnail() ? twentyni
'</span>' '</span>'
); );
?> ?>
</div><!-- .meta-info --> </div><!-- .entry-meta -->
<?php endif; ?> <?php endif; ?>

View file

@ -31,4 +31,5 @@ get_header(); ?>
</div><!-- #primary --> </div><!-- #primary -->
</div><!-- .wrap --> </div><!-- .wrap -->
<?php get_footer(); <?php
get_footer();

View file

@ -1,8 +1,9 @@
=== Twenty Seventeen === === Twenty Seventeen ===
Contributors: the WordPress team Contributors: wordpressdotorg
Requires at least: WordPress 4.7 Requires at least: WordPress 4.7
Tested up to: WordPress 5.0 Tested up to: WordPress 5.0
Version: 2.0 Requires PHP: 5.2.4
Version: 2.2
License: GPLv2 or later License: GPLv2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html License URI: http://www.gnu.org/licenses/gpl-2.0.html
Tags: one-column, two-columns, right-sidebar, flexible-header, accessibility-ready, custom-colors, custom-header, custom-menu, custom-logo, editor-style, featured-images, footer-widgets, post-formats, rtl-language-support, sticky-post, theme-options, threaded-comments, translation-ready Tags: one-column, two-columns, right-sidebar, flexible-header, accessibility-ready, custom-colors, custom-header, custom-menu, custom-logo, editor-style, featured-images, footer-widgets, post-formats, rtl-language-support, sticky-post, theme-options, threaded-comments, translation-ready
@ -60,6 +61,16 @@ Source: https://unsplash.com/@englr?photo=bIhpiQA009k
== Changelog == == Changelog ==
= 2.2 =
* Released: May 7, 2019
https://codex.wordpress.org/Twenty_Seventeen_Theme_Changelog#Version_2.2
= 2.1 =
* Released: February 21, 2019
https://codex.wordpress.org/Twenty_Seventeen_Theme_Changelog#Version_2.1
= 2.0 = = 2.0 =
* Released: January 9, 2019 * Released: January 9, 2019

View file

@ -2,7 +2,7 @@
/** /**
* The template for displaying archive pages * The template for displaying archive pages
* *
* @link https://codex.wordpress.org/Template_Hierarchy * @link https://developer.wordpress.org/themes/basics/template-hierarchy/
* *
* @package WordPress * @package WordPress
* @subpackage Twenty_Seventeen * @subpackage Twenty_Seventeen
@ -27,10 +27,12 @@ get_header(); ?>
<main id="main" class="site-main" role="main"> <main id="main" class="site-main" role="main">
<?php <?php
if ( have_posts() ) : ?> if ( have_posts() ) :
?>
<?php <?php
/* Start the Loop */ /* Start the Loop */
while ( have_posts() ) : the_post(); while ( have_posts() ) :
the_post();
/* /*
* Include the Post-Format-specific template for the content. * Include the Post-Format-specific template for the content.
@ -41,21 +43,25 @@ get_header(); ?>
endwhile; endwhile;
the_posts_pagination( array( the_posts_pagination(
array(
'prev_text' => twentyseventeen_get_svg( array( 'icon' => 'arrow-left' ) ) . '<span class="screen-reader-text">' . __( 'Previous page', 'twentyseventeen' ) . '</span>', 'prev_text' => twentyseventeen_get_svg( array( 'icon' => 'arrow-left' ) ) . '<span class="screen-reader-text">' . __( 'Previous page', 'twentyseventeen' ) . '</span>',
'next_text' => '<span class="screen-reader-text">' . __( 'Next page', 'twentyseventeen' ) . '</span>' . twentyseventeen_get_svg( array( 'icon' => 'arrow-right' ) ), 'next_text' => '<span class="screen-reader-text">' . __( 'Next page', 'twentyseventeen' ) . '</span>' . twentyseventeen_get_svg( array( 'icon' => 'arrow-right' ) ),
'before_page_number' => '<span class="meta-nav screen-reader-text">' . __( 'Page', 'twentyseventeen' ) . ' </span>', 'before_page_number' => '<span class="meta-nav screen-reader-text">' . __( 'Page', 'twentyseventeen' ) . ' </span>',
) ); )
);
else : else :
get_template_part( 'template-parts/post/content', 'none' ); get_template_part( 'template-parts/post/content', 'none' );
endif; ?> endif;
?>
</main><!-- #main --> </main><!-- #main -->
</div><!-- #primary --> </div><!-- #primary -->
<?php get_sidebar(); ?> <?php get_sidebar(); ?>
</div><!-- .wrap --> </div><!-- .wrap -->
<?php get_footer(); <?php
get_footer();

View file

@ -289,7 +289,7 @@ body.colors-dark,
color: #bbb; color: #bbb;
} }
.colors-dark button:hover, .colors-dark button:hover:not( .mejs-container > button ),
.colors-dark button:focus, .colors-dark button:focus,
.colors-dark input[type="button"]:hover, .colors-dark input[type="button"]:hover,
.colors-dark input[type="button"]:focus, .colors-dark input[type="button"]:focus,

View file

@ -674,6 +674,7 @@ table.wp-block-table tr {
border-bottom: 1px solid #eee; border-bottom: 1px solid #eee;
} }
table.wp-block-table th,
table.wp-block-table td { table.wp-block-table td {
border: 0; border: 0;
padding: 0.4em; padding: 0.4em;

View file

@ -208,6 +208,7 @@
adjustHeaderHeight(); adjustHeaderHeight();
setQuotesIcon(); setQuotesIcon();
belowEntryMetaClass( 'blockquote.alignleft, blockquote.alignright' );
if ( true === supportsInlineSVG() ) { if ( true === supportsInlineSVG() ) {
document.documentElement.className = document.documentElement.className.replace( /(\s*)no-svg(\s*)/, '$1svg$2' ); document.documentElement.className = document.documentElement.className.replace( /(\s*)no-svg(\s*)/, '$1svg$2' );
} }

View file

@ -5,7 +5,7 @@
* This is the template that displays the area of the page that contains both the current comments * This is the template that displays the area of the page that contains both the current comments
* and the comment form. * and the comment form.
* *
* @link https://codex.wordpress.org/Template_Hierarchy * @link https://developer.wordpress.org/themes/basics/template-hierarchy/
* *
* @package WordPress * @package WordPress
* @subpackage Twenty_Seventeen * @subpackage Twenty_Seventeen
@ -27,7 +27,8 @@ if ( post_password_required() ) {
<?php <?php
// You can start editing here -- including this comment! // You can start editing here -- including this comment!
if ( have_comments() ) : ?> if ( have_comments() ) :
?>
<h2 class="comments-title"> <h2 class="comments-title">
<?php <?php
$comments_number = get_comments_number(); $comments_number = get_comments_number();
@ -53,24 +54,30 @@ if ( post_password_required() ) {
<ol class="comment-list"> <ol class="comment-list">
<?php <?php
wp_list_comments( array( wp_list_comments(
array(
'avatar_size' => 100, 'avatar_size' => 100,
'style' => 'ol', 'style' => 'ol',
'short_ping' => true, 'short_ping' => true,
'reply_text' => twentyseventeen_get_svg( array( 'icon' => 'mail-reply' ) ) . __( 'Reply', 'twentyseventeen' ), 'reply_text' => twentyseventeen_get_svg( array( 'icon' => 'mail-reply' ) ) . __( 'Reply', 'twentyseventeen' ),
) ); )
);
?> ?>
</ol> </ol>
<?php the_comments_pagination( array( <?php
the_comments_pagination(
array(
'prev_text' => twentyseventeen_get_svg( array( 'icon' => 'arrow-left' ) ) . '<span class="screen-reader-text">' . __( 'Previous', 'twentyseventeen' ) . '</span>', 'prev_text' => twentyseventeen_get_svg( array( 'icon' => 'arrow-left' ) ) . '<span class="screen-reader-text">' . __( 'Previous', 'twentyseventeen' ) . '</span>',
'next_text' => '<span class="screen-reader-text">' . __( 'Next', 'twentyseventeen' ) . '</span>' . twentyseventeen_get_svg( array( 'icon' => 'arrow-right' ) ), 'next_text' => '<span class="screen-reader-text">' . __( 'Next', 'twentyseventeen' ) . '</span>' . twentyseventeen_get_svg( array( 'icon' => 'arrow-right' ) ),
) ); )
);
endif; // Check for have_comments(). endif; // Check for have_comments().
// If comments are closed and there are comments, let's leave a little note, shall we? // If comments are closed and there are comments, let's leave a little note, shall we?
if ( ! comments_open() && get_comments_number() && post_type_supports( get_post_type(), 'comments' ) ) : ?> if ( ! comments_open() && get_comments_number() && post_type_supports( get_post_type(), 'comments' ) ) :
?>
<p class="no-comments"><?php _e( 'Comments are closed.', 'twentyseventeen' ); ?></p> <p class="no-comments"><?php _e( 'Comments are closed.', 'twentyseventeen' ); ?></p>
<?php <?php

View file

@ -21,19 +21,23 @@
<?php <?php
get_template_part( 'template-parts/footer/footer', 'widgets' ); get_template_part( 'template-parts/footer/footer', 'widgets' );
if ( has_nav_menu( 'social' ) ) : ?> if ( has_nav_menu( 'social' ) ) :
?>
<nav class="social-navigation" role="navigation" aria-label="<?php esc_attr_e( 'Footer Social Links Menu', 'twentyseventeen' ); ?>"> <nav class="social-navigation" role="navigation" aria-label="<?php esc_attr_e( 'Footer Social Links Menu', 'twentyseventeen' ); ?>">
<?php <?php
wp_nav_menu( array( wp_nav_menu(
array(
'theme_location' => 'social', 'theme_location' => 'social',
'menu_class' => 'social-links-menu', 'menu_class' => 'social-links-menu',
'depth' => 1, 'depth' => 1,
'link_before' => '<span class="screen-reader-text">', 'link_before' => '<span class="screen-reader-text">',
'link_after' => '</span>' . twentyseventeen_get_svg( array( 'icon' => 'chain' ) ), 'link_after' => '</span>' . twentyseventeen_get_svg( array( 'icon' => 'chain' ) ),
) ); )
);
?> ?>
</nav><!-- .social-navigation --> </nav><!-- .social-navigation -->
<?php endif; <?php
endif;
get_template_part( 'template-parts/footer/site', 'info' ); get_template_part( 'template-parts/footer/site', 'info' );
?> ?>

View file

@ -4,7 +4,7 @@
* *
* If the user has selected a static page for their homepage, this is what will * If the user has selected a static page for their homepage, this is what will
* appear. * appear.
* Learn more: https://codex.wordpress.org/Template_Hierarchy * Learn more: https://developer.wordpress.org/themes/basics/template-hierarchy/
* *
* @package WordPress * @package WordPress
* @subpackage Twenty_Seventeen * @subpackage Twenty_Seventeen
@ -17,14 +17,17 @@ get_header(); ?>
<div id="primary" class="content-area"> <div id="primary" class="content-area">
<main id="main" class="site-main" role="main"> <main id="main" class="site-main" role="main">
<?php // Show the selected frontpage content. <?php
// Show the selected front page content.
if ( have_posts() ) : if ( have_posts() ) :
while ( have_posts() ) : the_post(); while ( have_posts() ) :
the_post();
get_template_part( 'template-parts/page/content', 'front-page' ); get_template_part( 'template-parts/page/content', 'front-page' );
endwhile; endwhile;
else : else :
get_template_part( 'template-parts/post/content', 'none' ); get_template_part( 'template-parts/post/content', 'none' );
endif; ?> endif;
?>
<?php <?php
// Get each of our panels and show the post data. // Get each of our panels and show the post data.
@ -46,9 +49,11 @@ get_header(); ?>
twentyseventeen_front_page_section( null, $i ); twentyseventeen_front_page_section( null, $i );
} }
endif; // The if ( 0 !== twentyseventeen_panel_count() ) ends here. ?> endif; // The if ( 0 !== twentyseventeen_panel_count() ) ends here.
?>
</main><!-- #main --> </main><!-- #main -->
</div><!-- #primary --> </div><!-- #primary -->
<?php get_footer(); <?php
get_footer();

View file

@ -59,28 +59,35 @@ function twentyseventeen_setup() {
$GLOBALS['content_width'] = 525; $GLOBALS['content_width'] = 525;
// This theme uses wp_nav_menu() in two locations. // This theme uses wp_nav_menu() in two locations.
register_nav_menus( array( register_nav_menus(
array(
'top' => __( 'Top Menu', 'twentyseventeen' ), 'top' => __( 'Top Menu', 'twentyseventeen' ),
'social' => __( 'Social Links Menu', 'twentyseventeen' ), 'social' => __( 'Social Links Menu', 'twentyseventeen' ),
) ); )
);
/* /*
* Switch default core markup for search form, comment form, and comments * Switch default core markup for search form, comment form, and comments
* to output valid HTML5. * to output valid HTML5.
*/ */
add_theme_support( 'html5', array( add_theme_support(
'html5',
array(
'comment-form', 'comment-form',
'comment-list', 'comment-list',
'gallery', 'gallery',
'caption', 'caption',
) ); )
);
/* /*
* Enable support for Post Formats. * Enable support for Post Formats.
* *
* See: https://codex.wordpress.org/Post_Formats * See: https://codex.wordpress.org/Post_Formats
*/ */
add_theme_support( 'post-formats', array( add_theme_support(
'post-formats',
array(
'aside', 'aside',
'image', 'image',
'video', 'video',
@ -88,14 +95,18 @@ function twentyseventeen_setup() {
'link', 'link',
'gallery', 'gallery',
'audio', 'audio',
) ); )
);
// Add theme support for Custom Logo. // Add theme support for Custom Logo.
add_theme_support( 'custom-logo', array( add_theme_support(
'custom-logo',
array(
'width' => 250, 'width' => 250,
'height' => 250, 'height' => 250,
'flex-width' => true, 'flex-width' => true,
) ); )
);
// Add theme support for selective refresh for widgets. // Add theme support for selective refresh for widgets.
add_theme_support( 'customize-selective-refresh-widgets' ); add_theme_support( 'customize-selective-refresh-widgets' );
@ -320,7 +331,8 @@ add_filter( 'wp_resource_hints', 'twentyseventeen_resource_hints', 10, 2 );
* @link https://developer.wordpress.org/themes/functionality/sidebars/#registering-a-sidebar * @link https://developer.wordpress.org/themes/functionality/sidebars/#registering-a-sidebar
*/ */
function twentyseventeen_widgets_init() { function twentyseventeen_widgets_init() {
register_sidebar( array( register_sidebar(
array(
'name' => __( 'Blog Sidebar', 'twentyseventeen' ), 'name' => __( 'Blog Sidebar', 'twentyseventeen' ),
'id' => 'sidebar-1', 'id' => 'sidebar-1',
'description' => __( 'Add widgets here to appear in your sidebar on blog posts and archive pages.', 'twentyseventeen' ), 'description' => __( 'Add widgets here to appear in your sidebar on blog posts and archive pages.', 'twentyseventeen' ),
@ -328,9 +340,11 @@ function twentyseventeen_widgets_init() {
'after_widget' => '</section>', 'after_widget' => '</section>',
'before_title' => '<h2 class="widget-title">', 'before_title' => '<h2 class="widget-title">',
'after_title' => '</h2>', 'after_title' => '</h2>',
) ); )
);
register_sidebar( array( register_sidebar(
array(
'name' => __( 'Footer 1', 'twentyseventeen' ), 'name' => __( 'Footer 1', 'twentyseventeen' ),
'id' => 'sidebar-2', 'id' => 'sidebar-2',
'description' => __( 'Add widgets here to appear in your footer.', 'twentyseventeen' ), 'description' => __( 'Add widgets here to appear in your footer.', 'twentyseventeen' ),
@ -338,9 +352,11 @@ function twentyseventeen_widgets_init() {
'after_widget' => '</section>', 'after_widget' => '</section>',
'before_title' => '<h2 class="widget-title">', 'before_title' => '<h2 class="widget-title">',
'after_title' => '</h2>', 'after_title' => '</h2>',
) ); )
);
register_sidebar( array( register_sidebar(
array(
'name' => __( 'Footer 2', 'twentyseventeen' ), 'name' => __( 'Footer 2', 'twentyseventeen' ),
'id' => 'sidebar-3', 'id' => 'sidebar-3',
'description' => __( 'Add widgets here to appear in your footer.', 'twentyseventeen' ), 'description' => __( 'Add widgets here to appear in your footer.', 'twentyseventeen' ),
@ -348,7 +364,8 @@ function twentyseventeen_widgets_init() {
'after_widget' => '</section>', 'after_widget' => '</section>',
'before_title' => '<h2 class="widget-title">', 'before_title' => '<h2 class="widget-title">',
'after_title' => '</h2>', 'after_title' => '</h2>',
) ); )
);
} }
add_action( 'widgets_init', 'twentyseventeen_widgets_init' ); add_action( 'widgets_init', 'twentyseventeen_widgets_init' );
@ -366,7 +383,8 @@ function twentyseventeen_excerpt_more( $link ) {
return $link; return $link;
} }
$link = sprintf( '<p class="link-more"><a href="%1$s" class="more-link">%2$s</a></p>', $link = sprintf(
'<p class="link-more"><a href="%1$s" class="more-link">%2$s</a></p>',
esc_url( get_permalink( get_the_ID() ) ), esc_url( get_permalink( get_the_ID() ) ),
/* translators: %s: Name of current post */ /* translators: %s: Name of current post */
sprintf( __( 'Continue reading<span class="screen-reader-text"> "%s"</span>', 'twentyseventeen' ), get_the_title( get_the_ID() ) ) sprintf( __( 'Continue reading<span class="screen-reader-text"> "%s"</span>', 'twentyseventeen' ), get_the_title( get_the_ID() ) )
@ -392,7 +410,7 @@ add_action( 'wp_head', 'twentyseventeen_javascript_detection', 0 );
*/ */
function twentyseventeen_pingback_header() { function twentyseventeen_pingback_header() {
if ( is_singular() && pings_open() ) { if ( is_singular() && pings_open() ) {
printf( '<link rel="pingback" href="%s">' . "\n", get_bloginfo( 'pingback_url' ) ); printf( '<link rel="pingback" href="%s">' . "\n", esc_url( get_bloginfo( 'pingback_url' ) ) );
} }
} }
add_action( 'wp_head', 'twentyseventeen_pingback_header' ); add_action( 'wp_head', 'twentyseventeen_pingback_header' );
@ -407,15 +425,21 @@ function twentyseventeen_colors_css_wrap() {
require_once( get_parent_theme_file_path( '/inc/color-patterns.php' ) ); require_once( get_parent_theme_file_path( '/inc/color-patterns.php' ) );
$hue = absint( get_theme_mod( 'colorscheme_hue', 250 ) ); $hue = absint( get_theme_mod( 'colorscheme_hue', 250 ) );
?>
<style type="text/css" id="custom-theme-colors" <?php if ( is_customize_preview() ) { echo 'data-hue="' . $hue . '"'; } ?>> $customize_preview_data_hue = '';
if ( is_customize_preview() ) {
$customize_preview_data_hue = 'data-hue="' . $hue . '"';
}
?>
<style type="text/css" id="custom-theme-colors" <?php echo $customize_preview_data_hue; ?>>
<?php echo twentyseventeen_custom_colors_css(); ?> <?php echo twentyseventeen_custom_colors_css(); ?>
</style> </style>
<?php } <?php
}
add_action( 'wp_head', 'twentyseventeen_colors_css_wrap' ); add_action( 'wp_head', 'twentyseventeen_colors_css_wrap' );
/** /**
* Enqueue scripts and styles. * Enqueues scripts and styles.
*/ */
function twentyseventeen_scripts() { function twentyseventeen_scripts() {
// Add custom fonts, used in the main stylesheet. // Add custom fonts, used in the main stylesheet.
@ -456,7 +480,12 @@ function twentyseventeen_scripts() {
wp_enqueue_script( 'twentyseventeen-navigation', get_theme_file_uri( '/assets/js/navigation.js' ), array( 'jquery' ), '1.0', true ); wp_enqueue_script( 'twentyseventeen-navigation', get_theme_file_uri( '/assets/js/navigation.js' ), array( 'jquery' ), '1.0', true );
$twentyseventeen_l10n['expand'] = __( 'Expand child menu', 'twentyseventeen' ); $twentyseventeen_l10n['expand'] = __( 'Expand child menu', 'twentyseventeen' );
$twentyseventeen_l10n['collapse'] = __( 'Collapse child menu', 'twentyseventeen' ); $twentyseventeen_l10n['collapse'] = __( 'Collapse child menu', 'twentyseventeen' );
$twentyseventeen_l10n['icon'] = twentyseventeen_get_svg( array( 'icon' => 'angle-down', 'fallback' => true ) ); $twentyseventeen_l10n['icon'] = twentyseventeen_get_svg(
array(
'icon' => 'angle-down',
'fallback' => true,
)
);
} }
wp_enqueue_script( 'twentyseventeen-global', get_theme_file_uri( '/assets/js/global.js' ), array( 'jquery' ), '1.0', true ); wp_enqueue_script( 'twentyseventeen-global', get_theme_file_uri( '/assets/js/global.js' ), array( 'jquery' ), '1.0', true );
@ -472,7 +501,7 @@ function twentyseventeen_scripts() {
add_action( 'wp_enqueue_scripts', 'twentyseventeen_scripts' ); add_action( 'wp_enqueue_scripts', 'twentyseventeen_scripts' );
/** /**
* Enqueue styles for the block-based editor. * Enqueues styles for the block-based editor.
* *
* @since Twenty Seventeen 1.8 * @since Twenty Seventeen 1.8
*/ */

View file

@ -23,6 +23,7 @@
</head> </head>
<body <?php body_class(); ?>> <body <?php body_class(); ?>>
<?php wp_body_open(); ?>
<div id="page" class="site"> <div id="page" class="site">
<a class="skip-link screen-reader-text" href="#content"><?php _e( 'Skip to content', 'twentyseventeen' ); ?></a> <a class="skip-link screen-reader-text" href="#content"><?php _e( 'Skip to content', 'twentyseventeen' ); ?></a>

View file

@ -48,9 +48,13 @@ function twentyseventeen_upgrade_notice() {
* @global string $wp_version WordPress version. * @global string $wp_version WordPress version.
*/ */
function twentyseventeen_customize() { function twentyseventeen_customize() {
wp_die( sprintf( __( 'Twenty Seventeen requires at least WordPress version 4.7. You are running version %s. Please upgrade and try again.', 'twentyseventeen' ), $GLOBALS['wp_version'] ), '', array( wp_die(
sprintf( __( 'Twenty Seventeen requires at least WordPress version 4.7. You are running version %s. Please upgrade and try again.', 'twentyseventeen' ), $GLOBALS['wp_version'] ),
'',
array(
'back_link' => true, 'back_link' => true,
) ); )
);
} }
add_action( 'load-customize.php', 'twentyseventeen_customize' ); add_action( 'load-customize.php', 'twentyseventeen_customize' );

View file

@ -307,7 +307,7 @@ body.colors-custom,
color: hsl( ' . $hue . ', ' . $saturation . ', 46% ); /* base: #767676; */ color: hsl( ' . $hue . ', ' . $saturation . ', 46% ); /* base: #767676; */
} }
.colors-custom button:hover, .colors-custom button:hover:not( .mejs-container > button ),
.colors-custom button:focus, .colors-custom button:focus,
.colors-custom input[type="button"]:hover, .colors-custom input[type="button"]:hover,
.colors-custom input[type="button"]:focus, .colors-custom input[type="button"]:focus,

View file

@ -25,40 +25,48 @@ function twentyseventeen_custom_header_setup() {
* An array of custom-header support arguments. * An array of custom-header support arguments.
* *
* @type string $default-image Default image of the header. * @type string $default-image Default image of the header.
* @type string $default_text_color Default color of the header text.
* @type int $width Width in pixels of the custom header image. Default 954. * @type int $width Width in pixels of the custom header image. Default 954.
* @type int $height Height in pixels of the custom header image. Default 1300. * @type int $height Height in pixels of the custom header image. Default 1300.
* @type string $flex-height Flex support for height of header.
* @type string $video Video support for header.
* @type string $wp-head-callback Callback function used to styles the header image and text * @type string $wp-head-callback Callback function used to styles the header image and text
* displayed on the blog. * displayed on the blog.
* @type string $flex-height Flex support for height of header.
* } * }
*/ */
add_theme_support( 'custom-header', apply_filters( 'twentyseventeen_custom_header_args', array( add_theme_support(
'custom-header',
apply_filters(
'twentyseventeen_custom_header_args',
array(
'default-image' => get_parent_theme_file_uri( '/assets/images/header.jpg' ), 'default-image' => get_parent_theme_file_uri( '/assets/images/header.jpg' ),
'width' => 2000, 'width' => 2000,
'height' => 1200, 'height' => 1200,
'flex-height' => true, 'flex-height' => true,
'video' => true, 'video' => true,
'wp-head-callback' => 'twentyseventeen_header_style', 'wp-head-callback' => 'twentyseventeen_header_style',
) ) ); )
)
);
register_default_headers( array( register_default_headers(
array(
'default-image' => array( 'default-image' => array(
'url' => '%s/assets/images/header.jpg', 'url' => '%s/assets/images/header.jpg',
'thumbnail_url' => '%s/assets/images/header.jpg', 'thumbnail_url' => '%s/assets/images/header.jpg',
'description' => __( 'Default Header Image', 'twentyseventeen' ), 'description' => __( 'Default Header Image', 'twentyseventeen' ),
), ),
) ); )
);
} }
add_action( 'after_setup_theme', 'twentyseventeen_custom_header_setup' ); add_action( 'after_setup_theme', 'twentyseventeen_custom_header_setup' );
if ( ! function_exists( 'twentyseventeen_header_style' ) ) : if ( ! function_exists( 'twentyseventeen_header_style' ) ) :
/** /**
* Styles the header image and text displayed on the blog. * Styles the header image and text displayed on the blog.
* *
* @see twentyseventeen_custom_header_setup(). * @see twentyseventeen_custom_header_setup().
*/ */
function twentyseventeen_header_style() { function twentyseventeen_header_style() {
$header_text_color = get_header_textcolor(); $header_text_color = get_header_textcolor();
// If no custom options for text are set, let's bail. // If no custom options for text are set, let's bail.
@ -106,7 +114,7 @@ function twentyseventeen_header_style() {
<?php endif; ?> <?php endif; ?>
</style> </style>
<?php <?php
} }
endif; // End of twentyseventeen_header_style. endif; // End of twentyseventeen_header_style.
/** /**

View file

@ -17,31 +17,45 @@ function twentyseventeen_customize_register( $wp_customize ) {
$wp_customize->get_setting( 'blogdescription' )->transport = 'postMessage'; $wp_customize->get_setting( 'blogdescription' )->transport = 'postMessage';
$wp_customize->get_setting( 'header_textcolor' )->transport = 'postMessage'; $wp_customize->get_setting( 'header_textcolor' )->transport = 'postMessage';
$wp_customize->selective_refresh->add_partial( 'blogname', array( $wp_customize->selective_refresh->add_partial(
'blogname',
array(
'selector' => '.site-title a', 'selector' => '.site-title a',
'render_callback' => 'twentyseventeen_customize_partial_blogname', 'render_callback' => 'twentyseventeen_customize_partial_blogname',
) ); )
$wp_customize->selective_refresh->add_partial( 'blogdescription', array( );
$wp_customize->selective_refresh->add_partial(
'blogdescription',
array(
'selector' => '.site-description', 'selector' => '.site-description',
'render_callback' => 'twentyseventeen_customize_partial_blogdescription', 'render_callback' => 'twentyseventeen_customize_partial_blogdescription',
) ); )
);
/** /**
* Custom colors. * Custom colors.
*/ */
$wp_customize->add_setting( 'colorscheme', array( $wp_customize->add_setting(
'colorscheme',
array(
'default' => 'light', 'default' => 'light',
'transport' => 'postMessage', 'transport' => 'postMessage',
'sanitize_callback' => 'twentyseventeen_sanitize_colorscheme', 'sanitize_callback' => 'twentyseventeen_sanitize_colorscheme',
) ); )
);
$wp_customize->add_setting( 'colorscheme_hue', array( $wp_customize->add_setting(
'colorscheme_hue',
array(
'default' => 250, 'default' => 250,
'transport' => 'postMessage', 'transport' => 'postMessage',
'sanitize_callback' => 'absint', // The hue is stored as a positive integer. 'sanitize_callback' => 'absint', // The hue is stored as a positive integer.
) ); )
);
$wp_customize->add_control( 'colorscheme', array( $wp_customize->add_control(
'colorscheme',
array(
'type' => 'radio', 'type' => 'radio',
'label' => __( 'Color Scheme', 'twentyseventeen' ), 'label' => __( 'Color Scheme', 'twentyseventeen' ),
'choices' => array( 'choices' => array(
@ -51,29 +65,44 @@ function twentyseventeen_customize_register( $wp_customize ) {
), ),
'section' => 'colors', 'section' => 'colors',
'priority' => 5, 'priority' => 5,
) ); )
);
$wp_customize->add_control( new WP_Customize_Color_Control( $wp_customize, 'colorscheme_hue', array( $wp_customize->add_control(
new WP_Customize_Color_Control(
$wp_customize,
'colorscheme_hue',
array(
'mode' => 'hue', 'mode' => 'hue',
'section' => 'colors', 'section' => 'colors',
'priority' => 6, 'priority' => 6,
) ) ); )
)
);
/** /**
* Theme options. * Theme options.
*/ */
$wp_customize->add_section( 'theme_options', array( $wp_customize->add_section(
'theme_options',
array(
'title' => __( 'Theme Options', 'twentyseventeen' ), 'title' => __( 'Theme Options', 'twentyseventeen' ),
'priority' => 130, // Before Additional CSS. 'priority' => 130, // Before Additional CSS.
) ); )
);
$wp_customize->add_setting( 'page_layout', array( $wp_customize->add_setting(
'page_layout',
array(
'default' => 'two-column', 'default' => 'two-column',
'sanitize_callback' => 'twentyseventeen_sanitize_page_layout', 'sanitize_callback' => 'twentyseventeen_sanitize_page_layout',
'transport' => 'postMessage', 'transport' => 'postMessage',
) ); )
);
$wp_customize->add_control( 'page_layout', array( $wp_customize->add_control(
'page_layout',
array(
'label' => __( 'Page Layout', 'twentyseventeen' ), 'label' => __( 'Page Layout', 'twentyseventeen' ),
'section' => 'theme_options', 'section' => 'theme_options',
'type' => 'radio', 'type' => 'radio',
@ -83,7 +112,8 @@ function twentyseventeen_customize_register( $wp_customize ) {
'two-column' => __( 'Two Column', 'twentyseventeen' ), 'two-column' => __( 'Two Column', 'twentyseventeen' ),
), ),
'active_callback' => 'twentyseventeen_is_view_with_layout_option', 'active_callback' => 'twentyseventeen_is_view_with_layout_option',
) ); )
);
/** /**
* Filter number of front page sections in Twenty Seventeen. * Filter number of front page sections in Twenty Seventeen.
@ -96,13 +126,18 @@ function twentyseventeen_customize_register( $wp_customize ) {
// Create a setting and control for each of the sections available in the theme. // Create a setting and control for each of the sections available in the theme.
for ( $i = 1; $i < ( 1 + $num_sections ); $i++ ) { for ( $i = 1; $i < ( 1 + $num_sections ); $i++ ) {
$wp_customize->add_setting( 'panel_' . $i, array( $wp_customize->add_setting(
'panel_' . $i,
array(
'default' => false, 'default' => false,
'sanitize_callback' => 'absint', 'sanitize_callback' => 'absint',
'transport' => 'postMessage', 'transport' => 'postMessage',
) ); )
);
$wp_customize->add_control( 'panel_' . $i, array( $wp_customize->add_control(
'panel_' . $i,
array(
/* translators: %d is the front page section number */ /* translators: %d is the front page section number */
'label' => sprintf( __( 'Front Page Section %d Content', 'twentyseventeen' ), $i ), 'label' => sprintf( __( 'Front Page Section %d Content', 'twentyseventeen' ), $i ),
'description' => ( 1 !== $i ? '' : __( 'Select pages to feature in each area from the dropdowns. Add an image to a section by setting a featured image in the page editor. Empty sections will not be displayed.', 'twentyseventeen' ) ), 'description' => ( 1 !== $i ? '' : __( 'Select pages to feature in each area from the dropdowns. Add an image to a section by setting a featured image in the page editor. Empty sections will not be displayed.', 'twentyseventeen' ) ),
@ -110,13 +145,17 @@ function twentyseventeen_customize_register( $wp_customize ) {
'type' => 'dropdown-pages', 'type' => 'dropdown-pages',
'allow_addition' => true, 'allow_addition' => true,
'active_callback' => 'twentyseventeen_is_static_front_page', 'active_callback' => 'twentyseventeen_is_static_front_page',
) ); )
);
$wp_customize->selective_refresh->add_partial( 'panel_' . $i, array( $wp_customize->selective_refresh->add_partial(
'panel_' . $i,
array(
'selector' => '#panel' . $i, 'selector' => '#panel' . $i,
'render_callback' => 'twentyseventeen_front_page_section', 'render_callback' => 'twentyseventeen_front_page_section',
'container_inclusive' => true, 'container_inclusive' => true,
) ); )
);
} }
} }
add_action( 'customize_register', 'twentyseventeen_customize_register' ); add_action( 'customize_register', 'twentyseventeen_customize_register' );

View file

@ -95,7 +95,7 @@ function twentyseventeen_panel_count() {
} }
/** /**
* Checks to see if we're on the homepage or not. * Checks to see if we're on the front page or not.
*/ */
function twentyseventeen_is_frontpage() { function twentyseventeen_is_frontpage() {
return ( is_front_page() && ! is_home() ); return ( is_front_page() && ! is_home() );

View file

@ -10,10 +10,10 @@
*/ */
if ( ! function_exists( 'twentyseventeen_posted_on' ) ) : if ( ! function_exists( 'twentyseventeen_posted_on' ) ) :
/** /**
* Prints HTML with meta information for the current post-date/time and author. * Prints HTML with meta information for the current post-date/time and author.
*/ */
function twentyseventeen_posted_on() { function twentyseventeen_posted_on() {
// Get the author name; wrap it in a link. // Get the author name; wrap it in a link.
$byline = sprintf( $byline = sprintf(
@ -24,21 +24,22 @@ function twentyseventeen_posted_on() {
// Finally, let's write all of this to the page. // Finally, let's write all of this to the page.
echo '<span class="posted-on">' . twentyseventeen_time_link() . '</span><span class="byline"> ' . $byline . '</span>'; echo '<span class="posted-on">' . twentyseventeen_time_link() . '</span><span class="byline"> ' . $byline . '</span>';
} }
endif; endif;
if ( ! function_exists( 'twentyseventeen_time_link' ) ) : if ( ! function_exists( 'twentyseventeen_time_link' ) ) :
/** /**
* Gets a nicely formatted string for the published date. * Gets a nicely formatted string for the published date.
*/ */
function twentyseventeen_time_link() { function twentyseventeen_time_link() {
$time_string = '<time class="entry-date published updated" datetime="%1$s">%2$s</time>'; $time_string = '<time class="entry-date published updated" datetime="%1$s">%2$s</time>';
if ( get_the_time( 'U' ) !== get_the_modified_time( 'U' ) ) { if ( get_the_time( 'U' ) !== get_the_modified_time( 'U' ) ) {
$time_string = '<time class="entry-date published" datetime="%1$s">%2$s</time><time class="updated" datetime="%3$s">%4$s</time>'; $time_string = '<time class="entry-date published" datetime="%1$s">%2$s</time><time class="updated" datetime="%3$s">%4$s</time>';
} }
$time_string = sprintf( $time_string, $time_string = sprintf(
$time_string,
get_the_date( DATE_W3C ), get_the_date( DATE_W3C ),
get_the_date(), get_the_date(),
get_the_modified_date( DATE_W3C ), get_the_modified_date( DATE_W3C ),
@ -51,15 +52,15 @@ function twentyseventeen_time_link() {
__( '<span class="screen-reader-text">Posted on</span> %s', 'twentyseventeen' ), __( '<span class="screen-reader-text">Posted on</span> %s', 'twentyseventeen' ),
'<a href="' . esc_url( get_permalink() ) . '" rel="bookmark">' . $time_string . '</a>' '<a href="' . esc_url( get_permalink() ) . '" rel="bookmark">' . $time_string . '</a>'
); );
} }
endif; endif;
if ( ! function_exists( 'twentyseventeen_entry_footer' ) ) : if ( ! function_exists( 'twentyseventeen_entry_footer' ) ) :
/** /**
* Prints HTML with meta information for the categories, tags and comments. * Prints HTML with meta information for the categories, tags and comments.
*/ */
function twentyseventeen_entry_footer() { function twentyseventeen_entry_footer() {
/* translators: used between list items, there is a space after the comma */ /* translators: used between list items, there is a space after the comma */
$separate_meta = __( ', ', 'twentyseventeen' ); $separate_meta = __( ', ', 'twentyseventeen' );
@ -96,12 +97,12 @@ function twentyseventeen_entry_footer() {
echo '</footer> <!-- .entry-footer -->'; echo '</footer> <!-- .entry-footer -->';
} }
} }
endif; endif;
if ( ! function_exists( 'twentyseventeen_edit_link' ) ) : if ( ! function_exists( 'twentyseventeen_edit_link' ) ) :
/** /**
* Returns an accessibility-friendly link to edit a post or page. * Returns an accessibility-friendly link to edit a post or page.
* *
* This also gives us a little context about what exactly we're editing * This also gives us a little context about what exactly we're editing
@ -109,7 +110,7 @@ if ( ! function_exists( 'twentyseventeen_edit_link' ) ) :
* of the template hierarchy and their content. Helpful when/if the single-page * of the template hierarchy and their content. Helpful when/if the single-page
* layout with multiple posts/pages shown gets confusing. * layout with multiple posts/pages shown gets confusing.
*/ */
function twentyseventeen_edit_link() { function twentyseventeen_edit_link() {
edit_post_link( edit_post_link(
sprintf( sprintf(
/* translators: %s: Name of current post */ /* translators: %s: Name of current post */
@ -119,7 +120,7 @@ function twentyseventeen_edit_link() {
'<span class="edit-link">', '<span class="edit-link">',
'</span>' '</span>'
); );
} }
endif; endif;
/** /**
@ -161,12 +162,14 @@ function twentyseventeen_categorized_blog() {
if ( false === $category_count ) { if ( false === $category_count ) {
// Create an array of all the categories that are attached to posts. // Create an array of all the categories that are attached to posts.
$categories = get_categories( array( $categories = get_categories(
array(
'fields' => 'ids', 'fields' => 'ids',
'hide_empty' => 1, 'hide_empty' => 1,
// We only need to know if there is more than one category. // We only need to know if there is more than one category.
'number' => 2, 'number' => 2,
) ); )
);
// Count the number of categories that are attached to the posts. // Count the number of categories that are attached to the posts.
$category_count = count( $categories ); $category_count = count( $categories );
@ -195,3 +198,21 @@ function twentyseventeen_category_transient_flusher() {
} }
add_action( 'edit_category', 'twentyseventeen_category_transient_flusher' ); add_action( 'edit_category', 'twentyseventeen_category_transient_flusher' );
add_action( 'save_post', 'twentyseventeen_category_transient_flusher' ); add_action( 'save_post', 'twentyseventeen_category_transient_flusher' );
if ( ! function_exists( 'wp_body_open' ) ) :
/**
* Fire the wp_body_open action.
*
* Added for backwards compatibility to support pre 5.2.0 WordPress versions.
*
* @since Twenty Seventeen 2.2
*/
function wp_body_open() {
/**
* Triggered after the opening <body> tag.
*
* @since Twenty Seventeen 2.2
*/
do_action( 'wp_body_open' );
}
endif;

View file

@ -7,7 +7,7 @@
* It is used to display a page when nothing more specific matches a query. * It is used to display a page when nothing more specific matches a query.
* E.g., it puts together the home page when no home.php file exists. * E.g., it puts together the home page when no home.php file exists.
* *
* @link https://codex.wordpress.org/Template_Hierarchy * @link https://developer.wordpress.org/themes/basics/template-hierarchy/
* *
* @package WordPress * @package WordPress
* @subpackage Twenty_Seventeen * @subpackage Twenty_Seventeen
@ -35,7 +35,8 @@ get_header(); ?>
if ( have_posts() ) : if ( have_posts() ) :
/* Start the Loop */ /* Start the Loop */
while ( have_posts() ) : the_post(); while ( have_posts() ) :
the_post();
/* /*
* Include the Post-Format-specific template for the content. * Include the Post-Format-specific template for the content.
@ -46,11 +47,13 @@ get_header(); ?>
endwhile; endwhile;
the_posts_pagination( array( the_posts_pagination(
array(
'prev_text' => twentyseventeen_get_svg( array( 'icon' => 'arrow-left' ) ) . '<span class="screen-reader-text">' . __( 'Previous page', 'twentyseventeen' ) . '</span>', 'prev_text' => twentyseventeen_get_svg( array( 'icon' => 'arrow-left' ) ) . '<span class="screen-reader-text">' . __( 'Previous page', 'twentyseventeen' ) . '</span>',
'next_text' => '<span class="screen-reader-text">' . __( 'Next page', 'twentyseventeen' ) . '</span>' . twentyseventeen_get_svg( array( 'icon' => 'arrow-right' ) ), 'next_text' => '<span class="screen-reader-text">' . __( 'Next page', 'twentyseventeen' ) . '</span>' . twentyseventeen_get_svg( array( 'icon' => 'arrow-right' ) ),
'before_page_number' => '<span class="meta-nav screen-reader-text">' . __( 'Page', 'twentyseventeen' ) . ' </span>', 'before_page_number' => '<span class="meta-nav screen-reader-text">' . __( 'Page', 'twentyseventeen' ) . ' </span>',
) ); )
);
else : else :
@ -64,4 +67,5 @@ get_header(); ?>
<?php get_sidebar(); ?> <?php get_sidebar(); ?>
</div><!-- .wrap --> </div><!-- .wrap -->
<?php get_footer(); <?php
get_footer();

View file

@ -7,7 +7,7 @@
* and that other 'pages' on your WordPress site may use a * and that other 'pages' on your WordPress site may use a
* different template. * different template.
* *
* @link https://codex.wordpress.org/Template_Hierarchy * @link https://developer.wordpress.org/themes/basics/template-hierarchy/
* *
* @package WordPress * @package WordPress
* @subpackage Twenty_Seventeen * @subpackage Twenty_Seventeen
@ -22,7 +22,8 @@ get_header(); ?>
<main id="main" class="site-main" role="main"> <main id="main" class="site-main" role="main">
<?php <?php
while ( have_posts() ) : the_post(); while ( have_posts() ) :
the_post();
get_template_part( 'template-parts/page/content', 'page' ); get_template_part( 'template-parts/page/content', 'page' );
@ -38,4 +39,5 @@ get_header(); ?>
</div><!-- #primary --> </div><!-- #primary -->
</div><!-- .wrap --> </div><!-- .wrap -->
<?php get_footer(); <?php
get_footer();

View file

@ -28,7 +28,8 @@ get_header(); ?>
<?php <?php
if ( have_posts() ) : if ( have_posts() ) :
/* Start the Loop */ /* Start the Loop */
while ( have_posts() ) : the_post(); while ( have_posts() ) :
the_post();
/** /**
* Run the loop for the search to output the results. * Run the loop for the search to output the results.
@ -39,13 +40,16 @@ get_header(); ?>
endwhile; // End of the loop. endwhile; // End of the loop.
the_posts_pagination( array( the_posts_pagination(
array(
'prev_text' => twentyseventeen_get_svg( array( 'icon' => 'arrow-left' ) ) . '<span class="screen-reader-text">' . __( 'Previous page', 'twentyseventeen' ) . '</span>', 'prev_text' => twentyseventeen_get_svg( array( 'icon' => 'arrow-left' ) ) . '<span class="screen-reader-text">' . __( 'Previous page', 'twentyseventeen' ) . '</span>',
'next_text' => '<span class="screen-reader-text">' . __( 'Next page', 'twentyseventeen' ) . '</span>' . twentyseventeen_get_svg( array( 'icon' => 'arrow-right' ) ), 'next_text' => '<span class="screen-reader-text">' . __( 'Next page', 'twentyseventeen' ) . '</span>' . twentyseventeen_get_svg( array( 'icon' => 'arrow-right' ) ),
'before_page_number' => '<span class="meta-nav screen-reader-text">' . __( 'Page', 'twentyseventeen' ) . ' </span>', 'before_page_number' => '<span class="meta-nav screen-reader-text">' . __( 'Page', 'twentyseventeen' ) . ' </span>',
) ); )
);
else : ?> else :
?>
<p><?php _e( 'Sorry, but nothing matched your search terms. Please try again with some different keywords.', 'twentyseventeen' ); ?></p> <p><?php _e( 'Sorry, but nothing matched your search terms. Please try again with some different keywords.', 'twentyseventeen' ); ?></p>
<?php <?php
@ -59,4 +63,5 @@ get_header(); ?>
<?php get_sidebar(); ?> <?php get_sidebar(); ?>
</div><!-- .wrap --> </div><!-- .wrap -->
<?php get_footer(); <?php
get_footer();

View file

@ -18,7 +18,8 @@ get_header(); ?>
<?php <?php
/* Start the Loop */ /* Start the Loop */
while ( have_posts() ) : the_post(); while ( have_posts() ) :
the_post();
get_template_part( 'template-parts/post/content', get_post_format() ); get_template_part( 'template-parts/post/content', get_post_format() );
@ -27,10 +28,12 @@ get_header(); ?>
comments_template(); comments_template();
endif; endif;
the_post_navigation( array( the_post_navigation(
array(
'prev_text' => '<span class="screen-reader-text">' . __( 'Previous Post', 'twentyseventeen' ) . '</span><span aria-hidden="true" class="nav-subtitle">' . __( 'Previous', 'twentyseventeen' ) . '</span> <span class="nav-title"><span class="nav-title-icon-wrapper">' . twentyseventeen_get_svg( array( 'icon' => 'arrow-left' ) ) . '</span>%title</span>', 'prev_text' => '<span class="screen-reader-text">' . __( 'Previous Post', 'twentyseventeen' ) . '</span><span aria-hidden="true" class="nav-subtitle">' . __( 'Previous', 'twentyseventeen' ) . '</span> <span class="nav-title"><span class="nav-title-icon-wrapper">' . twentyseventeen_get_svg( array( 'icon' => 'arrow-left' ) ) . '</span>%title</span>',
'next_text' => '<span class="screen-reader-text">' . __( 'Next Post', 'twentyseventeen' ) . '</span><span aria-hidden="true" class="nav-subtitle">' . __( 'Next', 'twentyseventeen' ) . '</span> <span class="nav-title">%title<span class="nav-title-icon-wrapper">' . twentyseventeen_get_svg( array( 'icon' => 'arrow-right' ) ) . '</span></span>', 'next_text' => '<span class="screen-reader-text">' . __( 'Next Post', 'twentyseventeen' ) . '</span><span aria-hidden="true" class="nav-subtitle">' . __( 'Next', 'twentyseventeen' ) . '</span> <span class="nav-title">%title<span class="nav-title-icon-wrapper">' . twentyseventeen_get_svg( array( 'icon' => 'arrow-right' ) ) . '</span></span>',
) ); )
);
endwhile; // End of the loop. endwhile; // End of the loop.
?> ?>
@ -40,4 +43,5 @@ get_header(); ?>
<?php get_sidebar(); ?> <?php get_sidebar(); ?>
</div><!-- .wrap --> </div><!-- .wrap -->
<?php get_footer(); <?php
get_footer();

View file

@ -4,7 +4,7 @@ Theme URI: https://wordpress.org/themes/twentyseventeen/
Author: the WordPress team Author: the WordPress team
Author URI: https://wordpress.org/ Author URI: https://wordpress.org/
Description: Twenty Seventeen brings your site to life with header video and immersive featured images. With a focus on business sites, it features multiple sections on the front page as well as widgets, navigation and social menus, a logo, and more. Personalize its asymmetrical grid with a custom color scheme and showcase your multimedia content with post formats. Our default theme for 2017 works great in many languages, for any abilities, and on any device. Description: Twenty Seventeen brings your site to life with header video and immersive featured images. With a focus on business sites, it features multiple sections on the front page as well as widgets, navigation and social menus, a logo, and more. Personalize its asymmetrical grid with a custom color scheme and showcase your multimedia content with post formats. Our default theme for 2017 works great in many languages, for any abilities, and on any device.
Version: 2.0 Version: 2.2
License: GNU General Public License v2 or later License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: twentyseventeen Text Domain: twentyseventeen
@ -1034,7 +1034,7 @@ input[type="submit"].secondary {
color: #222; color: #222;
} }
button:hover, button:hover:not( .mejs-container > button ),
button:focus, button:focus,
input[type="button"]:hover, input[type="button"]:hover,
input[type="button"]:focus, input[type="button"]:focus,
@ -1646,6 +1646,7 @@ body.home.title-tagline-hidden.has-header-video .custom-logo-link img {
body:not(.title-tagline-hidden) .site-branding-text { body:not(.title-tagline-hidden) .site-branding-text {
display: inline-block; display: inline-block;
max-width: 100%;
vertical-align: middle; vertical-align: middle;
} }
@ -1748,7 +1749,6 @@ body:not(.title-tagline-hidden) .site-branding-text {
@supports ( object-fit: cover ) { @supports ( object-fit: cover ) {
.has-header-image .custom-header-media img, .has-header-image .custom-header-media img,
.has-header-video .custom-header-media video, .has-header-video .custom-header-media video,
.has-header-video .custom-header-media iframe,
.has-header-image:not(.twentyseventeen-front-page):not(.home) .custom-header-media img { .has-header-image:not(.twentyseventeen-front-page):not(.home) .custom-header-media img {
height: 100%; height: 100%;
left: 0; left: 0;

View file

@ -13,16 +13,19 @@
<?php <?php
if ( is_active_sidebar( 'sidebar-2' ) || if ( is_active_sidebar( 'sidebar-2' ) ||
is_active_sidebar( 'sidebar-3' ) ) : is_active_sidebar( 'sidebar-3' ) ) :
?> ?>
<aside class="widget-area" role="complementary" aria-label="<?php esc_attr_e( 'Footer', 'twentyseventeen' ); ?>"> <aside class="widget-area" role="complementary" aria-label="<?php esc_attr_e( 'Footer', 'twentyseventeen' ); ?>">
<?php <?php
if ( is_active_sidebar( 'sidebar-2' ) ) { ?> if ( is_active_sidebar( 'sidebar-2' ) ) {
?>
<div class="widget-column footer-widget-1"> <div class="widget-column footer-widget-1">
<?php dynamic_sidebar( 'sidebar-2' ); ?> <?php dynamic_sidebar( 'sidebar-2' ); ?>
</div> </div>
<?php } <?php
if ( is_active_sidebar( 'sidebar-3' ) ) { ?> }
if ( is_active_sidebar( 'sidebar-3' ) ) {
?>
<div class="widget-column footer-widget-2"> <div class="widget-column footer-widget-2">
<?php dynamic_sidebar( 'sidebar-3' ); ?> <?php dynamic_sidebar( 'sidebar-3' ); ?>
</div> </div>

View file

@ -18,10 +18,14 @@
?> ?>
</button> </button>
<?php wp_nav_menu( array( <?php
wp_nav_menu(
array(
'theme_location' => 'top', 'theme_location' => 'top',
'menu_id' => 'top-menu', 'menu_id' => 'top-menu',
) ); ?> )
);
?>
<?php if ( ( twentyseventeen_is_frontpage() || ( is_home() && is_front_page() ) ) && has_custom_header() ) : ?> <?php if ( ( twentyseventeen_is_frontpage() || ( is_home() && is_front_page() ) ) && has_custom_header() ) : ?>
<a href="#content" class="menu-scroll-down"><?php echo twentyseventeen_get_svg( array( 'icon' => 'arrow-right' ) ); ?><span class="screen-reader-text"><?php _e( 'Scroll down to content', 'twentyseventeen' ); ?></span></a> <a href="#content" class="menu-scroll-down"><?php echo twentyseventeen_get_svg( array( 'icon' => 'arrow-right' ) ); ?><span class="screen-reader-text"><?php _e( 'Scroll down to content', 'twentyseventeen' ); ?></span></a>

View file

@ -14,7 +14,8 @@ global $twentyseventeencounter;
<article id="panel<?php echo $twentyseventeencounter; ?>" <?php post_class( 'twentyseventeen-panel ' ); ?> > <article id="panel<?php echo $twentyseventeencounter; ?>" <?php post_class( 'twentyseventeen-panel ' ); ?> >
<?php if ( has_post_thumbnail() ) : <?php
if ( has_post_thumbnail() ) :
$thumbnail = wp_get_attachment_image_src( get_post_thumbnail_id( $post->ID ), 'twentyseventeen-featured-image' ); $thumbnail = wp_get_attachment_image_src( get_post_thumbnail_id( $post->ID ), 'twentyseventeen-featured-image' );
// Calculate aspect ratio: h / w * 100%. // Calculate aspect ratio: h / w * 100%.
@ -39,24 +40,30 @@ global $twentyseventeencounter;
<div class="entry-content"> <div class="entry-content">
<?php <?php
/* translators: %s: Name of current post */ /* translators: %s: Name of current post */
the_content( sprintf( the_content(
sprintf(
__( 'Continue reading<span class="screen-reader-text"> "%s"</span>', 'twentyseventeen' ), __( 'Continue reading<span class="screen-reader-text"> "%s"</span>', 'twentyseventeen' ),
get_the_title() get_the_title()
) ); )
);
?> ?>
</div><!-- .entry-content --> </div><!-- .entry-content -->
<?php <?php
// Show recent blog posts if is blog posts page (Note that get_option returns a string, so we're casting the result as an int). // Show recent blog posts if is blog posts page (Note that get_option returns a string, so we're casting the result as an int).
if ( get_the_ID() === (int) get_option( 'page_for_posts' ) ) : ?> if ( get_the_ID() === (int) get_option( 'page_for_posts' ) ) :
?>
<?php // Show four most recent posts. <?php
$recent_posts = new WP_Query( array( // Show three most recent posts.
$recent_posts = new WP_Query(
array(
'posts_per_page' => 3, 'posts_per_page' => 3,
'post_status' => 'publish', 'post_status' => 'publish',
'ignore_sticky_posts' => true, 'ignore_sticky_posts' => true,
'no_found_rows' => true, 'no_found_rows' => true,
) ); )
);
?> ?>
<?php if ( $recent_posts->have_posts() ) : ?> <?php if ( $recent_posts->have_posts() ) : ?>
@ -64,7 +71,8 @@ global $twentyseventeencounter;
<div class="recent-posts"> <div class="recent-posts">
<?php <?php
while ( $recent_posts->have_posts() ) : $recent_posts->the_post(); while ( $recent_posts->have_posts() ) :
$recent_posts->the_post();
get_template_part( 'template-parts/post/content', 'excerpt' ); get_template_part( 'template-parts/post/content', 'excerpt' );
endwhile; endwhile;
wp_reset_postdata(); wp_reset_postdata();
@ -76,4 +84,4 @@ global $twentyseventeencounter;
</div><!-- .wrap --> </div><!-- .wrap -->
</div><!-- .panel-content --> </div><!-- .panel-content -->
</article><!-- #post-## --> </article><!-- #post-<?php the_ID(); ?> -->

View file

@ -11,7 +11,8 @@
?> ?>
<article id="post-<?php the_ID(); ?>" <?php post_class( 'twentyseventeen-panel ' ); ?> > <article id="post-<?php the_ID(); ?>" <?php post_class( 'twentyseventeen-panel ' ); ?> >
<?php if ( has_post_thumbnail() ) : <?php
if ( has_post_thumbnail() ) :
$thumbnail = wp_get_attachment_image_src( get_post_thumbnail_id( $post->ID ), 'twentyseventeen-featured-image' ); $thumbnail = wp_get_attachment_image_src( get_post_thumbnail_id( $post->ID ), 'twentyseventeen-featured-image' );
// Calculate aspect ratio: h / w * 100%. // Calculate aspect ratio: h / w * 100%.
@ -36,14 +37,16 @@
<div class="entry-content"> <div class="entry-content">
<?php <?php
/* translators: %s: Name of current post */ /* translators: %s: Name of current post */
the_content( sprintf( the_content(
sprintf(
__( 'Continue reading<span class="screen-reader-text"> "%s"</span>', 'twentyseventeen' ), __( 'Continue reading<span class="screen-reader-text"> "%s"</span>', 'twentyseventeen' ),
get_the_title() get_the_title()
) ); )
);
?> ?>
</div><!-- .entry-content --> </div><!-- .entry-content -->
</div><!-- .wrap --> </div><!-- .wrap -->
</div><!-- .panel-content --> </div><!-- .panel-content -->
</article><!-- #post-## --> </article><!-- #post-<?php the_ID(); ?> -->

View file

@ -2,7 +2,7 @@
/** /**
* Template part for displaying page content in page.php * Template part for displaying page content in page.php
* *
* @link https://codex.wordpress.org/Template_Hierarchy * @link https://developer.wordpress.org/themes/basics/template-hierarchy/
* *
* @package WordPress * @package WordPress
* @subpackage Twenty_Seventeen * @subpackage Twenty_Seventeen
@ -21,10 +21,12 @@
<?php <?php
the_content(); the_content();
wp_link_pages( array( wp_link_pages(
array(
'before' => '<div class="page-links">' . __( 'Pages:', 'twentyseventeen' ), 'before' => '<div class="page-links">' . __( 'Pages:', 'twentyseventeen' ),
'after' => '</div>', 'after' => '</div>',
) ); )
);
?> ?>
</div><!-- .entry-content --> </div><!-- .entry-content -->
</article><!-- #post-## --> </article><!-- #post-<?php the_ID(); ?> -->

View file

@ -2,7 +2,7 @@
/** /**
* Template part for displaying audio posts * Template part for displaying audio posts
* *
* @link https://codex.wordpress.org/Template_Hierarchy * @link https://developer.wordpress.org/themes/basics/template-hierarchy/
* *
* @package WordPress * @package WordPress
* @subpackage Twenty_Seventeen * @subpackage Twenty_Seventeen
@ -79,17 +79,21 @@
if ( is_single() || empty( $audio ) ) { if ( is_single() || empty( $audio ) ) {
/* translators: %s: Name of current post */ /* translators: %s: Name of current post */
the_content( sprintf( the_content(
sprintf(
__( 'Continue reading<span class="screen-reader-text"> "%s"</span>', 'twentyseventeen' ), __( 'Continue reading<span class="screen-reader-text"> "%s"</span>', 'twentyseventeen' ),
get_the_title() get_the_title()
) ); )
);
wp_link_pages( array( wp_link_pages(
array(
'before' => '<div class="page-links">' . __( 'Pages:', 'twentyseventeen' ), 'before' => '<div class="page-links">' . __( 'Pages:', 'twentyseventeen' ),
'after' => '</div>', 'after' => '</div>',
'link_before' => '<span class="page-number">', 'link_before' => '<span class="page-number">',
'link_after' => '</span>', 'link_after' => '</span>',
) ); )
);
}; };
?> ?>
@ -102,4 +106,4 @@
} }
?> ?>
</article><!-- #post-## --> </article><!-- #post-<?php the_ID(); ?> -->

View file

@ -4,7 +4,7 @@
* *
* Used in Search Results and for Recent Posts in Front Page panels. * Used in Search Results and for Recent Posts in Front Page panels.
* *
* @link https://codex.wordpress.org/Template_Hierarchy * @link https://developer.wordpress.org/themes/basics/template-hierarchy/
* *
* @package WordPress * @package WordPress
* @subpackage Twenty_Seventeen * @subpackage Twenty_Seventeen
@ -30,17 +30,19 @@
</div><!-- .entry-meta --> </div><!-- .entry-meta -->
<?php endif; ?> <?php endif; ?>
<?php if ( is_front_page() && ! is_home() ) { <?php
if ( is_front_page() && ! is_home() ) {
// The excerpt is being displayed within a front page section, so it's a lower hierarchy than h2. // The excerpt is being displayed within a front page section, so it's a lower hierarchy than h2.
the_title( sprintf( '<h3 class="entry-title"><a href="%s" rel="bookmark">', esc_url( get_permalink() ) ), '</a></h3>' ); the_title( sprintf( '<h3 class="entry-title"><a href="%s" rel="bookmark">', esc_url( get_permalink() ) ), '</a></h3>' );
} else { } else {
the_title( sprintf( '<h2 class="entry-title"><a href="%s" rel="bookmark">', esc_url( get_permalink() ) ), '</a></h2>' ); the_title( sprintf( '<h2 class="entry-title"><a href="%s" rel="bookmark">', esc_url( get_permalink() ) ), '</a></h2>' );
} ?> }
?>
</header><!-- .entry-header --> </header><!-- .entry-header -->
<div class="entry-summary"> <div class="entry-summary">
<?php the_excerpt(); ?> <?php the_excerpt(); ?>
</div><!-- .entry-summary --> </div><!-- .entry-summary -->
</article><!-- #post-## --> </article><!-- #post-<?php the_ID(); ?> -->

View file

@ -2,7 +2,7 @@
/** /**
* Template part for displaying gallery posts * Template part for displaying gallery posts
* *
* @link https://codex.wordpress.org/Template_Hierarchy * @link https://developer.wordpress.org/themes/basics/template-hierarchy/
* *
* @package WordPress * @package WordPress
* @subpackage Twenty_Seventeen * @subpackage Twenty_Seventeen
@ -66,17 +66,21 @@
if ( is_single() || ! get_post_gallery() ) { if ( is_single() || ! get_post_gallery() ) {
/* translators: %s: Name of current post */ /* translators: %s: Name of current post */
the_content( sprintf( the_content(
sprintf(
__( 'Continue reading<span class="screen-reader-text"> "%s"</span>', 'twentyseventeen' ), __( 'Continue reading<span class="screen-reader-text"> "%s"</span>', 'twentyseventeen' ),
get_the_title() get_the_title()
) ); )
);
wp_link_pages( array( wp_link_pages(
array(
'before' => '<div class="page-links">' . __( 'Pages:', 'twentyseventeen' ), 'before' => '<div class="page-links">' . __( 'Pages:', 'twentyseventeen' ),
'after' => '</div>', 'after' => '</div>',
'link_before' => '<span class="page-number">', 'link_before' => '<span class="page-number">',
'link_after' => '</span>', 'link_after' => '</span>',
) ); )
);
}; };
?> ?>
@ -89,4 +93,4 @@
} }
?> ?>
</article><!-- #post-## --> </article><!-- #post-<?php the_ID(); ?> -->

View file

@ -2,7 +2,7 @@
/** /**
* Template part for displaying image posts * Template part for displaying image posts
* *
* @link https://codex.wordpress.org/Template_Hierarchy * @link https://developer.wordpress.org/themes/basics/template-hierarchy/
* *
* @package WordPress * @package WordPress
* @subpackage Twenty_Seventeen * @subpackage Twenty_Seventeen
@ -51,21 +51,26 @@
<div class="entry-content"> <div class="entry-content">
<?php if ( is_single() || '' === get_the_post_thumbnail() ) { <?php
if ( is_single() || '' === get_the_post_thumbnail() ) {
// Only show content if is a single post, or if there's no featured image. // Only show content if is a single post, or if there's no featured image.
/* translators: %s: Name of current post */ /* translators: %s: Name of current post */
the_content( sprintf( the_content(
sprintf(
__( 'Continue reading<span class="screen-reader-text"> "%s"</span>', 'twentyseventeen' ), __( 'Continue reading<span class="screen-reader-text"> "%s"</span>', 'twentyseventeen' ),
get_the_title() get_the_title()
) ); )
);
wp_link_pages( array( wp_link_pages(
array(
'before' => '<div class="page-links">' . __( 'Pages:', 'twentyseventeen' ), 'before' => '<div class="page-links">' . __( 'Pages:', 'twentyseventeen' ),
'after' => '</div>', 'after' => '</div>',
'link_before' => '<span class="page-number">', 'link_before' => '<span class="page-number">',
'link_after' => '</span>', 'link_after' => '</span>',
) ); )
);
}; };
?> ?>
@ -78,4 +83,4 @@
} }
?> ?>
</article><!-- #post-## --> </article><!-- #post-<?php the_ID(); ?> -->

View file

@ -2,7 +2,7 @@
/** /**
* Template part for displaying a message that posts cannot be found * Template part for displaying a message that posts cannot be found
* *
* @link https://codex.wordpress.org/Template_Hierarchy * @link https://developer.wordpress.org/themes/basics/template-hierarchy/
* *
* @package WordPress * @package WordPress
* @subpackage Twenty_Seventeen * @subpackage Twenty_Seventeen
@ -18,7 +18,8 @@
</header> </header>
<div class="page-content"> <div class="page-content">
<?php <?php
if ( is_home() && current_user_can( 'publish_posts' ) ) : ?> if ( is_home() && current_user_can( 'publish_posts' ) ) :
?>
<p><?php printf( __( 'Ready to publish your first post? <a href="%1$s">Get started here</a>.', 'twentyseventeen' ), esc_url( admin_url( 'post-new.php' ) ) ); ?></p> <p><?php printf( __( 'Ready to publish your first post? <a href="%1$s">Get started here</a>.', 'twentyseventeen' ), esc_url( admin_url( 'post-new.php' ) ) ); ?></p>
@ -28,6 +29,7 @@
<?php <?php
get_search_form(); get_search_form();
endif; ?> endif;
?>
</div><!-- .page-content --> </div><!-- .page-content -->
</section><!-- .no-results --> </section><!-- .no-results -->

View file

@ -2,7 +2,7 @@
/** /**
* Template part for displaying video posts * Template part for displaying video posts
* *
* @link https://codex.wordpress.org/Template_Hierarchy * @link https://developer.wordpress.org/themes/basics/template-hierarchy/
* *
* @package WordPress * @package WordPress
* @subpackage Twenty_Seventeen * @subpackage Twenty_Seventeen
@ -78,17 +78,21 @@
if ( is_single() || empty( $video ) ) { if ( is_single() || empty( $video ) ) {
/* translators: %s: Name of current post */ /* translators: %s: Name of current post */
the_content( sprintf( the_content(
sprintf(
__( 'Continue reading<span class="screen-reader-text"> "%s"</span>', 'twentyseventeen' ), __( 'Continue reading<span class="screen-reader-text"> "%s"</span>', 'twentyseventeen' ),
get_the_title() get_the_title()
) ); )
);
wp_link_pages( array( wp_link_pages(
array(
'before' => '<div class="page-links">' . __( 'Pages:', 'twentyseventeen' ), 'before' => '<div class="page-links">' . __( 'Pages:', 'twentyseventeen' ),
'after' => '</div>', 'after' => '</div>',
'link_before' => '<span class="page-number">', 'link_before' => '<span class="page-number">',
'link_after' => '</span>', 'link_after' => '</span>',
) ); )
);
}; };
?> ?>
@ -100,4 +104,4 @@
} }
?> ?>
</article><!-- #post-## --> </article><!-- #post-<?php the_ID(); ?> -->

View file

@ -2,7 +2,7 @@
/** /**
* Template part for displaying posts * Template part for displaying posts
* *
* @link https://codex.wordpress.org/Template_Hierarchy * @link https://developer.wordpress.org/themes/basics/template-hierarchy/
* *
* @package WordPress * @package WordPress
* @subpackage Twenty_Seventeen * @subpackage Twenty_Seventeen
@ -52,17 +52,21 @@
<div class="entry-content"> <div class="entry-content">
<?php <?php
/* translators: %s: Name of current post */ /* translators: %s: Name of current post */
the_content( sprintf( the_content(
sprintf(
__( 'Continue reading<span class="screen-reader-text"> "%s"</span>', 'twentyseventeen' ), __( 'Continue reading<span class="screen-reader-text"> "%s"</span>', 'twentyseventeen' ),
get_the_title() get_the_title()
) ); )
);
wp_link_pages( array( wp_link_pages(
array(
'before' => '<div class="page-links">' . __( 'Pages:', 'twentyseventeen' ), 'before' => '<div class="page-links">' . __( 'Pages:', 'twentyseventeen' ),
'after' => '</div>', 'after' => '</div>',
'link_before' => '<span class="page-number">', 'link_before' => '<span class="page-number">',
'link_after' => '</span>', 'link_after' => '</span>',
) ); )
);
?> ?>
</div><!-- .entry-content --> </div><!-- .entry-content -->
@ -72,4 +76,4 @@
} }
?> ?>
</article><!-- #post-## --> </article><!-- #post-<?php the_ID(); ?> -->

View file

@ -9,7 +9,7 @@
* new template file for each one. For example, tag.php (Tag archives), * new template file for each one. For example, tag.php (Tag archives),
* category.php (Category archives), author.php (Author archives), etc. * category.php (Category archives), author.php (Author archives), etc.
* *
* @link https://codex.wordpress.org/Template_Hierarchy * @link https://developer.wordpress.org/themes/basics/template-hierarchy/
* *
* @package WordPress * @package WordPress
* @subpackage Twenty_Sixteen * @subpackage Twenty_Sixteen
@ -32,7 +32,8 @@ get_header(); ?>
<?php <?php
// Start the Loop. // Start the Loop.
while ( have_posts() ) : the_post(); while ( have_posts() ) :
the_post();
/* /*
* Include the Post-Format-specific template for the content. * Include the Post-Format-specific template for the content.
@ -45,11 +46,13 @@ get_header(); ?>
endwhile; endwhile;
// Previous/next page navigation. // Previous/next page navigation.
the_posts_pagination( array( the_posts_pagination(
array(
'prev_text' => __( 'Previous page', 'twentysixteen' ), 'prev_text' => __( 'Previous page', 'twentysixteen' ),
'next_text' => __( 'Next page', 'twentysixteen' ), 'next_text' => __( 'Next page', 'twentysixteen' ),
'before_page_number' => '<span class="meta-nav screen-reader-text">' . __( 'Page', 'twentysixteen' ) . ' </span>', 'before_page_number' => '<span class="meta-nav screen-reader-text">' . __( 'Page', 'twentysixteen' ) . ' </span>',
) ); )
);
// If no content, include the "No posts found" template. // If no content, include the "No posts found" template.
else : else :

View file

@ -50,11 +50,13 @@ if ( post_password_required() ) {
<ol class="comment-list"> <ol class="comment-list">
<?php <?php
wp_list_comments( array( wp_list_comments(
array(
'style' => 'ol', 'style' => 'ol',
'short_ping' => true, 'short_ping' => true,
'avatar_size' => 42, 'avatar_size' => 42,
) ); )
);
?> ?>
</ol><!-- .comment-list --> </ol><!-- .comment-list -->
@ -70,10 +72,12 @@ if ( post_password_required() ) {
<?php endif; ?> <?php endif; ?>
<?php <?php
comment_form( array( comment_form(
array(
'title_reply_before' => '<h2 id="reply-title" class="comment-reply-title">', 'title_reply_before' => '<h2 id="reply-title" class="comment-reply-title">',
'title_reply_after' => '</h2>', 'title_reply_after' => '</h2>',
) ); )
);
?> ?>
</div><!-- .comments-area --> </div><!-- .comments-area -->

View file

@ -16,10 +16,12 @@
<?php if ( has_nav_menu( 'primary' ) ) : ?> <?php if ( has_nav_menu( 'primary' ) ) : ?>
<nav class="main-navigation" role="navigation" aria-label="<?php esc_attr_e( 'Footer Primary Menu', 'twentysixteen' ); ?>"> <nav class="main-navigation" role="navigation" aria-label="<?php esc_attr_e( 'Footer Primary Menu', 'twentysixteen' ); ?>">
<?php <?php
wp_nav_menu( array( wp_nav_menu(
array(
'theme_location' => 'primary', 'theme_location' => 'primary',
'menu_class' => 'primary-menu', 'menu_class' => 'primary-menu',
) ); )
);
?> ?>
</nav><!-- .main-navigation --> </nav><!-- .main-navigation -->
<?php endif; ?> <?php endif; ?>
@ -27,13 +29,15 @@
<?php if ( has_nav_menu( 'social' ) ) : ?> <?php if ( has_nav_menu( 'social' ) ) : ?>
<nav class="social-navigation" role="navigation" aria-label="<?php esc_attr_e( 'Footer Social Links Menu', 'twentysixteen' ); ?>"> <nav class="social-navigation" role="navigation" aria-label="<?php esc_attr_e( 'Footer Social Links Menu', 'twentysixteen' ); ?>">
<?php <?php
wp_nav_menu( array( wp_nav_menu(
array(
'theme_location' => 'social', 'theme_location' => 'social',
'menu_class' => 'social-links-menu', 'menu_class' => 'social-links-menu',
'depth' => 1, 'depth' => 1,
'link_before' => '<span class="screen-reader-text">', 'link_before' => '<span class="screen-reader-text">',
'link_after' => '</span>', 'link_after' => '</span>',
) ); )
);
?> ?>
</nav><!-- .social-navigation --> </nav><!-- .social-navigation -->
<?php endif; ?> <?php endif; ?>

View file

@ -12,7 +12,7 @@
* the parent theme's file, so the child theme functions would be used. * the parent theme's file, so the child theme functions would be used.
* *
* @link https://codex.wordpress.org/Theme_Development * @link https://codex.wordpress.org/Theme_Development
* @link https://codex.wordpress.org/Child_Themes * @link https://developer.wordpress.org/themes/advanced-topics/child-themes/
* *
* Functions that are not pluggable (not wrapped in function_exists()) are * Functions that are not pluggable (not wrapped in function_exists()) are
* instead attached to a filter or action hook. * instead attached to a filter or action hook.
@ -33,7 +33,7 @@ if ( version_compare( $GLOBALS['wp_version'], '4.4-alpha', '<' ) ) {
} }
if ( ! function_exists( 'twentysixteen_setup' ) ) : if ( ! function_exists( 'twentysixteen_setup' ) ) :
/** /**
* Sets up theme defaults and registers support for various WordPress features. * Sets up theme defaults and registers support for various WordPress features.
* *
* Note that this function is hooked into the after_setup_theme hook, which * Note that this function is hooked into the after_setup_theme hook, which
@ -44,7 +44,7 @@ if ( ! function_exists( 'twentysixteen_setup' ) ) :
* *
* @since Twenty Sixteen 1.0 * @since Twenty Sixteen 1.0
*/ */
function twentysixteen_setup() { function twentysixteen_setup() {
/* /*
* Make theme available for translation. * Make theme available for translation.
* Translations can be filed at WordPress.org. See: https://translate.wordpress.org/projects/wp-themes/twentysixteen * Translations can be filed at WordPress.org. See: https://translate.wordpress.org/projects/wp-themes/twentysixteen
@ -69,44 +69,54 @@ function twentysixteen_setup() {
* *
* @since Twenty Sixteen 1.2 * @since Twenty Sixteen 1.2
*/ */
add_theme_support( 'custom-logo', array( add_theme_support(
'custom-logo',
array(
'height' => 240, 'height' => 240,
'width' => 240, 'width' => 240,
'flex-height' => true, 'flex-height' => true,
) ); )
);
/* /*
* Enable support for Post Thumbnails on posts and pages. * Enable support for Post Thumbnails on posts and pages.
* *
* @link https://codex.wordpress.org/Function_Reference/add_theme_support#Post_Thumbnails * @link https://developer.wordpress.org/reference/functions/add_theme_support/#post-thumbnails
*/ */
add_theme_support( 'post-thumbnails' ); add_theme_support( 'post-thumbnails' );
set_post_thumbnail_size( 1200, 9999 ); set_post_thumbnail_size( 1200, 9999 );
// This theme uses wp_nav_menu() in two locations. // This theme uses wp_nav_menu() in two locations.
register_nav_menus( array( register_nav_menus(
array(
'primary' => __( 'Primary Menu', 'twentysixteen' ), 'primary' => __( 'Primary Menu', 'twentysixteen' ),
'social' => __( 'Social Links Menu', 'twentysixteen' ), 'social' => __( 'Social Links Menu', 'twentysixteen' ),
) ); )
);
/* /*
* Switch default core markup for search form, comment form, and comments * Switch default core markup for search form, comment form, and comments
* to output valid HTML5. * to output valid HTML5.
*/ */
add_theme_support( 'html5', array( add_theme_support(
'html5',
array(
'search-form', 'search-form',
'comment-form', 'comment-form',
'comment-list', 'comment-list',
'gallery', 'gallery',
'caption', 'caption',
) ); )
);
/* /*
* Enable support for Post Formats. * Enable support for Post Formats.
* *
* See: https://codex.wordpress.org/Post_Formats * See: https://codex.wordpress.org/Post_Formats
*/ */
add_theme_support( 'post-formats', array( add_theme_support(
'post-formats',
array(
'aside', 'aside',
'image', 'image',
'video', 'video',
@ -116,7 +126,8 @@ function twentysixteen_setup() {
'status', 'status',
'audio', 'audio',
'chat', 'chat',
) ); )
);
/* /*
* This theme styles the visual editor to resemble the theme style, * This theme styles the visual editor to resemble the theme style,
@ -134,7 +145,9 @@ function twentysixteen_setup() {
add_theme_support( 'responsive-embeds' ); add_theme_support( 'responsive-embeds' );
// Add support for custom color scheme. // Add support for custom color scheme.
add_theme_support( 'editor-color-palette', array( add_theme_support(
'editor-color-palette',
array(
array( array(
'name' => __( 'Dark Gray', 'twentysixteen' ), 'name' => __( 'Dark Gray', 'twentysixteen' ),
'slug' => 'dark-gray', 'slug' => 'dark-gray',
@ -195,11 +208,12 @@ function twentysixteen_setup() {
'slug' => 'yellow', 'slug' => 'yellow',
'color' => '#ffef8e', 'color' => '#ffef8e',
), ),
) ); )
);
// Indicate widget sidebars can use selective refresh in the Customizer. // Indicate widget sidebars can use selective refresh in the Customizer.
add_theme_support( 'customize-selective-refresh-widgets' ); add_theme_support( 'customize-selective-refresh-widgets' );
} }
endif; // twentysixteen_setup endif; // twentysixteen_setup
add_action( 'after_setup_theme', 'twentysixteen_setup' ); add_action( 'after_setup_theme', 'twentysixteen_setup' );
@ -217,6 +231,27 @@ function twentysixteen_content_width() {
} }
add_action( 'after_setup_theme', 'twentysixteen_content_width', 0 ); add_action( 'after_setup_theme', 'twentysixteen_content_width', 0 );
/**
* Add preconnect for Google Fonts.
*
* @since Twenty Sixteen 1.6
*
* @param array $urls URLs to print for resource hints.
* @param string $relation_type The relation type the URLs are printed.
* @return array $urls URLs to print for resource hints.
*/
function twentysixteen_resource_hints( $urls, $relation_type ) {
if ( wp_style_is( 'twentysixteen-fonts', 'queue' ) && 'preconnect' === $relation_type ) {
$urls[] = array(
'href' => 'https://fonts.gstatic.com',
'crossorigin',
);
}
return $urls;
}
add_filter( 'wp_resource_hints', 'twentysixteen_resource_hints', 10, 2 );
/** /**
* Registers a widget area. * Registers a widget area.
* *
@ -225,7 +260,8 @@ add_action( 'after_setup_theme', 'twentysixteen_content_width', 0 );
* @since Twenty Sixteen 1.0 * @since Twenty Sixteen 1.0
*/ */
function twentysixteen_widgets_init() { function twentysixteen_widgets_init() {
register_sidebar( array( register_sidebar(
array(
'name' => __( 'Sidebar', 'twentysixteen' ), 'name' => __( 'Sidebar', 'twentysixteen' ),
'id' => 'sidebar-1', 'id' => 'sidebar-1',
'description' => __( 'Add widgets here to appear in your sidebar.', 'twentysixteen' ), 'description' => __( 'Add widgets here to appear in your sidebar.', 'twentysixteen' ),
@ -233,9 +269,11 @@ function twentysixteen_widgets_init() {
'after_widget' => '</section>', 'after_widget' => '</section>',
'before_title' => '<h2 class="widget-title">', 'before_title' => '<h2 class="widget-title">',
'after_title' => '</h2>', 'after_title' => '</h2>',
) ); )
);
register_sidebar( array( register_sidebar(
array(
'name' => __( 'Content Bottom 1', 'twentysixteen' ), 'name' => __( 'Content Bottom 1', 'twentysixteen' ),
'id' => 'sidebar-2', 'id' => 'sidebar-2',
'description' => __( 'Appears at the bottom of the content on posts and pages.', 'twentysixteen' ), 'description' => __( 'Appears at the bottom of the content on posts and pages.', 'twentysixteen' ),
@ -243,9 +281,11 @@ function twentysixteen_widgets_init() {
'after_widget' => '</section>', 'after_widget' => '</section>',
'before_title' => '<h2 class="widget-title">', 'before_title' => '<h2 class="widget-title">',
'after_title' => '</h2>', 'after_title' => '</h2>',
) ); )
);
register_sidebar( array( register_sidebar(
array(
'name' => __( 'Content Bottom 2', 'twentysixteen' ), 'name' => __( 'Content Bottom 2', 'twentysixteen' ),
'id' => 'sidebar-3', 'id' => 'sidebar-3',
'description' => __( 'Appears at the bottom of the content on posts and pages.', 'twentysixteen' ), 'description' => __( 'Appears at the bottom of the content on posts and pages.', 'twentysixteen' ),
@ -253,12 +293,13 @@ function twentysixteen_widgets_init() {
'after_widget' => '</section>', 'after_widget' => '</section>',
'before_title' => '<h2 class="widget-title">', 'before_title' => '<h2 class="widget-title">',
'after_title' => '</h2>', 'after_title' => '</h2>',
) ); )
);
} }
add_action( 'widgets_init', 'twentysixteen_widgets_init' ); add_action( 'widgets_init', 'twentysixteen_widgets_init' );
if ( ! function_exists( 'twentysixteen_fonts_url' ) ) : if ( ! function_exists( 'twentysixteen_fonts_url' ) ) :
/** /**
* Register Google fonts for Twenty Sixteen. * Register Google fonts for Twenty Sixteen.
* *
* Create your own twentysixteen_fonts_url() function to override in a child theme. * Create your own twentysixteen_fonts_url() function to override in a child theme.
@ -267,7 +308,7 @@ if ( ! function_exists( 'twentysixteen_fonts_url' ) ) :
* *
* @return string Google fonts URL for the theme. * @return string Google fonts URL for the theme.
*/ */
function twentysixteen_fonts_url() { function twentysixteen_fonts_url() {
$fonts_url = ''; $fonts_url = '';
$fonts = array(); $fonts = array();
$subsets = 'latin,latin-ext'; $subsets = 'latin,latin-ext';
@ -288,14 +329,17 @@ function twentysixteen_fonts_url() {
} }
if ( $fonts ) { if ( $fonts ) {
$fonts_url = add_query_arg( array( $fonts_url = add_query_arg(
array(
'family' => urlencode( implode( '|', $fonts ) ), 'family' => urlencode( implode( '|', $fonts ) ),
'subset' => urlencode( $subsets ), 'subset' => urlencode( $subsets ),
), 'https://fonts.googleapis.com/css' ); ),
'https://fonts.googleapis.com/css'
);
} }
return $fonts_url; return $fonts_url;
} }
endif; endif;
/** /**
@ -356,10 +400,14 @@ function twentysixteen_scripts() {
wp_enqueue_script( 'twentysixteen-script', get_template_directory_uri() . '/js/functions.js', array( 'jquery' ), '20181230', true ); wp_enqueue_script( 'twentysixteen-script', get_template_directory_uri() . '/js/functions.js', array( 'jquery' ), '20181230', true );
wp_localize_script( 'twentysixteen-script', 'screenReaderText', array( wp_localize_script(
'twentysixteen-script',
'screenReaderText',
array(
'expand' => __( 'expand child menu', 'twentysixteen' ), 'expand' => __( 'expand child menu', 'twentysixteen' ),
'collapse' => __( 'collapse child menu', 'twentysixteen' ), 'collapse' => __( 'collapse child menu', 'twentysixteen' ),
) ); )
);
} }
add_action( 'wp_enqueue_scripts', 'twentysixteen_scripts' ); add_action( 'wp_enqueue_scripts', 'twentysixteen_scripts' );
@ -422,10 +470,10 @@ function twentysixteen_hex2rgb( $color ) {
$color = trim( $color, '#' ); $color = trim( $color, '#' );
if ( strlen( $color ) === 3 ) { if ( strlen( $color ) === 3 ) {
$r = hexdec( substr( $color, 0, 1 ).substr( $color, 0, 1 ) ); $r = hexdec( substr( $color, 0, 1 ) . substr( $color, 0, 1 ) );
$g = hexdec( substr( $color, 1, 1 ).substr( $color, 1, 1 ) ); $g = hexdec( substr( $color, 1, 1 ) . substr( $color, 1, 1 ) );
$b = hexdec( substr( $color, 2, 1 ).substr( $color, 2, 1 ) ); $b = hexdec( substr( $color, 2, 1 ) . substr( $color, 2, 1 ) );
} else if ( strlen( $color ) === 6 ) { } elseif ( strlen( $color ) === 6 ) {
$r = hexdec( substr( $color, 0, 2 ) ); $r = hexdec( substr( $color, 0, 2 ) );
$g = hexdec( substr( $color, 2, 2 ) ); $g = hexdec( substr( $color, 2, 2 ) );
$b = hexdec( substr( $color, 4, 2 ) ); $b = hexdec( substr( $color, 4, 2 ) );
@ -433,7 +481,11 @@ function twentysixteen_hex2rgb( $color ) {
return array(); return array();
} }
return array( 'red' => $r, 'green' => $g, 'blue' => $b ); return array(
'red' => $r,
'green' => $g,
'blue' => $b,
);
} }
/** /**
@ -478,7 +530,7 @@ function twentysixteen_content_image_sizes_attr( $sizes, $size ) {
return $sizes; return $sizes;
} }
add_filter( 'wp_calculate_image_sizes', 'twentysixteen_content_image_sizes_attr', 10 , 2 ); add_filter( 'wp_calculate_image_sizes', 'twentysixteen_content_image_sizes_attr', 10, 2 );
/** /**
* Add custom image sizes attribute to enhance responsive image functionality * Add custom image sizes attribute to enhance responsive image functionality
@ -501,7 +553,7 @@ function twentysixteen_post_thumbnail_sizes_attr( $attr, $attachment, $size ) {
} }
return $attr; return $attr;
} }
add_filter( 'wp_get_attachment_image_attributes', 'twentysixteen_post_thumbnail_sizes_attr', 10 , 3 ); add_filter( 'wp_get_attachment_image_attributes', 'twentysixteen_post_thumbnail_sizes_attr', 10, 3 );
/** /**
* Modifies tag cloud widget arguments to display all tags in the same font size * Modifies tag cloud widget arguments to display all tags in the same font size

View file

@ -16,12 +16,13 @@
<meta name="viewport" content="width=device-width, initial-scale=1"> <meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="profile" href="http://gmpg.org/xfn/11"> <link rel="profile" href="http://gmpg.org/xfn/11">
<?php if ( is_singular() && pings_open( get_queried_object() ) ) : ?> <?php if ( is_singular() && pings_open( get_queried_object() ) ) : ?>
<link rel="pingback" href="<?php bloginfo( 'pingback_url' ); ?>"> <link rel="pingback" href="<?php echo esc_url( get_bloginfo( 'pingback_url' ) ); ?>">
<?php endif; ?> <?php endif; ?>
<?php wp_head(); ?> <?php wp_head(); ?>
</head> </head>
<body <?php body_class(); ?>> <body <?php body_class(); ?>>
<?php wp_body_open(); ?>
<div id="page" class="site"> <div id="page" class="site">
<div class="site-inner"> <div class="site-inner">
<a class="skip-link screen-reader-text" href="#content"><?php _e( 'Skip to content', 'twentysixteen' ); ?></a> <a class="skip-link screen-reader-text" href="#content"><?php _e( 'Skip to content', 'twentysixteen' ); ?></a>
@ -35,10 +36,12 @@
<h1 class="site-title"><a href="<?php echo esc_url( home_url( '/' ) ); ?>" rel="home"><?php bloginfo( 'name' ); ?></a></h1> <h1 class="site-title"><a href="<?php echo esc_url( home_url( '/' ) ); ?>" rel="home"><?php bloginfo( 'name' ); ?></a></h1>
<?php else : ?> <?php else : ?>
<p class="site-title"><a href="<?php echo esc_url( home_url( '/' ) ); ?>" rel="home"><?php bloginfo( 'name' ); ?></a></p> <p class="site-title"><a href="<?php echo esc_url( home_url( '/' ) ); ?>" rel="home"><?php bloginfo( 'name' ); ?></a></p>
<?php endif; <?php
endif;
$description = get_bloginfo( 'description', 'display' ); $description = get_bloginfo( 'description', 'display' );
if ( $description || is_customize_preview() ) : ?> if ( $description || is_customize_preview() ) :
?>
<p class="site-description"><?php echo $description; ?></p> <p class="site-description"><?php echo $description; ?></p>
<?php endif; ?> <?php endif; ?>
</div><!-- .site-branding --> </div><!-- .site-branding -->
@ -50,10 +53,12 @@
<?php if ( has_nav_menu( 'primary' ) ) : ?> <?php if ( has_nav_menu( 'primary' ) ) : ?>
<nav id="site-navigation" class="main-navigation" role="navigation" aria-label="<?php esc_attr_e( 'Primary Menu', 'twentysixteen' ); ?>"> <nav id="site-navigation" class="main-navigation" role="navigation" aria-label="<?php esc_attr_e( 'Primary Menu', 'twentysixteen' ); ?>">
<?php <?php
wp_nav_menu( array( wp_nav_menu(
array(
'theme_location' => 'primary', 'theme_location' => 'primary',
'menu_class' => 'primary-menu', 'menu_class' => 'primary-menu',
) ); )
);
?> ?>
</nav><!-- .main-navigation --> </nav><!-- .main-navigation -->
<?php endif; ?> <?php endif; ?>
@ -61,13 +66,15 @@
<?php if ( has_nav_menu( 'social' ) ) : ?> <?php if ( has_nav_menu( 'social' ) ) : ?>
<nav id="social-navigation" class="social-navigation" role="navigation" aria-label="<?php esc_attr_e( 'Social Links Menu', 'twentysixteen' ); ?>"> <nav id="social-navigation" class="social-navigation" role="navigation" aria-label="<?php esc_attr_e( 'Social Links Menu', 'twentysixteen' ); ?>">
<?php <?php
wp_nav_menu( array( wp_nav_menu(
array(
'theme_location' => 'social', 'theme_location' => 'social',
'menu_class' => 'social-links-menu', 'menu_class' => 'social-links-menu',
'depth' => 1, 'depth' => 1,
'link_before' => '<span class="screen-reader-text">', 'link_before' => '<span class="screen-reader-text">',
'link_after' => '</span>', 'link_after' => '</span>',
) ); )
);
?> ?>
</nav><!-- .social-navigation --> </nav><!-- .social-navigation -->
<?php endif; ?> <?php endif; ?>

View file

@ -14,7 +14,8 @@ get_header(); ?>
<?php <?php
// Start the loop. // Start the loop.
while ( have_posts() ) : the_post(); while ( have_posts() ) :
the_post();
?> ?>
<article id="post-<?php the_ID(); ?>" <?php post_class(); ?>> <article id="post-<?php the_ID(); ?>" <?php post_class(); ?>>
@ -52,14 +53,16 @@ get_header(); ?>
<?php <?php
the_content(); the_content();
wp_link_pages( array( wp_link_pages(
array(
'before' => '<div class="page-links"><span class="page-links-title">' . __( 'Pages:', 'twentysixteen' ) . '</span>', 'before' => '<div class="page-links"><span class="page-links-title">' . __( 'Pages:', 'twentysixteen' ) . '</span>',
'after' => '</div>', 'after' => '</div>',
'link_before' => '<span>', 'link_before' => '<span>',
'link_after' => '</span>', 'link_after' => '</span>',
'pagelink' => '<span class="screen-reader-text">' . __( 'Page', 'twentysixteen' ) . ' </span>%', 'pagelink' => '<span class="screen-reader-text">' . __( 'Page', 'twentysixteen' ) . ' </span>%',
'separator' => '<span class="screen-reader-text">, </span>', 'separator' => '<span class="screen-reader-text">, </span>',
) ); )
);
?> ?>
</div><!-- .entry-content --> </div><!-- .entry-content -->
@ -69,7 +72,8 @@ get_header(); ?>
// Retrieve attachment metadata. // Retrieve attachment metadata.
$metadata = wp_get_attachment_metadata(); $metadata = wp_get_attachment_metadata();
if ( $metadata ) { if ( $metadata ) {
printf( '<span class="full-size-link"><span class="screen-reader-text">%1$s </span><a href="%2$s">%3$s &times; %4$s</a></span>', printf(
'<span class="full-size-link"><span class="screen-reader-text">%1$s </span><a href="%2$s">%3$s &times; %4$s</a></span>',
esc_html_x( 'Full size', 'Used before full size attachment link.', 'twentysixteen' ), esc_html_x( 'Full size', 'Used before full size attachment link.', 'twentysixteen' ),
esc_url( wp_get_attachment_url() ), esc_url( wp_get_attachment_url() ),
absint( $metadata['width'] ), absint( $metadata['width'] ),
@ -89,7 +93,7 @@ get_header(); ?>
); );
?> ?>
</footer><!-- .entry-footer --> </footer><!-- .entry-footer -->
</article><!-- #post-## --> </article><!-- #post-<?php the_ID(); ?> -->
<?php <?php
// If comments are open or we have at least one comment, load up the comment template. // If comments are open or we have at least one comment, load up the comment template.
@ -98,9 +102,11 @@ get_header(); ?>
} }
// Parent post navigation. // Parent post navigation.
the_post_navigation( array( the_post_navigation(
array(
'prev_text' => _x( '<span class="meta-nav">Published in</span><span class="post-title">%title</span>', 'Parent post link', 'twentysixteen' ), 'prev_text' => _x( '<span class="meta-nav">Published in</span><span class="post-title">%title</span>', 'Parent post link', 'twentysixteen' ),
) ); )
);
// End the loop. // End the loop.
endwhile; endwhile;
?> ?>

View file

@ -50,9 +50,13 @@ function twentysixteen_upgrade_notice() {
* @global string $wp_version WordPress version. * @global string $wp_version WordPress version.
*/ */
function twentysixteen_customize() { function twentysixteen_customize() {
wp_die( sprintf( __( 'Twenty Sixteen requires at least WordPress version 4.4. You are running version %s. Please upgrade and try again.', 'twentysixteen' ), $GLOBALS['wp_version'] ), '', array( wp_die(
sprintf( __( 'Twenty Sixteen requires at least WordPress version 4.4. You are running version %s. Please upgrade and try again.', 'twentysixteen' ), $GLOBALS['wp_version'] ),
'',
array(
'back_link' => true, 'back_link' => true,
) ); )
);
} }
add_action( 'load-customize.php', 'twentysixteen_customize' ); add_action( 'load-customize.php', 'twentysixteen_customize' );

View file

@ -30,9 +30,15 @@ function twentysixteen_custom_header_and_background() {
* @type string $default-color Default color of the background. * @type string $default-color Default color of the background.
* } * }
*/ */
add_theme_support( 'custom-background', apply_filters( 'twentysixteen_custom_background_args', array( add_theme_support(
'custom-background',
apply_filters(
'twentysixteen_custom_background_args',
array(
'default-color' => $default_background_color, 'default-color' => $default_background_color,
) ) ); )
)
);
/** /**
* Filter the arguments used when adding 'custom-header' support in Twenty Sixteen. * Filter the arguments used when adding 'custom-header' support in Twenty Sixteen.
@ -50,18 +56,24 @@ function twentysixteen_custom_header_and_background() {
* displayed on the blog. * displayed on the blog.
* } * }
*/ */
add_theme_support( 'custom-header', apply_filters( 'twentysixteen_custom_header_args', array( add_theme_support(
'custom-header',
apply_filters(
'twentysixteen_custom_header_args',
array(
'default-text-color' => $default_text_color, 'default-text-color' => $default_text_color,
'width' => 1200, 'width' => 1200,
'height' => 280, 'height' => 280,
'flex-height' => true, 'flex-height' => true,
'wp-head-callback' => 'twentysixteen_header_style', 'wp-head-callback' => 'twentysixteen_header_style',
) ) ); )
)
);
} }
add_action( 'after_setup_theme', 'twentysixteen_custom_header_and_background' ); add_action( 'after_setup_theme', 'twentysixteen_custom_header_and_background' );
if ( ! function_exists( 'twentysixteen_header_style' ) ) : if ( ! function_exists( 'twentysixteen_header_style' ) ) :
/** /**
* Styles the header text displayed on the site. * Styles the header text displayed on the site.
* *
* Create your own twentysixteen_header_style() function to override in a child theme. * Create your own twentysixteen_header_style() function to override in a child theme.
@ -70,7 +82,7 @@ if ( ! function_exists( 'twentysixteen_header_style' ) ) :
* *
* @see twentysixteen_custom_header_and_background(). * @see twentysixteen_custom_header_and_background().
*/ */
function twentysixteen_header_style() { function twentysixteen_header_style() {
// If the header text option is untouched, let's bail. // If the header text option is untouched, let's bail.
if ( display_header_text() ) { if ( display_header_text() ) {
return; return;
@ -90,7 +102,7 @@ function twentysixteen_header_style() {
} }
</style> </style>
<?php <?php
} }
endif; // twentysixteen_header_style endif; // twentysixteen_header_style
/** /**
@ -107,83 +119,131 @@ function twentysixteen_customize_register( $wp_customize ) {
$wp_customize->get_setting( 'blogdescription' )->transport = 'postMessage'; $wp_customize->get_setting( 'blogdescription' )->transport = 'postMessage';
if ( isset( $wp_customize->selective_refresh ) ) { if ( isset( $wp_customize->selective_refresh ) ) {
$wp_customize->selective_refresh->add_partial( 'blogname', array( $wp_customize->selective_refresh->add_partial(
'blogname',
array(
'selector' => '.site-title a', 'selector' => '.site-title a',
'container_inclusive' => false, 'container_inclusive' => false,
'render_callback' => 'twentysixteen_customize_partial_blogname', 'render_callback' => 'twentysixteen_customize_partial_blogname',
) ); )
$wp_customize->selective_refresh->add_partial( 'blogdescription', array( );
$wp_customize->selective_refresh->add_partial(
'blogdescription',
array(
'selector' => '.site-description', 'selector' => '.site-description',
'container_inclusive' => false, 'container_inclusive' => false,
'render_callback' => 'twentysixteen_customize_partial_blogdescription', 'render_callback' => 'twentysixteen_customize_partial_blogdescription',
) ); )
);
} }
// Add color scheme setting and control. // Add color scheme setting and control.
$wp_customize->add_setting( 'color_scheme', array( $wp_customize->add_setting(
'color_scheme',
array(
'default' => 'default', 'default' => 'default',
'sanitize_callback' => 'twentysixteen_sanitize_color_scheme', 'sanitize_callback' => 'twentysixteen_sanitize_color_scheme',
'transport' => 'postMessage', 'transport' => 'postMessage',
) ); )
);
$wp_customize->add_control( 'color_scheme', array( $wp_customize->add_control(
'color_scheme',
array(
'label' => __( 'Base Color Scheme', 'twentysixteen' ), 'label' => __( 'Base Color Scheme', 'twentysixteen' ),
'section' => 'colors', 'section' => 'colors',
'type' => 'select', 'type' => 'select',
'choices' => twentysixteen_get_color_scheme_choices(), 'choices' => twentysixteen_get_color_scheme_choices(),
'priority' => 1, 'priority' => 1,
) ); )
);
// Add page background color setting and control. // Add page background color setting and control.
$wp_customize->add_setting( 'page_background_color', array( $wp_customize->add_setting(
'page_background_color',
array(
'default' => $color_scheme[1], 'default' => $color_scheme[1],
'sanitize_callback' => 'sanitize_hex_color', 'sanitize_callback' => 'sanitize_hex_color',
'transport' => 'postMessage', 'transport' => 'postMessage',
) ); )
);
$wp_customize->add_control( new WP_Customize_Color_Control( $wp_customize, 'page_background_color', array( $wp_customize->add_control(
new WP_Customize_Color_Control(
$wp_customize,
'page_background_color',
array(
'label' => __( 'Page Background Color', 'twentysixteen' ), 'label' => __( 'Page Background Color', 'twentysixteen' ),
'section' => 'colors', 'section' => 'colors',
) ) ); )
)
);
// Remove the core header textcolor control, as it shares the main text color. // Remove the core header textcolor control, as it shares the main text color.
$wp_customize->remove_control( 'header_textcolor' ); $wp_customize->remove_control( 'header_textcolor' );
// Add link color setting and control. // Add link color setting and control.
$wp_customize->add_setting( 'link_color', array( $wp_customize->add_setting(
'link_color',
array(
'default' => $color_scheme[2], 'default' => $color_scheme[2],
'sanitize_callback' => 'sanitize_hex_color', 'sanitize_callback' => 'sanitize_hex_color',
'transport' => 'postMessage', 'transport' => 'postMessage',
) ); )
);
$wp_customize->add_control( new WP_Customize_Color_Control( $wp_customize, 'link_color', array( $wp_customize->add_control(
new WP_Customize_Color_Control(
$wp_customize,
'link_color',
array(
'label' => __( 'Link Color', 'twentysixteen' ), 'label' => __( 'Link Color', 'twentysixteen' ),
'section' => 'colors', 'section' => 'colors',
) ) ); )
)
);
// Add main text color setting and control. // Add main text color setting and control.
$wp_customize->add_setting( 'main_text_color', array( $wp_customize->add_setting(
'main_text_color',
array(
'default' => $color_scheme[3], 'default' => $color_scheme[3],
'sanitize_callback' => 'sanitize_hex_color', 'sanitize_callback' => 'sanitize_hex_color',
'transport' => 'postMessage', 'transport' => 'postMessage',
) ); )
);
$wp_customize->add_control( new WP_Customize_Color_Control( $wp_customize, 'main_text_color', array( $wp_customize->add_control(
new WP_Customize_Color_Control(
$wp_customize,
'main_text_color',
array(
'label' => __( 'Main Text Color', 'twentysixteen' ), 'label' => __( 'Main Text Color', 'twentysixteen' ),
'section' => 'colors', 'section' => 'colors',
) ) ); )
)
);
// Add secondary text color setting and control. // Add secondary text color setting and control.
$wp_customize->add_setting( 'secondary_text_color', array( $wp_customize->add_setting(
'secondary_text_color',
array(
'default' => $color_scheme[4], 'default' => $color_scheme[4],
'sanitize_callback' => 'sanitize_hex_color', 'sanitize_callback' => 'sanitize_hex_color',
'transport' => 'postMessage', 'transport' => 'postMessage',
) ); )
);
$wp_customize->add_control( new WP_Customize_Color_Control( $wp_customize, 'secondary_text_color', array( $wp_customize->add_control(
new WP_Customize_Color_Control(
$wp_customize,
'secondary_text_color',
array(
'label' => __( 'Secondary Text Color', 'twentysixteen' ), 'label' => __( 'Secondary Text Color', 'twentysixteen' ),
'section' => 'colors', 'section' => 'colors',
) ) ); )
)
);
} }
add_action( 'customize_register', 'twentysixteen_customize_register', 11 ); add_action( 'customize_register', 'twentysixteen_customize_register', 11 );
@ -248,7 +308,9 @@ function twentysixteen_get_color_schemes() {
* } * }
* } * }
*/ */
return apply_filters( 'twentysixteen_color_schemes', array( return apply_filters(
'twentysixteen_color_schemes',
array(
'default' => array( 'default' => array(
'label' => __( 'Default', 'twentysixteen' ), 'label' => __( 'Default', 'twentysixteen' ),
'colors' => array( 'colors' => array(
@ -299,11 +361,12 @@ function twentysixteen_get_color_schemes() {
'#5b4d3e', '#5b4d3e',
), ),
), ),
) ); )
);
} }
if ( ! function_exists( 'twentysixteen_get_color_scheme' ) ) : if ( ! function_exists( 'twentysixteen_get_color_scheme' ) ) :
/** /**
* Retrieves the current Twenty Sixteen color scheme. * Retrieves the current Twenty Sixteen color scheme.
* *
* Create your own twentysixteen_get_color_scheme() function to override in a child theme. * Create your own twentysixteen_get_color_scheme() function to override in a child theme.
@ -312,7 +375,7 @@ if ( ! function_exists( 'twentysixteen_get_color_scheme' ) ) :
* *
* @return array An associative array of either the current or default color scheme HEX values. * @return array An associative array of either the current or default color scheme HEX values.
*/ */
function twentysixteen_get_color_scheme() { function twentysixteen_get_color_scheme() {
$color_scheme_option = get_theme_mod( 'color_scheme', 'default' ); $color_scheme_option = get_theme_mod( 'color_scheme', 'default' );
$color_schemes = twentysixteen_get_color_schemes(); $color_schemes = twentysixteen_get_color_schemes();
@ -321,11 +384,11 @@ function twentysixteen_get_color_scheme() {
} }
return $color_schemes['default']['colors']; return $color_schemes['default']['colors'];
} }
endif; // twentysixteen_get_color_scheme endif; // twentysixteen_get_color_scheme
if ( ! function_exists( 'twentysixteen_get_color_scheme_choices' ) ) : if ( ! function_exists( 'twentysixteen_get_color_scheme_choices' ) ) :
/** /**
* Retrieves an array of color scheme choices registered for Twenty Sixteen. * Retrieves an array of color scheme choices registered for Twenty Sixteen.
* *
* Create your own twentysixteen_get_color_scheme_choices() function to override * Create your own twentysixteen_get_color_scheme_choices() function to override
@ -335,7 +398,7 @@ if ( ! function_exists( 'twentysixteen_get_color_scheme_choices' ) ) :
* *
* @return array Array of color schemes. * @return array Array of color schemes.
*/ */
function twentysixteen_get_color_scheme_choices() { function twentysixteen_get_color_scheme_choices() {
$color_schemes = twentysixteen_get_color_schemes(); $color_schemes = twentysixteen_get_color_schemes();
$color_scheme_control_options = array(); $color_scheme_control_options = array();
@ -344,12 +407,12 @@ function twentysixteen_get_color_scheme_choices() {
} }
return $color_scheme_control_options; return $color_scheme_control_options;
} }
endif; // twentysixteen_get_color_scheme_choices endif; // twentysixteen_get_color_scheme_choices
if ( ! function_exists( 'twentysixteen_sanitize_color_scheme' ) ) : if ( ! function_exists( 'twentysixteen_sanitize_color_scheme' ) ) :
/** /**
* Handles sanitization for Twenty Sixteen color schemes. * Handles sanitization for Twenty Sixteen color schemes.
* *
* Create your own twentysixteen_sanitize_color_scheme() function to override * Create your own twentysixteen_sanitize_color_scheme() function to override
@ -360,7 +423,7 @@ if ( ! function_exists( 'twentysixteen_sanitize_color_scheme' ) ) :
* @param string $value Color scheme name value. * @param string $value Color scheme name value.
* @return string Color scheme name. * @return string Color scheme name.
*/ */
function twentysixteen_sanitize_color_scheme( $value ) { function twentysixteen_sanitize_color_scheme( $value ) {
$color_schemes = twentysixteen_get_color_scheme_choices(); $color_schemes = twentysixteen_get_color_scheme_choices();
if ( ! array_key_exists( $value, $color_schemes ) ) { if ( ! array_key_exists( $value, $color_schemes ) ) {
@ -368,7 +431,7 @@ function twentysixteen_sanitize_color_scheme( $value ) {
} }
return $value; return $value;
} }
endif; // twentysixteen_sanitize_color_scheme endif; // twentysixteen_sanitize_color_scheme
/** /**
@ -445,14 +508,17 @@ add_action( 'customize_preview_init', 'twentysixteen_customize_preview_js' );
* @return string Color scheme CSS. * @return string Color scheme CSS.
*/ */
function twentysixteen_get_color_scheme_css( $colors ) { function twentysixteen_get_color_scheme_css( $colors ) {
$colors = wp_parse_args( $colors, array( $colors = wp_parse_args(
$colors,
array(
'background_color' => '', 'background_color' => '',
'page_background_color' => '', 'page_background_color' => '',
'link_color' => '', 'link_color' => '',
'main_text_color' => '', 'main_text_color' => '',
'secondary_text_color' => '', 'secondary_text_color' => '',
'border_color' => '', 'border_color' => '',
) ); )
);
return <<<CSS return <<<CSS
/* Color Scheme */ /* Color Scheme */

View file

@ -10,17 +10,18 @@
*/ */
if ( ! function_exists( 'twentysixteen_entry_meta' ) ) : if ( ! function_exists( 'twentysixteen_entry_meta' ) ) :
/** /**
* Prints HTML with meta information for the categories, tags. * Prints HTML with meta information for the categories, tags.
* *
* Create your own twentysixteen_entry_meta() function to override in a child theme. * Create your own twentysixteen_entry_meta() function to override in a child theme.
* *
* @since Twenty Sixteen 1.0 * @since Twenty Sixteen 1.0
*/ */
function twentysixteen_entry_meta() { function twentysixteen_entry_meta() {
if ( 'post' === get_post_type() ) { if ( 'post' === get_post_type() ) {
$author_avatar_size = apply_filters( 'twentysixteen_author_avatar_size', 49 ); $author_avatar_size = apply_filters( 'twentysixteen_author_avatar_size', 49 );
printf( '<span class="byline"><span class="author vcard">%1$s<span class="screen-reader-text">%2$s </span> <a class="url fn n" href="%3$s">%4$s</a></span></span>', printf(
'<span class="byline"><span class="author vcard">%1$s<span class="screen-reader-text">%2$s </span> <a class="url fn n" href="%3$s">%4$s</a></span></span>',
get_avatar( get_the_author_meta( 'user_email' ), $author_avatar_size ), get_avatar( get_the_author_meta( 'user_email' ), $author_avatar_size ),
_x( 'Author', 'Used before post author name.', 'twentysixteen' ), _x( 'Author', 'Used before post author name.', 'twentysixteen' ),
esc_url( get_author_posts_url( get_the_author_meta( 'ID' ) ) ), esc_url( get_author_posts_url( get_the_author_meta( 'ID' ) ) ),
@ -34,7 +35,8 @@ function twentysixteen_entry_meta() {
$format = get_post_format(); $format = get_post_format();
if ( current_theme_supports( 'post-formats', $format ) ) { if ( current_theme_supports( 'post-formats', $format ) ) {
printf( '<span class="entry-format">%1$s<a href="%2$s">%3$s</a></span>', printf(
'<span class="entry-format">%1$s<a href="%2$s">%3$s</a></span>',
sprintf( '<span class="screen-reader-text">%s </span>', _x( 'Format', 'Used before post format.', 'twentysixteen' ) ), sprintf( '<span class="screen-reader-text">%s </span>', _x( 'Format', 'Used before post format.', 'twentysixteen' ) ),
esc_url( get_post_format_link( $format ) ), esc_url( get_post_format_link( $format ) ),
get_post_format_string( $format ) get_post_format_string( $format )
@ -50,51 +52,54 @@ function twentysixteen_entry_meta() {
comments_popup_link( sprintf( __( 'Leave a comment<span class="screen-reader-text"> on %s</span>', 'twentysixteen' ), get_the_title() ) ); comments_popup_link( sprintf( __( 'Leave a comment<span class="screen-reader-text"> on %s</span>', 'twentysixteen' ), get_the_title() ) );
echo '</span>'; echo '</span>';
} }
} }
endif; endif;
if ( ! function_exists( 'twentysixteen_entry_date' ) ) : if ( ! function_exists( 'twentysixteen_entry_date' ) ) :
/** /**
* Prints HTML with date information for current post. * Prints HTML with date information for current post.
* *
* Create your own twentysixteen_entry_date() function to override in a child theme. * Create your own twentysixteen_entry_date() function to override in a child theme.
* *
* @since Twenty Sixteen 1.0 * @since Twenty Sixteen 1.0
*/ */
function twentysixteen_entry_date() { function twentysixteen_entry_date() {
$time_string = '<time class="entry-date published updated" datetime="%1$s">%2$s</time>'; $time_string = '<time class="entry-date published updated" datetime="%1$s">%2$s</time>';
if ( get_the_time( 'U' ) !== get_the_modified_time( 'U' ) ) { if ( get_the_time( 'U' ) !== get_the_modified_time( 'U' ) ) {
$time_string = '<time class="entry-date published" datetime="%1$s">%2$s</time><time class="updated" datetime="%3$s">%4$s</time>'; $time_string = '<time class="entry-date published" datetime="%1$s">%2$s</time><time class="updated" datetime="%3$s">%4$s</time>';
} }
$time_string = sprintf( $time_string, $time_string = sprintf(
$time_string,
esc_attr( get_the_date( 'c' ) ), esc_attr( get_the_date( 'c' ) ),
get_the_date(), get_the_date(),
esc_attr( get_the_modified_date( 'c' ) ), esc_attr( get_the_modified_date( 'c' ) ),
get_the_modified_date() get_the_modified_date()
); );
printf( '<span class="posted-on"><span class="screen-reader-text">%1$s </span><a href="%2$s" rel="bookmark">%3$s</a></span>', printf(
'<span class="posted-on"><span class="screen-reader-text">%1$s </span><a href="%2$s" rel="bookmark">%3$s</a></span>',
_x( 'Posted on', 'Used before publish date.', 'twentysixteen' ), _x( 'Posted on', 'Used before publish date.', 'twentysixteen' ),
esc_url( get_permalink() ), esc_url( get_permalink() ),
$time_string $time_string
); );
} }
endif; endif;
if ( ! function_exists( 'twentysixteen_entry_taxonomies' ) ) : if ( ! function_exists( 'twentysixteen_entry_taxonomies' ) ) :
/** /**
* Prints HTML with category and tags for current post. * Prints HTML with category and tags for current post.
* *
* Create your own twentysixteen_entry_taxonomies() function to override in a child theme. * Create your own twentysixteen_entry_taxonomies() function to override in a child theme.
* *
* @since Twenty Sixteen 1.0 * @since Twenty Sixteen 1.0
*/ */
function twentysixteen_entry_taxonomies() { function twentysixteen_entry_taxonomies() {
$categories_list = get_the_category_list( _x( ', ', 'Used between list items, there is a space after the comma.', 'twentysixteen' ) ); $categories_list = get_the_category_list( _x( ', ', 'Used between list items, there is a space after the comma.', 'twentysixteen' ) );
if ( $categories_list && twentysixteen_categorized_blog() ) { if ( $categories_list && twentysixteen_categorized_blog() ) {
printf( '<span class="cat-links"><span class="screen-reader-text">%1$s </span>%2$s</span>', printf(
'<span class="cat-links"><span class="screen-reader-text">%1$s </span>%2$s</span>',
_x( 'Categories', 'Used before category names.', 'twentysixteen' ), _x( 'Categories', 'Used before category names.', 'twentysixteen' ),
$categories_list $categories_list
); );
@ -102,16 +107,17 @@ function twentysixteen_entry_taxonomies() {
$tags_list = get_the_tag_list( '', _x( ', ', 'Used between list items, there is a space after the comma.', 'twentysixteen' ) ); $tags_list = get_the_tag_list( '', _x( ', ', 'Used between list items, there is a space after the comma.', 'twentysixteen' ) );
if ( $tags_list && ! is_wp_error( $tags_list ) ) { if ( $tags_list && ! is_wp_error( $tags_list ) ) {
printf( '<span class="tags-links"><span class="screen-reader-text">%1$s </span>%2$s</span>', printf(
'<span class="tags-links"><span class="screen-reader-text">%1$s </span>%2$s</span>',
_x( 'Tags', 'Used before tag names.', 'twentysixteen' ), _x( 'Tags', 'Used before tag names.', 'twentysixteen' ),
$tags_list $tags_list
); );
} }
} }
endif; endif;
if ( ! function_exists( 'twentysixteen_post_thumbnail' ) ) : if ( ! function_exists( 'twentysixteen_post_thumbnail' ) ) :
/** /**
* Displays an optional post thumbnail. * Displays an optional post thumbnail.
* *
* Wraps the post thumbnail in an anchor element on index views, or a div * Wraps the post thumbnail in an anchor element on index views, or a div
@ -121,7 +127,7 @@ if ( ! function_exists( 'twentysixteen_post_thumbnail' ) ) :
* *
* @since Twenty Sixteen 1.0 * @since Twenty Sixteen 1.0
*/ */
function twentysixteen_post_thumbnail() { function twentysixteen_post_thumbnail() {
if ( post_password_required() || is_attachment() || ! has_post_thumbnail() ) { if ( post_password_required() || is_attachment() || ! has_post_thumbnail() ) {
return; return;
} }
@ -139,8 +145,9 @@ function twentysixteen_post_thumbnail() {
<?php the_post_thumbnail( 'post-thumbnail', array( 'alt' => the_title_attribute( 'echo=0' ) ) ); ?> <?php the_post_thumbnail( 'post-thumbnail', array( 'alt' => the_title_attribute( 'echo=0' ) ) ); ?>
</a> </a>
<?php endif; // End is_singular() <?php
} endif; // End is_singular()
}
endif; endif;
if ( ! function_exists( 'twentysixteen_excerpt' ) ) : if ( ! function_exists( 'twentysixteen_excerpt' ) ) :
@ -158,16 +165,18 @@ if ( ! function_exists( 'twentysixteen_excerpt' ) ) :
function twentysixteen_excerpt( $class = 'entry-summary' ) { function twentysixteen_excerpt( $class = 'entry-summary' ) {
$class = esc_attr( $class ); $class = esc_attr( $class );
if ( has_excerpt() || is_search() ) : ?> if ( has_excerpt() || is_search() ) :
?>
<div class="<?php echo $class; ?>"> <div class="<?php echo $class; ?>">
<?php the_excerpt(); ?> <?php the_excerpt(); ?>
</div><!-- .<?php echo $class; ?> --> </div><!-- .<?php echo $class; ?> -->
<?php endif; <?php
endif;
} }
endif; endif;
if ( ! function_exists( 'twentysixteen_excerpt_more' ) && ! is_admin() ) : if ( ! function_exists( 'twentysixteen_excerpt_more' ) && ! is_admin() ) :
/** /**
* Replaces "[...]" (appended to automatically generated excerpts) with ... and * Replaces "[...]" (appended to automatically generated excerpts) with ... and
* a 'Continue reading' link. * a 'Continue reading' link.
* *
@ -177,19 +186,20 @@ if ( ! function_exists( 'twentysixteen_excerpt_more' ) && ! is_admin() ) :
* *
* @return string 'Continue reading' link prepended with an ellipsis. * @return string 'Continue reading' link prepended with an ellipsis.
*/ */
function twentysixteen_excerpt_more() { function twentysixteen_excerpt_more() {
$link = sprintf( '<a href="%1$s" class="more-link">%2$s</a>', $link = sprintf(
'<a href="%1$s" class="more-link">%2$s</a>',
esc_url( get_permalink( get_the_ID() ) ), esc_url( get_permalink( get_the_ID() ) ),
/* translators: %s: Name of current post */ /* translators: %s: Name of current post */
sprintf( __( 'Continue reading<span class="screen-reader-text"> "%s"</span>', 'twentysixteen' ), get_the_title( get_the_ID() ) ) sprintf( __( 'Continue reading<span class="screen-reader-text"> "%s"</span>', 'twentysixteen' ), get_the_title( get_the_ID() ) )
); );
return ' &hellip; ' . $link; return ' &hellip; ' . $link;
} }
add_filter( 'excerpt_more', 'twentysixteen_excerpt_more' ); add_filter( 'excerpt_more', 'twentysixteen_excerpt_more' );
endif; endif;
if ( ! function_exists( 'twentysixteen_categorized_blog' ) ) : if ( ! function_exists( 'twentysixteen_categorized_blog' ) ) :
/** /**
* Determines whether blog/site has more than one category. * Determines whether blog/site has more than one category.
* *
* Create your own twentysixteen_categorized_blog() function to override in a child theme. * Create your own twentysixteen_categorized_blog() function to override in a child theme.
@ -198,14 +208,16 @@ if ( ! function_exists( 'twentysixteen_categorized_blog' ) ) :
* *
* @return bool True if there is more than one category, false otherwise. * @return bool True if there is more than one category, false otherwise.
*/ */
function twentysixteen_categorized_blog() { function twentysixteen_categorized_blog() {
if ( false === ( $all_the_cool_cats = get_transient( 'twentysixteen_categories' ) ) ) { if ( false === ( $all_the_cool_cats = get_transient( 'twentysixteen_categories' ) ) ) {
// Create an array of all the categories that are attached to posts. // Create an array of all the categories that are attached to posts.
$all_the_cool_cats = get_categories( array( $all_the_cool_cats = get_categories(
array(
'fields' => 'ids', 'fields' => 'ids',
// We only need to know if there is more than one category. // We only need to know if there is more than one category.
'number' => 2, 'number' => 2,
) ); )
);
// Count the number of categories that are attached to the posts. // Count the number of categories that are attached to the posts.
$all_the_cool_cats = count( $all_the_cool_cats ); $all_the_cool_cats = count( $all_the_cool_cats );
@ -220,7 +232,7 @@ function twentysixteen_categorized_blog() {
// This blog has only 1 category so twentysixteen_categorized_blog should return false. // This blog has only 1 category so twentysixteen_categorized_blog should return false.
return false; return false;
} }
} }
endif; endif;
/** /**
@ -239,16 +251,34 @@ add_action( 'edit_category', 'twentysixteen_category_transient_flusher' );
add_action( 'save_post', 'twentysixteen_category_transient_flusher' ); add_action( 'save_post', 'twentysixteen_category_transient_flusher' );
if ( ! function_exists( 'twentysixteen_the_custom_logo' ) ) : if ( ! function_exists( 'twentysixteen_the_custom_logo' ) ) :
/** /**
* Displays the optional custom logo. * Displays the optional custom logo.
* *
* Does nothing if the custom logo is not available. * Does nothing if the custom logo is not available.
* *
* @since Twenty Sixteen 1.2 * @since Twenty Sixteen 1.2
*/ */
function twentysixteen_the_custom_logo() { function twentysixteen_the_custom_logo() {
if ( function_exists( 'the_custom_logo' ) ) { if ( function_exists( 'the_custom_logo' ) ) {
the_custom_logo(); the_custom_logo();
} }
} }
endif;
if ( ! function_exists( 'wp_body_open' ) ) :
/**
* Fire the wp_body_open action.
*
* Added for backwards compatibility to support pre 5.2.0 WordPress versions.
*
* @since Twenty Sixteen 2.0
*/
function wp_body_open() {
/**
* Triggered after the opening <body> tag.
*
* @since Twenty Sixteen 2.0
*/
do_action( 'wp_body_open' );
}
endif; endif;

View file

@ -7,7 +7,7 @@
* It is used to display a page when nothing more specific matches a query. * It is used to display a page when nothing more specific matches a query.
* E.g., it puts together the home page when no home.php file exists. * E.g., it puts together the home page when no home.php file exists.
* *
* @link https://codex.wordpress.org/Template_Hierarchy * @link https://developer.wordpress.org/themes/basics/template-hierarchy/
* *
* @package WordPress * @package WordPress
* @subpackage Twenty_Sixteen * @subpackage Twenty_Sixteen
@ -29,7 +29,8 @@ get_header(); ?>
<?php <?php
// Start the loop. // Start the loop.
while ( have_posts() ) : the_post(); while ( have_posts() ) :
the_post();
/* /*
* Include the Post-Format-specific template for the content. * Include the Post-Format-specific template for the content.
@ -42,11 +43,13 @@ get_header(); ?>
endwhile; endwhile;
// Previous/next page navigation. // Previous/next page navigation.
the_posts_pagination( array( the_posts_pagination(
array(
'prev_text' => __( 'Previous page', 'twentysixteen' ), 'prev_text' => __( 'Previous page', 'twentysixteen' ),
'next_text' => __( 'Next page', 'twentysixteen' ), 'next_text' => __( 'Next page', 'twentysixteen' ),
'before_page_number' => '<span class="meta-nav screen-reader-text">' . __( 'Page', 'twentysixteen' ) . ' </span>', 'before_page_number' => '<span class="meta-nav screen-reader-text">' . __( 'Page', 'twentysixteen' ) . ' </span>',
) ); )
);
// If no content, include the "No posts found" template. // If no content, include the "No posts found" template.
else : else :

View file

@ -17,7 +17,8 @@ get_header(); ?>
<main id="main" class="site-main" role="main"> <main id="main" class="site-main" role="main">
<?php <?php
// Start the loop. // Start the loop.
while ( have_posts() ) : the_post(); while ( have_posts() ) :
the_post();
// Include the page content template. // Include the page content template.
get_template_part( 'template-parts/content', 'page' ); get_template_part( 'template-parts/content', 'page' );

View file

@ -1,8 +1,9 @@
=== Twenty Sixteen === === Twenty Sixteen ===
Contributors: the WordPress team Contributors: wordpressdotorg
Requires at least: WordPress 4.4 Requires at least: WordPress 4.4
Tested up to: WordPress 5.0 Tested up to: WordPress 5.0
Version: 1.8 Requires PHP: 5.2.4
Version: 2.0
License: GPLv2 or later License: GPLv2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html License URI: http://www.gnu.org/licenses/gpl-2.0.html
Tags: one-column, two-columns, right-sidebar, accessibility-ready, custom-background, custom-colors, custom-header, custom-menu, editor-style, featured-images, flexible-header, microformats, post-formats, rtl-language-support, sticky-post, threaded-comments, translation-ready, blog Tags: one-column, two-columns, right-sidebar, accessibility-ready, custom-background, custom-colors, custom-header, custom-menu, editor-style, featured-images, flexible-header, microformats, post-formats, rtl-language-support, sticky-post, threaded-comments, translation-ready, blog
@ -56,6 +57,16 @@ Image used in screenshot.png: A photo by Austin Schmid (https://unsplash.com/sch
== Changelog == == Changelog ==
= 2.0 =
* Released: May 7, 2019
https://codex.wordpress.org/Twenty_Sixteen_Theme_Changelog#Version_2.0
= 1.9 =
* Released: February 21, 2019
https://codex.wordpress.org/Twenty_Sixteen_Theme_Changelog#Version_1.9
= 1.8 = = 1.8 =
* Released: January 9, 2019 * Released: January 9, 2019

View file

@ -20,7 +20,8 @@ get_header(); ?>
<?php <?php
// Start the loop. // Start the loop.
while ( have_posts() ) : the_post(); while ( have_posts() ) :
the_post();
/** /**
* Run the loop for the search to output the results. * Run the loop for the search to output the results.
@ -33,11 +34,13 @@ get_header(); ?>
endwhile; endwhile;
// Previous/next page navigation. // Previous/next page navigation.
the_posts_pagination( array( the_posts_pagination(
array(
'prev_text' => __( 'Previous page', 'twentysixteen' ), 'prev_text' => __( 'Previous page', 'twentysixteen' ),
'next_text' => __( 'Next page', 'twentysixteen' ), 'next_text' => __( 'Next page', 'twentysixteen' ),
'before_page_number' => '<span class="meta-nav screen-reader-text">' . __( 'Page', 'twentysixteen' ) . ' </span>', 'before_page_number' => '<span class="meta-nav screen-reader-text">' . __( 'Page', 'twentysixteen' ) . ' </span>',
) ); )
);
// If no content, include the "No posts found" template. // If no content, include the "No posts found" template.
else : else :

View file

@ -13,7 +13,8 @@ get_header(); ?>
<main id="main" class="site-main" role="main"> <main id="main" class="site-main" role="main">
<?php <?php
// Start the loop. // Start the loop.
while ( have_posts() ) : the_post(); while ( have_posts() ) :
the_post();
// Include the single post content template. // Include the single post content template.
get_template_part( 'template-parts/content', 'single' ); get_template_part( 'template-parts/content', 'single' );
@ -25,19 +26,23 @@ get_header(); ?>
if ( is_singular( 'attachment' ) ) { if ( is_singular( 'attachment' ) ) {
// Parent post navigation. // Parent post navigation.
the_post_navigation( array( the_post_navigation(
array(
'prev_text' => _x( '<span class="meta-nav">Published in</span><span class="post-title">%title</span>', 'Parent post link', 'twentysixteen' ), 'prev_text' => _x( '<span class="meta-nav">Published in</span><span class="post-title">%title</span>', 'Parent post link', 'twentysixteen' ),
) ); )
);
} elseif ( is_singular( 'post' ) ) { } elseif ( is_singular( 'post' ) ) {
// Previous/next post navigation. // Previous/next post navigation.
the_post_navigation( array( the_post_navigation(
array(
'next_text' => '<span class="meta-nav" aria-hidden="true">' . __( 'Next', 'twentysixteen' ) . '</span> ' . 'next_text' => '<span class="meta-nav" aria-hidden="true">' . __( 'Next', 'twentysixteen' ) . '</span> ' .
'<span class="screen-reader-text">' . __( 'Next post:', 'twentysixteen' ) . '</span> ' . '<span class="screen-reader-text">' . __( 'Next post:', 'twentysixteen' ) . '</span> ' .
'<span class="post-title">%title</span>', '<span class="post-title">%title</span>',
'prev_text' => '<span class="meta-nav" aria-hidden="true">' . __( 'Previous', 'twentysixteen' ) . '</span> ' . 'prev_text' => '<span class="meta-nav" aria-hidden="true">' . __( 'Previous', 'twentysixteen' ) . '</span> ' .
'<span class="screen-reader-text">' . __( 'Previous post:', 'twentysixteen' ) . '</span> ' . '<span class="screen-reader-text">' . __( 'Previous post:', 'twentysixteen' ) . '</span> ' .
'<span class="post-title">%title</span>', '<span class="post-title">%title</span>',
) ); )
);
} }
// End of the loop. // End of the loop.

View file

@ -4,7 +4,7 @@ Theme URI: https://wordpress.org/themes/twentysixteen/
Author: the WordPress team Author: the WordPress team
Author URI: https://wordpress.org/ Author URI: https://wordpress.org/
Description: Twenty Sixteen is a modernized take on an ever-popular WordPress layout the horizontal masthead with an optional right sidebar that works perfectly for blogs and websites. It has custom color options with beautiful default color schemes, a harmonious fluid grid using a mobile-first approach, and impeccable polish in every detail. Twenty Sixteen will make your WordPress look beautiful everywhere. Description: Twenty Sixteen is a modernized take on an ever-popular WordPress layout the horizontal masthead with an optional right sidebar that works perfectly for blogs and websites. It has custom color options with beautiful default color schemes, a harmonious fluid grid using a mobile-first approach, and impeccable polish in every detail. Twenty Sixteen will make your WordPress look beautiful everywhere.
Version: 1.8 Version: 2.0
License: GNU General Public License v2 or later License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html License URI: http://www.gnu.org/licenses/gpl-2.0.html
Tags: one-column, two-columns, right-sidebar, accessibility-ready, custom-background, custom-colors, custom-header, custom-menu, editor-style, featured-images, flexible-header, microformats, post-formats, rtl-language-support, sticky-post, threaded-comments, translation-ready, blog Tags: one-column, two-columns, right-sidebar, accessibility-ready, custom-background, custom-colors, custom-header, custom-menu, editor-style, featured-images, flexible-header, microformats, post-formats, rtl-language-support, sticky-post, threaded-comments, translation-ready, blog

View file

@ -19,14 +19,16 @@
<?php <?php
the_content(); the_content();
wp_link_pages( array( wp_link_pages(
array(
'before' => '<div class="page-links"><span class="page-links-title">' . __( 'Pages:', 'twentysixteen' ) . '</span>', 'before' => '<div class="page-links"><span class="page-links-title">' . __( 'Pages:', 'twentysixteen' ) . '</span>',
'after' => '</div>', 'after' => '</div>',
'link_before' => '<span>', 'link_before' => '<span>',
'link_after' => '</span>', 'link_after' => '</span>',
'pagelink' => '<span class="screen-reader-text">' . __( 'Page', 'twentysixteen' ) . ' </span>%', 'pagelink' => '<span class="screen-reader-text">' . __( 'Page', 'twentysixteen' ) . ' </span>%',
'separator' => '<span class="screen-reader-text">, </span>', 'separator' => '<span class="screen-reader-text">, </span>',
) ); )
);
?> ?>
</div><!-- .entry-content --> </div><!-- .entry-content -->
@ -42,4 +44,4 @@
); );
?> ?>
</article><!-- #post-## --> </article><!-- #post-<?php the_ID(); ?> -->

View file

@ -49,5 +49,5 @@
?> ?>
<?php endif; ?> <?php endif; ?>
</article><!-- #post-## --> </article><!-- #post-<?php the_ID(); ?> -->

View file

@ -21,14 +21,16 @@
<?php <?php
the_content(); the_content();
wp_link_pages( array( wp_link_pages(
array(
'before' => '<div class="page-links"><span class="page-links-title">' . __( 'Pages:', 'twentysixteen' ) . '</span>', 'before' => '<div class="page-links"><span class="page-links-title">' . __( 'Pages:', 'twentysixteen' ) . '</span>',
'after' => '</div>', 'after' => '</div>',
'link_before' => '<span>', 'link_before' => '<span>',
'link_after' => '</span>', 'link_after' => '</span>',
'pagelink' => '<span class="screen-reader-text">' . __( 'Page', 'twentysixteen' ) . ' </span>%', 'pagelink' => '<span class="screen-reader-text">' . __( 'Page', 'twentysixteen' ) . ' </span>%',
'separator' => '<span class="screen-reader-text">, </span>', 'separator' => '<span class="screen-reader-text">, </span>',
) ); )
);
if ( '' !== get_the_author_meta( 'description' ) ) { if ( '' !== get_the_author_meta( 'description' ) ) {
get_template_part( 'template-parts/biography' ); get_template_part( 'template-parts/biography' );
@ -50,4 +52,4 @@
); );
?> ?>
</footer><!-- .entry-footer --> </footer><!-- .entry-footer -->
</article><!-- #post-## --> </article><!-- #post-<?php the_ID(); ?> -->

View file

@ -24,19 +24,23 @@
<div class="entry-content"> <div class="entry-content">
<?php <?php
/* translators: %s: Name of current post */ /* translators: %s: Name of current post */
the_content( sprintf( the_content(
sprintf(
__( 'Continue reading<span class="screen-reader-text"> "%s"</span>', 'twentysixteen' ), __( 'Continue reading<span class="screen-reader-text"> "%s"</span>', 'twentysixteen' ),
get_the_title() get_the_title()
) ); )
);
wp_link_pages( array( wp_link_pages(
array(
'before' => '<div class="page-links"><span class="page-links-title">' . __( 'Pages:', 'twentysixteen' ) . '</span>', 'before' => '<div class="page-links"><span class="page-links-title">' . __( 'Pages:', 'twentysixteen' ) . '</span>',
'after' => '</div>', 'after' => '</div>',
'link_before' => '<span>', 'link_before' => '<span>',
'link_after' => '</span>', 'link_after' => '</span>',
'pagelink' => '<span class="screen-reader-text">' . __( 'Page', 'twentysixteen' ) . ' </span>%', 'pagelink' => '<span class="screen-reader-text">' . __( 'Page', 'twentysixteen' ) . ' </span>%',
'separator' => '<span class="screen-reader-text">, </span>', 'separator' => '<span class="screen-reader-text">, </span>',
) ); )
);
?> ?>
</div><!-- .entry-content --> </div><!-- .entry-content -->
@ -54,4 +58,4 @@
); );
?> ?>
</footer><!-- .entry-footer --> </footer><!-- .entry-footer -->
</article><!-- #post-## --> </article><!-- #post-<?php the_ID(); ?> -->