Replace component constructor functions with state functions
Replace component constructor functions with state functions
Flatten event inputs in the state structs