Skip to content

Fix muse-manager loading states after React Query v5 - #1

Open
glin7976 wants to merge 43 commits into
mainfrom
fix/muse-manager-react-query-isPending
Open

glin7976 wants to merge 43 commits into
mainfrom
fix/muse-manager-react-query-isPending

Conversation

@glin7976

Copy link
Copy Markdown
Owner

Summary

  • React Query v5 renamed isLoading to isPending; muse-manager was still reading isLoading, so Modal OK loading and list skeletons stayed off after onOk/queries started.
  • Rename those destructures across muse-manager to isPending.
  • Bump @ebay/muse-manager to 2.0.11.

Test plan

  • Open a muse-manager modal (create app, deploy plugin, edit variables) and confirm the OK button/request status shows loading while the mutation runs.
  • Confirm plugin list and app page skeleton loading still appear while data is fetching.
  • Confirm MSP select and plugin release select still show their loading/disabled state.

supnate and others added 30 commits March 19, 2026 13:49
MUSE-1194 fix vite dev mode issue
MUSE-1223 add integration guides for Muse ui plugins
MUSE-1252 added MSP mgmt APIs
MUSE-1251 added sync latest API
MUSE-1252 add msp registry schema
MUSE-1244 upgrade tool in muse-dev-utils
MUSE-1280 update to latest antd, react
MUSE-1269 - Remove approval for prod env message
MUSE-1312 ensure lib plugin load sequence
MUSE-1310 add msp meta to plugin release.
MUSE-1309 validate msp when deployment
MUSE-1331 show MSP mismatch error when deploy validation
MUSE-1308 fix vanilla vite plugin
MUSE-1308 allow config msp for app and env
MUSE-1336 fix lib plugin build performance issue in watch mode
MUSE-1359, MUSE-1359, MUSE-1360, MUSE-1361, MUSE-1362 upgrade examples plugin to msp2606
MUSE-1391 antd v5 -> v6 migration
## Summary

Fixes the following React warning produced when rendering menus with `activeMatch`:

```text
Warning: React does not recognize the `activeMatch` prop on a DOM element.
If you accidentally passed it from a parent component, remove it from the DOM element.
```

## Root cause

`MetaMenu` uses the Muse-specific `activeMatch` property to calculate the active menu keys. After evaluating it, the original menu-item objects are passed to Ant Design unchanged.

Ant Design/rc-menu does not recognize `activeMatch` as a menu property and forwards it to the underlying `<li>`, which triggers the React warning.

## Fix

Before passing items to Ant Design, `MetaMenu` now recursively clones the menu tree and removes `activeMatch`.

The original internal items are retained for route matching, so existing active-menu behavior is unchanged. Recursive sanitization covers both top-level submenu items and nested children.

## Testing

- Added regression coverage for parent and nested menu items containing `activeMatch`.
- Verified that unsanitized items produce the React warning while sanitized items do not.
- Confirmed the `muse-lib-antd` production build succeeds.
Add environment variable security warning and pre-check before saving
Update version to 2.0.10 and revise security alert messages for publi…
glin7976 and others added 13 commits August 25, 2026 15:14
MUSE-1428 Add environment variable security warning and pre-check before saving
Prevent activeMatch from being forwarded to menu DOM elements
Render untrusted boot errors as text, validate plugin name/type/version, and only apply forcePlugins in local/dev or Muse e2e.

Co-authored-by: Cursor <cursoragent@cursor.com>
Prevent DOM XSS in muse-boot-default error UI and restrict forcePlugins.
JSON.stringify does not neutralize </script>, so plugin metadata could break out of the inline configuration script. Encode "<" as \u003c at the HTML rendering boundary and cover export plus middleware.

Co-authored-by: Cursor <cursoragent@cursor.com>
…-script

Encode MUSE_GLOBAL JSON when embedding it in HTML script tags.
v5 renamed mutation/query isLoading to isPending, so Modal OK loading and list skeletons never turned on.

Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants