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

resource page added with few free resource list issue #226 #231

Merged
merged 8 commits into from
Jul 31, 2024
Merged

Conversation

devvsakib
Copy link
Owner

@devvsakib devvsakib commented Jul 30, 2024

closes #226

Summary by CodeRabbit

Summary by CodeRabbit

  • New Features

    • Introduced a new MainTitle component for dynamic title rendering.
    • Added a ResourceCard component for displaying individual resource information.
    • Launched a new ResourceSection component to organize resources in a grid layout.
    • Created a dedicated Resources page showcasing various web development resources.
    • Added a structured Resources.json for managing educational content.
  • UI/UX Improvements

    • Updated navigation in the header to replace "Contributors" with "Resources".
    • Enhanced typography in the layout using the Poppins font.
    • Improved image responsiveness across the application.
  • Documentation Updates

    • Replaced static title in the documentation page with the new MainTitle component.

Copy link

vercel bot commented Jul 30, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
github-error-solve ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jul 31, 2024 4:41am

@devvsakib devvsakib changed the title resource page added with few free resource list issue $226 resource page added with few free resource list issue #226 Jul 30, 2024
Copy link

coderabbitai bot commented Jul 30, 2024

Caution

Review failed

The pull request is closed.

Walkthrough

The recent updates introduce an array of new components designed to enhance the presentation and accessibility of web development resources. Key additions include the MainTitle, ResourceCard, and ResourceSection components, alongside a structured JSON file for various resources. The navigation has been updated for improved clarity, and the layout has been refined to provide a cohesive user experience, making it easier for users to discover valuable information.

Changes

Files Change Summary
src/components/Common/MainTitle.jsx Introduced MainTitle component for rendering a styled title with an optional highlight.
src/components/Header/Header.jsx Updated navigation by replacing "Contributors" with "Resources," changing the link and icon accordingly.
src/components/Layout/Layout.jsx Modified typography by adding a Poppins font class to a div element.
src/components/Resources/ResourceCard.jsx Introduced ResourceCard component to display resource details with props for index and resource data.
src/components/Resources/ResourceSection.jsx Added ResourceSection component to organize and display multiple ResourceCard components based on an array of resources.
src/data/Resources.json Created a structured JSON repository for learning resources, tools, libraries, and career roadmaps in web development.
src/main.jsx Added a new route for the Resources component and modified the existing contributors route for consistency.
src/pages/Doc/index.jsx Replaced static title with the new MainTitle component within the DocList component.
src/pages/Resources.jsx Introduced Resources component to display resource categories, utilizing ResourceSection for organization and layout enhancements.

Sequence Diagram(s)

sequenceDiagram
    participant User
    participant Header
    participant Resources
    participant ResourceSection
    participant ResourceCard

    User->>Header: Navigate to Resources
    Header->>Resources: Route to Resources page
    Resources->>ResourceSection: Load resource categories
    ResourceSection->>ResourceCard: Generate cards for each resource
    ResourceCard-->>Resources: Display resource details
    Resources-->>User: Render completed resource page
Loading

Assessment against linked issues

Objective Addressed Explanation
Create a dedicated "Resources" page (##226)
Include sections for different types of resources (##226)
Ensure each resource has a description, link, and image (##226)
Maintain responsive design for the new page (##226)
Apply consistent design language across the site (##226)

Poem

🐰 In a land of code, the rabbits play,
With titles bright and resources to sway.
Each card a treasure, each link a guide,
Hopping through knowledge, we take great pride!
A sprinkle of Poppins, a dash of cheer,
Join us, dear friends, the resources are here! 🥕✨


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

@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 UI
Review profile: CHILL

Commits

Files that changed from the base of the PR and between 37ecd7b and 9dc2859.

Files selected for processing (9)
  • src/components/Common/MainTitle.jsx (1 hunks)
  • src/components/Header/Header.jsx (2 hunks)
  • src/components/Layout/Layout.jsx (1 hunks)
  • src/components/Resources/ResourceCard.jsx (1 hunks)
  • src/components/Resources/ResourceSection.jsx (1 hunks)
  • src/data/Resources.json (1 hunks)
  • src/main.jsx (2 hunks)
  • src/pages/Doc/index.jsx (2 hunks)
  • src/pages/Resources.jsx (1 hunks)
Files skipped from review due to trivial changes (1)
  • src/components/Layout/Layout.jsx
Additional context used
Biome
src/components/Resources/ResourceSection.jsx

[error] 8-8: Missing key property for this element in iterable.

The order of the items may change, and having a key can help React identify which item was moved.
Check the React documentation.

(lint/correctness/useJsxKeyInIterable)

src/pages/Doc/index.jsx

[error] 45-45: Missing key property for this element in iterable.

The order of the items may change, and having a key can help React identify which item was moved.
Check the React documentation.

(lint/correctness/useJsxKeyInIterable)

Additional comments not posted (17)
src/components/Common/MainTitle.jsx (1)

1-8: LGTM!

The MainTitle component is well-written and follows best practices for functional components.

src/components/Resources/ResourceCard.jsx (1)

1-27: LGTM!

The ResourceCard component is well-written and follows best practices for functional components.

src/main.jsx (3)

13-13: Approved: Import statement for the Resources component.

The import statement is correct and necessary for the new route.


30-32: Approved: New route for the Resources component.

The new route is correctly configured to use the Resources component.


34-36: Approved: Path change for the Contributors component.

The path change to lowercase is consistent with the routing structure.

src/pages/Resources.jsx (5)

1-1: Approved: Import statement for the Layout component.

The import statement is correct and necessary for the Resources component.


2-2: Approved: Import statement for the Space component from antd.

The import statement is correct and necessary for the Resources component.


3-3: Approved: Import statement for the MainTitle component.

The import statement is correct and necessary for the Resources component.


4-4: Approved: Import statement for the ResourceSection component.

The import statement is correct and necessary for the Resources component.


5-24: Approved: Import statement for the resources data and the Resources component implementation.

The import statement is correct, and the component implementation is consistent and adheres to best practices.

src/pages/Doc/index.jsx (2)

6-6: Approved: Import statement for the MainTitle component.

The import statement is correct and necessary for the DocList component.


41-46: Approved: Usage of MainTitle component.

The usage of the MainTitle component is correct and enhances the flexibility and reusability of the title rendering.

Tools
Biome

[error] 45-45: Missing key property for this element in iterable.

The order of the items may change, and having a key can help React identify which item was moved.
Check the React documentation.

(lint/correctness/useJsxKeyInIterable)

src/components/Header/Header.jsx (2)

7-7: Import statement for MdStore looks good.

The import statement for MdStore is necessary for the new "Resources" navigation item.


40-42: Navigation item changes look good.

The navigation item for "Contributors" has been correctly replaced with "Resources," including updates to the name, link, and icon.

src/data/Resources.json (3)

2-62: Learning resources section looks good.

The entries are well-structured and provide valuable information. Ensure that all links and images are valid and appropriate.


64-124: Tools and libraries section looks good.

The entries are well-structured and provide valuable information. Ensure that all links and images are valid and appropriate.


126-186: Career roadmaps section looks good.

The entries are well-structured and provide valuable information. Ensure that all links and images are valid and appropriate.

Comment on lines 7 to 8
{resources.map((resource, index) => (
<ResourceCard idx={index} resource={resource} />
Copy link

Choose a reason for hiding this comment

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

Add a key property to the ResourceCard component.

The ResourceCard component is missing a key property, which is necessary for React to efficiently update and manage the list of components.

-  <ResourceCard idx={index} resource={resource} />
+  <ResourceCard key={index} idx={index} resource={resource} />
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
{resources.map((resource, index) => (
<ResourceCard idx={index} resource={resource} />
{resources.map((resource, index) => (
<ResourceCard key={index} idx={index} resource={resource} />
Tools
Biome

[error] 8-8: Missing key property for this element in iterable.

The order of the items may change, and having a key can help React identify which item was moved.
Check the React documentation.

(lint/correctness/useJsxKeyInIterable)

@@ -37,12 +38,12 @@ const DocList = () => {
return (
<Layout>
<div className="container mx-auto p-4 min-h-screen">
<h1 className="text-3xl font-bold mb-20 mt-5 text-center">Documentation</h1>
<MainTitle highlight={'Documentation'} />
<ul className='grid gap-5 mx-auto md:max-w-2xl'>
{
docs.map(item =>
<Link to={item.title} className='capitalize group flex items-center justify-between bg-white/10 p-5 rounded-md'>{item.title.replace(/_/g, ' ')}
Copy link

Choose a reason for hiding this comment

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

Add a key property to the list items.

The list items are missing a key property, which can help React identify which item was moved.

-  <Link to={item.title} className='capitalize group flex items-center justify-between bg-white/10 p-5 rounded-md'>{item.title.replace(/_/g, ' ')}
+  <Link key={item.title} to={item.title} className='capitalize group flex items-center justify-between bg-white/10 p-5 rounded-md'>{item.title.replace(/_/g, ' ')}
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
<Link to={item.title} className='capitalize group flex items-center justify-between bg-white/10 p-5 rounded-md'>{item.title.replace(/_/g, ' ')}
<Link key={item.title} to={item.title} className='capitalize group flex items-center justify-between bg-white/10 p-5 rounded-md'>{item.title.replace(/_/g, ' ')}
Tools
Biome

[error] 45-45: Missing key property for this element in iterable.

The order of the items may change, and having a key can help React identify which item was moved.
Check the React documentation.

(lint/correctness/useJsxKeyInIterable)

@devvsakib devvsakib merged commit 7a02263 into main Jul 31, 2024
5 checks passed
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.

create a new page called Resources
1 participant