Though the candidates and local issues played a role in the results, voter attitudes about Trump were central to their choices.