Skip to content

Commit db36cde

Browse files
All tab
1 parent 7a0b21b commit db36cde

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

classes/Visualizer/Render/Library.php

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -81,6 +81,8 @@ private function _renderLibrary() {
8181
echo $this->custom_css;
8282
echo '<div id="visualizer-types" class="visualizer-clearfix">';
8383
echo '<ul class="subsubsub">';
84+
// All tab.
85+
echo '<li class="visualizer-list-item all"><a class="' . ( ! isset( $_GET['type'] ) || empty( $_GET['type'] ) ? 'current' : '' ) . '" href="', esc_url( add_query_arg( array( 'vpage' => false, 'type' => false ) ) ), '">' . __( 'All', 'visualizer' ) . '</a> | </li>';
8486
foreach ( $this->types as $type => $array ) {
8587
if ( ! is_array( $array ) ) {
8688
// support for old pro
@@ -98,9 +100,9 @@ private function _renderLibrary() {
98100
if ( ! $array['enabled'] ) {
99101
$link = "<a class=' visualizer-pro-only' href='" . Visualizer_Plugin::PRO_TEASER_URL . "' target='_blank'>";
100102
}
101-
echo '<li class="visualizer-list-item all">';
103+
echo '<li class="visualizer-list-item ' . esc_attr( $this->type ) . '">';
102104
if ( $type === $this->type ) {
103-
echo '<a class=" current" href="', esc_url( add_query_arg( 'vpage', false ) ), '">';
105+
echo '<a class="current" href="', esc_url( add_query_arg( 'vpage', false ) ), '">';
104106
echo $label;
105107
echo '</a>';
106108
} else {

0 commit comments

Comments
 (0)