Mechanics of curved surfaces, with application to surface‐parallel cracks