A directory listing theme for Hugo inspired by Craigslist, eBay, KYC Not, and XmrBazaar.
  • CSS 57.6%
  • HTML 42.4%
Find a file
2026-05-02 04:59:09 +02:00
layouts Add multiple abbreviations 2026-05-02 04:59:09 +02:00
static/css Flat badge flow, Component UI migration, explicit paginate 15 2026-04-21 07:01:09 +02:00
LICENSE Initial commit 2026-04-15 05:58:46 +02:00
README.md Add NOWPayments to abbreviation map 2026-04-21 08:38:46 +02:00
theme.toml Initial theme 2026-04-15 06:11:07 +02:00

Directory - Hugo Theme

A directory listing theme for Hugo inspired by Craigslist, eBay, KYC Not, and XmrBazaar.

WCAG 2.2 AAA compliant. Pure black default with automatic light theme. CSS-only interactions (no JavaScript except Pagefind search).

Features

  • List and grid view toggle (CSS :target, no JS)
  • Fixed-height cards with gradient fade
  • Taxonomy badge links (category, network, requirement, currency, status)
  • External URL indicators (↗)
  • Git commit timestamps via enableGitInfo
  • Dark/light theme toggle (checkbox hack + prefers-color-scheme)
  • Pagefind static search integration
  • Pagefind filter sidebar with CSS flexbox reordering
  • WCAG 2.2 AAA contrast ratios, target sizes, and focus indicators

Installation

Add as a Git submodule:

git submodule add https://forgejo.franklyflawless.org/FranklyFlawless/hugo-directory.git themes/directory

Set in hugo.toml:

theme = "directory"

Configuration

Required in hugo.toml

enableGitInfo = true

[frontmatter]
  date      = [":git", "date", "publishDate"]
  lastmod   = [":git", "lastmod"]
  pageinate = 15
[taxonomies]
  category    = "category"
  network     = "network"
  requirement = "requirement"
  currency    = "currency"
  status      = "status"

Overridable values

The following are hard-coded in the theme and can be overridden by creating matching files in your site's layouts/ directory:

File Hard-coded value Purpose
layouts/_default/baseof.html Site title in <title> tag Override define "title" block
layouts/_default/term.html ← Home nav link Override define "nav" block
layouts/_default/list.html ← Home nav link Override define "nav" block
layouts/partials/card.html Forgejo commit URL prefix Change forgejo.franklyflawless.org/FranklyFlawless/Website
layouts/partials/display-name.html Abbreviation map (DNS, I2P, ISO, JavaScript, NOWPayments, SSH, USD, VPN, VPS, XMPP) Add or change abbreviation mappings

Content frontmatter

---
title: "Service Name"
draft: false
category:
  - vps
network:
  - tor
requirement:
  - javascript
currency:
  - monero
status:
  - pending
thumbnail: "/img/service.svg"
privacy_score: 0
trust_score: 0
urls:
  clearnet: "https://example.com/"
  onion: ""
  i2p: ""
attributes:
  good:
    - onion-service
  warning: []
  bad: []
  info:
    - sweden
---

Description of the service.

Theme preference

The manual dark/light toggle uses a CSS checkbox hack. Because Hugo generates static HTML with no server-side state, the toggle resets on every page navigation. This is a known limitation of pure CSS themes.

The prefers-color-scheme media query automatically matches the operating system preference without any toggle interaction, so most users will see the correct theme by default.

Persisting the manual toggle across pages requires JavaScript (e.g. localStorage), which this theme intentionally avoids outside of Pagefind.

License

CC0-1.0