gallery center js fix