From 95a174c60f7c256cf327c7e1849d6d5a3ab532cf Mon Sep 17 00:00:00 2001 From: wcjord <32568597+wcjord@users.noreply.github.com> Date: Mon, 23 Jun 2025 17:22:59 -0400 Subject: [PATCH 1/2] fix(it): give sametype of hint for incorrect and correct choice --- lib/pangea/choreographer/widgets/it_bar.dart | 18 ++++++++++++------ 1 file changed, 12 insertions(+), 6 deletions(-) diff --git a/lib/pangea/choreographer/widgets/it_bar.dart b/lib/pangea/choreographer/widgets/it_bar.dart index b5b704d08..1c5b07a0b 100644 --- a/lib/pangea/choreographer/widgets/it_bar.dart +++ b/lib/pangea/choreographer/widgets/it_bar.dart @@ -1,23 +1,23 @@ import 'dart:async'; import 'dart:developer'; -import 'package:flutter/foundation.dart'; -import 'package:flutter/material.dart'; - import 'package:fluffychat/pangea/choreographer/constants/choreo_constants.dart'; import 'package:fluffychat/pangea/choreographer/controllers/choreographer.dart'; import 'package:fluffychat/pangea/choreographer/controllers/it_controller.dart'; +import 'package:fluffychat/pangea/choreographer/widgets/igc/word_data_card.dart'; import 'package:fluffychat/pangea/choreographer/widgets/it_feedback_card.dart'; import 'package:fluffychat/pangea/common/utils/error_handler.dart'; import 'package:fluffychat/pangea/instructions/instructions_enum.dart'; import 'package:fluffychat/pangea/instructions/instructions_inline_tooltip.dart'; import 'package:fluffychat/pangea/learning_settings/pages/settings_learning.dart'; import 'package:fluffychat/widgets/matrix.dart'; +import 'package:flutter/foundation.dart'; +import 'package:flutter/material.dart'; + import '../../common/utils/overlay.dart'; import '../controllers/it_feedback_controller.dart'; import '../models/it_response_model.dart'; import 'choice_array.dart'; -import 'igc/word_data_card.dart'; class ITBar extends StatefulWidget { final Choreographer choreographer; @@ -333,7 +333,13 @@ class ITChoices extends StatelessWidget { fullTextLang: sourceText != null ? controller.sourceLangCode : controller.targetLangCode, - hasInfo: controller.currentITStep!.continuances[index].hasInfo, + // IMPORTANT COMMENT TO KEEP: We're going to forace hasInfo to false for now + // because we don't want to show the word data card for correct choices and the contextual definition + // for incorrect choices. This gives away the answer (if you're Kel at least). + // The reason hasInfo is false for incorrect choices is that we're not includng the tokens for distractors. + // Correct choices will have the tokens, but we don't want to show something different for them. + // hasInfo: controller.currentITStep!.continuances[index].hasInfo, + hasInfo: false, choiceFeedback: choiceFeedback, room: controller.choreographer.chatController.room, ) @@ -352,7 +358,7 @@ class ITChoices extends StatelessWidget { sourceTextLang: controller.sourceLangCode, targetLang: controller.targetLangCode, ), - choiceFeedback: choiceFeedback, + choiceFeedback: choiceFeedback ?? "", ), maxHeight: 300, maxWidth: 300, From 36141d4043f149c72187f81ae092ac617bd8e767 Mon Sep 17 00:00:00 2001 From: ggurdin Date: Tue, 24 Jun 2025 09:13:42 -0400 Subject: [PATCH 2/2] chore: formatting --- lib/pangea/choreographer/widgets/it_bar.dart | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/lib/pangea/choreographer/widgets/it_bar.dart b/lib/pangea/choreographer/widgets/it_bar.dart index 1c5b07a0b..98f13510d 100644 --- a/lib/pangea/choreographer/widgets/it_bar.dart +++ b/lib/pangea/choreographer/widgets/it_bar.dart @@ -1,6 +1,9 @@ import 'dart:async'; import 'dart:developer'; +import 'package:flutter/foundation.dart'; +import 'package:flutter/material.dart'; + import 'package:fluffychat/pangea/choreographer/constants/choreo_constants.dart'; import 'package:fluffychat/pangea/choreographer/controllers/choreographer.dart'; import 'package:fluffychat/pangea/choreographer/controllers/it_controller.dart'; @@ -11,9 +14,6 @@ import 'package:fluffychat/pangea/instructions/instructions_enum.dart'; import 'package:fluffychat/pangea/instructions/instructions_inline_tooltip.dart'; import 'package:fluffychat/pangea/learning_settings/pages/settings_learning.dart'; import 'package:fluffychat/widgets/matrix.dart'; -import 'package:flutter/foundation.dart'; -import 'package:flutter/material.dart'; - import '../../common/utils/overlay.dart'; import '../controllers/it_feedback_controller.dart'; import '../models/it_response_model.dart'; @@ -358,7 +358,7 @@ class ITChoices extends StatelessWidget { sourceTextLang: controller.sourceLangCode, targetLang: controller.targetLangCode, ), - choiceFeedback: choiceFeedback ?? "", + choiceFeedback: choiceFeedback, ), maxHeight: 300, maxWidth: 300,