Connect the new ballast black and white wires where the old ballast wires are connected.
Those are common type linear fluorescent lamp sockets. See where the wire goes there is a slit/opening beside it (same place the wire goes). You stick a metal object (like a wire or straightened paper clip) in the slit/opening and this will release the wire. You have to pull the wire while you stick the metal object inside.
Hope that helps