Skip to content

Move trusted issuer feature into the configure-connections package#4286

Open
JayaShakthi97 wants to merge 1 commit into
thunder-id:mainfrom
JayaShakthi97:feature/integrations-page
Open

Move trusted issuer feature into the configure-connections package#4286
JayaShakthi97 wants to merge 1 commit into
thunder-id:mainfrom
JayaShakthi97:feature/integrations-page

Conversation

@JayaShakthi97

@JayaShakthi97 JayaShakthi97 commented Jul 23, 2026

Copy link
Copy Markdown
Contributor

Purpose

Consolidate the trusted issuer UI alongside the rest of the connection management code by moving it out of the console app and into the @thunderid/configure-connections package. This keeps all connection related screens, hooks, and models in one package so the console only wires up routes.

Approach

  • Relocated the trusted issuer API hooks, models, utils, components, pages, and their tests from frontend/apps/console/src/features/trusted-issuers into frontend/packages/configure-connections/src.
  • Moved the connection create wizard route out of frontend/apps/console/src/features/connections and folded it into the package's ConnectionCreateWizardPage, wiring the trusted issuer step in directly.
  • Exported TrustedIssuerDetailPage from the package and updated the console to lazy-load ConnectionCreateWizardPage and TrustedIssuerDetailPage from @thunderid/configure-connections.
  • Added the TRUSTED_ISSUER query key to the package's connection query keys and removed the now-unused console-local copies.

No behavior change: routes and navigation targets are unchanged; this is a structural move.

Related Issues

Related PRs

  • N/A

Checklist

  • Followed the contribution guidelines.
  • Manual test round performed and verified.
  • Documentation provided. (Add links if there are any)
    • Ran Vale and fixed all errors and warnings
  • Tests provided. (Add links if there are any)
    • Unit Tests
    • Integration Tests
  • Breaking changes. (Fill if applicable)
    • Breaking changes section filled.
    • breaking change label added.

Security checks

  • Followed secure coding standards in WSO2 Secure Coding Guidelines
  • Confirmed that this PR doesn't commit any keys, passwords, tokens, usernames, or other secrets.

Summary by CodeRabbit

  • New Features
    • Added Trusted Issuer as a built-in option in the connection creation wizard.
    • Added a dedicated Trusted Issuer details page, including navigation and deletion support.
    • Added a Back button to the Trusted Issuer setup form.
  • Bug Fixes
    • Improved Trusted Issuer form validation for required HTTPS issuer and JWKS endpoint inputs.
    • Fixed Trusted Issuer navigation and deletion flow wiring.
  • Tests
    • Expanded and updated coverage for wizard steps, form behavior (including Back), and Trusted Issuer detail deletion.

@coderabbitai

coderabbitai Bot commented Jul 23, 2026

Copy link
Copy Markdown
Contributor

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro Plus

Run ID: 15aba381-73c2-420d-9011-c8906e822631

📥 Commits

Reviewing files that changed from the base of the PR and between baa0ea9 and e248167.

📒 Files selected for processing (29)
  • frontend/apps/console/src/App.tsx
  • frontend/apps/console/src/__tests__/App.test.tsx
  • frontend/apps/console/src/features/connections/pages/ConnectionCreateWizardRoute.tsx
  • frontend/apps/console/src/features/connections/pages/__tests__/ConnectionCreateWizardRoute.test.tsx
  • frontend/apps/console/src/features/trusted-issuers/api/useDeleteTrustedIssuer.ts
  • frontend/apps/console/src/features/trusted-issuers/components/TrustedIssuerDeleteDialog.tsx
  • frontend/apps/console/src/features/trusted-issuers/constants/query-keys.ts
  • frontend/apps/console/src/features/trusted-issuers/pages/TrustedIssuerWizardStep.tsx
  • frontend/apps/console/src/features/trusted-issuers/pages/__tests__/TrustedIssuerWizardStep.test.tsx
  • frontend/packages/configure-connections/src/api/useCreateTrustedIssuer.ts
  • frontend/packages/configure-connections/src/api/useTrustedIssuer.ts
  • frontend/packages/configure-connections/src/api/useUpdateTrustedIssuer.ts
  • frontend/packages/configure-connections/src/components/TrustedIssuerCreateForm.tsx
  • frontend/packages/configure-connections/src/components/__tests__/TrustedIssuerCreateForm.test.tsx
  • frontend/packages/configure-connections/src/components/create-connection/SelectConnectionType.tsx
  • frontend/packages/configure-connections/src/components/create-connection/__tests__/SelectConnectionType.test.tsx
  • frontend/packages/configure-connections/src/constants/query-keys.ts
  • frontend/packages/configure-connections/src/index.ts
  • frontend/packages/configure-connections/src/models/trusted-issuer.ts
  • frontend/packages/configure-connections/src/pages/ConnectionCreateWizardPage.tsx
  • frontend/packages/configure-connections/src/pages/TrustedIssuerDetailPage.tsx
  • frontend/packages/configure-connections/src/pages/__tests__/ConnectionCreateWizardPage.test.tsx
  • frontend/packages/configure-connections/src/pages/__tests__/TrustedIssuerDetailPage.test.tsx
  • frontend/packages/configure-connections/src/utils/__tests__/isTrustedIssuerFormDirty.test.ts
  • frontend/packages/configure-connections/src/utils/__tests__/mapConnectionToTrustedIssuer.test.ts
  • frontend/packages/configure-connections/src/utils/isTrustedIssuerFormDirty.ts
  • frontend/packages/configure-connections/src/utils/mapConnectionToTrustedIssuer.ts
  • frontend/packages/configure-connections/src/utils/validateTrustedIssuerForm.ts
  • frontend/packages/i18n/src/locales/en-US.ts
💤 Files with no reviewable changes (8)
  • frontend/apps/console/src/features/trusted-issuers/pages/tests/TrustedIssuerWizardStep.test.tsx
  • frontend/apps/console/src/features/trusted-issuers/api/useDeleteTrustedIssuer.ts
  • frontend/apps/console/src/features/connections/pages/tests/ConnectionCreateWizardRoute.test.tsx
  • frontend/apps/console/src/features/trusted-issuers/pages/TrustedIssuerWizardStep.tsx
  • frontend/apps/console/src/features/connections/pages/ConnectionCreateWizardRoute.tsx
  • frontend/apps/console/src/features/trusted-issuers/constants/query-keys.ts
  • frontend/apps/console/src/features/trusted-issuers/components/TrustedIssuerDeleteDialog.tsx
  • frontend/packages/i18n/src/locales/en-US.ts
🚧 Files skipped from review as they are similar to previous changes (18)
  • frontend/packages/configure-connections/src/constants/query-keys.ts
  • frontend/packages/configure-connections/src/utils/tests/mapConnectionToTrustedIssuer.test.ts
  • frontend/packages/configure-connections/src/utils/tests/isTrustedIssuerFormDirty.test.ts
  • frontend/packages/configure-connections/src/utils/isTrustedIssuerFormDirty.ts
  • frontend/packages/configure-connections/src/api/useTrustedIssuer.ts
  • frontend/packages/configure-connections/src/models/trusted-issuer.ts
  • frontend/packages/configure-connections/src/utils/mapConnectionToTrustedIssuer.ts
  • frontend/packages/configure-connections/src/pages/tests/TrustedIssuerDetailPage.test.tsx
  • frontend/packages/configure-connections/src/components/create-connection/tests/SelectConnectionType.test.tsx
  • frontend/packages/configure-connections/src/index.ts
  • frontend/apps/console/src/App.tsx
  • frontend/packages/configure-connections/src/utils/validateTrustedIssuerForm.ts
  • frontend/apps/console/src/tests/App.test.tsx
  • frontend/packages/configure-connections/src/pages/tests/ConnectionCreateWizardPage.test.tsx
  • frontend/packages/configure-connections/src/pages/ConnectionCreateWizardPage.tsx
  • frontend/packages/configure-connections/src/components/tests/TrustedIssuerCreateForm.test.tsx
  • frontend/packages/configure-connections/src/api/useUpdateTrustedIssuer.ts
  • frontend/packages/configure-connections/src/components/create-connection/SelectConnectionType.tsx

📝 Walkthrough

Walkthrough

The PR moves trusted-issuer wizard and detail behavior into configure-connections, exposes shared models and query keys, replaces custom-step wiring with a built-in trusted-idp flow, adopts shared connection deletion, and updates console routing and tests.

Changes

Trusted issuer flow

Layer / File(s) Summary
Contracts and form utilities
frontend/packages/configure-connections/src/models/*, src/utils/*, src/constants/query-keys.ts
Adds trusted-issuer models, HTTPS validation, dirty-state comparison, and a shared trusted-issuer query key.
Wizard and creation form
frontend/packages/configure-connections/src/pages/ConnectionCreateWizardPage.tsx, src/components/TrustedIssuerCreateForm.tsx, src/components/create-connection/*
Makes trusted-idp a built-in wizard option, renders its specialized form, adds Back navigation, and updates creation flow wiring.
Detail page and connection operations
frontend/packages/configure-connections/src/api/*, src/pages/TrustedIssuerDetailPage.tsx, src/components/*
Uses shared connection query keys and deletion APIs, and navigates to /connections after deletion.
Package and console integration
frontend/packages/configure-connections/src/index.ts, frontend/apps/console/src/App.tsx, frontend/apps/console/src/__tests__/App.test.tsx
Exports the detail page and routes console creation and trusted-issuer detail paths to package pages.

Estimated code review effort: 3 (Moderate) | ~20 minutes

Sequence Diagram(s)

sequenceDiagram
  participant User
  participant ConnectionCreateWizardPage
  participant TrustedIssuerCreateForm
  participant useCreateTrustedIssuer
  User->>ConnectionCreateWizardPage: Select trusted-idp
  ConnectionCreateWizardPage->>TrustedIssuerCreateForm: Render trusted issuer form
  TrustedIssuerCreateForm->>useCreateTrustedIssuer: Submit issuer configuration
  useCreateTrustedIssuer-->>TrustedIssuerCreateForm: Return created issuer or conflict
Loading

Possibly related PRs

Suggested reviewers: jeradrutnam, donomalvindula, brionmario

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 72.73% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (4 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly and concisely summarizes the main change: moving the trusted issuer feature into the configure-connections package.
Description check ✅ Passed The description matches the repository template well, with Purpose, Approach, Issues, PRs, Checklist, and Security sections filled in.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Warning

There were issues while running some tools. Please review the errors and either fix the tool's configuration or disable the tool if it's a critical failure.

🔧 ESLint

If the error stems from missing dependencies, add them to the package.json file. For unrecoverable errors (e.g., due to private dependencies), disable the tool in the CodeRabbit configuration.

frontend/apps/console/src/App.tsx

ESLint skipped: missing config or dependency (missing-dependency). The ESLint configuration references a package that is not available in the sandbox.

frontend/apps/console/src/__tests__/App.test.tsx

ESLint skipped: the ESLint configuration for this file references a package that is not available in the sandbox.

frontend/packages/configure-connections/src/api/useCreateTrustedIssuer.ts

ESLint skipped: missing config or dependency (missing-dependency). The ESLint configuration references a package that is not available in the sandbox.

  • 18 others

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@coderabbitai coderabbitai Bot 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.

Actionable comments posted: 4

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (1)
frontend/packages/configure-connections/src/components/TrustedIssuerCreateForm.tsx (1)

121-125: 📐 Maintainability & Code Quality | 🟡 Minor | ⚡ Quick win

Avoid raw ThunderID literals. Is this hardcoded brand name intentional?

  • frontend/packages/configure-connections/src/components/TrustedIssuerCreateForm.tsx#L121-L125: use the existing productName config value as an interpolation variable in the fallback string.
  • frontend/packages/configure-connections/src/pages/__tests__/ConnectionCreateWizardPage.test.tsx#L33-L36: use a neutral fixture product name, since this test does not assert branding.

As per path instructions, hardcoded product names should be sourced from configuration where replaceable.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In
`@frontend/packages/configure-connections/src/components/TrustedIssuerCreateForm.tsx`
around lines 121 - 125, The TrustedIssuerCreateForm subtitle hardcodes the
ThunderID brand instead of using configured branding. Update the translation
fallback around the subtitle Typography to interpolate the existing productName
configuration value, and update ConnectionCreateWizardPage.test.tsx lines 33-36
to use a neutral fixture product name because branding is not under test.

Source: Path instructions

🧹 Nitpick comments (1)
frontend/packages/configure-connections/src/pages/TrustedIssuerWizardStep.tsx (1)

29-34: 📐 Maintainability & Code Quality | 🔵 Trivial | ⚡ Quick win

Remove the obsolete customConfigureSteps reference.

That API was removed from ConnectionCreateWizardPage; the comment now points maintainers to a nonexistent extension point.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In
`@frontend/packages/configure-connections/src/pages/TrustedIssuerWizardStep.tsx`
around lines 29 - 34, Remove the obsolete reference to customConfigureSteps from
the documentation comment for TrustedIssuerWizardStep, while preserving the
remaining description of the wizard integration and collected name step.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In
`@frontend/packages/configure-connections/src/components/TrustedIssuerCreateForm.tsx`:
- Around line 103-105: Update the post-create navigation in
TrustedIssuerCreateForm and resolve the destination through the package’s
use<Domain>Routes() hook instead of hardcoding `/trusted-issuers/${created.id}`.
Use the hook-provided trusted-issuer detail route with created.id, while
preserving the existing navigate behavior.

In
`@frontend/packages/configure-connections/src/components/TrustedIssuerDeleteDialog.tsx`:
- Around line 99-110: Update the i18n calls in TrustedIssuerDeleteDialog’s
cancel and confirm buttons to provide fallback default strings for
common:actions.cancel, common:status.deleting, and common:actions.delete, while
preserving the existing pending-state selection and button behavior.

In
`@frontend/packages/configure-connections/src/pages/TrustedIssuerDetailPage.tsx`:
- Line 131: The reusable TrustedIssuerDetailPage currently hardcodes the
console-specific /connections route in both the back action at
frontend/packages/configure-connections/src/pages/TrustedIssuerDetailPage.tsx:131-131
and the post-deletion navigation at
frontend/packages/configure-connections/src/pages/TrustedIssuerDetailPage.tsx:312-312.
Use useConnectionRoutes() to obtain connectionRoutes and navigate to
connectionRoutes.list() in both callbacks.

In
`@frontend/packages/configure-connections/src/utils/validateTrustedIssuerForm.ts`:
- Around line 39-65: Add unit tests for validateTrustedIssuerForm covering
whitespace-only names, empty issuer and jwksEndpoint fields, malformed and
non-HTTPS URLs, and valid HTTPS URLs. Assert the returned field error map for
each branch, including valid input producing no errors, and ensure coverage
reaches at least 80%.

---

Outside diff comments:
In
`@frontend/packages/configure-connections/src/components/TrustedIssuerCreateForm.tsx`:
- Around line 121-125: The TrustedIssuerCreateForm subtitle hardcodes the
ThunderID brand instead of using configured branding. Update the translation
fallback around the subtitle Typography to interpolate the existing productName
configuration value, and update ConnectionCreateWizardPage.test.tsx lines 33-36
to use a neutral fixture product name because branding is not under test.

---

Nitpick comments:
In
`@frontend/packages/configure-connections/src/pages/TrustedIssuerWizardStep.tsx`:
- Around line 29-34: Remove the obsolete reference to customConfigureSteps from
the documentation comment for TrustedIssuerWizardStep, while preserving the
remaining description of the wizard integration and collected name step.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro Plus

Run ID: 2931fd16-9ae8-4a05-8905-3bb96b89ece2

📥 Commits

Reviewing files that changed from the base of the PR and between 99130c3 and ae423ba.

📒 Files selected for processing (27)
  • frontend/apps/console/src/App.tsx
  • frontend/apps/console/src/features/connections/pages/ConnectionCreateWizardRoute.tsx
  • frontend/apps/console/src/features/connections/pages/__tests__/ConnectionCreateWizardRoute.test.tsx
  • frontend/apps/console/src/features/trusted-issuers/constants/query-keys.ts
  • frontend/packages/configure-connections/src/api/useCreateTrustedIssuer.ts
  • frontend/packages/configure-connections/src/api/useDeleteTrustedIssuer.ts
  • frontend/packages/configure-connections/src/api/useTrustedIssuer.ts
  • frontend/packages/configure-connections/src/api/useUpdateTrustedIssuer.ts
  • frontend/packages/configure-connections/src/components/TrustedIssuerCreateForm.tsx
  • frontend/packages/configure-connections/src/components/TrustedIssuerDeleteDialog.tsx
  • frontend/packages/configure-connections/src/components/__tests__/TrustedIssuerCreateForm.test.tsx
  • frontend/packages/configure-connections/src/components/create-connection/SelectConnectionType.tsx
  • frontend/packages/configure-connections/src/components/create-connection/__tests__/SelectConnectionType.test.tsx
  • frontend/packages/configure-connections/src/constants/query-keys.ts
  • frontend/packages/configure-connections/src/index.ts
  • frontend/packages/configure-connections/src/models/trusted-issuer.ts
  • frontend/packages/configure-connections/src/pages/ConnectionCreateWizardPage.tsx
  • frontend/packages/configure-connections/src/pages/TrustedIssuerDetailPage.tsx
  • frontend/packages/configure-connections/src/pages/TrustedIssuerWizardStep.tsx
  • frontend/packages/configure-connections/src/pages/__tests__/ConnectionCreateWizardPage.test.tsx
  • frontend/packages/configure-connections/src/pages/__tests__/TrustedIssuerDetailPage.test.tsx
  • frontend/packages/configure-connections/src/pages/__tests__/TrustedIssuerWizardStep.test.tsx
  • frontend/packages/configure-connections/src/utils/__tests__/isTrustedIssuerFormDirty.test.ts
  • frontend/packages/configure-connections/src/utils/__tests__/mapConnectionToTrustedIssuer.test.ts
  • frontend/packages/configure-connections/src/utils/isTrustedIssuerFormDirty.ts
  • frontend/packages/configure-connections/src/utils/mapConnectionToTrustedIssuer.ts
  • frontend/packages/configure-connections/src/utils/validateTrustedIssuerForm.ts
💤 Files with no reviewable changes (3)
  • frontend/apps/console/src/features/connections/pages/tests/ConnectionCreateWizardRoute.test.tsx
  • frontend/apps/console/src/features/trusted-issuers/constants/query-keys.ts
  • frontend/apps/console/src/features/connections/pages/ConnectionCreateWizardRoute.tsx

@coderabbitai coderabbitai Bot 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.

Caution

Inline review comments failed to post. This is likely due to GitHub's internal server error or limits when posting large numbers of comments. If you are seeing this consistently it is likely a permissions issue. Please check "Moderation" -> "Code review limits" under your organization settings.

Actionable comments posted: 4

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (1)
frontend/packages/configure-connections/src/components/TrustedIssuerCreateForm.tsx (1)

121-125: 📐 Maintainability & Code Quality | 🟡 Minor | ⚡ Quick win

Avoid raw ThunderID literals. Is this hardcoded brand name intentional?

  • frontend/packages/configure-connections/src/components/TrustedIssuerCreateForm.tsx#L121-L125: use the existing productName config value as an interpolation variable in the fallback string.
  • frontend/packages/configure-connections/src/pages/__tests__/ConnectionCreateWizardPage.test.tsx#L33-L36: use a neutral fixture product name, since this test does not assert branding.

As per path instructions, hardcoded product names should be sourced from configuration where replaceable.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In
`@frontend/packages/configure-connections/src/components/TrustedIssuerCreateForm.tsx`
around lines 121 - 125, The TrustedIssuerCreateForm subtitle hardcodes the
ThunderID brand instead of using configured branding. Update the translation
fallback around the subtitle Typography to interpolate the existing productName
configuration value, and update ConnectionCreateWizardPage.test.tsx lines 33-36
to use a neutral fixture product name because branding is not under test.

Source: Path instructions

🧹 Nitpick comments (1)
frontend/packages/configure-connections/src/pages/TrustedIssuerWizardStep.tsx (1)

29-34: 📐 Maintainability & Code Quality | 🔵 Trivial | ⚡ Quick win

Remove the obsolete customConfigureSteps reference.

That API was removed from ConnectionCreateWizardPage; the comment now points maintainers to a nonexistent extension point.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In
`@frontend/packages/configure-connections/src/pages/TrustedIssuerWizardStep.tsx`
around lines 29 - 34, Remove the obsolete reference to customConfigureSteps from
the documentation comment for TrustedIssuerWizardStep, while preserving the
remaining description of the wizard integration and collected name step.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In
`@frontend/packages/configure-connections/src/components/TrustedIssuerCreateForm.tsx`:
- Around line 103-105: Update the post-create navigation in
TrustedIssuerCreateForm and resolve the destination through the package’s
use<Domain>Routes() hook instead of hardcoding `/trusted-issuers/${created.id}`.
Use the hook-provided trusted-issuer detail route with created.id, while
preserving the existing navigate behavior.

In
`@frontend/packages/configure-connections/src/components/TrustedIssuerDeleteDialog.tsx`:
- Around line 99-110: Update the i18n calls in TrustedIssuerDeleteDialog’s
cancel and confirm buttons to provide fallback default strings for
common:actions.cancel, common:status.deleting, and common:actions.delete, while
preserving the existing pending-state selection and button behavior.

In
`@frontend/packages/configure-connections/src/pages/TrustedIssuerDetailPage.tsx`:
- Line 131: The reusable TrustedIssuerDetailPage currently hardcodes the
console-specific /connections route in both the back action at
frontend/packages/configure-connections/src/pages/TrustedIssuerDetailPage.tsx:131-131
and the post-deletion navigation at
frontend/packages/configure-connections/src/pages/TrustedIssuerDetailPage.tsx:312-312.
Use useConnectionRoutes() to obtain connectionRoutes and navigate to
connectionRoutes.list() in both callbacks.

In
`@frontend/packages/configure-connections/src/utils/validateTrustedIssuerForm.ts`:
- Around line 39-65: Add unit tests for validateTrustedIssuerForm covering
whitespace-only names, empty issuer and jwksEndpoint fields, malformed and
non-HTTPS URLs, and valid HTTPS URLs. Assert the returned field error map for
each branch, including valid input producing no errors, and ensure coverage
reaches at least 80%.

---

Outside diff comments:
In
`@frontend/packages/configure-connections/src/components/TrustedIssuerCreateForm.tsx`:
- Around line 121-125: The TrustedIssuerCreateForm subtitle hardcodes the
ThunderID brand instead of using configured branding. Update the translation
fallback around the subtitle Typography to interpolate the existing productName
configuration value, and update ConnectionCreateWizardPage.test.tsx lines 33-36
to use a neutral fixture product name because branding is not under test.

---

Nitpick comments:
In
`@frontend/packages/configure-connections/src/pages/TrustedIssuerWizardStep.tsx`:
- Around line 29-34: Remove the obsolete reference to customConfigureSteps from
the documentation comment for TrustedIssuerWizardStep, while preserving the
remaining description of the wizard integration and collected name step.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro Plus

Run ID: 2931fd16-9ae8-4a05-8905-3bb96b89ece2

📥 Commits

Reviewing files that changed from the base of the PR and between 99130c3 and ae423ba.

📒 Files selected for processing (27)
  • frontend/apps/console/src/App.tsx
  • frontend/apps/console/src/features/connections/pages/ConnectionCreateWizardRoute.tsx
  • frontend/apps/console/src/features/connections/pages/__tests__/ConnectionCreateWizardRoute.test.tsx
  • frontend/apps/console/src/features/trusted-issuers/constants/query-keys.ts
  • frontend/packages/configure-connections/src/api/useCreateTrustedIssuer.ts
  • frontend/packages/configure-connections/src/api/useDeleteTrustedIssuer.ts
  • frontend/packages/configure-connections/src/api/useTrustedIssuer.ts
  • frontend/packages/configure-connections/src/api/useUpdateTrustedIssuer.ts
  • frontend/packages/configure-connections/src/components/TrustedIssuerCreateForm.tsx
  • frontend/packages/configure-connections/src/components/TrustedIssuerDeleteDialog.tsx
  • frontend/packages/configure-connections/src/components/__tests__/TrustedIssuerCreateForm.test.tsx
  • frontend/packages/configure-connections/src/components/create-connection/SelectConnectionType.tsx
  • frontend/packages/configure-connections/src/components/create-connection/__tests__/SelectConnectionType.test.tsx
  • frontend/packages/configure-connections/src/constants/query-keys.ts
  • frontend/packages/configure-connections/src/index.ts
  • frontend/packages/configure-connections/src/models/trusted-issuer.ts
  • frontend/packages/configure-connections/src/pages/ConnectionCreateWizardPage.tsx
  • frontend/packages/configure-connections/src/pages/TrustedIssuerDetailPage.tsx
  • frontend/packages/configure-connections/src/pages/TrustedIssuerWizardStep.tsx
  • frontend/packages/configure-connections/src/pages/__tests__/ConnectionCreateWizardPage.test.tsx
  • frontend/packages/configure-connections/src/pages/__tests__/TrustedIssuerDetailPage.test.tsx
  • frontend/packages/configure-connections/src/pages/__tests__/TrustedIssuerWizardStep.test.tsx
  • frontend/packages/configure-connections/src/utils/__tests__/isTrustedIssuerFormDirty.test.ts
  • frontend/packages/configure-connections/src/utils/__tests__/mapConnectionToTrustedIssuer.test.ts
  • frontend/packages/configure-connections/src/utils/isTrustedIssuerFormDirty.ts
  • frontend/packages/configure-connections/src/utils/mapConnectionToTrustedIssuer.ts
  • frontend/packages/configure-connections/src/utils/validateTrustedIssuerForm.ts
💤 Files with no reviewable changes (3)
  • frontend/apps/console/src/features/connections/pages/tests/ConnectionCreateWizardRoute.test.tsx
  • frontend/apps/console/src/features/trusted-issuers/constants/query-keys.ts
  • frontend/apps/console/src/features/connections/pages/ConnectionCreateWizardRoute.tsx
🛑 Comments failed to post (4)
frontend/packages/configure-connections/src/components/TrustedIssuerCreateForm.tsx (1)

103-105: 🗄️ Data Integrity & Integration | 🟠 Major | 🏗️ Heavy lift

Use package-provided routes for post-create navigation.

🔴 Hardcoded route in a reusable package: resolve this destination through a use<Domain>Routes() hook instead of a literal path string — otherwise a host application cannot mount this package under a different URL without editing the package itself.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In
`@frontend/packages/configure-connections/src/components/TrustedIssuerCreateForm.tsx`
around lines 103 - 105, Update the post-create navigation in
TrustedIssuerCreateForm and resolve the destination through the package’s
use<Domain>Routes() hook instead of hardcoding `/trusted-issuers/${created.id}`.
Use the hook-provided trusted-issuer detail route with created.id, while
preserving the existing navigate behavior.

Source: Path instructions

frontend/packages/configure-connections/src/components/TrustedIssuerDeleteDialog.tsx (1)

99-110: 🎯 Functional Correctness | 🟡 Minor | ⚡ Quick win

Add fallbacks for common action labels.

common:actions.cancel, common:status.deleting, and common:actions.delete omit default strings, so a missing translation can expose raw keys in the dialog.

As per coding guidelines, every i18n t('key') call must provide a fallback default string.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In
`@frontend/packages/configure-connections/src/components/TrustedIssuerDeleteDialog.tsx`
around lines 99 - 110, Update the i18n calls in TrustedIssuerDeleteDialog’s
cancel and confirm buttons to provide fallback default strings for
common:actions.cancel, common:status.deleting, and common:actions.delete, while
preserving the existing pending-state selection and button behavior.

Source: Coding guidelines

frontend/packages/configure-connections/src/pages/TrustedIssuerDetailPage.tsx (1)

131-131: 🎯 Functional Correctness | 🟠 Major | ⚡ Quick win

Remove console-specific route literals from this reusable page. Both callbacks assume the host mounts connections at /connections; use useConnectionRoutes() and its list() destination instead.

  • frontend/packages/configure-connections/src/pages/TrustedIssuerDetailPage.tsx#L131-L131: navigate to connectionRoutes.list() for the back action.
  • frontend/packages/configure-connections/src/pages/TrustedIssuerDetailPage.tsx#L312-L312: navigate to connectionRoutes.list() after deletion.
📍 Affects 1 file
  • frontend/packages/configure-connections/src/pages/TrustedIssuerDetailPage.tsx#L131-L131 (this comment)
  • frontend/packages/configure-connections/src/pages/TrustedIssuerDetailPage.tsx#L312-L312
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In
`@frontend/packages/configure-connections/src/pages/TrustedIssuerDetailPage.tsx`
at line 131, The reusable TrustedIssuerDetailPage currently hardcodes the
console-specific /connections route in both the back action at
frontend/packages/configure-connections/src/pages/TrustedIssuerDetailPage.tsx:131-131
and the post-deletion navigation at
frontend/packages/configure-connections/src/pages/TrustedIssuerDetailPage.tsx:312-312.
Use useConnectionRoutes() to obtain connectionRoutes and navigate to
connectionRoutes.list() in both callbacks.

Source: Path instructions

frontend/packages/configure-connections/src/utils/validateTrustedIssuerForm.ts (1)

39-65: 📐 Maintainability & Code Quality | 🟠 Major | ⚡ Quick win

Add unit tests for the validation branches.

This new validator has no accompanying tests. Cover whitespace-only names, empty fields, malformed or HTTP URLs, and valid HTTPS URLs, targeting at least 80% coverage.

As per coding guidelines, write tests for new features and bug fixes, targeting at least 80% coverage.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In
`@frontend/packages/configure-connections/src/utils/validateTrustedIssuerForm.ts`
around lines 39 - 65, Add unit tests for validateTrustedIssuerForm covering
whitespace-only names, empty issuer and jwksEndpoint fields, malformed and
non-HTTPS URLs, and valid HTTPS URLs. Assert the returned field error map for
each branch, including valid input producing no errors, and ensure coverage
reaches at least 80%.

Source: Coding guidelines

@JayaShakthi97 JayaShakthi97 added Type/Improvement skip-changelog Skip generating changelog for a particular PR labels Jul 23, 2026
@codecov

codecov Bot commented Jul 23, 2026

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 75.00000% with 1 line in your changes missing coverage. Please review.

Files with missing lines Patch % Lines
frontend/apps/console/src/App.tsx 75.00% 1 Missing ⚠️

📢 Thoughts on this report? Let us know!

brionmario
brionmario previously approved these changes Jul 23, 2026

@coderabbitai coderabbitai Bot 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.

Actionable comments posted: 2

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In
`@frontend/packages/configure-connections/src/components/TrustedIssuerCreateForm.tsx`:
- Line 112: Replace the literal destination in TrustedIssuerCreateForm with the
appropriate use<Domain>Routes() hook, obtaining the trusted-issuer detail route
through its route resolver before calling navigate. Preserve navigation to the
newly created issuer while allowing host applications to configure the package’s
URL prefix.

In
`@frontend/packages/configure-connections/src/pages/TrustedIssuerDetailPage.tsx`:
- Line 134: Replace both hardcoded /connections destinations in
TrustedIssuerDetailPage.tsx at lines 134 and 322 with the appropriate values
from the package’s use<Domain>Routes() hook, using the same route abstraction
for back navigation and post-delete navigation.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro Plus

Run ID: c9d2630e-31ea-46e2-967e-ca20499ab3ba

📥 Commits

Reviewing files that changed from the base of the PR and between ae423ba and baa0ea9.

📒 Files selected for processing (28)
  • frontend/apps/console/src/App.tsx
  • frontend/apps/console/src/__tests__/App.test.tsx
  • frontend/apps/console/src/features/connections/pages/ConnectionCreateWizardRoute.tsx
  • frontend/apps/console/src/features/connections/pages/__tests__/ConnectionCreateWizardRoute.test.tsx
  • frontend/apps/console/src/features/trusted-issuers/api/useDeleteTrustedIssuer.ts
  • frontend/apps/console/src/features/trusted-issuers/components/TrustedIssuerDeleteDialog.tsx
  • frontend/apps/console/src/features/trusted-issuers/pages/TrustedIssuerWizardStep.tsx
  • frontend/apps/console/src/features/trusted-issuers/pages/__tests__/TrustedIssuerWizardStep.test.tsx
  • frontend/packages/configure-connections/src/api/useCreateTrustedIssuer.ts
  • frontend/packages/configure-connections/src/api/useTrustedIssuer.ts
  • frontend/packages/configure-connections/src/api/useUpdateTrustedIssuer.ts
  • frontend/packages/configure-connections/src/components/TrustedIssuerCreateForm.tsx
  • frontend/packages/configure-connections/src/components/__tests__/TrustedIssuerCreateForm.test.tsx
  • frontend/packages/configure-connections/src/components/create-connection/SelectConnectionType.tsx
  • frontend/packages/configure-connections/src/components/create-connection/__tests__/SelectConnectionType.test.tsx
  • frontend/packages/configure-connections/src/constants/query-keys.ts
  • frontend/packages/configure-connections/src/index.ts
  • frontend/packages/configure-connections/src/models/trusted-issuer.ts
  • frontend/packages/configure-connections/src/pages/ConnectionCreateWizardPage.tsx
  • frontend/packages/configure-connections/src/pages/TrustedIssuerDetailPage.tsx
  • frontend/packages/configure-connections/src/pages/__tests__/ConnectionCreateWizardPage.test.tsx
  • frontend/packages/configure-connections/src/pages/__tests__/TrustedIssuerDetailPage.test.tsx
  • frontend/packages/configure-connections/src/utils/__tests__/isTrustedIssuerFormDirty.test.ts
  • frontend/packages/configure-connections/src/utils/__tests__/mapConnectionToTrustedIssuer.test.ts
  • frontend/packages/configure-connections/src/utils/isTrustedIssuerFormDirty.ts
  • frontend/packages/configure-connections/src/utils/mapConnectionToTrustedIssuer.ts
  • frontend/packages/configure-connections/src/utils/validateTrustedIssuerForm.ts
  • frontend/packages/i18n/src/locales/en-US.ts
💤 Files with no reviewable changes (6)
  • frontend/apps/console/src/features/trusted-issuers/pages/tests/TrustedIssuerWizardStep.test.tsx
  • frontend/apps/console/src/features/trusted-issuers/api/useDeleteTrustedIssuer.ts
  • frontend/apps/console/src/features/connections/pages/tests/ConnectionCreateWizardRoute.test.tsx
  • frontend/apps/console/src/features/connections/pages/ConnectionCreateWizardRoute.tsx
  • frontend/apps/console/src/features/trusted-issuers/pages/TrustedIssuerWizardStep.tsx
  • frontend/apps/console/src/features/trusted-issuers/components/TrustedIssuerDeleteDialog.tsx
🚧 Files skipped from review as they are similar to previous changes (15)
  • frontend/packages/configure-connections/src/utils/mapConnectionToTrustedIssuer.ts
  • frontend/packages/configure-connections/src/api/useCreateTrustedIssuer.ts
  • frontend/packages/configure-connections/src/api/useTrustedIssuer.ts
  • frontend/packages/configure-connections/src/constants/query-keys.ts
  • frontend/packages/configure-connections/src/utils/isTrustedIssuerFormDirty.ts
  • frontend/packages/configure-connections/src/utils/validateTrustedIssuerForm.ts
  • frontend/packages/configure-connections/src/index.ts
  • frontend/packages/configure-connections/src/pages/tests/TrustedIssuerDetailPage.test.tsx
  • frontend/packages/configure-connections/src/utils/tests/isTrustedIssuerFormDirty.test.ts
  • frontend/packages/configure-connections/src/models/trusted-issuer.ts
  • frontend/packages/configure-connections/src/pages/ConnectionCreateWizardPage.tsx
  • frontend/packages/configure-connections/src/api/useUpdateTrustedIssuer.ts
  • frontend/packages/configure-connections/src/pages/tests/ConnectionCreateWizardPage.test.tsx
  • frontend/packages/configure-connections/src/components/create-connection/tests/SelectConnectionType.test.tsx
  • frontend/apps/console/src/App.tsx

Comment thread frontend/packages/configure-connections/src/pages/TrustedIssuerDetailPage.tsx Outdated
Consolidate the trusted issuer UI alongside the rest of the connection
management code by relocating it from the console app into the
`@thunderid/configure-connections` package.

- Move the trusted issuer API hooks, models, utils, components, pages,
  and their tests from `apps/console/src/features/trusted-issuers` into
  `packages/configure-connections/src`.
- Move the connection create wizard route out of
  `apps/console/src/features/connections` and fold it into the package's
  `ConnectionCreateWizardPage`, wiring the trusted issuer step in
  directly.
- Export `TrustedIssuerDetailPage` from the package and update the
  console to lazy-load `ConnectionCreateWizardPage` and
  `TrustedIssuerDetailPage` from `@thunderid/configure-connections`.
- Add the `TRUSTED_ISSUER` query key to the package's connection query
  keys and drop the now-unused console-local copies.
- Resolve the trusted-issuer navigation destinations through
  `useConnectionRoutes()` instead of hardcoding `/trusted-issuers/:id`
  and `/connections`, so host applications can remount this package
  under a different URL prefix.
@JayaShakthi97
JayaShakthi97 force-pushed the feature/integrations-page branch from baa0ea9 to e248167 Compare July 24, 2026 05:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

skip-changelog Skip generating changelog for a particular PR Type/Improvement

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants