Merge branch 'main' into fluffychat-merge-2
This commit is contained in:
commit
5f4b61d494
3 changed files with 36 additions and 7 deletions
|
|
@ -84,10 +84,19 @@ class LevelUpAnalyticsService {
|
|||
ownMessage: room.client.userID == event.senderId,
|
||||
);
|
||||
|
||||
messages.add({
|
||||
'sent': pangeaEvent.originalSent?.text ?? pangeaEvent.body,
|
||||
'written': pangeaEvent.originalWrittenContent,
|
||||
});
|
||||
if (pangeaEvent.isAudioMessage) {
|
||||
final stt = pangeaEvent.getSpeechToTextLocal();
|
||||
if (stt == null) continue;
|
||||
messages.add({
|
||||
'sent': stt.transcript.text,
|
||||
'written': stt.transcript.text,
|
||||
});
|
||||
} else {
|
||||
messages.add({
|
||||
'sent': pangeaEvent.originalSent?.text ?? pangeaEvent.body,
|
||||
'written': pangeaEvent.originalWrittenContent,
|
||||
});
|
||||
}
|
||||
} catch (e, s) {
|
||||
ErrorHandler.logError(
|
||||
e: e,
|
||||
|
|
|
|||
|
|
@ -111,9 +111,11 @@ class LanguageSelectionPageState extends State<LanguageSelectionPage> {
|
|||
child: Row(
|
||||
spacing: 12.0,
|
||||
children: [
|
||||
BackButton(
|
||||
onPressed: Navigator.of(context).pop,
|
||||
),
|
||||
Navigator.of(context).canPop()
|
||||
? BackButton(
|
||||
onPressed: Navigator.of(context).maybePop,
|
||||
)
|
||||
: const SizedBox(width: 40.0),
|
||||
Expanded(
|
||||
child: LayoutBuilder(
|
||||
builder: (context, constraints) {
|
||||
|
|
|
|||
|
|
@ -16,6 +16,9 @@ enum PartOfSpeechEnum {
|
|||
verb,
|
||||
adj,
|
||||
adv,
|
||||
idiom,
|
||||
phrasalv,
|
||||
compn,
|
||||
|
||||
//Function tokens
|
||||
sconj,
|
||||
|
|
@ -86,6 +89,12 @@ enum PartOfSpeechEnum {
|
|||
return L10n.of(context).grammarCopyPOSnoun;
|
||||
case PartOfSpeechEnum.intj:
|
||||
return L10n.of(context).grammarCopyPOSintj;
|
||||
case PartOfSpeechEnum.idiom:
|
||||
return L10n.of(context).grammarCopyPOSidiom;
|
||||
case PartOfSpeechEnum.phrasalv:
|
||||
return L10n.of(context).grammarCopyPOSphrasalv;
|
||||
case PartOfSpeechEnum.compn:
|
||||
return L10n.of(context).grammarCopyPOScompn;
|
||||
case PartOfSpeechEnum.x:
|
||||
return L10n.of(context).grammarCopyPOSx;
|
||||
}
|
||||
|
|
@ -96,6 +105,9 @@ enum PartOfSpeechEnum {
|
|||
PartOfSpeechEnum.verb,
|
||||
PartOfSpeechEnum.adj,
|
||||
PartOfSpeechEnum.adv,
|
||||
PartOfSpeechEnum.idiom,
|
||||
PartOfSpeechEnum.phrasalv,
|
||||
PartOfSpeechEnum.compn,
|
||||
].contains(this);
|
||||
|
||||
bool get canBeDefined => [
|
||||
|
|
@ -112,6 +124,9 @@ enum PartOfSpeechEnum {
|
|||
PartOfSpeechEnum.adp,
|
||||
PartOfSpeechEnum.aux,
|
||||
PartOfSpeechEnum.num,
|
||||
PartOfSpeechEnum.idiom,
|
||||
PartOfSpeechEnum.phrasalv,
|
||||
PartOfSpeechEnum.compn,
|
||||
].contains(this);
|
||||
|
||||
bool get canBeHeard => [
|
||||
|
|
@ -128,6 +143,9 @@ enum PartOfSpeechEnum {
|
|||
PartOfSpeechEnum.adp,
|
||||
PartOfSpeechEnum.aux,
|
||||
PartOfSpeechEnum.num,
|
||||
PartOfSpeechEnum.idiom,
|
||||
PartOfSpeechEnum.phrasalv,
|
||||
PartOfSpeechEnum.compn,
|
||||
].contains(this);
|
||||
|
||||
bool eligibleForPractice(ActivityTypeEnum activityType) {
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue