main.view--onboarding
article(
style='display: flex; flex-direction: column; align-items: center'
v-if='survey'
)
p {{ currentStep }}
p(v-if='currentStep != 0') You have completed: {{ currentStep - 1 }} / 7 survey steps
.answers(v-for='(value, key) in answered')
span(v-if='key == "name" && value && currentStep == 2') Hi {{ value }}!
span(v-if='key == "email" && value && currentStep == 3') Thanks for the contact info, {{ answered.name }}!
span(v-if='key == "zipcode" && value && currentStep == 5') Very cool, {{ answered.name }}, we'll be sure only to show you results in your area. Now let's get to know more about you!
.step(v-for='(step, i) in survey.steps')
component(
:aspect-questions='step.component == "Aspects" ? survey.aspectQuestions : null'
:is='step.component'
:question='step'
@handle-submit='onSubmit'
@update-answers='updateAnswers'
v-if='step && currentStep == i'
)
// TODO: change to different vue component
article(
style='display: flex; flex-direction: column; align-items: center; text-align: center;'
v-if='currentStep == 8'
)
h1 Thanks for Completing Our Survey!!
h2 Please review your answers and let us know if you need to change anything.
span Your name: {{ answered.name }}
span Your email: {{ answered.email }}
span Your zipcode: {{ answered.zipcode }}
span Your blurb: {{ answered.blurb }}
span Your image: {{ answered.image }}
br
button(@click="changeAnswers") Change Answers
br
button(@click="finalSubmit") Submit Answers