Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/vjeantet/hugo-theme-docport.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorvjeantet <valere.jeantet@gmail.com>2020-08-26 01:18:01 +0300
committervjeantet <valere.jeantet@gmail.com>2020-08-26 01:18:01 +0300
commit9229f60c97fe6eba1f6bc71166af347b78971ad8 (patch)
tree38fd2c1ea536af10fda68b67e9e7a4f48c8e62ec
parent552b6e64d212abf2680b801776b2d1972d37947e (diff)
update content
-rw-r--r--assets/sass/shortcodes/notice.scss3
-rw-r--r--exampleSite/content/content-organisation/_index.md18
-rw-r--r--exampleSite/content/content-organisation/customize-style/_index.md8
-rw-r--r--exampleSite/content/content-organisation/customize-style/colors/_index.md9
-rw-r--r--exampleSite/content/content-organisation/customize-style/disable/_index.md4
-rw-r--r--exampleSite/content/content-organisation/subpages.pngbin28919 -> 33121 bytes
-rw-r--r--exampleSite/content/create-page/_index.md33
-rw-r--r--exampleSite/content/create-page/control-page-menu/_index.md11
-rw-r--r--exampleSite/content/create-page/page-slide/_index.md26
-rw-r--r--exampleSite/content/create-page/set-your-homepage/_index.md7
-rw-r--r--exampleSite/content/docport-theme/_index.md20
-rw-r--r--exampleSite/content/docport-theme/credits/_index.md3
-rw-r--r--exampleSite/content/getting-start/installation/_index.md10
-rw-r--r--exampleSite/content/search/_index.md3
-rw-r--r--exampleSite/content/search/obscuripes13g.jpgbin216914 -> 0 bytes
-rw-r--r--exampleSite/resources/_gen/assets/scss/sass/shortcodes/notice.scss_f300667da4f5b5f84e1a9e0702b2fdde.content3
16 files changed, 87 insertions, 71 deletions
diff --git a/assets/sass/shortcodes/notice.scss b/assets/sass/shortcodes/notice.scss
index 276d2e6..e6291c5 100644
--- a/assets/sass/shortcodes/notice.scss
+++ b/assets/sass/shortcodes/notice.scss
@@ -18,7 +18,8 @@ $color_transparent : transparent ;
margin-top: 0px;
box-sizing: border-box;
box-shadow: inset 4px 0 0 black;
- background-color: lighten(black,90%)
+ background-color: lighten(black,90%);
+ font-size: smaller;
}
diff --git a/exampleSite/content/content-organisation/_index.md b/exampleSite/content/content-organisation/_index.md
index 4c9f414..368f4ed 100644
--- a/exampleSite/content/content-organisation/_index.md
+++ b/exampleSite/content/content-organisation/_index.md
@@ -33,14 +33,14 @@ To link pages to each other, place them in a folders hierarchy
**other.md** files are considered as "subpages"
{{%/alert%}}
-### Subpages ⊷
+## Subpages ⊷
Each other **.md** found in a section folder will be considered "subpages", for example, in the `content-organisation` folder there is 1 _index.md (the one your are currently reading) and 1 more files named "extramenu.md", they appear just under this page's title, look upper.
![agence](subpages.png?height=80px&classes=border,shadow)
-### Add header to a menu entry
+## Add header to a menu entry
in the page frontmatter, add a `head` param to insert any HTML code before the menu entry:
@@ -53,7 +53,7 @@ example to display a "Hello"
+++
```
-### Order sibling menu/page entries
+## Order sibling menu/page entries
in your frontmatter add `weight` param with a number to order.
@@ -63,9 +63,9 @@ in your frontmatter add `weight` param with a number to order.
weight = 4
+++
```
-{{%info%}}add `ordersectionsby = "title"` in your config.toml to order menu entries by title{{%/info%}}
+{{%notice tip%}} you can order pages by title by adding `ordersectionsby = "title"` in your config.toml {{%/notice%}}
-### Hide a menu entry
+## Hide a menu entry
in your frontmatter add `hidden=true` param.
```toml
@@ -75,7 +75,7 @@ in your frontmatter add `hidden=true` param.
+++
```
-### Unfolded menu entry by default
+## Keep menu entry opened by default
One or more menuentries can be displayed unfolded by default. (like the "Getting start" menu entry in this website)
@@ -89,12 +89,8 @@ example :
alwaysopen = true
```
-### Folder structure and file name
-Content organization **is** your `content` folder structure.
-
-
-### Homepage
+## Homepage
Find out how to [customize homepage]({{%relref "create-page/set-your-homepage/_index.md"%}})
diff --git a/exampleSite/content/content-organisation/customize-style/_index.md b/exampleSite/content/content-organisation/customize-style/_index.md
index 45f7fa0..4979fb4 100644
--- a/exampleSite/content/content-organisation/customize-style/_index.md
+++ b/exampleSite/content/content-organisation/customize-style/_index.md
@@ -8,7 +8,7 @@ You can change the style and behavior of the theme without touching its source c
* inject your own html, css or js into the page
* overide existing css or js with your own files
-{{%notice note %}}
+{{%notice warning %}}
No needs to copy the entire theme to customize some parts
Bellow are solutions to avoid copying the entire theme into your own codebase.
{{%/notice%}}
@@ -24,7 +24,7 @@ Create a file as `layouts/partials/head.html`
└── head.html
```
-write your own content like (an example from @nzbart):
+write your own content like :
```html
<link rel="stylesheet" href="/css/custom.css">
<script src="/js/custom.js"></script>
@@ -48,9 +48,9 @@ $(tweakPage)
now feel free to add the JS, CSS code you want :)
-## Add custom HTML before and after key elements of this theme :
+## Add custom HTML before and after key elements of this theme
-* @see [site placehors]({{%relref "content-organisation/placeholders/_index.md"%}})
+* @see [site placeholders]({{%relref "content-organisation/placeholders/_index.md"%}})
## Overide existing CSS or JS
diff --git a/exampleSite/content/content-organisation/customize-style/colors/_index.md b/exampleSite/content/content-organisation/customize-style/colors/_index.md
index 9acf7f2..7e348e7 100644
--- a/exampleSite/content/content-organisation/customize-style/colors/_index.md
+++ b/exampleSite/content/content-organisation/customize-style/colors/_index.md
@@ -11,18 +11,21 @@ You can choose this main color by editing the `config.toml` file.
This color is mainly used for menu.
-{{% alert theme="warning" %}}When omited, a random value is computed on each build {{%/alert%}}
+{{% notice primary %}}When omited, a random value is computed on each build {{%/notice%}}
```toml
[params]
color_main = "#B0B0B0"
```
## 2nd color (optional)
-{{% alert theme="warning" %}}When omited, this color is computed from main color with a saturated version{{%/alert%}}
+{{% notice primary %}}When omited, this color is computed from main color with a saturated version{{%/notice %}}
This color is mainly used for links.
```toml
[params]
- color_over = "red"
+ color_second = "red"
```
+
+## Random colors
+{{%alert success%}}**Random colors** : comment theses two params in your config.toml, you will have random colors on each build... {{%/alert%}} \ No newline at end of file
diff --git a/exampleSite/content/content-organisation/customize-style/disable/_index.md b/exampleSite/content/content-organisation/customize-style/disable/_index.md
index 8b16b12..07bd1a3 100644
--- a/exampleSite/content/content-organisation/customize-style/disable/_index.md
+++ b/exampleSite/content/content-organisation/customize-style/disable/_index.md
@@ -6,13 +6,13 @@ subpage=true
You can disable feature in docport by changing some params in `config.toml`
-## hide Next / Prev Chevrons
+## Hide Next Page Chevrons
```toml
[params]
disableNavChevron = true
```
-## hide Search box in side menu
+## Hide Search box in side menu
```toml
[params]
disableSearch = true
diff --git a/exampleSite/content/content-organisation/subpages.png b/exampleSite/content/content-organisation/subpages.png
index b2a00f6..528b828 100644
--- a/exampleSite/content/content-organisation/subpages.png
+++ b/exampleSite/content/content-organisation/subpages.png
Binary files differ
diff --git a/exampleSite/content/create-page/_index.md b/exampleSite/content/create-page/_index.md
index aadb076..9a2ff6f 100644
--- a/exampleSite/content/create-page/_index.md
+++ b/exampleSite/content/create-page/_index.md
@@ -18,9 +18,9 @@ tags:
---
-Hugo-theme-docport defines two types of pages. _Default_ and _Slide_.
+Hugo-theme-docport uses two types of pages. _Default_ and [_Slide_]({{%relref "create-page/page-slide/_index.md"%}}).
-## Page layout
+## Page params
Each page may define a Front Matter in yaml, toml or json.
Hugo-theme-docport uses the following parameters on top of the existing ones :
@@ -28,17 +28,21 @@ Hugo-theme-docport uses the following parameters on top of the existing ones :
```toml
+++
title="Create Page"
-layout = "full"
-# - <empty> will show left navigation, table of content, breadcrumb
-# - "simple" - will hide right bar and breadcrumb
-# - "full" will hide left nav, right nav and breadcrumb
-# - "raw" - only the page content will display (usefull for homepage)
-#
-# other keys exists to control how to render this page in navigations (see "Navigation Appearance")
-#
+
+subpage = false # When a page is a subpage, it will be displayed bellow the parent page title, and not in the left menu
+
+
+# Ajust layout for your page
+hide_header=false # set true to hide site header
+hide_nav=false # set true to hide the left navigation menu
+hide_breadcrumb=false # set true to hide the breadcrumb
+hide_toc=false # set true to hide the right menu (table of contents)
+hide_footer=false #set true to hide the website footer
+++
```
+
+
## Ordering
Hugo provides a flexible way to handle order for your pages.
@@ -53,16 +57,7 @@ weight = 10
[{{%icon play_circle_filled%}}Read more on content organization]({{%relref "content-organisation/_index.md"%}})
-## Page as a slidedeck
-* **Slide** is a page that use the full screen to display its markdown content as a [reveals.js presentation](http://lab.hakim.se/reveal-js/).
-To tell Hugo-theme-docport to consider a page as a slide, just add a `type="slide"`in then frontmatter of your file. [{{%icon play_circle_filled%}}read more on page as slide]({{%relref "page-slide.md"%}})
-
-```toml
-+++
-type="slide"
-+++
-```
diff --git a/exampleSite/content/create-page/control-page-menu/_index.md b/exampleSite/content/create-page/control-page-menu/_index.md
index 384adc3..e584e8f 100644
--- a/exampleSite/content/create-page/control-page-menu/_index.md
+++ b/exampleSite/content/create-page/control-page-menu/_index.md
@@ -1,8 +1,10 @@
+++
-title="Navigation appearance"
+title="Navigation entries"
pre = "👻&nbsp;&nbsp;"
post = "&nbsp;&nbsp;👋"
subpage = true
+hidden = false
+weight = 300
+++
Each page is displayed on navigation bars
@@ -25,11 +27,10 @@ pre = "👻"
post = "👋"
# LEFT MENU ONLY (Sections)
-# Show a "MY SECTION" text before menu entry
-# as an exemple, on the Create Page a head="<hr/>" is set
-head = "MY SECTION"
+# as an exemple, on the Getting started Page a head="<hr/>" is set
+head = "<hr/>"
-# Menu opened by default
+# Menu opened by default (like the Getting started menu entry)
alwaysopen = false
+++
diff --git a/exampleSite/content/create-page/page-slide/_index.md b/exampleSite/content/create-page/page-slide/_index.md
index cbbf50e..b5cfbc2 100644
--- a/exampleSite/content/create-page/page-slide/_index.md
+++ b/exampleSite/content/create-page/page-slide/_index.md
@@ -5,8 +5,6 @@ date = "2017-04-24T18:36:24+02:00"
weight = 90
subpage = true
-
-
hide_header=false
hide_nav=false
hide_breadcrumb=false
@@ -15,14 +13,28 @@ hide_footer=false
+++
-A basic md content page can be rendered as a reveal.js presentation full screen.
+A basic .md file can be rendered as a reveal.js presentation full screen.
+
+{{% notice %}}
+**Page As a SlideDeck** is a page that use the full screen to display its markdown content as a [reveals.js presentation](http://lab.hakim.se/reveal-js/).
+\
+[{{%icon aspect_ratio%}} click here to view an example]({{%relref "myslide.md"%}})
+
+{{%/notice%}}
+
+To tell Hugo-theme-docport to consider a page as a slide, just add a `type="slide"`in then frontmatter of your file.
+
+```toml
++++
+type="slide"
++++
+```
-* [{{%icon aspect_ratio%}} click here to view an example]({{%relref "myslide.md"%}})
-{{%alert info%}}You can, also, **embed presentation in a page** as a small box, using the [revealjs]({{% relref "shortcodes/revealjs/_index.md"%}}) shortcode in your md file.{{%/alert%}}
+{{%alert success%}}**Tip :** You can, also, **embed presentation in a page** as a small box, using the [revealjs]({{% relref "shortcodes/revealjs/_index.md"%}}) shortcode in your md file.{{%/alert%}}
-## Formating
+## Formating your content
Use your common Markdown syntax you use in Hugo, don't forget, you can put html tags too.
{{%notice info %}} Special syntax (in html comment) is available for adding attributes to Markdown elements. This is useful for fragments, amongst other things.
@@ -31,7 +43,7 @@ Use your common Markdown syntax you use in Hugo, don't forget, you can put html
Please read the [{{%icon book%}} doc from hakimel](https://github.com/hakimel/reveal.js/#instructions)
-## Options
+## Presentation options
In the frontmatter of your page file, set **type** and **revealOptions** params
Your content will be served as a fullscreen revealjs presentation and revealOptions will be used to ajust its behaviour.
diff --git a/exampleSite/content/create-page/set-your-homepage/_index.md b/exampleSite/content/create-page/set-your-homepage/_index.md
index a81b51e..88486ad 100644
--- a/exampleSite/content/create-page/set-your-homepage/_index.md
+++ b/exampleSite/content/create-page/set-your-homepage/_index.md
@@ -8,11 +8,10 @@ title="Create homepage"
## Create a dedicated homepage
To tell Hugo-theme-docport to consider a page as homepage's content, just create a content file named `_index.md` in `content` root folder.
-* use the `layout` key in frontmatter to control what to show/hide for this page
-
-## Get rid of header, footer and navigations for Homepage
-with `layout=raw` in frontmatter, your content will render without any navigation, menu, header, footer.
+* use `hide_header`,`hide_nav`,`hide_breadcrumb`,`hide_toc`,`hide_footer` params in frontmatter to control what to show/hide for this page
+## Use plain HTML for your homepage
+set a `layout=raw` param in frontmatter, your content will render without any navigation, menu, header, footer.
Example
diff --git a/exampleSite/content/docport-theme/_index.md b/exampleSite/content/docport-theme/_index.md
index 5190ea0..18e6873 100644
--- a/exampleSite/content/docport-theme/_index.md
+++ b/exampleSite/content/docport-theme/_index.md
@@ -6,22 +6,23 @@ weight = 1
[Hugo-theme-docport](https://github.com/vjeantet/hugo-theme-docport) is a theme for Hugo, a fast and modern static website engine. Hugo is often used for blogs.
-**This theme is fully designed for documentation.** and a port of the [docDock theme](https://github.com/vjenatet/hugo-theme-docdock) itslef a fork of a great theme : [hugo-theme-learn from matCornic](https://github.com/matcornic/hugo-theme-learn)
+**This theme is fully designed for documentation.** and a port of the [docDock theme](https://github.com/vjenatet/hugo-theme-docdock) which is a fork of [hugo-theme-learn from matCornic](https://github.com/matcornic/hugo-theme-learn)
-{{%panel%}}DocPort works with a "page tree structure" to organize content : All contents are pages, which belong to other pages. [read more about this]({{%relref "content-organisation/_index.md"%}}) {{%/panel%}}
+{{%notice%}}DocPort works with a "page tree structure" to organize content : All contents are pages, which belong to other pages. [read more about this]({{%relref "content-organisation/_index.md"%}}). {{%/notice%}}
## Main features
-
* [Search Engine]({{%relref "search/_index.md" %}})
* **Unlimited menu levels**
* [Placeholders]({{%relref "content-organisation/placeholders/_index.md" %}}) to inject HTML, CSS, JS in theme without modifying it.
-* [Customizable look and feel, colors]({{%relref "content-organisation/customize-style/_index.md" %}})
+* Responsive, [Customizable look and feel, colors]({{%relref "content-organisation/customize-style/_index.md" %}})
* [RevealJS presentation]({{%relref "page-slide/_index.md"%}}) from markdown (embededed or fullscreen page)
* [Image resizing, shadow...]({{%relref "create-page/page-images/_index.md" %}})
-* [Mermaid diagram]({{%relref "shortcodes/mermaid/_index.md" %}}) (flowchart, sequence, gantt)
-* [Attachments files]({{%relref "shortcodes/attachments/_index.md" %}}), [Icons]({{%relref "shortcodes/icon/_index.md" %}}), [Buttons]({{%relref "shortcodes/button/_index.md" %}}), [Alerts]({{%relref "shortcodes/alert/_index.md" %}}), [Panels]({{%relref "shortcodes/panel/_index.md" %}}), [Tip/Note/Info/Warning boxes]({{%relref "shortcodes/notice/_index.md" %}}), [Expand]({{%relref "shortcodes/expand/_index.md" %}}), [List child pages]({{%relref "shortcodes/children/_index.md" %}})
-* [Excerpt]({{%relref "shortcodes/excerpt/_index.md"%}}) ! Include segment of content from one page in another
+* A bunch of shortcodes
+ * [Mermaid diagram]({{%relref "shortcodes/mermaid/_index.md" %}}) (flowchart, sequence, gantt)
+ * [Attachments files]({{%relref "shortcodes/attachments/_index.md" %}}), [Icons]({{%relref "shortcodes/icon/_index.md" %}}), [Buttons]({{%relref "shortcodes/button/_index.md" %}}), [Alerts]({{%relref "shortcodes/alert/_index.md" %}}), [Panels]({{%relref "shortcodes/panel/_index.md" %}}), [Tip/Note/Info/Warning boxes]({{%relref "shortcodes/notice/_index.md" %}}), [Expand]({{%relref "shortcodes/expand/_index.md" %}}), [List child pages]({{%relref "shortcodes/children/_index.md" %}})
+ * [Excerpt]({{%relref "shortcodes/excerpt/_index.md"%}}) ! Include segment of content from one page in another
+
## Contribute to this documentation
Feel free to update this content, just click the **Edit this page** link displayed on top right of each page, and pullrequest it
@@ -31,3 +32,8 @@ Feel free to update this content, just click the **Edit this page** link display
## Documentation website
This current documentation has been statically generated with Hugo with a simple command : `hugo -t docport` -- source code is [available here at GitHub](https://github.com/vjeantet/hugo-theme-docPort)
+## Static + content management
+Docport theme seamless works with [Netlify CMS](https://www.netlifycms.org/)
+{{%notice%}}Use Netlify CMS with hugo and this theme for a faster and more flexible web project.{{%/notice%}}
+
+
diff --git a/exampleSite/content/docport-theme/credits/_index.md b/exampleSite/content/docport-theme/credits/_index.md
index 333be5a..1fcbc1e 100644
--- a/exampleSite/content/docport-theme/credits/_index.md
+++ b/exampleSite/content/docport-theme/credits/_index.md
@@ -81,4 +81,5 @@ hide_toc=true
## Tooling
-* [Hugo](https://gohugo.io/) \ No newline at end of file
+* [Hugo](https://gohugo.io/)
+* [Netlify CMS](https://www.netlifycms.org/) \ No newline at end of file
diff --git a/exampleSite/content/getting-start/installation/_index.md b/exampleSite/content/getting-start/installation/_index.md
index c41e0c2..b3b1212 100644
--- a/exampleSite/content/getting-start/installation/_index.md
+++ b/exampleSite/content/getting-start/installation/_index.md
@@ -27,11 +27,13 @@ Create empty directory, which will be root of your Hugo project. Navigate there
```
$ hugo new site .
```
-AFTER that, initialize this as git directory where to track further changes
+After that, initialize this as git directory where to track further changes
```
$ git init
```
+### Install DocPort
+
Next, there are at least three ways to install DocPort (first recommended):
1. **As git submodule**
@@ -40,7 +42,7 @@ Next, there are at least three ways to install DocPort (first recommended):
Navigate to your themes folder in your Hugo site and use perform one of following scenarios.
-### 1. Install DocPort as git submodule
+#### 1. Install DocPort as git submodule
DocPort will be added like a dependency repo to original project. When using CI tools like Netlify, Jenkins etc., submodule method is required, or you will get `theme not found` issues. Same applies when building site on remote server trough SSH.
@@ -62,7 +64,7 @@ Now you are ready to add content and customize looks. Do not change any file ins
If you want to freeze changes to DocPort theme itself and use still submodules, fork private copy of DocPort and use that as submodule. When you are ready to update theme, just pull changes from origin to your private fork.
-### 2. Install DocPort simply as git clone
+#### 2. Install DocPort simply as git clone
This method results that files are checked out locally, but won't be visible from parent git repo. Probably you will build site locally with `hugo` command and use result from `public/` on your own.
@@ -71,7 +73,7 @@ $ git clone https://github.com/vjeantet/hugo-theme-docport.git themes/docport
```
-### 3. Install DocPort from ZIP
+#### 3. Install DocPort from ZIP
All files from theme will be tracked inside parent repo, to update it, have to override files in theme. [{{%icon cloud_download%}} download zip](https://github.com/vjeantet/hugo-theme-docport/archive/master.zip) and extract inside `themes/`.
diff --git a/exampleSite/content/search/_index.md b/exampleSite/content/search/_index.md
index 62d7f10..d7307e3 100644
--- a/exampleSite/content/search/_index.md
+++ b/exampleSite/content/search/_index.md
@@ -7,10 +7,9 @@ post: "<i class='material-icons' >star_border</i> "
---
{{%excerpt-include filename="getting-start/configuration/_index.md" /%}}
-Docdock theme uses the last improvement available in hugo version 20+ to generate a json index file ready to be consumed by lunr.js javascript search engine.
+Docport theme uses the last improvement available in hugo version 20+ to generate a json index file ready to be consumed by lunr.js javascript search engine.
{{%note%}}hugo generate lunrjs index.json at the root of `public` folder if the site only has one language or within each language subfolder. <br/>When you build the site with `hugo server`, hugo generates it internally and of course it don't show up in the filesystem{{%/note%}}
-![](obscuripes13g.jpg) \ No newline at end of file
diff --git a/exampleSite/content/search/obscuripes13g.jpg b/exampleSite/content/search/obscuripes13g.jpg
deleted file mode 100644
index d184d4a..0000000
--- a/exampleSite/content/search/obscuripes13g.jpg
+++ /dev/null
Binary files differ
diff --git a/exampleSite/resources/_gen/assets/scss/sass/shortcodes/notice.scss_f300667da4f5b5f84e1a9e0702b2fdde.content b/exampleSite/resources/_gen/assets/scss/sass/shortcodes/notice.scss_f300667da4f5b5f84e1a9e0702b2fdde.content
index 4292aa2..8afa11a 100644
--- a/exampleSite/resources/_gen/assets/scss/sass/shortcodes/notice.scss_f300667da4f5b5f84e1a9e0702b2fdde.content
+++ b/exampleSite/resources/_gen/assets/scss/sass/shortcodes/notice.scss_f300667da4f5b5f84e1a9e0702b2fdde.content
@@ -6,7 +6,8 @@ div.notices p {
margin-top: 0px;
box-sizing: border-box;
box-shadow: inset 4px 0 0 black;
- background-color: #e6e6e6; }
+ background-color: #e6e6e6;
+ font-size: smaller; }
div.notices label {
font-size: 0.5em;