You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hello, I'm not sure about this, but I think I've found a slight misalignment with the Hugo spec. So Hugo's front matter documentation says:
linkTitle: used for creating links to content; if set, Hugo defaults to using the linktitle before the title. Hugo can also order lists of content by linktitle.
However, linkTitle currently seems to be ignored in this theme's file tree menu and other spots. I think having this would be nice; the title on the page itself can be very long, whereas a long title looks kind of crazy in the file tree menu.
I believe the fix is to:
Create a new partial specifically for cases where a title is meant as a link, e.g.: docs/linktitle.html
This partial would look exactly the same as docs/title.html except with an extra if case:
{{ if .LinkTitle }}
{{ $title = .LinkTitle }}
{{ else if .Title }}
{{ $title = .Title }}
...
Go through each call to docs/title.html and repoint it to the new partial if the title is being used in a link.
Does this seem like a reasonable solution to you? If so, I'd be happy to submit a pull request (I am not very familiar with open source, so I thought it best to raise this issue before doing so). Thanks - this is a really great theme, by the way!
The text was updated successfully, but these errors were encountered:
Hello, I'm not sure about this, but I think I've found a slight misalignment with the Hugo spec. So Hugo's front matter documentation says:
However,
linkTitle
currently seems to be ignored in this theme's file tree menu and other spots. I think having this would be nice; the title on the page itself can be very long, whereas a long title looks kind of crazy in the file tree menu.I believe the fix is to:
docs/linktitle.html
docs/title.html
except with an extra if case:docs/title.html
and repoint it to the new partial if the title is being used in a link.Does this seem like a reasonable solution to you? If so, I'd be happy to submit a pull request (I am not very familiar with open source, so I thought it best to raise this issue before doing so). Thanks - this is a really great theme, by the way!
The text was updated successfully, but these errors were encountered: