Repository navigation
Migrate Stackstorm Plugin MUI TO BUI - #10061
AmbrishRamachandiran wants to merge 2 commits into
Conversation
Signed-off-by: AmbrishRamachandiran <[email protected]>
Changed Packages
|
Signed-off-by: AmbrishRamachandiran <[email protected]>
There was a problem hiding this comment.
Pull request overview
Migrates parts of the StackStorm Backstage plugin UI from Material-UI (MUI v4) components/icons to Backstage UI (BUI) primitives, introducing CSS modules that rely on BUI design tokens.
Changes:
- Replaced MUI components in
ExecutionPanelandActionsListwith@backstage/uicomponents and plain semantic HTML + CSS modules. - Replaced MUI icons with
@remixicon/reacticons and added corresponding styling. - Updated StackStorm plugin dependencies (removed
@material-ui/*, added@backstage/ui+@remixicon/react) and updated the workspace lockfile.
Reviewed changes
Copilot reviewed 8 out of 9 changed files in this pull request and generated 2 comments.
Show a summary per file
| File | Description |
|---|---|
| workspaces/xcmetrics/.changeset/old-eyes-scream.md | Adds a changeset (currently targeting the wrong workspace/package for this PR). |
| workspaces/stackstorm/yarn.lock | Updates locked deps to reflect the move from MUI to @backstage/ui and Remixicon. |
| workspaces/stackstorm/plugins/stackstorm/src/components/StackstormHome/StackstormHome.tsx | Replaces MUI IconButton/icon with a Remixicon link + CSS module styling. |
| workspaces/stackstorm/plugins/stackstorm/src/components/StackstormHome/StackstormHome.module.css | Adds BUI-token-based styling for the docs icon link. |
| workspaces/stackstorm/plugins/stackstorm/src/components/ExecutionsTable/ExecutionPanel.tsx | Replaces MUI Card/Table/Typography/Button usage with BUI + semantic HTML + CSS module styling. |
| workspaces/stackstorm/plugins/stackstorm/src/components/ExecutionsTable/ExecutionPanel.module.css | Adds BUI-token-based styling for the execution details layout. |
| workspaces/stackstorm/plugins/stackstorm/src/components/ActionsList/ActionsList.tsx | Replaces MUI list/collapse UI with semantic lists, a button toggle, BUI Flex/Text, and Remixicons. |
| workspaces/stackstorm/plugins/stackstorm/src/components/ActionsList/ActionsList.module.css | Adds BUI-token-based styling for pack/action list UI. |
| workspaces/stackstorm/plugins/stackstorm/package.json | Swaps MUI deps for @backstage/ui and @remixicon/react. |
Comments suppressed due to low confidence (2)
workspaces/stackstorm/plugins/stackstorm/src/components/ActionsList/ActionsList.tsx:140
aria-labelledby="nested-list-subheader"references an id that doesn't exist anywhere in this plugin, and applyingrole="navigation"to a<ul>is not the expected semantics (navigation landmarks should be a<nav>). This currently produces an invalid ARIA reference and weakens accessibility.
<ul
role="navigation"
aria-labelledby="nested-list-subheader"
className={styles.root}
>
{(value || []).map(p => {
return (
<PackListItem
key={p.ref}
pack={p}
opened={expanded.includes(p.ref)}
onClick={onClick}
/>
);
})}
</ul>
workspaces/stackstorm/plugins/stackstorm/src/components/ExecutionsTable/ExecutionPanel.tsx:107
<Button>is being used as a child of an<a>, which creates nested interactive elements and can confuse screen readers / keyboard interaction. Prefer Backstage UI'sButtonLinkfor link-styled buttons.
<div className={styles.cardFooter}>
<a
href={st2.getExecutionHistoryUrl(e.id)}
target="_blank"
rel="noopener noreferrer"
>
<Button variant="secondary">View in ST2</Button>
</a>
There was a problem hiding this comment.
Pull request overview
Copilot reviewed 8 out of 9 changed files in this pull request and generated 1 comment.
Comments suppressed due to low confidence (3)
workspaces/stackstorm/plugins/stackstorm/src/components/ActionsList/ActionsList.tsx:79
- This
<button>is missing an explicittype. If this component is ever rendered inside a<form>, the defaulttype="submit"can cause unintended form submissions. It’s also a good place to expose the expanded/collapsed state viaaria-expanded.
<button className={styles.packItem} onClick={() => onClick(pack.ref)}>
workspaces/stackstorm/plugins/stackstorm/src/components/ExecutionsTable/ExecutionPanel.tsx:24
- Wrapping a BUI
Buttonin an<a>below creates nested interactive elements (likely<a><button/></a>). Switching toButtonLinkavoids invalid markup and keeps link semantics.
import { Button, Card, CardBody, Text } from '@backstage/ui';
workspaces/stackstorm/plugins/stackstorm/src/components/ExecutionsTable/ExecutionPanel.tsx:107
- The current markup nests a button inside a link (
<a>...<Button/>...</a>), which is invalid HTML and can confuse keyboard/screen-reader interaction. Prefer a single interactive element for this action.
target="_blank"
rel="noopener noreferrer"
>
<Button variant="secondary">View in ST2</Button>
</a>
|
This PR has been automatically marked as stale because it has not had recent activity from the author. It will be closed if no further activity occurs. If the PR was closed and you want it re-opened, let us know and we'll re-open the PR so that you can continue the contribution! |
Migrated screens