Skip to content

Commit

Permalink
fix: graduated reveal of hints on blanks (#570)
Browse files Browse the repository at this point in the history
  • Loading branch information
NiloCK authored Feb 9, 2025
2 parents 788b08b + 7f97ed4 commit 279c3fc
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -30,8 +30,7 @@ export default defineComponent({
// return (a as QuestionView<Question>).submitAnswer !== undefined;
// },
submit(answer: Answer) {
// const thisClassname = this.constructor.name;
return this.getQuestionViewAncestor().submitAnswer(answer);
return this.getQuestionViewAncestor().submitAnswer(answer, this.$options.name ?? 'UserInput');
},
getQuestionViewAncestor(): ViewComponent {
let ancestor = this.$parent;
Expand Down
4 changes: 2 additions & 2 deletions packages/vue/src/courses/default/questions/fillIn/fillIn.vue
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
<span>{{ obscuredAnswer }}</span>
</div>
<div v-else-if="priorAttempts == 2" class="text-center text-h6">
<span>{{ obscuredAnswer }}</span>
<span>{{ someAnswer }}</span>
</div>
<v-card-actions v-if="!isQuestion">
<v-spacer></v-spacer>
Expand Down Expand Up @@ -139,7 +139,7 @@ export default defineComponent({
) {
return gradeSpellingAttempt(questionUtils.priorAnswers.value[0][0] as string, sa);
} else {
console.log(`found no UserInputString`); // [ ] rework this - finding `VueComponent` instead, which prevents grading.
console.log(`found no UserInputString`);
}
if (someAnswer.value) {
Expand Down

0 comments on commit 279c3fc

Please sign in to comment.