bitpay / bitcore.io

Moved to https://github.com/bitpay/bitcore-website
13 stars 30 forks source link

Next Button #5

Open braydonf opened 9 years ago

braydonf commented 9 years ago

The next button isn't navigating to the next page in the menu

chejazi commented 9 years ago

I was going to fix this myself, but I don't know how to test changes for a repo like this. Fixing Prev/Next would require several changes.

The first would be in bitcore.io/scripts/helpers.js, to fix the regex for the current path in the documentation:

path = this.path.replace(/^guide\//, '')

Currently guide is docs which not part of the path.

The second would be to update the doc sidebar yaml (bitcore.io/themes/bitcore/_config.yml) to use lists:

doc_sidebar:
  Home:
    - Get Started: index.html
    - Contributing: contributing.html

The process of determining what page we're currently on (in bitcore.io/scripts/helpers.js) would need to be updated around this data structure change. But then, when you match the page you can properly increment/decrement the matched index for the proper "Prev" and "Next" page links (assuming they exist).