auto resize imgages and toggle folders on click.