<?php
/**
 * Template part for displaying a post's header
 *
 * @package code4rest
 */

namespace Code4rest;

$classes   = array();
$classes[] = 'entry-header';
if ( is_singular( get_post_type() ) ) {
	$classes[] = get_post_type() . '-title';
	$classes[] = 'title-align-' . ( code4rest()->sub_option( get_post_type() . '_title_align', 'desktop' ) ? code4rest()->sub_option( get_post_type() . '_title_align', 'desktop' ) : 'inherit' );
	$classes[] = 'title-tablet-align-' . ( code4rest()->sub_option( get_post_type() . '_title_align', 'tablet' ) ? code4rest()->sub_option( get_post_type() . '_title_align', 'tablet' ) : 'inherit' );
	$classes[] = 'title-mobile-align-' . ( code4rest()->sub_option( get_post_type() . '_title_align', 'mobile' ) ? code4rest()->sub_option( get_post_type() . '_title_align', 'mobile' ) : 'inherit' );
}
?>
<header class="<?php echo esc_attr( implode( ' ', $classes ) ); ?>">
	<?php
	do_action( 'code4rest_single_before_entry_header' );
	/**
	 * Code4rest Entry Header
	 *
	 * Hooked code4rest_entry_header 10
	 */
	do_action( 'code4rest_entry_header', get_post_type(), 'normal' );
	
	do_action( 'code4rest_single_after_entry_header' );
	?>
</header><!-- .entry-header -->
