• Is there any way to modify and/or disable the smooth scrolling in the theme? The smooth scrolling functionality is very nice for the top of page button, however it also appears to take control of the page when clicking the read more button.

    When clicking the read more button, the theme will jump to the post and disallow further user interaction (manual scrolling) for about 2 seconds. Additionally, the theme seems to slowly scroll a small amount.

    I believe this is tied to the animate() jquery function in the shapely-scripts.js file. There are three instances of it and some call for 2 second animations. I’ve tried to dequeue and enqueue it in a child theme (with low priority) but haven’t’ been able to actually get it working. Any advice is appreciated!

    Here’s the code I used to try to enqueue my own version of shapely-scripts.js, but maybe there’s an easier way?

    function dequeue_parent_styles() {
    $unwanted_scripts = array(
    ‘shapely-scripts’
    );
    foreach ( $unwanted_scripts as $script ) {
    wp_dequeue_script( $script );
    wp_deregister_script( $script );
    }

    wp_enqueue_script( ‘my-shapely-script’ , get_stylesheet_directory_uri() . ‘/assets/js/my-shapely-scripts.js’, array( ‘jquery’), ‘1.0’, true);

    }

  • The topic ‘Modify or Disable Smooth Scrolling’ is closed to new replies.