Initial commit

This commit is contained in:
xiahe93 2025-02-24 13:24:03 +08:00
commit 655b95962f
128 changed files with 17331 additions and 0 deletions

10
.!15522!.DS_Store Normal file
View File

@ -0,0 +1,10 @@
{
"domainStrategy": "IPOnDemand",
"rules": [
{
"type": "field",
"inboundTag": ["Shadowsocks_0.0.0.0_30000"],
"outboundTag": "tw02"
}
]
}

439
airport/index.html Normal file

File diff suppressed because one or more lines are too long

530
android-tutorial/index.html Normal file

File diff suppressed because one or more lines are too long

590
client-tutorial/index.html Normal file

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

406
en/index.html Normal file

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

339
en/qa-en/index.html Normal file

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

357
en/tutorial-en/index.html Normal file

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

565
index.html Normal file

File diff suppressed because one or more lines are too long

565
ios-tutorial/index.html Normal file

File diff suppressed because one or more lines are too long

576
other_tools/index.html Normal file

File diff suppressed because one or more lines are too long

476
qa/index.html Normal file

File diff suppressed because one or more lines are too long

516
server-tutorial/index.html Normal file

File diff suppressed because one or more lines are too long

515
tutorial/index.html Normal file

File diff suppressed because one or more lines are too long

597
version-1-10-1/index.html Normal file

File diff suppressed because one or more lines are too long

595
version-1-10-2/index.html Normal file

File diff suppressed because one or more lines are too long

595
version-1-10-3/index.html Normal file

File diff suppressed because one or more lines are too long

595
version-1-10-4/index.html Normal file

File diff suppressed because one or more lines are too long

595
version-1-10-5/index.html Normal file

File diff suppressed because one or more lines are too long

595
version-1-10-6/index.html Normal file

File diff suppressed because one or more lines are too long

503
version-1-8-12/index.html Normal file

File diff suppressed because one or more lines are too long

562
version-1-9-3/index.html Normal file

File diff suppressed because one or more lines are too long

542
version-updates/index.html Normal file

File diff suppressed because one or more lines are too long

87
widget/topMenus.html Normal file
View File

@ -0,0 +1,87 @@
<div class="mega-menu-toggle">
<div class="mega-toggle-blocks-left"></div>
<div class="mega-toggle-blocks-center">
<div class="mega-toggle-block mega-menu-toggle-animated-block mega-toggle-block-1" id="mega-toggle-block-1">
<button aria-label="Toggle Menu" class="mega-toggle-animated mega-toggle-animated-slider" type="button" aria-expanded="false">
<span class="mega-toggle-animated-box">
<span class="mega-toggle-animated-inner"></span>
</span>
</button>
</div>
</div>
<div class="mega-toggle-blocks-right"></div>
</div>
<ul
id="mega-menu-max_mega_menu_1"
class="mega-menu max-mega-menu mega-menu-horizontal mega-no-js"
data-event="hover_intent"
data-effect="fade_up"
data-effect-speed="200"
data-effect-mobile="slide"
data-effect-speed-mobile="200"
data-mobile-force-width="false"
data-second-click="go"
data-document-click="collapse"
data-vertical-behaviour="standard"
data-breakpoint="400"
data-unbind="true"
data-mobile-state="collapse_all"
data-hover-intent-timeout="300"
data-hover-intent-interval="100"
>
<li
class="mega-menu-item mega-menu-item-type-post_type mega-menu-item-object-page mega-menu-item-home mega-current-menu-item mega-page_item mega-page-item-13 mega-current_page_item mega-align-bottom-left mega-menu-flyout mega-menu-item-200"
id="mega-menu-item-200"
>
<a class="mega-menu-link" href="index.html" aria-current="page" tabindex="0">官网下载</a>
</li>
<!--
<li class="mega-menu-item mega-menu-item-type-custom mega-menu-item-object-custom mega-align-bottom-left mega-menu-flyout mega-menu-item-449" id="mega-menu-item-449">
<a target="_blank" class="mega-menu-link" href="https://jichangx.com/" tabindex="0">机场推荐</a>
</li>
-->
<li class="mega-menu-item mega-menu-item-type-post_type mega-menu-item-object-page mega-menu-item-has-children mega-align-bottom-left mega-menu-flyout mega-menu-item-194" id="mega-menu-item-194">
<a class="mega-menu-link" href="tutorial/index.html" aria-haspopup="true" aria-expanded="false" tabindex="0">使用教程<span class="mega-indicator"></span></a>
<ul class="mega-sub-menu">
<li class="mega-menu-item mega-menu-item-type-post_type mega-menu-item-object-post mega-menu-item-195" id="mega-menu-item-195">
<a class="mega-menu-link" href="android-tutorial/index.html">Android 使用教程</a>
</li>
<li class="mega-menu-item mega-menu-item-type-post_type mega-menu-item-object-post mega-menu-item-196" id="mega-menu-item-196">
<a class="mega-menu-link" href="ios-tutorial/index.html">iOS 使用教程</a>
</li>
<li class="mega-menu-item mega-menu-item-type-post_type mega-menu-item-object-post mega-menu-item-609" id="mega-menu-item-609">
<a class="mega-menu-link" href="gui-for-singbox-tutorial/index.html">Windows/Linux使用教程</a>
</li>
<li class="mega-menu-item mega-menu-item-type-post_type mega-menu-item-object-post mega-menu-item-197" id="mega-menu-item-197">
<a class="mega-menu-link" href="client-tutorial/index.html">macOS使用教程</a>
</li>
<li class="mega-menu-item mega-menu-item-type-post_type mega-menu-item-object-post mega-menu-item-198" id="mega-menu-item-198">
<a class="mega-menu-link" href="server-tutorial/index.html">服务端安装教程</a>
</li>
</ul>
</li>
<li class="mega-menu-item mega-menu-item-type-post_type mega-menu-item-object-page mega-align-bottom-left mega-menu-flyout mega-menu-item-193" id="mega-menu-item-193">
<a class="mega-menu-link" href="qa/index.html" tabindex="0">常见问题</a>
</li>
<li class="mega-menu-item mega-menu-item-type-post_type mega-menu-item-object-page mega-align-bottom-left mega-menu-flyout mega-menu-item-192" id="mega-menu-item-192">
<a class="mega-menu-link" href="other_tools/index.html" tabindex="0">更多客户端</a>
</li>
<li class="mega-menu-item mega-menu-item-type-post_type mega-menu-item-object-page mega-align-bottom-left mega-menu-flyout mega-menu-item-193" id="mega-menu-item-193">
<a class="mega-menu-link" href="../airport/index.html" tabindex="0">机场推荐</a>
</li>
<li
class="mega-pll-parent-menu-item mega-menu-item mega-menu-item-type-custom mega-menu-item-object-custom mega-menu-item-has-children mega-align-bottom-left mega-menu-flyout mega-has-icon mega-icon-left mega-menu-item-190 pll-parent-menu-item"
id="mega-menu-item-190"
>
<a class="dashicons-translation mega-menu-link" href="index.html#pll_switcher" aria-haspopup="true" aria-expanded="false" tabindex="0">中文<span class="mega-indicator"></span></a>
<ul class="mega-sub-menu">
<li
class="mega-lang-item mega-lang-item-19 mega-lang-item-en mega-lang-item-first mega-menu-item mega-menu-item-type-custom mega-menu-item-object-custom mega-menu-item-190-en lang-item lang-item-19 lang-item-en lang-item-first"
id="mega-menu-item-190-en"
>
<a class="mega-menu-link" href="en/index.html">English</a>
</li>
</ul>
</li>
</ul>

View File

@ -0,0 +1,761 @@
/*jslint browser: true, white: true, this: true, long: true */
/*global console,jQuery,megamenu,window,navigator*/
/*! Max Mega Menu jQuery Plugin */
(function ( $ ) {
"use strict";
$.maxmegamenu = function(menu, options) {
var plugin = this;
var $menu = $(menu);
var $toggle_bar = $menu.siblings(".mega-menu-toggle");
var html_body_class_timeout;
var defaults = {
event: $menu.attr("data-event"),
effect: $menu.attr("data-effect"),
effect_speed: parseInt($menu.attr("data-effect-speed")),
effect_mobile: $menu.attr("data-effect-mobile"),
effect_speed_mobile: parseInt($menu.attr("data-effect-speed-mobile")),
panel_width: $menu.attr("data-panel-width"),
panel_inner_width: $menu.attr("data-panel-inner-width"),
mobile_force_width: $menu.attr("data-mobile-force-width"),
mobile_overlay: $menu.attr("data-mobile-overlay"),
mobile_state: $menu.attr("data-mobile-state"),
second_click: $menu.attr("data-second-click"),
vertical_behaviour: $menu.attr("data-vertical-behaviour"),
document_click: $menu.attr("data-document-click"),
breakpoint: $menu.attr("data-breakpoint"),
unbind_events: $menu.attr("data-unbind"),
hover_intent_timeout: $menu.attr("data-hover-intent-timeout"),
hover_intent_interval: $menu.attr("data-hover-intent-interval")
};
plugin.settings = {};
var items_with_submenus = $("li.mega-menu-megamenu.mega-menu-item-has-children," +
"li.mega-menu-flyout.mega-menu-item-has-children," +
"li.mega-menu-tabbed > ul.mega-sub-menu > li.mega-menu-item-has-children," +
"li.mega-menu-flyout li.mega-menu-item-has-children", menu);
var collapse_children_parents = $("li.mega-menu-megamenu li.mega-menu-item-has-children.mega-collapse-children > a.mega-menu-link", menu);
plugin.addAnimatingClass = function(element) {
if (plugin.settings.effect === "disabled") {
return;
}
$(".mega-animating").removeClass("mega-animating");
var timeout = plugin.settings.effect_speed + parseInt(megamenu.timeout, 10);
element.addClass("mega-animating");
setTimeout(function() {
element.removeClass("mega-animating");
}, timeout );
};
plugin.hideAllPanels = function() {
$(".mega-toggle-on > a.mega-menu-link", $menu).each(function() {
plugin.hidePanel($(this), false);
});
};
plugin.expandMobileSubMenus = function() {
$(".mega-menu-item-has-children.mega-expand-on-mobile > a.mega-menu-link", $menu).each(function() {
plugin.showPanel($(this));
});
if ( plugin.settings.mobile_state == 'expand_all' ) {
$(".mega-menu-item-has-children > a.mega-menu-link", $menu).each(function() {
plugin.showPanel($(this));
});
}
if ( plugin.settings.mobile_state == 'expand_active' ) {
$("li.mega-current-menu-ancestor.mega-menu-item-has-children > a.mega-menu-link," +
"li.mega-current-menu-item.mega-menu-item-has-children > a.mega-menu-link" +
"li.mega-current-menu-parent.mega-menu-item-has-children > a.mega-menu-link" +
"li.mega-current_page_ancestor.mega-menu-item-has-children > a.mega-menu-link" +
"li.mega-current_page_item.mega-menu-item-has-children > a.mega-menu-link", $menu).each(function() {
plugin.showPanel($(this));
});
}
}
plugin.hideSiblingPanels = function(anchor, immediate) {
anchor.parent().parent().find(".mega-toggle-on").children("a.mega-menu-link").each(function() { // all open children of open siblings
plugin.hidePanel($(this), immediate);
});
};
plugin.isDesktopView = function() {
var width = Math.max(document.documentElement.clientWidth || 0, window.innerWidth || 0);
return width > plugin.settings.breakpoint;
};
plugin.isMobileView = function() {
return !plugin.isDesktopView();
};
plugin.showPanel = function(anchor) {
if ( anchor.is("li.mega-menu-item") ) {
anchor = anchor.find("a.mega-menu-link").first();
}
anchor.parent().triggerHandler("before_open_panel");
anchor.parent().find("[aria-expanded]").first().attr("aria-expanded", "true");
$(".mega-animating").removeClass("mega-animating");
if (plugin.isMobileView() && anchor.parent().hasClass("mega-hide-sub-menu-on-mobile")) {
return;
}
if (plugin.isDesktopView() && ( $menu.hasClass("mega-menu-horizontal") || $menu.hasClass("mega-menu-vertical") ) && !anchor.parent().hasClass("mega-collapse-children")) {
plugin.hideSiblingPanels(anchor, true);
}
if ((plugin.isMobileView() && $menu.hasClass("mega-keyboard-navigation")) || plugin.settings.vertical_behaviour === "accordion") {
plugin.hideSiblingPanels(anchor, false);
}
plugin.calculateDynamicSubmenuWidths(anchor);
// apply jQuery transition (only if the effect is set to "slide", other transitions are CSS based)
if ( anchor.parent().hasClass("mega-collapse-children") || plugin.settings.effect === "slide" ||
( plugin.isMobileView() && ( plugin.settings.effect_mobile === "slide" || plugin.settings.effect_mobile === "slide_left" || plugin.settings.effect_mobile === "slide_right" ) )
) {
var speed = plugin.isMobileView() ? plugin.settings.effect_speed_mobile : plugin.settings.effect_speed;
anchor.siblings(".mega-sub-menu").css("display", "none").animate({"height":"show", "paddingTop":"show", "paddingBottom":"show", "minHeight":"show"}, speed, function() {
$(this).css("display", "");
});
}
anchor.parent().addClass("mega-toggle-on").triggerHandler("open_panel");
};
plugin.hidePanel = function(anchor, immediate) {
if ( anchor.is("li.mega-menu-item") ) {
anchor = anchor.find("a.mega-menu-link").first();
}
anchor.parent().triggerHandler("before_close_panel");
anchor.parent().find("[aria-expanded]").first().attr("aria-expanded", "false");
if ( anchor.parent().hasClass("mega-collapse-children") || ( ! immediate && plugin.settings.effect === "slide" ) ||
( plugin.isMobileView() && ( plugin.settings.effect_mobile === "slide" || plugin.settings.effect_mobile === "slide_left" || plugin.settings.effect_mobile === "slide_right" ) )
) {
var speed = plugin.isMobileView() ? plugin.settings.effect_speed_mobile : plugin.settings.effect_speed;
anchor.siblings(".mega-sub-menu").animate({"height":"hide", "paddingTop":"hide", "paddingBottom":"hide", "minHeight":"hide"}, speed, function() {
anchor.siblings(".mega-sub-menu").css("display", "");
anchor.parent().removeClass("mega-toggle-on").triggerHandler("close_panel");
});
return;
}
if (immediate) {
anchor.siblings(".mega-sub-menu").css("display", "none").delay(plugin.settings.effect_speed).queue(function(){
$(this).css("display", "").dequeue();
});
}
// pause video widget videos
anchor.siblings(".mega-sub-menu").find(".widget_media_video video").each(function() {
this.player.pause();
});
anchor.parent().removeClass("mega-toggle-on").triggerHandler("close_panel");
plugin.addAnimatingClass(anchor.parent());
};
plugin.calculateDynamicSubmenuWidths = function(anchor) {
// apply dynamic width and sub menu position (only to top level mega menus)
if (anchor.parent().hasClass("mega-menu-megamenu") && anchor.parent().parent().hasClass("max-mega-menu") && plugin.settings.panel_width && $(plugin.settings.panel_width).length > 0) {
if (plugin.isDesktopView()) {
var submenu_offset = $menu.offset();
var target_offset = $(plugin.settings.panel_width).offset();
anchor.siblings(".mega-sub-menu").css({
width: $(plugin.settings.panel_width).outerWidth(),
left: (target_offset.left - submenu_offset.left) + "px"
});
} else {
anchor.siblings(".mega-sub-menu").css({
width: "",
left: ""
});
}
}
// apply inner width to sub menu by adding padding to the left and right of the mega menu
if (anchor.parent().hasClass("mega-menu-megamenu") && anchor.parent().parent().hasClass("max-mega-menu") && plugin.settings.panel_inner_width && $(plugin.settings.panel_inner_width).length > 0) {
var target_width = 0;
if ($(plugin.settings.panel_inner_width).length) {
// jQuery selector
target_width = parseInt($(plugin.settings.panel_inner_width).width(), 10);
} else {
// we"re using a pixel width
target_width = parseInt(plugin.settings.panel_inner_width, 10);
}
var submenu_width = parseInt(anchor.siblings(".mega-sub-menu").innerWidth(), 10);
if (plugin.isDesktopView() && target_width > 0 && target_width < submenu_width) {
anchor.siblings(".mega-sub-menu").css({
"paddingLeft": (submenu_width - target_width) / 2 + "px",
"paddingRight": (submenu_width - target_width) / 2 + "px"
});
} else {
anchor.siblings(".mega-sub-menu").css({
"paddingLeft": "",
"paddingRight": ""
});
}
}
};
plugin.bindClickEvents = function() {
var dragging = false;
$(document).on({
"touchmove": function(e) { dragging = true; },
"touchstart": function(e) { dragging = false; }
});
$(document).on("click touchend", function(e) { // hide menu when clicked away from
if (!dragging && plugin.settings.document_click === "collapse" && ! $(e.target).closest(".max-mega-menu li").length && ! $(e.target).closest(".mega-menu-toggle").length ) {
plugin.hideAllPanels();
plugin.hideMobileMenu();
}
dragging = false;
});
var clickable_parents = $("> a.mega-menu-link", items_with_submenus).add(collapse_children_parents);
clickable_parents.on("touchend.megamenu", function(e) {
if (plugin.settings.event === "hover_intent") {
plugin.unbindHoverIntentEvents();
}
if (plugin.settings.event === "hover") {
plugin.unbindHoverEvents();
}
});
clickable_parents.not("[data-has-click-event]").on("click.megamenu", function(e) {
if (plugin.isDesktopView() && $(this).parent().hasClass("mega-toggle-on") && $(this).closest("ul.mega-sub-menu").parent().hasClass("mega-menu-tabbed") ) {
if (plugin.settings.second_click === "go") {
return;
} else {
e.preventDefault();
return;
}
}
if (dragging) {
return;
}
if (plugin.isMobileView() && $(this).parent().hasClass("mega-hide-sub-menu-on-mobile")) {
return; // allow all clicks on parent items when sub menu is hidden on mobile
}
if ((plugin.settings.second_click === "go" || $(this).parent().hasClass("mega-click-click-go")) && $(this).attr("href") !== undefined) { // check for second click
if (!$(this).parent().hasClass("mega-toggle-on")) {
e.preventDefault();
plugin.showPanel($(this));
}
} else {
e.preventDefault();
if ($(this).parent().hasClass("mega-toggle-on")) {
plugin.hidePanel($(this), false);
} else {
plugin.showPanel($(this));
}
}
});
collapse_children_parents.each(function() {
$(this).attr("data-has-click-event", "true");
});
if ( plugin.settings.second_click === "disabled" ) {
clickable_parents.off("click.megamenu");
}
$(".mega-close-after-click:not(.mega-menu-item-has-children) > a.mega-menu-link", menu).on("click", function() {
plugin.hideAllPanels();
plugin.hideMobileMenu();
});
};
plugin.bindHoverEvents = function() {
items_with_submenus.on({
"mouseenter.megamenu" : function() {
plugin.unbindClickEvents();
if (! $(this).hasClass("mega-toggle-on")) {
plugin.showPanel($(this).children("a.mega-menu-link"));
}
},
"mouseleave.megamenu" : function() {
if ($(this).hasClass("mega-toggle-on") && ! $(this).hasClass("mega-disable-collapse") && ! $(this).parent().parent().hasClass("mega-menu-tabbed")) {
plugin.hidePanel($(this).children("a.mega-menu-link"), false);
}
}
});
};
plugin.bindHoverIntentEvents = function() {
items_with_submenus.hoverIntent({
over: function () {
plugin.unbindClickEvents();
if (! $(this).hasClass("mega-toggle-on")) {
plugin.showPanel($(this).children("a.mega-menu-link"));
}
},
out: function () {
if ($(this).hasClass("mega-toggle-on") && ! $(this).hasClass("mega-disable-collapse") && ! $(this).parent().parent().hasClass("mega-menu-tabbed")) {
plugin.hidePanel($(this).children("a.mega-menu-link"), false);
}
},
timeout: plugin.settings.hover_intent_timeout,
interval: plugin.settings.hover_intent_interval
});
};
plugin.bindKeyboardEvents = function() {
var tab_key = 9;
var escape_key = 27;
var enter_key = 13;
var left_arrow_key = 37;
var up_arrow_key = 38;
var right_arrow_key = 39;
var down_arrow_key = 40;
var space_key = 32;
$menu.parent().on("keyup.megamenu", ".max-mega-menu, .mega-menu-toggle", function(e) {
var keyCode = e.keyCode || e.which;
var active_link = $(e.target);
if (keyCode === tab_key) {
$menu.parent().addClass("mega-keyboard-navigation");
}
});
$menu.parent().on("keydown.megamenu", "a.mega-menu-link, .mega-indicator, .mega-menu-toggle-block, .mega-menu-toggle-animated-block button", function(e) {
if ( ! $menu.parent().hasClass("mega-keyboard-navigation") ) {
return;
}
var keyCode = e.keyCode || e.which;
var active_link = $(e.target);
if ( keyCode === space_key && active_link.is(".mega-menu-link") ) {
e.preventDefault();
// pressing space on a parent item will always toggle the sub menu
if ( active_link.parent().is(items_with_submenus) ) {
if ( active_link.parent().hasClass("mega-toggle-on") && ! active_link.closest("ul.mega-sub-menu").parent().hasClass("mega-menu-tabbed") ) {
plugin.hidePanel(active_link);
} else {
plugin.showPanel(active_link);
}
}
}
if ( keyCode === space_key && active_link.is("mega-indicator") ) {
e.preventDefault();
if ( active_link.parent().parent().hasClass("mega-toggle-on") && ! active_link.closest("ul.mega-sub-menu").parent().hasClass("mega-menu-tabbed") ) {
plugin.hidePanel(active_link.parent());
} else {
plugin.showPanel(active_link.parent());
}
}
if ( keyCode === escape_key ) {
var submenu_open = $("> .mega-toggle-on", $menu).length !== 0;
$("> .mega-toggle-on", $menu).find("[tabindex]:visible").first().focus();
plugin.hideAllPanels();
if ( plugin.isMobileView() && ! submenu_open ) {
plugin.hideMobileMenu();
$(".mega-menu-toggle-block, button.mega-toggle-animated", $toggle_bar).first().focus();
}
}
if ( keyCode === space_key ) {
e.preventDefault();
if ( active_link.is(".mega-menu-toggle-block, .mega-menu-toggle-animated-block button") ) {
if ( $toggle_bar.hasClass("mega-menu-open") ) {
plugin.hideMobileMenu();
} else {
plugin.showMobileMenu();
}
}
}
if ( keyCode === enter_key ) {
if ( active_link.is(".mega-menu-toggle-block") ) {
if ( $toggle_bar.hasClass("mega-menu-open") ) {
plugin.hideMobileMenu();
} else {
plugin.showMobileMenu();
}
}
// pressing enter on an arrow will toggle the sub menu
if ( active_link.is(".mega-indicator") ) {
if ( active_link.closest("li.mega-menu-item").hasClass("mega-toggle-on") && ! active_link.closest("ul.mega-sub-menu").parent().hasClass("mega-menu-tabbed") ) {
plugin.hidePanel(active_link.parent());
} else {
plugin.showPanel(active_link.parent());
}
return;
}
// pressing enter on a parent link
if ( active_link.parent().is(items_with_submenus) ) {
// when the arrow has been moved (i.e. it is clickable and visible, don't show the sub menu - just follow the link)
if ( active_link.is("[href]") && active_link.siblings(".mega-indicator[tabindex]:visible").length !== 0 ) {
return;
}
// pressing enter on a parent item without a link will toggle the sub menu
if ( active_link.is("[href]") === false ) {
if ( active_link.parent().hasClass("mega-toggle-on") && ! active_link.closest("ul.mega-sub-menu").parent().hasClass("mega-menu-tabbed") ) {
plugin.hidePanel(active_link);
} else {
plugin.showPanel(active_link);
}
return;
}
// pressing enter on a parent item will first open the sub menu, then follow the link
if ( active_link.parent().hasClass("mega-toggle-on") && ! active_link.closest("ul.mega-sub-menu").parent().hasClass("mega-menu-tabbed") ) {
return;
} else {
e.preventDefault();
plugin.showPanel(active_link);
}
}
}
if ( ( ( keyCode === right_arrow_key && plugin.isDesktopView() ) || ( keyCode === down_arrow_key && plugin.isMobileView() ) ) && $menu.hasClass("mega-menu-horizontal") ) {
e.preventDefault();
var next_top_level_item = $("> .mega-toggle-on", $menu).nextAll("li.mega-menu-item:visible").find("> a.mega-menu-link, .mega-search span[role=button]").first();
if (next_top_level_item.length === 0) {
next_top_level_item = $(":focus", $menu).parent().nextAll("li.mega-menu-item:visible").find("> a.mega-menu-link, .mega-search span[role=button]").first();
}
if (next_top_level_item.length === 0) {
next_top_level_item = $(":focus", $menu).parent().parent().parent().nextAll("li.mega-menu-item:visible").find("> a.mega-menu-link, .mega-search span[role=button]").first();
}
plugin.hideAllPanels();
next_top_level_item.focus();
}
if ( ( ( keyCode === left_arrow_key && plugin.isDesktopView() ) || ( keyCode === up_arrow_key && plugin.isMobileView() ) ) && $menu.hasClass("mega-menu-horizontal") ) {
e.preventDefault();
var prev_top_level_item = $("> .mega-toggle-on", $menu).prevAll("li.mega-menu-item:visible").find("> a.mega-menu-link, .mega-search span[role=button]").last();
if (prev_top_level_item.length === 0) {
prev_top_level_item = $(":focus", $menu).parent().prevAll("li.mega-menu-item:visible").find("> a.mega-menu-link, .mega-search span[role=button]").last();
}
if (prev_top_level_item.length === 0) {
prev_top_level_item = $(":focus", $menu).parent().parent().parent().prevAll("li.mega-menu-item:visible").find("> a.mega-menu-link, .mega-search span[role=button]").last();
}
plugin.hideAllPanels();
prev_top_level_item.focus();
}
});
$menu.parent().on("focusout.megamenu", function(e) {
if ( $menu.parent().hasClass("mega-keyboard-navigation") ) {
setTimeout(function() {
var menu_has_focus = $menu.parent().find(":focus").length > 0;
if (! menu_has_focus) {
$menu.parent().removeClass("mega-keyboard-navigation");
plugin.hideAllPanels();
plugin.hideMobileMenu();
}
}, 10);
}
});
};
plugin.unbindAllEvents = function() {
$("ul.mega-sub-menu, li.mega-menu-item, li.mega-menu-row, li.mega-menu-column, a.mega-menu-link, .mega-indicator", menu).off();
};
plugin.unbindClickEvents = function() {
// collapsable parents always have a click event
$("> a.mega-menu-link", items_with_submenus).not(collapse_children_parents).off("click.megamenu touchend.megamenu");
};
plugin.unbindHoverEvents = function() {
items_with_submenus.unbind("mouseenter.megamenu mouseleave.megamenu");
};
plugin.unbindHoverIntentEvents = function() {
items_with_submenus.unbind("mouseenter mouseleave").removeProp("hoverIntent_t").removeProp("hoverIntent_s"); // hoverintent does not allow namespaced events
};
plugin.unbindKeyboardEvents = function() {
$menu.parent().off("keyup.megamenu keydown.megamenu focusout.megamenu");
};
plugin.unbindMegaMenuEvents = function() {
if (plugin.settings.event === "hover_intent") {
plugin.unbindHoverIntentEvents();
}
if (plugin.settings.event === "hover") {
plugin.unbindHoverEvents();
}
plugin.unbindClickEvents();
plugin.unbindKeyboardEvents();
};
plugin.bindMegaMenuEvents = function() {
plugin.unbindMegaMenuEvents();
if (plugin.isDesktopView() && plugin.settings.event === "hover_intent") {
plugin.bindHoverIntentEvents();
}
if (plugin.isDesktopView() && plugin.settings.event === "hover") {
plugin.bindHoverEvents();
}
plugin.bindClickEvents(); // always bind click events for touch screen devices
plugin.bindKeyboardEvents();
};
plugin.checkWidth = function() {
if ( plugin.isMobileView() && $menu.data("view") === "desktop" ) {
plugin.switchToMobile();
}
if ( plugin.isDesktopView() && $menu.data("view") === "mobile" ) {
plugin.switchToDesktop();
}
plugin.calculateDynamicSubmenuWidths($("> li.mega-menu-megamenu > a.mega-menu-link", $menu));
};
plugin.reverseRightAlignedItems = function() {
if ( ! $("body").hasClass("rtl") && $menu.hasClass("mega-menu-horizontal") ) {
$menu.append($menu.children("li.mega-item-align-right").get().reverse());
}
};
plugin.addClearClassesToMobileItems = function() {
$(".mega-menu-row", $menu).each(function() {
$("> .mega-sub-menu > .mega-menu-column:not(.mega-hide-on-mobile)", $(this)).filter(":even").addClass("mega-menu-clear"); // :even is 0 based
});
};
plugin.initDesktop = function() {
$menu.data("view", "desktop");
plugin.bindMegaMenuEvents();
plugin.initIndicators();
};
plugin.switchToDesktop = function() {
$menu.data("view", "desktop");
plugin.bindMegaMenuEvents();
plugin.reverseRightAlignedItems();
plugin.hideAllPanels();
plugin.hideMobileMenu(true);
};
plugin.initMobile = function() {
plugin.switchToMobile();
};
plugin.switchToMobile = function() {
$menu.data("view", "mobile");
plugin.bindMegaMenuEvents();
plugin.initIndicators();
plugin.reverseRightAlignedItems();
plugin.addClearClassesToMobileItems();
plugin.hideAllPanels();
plugin.expandMobileSubMenus();
};
plugin.initToggleBar = function() {
$toggle_bar.on("click", function(e) {
if ( $(e.target).is(".mega-menu-toggle, .mega-menu-toggle-custom-block *, .mega-menu-toggle-block, .mega-menu-toggle-animated-block, .mega-menu-toggle-animated-block *, .mega-toggle-blocks-left, .mega-toggle-blocks-center, .mega-toggle-blocks-right, .mega-toggle-label, .mega-toggle-label span") ) {
e.preventDefault();
if ($(this).hasClass("mega-menu-open")) {
plugin.hideMobileMenu();
} else {
plugin.showMobileMenu();
}
}
});
};
plugin.initIndicators = function() {
$(".mega-indicator", $menu).not("[data-has-click-event]").on("click.megamenu", function(e) {
e.preventDefault();
e.stopPropagation();
if ( $(this).closest(".mega-menu-item").hasClass("mega-toggle-on") ) {
if ( ! $(this).closest("ul.mega-sub-menu").parent().hasClass("mega-menu-tabbed") || plugin.isMobileView() ) {
plugin.hidePanel($(this).parent(), false);
}
} else {
plugin.showPanel($(this).parent(), false);
}
});
$(".mega-indicator", $menu).each(function() {
$(this).attr('data-has-click-event', 'true');
});
}
plugin.hideMobileMenu = function(force) {
force = force || false;
if ( ! $toggle_bar.is(":visible") && ! force ) {
return;
}
html_body_class_timeout = setTimeout(function() {
$("body").removeClass($menu.attr("id") + "-mobile-open");
$("html").removeClass($menu.attr("id") + "-off-canvas-open");
}, plugin.settings.effect_speed_mobile);
$(".mega-toggle-label, .mega-toggle-animated", $toggle_bar).attr("aria-expanded", "false");
if (plugin.settings.effect_mobile === "slide" && ! force ) {
$menu.animate({"height":"hide"}, plugin.settings.effect_speed_mobile, function() {
$menu.css({
width: "",
left: "",
display: ""
});
$toggle_bar.removeClass("mega-menu-open");
});
} else {
$menu.css({
width: "",
left: "",
display: ""
});
$toggle_bar.removeClass("mega-menu-open");
}
$menu.triggerHandler("mmm:hideMobileMenu");
};
plugin.showMobileMenu = function() {
if ( ! $toggle_bar.is(":visible")) {
return;
}
clearTimeout(html_body_class_timeout);
$("body").addClass($menu.attr("id") + "-mobile-open");
plugin.expandMobileSubMenus();
if ( plugin.settings.effect_mobile === "slide_left" || plugin.settings.effect_mobile === "slide_right" ) {
$("html").addClass($menu.attr("id") + "-off-canvas-open");
}
$(".mega-toggle-label, .mega-toggle-animated", $toggle_bar).attr("aria-expanded", "true");
if (plugin.settings.effect_mobile === "slide") {
$menu.animate({"height":"show"}, plugin.settings.effect_speed_mobile, function() {
$(this).css("display", "");
});
}
$toggle_bar.addClass("mega-menu-open");
plugin.toggleBarForceWidth();
$menu.triggerHandler("mmm:showMobileMenu");
};
plugin.toggleBarForceWidth = function() {
if ($(plugin.settings.mobile_force_width).length && ( plugin.settings.effect_mobile === "slide" || plugin.settings.effect_mobile === "disabled" ) ) {
var submenu_offset = $toggle_bar.offset();
var target_offset = $(plugin.settings.mobile_force_width).offset();
$menu.css({
width: $(plugin.settings.mobile_force_width).outerWidth(),
left: (target_offset.left - submenu_offset.left) + "px"
});
}
};
plugin.init = function() {
$menu.triggerHandler("before_mega_menu_init");
plugin.settings = $.extend({}, defaults, options);
$menu.removeClass("mega-no-js");
plugin.initToggleBar();
if (plugin.settings.unbind_events === "true") {
plugin.unbindAllEvents();
}
$(window).on("load", function() {
plugin.calculateDynamicSubmenuWidths($("> li.mega-menu-megamenu > a.mega-menu-link", $menu));
});
if ( plugin.isDesktopView() ) {
plugin.initDesktop();
} else {
plugin.initMobile();
}
$(window).on("resize", function() {
plugin.checkWidth();
});
$menu.triggerHandler("after_mega_menu_init");
};
plugin.init();
};
$.fn.maxmegamenu = function(options) {
return this.each(function() {
if (undefined === $(this).data("maxmegamenu")) {
var plugin = new $.maxmegamenu(this, options);
$(this).data("maxmegamenu", plugin);
}
});
};
$(function() {
$(".max-mega-menu").maxmegamenu();
});
}( jQuery ));

View File

@ -0,0 +1,37 @@
/* Off canvas close button fix */
.wp-block-navigation__responsive-container.is-menu-open {
padding:20px !important;
}
/* Patterns fix */
.blog-two-columns .wp-block-post-featured-image {
min-width:40% !important;
}
@media only screen and (max-width: 750px) {
.blog-two-columns .wp-block-post-featured-image {
min-width:100% !important;
}
.blog-two-columns .has-post-thumbnail .wp-block-group{
-ms-flex-wrap:wrap !important;
flex-wrap:wrap !important;
}
}
@media only screen and (min-width: 600px) {
.author-introduction-pattern .wp-block-media-text .wp-block-media-text__content {
padding:0 4%;
}
}
@media only screen and (max-width: 600px) {
.author-introduction-pattern .wp-block-media-text {
text-align:center;
}
.author-introduction-pattern .wp-block-media-text__media{
text-align:center;
}
.author-introduction-pattern .wp-block-media-text__media img{
max-width: 100px;
}
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 16 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 30 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 36 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 48 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 70 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 26 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 47 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 55 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 72 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 101 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 43 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 28 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 49 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 56 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 9.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 36 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 71 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 47 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 8.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 31 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 57 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 60 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 11 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 41 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 80 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 67 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 12 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 47 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 117 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 22 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 29 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 11 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 40 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 20 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 22 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 38 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 52 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 9.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 64 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 97 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 22 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 13 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 9.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 9.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 11 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 12 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 18 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 18 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 24 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 23 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 20 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 20 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 26 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 26 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 8.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 31 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 8.3 KiB

Some files were not shown because too many files have changed in this diff Show More