Skip to content

Servicenow mig#9474

Open
amitkumar489 wants to merge 2 commits into
backstage:mainfrom
Infosys:servicenow_mig
Open

Servicenow mig#9474
amitkumar489 wants to merge 2 commits into
backstage:mainfrom
Infosys:servicenow_mig

Conversation

@amitkumar489

Copy link
Copy Markdown

Hey, I just made a Pull Request!

migrating service now plugin from mui to bui

✔️ Checklist

  • [+] A changeset describing the change and affected packages. (more info)
  • [+] Added or updated documentation
  • [+] Tests for new functionality and regression tests for bug fixes
  • [+] Screenshots attached (for UI changes)
  • [+] All your commits have a Signed-off-by line in the message. (more info)
image

Signed-off-by: amitkumar489 <amit.kumar489@infosys.com>
Signed-off-by: amitkumar489 <amit.kumar489@infosys.com>
@backstage-goalie

Copy link
Copy Markdown
Contributor

Changed Packages

Package Name Package Path Changeset Bump Current Version
@backstage-community/plugin-servicenow workspaces/servicenow/plugins/servicenow major v1.12.0

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Note

Copilot was unable to run its full agentic suite in this review.

This PR continues the ServiceNow plugin migration away from Material-UI by replacing MUI components/icons with Backstage UI + Remix Icons, and moving styling into CSS Modules while reworking the incidents table/filter UI.

Changes:

  • Replaced MUI icons/components (tables, filters, tooltips) with Remix Icons, @backstage/ui, and react-aria-components.
  • Rebuilt the incidents list table (header/body/row) and pagination with div/CSS-table layout and CSS Modules.
  • Updated tests and introduced multiple new CSS modules for the migrated components.

Reviewed changes

Copilot reviewed 18 out of 18 changed files in this pull request and generated 13 comments.

Show a summary per file
File Description
workspaces/servicenow/plugins/servicenow/src/utils/incidentUtils.tsx Switches priority/state icons to Remix Icons and updates label rendering markup.
workspaces/servicenow/plugins/servicenow/src/components/shared-components/IncidentEnumFilter.tsx Replaces MUI Autocomplete with a custom dropdown + BUI components/CSS module styling.
workspaces/servicenow/plugins/servicenow/src/components/shared-components/IncidentEnumFilter.module.css Adds CSS module styling for custom enum filter dropdown.
workspaces/servicenow/plugins/servicenow/src/components/Servicenow/IncidentsTableRow.tsx Migrates row rendering to BUI/react-aria tooltip and Remix icon button.
workspaces/servicenow/plugins/servicenow/src/components/Servicenow/IncidentsTableRow.test.tsx Updates mocks/imports for Remix icons and react-aria tooltip components.
workspaces/servicenow/plugins/servicenow/src/components/Servicenow/IncidentsTableRow.module.css Adds CSS module styling for div-based “table” row/cells.
workspaces/servicenow/plugins/servicenow/src/components/Servicenow/IncidentsTableHeader.tsx Replaces MUI sorting header with custom button-based header + Remix sort icons.
workspaces/servicenow/plugins/servicenow/src/components/Servicenow/IncidentsTableHeader.module.css Adds CSS module styling for custom header row/cells/buttons.
workspaces/servicenow/plugins/servicenow/src/components/Servicenow/IncidentsTableBody.tsx Replaces MUI TableBody/empty-state row with div-based “table-row-group”.
workspaces/servicenow/plugins/servicenow/src/components/Servicenow/IncidentsTableBody.module.css Adds CSS module styling for empty table state row.
workspaces/servicenow/plugins/servicenow/src/components/Servicenow/IncidentsFilter.tsx Migrates filter layout container to BUI Box + CSS module.
workspaces/servicenow/plugins/servicenow/src/components/Servicenow/IncidentsFilter.module.css Adds CSS module styling for filter container responsiveness/spacing.
workspaces/servicenow/plugins/servicenow/src/components/Servicenow/EntityServicenowContent.tsx Replaces Backstage Table/MUI pagination with custom table layout, search, and pagination controls.
workspaces/servicenow/plugins/servicenow/src/components/Servicenow/EntityServicenowContent.test.tsx Removes Material-UI ThemeProvider usage to match new component stack.
workspaces/servicenow/plugins/servicenow/src/components/Servicenow/EntityServicenowContent.module.css Adds CSS module styling for custom table, search, pagination, loading/error states.
workspaces/servicenow/plugins/servicenow/src/components/Servicenow/CustomSvgIcon.tsx Replaces MUI SvgIcon with an inline <svg> implementation supporting size/style.
workspaces/servicenow/plugins/servicenow/package.json Adds @backstage/ui, @remixicon/react, react-aria-components; tweaks MUI dependency.
workspaces/servicenow/.changeset/cruel-nails-happen.md Adds a major-version changeset describing the migration scope/status.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment on lines +61 to 62
"react-aria-components": "^1.4.0",
"react-dom": "^16.13.1 || ^17.0.0 || ^18.0.0",
Comment on lines +67 to +71
<ButtonIcon
icon={<RiExternalLinkLine size={16} />}
onPress={() => window.open(data.url, '_blank')}
variant="secondary"
/>
Comment on lines +238 to +240
<span className={styles.paginationInfo}>
{offset + 1}-{Math.min(offset + rowsPerPage, count)} of {count}
</span>
Comment on lines +294 to +298
<input
type="text"
placeholder="Search"
value={input}
onChange={e => setInput(e.target.value)}
Comment on lines +36 to +48
<div style={{ display: 'table-row-group' }}>
<div style={{ display: 'table-row', borderBottom: '1px solid #e0e0e0' }}>
<div
style={{
display: 'table-cell',
padding: '24px 16px 24px 20px',
textAlign: 'center',
}}
data-testid="no-incidents-found"
className={styles.emptyRow}
>
{t('table.emptyContent')}
</div>
Comment on lines +48 to +55
.dropdown {
position: absolute;
top: 100%;
left: 0;
right: 0;
margin-top: var(--bui-space-1);
background-color: var(--bui-fg-solid);
border: 1px solid var(--bui-border-default);

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

i have used this if i dosen,t use it will become transparent

Comment on lines 62 to +68
{column.title}
</TableSortLabel>
</TableCell>
{orderBy === column.field &&
(orderBy === column.field && order === 'asc' ? (
<RiArrowUpSLine size={16} />
) : (
<RiArrowDownSLine size={16} />
))}
Comment on lines +10 to +13
.tableRow:last-child td,
.tableRow:last-child th {
border: 0;
}
value,
onChange,
}: IncidentEnumFilterProps) => {
const [isOpen, setIsOpen] = React.useState(false);
Comment on lines +72 to +73
{isOpen && (
<div className={styles.dropdown}>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants