This repository has been archived by the owner on Feb 17, 2025. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 361
Try: Add hide site header/footer Customizer options to Varia #2961
Merged
Merged
Changes from 11 commits
Commits
Show all changes
37 commits
Select commit
Hold shift + click to select a range
c6ff72a
Try: Add hide site header/footer Customizer options to Varia.
kjellr bfeedb6
Hide the footer widget area too.
kjellr 7d979a0
Fix incorrect setting name.
kjellr 6bee1f4
Fix another variable name.
kjellr cb5315e
Remove top margin and padding from entry content by default.
kjellr 722be47
Merge branch 'trunk' into try/varia-header-footer-hide
kjellr 007f935
Begin refactor to more closely match #2985
kjellr fd4c213
Tidy up into partials.
kjellr 2e52a5e
footer info template part and Alves footer fix
MaggieCabrera 4662cf6
refactor footer templates to make it easier to share code
scruffian 2fd4a1f
Create a template for privacy policy
scruffian b43950c
replace site name code with a template
scruffian ffcae3f
move the WordPress credit into the site name template
scruffian 4229d46
social navigation template part
MaggieCabrera 00ed303
stratford social nav
MaggieCabrera bbbac69
header for Balasana
MaggieCabrera a15f25b
footer for Brompton
MaggieCabrera a458920
header for Coutoire
MaggieCabrera 5156757
header Dalston
MaggieCabrera f5897b4
footer dalston, margin top header too
MaggieCabrera eec55a5
fix spacing
scruffian 1f1d687
fix spacing
scruffian b35115c
header Morden
MaggieCabrera 217cd6e
another small refactor
scruffian 195bf6e
Merge branch 'try/varia-header-footer-hide' of github.com:Automattic/…
MaggieCabrera 45286ee
Merge branch 'try/varia-header-footer-hide' of github.com:Automattic/…
scruffian cff4974
rockfield header and footer
MaggieCabrera 07ab78f
Stow header
MaggieCabrera a436457
Merge branch 'try/varia-header-footer-hide' of github.com:Automattic/…
MaggieCabrera 5227731
small refactor, rivington header and footer
MaggieCabrera 6e1a598
Stratford header and footer
MaggieCabrera 1e4cb5f
refactor FSE header templates
scruffian 4a0a3ff
refactor FSE header templates
scruffian 7f79b14
remove unconnected change
scruffian 2260fd2
refactored site-navigation
MaggieCabrera 65829ef
Merge branch 'try/varia-header-footer-hide' of github.com:Automattic/…
MaggieCabrera fce321c
fix spacing issues
scruffian File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
<?php if ( class_exists( 'A8C\FSE\WP_Template' ) ) : // If the FSE plugin is active, use the Header template for content. ?> | ||
<footer class="fse-template-part fse-footer entry-content"> | ||
<?php | ||
$template = new A8C\FSE\WP_Template(); | ||
$template->output_template_content( A8C\FSE\WP_Template::FOOTER ); | ||
else : // Otherwise we'll fallback to the default Varia footer below. | ||
?> | ||
<footer id="colophon" class="site-footer"> | ||
<?php | ||
if ( ! ( true === get_theme_mod( 'hide_site_footer', false ) && is_front_page() && is_page() ) ) : // If this is the homepage and the footer elements are set to hide, don't load this part. | ||
get_template_part( 'template-parts/footer/footer', 'widgets' ); | ||
endif; | ||
?> | ||
|
||
<div id="footer-info-wrapper"> | ||
|
||
<?php | ||
if ( ! ( true === get_theme_mod( 'hide_site_footer', false ) && is_front_page() && is_page() ) ) : // If this is the homepage and the footer elements are set to hide, don't load this part. | ||
get_template_part( 'template-parts/footer/privacy-policy', '' ); | ||
get_template_part( 'template-parts/footer/footer', 'navigation' ); | ||
endif; | ||
get_template_part( 'template-parts/footer/footer', 'info' ); | ||
?> | ||
</div> | ||
<?php endif; ?> | ||
|
||
</footer><!-- #colophon --> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
<div class="site-info"> | ||
<?php $blog_info = get_bloginfo( 'name' ); ?> | ||
<?php if ( ! empty( $blog_info ) ) : ?> | ||
<a class="site-name" href="<?php echo esc_url( home_url( '/' ) ); ?>" rel="home"><?php bloginfo( 'name' ); ?></a><span class="comma">,</span> | ||
<?php endif; ?> | ||
<a href="<?php echo esc_url( __( 'https://wordpress.org/', 'alves' ) ); ?>" class="imprint"> | ||
<?php | ||
/* translators: %s: WordPress. */ | ||
printf( __( 'proudly powered by %s.', 'alves' ), 'WordPress' ); | ||
?> | ||
</a> | ||
</div> |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,63 @@ | ||
<footer id="colophon" class="site-footer responsive-max-width"> | ||
<?php | ||
if ( class_exists( 'A8C\FSE\WP_Template' ) ) : // If the FSE plugin is active, use the Header template for content. | ||
$template = new A8C\FSE\WP_Template(); | ||
$template->output_template_content( A8C\FSE\WP_Template::FOOTER ); | ||
else : // Otherwise we'll fallback to the default Balasana footer below. | ||
get_template_part( 'template-parts/footer/footer', 'widgets' ); | ||
|
||
if ( has_nav_menu( 'menu-2' ) || has_nav_menu( 'social' ) ) : ?> | ||
<div class="footer-menus"> | ||
|
||
<?php if ( has_nav_menu( 'menu-2' ) ) : ?> | ||
<nav class="footer-navigation" aria-label="<?php esc_attr_e( 'Footer Menu', 'balasana' ); ?>"> | ||
<?php | ||
wp_nav_menu( | ||
array( | ||
'theme_location' => 'menu-2', | ||
'menu_class' => 'footer-menu', | ||
'depth' => 1, | ||
) | ||
); | ||
?> | ||
</nav><!-- .footer-navigation --> | ||
<?php | ||
endif; | ||
|
||
if ( has_nav_menu( 'social' ) ) : | ||
?> | ||
<nav class="social-navigation" aria-label="<?php esc_attr_e( 'Social Links Menu', 'balasana' ); ?>"> | ||
<?php | ||
wp_nav_menu( | ||
array( | ||
'theme_location' => 'social', | ||
'menu_class' => 'social-links-menu', | ||
'link_before' => '<span class="screen-reader-text">', | ||
'link_after' => '</span>' . varia_get_icon_svg( 'link' ), | ||
'depth' => 1, | ||
) | ||
); | ||
?> | ||
</nav><!-- .social-navigation --> | ||
<?php endif; ?> | ||
|
||
</div><!-- .footer-menus --> | ||
<?php | ||
endif; | ||
endif; | ||
?> | ||
|
||
<div class="site-info"> | ||
<?php get_template_part( 'template-parts/footer/privacy-policy', '' ); ?> | ||
<?php $blog_info = get_bloginfo( 'name' ); ?> | ||
<?php if ( ! empty( $blog_info ) ) : ?> | ||
<a class="site-name" href="<?php echo esc_url( home_url( '/' ) ); ?>" rel="home"><?php bloginfo( 'name' ); ?></a><span class="comma">,</span> | ||
<?php endif; ?> | ||
<a href="<?php echo esc_url( __( 'https://wordpress.org/', 'balasana' ) ); ?>" class="imprint"> | ||
<?php | ||
/* translators: %s: WordPress. */ | ||
printf( __( 'proudly powered by %s.', 'balasana' ), 'WordPress' ); | ||
?> | ||
</a> | ||
</div><!-- .site-info --> | ||
</footer><!-- #colophon --> |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
<footer id="colophon" class="site-footer"> | ||
<?php get_template_part( 'template-parts/footer/footer', 'widgets' ); ?> | ||
<?php if ( has_nav_menu( 'menu-2' ) ) : ?> | ||
<nav class="footer-navigation" aria-label="<?php esc_attr_e( 'Footer Menu', 'varia' ); ?>"> | ||
<?php | ||
wp_nav_menu( | ||
array( | ||
'theme_location' => 'menu-2', | ||
'menu_class' => 'footer-menu', | ||
'depth' => 1, | ||
) | ||
); | ||
?> | ||
</nav><!-- .footer-navigation --> | ||
<?php endif; ?> | ||
<div class="site-info"> | ||
<?php $blog_info = get_bloginfo( 'name' ); ?> | ||
<?php if ( ! empty( $blog_info ) ) : ?> | ||
<a class="site-name" href="<?php echo esc_url( home_url( '/' ) ); ?>" rel="home"><?php bloginfo( 'name' ); ?></a><span class="comma">,</span> | ||
<?php endif; ?> | ||
<a href="<?php echo esc_url( __( 'https://wordpress.org/', 'varia' ) ); ?>" class="imprint"> | ||
<?php | ||
/* translators: %s: WordPress. */ | ||
printf( __( 'proudly powered by %s.', 'varia' ), 'WordPress' ); | ||
?> | ||
</a> | ||
<?php get_template_part( 'template-parts/footer/privacy-policy', '' ); ?> | ||
</div><!-- .site-info --> | ||
</footer><!-- #colophon --> |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Technically this is a change - previously the privacy policy was inside the wordpress.org link, but I assume that is a bug.