From 2f694796470b0c3f10c97c720df8a46fd3b09b17 Mon Sep 17 00:00:00 2001 From: Henk Verlinde Date: Fri, 10 Sep 2021 16:38:32 +0200 Subject: [PATCH] feat: add multilingual support --- assets/scss/components/_buttons.scss | 9 ++ config/_default/config.toml | 28 +---- config/_default/languages.toml | 18 ++++ config/_default/markup.toml | 29 ++++++ .../{menus.toml => menus/menus.en.toml} | 0 config/_default/menus/menus.nl.toml | 39 +++++++ config/_default/params.toml | 2 +- config/postcss.config.js | 1 + content/{ => en}/_index.md | 0 content/{ => en}/blog/_index.md | 0 .../{ => en}/blog/say-hello-to-doks/index.md | 0 .../say-hello-to-doks/say-hello-to-doks.png | Bin content/{ => en}/contact/index.md | 0 content/{ => en}/contributors/_index.md | 0 .../contributors/henk-verlinde/_index.md | 0 content/{ => en}/docs/_index.md | 0 content/{ => en}/docs/help/_index.md | 0 content/{ => en}/docs/help/faq.md | 0 content/{ => en}/docs/help/how-to-update.md | 0 content/{ => en}/docs/help/troubleshooting.md | 0 content/{ => en}/docs/prologue/_index.md | 0 content/{ => en}/docs/prologue/commands.md | 0 .../{ => en}/docs/prologue/introduction.md | 0 content/{ => en}/docs/prologue/quick-start.md | 0 content/{ => en}/privacy-policy/index.md | 0 content/nl/_index.md | 11 ++ content/nl/contact/index.md | 10 ++ content/nl/contributors/_index.md | 10 ++ .../nl/contributors/henk-verlinde/_index.md | 12 +++ content/nl/docs/_index.md | 9 ++ content/nl/docs/help/_index.md | 9 ++ content/nl/docs/help/faq.md | 50 +++++++++ content/nl/docs/help/how-to-update.md | 32 ++++++ content/nl/docs/help/troubleshooting.md | 30 ++++++ content/nl/docs/prologue/_index.md | 9 ++ content/nl/docs/prologue/commands.md | 98 ++++++++++++++++++ content/nl/docs/prologue/introduction.md | 58 +++++++++++ content/nl/docs/prologue/quick-start.md | 69 ++++++++++++ content/nl/privacy-policy/index.md | 36 +++++++ i18n/en.toml | 2 + i18n/nl.toml | 2 + layouts/docs/single.html | 5 +- layouts/index.html | 62 +++++------ layouts/partials/header/header.html | 36 ++++++- 44 files changed, 619 insertions(+), 57 deletions(-) create mode 100644 config/_default/languages.toml create mode 100644 config/_default/markup.toml rename config/_default/{menus.toml => menus/menus.en.toml} (100%) create mode 100644 config/_default/menus/menus.nl.toml rename content/{ => en}/_index.md (100%) rename content/{ => en}/blog/_index.md (100%) rename content/{ => en}/blog/say-hello-to-doks/index.md (100%) rename content/{ => en}/blog/say-hello-to-doks/say-hello-to-doks.png (100%) rename content/{ => en}/contact/index.md (100%) rename content/{ => en}/contributors/_index.md (100%) rename content/{ => en}/contributors/henk-verlinde/_index.md (100%) rename content/{ => en}/docs/_index.md (100%) rename content/{ => en}/docs/help/_index.md (100%) rename content/{ => en}/docs/help/faq.md (100%) rename content/{ => en}/docs/help/how-to-update.md (100%) rename content/{ => en}/docs/help/troubleshooting.md (100%) rename content/{ => en}/docs/prologue/_index.md (100%) rename content/{ => en}/docs/prologue/commands.md (100%) rename content/{ => en}/docs/prologue/introduction.md (100%) rename content/{ => en}/docs/prologue/quick-start.md (100%) rename content/{ => en}/privacy-policy/index.md (100%) create mode 100644 content/nl/_index.md create mode 100644 content/nl/contact/index.md create mode 100644 content/nl/contributors/_index.md create mode 100644 content/nl/contributors/henk-verlinde/_index.md create mode 100644 content/nl/docs/_index.md create mode 100644 content/nl/docs/help/_index.md create mode 100644 content/nl/docs/help/faq.md create mode 100644 content/nl/docs/help/how-to-update.md create mode 100644 content/nl/docs/help/troubleshooting.md create mode 100644 content/nl/docs/prologue/_index.md create mode 100644 content/nl/docs/prologue/commands.md create mode 100644 content/nl/docs/prologue/introduction.md create mode 100644 content/nl/docs/prologue/quick-start.md create mode 100644 content/nl/privacy-policy/index.md create mode 100644 i18n/en.toml create mode 100644 i18n/nl.toml diff --git a/assets/scss/components/_buttons.scss b/assets/scss/components/_buttons.scss index be5f3a6..5e8cb2f 100644 --- a/assets/scss/components/_buttons.scss +++ b/assets/scss/components/_buttons.scss @@ -209,3 +209,12 @@ pre { .offcanvas-header .btn-close { margin-right: 0 !important; } + +.dropdown-toggle::after { + display: none; +} + +.dropdown-caret { + margin-left: -0.1875rem; + margin-right: -0.3125rem; +} diff --git a/config/_default/config.toml b/config/_default/config.toml index 7f7d1ed..96455f2 100644 --- a/config/_default/config.toml +++ b/config/_default/config.toml @@ -9,6 +9,11 @@ languageCode = "en-US" paginate = 7 rssLimit = 10 +# Multilingual +defaultContentLanguage = "en" +# disableLanguages = ["nl"] +# defaultContentLanguageInSubdir = true + # add redirects/headers [outputs] home = ["HTML", "RSS", "REDIRECTS", "HEADERS"] @@ -47,29 +52,6 @@ rel = "sitemap" dir = ":cacheDir/:project" maxAge = "10s" -[markup] - [markup.goldmark] - [markup.goldmark.extensions] - linkify = false - [markup.goldmark.parser] - autoHeadingID = true - autoHeadingIDType = "github" - [markup.goldmark.parser.attribute] - block = true - title = true - [markup.goldmark.renderer] - unsafe = true - [markup.highlight] - codeFences = false - guessSyntax = false - hl_Lines = "" - lineNoStart = 1 - lineNos = false - lineNumbersInTable = true - noClasses = false - style = "dracula" - tabWidth = 4 - [sitemap] changefreq = "weekly" filename = "sitemap.xml" diff --git a/config/_default/languages.toml b/config/_default/languages.toml new file mode 100644 index 0000000..7cb4265 --- /dev/null +++ b/config/_default/languages.toml @@ -0,0 +1,18 @@ +[en] + languageName = "English" + contentDir = "content/en" + weight = 10 + [en.params] + languageISO = "EN" + +[nl] + languageName = "Nederlands" + contentDir = "content/nl" + weight = 20 + [nl.params] + languageISO = "NL" + titleAddition = "Modern documentatie-thema" + description = "Doks is een Hugo-thema waarmee je moderne documentatie-websites kunt bouwen die veilig, snel en klaar voor SEO zijn — standaard." + titleHome = "Doks thema" + footer = "Mogelijk gemaakt door Netlify, Hugo, en Doks" + alertText = "Introductie van het Doks-kinderthema, verschillende DX + UX-updates en meer! Bekijk Doks v0.2" diff --git a/config/_default/markup.toml b/config/_default/markup.toml new file mode 100644 index 0000000..2880e30 --- /dev/null +++ b/config/_default/markup.toml @@ -0,0 +1,29 @@ +defaultMarkdownHandler = "goldmark" + +[goldmark] + [goldmark.extensions] + linkify = false + [goldmark.parser] + autoHeadingID = true + autoHeadingIDType = "github" + [goldmark.parser.attribute] + block = true + title = true + [goldmark.renderer] + unsafe = true + +[highlight] + codeFences = false + guessSyntax = false + hl_Lines = "" + lineNoStart = 1 + lineNos = false + lineNumbersInTable = true + noClasses = false + style = "dracula" + tabWidth = 4 + +[tableOfContents] + endLevel = 3 + ordered = false + startLevel = 2 diff --git a/config/_default/menus.toml b/config/_default/menus/menus.en.toml similarity index 100% rename from config/_default/menus.toml rename to config/_default/menus/menus.en.toml diff --git a/config/_default/menus/menus.nl.toml b/config/_default/menus/menus.nl.toml new file mode 100644 index 0000000..e530352 --- /dev/null +++ b/config/_default/menus/menus.nl.toml @@ -0,0 +1,39 @@ +[[docs]] + name = "Prologue" + weight = 10 + identifier = "prologue" + url = "/docs/prologue/" + +[[docs]] + name = "Help" + weight = 60 + identifier = "help" + url = "/docs/help/" + +[[main]] + name = "Docs" + url = "/docs/prologue/introduction/" + weight = 10 + +# [[main]] +# name = "Blog" +# url = "/blog/" +# weight = 20 + +[[social]] + name = "GitHub" + pre = "" + url = "https://github.com/h-enk/doks" + post = "v0.1.0" + weight = 10 + +[[social]] + name = "Twitter" + pre = "" + url = "https://twitter.com/getdoks" + weight = 20 + +# [[footer]] +# name = "Privacy" +# url = "/privacy-policy/" +# weight = 10 diff --git a/config/_default/params.toml b/config/_default/params.toml index 5c5faaa..2463566 100644 --- a/config/_default/params.toml +++ b/config/_default/params.toml @@ -76,5 +76,5 @@ editPage = false highLight = true kaTex = false collapsibleSidebar = true - multilingualMode = false # Not yet functional + multilingualMode = true docsVersioning = false # Not yet functional diff --git a/config/postcss.config.js b/config/postcss.config.js index d5edc25..b6891e2 100644 --- a/config/postcss.config.js +++ b/config/postcss.config.js @@ -27,6 +27,7 @@ module.exports = { './assets/scss/components/_syntax.scss', './assets/scss/components/_search.scss', './assets/scss/common/_dark.scss', + './node_modules/bootstrap/scss/_dropdown.scss', './node_modules/katex/dist/katex.css', ]), ], diff --git a/content/_index.md b/content/en/_index.md similarity index 100% rename from content/_index.md rename to content/en/_index.md diff --git a/content/blog/_index.md b/content/en/blog/_index.md similarity index 100% rename from content/blog/_index.md rename to content/en/blog/_index.md diff --git a/content/blog/say-hello-to-doks/index.md b/content/en/blog/say-hello-to-doks/index.md similarity index 100% rename from content/blog/say-hello-to-doks/index.md rename to content/en/blog/say-hello-to-doks/index.md diff --git a/content/blog/say-hello-to-doks/say-hello-to-doks.png b/content/en/blog/say-hello-to-doks/say-hello-to-doks.png similarity index 100% rename from content/blog/say-hello-to-doks/say-hello-to-doks.png rename to content/en/blog/say-hello-to-doks/say-hello-to-doks.png diff --git a/content/contact/index.md b/content/en/contact/index.md similarity index 100% rename from content/contact/index.md rename to content/en/contact/index.md diff --git a/content/contributors/_index.md b/content/en/contributors/_index.md similarity index 100% rename from content/contributors/_index.md rename to content/en/contributors/_index.md diff --git a/content/contributors/henk-verlinde/_index.md b/content/en/contributors/henk-verlinde/_index.md similarity index 100% rename from content/contributors/henk-verlinde/_index.md rename to content/en/contributors/henk-verlinde/_index.md diff --git a/content/docs/_index.md b/content/en/docs/_index.md similarity index 100% rename from content/docs/_index.md rename to content/en/docs/_index.md diff --git a/content/docs/help/_index.md b/content/en/docs/help/_index.md similarity index 100% rename from content/docs/help/_index.md rename to content/en/docs/help/_index.md diff --git a/content/docs/help/faq.md b/content/en/docs/help/faq.md similarity index 100% rename from content/docs/help/faq.md rename to content/en/docs/help/faq.md diff --git a/content/docs/help/how-to-update.md b/content/en/docs/help/how-to-update.md similarity index 100% rename from content/docs/help/how-to-update.md rename to content/en/docs/help/how-to-update.md diff --git a/content/docs/help/troubleshooting.md b/content/en/docs/help/troubleshooting.md similarity index 100% rename from content/docs/help/troubleshooting.md rename to content/en/docs/help/troubleshooting.md diff --git a/content/docs/prologue/_index.md b/content/en/docs/prologue/_index.md similarity index 100% rename from content/docs/prologue/_index.md rename to content/en/docs/prologue/_index.md diff --git a/content/docs/prologue/commands.md b/content/en/docs/prologue/commands.md similarity index 100% rename from content/docs/prologue/commands.md rename to content/en/docs/prologue/commands.md diff --git a/content/docs/prologue/introduction.md b/content/en/docs/prologue/introduction.md similarity index 100% rename from content/docs/prologue/introduction.md rename to content/en/docs/prologue/introduction.md diff --git a/content/docs/prologue/quick-start.md b/content/en/docs/prologue/quick-start.md similarity index 100% rename from content/docs/prologue/quick-start.md rename to content/en/docs/prologue/quick-start.md diff --git a/content/privacy-policy/index.md b/content/en/privacy-policy/index.md similarity index 100% rename from content/privacy-policy/index.md rename to content/en/privacy-policy/index.md diff --git a/content/nl/_index.md b/content/nl/_index.md new file mode 100644 index 0000000..009034f --- /dev/null +++ b/content/nl/_index.md @@ -0,0 +1,11 @@ +--- +title : "Modern documentatie-thema" +description: "Doks is een Hugo-thema waarmee je moderne documentatie-websites kunt bouwen die veilig, snel en klaar voor SEO zijn — standaard." +lead: "Doks is een Hugo-thema waarmee je moderne documentatie-websites kunt bouwen die veilig, snel en klaar voor SEO zijn — standaard." +date: 2020-10-06T08:47:36+00:00 +lastmod: 2020-10-06T08:47:36+00:00 +draft: false +images: [] +--- + +:cow: diff --git a/content/nl/contact/index.md b/content/nl/contact/index.md new file mode 100644 index 0000000..795089f --- /dev/null +++ b/content/nl/contact/index.md @@ -0,0 +1,10 @@ +--- +title: "Contact" +description: "Drop us an email." +date: 2020-08-27T19:25:12+02:00 +lastmod: 2020-08-27T19:25:12+02:00 +draft: true +images: [] +--- + +{{< email user="hello" domain="getdoks.org" >}} diff --git a/content/nl/contributors/_index.md b/content/nl/contributors/_index.md new file mode 100644 index 0000000..e225f34 --- /dev/null +++ b/content/nl/contributors/_index.md @@ -0,0 +1,10 @@ +--- +title: "Contributors" +description: "The Doks contributors." +date: 2020-10-06T08:50:29+00:00 +lastmod: 2020-10-06T08:50:29+00:00 +draft: false +images: [] +--- + +The Doks contributors. diff --git a/content/nl/contributors/henk-verlinde/_index.md b/content/nl/contributors/henk-verlinde/_index.md new file mode 100644 index 0000000..f775534 --- /dev/null +++ b/content/nl/contributors/henk-verlinde/_index.md @@ -0,0 +1,12 @@ +--- +title: "Henk Verlinde" +description: "Creator of Hyas." +date: 2020-10-06T08:50:45+00:00 +lastmod: 2020-10-06T08:50:45+00:00 +draft: false +images: [] +--- + +Creator of Hyas. + +[@HenkVerlinde](https://twitter.com/henkverlinde) diff --git a/content/nl/docs/_index.md b/content/nl/docs/_index.md new file mode 100644 index 0000000..f807c65 --- /dev/null +++ b/content/nl/docs/_index.md @@ -0,0 +1,9 @@ +--- +title : "Docs" +description: "Docs Doks." +lead: "" +date: 2020-10-06T08:48:23+00:00 +lastmod: 2020-10-06T08:48:23+00:00 +draft: false +images: [] +--- diff --git a/content/nl/docs/help/_index.md b/content/nl/docs/help/_index.md new file mode 100644 index 0000000..bc503ec --- /dev/null +++ b/content/nl/docs/help/_index.md @@ -0,0 +1,9 @@ +--- +title: "Help" +description: "Help Doks." +lead: "" +date: 2020-10-06T08:49:15+00:00 +lastmod: 2020-10-06T08:49:15+00:00 +draft: false +images: [] +--- diff --git a/content/nl/docs/help/faq.md b/content/nl/docs/help/faq.md new file mode 100644 index 0000000..f0c3bb4 --- /dev/null +++ b/content/nl/docs/help/faq.md @@ -0,0 +1,50 @@ +--- +title: "FAQ" +description: "Answers to frequently asked questions." +lead: "Answers to frequently asked questions." +date: 2020-10-06T08:49:31+00:00 +lastmod: 2020-10-06T08:49:31+00:00 +draft: false +images: [] +menu: + docs: + parent: "help" +weight: 630 +toc: true +--- + +## Hyas? + +Doks is a [Hyas theme](https://gethyas.com/themes/) build by the creator of Hyas. + +## Footer notice? + +Please keep it in place. + +## Keyboard shortcuts for search? + +- focus: `Ctrl + /` +- select: `↓` and `↑` +- open: `Enter` +- close: `Esc` + +## Other documentation? + +- [Netlify](https://docs.netlify.com/) +- [Hugo](https://gohugo.io/documentation/) + +## Can I get support? + +Create a topic: + +- [Netlify Community](https://community.netlify.com/) +- [Hugo Forums](https://discourse.gohugo.io/) +- [Doks Discussions](https://github.com/h-enk/doks/discussions) + +## Contact the creator? + +Send `h-enk` a message: + +- [Netlify Community](https://community.netlify.com/) +- [Hugo Forums](https://discourse.gohugo.io/) +- [Doks Discussions](https://github.com/h-enk/doks/discussions) diff --git a/content/nl/docs/help/how-to-update.md b/content/nl/docs/help/how-to-update.md new file mode 100644 index 0000000..f9bb36b --- /dev/null +++ b/content/nl/docs/help/how-to-update.md @@ -0,0 +1,32 @@ +--- +title: "How to Update" +description: "Regularly update the installed npm packages to keep your Doks website stable, usable, and secure." +lead: "Regularly update the installed npm packages to keep your Doks website stable, usable, and secure." +date: 2020-11-12T13:26:54+01:00 +lastmod: 2020-11-12T13:26:54+01:00 +draft: false +images: [] +menu: + docs: + parent: "help" +weight: 610 +toc: true +--- + +{{< alert icon="💡" text="Learn more about semantic versioning and advanced range syntax." />}} + +## Check for outdated packages + +The [`npm outdated`](https://docs.npmjs.com/cli/v7/commands/npm-outdated) command will check the registry to see if any (or, specific) installed packages are currently outdated: + +```bash +npm outdated [[<@scope>/] ...] +``` + +## Update packages + +The [`npm update`](https://docs.npmjs.com/cli/v7/commands/npm-update) command will update all the packages listed to the latest version (specified by the tag config), respecting semver: + +```bash +npm update [...] +``` diff --git a/content/nl/docs/help/troubleshooting.md b/content/nl/docs/help/troubleshooting.md new file mode 100644 index 0000000..0d52dbb --- /dev/null +++ b/content/nl/docs/help/troubleshooting.md @@ -0,0 +1,30 @@ +--- +title: "Troubleshooting" +description: "Solutions to common problems." +lead: "Solutions to common problems." +date: 2020-11-12T15:22:20+01:00 +lastmod: 2020-11-12T15:22:20+01:00 +draft: false +images: [] +menu: + docs: + parent: "help" +weight: 620 +toc: true +--- + +## Problems updating npm packages + +Delete the `./node_modules` folder, and run again: + +```bash +npm install +``` + +## Problems with cache + +Delete the temporary directories: + +```bash +npm run clean +``` diff --git a/content/nl/docs/prologue/_index.md b/content/nl/docs/prologue/_index.md new file mode 100644 index 0000000..c3c1c40 --- /dev/null +++ b/content/nl/docs/prologue/_index.md @@ -0,0 +1,9 @@ +--- +title : "Prologue" +description: "Prologue Doks." +lead: "" +date: 2020-10-06T08:48:45+00:00 +lastmod: 2020-10-06T08:48:45+00:00 +draft: false +images: [] +--- diff --git a/content/nl/docs/prologue/commands.md b/content/nl/docs/prologue/commands.md new file mode 100644 index 0000000..e647a98 --- /dev/null +++ b/content/nl/docs/prologue/commands.md @@ -0,0 +1,98 @@ +--- +title: "Commands" +description: "Doks comes with commands for common tasks." +lead: "Doks comes with commands for common tasks." +date: 2020-10-13T15:21:01+02:00 +lastmod: 2020-10-13T15:21:01+02:00 +draft: false +images: [] +menu: + docs: + parent: "prologue" +weight: 130 +toc: true +--- + +{{< alert icon="💡" text="You can change the commands in the scripts section of `./package.json`." />}} + +## create + +Create new content for your site: + +```bash +npm run create [path] [flags] +``` + +See also the Hugo docs: [hugo new](https://gohugo.io/commands/hugo_new/). + +## lint + +Check scripts, styles, and markdown for errors: + +```bash +npm run lint +``` + +### scripts + +Check scripts for errors: + +```bash +npm run lint:scripts [-- --fix] +``` + +### styles + +Check styles for errors: + +```bash +npm run lint:styles [-- --fix] +``` + +### markdown + +Check markdown for errors: + +```bash +npm run lint:markdown [-- --fix] +``` + +## clean + +Delete temporary directories: + +```bash +npm run clean +``` + +## start + +Start local development server: + +```bash +npm run start +``` + +## build + +Build production website: + +```bash +npm run build +``` + +### functions + +Build Lambda functions: + +```bash +npm run build:functions +``` + +### preview + +Build production website including draft and future content: + +```bash +npm run build:preview +``` diff --git a/content/nl/docs/prologue/introduction.md b/content/nl/docs/prologue/introduction.md new file mode 100644 index 0000000..f215533 --- /dev/null +++ b/content/nl/docs/prologue/introduction.md @@ -0,0 +1,58 @@ +--- +title: "Introduction" +description: "Doks is a Hugo theme helping you build modern documentation websites that are secure, fast, and SEO-ready — by default." +lead: "Doks is a Hugo theme helping you build modern documentation websites that are secure, fast, and SEO-ready — by default." +date: 2020-10-06T08:48:57+00:00 +lastmod: 2020-10-06T08:48:57+00:00 +draft: false +images: [] +menu: + docs: + parent: "prologue" +weight: 100 +toc: true +--- + +## Get started + +There are two main ways to get started with Doks: + +### Tutorial + +{{< alert icon="👉" text="The Tutorial is intended for novice to intermediate users." />}} + +Step-by-step instructions on how to start a new Doks project. [Tutorial →](https://getdoks.org/tutorial/introduction/) + +### Quick Start + +{{< alert icon="👉" text="The Quick Start is intended for intermediate to advanced users." />}} + +One page summary of how to start a new Doks project. [Quick Start →]({{< relref "quick-start" >}}) + +## Go further + +Recipes, Reference Guides, Extensions, and Showcase. + +### Recipes + +Get instructions on how to accomplish common tasks with Doks. [Recipes →](https://getdoks.org/docs/recipes/project-configuration/) + +### Reference Guides + +Learn how to customize Doks to fully make it your own. [Reference Guides →](https://getdoks.org/docs/reference-guides/security/) + +### Extensions + +Get instructions on how to add even more to Doks. [Extensions →](https://getdoks.org/docs/extensions/breadcrumb-navigation/) + +### Showcase + +See what others have build with Doks. [Showcase →](https://getdoks.org/showcase/electric-blocks/) + +## Contributing + +Find out how to contribute to Doks. [Contributing →](https://getdoks.org/docs/contributing/how-to-contribute/) + +## Help + +Get help on Doks. [Help →]({{< relref "how-to-update" >}}) diff --git a/content/nl/docs/prologue/quick-start.md b/content/nl/docs/prologue/quick-start.md new file mode 100644 index 0000000..9282d3e --- /dev/null +++ b/content/nl/docs/prologue/quick-start.md @@ -0,0 +1,69 @@ +--- +title: "Quick Start" +description: "One page summary of how to start a new Doks project." +lead: "One page summary of how to start a new Doks project." +date: 2020-11-16T13:59:39+01:00 +lastmod: 2020-11-16T13:59:39+01:00 +draft: false +images: [] +menu: + docs: + parent: "prologue" +weight: 110 +toc: true +--- + +## Requirements + +Doks uses npm to centralize dependency management, making it [easy to update]({{< relref "how-to-update" >}}) resources, build tooling, plugins, and build scripts: + +- Download and install [Node.js](https://nodejs.org/) (it includes npm) for your platform. + +## Start a new Doks project + +Create a new site, change directories, install dependencies, and start development server. + +### Create a new site + +Doks is available as a child theme, and a starter theme: + +- Use the Doks child theme, if you do __not__ plan to customize a lot, and/or need future Doks updates. +- Use the Doks starter theme, if you plan to customize a lot, and/or do __not__ need future Doks updates. + +Not quite sure? Use the Doks child theme. + +#### Doks child theme + +```bash +git clone https://github.com/h-enk/doks-child-theme.git my-doks-site +``` + +#### Doks starter theme + +```bash +git clone https://github.com/h-enk/doks.git my-doks-site +``` + +### Change directories + +```bash +cd my-doks-site +``` + +### Install dependencies + +```bash +npm install +``` + +### Start development server + +```bash +npm run start +``` + +Doks will start the Hugo development webserver accessible by default at `http://localhost:1313`. Saved changes will live reload in the browser. + +## Other commands + +Doks comes with commands for common tasks. [Commands →]({{< relref "commands" >}}) diff --git a/content/nl/privacy-policy/index.md b/content/nl/privacy-policy/index.md new file mode 100644 index 0000000..6315024 --- /dev/null +++ b/content/nl/privacy-policy/index.md @@ -0,0 +1,36 @@ +--- +title: "Privacy Policy" +description: "We do not use cookies and we do not collect any personal data." +date: 2020-08-27T19:23:18+02:00 +lastmod: 2020-08-27T19:23:18+02:00 +draft: true +images: [] +--- + +__TLDR__: We do not use cookies and we do not collect any personal data. + +## Website visitors + +- No personal information is collected. +- No information is stored in the browser. +- No information is shared with, sent to or sold to third-parties. +- No information is shared with advertising companies. +- No information is mined and harvested for personal and behavioral trends. +- No information is monetized. + +### Information we collect and what we use it for + +We run [Plausible](https://plausible.io/) analytics on getdoks.org. The following information is collected: + +- __Page URL__. We track the page URL of each page view on this website. We use this to understand which pages have been viewed and how many times a particular page has been viewed. For example: _https://getdoks.org/_. +- __HTTP Referrer__. We use the referrer string to understand the number of visitors referred to this website from links on other sites. For example: _https://github.com/_. +- __Browser__. We use this to understand what browsers people use when visiting this website. This is derived from the User-Agent HTTP header. The full User-Agent is discarded. For example: _Chrome_. +- __Operating system__. We use this to understand what operating systems people use when visiting this website. We only use the brand of the operating system and don’t include the version number or any other details. This is derived from the User-Agent HTTP header. The full User-Agent is discarded. For example: _GNU/Linux_. +- __Device type__. We use this to understand what devices people use when visiting this website. This is derived from window.innerWidth. The actual width of the browser in pixels is discarded. For example: _Desktop_. +- __Visitor Country__. We look up the visitor’s country using the IP address. We do not track anything more granular than the country of origin and the IP address of the visitor is discarded. We never store IP addresses in our database or logs. For example: _Canada_. + +## Contact us + +[Contact us]({{< relref "contact/index.md" >}}) if you have any questions. + +Effective Date: _27th August 2020_ diff --git a/i18n/en.toml b/i18n/en.toml new file mode 100644 index 0000000..cb52685 --- /dev/null +++ b/i18n/en.toml @@ -0,0 +1,2 @@ +[get-started] + other = "Get Started" \ No newline at end of file diff --git a/i18n/nl.toml b/i18n/nl.toml new file mode 100644 index 0000000..f80323e --- /dev/null +++ b/i18n/nl.toml @@ -0,0 +1,2 @@ +[get-started] + other = "Aan de slag" \ No newline at end of file diff --git a/layouts/docs/single.html b/layouts/docs/single.html index c0f50f6..5c58c54 100644 --- a/layouts/docs/single.html +++ b/layouts/docs/single.html @@ -1,6 +1,6 @@ {{ define "main" }}
-
+
@@ -35,11 +35,14 @@ {{ if .Site.Params.editPage -}} {{ partial "main/edit-page.html" . }} {{ end -}} + {{ partial "main/docs-navigation.html" . }} +
{{ end }} \ No newline at end of file diff --git a/layouts/index.html b/layouts/index.html index 9f0c752..5496eda 100644 --- a/layouts/index.html +++ b/layouts/index.html @@ -6,7 +6,7 @@
@@ -14,38 +14,40 @@ {{ end }} {{ define "sidebar-prefooter" }} -
-
-
-
-

Security aware

-

Get A+ scores on Mozilla Observatory out of the box. Easily change the default Security Headers to suit your needs.

+ {{ if eq $.Site.Language.LanguageName "English" }} +
+
+
+
+

Security aware

+

Get A+ scores on Mozilla Observatory out of the box. Easily change the default Security Headers to suit your needs.

+
+
+

Fast by default ⚡️

+

Get 100 scores on Google Lighthouse by default. Doks removes unused css, prefetches links, and lazy loads images.

+
+
+

SEO-ready

+

Use sensible defaults for structured data, open graph, and Twitter cards. Or easily change the SEO settings to your liking.

+
-
-

Fast by default ⚡️

-

Get 100 scores on Google Lighthouse by default. Doks removes unused css, prefetches links, and lazy loads images.

-
-
-

SEO-ready

-

Use sensible defaults for structured data, open graph, and Twitter cards. Or easily change the SEO settings to your liking.

+
+
+

Full text search

+

Search your Doks site with FlexSearch. Easily customize index settings and search options to your liking.

+
+
+

Page layouts

+

Build pages with a landing page, blog, or documentation layout. Add custom sections and components to suit your needs.

+
+
+

Dark mode

+

Switch to a low-light UI with the click of a button. Change colors with variables to match your branding.

+
-
-
-

Full text search

-

Search your Doks site with FlexSearch. Easily customize index settings and search options to your liking.

-
-
-

Page layouts

-

Build pages with a landing page, blog, or documentation layout. Add custom sections and components to suit your needs.

-
-
-

Dark mode

-

Switch to a low-light UI with the click of a button. Change colors with variables to match your branding.

-
-
-
-
+
+ {{ end }} {{ end }} {{ define "sidebar-footer" }} diff --git a/layouts/partials/header/header.html b/layouts/partials/header/header.html index 75fc65e..3d23a4e 100644 --- a/layouts/partials/header/header.html +++ b/layouts/partials/header/header.html @@ -10,7 +10,7 @@