Update README and exampleSite

This commit is contained in:
Alex Selimov 2026-03-20 09:00:56 -04:00
parent 460fe6a820
commit 41c217030c
3 changed files with 43 additions and 17 deletions

View file

@ -1,7 +1,6 @@
# ᕦʕ •ᴥ•ʔᕤ Bear Cub # ᕦʕ •ᴥ•ʔᕤ Voting Bear Cub
[![github pages](https://github.com/clente/hugo-bearcub/actions/workflows/gh-pages.yml/badge.svg)](https://github.com/clente/hugo-bearcub/actions/workflows/gh-pages.yml) [![MIT license](https://img.shields.io/badge/license-MIT-blue)](https://forge.alexselimov.com/aselimov/hugo-bearcub/src/branch/main/LICENSE)
[![MIT license](https://img.shields.io/github/license/clente/hugo-bearcub)](https://github.com/clente/hugo-bearcub/blob/main/LICENSE)
## Overview ## Overview
@ -9,6 +8,22 @@
Blog](https://bearblog.dev) and [Hugo Bear Blog](https://bearblog.dev) and [Hugo Bear
Blog](https://github.com/janraasch/hugo-bearblog). Blog](https://github.com/janraasch/hugo-bearblog).
This is a fork of [Bear Cub](https://github.com/clente/hugo-bearcub) with the
following additions:
- **Anonymous post upvoting**: each post can display an upvote button backed by
a configurable API endpoint. Votes are tracked anonymously via cookies so
readers can toggle their vote without creating an account. Enable with
`upvotes = true` and set `upvoteApi` to your API base URL.
- **Redesigned header**: the site header now uses a mesh SVG background for a
more distinctive look.
- **GitHub light/dark color scheme**: the syntax highlighting palette has been
replaced with colors matching the GitHub light and dark themes.
- **Herman CSS upvote styles**: upvote button styles are bundled into the Herman
CSS variant so the button integrates cleanly with the existing theme.
- **Configurable index post count**: use `postsToShowOnIndex` in `[params]` to
control how many posts appear on the home page (defaults to 3).
**Bear Cub** takes care of speed and optimization, so you can focus on writing **Bear Cub** takes care of speed and optimization, so you can focus on writing
good content. It is free, multilingual, optimized for search engines, good content. It is free, multilingual, optimized for search engines,
no-nonsense, responsive, light, and fast. Really fast. no-nonsense, responsive, light, and fast. Really fast.

View file

@ -75,6 +75,17 @@ enableRobotsTXT = true
# information see layouts/partials/social_card.html # information see layouts/partials/social_card.html
generateSocialCard = true generateSocialCard = true
# The number of posts to show on the index page. Defaults to 3 if not set.
postsToShowOnIndex = 3
# Enable upvoting on posts. When set to true, each post will display an upvote
# button that calls the API endpoint specified by `upvoteApi`.
upvotes = false
# The base URL of the upvote API. Only used when `upvotes = true`.
# The API is expected to handle GET and POST requests at {upvoteApi}/{post-path}.
upvoteApi = "https://example.com/api"
# Social media. Delete any item you aren't using to make sure it won't show up # Social media. Delete any item you aren't using to make sure it won't show up
# in your website's metadata. # in your website's metadata.
[params.social] [params.social]

View file

@ -1,29 +1,29 @@
name = "Bear Cub" name = "Voting Bear Cub"
license = "MIT" license = "MIT"
licenselink = "https://github.com/clente/hugo-bearcub/blob/master/LICENSE" licenselink = "https://github.com/clente/hugo-bearcub/blob/master/LICENSE"
description = "A lightweight Hugo theme based on Bear Blog and Hugo Bear Blog. It is free, multilingual, optimized for search engines, no-nonsense, responsive, light, and fast. Really fast." description = """A lightweight Hugo theme based on Bear Blog and Hugo Bear Blog. It is free,
multilingual, optimized for search engines, no-nonsense, responsive, light, and fast. Really fast.
This version adds an upvote button that connects to an
https://forge.alexselimov.com/aselimov/upvoters server to handle anonymous upvotes.
"""
# The home page of the theme, where the source can be found. # The home page of the theme, where the source can be found.
homepage = "https://github.com/clente/hugo-bearcub" homepage = "https://forge.alexselimov.com/aselimov/hugo-bearcub"
# If you have a running demo of the theme.
demosite = "https://clente.github.io/hugo-bearcub"
tags = ["blog", "responsive", "minimal", "personal", "dark", "multilingual"] tags = ["blog", "responsive", "minimal", "personal", "dark", "multilingual"]
features = ["favicon", "seo", "no javascript", "rss", "social cards"] features = ["favicon", "seo", "no javascript", "rss", "social cards"]
# If the theme has a single author # If the theme has a single author
[author] [author]
name = "Caio Lente" name = "Alex Selimov"
homepage = "https://lente.dev" homepage = "https://alexselimov.com"
# If porting an existing theme
[original] [original]
author = "Jan Raasch" name = "Caio Lente"
homepage = "https://www.janraasch.com" homepage = "https://lente.dev"
repo = "https://github.com/janraasch/hugo-bearblog" repo = "https://github.com/clente/hugo-bearcub"
# Hugo versions the theme supports # Hugo versions the theme supports
[module] [module]
[module.hugoVersion] [module.hugoVersion]
min = "0.90" min = "0.90"