Commit Graph
76 Commits
Author SHA1 Message Date
PLanCompS 4fc59a578f Separate sorting of numbers and strings for navigation order
The values of `title` and `nav_order` can be numbers or strings.
Jekyll gives build failures when sorting on mixtures of different types,
so numbers and strings need to be sorted separately.

Here, numbers are sorted by their values, and come before all strings.
An omitted `nav_order` value is equivalent to the page's `title` value
(except that a numerical `title` value is treated as a string).

The case-sensitivity of string sorting is determined by `site.nav_sort`.
2020-08-11 18:25:58 +02:00
PLanCompS 83ec553348 Ensure pages with nav_exclude are ignored by navigation
Pages with `nav_exclude: true` were included when sorting on `title` or `nav_order`. That could cause build failures when the type of value of the field differs from that on other pages, as reported in https://github.com/pmarsceill/just-the-docs/issues/406.

Pages with `nav_exclude: true` or no `title` are never displayed in the navigation, so removing them from `pages_list` cannot break existing sites. This change also allows the removal of some tests in the code. (The indentation of the code should now be adjusted, but that has been deferred, to restrict the size of the diff for review.)

For testing, the title of `404.html` has been changed to the number `404`,  the page `docs/untitled-test.md`  has been added, and `nav_sort_order` has been set to `case_sensitive`. Those updates give build failures with the current version of `_includes/nav.html`, but not after the suggested changes.

It will still be possible for build failures to occur due to sorting fields of *non-excluded* pages with differing types of values (e.g., `nav_order`a mixture of numbers and strings). To make the code completely safe will require relatively complicated changes,.
2020-08-10 15:58:42 +02:00
Silvio Giebl 3f0b7254a2 Update _config.yml with default values 2020-06-25 23:19:24 +02:00
Silvio Giebl 1cf7d5aba9 Restored search.rake 2020-06-18 22:39:58 +02:00
Silvio Giebl 51f15965f2 Merge branch 'feature/search-sections' into improvement/navigation-new
# Conflicts:
#	_includes/nav.html
#	_layouts/default.html
#	assets/js/search-data.json
#	docs/configuration.md
#	lib/tasks/search.rake
2020-06-15 22:06:16 +02:00
Patrick Marsceill f664d410d7 Add back to top link and format footer 2020-05-01 17:31:44 -04:00
Matt WangandGitHub 6d487845a4 Merge branch 'v0.2.9' into aux-links-new-tab 2020-04-27 13:00:42 -07:00
Patrick MarsceillandGitHub 70c36d8aad Update _config.yml 2020-04-27 13:14:42 -04:00
Patrick MarsceillandGitHub 6066d22c82 Update _config.yml 2020-04-27 12:52:07 -04:00
Patrick MarsceillandGitHub 176ffc8e60 Update _config.yml 2020-04-27 12:51:48 -04:00
Patrick MarsceillandGitHub fad434bc74 Merge branch 'v0.2.9' into default-nav-order 2020-04-27 11:05:46 -04:00
PLanCompS c46ccd3484 Made case-insenstive sorting the default
Added a configuration option to determine whether the sort order is case-sensitive.
The default is case-insensitive.

To test:
- open `/just-the-docs/docs/utilities/` in the browser,
  and check that the navigation links in `Utilities` are sorted alphabetically;
- in `docs/utilities/layout.md', change the preamble to `title: layout`,
  and check that the  links in `Utilities` are still sorted alphabetically;
- add `nav_sort: case_sensitive` in the configuration file,
  and check that the link to `layout` is now listed last under `Utilities`.
2020-04-25 14:53:45 +02:00
Patrick MarsceillandGitHub 37fe8ca412 Update _config.yml 2020-04-24 15:52:19 -04:00
Patrick Marsceill 59d4802ce3 Merge branch 'improvement/custom-themes' of git://github.com/SgtSilvio/just-the-docs into SgtSilvio-improvement/custom-themes 2020-04-24 15:39:44 -04:00
Patrick MarsceillandGitHub 0716ea77d6 Merge pull request #250 from Labs64/pr-anonymize_ip
Enable IP anonymization in Google Analytics (GDPR)
2020-04-24 14:47:21 -04:00
c06eae8fa3 Update _config.yml
Co-Authored-By: Patrick Marsceill <pmarsceill@users.noreply.github.com>
2020-04-24 19:44:42 +02:00
Patrick MarsceillandGitHub 0507f77f4e Update _config.yml 2020-04-23 22:43:27 -04:00
Patrick MarsceillandGitHub 3b2a55fd10 Update _config.yml 2020-04-23 22:42:59 -04:00
Patrick MarsceillandGitHub 5d3b88a1e1 Update _config.yml 2020-04-23 22:38:45 -04:00
Patrick MarsceillandGitHub 17153f001f Update _config.yml 2020-04-23 22:32:46 -04:00
Silvio Giebl f5e6573e16 Removed unnecessary rake command and files
Improved search documentation
2020-03-25 00:23:17 +01:00
Matthew Wang 9b86e292fa implements requested branch and edit mode configs 2020-01-12 13:47:05 -08:00
Silvio Giebl f1c306c814 Multi search match highlight
Added multiple previews, configurable by site.search.previews
Improved search-data.json
2020-01-02 11:55:38 +01:00
Silvio Giebl 82b3f15443 Added search.button configuration
Improved documentation for search configurations
2019-12-29 21:30:44 +01:00
Silvio Giebl 2ef0029068 Add documentation for search configurations 2019-12-29 21:08:15 +01:00
Silvio Giebl ff30552748 Moved config search_tokenizer_separator -> search.tokenizer_separator 2019-12-29 20:08:34 +01:00
Silvio Giebl 7f5b1f14f1 Search for sections (configurable via search.heading_level)
Added more search configurations
Display "no results found"
2019-12-29 19:19:00 +01:00
Silvio Giebl bb0e5222ca Merge branch 'master2' into improvement-custom-themes-merged 2019-11-26 23:27:33 +01:00
Matthew Wang 2c94928917 oops, adds edit_link_text to layout 2019-11-13 23:06:23 -08:00
Alexey AverikhinandKonstantin 25331a5ffa Enable IP anonymization in Google Analytics (GDPR)
- Introduced "ga_tracking_anonymize_ip" parameter to enable/disable Google Analytics IP anonymization (to comply with GDPR).

(cherry picked from commit ce530f36fa0549c78ffe53ea6077f44f6f0b330f) (+1 squashed commit)
Squashed commits:
[69b7718] - enable GA anonymize_ip

(cherry picked from commit f2b67c632af72b61dd634b9a337200781519691e)
2019-11-12 10:27:01 +01:00
Matthew Wang 5549a15df9 adds option to make aux links open in new tab 2019-10-01 22:22:34 -07:00
Matthew WangandGitHub e917ea1f10 Merge branch 'master' into master 2019-09-11 15:40:51 -07:00
Matthew Wang 97efc81fa9 implements configuration for footer data and "edit this page" functionality 2019-09-11 15:31:47 -07:00
Patrick MarsceillandGitHub b44ebe6cb3 Merge branch 'v0.2.7-release' into mathjax 2019-09-09 16:30:59 -04:00
Patrick MarsceillandGitHub 423b8c9f46 Update _config.yml 2019-09-09 16:29:51 -04:00
Peter Mosses a7285b9e30 Replace blank_lines by blanklines. 2019-09-09 22:26:32 +02:00
Peter Mosses 119a0b241e Revert "Mathjax support added"
This reverts commit 7220197a1f.
2019-09-09 22:22:22 +02:00
Patrick MarsceillandGitHub 850a8fe256 Merge pull request #203 from pdmosses/search-config
Search config
2019-09-09 16:00:11 -04:00
Peter Mosses 7220197a1f Mathjax support added
Mathjax config options added.
`compress_html` config option changed,
Mathjax script loaded by head when `page.mathjax` is truthy.
Documentation and test page added.
See also issue #198.
2019-08-31 23:19:03 +02:00
Peter Mosses 4e65041849 Revert "Add configuration option search_tokenizer_separator"
This reverts commit 50cdf076b4.
2019-08-31 16:52:41 +02:00
Peter Mosses 50cdf076b4 Add configuration option search_tokenizer_separator
The default is for hyphens to separate tokens in search terms: `gem-based` is equivalent to `gem based`.

This adds `search_tokenizer_separator` as a site configuation option, to support search for hyphenated words.
2019-08-29 15:36:13 +02:00
Peter Mosses 5b74b44230 Revert "Optional delay of grandchildren link display"
This reverts commit 8ac545a5eb.
2019-08-29 14:42:23 +02:00
Peter Mosses 5e72b7db67 Revert "Revert "Optional delay of grandchildren link display""
This reverts commit 89f79138c3.
2019-08-29 14:41:09 +02:00
Peter Mosses 89f79138c3 Revert "Optional delay of grandchildren link display"
This reverts commit 8ac545a5eb.
2019-08-22 21:37:11 +02:00
Peter Mosses 8ac545a5eb Optional delay of grandchildren link display
The current default is that when a grandparent is selected, the links to its
children *and all its grandchildren* are displayed in the navigation menu.
Setting `grandchildren_branch: true` in `_config.yml` delays the display of links
to grandchildren until their parent is selected.
2019-08-21 13:49:07 +02:00
Silvio Giebl 91760ee8c9 Added documentation for logo variable 2019-08-17 14:46:28 +02:00
Silvio Giebl 132cecfea3 Added logo variable to _config.yml which can be set to a path/url
Automatically replaces the title with a logo
2019-08-17 14:32:25 +02:00
Silvio Giebl cba53a6914 Make themes more customizable
(cherry picked from commit dffb2706a158784e2f3091f895a868e373683bc8)
2019-08-15 18:35:10 +02:00
Patrick MarsceillandGitHub 2b3da2f75c Update _config.yml 2019-08-14 14:31:50 -04:00
Patrick MarsceillandGitHub 5ad439b53c Merge branch 'v0.2.6-release' into improve-search 2019-08-14 11:03:30 -04:00