Skip to content

Commit

Permalink
Merge branch 'release-0.9.7'
Browse files Browse the repository at this point in the history
  • Loading branch information
thingsym committed Mar 8, 2021
2 parents a84ed5b + 929c631 commit 5bf9a4d
Show file tree
Hide file tree
Showing 17 changed files with 5,144 additions and 3,072 deletions.
1 change: 1 addition & 0 deletions .github/FUNDING.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
github: thingsym
206 changes: 118 additions & 88 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,9 @@ The Techdoc is a Hugo Theme for technical documentation.
* Edit link to documentation repository
* Header link to HTML headings
* Custom Shortcodes
* Code highlight with clipboard
* Alert panel
* Button
* Code highlight with clipboard
* Alert panel
* Button
* Search Shortcode powered by [Algolia](https://www.algolia.com/)
* Open Graph
* Analytics with Google Analytics, Google Tag Manager
Expand Down Expand Up @@ -93,8 +93,11 @@ git commit
tree . -I node_modules
.
├── LICENSE.md
├── README.md
├── archetypes
│   └── default.md
├── docker-compose.yml
├── exampleSite
│   └── ..
├── gulpfile.js
Expand Down Expand Up @@ -143,15 +146,13 @@ tree . -I node_modules
│   ├── posts
│   │   ├── list.html
│   │   └── single.html
│   ── shortcodes
│   ── shortcodes
│   ├── button.html
│   ├── code.html
│   ├── panel.html
│   └── search.html
├── LICENSE.md
├── package.json
├── package-lock.json
├── README.md
├── package.json
├── resources
├── src
│   ├── js
Expand All @@ -164,24 +165,24 @@ tree . -I node_modules
│   │   ├── main.js
│   │   └── sidebar-menu.js
│   └── scss
│   ├── chroma.scss
│   ├── _component.scss
│   ├── _project.scss
│   ├── _structure.scss
│   ├── _variable.scss
│   ├── chroma.scss
│   ├── foundation
│   │   ├── _element.scss
│   │   ├── _index.scss
│   │   ├── _normalize.scss
│   │   ├── _reset.scss
│   │   └── _stack.scss
│   ├── _foundation.scss
│   ├── function
│   │   ├── _calc-font-size.scss
│   │   ├── _calc-stack.scss
│   │   ├── _contrast-color.scss
│   │   ├── _index.scss
│   │   └── _strip-unit.scss
│   ├── _function.scss
│   ├── _project.scss
│   ├── _structure.scss
│   ├── theme.scss
│   └── _variable.scss
│   └── theme.scss
├── static
│   ├── css
│   │   ├── chroma.css
Expand Down Expand Up @@ -211,24 +212,46 @@ Browse site on http://localhost:1313
hugo -t hugo-theme-techdoc -d public_html
```

## Development environment
## Local development environment

### Preview exampleSite

```
cd /path/to/dir/themes/hugo-theme-techdoc/exampleSite
hugo server --themesDir ../..
```

Browse site on http://localhost:1313

### Build development

```
cd /path/to/hugo-theme-techdoc
npm install
npm run gulp:watch
npm run gulp watch
```

### Preview exampleSite
## Docker development environment

```
cd /path/to/dir/themes/hugo-theme-techdoc/exampleSite
### Run Docker and Preview exampleSite

hugo server --themesDir ../..
```
cd /path/to/hugo-theme-techdoc
docker-compose up -d
```

Browse site on http://localhost:1313

### Build development

```
cd /path/to/hugo-theme-techdoc
docker-compose up -d
docker-compose run --rm node npm install
docker-compose run --rm node npm run watch
```

## Contribution

### Patches and Bug Fixes
Expand All @@ -243,94 +266,101 @@ Small patches and bug reports can be submitted a issue tracker in Github. Forkin

## Changelog

* Version 0.9.7 - 2021.03.08
* add docker-compose.yml for development environment
* change keyboard event from event.keyCode to event.key because it is deprecated
* update package.json
* add FUNDING.yml
* fix space for minify publish
* change flexbox-grid-mixins from libsass to dart-sass
* Version 0.9.6 - 2020.11.22
* add sample Markdown Syntax
* update sample document
* replace scss from node-sass to dart-sass
* add sample Markdown Syntax
* update sample document
* replace scss from node-sass to dart-sass
* Version 0.9.5 - 2020.11.05
* fix link style with Alert panel
* fix link style with Alert panel
* Version 0.9.4 - 2020.10.08
* improve scss for custom shortcodes using css custom properties
* change stack to css custom properties
* fix scss
* fix button shortcode, adding notice color
* add Code highlight with clipboard custom shortcode
* fix webpack.config.js
* fix npm scripts
* update package.json
* adjust no sidebar layout
* improve scss for custom shortcodes using css custom properties
* change stack to css custom properties
* fix scss
* fix button shortcode, adding notice color
* add Code highlight with clipboard custom shortcode
* fix webpack.config.js
* fix npm scripts
* update package.json
* adjust no sidebar layout
* Version 0.9.3 - 2020.08.02
* remove jQuery dependency with keydown nav
* add header link
* remove jQuery dependency with keydown nav
* add header link
* Version 0.9.2 - 2020.06.14
* add note and sample to document
* fix tableOfContents endLevel
* add chapter 'unlimited levels' to document
* add menu indentation up to 5 levels
* add note and sample to document
* fix tableOfContents endLevel
* add chapter 'unlimited levels' to document
* add menu indentation up to 5 levels
* Version 0.9.1 - 2020.05.24
* fix config.toml
* fix url in rss meta link
* remove line break in algolia.json
* fix config.toml
* fix url in rss meta link
* remove line break in algolia.json
* Version 0.9.0 - 2020.04.01
* fix lint config
* update Sample Document
* update jQuery to v3.4.1
* add search function and shortcode powered by Algolia
* fix config.toml
* fix sass
* fix hugo deprecated warning
* fix lint config
* update Sample Document
* update jQuery to v3.4.1
* add search function and shortcode powered by Algolia
* fix config.toml
* fix sass
* fix hugo deprecated warning
* Version 0.8.3 - 2020.03.19
* fix edit page link
* fix edit page link
* Version 0.8.2 - 2020.03.07
* fix open graph image path
* fix open graph image path
* Version 0.8.1 - 2020.03.07
* fix open graph image path
* fix open graph image path
* Version 0.8.0 - 2020.02.27
* update Sample Document
* config.toml
* add open graph image to exampleSite
* add safeCSS for ZgotmplZ with generated by Hugo Template
* update Sample Document
* config.toml
* add open graph image to exampleSite
* add safeCSS for ZgotmplZ with generated by Hugo Template
* Version 0.7.0 - 2020.02.07
* bump up Hugo minimum version to 0.60.0
* change shortcode delimiter from % to <
* improve tableOfContents for Goldmark
* bump up Hugo minimum version to 0.60.0
* change shortcode delimiter from % to <
* improve tableOfContents for Goldmark
* Version 0.6.0 - 2020.01.13
* fix scss
* gulp bump up version to 4.0
* fix hugo deprecated warning
* fix scss
* gulp bump up version to 4.0
* fix hugo deprecated warning
* Version 0.5.0 - 2019.12.08
* update Sample Document
* add table of contents
* add open graph
* add function and stack scss
* update Sample Document
* add table of contents
* add open graph
* add function and stack scss
* Version 0.4.0 - 2019.11.02
* update Sample Document
* add Theme color
* add Menu style
* improve scss
* update Sample Document
* add Theme color
* add Menu style
* improve scss
* Version 0.3.0 - 2019.10.06
* fix archetypes
* add prepend-body.html for Tag Manager noscript version
* change class name from menu to global-menu
* rename partials files
* fix javascript path for webpack
* improve development environment
* move javascript files to src directory
* fix archetypes
* add prepend-body.html for Tag Manager noscript version
* change class name from menu to global-menu
* rename partials files
* fix javascript path for webpack
* improve development environment
* move javascript files to src directory
* Version 0.2.2 - 2019.04.27
* fix Lastmod's and PublishDate's initial value of 0001-01-01
* fix Lastmod's and PublishDate's initial value of 0001-01-01
* Version 0.2.1 - 2018.12.07
* fix scss lint errors
* change lint from scss-lint to stylelint
* add published date
* change the font color of powered by
* fix link on powered by
* fix scss lint errors
* change lint from scss-lint to stylelint
* add published date
* change the font color of powered by
* fix link on powered by
* Version 0.2.0 - 2018.11.21
* add screenshot images
* add exampleSite
* fix sub-menu for responsive
* improve menu and pagination
* add screenshot images
* add exampleSite
* fix sub-menu for responsive
* improve menu and pagination
* Version 0.1.0 - 2018.03.04
* initial release
* initial release

## License

Expand Down
18 changes: 18 additions & 0 deletions docker-compose.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
version: '3'
services:
server:
image: klakegg/hugo:0.81.0-alpine
volumes:
- .:/hugo/themes/hugo-theme-techdoc
ports:
- 1313:1313
working_dir: /hugo/themes/hugo-theme-techdoc/exampleSite
command: "server --bind 0.0.0.0 -wD --ignoreCache --themesDir ../.. --minify"

node:
image: node:lts
volumes:
- .:/hugo/themes/hugo-theme-techdoc
working_dir: /hugo/themes/hugo-theme-techdoc
environment:
SHELL: /bin/bash
2 changes: 1 addition & 1 deletion exampleSite/config.toml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ enableMissingTranslationPlaceholders = false
# Source Code repository section
description = "put your description"
github_repository = "https://github.com/thingsym/hugo-theme-techdoc"
version = "0.9.6"
version = "0.9.7"

# Documentation repository section
# documentation repository (set edit link to documentation repository)
Expand Down
4 changes: 2 additions & 2 deletions exampleSite/content/getting-started/configuration.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ For an example of `config.toml`, see [config.toml](https://github.com/thingsym/h
# Source Code repository section
description = "put your description"
github_repository = "https://github.com/thingsym/hugo-theme-techdoc"
version = "0.9.6"
version = "0.9.7"

# Documentation repository section
# documentation repository (set edit link to documentation repository)
Expand Down Expand Up @@ -80,7 +80,7 @@ default: `https://github.com/thingsym/hugo-theme-techdoc`

The version of souce code

default: `0.9.6`
default: `0.9.7`

#### `github_doc_repository`

Expand Down
2 changes: 1 addition & 1 deletion exampleSite/content/sample/custom-shortcodes.md
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ TableOfContents: true

{{< button status="danger" url="#" >}}danger{{< /button >}}

#### Button with Font Awesome
### Button with Font Awesome

{{< button icon="fas fa-download" url="#" >}}Download{{< /button >}}

Expand Down
2 changes: 1 addition & 1 deletion layouts/partials/edit-page.html
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
{{- if and .Site.Params.github_doc_repository .File -}}
<a href="{{ .Site.Params.github_doc_repository }}/edit/master/content/{{ .File.Path }}" class="edit-page"><i class="fas fa-pen-square"></i> Edit on GitHub</a>
<a href="{{ .Site.Params.github_doc_repository }}/edit/master/content/{{ .File.Path }}" class="edit-page"><i class="fas fa-pen-square"></i>&nbsp;Edit on GitHub</a>
{{- end -}}
2 changes: 1 addition & 1 deletion layouts/partials/pagination.html
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
<nav class="pagination">
{{- template "pagination" dict "menu" .Site.Home "currentnode" $currentNode "menu_exclusion" .Site.Params.menu_exclusion -}}
{{- with ($.Scratch.Get "prevPage") -}}
<a class="nav nav-prev" href="{{ .Permalink }}" title="{{ .Title }}"><i class="fas fa-arrow-left" aria-hidden="true"></i> Prev - {{ .Title }}</a>
<a class="nav nav-prev" href="{{ .Permalink }}" title="{{ .Title }}"><i class="fas fa-arrow-left" aria-hidden="true"></i>&nbsp;Prev - {{ .Title }}</a>
{{ end -}}
{{- with ($.Scratch.Get "nextPage") -}}
<a class="nav nav-next" href="{{ .Permalink }}" title="{{ .Title }}">Next - {{ .Title }} <i class="fas fa-arrow-right" aria-hidden="true"></i></a>
Expand Down
2 changes: 1 addition & 1 deletion layouts/shortcodes/button.html
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
<a href="{{ with .Get "url" }}{{ . }}{{ end }}" class="button {{ with .Get "status" }}button-{{ . }}{{ else }}button-primary{{ end }}">
{{ with .Get "icon" }}<i class="{{ . }}"></i> {{ end }}{{- .Inner -}}
{{ with .Get "icon" }}<i class="{{ . }}"></i>&nbsp;{{ end }}{{- .Inner -}}
</a>
2 changes: 1 addition & 1 deletion layouts/shortcodes/panel.html
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<div class="panel {{ with .Get "status" }}panel-{{ . }}{{ else }}panel-primary{{ end }}">
{{- with .Get "title" -}}
<div class="panel-header">
<h3>{{ if $.Get "icon" }}<i class="{{ $.Get "icon" }}"></i> {{ end }}{{- htmlUnescape . | markdownify -}}</h3>
<h3>{{ if $.Get "icon" }}<i class="{{ $.Get "icon" }}"></i>&nbsp;{{ end }}{{- htmlUnescape . | markdownify -}}</h3>
</div>
{{- end -}}
<div class="panel-body">
Expand Down
Loading

0 comments on commit 5bf9a4d

Please sign in to comment.