Two-stage thiol-based click reactions for the preparation and adhesion of hydrogels