diff --git a/README.md b/README.md index f4b69ba6..10a8e210 100644 --- a/README.md +++ b/README.md @@ -99,6 +99,16 @@ vale :exclamation: make sure you are using Vale 2.16.0 or greater +#### Custom Prev/Next + +To configure a page to have a different prev or next link, +add the appropriate metadata to the top of the file: + +`:prev_link: .html` +`:prev_title: < title of link, can be anything>` + +For "next" use `next_link` and `next_title`. + #### Screenshots and Diagrams Visual assets can be found in `source/_static`. diff --git a/source/_templates/prev-next.html b/source/_templates/prev-next.html index a0ed0720..f3ea88ad 100644 --- a/source/_templates/prev-next.html +++ b/source/_templates/prev-next.html @@ -1,13 +1,26 @@ -{%- if (show_prev_next == 'true') and (next or prev) %} - {#- Translators: This is an ARIA section label for the footer section of the page. -#} - -{%- endif %} - -
+{# Modified version of PyData's prev-next, checks page metadata for custom links first #} +{# Displays links to the previous and next page in the TOCtree order. #} + diff --git a/source/conf.py b/source/conf.py index 605df178..766282fe 100644 --- a/source/conf.py +++ b/source/conf.py @@ -276,6 +276,7 @@ 'navbar_persistent': [], 'navbar_end': ['version-switcher', 'theme-switcher', 'navbar-icon-links'], 'secondary_sidebar_items': ['page-toc', 'book-demo'], + 'show_prev_next': False, # turn off default theme 'article_footer_items': ['prev-next'], 'content_footer_items': [], 'footer_start':['copyright'], diff --git a/source/getting-started/fioup-registration/index.rst b/source/getting-started/fioup-registration/index.rst index 93a91ccc..f17d1cf6 100644 --- a/source/getting-started/fioup-registration/index.rst +++ b/source/getting-started/fioup-registration/index.rst @@ -1,3 +1,7 @@ +:next_link: ../install-fioctl/index.html + +:next_title: Installing Fioctl + Registering Your Device with Fioup ================================== diff --git a/source/getting-started/install-fioctl/index.rst b/source/getting-started/install-fioctl/index.rst index e8b49e4f..dc0ad95e 100644 --- a/source/getting-started/install-fioctl/index.rst +++ b/source/getting-started/install-fioctl/index.rst @@ -1,3 +1,7 @@ +:prev_link: ../index.html + +:prev_title: Getting Started + .. _gs-install-fioctl: Installing Fioctl