🔵 other: Initial WP conversion from Eleventy
Sync TODOs with Issues / sync_todos (push) Successful in 7s

This commit is contained in:
Keith Solomon
2026-05-25 16:48:48 -05:00
parent 2e5bfaba89
commit dcb38250f8
56 changed files with 965 additions and 318 deletions
+41 -88
View File
@@ -2,110 +2,63 @@
/**
* Theme footer template
*
* @package BasicWP
* @package GoAskAuntie
* @since 1.0.0
*/
namespace BasicWP;
$footerLogo = getFieldValue( 'footer.footer_logo.url' ) ? getFieldValue( 'footer.footer_logo.url' ) : '';
$footerDesc = getFieldValue( 'footer.footer_description' ) ? getFieldValue( 'footer.footer_description' ) : '';
$copyright_text = getFieldValue( 'footer.copyright_text' ) ? getFieldValue( 'footer.copyright_text' ) : 'Copyright © %Y ' . get_bloginfo( 'name' );
$copyright = str_replace( '%Y', gmdate( 'Y' ), $copyright_text );
$locations = get_nav_menu_locations();
$footerNav = ! empty( $locations['footer_navigation'] )
? ( wp_get_nav_menu_items( (int) $locations['footer_navigation'] ) ? wp_get_nav_menu_items( (int) $locations['footer_navigation'] ) : array() )
: array();
$logo_url = get_theme_file_uri( '/static/img/logo.png' );
?>
</main>
<footer role="contentinfo" class="site-footer bg-gray-800 text-white text-base">
<div class="pt-16 pb-12 text-base">
<div class="container mx-auto">
<div class="grid grid-cols-4 gap-6 md:grid-cols-8 lg:grid-cols-12">
<div class="col-span-4 md:col-span-8 lg:col-span-4 max-w-[40ch] prose-p:text-14px prose-p:mb-4 text-balance" aria-labelledby="footer-header">
<h2 id="footer-header" class="max-w-64 h-auto">
<a href="<?php echo esc_url( home_url( '/' ) ); ?>" class="site-footer__logo-link h-full w-full">
<?php if ( $footerLogo ) { ?>
<img src="<?php echo esc_url( $footerLogo ); ?>" alt="<?php echo esc_attr( get_bloginfo( 'name' ) ); ?>" class="site-footer__logo-image" />
<?php
} else {
echo esc_html( get_bloginfo( 'name' ) );
}
?>
</a>
</h2>
<footer role="contentinfo" class="min-h-[640px] bg-transparent w-full flex flex-col justify-evenly bg-navy mt-60">
<!-- Colored stripe bar -->
<div>
<div class="h-8 w-full bg-red"></div>
<div class="h-4 w-full bg-teal-light"></div>
<div class="h-8 w-full bg-purple"></div>
<div class="h-4 w-full bg-teal-light"></div>
<div class="h-8 w-full bg-teal"></div>
<div class="h-4 w-full bg-teal-light"></div>
</div>
<div id="footer-description" aria-label="Footer description">
<?php echo wp_kses_post( $footerDesc ); ?>
</div>
<div class="social-links mt-8">
<?php
get_template_part(
'views/partials/social-media',
null,
array(
'circle' => false,
'classes' => 'social-icons p-0 mr-2 text-30px text-gray-300! hover:text-info!',
)
);
?>
</div>
</div>
<div id="footRight" class="col-span-4 md:col-span-8 grid md:grid-cols-4 gap-10 lg:justify-end">
<div aria-labelledby="footer-area-1" class="prose-p:text-balance">
<h3 class="mb-4 pb-2 border-b border-b-secondary font-bold text-white" id="footer-area-1">Footer Area 1</h3>
<?php dynamic_sidebar( 'footer-1' ); ?>
</div>
<div aria-labelledby="footer-area-2" class="prose-p:text-balance">
<h3 class="mb-4 pb-2 border-b border-b-secondary font-bold text-white" id="footer-area-2">Footer Area 2</h3>
<?php dynamic_sidebar( 'footer-2' ); ?>
</div>
<div aria-labelledby="footer-area-3" class="prose-p:text-balance">
<h3 class="mb-4 pb-2 border-b border-b-secondary font-bold text-white" id="footer-area-3">Footer Area 3</h3>
<?php dynamic_sidebar( 'footer-3' ); ?>
</div>
<div id="footer-nav" aria-labelledby="footer-navigation">
<h3 class="mb-4 pb-2 border-b border-b-secondary font-bold text-white" id="footer-navigation"><?php echo esc_html__( 'Navigation' ); ?></h3>
<?php if ( $footerNav ) : ?>
<nav class="site-footer__nav" aria-label="Footer navigation">
<ul class="site-footer__nav-list">
<?php foreach ( $footerNav as $item ) : ?>
<li class="site-footer__nav-item list-none text-left <?php echo esc_attr( implode( ' ', $item->classes ) ); ?>">
<a href="<?php echo esc_url( $item->url ); ?>" class="site-footer__nav-link">
<?php echo esc_html( $item->title ); ?>
</a>
</li>
<?php endforeach; ?>
</ul>
</nav>
<?php endif; ?>
</div>
</div>
<!-- Footer content -->
<div class="flex md:flex-row flex-col mx-auto h-auto justify-around w-full items-center md:items-end px-4 flex-1 self-end mb-16 bg-navy">
<div class="flex md:flex-row flex-col md:gap-8 items-center md:items-end">
<img src="<?php echo esc_url( $logo_url ); ?>" alt="Go Ask Auntie logo" class="object-contain block h-64 py-4 md:p-0 m-0">
<div class="text-xl">
<p class="text-teal-light font-bold">Ka Ni Kanichihk Mino Pimatisiwin<br>Sexual Wellness Lodge</p>
<p class="text-white">102 - 765 Main Street<br>
Winnipeg, Manitoba<br>
R2W 3N5</p>
</div>
</div>
<div class="text-white text-base">
<p>&copy; <?php echo gmdate( 'Y' ); ?> Go Ask Auntie, All rights reserved.</p>
</div>
</div>
<div class="copyright bg-primary text-white text-center py-3 text-14px">
<?php
if ( $copyright ) {
echo wp_kses_post( $copyright );
} else {
echo esc_html( '&copy; ' . gmdate( 'Y' ) . ' ' . get_bloginfo( 'name' ) . '.' );
}
?>
<!-- Vincent Design credit -->
<div class="bg-navy pb-2">
<p class="text-white text-xs md:text-lg text-center">Web Design & Development by <a href="https://www.vincentdesign.ca" class="text-white">Vincent Design</a></p>
</div>
</footer>
<!-- Mobile nav toggle script -->
<script>
function mobileNav() {
jQuery("#myLinks").slideToggle("fast", "linear", function () {
if (jQuery("#nav-icon").hasClass("fa-bars")) {
jQuery("#nav-icon").addClass("fa-times").removeClass("fa-bars");
} else {
jQuery("#nav-icon").addClass("fa-bars").removeClass("fa-times");
}
});
}
</script>
<?php wp_footer(); ?>
</body>
</html>
</html>