Rewrite README from AsciiDoc to Github-flavored Markdown.
Required to be listed on themes.gohugo.io.
This commit is contained in:
parent
ae9cdd8e47
commit
6ce250b863
106
README.adoc
106
README.adoc
|
@ -1,106 +0,0 @@
|
|||
= nocolor
|
||||
:project: hugo-theme-nocolor
|
||||
:uri-base: https://schlomp.space/tastytea/{project}
|
||||
:uri-archive: {uri-base}/archive/main.tar.gz
|
||||
:uri-hugo: https://gohugo.io/
|
||||
:uri-slick: https://github.com/spookey/slick
|
||||
:uri-slick-example: {uri-slick}/blob/master/_sites/example/config.toml
|
||||
:uri-opengraph: http://ogp.me/
|
||||
:uri-schema: https://schema.org/
|
||||
:uri-twittercards: https://developer.twitter.com/en/docs/tweets/optimize-with-cards/overview/abouts-cards.html
|
||||
:uri-hugo-doc-toc: https://gohugo.io/content-management/toc
|
||||
:uri-pygments: https://pygments.org/
|
||||
:uri-mozilla-aria-nav: https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/Roles/Navigation_Role
|
||||
|
||||
*nocolor* is a link:{uri-hugo}[Hugo] theme with no predefined colors and minimal
|
||||
styling. It is based on link:{uri-slick}[Slick].
|
||||
|
||||
== Features
|
||||
|
||||
* Supports taxonomies of tags, categories and series with their own pages.
|
||||
* RSS Feed with complete entries.
|
||||
* link:{uri-opengraph}[Open Graph], link:{uri-schema}[Schema.org] and
|
||||
link:{uri-twittercards}[Twitter Cards] support.
|
||||
* Fully customizable menu entries.
|
||||
* No JavaScript, no bundled fonts, no external requests.
|
||||
* Ability to inject own CSS file.
|
||||
|
||||
== Installation
|
||||
|
||||
[source,shell]
|
||||
--------------------------------------------------------------------------------
|
||||
git submodule add --branch main https://schlomp.space/tastytea/hugo-theme-nocolor.git themes/nocolor
|
||||
echo 'theme = "nocolor"' >> config.toml
|
||||
--------------------------------------------------------------------------------
|
||||
|
||||
Update with `git submodule update --remote`. If you don't keep your blog in a
|
||||
git repository, install it with `git clone
|
||||
https://schlomp.space/tastytea/hugo-theme-nocolor.git themes/nocolor` or unpack
|
||||
the link:{uri-archive}[archive] into `themes/nocolor`.
|
||||
|
||||
== Configuration & Modification
|
||||
|
||||
Please take a look at the link:{uri-slick-example}[configuration example for
|
||||
Slick]. It is valid for nocolor too, with these exceptions:
|
||||
|
||||
* `favicon` and `css` have to be in in the assets folder.
|
||||
|
||||
You can add things to the end of the `<head>` section by overwriting the partial
|
||||
template `extra_head.html` or above the footer by overwriting
|
||||
`extra_foot.html`. The common way to do it is to create
|
||||
`layouts/partials/extra_head.html` or `layouts/partials/extra_foot.html`,
|
||||
respectively.
|
||||
|
||||
=== Custom ARIA labels
|
||||
|
||||
Some elements can't be labeled by default because we don't know what's going to
|
||||
be in it. Custom link:{uri-mozilla-aria-nav}[ARIA labels] are supported for the
|
||||
top menu and the bottom menu.
|
||||
|
||||
.`config.toml`
|
||||
[source,toml]
|
||||
--------------------------------------------------------------------------------
|
||||
[params]
|
||||
[params.aria]
|
||||
menu_top = "Main"
|
||||
menu_bottom = "Contact"
|
||||
--------------------------------------------------------------------------------
|
||||
|
||||
=== Syntax highlighting with Asciidoctor
|
||||
|
||||
If you want source code highlighting with AsciiDoc, you'll need pygmentize from
|
||||
the package link:{uri-pygments}[pygments]. Set this in your config file:
|
||||
|
||||
.`config.toml`
|
||||
[source,toml]
|
||||
--------------------------------------------------------------------------------
|
||||
pygmentsCodefences = true
|
||||
pygmentsCodeFencesGuessSyntax = false
|
||||
pygmentsUseClasses = true
|
||||
--------------------------------------------------------------------------------
|
||||
|
||||
Run `pygmentize -L styles` for a list of available styles and generate a CSS
|
||||
file:
|
||||
|
||||
[source,shell]
|
||||
--------------------------------------------------------------------------------
|
||||
pygmentize -f html -S <style> -a .highlight \
|
||||
| grep -v '^[^\.]' | sed -E 's/ \.(\w+) \{/ \.tok-\1 {/' > static/syntax.css
|
||||
--------------------------------------------------------------------------------
|
||||
|
||||
And add `:source-highlighter: pygments` at the top of your posts, below the
|
||||
front matter. Make sure to include the generated CSS file.
|
||||
|
||||
== Good to know
|
||||
|
||||
Table of contents are only written when the word count exceeds 400 and the `toc`
|
||||
field in your content’s front matter is set to true. See
|
||||
link:{uri-hugo-doc-toc}[the Hugo documentation] for details. You can overwrite
|
||||
the template by adding the file `layouts/partials/toc.html` to your blog.
|
||||
|
||||
== Screenshots
|
||||
|
||||
link:{uri-base}/raw/branch/main/images/screenshot.png[
|
||||
image:{uri-base}/raw/branch/main/images/tn.png[Screenshot]]
|
||||
|
||||
include::{uri-base}/raw/branch/main/CONTRIBUTING.adoc[]
|
98
README.md
Normal file
98
README.md
Normal file
|
@ -0,0 +1,98 @@
|
|||
# nocolor
|
||||
|
||||
**nocolor** is a [Hugo](https://gohugo.io/) theme with no predefined colors and
|
||||
minimal styling. It is based on [Slick](https://github.com/spookey/slick).
|
||||
|
||||
## Features
|
||||
|
||||
* Supports taxonomies of tags, categories and series with their own pages.
|
||||
* RSS Feed with complete entries.
|
||||
* [Open Graph](http://ogp.me/), [Schema.org](https://schema.org/) and [Twitter
|
||||
Cards](https://developer.twitter.com/en/docs/tweets/optimize-with-cards/overview/abouts-cards.html)
|
||||
support.
|
||||
* Fully customizable menu entries.
|
||||
* No JavaScript, no bundled fonts, no external requests.
|
||||
* Ability to inject own CSS file.
|
||||
|
||||
## Installation
|
||||
|
||||
``` shell
|
||||
git submodule add --branch main https://schlomp.space/tastytea/hugo-theme-nocolor.git themes/nocolor
|
||||
echo 'theme = "nocolor"' >> config.toml
|
||||
```
|
||||
|
||||
Update with `git submodule update --remote`. If you don't keep your blog in a
|
||||
git repository, install it with `git clone
|
||||
https://schlomp.space/tastytea/hugo-theme-nocolor.git themes/nocolor` or unpack
|
||||
the
|
||||
[archive](https://schlomp.space/tastytea/hugo-theme-nocolor/archive/main.tar.gz)
|
||||
into `themes/nocolor`.
|
||||
|
||||
## Configuration & Modification
|
||||
|
||||
Please take a look at the [configuration example for
|
||||
Slick](https://github.com/spookey/slick/blob/master/_sites/example/config.toml). It
|
||||
is valid for nocolor too, with these exceptions:
|
||||
|
||||
* `favicon` and `css` have to be in in the assets folder.
|
||||
|
||||
You can add things to the end of the `<head>` section by overwriting the partial
|
||||
template `extra_head.html` or above the footer by overwriting
|
||||
`extra_foot.html`. The common way to do it is to create
|
||||
`layouts/partials/extra_head.html` or `layouts/partials/extra_foot.html`,
|
||||
respectively.
|
||||
|
||||
### Custom ARIA labels
|
||||
|
||||
Some elements can't be labeled by default because we don't know what's going to
|
||||
be in it. Custom [ARIA
|
||||
labels](https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/Roles/Navigation_Role)
|
||||
are supported for the top menu and the bottom menu.
|
||||
|
||||
.`config.toml`
|
||||
|
||||
``` toml
|
||||
[params]
|
||||
[params.aria]
|
||||
menu_top = "Main"
|
||||
menu_bottom = "Contact"
|
||||
```
|
||||
|
||||
### Syntax highlighting with Asciidoctor
|
||||
|
||||
If you want source code highlighting with AsciiDoc, you'll need pygmentize from
|
||||
the package [pygments](https://pygments.org/). Set this in your config file:
|
||||
|
||||
.`config.toml`
|
||||
|
||||
``` toml
|
||||
pygmentsCodefences = true
|
||||
pygmentsCodeFencesGuessSyntax = false
|
||||
pygmentsUseClasses = true
|
||||
```
|
||||
|
||||
Run `pygmentize -L styles` for a list of available styles and generate a CSS
|
||||
file:
|
||||
|
||||
``` shell
|
||||
pygmentize -f html -S <style> -a .highlight \
|
||||
| grep -v '^[^\.]' | sed -E 's/ \.(\w+) \{/ \.tok-\1 {/' > static/syntax.css
|
||||
```
|
||||
|
||||
And add `:source-highlighter: pygments` at the top of your posts, below the
|
||||
front matter. Make sure to include the generated CSS file.
|
||||
|
||||
## Good to know
|
||||
|
||||
Table of contents are only written when the word count exceeds 400 and the `toc`
|
||||
field in your content’s front matter is set to true. See [the Hugo
|
||||
documentation](https://gohugo.io/content-management/toc) for details. You can overwrite the template
|
||||
by adding the file `layouts/partials/toc.html` to your blog.
|
||||
|
||||
## Screenshots
|
||||
|
||||
[![Screenshot](https://schlomp.space/tastytea/hugo-theme-nocolor/raw/branch/main/images/tn.png)](https://schlomp.space/tastytea/hugo-theme-nocolor/raw/branch/main/images/screenshot.png)
|
||||
|
||||
## Contributing
|
||||
|
||||
See <https://schlomp.space/tastytea/hugo-theme-nocolor/src/branch/main/CONTRIBUTING.adoc>.
|
Reference in New Issue
Block a user