scripts for leaves frontend