Version Description
[15/08/2016] =
- Fix: Mega sub menus not correctly closed on mobile when effect is set to Fade
- Fix: Cursor styling for disabled links
- Fix: Apply animation to closing sub menus
- Fix: Bring megamenu button forward on nav-menus page
- Fix: Replace deprecated jQuery 'addSelf' with 'andBack'
- Improvement: Theme Editor usability. Add color pallete to color picker. Add Copy Color option
- Improvement: Only prompt for SCSS compilation when current CSS is outdated
- Change: Indicate whether style.css file was generated from core or custom version of megamenu.scss
Download this release
Release Info
Developer | megamenu |
Plugin | Max Mega Menu |
Version | 2.2.3 |
Comparing to | |
See all releases |
Code changes from version 2.2.2 to 2.2.3
- classes/settings.class.php +127 -42
- classes/style-manager.class.php +37 -22
- css/admin/menus.css +3 -4
- css/admin/settings.css +37 -1
- css/megamenu.scss +12 -11
- css/toggle-blocks.scss +0 -2
- js/maxmegamenu.js +5 -5
- js/settings.js +14 -2
- megamenu.php +9 -3
- readme.txt +12 -1
classes/settings.class.php
CHANGED
@@ -1570,6 +1570,19 @@ class Mega_Menu_Settings {
|
|
1570 |
'menu_bar' => array(
|
1571 |
'title' => __( "Menu Bar", "megamenu" ),
|
1572 |
'settings' => array(
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1573 |
'menu_background' => array(
|
1574 |
'priority' => 10,
|
1575 |
'title' => __( "Menu Background", "megamenu" ),
|
@@ -1580,6 +1593,11 @@ class Mega_Menu_Settings {
|
|
1580 |
'type' => 'color',
|
1581 |
'key' => 'container_background_from'
|
1582 |
),
|
|
|
|
|
|
|
|
|
|
|
1583 |
array(
|
1584 |
'title' => __( "To", "megamenu" ),
|
1585 |
'type' => 'color',
|
@@ -1677,6 +1695,11 @@ class Mega_Menu_Settings {
|
|
1677 |
'type' => 'color',
|
1678 |
'key' => 'menu_item_background_from'
|
1679 |
),
|
|
|
|
|
|
|
|
|
|
|
1680 |
array(
|
1681 |
'title' => __( "To", "megamenu" ),
|
1682 |
'type' => 'color',
|
@@ -1694,6 +1717,11 @@ class Mega_Menu_Settings {
|
|
1694 |
'type' => 'color',
|
1695 |
'key' => 'menu_item_background_hover_from'
|
1696 |
),
|
|
|
|
|
|
|
|
|
|
|
1697 |
array(
|
1698 |
'title' => __( "To", "megamenu" ),
|
1699 |
'type' => 'color',
|
@@ -1714,19 +1742,6 @@ class Mega_Menu_Settings {
|
|
1714 |
)
|
1715 |
)
|
1716 |
),
|
1717 |
-
'menu_item_height' => array(
|
1718 |
-
'priority' => 90,
|
1719 |
-
'title' => __( "Menu Item Height", "megamenu" ),
|
1720 |
-
'description' => __( "Define the height of each top level menu item. This value, plus the container top and bottom padding values define the overall height of the menu bar.", "megamenu" ),
|
1721 |
-
'settings' => array(
|
1722 |
-
array(
|
1723 |
-
'title' => __( "", "megamenu" ),
|
1724 |
-
'type' => 'freetext',
|
1725 |
-
'key' => 'menu_item_link_height',
|
1726 |
-
'validation' => 'px'
|
1727 |
-
)
|
1728 |
-
)
|
1729 |
-
),
|
1730 |
'menu_item_font' => array(
|
1731 |
'priority' => 100,
|
1732 |
'title' => __( "Font", "megamenu" ),
|
@@ -1763,6 +1778,11 @@ class Mega_Menu_Settings {
|
|
1763 |
'type' => 'decoration',
|
1764 |
'key' => 'menu_item_link_text_decoration'
|
1765 |
),
|
|
|
|
|
|
|
|
|
|
|
1766 |
)
|
1767 |
),
|
1768 |
'menu_item_font_hover' => array(
|
@@ -1947,6 +1967,11 @@ class Mega_Menu_Settings {
|
|
1947 |
'type' => 'color',
|
1948 |
'key' => 'panel_background_from'
|
1949 |
),
|
|
|
|
|
|
|
|
|
|
|
1950 |
array(
|
1951 |
'title' => __( "To", "megamenu" ),
|
1952 |
'type' => 'color',
|
@@ -2075,8 +2100,8 @@ class Mega_Menu_Settings {
|
|
2075 |
),
|
2076 |
'widget_padding' => array(
|
2077 |
'priority' => 60,
|
2078 |
-
'title' => __( "
|
2079 |
-
'description' => __( "Use this to define the spacing between each widget
|
2080 |
'settings' => array(
|
2081 |
array(
|
2082 |
'title' => __( "Top", "megamenu" ),
|
@@ -2104,9 +2129,14 @@ class Mega_Menu_Settings {
|
|
2104 |
)
|
2105 |
)
|
2106 |
),
|
|
|
|
|
|
|
|
|
|
|
2107 |
'widget_heading_font' => array(
|
2108 |
'priority' => 70,
|
2109 |
-
'title' => __( "
|
2110 |
'description' => __( "Set the font to use Widget headers in the mega menu. Tip: set this to the same style as the Second Level Menu Item Header font to keep your styling consistent.", "megamenu" ),
|
2111 |
'settings' => array(
|
2112 |
array(
|
@@ -2142,32 +2172,9 @@ class Mega_Menu_Settings {
|
|
2142 |
),
|
2143 |
)
|
2144 |
),
|
2145 |
-
'widget_content_font' => array(
|
2146 |
-
'priority' => 80,
|
2147 |
-
'title' => __( "Widget Content Font", "megamenu" ),
|
2148 |
-
'description' => __( "Set the font to use for panel contents.", "megamenu" ),
|
2149 |
-
'settings' => array(
|
2150 |
-
array(
|
2151 |
-
'title' => __( "Color", "megamenu" ),
|
2152 |
-
'type' => 'color',
|
2153 |
-
'key' => 'panel_font_color'
|
2154 |
-
),
|
2155 |
-
array(
|
2156 |
-
'title' => __( "Size", "megamenu" ),
|
2157 |
-
'type' => 'freetext',
|
2158 |
-
'key' => 'panel_font_size',
|
2159 |
-
'validation' => 'px'
|
2160 |
-
),
|
2161 |
-
array(
|
2162 |
-
'title' => __( "Family", "megamenu" ),
|
2163 |
-
'type' => 'font',
|
2164 |
-
'key' => 'panel_font_family'
|
2165 |
-
)
|
2166 |
-
)
|
2167 |
-
),
|
2168 |
'widget_heading_padding' => array(
|
2169 |
'priority' => 90,
|
2170 |
-
'title' => __( "
|
2171 |
'description' => __( "Set the padding for the widget headings.", "megamenu" ),
|
2172 |
'settings' => array(
|
2173 |
array(
|
@@ -2198,7 +2205,7 @@ class Mega_Menu_Settings {
|
|
2198 |
),
|
2199 |
'widget_heading_margin' => array(
|
2200 |
'priority' => 100,
|
2201 |
-
'title' => __( "
|
2202 |
'description' => __( "Set the margin for the widget headings.", "megamenu" ),
|
2203 |
'settings' => array(
|
2204 |
array(
|
@@ -2229,7 +2236,7 @@ class Mega_Menu_Settings {
|
|
2229 |
),
|
2230 |
'widget_header_border' => array(
|
2231 |
'priority' => 110,
|
2232 |
-
'title' => __( "
|
2233 |
'description' => __( "Set the border for the widget headings.", "megamenu" ),
|
2234 |
'settings' => array(
|
2235 |
array(
|
@@ -2263,6 +2270,29 @@ class Mega_Menu_Settings {
|
|
2263 |
)
|
2264 |
)
|
2265 |
),
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2266 |
'second_level_menu_items' => array(
|
2267 |
'priority' => 120,
|
2268 |
'title' => __( "Second Level Menu Items", "megamenu" ),
|
@@ -2338,6 +2368,11 @@ class Mega_Menu_Settings {
|
|
2338 |
'type' => 'color',
|
2339 |
'key' => 'panel_second_level_background_hover_from'
|
2340 |
),
|
|
|
|
|
|
|
|
|
|
|
2341 |
array(
|
2342 |
'title' => __( "To", "megamenu" ),
|
2343 |
'type' => 'color',
|
@@ -2518,6 +2553,11 @@ class Mega_Menu_Settings {
|
|
2518 |
'type' => 'color',
|
2519 |
'key' => 'panel_third_level_background_hover_from'
|
2520 |
),
|
|
|
|
|
|
|
|
|
|
|
2521 |
array(
|
2522 |
'title' => __( "To", "megamenu" ),
|
2523 |
'type' => 'color',
|
@@ -2571,6 +2611,11 @@ class Mega_Menu_Settings {
|
|
2571 |
'type' => 'color',
|
2572 |
'key' => 'flyout_menu_background_from'
|
2573 |
),
|
|
|
|
|
|
|
|
|
|
|
2574 |
array(
|
2575 |
'title' => __( "To", "megamenu" ),
|
2576 |
'type' => 'color',
|
@@ -2701,6 +2746,11 @@ class Mega_Menu_Settings {
|
|
2701 |
'type' => 'color',
|
2702 |
'key' => 'flyout_background_from'
|
2703 |
),
|
|
|
|
|
|
|
|
|
|
|
2704 |
array(
|
2705 |
'title' => __( "To", "megamenu" ),
|
2706 |
'type' => 'color',
|
@@ -2718,6 +2768,11 @@ class Mega_Menu_Settings {
|
|
2718 |
'type' => 'color',
|
2719 |
'key' => 'flyout_background_hover_from'
|
2720 |
),
|
|
|
|
|
|
|
|
|
|
|
2721 |
array(
|
2722 |
'title' => __( "To", "megamenu" ),
|
2723 |
'type' => 'color',
|
@@ -2883,6 +2938,11 @@ class Mega_Menu_Settings {
|
|
2883 |
'type' => 'color',
|
2884 |
'key' => 'toggle_background_from'
|
2885 |
),
|
|
|
|
|
|
|
|
|
|
|
2886 |
array(
|
2887 |
'title' => __( "To", "megamenu" ),
|
2888 |
'type' => 'color',
|
@@ -2949,6 +3009,11 @@ class Mega_Menu_Settings {
|
|
2949 |
'type' => 'color',
|
2950 |
'key' => 'mobile_background_from'
|
2951 |
),
|
|
|
|
|
|
|
|
|
|
|
2952 |
array(
|
2953 |
'title' => __( "To", "megamenu" ),
|
2954 |
'type' => 'color',
|
@@ -3054,6 +3119,9 @@ class Mega_Menu_Settings {
|
|
3054 |
case "mobile_columns":
|
3055 |
$this->print_theme_mobile_columns_option( $setting['key'] );
|
3056 |
break;
|
|
|
|
|
|
|
3057 |
default:
|
3058 |
do_action("megamenu_print_theme_option_{$setting['type']}", $setting['key'], $this->id );
|
3059 |
break;
|
@@ -3173,6 +3241,23 @@ class Mega_Menu_Settings {
|
|
3173 |
}
|
3174 |
|
3175 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
3176 |
/**
|
3177 |
* Print a select dropdown with 1 and 2 options
|
3178 |
*
|
1570 |
'menu_bar' => array(
|
1571 |
'title' => __( "Menu Bar", "megamenu" ),
|
1572 |
'settings' => array(
|
1573 |
+
'menu_item_height' => array(
|
1574 |
+
'priority' => 05,
|
1575 |
+
'title' => __( "Menu Height", "megamenu" ),
|
1576 |
+
'description' => __( "Define the height of each top level menu item link. This value plus the Menu Padding (top and bottom) settings define the overall height of the menu bar.", "megamenu" ),
|
1577 |
+
'settings' => array(
|
1578 |
+
array(
|
1579 |
+
'title' => __( "", "megamenu" ),
|
1580 |
+
'type' => 'freetext',
|
1581 |
+
'key' => 'menu_item_link_height',
|
1582 |
+
'validation' => 'px'
|
1583 |
+
)
|
1584 |
+
)
|
1585 |
+
),
|
1586 |
'menu_background' => array(
|
1587 |
'priority' => 10,
|
1588 |
'title' => __( "Menu Background", "megamenu" ),
|
1593 |
'type' => 'color',
|
1594 |
'key' => 'container_background_from'
|
1595 |
),
|
1596 |
+
array(
|
1597 |
+
'title' => __( "Copy", "megamenu" ),
|
1598 |
+
'type' => 'copy_color',
|
1599 |
+
'key' => 'copy_color'
|
1600 |
+
),
|
1601 |
array(
|
1602 |
'title' => __( "To", "megamenu" ),
|
1603 |
'type' => 'color',
|
1695 |
'type' => 'color',
|
1696 |
'key' => 'menu_item_background_from'
|
1697 |
),
|
1698 |
+
array(
|
1699 |
+
'title' => __( "Copy", "megamenu" ),
|
1700 |
+
'type' => 'copy_color',
|
1701 |
+
'key' => 'copy_color'
|
1702 |
+
),
|
1703 |
array(
|
1704 |
'title' => __( "To", "megamenu" ),
|
1705 |
'type' => 'color',
|
1717 |
'type' => 'color',
|
1718 |
'key' => 'menu_item_background_hover_from'
|
1719 |
),
|
1720 |
+
array(
|
1721 |
+
'title' => __( "Copy", "megamenu" ),
|
1722 |
+
'type' => 'copy_color',
|
1723 |
+
'key' => 'copy_color'
|
1724 |
+
),
|
1725 |
array(
|
1726 |
'title' => __( "To", "megamenu" ),
|
1727 |
'type' => 'color',
|
1742 |
)
|
1743 |
)
|
1744 |
),
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1745 |
'menu_item_font' => array(
|
1746 |
'priority' => 100,
|
1747 |
'title' => __( "Font", "megamenu" ),
|
1778 |
'type' => 'decoration',
|
1779 |
'key' => 'menu_item_link_text_decoration'
|
1780 |
),
|
1781 |
+
array(
|
1782 |
+
'title' => __( "Align", "megamenu" ),
|
1783 |
+
'type' => 'align',
|
1784 |
+
'key' => 'menu_item_link_text_align'
|
1785 |
+
),
|
1786 |
)
|
1787 |
),
|
1788 |
'menu_item_font_hover' => array(
|
1967 |
'type' => 'color',
|
1968 |
'key' => 'panel_background_from'
|
1969 |
),
|
1970 |
+
array(
|
1971 |
+
'title' => __( "Copy", "megamenu" ),
|
1972 |
+
'type' => 'copy_color',
|
1973 |
+
'key' => 'copy_color'
|
1974 |
+
),
|
1975 |
array(
|
1976 |
'title' => __( "To", "megamenu" ),
|
1977 |
'type' => 'color',
|
2100 |
),
|
2101 |
'widget_padding' => array(
|
2102 |
'priority' => 60,
|
2103 |
+
'title' => __( "Item Padding", "megamenu" ),
|
2104 |
+
'description' => __( "Use this to define the spacing between each widget / set of menu items within the panel.", "megamenu" ),
|
2105 |
'settings' => array(
|
2106 |
array(
|
2107 |
'title' => __( "Top", "megamenu" ),
|
2129 |
)
|
2130 |
)
|
2131 |
),
|
2132 |
+
'mega_menu_widgets' => array(
|
2133 |
+
'priority' => 65,
|
2134 |
+
'title' => __( "Widgets", "megamenu" ),
|
2135 |
+
'description' => '',
|
2136 |
+
),
|
2137 |
'widget_heading_font' => array(
|
2138 |
'priority' => 70,
|
2139 |
+
'title' => __( "Heading Font", "megamenu" ),
|
2140 |
'description' => __( "Set the font to use Widget headers in the mega menu. Tip: set this to the same style as the Second Level Menu Item Header font to keep your styling consistent.", "megamenu" ),
|
2141 |
'settings' => array(
|
2142 |
array(
|
2172 |
),
|
2173 |
)
|
2174 |
),
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2175 |
'widget_heading_padding' => array(
|
2176 |
'priority' => 90,
|
2177 |
+
'title' => __( "Heading Padding", "megamenu" ),
|
2178 |
'description' => __( "Set the padding for the widget headings.", "megamenu" ),
|
2179 |
'settings' => array(
|
2180 |
array(
|
2205 |
),
|
2206 |
'widget_heading_margin' => array(
|
2207 |
'priority' => 100,
|
2208 |
+
'title' => __( "Heading Margin", "megamenu" ),
|
2209 |
'description' => __( "Set the margin for the widget headings.", "megamenu" ),
|
2210 |
'settings' => array(
|
2211 |
array(
|
2236 |
),
|
2237 |
'widget_header_border' => array(
|
2238 |
'priority' => 110,
|
2239 |
+
'title' => __( "Header Border", "megamenu" ),
|
2240 |
'description' => __( "Set the border for the widget headings.", "megamenu" ),
|
2241 |
'settings' => array(
|
2242 |
array(
|
2270 |
)
|
2271 |
)
|
2272 |
),
|
2273 |
+
'widget_content_font' => array(
|
2274 |
+
'priority' => 115,
|
2275 |
+
'title' => __( "Content Font", "megamenu" ),
|
2276 |
+
'description' => __( "Set the font to use for panel contents.", "megamenu" ),
|
2277 |
+
'settings' => array(
|
2278 |
+
array(
|
2279 |
+
'title' => __( "Color", "megamenu" ),
|
2280 |
+
'type' => 'color',
|
2281 |
+
'key' => 'panel_font_color'
|
2282 |
+
),
|
2283 |
+
array(
|
2284 |
+
'title' => __( "Size", "megamenu" ),
|
2285 |
+
'type' => 'freetext',
|
2286 |
+
'key' => 'panel_font_size',
|
2287 |
+
'validation' => 'px'
|
2288 |
+
),
|
2289 |
+
array(
|
2290 |
+
'title' => __( "Family", "megamenu" ),
|
2291 |
+
'type' => 'font',
|
2292 |
+
'key' => 'panel_font_family'
|
2293 |
+
)
|
2294 |
+
)
|
2295 |
+
),
|
2296 |
'second_level_menu_items' => array(
|
2297 |
'priority' => 120,
|
2298 |
'title' => __( "Second Level Menu Items", "megamenu" ),
|
2368 |
'type' => 'color',
|
2369 |
'key' => 'panel_second_level_background_hover_from'
|
2370 |
),
|
2371 |
+
array(
|
2372 |
+
'title' => __( "Copy", "megamenu" ),
|
2373 |
+
'type' => 'copy_color',
|
2374 |
+
'key' => 'copy_color'
|
2375 |
+
),
|
2376 |
array(
|
2377 |
'title' => __( "To", "megamenu" ),
|
2378 |
'type' => 'color',
|
2553 |
'type' => 'color',
|
2554 |
'key' => 'panel_third_level_background_hover_from'
|
2555 |
),
|
2556 |
+
array(
|
2557 |
+
'title' => __( "Copy", "megamenu" ),
|
2558 |
+
'type' => 'copy_color',
|
2559 |
+
'key' => 'copy_color'
|
2560 |
+
),
|
2561 |
array(
|
2562 |
'title' => __( "To", "megamenu" ),
|
2563 |
'type' => 'color',
|
2611 |
'type' => 'color',
|
2612 |
'key' => 'flyout_menu_background_from'
|
2613 |
),
|
2614 |
+
array(
|
2615 |
+
'title' => __( "Copy", "megamenu" ),
|
2616 |
+
'type' => 'copy_color',
|
2617 |
+
'key' => 'copy_color'
|
2618 |
+
),
|
2619 |
array(
|
2620 |
'title' => __( "To", "megamenu" ),
|
2621 |
'type' => 'color',
|
2746 |
'type' => 'color',
|
2747 |
'key' => 'flyout_background_from'
|
2748 |
),
|
2749 |
+
array(
|
2750 |
+
'title' => __( "Copy", "megamenu" ),
|
2751 |
+
'type' => 'copy_color',
|
2752 |
+
'key' => 'copy_color'
|
2753 |
+
),
|
2754 |
array(
|
2755 |
'title' => __( "To", "megamenu" ),
|
2756 |
'type' => 'color',
|
2768 |
'type' => 'color',
|
2769 |
'key' => 'flyout_background_hover_from'
|
2770 |
),
|
2771 |
+
array(
|
2772 |
+
'title' => __( "Copy", "megamenu" ),
|
2773 |
+
'type' => 'copy_color',
|
2774 |
+
'key' => 'copy_color'
|
2775 |
+
),
|
2776 |
array(
|
2777 |
'title' => __( "To", "megamenu" ),
|
2778 |
'type' => 'color',
|
2938 |
'type' => 'color',
|
2939 |
'key' => 'toggle_background_from'
|
2940 |
),
|
2941 |
+
array(
|
2942 |
+
'title' => __( "Copy", "megamenu" ),
|
2943 |
+
'type' => 'copy_color',
|
2944 |
+
'key' => 'copy_color'
|
2945 |
+
),
|
2946 |
array(
|
2947 |
'title' => __( "To", "megamenu" ),
|
2948 |
'type' => 'color',
|
3009 |
'type' => 'color',
|
3010 |
'key' => 'mobile_background_from'
|
3011 |
),
|
3012 |
+
array(
|
3013 |
+
'title' => __( "Copy", "megamenu" ),
|
3014 |
+
'type' => 'copy_color',
|
3015 |
+
'key' => 'copy_color'
|
3016 |
+
),
|
3017 |
array(
|
3018 |
'title' => __( "To", "megamenu" ),
|
3019 |
'type' => 'color',
|
3119 |
case "mobile_columns":
|
3120 |
$this->print_theme_mobile_columns_option( $setting['key'] );
|
3121 |
break;
|
3122 |
+
case "copy_color":
|
3123 |
+
$this->print_theme_copy_color_option( $setting['key'] );
|
3124 |
+
break;
|
3125 |
default:
|
3126 |
do_action("megamenu_print_theme_option_{$setting['type']}", $setting['key'], $this->id );
|
3127 |
break;
|
3241 |
}
|
3242 |
|
3243 |
|
3244 |
+
/**
|
3245 |
+
* Print a copy icon
|
3246 |
+
*
|
3247 |
+
* @since 2.2.3
|
3248 |
+
* @param string $key
|
3249 |
+
* @param string $value
|
3250 |
+
*/
|
3251 |
+
public function print_theme_copy_color_option( $key ) {
|
3252 |
+
|
3253 |
+
?>
|
3254 |
+
|
3255 |
+
<span class='dashicons dashicons-arrow-right-alt'></span>
|
3256 |
+
|
3257 |
+
<?php
|
3258 |
+
}
|
3259 |
+
|
3260 |
+
|
3261 |
/**
|
3262 |
* Print a select dropdown with 1 and 2 options
|
3263 |
*
|
classes/style-manager.class.php
CHANGED
@@ -93,6 +93,7 @@ final class Mega_Menu_Style_Manager {
|
|
93 |
'menu_item_link_weight' => 'normal',
|
94 |
'menu_item_link_text_transform' => 'none',
|
95 |
'menu_item_link_text_decoration' => 'none',
|
|
|
96 |
'menu_item_link_color_hover' => '#ffffff',
|
97 |
'menu_item_link_weight_hover' => 'normal',
|
98 |
'menu_item_link_text_decoration_hover' => 'none',
|
@@ -436,27 +437,28 @@ final class Mega_Menu_Style_Manager {
|
|
436 |
$css = "";
|
437 |
|
438 |
foreach ( $this->settings as $location => $settings ) {
|
439 |
-
|
440 |
if ( isset( $settings['enabled'] ) && has_nav_menu( $location ) ) {
|
441 |
-
|
442 |
$theme = $this->get_theme_settings_for_location( $location );
|
443 |
$menu_id = $this->get_menu_id_for_location( $location );
|
444 |
-
|
445 |
$compiled_css = $this->generate_css_for_location( $location, $theme, $menu_id );
|
446 |
|
447 |
if ( ! is_wp_error( $compiled_css ) ) {
|
448 |
-
|
449 |
$css .= $compiled_css;
|
450 |
-
|
451 |
}
|
452 |
-
|
453 |
}
|
454 |
-
|
455 |
}
|
456 |
|
457 |
if ( strlen( $css ) ) {
|
458 |
|
459 |
-
$
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
460 |
|
461 |
$this->set_cached_css( $css );
|
462 |
|
@@ -504,6 +506,31 @@ final class Mega_Menu_Style_Manager {
|
|
504 |
}
|
505 |
|
506 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
507 |
/**
|
508 |
* Return the path to the megamenu.scss file, look for custom files before
|
509 |
* loading the core version.
|
@@ -529,11 +556,7 @@ final class Mega_Menu_Style_Manager {
|
|
529 |
$scss = file_get_contents( MEGAMENU_PATH . trailingslashit('css') . 'mixin.scss' );
|
530 |
$scss .= file_get_contents( MEGAMENU_PATH . trailingslashit('css') . 'reset.scss' );
|
531 |
|
532 |
-
$locations =
|
533 |
-
trailingslashit( get_stylesheet_directory() ) . trailingslashit("megamenu") . 'megamenu.scss', // child theme
|
534 |
-
trailingslashit( get_template_directory() ) . trailingslashit("megamenu") . 'megamenu.scss', // parent theme
|
535 |
-
MEGAMENU_PATH . trailingslashit('css') . 'megamenu.scss' // default
|
536 |
-
));
|
537 |
|
538 |
foreach ( $locations as $path ) {
|
539 |
|
@@ -553,6 +576,7 @@ final class Mega_Menu_Style_Manager {
|
|
553 |
|
554 |
}
|
555 |
|
|
|
556 |
/**
|
557 |
* Compiles raw SCSS into CSS for a particular menu location.
|
558 |
*
|
@@ -765,15 +789,6 @@ final class Mega_Menu_Style_Manager {
|
|
765 |
$params = apply_filters("megamenu_javascript_localisation",
|
766 |
array(
|
767 |
"effect" => array(
|
768 |
-
"fade" => array(
|
769 |
-
"in" => array(
|
770 |
-
"animate" => array("opacity" => "show"),
|
771 |
-
"css" => array("display" => "none")
|
772 |
-
),
|
773 |
-
"out" => array(
|
774 |
-
"animate" => array("opacity" => "hide")
|
775 |
-
)
|
776 |
-
),
|
777 |
"slide" => array(
|
778 |
"in" => array(
|
779 |
"animate" => array("height" => "show"),
|
93 |
'menu_item_link_weight' => 'normal',
|
94 |
'menu_item_link_text_transform' => 'none',
|
95 |
'menu_item_link_text_decoration' => 'none',
|
96 |
+
'menu_item_link_text_align' => 'left',
|
97 |
'menu_item_link_color_hover' => '#ffffff',
|
98 |
'menu_item_link_weight_hover' => 'normal',
|
99 |
'menu_item_link_text_decoration_hover' => 'none',
|
437 |
$css = "";
|
438 |
|
439 |
foreach ( $this->settings as $location => $settings ) {
|
|
|
440 |
if ( isset( $settings['enabled'] ) && has_nav_menu( $location ) ) {
|
|
|
441 |
$theme = $this->get_theme_settings_for_location( $location );
|
442 |
$menu_id = $this->get_menu_id_for_location( $location );
|
|
|
443 |
$compiled_css = $this->generate_css_for_location( $location, $theme, $menu_id );
|
444 |
|
445 |
if ( ! is_wp_error( $compiled_css ) ) {
|
|
|
446 |
$css .= $compiled_css;
|
|
|
447 |
}
|
|
|
448 |
}
|
|
|
449 |
}
|
450 |
|
451 |
if ( strlen( $css ) ) {
|
452 |
|
453 |
+
$scss_location = 'core';
|
454 |
+
|
455 |
+
foreach ( $this->get_possible_scss_file_locations() as $path ) {
|
456 |
+
if ( file_exists($path) && $path !== $this->get_default_scss_file_location() ) {
|
457 |
+
$scss_location = 'custom';
|
458 |
+
}
|
459 |
+
}
|
460 |
+
|
461 |
+
$css = "/** " . date('l jS \of F Y h:i:s A') . " ({$scss_location}) **/\n\n" . $css;
|
462 |
|
463 |
$this->set_cached_css( $css );
|
464 |
|
506 |
}
|
507 |
|
508 |
|
509 |
+
/**
|
510 |
+
* Return an array of all the possible file path locations for the SCSS file
|
511 |
+
* @since 2.2.3
|
512 |
+
* @return array
|
513 |
+
*/
|
514 |
+
private function get_possible_scss_file_locations() {
|
515 |
+
return apply_filters( "megamenu_scss_locations", array(
|
516 |
+
trailingslashit( get_stylesheet_directory() ) . trailingslashit("megamenu") . 'megamenu.scss', // child theme
|
517 |
+
trailingslashit( get_template_directory() ) . trailingslashit("megamenu") . 'megamenu.scss', // parent theme
|
518 |
+
$this->get_default_scss_file_location()
|
519 |
+
));
|
520 |
+
}
|
521 |
+
|
522 |
+
|
523 |
+
/**
|
524 |
+
* Return the default SCSS file path
|
525 |
+
*
|
526 |
+
* @since 2.2.3
|
527 |
+
* @return string
|
528 |
+
*/
|
529 |
+
private function get_default_scss_file_location() {
|
530 |
+
return MEGAMENU_PATH . trailingslashit('css') . 'megamenu.scss';
|
531 |
+
}
|
532 |
+
|
533 |
+
|
534 |
/**
|
535 |
* Return the path to the megamenu.scss file, look for custom files before
|
536 |
* loading the core version.
|
556 |
$scss = file_get_contents( MEGAMENU_PATH . trailingslashit('css') . 'mixin.scss' );
|
557 |
$scss .= file_get_contents( MEGAMENU_PATH . trailingslashit('css') . 'reset.scss' );
|
558 |
|
559 |
+
$locations = $this->get_possible_scss_file_locations();
|
|
|
|
|
|
|
|
|
560 |
|
561 |
foreach ( $locations as $path ) {
|
562 |
|
576 |
|
577 |
}
|
578 |
|
579 |
+
|
580 |
/**
|
581 |
* Compiles raw SCSS into CSS for a particular menu location.
|
582 |
*
|
789 |
$params = apply_filters("megamenu_javascript_localisation",
|
790 |
array(
|
791 |
"effect" => array(
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
792 |
"slide" => array(
|
793 |
"in" => array(
|
794 |
"animate" => array("height" => "show"),
|
css/admin/menus.css
CHANGED
@@ -728,6 +728,8 @@
|
|
728 |
-o-transition: all 0.3s ease;
|
729 |
-ms-transition: all 0.3s ease;
|
730 |
transition: all 0.3s ease;
|
|
|
|
|
731 |
}
|
732 |
|
733 |
.mm_launch:before {
|
@@ -816,6 +818,7 @@
|
|
816 |
font-size: 0.9em;
|
817 |
width: 100%;
|
818 |
margin-bottom: 5px;
|
|
|
819 |
}
|
820 |
|
821 |
.mega_menu_meta_box div table select {
|
@@ -833,10 +836,6 @@
|
|
833 |
font-size: 1.1em;
|
834 |
}
|
835 |
|
836 |
-
.mega_menu_meta_box div table td:nth-child(1) {
|
837 |
-
padding-left: 5px;
|
838 |
-
}
|
839 |
-
|
840 |
.mega_menu_meta_box div table td:nth-child(2) {
|
841 |
text-align: right;
|
842 |
min-width: 150px;
|
728 |
-o-transition: all 0.3s ease;
|
729 |
-ms-transition: all 0.3s ease;
|
730 |
transition: all 0.3s ease;
|
731 |
+
z-index: 1;
|
732 |
+
position: relative;
|
733 |
}
|
734 |
|
735 |
.mm_launch:before {
|
818 |
font-size: 0.9em;
|
819 |
width: 100%;
|
820 |
margin-bottom: 5px;
|
821 |
+
border-collapse: collapse;
|
822 |
}
|
823 |
|
824 |
.mega_menu_meta_box div table select {
|
836 |
font-size: 1.1em;
|
837 |
}
|
838 |
|
|
|
|
|
|
|
|
|
839 |
.mega_menu_meta_box div table td:nth-child(2) {
|
840 |
text-align: right;
|
841 |
min-width: 150px;
|
css/admin/settings.css
CHANGED
@@ -211,6 +211,8 @@ body[class*='mega-menu_page_maxmegamenu_'] .menu_settings h3 {
|
|
211 |
line-height: 20px;
|
212 |
width: 100%;
|
213 |
}
|
|
|
|
|
214 |
.megamenu_outer_wrap .megamenu_right .menu_settings td.mega-value .mega-info:before {
|
215 |
font: 400 20px/1 dashicons;
|
216 |
content: "\f348";
|
@@ -321,6 +323,25 @@ body[class*='mega-menu_page_maxmegamenu_'] .menu_settings h3 {
|
|
321 |
.mega-menu_page_maxmegamenu_theme_editor .select2-results li {
|
322 |
float: left;
|
323 |
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
324 |
.megamenu_outer_wrap .select2-container-sm .select2-choice {
|
325 |
padding: 0 5px 0 5px;
|
326 |
height: 28px;
|
@@ -450,6 +471,17 @@ body[class*='mega-menu_page_maxmegamenu_'] .menu_settings h3 {
|
|
450 |
display: block;
|
451 |
margin: 0 0 2px 1px;
|
452 |
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
453 |
.megamenu_outer_wrap .megamenu_right .menu_settings table .wide input[type=text] {
|
454 |
width: 300px;
|
455 |
}
|
@@ -545,6 +577,11 @@ body[class*='mega-menu_page_maxmegamenu_'] .menu_settings h3 {
|
|
545 |
float: left;
|
546 |
}
|
547 |
|
|
|
|
|
|
|
|
|
|
|
548 |
.megamenu_outer_wrap .mm-picker-container .sp-replacer .sp-preview {
|
549 |
border: 0;
|
550 |
height: 26px;
|
@@ -566,7 +603,6 @@ body[class*='mega-menu_page_maxmegamenu_'] .menu_settings h3 {
|
|
566 |
box-shadow: 0 1px 0 rgba(0,0,0,.08);
|
567 |
border: 1px solid #ccc;
|
568 |
font-size: 0.9em;
|
569 |
-
margin-right: 10px;
|
570 |
float: left;
|
571 |
}
|
572 |
|
211 |
line-height: 20px;
|
212 |
width: 100%;
|
213 |
}
|
214 |
+
|
215 |
+
|
216 |
.megamenu_outer_wrap .megamenu_right .menu_settings td.mega-value .mega-info:before {
|
217 |
font: 400 20px/1 dashicons;
|
218 |
content: "\f348";
|
323 |
.mega-menu_page_maxmegamenu_theme_editor .select2-results li {
|
324 |
float: left;
|
325 |
}
|
326 |
+
|
327 |
+
.megamenu_outer_wrap .select2-container-sm .select2-choice > .select2-chosen i,
|
328 |
+
.mega-menu_page_maxmegamenu_theme_editor .select2-result-label i {
|
329 |
+
display: inline-block;
|
330 |
+
width: 20px;
|
331 |
+
height: 20px;
|
332 |
+
font-size: 20px;
|
333 |
+
line-height: 1;
|
334 |
+
font-family: dashicons;
|
335 |
+
text-decoration: inherit;
|
336 |
+
font-weight: normal;
|
337 |
+
font-style: normal;
|
338 |
+
vertical-align: top;
|
339 |
+
text-align: center;
|
340 |
+
-webkit-transition: color .1s ease-in 0;
|
341 |
+
transition: color .1s ease-in 0;
|
342 |
+
-webkit-font-smoothing: antialiased;
|
343 |
+
-moz-osx-font-smoothing: grayscale;
|
344 |
+
}
|
345 |
.megamenu_outer_wrap .select2-container-sm .select2-choice {
|
346 |
padding: 0 5px 0 5px;
|
347 |
height: 28px;
|
471 |
display: block;
|
472 |
margin: 0 0 2px 1px;
|
473 |
}
|
474 |
+
.megamenu_outer_wrap .megamenu_right .menu_settings table label.mega-copy_color {
|
475 |
+
margin-right: 3px;
|
476 |
+
}
|
477 |
+
.megamenu_outer_wrap .megamenu_right .menu_settings table label.mega-copy_color span.mega-short-desc {
|
478 |
+
visibility: hidden;
|
479 |
+
}
|
480 |
+
.megamenu_outer_wrap .megamenu_right .menu_settings table label.mega-copy_color span.dashicons {
|
481 |
+
opacity: 0.5;
|
482 |
+
margin-top: 6px;
|
483 |
+
font-size: 16px;
|
484 |
+
}
|
485 |
.megamenu_outer_wrap .megamenu_right .menu_settings table .wide input[type=text] {
|
486 |
width: 300px;
|
487 |
}
|
577 |
float: left;
|
578 |
}
|
579 |
|
580 |
+
.mega-menu_page_maxmegamenu_theme_editor .sp-palette-container {
|
581 |
+
width: 40px;
|
582 |
+
}
|
583 |
+
|
584 |
+
|
585 |
.megamenu_outer_wrap .mm-picker-container .sp-replacer .sp-preview {
|
586 |
border: 0;
|
587 |
height: 26px;
|
603 |
box-shadow: 0 1px 0 rgba(0,0,0,.08);
|
604 |
border: 1px solid #ccc;
|
605 |
font-size: 0.9em;
|
|
|
606 |
float: left;
|
607 |
}
|
608 |
|
css/megamenu.scss
CHANGED
@@ -77,6 +77,7 @@
|
|
77 |
}
|
78 |
|
79 |
a.mega-menu-link {
|
|
|
80 |
display: inline;
|
81 |
|
82 |
@if $transitions == 'on' {
|
@@ -87,6 +88,10 @@
|
|
87 |
}
|
88 |
}
|
89 |
|
|
|
|
|
|
|
|
|
90 |
&.mega-keyboard-navigation + .mega-menu-toggle.mega-menu-open,
|
91 |
&.mega-keyboard-navigation a:focus,
|
92 |
&.mega-keyboard-navigation input:focus {
|
@@ -186,10 +191,6 @@
|
|
186 |
font-family: dashicons;
|
187 |
}
|
188 |
|
189 |
-
li.mega-disable-link > a.mega-menu-link {
|
190 |
-
cursor: default;
|
191 |
-
}
|
192 |
-
|
193 |
li.mega-menu-item a.mega-menu-link:before {
|
194 |
display: inline-block;
|
195 |
font: inherit;
|
@@ -296,7 +297,7 @@
|
|
296 |
font-weight: $menu_item_link_weight;
|
297 |
height: $menu_item_link_height;
|
298 |
vertical-align: baseline;
|
299 |
-
text-align:
|
300 |
width: auto;
|
301 |
display: block;
|
302 |
color: $menu_item_link_color;
|
@@ -306,7 +307,6 @@
|
|
306 |
@include border-radius($menu_item_link_border_radius_top_left, $menu_item_link_border_radius_top_right, $menu_item_link_border_radius_bottom_right, $menu_item_link_border_radius_bottom_left);
|
307 |
font-family: $menu_item_link_font;
|
308 |
font-size: $menu_item_link_font_size;
|
309 |
-
cursor: pointer;
|
310 |
}
|
311 |
|
312 |
@include mobile {
|
@@ -365,10 +365,12 @@
|
|
365 |
width: 100% !important;
|
366 |
}
|
367 |
|
368 |
-
@
|
369 |
-
@for $
|
370 |
-
|
371 |
-
|
|
|
|
|
372 |
}
|
373 |
}
|
374 |
}
|
@@ -711,7 +713,6 @@
|
|
711 |
|
712 |
}
|
713 |
|
714 |
-
// responsive toggle hamburger
|
715 |
.mega-menu-toggle {
|
716 |
display: none;
|
717 |
z-index: 1;
|
77 |
}
|
78 |
|
79 |
a.mega-menu-link {
|
80 |
+
cursor: pointer;
|
81 |
display: inline;
|
82 |
|
83 |
@if $transitions == 'on' {
|
88 |
}
|
89 |
}
|
90 |
|
91 |
+
li.mega-disable-link > a.mega-menu-link {
|
92 |
+
cursor: default;
|
93 |
+
}
|
94 |
+
|
95 |
&.mega-keyboard-navigation + .mega-menu-toggle.mega-menu-open,
|
96 |
&.mega-keyboard-navigation a:focus,
|
97 |
&.mega-keyboard-navigation input:focus {
|
191 |
font-family: dashicons;
|
192 |
}
|
193 |
|
|
|
|
|
|
|
|
|
194 |
li.mega-menu-item a.mega-menu-link:before {
|
195 |
display: inline-block;
|
196 |
font: inherit;
|
297 |
font-weight: $menu_item_link_weight;
|
298 |
height: $menu_item_link_height;
|
299 |
vertical-align: baseline;
|
300 |
+
text-align: $menu_item_link_text_align;
|
301 |
width: auto;
|
302 |
display: block;
|
303 |
color: $menu_item_link_color;
|
307 |
@include border-radius($menu_item_link_border_radius_top_left, $menu_item_link_border_radius_top_right, $menu_item_link_border_radius_bottom_right, $menu_item_link_border_radius_bottom_left);
|
308 |
font-family: $menu_item_link_font;
|
309 |
font-size: $menu_item_link_font_size;
|
|
|
310 |
}
|
311 |
|
312 |
@include mobile {
|
365 |
width: 100% !important;
|
366 |
}
|
367 |
|
368 |
+
@include desktop {
|
369 |
+
@for $of from 1 through 8 {
|
370 |
+
@for $cols from 1 through $of {
|
371 |
+
li.mega-menu-columns-#{$cols}-of-#{$of} {
|
372 |
+
width: (100% / $of) * $cols;
|
373 |
+
}
|
374 |
}
|
375 |
}
|
376 |
}
|
713 |
|
714 |
}
|
715 |
|
|
|
716 |
.mega-menu-toggle {
|
717 |
display: none;
|
718 |
z-index: 1;
|
css/toggle-blocks.scss
CHANGED
@@ -1,6 +1,5 @@
|
|
1 |
#{$wrap} .mega-menu-toggle {
|
2 |
|
3 |
-
/** Menu Toggle Blocks **/
|
4 |
@each $item in $menu_toggle_blocks {
|
5 |
$id: nth($item, 1);
|
6 |
$align: nth($item, 2);
|
@@ -43,7 +42,6 @@
|
|
43 |
|
44 |
}
|
45 |
|
46 |
-
/** Spacer Toggle Blocks **/
|
47 |
@each $item in $spacer_toggle_blocks {
|
48 |
|
49 |
$id: nth($item, 1);
|
1 |
#{$wrap} .mega-menu-toggle {
|
2 |
|
|
|
3 |
@each $item in $menu_toggle_blocks {
|
4 |
$id: nth($item, 1);
|
5 |
$align: nth($item, 2);
|
42 |
|
43 |
}
|
44 |
|
|
|
45 |
@each $item in $spacer_toggle_blocks {
|
46 |
|
47 |
$id: nth($item, 1);
|
js/maxmegamenu.js
CHANGED
@@ -83,14 +83,14 @@
|
|
83 |
|
84 |
plugin.hideAllPanels = function() {
|
85 |
$('.mega-toggle-on > a', $menu).each(function() {
|
86 |
-
plugin.hidePanel($(this),
|
87 |
});
|
88 |
};
|
89 |
|
90 |
|
91 |
plugin.hideSiblingPanels = function(anchor, immediate) {
|
92 |
// all open children of open siblings
|
93 |
-
anchor.parent().siblings().find('.mega-toggle-on').
|
94 |
plugin.hidePanel($(this), immediate);
|
95 |
});
|
96 |
}
|
@@ -177,7 +177,7 @@
|
|
177 |
|
178 |
if (effect.animate) {
|
179 |
anchor.siblings('.mega-sub-menu').animate(effect.animate, speed, 'swing', function() {
|
180 |
-
$(this).css('
|
181 |
});
|
182 |
}
|
183 |
}
|
@@ -283,9 +283,9 @@
|
|
283 |
if (keyCode == tab_key) {
|
284 |
$menu.addClass('mega-keyboard-navigation');
|
285 |
|
286 |
-
if ( active_link.parent().hasClass('mega-menu-item-has-children')
|
287 |
// menu item with sub menu
|
288 |
-
plugin.showPanel(
|
289 |
} else if ( active_link.parent().parent().hasClass('mega-menu') ) {
|
290 |
// top level item with no children
|
291 |
plugin.hideAllPanels();
|
83 |
|
84 |
plugin.hideAllPanels = function() {
|
85 |
$('.mega-toggle-on > a', $menu).each(function() {
|
86 |
+
plugin.hidePanel($(this), false);
|
87 |
});
|
88 |
};
|
89 |
|
90 |
|
91 |
plugin.hideSiblingPanels = function(anchor, immediate) {
|
92 |
// all open children of open siblings
|
93 |
+
anchor.parent().siblings().find('.mega-toggle-on').addBack().children('a').each(function() {
|
94 |
plugin.hidePanel($(this), immediate);
|
95 |
});
|
96 |
}
|
177 |
|
178 |
if (effect.animate) {
|
179 |
anchor.siblings('.mega-sub-menu').animate(effect.animate, speed, 'swing', function() {
|
180 |
+
$(this).css('display', '');
|
181 |
});
|
182 |
}
|
183 |
}
|
283 |
if (keyCode == tab_key) {
|
284 |
$menu.addClass('mega-keyboard-navigation');
|
285 |
|
286 |
+
if ( active_link.parent().hasClass('mega-menu-item-has-children') ) {
|
287 |
// menu item with sub menu
|
288 |
+
plugin.showPanel(active_link);
|
289 |
} else if ( active_link.parent().parent().hasClass('mega-menu') ) {
|
290 |
// top level item with no children
|
291 |
plugin.hideAllPanels();
|
js/settings.js
CHANGED
@@ -30,6 +30,10 @@ jQuery(function ($) {
|
|
30 |
showInput: true,
|
31 |
showAlpha: true,
|
32 |
clickoutFiresChange: true,
|
|
|
|
|
|
|
|
|
33 |
change: function(color) {
|
34 |
if (color.getAlpha() === 0) {
|
35 |
$(this).siblings('div.chosen-color').html('transparent');
|
@@ -39,6 +43,14 @@ jQuery(function ($) {
|
|
39 |
}
|
40 |
});
|
41 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
42 |
$(".confirm").on("click", function() {
|
43 |
return confirm(megamenu_settings.confirm);
|
44 |
});
|
@@ -63,10 +75,10 @@ jQuery(function ($) {
|
|
63 |
dropdownCssClass: 'tpx-select2-drop',
|
64 |
minimumResultsForSearch: -1,
|
65 |
formatResult: function(icon) {
|
66 |
-
return '<i class="
|
67 |
},
|
68 |
formatSelection: function (icon) {
|
69 |
-
return '<i class="
|
70 |
}
|
71 |
});
|
72 |
|
30 |
showInput: true,
|
31 |
showAlpha: true,
|
32 |
clickoutFiresChange: true,
|
33 |
+
showSelectionPalette: true,
|
34 |
+
showPalette: true,
|
35 |
+
palette: [ ],
|
36 |
+
localStorageKey: "maxmegamenu.themeeditor",
|
37 |
change: function(color) {
|
38 |
if (color.getAlpha() === 0) {
|
39 |
$(this).siblings('div.chosen-color').html('transparent');
|
43 |
}
|
44 |
});
|
45 |
|
46 |
+
$(".mega-copy_color span").live('click', function() {
|
47 |
+
var from = $(this).parent().parent().children(":first").find("input");
|
48 |
+
var to = $(this).parent().parent().children(":last").find("input");
|
49 |
+
|
50 |
+
$(to).spectrum("set", from.val());
|
51 |
+
to.siblings('div.chosen-color').html(from.siblings('div.chosen-color').html());
|
52 |
+
})
|
53 |
+
|
54 |
$(".confirm").on("click", function() {
|
55 |
return confirm(megamenu_settings.confirm);
|
56 |
});
|
75 |
dropdownCssClass: 'tpx-select2-drop',
|
76 |
minimumResultsForSearch: -1,
|
77 |
formatResult: function(icon) {
|
78 |
+
return '<i class="' + $(icon.element).attr('data-class') + '"></i>';
|
79 |
},
|
80 |
formatSelection: function (icon) {
|
81 |
+
return '<i class="' + $(icon.element).attr('data-class') + '"></i>';
|
82 |
}
|
83 |
});
|
84 |
|
megamenu.php
CHANGED
@@ -4,7 +4,7 @@
|
|
4 |
* Plugin Name: Max Mega Menu
|
5 |
* Plugin URI: https://www.maxmegamenu.com
|
6 |
* Description: Mega Menu for WordPress.
|
7 |
-
* Version: 2.2.
|
8 |
* Author: Tom Hemsley
|
9 |
* Author URI: https://www.maxmegamenu.com
|
10 |
* License: GPL-2.0+
|
@@ -26,7 +26,13 @@ final class Mega_Menu {
|
|
26 |
/**
|
27 |
* @var string
|
28 |
*/
|
29 |
-
public $version = '2.2.
|
|
|
|
|
|
|
|
|
|
|
|
|
30 |
|
31 |
|
32 |
/**
|
@@ -809,7 +815,7 @@ final class Mega_Menu {
|
|
809 |
$css_version = get_transient("megamenu_css_version");
|
810 |
$css = get_transient("megamenu_css");
|
811 |
|
812 |
-
if ( $css && version_compare( $this->
|
813 |
|
814 |
?>
|
815 |
<div class="updated">
|
4 |
* Plugin Name: Max Mega Menu
|
5 |
* Plugin URI: https://www.maxmegamenu.com
|
6 |
* Description: Mega Menu for WordPress.
|
7 |
+
* Version: 2.2.3
|
8 |
* Author: Tom Hemsley
|
9 |
* Author URI: https://www.maxmegamenu.com
|
10 |
* License: GPL-2.0+
|
26 |
/**
|
27 |
* @var string
|
28 |
*/
|
29 |
+
public $version = '2.2.3';
|
30 |
+
|
31 |
+
|
32 |
+
/**
|
33 |
+
* @var string
|
34 |
+
*/
|
35 |
+
public $scss_last_updated = '2.2.2';
|
36 |
|
37 |
|
38 |
/**
|
815 |
$css_version = get_transient("megamenu_css_version");
|
816 |
$css = get_transient("megamenu_css");
|
817 |
|
818 |
+
if ( $css && version_compare( $this->scss_last_updated, $css_version, '>' ) ) :
|
819 |
|
820 |
?>
|
821 |
<div class="updated">
|
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.5
|
6 |
-
Stable tag: 2.2.
|
7 |
License: GPLv2 or later
|
8 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
9 |
|
@@ -97,6 +97,17 @@ See https://www.maxmegamenu.com for more screenshots
|
|
97 |
|
98 |
== Changelog ==
|
99 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
100 |
= 2.2.2 [21/07/2016] =
|
101 |
|
102 |
* Fix: Save button missing from menu locations
|
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.5
|
6 |
+
Stable tag: 2.2.2
|
7 |
License: GPLv2 or later
|
8 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
9 |
|
97 |
|
98 |
== Changelog ==
|
99 |
|
100 |
+
= 2.2.3 [15/08/2016] =
|
101 |
+
|
102 |
+
* Fix: Mega sub menus not correctly closed on mobile when effect is set to Fade
|
103 |
+
* Fix: Cursor styling for disabled links
|
104 |
+
* Fix: Apply animation to closing sub menus
|
105 |
+
* Fix: Bring megamenu button forward on nav-menus page
|
106 |
+
* Fix: Replace deprecated jQuery 'addSelf' with 'andBack'
|
107 |
+
* Improvement: Theme Editor usability. Add color pallete to color picker. Add Copy Color option
|
108 |
+
* Improvement: Only prompt for SCSS compilation when current CSS is outdated
|
109 |
+
* Change: Indicate whether style.css file was generated from core or custom version of megamenu.scss
|
110 |
+
|
111 |
= 2.2.2 [21/07/2016] =
|
112 |
|
113 |
* Fix: Save button missing from menu locations
|