-
Notifications
You must be signed in to change notification settings - Fork 65
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
Prevent score point deduction #97
base: master
Are you sure you want to change the base?
Changes from 3 commits
659cc67
8b92163
809eb8e
85b3b48
6b8ae29
6581751
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -33,7 +33,8 @@ H5P.MarkTheWords = (function ($, Question, Word, KeyboardNav, XapiGenerator) { | |
enableRetry: true, | ||
enableSolutionsButton: true, | ||
enableCheckButton: true, | ||
showScorePoints: true | ||
showScorePoints: true, | ||
preventPointSubstraction: false | ||
}, | ||
checkAnswerButton: "Check", | ||
submitAnswerButton: "Submit", | ||
|
@@ -472,7 +473,7 @@ H5P.MarkTheWords = (function ($, Question, Word, KeyboardNav, XapiGenerator) { | |
if (word.isCorrect()) { | ||
result.correct++; | ||
} | ||
else if (word.isWrong()) { | ||
else if (word.isWrong()&&!self.params.behaviour.preventPointSubstraction) { | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. It's required to add blanks around There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Thank you for this hint. |
||
result.wrong++; | ||
} | ||
else if (word.isMissed()) { | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -208,6 +208,14 @@ | |
"description": "Show points earned for each answer.", | ||
"importance": "low", | ||
"default": true | ||
}, | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. If you add fields to The H5P CLI tool can help you with updating translations. You can mark fields with one of the appropriate attributes There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Yes, I knew that I shouldn't only update the German language file but didn't know how to change all language files. Thank you so much for clearifying this. As for There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. @osa-freiburg Nope, the command is There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Ok, thank you. I have to check this, but probably not today any more, but the day after tomorrow. I'll come back... There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. As it was not a big thing, I just fixed the faulty translation files. The error message was generated from an old h5p CLI - sorry, that I didn't update it in the beginning. Now the There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Ah, one thing FYI: I had to remove the |
||
{ | ||
"name": "preventPointSubstraction", | ||
"type": "boolean", | ||
"label": "No score point deduction", | ||
"importance": "low", | ||
"description": "Enable to prevent score point deduction for wrong marked words.", | ||
"default": false | ||
} | ||
] | ||
}, | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In this case, bumping the patch version is not strictly required by the change alone (yes, if you want to deploy it, but not on a development system to test), so version number management should be left to the release manager.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ok, I switched back to patchVersion 0