|
|
@@ -2,12 +2,12 @@
|
|
2
|
2
|
main.view--onboarding
|
|
3
|
3
|
article(
|
|
4
|
4
|
style='display: flex; flex-direction: column; align-items: center'
|
|
5
|
|
- v-if='currentStep !== survey.steps.length'
|
|
|
5
|
+ v-if='currentStep !== survey?.steps?.length'
|
|
6
|
6
|
)
|
|
7
|
7
|
.answers(v-for='(value, key) in answered')
|
|
8
|
8
|
span(v-if='key == "name" && value && currentStep == 2') Hi {{ value }}!
|
|
9
|
9
|
br
|
|
10
|
|
- .step(v-for='(step, i) in survey.steps')
|
|
|
10
|
+ .step(v-for='(step, i) in survey?.steps')
|
|
11
|
11
|
component(
|
|
12
|
12
|
:answered='answered'
|
|
13
|
13
|
:currentStep='currentStep'
|
|
|
@@ -15,7 +15,7 @@ main.view--onboarding
|
|
15
|
15
|
:question='step'
|
|
16
|
16
|
:responses='responses'
|
|
17
|
17
|
:survey='survey'
|
|
18
|
|
- :surveyStepsCount='survey.steps.length'
|
|
|
18
|
+ :surveyStepsCount='survey?.steps?.length'
|
|
19
|
19
|
@handle-submit='onSubmit'
|
|
20
|
20
|
@update-answers='updateAnswers'
|
|
21
|
21
|
v-if='step && currentStep == i'
|
|
|
@@ -27,10 +27,10 @@ main.view--onboarding
|
|
27
|
27
|
p {{ survey.steps[currentStep].invalidInputPrompt }}
|
|
28
|
28
|
|
|
29
|
29
|
footer
|
|
30
|
|
- p(v-if='currentStep != 0') You have completed: {{ currentStep }} / {{ survey.steps.length }} survey steps
|
|
|
30
|
+ p(v-if='currentStep != 0') You have completed: {{ currentStep }} / {{ survey?.steps?.length }} survey steps
|
|
31
|
31
|
|
|
32
|
32
|
article(v-else)
|
|
33
|
|
- SurveyCompleteView(:answers='answered' :surveySteps='survey.steps')
|
|
|
33
|
+ SurveyCompleteView(:answers='answered' :surveySteps='survey?.steps')
|
|
34
|
34
|
</template>
|
|
35
|
35
|
|
|
36
|
36
|
<script>
|