# Paige
Powerful, pliable pixel perfection. An advanced Hugo theme. [Try it out.](https://willfaught.com/paige)
Paige is designed to put your content front and center,
avoiding the typical clutter.
The look is seamless and smooth, scalable and readable, portable and efficient.
The layout is minimal and responsive,
using verticality and white space to focus and delineate parts of the page.
The implementation is flexible and extensible.
It's a versatile canvas that serves most web needs.
Welcome to the last Hugo theme you'll probably ever need.
## Features
- Accessibility
- Analytics
- Automatic switching between light and dark color schemes
- Blog
- Bootstrap
- Comments
- Customizable
- Dark color scheme
- E-mail protection
- Facebook sharing
- Header links
- Landing page
- Light color scheme
- Math typesetting
- Menu
- Minimal design
- Multiple authors
- Multiple languages
- RSS with full content
- Responsive
- Right-to-left languages
- SEO
- Safari and Firefox Reader View support
- Search
- Sections
- Single column
- Social links
- Table of contents
- Twitter sharing
## Community
Get started by [starring](https://github.com/willfaught/paige/stargazers)
and [following](https://github.com/willfaught/paige/watchers) the project.
If you find a problem or have a suggestion,
please share it by [creating an issue](https://github.com/willfaught/paige/issues/new).
Feedback is encouraged and appreciated.
If you have a fix or improvement,
please share it by [creating a pull request](https://github.com/willfaught/paige/compare).
If you make a customization or alteration,
please share it by [posting code or screenshots](https://github.com/willfaught/paige/discussions/8).
## Get started with Hugo
1. [Install Hugo](https://gohugo.io/installation/).
For Homebrew on Mac:
```sh
$ brew install hugo
```
2. Create a site:
```sh
$ hugo new site yourproject
```
3. Create a post:
```sh
$ cd yourproject
$ hugo new my-post.md
```
See [Hugo's quick start guide](https://gohugo.io/getting-started/quick-start/) for more information.
## Install
### Option 1: Use a Hugo module
Example `config.yaml`:
```yaml
module:
imports:
- path: "github.com/willfaught/paige"
```
Install:
```sh
$ cd yourproject
$ hugo mod init github.com/youraccount/yourproject
$ hugo mod get github.com/willfaught/paige
```
Update:
```sh
$ cd yourproject
$ hugo mod get -u
```
### Option 2: Use a Git subtree
Example `config.yaml`:
```yaml
theme: "paige"
```
Install:
```sh
$ cd yourproject
$ git subtree add --prefix themes/paige --squash https://github.com/willfaught/paige master
```
Update:
```sh
$ cd yourproject
$ git subtree pull --prefix themes/paige --squash https://github.com/willfaught/paige master
```
### Option 3: Use a Git submodule
Example `config.yaml`:
```yaml
theme: "paige"
```
Install:
```sh
$ cd yourproject
$ git submodule add https://github.com/willfaught/paige themes/paige
$ git submodule update --init --recursive --remote
```
Update:
```sh
$ cd yourproject
$ git submodule update --recursive --remote
```
### Option 4: Use a copy
Example `config.yaml`:
```yaml
theme: "paige"
```
Install:
```sh
$ cd yourproject
$ git clone https://github.com/willfaught/paige themes/paige
$ rm -rf themes/paige/.git
```
Update:
```sh
$ cd yourproject
$ rm -rf themes/paige
$ git clone https://github.com/willfaught/paige themes/paige
$ rm -rf themes/paige/.git
```
## Run
```sh
$ cd yourproject
$ hugo mod npm pack
$ npm install
$ hugo server -D
```
## Configure
### Parameters
There is a single parameter object with sensible defaults that can be overridden in site or page parameters:
```yaml
paige:
analytics:
chartbeat: # See https://chartbeat.com
account_id: ""
domain: ""
clicky: # See https://clicky.com
account_id: ""
fathom: # See https://usefathom.com
account_id: ""
finteza: # See https://finteza.com
account_id: ""
script_url: ""
hotjar: # See https://hotjar.com
account_id: ""
matomo: # See https://matomo.org
account_id: ""
host_url: ""
mixpanel: # See https://mixpanel.com
token: ""
plausible: # See https://plausible.io
account_id: ""
woopra: # See https://woopra.com
domain: ""
yandex: # See https://metrica.yandex.com
account_id: ""
authors:
class: "text-center text-secondary"
hide: false
color: "#0d6efd" # Bootstrap primary color; theme color for Safari and Windows
color_scheme: "" # Always use this color scheme without automatic switching; must be "", "light", or "dark"
comments:
cactus: # See https://cactus.chat
account_id: ""
commento: # See https://commento.io
script_url: ""
hyvor: # See https://hyvor.com
account_id: ""
intensedebate: # See https://intensedebate.com
account_id: ""
isso: # See https://isso-comments.de
script_url: ""
remark42: # See https://remark42.com
host_url: ""
site_id: ""
replybox: # See https://getreplybox.com
account_id: ""
utterances: # See https://utteranc.es
github_repo: ""
content:
class: "mw-100 paige-content"
hide: false
max_width: ""
credit:
data:
hide: false # Don't credit this project in a data attribute
link:
hide: false # Don't credit this project in the footer
date:
class: "text-center text-secondary"
format: ":date_long" # Hugo date format
hide: false
source: "published" # Displayed date; must be "published" or "modified"
description:
class: "lead text-center"
hide: false
git:
commit_url_prefix: "" # Example is "https://github.com/willfaught/paige/commit/"
list:
authors:
class: "mb-0 text-center text-secondary"
hide: false
content:
show: false
date:
class: "mb-0 text-center text-secondary"
format: ":date_long" # Hugo date format
hide: false
date_header:
class: "h5 text-center"
hide: false
description:
class: "mb-0 text-center"
hide: false
pages:
hide: false
reading_time:
class: "mb-0 text-center text-secondary"
hide: false
section:
class: "mb-3 w-100"
summary:
class: "fst-italic mb-0 text-center"
hide: false
terms:
hide: false
inner_class: "badge text-bg-secondary text-decoration-none"
outer_class: "mb-0 text-center"
math: false # Enable math typesetting
menu:
breakpoint: "sm" # Bootstrap breakpoint at which to display all menu items
style: "pills" # Must be "links" or "pills"
metadata:
max_width: ""
reading_time:
class: "text-center text-secondary"
hide: false
rss:
hide_page: false
managing_editor: ""
web_master: ""
search:
hide_page: false
style: ""
terms:
hide: false
inner_class: "badge text-bg-secondary text-decoration-none"
outer_class: "text-center"
table_of_contents:
class: "border mb-3 pe-3 ps-3 pt-3 rounded"
hide: false
max_width: ""
```
The assigned values shown are the default values.
If you set `paige.credit.data.hide` or `paige.credit.link.hide`, please credit this project in a post to help others find it.
### Site parameters
Optional site parameters:
```yaml
authors:
will_faught:
name: "Will Faught"
default: false # Credit this author in pages that have no authors parameter
```
### Page parameters
Optional page parameters:
```yaml
authors:
- "will_faught" # Credit the corresponding author in the site parameters
- author: "will_faught" # Credit the corresponding author in the site parameters
- name: "Will Faught" # Credit this author
link: "https://youtu.be/dQw4w9WgXcQ" # The reference for an anchor around the title
```
### Minimal look
By default, everything is shown. If you want a more minimal look, try the following:
```yaml
paige:
list:
authors:
hide: true
date:
hide: true
reading_time:
hide: true
summary:
hide: true
terms:
hide: true
main:
metadata:
reading_time:
hide: true
terms:
hide: true
table_of_contents:
hide: true
```
## Layouts
### Home
The `paige/home` layout provides a home page.
Example `content/_index.md`:
```yaml
layout: "paige/home"
paige:
home:
blurb: "" # Displayed below the greeting
greeting: "" # Displayed below the image
image:
raw: false # Do not copy or process the file
stretch: false # Stretch the image fully horizontally if true; center the image otherwise
url: "" # Local or remote resource glob
social:
examplesite:
bootstrap_icon: "" # Example is "example-icon"
name: "" # Example is "Example"
url: "" # Example is "https://example.com/username"
```
The assigned values shown are the default values.
### Search
The `paige/search` layout provides full site search.
Example `config.yaml`:
```yaml
outputs:
home: ["html", "json", "rss"]
```
Example `content/search.md`:
```yaml
layout: "paige/search"
title: "Search"
```
## Shortcodes
### Figure
The `paige/figure` shortcode provides a figure with content.
```
{{< paige/figure
caption="My caption"
float="left"
height="10rem"
horizontal="center"
maxheight="10rem"
maxwidth="10rem"
number=0
numbered=false
vertical="center"
width="10rem"
>}}
My content
{{< /paige/figure >}}
```
Inner content: Required. String. Markdown. The content.
Parameters:
caption
float
start
or end
.height
horizontal
start
, center
, or end
. Default is center
.maxheight
maxwidth
number
numbered
vertical
start
, center
, or end
. Default is center
.width
Test
{{< /paige/code >}} ``` Inner content: Required. String. The code. Parameters:caption
lang
plaintext
. See the codes.options
alt
caption
link
method
crop
, fill
, fit
, or resize
. Must be specified with options
. See the methods.options
method
. See the options.raw
false
.src
title
align
baseline
, center
, end
, start
, or stretch
. Must not be used when nested.caption
height
image
images
justify
around
, between
, center
, end
, evenly
, or start
. Must not be used when nested.maxheight
maxwidth
method
crop
, fill
, fit
, or resize
. Default is resize
. See the methods.options
550x webp picture Lanczos
. See the options.raw
false
.type
grid
or list
. Default is list
.width
autopause
true
.autoplay
false
.background
false
.byline
color
00adef
.controls
true
.description
Vimeo video
.dnt
false
.fullscreen
true
.keyboard
true
.loop
false
.muted
false
.pip
false
.playsinline
true
.portrait
quality
auto
, 240p
, 360p
, 540p
, 720p
, 1080p
, 2k
, or 4k
. Default is auto
.speed
false
.texttrack
en
, en-US
). Use the corresponding subtitles. Default is false
.time
0m
, 1m2s
). Start time. Default is 0m
.title
transparent
true
.video
autoplay
controls
true
.description
YouTube video
.end
fullscreen
true
.list
loop
mute
start
video
#paige-copyright
#paige-credit
#paige-footer
#paige-header
#paige-main
#paige-pages
#paige-pagination
#paige-root
.paige-article
.paige-authors
.paige-content
.paige-date
.paige-date-header
.paige-description
.paige-draft
.paige-expired
.paige-future
.paige-home
.paige-article
for a page with kind "home"..paige-metadata
.paige-modified
.paige-page
.paige-published
.paige-section
.paige-article
for a page with kind "section"..paige-single
.paige-article
for a page with kind "page"..paige-summary
.paige-reading-time
.paige-taxonomy
.paige-article
for a page with kind "taxonomy"..paige-term
.paige-article
for a page with kind "term"..paige-terms-inner
.paige-terms-outer
.paige-title
.paige-toc
.paige-unpublished