Skip to content

Conversation

YlanAllouche
Copy link

@YlanAllouche YlanAllouche commented Aug 21, 2025

Add missing projects section support.

Implements the projects section from the JSON Resume schema that was missing from the template.
Tried to match the existing design as much as possible.

Summary by CodeRabbit

  • New Features
    • Added a Projects section to resumes, shown when projects are available. Displays project name (with optional external link that opens in a new tab), organization, date range, website, markdown-formatted description, and a bullet list of highlights.
  • Style
    • Added styling for project entity, date, and website elements and extended layout rules to include the new Projects section for consistent spacing and readability.

@jsonresume jsonresume deleted a comment from coderabbitai bot Aug 21, 2025
Copy link

coderabbitai bot commented Aug 21, 2025

Walkthrough

Adds a conditional Projects section to resume.handlebars that renders project entries (name/link, optional entity, date range via date helper, website, markdown description, and highlights). Updates style.css to add .project_entity, .project_date, .project_website selectors and extend selectors to include #projects and #projects .item. Links open in a new tab.

Changes

Cohort / File(s) Summary of changes
Resume template: Projects section
resume.handlebars
Added a conditional Projects section rendered only when resume.projects.length is truthy; iterates projects and renders name (linked with target="_blank" if url), optional entity, optional date range using startDate/endDate via date helper, optional website with link helper, markdown description, and markdown highlights; uses project-specific CSS classes.
Styles for Projects
style.css
Added selectors .project_entity, .project_date, .project_website (margin-bottom: 10px / width: 30% per change); extended existing selectors to include #projects (e.g., #work, #volunteer#work, #volunteer, #projects and #work .item, #volunteer .item#work .item, #volunteer .item, #projects .item). No existing rules removed.

Sequence Diagram(s)

sequenceDiagram
  autonumber
  actor User
  participant Renderer as Template Renderer
  participant Template as resume.handlebars
  participant CSS as style.css

  User->>Renderer: Render resume with data
  Renderer->>Template: Evaluate template
  alt resume.projects.length > 0
    Template->>Template: Loop over projects
    alt project.url present
      Template-->>User: Render project name as <link target="_blank">
      Template->>CSS: Apply project classes
    else
      Template-->>User: Render project name as plain text
    end
    opt project.entity or dates
      Template-->>User: Render entity and date range (date helper)
      Template->>CSS: Use .project_date / .project_entity spacing
    end
    opt project.website
      Template-->>User: Render project website link
    end
    opt description or highlights
      Template-->>User: Render markdown description and highlights list
    end
  else
    Template-->>User: Skip Projects section
  end
  Renderer-->>User: Return final HTML + CSS
Loading

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~20 minutes

Poem

A rabbit nibbles lines of text,\n> New projects sprout where code connects.\n> Links that open, dates aligned,\n> Markdown tales and highlights mined.\n> Hops of joy — the resume's refined.

Tip

🔌 Remote MCP (Model Context Protocol) integration is now available!

Pro plan users can now connect to remote MCP servers from the Integrations page. Connect with popular remote MCPs such as Notion and Linear to add more context to your reviews and chats.


📜 Recent review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

💡 Knowledge Base configuration:

  • MCP integration is disabled by default for public repositories
  • Jira integration is disabled by default for public repositories
  • Linear integration is disabled by default for public repositories

You can enable these sources in your CodeRabbit configuration.

📥 Commits

Reviewing files that changed from the base of the PR and between f122bb7 and f682e8f.

📒 Files selected for processing (2)
  • resume.handlebars (1 hunks)
  • style.css (2 hunks)
🚧 Files skipped from review as they are similar to previous changes (1)
  • resume.handlebars
🔇 Additional comments (3)
style.css (3)

126-129: Good: Section framing extended to Projects

Adding #projects to the section divider set keeps visual rhythm consistent with Work and Volunteer. LGTM.


133-136: Good: Item spacing parity for Projects

Including #projects .item in the margin rules aligns spacing across sections. LGTM.


85-90: Add missing .project_website class or override selector

The .project_website { width: 30%; } rule never applies—resume.handlebars doesn’t output that class—so the later .website { width: 50%; } always wins. To fix, either:

  • Add class="project_website" to the project link markup and, after the generic rule, include:
    .project_website { width: 30%; }
  • Or override within the projects container by placing below the .website block:
    #projects .website { width: 30%; }
✨ Finishing Touches
🧪 Generate unit tests
  • 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
🪧 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.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbit in a new review comment at the desired location with your query.
  • PR comments: Tag @coderabbit 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:
    • @coderabbit gather interesting stats about this repository and render them as a table. Additionally, render a pie chart showing the language distribution in the codebase.
    • @coderabbit read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.

Support

Need help? Create a ticket on our support page for assistance with any issues or questions.

CodeRabbit Commands (Invoked using PR/Issue comments)

Type @coderabbit help to get the list of available commands.

Other keywords and placeholders

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

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

Status, Documentation and Community

  • Visit our Status Page to check the current availability of CodeRabbit.
  • 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: 1

🧹 Nitpick comments (3)
style.css (1)

85-87: Align project_date layout with existing split column rules (use width/margin-bottom instead of margin-right).

Other sections (.work_date, .study_date, etc.) use width: 30% + margin-bottom for consistent multi-column layout inside .split. Using only margin-right for .project_date can cause misalignment/wrapping in narrow viewports.

Apply this minimal change to match existing layout conventions:

 .project_date {
-  margin-right: 2em;
+  margin-bottom: 10px;
+  width: 30%;
 }

Additionally, to keep the three project columns aligned like work/education, consider adding matching rules for the sibling elements:

/* New — mirrors .work_* layout */
.project_entity,
.project_date,
.project_website {
  margin-bottom: 10px;
  width: 30%;
}

And for visual consistency with Work/Volunteer sections, optionally add:

/* New — optional consistency with #work/#volunteer */
#projects {
  padding-bottom: 5px;
  border-bottom: 1px var(--separator-color) solid;
}
#projects .item {
  margin: 25px 0;
}
resume.handlebars (2)

254-258: Render dates without a dangling hyphen when endDate is missing.

This mirrors the Work section’s current approach but still yields “start - ” when endDate is absent. Simple guard avoids that.

-        {{#if startDate}}
-        {{{date startDate}}} - {{{date endDate}}}
-        {{/if}}
+        {{#if startDate}}
+          {{#if endDate}}
+            {{{date startDate}}} - {{{date endDate}}}
+          {{else}}
+            {{{date startDate}}}
+          {{/if}}
+        {{/if}}

247-253: Optional: Support more JSON Resume fields (roles/type) if present.

The schema allows roles (array) and type; rendering them improves fidelity without impacting existing resumes.

Example insertion near entity:

{{#if roles.length}}
  <div class="project_roles">
    {{#each roles}}
      <span class="role">{{.}}{{#unless @last}}, {{/unless}}</span>
    {{/each}}
  </div>
{{/if}}
{{#if type}}
  <div class="project_type"><em>{{type}}</em></div>
{{/if}}

I can send a follow-up patch including minimal CSS for .project_roles/.project_type if you’d like.

📜 Review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

💡 Knowledge Base configuration:

  • MCP integration is disabled by default for public repositories
  • Jira integration is disabled by default for public repositories
  • Linear integration is disabled by default for public repositories

You can enable these sources in your CodeRabbit configuration.

📥 Commits

Reviewing files that changed from the base of the PR and between b7cc0ad and f122bb7.

📒 Files selected for processing (2)
  • resume.handlebars (1 hunks)
  • style.css (1 hunks)
🔇 Additional comments (2)
resume.handlebars (2)

232-283: Overall: Nice, schema-aligned Projects section with consistent conditional rendering.

Good use of existing helpers (date, link, markdown) and class naming mirrors other sections. Once the small issues above are addressed, this will fit cleanly into the template.


239-244: Avoid duplicating the project link

Lines 239–244 and 260–264 in resume.handlebars render both a clickable project title and a separate website link. This is inconsistent with the Work/Volunteer sections, which render only one link. Choose one of the following patterns for consistency:

Option A — keep the title plain and show the link only in the project_website block (matches Work/Volunteer):

-        {{#if url}}
-        <a href="{{url}}" target="_blank">{{name}}</a>
-        {{else}}
-        {{name}}
-        {{/if}}
+        {{name}}

Option B — make the title itself the link and drop the separate project_website block:

-      {{#if url}}
-      <div class="project_website">
-        {{{link url}}}
-      </div>
-      {{/if}}
+      {{!-- website link omitted because title is already the link --}}

Or, if the {{{link}}} helper supports custom link text:

<h3 class="project_name">
  {{#if url}}
    {{{link url name}}}
  {{else}}
    {{name}}
  {{/if}}
</h3>

I wasn’t able to locate the implementation of the {{{link}}} helper in the codebase to confirm whether it already adds target="_blank" and rel="noopener noreferrer". If you choose Option B, please verify that helper emits the necessary attributes for external links.

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