Skip to content

(feat) O3-5857: Share @carbon/react and @carbon/icons-react in openmrs-esm-core - #1836

Open
omsrivastava512 wants to merge 1 commit into
openmrs:mainfrom
omsrivastava512:feat/O3-5857-share-carbon-icons
Open

(feat) O3-5857: Share @carbon/react and @carbon/icons-react in openmrs-esm-core#1836
omsrivastava512 wants to merge 1 commit into
openmrs:mainfrom
omsrivastava512:feat/O3-5857-share-carbon-icons

Conversation

@omsrivastava512

@omsrivastava512 omsrivastava512 commented Aug 5, 2026

Copy link
Copy Markdown

Requirements

  • This PR has a title that briefly describes the work done including the ticket number. If there is a ticket, make sure your PR title includes a conventional commit label. See existing PR titles for inspiration.
  • My work is based on designs, which are linked or shown either in the Jira ticket or the description below. (See also: Styleguide)
  • My work includes tests or is validated by existing tests.
  • I have updated the esm-framework and storybook mocks (mock.tsx, mock-jest.tsx, and storybook mocks) to reflect any API changes.

Summary

This PR addresses O3-5857 (prerequisite child of parent epic O3-5854). It configures @carbon/icons-react as a shared singleton provided by the app shell scope, and updates all 6 of the microfrontend apps in openmrs-esm-core to declare @carbon/icons-react inside peerDependencies.

Key Changes

  1. App Shell (packages/shell/esm-app-shell):
    • Added @carbon/icons-react to dependencies.json so the shell exposes it in the shared Module Federation scope.
    • Added "@carbon/icons-react": "^11.58.0" to package.json / dependencies.
  2. App Packages (packages/apps/*):
    • Added "@carbon/icons-react": "11.x" to peerDependencies across all 6 app packages (esm-devtools-app, esm-help-menu-app, esm-implementer-tools-app, esm-login-app, esm-offline-tools-app, esm-primary-navigation-app).
    • Verified @carbon/react: 1.x is already consistently declared across all app packages.
    • For esm-offline-tools-app: Shifted @carbon/icons-react from dependencies to peerDependencies + devDependencies to consume the shell singleton cleanly.

Verification & Testing

  • Executed yarn build:apps: all 30 workspace targets built cleanly.
  • Confirmed version specifiers (11.x) match the shell's version range (11.58.0 in lockfile).

Screenshots

N/A

Related Issue

https://openmrs.atlassian.net/browse/O3-5857

Other

@changeset-bot

changeset-bot Bot commented Aug 5, 2026

Copy link
Copy Markdown

⚠️ No Changeset found

Latest commit: a74cdca

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

@sonarqubecloud

sonarqubecloud Bot commented Aug 5, 2026

Copy link
Copy Markdown

@greptile-apps

greptile-apps Bot commented Aug 5, 2026

Copy link
Copy Markdown

Greptile Summary

Adds @carbon/icons-react to the app shell’s shared dependency scope and aligns the six affected microfrontend peer declarations with Carbon Icons v11. The potential shared-module compatibility failure was disproved: version 11.68.0 resolves from the app shell, satisfies its declared range and all six peer ranges, and the app shell development build completes successfully. No defects were found.

Confidence Score: 5/5

T-Rex T-Rex Logs

What T-Rex did

  • The validation compared the pre-capture state with the post-capture state to confirm contract expectations, noting that the parent shell had no icon dependency or shared entry before, and that after capture @carbon/icons-react 11.68.0 was installed with an 11.x shared requirement, six compatible peers, 2,511 module exports, and a successful development build.

View all artifacts

T-Rex Ran code and verified through T-Rex

Reviews (1): Last reviewed commit: "feat(shell): share @carbon/react and @ca..." | Re-trigger Greptile

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.

1 participant