nesta icon indicating copy to clipboard operation
nesta copied to clipboard

Override text to use in the menu

Open gma opened this issue 14 years ago • 4 comments

When you construct a menu you specify the paths to pages in your site, and Nesta will use the headings on those pages as link text when building the menu. Sometimes it makes sense to override the text used for a menu item; allow link text to be optionally specified in menu.txt after a menu item's path. The link will be separated from the path by whitespace.

gma avatar Aug 25 '11 22:08 gma

I can take this, if you want.

I made a new project with Nesta 0.9.13, and saw that a "Link text" metadata was added to the content-demo index page. As far as I can tell, it doesn't do anything. I was going to implement "text to use on the menu" using that, but I like the idea of using menu.txt more.

chadoh avatar Jun 16 '12 21:06 chadoh

Thanks for the offer – much appreciated. If you fancy having a crack at it I think the message at the top of this bug report covers the implementation I was planning to explore. It would look something like this:

- / Home
- path/to/page Some page
  - another/page Another page with a really long link

The content-demo is a separate repository that isn't branched. If you install Nesta from master on GitHub [1] you'll be able to use the Link text metadata to control the menu links. I need to get 0.10.0 out; it's becoming a bit embarrassing, but I really need to move quickly on my startup right now so almost all my time is spent on that. A PR for this feature would be very welcome, but wouldn't be merged until I get a free afternoon to work on releasing 0.10.0.

[1] http://nestacms.com/docs/recipes/running-the-latest-code

gma avatar Jun 16 '12 21:06 gma

Ah, perfect, master does just what I want. So... I'm not gonna bother modifying the behavior of menu.txt! Sorry for the false hope.

chadoh avatar Jun 16 '12 21:06 chadoh

No problem! Link text has certainly reduced the priority of this one for me…

gma avatar Jun 16 '12 23:06 gma

Given that nobody has missed this enough to comment for over a decade (myself included), I'm closing it!

gma avatar Mar 14 '23 09:03 gma