From e257bffd0d6702796fb4569f54bf0d6806b289e8 Mon Sep 17 00:00:00 2001 From: REJack Date: Mon, 21 Sep 2020 09:12:41 +0200 Subject: [PATCH 1/4] add posibile fix to use multiple sidebar treeviews --- build/js/Treeview.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/build/js/Treeview.js b/build/js/Treeview.js index decf2452b..928792abf 100644 --- a/build/js/Treeview.js +++ b/build/js/Treeview.js @@ -118,7 +118,8 @@ class Treeview { // Private _setupListeners() { - $(document).on('click', this._config.trigger, event => { + const elementId = this._element.attr('id') !== undefined ? `#${this._element.attr('id')}` : '' + $(document).on('click', `${elementId}${this._config.trigger}`, event => { this.toggle(event) }) } From 209075b5047dcdf663db51ba99250344dd21b462 Mon Sep 17 00:00:00 2001 From: REJack Date: Mon, 21 Sep 2020 09:28:14 +0200 Subject: [PATCH 2/4] fix mulitple level dropdown-menu overlapping --- build/js/Dropdown.js | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/build/js/Dropdown.js b/build/js/Dropdown.js index 0bf29f2a0..072163b9d 100644 --- a/build/js/Dropdown.js +++ b/build/js/Dropdown.js @@ -22,6 +22,7 @@ const SELECTOR_DROPDOWN_MENU_ACTIVE = '.dropdown-menu.show' const SELECTOR_DROPDOWN_TOGGLE = '[data-toggle="dropdown"]' const CLASS_NAME_DROPDOWN_RIGHT = 'dropdown-menu-right' +const CLASS_NAME_DROPDOWN_SUBMENU = 'dropdown-submenu' // TODO: this is unused; should be removed along with the extend? const Default = { @@ -122,6 +123,10 @@ $(`${SELECTOR_DROPDOWN_MENU} ${SELECTOR_DROPDOWN_TOGGLE}`).on('click', function $(`${SELECTOR_NAVBAR} ${SELECTOR_DROPDOWN_TOGGLE}`).on('click', event => { event.preventDefault() + if ($(event.target).parent().hasClass(CLASS_NAME_DROPDOWN_SUBMENU)) { + return + } + setTimeout(function () { Dropdown._jQueryInterface.call($(this), 'fixPosition') }, 1) From ee590b06452fb29e962c98fbd95d0babf0c97297 Mon Sep 17 00:00:00 2001 From: REJack Date: Mon, 21 Sep 2020 09:32:01 +0200 Subject: [PATCH 3/4] update control-sidebar methods in docs --- docs/javascript/control-sidebar.md | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/docs/javascript/control-sidebar.md b/docs/javascript/control-sidebar.md index 718c66a7c..9ec14c656 100644 --- a/docs/javascript/control-sidebar.md +++ b/docs/javascript/control-sidebar.md @@ -61,3 +61,17 @@ $("#my-toggle-button").ControlSidebar('toggle'); {: .table .table-bordered .bg-light} Example: `$('#toggle-button').on('expanded.lte.controlsidebar', handleExpandedEvent)` + + +##### Methods +{: .mt-4} + +|--- +| Method | Description +|-|- +|collapse | Collapses the control-sidebar +|show | Show's the control-sidebar +|toggle | Toggles the state of the control-sidebar expanded and collapsed +{: .table .table-bordered .bg-light} + +Example: `$('#toggle-button').ControlSidebar('toggle')` From 06b7deef80e0f05c3fe196cb67c5ce3b215d14b9 Mon Sep 17 00:00:00 2001 From: REJack Date: Mon, 21 Sep 2020 10:20:07 +0200 Subject: [PATCH 4/4] fix tooltip in maximized card --- build/scss/_cards.scss | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build/scss/_cards.scss b/build/scss/_cards.scss index 3f609662e..dee3d6de7 100644 --- a/build/scss/_cards.scss +++ b/build/scss/_cards.scss @@ -34,7 +34,7 @@ position: fixed; top: 0; width: 100% !important; - z-index: 9999; + z-index: $zindex-modal-backdrop; &.was-collapsed .card-body { display: block !important;