Merge pull request #59 from deining/contrib

Instructions to install theme as a model and spelling fixes.
This commit is contained in:
Fredrik Jonsson 2022-05-13 15:19:54 +02:00 • committed by GitHub
commit ed65193b72
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
19 changed files with 61 additions and 18 deletions

View file

@ -81,6 +81,26 @@ Hugo Extended version 0.88.1 or higher is required.
## Installation
### Hugo module
First of all, you need to turn your new or existing site into a hugo module.
From the root of your site:
```
$ hugo mod init github.com/me/my-site
```
Afterwards, declare the `zen` theme module as a dependency of your site:
From the root of your site:
```
$ hugo mod get github.com/frjo/hugo-theme-zen
```
### Git submodule
You can download and unpack the theme manually from Github but it's easier to use git to clone the repo.
From the root of your site:
@ -100,6 +120,16 @@ git submodule add https://github.com/frjo/hugo-theme-zen.git themes/zen
## Updating
### Hugo module
From the root of your site:
```
hugo mod get -u github.com/frjo/hugo-theme-zen
```
### Git submodule
From the root of your site:
```
@ -211,7 +241,7 @@ params:
category:
name: # * Feed category (iTunes).
subcategories: [] # Feed sub category (iTunes).
explicit: false/true # Feed explicit settting, default to false (iTunes).
explicit: false/true # Feed explicit setting, default to false (iTunes).
author: # Feed author (iTunes).
owner:
name: # Feed owner name (iTunes).
@ -290,7 +320,7 @@ To customise a js or sass file, copy it to the root assets directory and edit it
There is an `assets/sass/_custom.scss` file meant for your custom styles. Copy it to the root `assets/sass/_custom.scss` to use it.
The default styles in `assets/sass/_zen.scss` are boring but functional. You can easily overide them completely by placing an empty file named "_zen.scss" in root assets/sass directory.
The default styles in `assets/sass/_zen.scss` are boring but functional. You can easily override them completely by placing an empty file named "_zen.scss" in root assets/sass directory.
The sass files are by default built for production, compressed with fingerprint.
@ -308,7 +338,7 @@ Needed styles are in the `_zen.scss` file.
## Multilingual
Arabic, Danish, Finnish, English, Hebrew, French, German, Norwegian, Portugis and Swedish translations are included and you can easily add more to the `i18n` site directory. All but English and Swedish are contributed by users, thanks!
Arabic, Danish, Finnish, English, Hebrew, French, German, Norwegian, Portuguese and Swedish translations are included and you can easily add more to the `i18n` site directory. All but English and Swedish are contributed by users, thanks!
A language selector will be included on sites with more than one language. Add `languageName` to your language configuration, this is what will be displayed in the selector.
@ -386,7 +416,7 @@ If your server support php with the mail() command (very common) you can use the
If you have a SPF record for your domain, make sure the web server is listed or other mail server may mark the mail as spam.
Two types of spam protection is implemented. The form can only be posted after the user have moved the mouse or pressed the tab or enter key. The form have a "honypot" field that is invisible to humans but not to most spam boots. If that field is filled in the mail will not be sent.
Two types of spam protection are implemented. The form can only be posted after the user moved the mouse or pressed the tab or enter key. The form has a "honeypot" field that is invisible to humans but not to most spam boots. If that field is filled in the mail will not be sent.
Form validation is handled by HTML5 and there is some CSS to make it look nice.

3
exampleSite/.gitignore vendored Normal file
View file

@ -0,0 +1,3 @@
.hugo_build.lock
public/
resources/

View file

@ -1,7 +1,7 @@
---
title: "Hugo Zen theme"
baseURL: "https://example.org/"
theme: "zen"
theme: "github.com/frjo/hugo-theme-zen"
languageCode: "en-GB"
defaultContentLanguage: "en"
pluralizelisttitles: false

5
exampleSite/go.mod Normal file
View file

@ -0,0 +1,5 @@
module github.com/frjo/hugo-theme-zen/exampleSite
go 1.12
require github.com/frjo/hugo-theme-zen v2.1.0+incompatible // indirect

2
exampleSite/go.sum Normal file
View file

@ -0,0 +1,2 @@
github.com/frjo/hugo-theme-zen v2.1.0+incompatible h1:aDpNcrjQ+w+82oZXEG9ADZadk5nllXpHyN3wzJctD3M=
github.com/frjo/hugo-theme-zen v2.1.0+incompatible/go.mod h1:rnj+r21QUs67tvO9VRsMEggl1cB637lMtSTIZBQk/iA=

3
go.mod Normal file
View file

@ -0,0 +1,3 @@
module github.com/frjo/hugo-theme-zen
go 1.12

View file

@ -88,7 +88,7 @@ other = "هنا تكتب رسالتك…"
[contact_submit]
other = "ارسل"
[contact_honypot]
[contact_honeypot]
other = "تجاهل"
[lang_select_title]

View file

@ -88,7 +88,7 @@ other = "Skriv din beskeden her…"
[contact_submit]
other = "Send besked"
[contact_honypot]
[contact_honeypot]
other = "Spring over hvis du er et meneske"
[lang_select_title]

View file

@ -88,7 +88,7 @@ other = "Hier den Nachrichtentext eingeben…"
[contact_submit]
other = "Nachricht senden"
[contact_honypot]
[contact_honeypot]
other = "Überspringen, wenn du ein Mensch bist"
[lang_select_title]

View file

@ -88,7 +88,7 @@ other = "The messages goes here…"
[contact_submit]
other = "Send message"
[contact_honypot]
[contact_honeypot]
other = "Skip if you are a human"
[lang_select_title]

View file

@ -88,7 +88,7 @@ other = "Viesti kirjoitetaan tähän..."
[contact_submit]
other = "Lähetä viesti"
[contact_honypot]
[contact_honeypot]
other = "Jätä tämä väliin jos olet ihminen."
[lang_select_title]

View file

@ -88,7 +88,7 @@ other = "Contenu du message"
[contact_submit]
other = "Envoyer"
[contact_honypot]
[contact_honeypot]
other = "Ne faites pas attention à ça si vous êtes humain"
[lang_select_title]

View file

@ -88,7 +88,7 @@ other = "…הכנס מסר כאן"
[contact_submit]
other = "שליחת מסר"
[contact_honypot]
[contact_honeypot]
other = "דלג אם אתה בן אנוש"
[lang_select_title]

View file

@ -88,7 +88,7 @@ other = "Pesan anda di sini…"
[contact_submit]
other = "Kirim pesan"
[contact_honypot]
[contact_honeypot]
other = "Lewati jika anda manusia"
[lang_select_title]

View file

@ -88,7 +88,7 @@ other = "Skriv inn meldingen din her…"
[contact_submit]
other = "Send meldingen"
[contact_honypot]
[contact_honeypot]
other = "Hopp over om du er menneske."
[lang_select_title]

View file

@ -89,7 +89,7 @@ other = "As mensagens vão aqui…"
[contact_submit]
other = "Enviar menssagem"
[contact_honypot]
[contact_honeypot]
other = "Pular se você é humano"
[lang_select_title]

View file

@ -88,7 +88,7 @@ other = "Овде иде порука…"
[contact_submit]
other = "Пошаљи поруку"
[contact_honypot]
[contact_honeypot]
other = "Прескочи уколико си људско биће"
[lang_select_title]

View file

@ -88,7 +88,7 @@ other = "Meddelandet skrivs här…"
[contact_submit]
other = "Skicka meddelande"
[contact_honypot]
[contact_honeypot]
other = "Hoppa över ifall du är människa."
[lang_select_title]

View file

@ -7,7 +7,7 @@
<input type="text" id="edit-name" name="name" placeholder="{{ i18n "contact_name_placeholder" }}" tabindex="1" required autofocus><span></span>
<label for="edit-mail">{{ i18n "contact_mail" }}</label>
<input type="email" id="edit-mail" name="email" placeholder="{{ i18n "contact_mail_placeholder" }}" tabindex="2" required><span></span>
<input type="text" id="edit-url" class="hidden" name="url" placeholder="{{ i18n "contact_honypot" }}">
<input type="text" id="edit-url" class="hidden" name="url" placeholder="{{ i18n "contact_honeypot" }}">
<label for="edit-subject">{{ i18n "contact_subject" }}</label>
<input type="text" id="edit-subject" name="subject" placeholder="{{ i18n "contact_subject_placeholder" }}" tabindex="3" required><span></span>
<label for="edit-message">{{ i18n "contact_message" }}</label>