change navBar to use slice