just-the-docs-peter 0.1.0 → 0.1.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (96) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +1508 -0
  3. data/LICENSE.txt +21 -0
  4. data/README.md +110 -0
  5. data/Rakefile +1 -0
  6. data/_includes/components/aux_nav.html +15 -0
  7. data/_includes/components/breadcrumbs.html +43 -0
  8. data/_includes/components/children_nav.html +33 -0
  9. data/_includes/components/footer.html +34 -0
  10. data/_includes/components/header.html +11 -0
  11. data/_includes/components/mermaid.html +45 -0
  12. data/_includes/components/search_footer.html +7 -0
  13. data/_includes/components/search_header.html +9 -0
  14. data/_includes/components/sidebar.html +71 -0
  15. data/_includes/css/callouts.scss.liquid +93 -0
  16. data/_includes/css/custom.scss.liquid +1 -0
  17. data/_includes/css/just-the-docs.scss.liquid +12 -0
  18. data/_includes/fix_linenos.html +65 -0
  19. data/_includes/footer_custom.html +3 -0
  20. data/_includes/head.html +42 -0
  21. data/_includes/head_custom.html +0 -0
  22. data/_includes/header_custom.html +0 -0
  23. data/_includes/icons/code_copy.html +15 -0
  24. data/_includes/icons/document.html +6 -0
  25. data/_includes/icons/expand.html +6 -0
  26. data/_includes/icons/external_link.html +5 -0
  27. data/_includes/icons/icons.html +13 -0
  28. data/_includes/icons/link.html +6 -0
  29. data/_includes/icons/menu.html +6 -0
  30. data/_includes/icons/search.html +6 -0
  31. data/_includes/js/custom.js +0 -0
  32. data/_includes/lunr/custom-data.json +0 -0
  33. data/_includes/lunr/custom-index.js +0 -0
  34. data/_includes/mermaid_config.js +1 -0
  35. data/_includes/nav.html +106 -0
  36. data/_includes/nav_footer_custom.html +0 -0
  37. data/_includes/search_placeholder_custom.html +1 -0
  38. data/_includes/sorted_pages.html +95 -0
  39. data/_includes/title.html +5 -0
  40. data/_includes/toc_heading_custom.html +1 -0
  41. data/_includes/vendor/anchor_headings.html +172 -0
  42. data/_layouts/about.html +5 -0
  43. data/_layouts/default.html +41 -0
  44. data/_layouts/home.html +5 -0
  45. data/_layouts/minimal.html +34 -0
  46. data/_layouts/page.html +5 -0
  47. data/_layouts/post.html +5 -0
  48. data/_layouts/table_wrappers.html +7 -0
  49. data/_layouts/vendor/compress.html +10 -0
  50. data/_sass/base.scss +109 -0
  51. data/_sass/buttons.scss +123 -0
  52. data/_sass/code.scss +246 -0
  53. data/_sass/color_schemes/dark.scss +17 -0
  54. data/_sass/color_schemes/legacy_light.scss +208 -0
  55. data/_sass/color_schemes/light.scss +15 -0
  56. data/_sass/color_schemes/light_peter.scss +15 -0
  57. data/_sass/content.scss +239 -0
  58. data/_sass/custom/custom.scss +1 -0
  59. data/_sass/custom/setup.scss +1 -0
  60. data/_sass/labels.scss +33 -0
  61. data/_sass/layout.scss +209 -0
  62. data/_sass/modules.scss +17 -0
  63. data/_sass/navigation.scss +235 -0
  64. data/_sass/print.scss +40 -0
  65. data/_sass/search.scss +311 -0
  66. data/_sass/skiptomain.scss +30 -0
  67. data/_sass/support/_variables.scss +116 -0
  68. data/_sass/support/mixins/_buttons.scss +27 -0
  69. data/_sass/support/mixins/_layout.scss +33 -0
  70. data/_sass/support/mixins/_typography.scss +84 -0
  71. data/_sass/support/mixins/mixins.scss +3 -0
  72. data/_sass/support/support.scss +2 -0
  73. data/_sass/tables.scss +54 -0
  74. data/_sass/typography.scss +63 -0
  75. data/_sass/utilities/_colors.scss +237 -0
  76. data/_sass/utilities/_layout.scss +101 -0
  77. data/_sass/utilities/_lists.scss +15 -0
  78. data/_sass/utilities/_spacing.scss +162 -0
  79. data/_sass/utilities/_typography.scss +85 -0
  80. data/_sass/utilities/utilities.scss +5 -0
  81. data/_sass/vendor/OneDarkJekyll/LICENSE +21 -0
  82. data/_sass/vendor/OneDarkJekyll/syntax.scss +202 -0
  83. data/_sass/vendor/OneLightJekyll/LICENSE +65 -0
  84. data/_sass/vendor/OneLightJekyll/syntax.scss +208 -0
  85. data/_sass/vendor/normalize.scss/README.md +7 -0
  86. data/_sass/vendor/normalize.scss/normalize.scss +351 -0
  87. data/assets/css/just-the-docs-dark.scss +3 -0
  88. data/assets/css/just-the-docs-default.scss +8 -0
  89. data/assets/css/just-the-docs-light.scss +3 -0
  90. data/assets/js/just-the-docs.js +535 -0
  91. data/assets/js/vendor/lunr.min.js +61 -0
  92. data/assets/js/zzzz-search-data.json +74 -0
  93. data/bin/just-the-docs +16 -0
  94. data/favicon.ico +0 -0
  95. data/lib/tasks/search.rake +88 -0
  96. metadata +152 -11
data/LICENSE.txt ADDED
@@ -0,0 +1,21 @@
1
+ The MIT License (MIT)
2
+
3
+ Copyright (c) 2016 Patrick Marsceill
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in
13
+ all copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
21
+ THE SOFTWARE.
data/README.md ADDED
@@ -0,0 +1,110 @@
1
+ <p align="right">
2
+ <a href="https://badge.fury.io/rb/just-the-docs"><img src="https://badge.fury.io/rb/just-the-docs.svg" alt="Gem version"></a> <a href="https://github.com/just-the-docs/just-the-docs/actions/workflows/ci.yml"><img src="https://github.com/just-the-docs/just-the-docs/actions/workflows/ci.yml/badge.svg" alt="CI Build status"></a> <a href="https://app.netlify.com/sites/just-the-docs/deploys"><img src="https://api.netlify.com/api/v1/badges/9dc0386d-c2a4-4077-ad83-f02c33a6c0ca/deploy-status" alt="Netlify Status"></a>
3
+ </p>
4
+ <br><br>
5
+ <p align="center">
6
+ <h1 align="center">Just the Docs</h1>
7
+ <p align="center">A modern, highly customizable, and responsive Jekyll theme for documentation with built-in search.<br>Easily hosted on GitHub Pages with few dependencies.</p>
8
+ <p align="center"><strong><a href="https://just-the-docs.com/">See it in action!</a></strong></p>
9
+ <br><br><br>
10
+ </p>
11
+
12
+ <p align="center">A video walkthrough of various Just the Docs features</p>
13
+
14
+ https://user-images.githubusercontent.com/85418632/211225192-7e5d1116-2f4f-4305-bb9b-437fe47df071.mp4
15
+
16
+ ## Installation
17
+
18
+ ### Use the template
19
+
20
+ The [Just the Docs Template] provides the simplest, quickest, and easiest way to create a new website that uses the Just the Docs theme. To get started with creating a site, just click "[use the template]"!
21
+
22
+ Note: To use the theme, you do ***not*** need to clone or fork the [Just the Docs repo]! You should do that only if you intend to browse the theme docs locally, contribute to the development of the theme, or develop a new theme based on Just the Docs.
23
+
24
+ You can easily set the site created by the template to be published on [GitHub Pages] – the [template README] file explains how to do that, along with other details.
25
+
26
+ If [Jekyll] is installed on your computer, you can also build and preview the created site *locally*. This lets you test changes before committing them, and avoids waiting for GitHub Pages.[^2] And you will be able to deploy your local build to a different platform than GitHub Pages.
27
+
28
+ More specifically, the created site:
29
+
30
+ - uses a gem-based approach, i.e. uses a `Gemfile` and loads the `just-the-docs` gem
31
+ - uses the [GitHub Pages / Actions workflow] to build and publish the site on GitHub Pages
32
+
33
+ Other than that, you're free to customize sites that you create with the template, however you like. You can easily change the versions of `just-the-docs` and Jekyll it uses, as well as adding further plugins.
34
+
35
+ ### Use RubyGems
36
+
37
+ Alternatively, you can install the theme as a Ruby Gem, without creating a new site.
38
+
39
+ Add this line to your Jekyll site's `Gemfile`:
40
+
41
+ ```ruby
42
+ gem "just-the-docs"
43
+ ```
44
+
45
+ And add this line to your Jekyll site's `_config.yml`:
46
+
47
+ ```yaml
48
+ theme: just-the-docs
49
+ ```
50
+
51
+ And then execute:
52
+
53
+ $ bundle
54
+
55
+ Or install it yourself as:
56
+
57
+ $ gem install just-the-docs
58
+
59
+ Alternatively, you can run it inside Docker while developing your site
60
+
61
+ $ docker-compose up
62
+
63
+ ## Usage
64
+
65
+ [View the documentation][Just the Docs] for usage information.
66
+
67
+ ## Contributing
68
+
69
+ Bug reports, proposals of new features, and pull requests are welcome on GitHub at https://github.com/just-the-docs/just-the-docs. This project is intended to be a safe, welcoming space for collaboration, and contributors are expected to adhere to the [Contributor Covenant](http://contributor-covenant.org) code of conduct.
70
+
71
+ ### Submitting code changes:
72
+
73
+ - Submit an [Issue](https://github.com/just-the-docs/just-the-docs/issues) that motivates the changes, using the appropriate template
74
+ - Discuss the proposed changes with other users and the maintainers
75
+ - Open a [Pull Request](https://github.com/just-the-docs/just-the-docs/pulls)
76
+ - Ensure all CI tests pass
77
+ - Provide instructions to check the effect of the changes
78
+ - Await code review
79
+
80
+ ### Design and development principles of this theme:
81
+
82
+ 1. As few dependencies as possible
83
+ 2. No build script needed
84
+ 3. First class mobile experience
85
+ 4. Make the content shine
86
+
87
+ ## Development
88
+
89
+ To set up your environment to develop this theme: fork this repo, the run `bundle install` from the root directory.
90
+
91
+ A modern [devcontainer configuration](https://code.visualstudio.com/docs/remote/containers) for VSCode is included.
92
+
93
+ Your theme is set up just like a normal Jekyll site! To test your theme, run `bundle exec jekyll serve` and open your browser at `http://localhost:4000`. This starts a Jekyll server using your theme. Add pages, documents, data, etc. like normal to test your theme's contents. As you make modifications to your theme and to your content, your site will regenerate and you should see the changes in the browser after a refresh, just like normal.
94
+
95
+ When this theme is released, only the files in `_layouts`, `_includes`, and `_sass` tracked with Git will be included in the gem.
96
+
97
+ ## License
98
+
99
+ The theme is available as open source under the terms of the [MIT License](http://opensource.org/licenses/MIT).
100
+
101
+ [^2]: [It can take up to 10 minutes for changes to your site to publish after you push the changes to GitHub](https://docs.github.com/en/pages/setting-up-a-github-pages-site-with-jekyll/creating-a-github-pages-site-with-jekyll#creating-your-site).
102
+
103
+ [Jekyll]: https://jekyllrb.com
104
+ [Just the Docs Template]: https://just-the-docs.github.io/just-the-docs-template/
105
+ [Just the Docs]: https://just-the-docs.com
106
+ [Just the Docs repo]: https://github.com/just-the-docs/just-the-docs
107
+ [GitHub Pages]: https://pages.github.com/
108
+ [Template README]: https://github.com/just-the-docs/just-the-docs-template/blob/main/README.md
109
+ [GitHub Pages / Actions workflow]: https://github.blog/changelog/2022-07-27-github-pages-custom-github-actions-workflows-beta/
110
+ [use the template]: https://github.com/just-the-docs/just-the-docs-template/generate
data/Rakefile ADDED
@@ -0,0 +1 @@
1
+ Dir.glob('lib/tasks/*.rake').each {|r| import r}
@@ -0,0 +1,15 @@
1
+ <nav aria-label="Auxiliary" class="aux-nav">
2
+ <ul class="aux-nav-list">
3
+ {% for link in site.aux_links %}
4
+ <li class="aux-nav-list-item">
5
+ <a href="{{ link.last }}" class="site-button"
6
+ {% if site.aux_links_new_tab %}
7
+ target="_blank" rel="noopener noreferrer"
8
+ {% endif %}
9
+ >
10
+ {{ link.first }}
11
+ </a>
12
+ </li>
13
+ {% endfor %}
14
+ </ul>
15
+ </nav>
@@ -0,0 +1,43 @@
1
+ {%- comment -%}
2
+ Include as: {%- include components/breadcrumbs.html -%}
3
+ Depends on: page, site.
4
+ Results in: HTML for the breadcrumbs component.
5
+ Overwrites:
6
+ pages_list, parent_page, grandparent_page.
7
+ {%- endcomment -%}
8
+
9
+ {%- if page.url != "/" and page.parent -%}
10
+
11
+ {%- assign pages_list = site[page.collection]
12
+ | default: site.html_pages
13
+ | where_exp: "item", "item.title != nil"
14
+ | where_exp: "item", "item.has_children != nil" -%}
15
+
16
+ {%- if page.grand_parent -%}
17
+ {%- assign parent_page = pages_list
18
+ | where: "title", page.parent
19
+ | where: "parent", page.grand_parent
20
+ | first -%}
21
+ {%- assign grandparent_page = pages_list
22
+ | where: "title", page.grand_parent
23
+ | first -%}
24
+ {%- else -%}
25
+ {%- assign parent_page = pages_list
26
+ | where: "title", page.parent
27
+ | where_exp: "item", "item.parent == nil"
28
+ | first -%}
29
+ {%- endif -%}
30
+
31
+ <nav aria-label="Breadcrumb" class="breadcrumb-nav">
32
+ <ol class="breadcrumb-nav-list">
33
+ {% if page.parent -%}
34
+ {%- if page.grand_parent %}
35
+ <li class="breadcrumb-nav-list-item"><a href="{{ grandparent_page.url | relative_url }}">{{ page.grand_parent }}</a></li>
36
+ {%- endif %}
37
+ <li class="breadcrumb-nav-list-item"><a href="{{ parent_page.url | relative_url }}">{{ page.parent }}</a></li>
38
+ {% endif -%}
39
+ <li class="breadcrumb-nav-list-item"><span>{{ page.title }}</span></li>
40
+ </ol>
41
+ </nav>
42
+
43
+ {%- endif -%}
@@ -0,0 +1,33 @@
1
+ {%- comment -%}
2
+ Include as: {%- include components/children_nav.html -%}
3
+ Depends on: page, site.
4
+ Results in: HTML for the children-navigation component.
5
+ Includes:
6
+ sorted_pages.html
7
+ toc_heading_custom.html
8
+ Overwrites:
9
+ child_pages.
10
+ {%- endcomment -%}
11
+
12
+ {%- if page.has_children == true and page.has_toc != false -%}
13
+ {%- assign child_pages = site[page.collection]
14
+ | default: site.html_pages
15
+ | where: "parent", page.title
16
+ | where: "grand_parent", page.parent -%}
17
+
18
+ {%- include sorted_pages.html pages = child_pages -%}
19
+
20
+ {%- if page.child_nav_order == 'desc' or page.child_nav_order == 'reversed' -%}
21
+ {%- assign sorted_pages = sorted_pages | reverse -%}
22
+ {%- endif -%}
23
+ {%- endif -%}
24
+
25
+ <hr>
26
+ {% include toc_heading_custom.html %}
27
+ <ul>
28
+ {% for child in sorted_pages %}
29
+ <li>
30
+ <a href="{{ child.url | relative_url }}">{{ child.title }}</a>{% if child.summary %} - {{ child.summary }}{% endif %}
31
+ </li>
32
+ {% endfor %}
33
+ </ul>
@@ -0,0 +1,34 @@
1
+ {% capture footer_custom %}
2
+ {%- include footer_custom.html -%}
3
+ {% endcapture %}
4
+ {% if footer_custom != "" or site.last_edit_timestamp or site.gh_edit_link %}
5
+ <hr>
6
+ <footer>
7
+ {% if site.back_to_top %}
8
+ <p><a href="#top" id="back-to-top">{{ site.back_to_top_text }}</a></p>
9
+ {% endif %}
10
+
11
+ {{ footer_custom }}
12
+
13
+ {% if site.last_edit_timestamp or site.gh_edit_link %}
14
+ <div class="d-flex mt-2">
15
+ {% if site.last_edit_timestamp and site.last_edit_time_format and page.last_modified_date %}
16
+ <p class="text-small text-grey-dk-000 mb-0 mr-2">
17
+ Page last modified: <span class="d-inline-block">{{ page.last_modified_date | date: site.last_edit_time_format }}</span>.
18
+ </p>
19
+ {% endif %}
20
+ {% if
21
+ site.gh_edit_link and
22
+ site.gh_edit_link_text and
23
+ site.gh_edit_repository and
24
+ site.gh_edit_branch and
25
+ site.gh_edit_view_mode
26
+ %}
27
+ <p class="text-small text-grey-dk-000 mb-0">
28
+ <a href="{{ site.gh_edit_repository }}/{{ site.gh_edit_view_mode }}/{{ site.gh_edit_branch }}{% if site.gh_edit_source %}/{{ site.gh_edit_source }}{% endif %}{% if page.collection and site.collections_dir %}/{{ site.collections_dir }}{% endif %}/{{ page.path }}" id="edit-this-page">{{ site.gh_edit_link_text }}</a>
29
+ </p>
30
+ {% endif %}
31
+ </div>
32
+ {% endif %}
33
+ </footer>
34
+ {% endif %}
@@ -0,0 +1,11 @@
1
+ <div id="main-header" class="main-header">
2
+ {% if site.search_enabled != false %}
3
+ {% include components/search_header.html %}
4
+ {% else %}
5
+ <div></div>
6
+ {% endif %}
7
+ {% include header_custom.html %}
8
+ {% if site.aux_links %}
9
+ {% include components/aux_nav.html %}
10
+ {% endif %}
11
+ </div>
@@ -0,0 +1,45 @@
1
+ {% comment %}
2
+ The complexity of this file comes from a breaking change in Mermaid v10; mermaid.init has been deprecated (and supposedly, didn't work earlier?).
3
+
4
+ So, we check whether the user's Mermaid version is >= 10; if not, we fall back to the previous init syntax.
5
+
6
+ If a user is using a custom mermaid file and doesn't specify a version, we default to the < v10 behaviour. Users who use version v10 or above should specify this in the version key.
7
+ {% endcomment %}
8
+
9
+ {% if site.mermaid.version %}
10
+ {% assign mermaid_major_version = site.mermaid.version | split: "." | first | plus: 0 %}
11
+ {% else %}
12
+ {% assign mermaid_major_version = 9 %}
13
+ {% endif %}
14
+
15
+ {% if mermaid_major_version > 9 %}
16
+
17
+ <script type="module">
18
+ {% if site.mermaid.path %}
19
+ import mermaid from '{{ site.mermaid.path | relative_url }}';
20
+ {% else %}
21
+ import mermaid from 'https://cdn.jsdelivr.net/npm/mermaid@{{ site.mermaid.version }}/dist/mermaid.esm.min.mjs';
22
+ {% endif %}
23
+
24
+ var config = {% include mermaid_config.js %};
25
+ mermaid.initialize(config);
26
+ mermaid.run({
27
+ querySelector: '.language-mermaid',
28
+ });
29
+ </script>
30
+
31
+ {% else %}
32
+
33
+ {% if site.mermaid.path %}
34
+ <script src="{{ site.mermaid.path | relative_url }}"></script>
35
+ {% else %}
36
+ <script src="https://cdn.jsdelivr.net/npm/mermaid@{{ site.mermaid.version }}/dist/mermaid.min.js"></script>
37
+ {% endif %}
38
+
39
+ <script>
40
+ var config = {% include mermaid_config.js %};
41
+ mermaid.initialize(config);
42
+ window.mermaid.init(undefined, document.querySelectorAll('.language-mermaid'));
43
+ </script>
44
+
45
+ {% endif %}
@@ -0,0 +1,7 @@
1
+ {% if site.search.button %}
2
+ <button id="search-button" class="search-button btn-reset" aria-label="Focus on search">
3
+ <svg viewBox="0 0 24 24" class="icon" aria-hidden="true"><use xlink:href="#svg-search"></use></svg>
4
+ </button>
5
+ {% endif %}
6
+
7
+ <div class="search-overlay"></div>
@@ -0,0 +1,9 @@
1
+ {% capture search_placeholder %}{% include search_placeholder_custom.html %}{% endcapture %}
2
+
3
+ <div class="search" role="search">
4
+ <div class="search-input-wrap">
5
+ <input type="text" id="search-input" class="search-input" tabindex="0" placeholder="{{ search_placeholder | strip_html | strip }}" aria-label="{{ search_placeholder | strip_html| strip }}" autocomplete="off">
6
+ <label for="search-input" class="search-label"><svg viewBox="0 0 24 24" class="search-icon"><use xlink:href="#svg-search"></use></svg></label>
7
+ </div>
8
+ <div id="search-results" class="search-results"></div>
9
+ </div>
@@ -0,0 +1,71 @@
1
+ <div class="side-bar">
2
+ <div class="site-header" role="banner">
3
+ <a href="{{ '/' | relative_url }}" class="site-title lh-tight">{% include title.html %}</a>
4
+ <button id="menu-button" class="site-button btn-reset" aria-label="Toggle menu" aria-pressed="false">
5
+ <svg viewBox="0 0 24 24" class="icon" aria-hidden="true"><use xlink:href="#svg-menu"></use></svg>
6
+ </a>
7
+ </div>
8
+ <nav aria-label="Main" id="site-nav" class="site-nav">
9
+ {% assign pages_top_size = site.html_pages
10
+ | where_exp:"item", "item.title != nil"
11
+ | where_exp:"item", "item.parent == nil"
12
+ | where_exp:"item", "item.nav_exclude != true"
13
+ | size %}
14
+ {% if pages_top_size > 0 %}
15
+ {% include nav.html pages=site.html_pages key=nil %}
16
+ {% endif %}
17
+ {%- if site.nav_external_links -%}
18
+ <ul class="nav-list">
19
+ {%- for node in site.nav_external_links -%}
20
+ <li class="nav-list-item external">
21
+ <a href="{{ node.url | absolute_url }}" class="nav-list-link external">
22
+ {{ node.title }}
23
+ {% unless node.hide_icon %}<svg viewBox="0 0 24 24" aria-labelledby="svg-external-link-title"><use xlink:href="#svg-external-link"></use></svg>{% endunless %}
24
+ </a>
25
+ </li>
26
+ {%- endfor -%}
27
+ </ul>
28
+ {%- endif -%}
29
+ {% if site.just_the_docs.collections %}
30
+ {% assign collections_size = site.just_the_docs.collections | size %}
31
+ {% for collection_entry in site.just_the_docs.collections %}
32
+ {% assign collection_key = collection_entry[0] %}
33
+ {% assign collection_value = collection_entry[1] %}
34
+ {% assign collection = site[collection_key] %}
35
+ {% if collection_value.nav_exclude != true %}
36
+ {% if collections_size > 1 or pages_top_size > 0 %}
37
+ {% if collection_value.nav_fold == true %}
38
+ <ul class="nav-list nav-category-list">
39
+ <li class="nav-list-item{% if page.collection == collection_key %} active{% endif %}">
40
+ {%- if collection.size > 0 -%}
41
+ <button class="nav-list-expander btn-reset" aria-label="Toggle collection {{ collection_value.name }}" aria-pressed="{% if page.collection == collection_key %}true{% else %}false{% endif %}">
42
+ <svg viewBox="0 0 24 24" aria-hidden="true"><use xlink:href="#svg-arrow-right"></use></svg>
43
+ </button>
44
+ {%- endif -%}
45
+ <div class="nav-category">{{ collection_value.name }}</div>
46
+ {% include nav.html pages=collection key=collection_key %}
47
+ </li>
48
+ </ul>
49
+ {% else %}
50
+ <div class="nav-category">{{ collection_value.name }}</div>
51
+ {% include nav.html pages=collection key=collection_key %}
52
+ {% endif %}
53
+ {% else %}
54
+ {% include nav.html pages=collection key=collection_key %}
55
+ {% endif %}
56
+ {% endif %}
57
+ {% endfor %}
58
+ {% endif %}
59
+ </nav>
60
+
61
+ {% capture nav_footer_custom %}
62
+ {%- include nav_footer_custom.html -%}
63
+ {% endcapture %}
64
+ {% if nav_footer_custom != "" %}
65
+ {{ nav_footer_custom }}
66
+ {% else %}
67
+ <footer class="site-footer">
68
+ This site uses <a href="https://github.com/just-the-docs/just-the-docs">Just the Docs</a>, a documentation theme for Jekyll.
69
+ </footer>
70
+ {% endif %}
71
+ </div>
@@ -0,0 +1,93 @@
1
+ {%- comment -%}
2
+ {% include css/callouts.scss.liquid color_scheme = string %}
3
+ produces SCSS for all the callouts in site.callouts. For the "dark"
4
+ color scheme, the levels of the text and background colors are reversed.
5
+ {%- endcomment -%}
6
+
7
+ {%- assign callout_background_hue = "000" -%}
8
+ {%- assign callout_color_hue = "300" -%}
9
+ {%- if site.callouts_level == "loud" or include.color_scheme == "dark" and site.callouts_level != "quiet" -%}
10
+ {%- assign callout_background_hue = "300" -%}
11
+ {%- assign callout_color_hue = "000" -%}
12
+ {%- endif -%}
13
+
14
+ div.opaque {
15
+ background-color: $body-background-color;
16
+ }
17
+
18
+ {%- for callout in site.callouts %}
19
+
20
+ {%- assign callout_opacity = callout[1].opacity | default: site.callouts_opacity | default: 0.2 -%}
21
+
22
+ p.{{ callout[0] }}, blockquote.{{ callout[0] }} {
23
+ background: rgba(${{ callout[1].color }}-{{ callout_background_hue }}, {{ callout_opacity }});
24
+ border-left: $border-radius solid ${{ callout[1].color }}-{{ callout_color_hue }};
25
+ border-radius: $border-radius;
26
+ box-shadow: 0 1px 2px rgba(0, 0, 0, 0.12), 0 3px 10px rgba(0, 0, 0, 0.08);
27
+ padding: .8rem;
28
+ {% if callout[1].title %}
29
+ &::before {
30
+ color: ${{ callout[1].color }}-{{ callout_color_hue }};
31
+ content: "{{ callout[1].title }}";
32
+ display: block;
33
+ font-weight: bold;
34
+ text-transform: uppercase;
35
+ font-size: .75em;
36
+ padding-bottom: .125rem;
37
+ }
38
+ {% endif %}
39
+ > .{{ callout[0] }}-title {
40
+ color: ${{ callout[1].color }}-{{ callout_color_hue }};
41
+ display: block;
42
+ font-weight: bold;
43
+ text-transform: uppercase;
44
+ font-size: .75em;
45
+ padding-bottom: .125rem;
46
+ }
47
+ }
48
+
49
+ p.{{ callout[0] }}-title, blockquote.{{ callout[0] }}-title {
50
+ background: rgba(${{ callout[1].color }}-{{ callout_background_hue }}, {{ callout_opacity }});
51
+ border-left: $border-radius solid ${{ callout[1].color }}-{{ callout_color_hue }};
52
+ border-radius: $border-radius;
53
+ box-shadow: 0 1px 2px rgba(0, 0, 0, 0.12), 0 3px 10px rgba(0, 0, 0, 0.08);
54
+ padding: .8rem;
55
+ > p:first-child {
56
+ margin-top: 0;
57
+ margin-bottom: 0;
58
+ color: ${{ callout[1].color }}-{{ callout_color_hue }};
59
+ display: block;
60
+ font-weight: bold;
61
+ text-transform: uppercase;
62
+ font-size: .75em;
63
+ padding-bottom: .125rem;
64
+ }
65
+ }
66
+
67
+ blockquote.{{ callout[0] }} {
68
+ margin-left: 0;
69
+ margin-right: 0;
70
+
71
+ > p:first-child {
72
+ margin-top: 0;
73
+ }
74
+
75
+ > p:last-child {
76
+ margin-bottom: 0;
77
+ }
78
+ }
79
+
80
+ blockquote.{{ callout[0] }}-title {
81
+ margin-left: 0;
82
+ margin-right: 0;
83
+
84
+ > p:nth-child(2) {
85
+ margin-top: 0;
86
+ }
87
+
88
+ > p:last-child {
89
+ margin-bottom: 0;
90
+ }
91
+ }
92
+
93
+ {% endfor -%}
@@ -0,0 +1 @@
1
+ @import "./custom/custom";
@@ -0,0 +1,12 @@
1
+ {% if site.logo %}
2
+ $logo: "{{ site.logo | relative_url }}";
3
+ {% endif %}
4
+ @import "./support/support";
5
+ @import "./custom/setup";
6
+ @import "./color_schemes/light";
7
+ {% unless include.color_scheme == "light" %}
8
+ @import "./color_schemes/{{ include.color_scheme }}";
9
+ {% endunless %}
10
+ @import "./modules";
11
+ {% include css/callouts.scss.liquid color_scheme = include.color_scheme %}
12
+ {% include css/custom.scss.liquid %}
@@ -0,0 +1,65 @@
1
+ {%- comment -%}
2
+ This file can be used to fix the HTML produced by Jekyll for highlighted
3
+ code with line numbers.
4
+
5
+ It works with `{% highlight some_language linenos %}...{% endhighlight %}`
6
+ and with the Kramdown option to add line numbers to fenced code.
7
+
8
+ The implementation was derived from the workaround provided by
9
+ Dmitry Hrabrov (DeXP) at
10
+ https://github.com/penibelst/jekyll-compress-html/issues/71#issuecomment-188144901
11
+
12
+ EXPLANATION
13
+
14
+ The HTML produced by Rouge highlighting with lie numbers is of the form
15
+ `code table`. Jekyll (<= 4.1.1) always wraps the highlighted HTML
16
+ with `pre`. This wrapping is not only unnecessary, but also transforms
17
+ the conforming HTML produced by Rouge to non-conforming HTML, which
18
+ results in HTML validation error reports.
19
+
20
+ The fix removes the outer `pre` tags whenever they contain the pattern
21
+ `<table class="rouge-table">`.
22
+
23
+ Apart from avoiding HTML validation errors, the fix allows the use of
24
+ the [Jekyll layout for compressing HTML](http://jch.penibelst.de),
25
+ which relies on `pre` tags not being nested, according to
26
+ https://github.com/penibelst/jekyll-compress-html/issues/71#issuecomment-172069842
27
+
28
+ USAGE
29
+
30
+ (Any names can be used for `some_var` and `some_language`.)
31
+
32
+ {% capture some_var %}
33
+ {% highlight some_language linenos %}
34
+ Some code
35
+ {% endhighlight %}
36
+ {% endcapture %}
37
+ {% include fix_linenos.html code=some_var %}
38
+
39
+ For code fences:
40
+
41
+ {% capture some_var %}
42
+ ```some_language
43
+ Some code
44
+ ```
45
+ {% endcapture %}
46
+ {% assign some_var = some_var | markdownify %}
47
+ {% include fix_linenos.html code=some_var %}
48
+
49
+ CAVEATS
50
+
51
+ The above does not work when `Some code` happens to contain the matched string
52
+ `<table class="rouge-table">`.
53
+
54
+ The use of this file overwrites the variable `fix_linenos_code` with `nil`.
55
+
56
+ {%- endcomment -%}
57
+
58
+ {% assign fix_linenos_code = include.code %}
59
+ {% if fix_linenos_code contains '<table class="rouge-table">' %}
60
+ {% assign fix_linenos_code = fix_linenos_code | replace: '<pre class="highlight">', '<pre>' %}
61
+ {% assign fix_linenos_code = fix_linenos_code | replace: "<pre><code", "<code" %}
62
+ {% assign fix_linenos_code = fix_linenos_code | replace: "</code></pre>", "</code>" %}
63
+ {% endif %}
64
+ {{ fix_linenos_code }}
65
+ {% assign fix_linenos_code = nil %}
@@ -0,0 +1,3 @@
1
+ {%- if site.footer_content -%}
2
+ <p class="text-small text-grey-dk-100 mb-0">{{ site.footer_content }}</p>
3
+ {%- endif -%}
@@ -0,0 +1,42 @@
1
+ <head>
2
+ <meta charset="UTF-8">
3
+ <meta http-equiv="X-UA-Compatible" content="IE=Edge">
4
+
5
+ <link rel="stylesheet" href="{{ '/assets/css/just-the-docs-default.css' | relative_url }}">
6
+
7
+ {% if site.ga_tracking != nil %}
8
+ {% assign ga_tracking_ids = site.ga_tracking | split: "," %}
9
+ <script async src="https://www.googletagmanager.com/gtag/js?id={{ ga_tracking_ids.first }}"></script>
10
+ <script>
11
+ window.dataLayer = window.dataLayer || [];
12
+ function gtag(){dataLayer.push(arguments);}
13
+ gtag('js', new Date());
14
+
15
+ {% for ga_property in ga_tracking_ids %}
16
+ gtag('config', '{{ ga_property }}'{% unless site.ga_tracking_anonymize_ip == nil %}, { 'anonymize_ip': true }{% endunless %});
17
+ {% endfor %}
18
+ </script>
19
+ {% endif %}
20
+
21
+ {% if site.search_enabled != false %}
22
+ <script src="{{ '/assets/js/vendor/lunr.min.js' | relative_url }}"></script>
23
+ {% endif %}
24
+
25
+ <script src="{{ '/assets/js/just-the-docs.js' | relative_url }}"></script>
26
+
27
+ <meta name="viewport" content="width=device-width, initial-scale=1">
28
+
29
+ {% for file in site.static_files %}
30
+ {% if file.path == site.favicon_ico or file.path == '/favicon.ico' %}
31
+ {% assign favicon = true %}
32
+ {% endif %}
33
+ {% endfor %}
34
+ {% if favicon %}
35
+ <link rel="icon" href="{{ site.favicon_ico | default: '/favicon.ico' | relative_url }}" type="image/x-icon">
36
+ {% endif %}
37
+
38
+ {% seo %}
39
+
40
+ {% include head_custom.html %}
41
+
42
+ </head>
File without changes
File without changes
@@ -0,0 +1,15 @@
1
+ <!-- Bootstrap Icons. MIT License: https://github.com/twbs/icons/blob/main/LICENSE.md -->
2
+ <symbol id="svg-copy" viewBox="0 0 16 16">
3
+ <title>Copy</title>
4
+ <svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" fill="currentColor" class="bi bi-clipboard" viewBox="0 0 16 16">
5
+ <path d="M4 1.5H3a2 2 0 0 0-2 2V14a2 2 0 0 0 2 2h10a2 2 0 0 0 2-2V3.5a2 2 0 0 0-2-2h-1v1h1a1 1 0 0 1 1 1V14a1 1 0 0 1-1 1H3a1 1 0 0 1-1-1V3.5a1 1 0 0 1 1-1h1v-1z"/>
6
+ <path d="M9.5 1a.5.5 0 0 1 .5.5v1a.5.5 0 0 1-.5.5h-3a.5.5 0 0 1-.5-.5v-1a.5.5 0 0 1 .5-.5h3zm-3-1A1.5 1.5 0 0 0 5 1.5v1A1.5 1.5 0 0 0 6.5 4h3A1.5 1.5 0 0 0 11 2.5v-1A1.5 1.5 0 0 0 9.5 0h-3z"/>
7
+ </svg>
8
+ </symbol>
9
+ <symbol id="svg-copied" viewBox="0 0 16 16">
10
+ <title>Copied</title>
11
+ <svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" fill="currentColor" class="bi bi-clipboard-check-fill" viewBox="0 0 16 16">
12
+ <path d="M6.5 0A1.5 1.5 0 0 0 5 1.5v1A1.5 1.5 0 0 0 6.5 4h3A1.5 1.5 0 0 0 11 2.5v-1A1.5 1.5 0 0 0 9.5 0h-3Zm3 1a.5.5 0 0 1 .5.5v1a.5.5 0 0 1-.5.5h-3a.5.5 0 0 1-.5-.5v-1a.5.5 0 0 1 .5-.5h3Z"/>
13
+ <path d="M4 1.5H3a2 2 0 0 0-2 2V14a2 2 0 0 0 2 2h10a2 2 0 0 0 2-2V3.5a2 2 0 0 0-2-2h-1v1A2.5 2.5 0 0 1 9.5 5h-3A2.5 2.5 0 0 1 4 2.5v-1Zm6.854 7.354-3 3a.5.5 0 0 1-.708 0l-1.5-1.5a.5.5 0 0 1 .708-.708L7.5 10.793l2.646-2.647a.5.5 0 0 1 .708.708Z"/>
14
+ </svg>
15
+ </symbol>