From a6d7ab0fd1b4f568e62cc85f2abc40dba3ecdf60 Mon Sep 17 00:00:00 2001 From: Christina Toegl <toegl@tugraz.at> Date: Mon, 3 Jan 2022 14:18:31 +0100 Subject: [PATCH] Fix breadcrumb menu width condition --- packages/file-handling/src/nextcloud-file-picker.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/packages/file-handling/src/nextcloud-file-picker.js b/packages/file-handling/src/nextcloud-file-picker.js index 0ee5cb90..1550311c 100644 --- a/packages/file-handling/src/nextcloud-file-picker.js +++ b/packages/file-handling/src/nextcloud-file-picker.js @@ -1974,7 +1974,9 @@ export class NextcloudFilePicker extends ScopedElementsMixin(DBPLitElement) { // computations for overflow - end if (!menu.classList.contains('hidden')) { // add event listener for clicking outside of menu - menu.setAttribute('style', 'max-width: ' + maxWidth + 'px;'); //TODO verify if this is enough + if (!isMenuOverflow) { + menu.setAttribute('style', 'max-width: ' + maxWidth + 'px;'); + } document.addEventListener('click', this.boundCloseBreadcrumbMenuHandler); this.initateOpenBreadcrumbMenu = true; } -- GitLab