Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: graduated reveal of hints on blanks #570

Merged
merged 1 commit into from
Feb 9, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
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
Loading