From d0081b8cec8ca84ec091a746e41671f1039512ce Mon Sep 17 00:00:00 2001 From: agata <automa@insicuri.net> Date: Sat, 24 Apr 2021 21:44:34 +0200 Subject: [PATCH] [auto] theme: twentyeleven 3.7 --- wp-content/themes/twentyeleven/author.php | 2 +- wp-content/themes/twentyeleven/category.php | 2 +- .../themes/twentyeleven/content-featured.php | 26 ++--- .../themes/twentyeleven/content-gallery.php | 14 ++- .../themes/twentyeleven/content-image.php | 13 ++- .../themes/twentyeleven/content-quote.php | 14 ++- .../themes/twentyeleven/content-single.php | 36 ++++--- .../themes/twentyeleven/content-status.php | 2 +- wp-content/themes/twentyeleven/content.php | 8 +- .../themes/twentyeleven/editor-blocks.css | 102 ++++++++++++++---- wp-content/themes/twentyeleven/functions.php | 53 ++++----- wp-content/themes/twentyeleven/header.php | 13 +-- wp-content/themes/twentyeleven/image.php | 4 +- .../themes/twentyeleven/inc/theme-options.php | 22 ++-- .../themes/twentyeleven/inc/widgets.php | 2 +- wp-content/themes/twentyeleven/js/showcase.js | 4 +- .../twentyeleven/languages/twentyeleven.pot | 2 +- wp-content/themes/twentyeleven/readme.txt | 21 +++- wp-content/themes/twentyeleven/showcase.php | 2 +- wp-content/themes/twentyeleven/sidebar.php | 2 +- wp-content/themes/twentyeleven/style.css | 5 +- wp-content/themes/twentyeleven/tag.php | 2 +- 22 files changed, 229 insertions(+), 122 deletions(-) diff --git a/wp-content/themes/twentyeleven/author.php b/wp-content/themes/twentyeleven/author.php index 1711a8c73..0c3f90dab 100644 --- a/wp-content/themes/twentyeleven/author.php +++ b/wp-content/themes/twentyeleven/author.php @@ -53,7 +53,7 @@ get_header(); ?> <div id="author-avatar"> <?php /** - * Filter the Twenty Eleven author bio avatar size. + * Filters the Twenty Eleven author bio avatar size. * * @since Twenty Eleven 1.0 * diff --git a/wp-content/themes/twentyeleven/category.php b/wp-content/themes/twentyeleven/category.php index f37983166..1f7a81fbd 100644 --- a/wp-content/themes/twentyeleven/category.php +++ b/wp-content/themes/twentyeleven/category.php @@ -26,7 +26,7 @@ get_header(); ?> $category_description = category_description(); if ( ! empty( $category_description ) ) { /** - * Filter the default Twenty Eleven category description. + * Filters the default Twenty Eleven category description. * * @since Twenty Eleven 1.0 * diff --git a/wp-content/themes/twentyeleven/content-featured.php b/wp-content/themes/twentyeleven/content-featured.php index a909dfe90..98a0277fe 100644 --- a/wp-content/themes/twentyeleven/content-featured.php +++ b/wp-content/themes/twentyeleven/content-featured.php @@ -32,24 +32,26 @@ global $feature_class; <footer class="entry-meta"> <?php - /* translators: Used between list items, there is a space after the comma. */ - $tag_list = get_the_tag_list( '', __( ', ', 'twentyeleven' ) ); - if ( '' != $tag_list ) { + /* translators: Used between list items, there is a space after the comma. */ + $tags_list = get_the_tag_list( '', __( ', ', 'twentyeleven' ) ); + + if ( $tags_list && ! is_wp_error( $tags_list ) ) { /* translators: 1: Category list, 2: Tag list, 3: Post permalink, 4: Post title. */ $utility_text = __( 'This entry was posted in %1$s and tagged %2$s. Bookmark the <a href="%3$s" title="Permalink to %4$s" rel="bookmark">permalink</a>.', 'twentyeleven' ); } else { /* translators: 1: Category list, 3: Post permalink, 4: Post title. */ $utility_text = __( 'This entry was posted in %1$s. Bookmark the <a href="%3$s" title="Permalink to %4$s" rel="bookmark">permalink</a>.', 'twentyeleven' ); } - printf( - $utility_text, - /* translators: Used between list items, there is a space after the comma. */ - get_the_category_list( __( ', ', 'twentyeleven' ) ), - $tag_list, - esc_url( get_permalink() ), - the_title_attribute( 'echo=0' ) - ); - ?> + + printf( + $utility_text, + /* translators: Used between list items, there is a space after the comma. */ + get_the_category_list( __( ', ', 'twentyeleven' ) ), + $tags_list, + esc_url( get_permalink() ), + the_title_attribute( 'echo=0' ) + ); + ?> <?php edit_post_link( __( 'Edit', 'twentyeleven' ), '<span class="edit-link">', '</span>' ); ?> </footer><!-- .entry-meta --> diff --git a/wp-content/themes/twentyeleven/content-gallery.php b/wp-content/themes/twentyeleven/content-gallery.php index 6ee0b9fb5..f302dc8e5 100644 --- a/wp-content/themes/twentyeleven/content-gallery.php +++ b/wp-content/themes/twentyeleven/content-gallery.php @@ -70,9 +70,11 @@ <footer class="entry-meta"> <?php $show_sep = false; ?> + <?php - /* translators: Used between list items, there is a space after the comma. */ - $categories_list = get_the_category_list( __( ', ', 'twentyeleven' ) ); + /* translators: Used between list items, there is a space after the comma. */ + $categories_list = get_the_category_list( __( ', ', 'twentyeleven' ) ); + if ( $categories_list ) : ?> <span class="cat-links"> @@ -83,10 +85,12 @@ ?> </span> <?php endif; // End if categories. ?> + <?php - /* translators: Used between list items, there is a space after the comma. */ - $tags_list = get_the_tag_list( '', __( ', ', 'twentyeleven' ) ); - if ( $tags_list ) : + /* translators: Used between list items, there is a space after the comma. */ + $tags_list = get_the_tag_list( '', __( ', ', 'twentyeleven' ) ); + + if ( $tags_list && ! is_wp_error( $tags_list ) ) : if ( $show_sep ) : ?> <span class="sep"> | </span> diff --git a/wp-content/themes/twentyeleven/content-image.php b/wp-content/themes/twentyeleven/content-image.php index f458795fb..fbbfeaf13 100644 --- a/wp-content/themes/twentyeleven/content-image.php +++ b/wp-content/themes/twentyeleven/content-image.php @@ -55,8 +55,9 @@ </div><!-- .entry-meta --> <div class="entry-meta"> <?php - /* translators: Used between list items, there is a space after the comma. */ - $categories_list = get_the_category_list( __( ', ', 'twentyeleven' ) ); + /* translators: Used between list items, there is a space after the comma. */ + $categories_list = get_the_category_list( __( ', ', 'twentyeleven' ) ); + if ( $categories_list ) : ?> <span class="cat-links"> @@ -66,10 +67,12 @@ ?> </span> <?php endif; // End if categories. ?> + <?php - /* translators: Used between list items, there is a space after the comma. */ - $tags_list = get_the_tag_list( '', __( ', ', 'twentyeleven' ) ); - if ( $tags_list ) : + /* translators: Used between list items, there is a space after the comma. */ + $tags_list = get_the_tag_list( '', __( ', ', 'twentyeleven' ) ); + + if ( $tags_list && ! is_wp_error( $tags_list ) ) : ?> <span class="tag-links"> <?php diff --git a/wp-content/themes/twentyeleven/content-quote.php b/wp-content/themes/twentyeleven/content-quote.php index acc9c5f31..61430ce8d 100644 --- a/wp-content/themes/twentyeleven/content-quote.php +++ b/wp-content/themes/twentyeleven/content-quote.php @@ -46,9 +46,11 @@ <footer class="entry-meta"> <?php $show_sep = false; ?> + <?php - /* translators: Used between list items, there is a space after the comma. */ - $categories_list = get_the_category_list( __( ', ', 'twentyeleven' ) ); + /* translators: Used between list items, there is a space after the comma. */ + $categories_list = get_the_category_list( __( ', ', 'twentyeleven' ) ); + if ( $categories_list ) : ?> <span class="cat-links"> @@ -59,10 +61,12 @@ ?> </span> <?php endif; // End if categories. ?> + <?php - /* translators: Used between list items, there is a space after the comma. */ - $tags_list = get_the_tag_list( '', __( ', ', 'twentyeleven' ) ); - if ( $tags_list ) : + /* translators: Used between list items, there is a space after the comma. */ + $tags_list = get_the_tag_list( '', __( ', ', 'twentyeleven' ) ); + + if ( $tags_list && ! is_wp_error( $tags_list ) ) : if ( $show_sep ) : ?> <span class="sep"> | </span> diff --git a/wp-content/themes/twentyeleven/content-single.php b/wp-content/themes/twentyeleven/content-single.php index df8f9fdbe..1e32166a8 100644 --- a/wp-content/themes/twentyeleven/content-single.php +++ b/wp-content/themes/twentyeleven/content-single.php @@ -12,7 +12,7 @@ <header class="entry-header"> <h1 class="entry-title"><?php the_title(); ?></h1> - <?php if ( 'post' == get_post_type() ) : ?> + <?php if ( 'post' === get_post_type() ) : ?> <div class="entry-meta"> <?php twentyeleven_posted_on(); ?> </div><!-- .entry-meta --> @@ -33,15 +33,16 @@ <footer class="entry-meta"> <?php - /* translators: Used between list items, there is a space after the comma. */ - $categories_list = get_the_category_list( __( ', ', 'twentyeleven' ) ); + /* translators: Used between list items, there is a space after the comma. */ + $categories_list = get_the_category_list( __( ', ', 'twentyeleven' ) ); - /* translators: Used between list items, there is a space after the comma. */ - $tag_list = get_the_tag_list( '', __( ', ', 'twentyeleven' ) ); - if ( '' != $tag_list ) { + /* translators: Used between list items, there is a space after the comma. */ + $tags_list = get_the_tag_list( '', __( ', ', 'twentyeleven' ) ); + + if ( $tags_list && ! is_wp_error( $tags_list ) ) { /* translators: 1: Categories list, 2: Tag list, 3: Permalink, 4: Post title, 5: Author name, 6: Author URL. */ $utility_text = __( 'This entry was posted in %1$s and tagged %2$s by <a href="%6$s">%5$s</a>. Bookmark the <a href="%3$s" title="Permalink to %4$s" rel="bookmark">permalink</a>.', 'twentyeleven' ); - } elseif ( '' != $categories_list ) { + } elseif ( $categories_list ) { /* translators: 1: Categories list, 2: Tag list, 3: Permalink, 4: Post title, 5: Author name, 6: Author URL. */ $utility_text = __( 'This entry was posted in %1$s by <a href="%6$s">%5$s</a>. Bookmark the <a href="%3$s" title="Permalink to %4$s" rel="bookmark">permalink</a>.', 'twentyeleven' ); } else { @@ -49,16 +50,17 @@ $utility_text = __( 'This entry was posted by <a href="%6$s">%5$s</a>. Bookmark the <a href="%3$s" title="Permalink to %4$s" rel="bookmark">permalink</a>.', 'twentyeleven' ); } - printf( - $utility_text, - $categories_list, - $tag_list, - esc_url( get_permalink() ), - the_title_attribute( 'echo=0' ), - get_the_author(), - esc_url( get_author_posts_url( get_the_author_meta( 'ID' ) ) ) - ); - ?> + printf( + $utility_text, + $categories_list, + $tags_list, + esc_url( get_permalink() ), + the_title_attribute( 'echo=0' ), + get_the_author(), + esc_url( get_author_posts_url( get_the_author_meta( 'ID' ) ) ) + ); + ?> + <?php edit_post_link( __( 'Edit', 'twentyeleven' ), '<span class="edit-link">', '</span>' ); ?> <?php diff --git a/wp-content/themes/twentyeleven/content-status.php b/wp-content/themes/twentyeleven/content-status.php index da38a80b6..5a2f2f317 100644 --- a/wp-content/themes/twentyeleven/content-status.php +++ b/wp-content/themes/twentyeleven/content-status.php @@ -35,7 +35,7 @@ <div class="avatar"> <?php /** - * Filter the Twenty Eleven status avatar size. + * Filters the Twenty Eleven status avatar size. * * @since Twenty Eleven 1.0 * diff --git a/wp-content/themes/twentyeleven/content.php b/wp-content/themes/twentyeleven/content.php index 36ead6588..e002eb3c9 100644 --- a/wp-content/themes/twentyeleven/content.php +++ b/wp-content/themes/twentyeleven/content.php @@ -19,7 +19,7 @@ <h1 class="entry-title"><a href="<?php the_permalink(); ?>" rel="bookmark"><?php the_title(); ?></a></h1> <?php endif; ?> - <?php if ( 'post' == get_post_type() ) : ?> + <?php if ( 'post' === get_post_type() ) : ?> <div class="entry-meta"> <?php twentyeleven_posted_on(); ?> </div><!-- .entry-meta --> @@ -52,10 +52,12 @@ <footer class="entry-meta"> <?php $show_sep = false; ?> + <?php if ( is_object_in_taxonomy( get_post_type(), 'category' ) ) : // Hide category text when not supported. ?> <?php /* translators: Used between list items, there is a space after the comma. */ $categories_list = get_the_category_list( __( ', ', 'twentyeleven' ) ); + if ( $categories_list ) : ?> <span class="cat-links"> @@ -67,11 +69,13 @@ </span> <?php endif; // End if categories. ?> <?php endif; // End if is_object_in_taxonomy( get_post_type(), 'category' ). ?> + <?php if ( is_object_in_taxonomy( get_post_type(), 'post_tag' ) ) : // Hide tag text when not supported. ?> <?php /* translators: Used between list items, there is a space after the comma. */ $tags_list = get_the_tag_list( '', __( ', ', 'twentyeleven' ) ); - if ( $tags_list ) : + + if ( $tags_list && ! is_wp_error( $tags_list ) ) : if ( $show_sep ) : ?> <span class="sep"> | </span> diff --git a/wp-content/themes/twentyeleven/editor-blocks.css b/wp-content/themes/twentyeleven/editor-blocks.css index 8c56a7bcd..70cb813fc 100644 --- a/wp-content/themes/twentyeleven/editor-blocks.css +++ b/wp-content/themes/twentyeleven/editor-blocks.css @@ -12,6 +12,7 @@ Description: Used to style blocks in the editor. 4.0 Blocks - Formatting 5.0 Blocks - Layout Elements 6.0 Blocks - Widgets +7.0 Blocks - Colors --------------------------------------------------------------*/ /*-------------------------------------------------------------- @@ -95,11 +96,7 @@ Description: Used to style blocks in the editor. .block-library-list ul.editor-rich-text__tinymce, .edit-post-visual-editor ol, .editor-block-list__block ol, -.block-library-list ol.editor-rich-text__tinymce { - margin: 0 0 1.625em 2.5em; - padding: 0; -} - +.block-library-list ol.editor-rich-text__tinymce, .block-library-list .editor-rich-text__tinymce { padding: 0; } @@ -145,14 +142,22 @@ Description: Used to style blocks in the editor. margin-bottom: 0; } -.rtl .edit-post-visual-editor ul:not(.wp-block-gallery), -.rtl .editor-block-list__block ul:not(.wp-block-gallery), -.rtl .block-library-list ul, -.rtl .edit-post-visual-editor ol, -.rtl .editor-block-list__block ol, -.rtl .block-library-list ol { +.rtl .editor-styles-wrapper ul ul, +.rtl .editor-styles-wrapper ol ol, +.rtl .editor-styles-wrapper ul ol, +.rtl .editor-styles-wrapper ol ul { margin-left: 0; - margin-right: 1.3333em; + margin-right: 2.5em; +} + +.wp-block-freeform.block-library-rich-text__tinymce ul, +.wp-block-freeform.block-library-rich-text__tinymce ol { + padding-left: 2.5em; +} + +.rtl .wp-block-freeform.block-library-rich-text__tinymce ul, +.rtl .wp-block-freeform.block-library-rich-text__tinymce ol { + padding: 0; } /* Captions */ @@ -262,17 +267,19 @@ p.has-drop-cap:not(:focus)::first-letter { padding: 0; } -.edit-post-visual-editor .editor-block-list__block .wp-block-quote p { +.edit-post-visual-editor .editor-block-list__block .wp-block-quote p, +.editor-styles-wrapper .wp-block-quote p { font-family: Georgia, "Bitstream Charter", serif; } .wp-block-quote:not(.is-large):not(.is-style-large) { border: 0; - padding-left: 0; - padding-right: 0; + padding-left: 3em; + padding-right: 3em; } -.wp-block-quote .wp-block-quote__citation.editor-rich-text__tinymce.mce-content-body { +.wp-block-quote .wp-block-quote__citation.editor-rich-text__tinymce.mce-content-body, +.wp-block-quote .wp-block-quote__citation { color: #666; font-family: "Helvetica Neue", Helvetica, Arial, sans-serif; font-weight: 300; @@ -326,7 +333,7 @@ p.has-drop-cap:not(:focus)::first-letter { /* Code */ -.wp-block-code { +.editor-styles-wrapper .wp-block-code { background: transparent; border: 0; padding: 0; @@ -334,7 +341,8 @@ p.has-drop-cap:not(:focus)::first-letter { /* Pullquote */ -.edit-post-visual-editor .editor-block-list__block .wp-block-pullquote p { +.edit-post-visual-editor .editor-block-list__block .wp-block-pullquote p, +.editor-styles-wrapper .wp-block-pullquote p { font-family: Georgia, "Bitstream Charter", serif; font-style: italic; font-weight: normal; @@ -363,6 +371,12 @@ p.has-drop-cap:not(:focus)::first-letter { text-align: right; } +/* Verse */ + +.editor-styles-wrapper .wp-block-verse { + font-family: inherit; +} + /*-------------------------------------------------------------- 5.0 Blocks - Layout Elements @@ -471,3 +485,55 @@ p.has-drop-cap:not(:focus)::first-letter { margin-left: 0; margin-right: 0; } + +/*-------------------------------------------------------------- +7.0 Blocks - Colors +--------------------------------------------------------------*/ + +:root .editor-styles-wrapper .has-blue-color { + color: #1982d1; +} + +:root .editor-styles-wrapper .has-blue-background-color { + background-color: #1982d1; +} + +:root .editor-styles-wrapper .has-black-color { + color: #000; +} + +:root .editor-styles-wrapper .has-black-background-color { + background-color: #000; +} + +:root .editor-styles-wrapper .has-dark-gray-color { + color: #373737; +} + +:root .editor-styles-wrapper .has-dark-gray-background-color { + background-color: #373737; +} + +:root .editor-styles-wrapper .has-medium-gray-color { + color: #666; +} + +:root .editor-styles-wrapper .has-medium-gray-background-color { + background-color: #666; +} + +:root .editor-styles-wrapper .has-light-gray-color { + color: #e2e2e2; +} + +:root .editor-styles-wrapper .has-light-gray-background-color { + background-color: #e2e2e2; +} + +:root .editor-styles-wrapper .has-white-color { + color: #fff; +} + +:root .editor-styles-wrapper .has-white-background-color { + background-color: #fff; +} diff --git a/wp-content/themes/twentyeleven/functions.php b/wp-content/themes/twentyeleven/functions.php index 9ace59958..446c17f58 100644 --- a/wp-content/themes/twentyeleven/functions.php +++ b/wp-content/themes/twentyeleven/functions.php @@ -147,7 +147,7 @@ if ( ! function_exists( 'twentyeleven_setup' ) ) : add_theme_support( 'post-formats', array( 'aside', 'link', 'gallery', 'status', 'quote', 'image' ) ); $theme_options = twentyeleven_get_theme_options(); - if ( 'dark' == $theme_options['color_scheme'] ) { + if ( 'dark' === $theme_options['color_scheme'] ) { $default_background_color = '1d1d1d'; } else { $default_background_color = 'e2e2e2'; @@ -174,7 +174,7 @@ if ( ! function_exists( 'twentyeleven_setup' ) ) : 'default-text-color' => '000', // The height and width of our custom header. /** - * Filter the Twenty Eleven default header image width. + * Filters the Twenty Eleven default header image width. * * @since Twenty Eleven 1.0 * @@ -182,7 +182,7 @@ if ( ! function_exists( 'twentyeleven_setup' ) ) : */ 'width' => apply_filters( 'twentyeleven_header_image_width', 1000 ), /** - * Filter the Twenty Eleven default header image height. + * Filters the Twenty Eleven default header image height. * * @since Twenty Eleven 1.0 * @@ -305,7 +305,7 @@ add_action( 'wp_enqueue_scripts', 'twentyeleven_scripts_styles' ); */ function twentyeleven_block_editor_styles() { // Block styles. - wp_enqueue_style( 'twentyeleven-block-editor-style', get_template_directory_uri() . '/editor-blocks.css', array(), '20190102' ); + wp_enqueue_style( 'twentyeleven-block-editor-style', get_template_directory_uri() . '/editor-blocks.css', array(), '20201208' ); } add_action( 'enqueue_block_editor_assets', 'twentyeleven_block_editor_styles' ); @@ -328,7 +328,7 @@ if ( ! function_exists( 'twentyeleven_header_style' ) ) : <style type="text/css" id="twentyeleven-header-css"> <?php // Has the text been hidden? - if ( 'blank' == $text_color ) : + if ( 'blank' === $text_color ) : ?> #site-title, #site-description { @@ -471,7 +471,7 @@ endif; // twentyeleven_continue_reading_link() * @since Twenty Eleven 1.0 * * @param string $more The Read More text. - * @return The filtered Read More text. + * @return string The filtered Read More text. */ function twentyeleven_auto_excerpt_more( $more ) { if ( ! is_admin() ) { @@ -698,9 +698,9 @@ if ( ! function_exists( 'twentyeleven_comment' ) ) : * * @since Twenty Eleven 1.0 * - * @param object $comment The comment object. - * @param array $args An array of comment arguments. @see get_comment_reply_link() - * @param int $depth The depth of the comment. + * @param WP_Comment $comment The comment object. + * @param array $args An array of comment arguments. @see get_comment_reply_link() + * @param int $depth The depth of the comment. */ function twentyeleven_comment( $comment, $args, $depth ) { $GLOBALS['comment'] = $comment; @@ -719,28 +719,29 @@ if ( ! function_exists( 'twentyeleven_comment' ) ) : <footer class="comment-meta"> <div class="comment-author vcard"> <?php - $avatar_size = 68; + $avatar_size = 68; + if ( '0' != $comment->comment_parent ) { $avatar_size = 39; } - echo get_avatar( $comment, $avatar_size ); - - printf( - /* translators: 1: Comment author, 2: Date and time. */ - __( '%1$s on %2$s <span class="says">said:</span>', 'twentyeleven' ), - sprintf( '<span class="fn">%s</span>', get_comment_author_link() ), - sprintf( - '<a href="%1$s"><time datetime="%2$s">%3$s</time></a>', - esc_url( get_comment_link( $comment->comment_ID ) ), - get_comment_time( 'c' ), - /* translators: 1: Date, 2: Time. */ - sprintf( __( '%1$s at %2$s', 'twentyeleven' ), get_comment_date(), get_comment_time() ) - ) - ); + echo get_avatar( $comment, $avatar_size ); + + printf( + /* translators: 1: Comment author, 2: Date and time. */ + __( '%1$s on %2$s <span class="says">said:</span>', 'twentyeleven' ), + sprintf( '<span class="fn">%s</span>', get_comment_author_link() ), + sprintf( + '<a href="%1$s"><time datetime="%2$s">%3$s</time></a>', + esc_url( get_comment_link( $comment->comment_ID ) ), + get_comment_time( 'c' ), + /* translators: 1: Date, 2: Time. */ + sprintf( __( '%1$s at %2$s', 'twentyeleven' ), get_comment_date(), get_comment_time() ) + ) + ); ?> - <?php edit_comment_link( __( 'Edit', 'twentyeleven' ), '<span class="edit-link">', '</span>' ); ?> + <?php edit_comment_link( __( 'Edit', 'twentyeleven' ), '<span class="edit-link">', '</span>' ); ?> </div><!-- .comment-author .vcard --> <?php @@ -748,7 +749,7 @@ if ( ! function_exists( 'twentyeleven_comment' ) ) : if ( $commenter['comment_author_email'] ) { $moderation_note = __( 'Your comment is awaiting moderation.', 'twentyeleven' ); } else { - $moderation_note = __( 'Your comment is awaiting moderation. This is a preview, your comment will be visible after it has been approved.', 'twentyeleven' ); + $moderation_note = __( 'Your comment is awaiting moderation. This is a preview; your comment will be visible after it has been approved.', 'twentyeleven' ); } ?> diff --git a/wp-content/themes/twentyeleven/header.php b/wp-content/themes/twentyeleven/header.php index b29a33a3b..ef2db57fc 100644 --- a/wp-content/themes/twentyeleven/header.php +++ b/wp-content/themes/twentyeleven/header.php @@ -48,7 +48,7 @@ if ( ( $paged >= 2 || $page >= 2 ) && ! is_404() ) { ?> </title> -<link rel="profile" href="http://gmpg.org/xfn/11" /> +<link rel="profile" href="https://gmpg.org/xfn/11" /> <link rel="stylesheet" type="text/css" media="all" href="<?php bloginfo( 'stylesheet_url' ); ?>?ver=20190507" /> <link rel="pingback" href="<?php echo esc_url( get_bloginfo( 'pingback_url' ) ); ?>"> <!--[if lt IE 9]> @@ -103,12 +103,13 @@ if ( is_singular() && get_option( 'thread_comments' ) ) { * The header image. * Check if this is a post or page, if it has a thumbnail, and if it's a big one */ + $image = false; if ( is_singular() && has_post_thumbnail( $post->ID ) ) { $image = wp_get_attachment_image_src( get_post_thumbnail_id( $post->ID ), array( $header_image_width, $header_image_width ) ); - if ( $image && $image[1] >= $header_image_width ) { - // Houston, we have a new header image! - echo get_the_post_thumbnail( $post->ID, 'post-thumbnail' ); - } + } + if ( $image && $image[1] >= $header_image_width ) { + // Houston, we have a new header image! + echo get_the_post_thumbnail( $post->ID, 'post-thumbnail' ); } else { // Compatibility with versions of WordPress prior to 3.4. if ( function_exists( 'get_custom_header' ) ) { @@ -128,7 +129,7 @@ if ( is_singular() && get_option( 'thread_comments' ) ) { <?php // Has the text been hidden? - if ( 'blank' == get_header_textcolor() ) : + if ( 'blank' === get_header_textcolor() ) : $header_image_class = ''; if ( $header_image ) { $header_image_class = ' with-image'; diff --git a/wp-content/themes/twentyeleven/image.php b/wp-content/themes/twentyeleven/image.php index 7a23e1157..bf71d666b 100644 --- a/wp-content/themes/twentyeleven/image.php +++ b/wp-content/themes/twentyeleven/image.php @@ -32,7 +32,7 @@ get_header(); ?> $metadata = wp_get_attachment_metadata(); printf( /* translators: 1: Time, 2: Date, 3: Image permalink, 4: Image width, 5: Image height, 6: Parent permalink, 7: Parent post title, 8: Parent post title. */ - __( '<span class="meta-prep meta-prep-entry-date">Published </span> <span class="entry-date"><abbr class="published" title="%1$s">%2$s</abbr></span> at <a href="%3$s" title="Link to full-size image">%4$s × %5$s</a> in <a href="%6$s" title="Return to %7$s" rel="gallery">%8$s</a>', 'twentyeleven' ), + __( '<span class="meta-prep meta-prep-entry-date">Published </span> <span class="entry-date"><abbr class="published" title="%1$s">%2$s</abbr></span> at <a href="%3$s" title="Link to full-size image">%4$s × %5$s</a> in <a href="%6$s" title="Go to %7$s" rel="gallery">%8$s</a>', 'twentyeleven' ), esc_attr( get_the_time() ), get_the_date(), esc_url( wp_get_attachment_url() ), @@ -93,7 +93,7 @@ get_header(); ?> <a href="<?php echo esc_url( $next_attachment_url ); ?>" title="<?php the_title_attribute(); ?>" rel="attachment"> <?php /** - * Filter the Twenty Eleven default attachment size. + * Filters the Twenty Eleven default attachment size. * * @since Twenty Eleven 1.0 * diff --git a/wp-content/themes/twentyeleven/inc/theme-options.php b/wp-content/themes/twentyeleven/inc/theme-options.php index 025692e53..b88b2c362 100644 --- a/wp-content/themes/twentyeleven/inc/theme-options.php +++ b/wp-content/themes/twentyeleven/inc/theme-options.php @@ -162,7 +162,7 @@ function twentyeleven_color_schemes() { ); /** - * Filter the Twenty Eleven color scheme options. + * Filters the Twenty Eleven color scheme options. * * @since Twenty Eleven 1.0 * @@ -196,7 +196,7 @@ function twentyeleven_layouts() { ); /** - * Filter the Twenty Eleven layout options. + * Filters the Twenty Eleven layout options. * * @since Twenty Eleven 1.0 * @@ -224,7 +224,7 @@ function twentyeleven_get_default_theme_options() { } /** - * Filter the Twenty Eleven default options. + * Filters the Twenty Eleven default options. * * @since Twenty Eleven 1.0 * @@ -398,7 +398,7 @@ function twentyeleven_theme_options_validate( $input ) { } /** - * Filter the Twenty Eleven sanitized form input array. + * Filters the Twenty Eleven sanitized form input array. * * @since Twenty Eleven 1.0 * @@ -418,7 +418,7 @@ function twentyeleven_enqueue_color_scheme() { $options = twentyeleven_get_theme_options(); $color_scheme = $options['color_scheme']; - if ( 'dark' == $color_scheme ) { + if ( 'dark' === $color_scheme ) { wp_enqueue_style( 'dark', get_template_directory_uri() . '/colors/dark.css', array(), '20190404' ); } @@ -493,22 +493,22 @@ function twentyeleven_layout_classes( $existing_classes ) { $options = twentyeleven_get_theme_options(); $current_layout = $options['theme_layout']; - if ( in_array( $current_layout, array( 'content-sidebar', 'sidebar-content' ) ) ) { + if ( in_array( $current_layout, array( 'content-sidebar', 'sidebar-content' ), true ) ) { $classes = array( 'two-column' ); } else { $classes = array( 'one-column' ); } - if ( 'content-sidebar' == $current_layout ) { + if ( 'content-sidebar' === $current_layout ) { $classes[] = 'right-sidebar'; - } elseif ( 'sidebar-content' == $current_layout ) { + } elseif ( 'sidebar-content' === $current_layout ) { $classes[] = 'left-sidebar'; } else { $classes[] = $current_layout; } /** - * Filter the Twenty Eleven layout body classes. + * Filters the Twenty Eleven layout body classes. * * @since Twenty Eleven 1.0 * @@ -526,7 +526,7 @@ add_filter( 'body_class', 'twentyeleven_layout_classes' ); * * @since Twenty Eleven 1.3 * - * @param object $wp_customize Customizer object. + * @param WP_Customize_Manager $wp_customize Customizer object. */ function twentyeleven_customize_register( $wp_customize ) { $wp_customize->get_setting( 'blogname' )->transport = 'postMessage'; @@ -644,6 +644,7 @@ add_action( 'customize_register', 'twentyeleven_customize_register' ); * Render the site title for the selective refresh partial. * * @since Twenty Eleven 2.4 + * * @see twentyeleven_customize_register() * * @return void @@ -656,6 +657,7 @@ function twentyeleven_customize_partial_blogname() { * Render the site tagline for the selective refresh partial. * * @since Twenty Eleven 2.4 + * * @see twentyeleven_customize_register() * * @return void diff --git a/wp-content/themes/twentyeleven/inc/widgets.php b/wp-content/themes/twentyeleven/inc/widgets.php index 8c8541424..4d70ca8fc 100644 --- a/wp-content/themes/twentyeleven/inc/widgets.php +++ b/wp-content/themes/twentyeleven/inc/widgets.php @@ -111,7 +111,7 @@ class Twenty_Eleven_Ephemera_Widget extends WP_Widget { $ephemera->the_post(); ?> - <?php if ( 'link' != get_post_format() ) : ?> + <?php if ( 'link' !== get_post_format() ) : ?> <li class="widget-entry-title"> <a href="<?php echo esc_url( get_permalink() ); ?>" rel="bookmark"><?php the_title(); ?></a> diff --git a/wp-content/themes/twentyeleven/js/showcase.js b/wp-content/themes/twentyeleven/js/showcase.js index 89d523f0b..8699c5685 100644 --- a/wp-content/themes/twentyeleven/js/showcase.js +++ b/wp-content/themes/twentyeleven/js/showcase.js @@ -1,6 +1,6 @@ (function($) { $(document).ready( function() { - $('.feature-slider a').click(function(e) { + $('.feature-slider a').on( 'click', function(e) { $('.featured-posts section.featured-post').css({ opacity: 0, visibility: 'hidden' @@ -14,4 +14,4 @@ e.preventDefault(); }); }); -})(jQuery); \ No newline at end of file +})(jQuery); diff --git a/wp-content/themes/twentyeleven/languages/twentyeleven.pot b/wp-content/themes/twentyeleven/languages/twentyeleven.pot index 4a62f17b4..ff95eb5f3 100644 --- a/wp-content/themes/twentyeleven/languages/twentyeleven.pot +++ b/wp-content/themes/twentyeleven/languages/twentyeleven.pot @@ -441,7 +441,7 @@ msgid "Next →" msgstr "" #: image.php:34 -msgid "<span class=\"meta-prep meta-prep-entry-date\">Published </span> <span class=\"entry-date\"><abbr class=\"published\" title=\"%1$s\">%2$s</abbr></span> at <a href=\"%3$s\" title=\"Link to full-size image\">%4$s × %5$s</a> in <a href=\"%6$s\" title=\"Return to %7$s\" rel=\"gallery\">%8$s</a>" +msgid "<span class=\"meta-prep meta-prep-entry-date\">Published </span> <span class=\"entry-date\"><abbr class=\"published\" title=\"%1$s\">%2$s</abbr></span> at <a href=\"%3$s\" title=\"Link to full-size image\">%4$s × %5$s</a> in <a href=\"%6$s\" title=\"Go to %7$s\" rel=\"gallery\">%8$s</a>" msgstr "" #: inc/theme-options.php:56 inc/theme-options.php:564 diff --git a/wp-content/themes/twentyeleven/readme.txt b/wp-content/themes/twentyeleven/readme.txt index 3fb2a8b8d..0215a7d1b 100644 --- a/wp-content/themes/twentyeleven/readme.txt +++ b/wp-content/themes/twentyeleven/readme.txt @@ -1,8 +1,8 @@ === Twenty Eleven === Contributors: wordpressdotorg Requires at least: WordPress 3.2 -Tested up to: 5.0 -Stable tag: 3.4 +Tested up to: 5.6 +Stable tag: 3.7 License: GPLv2 or later License URI: http://www.gnu.org/licenses/gpl-2.0.html Tags: blog, one-column, two-columns, left-sidebar, right-sidebar, custom-background, custom-colors, custom-header, custom-menu, editor-style, featured-image-header, featured-images, flexible-header, footer-widgets, full-width-template, microformats, post-formats, rtl-language-support, sticky-post, theme-options, translation-ready @@ -22,7 +22,7 @@ For more information about Twenty Eleven please go to https://codex.wordpress.or == Copyright == -Twenty Eleven WordPress Theme, Copyright 2011-2020 WordPress.org & Automattic.com +Twenty Eleven WordPress Theme, Copyright 2011-2021 WordPress.org & Automattic.com Twenty Eleven is Distributed under the terms of the GNU GPL This program is free software: you can redistribute it and/or modify @@ -43,6 +43,21 @@ Source: https://github.com/aFarkas/html5shiv == Changelog == += 3.7 = +* Released: March 9, 2021 + +https://codex.wordpress.org/Twenty_Eleven_Theme_Changelog#Version_3.7 + += 3.6 = +* Released: December 8, 2020 + +https://codex.wordpress.org/Twenty_Eleven_Theme_Changelog#Version_3.6 + += 3.5 = +* Released: August 11, 2020 + +https://codex.wordpress.org/Twenty_Eleven_Theme_Changelog#Version_3.5 + = 3.4 = * Released: March 31, 2020 diff --git a/wp-content/themes/twentyeleven/showcase.php b/wp-content/themes/twentyeleven/showcase.php index c7b76446b..fa258dadc 100644 --- a/wp-content/themes/twentyeleven/showcase.php +++ b/wp-content/themes/twentyeleven/showcase.php @@ -33,7 +33,7 @@ get_header(); ?> * We are using a heading by rendering the_content * If we have content for this page, let's display it. */ - if ( '' != get_the_content() ) { + if ( '' !== get_the_content() ) { get_template_part( 'content', 'intro' ); } ?> diff --git a/wp-content/themes/twentyeleven/sidebar.php b/wp-content/themes/twentyeleven/sidebar.php index 3ff40988c..23736edfe 100644 --- a/wp-content/themes/twentyeleven/sidebar.php +++ b/wp-content/themes/twentyeleven/sidebar.php @@ -10,7 +10,7 @@ $options = twentyeleven_get_theme_options(); $current_layout = $options['theme_layout']; -if ( 'content' != $current_layout ) : +if ( 'content' !== $current_layout ) : ?> <div id="secondary" class="widget-area" role="complementary"> <?php if ( ! dynamic_sidebar( 'sidebar-1' ) ) : ?> diff --git a/wp-content/themes/twentyeleven/style.css b/wp-content/themes/twentyeleven/style.css index 34a9e6cce..e6993ad7c 100644 --- a/wp-content/themes/twentyeleven/style.css +++ b/wp-content/themes/twentyeleven/style.css @@ -4,7 +4,7 @@ Theme URI: https://wordpress.org/themes/twentyeleven/ Author: the WordPress team Author URI: https://wordpress.org/ Description: The 2011 theme for WordPress is sophisticated, lightweight, and adaptable. Make it yours with a custom menu, header image, and background -- then go further with available theme options for light or dark color scheme, custom link colors, and three layout choices. Twenty Eleven comes equipped with a Showcase page template that transforms your front page into a showcase to show off your best content, widget support galore (sidebar, three footer areas, and a Showcase page widget area), and a custom "Ephemera" widget to display your Aside, Link, Quote, or Status posts. Included are styles for print and for the admin editor, support for featured images (as custom header images on posts and pages and as large images on featured "sticky" posts), and special styles for six different post formats. -Version: 3.4 +Version: 3.7 Requires PHP: 5.2.4 License: GNU General Public License v2 or later License URI: http://www.gnu.org/licenses/gpl-2.0.html @@ -1846,6 +1846,9 @@ video { .widget a:active { text-decoration: underline; } +.widget select { + max-width: 100%; + } /* Search Widget */ .widget_search form { diff --git a/wp-content/themes/twentyeleven/tag.php b/wp-content/themes/twentyeleven/tag.php index f03f3efd4..43487f397 100644 --- a/wp-content/themes/twentyeleven/tag.php +++ b/wp-content/themes/twentyeleven/tag.php @@ -26,7 +26,7 @@ get_header(); ?> $tag_description = tag_description(); if ( ! empty( $tag_description ) ) { /** - * Filter the default Twenty Eleven tag description. + * Filters the default Twenty Eleven tag description. * * @since Twenty Eleven 1.0 * -- GitLab