doc theme
This commit is contained in:
+40
@@ -0,0 +1,40 @@
|
||||
+++
|
||||
title = "Customize website look and feel"
|
||||
Weight=3
|
||||
+++
|
||||
|
||||
You can change the style and behavior of the theme without touching it.
|
||||
|
||||
* inject your own html, css or js into the page
|
||||
* overide existing css or js with your own files
|
||||
|
||||
## Inject your HTML
|
||||
|
||||
### into the \<head\> part of each page :
|
||||
|
||||
Create a `custom-head.html` into a `layouts/partials` folder next to the content folder
|
||||
|
||||
> * content/
|
||||
> * layouts/
|
||||
> * partials/
|
||||
> * custom-head.html
|
||||
|
||||
now feel free to add the JS, CSS, HTML code you want :)
|
||||
|
||||
### at the end of the body part of each page :
|
||||
|
||||
Create a `custom-footer.html` into a `layouts/partials` folder next to the content folder
|
||||
|
||||
> * content/
|
||||
> * layouts/
|
||||
> * partials/
|
||||
> * custom-footer.html
|
||||
|
||||
now feel free to add the JS, CSS, HTML code you want :)
|
||||
|
||||
## overide existing CSS or JS
|
||||
|
||||
Create the matching file in your static folder, hugo will use yours instead of the theme's one.
|
||||
Example :
|
||||
|
||||
create a theme.css and place it into `static/css/` to fully overide docdock's theme.css
|
||||
+35
@@ -0,0 +1,35 @@
|
||||
+++
|
||||
title = "Theme variants"
|
||||
description = "change theme style/colors"
|
||||
+++
|
||||
|
||||
In site configuration file, you can set a variant name of this theme to load a specific css, with different color specifications.
|
||||
|
||||
add a param `themeVariant = "VARIANT_NAME"` in the `[params]` part of config.toml file.
|
||||
|
||||
{{%info%}}Available variants change only colors at this moment{{%/info%}}
|
||||
|
||||
|
||||
## Variant "gray"
|
||||
```
|
||||
[params]
|
||||
themeVariant = "gray"
|
||||
```
|
||||
|
||||

|
||||
|
||||
## Variant "gold"
|
||||
```
|
||||
[params]
|
||||
themeVariant = "gold"
|
||||
```
|
||||
|
||||

|
||||
|
||||
## Variant "green"
|
||||
```
|
||||
[params]
|
||||
themeVariant = "green"`
|
||||
```
|
||||
|
||||

|
||||
Reference in New Issue
Block a user