From e39b0ea24960b53924b5b40c1fa431786c865ef0 Mon Sep 17 00:00:00 2001 From: Wuyuan Huang <451613245@qq.com> Date: Thu, 20 Dec 2018 10:33:09 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E5=AF=BC=E8=88=AA=E6=A0=8Fbu?= =?UTF-8?q?g?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 嗯 --- cn/index.html | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) diff --git a/cn/index.html b/cn/index.html index 2b0b58c20..0ff7b1c27 100644 --- a/cn/index.html +++ b/cn/index.html @@ -4051,6 +4051,31 @@

$(document).ready(function() { + $(document).on('click', '.has-sub', function(){ + var _this = $(this) + if(!$(this).hasClass('expanded')) { + setTimeout(function(){ + _this.find('ul').attr("style","") + }, 300); + + } else { + $('.has-sub ul').each(function(id,ele){ + var _that = $(this) + if(_this.find('ul')[0] != ele) { + setTimeout(function(){ + _that.attr("style","") + }, 300); + } + }) + } + }) + $('.user-info-menu .hidden-sm').click(function(){ + if($('.sidebar-menu').hasClass('collapsed')) { + $('.has-sub.expanded > ul').attr("style","") + } else { + $('.has-sub.expanded > ul').show() + } + }) $("#main-menu li ul li").click(function() { $(this).siblings('li').removeClass('active'); // 删除其他兄弟元素的样式 $(this).addClass('active'); // 添加当前元素的样式