Fabrik icon indicating copy to clipboard operation
Fabrik copied to clipboard

Signup Page for Fabrik

Open sayamkanwar opened this issue 6 years ago • 17 comments

Hi, I have created the signup page for Fabrik. I have added all the custom validation code. For csrf, I have used npm package django-react-csrftoken. The signup form should be available at /#/signup.

Here's a demo

fabrik_signup

Please review @Ram81 @RishabhJain2018 @yashdusing @utsavgarg Thank you! :)

sayamkanwar avatar Dec 11 '18 01:12 sayamkanwar

Sure @Ram81

sayamkanwar avatar Dec 11 '18 07:12 sayamkanwar

@Ram81, do you want me to completely change the design or change the color scheme to match with that of Fabrik?

sayamkanwar avatar Dec 11 '18 09:12 sayamkanwar

Or would you like something like this? @Ram81

screenshot 2018-12-11 at 4 01 33 pm

sayamkanwar avatar Dec 11 '18 10:12 sayamkanwar

@Ram81, Can you please describe what type of design are you expecting?

sayamkanwar avatar Dec 11 '18 11:12 sayamkanwar

Also @Ram81, can you please review the code as well? So that I can do all the changes at once. Thank you!

sayamkanwar avatar Dec 11 '18 14:12 sayamkanwar

@sayamkanwar you can see some work done by previous students who attempted the task there was one PR by @C0derLint which had a good design example

Ram81 avatar Dec 11 '18 14:12 Ram81

Oh okay @Ram81. But he had combined the login and signup form right? For me, I have to just create a sign up form?

sayamkanwar avatar Dec 11 '18 14:12 sayamkanwar

Is this fine @Ram81?

new_signup_mockup

sayamkanwar avatar Dec 11 '18 15:12 sayamkanwar

@Ram81, By security do you mean the prevention for different types of attacks through the input?

sayamkanwar avatar Dec 11 '18 17:12 sayamkanwar

@sayamkanwar yes

Ram81 avatar Dec 11 '18 17:12 Ram81

Okay @Ram81, I'll add those checks. Thanks for pointing out! :)

sayamkanwar avatar Dec 11 '18 17:12 sayamkanwar

Do these 2 match Fabrik's theme? @Ram81

new_signup_mockup2

new_signup_mockup3

If you like these, please mention your choice as well.

sayamkanwar avatar Dec 11 '18 18:12 sayamkanwar

@sayamkanwar second one looks good for now

Ram81 avatar Dec 12 '18 04:12 Ram81

@Ram81, okay I'll code this then. Thank you! :)

sayamkanwar avatar Dec 12 '18 06:12 sayamkanwar

I have created the new design with all the changes you had asked for. I have also added the code to clean the string before submitting to the database which will prevent cyber security attacks. Also added all types of validation rules in the form. I have also added the code which gives an error if the account with the provided details already exists in the database.

New UI screenshot 2018-12-12 at 9 22 39 pm

Demo demo_account

Please review @Ram81 @RishabhJain2018 Thank you! :)

sayamkanwar avatar Dec 12 '18 15:12 sayamkanwar

Also, if you see any odd indentations, that's probably because of ESLint. Without those, I was getting webpack errors and warnings.

sayamkanwar avatar Dec 12 '18 16:12 sayamkanwar

@Ram81, I have added the code which sets the logged in user's details in localStorage. localStorage will be the best option to maintain such type of records which are to be used at the frontend for real-time collaboration purpose.

Here's a demo on how this will work. signup-localstorage

So whenever we need to use them, we can simply read the item value from localStorage through javascript. For User ID: localStorage.getItem("userID"), For Username: localStorage.getItem("username"), For Email: localStorage.getItem("email")

Let me know your opinion on this. Thank you! :)

sayamkanwar avatar Dec 13 '18 15:12 sayamkanwar