[ResponsivePopover] Popover close event is called when menu inside the popover is closed
Bug Description
When you have a ResponsivePopover and a Menu component inside it, and you close the menu component, the "close" event of the ResponsivePopover is triggered.
Sandbox -
Affected Component
ResponsivePopover
Expected Behaviour
The close event should not be triggered
Isolated Example
No response
Steps to Reproduce
- Open the responsive popover
- Open the menu inside it
- Close the menu by either clicking a menu item or clicking outside the menu ...
Log Output, Stack Trace or Screenshots
No response
Priority
High
UI5 Web Components Version
2.3.0
Browser
Chrome
Operating System
No response
Additional Context
No response
Organization
No response
Declaration
- [X] I’m not disclosing any internal or sensitive information.
Hi @Vir-Mittal ,
thank you for sharing your finding, and for the example that you have prepared.
It seems that the problem is this code
respPopover.addEventListener("close", () => { respPopover.open = false; });
Do you need to add it in this case?
Thank you!
Best regards,
Petya Markova.
(UI5 Web Components Dispatcher)
Hi @PetyaMarkovaBogdanova @ilhan007 yes for our use case, we need to have that part of the code. But, the issue is that any code inside that callback will be executed even though that event should not have been emitted in the first place right? Only when the responsive popover is actually closed, should that callback be called. But in the sandbox case, it is being called even when a separate component (the menu) is closed
Hi @PetyaMarkovaBogdanova @ilhan007 is there any update on this issue about when it is expected to be fixed? It is blocking us from upgrading to wc 2.0 and we will have to rollback to an old version if the fix will take time
Will be soon resolved with this change https://github.com/SAP/ui5-webcomponents/pull/10133
and will be released with 2.5.0-rc.0 on Thursday
:tada: This issue has been resolved in version v2.4.1-rc.0 :tada:
The release is available on v2.4.1-rc.0
Your semantic-release bot :package::rocket: