Move portfolio case studies to data-driven template system and archive old individual files

This commit is contained in:
Ovidiu U
2026-03-15 18:04:56 +00:00
parent ac917dbc0a
commit 28cd60a427
21 changed files with 1789 additions and 1188 deletions

View File

@@ -3,13 +3,8 @@
/*
* Case Study Header Partial
* ─────────────────────────────────────────────────────────────────
* Requires the following variables set by the calling page BEFORE
* requiring this file:
*
* Requires the following variable set by the calling page:
* $cs_slug string Key into $projects, e.g. 'thompson'
*
* Everything else ($title, $description, hero content) is read from
* $projects[$cs_slug] in data/projects.php.
* ─────────────────────────────────────────────────────────────────
*/
@@ -18,21 +13,42 @@ require __DIR__ . '/../data/projects.php';
$p = $projects[$cs_slug];
$title = $p['page_title'];
$description = $p['page_desc'];
$nav_back = ['url' => '/portfolio', 'label' => '← Portfolio'];
//$nav_cta = ['url' => 'https://' . $p['domain'], 'label' => 'Visit Site →'];
require __DIR__ . '/header.php';
?>
<div class="cs-breadcrumb">
<a href="/portfolio" class="cs-back">← All Work</a>
<span class="cs-breadcrumb-label">[<?= htmlspecialchars($p['num']) ?> / <?= htmlspecialchars($p['code']) ?>]</span>
</div>
<header class="hero">
<div class="section-label">Case Study — <?= htmlspecialchars($p['num']) ?></div>
<h1><?= htmlspecialchars($p['h1'][0]) ?><br><span class="h1-sub"><?= htmlspecialchars($p['h1'][1]) ?></span></h1>
<p class="hero-sub"><?= htmlspecialchars($p['sub']) ?></p>
<ul class="cs-meta-bar">
<li><?= htmlspecialchars($p['stack']) ?></li>
<li><?= htmlspecialchars($p['location']) ?></li>
<li><?= htmlspecialchars($p['year']) ?></li>
</ul>
<header class="hero hero--cs">
<div class="hero-content">
<div class="hero-divider"></div>
<div class="hero-meta-row">
<div class="hero-meta">
<span><?php echo htmlspecialchars($p['num']); ?> / WEB_DEV · <?php echo htmlspecialchars($p['year']); ?></span>
<span><?php echo htmlspecialchars($p['location']); ?></span>
</div>
</div>
<h1 class="hero-headline">
<span class="line1"><?php echo htmlspecialchars($p['h1'][0]); ?></span>
<span class="line2"><?php echo htmlspecialchars($p['h1'][1]); ?></span>
</h1>
</div>
</header>
<div class="meta-bar">
<div class="meta-col">
<span class="meta-col-label">Client</span>
<span class="meta-col-value"><?php echo htmlspecialchars($p['title']); ?></span>
</div>
<div class="meta-col">
<span class="meta-col-label">Year</span>
<span class="meta-col-value"><?php echo htmlspecialchars($p['year']); ?></span>
</div>
<div class="meta-col">
<span class="meta-col-label">Stack</span>
<span class="meta-col-value"><?php echo htmlspecialchars($p['stack']); ?></span>
</div>
<div class="meta-col">
<span class="meta-col-label">Location</span>
<span class="meta-col-value"><?php echo htmlspecialchars($p['location']); ?></span>
</div>
</div>