His book about time-traveling dinosaurs became a movie. He also adapted the Broadway show “Into the Woods” for young readers and wrote about his struggles with dyslexia.