[ Index ]

PHP Cross Reference of WordPress

title

Body

[close]

/wp-content/themes/twentysixteen/inc/ -> block-patterns.php (source)

   1  <?php
   2  /**
   3   * Twenty Sixteen Theme: Block Patterns
   4   *
   5   * @package WordPress
   6   * @subpackage Twenty_Sixteen
   7   * @since Twenty Sixteen 2.3
   8   */
   9  
  10  /**
  11   * Register Block Pattern Category.
  12   */
  13  if ( function_exists( 'register_block_pattern_category' ) ) {
  14  
  15      register_block_pattern_category(
  16          'twentysixteen',
  17          array( 'label' => __( 'Twenty Sixteen', 'twentysixteen' ) )
  18      );
  19  }
  20  
  21  /**
  22   * Register Block Patterns.
  23   */
  24  if ( function_exists( 'register_block_pattern' ) ) {
  25      register_block_pattern(
  26          'twentysixteen/large-heading-short-description',
  27          array(
  28              'title'      => __( 'Large heading with short description', 'twentysixteen' ),
  29              'categories' => array( 'twentysixteen' ),
  30              'content'    => '<!-- wp:group {"align":"full","backgroundColor":"background"} -->
  31              <div class="wp-block-group alignfull has-background-background-color has-background"><div class="wp-block-group__inner-container"><!-- wp:spacer {"height":60} -->
  32              <div style="height:60px" aria-hidden="true" class="wp-block-spacer"></div>
  33              <!-- /wp:spacer -->
  34              <!-- wp:heading {"level":6,"style":{"typography":{"lineHeight":"1.5","fontSize":35}}} -->
  35              <h6 style="font-size:35px;line-height:1.5"><strong>' . esc_html__( 'Twenty Sixteen is a modern take on the horizontal masthead with an optional right sidebar. It works perfectly for WordPress websites and blogs.', 'twentysixteen' ) . '</strong></h6>
  36              <!-- /wp:heading -->
  37              <!-- wp:paragraph {"style":{"typography":{"lineHeight":"1.8"}}} -->
  38              <p style="line-height:1.8">' . esc_html__( 'Twenty Sixteen will make your WordPress website look beautiful everywhere. Take advantage of custom color options, beautiful default color schemes, a harmonious fluid grid using a mobile-first approach, and impeccable polish in every detail.', 'twentysixteen' ) . '</p>
  39              <!-- /wp:paragraph -->
  40              <!-- wp:spacer {"height":60} -->
  41              <div style="height:60px" aria-hidden="true" class="wp-block-spacer"></div>
  42              <!-- /wp:spacer --></div></div>
  43              <!-- /wp:group -->',
  44          )
  45      );
  46  
  47      register_block_pattern(
  48          'twentysixteen/big-title-two-columns-text',
  49          array(
  50              'title'      => __( 'Big Title with Two Columns Text', 'twentysixteen' ),
  51              'categories' => array( 'twentysixteen' ),
  52              'content'    => '<!-- wp:spacer -->
  53              <div style="height:100px" aria-hidden="true" class="wp-block-spacer"></div>
  54              <!-- /wp:spacer -->
  55  
  56              <!-- wp:heading {"level":1,"style":{"typography":{"fontSize":55}}} -->
  57              <h1 style="font-size:55px">' . esc_html__( 'Twenty Sixteen' ) . '</h1>
  58              <!-- /wp:heading -->
  59  
  60              <!-- wp:spacer {"height":30} -->
  61              <div style="height:30px" aria-hidden="true" class="wp-block-spacer"></div>
  62              <!-- /wp:spacer -->
  63  
  64              <!-- wp:columns -->
  65              <div class="wp-block-columns"><!-- wp:column -->
  66              <div class="wp-block-column"><!-- wp:paragraph {"dropCap":true} -->
  67              <p class="has-drop-cap">' . esc_html__( 'Twenty Sixteen will make your WordPress website look beautiful everywhere. Take advantage of its custom color options and beautiful default color schemes.', 'twentysixteen' ) . '</p>
  68              <!-- /wp:paragraph --></div>
  69              <!-- /wp:column -->
  70  
  71              <!-- wp:column -->
  72              <div class="wp-block-column"><!-- wp:paragraph -->
  73              <p>' . esc_html__( 'The theme features a harmonious fluid grid using a mobile-first approach. The layout is a modern take on the horizontal masthead with an optional right sidebar.', 'twentysixteen' ) . '</p>
  74              <!-- /wp:paragraph --></div>
  75              <!-- /wp:column --></div>
  76              <!-- /wp:columns -->
  77  
  78              <!-- wp:spacer -->
  79              <div style="height:100px" aria-hidden="true" class="wp-block-spacer"></div>
  80              <!-- /wp:spacer -->',
  81          )
  82      );
  83  
  84      register_block_pattern(
  85          'twentysixteen/large-blockquote',
  86          array(
  87              'title'      => __( 'Large Blockquote', 'twentysixteen' ),
  88              'categories' => array( 'twentysixteen' ),
  89              'content'    => '<!-- wp:spacer -->
  90              <div style="height:100px" aria-hidden="true" class="wp-block-spacer"></div>
  91              <!-- /wp:spacer -->
  92  
  93              <!-- wp:separator {"color":"dark-gray","className":"is-style-wide"} -->
  94              <hr class="wp-block-separator has-text-color has-background has-dark-gray-background-color has-dark-gray-color is-style-wide"/>
  95              <!-- /wp:separator -->
  96  
  97              <!-- wp:heading {"style":{"typography":{"lineHeight":"1.5","fontSize":40}}} -->
  98              <h2 style="font-size:40px;line-height:1.5"><em>' . esc_html__( 'Twenty Sixteen will make your WordPress look beautiful everywhere.', 'twentysixteen' ) . '</em></h2>
  99              <!-- /wp:heading -->
 100  
 101              <!-- wp:paragraph {"textColor":"medium-gray"} -->
 102              <p class="has-medium-gray-color has-text-color">' . esc_html__( '— Takashi Irie', 'twentysixteen' ) . '</p>
 103              <!-- /wp:paragraph -->
 104  
 105              <!-- wp:spacer {"height":52} -->
 106              <div style="height:52px" aria-hidden="true" class="wp-block-spacer"></div>
 107              <!-- /wp:spacer -->
 108  
 109              <!-- wp:separator {"color":"dark-gray","className":"is-style-wide"} -->
 110              <hr class="wp-block-separator has-text-color has-background has-dark-gray-background-color has-dark-gray-color is-style-wide"/>
 111              <!-- /wp:separator -->
 112  
 113              <!-- wp:spacer -->
 114              <div style="height:100px" aria-hidden="true" class="wp-block-spacer"></div>
 115              <!-- /wp:spacer -->',
 116          )
 117      );
 118  
 119      register_block_pattern(
 120          'twentysixteen/call-to-action',
 121          array(
 122              'title'      => __( 'Call to Action', 'twentysixteen' ),
 123              'categories' => array( 'twentysixteen' ),
 124              'content'    => '<!-- wp:spacer -->
 125              <div style="height:100px" aria-hidden="true" class="wp-block-spacer"></div>
 126              <!-- /wp:spacer -->
 127  
 128              <!-- wp:separator {"color":"dark-gray","className":"is-style-wide"} -->
 129              <hr class="wp-block-separator has-text-color has-background has-dark-gray-background-color has-dark-gray-color is-style-wide"/>
 130              <!-- /wp:separator -->
 131  
 132              <!-- wp:heading {"level":1,"style":{"typography":{"fontSize":35,"lineHeight":"1.5"}}} -->
 133              <h1 style="font-size:35px;line-height:1.5">' . esc_html__( 'My new book “Twenty Sixteen” is available for pre-order.', 'twentysixteen' ) . '</h1>
 134              <!-- /wp:heading -->
 135  
 136              <!-- wp:columns -->
 137              <div class="wp-block-columns"><!-- wp:column -->
 138              <div class="wp-block-column"><!-- wp:buttons -->
 139              <div class="wp-block-buttons"><!-- wp:button {"borderRadius":0,"backgroundColor":"bright-blue"} -->
 140              <div class="wp-block-button"><a class="wp-block-button__link has-bright-blue-background-color has-background no-border-radius">' . esc_html__( 'Pre-Order Now', 'twentysixteen' ) . '</a></div>
 141              <!-- /wp:button --></div>
 142              <!-- /wp:buttons --></div>
 143              <!-- /wp:column -->
 144  
 145              <!-- wp:column -->
 146              <div class="wp-block-column"><!-- wp:spacer {"height":54} -->
 147              <div style="height:54px" aria-hidden="true" class="wp-block-spacer"></div>
 148              <!-- /wp:spacer --></div>
 149              <!-- /wp:column --></div>
 150              <!-- /wp:columns -->
 151  
 152              <!-- wp:spacer -->
 153              <div style="height:100px" aria-hidden="true" class="wp-block-spacer"></div>
 154              <!-- /wp:spacer -->',
 155          )
 156      );
 157  }


Generated: Sun Nov 24 01:00:02 2024 Cross-referenced by PHPXref 0.7.1