Edgewall Software

Opened 12 years ago

Last modified 2 months ago

#6724 new defect

Redirecting mainnav buttons to wiki page breaks "active" highlight

Reported by: rsm@… Owned by:
Priority: normal Milestone: next-stable-1.4.x
Component: general Version: 0.11b1
Severity: normal Keywords: navigation
Cc: Branch:
Release Notes:
API Changes:
Internal Changes:


I've modified some of my Mainnav buttons as per the TracInterfaceCustomization page. Both my Timeline and Roadmap button now link to a wikipage. When I use these buttons the Wiki button is highlighted instead of the Timeline or Roadmap button.

I use IE 7.0 and can't test other browsers as this is a work pc.
Following is the trac.ini change I made for the mainnav:

#added for custom menu
wiki.label = Home
timeline.label = Documentation
timeline.href = /wiki/Documentation
roadmap.label = Community
roadmap.href = /wiki/Community

Attachments (0)

Change History (6)

comment:1 by Christian Boos, 12 years ago

Component: wikigeneral
Keywords: navigation added
Owner: changed from Christian Boos to Jonas Borgström

This is of course not a browser-specific issue, rather a current limitation of the feature: when redirecting to a wiki page, it's effectively the wiki module which will handle the page and therefore it's the Wiki tab which will get highlighted.

Ideas for a fix welcomed.

comment:2 by rsm@…, 12 years ago

I would suggest making it clear somewhere that the buttons represent modules as oppposed to pages (maybe this is already explained somewhere, but my rtfm session didn't result in any mention of this). I suppose if I changed the label back from home to wiki, the active marker would at least make sense.

Perhaps something similar to how TocMacro works could be implemented? I don't really know anything about the way Trac is structured so I do not think I can suggest anything more substantial.

comment:3 by Ryan J Ollos, 6 years ago

Milestone: next-minor-0.12.xnext-stable-1.0.x

Moving this forward since I don't think it needs to be fixed on 0.12-stable, but please comment if you feel differently.

There is a PoC in log:rjollos.git:t6724. If the navigation item has an href property, a request to any path that starts with href will result in the navigation item highlighted. If we need to be more precise, we could have an active_href attribute that support regexes, but I think this is good enough to cover most cases.

comment:4 by Ryan J Ollos, 5 years ago

Owner: Jonas Borgström removed

comment:5 by Ryan J Ollos, 4 years ago

Milestone: next-stable-1.0.xnext-stable-1.2.x

Moved ticket assigned to next-stable-1.0.x since maintenance of 1.0.x is coming to a close. Please move the ticket back if it's critical to fix on 1.0.x.

comment:6 by Ryan J Ollos, 2 months ago

Milestone: next-stable-1.2.xnext-stable-1.4.x

Modify Ticket

Change Properties
Set your email in Preferences
as new The ticket will remain with no owner.
The ticket will be disowned.
as The resolution will be set. Next status will be 'closed'.
The owner will be changed from (none) to anonymous. Next status will be 'assigned'.

Add Comment

E-mail address and name can be saved in the Preferences .
Note: See TracTickets for help on using tickets.