Make WordPress Core

Ticket #51106: 51106.1.diff

File 51106.1.diff, 11.9 KB (added by audrasjb, 4 years ago)

Translation strings update

  • src/wp-content/themes/twentyeleven/functions.php

    diff --git a/src/wp-content/themes/twentyeleven/functions.php b/src/wp-content/themes/twentyeleven/functions.php
    index ae11ca26b0..a26db9eba9 100644
    a b if ( ! function_exists( 'twentyeleven_setup' ) ) : 
    137137                // Grab Twenty Eleven's Ephemera widget.
    138138                require get_template_directory() . '/inc/widgets.php';
    139139
     140                // Load block patterns.
     141                require get_template_directory() . '/inc/block-patterns.php';
     142
    140143                // Add default posts and comments RSS feed links to <head>.
    141144                add_theme_support( 'automatic-feed-links' );
    142145
  • new file src/wp-content/themes/twentyeleven/inc/block-patterns.php

    diff --git a/src/wp-content/themes/twentyeleven/inc/block-patterns.php b/src/wp-content/themes/twentyeleven/inc/block-patterns.php
    new file mode 100644
    index 0000000000..faf41490eb
    - +  
     1<?php
     2/**
     3 * Block Patterns
     4 *
     5 * @link https://developer.wordpress.org/reference/functions/register_block_pattern/
     6 * @link https://developer.wordpress.org/reference/functions/register_block_pattern_category/
     7 *
     8 * @package WordPress
     9 * @subpackage Twenty_Eleven
     10 * @since Twenty Eleven 1.0
     11 */
     12
     13 /**
     14 * Register Block Pattern Category.
     15 */
     16if ( function_exists( 'register_block_pattern_category' ) ) {
     17
     18        register_block_pattern_category(
     19                'twentyeleven',
     20                array( 'label' => esc_html__( 'Twenty Eleven', 'twentyeleven' ) )
     21        );
     22}
     23
     24/**
     25 * Register Block Patterns.
     26 */
     27if ( function_exists( 'register_block_pattern' ) ) {
     28
     29        // Heading, and two columns featuring an image and dropcap.
     30        register_block_pattern(
     31                'twentyeleven/large-text',
     32                array(
     33                        'title'         => esc_html__( 'Image and Text Columns', 'twentyeleven' ),
     34                        'categories'    => array( 'twentyeleven' ),
     35                        'viewportWidth' => 1000,
     36                        'content'       => '<!-- wp:heading {"style":{"typography":{"fontSize":45}}} -->
     37                                <h2 style="font-size:45px">' . esc_html__( 'A Bowl Full of&nbsp;Flowers', 'twentyeleven' ) . '</h2>
     38                                <!-- /wp:heading -->
     39                                <!-- wp:columns -->
     40                                <div class="wp-block-columns"><!-- wp:column -->
     41                                <div class="wp-block-column"><!-- wp:image {"id":38,"sizeSlug":"large","linkDestination":"none"} -->
     42                                <figure class="wp-block-image size-large"><img src="' . get_stylesheet_directory_uri() . '/images/patterns/pattern-flower.jpg" alt="' . esc_attr( 'A yellow flower against a dark background.', 'twentyeleven' ) . '" /></figure>
     43                                <!-- /wp:image -->
     44                                <!-- wp:paragraph {"dropCap":true} -->
     45                                <p class="has-drop-cap">' . esc_html__( 'This is just an example post to showcase the featured post section on the showcase page. Who doesn&#8217;t like flowers? I like flowers. Nullam hendrerit enim nunc. Vestibulum eget nulla magna! Fusce lobortis neque eu neque egestas tincidunt. Duis elementum consequat lorem, in eleifend justo mollis at. Nam quis adipiscing magna. Duis adipiscing est ac nibh feugiat rhoncus. Donec non lorem felis, eget commodo purus.', 'twentyeleven' ) . '</p>
     46                                <!-- /wp:paragraph --></div>
     47                                <!-- /wp:column -->
     48                                <!-- wp:column {"width":"40%"} -->
     49                                <div class="wp-block-column" style="flex-basis:40%"><!-- wp:paragraph -->
     50                                <p>' . esc_html__( 'Aenean euismod elementum nisi quis eleifend. Lectus quam id leo in vitae turpis. Etiam tempor orci eu lobortis elementum nibh. At quis risus sed vulputate odio ut enim blandit. Id ornare arcu odio ut. Blandit massa enim nec dui nunc mattis enim ut tellus. Fermentum iaculis eu non diam phasellus vestibulum. Magna fermentum iaculis eu non diam phasellus vestibulum lorem. Ullamcorper velit sed ullamcorper morbi tincidunt ornare massa. Cursus sit amet dictum sit amet justo donec. At tellus at urna condimentum mattis. Et ligula ullamcorper malesuada proin libero nunc. Ipsum dolor sit amet consectetur adipiscing elit duis tristique sollicitudin. Pellentesque diam volutpat commodo sed egestas. Mi proin sed libero enim sed faucibus.', 'twentyeleven' ) . '</p>
     51                                <!-- /wp:paragraph --></div>
     52                                <!-- /wp:column --></div>
     53                                <!-- /wp:columns -->',
     54                )
     55        );
     56
     57        // Two columns with a quote.
     58        register_block_pattern(
     59                'twentyeleven/inline-quote',
     60                array(
     61                        'title'         => esc_html__( 'Inline Quote', 'twentyeleven' ),
     62                        'categories'    => array( 'twentyeleven' ),
     63                        'viewportWidth' => 1000,
     64                        'content'       => '<!-- wp:columns -->
     65                                <div class="wp-block-columns"><!-- wp:column -->
     66                                <div class="wp-block-column"><!-- wp:paragraph -->
     67                                <p>' . esc_html__( 'This is just an example post to showcase the featured post section on the showcase page. Who doesn&#8217;t like flowers? I like flowers. Nullam hendrerit enim nunc. Vestibulum eget nulla magna! Fusce lobortis neque eu neque egestas tincidunt. Duis elementum consequat lorem, in eleifend justo mollis at. Nam quis adipiscing magna. Duis adipiscing est ac nibh feugiat rhoncus. Donec non lorem felis, eget commodo purus.', 'twentyeleven' ) . '</p>
     68                                <!-- /wp:paragraph --></div>
     69                                <!-- /wp:column -->
     70                                <!-- wp:column -->
     71                                <div class="wp-block-column"><!-- wp:separator {"color":"black","className":"is-style-wide"} -->
     72                                <hr class="wp-block-separator has-text-color has-background has-black-background-color has-black-color is-style-wide"/>
     73                                <!-- /wp:separator -->
     74                                <!-- wp:quote {"className":"is-style-large"} -->
     75                                <blockquote class="wp-block-quote is-style-large"><p><strong><em>' . esc_html__( '"There are always flowers for those who want to see them."', 'twentyeleven' ) . '</em></strong></p><cite>Henri Matisse</cite></blockquote>
     76                                <!-- /wp:quote --></div>
     77                                <!-- /wp:column --></div>
     78                                <!-- /wp:columns -->',
     79                )
     80        );
     81
     82        // Cover block with a call-to-action to follow the blog.
     83        register_block_pattern(
     84                'twentyeleven/follow',
     85                array(
     86                        'title'         => esc_html__( 'Follow Blog', 'twentyeleven' ),
     87                        'categories'    => array( 'twentyeleven' ),
     88                        'viewportWidth' => 1000,
     89                        'content'       => '<!-- wp:cover {"overlayColor":"black","minHeight":900,"minHeightUnit":"px","align":"center"} -->
     90                                <div class="wp-block-cover aligncenter has-black-background-color has-background-dim" style="min-height:900px"><div class="wp-block-cover__inner-container"><!-- wp:paragraph {"align":"center","style":{"typography":{"fontSize":85}}} -->
     91                                <p class="has-text-align-center" style="font-size:85px">' . esc_html__( 'Get In Touch', 'twentyeleven' ) . '</p>
     92                                <!-- /wp:paragraph -->
     93                                <!-- wp:paragraph {"align":"center","style":{"typography":{"fontSize":25}}} -->
     94                                <p class="has-text-align-center" style="font-size:25px">' . esc_html__( 'Click to subscribe to this blog and receive notifications of new posts by email.', 'twentyeleven' ) . '</p>
     95                                <!-- /wp:paragraph -->
     96                                <!-- wp:paragraph {"align":"center","style":{"typography":{"fontSize":25}}} -->
     97                                <p class="has-text-align-center" style="font-size:25px">' . esc_html__( 'Join 1,729 other followers', 'twentyeleven' ) . '</p>
     98                                <!-- /wp:paragraph -->
     99                                <!-- wp:buttons {"contentJustification":"center"} -->
     100                                <div class="wp-block-buttons is-content-justification-center"><!-- wp:button {"borderRadius":0,"backgroundColor":"white","textColor":"black"} -->
     101                                <div class="wp-block-button"><a class="wp-block-button__link has-black-color has-white-background-color has-text-color has-background no-border-radius">' . esc_html__( 'Follow', 'twentyeleven' ) . '</a></div>
     102                                <!-- /wp:button --></div>
     103                                <!-- /wp:buttons --></div></div>
     104                                <!-- /wp:cover -->',
     105                )
     106        );
     107
     108        // Heading, and two columns with an image and text.
     109        register_block_pattern(
     110                'twentyeleven/about',
     111                array(
     112                        'title'         => esc_html__( 'About Me', 'twentyeleven' ),
     113                        'categories'    => array( 'twentyeleven' ),
     114                        'viewportWidth' => 1000,
     115                        'content'       => '<!-- wp:heading {"style":{"typography":{"fontSize":50}}} -->
     116                                <h2 style="font-size:50px">About Me</h2>
     117                                <!-- /wp:heading -->
     118                                <!-- wp:columns -->
     119                                <div class="wp-block-columns"><!-- wp:column -->
     120                                <div class="wp-block-column"><!-- wp:image {"id":31,"sizeSlug":"large","linkDestination":"none"} -->
     121                                <figure class="wp-block-image size-large"><img src="' . get_stylesheet_directory_uri() . '/images/patterns/pattern-woman.jpg" alt="' . esc_attr( 'Photo of a woman.', 'twentyeleven' ) . '" /></figure>
     122                                <!-- /wp:image --></div>
     123                                <!-- /wp:column -->
     124                                <!-- wp:column -->
     125                                <div class="wp-block-column"><!-- wp:paragraph -->
     126                                <p><strong>' . esc_html__( 'This is a paragraph to tell about yourself.</strong> Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Nulla porttitor massa id neque aliquam vestibulum morbi blandit cursus. Feugiat nisl pretium fusce id velit. Cursus risus at ultrices mi. Pellentesque nec nam aliquam sem et tortor consequat. Est lorem ipsum dolor sit amet consectetur adipiscing. Nisi porta lorem mollis aliquam. Aenean euismod elementum nisi quis eleifend quam adipiscing vitae proin. Malesuada bibendum arcu vitae elementum curabitur vitae nunc sed. Quis hendrerit dolor magna eget est lorem ipsum dolor sit. Viverra vitae congue eu consequat.', 'twentyeleven' ) . '</p>
     127                                <!-- /wp:paragraph --></div>
     128                                <!-- /wp:column --></div>
     129                                <!-- /wp:columns -->',
     130                )
     131        );
     132
     133        // Two columns with headings and lists.
     134        register_block_pattern(
     135                'twentyeleven/lists',
     136                array(
     137                        'title'         => esc_html__( 'Two Columns of Lists', 'twentyeleven' ),
     138                        'categories'    => array( 'twentyeleven' ),
     139                        'viewportWidth' => 1000,
     140                        'content'       => '<!-- wp:columns -->
     141                                <div class="wp-block-columns"><!-- wp:column -->
     142                                <div class="wp-block-column"><!-- wp:paragraph {"style":{"typography":{"fontSize":25}}} -->
     143                                <p style="font-size:25px"><strong>' . esc_html__( 'Books', 'twentyeleven' ) . '</strong></p>
     144                                <!-- /wp:paragraph -->
     145                                <!-- wp:list -->
     146                                <ul><li>' . esc_html__( 'Aenean euismod elementum, 1999', 'twentyeleven' ) . '</li><li>' . esc_html__( 'Nisi quis eleifend, 1999', 'twentyeleven' ) . '</li><li>' . esc_html__( 'Lectus quam id leo in vitae turpis, 2006', 'twentyeleven' ) . '</li><li>' . esc_html__( 'Etiam tempor orci eu lobortis, 2009', 'twentyeleven' ) . '</li><li>' . esc_html__( 'At quis risus sed vulputate odio ut enim, 2015', 'twentyeleven' ) . '</li><li>' . esc_html__( 'Blandit. Id ornare arcu odio ut, 2018', 'twentyeleven' ) . '</li><li>' . esc_html__( 'Aenean euismod elementum II, 2020', 'twentyeleven' ) . '</li></ul>
     147                                <!-- /wp:list --></div>
     148                                <!-- /wp:column -->
     149                                <!-- wp:column -->
     150                                <div class="wp-block-column"><!-- wp:paragraph {"style":{"typography":{"fontSize":25}}} -->
     151                                <p style="font-size:25px"><strong>' . esc_html__( 'Talks', 'twentyeleven' ) . '</strong></p>
     152                                <!-- /wp:paragraph -->
     153                                <!-- wp:list -->
     154                                <ul><li>' . esc_html__( 'Aenean euismod elementum', 'twentyeleven' ) . '</li><li>' . esc_html__( 'Nisi quis eleifend', 'twentyeleven' ) . '</li><li>' . esc_html__( 'Lectus quam id leo in vitae turpis', 'twentyeleven' ) . '</li><li>' . esc_html__( 'Etiam tempor orci eu lobortis', 'twentyeleven' ) . '</li><li>' . esc_html__( 'At quis risus sed vulputate odio ut enim', 'twentyeleven' ) . '</li><li>' . esc_html__( 'Blandit. Id ornare arcu odio ut', 'twentyeleven' ) . '</li><li>' . esc_html__( 'Aenean euismod elementum', 'twentyeleven' ) . '</li></ul>
     155                                <!-- /wp:list --></div>
     156                                <!-- /wp:column --></div>
     157                                <!-- /wp:columns -->',
     158                )
     159        );
     160
     161}
     162 No newline at end of file
  • src/wp-content/themes/twentyeleven/readme.txt

    diff --git a/src/wp-content/themes/twentyeleven/readme.txt b/src/wp-content/themes/twentyeleven/readme.txt
    index 1276e73f82..718be51ba5 100644
    a b HTML5 Shiv v3.7.0, Copyright 2014 Alexander Farkas 
    4141Licenses: MIT/GPL2
    4242Source: https://github.com/aFarkas/html5shiv
    4343
     44Images
     45"Yellow Flower Photo" by Bernard Spragg. CC0. https://stocksnap.io/photo/yellow-flower-GWT9JVALSV
     46"People Woman Photo" by Brooke Cagle. CC0. https://stocksnap.io/photo/people-woman-MU7G67710S
     47
    4448== Changelog ==
    4549
    4650= 3.7 =