Make WordPress Core

Changeset 26574


Ignore:
Timestamp:
12/03/2013 06:34:34 PM (10 years ago)
Author:
lancewillett
Message:

Twenty Fourteen: reposition the window on jump-to-anchor to account for header height. Props obenland, fixes #26213.

Location:
trunk/src/wp-content/themes/twentyfourteen
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-content/themes/twentyfourteen/functions.php

    r26565 r26574  
    264264    }
    265265
    266     wp_enqueue_script( 'twentyfourteen-script', get_template_directory_uri() . '/js/functions.js', array( 'jquery' ), '20131102', true );
     266    wp_enqueue_script( 'twentyfourteen-script', get_template_directory_uri() . '/js/functions.js', array( 'jquery' ), '20131203', true );
    267267}
    268268add_action( 'wp_enqueue_scripts', 'twentyfourteen_scripts' );
  • trunk/src/wp-content/themes/twentyfourteen/js/functions.js

    r26332 r26574  
    4949
    5050            element.focus();
     51
     52            // Repositions the window on jump-to-anchor to account for header height.
     53            window.scrollBy( 0, -80 );
    5154        }
    5255    } );
Note: See TracChangeset for help on using the changeset viewer.