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

feat UI: Styling changes #2826

Open
wants to merge 6 commits into
base: develop-postgres
Choose a base branch
from

Conversation

karthik-nair-20
Copy link

@karthik-nair-20 karthik-nair-20 commented Jan 3, 2025

What kind of change does this PR introduce?

Issue Number:

Fixes #2816
1st PR made for initial Docs UI updation.

Did you add tests for your changes?

Snapshots/Videos:

Screenshot 2025-01-03 at 11 15 15 AM Screenshot 2025-01-03 at 11 15 10 AM

If relevant, did you update the documentation?

Summary

Does this PR introduce a breaking change?

Other information

Have you read the contributing guide?

Summary by CodeRabbit

  • New Features

    • Updated site configuration with expanded navigation and footer links.
    • Added new social media and development section links.
  • Documentation

    • Updated site title to "Talawa-docs".
    • Dynamically updated copyright notice.
  • Style

    • Introduced new color variables and custom CSS properties.
    • Refined header, navbar, and footer styling.
    • Increased padding for the hero banner and added new title and subtitle classes.

Copy link

coderabbitai bot commented Jan 3, 2025

Walkthrough

This pull request updates the Docusaurus documentation site for Talawa-API with significant modifications to the configuration, styling, and homepage. Key changes include updating the site title, enhancing the navigation bar with new items, restructuring the footer, and implementing a modern color scheme. The CSS has been extensively revised to improve the overall aesthetic and functionality of the site, aligning it with the project's design guidelines.

Changes

File Change Summary
docs/docusaurus.config.ts - Updated site title to "Talawa-docs"
- Changed logo source
- Expanded navigation bar with new items
- Transformed footer with new social media and development links
docs/src/css/custom.css - Removed several CSS custom properties
- Introduced new CSS custom properties for improved color palette
- Added new classes and updated existing ones for various components
docs/src/pages/index.module.css - Increased hero banner padding
- Added new .title and .subtitle classes
- Updated button styling with new margin
docs/src/pages/index.tsx - Restructured homepage header component
- Simplified class names and layout

Assessment against linked issues

Objective Addressed Explanation
Update site CSS to be more modern
Restore dark/light mode capabilities
Create NavBar with specific links
Update homepage layout
Professional look with minimal imagery

Possibly related PRs

Suggested reviewers

  • palisadoes

Finishing Touches

  • 📝 Generate Docstrings (Beta)

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>, please review it.
    • 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 gather interesting stats about this repository and render them as a table. Additionally, render a pie chart showing the language distribution in the codebase.
    • @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 using 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 generate docstrings to generate docstrings for this PR. (Beta)
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai configuration to show the current CodeRabbit configuration for the repository.
  • @coderabbitai help to get help.

Other keywords and placeholders

  • Add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.
  • Add @coderabbitai summary to generate the high-level summary at a specific location in the PR description.
  • Add @coderabbitai anywhere in the PR title to generate the title automatically.

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

github-actions bot commented Jan 3, 2025

Our Pull Request Approval Process

Thanks for contributing!

Testing Your Code

Remember, your PRs won't be reviewed until these criteria are met:

  1. We don't merge PRs with poor code quality.
    1. Follow coding best practices such that CodeRabbit.ai approves your PR.
  2. We don't merge PRs with failed tests.
    1. When tests fail, click on the Details link to learn more.
    2. Write sufficient tests for your changes (CodeCov Patch Test). Your testing level must be better than the target threshold of the repository
    3. Tests may fail if you edit sensitive files. Ask to add the ignore-sensitive-files-pr label if the edits are necessary.
  3. We cannot merge PRs with conflicting files. These must be fixed.

Our policies make our code better.

Reviewers

Do not assign reviewers. Our Queue Monitors will review your PR and assign them.
When your PR has been assigned reviewers contact them to get your code reviewed and approved via:

  1. comments in this PR or
  2. our slack channel

Reviewing Your Code

Your reviewer(s) will have the following roles:

  1. arbitrators of future discussions with other contributors about the validity of your changes
  2. point of contact for evaluating the validity of your work
  3. person who verifies matching issues by others that should be closed.
  4. person who gives general guidance in fixing your tests

CONTRIBUTING.md

Read our CONTRIBUTING.md file. Most importantly:

  1. PRs with issues not assigned to you will be closed by the reviewer
  2. Fix the first comment in the PR so that each issue listed automatically closes

Other

  1. 🎯 Please be considerate of our volunteers' time. Contacting the person who assigned the reviewers is not advised unless they ask for your input. Do not @ the person who did the assignment otherwise.
  2. Read the CONTRIBUTING.md file make

Copy link

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

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

Congratulations on making your first PR! 🎊 If you haven't already, check out our Contributing Guidelines and PR Reporting Guidelines to ensure that you are following our guidelines for contributing and creating PR.

Copy link

@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: 5

📜 Review details

Configuration used: .coderabbit.yaml
Review profile: ASSERTIVE
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between bb65c66 and 4a459d5.

⛔ Files ignored due to path filters (5)
  • docs/static/img/logos/github-dark.svg is excluded by !**/*.svg
  • docs/static/img/logos/github.svg is excluded by !**/*.svg
  • docs/static/img/logos/logo.png is excluded by !**/*.png
  • docs/static/img/logos/youtube-light.svg is excluded by !**/*.svg
  • docs/static/img/logos/youtube.svg is excluded by !**/*.svg
📒 Files selected for processing (4)
  • docs/docusaurus.config.ts (3 hunks)
  • docs/src/css/custom.css (1 hunks)
  • docs/src/pages/index.module.css (2 hunks)
  • docs/src/pages/index.tsx (1 hunks)
🔇 Additional comments (23)
docs/src/pages/index.tsx (1)

15-27: Overall structure looks good.

The new layout with separate .title and .subtitle classes provides a neat separation of concerns and improves readability. The changes seem consistent with the updated CSS module classes.

docs/docusaurus.config.ts (5)

50-53: Validate brand naming and references.

Ensure that the title: 'Talawa-docs' label in the navbar corresponds accurately with the title: 'Talawa API Documentation' in the config. Consider unifying them if they should be the same.


63-73: Useful external docs references.

Linking out to various docs sites (mobile, admin, API) is helpful. Ensure all references point to live sites and confirm no transitions from HTTP to HTTPS are missed if secure links are desired.
[approve]


85-95: Great addition of GitHub & YouTube icons.

Providing direct links to GitHub and YouTube fosters community engagement. Ensure the corresponding icons and classes are present in the global or module CSS.


115-127: Slack, News & Contact.

These custom links in the 'Community' section support user engagement beyond code contributions. Validate that the classes used (footer__slack, footer__news, footer__contact) exist in your CSS or gracefully fallback if not found.


132-148: Social media icons.

Confirm that the social media icons are indeed accessible from your location. It's also good to verify that they function appropriately under dark/light modes.

docs/src/pages/index.module.css (3)

13-17: Clear, bold heading style.

The .title class definitions effectively emphasize the main heading. Good use of a distinct color variable for brand consistency.


19-26: Subtitle improvements.

Limiting max-width is a smart move to maintain better readability. This approach ensures text isn’t too wide on larger displays.


38-38: Spacing for CTA buttons.

Adding margin-top: 2rem can help the call-to-action buttons stand out. Ensure it aligns nicely in mobile displays.

docs/src/css/custom.css (14)

13-31: Global setting adjustments.

Defining custom properties in :root is a solid approach for consistent theming. Confirm that none of the newly introduced variables override essential defaults inadvertently.


36-57: Dark mode values.

Providing separate color sets for dark mode ensures good contrast and usability. Consider verifying with a color contrast checker for accessibility compliance.


59-64: .main-wrapper usage?

If .main-wrapper is meant to wrap core content, confirm that relevant templates or pages actually apply this class. Otherwise, it might be unused.


70-72: Background color in .main__content.

Ensuring consistent background color across all main content. Good approach for uniform site design.


83-86: .menu__list border.

The border helps create clear separation. Ensure it isn’t duplicated if the site’s design also uses other dividing elements.


88-94: Navbar styling.

The custom background and shadow are appealing. Keep in mind theming consistency with the rest of the site, especially in dark mode transitions.


96-98: Font size in navbar items.

Slightly smaller font size can visually separate the navbar from main headings. Keep a consistent scale across breakpoints so the navbar remains legible on smaller screens.


100-104: Hover states.

Providing a clear color shift on hover helps the user identify clickable elements. This is a good accessibility practice.


110-113: Dark footer style.

Be sure that the newly defined footer--dark background color doesn’t clash with text or link colors in dark mode. Validate color contrast if possible.


115-123: GitHub link icon.

Ensure the local "/img/logos/github-dark.svg" path is valid and that the icon’s license is correctly handled if it’s from a third-party source.


126-135: YouTube link icon.

Same note as the GitHub icon. Confirm the file paths and usage rights for any proprietary logos.


137-142: Dark mode icon override.

This is a handy approach to maintain brand coloring for GitHub and YouTube logos. Double-check that the images exist in the correct locations.


144-148: Improved spacing in .footer--dark li.

This ensures each footer list item is clearly separated. Good for readability and consistent spacing across the site.


150-153: Footer icon color.

Color set to #fff ensures link visibility. Consider verifying that links are distinguishable from normal text if user expects them to be a different shade.

docs/src/pages/index.tsx Outdated Show resolved Hide resolved
docs/src/pages/index.module.css Show resolved Hide resolved
docs/src/css/custom.css Show resolved Hide resolved
@palisadoes palisadoes added the ignore-sensitive-files-pr The contributor has a legitimate reason for editiing protected files label Jan 3, 2025
@palisadoes
Copy link
Contributor

Please make codec rabbit approve your work

coderabbitai[bot]
coderabbitai bot previously approved these changes Jan 4, 2025
Copy link

github-actions bot commented Jan 4, 2025

Our Pull Request Approval Process

Thanks for contributing!

Testing Your Code

Remember, your PRs won't be reviewed until these criteria are met:

  1. We don't merge PRs with poor code quality.
    1. Follow coding best practices such that CodeRabbit.ai approves your PR.
  2. We don't merge PRs with failed tests.
    1. When tests fail, click on the Details link to learn more.
    2. Write sufficient tests for your changes (CodeCov Patch Test). Your testing level must be better than the target threshold of the repository
    3. Tests may fail if you edit sensitive files. Ask to add the ignore-sensitive-files-pr label if the edits are necessary.
  3. We cannot merge PRs with conflicting files. These must be fixed.

Our policies make our code better.

Reviewers

Do not assign reviewers. Our Queue Monitors will review your PR and assign them.
When your PR has been assigned reviewers contact them to get your code reviewed and approved via:

  1. comments in this PR or
  2. our slack channel

Reviewing Your Code

Your reviewer(s) will have the following roles:

  1. arbitrators of future discussions with other contributors about the validity of your changes
  2. point of contact for evaluating the validity of your work
  3. person who verifies matching issues by others that should be closed.
  4. person who gives general guidance in fixing your tests

CONTRIBUTING.md

Read our CONTRIBUTING.md file. Most importantly:

  1. PRs with issues not assigned to you will be closed by the reviewer
  2. Fix the first comment in the PR so that each issue listed automatically closes

Other

  1. 🎯 Please be considerate of our volunteers' time. Contacting the person who assigned the reviewers is not advised unless they ask for your input. Do not @ the person who did the assignment otherwise.
  2. Read the CONTRIBUTING.md file make

Copy link

@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: 2

📜 Review details

Configuration used: .coderabbit.yaml
Review profile: ASSERTIVE
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 4a459d5 and ae97b45.

📒 Files selected for processing (1)
  • docs/src/pages/index.tsx (1 hunks)
🔇 Additional comments (1)
docs/src/pages/index.tsx (1)

13-13: LGTM! The className spelling has been corrected.

The previously reported typo in the className has been fixed, ensuring proper styling application.

docs/src/pages/index.tsx Show resolved Hide resolved
docs/src/pages/index.tsx Show resolved Hide resolved
@karthik-nair-20
Copy link
Author

@coderabbitai full review

Copy link

coderabbitai bot commented Jan 4, 2025

✅ Actions performed

Full review triggered.

@karthik-nair-20
Copy link
Author

@coderabbitai full review

Copy link

coderabbitai bot commented Jan 4, 2025

✅ Actions performed

Full review triggered.

Copy link

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

📜 Review details

Configuration used: .coderabbit.yaml
Review profile: ASSERTIVE
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between bb65c66 and ae97b45.

⛔ Files ignored due to path filters (5)
  • docs/static/img/logos/github-dark.svg is excluded by !**/*.svg
  • docs/static/img/logos/github.svg is excluded by !**/*.svg
  • docs/static/img/logos/logo.png is excluded by !**/*.png
  • docs/static/img/logos/youtube-light.svg is excluded by !**/*.svg
  • docs/static/img/logos/youtube.svg is excluded by !**/*.svg
📒 Files selected for processing (4)
  • docs/docusaurus.config.ts (3 hunks)
  • docs/src/css/custom.css (1 hunks)
  • docs/src/pages/index.module.css (2 hunks)
  • docs/src/pages/index.tsx (1 hunks)
🔇 Additional comments (9)
docs/src/pages/index.module.css (3)

7-7: Verify mobile responsiveness of increased padding.

The padding has been increased to 8rem, which looks good on desktop but might push content too far down on mobile screens.


13-26: Well-structured title and subtitle styles!

Good use of:

  • CSS variables for consistent colors
  • Appropriate font sizes for hierarchy
  • Max-width constraint for better readability

38-38: LGTM!

The 2rem margin provides good vertical spacing between the subtitle and buttons.

docs/src/pages/index.tsx (2)

15-19: Use CSS modules consistently.

While styles.heroBanner uses CSS modules, the classes 'content', 'title', and 'subtitle' don't. This inconsistency could lead to naming conflicts.


20-26: Update button text for Talawa API.

The button still contains template content "Docusaurus Tutorial - 5min ⏱️". Update it to be more relevant to Talawa API documentation.

docs/src/css/custom.css (1)

36-57: Well-implemented dark theme!

Excellent dark theme implementation with:

  • Good contrast ratios
  • Consistent color scheme
  • Proper variable overrides
docs/docusaurus.config.ts (3)

53-53: Verify logo file existence

Let's verify that the logo file exists at the specified path.

✅ Verification successful

Logo file exists at the specified path

The logo file logo.png exists at the correct location docs/static/img/logos/logo.png, which matches the path referenced in the configuration.

🏁 Scripts executed

The following scripts were executed for the analysis:

Script:

#!/bin/bash
# Check if logo exists
fd --type f "logo.png" docs/static/img/logos/

Length of output: 76


Line range hint 8-13: Verify favicon existence and path

The configuration specifies a favicon at 'img/favicon.ico'. Let's ensure this file exists at the correct location.

✅ Verification successful

Favicon exists at the specified location

The favicon file exists at docs/static/img/favicon.ico, which matches the path specified in the configuration (img/favicon.ico). The path is correct since Docusaurus automatically looks for static assets in the static directory.

🏁 Scripts executed

The following scripts were executed for the analysis:

Script:

#!/bin/bash
# Check if favicon exists
fd --type f "favicon.ico" docs/static/img/

Length of output: 70


88-95: Verify custom CSS classes for header icons

The configuration uses custom CSS classes for GitHub and YouTube links. Let's verify these classes are defined in the custom CSS file.

✅ Verification successful

Let's verify the actual CSS implementation for these classes.


Let's verify if the referenced image assets exist.


Let's try to locate the correct path for the images directory.


Let's check for the SVG files in the correct path.


✓ Header icon CSS classes and assets are properly configured

The verification confirms that:

  • Custom CSS classes header-github-link and header-youtube-link are properly defined in docs/src/css/custom.css
  • CSS includes proper styling for both light and dark themes
  • All required SVG assets are present at the correct paths:
    • docs/static/img/logos/github-dark.svg
    • docs/static/img/logos/github.svg
    • docs/static/img/logos/youtube-light.svg
    • docs/static/img/logos/youtube.svg
🏁 Scripts executed

The following scripts were executed for the analysis:

Script:

#!/bin/bash
# Check for header icon CSS classes in custom.css
rg -l "header-(github|youtube)-link" docs/src/css/

Length of output: 76


Script:

#!/bin/bash
# Check the content of the CSS classes in custom.css
rg "header-(github|youtube)-link" docs/src/css/custom.css -A 5

Length of output: 631


Script:

#!/bin/bash
# Check if the referenced SVG files exist
fd -e svg -p "github|youtube" static/img/logos/

Length of output: 154


Script:

#!/bin/bash
# Find the correct path for image assets
fd -t d "img|static"

Length of output: 83


Script:

#!/bin/bash
# Check if the referenced SVG files exist in the correct path
fd -e svg -p "github|youtube" docs/static/img/logos/

Length of output: 199

docs/docusaurus.config.ts Show resolved Hide resolved
docs/docusaurus.config.ts Show resolved Hide resolved
docs/docusaurus.config.ts Show resolved Hide resolved
docs/docusaurus.config.ts Show resolved Hide resolved
docs/docusaurus.config.ts Show resolved Hide resolved
@duplixx duplixx self-requested a review January 4, 2025 18:52
@palisadoes
Copy link
Contributor

@coderabbitai full review

Copy link

coderabbitai bot commented Jan 5, 2025

✅ Actions performed

Full review triggered.

Copy link

@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: 4

📜 Review details

Configuration used: .coderabbit.yaml
Review profile: ASSERTIVE
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between bb65c66 and ae97b45.

⛔ Files ignored due to path filters (5)
  • docs/static/img/logos/github-dark.svg is excluded by !**/*.svg
  • docs/static/img/logos/github.svg is excluded by !**/*.svg
  • docs/static/img/logos/logo.png is excluded by !**/*.png
  • docs/static/img/logos/youtube-light.svg is excluded by !**/*.svg
  • docs/static/img/logos/youtube.svg is excluded by !**/*.svg
📒 Files selected for processing (4)
  • docs/docusaurus.config.ts (3 hunks)
  • docs/src/css/custom.css (1 hunks)
  • docs/src/pages/index.module.css (2 hunks)
  • docs/src/pages/index.tsx (1 hunks)
🔇 Additional comments (14)
docs/docusaurus.config.ts (4)

63-84: Verify link targets for consistency and user experience.
The Mobile Guide and Admin Guide links open in a new tab ("_blank"), whereas the API Guide uses "_self". Unless intentional, consider uniform behavior for these external documentation links.


132-148: Check the correctness and availability of social media links.
Confirm the Twitter, Facebook, and Instagram links are valid and publicly accessible. Update them if they result in errors or redirected pages.


115-127: ⚠️ Potential issue

Ensure the Slack link actually points to the Slack workspace.
The link currently redirects to GitHub instead of Slack. This can confuse users trying to join your community channel.

 {
   label: "Slack",
-  to: "https://github.com/PalisadoesFoundation",
+  to: "https://<your_slack_workspace_invite_url>",
   className: "footer__icon footer__slack",
 },

Likely invalid or redundant comment.


50-53: 🧹 Nitpick (assertive)

Consider updating the alt text to reflect the actual site logo.
Currently, the logo alt text is "My Site Logo". This generic text should be revised to accurately describe the Talawa project or the Palisadoes Foundation branding for better accessibility.

   logo: {
-    alt: 'My Site Logo',
+    alt: 'Talawa API Documentation Logo',
     src: 'img/logos/logo.png',
   },

Likely invalid or redundant comment.

docs/src/pages/index.module.css (3)

7-7: Be cautious with large padding.
Expanding the hero banner from 4rem 0 to 8rem 0 significantly increases vertical spacing. While it improves aesthetics on large screens, test smaller devices to ensure the banner isn't pushing essential content too far down.


13-26: Welcome addition of dedicated title and subtitle classes.
This separation helps maintain a clean look and improves readability. Ensure the color variables (var(--primary-neutral-600) and #718096) meet accessibility contrast guidelines.


38-39: Enhance button spacing.
Adding a margin-top of 2rem to .buttons nicely separates the call-to-action from the content block, improving the layout. No issues here.

docs/src/pages/index.tsx (3)

13-13: Great fix for the hero banner class name.
Using styles.heroBanner ensures the correct styling is applied, matching the CSS module name.


21-26: 🧹 Nitpick (assertive)

Replace tutorial text with Talawa-specific copy.
"Docusaurus Tutorial - 5min" may confuse users who expect Talawa docs. Customize the button text to match your project context.

-  Docusaurus Tutorial - 5min ⏱️
+  Get Started with Talawa →

Likely invalid or redundant comment.


15-20: 🧹 Nitpick (assertive)

Consider using CSS modules consistently.
Defining .content, .title, and .subtitle as global classes can lead to future naming conflicts. If possible, move them into index.module.css for better scoping and maintenance.

- <div className="content">
-   <Heading as="h1" className="title">
-   <p className="subtitle">{siteConfig.tagline}</p>
+ <div className={styles.content}>
+   <Heading as="h1" className={styles.title}>
+   <p className={styles.subtitle}>{siteConfig.tagline}</p>

Likely invalid or redundant comment.

docs/src/css/custom.css (4)

13-31: Good use of CSS variables for theming and brand consistency.
The newly introduced color variables and highlight background are properly organized. Ensure naming remains consistent across files (e.g., --secondary-blue-900 vs. --secondary-blue-500) so future contributors understand your color hierarchy.


36-57: Double-check dark mode brand color alignment.
You introduced different values for brand and neutral colors in dark mode. Verify these changes align with your design guidelines and remain accessible.


137-142: Sync GitHub/YouTube icons for dark mode.
The approach of switching icons with :before is correct, but confirm the image paths exist and appear correctly on both light and dark themes.


150-153: Consistent icon styling in the footer.
.footer__icon looks good for uniform spacing. Ensure each social link uses the same base styling so users recognize clickable icons immediately.

docs/docusaurus.config.ts Show resolved Hide resolved
Comment on lines +151 to +160
{
title: "Development",
items: [
{
label: " GitHub",
to: "https://github.com/PalisadoesFoundation",
className: "footer__icon footer__github",
},
]
}
Copy link

Choose a reason for hiding this comment

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

🧹 Nitpick (assertive)

Confirm the "Development" section aligns with user expectations.
The "Development" footer section references GitHub, but consider whether it might also include contributor guides, code of conduct, or other dev resources for completeness.

docs/src/css/custom.css Outdated Show resolved Hide resolved
docs/src/css/custom.css Outdated Show resolved Hide resolved
@palisadoes
Copy link
Contributor

Please make coderabbit.ai approve your changes

@duplixx
Copy link
Member

duplixx commented Jan 10, 2025

@karthik-nair-20 any update?
please make coderabbit.ai appprove your PR, then only i can review it

@karthik-nair-20
Copy link
Author

sure sir, will update this PR

Copy link

Our Pull Request Approval Process

Thanks for contributing!

Testing Your Code

Remember, your PRs won't be reviewed until these criteria are met:

  1. We don't merge PRs with poor code quality.
    1. Follow coding best practices such that CodeRabbit.ai approves your PR.
  2. We don't merge PRs with failed tests.
    1. When tests fail, click on the Details link to learn more.
    2. Write sufficient tests for your changes (CodeCov Patch Test). Your testing level must be better than the target threshold of the repository
    3. Tests may fail if you edit sensitive files. Ask to add the ignore-sensitive-files-pr label if the edits are necessary.
  3. We cannot merge PRs with conflicting files. These must be fixed.

Our policies make our code better.

Reviewers

Do not assign reviewers. Our Queue Monitors will review your PR and assign them.
When your PR has been assigned reviewers contact them to get your code reviewed and approved via:

  1. comments in this PR or
  2. our slack channel

Reviewing Your Code

Your reviewer(s) will have the following roles:

  1. arbitrators of future discussions with other contributors about the validity of your changes
  2. point of contact for evaluating the validity of your work
  3. person who verifies matching issues by others that should be closed.
  4. person who gives general guidance in fixing your tests

CONTRIBUTING.md

Read our CONTRIBUTING.md file. Most importantly:

  1. PRs with issues not assigned to you will be closed by the reviewer
  2. Fix the first comment in the PR so that each issue listed automatically closes

Other

  1. 🎯 Please be considerate of our volunteers' time. Contacting the person who assigned the reviewers is not advised unless they ask for your input. Do not @ the person who did the assignment otherwise.
  2. Read the CONTRIBUTING.md file make

Copy link

@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: 4

📜 Review details

Configuration used: .coderabbit.yaml
Review profile: ASSERTIVE
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between ae97b45 and 0c24be9.

📒 Files selected for processing (1)
  • docs/src/css/custom.css (1 hunks)
⏰ Context from checks skipped due to timeout of 90000ms (2)
🔇 Additional comments (2)
docs/src/css/custom.css (2)

64-66: Small font size in table of contents.

The font size of 0.75rem might be too small for comfortable reading.


34-54: Verify color contrast ratios for dark theme.

While the color choices look good, it's important to verify that they meet WCAG accessibility guidelines for contrast ratios, especially for text elements.

Run this script to check color contrast ratios:

✅ Verification successful

Color contrast ratios meet accessibility standards

The dark theme implementation demonstrates excellent contrast ratios that exceed WCAG 2.1 Level AAA requirements (7:1) for text readability:

  • Main background (#111927) with text colors (#c4c4c4, #9da4ae)
  • Code background (#001b66) with light text
  • Interactive elements use sufficiently contrasting colors
🏁 Scripts executed

The following scripts were executed for the analysis:

Script:

#!/bin/bash
# Extract color values and output them for manual verification
echo "Colors to verify contrast ratios:"
rg "^[[:space:]]*--.*:#[0-9a-fA-F]{6}" docs/src/css/custom.css | sort -u

Length of output: 188


Script:

#!/bin/bash
echo "Direct color values:"
rg --no-line-number ":[[:space:]]*#[0-9a-fA-F]{3,6}|:[[:space:]]*rgb[a]?\([^)]+\)" docs/src/css/custom.css

echo -e "\nVariable references:"
rg --no-line-number ":[[:space:]]*var\(--[^)]+\)" docs/src/css/custom.css

Length of output: 1984

docs/src/css/custom.css Outdated Show resolved Hide resolved
docs/src/css/custom.css Outdated Show resolved Hide resolved
docs/src/css/custom.css Show resolved Hide resolved
docs/src/css/custom.css Outdated Show resolved Hide resolved
Copy link

Our Pull Request Approval Process

Thanks for contributing!

Testing Your Code

Remember, your PRs won't be reviewed until these criteria are met:

  1. We don't merge PRs with poor code quality.
    1. Follow coding best practices such that CodeRabbit.ai approves your PR.
  2. We don't merge PRs with failed tests.
    1. When tests fail, click on the Details link to learn more.
    2. Write sufficient tests for your changes (CodeCov Patch Test). Your testing level must be better than the target threshold of the repository
    3. Tests may fail if you edit sensitive files. Ask to add the ignore-sensitive-files-pr label if the edits are necessary.
  3. We cannot merge PRs with conflicting files. These must be fixed.

Our policies make our code better.

Reviewers

Do not assign reviewers. Our Queue Monitors will review your PR and assign them.
When your PR has been assigned reviewers contact them to get your code reviewed and approved via:

  1. comments in this PR or
  2. our slack channel

Reviewing Your Code

Your reviewer(s) will have the following roles:

  1. arbitrators of future discussions with other contributors about the validity of your changes
  2. point of contact for evaluating the validity of your work
  3. person who verifies matching issues by others that should be closed.
  4. person who gives general guidance in fixing your tests

CONTRIBUTING.md

Read our CONTRIBUTING.md file. Most importantly:

  1. PRs with issues not assigned to you will be closed by the reviewer
  2. Fix the first comment in the PR so that each issue listed automatically closes

Other

  1. 🎯 Please be considerate of our volunteers' time. Contacting the person who assigned the reviewers is not advised unless they ask for your input. Do not @ the person who did the assignment otherwise.
  2. Read the CONTRIBUTING.md file make

Copy link

@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: 2

📜 Review details

Configuration used: .coderabbit.yaml
Review profile: ASSERTIVE
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 0c24be9 and 1164659.

📒 Files selected for processing (1)
  • docs/src/css/custom.css (1 hunks)
⏰ Context from checks skipped due to timeout of 90000ms (2)
🔇 Additional comments (3)
docs/src/css/custom.css (3)

8-31: Well-structured root variables with semantic naming! 👍

Good job on:

  • Using semantic color naming (e.g., --primary-blue-600, --secondary-blue-900)
  • Following system-first font stack approach
  • Adding button hover states as requested

74-107: Menu and navbar styles look good! 👍

The styles provide good hierarchy and spacing. Nice touch with the consistent font sizes and weights.


36-57: Verify color contrast ratios for dark theme.

The navbar link color (#9da4ae) against the dark background might not meet WCAG 2.1 AA contrast requirements. Please verify the accessibility of these color combinations.

✅ Verification successful

Color contrast ratios in dark theme are appropriate

After analyzing the color combinations in the dark theme implementation, the contrast ratios appear to be sufficient for WCAG 2.1 AA compliance. The navbar link color (#9da4ae) provides adequate contrast against the dark background (#111927).

🏁 Scripts executed

The following scripts were executed for the analysis:

Script:

#!/bin/bash
# Description: Check for any other potential color contrast issues in the codebase
# Look for color definitions that might need contrast verification
rg -i '(#[0-9a-f]{6}|#[0-9a-f]{3}|rgba?\(|hsla?\()' docs/src/css/custom.css

Length of output: 1324

Comment on lines 59 to 72
.main-wrapper{
background-color: var(--ifm-background);
display: block;
margin: 0 calc(-1 * var(--ifm-pre-padding));
padding: 0 var(--ifm-pre-padding);
}

.table-of-contents {
font-size: 0.75rem;
}

.main__content{
background-color: var(--ifm-background);
}
Copy link

Choose a reason for hiding this comment

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

🧹 Nitpick (assertive)

Consider responsive padding for better mobile experience.

The main wrapper's negative margin and padding approach might cause issues on smaller screens. Consider using a more flexible layout approach.

 .main-wrapper {
   background-color: var(--ifm-background);
   display: block;
-  margin: 0 calc(-1 * var(--ifm-pre-padding));
-  padding: 0 var(--ifm-pre-padding);
+  padding: 0 max(var(--ifm-pre-padding), 16px);
 }
📝 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
.main-wrapper{
background-color: var(--ifm-background);
display: block;
margin: 0 calc(-1 * var(--ifm-pre-padding));
padding: 0 var(--ifm-pre-padding);
}
.table-of-contents {
font-size: 0.75rem;
}
.main__content{
background-color: var(--ifm-background);
}
.main-wrapper{
background-color: var(--ifm-background);
display: block;
padding: 0 max(var(--ifm-pre-padding), 16px);
}
.table-of-contents {
font-size: 0.75rem;
}
.main__content{
background-color: var(--ifm-background);
}

docs/src/css/custom.css Outdated Show resolved Hide resolved
@karthik-nair-20
Copy link
Author

@duplixx sir pls review

@duplixx
Copy link
Member

duplixx commented Jan 12, 2025

@duplixx sir pls review

Incorporate Coderabbit.ai suggestions in your Pull Request and ensure Coderabbit approves the changes.

Copy link

Our Pull Request Approval Process

Thanks for contributing!

Testing Your Code

Remember, your PRs won't be reviewed until these criteria are met:

  1. We don't merge PRs with poor code quality.
    1. Follow coding best practices such that CodeRabbit.ai approves your PR.
  2. We don't merge PRs with failed tests.
    1. When tests fail, click on the Details link to learn more.
    2. Write sufficient tests for your changes (CodeCov Patch Test). Your testing level must be better than the target threshold of the repository
    3. Tests may fail if you edit sensitive files. Ask to add the ignore-sensitive-files-pr label if the edits are necessary.
  3. We cannot merge PRs with conflicting files. These must be fixed.

Our policies make our code better.

Reviewers

Do not assign reviewers. Our Queue Monitors will review your PR and assign them.
When your PR has been assigned reviewers contact them to get your code reviewed and approved via:

  1. comments in this PR or
  2. our slack channel

Reviewing Your Code

Your reviewer(s) will have the following roles:

  1. arbitrators of future discussions with other contributors about the validity of your changes
  2. point of contact for evaluating the validity of your work
  3. person who verifies matching issues by others that should be closed.
  4. person who gives general guidance in fixing your tests

CONTRIBUTING.md

Read our CONTRIBUTING.md file. Most importantly:

  1. PRs with issues not assigned to you will be closed by the reviewer
  2. Fix the first comment in the PR so that each issue listed automatically closes

Other

  1. 🎯 Please be considerate of our volunteers' time. Contacting the person who assigned the reviewers is not advised unless they ask for your input. Do not @ the person who did the assignment otherwise.
  2. Read the CONTRIBUTING.md file make

Copy link

@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: 3

📜 Review details

Configuration used: .coderabbit.yaml
Review profile: ASSERTIVE
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 1164659 and ea99e52.

📒 Files selected for processing (1)
  • docs/src/css/custom.css (1 hunks)
⏰ Context from checks skipped due to timeout of 90000ms (2)
🔇 Additional comments (2)
docs/src/css/custom.css (2)

8-31: Well-structured root variables with semantic naming!

Good job on:

  • Using semantic color naming (e.g., --primary-blue-600, --secondary-blue-900)
  • Including button hover states
  • Comprehensive system font stack

113-140: Great improvements in icon handling!

The implementation now correctly:

  • Uses relative paths for image assets
  • Handles both light and dark theme icons
  • Maintains consistent positioning

docs/src/css/custom.css Outdated Show resolved Hide resolved
docs/src/css/custom.css Outdated Show resolved Hide resolved
docs/src/css/custom.css Outdated Show resolved Hide resolved
Copy link

Our Pull Request Approval Process

Thanks for contributing!

Testing Your Code

Remember, your PRs won't be reviewed until these criteria are met:

  1. We don't merge PRs with poor code quality.
    1. Follow coding best practices such that CodeRabbit.ai approves your PR.
  2. We don't merge PRs with failed tests.
    1. When tests fail, click on the Details link to learn more.
    2. Write sufficient tests for your changes (CodeCov Patch Test). Your testing level must be better than the target threshold of the repository
    3. Tests may fail if you edit sensitive files. Ask to add the ignore-sensitive-files-pr label if the edits are necessary.
  3. We cannot merge PRs with conflicting files. These must be fixed.

Our policies make our code better.

Reviewers

Do not assign reviewers. Our Queue Monitors will review your PR and assign them.
When your PR has been assigned reviewers contact them to get your code reviewed and approved via:

  1. comments in this PR or
  2. our slack channel

Reviewing Your Code

Your reviewer(s) will have the following roles:

  1. arbitrators of future discussions with other contributors about the validity of your changes
  2. point of contact for evaluating the validity of your work
  3. person who verifies matching issues by others that should be closed.
  4. person who gives general guidance in fixing your tests

CONTRIBUTING.md

Read our CONTRIBUTING.md file. Most importantly:

  1. PRs with issues not assigned to you will be closed by the reviewer
  2. Fix the first comment in the PR so that each issue listed automatically closes

Other

  1. 🎯 Please be considerate of our volunteers' time. Contacting the person who assigned the reviewers is not advised unless they ask for your input. Do not @ the person who did the assignment otherwise.
  2. Read the CONTRIBUTING.md file make

@karthik-nair-20
Copy link
Author

@coderabbitai full review

Copy link

coderabbitai bot commented Jan 12, 2025

✅ Actions performed

Full review triggered.

Copy link

@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: 2

📜 Review details

Configuration used: .coderabbit.yaml
Review profile: ASSERTIVE
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between bb65c66 and 9775003.

⛔ Files ignored due to path filters (5)
  • docs/static/img/logos/github-dark.svg is excluded by !**/*.svg
  • docs/static/img/logos/github.svg is excluded by !**/*.svg
  • docs/static/img/logos/logo.png is excluded by !**/*.png
  • docs/static/img/logos/youtube-light.svg is excluded by !**/*.svg
  • docs/static/img/logos/youtube.svg is excluded by !**/*.svg
📒 Files selected for processing (4)
  • docs/docusaurus.config.ts (3 hunks)
  • docs/src/css/custom.css (1 hunks)
  • docs/src/pages/index.module.css (2 hunks)
  • docs/src/pages/index.tsx (1 hunks)
🔇 Additional comments (16)
docs/src/pages/index.module.css (2)

7-7: Increased vertical spacing in the hero banner.

The padding has been increased from 4rem to 8rem as previously suggested, which enhances the visual balance on large screens.


13-17: LGTM! Well-structured title styling.

The title styling is well-defined with appropriate font size, weight, and uses CSS variables for consistent theming.

docs/src/pages/index.tsx (2)

15-19: Consider using CSS modules consistently.

While some classes use CSS modules (e.g., styles.heroBanner), others like 'content', 'title', and 'subtitle' use global classes. For better maintainability and to avoid naming conflicts, consider using CSS modules consistently.


20-26: Update button text to reflect Talawa API documentation.

The current button text refers to a "Docusaurus Tutorial", which appears to be template content. Consider updating it to something more relevant to Talawa API documentation.

docs/src/css/custom.css (7)

11-31: LGTM! Well-organized CSS variables.

The CSS variables are well-structured with:

  • Consistent naming conventions
  • Proper button hover states
  • Comprehensive font stack

36-57: LGTM! Well-balanced dark theme.

The dark theme variables provide good contrast while maintaining consistency with the light theme structure.


59-65: Consider adding max-width for better readability.

The main wrapper could benefit from a max-width constraint to ensure optimal line length for readability on larger screens.


67-69: Tiny font usage in .table-of-contents.

A 0.75rem font size can be hard to read for some audiences. Confirm that this meets your accessibility guidelines.


75-86: LGTM! Well-structured menu styles.

The menu styles provide good readability with appropriate font size, padding, and visual separation.


88-108: Consider fixed height for consistent navbar.

Using a fixed height helps maintain a consistent UI. The current implementation aligns with this recommendation.


110-153: Consider adding hover states for footer links.

The footer styles now include hover states with opacity transition, which improves user experience.

docs/docusaurus.config.ts (5)

50-54: Update generic logo alt text.

The logo's alt text is still set to a generic "My Site Logo". This should be updated to reflect the actual site name.


115-128: Update Slack link and add missing footer icon styles.

The Slack link points to GitHub instead of a proper Slack workspace. Additionally, the custom CSS classes for footer icons need to be defined.


132-148: Social media links and icons need attention.

Several issues need to be addressed:

  • Twitter URL returns a 403 (Forbidden)
  • Missing CSS classes for social media icons
  • Instagram URL redirection needs verification

151-160: Confirm the "Development" section aligns with user expectations.

Consider including contributor guides, code of conduct, or other dev resources for completeness.


81-84: 🧹 Nitpick (assertive)

Add target attribute for consistency.

The Demo link should open in a new tab for consistency with other external links.

 {
   label: "Demo",
   position: "left",
   href: "http://admin-demo.talawa.io/",
+  target: "_blank",
 },

Likely invalid or redundant comment.

Comment on lines +19 to +26
.subtitle {
margin-top: 1rem;
max-width: 42rem;
font-size: 1.25rem;
color: #718096;
margin-left: auto;
margin-right: auto;
}
Copy link

Choose a reason for hiding this comment

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

🧹 Nitpick (assertive)

Consider using CSS variables for color consistency.

The subtitle color is defined using a hex value #718096. For better maintainability and theme consistency, consider using a CSS variable.

 .subtitle {
   margin-top: 1rem;
   max-width: 42rem;
   font-size: 1.25rem;
-  color: #718096;
+  color: var(--primary-neutral-600);
   margin-left: auto;
   margin-right: auto;
 }
📝 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
.subtitle {
margin-top: 1rem;
max-width: 42rem;
font-size: 1.25rem;
color: #718096;
margin-left: auto;
margin-right: auto;
}
.subtitle {
margin-top: 1rem;
max-width: 42rem;
font-size: 1.25rem;
color: var(--primary-neutral-600);
margin-left: auto;
margin-right: auto;
}

Comment on lines +155 to +158
.footer__icon {
margin: 0;
color: #fff;
}
Copy link

Choose a reason for hiding this comment

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

🧹 Nitpick (assertive)

Consider enhancing footer icon styles.

The footer icon styles could be improved by:

  • Adding a size constraint for consistency
  • Including spacing between icon and text
  • Ensuring proper vertical alignment
 .footer__icon {
   margin: 0;
   color: #fff;
+  display: inline-flex;
+  align-items: center;
+  gap: 0.5rem;
 }
📝 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
.footer__icon {
margin: 0;
color: #fff;
}
.footer__icon {
margin: 0;
color: #fff;
display: inline-flex;
align-items: center;
gap: 0.5rem;
}

@palisadoes
Copy link
Contributor

Please make sure coderabbit approves your PR

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
ignore-sensitive-files-pr The contributor has a legitimate reason for editiing protected files
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants