Skip to content

Commit 0b3568b

Browse files
fix: make feedback text optional (closes #232)
* fix: make feedback text optional currently the form required people to type something in the final form * [autofix.ci] apply automated fixes --------- Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
1 parent c083c44 commit 0b3568b

1 file changed

Lines changed: 6 additions & 9 deletions

File tree

src/builtins/taskFeedbackSurvey/TaskFeedbackSurveyView.vue

Lines changed: 6 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -26,15 +26,11 @@ if (!api.persist.isDefined('forminfo')) {
2626
}
2727
2828
/**
29-
* Computed property to check if all form fields are completed
29+
* Computed property to check if required form fields are completed
3030
* @returns {boolean} True if all required fields have values
3131
*/
3232
const complete = computed(
33-
() =>
34-
api.persist.forminfo.difficulty_rating !== '' &&
35-
api.persist.forminfo.enjoyment_rating !== '' &&
36-
api.persist.forminfo.feedback !== '' &&
37-
api.persist.forminfo.issues !== ''
33+
() => api.persist.forminfo.difficulty_rating !== '' && api.persist.forminfo.enjoyment_rating !== ''
3834
)
3935
4036
/**
@@ -140,10 +136,10 @@ function finish() {
140136
<p class="text-xs text-muted-foreground mt-1">Select your rating</p>
141137
</div>
142138

143-
<!-- General feedback textarea -->
139+
<!-- General feedback textarea (optional) -->
144140
<div class="mb-3">
145141
<label class="block text-md font-semibold text-foreground mb-2">
146-
Any general feedback for the study team?
142+
Any general feedback for the study team? <span class="font-normal text-muted-foreground">(optional)</span>
147143
</label>
148144
<Textarea
149145
v-model="api.persist.forminfo.feedback"
@@ -154,10 +150,11 @@ function finish() {
154150
<p class="text-xs text-muted-foreground mt-1">Share your general thoughts and reactions</p>
155151
</div>
156152

157-
<!-- Issues reporting textarea -->
153+
<!-- Issues reporting textarea (optional) -->
158154
<div class="mb-3">
159155
<label class="block text-md font-semibold text-foreground mb-2">
160156
Any specific issues to report that might improve the study?
157+
<span class="font-normal text-muted-foreground">(optional)</span>
161158
</label>
162159
<Textarea
163160
v-model="api.persist.forminfo.issues"

0 commit comments

Comments
 (0)