Attempt at improved sidebar. Currently suffering from an issue with recursive sidebars