Moved toggles to a new class and added toggling of the hierarchy.