Fix flickering of dropdown menu on thumbnail file preview [SCI-10329]

This commit is contained in:
Andrej 2024-03-04 09:24:04 +01:00
parent 74e1478c07
commit 2be9dd3d74
2 changed files with 9 additions and 6 deletions

View file

@ -279,12 +279,10 @@ export default {
await this.fetchLocalAppInfo(); await this.fetchLocalAppInfo();
this.showOptions = true; this.showOptions = true;
}, },
handleMenuVisibilityChange({ isMenuOpen, showOptions }) { handleMenuVisibilityChange(isMenuOpen) {
if (isMenuOpen !== null) { this.isMenuOpen = isMenuOpen;
this.isMenuOpen = isMenuOpen; if (isMenuOpen) {
} this.showOptions = true;
if (showOptions !== null) {
this.showOptions = showOptions;
} }
}, },
handleClickOutsideThumbnail(event) { handleClickOutsideThumbnail(event) {

View file

@ -87,6 +87,11 @@ export default {
'click-outside': vOnClickOutside 'click-outside': vOnClickOutside
}, },
mixins: [FixedFlyoutMixin], mixins: [FixedFlyoutMixin],
watch: {
isOpen(newValue) {
this.$emit('menu-visibility-changed', newValue);
}
},
methods: { methods: {
closeMenu() { closeMenu() {
this.isOpen = false; this.isOpen = false;