Added links to the node page from the facts_table if show_nodes is True. Added links to the facts page from the facts_table if show_nodes is False. Added logic to switch TH table from facts to nodes if show_nodes is True.
This is all the code after a week and a bit hacking on this project. It's in a rather experimental state but should work with a little effort.