Skip to content

Commit

Permalink
header changes
Browse files Browse the repository at this point in the history
  • Loading branch information
tronsymphony committed Nov 28, 2023
1 parent a1cc12c commit 3076b15
Show file tree
Hide file tree
Showing 5 changed files with 31 additions and 35 deletions.
2 changes: 1 addition & 1 deletion assets/css/main.css

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion assets/css/main.css.map

Large diffs are not rendered by default.

32 changes: 17 additions & 15 deletions assets/scss/partials/_singular.scss
Original file line number Diff line number Diff line change
Expand Up @@ -672,7 +672,7 @@ img.wprm-comment-rating {
&-details {
padding: 40px 0 0;
margin-bottom: 20px;
color: var(--Black, #000);
color: black;
font-size: 16px;
font-style: normal;
font-weight: 400;
Expand Down Expand Up @@ -867,7 +867,7 @@ img.wprm-comment-rating {

a {
background: #82BC46;
color: var(--Black, #000);
color: black;
text-align: center;
font-size: 14px;
font-style: normal;
Expand Down Expand Up @@ -945,7 +945,7 @@ img.wprm-comment-rating {
--------------------------------------------- */
.post_type_layout_standard {
.entry-content {
padding: 40px 0;
padding: 0px 0 40px;
}

}
Expand All @@ -963,12 +963,15 @@ img.wprm-comment-rating {
line-height: 24px;
}
}
.inner-hero {
margin-bottom: 40px;
}
}

.home {
.inner-hero {
@include media(">tablet") {
padding: 132px 0;
padding: 40px 0;
}
}
}
Expand All @@ -983,16 +986,16 @@ img.wprm-comment-rating {

.inner-hero {
background-color: brand-color('tertiary');
padding: 60px 0;
padding: 20px 0;
position: relative;
grid-column-start: 1;
grid-column-end: 13;
width: 100%;
min-height: 200px;
min-height: 140px;

@include media(">tablet") {
padding: 60px 0;
min-height: 280px;
padding: 40px 0;
min-height: 200px;
display: flex;
flex-direction: column;
justify-content: center;
Expand Down Expand Up @@ -1207,7 +1210,7 @@ img.wprm-comment-rating {
font-style: normal;
font-weight: 400;
line-height: 16px;
color: white;
color: black;

a {
color: inherit;
Expand Down Expand Up @@ -1472,7 +1475,7 @@ img.wprm-comment-rating {
max-width: 171px;

h2 {
color: var(--Black, #000);
color: black;
font-size: 16px;
font-style: normal;
font-weight: 700;
Expand All @@ -1481,7 +1484,7 @@ img.wprm-comment-rating {
}

&-container__copy {
color: var(--Black, #000);
color: black;
font-size: 14px;
font-style: normal;
font-weight: 400;
Expand Down Expand Up @@ -1678,7 +1681,7 @@ section.refinance_lender_section {
}

button.btn-text {
color: var(--Black, #000);
color: black;
text-align: center;
font-size: 14px;
font-style: normal;
Expand Down Expand Up @@ -1802,7 +1805,7 @@ section.refinance_lender_section {
}

.author_name {
color: var(--Black, #000);
color: black;
font-size: 18px;
font-style: normal;
font-weight: 600;
Expand Down Expand Up @@ -1833,12 +1836,11 @@ section.refinance_lender_section {
}

&_author_entry-data {
color: var(--Black, #000);
color: black;
font-size: 16px;
font-style: normal;
font-weight: 400;
line-height: 24px;
/* 150% */
}

&_author_entry-info {
Expand Down
21 changes: 4 additions & 17 deletions inc/loop.php
Original file line number Diff line number Diff line change
Expand Up @@ -92,11 +92,15 @@ function eqd_single_header() {
$link = get_field( 'single_post_link', $page_id );
$output = null;
$container_class = '';

if ( get_field( 'post_format_style' ) == 'full-width' ) {
$container_class .= 'hero_relative';
} else {
$container_class .= 'inner-hero-alternate-style';
}
if ( get_field( 'post_format_style' ) == 'full-width' ) {
$container_class .= ' inner-hero-alternate-style';
}
?>
<header class="inner-hero <?php echo wp_kses_post( $container_class ); ?>">
<div class="inner-hero-container">
Expand Down Expand Up @@ -159,23 +163,6 @@ function eqd_single_header() {

</div>

<?php
// Background image.
if ( get_field( 'post_format_style' ) == 'full-width' ) :
?>
<span class="hero_image">
<?php if ( ! empty( $background_image['ID'] ) ) : ?>
<?php echo wp_get_attachment_image( $background_image['ID'], 'full' ); ?>
<?php endif; ?>

<?php
$featured_image = get_the_post_thumbnail_url( get_the_ID() );
if ( $featured_image ) {
?>
<?php echo '<img src="' . esc_url( $featured_image ) . '" />'; ?>
<?php } ?>
</span>
<?php endif; ?>
</header>

<?php
Expand Down
9 changes: 8 additions & 1 deletion inc/template-tags.php
Original file line number Diff line number Diff line change
Expand Up @@ -297,7 +297,12 @@ function eqd_tha_page_header() {
$alternate_header_style = get_field( 'alternate_header_style' );
if ( $alternate_header_style ) {
$container_class .= 'inner-hero-alternate-style';
} elseif ( is_page() ) {
if ( ! is_front_page() ) {
$container_class .= 'inner-hero-alternate-style';
}
}

?>
<header class="inner-hero <?php echo wp_kses_post( $container_class ); ?>">
<div class="inner-hero-container">
Expand Down Expand Up @@ -368,12 +373,14 @@ function eqd_tha_page_header() {
<?php if ( !$alternate_header_style ): ?>
<?php
if ( ! is_search() ) {
if ( ! empty( $bg_url ) ) :
if(!is_page()):
if ( ! empty( $bg_url ) ) :
?>
<span class="hero_image">
<img src="<?php echo $bg_url; ?>" alt="<?php the_title(); ?>" />
</span>
<?php
endif;
endif;
}
?>
Expand Down

0 comments on commit 3076b15

Please sign in to comment.