Skip to content

Conversation

@Biswas-Samrat
Copy link

@Biswas-Samrat Biswas-Samrat commented Nov 15, 2025

🚀 Feature/Refactor: Link Github Button to External URL

Description

This pull request updates the Github component by replacing the <button> element with a semantically correct anchor tag (<a>). This change allows the component to function as a hyperlink, redirecting users to the project's organization page on GitHub.

Changes Made

  1. Component: Replaced <button className="btn-github"> with <a className="btn-github">.
  2. Functionality: Added href="https://github.com/AOSSIE-Org" to direct the user to the correct organization page.
  3. User Experience: Added target="_blank" so the link opens in a new browser tab, preventing the user from leaving the current application context.
  4. Security/Best Practice: Included rel="noopener noreferrer" for security best practices when using target="_blank".
  5. Styling: Added text-decoration: none; to the .btn-github styles to ensure the anchor tag does not display the default browser underline.

✅ Testing Steps

  1. Run the application locally.
  2. Locate the "Contribute on Github" button.
  3. Click the button.
  4. Verify: A new browser tab opens, navigated to https://github.com/AOSSIE-Org.

Summary by CodeRabbit

  • Improvements
    • Updated the GitHub call-to-action to link directly to the AOSSIE GitHub organization and open in a new tab for easier access.
    • Refined the visual styling of the GitHub button with improved hover states and text formatting for a consistent appearance.

@coderabbitai
Copy link
Contributor

coderabbitai bot commented Nov 15, 2025

Walkthrough

The GitHub CTA component is converted from a button element to an anchor tag linking to https://github.com/AOSSIE-Org with security attributes. Styling is preserved with minor CSS adjustments, and imports are reformatted to use double quotes for consistency.

Changes

Cohort / File(s) Summary
GitHub CTA Component
LandingPage/src/components/github.tsx
Replaces button element with anchor tag linking to GitHub organization; adds security attributes (target="_blank", rel="noopener noreferrer"); adds text-decoration: none to CSS; reformats imports to double quotes; preserves existing styling and component export.

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~3 minutes

  • Verify the GitHub organization URL is correct and intentional
  • Confirm security attributes (target="_blank" and rel="noopener noreferrer") are properly set to prevent security vulnerabilities

Poem

🐰 A button hops to become a link so fine,
Off to GitHub where open-source does shine,
With security guards at the door so keen,
The smoothest CTA ever seen! 🔗✨

Pre-merge checks and finishing touches

✅ Passed checks (3 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title accurately summarizes the main change: replacing a button element with an anchor link for the GitHub CTA.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
✨ Finishing touches
  • 📝 Generate docstrings
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment

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 and usage tips.

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: 1

🧹 Nitpick comments (1)
LandingPage/src/components/github.tsx (1)

1-1: Verify quote style consistency across the project.

The import statement now uses double quotes instead of single quotes. Ensure this aligns with the project's linting rules or style guide.

📜 Review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between a3be437 and ece876f.

📒 Files selected for processing (1)
  • LandingPage/src/components/github.tsx (2 hunks)
🔇 Additional comments (2)
LandingPage/src/components/github.tsx (2)

6-25: Excellent semantic improvement with proper security attributes.

Converting the button to an anchor tag is the correct approach for external navigation. The inclusion of target="_blank" and rel="noopener noreferrer" follows security best practices by preventing the opened page from accessing window.opener.


30-61: CSS adjustments appropriately handle the anchor element.

The addition of text-decoration: none; correctly removes the default underline from the anchor tag while preserving the button-like appearance. The formatting adjustments to box-shadow and color properties are cosmetic improvements.

fill="currentcolor"
/>
</svg>
<span>Contribute on Github</span>
Copy link
Contributor

Choose a reason for hiding this comment

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

⚠️ Potential issue | 🟡 Minor

Fix the brand name capitalization.

The text reads "Contribute on Github" but the correct brand name is "GitHub" with a capital H.

Apply this diff:

-        <span>Contribute on Github</span>
+        <span>Contribute on GitHub</span>
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
<span>Contribute on Github</span>
<span>Contribute on GitHub</span>
🤖 Prompt for AI Agents
In LandingPage/src/components/github.tsx around line 24, the visible text uses
the incorrect brand capitalization "Contribute on Github"; update the span text
to use the official brand "GitHub" by replacing the string with "Contribute on
GitHub" (also update any identical occurrences in this file if present to ensure
consistent branding).

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