SAP / ui5-webcomponents

UI5 Web Components - the enterprise-flavored sugar on top of native APIs! Build SAP Fiori user interfaces with the technology of your choice.
https://sap.github.io/ui5-webcomponents/
Apache License 2.0
1.51k stars 263 forks source link

[Menu & MenuItem | 1.14.0]: The Dynamic Menu is not working on the second sub-level #7391

Closed rv97 closed 2 weeks ago

rv97 commented 1 year ago

Bug Description

When the main menu has two levels of sub-menu where the second level sub-menu should be rendered dynamically, then the loading indicator is stuck and does not render the content automatically. We need to go one level back and then open the sub-menu to show the rendered content. The same works in the case of the first-level sub-menu.

Affected Component

Menu, MenuItem

Expected Behaviour

How many ever sub-levels are there, the busy indicator should be gone automatically and render the content.

Isolated Example

https://codesandbox.io/s/prod-bird-mjtv35?file=/src/App.js

Steps to Reproduce

  1. Open the sandbox link shared.
  2. Click on "Show Menu"
  3. Open the "New File" sub-menu.
  4. Again open the "Open" sub-menu ...

You can observe that the sub-menu inside a sub-menu does not render the content automatically.

Log Output, Stack Trace or Screenshots

No response

Priority

High

UI5 Web Components Version

1.14.0

Browser

Chrome

Operating System

MacOS

Additional Context

No response

Organization

SAP Labs

Declaration

unazko commented 1 year ago

Hello @SAP/ui5-webcomponents-topic-b,

This issue is for us.

Best regards, Boyan

rv97 commented 10 months ago

Hi @unazko ,

Is there any update on this?

unazko commented 7 months ago

Hi @rv97,

Apologies for the late reply. We've got stuck with merging the previously related PR. Currently there is a new related PR, which will most probably fix this issue. We're currently testing if the issue will be resolved with the PR.

Best regards, Boyan

unazko commented 7 months ago

Hello @rv97,

I've managed to fully test the provided sample and unfortunately the previously linked PR's aren't going to fix this issue: I suspect you're already using the following workaround: https://codesandbox.io/p/sandbox/boring-solomon-92qknd?file=%2Fsrc%2FApp.js

There is a workaround at least. We're going to continue debugging this behavior.

Best regards, Boyan

shubhamnazare commented 5 months ago

Hi @unazko,

I'm from @rv97' team working on this issue. The workaround you proposed is not working in our case. We have a complex reusable component which is used to render all the menus across the entire application. Introducing the workaround in our application brings in a lot of code refactoring and unnecessary errors. Hence, we request the UI5 Web Components Team to check if it is possible to fix this issue in the Menu component itself.

Thanks & Regards, Shubham.

DMihaylova commented 4 months ago

Hi @rv97 & @shubhamnazare,

We're actively addressing your concern and will update you shortly. Thank you for your patience!

Regards, Diana

rv97 commented 4 months ago

Hi @DMihaylova ,

Thanks for the update.

Regards, Vignesh R

unazko commented 4 months ago

Hello @rv97,

The issue is fixed with the following PR (https://github.com/SAP/ui5-webcomponents/pull/8722) for the latest ui5-webcomponents release.

We'll have to develop separate fix for 1.24 release though as the upper change is a major refactoring of the ui5-menu.

Best regards, Boyan

rv97 commented 4 months ago

Thanks @unazko. Please let us know once you have finalized the version this fix would be available from.

Thanks, Vignesh R

unazko commented 4 months ago

Hi Vignesh R,

This behavior will be fixed with webc v2 currently. We'll be working on a transport as a separate fix for 1.24.x releases. From the following URL you could see the release candidate for v2 marked with the @next tag: https://www.npmjs.com/package/@ui5/webcomponents?activeTab=versions

You could perform internal testing with the release candidate (2.0.0-rc.4).

There is also information about the incoming releases down on the following page: https://github.com/SAP/ui5-webcomponents/projects?type=classic

We expect to have an official release containing the working behavior at the end of June. That will be webc v2.

Best regards, Boyan

Abanindra commented 3 months ago

Hi @unazko,

Since we are yet to move to v2, we are expecting the fix in one of the V 1.x. Appreciate if you can let us know by when we can expect the fix.

reagrds Aban

Abanindra commented 3 months ago

Hi @unazko Can you please comment on this as we need an urgent fix for this issue?

unazko commented 2 months ago

Hi @Abanindra,

I've referenced a PR, which will fix this issue for 1.24 release once merged. Currently the PR is in the review phase.

Best regards, Boyan

unazko commented 2 months ago

Hi @Abanindra,

The fix is done and it is transported into 1.24 release. The solution could be consumed with 1.24.8 patch, which is expected to be released in the beginning of August.

Best regards, Boyan

Abanindra commented 2 months ago

Thank you @unazko for the update.

rv97 commented 2 months ago

Thanks @unazko !

shubhamnazare commented 1 month ago

Hi @unazko

I was validating the fix with the above codesandbox example and unfortunately the issue is still reproducible. The versions I used were - ui5/webcomponents: 1.24.8 and ui5/webcomponents-react: 1.29.6.

Could you please validate from your side and confirm the same if possible.

Thanks a lot!

shubhamnazare commented 3 weeks ago

Hi @unazko

I was validating the fix with the above codesandbox example and unfortunately the issue is still reproducible. The versions I used were - ui5/webcomponents: 1.24.8 and ui5/webcomponents-react: 1.29.6.

Could you please validate from your side and confirm the same if possible.

Thanks a lot!

Hi @unazko

As I mentioned this issue is still reproducible in 'ui5/webcomponents: 1.24.8' and 'ui5/webcomponents-react: 1.29.6'. Could you please validate and let me know what are the next steps?

unazko commented 2 weeks ago

Hi @shubhamnazare,

The previous sample from the codesandbox doesn't load for me. I've made similar sample into a different platform: https://stackblitz.com/edit/vitejs-vite-pekkod?file=package.json Just wait for the dependencies to get installed. I couldn't reproduce the issue at my side with 1.24.8 patch.

The "New file" menu item has sub-menu and afterwards we have second level of nested sub-menus. I've tested on Firefox, Chrome and Edge browser and also on macos and windows. Everything works at my side.

Could you please test at your side and edit the sample if necessary so the issue is reproducible?

rv97 commented 2 weeks ago

Hi @unazko ,

I opened the sandbox link which you had mentioned. I am still able to reproduce the issue. Here is the video of me doing the same: https://sap-my.sharepoint.com/:v:/p/vignesh_r02/EahKUzIpMblNsW5dGYVsaggByZ9iCPOjl1KdAwurmy2Elg?nav=eyJyZWZlcnJhbEluZm8iOnsicmVmZXJyYWxBcHAiOiJPbmVEcml2ZUZvckJ1c2luZXNzIiwicmVmZXJyYWxBcHBQbGF0Zm9ybSI6IldlYiIsInJlZmVycmFsTW9kZSI6InZpZXciLCJyZWZlcnJhbFZpZXciOiJNeUZpbGVzTGlua0NvcHkifX0&e=DoriS7

Steps: Show Menu -> New File -> Open

You can see it is stuck at the loading indicator forever until i go back one level and open it again.

CC @shubhamnazare @Abanindra

unazko commented 2 weeks ago

Hi @rv97,

Thanks for the reproduction steps. I've managed to reproduce the issue again. It seems as an additional scenario to the same issue. Hopefully I'll manage to fix it faster. We'll be aiming for a next release next week or the week after.

unazko commented 2 weeks ago

Hi @rv97, @shubhamnazare, @Abanindra,

The issue is now fixed via the related change in 1.24.10 patch, which was just released. I've switched to 1.24.10 patch in the sample application and the issue isn't reproducible any longer. Please do perform a re-test at your side: https://stackblitz.com/edit/vitejs-vite-pekkod?file=package.json