fix loading bar directive