Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ui5-menu: runtime error #8764

Closed
1 task done
vladitasev opened this issue Apr 16, 2024 · 3 comments · Fixed by #8778
Closed
1 task done

ui5-menu: runtime error #8764

vladitasev opened this issue Apr 16, 2024 · 3 comments · Fixed by #8778
Assignees
Labels
bug This issue is a bug in the code High Prio TOPIC B

Comments

@vladitasev
Copy link
Contributor

Bug Description

1.Run the project locally

  1. Click "Open Menu" -> Open -> Open Locally -> Open from C

  2. There is a runtime error

image

Affected Component

No response

Expected Behaviour

No response

Isolated Example

No response

Steps to Reproduce

...

Log Output, Stack Trace or Screenshots

No response

Priority

High

UI5 Web Components Version

2.0

Browser

Chrome

Operating System

No response

Additional Context

No response

Organization

No response

Declaration

  • I’m not disclosing any internal or sensitive information.
@vladitasev vladitasev added bug This issue is a bug in the code TOPIC B labels Apr 16, 2024
@vladitasev
Copy link
Contributor Author

vladitasev commented Apr 16, 2024

@unazko @tsanislavgatev Please have a look

I debugged a bit. When the error occurs:
image

I manually followed the DOM and found out that:
image

Basically, when I find the "Open from local" item in the DOM and click it ($0) I can confirm that this is not the same DOM element as the one in the expression, therefore the code breaks.

@petyabegovska petyabegovska added this to New Issues in Maintenance - Topic B via automation Apr 16, 2024
@unazko unazko self-assigned this Apr 16, 2024
@unazko unazko moved this from New Issues to In Progress in Maintenance - Topic B Apr 16, 2024
@unazko
Copy link
Contributor

unazko commented Apr 16, 2024

Hello @vladitasev,

This issue only happens as the busy state of the ui5-menu-item is broken after changing the names of the busy and busyDelay properties to loading and loadingDelay in the ui5-list. I suspect that we open the sub-menu from the current item. Later the same item gets re-rendered after two additional items are being added so it's a different item than the one from which we've opened the menu.

The same issue isn't reproducible via the following PR: #8722
I'll take only the needed part from the PR as it is a more major refactoring.

Best regards,
Boyan

@vladitasev
Copy link
Contributor Author

Thanks for the quick fix! I've approved the PR.

When the colleagues merged the change to ui5-list (renaming of these properties) all menu tests were still passing, meaning there's no test covering the usage of this property. This is something to be improved in the future.

Maintenance - Topic B automation moved this from In Progress to Completed Apr 22, 2024
unazko added a commit that referenced this issue Apr 22, 2024
Renames the busy and busyDelay properties of the ui5-menu and ui5-menu-item to loading and loadingDelay.

BREAKING CHANGE: The busy and busyDelay and properties of the ui5-menu and ui5-menu-item are renamed.
If you have previously used the busy, busyDelay properties:

<ui5-menu header-text="My ui5-menu" busy busy-delay="100"><ui5-menu>
<ui5-menu-item text="Open" icon="open-folder" busy busy-delay="100"><ui5-menu-item>
now you should use loading and loadingDelay properties:

<ui5-menu header-text="My ui5-menu" loading loading-delay="100"><ui5-menu>
<ui5-menu-item text="Open" icon="open-folder" loading loading-delay="100"><ui5-menu-item>

Fixes: #8764
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug This issue is a bug in the code High Prio TOPIC B
Projects
Development

Successfully merging a pull request may close this issue.

3 participants