The court ruled unanimously that compulsory sterilization surgery for people who seek to legally change their gender is unconstitutional.