diff --git a/404.html b/404.html index 56efce4..1e7a37e 100644 --- a/404.html +++ b/404.html @@ -8,4 +8,4 @@ search_exclude: true
The page you requested could not be found. Try using the navigation {% if site.search_enabled %}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/Rakefile b/Rakefile deleted file mode 100644 index b8b42c4..0000000 --- a/Rakefile +++ /dev/null @@ -1 +0,0 @@ -Dir.glob('lib/tasks/*.rake').each {|r| import r} diff --git a/_config.yml b/_config.yml index 42ccec2..054d926 100644 --- a/_config.yml +++ b/_config.yml @@ -19,16 +19,37 @@ baseurl: "/just-the-docs" # the subpath of your site, e.g. /blog url: "https://pmarsceill.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"] +exclude: ["node_modules/", "*.gemspec", "*.gem", "Gemfile", "Gemfile.lock", "package.json", "package-lock.json", "script/", "LICENSE.txt", "README.md"] # Set a path/url to a logo that will be displayed instead of the title #logo: "/assets/images/just-the-docs.png" # Enable or disable the site search +# Supports true (default) or false search_enabled: true - -# Set the search token separator for hyphenated-word search: -search_tokenizer_separator: /[\s/]+/ +search: + # Split pages into sections that can be searched individually + # Supports 1 - 6, default: 2 + heading_level: 2 + # Maximum amount of previews per search result + # Default: 3 + previews: 3 + # Maximum amount of words to display before a matched word in the preview + # Default: 5 + preview_words_before: 5 + # Maximum amount of words to display after a matched word in the preview + # Default: 10 + preview_words_after: 10 + # Set the search token separator + # Default: /[\s\-/]+/ + # Example: enable support for hyphenated search words + tokenizer_separator: /[\s/]+/ + # Display the relative url in search results + # Supports true (default) or false + rel_url: false + # Enable or disable the search button + # Supports true or false (default) + button: true # Enable or disable heading anchors heading_anchors: true diff --git a/_includes/nav.html b/_includes/nav.html index 603d8d3..f2ec7e5 100644 --- a/_includes/nav.html +++ b/_includes/nav.html @@ -17,7 +17,7 @@ {%- assign first_level_url = node.url | absolute_url -%} {%- endif -%} {%- if node.has_children -%} - + {%- endif -%} {{ node.title }} {%- if node.has_children -%} @@ -30,7 +30,7 @@ {%- assign second_level_url = child.url | absolute_url -%} {%- endif -%} {%- if child.has_children -%} - + {%- endif -%} {{ child.title }} {%- if child.has_children -%} diff --git a/_layouts/default.html b/_layouts/default.html index 69e253c..860efe6 100644 --- a/_layouts/default.html +++ b/_layouts/default.html @@ -8,29 +8,33 @@ layout: table_wrappers {% include head.html %} + + {% if site.search_enabled != false %} + {% if site.search.button %} + + + + {% endif %} + + + {% endif %} - - {% if site.search_enabled != false %} - - - - {% endif %} -