Extension talk:CategoryMembersOnSidebar

Is there any reason the top level can't also be linked? So if I have CATEGORY:Foo|Foo , I get a heading "Foo" with a link to "bar" underneath (if "Bar" is a page having category "Foo"). I would like, though, to also be able to click the header "Foo" to get to the page Category:Foo

Any ideas on how to do this? I'm new to mw, and didn't see in the php how this could be done.

Thanks!

Also would be interested in advice for expanding this to multi-levels.