🐞 fix: Fix mobile issues, enablke deploy on push #skipGA
This commit is contained in:
@@ -3,9 +3,9 @@ on:
|
|||||||
workflow_dispatch:
|
workflow_dispatch:
|
||||||
# Remove "workflow_dispatch" above and uncomment the lines below to enable deploy on push
|
# Remove "workflow_dispatch" above and uncomment the lines below to enable deploy on push
|
||||||
# only do this once you're actually ready to start deploying to Dreamhost
|
# only do this once you're actually ready to start deploying to Dreamhost
|
||||||
# push:
|
push:
|
||||||
# branches:
|
branches:
|
||||||
# - main
|
- main
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
build:
|
build:
|
||||||
|
|||||||
+4
-1
@@ -13,6 +13,9 @@ global $views;
|
|||||||
$headerLogo = getFieldValue( 'header.header_logo.url' ) ? getFieldValue( 'header.header_logo.url' ) : get_theme_file_uri( '/static/img/logo.svg' );
|
$headerLogo = getFieldValue( 'header.header_logo.url' ) ? getFieldValue( 'header.header_logo.url' ) : get_theme_file_uri( '/static/img/logo.svg' );
|
||||||
$linkResume = getFieldValue( 'header.resume_link' ) ? getFieldValue( 'header.resume_link' ) : '';
|
$linkResume = getFieldValue( 'header.resume_link' ) ? getFieldValue( 'header.resume_link' ) : '';
|
||||||
|
|
||||||
|
// Expose resume link to the main nav component (used by the mobile menu's footer area).
|
||||||
|
$GLOBALS['ks_portfolio_link_resume'] = $linkResume;
|
||||||
|
|
||||||
// Check conditions for displaying the hero section
|
// Check conditions for displaying the hero section
|
||||||
$showHero = in_array(
|
$showHero = in_array(
|
||||||
true,
|
true,
|
||||||
@@ -53,7 +56,7 @@ $showHero = in_array(
|
|||||||
|
|
||||||
<?php get_template_part( 'views/components/nav-main' ); ?>
|
<?php get_template_part( 'views/components/nav-main' ); ?>
|
||||||
|
|
||||||
<div class="site-header__aux">
|
<div class="site-header__aux hidden lg:flex">
|
||||||
<a class="button button--outline" href="<?php echo esc_url( $linkResume ); ?>">
|
<a class="button button--outline" href="<?php echo esc_url( $linkResume ); ?>">
|
||||||
<?php echo esc_html__( 'Resume', 'ks-portfolio' ); ?>
|
<?php echo esc_html__( 'Resume', 'ks-portfolio' ); ?>
|
||||||
</a>
|
</a>
|
||||||
|
|||||||
@@ -16,6 +16,11 @@ if ( $location === 'main_navigation' ) {
|
|||||||
} else {
|
} else {
|
||||||
$menuID = 'menu-container-aux';
|
$menuID = 'menu-container-aux';
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Resume link is exposed by header.php via $GLOBALS['ks_portfolio_link_resume']
|
||||||
|
// and read here so it can be appended as a mobile-only CTA at the bottom of
|
||||||
|
// the menu panel (hidden on desktop via lg:hidden).
|
||||||
|
$linkResume = isset( $GLOBALS['ks_portfolio_link_resume'] ) ? $GLOBALS['ks_portfolio_link_resume'] : '';
|
||||||
?>
|
?>
|
||||||
|
|
||||||
<ul id="<?php echo esc_attr( $menuID ); ?>" class="menu-vdi">
|
<ul id="<?php echo esc_attr( $menuID ); ?>" class="menu-vdi">
|
||||||
@@ -30,4 +35,12 @@ if ( $location === 'main_navigation' ) {
|
|||||||
<?php include __DIR__ . '/single.php'; ?>
|
<?php include __DIR__ . '/single.php'; ?>
|
||||||
<?php endif; ?>
|
<?php endif; ?>
|
||||||
<?php endforeach; ?>
|
<?php endforeach; ?>
|
||||||
|
|
||||||
|
<?php if ( ! empty( $linkResume ) && $location === 'main_navigation' ) : ?>
|
||||||
|
<li class="menu-vdi__item menu-item--resume lg:hidden border-t border-secondary-200 mt-2 pt-2">
|
||||||
|
<a href="<?php echo esc_url( $linkResume ); ?>" class="menu-vdi__link button button--primary mx-4 inline-block">
|
||||||
|
<?php echo esc_html__( 'Resume', 'ks-portfolio' ); ?>
|
||||||
|
</a>
|
||||||
|
</li>
|
||||||
|
<?php endif; ?>
|
||||||
</ul>
|
</ul>
|
||||||
|
|||||||
@@ -9,6 +9,10 @@
|
|||||||
namespace KsPortfolio;
|
namespace KsPortfolio;
|
||||||
|
|
||||||
global $views;
|
global $views;
|
||||||
|
|
||||||
|
// Expose resume link to the menu items renderer so the CTA can be appended
|
||||||
|
// as the final <li> in the mobile panel (hidden on desktop via lg:hidden).
|
||||||
|
$GLOBALS['ks_portfolio_link_resume'] = isset( $GLOBALS['ks_portfolio_link_resume'] ) ? $GLOBALS['ks_portfolio_link_resume'] : '';
|
||||||
?>
|
?>
|
||||||
|
|
||||||
<nav class="nav-main" role="navigation" aria-label="Main">
|
<nav class="nav-main" role="navigation" aria-label="Main">
|
||||||
|
|||||||
@@ -29,7 +29,7 @@ if ( $navIcon ) {
|
|||||||
<?php else : ?>
|
<?php else : ?>
|
||||||
<!-- Hamburger Icon -->
|
<!-- Hamburger Icon -->
|
||||||
<span class="nav-toggle-icon nav-toggle-hamburger">
|
<span class="nav-toggle-icon nav-toggle-hamburger">
|
||||||
<svg class="text-black fill-black" viewBox="0 0 100 80" width="40" height="40">
|
<svg class="text-current fill-current" viewBox="0 0 100 80" width="40" height="40">
|
||||||
<rect y="0" width="100" height="15"></rect>
|
<rect y="0" width="100" height="15"></rect>
|
||||||
<rect y="30" width="100" height="15"></rect>
|
<rect y="30" width="100" height="15"></rect>
|
||||||
<rect y="60" width="100" height="15"></rect>
|
<rect y="60" width="100" height="15"></rect>
|
||||||
@@ -37,9 +37,9 @@ if ( $navIcon ) {
|
|||||||
</span>
|
</span>
|
||||||
<!-- X Icon -->
|
<!-- X Icon -->
|
||||||
<span class="nav-toggle-icon nav-toggle-x">
|
<span class="nav-toggle-icon nav-toggle-x">
|
||||||
<svg class="text-black fill-black" viewBox="0 0 100 80" width="40" height="40">
|
<svg class="text-current stroke-current" viewBox="0 0 100 80" width="40" height="40">
|
||||||
<line x1="20" y1="20" x2="80" y2="60" stroke="black" stroke-width="15" stroke-linecap="round" />
|
<line x1="20" y1="20" x2="80" y2="60" stroke-width="15" stroke-linecap="round" />
|
||||||
<line x1="80" y1="20" x2="20" y2="60" stroke="black" stroke-width="15" stroke-linecap="round" />
|
<line x1="80" y1="20" x2="20" y2="60" stroke-width="15" stroke-linecap="round" />
|
||||||
</svg>
|
</svg>
|
||||||
</span>
|
</span>
|
||||||
<?php endif; ?>
|
<?php endif; ?>
|
||||||
|
|||||||
Reference in New Issue
Block a user