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

UiFramework.openCursorMenu requires deprecated properties #1235

Open
ChrisBAtBentley opened this issue Feb 25, 2025 · 0 comments
Open

UiFramework.openCursorMenu requires deprecated properties #1235

ChrisBAtBentley opened this issue Feb 25, 2025 · 0 comments
Assignees
Labels
bug Something isn't working

Comments

@ChrisBAtBentley
Copy link

Describe the bug

Our product is creating multiple CursorMenuItemProps that are being sent to UiFramework.openCursorMenu. We are in the process of upgrading deprecated properties, one of which is adjusting icons that utilize IconSpec. Upon changing the objects to use iconNode instead (which is the recommended action), the cursor menu that is generated no longer shows any icons. It seems that the logic that is kicked off by openCursorMenu (which appears to be createMenuItemNode in MenuItem.tsx) ignores the new iconNode property.

To Reproduce

  1. Create CursorMenuItemProps and assign the icon object to the "icon" property. On opening the cursor menu, the icons should appear.
  2. Change the "icon" property of those CursorMenuItemProps to "iconNode". On opening the cursor menu, the icons are missing.

Expected Behavior

Making objects with iconNode should cause the icons to appear in the cursor menu.

Screenshots

No response

Desktop (please complete the applicable information)

AppUI 5.0.5
Win11, Edge 132.0.2957.140

Additional context

While the main issue is with UiFramework.openCursorMenu, this issue may apply to other methods as well; I believe that some action item helpers were still returning properties of type IconSpec as well.

@ChrisBAtBentley ChrisBAtBentley added the bug Something isn't working label Feb 25, 2025
@GerardasB GerardasB self-assigned this Feb 25, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants