jekyll-rtd-theme 1.1.8 → 2.0.0.pre.beta

Sign up to get free protection for your applications and to get access to all the features.
Files changed (109) hide show
  1. checksums.yaml +4 -4
  2. data/LICENSE +1 -1
  3. data/README.md +23 -65
  4. data/_includes/addons/analytics.liquid +4 -4
  5. data/_includes/addons/github.liquid +7 -10
  6. data/_includes/breadcrumbs.liquid +27 -0
  7. data/_includes/extend/list.liquid +2 -2
  8. data/_includes/{reset → extend}/tabs.liquid +0 -0
  9. data/_includes/extend/toctree.liquid +6 -5
  10. data/_includes/footer.liquid +36 -0
  11. data/_includes/reset/defaults.liquid +25 -60
  12. data/_includes/reset/workdir.liquid +1 -0
  13. data/_includes/safe/shortcodes.liquid +9 -0
  14. data/_includes/shortcodes/danger.liquid +3 -2
  15. data/_includes/shortcodes/note.liquid +3 -2
  16. data/_includes/shortcodes/tip.liquid +3 -2
  17. data/_includes/shortcodes/warning.liquid +3 -2
  18. data/_includes/{class/_toctree.liquid → toctree.liquid} +2 -2
  19. data/_layouts/default.liquid +182 -23
  20. data/_layouts/plugins/extension.liquid +6 -8
  21. data/_sass/@primer/base/base.scss +90 -0
  22. data/_sass/@primer/base/index.scss +6 -0
  23. data/_sass/@primer/base/kbd.scss +21 -0
  24. data/_sass/@primer/base/normalize.scss +423 -0
  25. data/_sass/@primer/base/typography-base.scss +100 -0
  26. data/_sass/@primer/breadcrumb/breadcrumb.scss +28 -0
  27. data/_sass/@primer/breadcrumb/index.scss +3 -0
  28. data/_sass/@primer/buttons/button-group.scss +91 -0
  29. data/_sass/@primer/buttons/button.scss +296 -0
  30. data/_sass/@primer/buttons/index.scss +4 -0
  31. data/_sass/@primer/buttons/misc.scss +205 -0
  32. data/_sass/@primer/forms/form-control.scss +278 -0
  33. data/_sass/@primer/forms/form-group.scss +279 -0
  34. data/_sass/@primer/forms/form-select.scss +38 -0
  35. data/_sass/@primer/forms/form-validation.scss +369 -0
  36. data/_sass/@primer/forms/index.scss +7 -0
  37. data/_sass/@primer/forms/input-group.scss +53 -0
  38. data/_sass/@primer/forms/radio-group.scss +43 -0
  39. data/_sass/@primer/markdown/blob-csv.scss +31 -0
  40. data/_sass/@primer/markdown/code.scss +73 -0
  41. data/_sass/@primer/markdown/headings.scss +72 -0
  42. data/_sass/@primer/markdown/images.scss +131 -0
  43. data/_sass/@primer/markdown/index.scss +8 -0
  44. data/_sass/@primer/markdown/lists.scss +76 -0
  45. data/_sass/@primer/markdown/markdown-body.scss +99 -0
  46. data/_sass/@primer/markdown/tables.scss +38 -0
  47. data/_sass/@primer/support/index.scss +11 -0
  48. data/_sass/@primer/support/mixins/buttons.scss +184 -0
  49. data/_sass/@primer/support/mixins/layout.scss +55 -0
  50. data/_sass/@primer/support/mixins/misc.scss +32 -0
  51. data/_sass/@primer/support/mixins/typography.scss +88 -0
  52. data/_sass/@primer/support/variables/color-system.scss +243 -0
  53. data/_sass/@primer/support/variables/colors.scss +55 -0
  54. data/_sass/@primer/support/variables/layout.scss +149 -0
  55. data/_sass/@primer/support/variables/misc.scss +42 -0
  56. data/_sass/@primer/support/variables/typography.scss +43 -0
  57. data/_sass/@primer/utilities/animations.scss +187 -0
  58. data/_sass/@primer/utilities/borders.scss +184 -0
  59. data/_sass/@primer/utilities/box-shadow.scss +25 -0
  60. data/_sass/@primer/utilities/colors.scss +185 -0
  61. data/_sass/@primer/utilities/details.scss +34 -0
  62. data/_sass/@primer/utilities/flexbox.scss +121 -0
  63. data/_sass/@primer/utilities/index.scss +14 -0
  64. data/_sass/@primer/utilities/layout.scss +134 -0
  65. data/_sass/@primer/utilities/margin.scss +68 -0
  66. data/_sass/@primer/utilities/padding.scss +59 -0
  67. data/_sass/@primer/utilities/typography.scss +325 -0
  68. data/_sass/@primer/utilities/visibility-display.scss +82 -0
  69. data/_sass/_font-face.scss +65 -0
  70. data/_sass/_icons.scss +53 -0
  71. data/_sass/_layout.scss +76 -0
  72. data/_sass/_reset.scss +21 -0
  73. data/_sass/_root.scss +9 -0
  74. data/_sass/_variables.scss +29 -0
  75. data/_sass/class/addons-wrap.scss +39 -0
  76. data/_sass/class/container.scss +11 -0
  77. data/_sass/class/content-wrap.scss +4 -0
  78. data/_sass/class/header.scss +10 -0
  79. data/_sass/{highlight.scss → class/highlight.scss} +0 -0
  80. data/_sass/class/markdown-body.scss +49 -0
  81. data/_sass/class/sidebar-wrap.scss +72 -0
  82. data/_sass/class/title.scss +13 -0
  83. data/_sass/theme.scss +26 -12
  84. data/assets/404.liquid +1 -3
  85. data/assets/css/theme.min.css +1 -4
  86. data/assets/css/theme.scss +4 -0
  87. data/assets/js/mermaid.min.js +6 -5
  88. data/assets/js/search.js +90 -0
  89. data/assets/js/theme.js +55 -121
  90. data/assets/js/theme.min.js +1 -1
  91. data/assets/search.liquid +9 -1
  92. metadata +74 -25
  93. data/_includes/assets/custom.js +0 -0
  94. data/_includes/assets/custom.scss +0 -0
  95. data/_includes/class/_breadcrumbs.liquid +0 -28
  96. data/_includes/class/_footer.liquid +0 -38
  97. data/_includes/class/rst-versions.liquid +0 -22
  98. data/_includes/class/wy-nav-content.liquid +0 -15
  99. data/_includes/class/wy-nav-side.liquid +0 -18
  100. data/_includes/class/wy-nav-top.liquid +0 -8
  101. data/_includes/extra/footer.html +0 -0
  102. data/_includes/extra/head.html +0 -0
  103. data/_includes/node/links.liquid +0 -24
  104. data/_includes/node/metadata.liquid +0 -21
  105. data/_includes/node/script.extension.liquid +0 -29
  106. data/_includes/node/script.liquid +0 -20
  107. data/_includes/node/script.schema.liquid +0 -27
  108. data/_includes/node/title.liquid +0 -1
  109. data/_includes/reset/i18n.liquid +0 -1
@@ -5,29 +5,188 @@ layout: plugins/compress
5
5
  {%- include reset/defaults.liquid -%}
6
6
 
7
7
  <!DOCTYPE html>
8
- <html class="writer-html5" lang="{{ lang }}">
9
- <head>
10
- {%- include node/metadata.liquid -%}
11
-
12
- {%- include node/title.liquid -%}
13
- {%- include node/links.liquid -%}
14
-
15
- {%- include node/script.schema.liquid -%}
16
-
17
- {%- include extra/head.html -%}
18
- </head>
19
- <body class="wy-body-for-nav">
20
- <div class="wy-grid-for-nav">
21
- {%- include class/wy-nav-side.liquid -%}
22
- <section data-toggle="wy-nav-shift" class="wy-nav-content-wrap">
23
- {%- include class/wy-nav-top.liquid -%}
24
- {%- include class/wy-nav-content.liquid -%}
25
- </section>
8
+ <html lang="{{ site.lang }}">
9
+
10
+ <head>
11
+ <meta charset="utf-8">
12
+ <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no">
13
+ <meta content="IE=Edge" http-equiv="X-UA-Compatible">
14
+ <title>{{ title | truncate: 110 }}</title>
15
+ <!-- meta -->
16
+ <meta name="description" content="{{ description }}">
17
+ <meta name="author" content="{{ site.github.owner_name }}">
18
+ <meta name="revised" content="{{ site.github.build_revision }}">
19
+ <meta name="generator" content="jekyll-rtd-theme v{{ version }}">
20
+ <!-- meta-ogp -->
21
+ {% comment %} https://ogp.me {% endcomment %}
22
+ <meta property="og:title" content="{{ title }}">
23
+ <meta property="og:description" content="{{ description }}">
24
+ <meta property="og:locale" content="{{ site.lang }}">
25
+ <meta property="og:url" content="{{ schema_surl }}">
26
+ <meta property="og:type" content="article">
27
+ <meta property="article:author" content="{{ site.github.owner_name }}">
28
+ <meta property="article:published_time" content="{{ schema_date }}">
29
+ <meta property="article:modified_time" content="{{ schema_modi }}">
30
+ <!-- meta-custom -->
31
+ {% for meta in site.meta -%}
32
+ <meta name="{{ meta.first }}" content="{{ meta.last }}">
33
+ {% endfor -%}
34
+ <!-- schema -->
35
+ <script type="application/ld+json">
36
+ {
37
+ "@context": "https://schema.org",
38
+ "@type": "Article",
39
+ "mainEntityOfPage": {
40
+ "@type": "WebPage",
41
+ "@id": "{{ schema_surl }}"
42
+ },
43
+ "headline": "{{ title | truncate: 110 }}",
44
+ "image": [{% for image in page.images %}"{{ image }}"{% unless forloop.last %},{% endunless %}{% endfor %}],
45
+ "author": {
46
+ "@type": "Person",
47
+ "name": "{{ site.github.owner_name }}"
48
+ },
49
+ "datePublished": "{{ schema_date }}",
50
+ "dateModified": "{{ schema_modi }}",
51
+ "publisher": {
52
+ "@type": "Organization",
53
+ "name": "RunDocs",
54
+ "logo": {
55
+ "@type": "ImageObject",
56
+ "url": "https://rundocs.io/logo.png"
57
+ }
58
+ },
59
+ "description": "{{ description }}"
60
+ }
61
+ </script>
62
+ <!-- link -->
63
+ <link rel="canonical" href="{{ schema_surl }}">
64
+ {% if prev %}<link rel="prev" href="{{ prev.url | absolute_url }}">{% endif %}
65
+ {% if next %}<link rel="next" href="{{ next.url | absolute_url }}">{% endif %}
66
+ <!-- theme -->
67
+ <link rel="stylesheet" href="{{ cdn }}/assets/css/theme{% if site.debug.dist != false %}.min{% endif %}.css">
68
+ <!-- icon -->
69
+ <link rel="icon" type="image/svg+xml" href="{{ site.baseurl }}/favicon.svg">
70
+ <!-- script -->
71
+ <script>
72
+ window.ui = {
73
+ baseurl: "{{ site.baseurl }}",
74
+ title: "{{ site.title }}",
75
+ admonition: {
76
+ note: "{{ __note }}",
77
+ tip: "{{ __tip }}",
78
+ warning: "{{ __warning }}",
79
+ danger: "{{ __danger }}"
80
+ },
81
+ lang: "{{ site.lang }}",
82
+ version: "{{ version }}"
83
+ };
84
+ </script>
85
+ <!-- script -->
86
+ <script src="{{ cdn }}/assets/js/jquery.min.js"></script>
87
+ <script src="{{ cdn }}/assets/js/theme{% if site.debug.dist != false %}.min{% endif %}.js"></script>
88
+
89
+ </head>
90
+
91
+ <body class="container">
92
+ <div class="sidebar-wrap overflow-hidden">
93
+ <div class="sidebar d-flex flex-column height-full overflow-y-scroll overflow-x-hidden">
94
+ <div class="header d-flex flex-column p-3 text-center">
95
+ <div class="title pb-1 no-underline">
96
+ <a class="h4 py-1 px-2 rounded-1" href="{{ site.baseurl }}/">
97
+ {% if site.logo %}
98
+ <img class="logo" src="{{ site.baseurl }}/{{ site.logo }}" alt="{{ site.title }}">
99
+ {% else %}
100
+ <i class="fa fa-home"></i> {{ site.title }}
101
+ {% endif %}
102
+ </a>
103
+ </div>
104
+ <span class="version text-gray">{{ site.github.latest_release.name }}</span>
105
+ <form class="search pt-2" action="{{ site.baseurl }}/search.html" method="get" autocomplete="off">
106
+ <input class="form-control input-block input-sm" type="text" name="q" placeholder="{{ site.data.translate.search_docs | default: 'Search docs' }}...">
107
+ </form>
108
+ </div>
109
+ <div class="toctree py-2" data-spy="affix" role="navigation" aria-label="main navigation">
110
+ {% include toctree.liquid %}
111
+ </div>
112
+ <div class="embed-wrap">
113
+ <div class="embed p-2 m-3 rounded-2 text-blue bg-white">
114
+ {{ site.embed }}
115
+ </div>
116
+ </div>
117
+ </div>
118
+ </div>
119
+ <div class="content-wrap">
120
+ <div class="header d-flex flex-justify-between p-2 hide-lg hide-xl" aria-label="top navigation">
121
+ <button id="toggle" class="btn-octicon p-2 m-0 text-white" type="button">
122
+ <i class="fa fa-bars"></i>
123
+ </button>
124
+ <div class="title flex-1 no-underline d-flex flex-justify-center">
125
+ <a class="h4 py-1 px-2 rounded-1" href="{{ site.baseurl }}/">{{ site.title }}</a>
126
+ </div>
127
+ </div>
128
+ <div class="content p-5">
129
+ {% include breadcrumbs.liquid %}
130
+ <hr>
131
+ <div role="main" itemscope="itemscope" itemtype="http://schema.org/Article">
132
+ <div class="markdown-body" itemprop="articleBody">
133
+ {{ content }}
134
+ </div>
135
+ </div>
136
+ {% include footer.liquid %}
26
137
  </div>
27
- {% include class/rst-versions.liquid %}
138
+ </div>
139
+ <div class="addons-wrap d-flex flex-column overflow-y-auto">
140
+ <div class="status d-flex flex-justify-between p-2">
141
+ <div class="title p-1">
142
+ <i class="fa fa-book"></i> {{ site.title }}
143
+ </div>
144
+ <div class="branch p-1">
145
+ <span class="name">
146
+ {{ site.github.source.branch }}
147
+ </span>
148
+ <i class="fa fa-caret-down"></i>
149
+ </div>
150
+ </div>
151
+ <div class="addons d-flex flex-column height-full p-2 d-none">
152
+ {%- assign items = "github, analytics" | split: ", " -%}
153
+ {% for item in items -%}
154
+ {% include addons/{{ item }}.liquid %}
155
+ {% endfor -%}
156
+ <hr>
157
+ <div class="generator f6 pb-2">
158
+ Built with
159
+ <a href="https://github.com/rundocs/jekyll-rtd-theme" target="_blank" title="{% if site.remote_theme %}remote{% endif %} theme v{{ version }}">jekyll-rtd-theme</a>
160
+ provided by
161
+ <a href="https://rundocs.io" target="_blank">RunDocs</a>
162
+ </div>
163
+ </div>
164
+ </div>
165
+
166
+ {%- comment %} mermaid {% endcomment -%}
167
+ {%- if content contains '<code class="language-mermaid">' -%}
168
+ {%- if site.mermaid.custom -%}
169
+ <script src="{{ site.mermaid.custom }}"></script>
170
+ {%- else -%}
171
+ <script src="{{ cdn }}/assets/js/mermaid.min.js"></script>
172
+ {%- endif %}
173
+ <script>
174
+ mermaid.initialize({% if site.mermaid.initialize %}{{ site.mermaid.initialize | jsonify }}{% else %}{}{% endif %});
175
+ </script>
176
+ {%- endif %}
177
+
178
+ {% comment %} Google Analytics {% endcomment %}
179
+ {%- if site.google.gtag -%}
180
+ <script async src="https://www.googletagmanager.com/gtag/js?id={{ site.google.gtag }}"></script>
181
+ <script>
182
+ window.dataLayer = window.dataLayer || [];
183
+ function gtag() {
184
+ dataLayer.push(arguments);
185
+ }
186
+ gtag("js", new Date());
187
+ gtag("config", "{{ site.google.gtag }}");
188
+ </script>
189
+ {%- endif -%}
190
+ </body>
28
191
 
29
- {%- include node/script.liquid -%}
30
- {%- include node/script.extension.liquid -%}
31
- {% include extra/footer.html %}
32
- </body>
33
192
  </html>
@@ -1,6 +1,4 @@
1
- {%- include reset/i18n.liquid -%}
2
-
3
- {%- assign shortcodes = "mermaid, warning, note, tip, danger" | split: ", " -%}
1
+ {%- include safe/shortcodes.liquid -%}
4
2
 
5
3
  {%- if site.debug.extension == false -%}
6
4
  {{ content }}
@@ -10,12 +8,12 @@
10
8
  {%- for content_block in content_blocks -%}
11
9
  {%- if content_block contains "</pre>" -%}
12
10
  {%- assign pre_blocks = content_block | split: "</pre>" -%}
13
- {%- if content_block contains ' class="language-' -%}
14
- {%- comment %} shortcodes: <pre class="language-**"> {% endcomment -%}
15
- {%- assign custom = content_block | replace_first: ' class="language-', "" | replace_first: '">', "<temp/>" | split: "<temp/>" -%}
11
+ {%- if content_block contains '><code class="language-' -%}
12
+ {%- comment %} shortcodes: <pre><code class="language-**"> {% endcomment -%}
13
+ {%- assign custom = content_block | replace_first: '><code class="language-', "" | replace_first: '">', "<temp/>" | split: "<temp/>" -%}
16
14
  {%- assign lang = custom.first -%}
17
- {%- assign codes = custom.last | split: "</pre>" | first -%}
18
- {%- assign others = custom.last | split: "</pre>" | last -%}
15
+ {%- assign codes = custom.last | split: "</code>" | first -%}
16
+ {%- assign others = custom.last | split: "</code>" | last -%}
19
17
  {%- if shortcodes contains lang -%}
20
18
  {%- include shortcodes/{{ lang }}.liquid -%} {{- others -}}
21
19
  {%- else -%}
@@ -0,0 +1,90 @@
1
+ // stylelint-disable selector-max-type
2
+ * {
3
+ box-sizing: border-box;
4
+ }
5
+
6
+ input,
7
+ select,
8
+ textarea,
9
+ button {
10
+ font-family: inherit;
11
+ font-size: inherit;
12
+ line-height: inherit;
13
+ }
14
+
15
+ body {
16
+ font-family: $body-font;
17
+ font-size: $body-font-size;
18
+ line-height: $body-line-height;
19
+ color: $text-gray-dark;
20
+ background-color: $bg-white;
21
+ }
22
+
23
+ a {
24
+ color: $text-blue;
25
+ text-decoration: none;
26
+
27
+ &:hover {
28
+ text-decoration: underline;
29
+ }
30
+ }
31
+
32
+ b,
33
+ strong {
34
+ font-weight: $font-weight-bold;
35
+ }
36
+
37
+ // Horizontal lines
38
+ //
39
+ // TODO-MDO: Remove `.rule` from everywhere and replace with `<hr>`s
40
+ hr,
41
+ .rule {
42
+ height: 0;
43
+ // stylelint-disable-next-line primer/spacing
44
+ margin: 15px 0;
45
+ overflow: hidden;
46
+ background: transparent;
47
+ border: 0;
48
+ // stylelint-disable-next-line primer/borders
49
+ border-bottom: $border-width $border-style lighten($gray-300, 5%);
50
+ @include clearfix();
51
+ }
52
+
53
+ //
54
+ // Remove most spacing between table cells.
55
+ //
56
+
57
+ table {
58
+ border-spacing: 0;
59
+ border-collapse: collapse;
60
+ }
61
+
62
+ td,
63
+ th {
64
+ padding: 0;
65
+ }
66
+
67
+ button {
68
+ cursor: pointer;
69
+ // Remove border radius added by Chrome macOS
70
+ border-radius: 0;
71
+ }
72
+
73
+ // increase the selector specificity for [hidden]
74
+ // so that it always overrides utility classes (.d-block, etc.)
75
+ [hidden][hidden] {
76
+ display: none !important;
77
+ }
78
+
79
+ details {
80
+ summary {
81
+ cursor: pointer;
82
+ }
83
+
84
+ &:not([open]) {
85
+ // Set details content hidden by default for browsers that don't do this
86
+ > *:not(summary) {
87
+ display: none !important;
88
+ }
89
+ }
90
+ }
@@ -0,0 +1,6 @@
1
+ @import "../support/index.scss";
2
+
3
+ @import "./normalize.scss";
4
+ @import "./base.scss";
5
+ @import "./kbd.scss";
6
+ @import "./typography-base.scss";
@@ -0,0 +1,21 @@
1
+ // Keyboard shortcuts
2
+ // stylelint-disable selector-max-type
3
+
4
+ kbd {
5
+ display: inline-block;
6
+ // stylelint-disable-next-line primer/spacing
7
+ padding: ($spacer-1 - 1) ($spacer-1 + 1);
8
+ font: 11px $mono-font;
9
+ // stylelint-disable-next-line primer/typography
10
+ line-height: 10px;
11
+ // stylelint-disable-next-line primer/colors
12
+ color: $gray-700;
13
+ vertical-align: middle;
14
+ background-color: $bg-gray-light;
15
+ // stylelint-disable-next-line primer/borders
16
+ border: $border-style $border-width $border-gray-dark;
17
+ border-bottom-color: $border-gray-dark;
18
+ border-radius: $border-radius;
19
+ // stylelint-disable-next-line primer/box-shadow
20
+ box-shadow: inset 0 -1px 0 $border-gray-dark;
21
+ }