Version Description
Download this release
Release Info
Developer | megamenu |
Plugin | Max Mega Menu |
Version | 2.4.1.5.1 |
Comparing to | |
See all releases |
Code changes from version 2.4.1.5 to 2.4.1.5.1
- classes/settings.class.php +78 -15
- classes/style-manager.class.php +4 -1
- classes/widget-manager.class.php +8 -0
- css/megamenu.scss +56 -10
- js/maxmegamenu.js +12 -6
- megamenu.php +3 -3
- readme.txt +11 -1
classes/settings.class.php
CHANGED
@@ -3083,6 +3083,11 @@ class Mega_Menu_Settings {
|
|
3083 |
'mobile_menu' => array(
|
3084 |
'title' => __( "Mobile Menu", "megamenu" ),
|
3085 |
'settings' => array(
|
|
|
|
|
|
|
|
|
|
|
3086 |
'toggle_bar_background' => array(
|
3087 |
'priority' => 20,
|
3088 |
'title' => __( "Toggle Bar Background", "megamenu" ),
|
@@ -3152,15 +3157,20 @@ class Mega_Menu_Settings {
|
|
3152 |
'title' => __( "The 'Disable Mobile Toggle Bar' option has been enabled. The following options are disabled as the mobile toggle bar will not be displayed.", "megamenu" ),
|
3153 |
'description' => '',
|
3154 |
),
|
3155 |
-
'
|
3156 |
-
'priority' =>
|
3157 |
-
'title' => __( "
|
3158 |
-
'description' =>
|
|
|
|
|
|
|
|
|
|
|
3159 |
'settings' => array(
|
3160 |
array(
|
3161 |
'title' => "",
|
3162 |
-
'type' => '
|
3163 |
-
'key' => '
|
3164 |
)
|
3165 |
)
|
3166 |
),
|
@@ -3186,15 +3196,25 @@ class Mega_Menu_Settings {
|
|
3186 |
)
|
3187 |
)
|
3188 |
),
|
3189 |
-
'
|
3190 |
-
'priority' =>
|
3191 |
-
'title' => __( "Menu Item
|
3192 |
-
'description' => __( "
|
3193 |
'settings' => array(
|
3194 |
array(
|
3195 |
-
'title' => "",
|
3196 |
-
'type' => '
|
3197 |
-
'key' => '
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
3198 |
)
|
3199 |
)
|
3200 |
),
|
@@ -3221,6 +3241,35 @@ class Mega_Menu_Settings {
|
|
3221 |
),
|
3222 |
)
|
3223 |
),
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
3224 |
)
|
3225 |
),
|
3226 |
'custom_styling' => array(
|
@@ -3709,17 +3758,31 @@ class Mega_Menu_Settings {
|
|
3709 |
<textarea id='codemirror' name='settings[<?php echo $key ?>]'><?php echo stripslashes( $value ) ?></textarea>
|
3710 |
|
3711 |
<p><b><?php _e("Custom Styling Tips", "megamenu"); ?></b></p>
|
|
|
3712 |
<ul class='custom_styling_tips'>
|
3713 |
<li><code>#{$wrap}</code> <?php _e("converts to the ID selector of the menu wrapper, e.g. div#mega-menu-wrap-primary", "megamenu"); ?></li>
|
3714 |
<li><code>#{$menu}</code> <?php _e("converts to the ID selector of the menu, e.g. ul#mega-menu-primary", "megamenu"); ?></li>
|
|
|
3715 |
<?php
|
3716 |
-
$string = __("Using the %wrap% and %menu% variables makes your theme portable (allowing you to apply the same theme to multiple menu locations)
|
3717 |
$string = str_replace('%wrap%', '<code>#{$wrap}</code>', $string);
|
3718 |
$string = str_replace('%menu%', '<code>#{$menu}</code>', $string);
|
3719 |
?>
|
3720 |
<li><?php echo $string; ?></li>
|
3721 |
<li>Example CSS:</li>
|
3722 |
-
<code>/** Add text shadow to top level menu items
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
3723 |
</ul>
|
3724 |
|
3725 |
<?php
|
3083 |
'mobile_menu' => array(
|
3084 |
'title' => __( "Mobile Menu", "megamenu" ),
|
3085 |
'settings' => array(
|
3086 |
+
'mobile_toggle_bar' => array(
|
3087 |
+
'priority' => 5,
|
3088 |
+
'title' => __( "Mobile Toggle Bar", "megamenu" ),
|
3089 |
+
'description' => '',
|
3090 |
+
),
|
3091 |
'toggle_bar_background' => array(
|
3092 |
'priority' => 20,
|
3093 |
'title' => __( "Toggle Bar Background", "megamenu" ),
|
3157 |
'title' => __( "The 'Disable Mobile Toggle Bar' option has been enabled. The following options are disabled as the mobile toggle bar will not be displayed.", "megamenu" ),
|
3158 |
'description' => '',
|
3159 |
),
|
3160 |
+
'mobile_top_level_menu_items' => array(
|
3161 |
+
'priority' => 33,
|
3162 |
+
'title' => __( "Top Level Menu Items", "megamenu" ),
|
3163 |
+
'description' => '',
|
3164 |
+
),
|
3165 |
+
'mobile_menu_item_height' => array(
|
3166 |
+
'priority' => 34,
|
3167 |
+
'title' => __( "Menu Item Height", "megamenu" ),
|
3168 |
+
'description' => __( "Height of each top level item in the mobile menu.", "megamenu" ),
|
3169 |
'settings' => array(
|
3170 |
array(
|
3171 |
'title' => "",
|
3172 |
+
'type' => 'freetext',
|
3173 |
+
'key' => 'mobile_menu_item_height'
|
3174 |
)
|
3175 |
)
|
3176 |
),
|
3196 |
)
|
3197 |
)
|
3198 |
),
|
3199 |
+
'mobile_background_hover' => array(
|
3200 |
+
'priority' => 36,
|
3201 |
+
'title' => __( "Menu Item Background (Hover)", "megamenu" ),
|
3202 |
+
'description' => __( "Set the background color for each top level item the mobile menu on hover.", "megamenu" ),
|
3203 |
'settings' => array(
|
3204 |
array(
|
3205 |
+
'title' => __( "From", "megamenu" ),
|
3206 |
+
'type' => 'color',
|
3207 |
+
'key' => 'mobile_menu_item_background_hover_from'
|
3208 |
+
),
|
3209 |
+
array(
|
3210 |
+
'title' => __( "Copy", "megamenu" ),
|
3211 |
+
'type' => 'copy_color',
|
3212 |
+
'key' => 'copy_color'
|
3213 |
+
),
|
3214 |
+
array(
|
3215 |
+
'title' => __( "To", "megamenu" ),
|
3216 |
+
'type' => 'color',
|
3217 |
+
'key' => 'mobile_menu_item_background_hover_to'
|
3218 |
)
|
3219 |
)
|
3220 |
),
|
3241 |
),
|
3242 |
)
|
3243 |
),
|
3244 |
+
'mobile_menu_item_font_hover' => array(
|
3245 |
+
'priority' => 55,
|
3246 |
+
'title' => __( "Font (Hover)", "megamenu" ),
|
3247 |
+
'description' => __( "The font color to use for each top level menu item in the mobile menu on hover.", "megamenu" ),
|
3248 |
+
'settings' => array(
|
3249 |
+
array(
|
3250 |
+
'title' => __( "Color", "megamenu" ),
|
3251 |
+
'type' => 'color',
|
3252 |
+
'key' => 'mobile_menu_item_link_color_hover'
|
3253 |
+
)
|
3254 |
+
)
|
3255 |
+
),
|
3256 |
+
'mobile_mega_menus' => array(
|
3257 |
+
'priority' => 60,
|
3258 |
+
'title' => __( "Mega Menus", "megamenu" ),
|
3259 |
+
'description' => '',
|
3260 |
+
),
|
3261 |
+
'mobile_columns' => array(
|
3262 |
+
'priority' => 65,
|
3263 |
+
'title' => __( "Mega Menu Columns", "megamenu" ),
|
3264 |
+
'description' => __( "Collapse mega menu content into this many columns on mobile.", "megamenu" ),
|
3265 |
+
'settings' => array(
|
3266 |
+
array(
|
3267 |
+
'title' => "",
|
3268 |
+
'type' => 'mobile_columns',
|
3269 |
+
'key' => 'mobile_columns'
|
3270 |
+
)
|
3271 |
+
)
|
3272 |
+
)
|
3273 |
)
|
3274 |
),
|
3275 |
'custom_styling' => array(
|
3758 |
<textarea id='codemirror' name='settings[<?php echo $key ?>]'><?php echo stripslashes( $value ) ?></textarea>
|
3759 |
|
3760 |
<p><b><?php _e("Custom Styling Tips", "megamenu"); ?></b></p>
|
3761 |
+
<p><?php _e("You can enter standard CSS or <a href='https://sass-lang.com/guide' target='_blank'>SCSS</a> into the custom styling area. If using SCSS there are some variables and mixins you can use:"); ?></p>
|
3762 |
<ul class='custom_styling_tips'>
|
3763 |
<li><code>#{$wrap}</code> <?php _e("converts to the ID selector of the menu wrapper, e.g. div#mega-menu-wrap-primary", "megamenu"); ?></li>
|
3764 |
<li><code>#{$menu}</code> <?php _e("converts to the ID selector of the menu, e.g. ul#mega-menu-primary", "megamenu"); ?></li>
|
3765 |
+
<li><code>@include mobile|desktop { .. }</code> <?php _e("wraps the CSS within a media query based on the configured Responsive Breakpoint (see example CSS)", "megamenu"); ?></li>
|
3766 |
<?php
|
3767 |
+
$string = __("Using the %wrap% and %menu% variables makes your theme portable (allowing you to apply the same theme to multiple menu locations)", "megamenu");
|
3768 |
$string = str_replace('%wrap%', '<code>#{$wrap}</code>', $string);
|
3769 |
$string = str_replace('%menu%', '<code>#{$menu}</code>', $string);
|
3770 |
?>
|
3771 |
<li><?php echo $string; ?></li>
|
3772 |
<li>Example CSS:</li>
|
3773 |
+
<code>/** Add text shadow to top level menu items on desktop AND mobile **/
|
3774 |
+
<br />#{$wrap} #{$menu} > li.mega-menu-item > a.mega-menu-link {
|
3775 |
+
<br /> text-shadow: 1px 1px #000000;
|
3776 |
+
<br />}
|
3777 |
+
</code>
|
3778 |
+
<br /><br />
|
3779 |
+
<code>/** Add text shadow to top level menu items on desktop only **/
|
3780 |
+
<br />@include desktop {
|
3781 |
+
<br /> #{$wrap} #{$menu} > li.mega-menu-item > a.mega-menu-link {
|
3782 |
+
<br /> text-shadow: 1px 1px #000000;
|
3783 |
+
<br /> }
|
3784 |
+
<br />}
|
3785 |
+
</code></li>
|
3786 |
</ul>
|
3787 |
|
3788 |
<?php
|
classes/style-manager.class.php
CHANGED
@@ -251,6 +251,9 @@ final class Mega_Menu_Style_Manager {
|
|
251 |
'mobile_menu_item_link_font_size' => 'menu_item_link_font_size',
|
252 |
'mobile_menu_item_link_color' => 'menu_item_link_color',
|
253 |
'mobile_menu_item_link_text_align' => 'menu_item_link_text_align',
|
|
|
|
|
|
|
254 |
'disable_mobile_toggle' => 'off',
|
255 |
'custom_css' => '/** Push menu onto new line **/
|
256 |
#{$wrap} {
|
@@ -457,7 +460,7 @@ final class Mega_Menu_Style_Manager {
|
|
457 |
}
|
458 |
}
|
459 |
|
460 |
-
$css = "/** " . date('l jS
|
461 |
|
462 |
$css = apply_filters( "megamenu_compiled_css", $css );
|
463 |
|
251 |
'mobile_menu_item_link_font_size' => 'menu_item_link_font_size',
|
252 |
'mobile_menu_item_link_color' => 'menu_item_link_color',
|
253 |
'mobile_menu_item_link_text_align' => 'menu_item_link_text_align',
|
254 |
+
'mobile_menu_item_link_color_hover' => 'menu_item_link_color_hover',
|
255 |
+
'mobile_menu_item_background_hover_from' => 'menu_item_background_hover_from',
|
256 |
+
'mobile_menu_item_background_hover_to' => 'menu_item_background_hover_to',
|
257 |
'disable_mobile_toggle' => 'off',
|
258 |
'custom_css' => '/** Push menu onto new line **/
|
259 |
#{$wrap} {
|
460 |
}
|
461 |
}
|
462 |
|
463 |
+
$css = "/** " . date('l jS F Y H:i:s e') . " ({$scss_location}) **/\n\n" . $css;
|
464 |
|
465 |
$css = apply_filters( "megamenu_compiled_css", $css );
|
466 |
|
classes/widget-manager.class.php
CHANGED
@@ -728,11 +728,19 @@ class Mega_Menu_Widget_Manager {
|
|
728 |
(array) $wp_registered_widgets[$id]['params']
|
729 |
);
|
730 |
|
|
|
731 |
$params[0]['before_title'] = apply_filters( "megamenu_before_widget_title", '<h4 class="mega-block-title">', $wp_registered_widgets[$id] );
|
732 |
$params[0]['after_title'] = apply_filters( "megamenu_after_widget_title", '</h4>', $wp_registered_widgets[$id] );
|
733 |
$params[0]['before_widget'] = apply_filters( "megamenu_before_widget", "", $wp_registered_widgets[$id] );
|
734 |
$params[0]['after_widget'] = apply_filters( "megamenu_after_widget", "", $wp_registered_widgets[$id] );
|
|
|
|
|
|
|
|
|
735 |
|
|
|
|
|
|
|
736 |
$callback = $wp_registered_widgets[$id]['callback'];
|
737 |
|
738 |
if ( is_callable( $callback ) ) {
|
728 |
(array) $wp_registered_widgets[$id]['params']
|
729 |
);
|
730 |
|
731 |
+
$params[0]['id'] = 'mega-menu';
|
732 |
$params[0]['before_title'] = apply_filters( "megamenu_before_widget_title", '<h4 class="mega-block-title">', $wp_registered_widgets[$id] );
|
733 |
$params[0]['after_title'] = apply_filters( "megamenu_after_widget_title", '</h4>', $wp_registered_widgets[$id] );
|
734 |
$params[0]['before_widget'] = apply_filters( "megamenu_before_widget", "", $wp_registered_widgets[$id] );
|
735 |
$params[0]['after_widget'] = apply_filters( "megamenu_after_widget", "", $wp_registered_widgets[$id] );
|
736 |
+
|
737 |
+
if ( defined("MEGAMENU_DYNAMIC_SIDEBAR_PARAMS") && MEGAMENU_DYNAMIC_SIDEBAR_PARAMS ) {
|
738 |
+
$params[0]['before_widget'] = apply_filters( "megamenu_before_widget", '<div id="" class="">', $wp_registered_widgets[$id] );
|
739 |
+
$params[0]['after_widget'] = apply_filters( "megamenu_after_widget", '</div>', $wp_registered_widgets[$id] );
|
740 |
|
741 |
+
$params = apply_filters('dynamic_sidebar_params', $params);
|
742 |
+
}
|
743 |
+
|
744 |
$callback = $wp_registered_widgets[$id]['callback'];
|
745 |
|
746 |
if ( is_callable( $callback ) ) {
|
css/megamenu.scss
CHANGED
@@ -50,6 +50,7 @@
|
|
50 |
vertical-align: baseline;
|
51 |
visibility: inherit;
|
52 |
width: auto;
|
|
|
53 |
|
54 |
&:before,
|
55 |
&:after {
|
@@ -96,9 +97,11 @@
|
|
96 |
.mega-description-group {
|
97 |
vertical-align: middle;
|
98 |
display: inline-block;
|
|
|
99 |
|
100 |
.mega-menu-title,
|
101 |
.mega-menu-description {
|
|
|
102 |
line-height: 1.5;
|
103 |
display: block;
|
104 |
}
|
@@ -126,6 +129,7 @@
|
|
126 |
|
127 |
> span.mega-title-below {
|
128 |
display: inline-block;
|
|
|
129 |
}
|
130 |
}
|
131 |
|
@@ -340,6 +344,11 @@
|
|
340 |
font-weight: $menu_item_link_weight_hover;
|
341 |
text-decoration: $menu_item_link_text_decoration_hover;
|
342 |
border-color: $menu_item_border_color_hover;
|
|
|
|
|
|
|
|
|
|
|
343 |
}
|
344 |
|
345 |
@if $menu_item_highlight_current == 'on' {
|
@@ -353,6 +362,11 @@
|
|
353 |
font-weight: $menu_item_link_weight_hover;
|
354 |
text-decoration: $menu_item_link_text_decoration_hover;
|
355 |
border-color: $menu_item_border_color_hover;
|
|
|
|
|
|
|
|
|
|
|
356 |
}
|
357 |
}
|
358 |
|
@@ -381,11 +395,7 @@
|
|
381 |
font-family: $menu_item_link_font;
|
382 |
font-size: $menu_item_link_font_size;
|
383 |
|
384 |
-
|
385 |
-
text-align: $mobile_menu_item_link_text_align;
|
386 |
-
color: $mobile_menu_item_link_color;
|
387 |
-
font-size: $mobile_menu_item_link_font_size;
|
388 |
-
}
|
389 |
}
|
390 |
|
391 |
// support for multi line links
|
@@ -413,12 +423,16 @@
|
|
413 |
}
|
414 |
|
415 |
> a.mega-menu-link {
|
416 |
-
@include border-radius(0
|
417 |
border: 0;
|
418 |
margin: 0;
|
419 |
line-height: $mobile_menu_item_height;
|
420 |
height: $mobile_menu_item_height;
|
421 |
padding: 0 10px;
|
|
|
|
|
|
|
|
|
422 |
}
|
423 |
|
424 |
}
|
@@ -563,6 +577,7 @@
|
|
563 |
padding: $panel_header_padding_top $panel_header_padding_right $panel_header_padding_bottom $panel_header_padding_left;
|
564 |
vertical-align: top;
|
565 |
display: block;
|
|
|
566 |
border-top: $panel_header_border_top solid $panel_header_border_color;
|
567 |
border-left: $panel_header_border_left solid $panel_header_border_color;
|
568 |
border-right: $panel_header_border_right solid $panel_header_border_color;
|
@@ -926,14 +941,13 @@
|
|
926 |
padding: 0;
|
927 |
}
|
928 |
|
929 |
-
.mega-search-wrap {
|
930 |
-
align-self: center;
|
931 |
-
}
|
932 |
-
|
933 |
@include mobile {
|
934 |
@if $disable_mobile_toggle == on {
|
935 |
display: none;
|
936 |
} @else {
|
|
|
|
|
|
|
937 |
display: flex;
|
938 |
}
|
939 |
}
|
@@ -941,12 +955,25 @@
|
|
941 |
.mega-toggle-blocks-left,
|
942 |
.mega-toggle-blocks-center,
|
943 |
.mega-toggle-blocks-right {
|
|
|
|
|
|
|
944 |
display: flex;
|
|
|
|
|
|
|
945 |
flex-basis: 33.33%;
|
946 |
}
|
947 |
|
948 |
.mega-toggle-blocks-left {
|
|
|
|
|
|
|
949 |
flex: 1;
|
|
|
|
|
|
|
|
|
950 |
justify-content: flex-start;
|
951 |
|
952 |
.mega-toggle-block {
|
@@ -955,6 +982,9 @@
|
|
955 |
}
|
956 |
|
957 |
.mega-toggle-blocks-center {
|
|
|
|
|
|
|
958 |
justify-content: center;
|
959 |
|
960 |
.mega-toggle-block {
|
@@ -964,7 +994,13 @@
|
|
964 |
}
|
965 |
|
966 |
.mega-toggle-blocks-right {
|
|
|
|
|
|
|
967 |
flex: 1;
|
|
|
|
|
|
|
968 |
justify-content: flex-end;
|
969 |
|
970 |
.mega-toggle-block {
|
@@ -973,8 +1009,18 @@
|
|
973 |
}
|
974 |
|
975 |
.mega-toggle-block {
|
|
|
|
|
|
|
976 |
display: flex;
|
977 |
height: 100%;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
978 |
flex-shrink: 0;
|
979 |
}
|
980 |
|
50 |
vertical-align: baseline;
|
51 |
visibility: inherit;
|
52 |
width: auto;
|
53 |
+
word-wrap: break-word;
|
54 |
|
55 |
&:before,
|
56 |
&:after {
|
97 |
.mega-description-group {
|
98 |
vertical-align: middle;
|
99 |
display: inline-block;
|
100 |
+
transition: none;
|
101 |
|
102 |
.mega-menu-title,
|
103 |
.mega-menu-description {
|
104 |
+
transition: none;
|
105 |
line-height: 1.5;
|
106 |
display: block;
|
107 |
}
|
129 |
|
130 |
> span.mega-title-below {
|
131 |
display: inline-block;
|
132 |
+
transition: none;
|
133 |
}
|
134 |
}
|
135 |
|
344 |
font-weight: $menu_item_link_weight_hover;
|
345 |
text-decoration: $menu_item_link_text_decoration_hover;
|
346 |
border-color: $menu_item_border_color_hover;
|
347 |
+
|
348 |
+
@include mobile {
|
349 |
+
color: $mobile_menu_item_link_color_hover;
|
350 |
+
@include background($mobile_menu_item_background_hover_from, $mobile_menu_item_background_hover_to);
|
351 |
+
}
|
352 |
}
|
353 |
|
354 |
@if $menu_item_highlight_current == 'on' {
|
362 |
font-weight: $menu_item_link_weight_hover;
|
363 |
text-decoration: $menu_item_link_text_decoration_hover;
|
364 |
border-color: $menu_item_border_color_hover;
|
365 |
+
|
366 |
+
@include mobile {
|
367 |
+
color: $mobile_menu_item_link_color_hover;
|
368 |
+
@include background($mobile_menu_item_background_hover_from, $mobile_menu_item_background_hover_to);
|
369 |
+
}
|
370 |
}
|
371 |
}
|
372 |
|
395 |
font-family: $menu_item_link_font;
|
396 |
font-size: $menu_item_link_font_size;
|
397 |
|
398 |
+
|
|
|
|
|
|
|
|
|
399 |
}
|
400 |
|
401 |
// support for multi line links
|
423 |
}
|
424 |
|
425 |
> a.mega-menu-link {
|
426 |
+
@include border-radius(0);
|
427 |
border: 0;
|
428 |
margin: 0;
|
429 |
line-height: $mobile_menu_item_height;
|
430 |
height: $mobile_menu_item_height;
|
431 |
padding: 0 10px;
|
432 |
+
background: transparent;
|
433 |
+
text-align: $mobile_menu_item_link_text_align;
|
434 |
+
color: $mobile_menu_item_link_color;
|
435 |
+
font-size: $mobile_menu_item_link_font_size;
|
436 |
}
|
437 |
|
438 |
}
|
577 |
padding: $panel_header_padding_top $panel_header_padding_right $panel_header_padding_bottom $panel_header_padding_left;
|
578 |
vertical-align: top;
|
579 |
display: block;
|
580 |
+
visibility: inherit;
|
581 |
border-top: $panel_header_border_top solid $panel_header_border_color;
|
582 |
border-left: $panel_header_border_left solid $panel_header_border_color;
|
583 |
border-right: $panel_header_border_right solid $panel_header_border_color;
|
941 |
padding: 0;
|
942 |
}
|
943 |
|
|
|
|
|
|
|
|
|
944 |
@include mobile {
|
945 |
@if $disable_mobile_toggle == on {
|
946 |
display: none;
|
947 |
} @else {
|
948 |
+
display: -webkit-box;
|
949 |
+
display: -ms-flexbox;
|
950 |
+
display: -webkit-flex;
|
951 |
display: flex;
|
952 |
}
|
953 |
}
|
955 |
.mega-toggle-blocks-left,
|
956 |
.mega-toggle-blocks-center,
|
957 |
.mega-toggle-blocks-right {
|
958 |
+
display: -webkit-box;
|
959 |
+
display: -ms-flexbox;
|
960 |
+
display: -webkit-flex;
|
961 |
display: flex;
|
962 |
+
|
963 |
+
-ms-flex-preferred-size: 33.33%;
|
964 |
+
-webkit-flex-basis: 33.33%;
|
965 |
flex-basis: 33.33%;
|
966 |
}
|
967 |
|
968 |
.mega-toggle-blocks-left {
|
969 |
+
-webkit-box-flex: 1;
|
970 |
+
-ms-flex: 1;
|
971 |
+
-webkit-flex: 1;
|
972 |
flex: 1;
|
973 |
+
|
974 |
+
-webkit-box-pack: start;
|
975 |
+
-ms-flex-pack: start;
|
976 |
+
-webkit-justify-content: flex-start;
|
977 |
justify-content: flex-start;
|
978 |
|
979 |
.mega-toggle-block {
|
982 |
}
|
983 |
|
984 |
.mega-toggle-blocks-center {
|
985 |
+
-webkit-box-pack: center;
|
986 |
+
-ms-flex-pack: center;
|
987 |
+
-webkit-justify-content: center;
|
988 |
justify-content: center;
|
989 |
|
990 |
.mega-toggle-block {
|
994 |
}
|
995 |
|
996 |
.mega-toggle-blocks-right {
|
997 |
+
-webkit-box-flex: 1;
|
998 |
+
-ms-flex: 1;
|
999 |
+
-webkit-flex: 1;
|
1000 |
flex: 1;
|
1001 |
+
-webkit-box-pack: end;
|
1002 |
+
-ms-flex-pack: end;
|
1003 |
+
-webkit-justify-content: flex-end;
|
1004 |
justify-content: flex-end;
|
1005 |
|
1006 |
.mega-toggle-block {
|
1009 |
}
|
1010 |
|
1011 |
.mega-toggle-block {
|
1012 |
+
display: -webkit-box;
|
1013 |
+
display: -ms-flexbox;
|
1014 |
+
display: -webkit-flex;
|
1015 |
display: flex;
|
1016 |
height: 100%;
|
1017 |
+
|
1018 |
+
-webkit-align-self: center;
|
1019 |
+
-ms-flex-item-align: center;
|
1020 |
+
align-self: center;
|
1021 |
+
|
1022 |
+
-ms-flex-negative: 0;
|
1023 |
+
-webkit-flex-shrink: 0;
|
1024 |
flex-shrink: 0;
|
1025 |
}
|
1026 |
|
js/maxmegamenu.js
CHANGED
@@ -119,7 +119,9 @@
|
|
119 |
if ( plugin.settings.effect == "slide" || plugin.isMobileView() && plugin.settings.effect_mobile == 'slide') {
|
120 |
var speed = plugin.isMobileView() ? plugin.settings.effect_speed_mobile : plugin.settings.effect_speed;
|
121 |
|
122 |
-
anchor.siblings(".mega-sub-menu").css("display", "none").animate({'height':'show', 'paddingTop':'show', 'paddingBottom':'show', 'minHeight':'show'}, speed)
|
|
|
|
|
123 |
}
|
124 |
|
125 |
anchor.parent().addClass("mega-toggle-on").triggerHandler("open_panel");
|
@@ -369,9 +371,7 @@
|
|
369 |
plugin.switchToDesktop();
|
370 |
}
|
371 |
|
372 |
-
|
373 |
-
plugin.calculateDynamicSubmenuWidths($("li.mega-menu-megamenu.mega-toggle-on > a.mega-menu-link", $menu));
|
374 |
-
}
|
375 |
};
|
376 |
|
377 |
plugin.reverseRightAlignedItems = function() {
|
@@ -410,7 +410,13 @@
|
|
410 |
$menu.siblings(".mega-menu-toggle").on("click", function(e) {
|
411 |
if ( $(e.target).is(".mega-menu-toggle-block, .mega-toggle-blocks-left, .mega-toggle-blocks-center, .mega-toggle-blocks-right, .mega-toggle-label, .mega-toggle-label span") ) {
|
412 |
if (plugin.settings.effect_mobile == 'slide') {
|
413 |
-
$
|
|
|
|
|
|
|
|
|
|
|
|
|
414 |
}
|
415 |
$(this).toggleClass("mega-menu-open");
|
416 |
}
|
@@ -438,6 +444,6 @@
|
|
438 |
};
|
439 |
|
440 |
$(function() {
|
441 |
-
$(
|
442 |
});
|
443 |
})(jQuery);
|
119 |
if ( plugin.settings.effect == "slide" || plugin.isMobileView() && plugin.settings.effect_mobile == 'slide') {
|
120 |
var speed = plugin.isMobileView() ? plugin.settings.effect_speed_mobile : plugin.settings.effect_speed;
|
121 |
|
122 |
+
anchor.siblings(".mega-sub-menu").css("display", "none").animate({'height':'show', 'paddingTop':'show', 'paddingBottom':'show', 'minHeight':'show'}, speed, function() {
|
123 |
+
$(this).css("display", "");
|
124 |
+
});
|
125 |
}
|
126 |
|
127 |
anchor.parent().addClass("mega-toggle-on").triggerHandler("open_panel");
|
371 |
plugin.switchToDesktop();
|
372 |
}
|
373 |
|
374 |
+
plugin.calculateDynamicSubmenuWidths($("li.mega-menu-megamenu.mega-toggle-on > a.mega-menu-link", $menu));
|
|
|
|
|
375 |
};
|
376 |
|
377 |
plugin.reverseRightAlignedItems = function() {
|
410 |
$menu.siblings(".mega-menu-toggle").on("click", function(e) {
|
411 |
if ( $(e.target).is(".mega-menu-toggle-block, .mega-toggle-blocks-left, .mega-toggle-blocks-center, .mega-toggle-blocks-right, .mega-toggle-label, .mega-toggle-label span") ) {
|
412 |
if (plugin.settings.effect_mobile == 'slide') {
|
413 |
+
if ($(this).hasClass("mega-menu-open")) {
|
414 |
+
$menu.animate({'height':'hide'}, plugin.settings.effect_speed_mobile, function() {
|
415 |
+
$(this).css("display", "");
|
416 |
+
});
|
417 |
+
} else {
|
418 |
+
$menu.animate({'height':'show'}, plugin.settings.effect_speed_mobile);
|
419 |
+
}
|
420 |
}
|
421 |
$(this).toggleClass("mega-menu-open");
|
422 |
}
|
444 |
};
|
445 |
|
446 |
$(function() {
|
447 |
+
$('.max-mega-menu').maxmegamenu();
|
448 |
});
|
449 |
})(jQuery);
|
megamenu.php
CHANGED
@@ -4,7 +4,7 @@
|
|
4 |
* Plugin Name: Max Mega Menu
|
5 |
* Plugin URI: https://www.megamenu.com
|
6 |
* Description: Easy to use drag & drop WordPress Mega Menu plugin. Create Mega Menus using Widgets. Responsive, retina & touch ready.
|
7 |
-
* Version: 2.4.1.5
|
8 |
* Author: Tom Hemsley
|
9 |
* Author URI: https://www.megamenu.com
|
10 |
* License: GPL-2.0+
|
@@ -26,7 +26,7 @@ final class Mega_Menu {
|
|
26 |
/**
|
27 |
* @var string
|
28 |
*/
|
29 |
-
public $version = '2.4.1.5';
|
30 |
|
31 |
|
32 |
/**
|
@@ -1090,7 +1090,7 @@ final class Mega_Menu {
|
|
1090 |
'container' => 'div',
|
1091 |
'container_class' => 'mega-menu-wrap',
|
1092 |
'container_id' => 'mega-menu-wrap-' . $sanitized_location,
|
1093 |
-
'menu_class' => 'mega-menu mega-menu-horizontal',
|
1094 |
'menu_id' => 'mega-menu-' . $sanitized_location,
|
1095 |
'fallback_cb' => 'wp_page_menu',
|
1096 |
'before' => '',
|
4 |
* Plugin Name: Max Mega Menu
|
5 |
* Plugin URI: https://www.megamenu.com
|
6 |
* Description: Easy to use drag & drop WordPress Mega Menu plugin. Create Mega Menus using Widgets. Responsive, retina & touch ready.
|
7 |
+
* Version: 2.4.1.5.1
|
8 |
* Author: Tom Hemsley
|
9 |
* Author URI: https://www.megamenu.com
|
10 |
* License: GPL-2.0+
|
26 |
/**
|
27 |
* @var string
|
28 |
*/
|
29 |
+
public $version = '2.4.1.5.1';
|
30 |
|
31 |
|
32 |
/**
|
1090 |
'container' => 'div',
|
1091 |
'container_class' => 'mega-menu-wrap',
|
1092 |
'container_id' => 'mega-menu-wrap-' . $sanitized_location,
|
1093 |
+
'menu_class' => 'mega-menu max-mega-menu mega-menu-horizontal',
|
1094 |
'menu_id' => 'mega-menu-' . $sanitized_location,
|
1095 |
'fallback_cb' => 'wp_page_menu',
|
1096 |
'before' => '',
|
readme.txt
CHANGED
@@ -3,7 +3,7 @@ Contributors: megamenu
|
|
3 |
Tags: menu, megamenu, mega menu, navigation, widget, dropdown menu, drag and drop, mobile, responsive, retina, theme editor, widget, shortcode, sidebar, icons, dashicons
|
4 |
Requires at least: 3.8
|
5 |
Tested up to: 4.9
|
6 |
-
Stable tag: 2.4.1.
|
7 |
License: GPLv2 or later
|
8 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
9 |
|
@@ -108,6 +108,16 @@ See https://www.megamenu.com for more screenshots
|
|
108 |
|
109 |
== Changelog ==
|
110 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
111 |
= 2.4.1.5 =
|
112 |
|
113 |
* Improvement: Detect Hummingbird as a caching plugin
|
3 |
Tags: menu, megamenu, mega menu, navigation, widget, dropdown menu, drag and drop, mobile, responsive, retina, theme editor, widget, shortcode, sidebar, icons, dashicons
|
4 |
Requires at least: 3.8
|
5 |
Tested up to: 4.9
|
6 |
+
Stable tag: 2.4.1.5
|
7 |
License: GPLv2 or later
|
8 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
9 |
|
108 |
|
109 |
== Changelog ==
|
110 |
|
111 |
+
= 2.4.1.6 =
|
112 |
+
|
113 |
+
* Fix: Add vendor prefixes to toggle block CSS to add compatibility for old iPhones
|
114 |
+
* Fix: Desktop menu visibility when Mobile Effect is set to slide and the browser is resized between desktop - mobile - desktop
|
115 |
+
* Improvement: Enable dynamic_sidebar_params filter when MEGAMENU_DYNAMIC_SIDEBAR_PARAMS constant is true
|
116 |
+
* Improvement: Add Mobile Font (Hover) and Mobile Menu Item Background (Hover) options to theme editor
|
117 |
+
* Improvement: CSS overrides/resets - word-wrap on menu item titles, transitions on anchors, visibility on h4 elements
|
118 |
+
* Improvement: Use "max-mega-menu" class instead of "mega-menu" to avoid conflicts with themes that already use a "mega-menu" class
|
119 |
+
* Improvement: Small JavaScript update
|
120 |
+
|
121 |
= 2.4.1.5 =
|
122 |
|
123 |
* Improvement: Detect Hummingbird as a caching plugin
|