diff --git a/404.html b/404.html index 5fde96683254..a2d250a53cf9 100644 --- a/404.html +++ b/404.html @@ -8,4 +8,4 @@
The page you requested could not be found. Try using the navigation {% if site.search_enabled != false %}or search {% endif %}to find what you're looking for or go to this site's home page.
+The page you requested could not be found. Try using the navigation {% if site.search_enabled != false %}or search {% endif %}to find what you're looking for or go to this site's home page.
diff --git a/_config.yml b/_config.yml index dbe742f2f739..e5908211459f 100644 --- a/_config.yml +++ b/_config.yml @@ -19,15 +19,7 @@ baseurl: "/just-the-docs" # the subpath of your site, e.g. /blog url: "https://just-the-docs.github.io" # the base hostname & protocol for your site, e.g. http://example.com permalink: pretty -exclude: ["node_modules/", "*.gemspec", "*.gem", "Gemfile", "Gemfile.lock", "package.json", "package-lock.json", "script/", "LICENSE.txt", "lib/", "bin/", "README.md", "Rakefile" -, "docs/tests/" -] - -# Regression tests -# By default, the pages in /docs/tests are excluded when the ste is built. -# To include them, comment-out the relevant line above. -# Uncommenting the following line doesn't work - see https://github.com/jekyll/jekyll/issues/4791 -# include: ["docs/tests/"] +exclude: ["node_modules/", "*.gemspec", "*.gem", "Gemfile", "Gemfile.lock", "package.json", "package-lock.json", "script/", "LICENSE.txt", "lib/", "bin/", "README.md", "Rakefile"] # Set a path/url to a logo that will be displayed instead of the title #logo: "/assets/images/just-the-docs.png" diff --git a/_includes/css/callouts.scss.liquid b/_includes/css/callouts.scss.liquid new file mode 100644 index 000000000000..e99600e51b3d --- /dev/null +++ b/_includes/css/callouts.scss.liquid @@ -0,0 +1,93 @@ +{%- comment -%} + {% include css/callouts.scss.liquid color_scheme = string %} + produces SCSS for all the callouts in site.callouts. For the "dark" + color scheme, the levels of the text and background colors are reversed. +{%- endcomment -%} + +{%- assign callout_background_hue = "000" -%} +{%- assign callout_color_hue = "300" -%} +{%- if site.callouts_level == "loud" or include.color_scheme == "dark" and site.callouts_level != "quiet" -%} + {%- assign callout_background_hue = "300" -%} + {%- assign callout_color_hue = "000" -%} +{%- endif -%} + +div.opaque { + background-color: $body-background-color; +} + +{%- for callout in site.callouts %} + +{%- assign callout_opacity = callout[1].opacity | default: site.callouts_opacity | default: 0.2 -%} + +p.{{ callout[0] }}, blockquote.{{ callout[0] }} { + background: rgba(${{ callout[1].color }}-{{ callout_background_hue }}, {{ callout_opacity }}); + border-left: $border-radius solid ${{ callout[1].color }}-{{ callout_color_hue }}; + border-radius: $border-radius; + box-shadow: 0 1px 2px rgba(0, 0, 0, 0.12), 0 3px 10px rgba(0, 0, 0, 0.08); + padding: .8rem; + {% if callout[1].title %} + &::before { + color: ${{ callout[1].color }}-{{ callout_color_hue }}; + content: "{{ callout[1].title }}"; + display: block; + font-weight: bold; + text-transform: uppercase; + font-size: .75em; + padding-bottom: .125rem; + } + {% endif %} + > .{{ callout[0] }}-title { + color: ${{ callout[1].color }}-{{ callout_color_hue }}; + display: block; + font-weight: bold; + text-transform: uppercase; + font-size: .75em; + padding-bottom: .125rem; + } +} + +p.{{ callout[0] }}-title, blockquote.{{ callout[0] }}-title { + background: rgba(${{ callout[1].color }}-{{ callout_background_hue }}, {{ callout_opacity }}); + border-left: $border-radius solid ${{ callout[1].color }}-{{ callout_color_hue }}; + border-radius: $border-radius; + box-shadow: 0 1px 2px rgba(0, 0, 0, 0.12), 0 3px 10px rgba(0, 0, 0, 0.08); + padding: .8rem; + > p:first-child { + margin-top: 0; + margin-bottom: 0; + color: ${{ callout[1].color }}-{{ callout_color_hue }}; + display: block; + font-weight: bold; + text-transform: uppercase; + font-size: .75em; + padding-bottom: .125rem; + } +} + +blockquote.{{ callout[0] }} { + margin-left: 0; + margin-right: 0; + + > p:first-child { + margin-top: 0; + } + + > p:last-child { + margin-bottom: 0; + } +} + +blockquote.{{ callout[0] }}-title { + margin-left: 0; + margin-right: 0; + + > p:nth-child(2) { + margin-top: 0; + } + + > p:last-child { + margin-bottom: 0; + } +} + +{% endfor -%} diff --git a/_includes/css/just-the-docs.scss.liquid b/_includes/css/just-the-docs.scss.liquid index 495cd6dd902a..29d569026244 100644 --- a/_includes/css/just-the-docs.scss.liquid +++ b/_includes/css/just-the-docs.scss.liquid @@ -1,7 +1,8 @@ {% if site.logo %} -$logo: "{{ site.logo | absolute_url }}"; +$logo: "{{ site.logo | relative_url }}"; {% endif %} @import "./support/support"; @import "./color_schemes/{{ include.color_scheme }}"; @import "./modules"; {% include css/custom.scss.liquid %} +{% include css/callouts.scss.liquid color_scheme = include.color_scheme %} diff --git a/_includes/nav.html b/_includes/nav.html index 325a68c88404..accfd891688e 100644 --- a/_includes/nav.html +++ b/_includes/nav.html @@ -60,11 +60,11 @@ {%- for node in pages_list -%} {%- if node.parent == nil -%} {%- unless node.nav_exclude -%} -