@sage-rsc/talking-head-react 1.0.59 → 1.0.60

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@sage-rsc/talking-head-react",
3
- "version": "1.0.59",
3
+ "version": "1.0.60",
4
4
  "description": "A reusable React component for 3D talking avatars with lip-sync and text-to-speech",
5
5
  "main": "./dist/index.cjs",
6
6
  "module": "./dist/index.js",
@@ -185,11 +185,9 @@ const CurriculumLearning = forwardRef(({
185
185
  : 100;
186
186
  let feedbackMessage = `Congratulations! You've completed this lesson`;
187
187
  if (stateRef.current.totalQuestions > 0) {
188
- // Rephrase for clearer TTS: "You got X correct out of Y questions, which is Z percent"
189
- const scoreText = stateRef.current.score === 1 ? 'one' : stateRef.current.score;
190
- const totalText = stateRef.current.totalQuestions === 1 ? 'one' : stateRef.current.totalQuestions;
191
- const percentText = percentage === 50 ? 'fifty' : `${percentage}`;
192
- feedbackMessage += ` You got ${scoreText} correct out of ${totalText} question${stateRef.current.totalQuestions === 1 ? '' : 's'}, which is ${percentText} percent. `;
188
+ // Rephrase for clearer TTS: "You got X correct out of Y questions, achieving Z percent"
189
+ // Use numbers as-is for TTS to handle naturally
190
+ feedbackMessage += ` You got ${stateRef.current.score} correct out of ${stateRef.current.totalQuestions} question${stateRef.current.totalQuestions === 1 ? '' : 's'}, achieving a score of ${percentage} percent. `;
193
191
  } else {
194
192
  feedbackMessage += `! `;
195
193
  }