refactor Signin form for Ex.8.5