Transgender library worker wins settlement over denied surgery