Conversation
# Conflicts: # src/modules/clusters/cluster-information/components/clusterHeading.tsx
Contributor
There was a problem hiding this comment.
Pull Request Overview
This PR refactors the MCP Button component to handle complex MCP response formatting and display. It enhances the button's ability to render structured debug responses with improved error formatting and adds support for custom icons.
- Added
FailedProfiletype for consistent MCP debug response formatting - Refactored
McpButtonto accept complex response objects and custom icons - Updated all MCP button usages to use the new response format
Reviewed Changes
Copilot reviewed 7 out of 7 changed files in this pull request and generated 4 comments.
Show a summary per file
| File | Description |
|---|---|
| tsconfig.node.json | Added trailing newline |
| src/types/profile.types.ts | Added FailedProfile interface for MCP response structure |
| src/modules/common/components/actions/VerifyInstallation.tsx | Updated to use new MCP button props with custom icons and response data |
| src/modules/clusters/cluster-information/components/clusterHeading.tsx | Updated MCP debug button to use new response format and cleaned up console logs |
| src/modules/clusters/cluster-information/components/addonsTable/rows/ProfileRow.tsx | Updated MCP button to use new mcpResponse prop |
| src/lib/components/ui/inputs/mcp-button.tsx | Major refactor to support custom icons, array responses, and improved error formatting |
| src/hooks/useMcp.tsx | Added response processing functions and updated return types for structured data |
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This pull request refactors the MCP Button
Added the
FailedProfiletype toprofile.types.tsto consistently format MCP debug responses.Updated the
McpButtoncomponent to accept and render complex MCP responses (mcpResponse), support custom icons, and display error messages with improved formatting.Modified usages of
McpButtoninProfileRow,ClusterHeading, andVerifyInstallationto the new response