Add the mode hook definition. Fix a few spelling errors.