Na adsorption on the layered semiconductors SnS2 and WSe2