Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: Issue 34961 GraphQL Logo seems to be incorrect #34974

Merged
merged 3 commits into from
Jul 23, 2024

Conversation

shubham88fru
Copy link
Contributor

@shubham88fru shubham88fru commented Jul 16, 2024

Description

Issue: The GRAPHQL plugin logo is shown same as RestAPI plugin.
Fix: Imported the right logo for graphql and used the right image in the img tag

Fixes #34961

Automation

/ok-to-test tags="@tag.Sanity @tag.IDE"

🔍 Cypress test results

Caution

If you modify the content in this section, you are likely to disrupt the CI result for your PR.

Communication

Should the DevRel and Marketing teams inform users about this change?

  • Yes
  • No

Summary by CodeRabbit

  • New Features
    • Updated the New API screen to display the GraphQL logo instead of the Plus logo.

Copy link
Contributor

coderabbitai bot commented Jul 16, 2024

Walkthrough

This update addresses the incorrect display of the GraphQL logo in the integration editor. The change replaces the logo used for GraphQL API integration from the current PlusLogo to the accurate GraphQLLogo, ensuring the correct graphical representation in the user interface.

Changes

Files Change Summary
app/client/src/pages/Editor/.../NewApi.tsx Added a new import for GraphQLLogo from "assets/images/Graphql-logo.svg" and replaced the image source.

Sequence Diagram(s)

None needed for this simple change.

Assessment against linked issues

Objective Addressed Explanation
Correct the GraphQL logo display in the integration editor (#34961)

In the world of code, a logo set right,
GraphQL shines with a brand new light.
A small fix, but it makes things bright,
Now UI's ready, for every user's sight! 🚀


Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media?

Share
Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>.
    • Generate unit testing code for this file.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query. Examples:
    • @coderabbitai generate unit testing code for this file.
    • @coderabbitai modularize this function.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai generate interesting stats about this repository and render them as a table.
    • @coderabbitai show all the console.log statements in this repository.
    • @coderabbitai read src/utils.ts and generate unit testing code.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.
    • @coderabbitai help me debug CodeRabbit configuration file.

Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments.

CodeRabbit Commands (invoked as PR comments)

  • @coderabbitai pause to pause the reviews on a PR.
  • @coderabbitai resume to resume the paused reviews.
  • @coderabbitai review to trigger an incremental review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai full review to do a full review from scratch and review all the files again.
  • @coderabbitai summary to regenerate the summary of the PR.
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai configuration to show the current CodeRabbit configuration for the repository.
  • @coderabbitai help to get help.

Additionally, you can add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.

CodeRabbit Configuration File (.coderabbit.yaml)

  • You can programmatically configure CodeRabbit by adding a .coderabbit.yaml file to the root of your repository.
  • Please see the configuration documentation for more information.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json

Documentation and Community

  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 0

Review details

Configuration used: .coderabbit.yaml
Review profile: CHILL

Commits

Files that changed from the base of the PR and between 9cf62ca and 9a907af.

Files selected for processing (1)
  • app/client/src/pages/Editor/IntegrationEditor/NewApi.tsx (2 hunks)
Additional comments not posted (2)
app/client/src/pages/Editor/IntegrationEditor/NewApi.tsx (2)

10-10: Correct import for GraphQL logo.

The addition of the GraphQLLogo import from the correct path is a necessary step to resolve the issue with the incorrect logo display. This change is directly aligned with the PR's objective to differentiate the GraphQL logo from the RestAPI logo. Well done on ensuring the path matches the project's structure.


270-270: Updated image source to use the correct logo.

You have correctly updated the image source for the GraphQL API card to use the newly imported GraphQLLogo. This change ensures that the correct logo is displayed, resolving the cosmetic issue reported. It's important to visually confirm this change in the UI to ensure that the logo appears as expected.

Verification successful

Let's verify the import and usage of GraphQLLogo in the NewApi.tsx file to ensure it is correctly implemented.


Updated image source to use the correct logo.

You have correctly updated the image source for the GraphQL API card to use the newly imported GraphQLLogo. This change ensures that the correct logo is displayed, resolving the cosmetic issue reported. It's important to visually confirm this change in the UI to ensure that the logo appears as expected.

  • The import statement for GraphQLLogo is correctly set to "assets/images/Graphql-logo.svg".
  • The GraphQLLogo is used in the component with src={GraphQLLogo}.
Scripts executed

The following scripts were executed for the analysis:

Script:

#!/bin/bash
# Description: Verify the correct display of the GraphQL logo in the UI.

# Test: Check the rendered HTML for the presence of the GraphQL logo image.
echo "Manual verification required: Please ensure the GraphQL logo is correctly displayed in the UI."

Length of output: 198


Script:

#!/bin/bash
# Verify the import statement for GraphQLLogo
rg 'import .*GraphQLLogo.* from' app/client/src/pages/Editor/IntegrationEditor/NewApi.tsx

# Verify the usage of GraphQLLogo in the component
rg 'GraphQLLogo' -A 5 app/client/src/pages/Editor/IntegrationEditor/NewApi.tsx

Length of output: 826

@shubham88fru shubham88fru changed the title Fix for bug 34961: GraphQL Logo seems to be incorrect fix: Issue 34961 GraphQL Logo seems to be incorrect Jul 16, 2024
@shubham88fru
Copy link
Contributor Author

Hi @ayushpahwa . Please review.

@shubham88fru
Copy link
Contributor Author

Hi @ayushpahwa , please review this PR.

@NilanshBansal
Copy link
Contributor

/build-deploy-preview skip-tests=true

Copy link

Deploying Your Preview: https://github.com/appsmithorg/appsmith/actions/runs/10053916997.
Workflow: On demand build Docker image and deploy preview.
skip-tests: true.
env: ``.
PR: 34974.
recreate: .

Copy link

Deploy-Preview-URL: https://ce-34974.dp.appsmith.com

@ayushpahwa ayushpahwa added the ok-to-test Required label for CI label Jul 23, 2024
Copy link
Contributor

@ayushpahwa ayushpahwa left a comment

Choose a reason for hiding this comment

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

LGTM. Thanks for your contribution!

@NilanshBansal
Copy link
Contributor

@ayushpahwa do we need any tests for this?

@ayushpahwa
Copy link
Contributor

@NilanshBansal for UI changes like this, snapshot tests might be relevant but they are not really maintainable. I have done manual test on the DP generated however. Lemme know if there's any other suggestions/reservations.

@NilanshBansal
Copy link
Contributor

Thanks @ayushpahwa for the confirmation! Looks good to me. Let's go ahead and get this merged in that case.

@ayushpahwa
Copy link
Contributor

All automation tests passed, okay to merge.

@yatinappsmith yatinappsmith merged commit d350299 into appsmithorg:release Jul 23, 2024
19 of 20 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
ok-to-test Required label for CI
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Bug]: GraphQL Logo seems to be incorrect
4 participants