From 573341acf0974bfd0f9976fecea29480c472e3c4 Mon Sep 17 00:00:00 2001 From: Alessio Comi Date: Sun, 14 Apr 2024 12:34:31 +0200 Subject: [PATCH 1/3] updating style from add question too look more like mockup --- frontend/src/components/CustomInput.vue | 6 +- frontend/src/views/AddQuestionView.vue | 78 ++++++++++++++++++++----- 2 files changed, 67 insertions(+), 17 deletions(-) diff --git a/frontend/src/components/CustomInput.vue b/frontend/src/components/CustomInput.vue index d90f179..f622288 100644 --- a/frontend/src/components/CustomInput.vue +++ b/frontend/src/components/CustomInput.vue @@ -45,14 +45,14 @@ const onChange = (event) => { \ No newline at end of file + +@media (min-width: 576px) { + .form-wrapper { + max-width: 90%; + } +} + + +@media (min-width: 1024px) { + .form-wrapper { + max-width: 70%; + } +} + + + From 51fd49cf975623447587e96e0061e8b7481f7981 Mon Sep 17 00:00:00 2001 From: Alessio Comi Date: Sun, 14 Apr 2024 13:19:22 +0200 Subject: [PATCH 2/3] update LoginView to look like mockup --- .../src/views/Authentication/LoginView.vue | 60 +++++++++++++++++-- 1 file changed, 54 insertions(+), 6 deletions(-) diff --git a/frontend/src/views/Authentication/LoginView.vue b/frontend/src/views/Authentication/LoginView.vue index 52e8ff7..bec2235 100644 --- a/frontend/src/views/Authentication/LoginView.vue +++ b/frontend/src/views/Authentication/LoginView.vue @@ -39,12 +39,17 @@ const login = async () => { - From 48b21a4256044850baf69138e878cbcae03f9e64 Mon Sep 17 00:00:00 2001 From: Alessio Comi Date: Sun, 14 Apr 2024 14:28:31 +0200 Subject: [PATCH 3/3] grouping style into main.css and doing signup --- frontend/src/assets/main.css | 14 +++++- frontend/src/views/AddQuestionView.vue | 21 +-------- .../src/views/Authentication/LoginView.vue | 23 +--------- .../src/views/Authentication/SignUpView.vue | 43 +++++++++++++++---- 4 files changed, 50 insertions(+), 51 deletions(-) diff --git a/frontend/src/assets/main.css b/frontend/src/assets/main.css index 4dadf12..d0e340a 100644 --- a/frontend/src/assets/main.css +++ b/frontend/src/assets/main.css @@ -41,7 +41,6 @@ h4 text-decoration: none; } - .info { margin: 1.5rem 0 1rem 0; } @@ -70,6 +69,19 @@ h4 padding: 0 1rem; } +.form-wrapper { + width: 100%; + max-width: 100%; + padding: 0 1rem; + box-sizing: border-box; +} + +.button-wrapper { + margin-top: 1.5rem; + display: flex; + justify-content: center; +} + @media (hover: hover) { a:hover { text-decoration: underline; diff --git a/frontend/src/views/AddQuestionView.vue b/frontend/src/views/AddQuestionView.vue index 22e74b2..d57f5a6 100644 --- a/frontend/src/views/AddQuestionView.vue +++ b/frontend/src/views/AddQuestionView.vue @@ -81,27 +81,8 @@ const submitForm = () => { align-items: center; } -.title { +.title, .info { text-align: center; - margin-bottom: 1.3rem; -} - -.info { - text-align: center; - margin-bottom: 1.5rem; -} - -.form-wrapper { - width: 100%; - max-width: 100%; - padding: 0 1rem; - box-sizing: border-box; -} - -.button-wrapper { - margin-top: 1.5rem; - display: flex; - justify-content: center; } .success-message { diff --git a/frontend/src/views/Authentication/LoginView.vue b/frontend/src/views/Authentication/LoginView.vue index bec2235..4768daa 100644 --- a/frontend/src/views/Authentication/LoginView.vue +++ b/frontend/src/views/Authentication/LoginView.vue @@ -64,27 +64,8 @@ const login = async () => { align-items: center; } -.title { +.title, .info { text-align: center; - margin-bottom: 1.3rem; -} - -.info { - text-align: center; - margin-bottom: 1.5rem; -} - -.form-wrapper { - width: 100%; - max-width: 100%; - padding: 0 1rem; - box-sizing: border-box; -} - -.button-wrapper { - margin-top: 1.5rem; - display: flex; - justify-content: center; } .success-message { @@ -97,11 +78,9 @@ const login = async () => { } } - @media (min-width: 1024px) { .form-wrapper { max-width: 70%; } } - diff --git a/frontend/src/views/Authentication/SignUpView.vue b/frontend/src/views/Authentication/SignUpView.vue index 786fad0..9f65ef3 100644 --- a/frontend/src/views/Authentication/SignUpView.vue +++ b/frontend/src/views/Authentication/SignUpView.vue @@ -12,6 +12,7 @@ const clearForm = () => { username.value = ''; password.value = ''; confirmPassword.value = ''; + validationMessage.value = ''; }; const register = async () => { @@ -39,14 +40,19 @@ const register = async () => { +