diff --git a/Cargo.lock b/Cargo.lock index d6287b7f..96299c2d 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -37,7 +37,7 @@ dependencies = [ "backtrace-sys 0.1.16 (registry+https://github.com/rust-lang/crates.io-index)", "cfg-if 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)", "libc 0.2.36 (registry+https://github.com/rust-lang/crates.io-index)", - "rustc-demangle 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)", + "rustc-demangle 0.1.6 (registry+https://github.com/rust-lang/crates.io-index)", "winapi 0.3.4 (registry+https://github.com/rust-lang/crates.io-index)", ] @@ -382,7 +382,7 @@ dependencies = [ "staticfile 0.5.0 (registry+https://github.com/rust-lang/crates.io-index)", "term-painter 0.2.4 (registry+https://github.com/rust-lang/crates.io-index)", "toml 0.4.5 (registry+https://github.com/rust-lang/crates.io-index)", - "url 1.6.0 (registry+https://github.com/rust-lang/crates.io-index)", + "url 1.7.0 (registry+https://github.com/rust-lang/crates.io-index)", "utils 0.1.0", "ws 0.7.3 (registry+https://github.com/rust-lang/crates.io-index)", ] @@ -420,7 +420,7 @@ dependencies = [ "traitobject 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)", "typeable 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)", "unicase 1.4.2 (registry+https://github.com/rust-lang/crates.io-index)", - "url 1.6.0 (registry+https://github.com/rust-lang/crates.io-index)", + "url 1.7.0 (registry+https://github.com/rust-lang/crates.io-index)", ] [[package]] @@ -462,7 +462,7 @@ dependencies = [ "num_cpus 1.8.0 (registry+https://github.com/rust-lang/crates.io-index)", "plugin 0.2.6 (registry+https://github.com/rust-lang/crates.io-index)", "typemap 0.3.3 (registry+https://github.com/rust-lang/crates.io-index)", - "url 1.6.0 (registry+https://github.com/rust-lang/crates.io-index)", + "url 1.7.0 (registry+https://github.com/rust-lang/crates.io-index)", ] [[package]] @@ -696,7 +696,7 @@ dependencies = [ "kernel32-sys 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)", "libc 0.2.36 (registry+https://github.com/rust-lang/crates.io-index)", "mio 0.5.1 (registry+https://github.com/rust-lang/crates.io-index)", - "walkdir 2.1.3 (registry+https://github.com/rust-lang/crates.io-index)", + "walkdir 2.1.4 (registry+https://github.com/rust-lang/crates.io-index)", "winapi 0.2.8 (registry+https://github.com/rust-lang/crates.io-index)", ] @@ -801,15 +801,15 @@ source = "registry+https://github.com/rust-lang/crates.io-index" [[package]] name = "pest" -version = "1.0.3" +version = "1.0.6" source = "registry+https://github.com/rust-lang/crates.io-index" [[package]] name = "pest_derive" -version = "1.0.3" +version = "1.0.6" source = "registry+https://github.com/rust-lang/crates.io-index" dependencies = [ - "pest 1.0.3 (registry+https://github.com/rust-lang/crates.io-index)", + "pest 1.0.6 (registry+https://github.com/rust-lang/crates.io-index)", "quote 0.3.15 (registry+https://github.com/rust-lang/crates.io-index)", "syn 0.11.11 (registry+https://github.com/rust-lang/crates.io-index)", ] @@ -876,7 +876,7 @@ dependencies = [ [[package]] name = "pulldown-cmark" -version = "0.1.0" +version = "0.1.2" source = "registry+https://github.com/rust-lang/crates.io-index" dependencies = [ "bitflags 0.9.1 (registry+https://github.com/rust-lang/crates.io-index)", @@ -989,7 +989,7 @@ dependencies = [ "front_matter 0.1.0", "highlighting 0.1.0", "lazy_static 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)", - "pulldown-cmark 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)", + "pulldown-cmark 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)", "regex 0.2.6 (registry+https://github.com/rust-lang/crates.io-index)", "serde 1.0.27 (registry+https://github.com/rust-lang/crates.io-index)", "serde_derive 1.0.27 (registry+https://github.com/rust-lang/crates.io-index)", @@ -1002,7 +1002,7 @@ dependencies = [ [[package]] name = "rustc-demangle" -version = "0.1.5" +version = "0.1.6" source = "registry+https://github.com/rust-lang/crates.io-index" [[package]] @@ -1121,7 +1121,7 @@ dependencies = [ "templates 0.1.0", "tera 0.11.3 (registry+https://github.com/rust-lang/crates.io-index)", "utils 0.1.0", - "walkdir 2.1.3 (registry+https://github.com/rust-lang/crates.io-index)", + "walkdir 2.1.4 (registry+https://github.com/rust-lang/crates.io-index)", ] [[package]] @@ -1150,7 +1150,7 @@ dependencies = [ "iron 0.6.0 (registry+https://github.com/rust-lang/crates.io-index)", "mount 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)", "time 0.1.39 (registry+https://github.com/rust-lang/crates.io-index)", - "url 1.6.0 (registry+https://github.com/rust-lang/crates.io-index)", + "url 1.7.0 (registry+https://github.com/rust-lang/crates.io-index)", ] [[package]] @@ -1192,7 +1192,7 @@ dependencies = [ "serde 1.0.27 (registry+https://github.com/rust-lang/crates.io-index)", "serde_derive 1.0.27 (registry+https://github.com/rust-lang/crates.io-index)", "serde_json 1.0.9 (registry+https://github.com/rust-lang/crates.io-index)", - "walkdir 2.1.3 (registry+https://github.com/rust-lang/crates.io-index)", + "walkdir 2.1.4 (registry+https://github.com/rust-lang/crates.io-index)", "yaml-rust 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)", ] @@ -1229,7 +1229,7 @@ dependencies = [ "content 0.1.0", "errors 0.1.0", "lazy_static 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)", - "pulldown-cmark 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)", + "pulldown-cmark 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)", "taxonomies 0.1.0", "tera 0.11.3 (registry+https://github.com/rust-lang/crates.io-index)", "utils 0.1.0", @@ -1245,13 +1245,13 @@ dependencies = [ "glob 0.2.11 (registry+https://github.com/rust-lang/crates.io-index)", "humansize 1.1.0 (registry+https://github.com/rust-lang/crates.io-index)", "lazy_static 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)", - "pest 1.0.3 (registry+https://github.com/rust-lang/crates.io-index)", - "pest_derive 1.0.3 (registry+https://github.com/rust-lang/crates.io-index)", + "pest 1.0.6 (registry+https://github.com/rust-lang/crates.io-index)", + "pest_derive 1.0.6 (registry+https://github.com/rust-lang/crates.io-index)", "regex 0.2.6 (registry+https://github.com/rust-lang/crates.io-index)", "serde 1.0.27 (registry+https://github.com/rust-lang/crates.io-index)", "serde_json 1.0.9 (registry+https://github.com/rust-lang/crates.io-index)", "slug 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)", - "url 1.6.0 (registry+https://github.com/rust-lang/crates.io-index)", + "url 1.7.0 (registry+https://github.com/rust-lang/crates.io-index)", ] [[package]] @@ -1388,7 +1388,7 @@ dependencies = [ [[package]] name = "url" -version = "1.6.0" +version = "1.7.0" source = "registry+https://github.com/rust-lang/crates.io-index" dependencies = [ "idna 0.1.4 (registry+https://github.com/rust-lang/crates.io-index)", @@ -1427,7 +1427,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" [[package]] name = "walkdir" -version = "2.1.3" +version = "2.1.4" source = "registry+https://github.com/rust-lang/crates.io-index" dependencies = [ "same-file 1.0.2 (registry+https://github.com/rust-lang/crates.io-index)", @@ -1476,7 +1476,7 @@ dependencies = [ "rand 0.3.22 (registry+https://github.com/rust-lang/crates.io-index)", "sha1 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)", "slab 0.3.0 (registry+https://github.com/rust-lang/crates.io-index)", - "url 1.6.0 (registry+https://github.com/rust-lang/crates.io-index)", + "url 1.7.0 (registry+https://github.com/rust-lang/crates.io-index)", ] [[package]] @@ -1591,8 +1591,8 @@ dependencies = [ "checksum onig_sys 67.1.0 (registry+https://github.com/rust-lang/crates.io-index)" = "34d894e8da3390097d99eb197eac2ec443277551388eff0f97c5f789933350ee" "checksum os_pipe 0.6.0 (registry+https://github.com/rust-lang/crates.io-index)" = "7f547689aea1f11fac90333d573854a8e3e52a9160df1c42aefa8cd16734a3c0" "checksum percent-encoding 1.0.1 (registry+https://github.com/rust-lang/crates.io-index)" = "31010dd2e1ac33d5b46a5b413495239882813e0369f8ed8a5e266f173602f831" -"checksum pest 1.0.3 (registry+https://github.com/rust-lang/crates.io-index)" = "e1117ca38a751edc66a4cd9ca1b35644b7d00305971306e07e0d3befbc61e906" -"checksum pest_derive 1.0.3 (registry+https://github.com/rust-lang/crates.io-index)" = "1debf85717cb8fa6bf2aad21fbbe888fda5797aae22d332cefec9ba79b6c7a33" +"checksum pest 1.0.6 (registry+https://github.com/rust-lang/crates.io-index)" = "0fce5d8b5cc33983fc74f78ad552b5522ab41442c4ca91606e4236eb4b5ceefc" +"checksum pest_derive 1.0.6 (registry+https://github.com/rust-lang/crates.io-index)" = "6453faedc5c9980a3c278f28b1df33344a79cc6d4a2fd96e2b56288374dc822a" "checksum phf 0.7.21 (registry+https://github.com/rust-lang/crates.io-index)" = "cb325642290f28ee14d8c6201159949a872f220c62af6e110a56ea914fbe42fc" "checksum phf_codegen 0.7.21 (registry+https://github.com/rust-lang/crates.io-index)" = "d62594c0bb54c464f633175d502038177e90309daf2e0158be42ed5f023ce88f" "checksum phf_generator 0.7.21 (registry+https://github.com/rust-lang/crates.io-index)" = "6b07ffcc532ccc85e3afc45865469bf5d9e4ef5bfcf9622e3cfe80c2d275ec03" @@ -1600,7 +1600,7 @@ dependencies = [ "checksum pkg-config 0.3.9 (registry+https://github.com/rust-lang/crates.io-index)" = "3a8b4c6b8165cd1a1cd4b9b120978131389f64bdaf456435caa41e630edba903" "checksum plist 0.2.4 (registry+https://github.com/rust-lang/crates.io-index)" = "c61ac2afed2856590ae79d6f358a24b85ece246d2aa134741a66d589519b7503" "checksum plugin 0.2.6 (registry+https://github.com/rust-lang/crates.io-index)" = "1a6a0dc3910bc8db877ffed8e457763b317cf880df4ae19109b9f77d277cf6e0" -"checksum pulldown-cmark 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)" = "a656fdb8b6848f896df5e478a0eb9083681663e37dcb77dd16981ff65329fe8b" +"checksum pulldown-cmark 0.1.2 (registry+https://github.com/rust-lang/crates.io-index)" = "d6fdf85cda6cadfae5428a54661d431330b312bc767ddbc57adbedc24da66e32" "checksum quote 0.3.15 (registry+https://github.com/rust-lang/crates.io-index)" = "7a6e920b65c65f10b2ae65c831a81a073a89edd28c7cce89475bff467ab4167a" "checksum rand 0.3.22 (registry+https://github.com/rust-lang/crates.io-index)" = "15a732abf9d20f0ad8eeb6f909bf6868722d9a06e1e50802b6a70351f40b4eb1" "checksum rand 0.4.2 (registry+https://github.com/rust-lang/crates.io-index)" = "eba5f8cb59cc50ed56be8880a5c7b496bfd9bd26394e176bc67884094145c2c5" @@ -1611,7 +1611,7 @@ dependencies = [ "checksum regex 0.2.6 (registry+https://github.com/rust-lang/crates.io-index)" = "5be5347bde0c48cfd8c3fdc0766cdfe9d8a755ef84d620d6794c778c91de8b2b" "checksum regex-syntax 0.4.2 (registry+https://github.com/rust-lang/crates.io-index)" = "8e931c58b93d86f080c734bfd2bce7dd0079ae2331235818133c8be7f422e20e" "checksum remove_dir_all 0.3.0 (registry+https://github.com/rust-lang/crates.io-index)" = "b5d2f806b0fcdabd98acd380dc8daef485e22bcb7cddc811d1337967f2528cf5" -"checksum rustc-demangle 0.1.5 (registry+https://github.com/rust-lang/crates.io-index)" = "aee45432acc62f7b9a108cc054142dac51f979e69e71ddce7d6fc7adf29e817e" +"checksum rustc-demangle 0.1.6 (registry+https://github.com/rust-lang/crates.io-index)" = "f312457f8a4fa31d3581a6f423a70d6c33a10b95291985df55f1ff670ec10ce8" "checksum safemem 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)" = "e27a8b19b835f7aea908818e871f5cc3a5a186550c30773be987e155e8163d8f" "checksum same-file 1.0.2 (registry+https://github.com/rust-lang/crates.io-index)" = "cfb6eded0b06a0b512c8ddbcf04089138c9b4362c2f696f3c3d76039d68f3637" "checksum sass-rs 0.2.1 (registry+https://github.com/rust-lang/crates.io-index)" = "90f8cf6e645aa843ffffcbdc1e8752b1f221dfa314c81895aeb229a77aea7e05" @@ -1653,12 +1653,12 @@ dependencies = [ "checksum unidecode 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)" = "d2adb95ee07cd579ed18131f2d9e7a17c25a4b76022935c7f2460d2bfae89fd2" "checksum unreachable 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)" = "382810877fe448991dfc7f0dd6e3ae5d58088fd0ea5e35189655f84e6814fa56" "checksum unsafe-any 0.4.2 (registry+https://github.com/rust-lang/crates.io-index)" = "f30360d7979f5e9c6e6cea48af192ea8fab4afb3cf72597154b8f08935bc9c7f" -"checksum url 1.6.0 (registry+https://github.com/rust-lang/crates.io-index)" = "fa35e768d4daf1d85733418a49fb42e10d7f633e394fccab4ab7aba897053fe2" +"checksum url 1.7.0 (registry+https://github.com/rust-lang/crates.io-index)" = "f808aadd8cfec6ef90e4a14eb46f24511824d1ac596b9682703c87056c8678b7" "checksum utf8-ranges 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)" = "662fab6525a98beff2921d7f61a39e7d59e0b425ebc7d0d9e66d316e55124122" "checksum vec_map 0.8.0 (registry+https://github.com/rust-lang/crates.io-index)" = "887b5b631c2ad01628bbbaa7dd4c869f80d3186688f8d0b6f58774fbe324988c" "checksum version_check 0.1.3 (registry+https://github.com/rust-lang/crates.io-index)" = "6b772017e347561807c1aa192438c5fd74242a670a6cffacc40f2defd1dc069d" "checksum void 1.0.2 (registry+https://github.com/rust-lang/crates.io-index)" = "6a02e4885ed3bc0f2de90ea6dd45ebcbb66dacffe03547fadbb0eeae2770887d" -"checksum walkdir 2.1.3 (registry+https://github.com/rust-lang/crates.io-index)" = "b167e9a4420d8dddb260e70c90a4a375a1e5691f21f70e715553da87b6c2503a" +"checksum walkdir 2.1.4 (registry+https://github.com/rust-lang/crates.io-index)" = "63636bd0eb3d00ccb8b9036381b526efac53caf112b7783b730ab3f8e44da369" "checksum winapi 0.2.8 (registry+https://github.com/rust-lang/crates.io-index)" = "167dc9d6949a9b857f3451275e911c3f44255842c1f7a76f33c55103a909087a" "checksum winapi 0.3.4 (registry+https://github.com/rust-lang/crates.io-index)" = "04e3bd221fcbe8a271359c04f21a76db7d0c6028862d1bb5512d85e1e2eb5bb3" "checksum winapi-build 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)" = "2d315eee3b34aca4797b2da6b13ed88266e6d612562a0c46390af8299fc699bc" diff --git a/docs/content/themes/_index.md b/docs/content/themes/_index.md new file mode 100644 index 00000000..5aa2e7b5 --- /dev/null +++ b/docs/content/themes/_index.md @@ -0,0 +1,6 @@ + ++++ +template = "themes.html" +sort_by = "date" ++++ + \ No newline at end of file diff --git a/docs/content/themes/after-dark/index.md b/docs/content/themes/after-dark/index.md new file mode 100644 index 00000000..0d999e49 --- /dev/null +++ b/docs/content/themes/after-dark/index.md @@ -0,0 +1,70 @@ + ++++ +title = "after-dark" +description = "A robust, elegant dark theme" +template = "theme.html" +date = 2017-11-07T17:39:37+01:00 + +[extra] +created = 2018-02-22T19:13:36+01:00 +updated = 2017-11-07T17:39:37+01:00 +repository = "https://github.com/Keats/after-dark" +homepage = "https://github.com/Keats/after-dark" +minimum_version = "0.2" +license = "MIT" + +[extra.author] +name = "Vincent Prouillet" +homepage = "https://vincent.is" ++++ + +# after-dark + +![after-dark screenshot](https://github.com/Keats/after-dark/blob/master/screenshot.png?raw=true) + +## Contents + +- [Installation](#installation) +- [Options](#options) + - [Top menu](#top-menu) + - [Title](#title) + +## Installation +First download this theme to your `themes` directory: + +```bash +$ cd themes +$ git clone https://github.com/Keats/after-dark.git +``` +and then enable it in your `config.toml`: + +```toml +theme = "after-dark" +``` + +## Options + +### Top-menu +Set a field in `extra` with a key of `after_dark_menu`: + +```toml +after_dark_menu = [ + {url = "$BASE_URL", name = "Home"}, + {url = "$BASE_URL/categories", name = "Categories"}, + {url = "$BASE_URL/tags", name = "Tags"}, + {url = "https://google.com", name = "Google"}, +] +``` + +If you put `$BASE_URL` in a url, it will automatically be replaced by the actual +site URL. + +### Title +The site title is shown on the homepage. As it might be different from the `` +element that the `title` field in the config represents, you can set the `after_dark_title` +instead. + +## Original +This template is based on the Hugo template https://github.com/comfusion/after-dark + + \ No newline at end of file diff --git a/docs/content/themes/after-dark/screenshot.png b/docs/content/themes/after-dark/screenshot.png new file mode 100644 index 00000000..e34718d6 Binary files /dev/null and b/docs/content/themes/after-dark/screenshot.png differ diff --git a/docs/content/themes/book/index.md b/docs/content/themes/book/index.md new file mode 100644 index 00000000..7edd3ad1 --- /dev/null +++ b/docs/content/themes/book/index.md @@ -0,0 +1,58 @@ + ++++ +title = "book" +description = "A book theme inspired from GitBook/mdBook" +template = "theme.html" +date = 2018-01-28T10:53:19+01:00 + +[extra] +created = 2018-02-22T19:13:36+01:00 +updated = 2018-01-28T10:53:19+01:00 +repository = "https://github.com/Keats/book" +homepage = "https://github.com/Keats/book" +minimum_version = "0.2" +license = "MIT" + +[extra.author] +name = "Vincent Prouillet" +homepage = "https://vincent.is" ++++ + +# book + +A theme based on [Gitbook](https://www.gitbook.com), to write documentation +or books. + +![book screenshot](https://github.com/Keats/book/blob/master/screenshot.png?raw=true) + + +## Contents + +- [Installation](#installation) +- [Options](#options) + - [Numbered chapters](#numbered-chapters) + +## Installation +First download this theme to your `themes` directory: + +```bash +$ cd themes +$ git clone https://github.com/Keats/book.git +``` +and then enable it in your `config.toml`: + +```toml +theme = "book" +``` + +## Options + +### Numbered chapters +By default, the `book` theme will number the chapters and pages in the left menu. +You can disable that by setting the `book_numbered_chapters` in `extra`: + +```toml +book_numbered_chapters = false +``` + + \ No newline at end of file diff --git a/docs/content/themes/book/screenshot.png b/docs/content/themes/book/screenshot.png new file mode 100644 index 00000000..d4dfd078 Binary files /dev/null and b/docs/content/themes/book/screenshot.png differ diff --git a/docs/content/themes/even/index.md b/docs/content/themes/even/index.md new file mode 100644 index 00000000..6e83d0e8 --- /dev/null +++ b/docs/content/themes/even/index.md @@ -0,0 +1,69 @@ + ++++ +title = "even" +description = "A robust, elegant dark theme" +template = "theme.html" +date = 2018-01-25T18:44:44+01:00 + +[extra] +created = 2018-02-22T19:13:36+01:00 +updated = 2018-01-25T18:44:44+01:00 +repository = "https://github.com/Keats/even" +homepage = "https://github.com/Keats/even" +minimum_version = "0.3" +license = "MIT" + +[extra.author] +name = "Vincent Prouillet" +homepage = "https://vincent.is" ++++ + +# Even +Even is a clean, responsive theme based on the Hugo theme with the same name featuring categories, tags and pagination. + +![even screenshot](https://github.com/Keats/even/blob/master/screenshot.png?raw=true) + +## Contents + +- [Installation](#installation) +- [Options](#options) + - [Top menu](#top-menu) + - [Title](#title) + +## Installation +First download this theme to your `themes` directory: + +```bash +$ cd themes +$ git clone https://github.com/Keats/even.git +``` +and then enable it in your `config.toml`: + +```toml +theme = "even" +``` + +## Options + +### Top-menu +Set a field in `extra` with a key of `even_menu`: + +```toml +# This is the default menu +even_menu = [ + {url = "$BASE_URL", name = "Home"}, + {url = "$BASE_URL/categories", name = "Categories"}, + {url = "$BASE_URL/tags", name = "Tags"}, + {url = "$BASE_URL/about", name = "About"}, +] +``` + +If you put `$BASE_URL` in a url, it will automatically be replaced by the actual +site URL. + +### Title +The site title is shown on the header. As it might be different from the `<title>` +element that the `title` field in the config represents, you can set the `even_title` +instead. + + \ No newline at end of file diff --git a/docs/content/themes/even/screenshot.png b/docs/content/themes/even/screenshot.png new file mode 100644 index 00000000..1acdd623 Binary files /dev/null and b/docs/content/themes/even/screenshot.png differ diff --git a/docs/content/themes/hyde/index.md b/docs/content/themes/hyde/index.md new file mode 100644 index 00000000..e11e16a2 --- /dev/null +++ b/docs/content/themes/hyde/index.md @@ -0,0 +1,89 @@ + ++++ +title = "hyde" +description = "A classic blog theme" +template = "theme.html" +date = 2017-10-24T15:01:52+02:00 + +[extra] +created = 2018-01-25T18:45:36+01:00 +updated = 2017-10-24T15:01:52+02:00 +repository = "https://github.com/Keats/hyde" +homepage = "https://github.com/Keats/gutenberg-hyde" +minimum_version = "0.2" +license = "MIT" + +[extra.author] +name = "Vincent Prouillet" +homepage = "https://vincent.is" ++++ + +# hyde +Hyde is a brazen two-column [Gutenberg](https://github.com/Keats/gutenberg) based on the Jekyll theme of the same name that pairs a prominent sidebar with uncomplicated content. + +![Hyde screenshot](https://f.cloud.github.com/assets/98681/1831228/42af6c6a-7384-11e3-98fb-e0b923ee0468.png) + + +## Contents + +- [Installation](#installation) +- [Options](#options) + - [Sidebar menu](#sidebar-menu) + - [Sticky sidebar content](#sticky-sidebar-content) + - [Themes](#themes) + - [Reverse layout](#reverse-layout) + +## Installation +First download this theme to your `themes` directory: + +```bash +$ cd themes +$ git clone https://github.com/Keats/hyde.git +``` +and then enable it in your `config.toml`: + +```toml +theme = "hyde" +``` + +## Options + +### Sidebar menu +Set a field in `extra` with a key of `hyde_links`: +```toml +[extra] +hyde_links = [ + {url = "https://google.com", name = "Google.com"}, + {url = "https://google.fr", name = "Google.fr"}, +] +``` +Each link needs to have a `url` and a `name`. + +### Sticky sidebar content +By default Hyde ships with a sidebar that affixes it's content to the bottom of the sidebar. You can optionally disable this by setting `hyde_sticky` to false in your `config.toml`. + +### Themes +Hyde ships with eight optional themes based on the [base16 color scheme](https://github.com/chriskempson/base16). Apply a theme to change the color scheme (mostly applies to sidebar and links). + +![Hyde in red](https://f.cloud.github.com/assets/98681/1831229/42b0b354-7384-11e3-8462-31b8df193fe5.png) + +There are eight themes available at this time. + +![Hyde theme classes](https://f.cloud.github.com/assets/98681/1817044/e5b0ec06-6f68-11e3-83d7-acd1942797a1.png) + +To use a theme, set the `hyde_theme` field in `config.toml` to any of the themes name: + +```toml +[extra] +hyde_theme = "theme-base-08" +``` + +To create your own theme, look to the Themes section of [included CSS file](https://github.com/poole/hyde/blob/master/public/css/hyde.css). Copy any existing theme (they're only a few lines of CSS), rename it, and change the provided colors. + +### Reverse layout + +![Hyde with reverse layout](https://f.cloud.github.com/assets/98681/1831230/42b0d3ac-7384-11e3-8d54-2065afd03f9e.png) + +Hyde's page orientation can be reversed by setting `hyde_reversed` to `true` in the `config.toml`. + + \ No newline at end of file diff --git a/docs/content/themes/hyde/screenshot.png b/docs/content/themes/hyde/screenshot.png new file mode 100644 index 00000000..5e218059 Binary files /dev/null and b/docs/content/themes/hyde/screenshot.png differ diff --git a/docs/sass/_themes.scss b/docs/sass/_themes.scss new file mode 100644 index 00000000..3b89053d --- /dev/null +++ b/docs/sass/_themes.scss @@ -0,0 +1,50 @@ + +.themes-container { + padding: 3rem; + + img { + max-width: 100%; + } +} + +.themes { + display: flex; + flex-wrap: wrap; + justify-content: space-between; + + .theme { + width: 30%; + text-decoration: none; + cursor: pointer; + margin-bottom: 2rem; + border-bottom: none; + box-shadow: 0 1px 2px rgba(0, 0, 0, 0.4); + padding: 10px; + + img { + width: 100%; + } + + span { + display: block; + text-align: center; + } + } +} + +.theme-info { + display: flex; + align-items: flex-start; + + .thumb { + box-shadow: 0 1px 2px rgba(0, 0, 0, 0.07); + width: 400px; + margin-right: 2rem; + } + + h1, p { + margin: 0; + } + + padding: 1rem; +} diff --git a/docs/sass/site.scss b/docs/sass/site.scss index bae6b5d7..fadaa37b 100644 --- a/docs/sass/site.scss +++ b/docs/sass/site.scss @@ -15,3 +15,4 @@ $link-color: #007CBC; @import "header"; @import "index"; @import "docs"; +@import "themes"; diff --git a/docs/templates/index.html b/docs/templates/index.html index c366dbb9..5b3bac13 100644 --- a/docs/templates/index.html +++ b/docs/templates/index.html @@ -16,6 +16,7 @@ <nav class="{% block extra_nav_class %}container{% endblock extra_nav_class %}"> <a class="header__logo white" href="{{ config.base_url }}">Gutenberg</a> <a class="white" href="{{ get_url(path="./documentation/_index.md") }}" class="nav-link">Docs</a> + <a class="white" href="{{ get_url(path="./themes/_index.md") }}" class="nav-link">Themes</a> <a class="white" href="https://github.com/Keats/gutenberg" class="nav-link">GitHub</a> </nav> </header> @@ -90,7 +91,7 @@ {% endblock content %} </div> <footer> - ©2017 — <a class="white" href="https://vincent.is">Vincent Prouillet</a> and <a class="white" href="https://github.com/Keats/gutenberg/graphs/contributors">contributors</a> + ©2017-2018 — <a class="white" href="https://vincent.is">Vincent Prouillet</a> and <a class="white" href="https://github.com/Keats/gutenberg/graphs/contributors">contributors</a> </footer> </body> </html> diff --git a/docs/templates/theme.html b/docs/templates/theme.html new file mode 100644 index 00000000..85bf745c --- /dev/null +++ b/docs/templates/theme.html @@ -0,0 +1,19 @@ +{% extends "themes.html" %} + +{% block title %}{{ page.title }} | Gutenberg {% endblock title %} +{% block theme_content %} + <div class="theme-info"> + <img src="{{page.permalink}}screenshot.png" class="thumb"> + <div class="metadata"> + <h1>{{ page.title }}</h1> + <p>{{ page.description }}</p> + <p><b>Author:</b> {{page.extra.author.name}}</p> + <p><b>License:</b> {{page.extra.license}}</p> + <p><b>Homepage:</b> {{page.extra.homepage}}</p> + <p><b>Last updated:</b> {{page.extra.updated }}</p> + </div> + </div> + + <hr> + {{page.content | safe}} +{% endblock theme_content %} diff --git a/docs/templates/themes.html b/docs/templates/themes.html new file mode 100644 index 00000000..e4dcb7d5 --- /dev/null +++ b/docs/templates/themes.html @@ -0,0 +1,22 @@ +{% extends "index.html" %} + +{% block extra_nav_class %}{% endblock extra_nav_class %} +{% block extra_content_class %}content--reversed{% endblock extra_content_class %} + +{% block title %}Themes | {{ super() }} {% endblock title %} + +{% block content %} + <div class="themes-container"> + {% block theme_content %} + <h1>Gutenberg themes</h1> + <div class="themes"> + {% for theme in section.pages %} + <a class="theme" href="{{theme.permalink}}"> + <img src="{{theme.permalink}}screenshot.png" alt="Screenshot of {{theme.title}}"> + <span>{{theme.title}}</span> + </a> + {% endfor %} + </div> + {% endblock theme_content %} + </div> +{% endblock content %}