* [task#121408] add hiddenTree function of thinkstepmenu.

This commit is contained in:
Zhangyu
2024-07-01 08:45:25 +08:00
committed by 刘刚
parent 4fe2a17384
commit 4fdc80bfe5
2 changed files with 15 additions and 1 deletions
+14
View File
@@ -166,3 +166,17 @@ window.toggleQuestionShow = function()
$(node).find('.tree-toggle').trigger('click');
});
}
/**
* 点击左侧树结构下方按钮隐藏左侧树。
* Click the button below the left tree structure to hide the left tree.
*
* @access public
* @return void
*/
var hiddenSidbar = localStorage.getItem('hiddenSidbar');
window.hiddenTree = function()
{
localStorage.setItem('hiddenSidbar', true);
$('.think-node-menu').closest(".sidebar").sidebar("toggle");
}
+1 -1
View File
@@ -256,7 +256,7 @@ class thinkStepMenu extends wg
set::size('sm'),
set::icon('menu-arrow-left text-gray'),
set::hint($this->lang->collapse),
on::click()->do('$this.closest(".sidebar").sidebar("toggle");')
on::click('hiddenTree')
)
),
h::js("$('#mainContainer').addClass('has-sidebar');$('#mainContainer .sidebar').addClass('relative');")