Downloaded theme
This commit is contained in:
46
themes/minimal-black/layouts/partials/analytics.html
Normal file
46
themes/minimal-black/layouts/partials/analytics.html
Normal file
@@ -0,0 +1,46 @@
|
||||
{{- if not hugo.IsServer -}}
|
||||
|
||||
<!-- Google Analytics (GA4) -->
|
||||
{{ with .Site.Params.analytics.googleAnalytics }}
|
||||
{{ if . }}
|
||||
<script async src="https://www.googletagmanager.com/gtag/js?id={{ . }}"></script>
|
||||
<script>
|
||||
window.dataLayer = window.dataLayer || [];
|
||||
function gtag(){dataLayer.push(arguments);}
|
||||
gtag('js', new Date());
|
||||
gtag('config', '{{ . }}');
|
||||
</script>
|
||||
{{ end }}
|
||||
{{ end }}
|
||||
|
||||
<!-- Plausible Analytics -->
|
||||
{{ with .Site.Params.analytics.plausible }}
|
||||
{{ if .enabled }}
|
||||
<script defer data-domain="{{ .domain }}" src="{{ default "https://plausible.io/js/script.js" .scriptUrl }}"></script>
|
||||
{{ end }}
|
||||
{{ end }}
|
||||
|
||||
<!-- Umami Analytics -->
|
||||
{{ with .Site.Params.analytics.umami }}
|
||||
{{ if .enabled }}
|
||||
<script defer src="{{ .scriptUrl }}" data-website-id="{{ .websiteId }}"></script>
|
||||
{{ end }}
|
||||
{{ end }}
|
||||
|
||||
<!-- Fathom Analytics -->
|
||||
{{ with .Site.Params.analytics.fathom }}
|
||||
{{ if .enabled }}
|
||||
<script src="{{ .scriptUrl }}" data-site="{{ .siteId }}" defer></script>
|
||||
{{ end }}
|
||||
{{ end }}
|
||||
|
||||
<!-- Custom Analytics Scripts -->
|
||||
{{ with .Site.Params.analytics.custom }}
|
||||
{{ if .head }}
|
||||
{{ range .head }}
|
||||
{{ . | safeHTML }}
|
||||
{{ end }}
|
||||
{{ end }}
|
||||
{{ end }}
|
||||
|
||||
{{- end -}}
|
||||
@@ -0,0 +1,53 @@
|
||||
{{/* props: Page (post page) */}}
|
||||
{{- $p := .Page -}}
|
||||
{{- $icon := $p.Params.icon | default "fa-regular fa-file-lines" -}}
|
||||
{{- $category := $p.Params.category | default "Article" -}}
|
||||
|
||||
<article class="card card-pad card-home card-home--post group">
|
||||
<a href="{{ $p.RelPermalink }}" class="card-home-body">
|
||||
<div class="card-home-header">
|
||||
<div class="card-home-icon card-home-icon--post">
|
||||
<i class="{{ $icon }}"></i>
|
||||
</div>
|
||||
|
||||
<div class="min-w-0">
|
||||
<div class="flex items-start justify-between gap-2">
|
||||
<div class="min-w-0">
|
||||
<h3 class="truncate text-sm font-semibold tracking-tight group-hover:text-accent">
|
||||
{{ $p.Title }}
|
||||
</h3>
|
||||
|
||||
<div class="mt-0.5 flex flex-wrap items-center gap-2 text-[0.68rem] text-muted">
|
||||
{{ with $p.Date }}
|
||||
<span>{{ .Format "02 Jan 2006" }}</span>
|
||||
{{ end }}
|
||||
{{ with $p.ReadingTime }}
|
||||
<span>• {{ . }} min read</span>
|
||||
{{ end }}
|
||||
</div>
|
||||
</div>
|
||||
|
||||
{{ with $category }}
|
||||
<span class="card-badge card-badge--soft">
|
||||
{{ . }}
|
||||
</span>
|
||||
{{ end }}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
{{ with $p.Params.description }}
|
||||
<p class="mt-2 text-xs text-muted">
|
||||
{{ . }}
|
||||
</p>
|
||||
{{ end }}
|
||||
|
||||
{{ with $p.Params.tags }}
|
||||
<div class="mt-3 card-tag-row">
|
||||
{{ range first 3 . }}
|
||||
<span class="card-tag-pill">{{ . }}</span>
|
||||
{{ end }}
|
||||
</div>
|
||||
{{ end }}
|
||||
</a>
|
||||
</article>
|
||||
@@ -0,0 +1,87 @@
|
||||
{{/* props: Page (project page) */}}
|
||||
{{- $p := .Page -}}
|
||||
|
||||
{{- $icon := $p.Params.icon | default "fa-solid fa-folder-tree" -}}
|
||||
{{- $badge := cond ($p.Params.featured) "Featured" "" -}}
|
||||
|
||||
{{- $repo := $p.Params.repo -}}
|
||||
{{- $repoIcon := $p.Params.repoIcon | default "fa-brands fa-github" -}}
|
||||
{{- $repoLabel := $p.Params.repoLabel | default "Repo" -}}
|
||||
|
||||
{{- $demo := $p.Params.demo -}}
|
||||
{{- $demoIcon := $p.Params.demoIcon | default "fa-solid fa-play" -}}
|
||||
{{- $demoLabel := $p.Params.demoLabel | default "Demo" -}}
|
||||
|
||||
{{- $website := $p.Params.website -}}
|
||||
{{- $websiteIcon := $p.Params.websiteIcon | default "fa-solid fa-globe" -}}
|
||||
{{- $websiteLabel := $p.Params.websiteLabel | default "Website" -}}
|
||||
|
||||
<article class="card card-pad card-home card-home--project group">
|
||||
<!-- Entire main body is clickable -->
|
||||
<a href="{{ $p.RelPermalink }}" class="card-home-body">
|
||||
<div class="card-home-header">
|
||||
<div class="card-home-icon">
|
||||
<i class="{{ $icon }}"></i>
|
||||
</div>
|
||||
|
||||
<div class="min-w-0">
|
||||
<div class="inline-flex items-center gap-1">
|
||||
<h3 class="truncate text-sm font-semibold tracking-tight group-hover:text-accent">
|
||||
{{ $p.Title }}
|
||||
</h3>
|
||||
{{ with $badge }}
|
||||
<span class="card-badge">{{ . }}</span>
|
||||
{{ end }}
|
||||
</div>
|
||||
|
||||
{{ with $p.Params.subtitle }}
|
||||
<p class="mt-0.5 truncate text-[0.7rem] text-muted">
|
||||
{{ . }}
|
||||
</p>
|
||||
{{ end }}
|
||||
</div>
|
||||
</div>
|
||||
|
||||
{{ with $p.Params.description }}
|
||||
<p class="mt-2 text-xs text-muted">
|
||||
{{ . }}
|
||||
</p>
|
||||
{{ end }}
|
||||
|
||||
{{ with $p.Params.stack }}
|
||||
<div class="mt-3 card-tag-row">
|
||||
{{ range . }}
|
||||
<span class="card-tag-pill">{{ . }}</span>
|
||||
{{ end }}
|
||||
</div>
|
||||
{{ end }}
|
||||
</a>
|
||||
|
||||
<!-- Footer buttons: repo, demo, website -->
|
||||
<div class="card-home-footer card-home-footer--buttons">
|
||||
<div class="flex items-center gap-2">
|
||||
|
||||
{{ with $repo }}
|
||||
<a href="{{ . }}" class="card-cta-btn" target="_blank" rel="noopener noreferrer">
|
||||
<i class="{{ $repoIcon }} text-[0.75rem]"></i>
|
||||
<span>{{ $repoLabel }}</span>
|
||||
</a>
|
||||
{{ end }}
|
||||
|
||||
{{ with $demo }}
|
||||
<a href="{{ . }}" class="card-cta-btn" target="_blank" rel="noopener noreferrer">
|
||||
<i class="{{ $demoIcon }} text-[0.75rem]"></i>
|
||||
<span>{{ $demoLabel }}</span>
|
||||
</a>
|
||||
{{ end }}
|
||||
|
||||
{{ with $website }}
|
||||
<a href="{{ . }}" class="card-cta-btn" target="_blank" rel="noopener noreferrer">
|
||||
<i class="{{ $websiteIcon }} text-[0.75rem]"></i>
|
||||
<span>{{ $websiteLabel }}</span>
|
||||
</a>
|
||||
{{ end }}
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</article>
|
||||
@@ -0,0 +1,12 @@
|
||||
{{/* props: Title, Url, Small (bool) */}} {{- $title := .Title | default
|
||||
"Section" -}} {{- $url := .Url -}} {{- $small := .Small | default false -}}
|
||||
|
||||
<div class="flex items-baseline justify-between gap-2">
|
||||
<h2 class="heading-section">{{ $title }}</h2>
|
||||
|
||||
{{ with $url }}
|
||||
<a href="{{ . | relURL }}" class="link-underline text-[0.72rem] text-muted">
|
||||
{{ if $small }}All{{ else }}View all{{ end }}
|
||||
</a>
|
||||
{{ end }}
|
||||
</div>
|
||||
41
themes/minimal-black/layouts/partials/dark-toggle.html
Normal file
41
themes/minimal-black/layouts/partials/dark-toggle.html
Normal file
@@ -0,0 +1,41 @@
|
||||
<button
|
||||
type="button"
|
||||
class="theme-toggle"
|
||||
aria-label="Toggle dark mode"
|
||||
data-theme-toggle
|
||||
>
|
||||
<span data-theme-icon-light style="display: none">
|
||||
<!-- Sun icon -->
|
||||
<svg
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
class="h-4 w-4"
|
||||
viewBox="0 0 24 24"
|
||||
fill="none"
|
||||
stroke="currentColor"
|
||||
stroke-width="1.5"
|
||||
stroke-linecap="round"
|
||||
stroke-linejoin="round"
|
||||
>
|
||||
<circle cx="12" cy="12" r="4" />
|
||||
<path
|
||||
d="M12 3v2m0 14v2m9-9h-2M5 12H3m15.364-6.364-1.414 1.414M8.05 15.95l-1.414 1.414m0-11.314L8.05 8.05m9.9 9.9-1.414-1.414"
|
||||
/>
|
||||
</svg>
|
||||
</span>
|
||||
|
||||
<span data-theme-icon-dark>
|
||||
<!-- Moon icon -->
|
||||
<svg
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
class="h-4 w-4"
|
||||
viewBox="0 0 24 24"
|
||||
fill="none"
|
||||
stroke="currentColor"
|
||||
stroke-width="1.5"
|
||||
stroke-linecap="round"
|
||||
stroke-linejoin="round"
|
||||
>
|
||||
<path d="M21 12.79A9 9 0 0 1 12.21 3 7 7 0 1 0 21 12.79z" />
|
||||
</svg>
|
||||
</span>
|
||||
</button>
|
||||
55
themes/minimal-black/layouts/partials/dock.html
Normal file
55
themes/minimal-black/layouts/partials/dock.html
Normal file
@@ -0,0 +1,55 @@
|
||||
{{- $isHome := .IsHome -}}
|
||||
|
||||
<div class="dock" data-dock>
|
||||
<div class="dock-inner">
|
||||
<!-- Actions panel -->
|
||||
<div class="dock-panel" data-dock-panel>
|
||||
{{ if not $isHome }}
|
||||
<!-- Back -->
|
||||
<button
|
||||
type="button"
|
||||
class="dock-action"
|
||||
data-dock-action="back"
|
||||
aria-label="Go back"
|
||||
>
|
||||
<i class="fa-solid fa-arrow-left text-[0.7rem]"></i>
|
||||
</button>
|
||||
<span class="dock-divider" aria-hidden="true"></span>
|
||||
{{ end }}
|
||||
|
||||
<!-- Search -->
|
||||
<button
|
||||
type="button"
|
||||
class="dock-action"
|
||||
data-dock-action="search"
|
||||
aria-label="Search"
|
||||
onclick="window.MinimalSearch && window.MinimalSearch.open()"
|
||||
>
|
||||
<i class="fa-solid fa-magnifying-glass text-[0.7rem]"></i>
|
||||
</button>
|
||||
|
||||
<!-- Divider -->
|
||||
<span class="dock-divider" aria-hidden="true"></span>
|
||||
|
||||
<!-- Back to top -->
|
||||
<button
|
||||
type="button"
|
||||
class="dock-action"
|
||||
data-dock-action="top"
|
||||
aria-label="Back to top"
|
||||
>
|
||||
<i class="fa-solid fa-arrow-up text-[0.7rem]"></i>
|
||||
</button>
|
||||
</div>
|
||||
|
||||
<!-- Toggle -->
|
||||
<button
|
||||
type="button"
|
||||
class="dock-toggle"
|
||||
aria-label="Open quick actions"
|
||||
data-dock-toggle
|
||||
>
|
||||
<span class="dock-toggle-dots"></span>
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
56
themes/minimal-black/layouts/partials/footer.html
Normal file
56
themes/minimal-black/layouts/partials/footer.html
Normal file
@@ -0,0 +1,56 @@
|
||||
<footer class="pb-6 pt-10">
|
||||
<div class="mx-auto max-w-7xl px-4 sm:px-6">
|
||||
<div class="footer-shell">
|
||||
<div class="footer-inner">
|
||||
<!-- Left -->
|
||||
<div class="space-y-1">
|
||||
<p class="footer-small">
|
||||
© {{ now.Format "2006" }} {{ .Site.Title }} — All rights
|
||||
reserved.
|
||||
</p>
|
||||
|
||||
<p class="footer-small flex flex-wrap items-center gap-1">
|
||||
<span>Built with</span>
|
||||
|
||||
<a
|
||||
href="https://gohugo.io/"
|
||||
class="footer-link footer-float link-underline"
|
||||
target="_blank"
|
||||
rel="noopener noreferrer"
|
||||
>
|
||||
<span>Hugo</span>
|
||||
</a>
|
||||
|
||||
<span>/</span>
|
||||
|
||||
<a
|
||||
href="{{ .Site.Params.themeGit }}"
|
||||
class="footer-link footer-float link-underline"
|
||||
target="_blank"
|
||||
rel="noopener noreferrer"
|
||||
>
|
||||
<span>Minimal Black</span>
|
||||
</a>
|
||||
</p>
|
||||
</div>
|
||||
|
||||
<!-- Right -->
|
||||
{{ with .Site.Params.social }}
|
||||
<div class="footer-links">
|
||||
{{ range . }}
|
||||
<a
|
||||
href="{{ .url }}"
|
||||
class="footer-link footer-float link-underline"
|
||||
target="_blank"
|
||||
rel="noopener noreferrer"
|
||||
>
|
||||
<i class="{{ .icon }} text-[0.8rem]"></i>
|
||||
<span>{{ .label }}</span>
|
||||
</a>
|
||||
{{ end }}
|
||||
</div>
|
||||
{{ end }}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</footer>
|
||||
103
themes/minimal-black/layouts/partials/head.html
Normal file
103
themes/minimal-black/layouts/partials/head.html
Normal file
@@ -0,0 +1,103 @@
|
||||
{{- $title := cond (ne .Title "") (printf "%s | %s" .Title .Site.Title)
|
||||
.Site.Title -}}
|
||||
<meta charset="utf-8" />
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1" />
|
||||
|
||||
<title>{{ $title }}</title>
|
||||
|
||||
{{ partial "meta.html" . }}
|
||||
|
||||
<!-- Favicon -->
|
||||
{{ with .Site.Params.favicon }}
|
||||
<link rel="icon" type="image/x-icon" href="{{ . | relURL }}" />
|
||||
{{ else }}
|
||||
<!-- Default favicon paths -->
|
||||
{{ if fileExists "static/favicon.ico" }}
|
||||
<link rel="icon" type="image/x-icon" href="{{ "favicon.ico" | relURL }}" />
|
||||
{{ end }}
|
||||
{{ if fileExists "static/favicon.png" }}
|
||||
<link rel="icon" type="image/png" href="{{ "favicon.png" | relURL }}" />
|
||||
{{ end }}
|
||||
{{ if fileExists "static/favicon.svg" }}
|
||||
<link rel="icon" type="image/svg+xml" href="{{ "favicon.svg" | relURL }}" />
|
||||
{{ end }}
|
||||
{{ end }}
|
||||
|
||||
<!-- Apple Touch Icon -->
|
||||
{{ if .Site.Params.appleTouchIcon }}
|
||||
<link rel="apple-touch-icon" href="{{ . | relURL }}" />
|
||||
{{ else if fileExists "static/apple-touch-icon.png" }}
|
||||
<link rel="apple-touch-icon" href="{{ "apple-touch-icon.png" | relURL }}" />
|
||||
{{ end }}
|
||||
|
||||
<!-- Web App Manifest -->
|
||||
{{ with .Site.GetPage "/" }}
|
||||
{{ range .OutputFormats }}
|
||||
{{ if eq .Name "webappmanifest" }}
|
||||
<link rel="manifest" href="{{ .Permalink }}" />
|
||||
{{ end }}
|
||||
{{ end }}
|
||||
{{ end }}
|
||||
|
||||
<link rel="stylesheet" href="{{ "css/main.css" | relURL }}">
|
||||
|
||||
{{ if .Site.Params.icons.useFontAwesome }}
|
||||
<link
|
||||
rel="stylesheet"
|
||||
href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/7.0.1/css/all.min.css"
|
||||
>
|
||||
{{ end }}
|
||||
|
||||
{{ if .Site.Params.icons.useDevicon }}
|
||||
<link
|
||||
rel="stylesheet"
|
||||
href="https://cdn.jsdelivr.net/gh/devicons/devicon@v2.17.0/devicon.min.css"
|
||||
>
|
||||
{{ end }}
|
||||
|
||||
<!-- GLightbox -->
|
||||
<link
|
||||
rel="stylesheet"
|
||||
href="https://cdn.jsdelivr.net/npm/glightbox/dist/css/glightbox.min.css"
|
||||
/>
|
||||
|
||||
<!-- Justified Gallery (Vanilla) -->
|
||||
<link
|
||||
rel="stylesheet"
|
||||
href="https://cdn.jsdelivr.net/npm/justified-gallery@3.8.2/dist/css/justifiedGallery.min.css"
|
||||
/>
|
||||
|
||||
<script src="https://cdn.jsdelivr.net/npm/mermaid@10/dist/mermaid.min.js"></script>
|
||||
<script>
|
||||
mermaid.initialize({ theme: "dark" });
|
||||
</script>
|
||||
|
||||
<script>
|
||||
(function () {
|
||||
try {
|
||||
var stored = localStorage.getItem("theme");
|
||||
var systemDark =
|
||||
window.matchMedia &&
|
||||
window.matchMedia("(prefers-color-scheme: dark)").matches;
|
||||
var defaultTheme =
|
||||
'{{ default "system" .Site.Params.theme.defaultTheme }}';
|
||||
|
||||
var theme =
|
||||
stored ||
|
||||
(defaultTheme === "dark"
|
||||
? "dark"
|
||||
: defaultTheme === "light"
|
||||
? "light"
|
||||
: systemDark
|
||||
? "dark"
|
||||
: "light");
|
||||
|
||||
document.documentElement.setAttribute("data-theme", theme);
|
||||
} catch (e) {
|
||||
document.documentElement.setAttribute("data-theme", "light");
|
||||
}
|
||||
})();
|
||||
</script>
|
||||
|
||||
<!-- Analytics -->
|
||||
{{ partial "analytics.html" . }}
|
||||
86
themes/minimal-black/layouts/partials/header.html
Normal file
86
themes/minimal-black/layouts/partials/header.html
Normal file
@@ -0,0 +1,86 @@
|
||||
<header class="pt-6">
|
||||
{{/* Brand string for logo/monogram */}}
|
||||
{{- $brand := .Site.Params.brand | default .Site.Title}}
|
||||
{{- $mono := upper (substr $brand 0 2) -}}
|
||||
|
||||
<div class="mx-auto max-w-7xl px-4 sm:px-6">
|
||||
<!-- Floating nav container -->
|
||||
<div class="nav-shell">
|
||||
<div class="nav-inner">
|
||||
<!-- Brand: logo or monogram, always links to root -->
|
||||
<a href="{{ "/" | relURL }}" class="flex items-center gap-2">
|
||||
{{ with .Site.Params.logo }}
|
||||
<div class="flex h-8 w-8 items-center justify-center overflow-hidden rounded-full bg-surface">
|
||||
<img
|
||||
src="{{ . | relURL }}"
|
||||
alt="{{ $brand }}"
|
||||
class="h-full w-full object-cover"
|
||||
>
|
||||
</div>
|
||||
{{ else }}
|
||||
<div class="logo-badge">
|
||||
{{ $mono }}
|
||||
</div>
|
||||
{{ end }}
|
||||
<span class="text-xs font-semibold tracking-wide">
|
||||
{{ $brand }}
|
||||
</span>
|
||||
</a>
|
||||
|
||||
<div class="flex items-center gap-2">
|
||||
<!-- Desktop nav (configurable) -->
|
||||
<nav class="hidden items-center gap-5 md:flex">
|
||||
{{- $current := . -}}
|
||||
{{- range .Site.Menus.main }}
|
||||
<a
|
||||
href="{{ .URL | relURL }}"
|
||||
class="nav-link link-underline flex items-center gap-1 {{ if $current.IsMenuCurrent "main" . }}text-text{{ end }}"
|
||||
>
|
||||
{{ with .Params.icon }}
|
||||
<i class="{{ . }} text-[0.75rem]"></i>
|
||||
{{ end }}
|
||||
<span>{{ .Name }}</span>
|
||||
</a>
|
||||
{{- end }}
|
||||
</nav>
|
||||
|
||||
<!-- Theme toggle, sized to match nav -->
|
||||
{{ partial "dark-toggle.html" . }}
|
||||
|
||||
<!-- Mobile menu button -->
|
||||
<button
|
||||
type="button"
|
||||
class="ml-1 inline-flex items-center justify-center rounded-full border border-border bg-bg p-2 text-muted shadow-sm hover:text-accent md:hidden"
|
||||
aria-label="Toggle navigation"
|
||||
data-mobile-nav-toggle
|
||||
>
|
||||
<span class="sr-only">Open navigation</span>
|
||||
<svg xmlns="http://www.w3.org/2000/svg" class="h-4 w-4" viewBox="0 0 24 24" fill="none"
|
||||
stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round">
|
||||
<line x1="4" y1="6" x2="20" y2="6" />
|
||||
<line x1="4" y1="12" x2="20" y2="12" />
|
||||
<line x1="4" y1="18" x2="20" y2="18" />
|
||||
</svg>
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- Mobile nav (uses same menu config) -->
|
||||
<div class="mx-auto mt-2 max-w-7xl px-4 sm:px-6 md:hidden">
|
||||
<nav
|
||||
class="hidden rounded-2xl border border-border bg-surface px-4 py-3 text-sm text-muted shadow-md"
|
||||
data-mobile-nav
|
||||
>
|
||||
{{ range .Site.Menus.main }}
|
||||
<a href="{{ .URL | relURL }}" class="flex items-center gap-2 py-1.5">
|
||||
{{ with .Params.icon }}
|
||||
<i class="{{ . }} text-[0.8rem]"></i>
|
||||
{{ end }}
|
||||
<span>{{ .Name }}</span>
|
||||
</a>
|
||||
{{ end }}
|
||||
</nav>
|
||||
</div>
|
||||
</header>
|
||||
94
themes/minimal-black/layouts/partials/home/hero.html
Normal file
94
themes/minimal-black/layouts/partials/home/hero.html
Normal file
@@ -0,0 +1,94 @@
|
||||
{{- $hero := .Site.Params.hero -}}
|
||||
|
||||
<div class="grid gap-8 md:grid-cols-[minmax(0,2fr)_minmax(0,1.2fr)] items-start">
|
||||
<div class="space-y-5 animate-fade-up">
|
||||
<!-- Badge + availability -->
|
||||
<div class="flex flex-wrap items-center gap-4">
|
||||
{{ with $hero.badge }}
|
||||
<p class="eyebrow font-medium text-sm text-accent">{{ . }}</p>
|
||||
{{ end }}
|
||||
|
||||
{{ if $hero.available }}
|
||||
<span class="badge-available px-3">
|
||||
<span class="h-1.5 w-1.5 rounded-full bg-white/95"></span>
|
||||
<span>{{ default "Available for work" $hero.availableLabel }}</span>
|
||||
</span>
|
||||
{{ end }}
|
||||
</div>
|
||||
|
||||
<div class="space-y-2">
|
||||
<h1 class="heading-page text-3xl sm:text-4xl">
|
||||
{{ default "Hi, I’m Your Name." $hero.title }}
|
||||
</h1>
|
||||
{{ with $hero.role }}
|
||||
<p class="text-sm font-medium text-muted">
|
||||
{{ . }}
|
||||
</p>
|
||||
{{ end }}
|
||||
</div>
|
||||
|
||||
{{ with $hero.summary }}
|
||||
<p class="max-w-xl text-sm text-muted">
|
||||
{{ . }}
|
||||
</p>
|
||||
{{ end }}
|
||||
|
||||
<!-- Meta row: location + focus -->
|
||||
<div class="mt-3 flex flex-wrap gap-2 text-[0.7rem] text-muted">
|
||||
{{ with $hero.location }}
|
||||
<span class="inline-flex items-center gap-1.5 rounded-full border border-border bg-surface/90 px-3 py-1.5">
|
||||
<i class="fa-solid fa-location-dot text-[0.8rem]"></i>
|
||||
<span class="font-medium">{{ . }}</span>
|
||||
</span>
|
||||
{{ end }}
|
||||
|
||||
{{ with $hero.focus }}
|
||||
<span class="inline-flex items-center gap-1.5 rounded-full border border-border bg-surface/80 px-3 py-1.5">
|
||||
<i class="fa-regular fa-circle-dot text-[0.8rem]"></i>
|
||||
<span>{{ . }}</span>
|
||||
</span>
|
||||
{{ end }}
|
||||
</div>
|
||||
|
||||
<!-- Optional highlight pills -->
|
||||
{{ with $hero.highlights }}
|
||||
<div class="mt-3 flex flex-wrap gap-2">
|
||||
{{ range . }}
|
||||
<span class="inline-flex items-center rounded-full border border-border bg-surface/80 px-3 py-1 text-[0.7rem] text-muted">
|
||||
{{ .label }}
|
||||
</span>
|
||||
{{ end }}
|
||||
</div>
|
||||
{{ end }}
|
||||
|
||||
<!-- CTAs -->
|
||||
<div class="mt-4 flex flex-wrap items-center gap-3">
|
||||
{{ with $hero.primary }}
|
||||
<a href="{{ .href | default "/projects/" }}" class="btn-primary">
|
||||
{{ .label | default "View projects" }}
|
||||
</a>
|
||||
{{ end }}
|
||||
|
||||
{{ with $hero.secondary }}
|
||||
<a href="{{ .href | default "/blog/" }}" class="btn-ghost link-underline">
|
||||
{{ .label | default "Read the blog" }}
|
||||
</a>
|
||||
{{ end }}
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- Avatar ONLY if provided -->
|
||||
{{ with $hero.avatar }}
|
||||
<div class="order-first md:order-none">
|
||||
<div class="card card-pad flex items-center justify-center md:justify-end">
|
||||
<div class="h-24 w-24 sm:h-28 sm:w-28 overflow-hidden rounded-2xl border border-border bg-surface shadow-md">
|
||||
<img
|
||||
src="{{ . | relURL }}"
|
||||
alt="{{ $hero.title | default $.Site.Title }}"
|
||||
class="h-full w-full object-cover"
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
{{ end }}
|
||||
</div>
|
||||
28
themes/minimal-black/layouts/partials/home/now.html
Normal file
28
themes/minimal-black/layouts/partials/home/now.html
Normal file
@@ -0,0 +1,28 @@
|
||||
{{- $hero := .Site.Params.hero -}}
|
||||
{{- $home := .Site.Params.home -}}
|
||||
|
||||
{{ if $home.showNowSection }}
|
||||
<div class="space-y-4">
|
||||
<div class="space-y-3">
|
||||
<h2 class="heading-section">{{ default "Now" $hero.nowLabel }}</h2>
|
||||
<div class="card card-pad text-xs text-muted">
|
||||
{{ with $hero.nowIntro }}
|
||||
<p class="mb-2">{{ . }}</p>
|
||||
{{ end }}
|
||||
|
||||
{{ with $hero.now }}
|
||||
<ul class="list-disc space-y-1 pl-4">
|
||||
{{ range . }}
|
||||
<li>{{ . }}</li>
|
||||
{{ end }}
|
||||
</ul>
|
||||
{{ else }}
|
||||
<p>
|
||||
Add a <code>hero.now</code> list in your config to describe what you’re
|
||||
focused on right now.
|
||||
</p>
|
||||
{{ end }}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
{{ end }}
|
||||
38
themes/minimal-black/layouts/partials/home/posts.html
Normal file
38
themes/minimal-black/layouts/partials/home/posts.html
Normal file
@@ -0,0 +1,38 @@
|
||||
{{- $home := .Site.Params.home -}}
|
||||
{{ if ne $home.showLatestPosts false }}
|
||||
<div class="space-y-3 animate-fade-up">
|
||||
<div class="space-y-1">
|
||||
<h2 class="heading-section">
|
||||
{{ default "Latest writing" $home.blogTitle }}
|
||||
</h2>
|
||||
{{ with $home.blogSubtitle }}
|
||||
<p class="text-xs text-muted">
|
||||
{{ . }}
|
||||
</p>
|
||||
{{ end }}
|
||||
</div>
|
||||
|
||||
{{ $limit := cond (gt (int $home.latestPostsLimit) 0) (int $home.latestPostsLimit) 3 }}
|
||||
{{ $posts := first $limit (where .Site.RegularPages "Section" "blog") }}
|
||||
|
||||
<div class="grid gap-4 md:grid-cols-2">
|
||||
{{ range $posts }}
|
||||
{{ partial "components/post-card.html" (dict "Page" . "Root" $) }}
|
||||
{{ else }}
|
||||
<p class="text-xs text-muted">
|
||||
No posts yet. Add some under <code>content/blog</code>.
|
||||
</p>
|
||||
{{ end }}
|
||||
</div>
|
||||
|
||||
<div class="mt-3 flex justify-end">
|
||||
<a
|
||||
href="{{ "/blog/" | relURL }}"
|
||||
class="btn-primary btn-primary-sm inline-flex items-center gap-2"
|
||||
>
|
||||
<span>View all posts</span>
|
||||
<i class="fa-solid fa-arrow-right-long text-[0.8rem]"></i>
|
||||
</a>
|
||||
</div>
|
||||
</div>
|
||||
{{ end }}
|
||||
43
themes/minimal-black/layouts/partials/home/projects.html
Normal file
43
themes/minimal-black/layouts/partials/home/projects.html
Normal file
@@ -0,0 +1,43 @@
|
||||
{{- $home := .Site.Params.home -}}
|
||||
{{ if ne $home.showFeaturedProjects false }}
|
||||
<div class="space-y-3 animate-fade-up">
|
||||
<div class="space-y-1">
|
||||
<h2 class="heading-section">
|
||||
{{ default "Selected work" $home.projectsTitle }}
|
||||
</h2>
|
||||
{{ with $home.projectsSubtitle }}
|
||||
<p class="text-xs text-muted">
|
||||
{{ . }}
|
||||
</p>
|
||||
{{ end }}
|
||||
</div>
|
||||
|
||||
{{ $limit := cond (gt (int $home.featuredProjectsLimit) 0) (int $home.featuredProjectsLimit) 3 }}
|
||||
{{ $allProjects := where .Site.RegularPages "Section" "projects" }}
|
||||
{{ $featured := where $allProjects "Params.featured" true }}
|
||||
{{ if not (gt (len $featured) 0) }}
|
||||
{{ $featured = $allProjects }}
|
||||
{{ end }}
|
||||
{{ $list := first $limit $featured }}
|
||||
|
||||
<div class="grid gap-4 md:grid-cols-2">
|
||||
{{ range $list }}
|
||||
{{ partial "components/project-card.html" (dict "Page" . "Root" $) }}
|
||||
{{ else }}
|
||||
<p class="text-xs text-muted">
|
||||
No projects yet. Add some under <code>content/projects</code>.
|
||||
</p>
|
||||
{{ end }}
|
||||
</div>
|
||||
|
||||
<div class="mt-3 flex justify-end">
|
||||
<a
|
||||
href="{{ "/projects/" | relURL }}"
|
||||
class="btn-primary btn-primary-sm inline-flex items-center gap-2"
|
||||
>
|
||||
<span>View all projects</span>
|
||||
<i class="fa-solid fa-arrow-right-long text-[0.8rem]"></i>
|
||||
</a>
|
||||
</div>
|
||||
</div>
|
||||
{{ end }}
|
||||
59
themes/minimal-black/layouts/partials/home/tech-marquee.html
Normal file
59
themes/minimal-black/layouts/partials/home/tech-marquee.html
Normal file
@@ -0,0 +1,59 @@
|
||||
{{- $home := .Site.Params.home -}}
|
||||
{{- $hero := .Site.Params.hero -}}
|
||||
{{- $techMain := $home.tech -}}
|
||||
{{- $techReverse := $home.techReverse -}}
|
||||
{{- $variant := $home.techVariant | default "wide" -}}
|
||||
|
||||
{{ with $techMain }}
|
||||
<div class="space-y-5 animate-fade-up">
|
||||
<div class="space-y-2">
|
||||
<h3 class="heading-section text-base">
|
||||
{{ default "What I Work With" $hero.techMarqueeLabel }}
|
||||
</h3>
|
||||
|
||||
<div class="tech-strip {{ if eq $variant "compact" }}tech-strip--compact{{ else }}tech-strip--wide{{ end }}">
|
||||
<!-- primary row (always rendered) -->
|
||||
<div class="tech-strip-track tech-strip-track--primary">
|
||||
{{ range . }}
|
||||
<div class="tech-strip-item">
|
||||
{{ with .icon }}
|
||||
<i class="{{ . }} tech-icon"></i>
|
||||
{{ end }}
|
||||
<span class="font-medium">{{ .label }}</span>
|
||||
</div>
|
||||
{{ end }}
|
||||
{{ range . }}
|
||||
<div class="tech-strip-item" aria-hidden="true">
|
||||
{{ with .icon }}
|
||||
<i class="{{ . }} tech-icon"></i>
|
||||
{{ end }}
|
||||
<span class="font-medium">{{ .label }}</span>
|
||||
</div>
|
||||
{{ end }}
|
||||
</div>
|
||||
|
||||
<!-- secondary row, reverse (only if techReverse is defined) -->
|
||||
{{ with $techReverse }}
|
||||
<div class="tech-strip-track tech-strip-track--secondary">
|
||||
{{ range . }}
|
||||
<div class="tech-strip-item">
|
||||
{{ with .icon }}
|
||||
<i class="{{ . }} tech-icon"></i>
|
||||
{{ end }}
|
||||
<span class="font-medium">{{ .label }}</span>
|
||||
</div>
|
||||
{{ end }}
|
||||
{{ range . }}
|
||||
<div class="tech-strip-item" aria-hidden="true">
|
||||
{{ with .icon }}
|
||||
<i class="{{ . }} tech-icon"></i>
|
||||
{{ end }}
|
||||
<span class="font-medium">{{ .label }}</span>
|
||||
</div>
|
||||
{{ end }}
|
||||
</div>
|
||||
{{ end }}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
{{ end }}
|
||||
7
themes/minimal-black/layouts/partials/meta.html
Normal file
7
themes/minimal-black/layouts/partials/meta.html
Normal file
@@ -0,0 +1,7 @@
|
||||
{{- with .Description -}}
|
||||
<meta name="description" content="{{ . }}" />
|
||||
{{- else -}}
|
||||
<meta name="description" content="{{ .Site.Params.description }}" />
|
||||
{{- end }} {{- with .Site.Params.author }}
|
||||
<meta name="author" content="{{ . }}" />
|
||||
{{- end }}
|
||||
59
themes/minimal-black/layouts/partials/search-overlay.html
Normal file
59
themes/minimal-black/layouts/partials/search-overlay.html
Normal file
@@ -0,0 +1,59 @@
|
||||
<div class="search-overlay" data-search-overlay>
|
||||
<div class="search-overlay-backdrop" data-search-close></div>
|
||||
|
||||
<div class="search-panel">
|
||||
<div class="search-panel-header">
|
||||
<div class="search-input-wrap">
|
||||
<i class="fa-solid fa-magnifying-glass text-[0.8rem] text-muted"></i>
|
||||
<input
|
||||
type="search"
|
||||
class="search-input"
|
||||
placeholder="Search posts..."
|
||||
autocomplete="off"
|
||||
data-search-input
|
||||
/>
|
||||
</div>
|
||||
<button
|
||||
type="button"
|
||||
class="search-close"
|
||||
data-search-close
|
||||
aria-label="Close search"
|
||||
>
|
||||
<i class="fa-solid fa-xmark text-[0.8rem]"></i>
|
||||
</button>
|
||||
</div>
|
||||
|
||||
<div class="search-panel-body">
|
||||
<div class="search-results" data-search-results>
|
||||
<div class="search-empty-state">
|
||||
<div class="search-empty-icon">
|
||||
<i class="fa-solid fa-magnifying-glass text-[1rem]"></i>
|
||||
</div>
|
||||
<p class="search-empty-title">Start searching</p>
|
||||
<p class="search-empty-subtitle">
|
||||
Enter keywords to search articles.
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="search-footer-hints">
|
||||
<div class="search-hint-key">
|
||||
<span>↑↓</span>
|
||||
<span>Navigate</span>
|
||||
</div>
|
||||
<div class="search-hint-key">
|
||||
<span>↵</span>
|
||||
<span>Select</span>
|
||||
</div>
|
||||
<div class="search-hint-key">
|
||||
<span>ESC</span>
|
||||
<span>Close</span>
|
||||
</div>
|
||||
<div class="search-hint-key search-hint-right">
|
||||
<span>Ctrl</span><span>K</span>
|
||||
<span>Shortcut</span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
Reference in New Issue
Block a user