Version Description
- Fix issue with CSS classnames on current page's children.
Download this release
Release Info
Developer | Mat Lipe |
Plugin | Advanced Sidebar Menu |
Version | 8.6.3 |
Comparing to | |
See all releases |
Code changes from version 8.6.2 to 8.6.3
- advanced-sidebar-menu.php +2 -2
- readme.txt +19 -6
- src/List_Pages.php +1 -1
advanced-sidebar-menu.php
CHANGED
@@ -4,7 +4,7 @@
|
|
4 |
* Plugin URI: https://onpointplugins.com/advanced-sidebar-menu/
|
5 |
* Description: Creates dynamic menus based on parent/child relationship of your pages or categories.
|
6 |
* Author: OnPoint Plugins
|
7 |
-
* Version: 8.6.
|
8 |
* Author URI: https://onpointplugins.com
|
9 |
* Text Domain: advanced-sidebar-menu
|
10 |
* Domain Path: /languages/
|
@@ -19,7 +19,7 @@ if ( defined( 'ADVANCED_SIDEBAR_BASIC_VERSION' ) ) {
|
|
19 |
return;
|
20 |
}
|
21 |
|
22 |
-
define( 'ADVANCED_SIDEBAR_BASIC_VERSION', '8.6.
|
23 |
define( 'ADVANCED_SIDEBAR_MENU_REQUIRED_PRO_VERSION', '8.3.1' );
|
24 |
define( 'ADVANCED_SIDEBAR_DIR', plugin_dir_path( __FILE__ ) );
|
25 |
define( 'ADVANCED_SIDEBAR_MENU_URL', plugin_dir_url( __FILE__ ) );
|
4 |
* Plugin URI: https://onpointplugins.com/advanced-sidebar-menu/
|
5 |
* Description: Creates dynamic menus based on parent/child relationship of your pages or categories.
|
6 |
* Author: OnPoint Plugins
|
7 |
+
* Version: 8.6.3
|
8 |
* Author URI: https://onpointplugins.com
|
9 |
* Text Domain: advanced-sidebar-menu
|
10 |
* Domain Path: /languages/
|
19 |
return;
|
20 |
}
|
21 |
|
22 |
+
define( 'ADVANCED_SIDEBAR_BASIC_VERSION', '8.6.3' );
|
23 |
define( 'ADVANCED_SIDEBAR_MENU_REQUIRED_PRO_VERSION', '8.3.1' );
|
24 |
define( 'ADVANCED_SIDEBAR_DIR', plugin_dir_path( __FILE__ ) );
|
25 |
define( 'ADVANCED_SIDEBAR_MENU_URL', plugin_dir_url( __FILE__ ) );
|
readme.txt
CHANGED
@@ -6,7 +6,7 @@ Tags: menus, sidebar menu, hierarchy, category menu, pages menu, dynamic
|
|
6 |
Requires at least: 5.2.0
|
7 |
Tested up to: 5.8.1
|
8 |
Requires PHP: 5.6.0
|
9 |
-
Stable tag: 8.6.
|
10 |
|
11 |
== Description ==
|
12 |
|
@@ -119,22 +119,33 @@ Manual Installation
|
|
119 |
The widgets in this plugin are smart enough to not show up on pages or categories where the only thing that would display is the title. While it may appear like the widget is broken, it is actually doing what it is intended to do.
|
120 |
|
121 |
The most common causes for this confusion come from one of these reasons:
|
122 |
-
1. The incorrect widget was selected
|
123 |
2. "Display the highest level parent page" or "Display the highest level parent category" is not checked.
|
124 |
3. The widget is currently not being viewed on a page (for the pages widget) or category (for the categories widget).
|
125 |
|
126 |
= How do I change the styling of the current page? =
|
127 |
|
128 |
-
You may add
|
|
|
|
|
|
|
|
|
|
|
129 |
|
130 |
-
For Instance This would remove the dot and change the color
|
131 |
<code>
|
|
|
132 |
.advanced-sidebar-menu li.current_page_item a {
|
133 |
color: black;
|
134 |
}
|
135 |
|
|
|
136 |
.advanced-sidebar-menu li.current_page_item {
|
137 |
-
list-style-type:
|
|
|
|
|
|
|
|
|
|
|
138 |
}
|
139 |
</code>
|
140 |
|
@@ -156,6 +167,9 @@ Yes. Based on whatever page, post, or category you are on, the menu will change
|
|
156 |
|
157 |
|
158 |
== Changelog ==
|
|
|
|
|
|
|
159 |
= 8.6.2 =
|
160 |
* Assured consistency for levels of page menu's CSS classes.
|
161 |
* Converted category get highest parent logic to `get_ancestors`.
|
@@ -283,4 +297,3 @@ Update to support WordPress version 5.8.
|
|
283 |
|
284 |
= 8.5.0 =
|
285 |
Update to support PRO version 8.4.0.
|
286 |
-
|
6 |
Requires at least: 5.2.0
|
7 |
Tested up to: 5.8.1
|
8 |
Requires PHP: 5.6.0
|
9 |
+
Stable tag: 8.6.3
|
10 |
|
11 |
== Description ==
|
12 |
|
119 |
The widgets in this plugin are smart enough to not show up on pages or categories where the only thing that would display is the title. While it may appear like the widget is broken, it is actually doing what it is intended to do.
|
120 |
|
121 |
The most common causes for this confusion come from one of these reasons:
|
122 |
+
1. The incorrect widget was selected. Categories have their own widget as pages have their own widget.
|
123 |
2. "Display the highest level parent page" or "Display the highest level parent category" is not checked.
|
124 |
3. The widget is currently not being viewed on a page (for the pages widget) or category (for the categories widget).
|
125 |
|
126 |
= How do I change the styling of the current page? =
|
127 |
|
128 |
+
You may add CSS to your theme’s style.css to change the way the menu looks.
|
129 |
+
|
130 |
+
For example the following CSS would:
|
131 |
+
1. Remove the dot to the left of the menu item.
|
132 |
+
2. Change the link color.
|
133 |
+
3. Add a background on hover.
|
134 |
|
|
|
135 |
<code>
|
136 |
+
.advanced-sidebar-menu li.current-cat a,
|
137 |
.advanced-sidebar-menu li.current_page_item a {
|
138 |
color: black;
|
139 |
}
|
140 |
|
141 |
+
.advanced-sidebar-menu li.current-cat,
|
142 |
.advanced-sidebar-menu li.current_page_item {
|
143 |
+
list-style-type: none !important;
|
144 |
+
}
|
145 |
+
|
146 |
+
.advanced-sidebar-menu li.current-cat > a:hover,
|
147 |
+
.advanced-sidebar-menu li.current_page_item > a:hover {
|
148 |
+
background: teal;
|
149 |
}
|
150 |
</code>
|
151 |
|
167 |
|
168 |
|
169 |
== Changelog ==
|
170 |
+
= 8.6.3 =
|
171 |
+
* Fix issue with CSS classnames on current page's children.
|
172 |
+
|
173 |
= 8.6.2 =
|
174 |
* Assured consistency for levels of page menu's CSS classes.
|
175 |
* Converted category get highest parent logic to `get_ancestors`.
|
297 |
|
298 |
= 8.5.0 =
|
299 |
Update to support PRO version 8.4.0.
|
|
src/List_Pages.php
CHANGED
@@ -120,7 +120,7 @@ class List_Pages {
|
|
120 |
if ( ! empty( $this->get_current_page_id() ) ) {
|
121 |
if ( $this->get_current_page_id() === $post->ID ) {
|
122 |
$classes[] = 'current_page_item';
|
123 |
-
} elseif ( $this->
|
124 |
$classes[] = 'current_page_parent';
|
125 |
$classes[] = 'current_page_ancestor';
|
126 |
} else {
|
120 |
if ( ! empty( $this->get_current_page_id() ) ) {
|
121 |
if ( $this->get_current_page_id() === $post->ID ) {
|
122 |
$classes[] = 'current_page_item';
|
123 |
+
} elseif ( $this->current_page->post_parent === $post->ID ) {
|
124 |
$classes[] = 'current_page_parent';
|
125 |
$classes[] = 'current_page_ancestor';
|
126 |
} else {
|