• Skip to main content
  • Skip to forum navigation

StudioPress

  • Shop for Themes
  • My StudioPress

Forum navigation

  • Home
  • General Genesis Discussions
  • StudioPress Themes
  • Genesis Blocks
    • Genesis Blocks
    • Genesis Custom Blocks
  • Retired Themes
  • FAQs
  • Forum Rules
  • Internationalization and Translations
  • Forum Bugs and Suggestions
  • Forum Log In

Are You Using The WordPress Block Editor?

Genesis now offers plugins that help you build better sites faster with the WordPress block editor (Gutenberg). Try the feature-rich free versions of each plugin for yourself!

Genesis Blocks Genesis Custom Blocks

Altitude site header on minimum pro

Welcome!

These forums are for general discussion on WordPress and Genesis. Official support for StudioPress themes is offered exclusively at My StudioPress. Responses in this forum are not guaranteed. Please note that this forum will require a new username, separate from the one used for My.StudioPress.

Log In
Register Lost Password

Community Forums › Forums › Archived Forums › Design Tips and Tricks › Altitude site header on minimum pro

This topic is: not resolved

Tagged: altitude

  • This topic has 3 replies, 3 voices, and was last updated 8 years, 1 month ago by Genesis Developer.
Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • February 19, 2015 at 6:38 pm #141384
    Kristie Hill
    Member

    Hi.

    The site header on Altitude pro is transparent until you scroll, and then it becomes black.

    I am trying to replicate the same thing in Minimum Pro (also uses static site header).

    Is the scroll effect done with CSS alone, or is there also js involved? This is the css below that I could find relating to the site header.

    What else do I need to adjust?

    Site Header
    ---------------------------------------------------------------------------------------------------- */
    
    .site-header {
    	background-color: #000;
    	left: 0;
    	position: fixed;
    	top: 0;
    	width: 100%;
    	z-index: 999;
    }
    
    .featured-section .site-header {
    	background-color: transparent;
    }
    
    .featured-section .site-header > .wrap {
    	border-bottom: 1px solid #fff;
    } 

    Kristie Hill

    February 19, 2015 at 7:11 pm #141388
    Ren Ventura
    Member

    Altitude is using a bit of jQuery to add a class to the header once the user starts to scroll, which is then styled with CSS. Minimum doesn't do this by default but you can add something like Waypoints.js or just use the .scrollTop() function to give you what you're looking for.


    Web & Software Developer & Blogger | RenVentura.com | Follow Me on Twitter @CLE_Ren

    February 19, 2015 at 11:48 pm #141408
    Kristie Hill
    Member

    I thought it was probably a jQuery. There are 2 files in the altitude theme that are jquery and theme related: jquery.logalScroll.min.js and jquery.scrollTO.min.js

    Do you think both are necessary to accomplish it the transparent to solid?


    Kristie Hill

    February 20, 2015 at 12:07 am #141410
    Genesis Developer
    Member

    Those two JS files are using for smooth scrolling on Home page only. Check the global.js file. Code is there

    if( $( document ).scrollTop() > 0 ){
    		$( '.site-header' ).addClass( 'dark' );			
    	}
    
    	// Add opacity class to site header
    	$( document ).on('scroll', function(){
    
    		if ( $( document ).scrollTop() > 0 ){
    			$( '.site-header' ).addClass( 'dark' );			
    
    		} else {
    			$( '.site-header' ).removeClass( 'dark' );			
    		}
    
    	});

    Download Genesis Featured Posts Combo Widget | Simple Grid Layouts Plugin for Posts, CPTs and terms
    You can request new tips/help.

  • Author
    Posts
Viewing 4 posts - 1 through 4 (of 4 total)
  • The forum ‘Design Tips and Tricks’ is closed to new topics and replies.

CTA

Ready to get started? Create a site or shop for themes.

Create a site with WP EngineShop for Themes

Footer

StudioPress

© 2023 WPEngine, Inc.

Products
  • Create a Site with WP Engine
  • Shop for Themes
  • Theme Features
  • Get Started
  • Showcase
Company
  • Brand Assets
  • Terms of Service
  • Accptable Usse Policy
  • Privacy Policy
  • Refund Policy
  • Contact Us
Community
  • Find Developers
  • Forums
  • Facebook Group
  • #GenesisWP
  • Showcase
Resources
  • StudioPress Blog
  • Help & Documentation
  • FAQs
  • Code Snippets
  • Affiliates
Connect
  • StudioPress Live
  • StudioPress FM
  • Facebook
  • Twitter
  • Dribbble