Squark contributions to Higgs boson masses in the next-to-minimal supersymmetric standard model