- CSS 48.4%
- HTML 46.3%
- JavaScript 4.1%
- PHP 1.2%
| _design | ||
| archetypes/reviews | ||
| assets | ||
| layouts | ||
| static | ||
| .gitignore | ||
| README.md | ||
| theme.toml | ||
ChinaGearLab Hugo Theme
A dense, catalogue-style Hugo theme for ChinaGearLab — a one-person review catalogue of Chinese-market tools and test equipment. No star ratings; every review resolves to a three-state verdict pill (yes / maybe / no) with an owned-for stamp. Teardown photography is the differentiator.
Requires: Hugo Extended (for Hugo Pipes asset processing)
Installation
As a theme directory
# From your site root:
git clone https://git.wiredincode.com/WiredInCode/chinagearlab-hugo-theme.git themes/chinagearlab
Then set theme = "chinagearlab" in your hugo.toml.
Content structure
content/
├── _index.md # Homepage front matter (intro, stats)
├── reviews/
│ ├── _index.md
│ └── my-review.md
├── categories/ # optional — pin a category's slug/intro copy
│ └── power-tools/_index.md
├── about/
│ └── _index.md
├── buying-guides/
│ └── _index.md # plain content page, not a review list
└── contact/
└── _index.md # renders the contact form (layouts/contact/list.html)
See archetypes/reviews.md for the full review front-matter schema (verdict, price history,
specs, pros/cons, gallery, teardown). Note owned_since is a date (when you started using the
product) — the "owned N weeks/months" text is computed live in the browser from that date via
layouts/partials/owned-duration.html + assets/js/main.js, so it never goes stale between
rebuilds. It is deliberately not the same as the front-matter date (which is the publish date).
Build
hugo server # dev
hugo --minify # production build
npx pagefind --site public # rebuild the search index — do this after every build
The site repo's deploy.sh runs the last two steps together.
Design reference
The _design/ directory contains the original design handoff files (token CSS, base design
system CSS, .dc.html mockups). These are not included in any Hugo build output — Hugo ignores
_-prefixed directories. See _design/cgl-tokens.css for the source of truth on colour/type
tokens.
License
MIT