docs icon indicating copy to clipboard operation
docs copied to clipboard

Adding `previous` and `next` links for moving between articles

Open zeke opened this issue 7 years ago • 9 comments

In https://github.com/github/help-docs/pull/11410 we introduced breadcrumbs. Under the hood, the breadcrumbs are generated by a currentTree object that captures the entire hierarchy of the site, relative to the page you're currently viewing. We can use this new tree to infer what pages precede and follow a given article.

Let's consider adding [Previous] and [Next] links below each article, where appropriate. We'll have to iron out the details of when these links should and should NOT be displayed:

  • should these links be displayed for articles that don't have a parent map topic?
  • does an article at the end of a map topic link to the next map topic?
  • does an article at the beginning of a map topic link to the previous map topic?
  • does an article at the end of the last map topic have a [next] link?
  • etc

cc @github/product-docs-engineering @github/product-docs-content-strategy

zeke avatar Nov 12 '19 17:11 zeke

Let's consider adding [Previous] and [Next] links below each article, where appropriate.

🙌 ⚡️

should these links be displayed for articles that don't have a parent map topic?

👍 Yes, I think so! Some categories don't have map topics and the previous and next buttons would still be useful as we still display the content in a somewhat linear order.

The only category without map topics where the buttons might not make as much sense is probably in the "Site policy" category, although I don't think it will hurt anything to have them displayed there.

does an article at the end of a map topic link to the next map topic? does an article at the beginning of a map topic link to the previous map topic?

Great questions - I think so! 👍

does an article at the end of the last map topic have a [next] link?

In this case, I think not, since the next link would go to the next category and those aren't as closely linked as map topics within a category. Also, the next category will be shown in the sidebar.

emilyistoofunky avatar Nov 12 '19 17:11 emilyistoofunky

This issue is stale because it has been open 60 days with no activity. Comment with a status update or this will be closed in 14 days

github-actions[bot] avatar Jul 25 '20 00:07 github-actions[bot]

Still relevant.

zeke avatar Jul 25 '20 16:07 zeke

@sezhan1229 Can you help us out with a design for this? We'll need to have that ready when we begin implementation on this.

jwargo avatar Jul 28 '20 13:07 jwargo

This issue is stale because it has been open 60 days with no activity.

github-actions[bot] avatar Dec 06 '20 16:12 github-actions[bot]

This issue is stale because it has been open 60 days with no activity.

github-actions[bot] avatar Feb 06 '21 17:02 github-actions[bot]

@chiedo @emilyistoofunky Is this still relevant or should we close it out?

janiceilene avatar Feb 08 '21 20:02 janiceilene

I think this may be part of the learning track designs - @chiedo do you know?

emilyistoofunky avatar Feb 08 '21 21:02 emilyistoofunky

Yeah we can close this one out! We've got it tracked elsewhere.

chiedo avatar Feb 08 '21 21:02 chiedo