Fix closing items sidebar on opened modals [SCI-9541] (#6455)

This commit is contained in:
ajugo 2023-10-16 15:59:32 +02:00 committed by GitHub
parent 550aa9df48
commit cede97d7d9
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -298,8 +298,10 @@ export default {
if (!this.isShowing) return
const sidebar = this.$refs.wrapper;
// Check if the clicked element is not within the sidebar and it's not another item link
if (!sidebar.contains(event.target) && !event.target.closest('a')) {
// Check if the clicked element is not within the sidebar and it's not another item link or belogs to modal
if (!sidebar.contains(event.target) &&
!event.target.closest('a') &&
!event.target.closest('.modal')) {
this.toggleShowHideSidebar(null)
}
},