make sidebar as directive