mirror of https://github.com/onweru/compose.git

weru
08.33.2020 f8b4b41a58e238983b9047d68566065e644c9b3d
update
1 files added
3 files modified
108 ■■■■ changed files
exampleSite/content/docs/clarity/blogging.md 54 ●●●●● patch | view | raw | blame | history
exampleSite/content/docs/clarity/customize.md 50 ●●●●● patch | view | raw | blame | history
exampleSite/go.mod 2 ●●● patch | view | raw | blame | history
exampleSite/go.sum 2 ●●●●● patch | view | raw | blame | history
exampleSite/content/docs/clarity/blogging.md
New file
@@ -0,0 +1,54 @@
+++
title="Blogging"
+++
### Blog directory
Edit the `config.toml` file and change the `mainSections` key. Values will be directories where the blogs reside.
```yaml
[params]
...
mainSections = ["posts", "docs", "blogs"]
...
```
For more info, see the [Hugo docs](https://gohugo.io/functions/where/#mainsections).
### Mobile menu positioning
The navigation menu when mobile browsing can be configured in `config.toml` to open right or left depending on preference. The "hamburger" menu icon will always display in the upper right hand corner regardless.
```yaml
[params]
...
mobileNavigation = "left" # Mobile nav menu will open to the left of the screen.
...
```
### Tags and Taxonomies
#### Show number of tags
The number of tags and taxonomies (including categories) that should be shown can be configured so that any more than this value will only be accessible when clicking the All Tags button. This is to ensure a large number of tags or categories can be easily managed without consuming excess screen real estate. Edit the `numberOfTagsShown` parameter and set accordingly.
```yaml
[params]
...
numberOfTagsShown = 14 # Applies for all other default & custom taxonomies. e.g categories, brands see https://gohugo.io/content-management/taxonomies#what-is-a-taxonomy
...
```
#### Number of tags example
![Tags](https://github.com/chipzoller/hugo-clarity/blob/master/images/tags.png)
<!-- mark -->
### Table of contents
Each article can optionally have a table of contents (TOC) generated for it based on top-level links. By configuring the `toc` parameter in the article frontmatter and setting it to `true`, a TOC will be generated only for that article. The TOC will then render under the featured image.
#### Table of contents (TOC) example
![Article table of contents](https://github.com/chipzoller/hugo-clarity/blob/master/images/article-toc.png)
exampleSite/content/docs/clarity/customize.md
@@ -75,56 +75,6 @@
If using Google Analytics, configure the `ga_analytics` global parameter in your site with your ID.
### Blog directory
Edit the `config.toml` file and change the `mainSections` key. Values will be directories where the blogs reside.
```yaml
[params]
...
mainSections = ["posts", "docs", "blogs"]
...
```
For more info, see the [Hugo docs](https://gohugo.io/functions/where/#mainsections).
### Mobile menu positioning
The navigation menu when mobile browsing can be configured in `config.toml` to open right or left depending on preference. The "hamburger" menu icon will always display in the upper right hand corner regardless.
```yaml
[params]
...
mobileNavigation = "left" # Mobile nav menu will open to the left of the screen.
...
```
### Tags and Taxonomies
#### Show number of tags
The number of tags and taxonomies (including categories) that should be shown can be configured so that any more than this value will only be accessible when clicking the All Tags button. This is to ensure a large number of tags or categories can be easily managed without consuming excess screen real estate. Edit the `numberOfTagsShown` parameter and set accordingly.
```yaml
[params]
...
numberOfTagsShown = 14 # Applies for all other default & custom taxonomies. e.g categories, brands see https://gohugo.io/content-management/taxonomies#what-is-a-taxonomy
...
```
#### Number of tags example
![Tags](https://github.com/chipzoller/hugo-clarity/blob/master/images/tags.png)
<!-- mark -->
### Table of contents
Each article can optionally have a table of contents (TOC) generated for it based on top-level links. By configuring the `toc` parameter in the article frontmatter and setting it to `true`, a TOC will be generated only for that article. The TOC will then render under the featured image.
#### Table of contents (TOC) example
![Article table of contents](https://github.com/chipzoller/hugo-clarity/blob/master/images/article-toc.png)
### Custom CSS and JS
exampleSite/go.mod
@@ -2,4 +2,4 @@
go 1.15
require github.com/onweru/compose v0.0.0-20201006150935-3c1a2b1a5808 // indirect
require github.com/onweru/compose v0.0.0-20201008112336-b33efbb800d7 // indirect
exampleSite/go.sum
@@ -1,2 +1,4 @@
github.com/onweru/compose v0.0.0-20201006150935-3c1a2b1a5808 h1:6eVMm+cuEWeCodoHVzfjPc1+BOJMvm7boxrsXSMcbBg=
github.com/onweru/compose v0.0.0-20201006150935-3c1a2b1a5808/go.mod h1:tf1kQIBUcwJ/3mRFU5eiMrMvsDScVTK2IEFsZE3hZOc=
github.com/onweru/compose v0.0.0-20201008112336-b33efbb800d7 h1:tAyTSeyByfv2gPaqUrYi0kk0Z9jLTkAz24iSqLsotaA=
github.com/onweru/compose v0.0.0-20201008112336-b33efbb800d7/go.mod h1:tf1kQIBUcwJ/3mRFU5eiMrMvsDScVTK2IEFsZE3hZOc=