Decide to combine some states for simpler code, inspired by https://levelup.gitconnected.com/5-ways-to-simplify-your-react-hooks-fbedb406eee0