- Timestamp:
- 12/18/2018 10:45:16 PM (6 years ago)
- Location:
- trunk
- Files:
-
- 15 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk
- Property svn:mergeinfo changed
/branches/5.0 merged: 44196,44199,44201-44202
- Property svn:mergeinfo changed
-
trunk/src/wp-content/themes/twentynineteen/classes/class-twentynineteen-walker-comment.php
r44155 r44305 34 34 <div class="comment-author vcard"> 35 35 <?php 36 37 38 39 36 $comment_author_link = get_comment_author_link( $comment ); 37 $comment_author_url = get_comment_author_url( $comment ); 38 $comment_author = get_comment_author( $comment ); 39 $avatar = get_avatar( $comment, $args['avatar_size'] ); 40 40 if ( 0 != $args['avatar_size'] ) { 41 41 if ( empty( $comment_author_url ) ) { … … 46 46 } 47 47 } 48 49 /* 50 * Using the `check` icon instead of `check_circle`, since we can't add a 51 * fill color to the inner check shape when in circle form. 52 */ 48 /* 49 * Using the `check` icon instead of `check_circle`, since we can't add a 50 * fill color to the inner check shape when in circle form. 51 */ 53 52 if ( twentynineteen_is_comment_by_post_author( $comment ) ) { 54 /* translators: %s: SVG Icon */55 53 printf( '<span class="post-author-badge" aria-hidden="true">%s</span>', twentynineteen_get_icon_svg( 'check', 24 ) ); 56 54 } 57 55 58 printf( 59 /* translators: %s: comment author link */ 56 /* 57 * Using the `check` icon instead of `check_circle`, since we can't add a 58 * fill color to the inner check shape when in circle form. 59 */ 60 if ( twentynineteen_is_comment_by_post_author( $comment ) ) { 61 printf( '<span class="post-author-badge" aria-hidden="true">%s</span>', twentynineteen_get_icon_svg( 'check', 24 ) ); 62 } 63 64 printf( 65 /* translators: %s: comment author link */ 66 wp_kses( 60 67 __( '%s <span class="screen-reader-text says">says:</span>', 'twentynineteen' ), 61 sprintf( '<span class="fn">%s</span>', $comment_author ) 62 ); 68 array( 69 'span' => array( 70 'class' => array(), 71 ), 72 ) 73 ), 74 '<b class="fn">' . get_comment_author_link( $comment ) . '</b>' 75 ); 63 76 64 77 if ( ! empty( $comment_author_url ) ) { … … 111 124 <?php 112 125 } 113 114 126 } -
trunk/src/wp-content/themes/twentynineteen/functions.php
r44298 r44305 222 222 wp_style_add_data( 'twentynineteen-style', 'rtl', 'replace' ); 223 223 224 wp_enqueue_script( 'twentynineteen-skip-link-focus-fix', get_template_directory_uri() . '/js/skip-link-focus-fix.js', array(), '20151215', true );225 226 224 if ( has_nav_menu( 'menu-1' ) ) { 227 225 wp_enqueue_script( 'twentynineteen-priority-menu', get_theme_file_uri( '/js/priority-menu.js' ), array(), '1.0', true ); … … 236 234 } 237 235 add_action( 'wp_enqueue_scripts', 'twentynineteen_scripts' ); 236 237 /** 238 * Fix skip link focus in IE11. 239 * 240 * This does not enqueue the script because it is tiny and because it is only for IE11, 241 * thus it does not warrant having an entire dedicated blocking script being loaded. 242 * 243 * @link https://git.io/vWdr2 244 */ 245 function twentynineteen_skip_link_focus_fix() { 246 // The following is minified via `terser --compress --mangle -- js/skip-link-focus-fix.js`. 247 ?> 248 <script> 249 /(trident|msie)/i.test(navigator.userAgent)&&document.getElementById&&window.addEventListener&&window.addEventListener("hashchange",function(){var t,e=location.hash.substring(1);/^[A-z0-9_-]+$/.test(e)&&(t=document.getElementById(e))&&(/^(?:a|select|input|button|textarea)$/i.test(t.tagName)||(t.tabIndex=-1),t.focus())},!1); 250 </script> 251 <?php 252 } 253 add_action( 'wp_print_footer_scripts', 'twentynineteen_skip_link_focus_fix' ); 238 254 239 255 /** -
trunk/src/wp-content/themes/twentynineteen/header.php
r44298 r44305 38 38 39 39 $classes = 'entry-header'; 40 if ( ! empty( $discussion ) && count( $discussion->responses ) > 0 ) {40 if ( ! empty( $discussion ) && absint( $discussion->responses ) > 0 ) { 41 41 $classes = 'entry-header has-discussion'; 42 42 } -
trunk/src/wp-content/themes/twentynineteen/inc/template-tags.php
r44298 r44305 41 41 function twentynineteen_posted_by() { 42 42 printf( 43 /* translators: 1: SVG icon. 2: post author, only visible to screen readers. 3: author link. */ 43 44 '<span class="byline">%1$s<span class="screen-reader-text">%2$s</span><span class="author vcard"><a class="url fn n" href="%3$s">%4$s</a></span></span>', 44 /* translators: 1: SVG icon. 2: post author, only visible to screen readers. 3: author link. */45 45 twentynineteen_get_icon_svg( 'person', 16 ), 46 46 __( 'Posted by', 'twentynineteen' ), … … 86 86 $categories_list = get_the_category_list( __( ', ', 'twentynineteen' ) ); 87 87 if ( $categories_list ) { 88 /* translators: 1: SVG icon. 2: posted in label, only visible to screen readers. 3: list of categories. */89 88 printf( 89 /* translators: 1: SVG icon. 2: posted in label, only visible to screen readers. 3: list of categories. */ 90 90 '<span class="cat-links">%1$s<span class="screen-reader-text">%2$s</span>%3$s</span>', 91 91 twentynineteen_get_icon_svg( 'archive', 16 ), … … 98 98 $tags_list = get_the_tag_list( '', __( ', ', 'twentynineteen' ) ); 99 99 if ( $tags_list ) { 100 /* translators: 1: SVG icon. 2: posted in label, only visible to screen readers. 3: list of tags. */101 100 printf( 101 /* translators: 1: SVG icon. 2: posted in label, only visible to screen readers. 3: list of tags. */ 102 102 '<span class="tags-links">%1$s<span class="screen-reader-text">%2$s </span>%3$s</span>', 103 103 twentynineteen_get_icon_svg( 'tag', 16 ), -
trunk/src/wp-content/themes/twentynineteen/js/skip-link-focus-fix.js
r43808 r44305 3 3 * 4 4 * Helps with accessibility for keyboard only users. 5 * 6 * This is the source file for what is minified in the twentynineteen_skip_link_focus_fix() PHP function. 5 7 * 6 8 * Learn more: https://git.io/vWdr2 -
trunk/src/wp-content/themes/twentynineteen/readme.txt
r44279 r44305 1 # Twenty Nineteen 1 === Twenty Nineteen === 2 Contributors: the WordPress team 3 Tags: one-column, flexible-header, accessibility-ready, custom-colors, custom-menu, custom-logo, editor-style, featured-images, footer-widgets, rtl-language-support, sticky-post, theme-options, threaded-comments, translation-ready 4 Requires at least: 4.9.6 5 Tested up to: 5.0 6 Stable tag: 1.0 7 License: GPLv2 or later 8 License URI: http://www.gnu.org/licenses/gpl-2.0.html 2 9 3 [![Build Status](https://travis-ci.org/WordPress/twentynineteen.svg?branch=master)](https://travis-ci.org/WordPress/twentynineteen) 10 Our 2019 default theme is designed to show off the power of the block editor. 4 11 5 **Contributors:** the WordPress team 6 **Requires at least:** WordPress 4.9.6 7 **Tested up to:** WordPress 4.9.8 8 **Version:** 1.0 9 **License:** GPLv2 or later 10 **License URI:** http://www.gnu.org/licenses/gpl-2.0.html 11 **Tags:** one-column, flexible-header, accessibility-ready, custom-colors, custom-menu, custom-logo, editor-style, featured-images, footer-widgets, rtl-language-support, sticky-post, theme-options, threaded-comments, translation-ready 12 == Description == 13 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 you’re 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. 12 14 13 ## Description 15 == Changelog == 14 16 15 Twenty Nineteen is a Gutenberg-ready theme for WordPress. 17 = 1.0 = 18 * Initial Release 16 19 17 ## Installation 18 19 1. In your admin panel, go to Appearance -> Themes and click the 'Add New' button. 20 2. Type in Twenty Nineteen in the search form and press the 'Enter' key on your keyboard. 21 3. Click on the 'Activate' button to use your new theme right away. 22 4. Go to https://codex.wordpress.org/Twenty_Nineteen for a guide on how to customize this theme. 23 5. Navigate to Appearance > Customize in your admin panel and customize to taste. 24 25 ## Copyright 26 27 Twenty Nineteen WordPress Theme, Copyright 2018 WordPress.org 28 Twenty Nineteen is distributed under the terms of the GNU GPL. 29 30 This program is free software: you can redistribute it and/or modify 31 it under the terms of the GNU General Public License as published by 32 the Free Software Foundation, either version 2 of the License, or 33 (at your option) any later version. 34 35 This program is distributed in the hope that it will be useful, 36 but WITHOUT ANY WARRANTY; without even the implied warranty of 37 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 38 GNU General Public License for more details. 39 40 Twenty Nineteen bundles the following third-party resources: 41 42 _s, Copyright 2015-2018 Automattic, Inc. 43 **License:** GPLv2 or later 44 Source: https://github.com/Automattic/_s/ 45 46 normalize.css, Copyright 2012-2016 Nicolas Gallagher and Jonathan Neal 47 **License:** MIT 48 Source: https://necolas.github.io/normalize.css/ 49 50 Bundled header image 1, Copyright XXXXX XXXXX 51 **License:** CC0 1.0 Universal (CC0 1.0) 52 Source: https://pexels.com/xxxxxxxxxx 53 54 Bundled header image 2, Copyright XXXXX XXXXX 55 **License:** CC0 1.0 Universal (CC0 1.0) 56 Source: https://pexels.com/xxxxxxxxxx 57 58 ## Changelog 59 60 ### 1.0 61 62 * Released: December 6, 2018 63 64 Initial release 20 == Resources == 21 * normalize.css, © 2012-2018 Nicolas Gallagher and Jonathan Neal, MIT 22 * Underscores, © 2012-2018 Automattic, Inc., GNU GPL v2 or later -
trunk/src/wp-content/themes/twentynineteen/sass/blocks/_blocks.scss
r44302 r44305 325 325 margin-bottom: calc(4.33 * #{ $size__spacing-unit}); 326 326 margin-right: 0; 327 padding-left: 0; 327 328 } 328 329 … … 363 364 364 365 blockquote { 365 margin -left:0;366 margin: $size__spacing-unit 0; 366 367 padding: 0; 367 368 text-align: left; 368 369 max-width: 100%; 370 371 p:first-child { 372 margin-top: 0; 373 } 369 374 } 370 375 } … … 400 405 401 406 blockquote { 402 max-width: calc(100% - (2 * #{$size__spacing-unit}));407 max-width: 100%; 403 408 color: $color__background-body; 404 409 padding-left: 0; 405 410 margin-left: $size__spacing-unit; 411 margin-right: $size__spacing-unit; 406 412 407 413 &.has-text-color p, … … 418 424 margin-left: 0; 419 425 margin-right: 0; 426 } 427 } 428 429 &.alignright, 430 &.alignleft { 431 432 @include media(tablet) { 433 padding: $size__spacing-unit calc(2 * #{$size__spacing-unit}); 420 434 } 421 435 } … … 529 543 padding: 0; 530 544 color: #fff; 531 -ms-hyphens: auto;532 -moz-hyphens: auto;533 -webkit-hyphens: auto;534 hyphens: auto;535 545 536 546 @include media(tablet) { … … 545 555 546 556 @include media(tablet) { 547 padding: $size__spacing-unit ;557 padding: $size__spacing-unit calc(2 * #{$size__spacing-unit}); 548 558 } 549 559 } … … 578 588 .blocks-gallery-item:last-child { 579 589 margin-bottom: 16px; 590 } 591 592 figcaption a { 593 color: #fff; 580 594 } 581 595 } -
trunk/src/wp-content/themes/twentynineteen/single.php
r44149 r44305 28 28 the_post_navigation( 29 29 array( 30 'prev_text' => _x( '<span class="meta-nav">Published in</span><br/><span class="post-title">%title</span>', 'Parent post link', 'twentynineteen' ), 30 /* translators: %s: parent post link */ 31 'prev_text' => sprintf( __( '<span class="meta-nav">Published in</span><span class="post-title">%s</span>', 'twentynineteen' ), '%title' ), 31 32 ) 32 33 ); -
trunk/src/wp-content/themes/twentynineteen/style-editor.css
r44302 r44305 333 333 width: 100%; 334 334 max-width: 100%; 335 padding: calc(1.375 * 1rem); 336 } 337 338 .wp-block[data-type="core/cover"][data-align="left"] .wp-block-cover p, 339 .wp-block[data-type="core/cover"][data-align="right"] .wp-block-cover p { 340 padding-left: 0; 341 padding-right: 0; 335 342 } 336 343 … … 338 345 .wp-block[data-type="core/cover"][data-align="left"] .wp-block-cover, 339 346 .wp-block[data-type="core/cover"][data-align="right"] .wp-block-cover { 340 padding: 1rem;347 padding: calc(2.75 * 1rem) calc(2.75 * 1rem) calc(3.125 * 1rem); 341 348 } 342 349 } … … 761 768 /* Make sure our non-latin font overrides don't overwrite the iconfont used in the classic editor toolbar */ 762 769 .wp-block[data-type="core/freeform"] .mce-btn i { 763 764 } 770 font-family: dashicons !important; 771 } -
trunk/src/wp-content/themes/twentynineteen/style-editor.scss
r44302 r44305 295 295 width: 100%; 296 296 max-width: 100%; 297 } 298 299 @include media(tablet) { 300 301 .wp-block-cover { 302 padding: $size__spacing-unit; 297 padding: calc(1.375 * #{$size__spacing-unit}); 298 299 p { 300 padding-left: 0; 301 padding-right: 0; 302 } 303 304 @include media(tablet) { 305 padding: calc(2.75 * #{$size__spacing-unit}) calc(2.75 * #{$size__spacing-unit}) calc(3.125 * #{$size__spacing-unit}); 303 306 } 304 307 } -
trunk/src/wp-content/themes/twentynineteen/style-rtl.css
r44302 r44305 3766 3766 margin-bottom: calc(4.33 * 1rem); 3767 3767 margin-left: 0; 3768 padding-right: 0; 3768 3769 } 3769 3770 … … 3805 3806 3806 3807 .entry .entry-content .wp-block-pullquote.alignleft blockquote, .entry .entry-content .wp-block-pullquote.alignright blockquote { 3807 margin -right:0;3808 margin: 1rem 0; 3808 3809 padding: 0; 3809 3810 text-align: right; 3810 3811 max-width: 100%; 3812 } 3813 3814 .entry .entry-content .wp-block-pullquote.alignleft blockquote p:first-child, .entry .entry-content .wp-block-pullquote.alignright blockquote p:first-child { 3815 margin-top: 0; 3811 3816 } 3812 3817 … … 3846 3851 3847 3852 .entry .entry-content .wp-block-pullquote.is-style-solid-color blockquote { 3848 max-width: calc(100% - (2 * 1rem));3853 max-width: 100%; 3849 3854 color: #fff; 3850 3855 padding-right: 0; 3851 3856 margin-right: 1rem; 3857 margin-left: 1rem; 3852 3858 } 3853 3859 … … 3861 3867 margin-right: 0; 3862 3868 margin-left: 0; 3869 } 3870 } 3871 3872 @media only screen and (min-width: 768px) { 3873 .entry .entry-content .wp-block-pullquote.is-style-solid-color.alignright, .entry .entry-content .wp-block-pullquote.is-style-solid-color.alignleft { 3874 padding: 1rem calc(2 * 1rem); 3863 3875 } 3864 3876 } … … 3968 3980 padding: 0; 3969 3981 color: #fff; 3970 -ms-hyphens: auto;3971 -moz-hyphens: auto;3972 -webkit-hyphens: auto;3973 hyphens: auto;3974 3982 } 3975 3983 … … 3996 4004 .entry .entry-content .wp-block-cover.alignleft, 3997 4005 .entry .entry-content .wp-block-cover.alignright { 3998 padding: 1rem ;4006 padding: 1rem calc(2 * 1rem); 3999 4007 } 4000 4008 } … … 4046 4054 .entry .entry-content .wp-block-gallery .blocks-gallery-item:last-child { 4047 4055 margin-bottom: 16px; 4056 } 4057 4058 .entry .entry-content .wp-block-gallery figcaption a { 4059 color: #fff; 4048 4060 } 4049 4061 -
trunk/src/wp-content/themes/twentynineteen/style.css
r44302 r44305 3778 3778 margin-bottom: calc(4.33 * 1rem); 3779 3779 margin-right: 0; 3780 padding-left: 0; 3780 3781 } 3781 3782 … … 3817 3818 3818 3819 .entry .entry-content .wp-block-pullquote.alignleft blockquote, .entry .entry-content .wp-block-pullquote.alignright blockquote { 3819 margin -left:0;3820 margin: 1rem 0; 3820 3821 padding: 0; 3821 3822 text-align: left; 3822 3823 max-width: 100%; 3824 } 3825 3826 .entry .entry-content .wp-block-pullquote.alignleft blockquote p:first-child, .entry .entry-content .wp-block-pullquote.alignright blockquote p:first-child { 3827 margin-top: 0; 3823 3828 } 3824 3829 … … 3858 3863 3859 3864 .entry .entry-content .wp-block-pullquote.is-style-solid-color blockquote { 3860 max-width: calc(100% - (2 * 1rem));3865 max-width: 100%; 3861 3866 color: #fff; 3862 3867 padding-left: 0; 3863 3868 margin-left: 1rem; 3869 margin-right: 1rem; 3864 3870 } 3865 3871 … … 3873 3879 margin-left: 0; 3874 3880 margin-right: 0; 3881 } 3882 } 3883 3884 @media only screen and (min-width: 768px) { 3885 .entry .entry-content .wp-block-pullquote.is-style-solid-color.alignright, .entry .entry-content .wp-block-pullquote.is-style-solid-color.alignleft { 3886 padding: 1rem calc(2 * 1rem); 3875 3887 } 3876 3888 } … … 3980 3992 padding: 0; 3981 3993 color: #fff; 3982 -ms-hyphens: auto;3983 -moz-hyphens: auto;3984 -webkit-hyphens: auto;3985 hyphens: auto;3986 3994 } 3987 3995 … … 4008 4016 .entry .entry-content .wp-block-cover.alignleft, 4009 4017 .entry .entry-content .wp-block-cover.alignright { 4010 padding: 1rem ;4018 padding: 1rem calc(2 * 1rem); 4011 4019 } 4012 4020 } … … 4058 4066 .entry .entry-content .wp-block-gallery .blocks-gallery-item:last-child { 4059 4067 margin-bottom: 16px; 4068 } 4069 4070 .entry .entry-content .wp-block-gallery figcaption a { 4071 color: #fff; 4060 4072 } 4061 4073 -
trunk/src/wp-content/themes/twentynineteen/template-parts/post/author-bio.php
r44149 r44305 11 11 <div class="author-bio"> 12 12 <h2 class="author-title"> 13 <span class="author-heading"><?php echo esc_html( sprintf( __( 'Published by %s', 'twentynineteen' ), get_the_author() ) ); ?></span> 13 <span class="author-heading"> 14 <?php 15 printf( 16 /* translators: %s: post author */ 17 __( 'Published by %s', 'twentynineteen' ), 18 esc_html( get_the_author() ) 19 ); 20 ?> 21 </span> 14 22 </h2> 15 23 <p class="author-description"> -
trunk/src/wp-content/themes/twentynineteen/template-parts/post/discussion-meta.php
r44149 r44305 18 18 $meta_label = __( 'No comments', 'twentynineteen' ); 19 19 } 20 21 20 ?> 22 21
Note: See TracChangeset
for help on using the changeset viewer.