<?php
/** Generic loop content. @package Fragrance_Trade */
if ( ! defined( 'ABSPATH' ) ) {
	exit;
}

?>
<article id="post-<?php the_ID(); ?>" <?php post_class( 'fragrance-entry' ); ?>>
	<header class="entry-header mb-3">
		<?php if ( is_singular() ) : ?>
			<?php the_title( '<h1 class="entry-title">', '</h1>' ); ?>
		<?php else : ?>
			<?php the_title( '<h2 class="entry-title"><a href="' . esc_url( get_permalink() ) . '" rel="bookmark">', '</a></h2>' ); ?>
		<?php endif; ?>
		<?php if ( 'post' === get_post_type() ) : ?>
			<div class="entry-meta text-secondary"><?php echo esc_html( get_the_date() ); ?></div>
		<?php endif; ?>
	</header>
	<?php if ( has_post_thumbnail() ) : ?>
		<div class="entry-thumbnail mb-4"><?php the_post_thumbnail( 'large', array( 'class' => 'img-fluid' ) ); ?></div>
	<?php endif; ?>
	<div class="entry-content">
		<?php is_singular() ? the_content() : the_excerpt(); ?>
		<?php wp_link_pages(); ?>
	</div>
</article>
