🐞 fix: Add switch to show back link on single post pages
This commit is contained in:
@@ -31,7 +31,10 @@ $wrapperStyle = $bgColor ? 'background-color: ' . esc_attr( $bgColor ) . ';' : '
|
|||||||
<?php Breadcrumbs::render(); ?>
|
<?php Breadcrumbs::render(); ?>
|
||||||
</div> -->
|
</div> -->
|
||||||
|
|
||||||
<?php if ( $heading ) : ?>
|
<?php
|
||||||
|
if ( ! is_single() ) :
|
||||||
|
if ( $heading ) :
|
||||||
|
?>
|
||||||
<h1 class="page-hero__heading flex-0">
|
<h1 class="page-hero__heading flex-0">
|
||||||
<?php echo wp_kses_post( $heading ); ?><em>.</em>
|
<?php echo wp_kses_post( $heading ); ?><em>.</em>
|
||||||
</h1>
|
</h1>
|
||||||
@@ -41,6 +44,14 @@ $wrapperStyle = $bgColor ? 'background-color: ' . esc_attr( $bgColor ) . ';' : '
|
|||||||
<div class="page-hero__intro grow text-18px pt-3">
|
<div class="page-hero__intro grow text-18px pt-3">
|
||||||
<?php echo wp_kses_post( $intro ); ?>
|
<?php echo wp_kses_post( $intro ); ?>
|
||||||
</div>
|
</div>
|
||||||
|
<?php
|
||||||
|
endif;
|
||||||
|
else :
|
||||||
|
?>
|
||||||
|
<a href="<?php echo esc_url( get_permalink( get_option( 'page_for_posts' ) ) ); ?>" class="page-hero__back-link flex items-center gap-2 text-20px font-bold text-cwc-blue-03! hover:text-cwc-blue-01!">
|
||||||
|
<span class=""><?php get_template_part( 'views/icons/prev', null, array( 'width' => 7, 'height' => 12 ) ); // phpcs:ignore ?></span>
|
||||||
|
<span>Back</span>
|
||||||
|
</a>
|
||||||
<?php endif; ?>
|
<?php endif; ?>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
Reference in New Issue
Block a user