From bc8454e5971ff132a1adae9eb0d4f3703052a2f4 Mon Sep 17 00:00:00 2001 From: Mason Payne Date: Mon, 8 Apr 2024 13:55:30 -0600 Subject: [PATCH] get styles closer --- src/App.vue | 26 +++---- src/assets/main.css | 65 +++++++++-------- src/components/wizard-questions.vue | 108 ++++++++++++++++++++-------- src/views/WizardView.vue | 5 +- 4 files changed, 128 insertions(+), 76 deletions(-) diff --git a/src/App.vue b/src/App.vue index 53b5551..a7cc29e 100644 --- a/src/App.vue +++ b/src/App.vue @@ -4,25 +4,25 @@ import HelloWorld from './components/HelloWorld.vue' diff --git a/src/assets/main.css b/src/assets/main.css index 36fb845..6119f28 100644 --- a/src/assets/main.css +++ b/src/assets/main.css @@ -1,35 +1,40 @@ @import './base.css'; #app { - max-width: 1280px; - margin: 0 auto; - padding: 2rem; - font-weight: normal; -} - -a, -.green { - text-decoration: none; - color: hsla(160, 100%, 37%, 1); - transition: 0.4s; - padding: 3px; -} - -@media (hover: hover) { - a:hover { - background-color: hsla(160, 100%, 37%, 0.2); - } -} - -@media (min-width: 1024px) { - body { + /*max-width: 1280px;*/ + /*margin: 0 auto;*/ + /*padding: 2rem;*/ + /*font-weight: normal;*/ + height: 100vh; display: flex; - place-items: center; - } - - #app { - display: grid; - grid-template-columns: 1fr 1fr; - padding: 0 2rem; - } + flex-direction: column; + justify-content: center; + padding: 1rem; } + +/*a,*/ +/*.green {*/ +/* text-decoration: none;*/ +/* color: hsla(160, 100%, 37%, 1);*/ +/* transition: 0.4s;*/ +/* padding: 3px;*/ +/*}*/ + +/*@media (hover: hover) {*/ +/* a:hover {*/ +/* background-color: hsla(160, 100%, 37%, 0.2);*/ +/* }*/ +/*}*/ + +/*@media (min-width: 1024px) {*/ +/* body {*/ +/* display: flex;*/ +/* place-items: center;*/ +/* }*/ + +/* #app {*/ +/* display: grid;*/ +/* grid-template-columns: 1fr 1fr;*/ +/* padding: 0 2rem;*/ +/* }*/ +/*}*/ diff --git a/src/components/wizard-questions.vue b/src/components/wizard-questions.vue index 38de15c..77d8587 100644 --- a/src/components/wizard-questions.vue +++ b/src/components/wizard-questions.vue @@ -17,7 +17,7 @@ interface Question { options: string[]; } -const currentQuestionIndex = ref(1); +const currentQuestionIndex = ref(0); const questions = ref([ { id: 1, @@ -142,12 +142,16 @@ const questions = ref([ ]); function previousQuestion() { + // TODO: notify the backend that the user navigated backwards + if (currentQuestionIndex.value > 0) { currentQuestionIndex.value--; } } function nextQuestion() { + // TODO: notify the backend the users progress + if (currentQuestionIndex.value < questions.value.length - 1) { currentQuestionIndex.value++; } @@ -171,29 +175,77 @@ const isNextButtonDisabled = computed(() => { diff --git a/src/views/WizardView.vue b/src/views/WizardView.vue index 2067a2a..528304a 100644 --- a/src/views/WizardView.vue +++ b/src/views/WizardView.vue @@ -5,13 +5,12 @@ import WizardQuestions from "@/components/wizard-questions.vue";