1 GitHub star = 1 new component.

Developer Portfolio

Dev Project Detail

Project case study: overview, challenge, solution and highlights next to a sticky spec sheet (role, year, status, stack, metrics, links), with previous / next keys.

case-studyprojectspec-sheetportfolio
Live Preview

Overview

A cross-platform CLI that finds and safely removes stale build caches, node_modules and Docker layers, with a dry run and an undo log.

The challenge

Developer machines quietly fill up with caches from a dozen tools, and cleaning them by hand is risky.

The solution

A rule-based scanner that knows where each tool keeps its caches and moves files to a recoverable trash first.

Highlights

  • Rules for 30+ tools
  • Dry run with sizes and last access
  • Undo log for every removal

Usage

Copy and paste this code into your Astro page:

astro
---
import { DevProjectDetail } from 'astro-component-kit/sections';
---

<DevProjectDetail project={{ title: 'Tidy', description: 'Frees disk space.', technologies: ['Rust'], role: 'Author', year: '2025' }} />
--- import { DevProjectDetail } from 'astro-component-kit/sections'; --- <DevProjectDetail project={{ title: 'Tidy', description: 'Frees disk space.', technologies: ['Rust'], role: 'Author', year: '2025' }} />

Examples in context

Real code from the kit: how this piece is used inside templates, sections and other components.

Template Developer Portfolio PortfolioProjectPage.astro
astro
<DevProjectDetail
  project={project}
  prev={prev && { title: prev.title, href: portfolioProjectHref(routes, prev.slug) }}
  next={next && { title: next.title, href: portfolioProjectHref(routes, next.slug) }}
/>
<DevProjectDetail project={project} prev={prev && { title: prev.title, href: portfolioProjectHref(routes, prev.slug) }} next={next && { title: next.title, href: portfolioProjectHref(routes, next.slug) }} />

Used in

Works well with

Manual Installation

If you are not using the npm package, create a new file and paste the following code: src/components/sections/DevProjectDetail.astro:

astro
---
/**
 * DevProjectDetail — Project case study for developer portfolios ("Keycap" design): a long-form
 * column (overview, challenge, solution, features) next to a sticky "spec sheet" with role, year,
 * status, stack, metrics and links, followed by previous / next project keys.
 *
 * @param {object} project - { title, description, challenge?, solution?, features?: string[], role?, year?, status?, technologies[], metrics?: [{value, label}], liveUrl?, repoUrl?, stars? }
 * @param {{title: string, href: string}} prev - Previous project link.
 * @param {{title: string, href: string}} next - Next project link.
 * @param {object} labels - { overview, challenge, solution, features, spec, role, year, status, stack, live, code, prev, next }.
 * @param {string} className - Extra class.
 *
 * Accessibility: headings structure the long-form column; the spec sheet is an aside with a
 * definition list; prev/next is a labelled nav.
 */
interface Props {
  project?: {
    title: string;
    description: string;
    challenge?: string;
    solution?: string;
    features?: string[];
    role?: string;
    year?: string;
    status?: string;
    technologies: string[];
    metrics?: Array<{ value: string; label: string }>;
    liveUrl?: string;
    repoUrl?: string;
    stars?: number;
  };
  prev?: { title: string; href: string };
  next?: { title: string; href: string };
  labels?: Partial<Record<'overview' | 'challenge' | 'solution' | 'features' | 'spec' | 'role' | 'year' | 'status' | 'stack' | 'live' | 'code' | 'prev' | 'next', string>>;
  className?: string;
}

const {
  project: p = {
    title: 'Tidy',
    description: 'A cross-platform CLI that finds and safely removes stale build caches, node_modules and Docker layers, with a dry run and an undo log.',
    challenge: 'Developer machines quietly fill up with caches from a dozen tools, and cleaning them by hand is risky.',
    solution: 'A rule-based scanner that knows where each tool keeps its caches and moves files to a recoverable trash first.',
    features: ['Rules for 30+ tools', 'Dry run with sizes and last access', 'Undo log for every removal'],
    role: 'Author', year: '2025', status: 'Live', stars: 486,
    technologies: ['Rust', 'CLI', 'Docker'],
    metrics: [{ value: '12 GB', label: 'freed on average' }, { value: '3', label: 'platforms' }, { value: '<1s', label: 'scan' }],
    repoUrl: '#',
  },
  prev,
  next,
  labels = {},
  className = '',
} = Astro.props;
const L = {
  overview: 'Overview', challenge: 'The challenge', solution: 'The solution', features: 'Highlights', spec: 'SPEC_SHEET',
  role: 'Role', year: 'Year', status: 'Status', stack: 'Stack', live: 'Visit live site', code: 'Source code', prev: 'Previous', next: 'Next',
  ...labels,
};
---

<section class:list={['dvpd', className]}>
  <div class="dvpd__wrap">
    <article class="dvpd__body">
      <h2>{L.overview}</h2>
      <p class="dvpd__lead">{p.description}</p>
      {p.challenge && (<><h2>{L.challenge}</h2><p>{p.challenge}</p></>)}
      {p.solution && (<><h2>{L.solution}</h2><p>{p.solution}</p></>)}
      {p.features && p.features.length > 0 && (
        <>
          <h2>{L.features}</h2>
          <ul class="dvpd__features">{p.features.map((f, i) => <li><span aria-hidden="true">{String(i + 1).padStart(2, '0')}</span>{f}</li>)}</ul>
        </>
      )}
    </article>

    <aside class="dvpd__spec" aria-label={L.spec}>
      <p class="dvpd__spec-head"><b>[</b>{` ${L.spec} `}<b>]</b></p>
      <dl>
        {p.role && <div><dt>{L.role}</dt><dd>{p.role}</dd></div>}
        {p.year && <div><dt>{L.year}</dt><dd>{p.year}</dd></div>}
        {p.status && <div><dt>{L.status}</dt><dd>{p.status}</dd></div>}
        {!!p.stars && <div><dt>GitHub</dt><dd>★ {p.stars.toLocaleString('en')}</dd></div>}
      </dl>
      <p class="dvpd__label">{L.stack}</p>
      <ul class="dvpd__chips">{p.technologies.map((t) => <li>{t}</li>)}</ul>
      {p.metrics && p.metrics.length > 0 && (
        <ul class="dvpd__metrics">{p.metrics.map((m) => <li><strong>{m.value}</strong><span>{m.label}</span></li>)}</ul>
      )}
      <div class="dvpd__links">
        {p.liveUrl && <a class="dvpd__btn dvpd__btn--primary" href={p.liveUrl} target="_blank" rel="noopener noreferrer">{L.live} ↗</a>}
        {p.repoUrl && <a class="dvpd__btn" href={p.repoUrl} target="_blank" rel="noopener noreferrer">{L.code} ↗</a>}
      </div>
    </aside>
  </div>

  {(prev || next) && (
    <nav class="dvpd__pager" aria-label="More projects">
      {prev ? <a class="dvpd__key" href={prev.href} rel="prev"><span>← {L.prev}</span><strong>{prev.title}</strong></a> : <span></span>}
      {next && <a class="dvpd__key dvpd__key--next" href={next.href} rel="next"><span>{L.next} →</span><strong>{next.title}</strong></a>}
    </nav>
  )}
</section>

<style>
  .dvpd { padding: 0 0 clamp(3rem, 7vw, 5rem); color: var(--c-text-1); }
  .dvpd__wrap { max-width: 1040px; margin: 0 auto; padding: 0 clamp(1rem, 3vw, 1.5rem); display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: clamp(2rem, 5vw, 4rem); align-items: start; }
  .dvpd__body h2 { margin: 2.25rem 0 0.75rem; font-family: var(--font-mono); font-size: 0.78rem; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--c-text-3); }
  .dvpd__body h2:first-child { margin-top: 0; }
  .dvpd__body p { margin: 0; font-size: 1.02rem; line-height: 1.8; color: var(--c-text-2); }
  .dvpd__body .dvpd__lead { font-size: 1.2rem; line-height: 1.65; color: var(--c-text-1); }
  .dvpd__features { display: grid; gap: 0.6rem; margin: 0; padding: 0; list-style: none; }
  .dvpd__features li { display: flex; gap: 0.85rem; align-items: baseline; padding: 0.85rem 1rem; border: 1px solid var(--c-border); border-radius: 4px; font-size: 0.95rem; line-height: 1.55; }
  .dvpd__features span { font-family: var(--font-mono); font-size: 0.7rem; font-weight: 700; color: var(--c-text-3); }

  .dvpd__spec { position: sticky; top: 6rem; padding: 1.5rem; border: 2px solid var(--c-text-1); border-radius: 4px; background: var(--c-bg); box-shadow: 6px 6px 0 var(--c-text-1); }
  .dvpd__spec-head { margin: 0 0 1rem; font-family: var(--font-mono); font-size: 0.72rem; letter-spacing: 0.08em; color: var(--c-text-3); }
  .dvpd__spec-head b { color: var(--c-text-1); }
  .dvpd__spec dl { margin: 0 0 1.25rem; }
  .dvpd__spec dl div { display: flex; justify-content: space-between; gap: 1rem; padding: 0.55rem 0; border-bottom: 1px dashed rgb(var(--ink-rgb, 0 0 0) / 0.15); }
  .dvpd__spec dt { font-family: var(--font-mono); font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.05em; color: var(--c-text-3); }
  .dvpd__spec dd { margin: 0; font-size: 0.88rem; font-weight: 600; text-align: right; }
  .dvpd__label { margin: 0 0 0.5rem; font-family: var(--font-mono); font-size: 0.68rem; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--c-text-3); }
  .dvpd__chips { display: flex; flex-wrap: wrap; gap: 0.4rem; margin: 0 0 1.25rem; padding: 0; list-style: none; }
  .dvpd__chips li { padding: 0.3rem 0.6rem; border: 1.5px solid var(--c-text-1); border-radius: 2px; font-family: var(--font-mono); font-size: 0.7rem; font-weight: 600; }
  .dvpd__metrics { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0.5rem; margin: 0 0 1.25rem; padding: 0; list-style: none; }
  .dvpd__metrics li { display: flex; flex-direction: column; gap: 0.15rem; padding: 0.6rem 0.5rem; border-radius: 4px; background: rgb(var(--ink-rgb, 0 0 0) / 0.04); text-align: center; }
  .dvpd__metrics strong { font-size: 1rem; font-weight: 800; letter-spacing: -0.02em; }
  .dvpd__metrics span { font-family: var(--font-mono); font-size: 0.6rem; line-height: 1.3; color: var(--c-text-3); }
  .dvpd__links { display: grid; gap: 0.6rem; }
  .dvpd__btn { display: inline-flex; align-items: center; justify-content: center; min-height: 44px; border: 1.5px solid var(--c-text-1); border-radius: 2px; color: var(--c-text-1); font-family: var(--font-mono); font-size: 0.82rem; font-weight: 700; text-decoration: none; box-shadow: 2px 2px 0 var(--c-text-1); transition: transform 0.15s ease, box-shadow 0.15s ease; }
  .dvpd__btn:hover { transform: translateY(-1px); box-shadow: 3px 3px 0 var(--c-text-1); }
  .dvpd__btn--primary { background: var(--c-text-1); color: var(--c-bg); }

  .dvpd__pager { max-width: 1040px; margin: clamp(3rem, 6vw, 4.5rem) auto 0; padding: 0 clamp(1rem, 3vw, 1.5rem); display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
  .dvpd__key { display: flex; flex-direction: column; gap: 0.3rem; padding: 1.1rem 1.25rem; border: 1.5px solid var(--c-text-1); border-radius: 4px; color: var(--c-text-1); text-decoration: none; box-shadow: 0 4px 0 var(--c-text-1); transition: transform 0.18s ease, box-shadow 0.18s ease; }
  .dvpd__key:hover { transform: translateY(2px); box-shadow: 0 2px 0 var(--c-text-1); }
  .dvpd__key span { font-family: var(--font-mono); font-size: 0.7rem; text-transform: uppercase; letter-spacing: 0.06em; color: var(--c-text-3); }
  .dvpd__key strong { font-size: 1.1rem; }
  .dvpd__key--next { text-align: right; grid-column: 2; }
  .dvpd :focus-visible { outline: 2px solid var(--c-text-1); outline-offset: 3px; }
  @media (max-width: 860px) {
    .dvpd__wrap { grid-template-columns: 1fr; }
    .dvpd__spec { position: static; }
  }
  @media (max-width: 560px) { .dvpd__pager { grid-template-columns: 1fr; } .dvpd__key--next { grid-column: auto; } }
</style>
--- /** * DevProjectDetail — Project case study for developer portfolios ("Keycap" design): a long-form * column (overview, challenge, solution, features) next to a sticky "spec sheet" with role, year, * status, stack, metrics and links, followed by previous / next project keys. * * @param {object} project - { title, description, challenge?, solution?, features?: string[], role?, year?, status?, technologies[], metrics?: [{value, label}], liveUrl?, repoUrl?, stars? } * @param {{title: string, href: string}} prev - Previous project link. * @param {{title: string, href: string}} next - Next project link. * @param {object} labels - { overview, challenge, solution, features, spec, role, year, status, stack, live, code, prev, next }. * @param {string} className - Extra class. * * Accessibility: headings structure the long-form column; the spec sheet is an aside with a * definition list; prev/next is a labelled nav. */ interface Props { project?: { title: string; description: string; challenge?: string; solution?: string; features?: string[]; role?: string; year?: string; status?: string; technologies: string[]; metrics?: Array<{ value: string; label: string }>; liveUrl?: string; repoUrl?: string; stars?: number; }; prev?: { title: string; href: string }; next?: { title: string; href: string }; labels?: Partial<Record<'overview' | 'challenge' | 'solution' | 'features' | 'spec' | 'role' | 'year' | 'status' | 'stack' | 'live' | 'code' | 'prev' | 'next', string>>; className?: string; } const { project: p = { title: 'Tidy', description: 'A cross-platform CLI that finds and safely removes stale build caches, node_modules and Docker layers, with a dry run and an undo log.', challenge: 'Developer machines quietly fill up with caches from a dozen tools, and cleaning them by hand is risky.', solution: 'A rule-based scanner that knows where each tool keeps its caches and moves files to a recoverable trash first.', features: ['Rules for 30+ tools', 'Dry run with sizes and last access', 'Undo log for every removal'], role: 'Author', year: '2025', status: 'Live', stars: 486, technologies: ['Rust', 'CLI', 'Docker'], metrics: [{ value: '12 GB', label: 'freed on average' }, { value: '3', label: 'platforms' }, { value: '<1s', label: 'scan' }], repoUrl: '#', }, prev, next, labels = {}, className = '', } = Astro.props; const L = { overview: 'Overview', challenge: 'The challenge', solution: 'The solution', features: 'Highlights', spec: 'SPEC_SHEET', role: 'Role', year: 'Year', status: 'Status', stack: 'Stack', live: 'Visit live site', code: 'Source code', prev: 'Previous', next: 'Next', ...labels, }; --- <section class:list={['dvpd', className]}> <div class="dvpd__wrap"> <article class="dvpd__body"> <h2>{L.overview}</h2> <p class="dvpd__lead">{p.description}</p> {p.challenge && (<><h2>{L.challenge}</h2><p>{p.challenge}</p></>)} {p.solution && (<><h2>{L.solution}</h2><p>{p.solution}</p></>)} {p.features && p.features.length > 0 && ( <> <h2>{L.features}</h2> <ul class="dvpd__features">{p.features.map((f, i) => <li><span aria-hidden="true">{String(i + 1).padStart(2, '0')}</span>{f}</li>)}</ul> </> )} </article> <aside class="dvpd__spec" aria-label={L.spec}> <p class="dvpd__spec-head"><b>[</b>{` ${L.spec} `}<b>]</b></p> <dl> {p.role && <div><dt>{L.role}</dt><dd>{p.role}</dd></div>} {p.year && <div><dt>{L.year}</dt><dd>{p.year}</dd></div>} {p.status && <div><dt>{L.status}</dt><dd>{p.status}</dd></div>} {!!p.stars && <div><dt>GitHub</dt><dd>★ {p.stars.toLocaleString('en')}</dd></div>} </dl> <p class="dvpd__label">{L.stack}</p> <ul class="dvpd__chips">{p.technologies.map((t) => <li>{t}</li>)}</ul> {p.metrics && p.metrics.length > 0 && ( <ul class="dvpd__metrics">{p.metrics.map((m) => <li><strong>{m.value}</strong><span>{m.label}</span></li>)}</ul> )} <div class="dvpd__links"> {p.liveUrl && <a class="dvpd__btn dvpd__btn--primary" href={p.liveUrl} target="_blank" rel="noopener noreferrer">{L.live} ↗</a>} {p.repoUrl && <a class="dvpd__btn" href={p.repoUrl} target="_blank" rel="noopener noreferrer">{L.code} ↗</a>} </div> </aside> </div> {(prev || next) && ( <nav class="dvpd__pager" aria-label="More projects"> {prev ? <a class="dvpd__key" href={prev.href} rel="prev"><span>← {L.prev}</span><strong>{prev.title}</strong></a> : <span></span>} {next && <a class="dvpd__key dvpd__key--next" href={next.href} rel="next"><span>{L.next} →</span><strong>{next.title}</strong></a>} </nav> )} </section> <style> .dvpd { padding: 0 0 clamp(3rem, 7vw, 5rem); color: var(--c-text-1); } .dvpd__wrap { max-width: 1040px; margin: 0 auto; padding: 0 clamp(1rem, 3vw, 1.5rem); display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: clamp(2rem, 5vw, 4rem); align-items: start; } .dvpd__body h2 { margin: 2.25rem 0 0.75rem; font-family: var(--font-mono); font-size: 0.78rem; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--c-text-3); } .dvpd__body h2:first-child { margin-top: 0; } .dvpd__body p { margin: 0; font-size: 1.02rem; line-height: 1.8; color: var(--c-text-2); } .dvpd__body .dvpd__lead { font-size: 1.2rem; line-height: 1.65; color: var(--c-text-1); } .dvpd__features { display: grid; gap: 0.6rem; margin: 0; padding: 0; list-style: none; } .dvpd__features li { display: flex; gap: 0.85rem; align-items: baseline; padding: 0.85rem 1rem; border: 1px solid var(--c-border); border-radius: 4px; font-size: 0.95rem; line-height: 1.55; } .dvpd__features span { font-family: var(--font-mono); font-size: 0.7rem; font-weight: 700; color: var(--c-text-3); } .dvpd__spec { position: sticky; top: 6rem; padding: 1.5rem; border: 2px solid var(--c-text-1); border-radius: 4px; background: var(--c-bg); box-shadow: 6px 6px 0 var(--c-text-1); } .dvpd__spec-head { margin: 0 0 1rem; font-family: var(--font-mono); font-size: 0.72rem; letter-spacing: 0.08em; color: var(--c-text-3); } .dvpd__spec-head b { color: var(--c-text-1); } .dvpd__spec dl { margin: 0 0 1.25rem; } .dvpd__spec dl div { display: flex; justify-content: space-between; gap: 1rem; padding: 0.55rem 0; border-bottom: 1px dashed rgb(var(--ink-rgb, 0 0 0) / 0.15); } .dvpd__spec dt { font-family: var(--font-mono); font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.05em; color: var(--c-text-3); } .dvpd__spec dd { margin: 0; font-size: 0.88rem; font-weight: 600; text-align: right; } .dvpd__label { margin: 0 0 0.5rem; font-family: var(--font-mono); font-size: 0.68rem; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--c-text-3); } .dvpd__chips { display: flex; flex-wrap: wrap; gap: 0.4rem; margin: 0 0 1.25rem; padding: 0; list-style: none; } .dvpd__chips li { padding: 0.3rem 0.6rem; border: 1.5px solid var(--c-text-1); border-radius: 2px; font-family: var(--font-mono); font-size: 0.7rem; font-weight: 600; } .dvpd__metrics { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0.5rem; margin: 0 0 1.25rem; padding: 0; list-style: none; } .dvpd__metrics li { display: flex; flex-direction: column; gap: 0.15rem; padding: 0.6rem 0.5rem; border-radius: 4px; background: rgb(var(--ink-rgb, 0 0 0) / 0.04); text-align: center; } .dvpd__metrics strong { font-size: 1rem; font-weight: 800; letter-spacing: -0.02em; } .dvpd__metrics span { font-family: var(--font-mono); font-size: 0.6rem; line-height: 1.3; color: var(--c-text-3); } .dvpd__links { display: grid; gap: 0.6rem; } .dvpd__btn { display: inline-flex; align-items: center; justify-content: center; min-height: 44px; border: 1.5px solid var(--c-text-1); border-radius: 2px; color: var(--c-text-1); font-family: var(--font-mono); font-size: 0.82rem; font-weight: 700; text-decoration: none; box-shadow: 2px 2px 0 var(--c-text-1); transition: transform 0.15s ease, box-shadow 0.15s ease; } .dvpd__btn:hover { transform: translateY(-1px); box-shadow: 3px 3px 0 var(--c-text-1); } .dvpd__btn--primary { background: var(--c-text-1); color: var(--c-bg); } .dvpd__pager { max-width: 1040px; margin: clamp(3rem, 6vw, 4.5rem) auto 0; padding: 0 clamp(1rem, 3vw, 1.5rem); display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; } .dvpd__key { display: flex; flex-direction: column; gap: 0.3rem; padding: 1.1rem 1.25rem; border: 1.5px solid var(--c-text-1); border-radius: 4px; color: var(--c-text-1); text-decoration: none; box-shadow: 0 4px 0 var(--c-text-1); transition: transform 0.18s ease, box-shadow 0.18s ease; } .dvpd__key:hover { transform: translateY(2px); box-shadow: 0 2px 0 var(--c-text-1); } .dvpd__key span { font-family: var(--font-mono); font-size: 0.7rem; text-transform: uppercase; letter-spacing: 0.06em; color: var(--c-text-3); } .dvpd__key strong { font-size: 1.1rem; } .dvpd__key--next { text-align: right; grid-column: 2; } .dvpd :focus-visible { outline: 2px solid var(--c-text-1); outline-offset: 3px; } @media (max-width: 860px) { .dvpd__wrap { grid-template-columns: 1fr; } .dvpd__spec { position: static; } } @media (max-width: 560px) { .dvpd__pager { grid-template-columns: 1fr; } .dvpd__key--next { grid-column: auto; } } </style>
Part of a complete template

This section was crafted as a core block for the following template. You can preview the full interactive multi-page experience or explore all related components.

Full templates 6 pages · 15 components

Developer Portfolio

A monochrome, keyboard-inspired portfolio with 3D projects, a typing keyboard and a contribution matrix of flying cubes.

More Sections to Explore

Discover other full-width landing blocks and production-ready sections from our library.

All sections