1
0
Fork 0
forked from sr2/hugo-sr2

Compare commits

..

10 commits

Author SHA1 Message Date
N-Pex
938f5efabd Add more meta data and move scripts to site
Makes it easy to add custom scripts by overriding _partials/scripts.html
2026-03-02 10:00:07 +01:00
irl
1c9895212e Merge branch 'main' of https://hosted.weblate.org/git/sr2/hugo-sr2 2026-02-17 20:38:06 +00:00
irl
46c881aa5e feat: add sv translations 2026-02-17 20:29:58 +00:00
irl
cdad1ec38f
Translated using Weblate (Swedish)
Currently translated at 100.0% (3 of 3 strings)

Translation: sr2/hugo-sr2
Translate-URL: https://hosted.weblate.org/projects/sr2/hugo-sr2/sv/
2026-02-17 21:29:05 +01:00
irl
1f4ee5dd22
Translated using Weblate (Toki Pona)
Currently translated at 100.0% (3 of 3 strings)

Translation: sr2/hugo-sr2
Translate-URL: https://hosted.weblate.org/projects/sr2/hugo-sr2/tok/
2026-02-17 21:29:05 +01:00
irl
3a539901bb feat: add more strings for translation 2026-02-17 20:28:00 +00:00
irl
96419e08dc Added translation using Weblate (Toki Pona) 2026-02-17 20:10:03 +00:00
irl
108a805f27 Add examples of usage to README 2026-02-17 19:54:10 +00:00
irl
a65dc757fe Add README.md 2026-02-17 19:50:32 +00:00
irl
40e78494ec fix: use sv for swedish 2026-02-17 19:33:06 +00:00
7 changed files with 70 additions and 26 deletions

30
README.md Normal file
View file

@ -0,0 +1,30 @@
SR2's Hugo Theme
================
[![Translation status](https://hosted.weblate.org/widget/sr2/hugo-sr2/svg-badge.svg)](https://hosted.weblate.org/engage/sr2/)
[![License](https://img.shields.io/badge/License-BSD_2--Clause-orange.svg)](https://opensource.org/licenses/BSD-2-Clause)
A Hugo theme created for SR2, with some simple page and blog layouts.
Examples
--------
* [SR2 Communications](https://www.sr2.uk/) ([Source Code](https://guardianproject.dev/sr2/www.sr2.uk/))
* [SR2 Professional Services](https://www.sr2pro.uk/) ([Source Code](https://guardianproject.dev/sr2/www.sr2pro.uk/))
* [499-501 Union Street (Management) Limited](https://www.499501.com/) ([Source Code](https://guardianproject.dev/sr2/www.499501.com/))
Translations
------------
The theme is created to support multiple languages.
Translations of strings in the themes are managed on Weblate.
<a href="https://hosted.weblate.org/engage/sr2/">
<img src="https://hosted.weblate.org/widget/sr2/hugo-sr2/multi-auto.svg" alt="Translation status" />
</a>
Licence & Copyright
-------------------
&copy; SR2 Communications Limited. See [LICENCE](./LICENCE) for details of the BSD 2 clause licence.

View file

@ -1,3 +1,10 @@
Published = 'Published' Published = 'Published'
Updated = 'Updated'
By = 'By %s' By = 'By %s'
'Show larger map' = 'Show larger map' 'Show larger map' = 'Show larger map'
Telephone = 'Telephone'
Email = 'Email'
Fax = 'Fax'
'Address' = 'Address'
'Our Team' = 'Our Team'
'Contact Us' = 'Contact Us'

View file

@ -1,3 +0,0 @@
Published = 'Publicerad'
By = 'Av %s'
'Show larger map' = 'Visa större karta'

9
i18n/sv.toml Normal file
View file

@ -0,0 +1,9 @@
Published = 'Publicerad'
Updated = 'Ändrad'
By = 'Av %s'
'Show larger map' = 'Visa större karta'
Telephone = 'Telefon'
Email = 'Epost'
Fax = 'Fax'
'Our Team' = 'Vårt Team'
'Contact Us' = 'Kontakta oss'

3
i18n/tok.toml Normal file
View file

@ -0,0 +1,3 @@
Published = "tenpo toki"
By = "tan %s"
'Show larger map' = "o suli e sitelen ma"

View file

@ -9,31 +9,27 @@
</title> </title>
{{ partialCached "head/css.html" . }} {{ partialCached "head/css.html" . }}
{{ partialCached "head/js.html" . }} {{ partialCached "head/js.html" . }}
{{ partial "head/scripts.html" . }}
<link rel="preconnect" href="https://fonts.googleapis.com" /> <link rel="preconnect" href="https://fonts.googleapis.com" />
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin /> <link rel="preconnect" href="https://fonts.gstatic.com" crossorigin />
<link <link
href="https://fonts.googleapis.com/css2?family=Assistant:wght@200..800&display=swap" href="https://fonts.googleapis.com/css2?family=Assistant:wght@200..800&display=swap"
rel="stylesheet" /> rel="stylesheet" />
{{ if not .IsHome }}
<!-- Meta data-->
{{- if .Description }}
<meta name="description" content="{{ .Description }}" />
<meta property="og:description" content="{{ .Description }}" />
{{- end }}
{{- if .Params.MetaKeywords }}
<meta name="kaywords" content="{{ .Params.MetaKeywords }}" />
{{- end }}
{{- if .Params.MetaAuthor }}
<meta name="author" content="{{ .Params.MetaAuthor }}" />
{{- end }}
<meta name="robots" content="index, follow" />
<meta name="language" content="{{ (page.Language.LanguageCode | default (site.LanguageCode | default "en")) }}" />
<meta property="og:title" content="{{ .Title }}" /> <meta property="og:title" content="{{ .Title }}" />
<meta property="og:url" content="{{ .RelPermalink }}" /> <meta property="og:url" content="{{ .RelPermalink }}" />
<meta property="og:description" content="{{ .Description }}" />
<meta property="og:type" content="website" /> <meta property="og:type" content="website" />
{{ end }}
{{ if eq .Name "Contact" }}
<script src="https://code.jquery.com/jquery-3.6.0.min.js"></script>
<script
id="zammad_form_script"
src="https://help.sr2.uk/assets/form/form.js"></script>
<script>
$(function () {
$("#zammad-feedback-form").ZammadForm({
agreementMessage: {{ site.Params.feedback.agreementMessage }},
messageSubmit:{{ site.Params.feedback.messageSubmit }},
messageThankYou:{{ site.Params.feedback.messageThankYou }},
showTitle: false,
noCSS: true,
});
});
</script>
{{ end }}

View file

@ -0,0 +1,2 @@
<!-- Use this file to add additional scripts you might need -->