Skip to content

add 'shortTitle' as a top matter option to enable shorter links in the sidebar for long titles #21

@smagdali

Description

@smagdali

It would be good to be able to sometimes use a shorter text in the sidebar title from the main title - especially as the title: becomes the H1

As an example, imagine the following in your top matter:

title: "Frequently Asked Questions about the Filecoin Virtual Machine"
shortTitle: "FAQs"

should give you a nice long title and H1 for the page, but a sidebar link that's completely clear from the context but much more manageable. Helps readability and discoverability.

We do this by (copy/paste from discussion with @johnnymatthews ):

Add conditionals to the following to enable a different sidebar menu linktext, from the main title:

https://github.com/filecoin-project/filecoin-docs/blob/main/layouts/_default/list.html

https://github.com/filecoin-project/filecoin-docs/blob/main/layouts/partials/sidebar/auto-default-menu.html

Metadata

Metadata

Assignees

No one assigned

    Labels

    P2Medium: Good to have, but can wait until someone steps updif/mediumPrior experience is likely helpfuleffort/hoursEstimated to take one or several hours

    Type

    No type

    Projects

    Status

    📋 Backlog

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions