From cd20e417d249e9f8c7700497ef4ce6e3c161e962 Mon Sep 17 00:00:00 2001 From: Foxaii Date: Sun, 28 Jul 2013 13:23:38 +0100 Subject: [PATCH] Library changes --- lib/config.php | 6 +++--- lib/nav.php | 10 +++------- lib/scripts.php | 1 - 3 files changed, 6 insertions(+), 11 deletions(-) diff --git a/lib/config.php b/lib/config.php index 78d60ef..b45d574 100644 --- a/lib/config.php +++ b/lib/config.php @@ -21,10 +21,10 @@ define('POST_EXCERPT_LENGTH', 40); function roots_main_class() { if (roots_display_sidebar()) { // Classes on pages with the sidebar - $class = 'span8'; + $class = 'col-sm-7 col-lg-8'; } else { // Classes on full width pages - $class = 'span12'; + $class = 'col-lg-12'; } return $class; @@ -34,7 +34,7 @@ function roots_main_class() { * .sidebar classes */ function roots_sidebar_class() { - return 'span4'; + return 'col-sm-5 col-lg-4'; } /** diff --git a/lib/nav.php b/lib/nav.php index 8a071b1..beac858 100644 --- a/lib/nav.php +++ b/lib/nav.php @@ -30,7 +30,7 @@ class Roots_Nav_Walker extends Walker_Nav_Menu { elseif (stristr($item_html, 'li class="divider')) { $item_html = preg_replace('/]*>.*?<\/a>/iU', '', $item_html); } - elseif (stristr($item_html, 'li class="nav-header')) { + elseif (stristr($item_html, 'li class="dropdown-header')) { $item_html = preg_replace('/]*>(.*)<\/a>/iU', '$1', $item_html); } @@ -42,11 +42,7 @@ class Roots_Nav_Walker extends Walker_Nav_Menu { $element->is_dropdown = ((!empty($children_elements[$element->ID]) && (($depth + 1) < $max_depth || ($max_depth === 0)))); if ($element->is_dropdown) { - if ($depth === 0) { - $element->classes[] = 'dropdown'; - } elseif ($depth === 1) { - $element->classes[] = 'dropdown-submenu'; - } + $element->classes[] = 'dropdown'; } parent::display_element($element, $children_elements, $max_depth, $depth, $args, $output); @@ -85,7 +81,7 @@ function roots_nav_menu_args($args = '') { } if (current_theme_supports('bootstrap-top-navbar')) { - $roots_nav_menu_args['depth'] = 3; + $roots_nav_menu_args['depth'] = 2; } if (!$args['walker']) { diff --git a/lib/scripts.php b/lib/scripts.php index daa34fa..87fcba4 100644 --- a/lib/scripts.php +++ b/lib/scripts.php @@ -15,7 +15,6 @@ */ function roots_scripts() { wp_enqueue_style('roots_bootstrap', get_template_directory_uri() . '/assets/css/bootstrap.css', false, null); - wp_enqueue_style('roots_bootstrap_responsive', get_template_directory_uri() . '/assets/css/bootstrap-responsive.css', array('roots_bootstrap'), null); wp_enqueue_style('roots_app', get_template_directory_uri() . '/assets/css/app.css', false, null); // jQuery is loaded using the same method from HTML5 Boilerplate: