fixed gallery nav issue