Refactore sidebar category browser to use dynamically-generated links with an active state