forked from mirror/_s
Merge pull request #1140 from truongwp/patch-1
Correct code indentation to align with WordPress code standards
This commit is contained in:
commit
f349fc5ad7
|
@ -8,14 +8,14 @@
|
||||||
*/
|
*/
|
||||||
|
|
||||||
if ( ! function_exists( '_s_setup' ) ) :
|
if ( ! function_exists( '_s_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
|
||||||
* runs before the init hook. The init hook is too late for some features, such
|
* runs before the init hook. The init hook is too late for some features, such
|
||||||
* as indicating support for post thumbnails.
|
* as indicating support for post thumbnails.
|
||||||
*/
|
*/
|
||||||
function _s_setup() {
|
function _s_setup() {
|
||||||
/*
|
/*
|
||||||
* Make theme available for translation.
|
* Make theme available for translation.
|
||||||
* Translations can be filed in the /languages/ directory.
|
* Translations can be filed in the /languages/ directory.
|
||||||
|
@ -79,7 +79,7 @@ function _s_setup() {
|
||||||
'flex-width' => true,
|
'flex-width' => true,
|
||||||
'flex-height' => true,
|
'flex-height' => true,
|
||||||
) );
|
) );
|
||||||
}
|
}
|
||||||
endif;
|
endif;
|
||||||
add_action( 'after_setup_theme', '_s_setup' );
|
add_action( 'after_setup_theme', '_s_setup' );
|
||||||
|
|
||||||
|
|
|
@ -29,12 +29,12 @@ function _s_custom_header_setup() {
|
||||||
add_action( 'after_setup_theme', '_s_custom_header_setup' );
|
add_action( 'after_setup_theme', '_s_custom_header_setup' );
|
||||||
|
|
||||||
if ( ! function_exists( '_s_header_style' ) ) :
|
if ( ! function_exists( '_s_header_style' ) ) :
|
||||||
/**
|
/**
|
||||||
* Styles the header image and text displayed on the blog.
|
* Styles the header image and text displayed on the blog.
|
||||||
*
|
*
|
||||||
* @see _s_custom_header_setup().
|
* @see _s_custom_header_setup().
|
||||||
*/
|
*/
|
||||||
function _s_header_style() {
|
function _s_header_style() {
|
||||||
$header_text_color = get_header_textcolor();
|
$header_text_color = get_header_textcolor();
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
@ -68,5 +68,5 @@ function _s_header_style() {
|
||||||
<?php endif; ?>
|
<?php endif; ?>
|
||||||
</style>
|
</style>
|
||||||
<?php
|
<?php
|
||||||
}
|
}
|
||||||
endif;
|
endif;
|
||||||
|
|
|
@ -8,10 +8,10 @@
|
||||||
*/
|
*/
|
||||||
|
|
||||||
if ( ! function_exists( '_s_posted_on' ) ) :
|
if ( ! function_exists( '_s_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 _s_posted_on() {
|
function _s_posted_on() {
|
||||||
$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>';
|
||||||
|
@ -38,14 +38,14 @@ function _s_posted_on() {
|
||||||
|
|
||||||
echo '<span class="posted-on">' . $posted_on . '</span><span class="byline"> ' . $byline . '</span>'; // WPCS: XSS OK.
|
echo '<span class="posted-on">' . $posted_on . '</span><span class="byline"> ' . $byline . '</span>'; // WPCS: XSS OK.
|
||||||
|
|
||||||
}
|
}
|
||||||
endif;
|
endif;
|
||||||
|
|
||||||
if ( ! function_exists( '_s_entry_footer' ) ) :
|
if ( ! function_exists( '_s_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 _s_entry_footer() {
|
function _s_entry_footer() {
|
||||||
// Hide category and tag text for pages.
|
// Hide category and tag text for pages.
|
||||||
if ( 'post' === get_post_type() ) {
|
if ( 'post' === get_post_type() ) {
|
||||||
/* translators: used between list items, there is a space after the comma */
|
/* translators: used between list items, there is a space after the comma */
|
||||||
|
@ -98,5 +98,5 @@ function _s_entry_footer() {
|
||||||
'<span class="edit-link">',
|
'<span class="edit-link">',
|
||||||
'</span>'
|
'</span>'
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
endif;
|
endif;
|
||||||
|
|
Reference in New Issue