added dev state to database, in progress tidy up to keyboardnav