From b4bfafe11bd5eb9e77aaee250115a00dbf85a44f Mon Sep 17 00:00:00 2001 From: ggurdin Date: Wed, 30 Oct 2024 12:21:54 -0400 Subject: [PATCH] updated some copy --- assets/l10n/intl_en.arb | 51 ++---- assets/l10n/intl_es.arb | 154 +++++++++++++++++- .../class_description_button.dart | 4 +- .../p_class_widgets/room_capacity_button.dart | 38 +++-- 4 files changed, 184 insertions(+), 63 deletions(-) diff --git a/assets/l10n/intl_en.arb b/assets/l10n/intl_en.arb index c54d4e7b0..1cd522a5c 100644 --- a/assets/l10n/intl_en.arb +++ b/assets/l10n/intl_en.arb @@ -3656,11 +3656,6 @@ "unknownPrivateChat": "Unknown private chat", "copyClassCodeDesc": "Users who are already in the app can 'Join space' via the main menu.", "addToSpaceDesc": "Adding a chat to a space will make the chat appear within the space for students and give them access.", - "@addToSpaceDesc": { - "placeholders": { - "roomtype": {} - } - }, "invitedToSpace": "{user} has invited you to join a space: {space}! Do you wish to accept?", "@invitedToSpace": { "placeholders": { @@ -4008,7 +4003,7 @@ "accuracy": "Accuracy", "points": "Points", "noPaymentInfo": "No payment info necessary!", - "conversationBotModeSelectDescription": "Chat Activity", + "conversationBotModeSelectDescription": "Chat activity", "conversationBotModeSelectOption_discussion": "Discussion", "conversationBotModeSelectOption_custom": "Custom", "conversationBotModeSelectOption_conversation": "Conversation", @@ -4029,7 +4024,7 @@ "conversationBotCustomZone_customSystemPromptPlaceholder": "Set custom system prompt", "conversationBotCustomZone_customSystemPromptEmptyError": "Missing custom system prompt", "conversationBotCustomZone_customTriggerReactionEnabledLabel": "Responds on ⏩ reaction", - "botConfig": "Chat Settings", + "botConfig": "Chat settings", "addConversationBotDialogTitleInvite": "Confirm inviting conversation bot", "addConversationBotButtonInvite": "Invite", "addConversationBotDialogInviteConfirmation": "Invite", @@ -4059,39 +4054,21 @@ "tooltipInstructionsMobileBody": "Press and hold items to view tooltips.", "tooltipInstructionsBrowserBody": "Hover over items to view tooltips.", "addSpaceToSpaceDescription": "Select a space to add as a parent", - "roomCapacity": "{roomType} Capacity", - "@roomCapacity": { - "type": "text", - "placeholders": { - "roomType": {} - } - }, + "chatCapacity": "Chat capacity", + "spaceCapacity": "Space capacity", "roomFull": "This room is already at capacity.", "topicNotSet": "The topic has not been set.", - "capacityNotSet": "This room has no capacity limit.", - "roomCapacityHasBeenChanged": "{roomType} capacity changed", - "@roomCapacityHasBeenChanged": { - "type": "text", - "placeholders": { - "roomType": {} - } - }, - "roomExceedsCapacity": "Room exceeds capacity. Consider removing students from the room, or raising the capacity.", - "capacitySetTooLow": "{roomType} capacity cannot be set below the current number of non-admins.", - "@capacitySetTooLow": { - "type": "text", - "placeholders": { - "roomType": {} - } - }, - "roomCapacityExplanation": "{roomType} capacity limits the number of non-admins allowed in a room.", + "chatCapacityNotSet": "This chat has no capacity limit.", + "spaceCapacityNotSet": "This space has no capacity limit.", + "chatCapacityHasBeenChanged": "Chat capacity changed", + "spaceCapacityHasBeenChanged": "Space capacity changed", + "chatCapacitySetTooLow": "Chat capacity cannot be set below the current number of non-admins.", + "spaceCapacitySetTooLow": "Space capacity cannot be set below the current number of non-admins.", + "chatCapacityExplanation": "Chat capacity limits the number of non-admins allowed in a chat.", + "spaceCapacityExplanation": "Space capacity limits the number of non-admins allowed in a space.", + "chatExceedsCapacity": "This chat exceeds its capacity.", + "spaceExceedsCapacity": "This space exceeds its capacity.", "tooManyRequest": "Too many request, please try again later.", - "@roomCapacityExplanation": { - "type": "text", - "placeholders": { - "roomType": {} - } - }, "enterNumber": "Please enter a whole number value.", "buildTranslation": "Build your translation from the choices above", "noDatabaseEncryption": "Database encryption is not supported on this platform", diff --git a/assets/l10n/intl_es.arb b/assets/l10n/intl_es.arb index acfcdee46..a833f813c 100644 --- a/assets/l10n/intl_es.arb +++ b/assets/l10n/intl_es.arb @@ -4576,14 +4576,8 @@ "roomDataMissing": "Es posible que falten algunos datos de las salas de las que no es miembro.", "suggestToChat": "Sugerir este chat", "suggestToChatDesc": "Los chats sugeridos aparecerán en las listas de chats", - "roomCapacity": "Capacidad de la sala", "roomFull": "Esta sala ya está al límite de su capacidad.", "topicNotSet": "El tema no se ha fijado.", - "capacityNotSet": "Esta sala no tiene límite de capacidad.", - "roomCapacityHasBeenChanged": "Capacidad de la sala modificada", - "roomExceedsCapacity": "La sala supera su capacidad. Considere la posibilidad de retirar a los alumnos de la sala o de aumentar la capacidad.", - "capacitySetTooLow": "La capacidad de la sala no puede fijarse por debajo del número actual de no administradores.", - "roomCapacityExplanation": "La capacidad de la sala limita el número de personas que pueden entrar en ella.", "enterNumber": "Introduzca un valor numérico entero.", "autoIGCToolName": "Ejecutar automáticamente la asistencia lingüística", "autoIGCToolDescription": "Ejecutar automáticamente la asistencia lingüística después de escribir mensajes", @@ -4769,7 +4763,6 @@ "conversationBotCustomZone_customSystemPromptPlaceholder": "Establecer mensaje del sistema personalizado", "conversationBotCustomZone_customSystemPromptEmptyError": "Falta mensaje del sistema personalizado", "conversationBotCustomZone_customTriggerReactionEnabledLabel": "Responde a la reacción ⏩", - "botConfig": "Configuraciones del Bot de Conversación", "addConversationBotDialogTitleInvite": "Confirmar la invitación del bot de conversación", "addConversationBotButtonInvite": "Invitar", "addConversationBotDialogInviteConfirmation": "Invitar", @@ -4871,5 +4864,148 @@ "l2SupportNa": "Haz clic en la palabra seleccionada para deseleccionarla", "l2SupportAlpha": "Alfa", "l2SupportBeta": "Beta", - "l2SupportFull": "Lleno" -} \ No newline at end of file + "l2SupportFull": "Lleno", + "chatCapacity": "Capacidad de chat", + "spaceCapacity": "Capacidad espacial", + "chatCapacityHasBeenChanged": "Capacidad de chat modificada", + "spaceCapacityHasBeenChanged": "Capacidad espacial modificada", + "chatCapacitySetTooLow": "La capacidad del chat no se puede establecer por debajo del número actual de no administradores.", + "spaceCapacitySetTooLow": "La capacidad de espacio no puede fijarse por debajo del número actual de no administradores.", + "chatCapacityExplanation": "La capacidad del chat limita el número de usuarios no administradores permitidos en un chat.", + "spaceCapacityExplanation": "La capacidad del espacio limita el número de no administradores permitidos en un espacio.", + "tooManyRequest": "Demasiadas solicitudes, por favor inténtelo más tarde.", + "voiceNotAvailable": "Parece que no tienes una voz instalada para este idioma.", + "openVoiceSettings": "Haz clic aquí para abrir los ajustes de voz", + "playAudio": "Jugar", + "stop": "Stop", + "grammarCopySCONJ": "Conjunción subordinante", + "grammarCopyNUM": "Número", + "grammarCopyVERB": "Verbo", + "grammarCopyAFFIX": "Coloque", + "grammarCopyPARTpos": "Partículas", + "grammarCopyADJ": "Adjetivo", + "grammarCopyCCONJ": "Conjunción de coordinación", + "grammarCopyPUNCT": "Puntuación", + "grammarCopyADV": "Adverbio", + "grammarCopyAUX": "Auxiliar", + "grammarCopySPACE": "Espacio", + "grammarCopySYM": "Símbolo", + "grammarCopyDET": "Determinante", + "grammarCopyPRON": "Pronombre", + "grammarCopyADP": "Adposición", + "grammarCopyPROPN": "Nombre propio", + "grammarCopyNOUN": "Sustantivo", + "grammarCopyINTJ": "Interjección", + "grammarCopyX": "Otros", + "grammarCopyFem": "Femenino", + "grammarCopy2": "Segunda persona", + "grammarCopyImp": "Imperativo", + "grammarCopyQest": "Pregunta", + "grammarCopyPerf": "Perfecto", + "grammarCopyAccNom": "Acusativo, Nominativo", + "grammarCopyObl": "Caso oblicuo", + "grammarCopyAct": "Activo", + "grammarCopyBrck": "Soporte", + "grammarCopyArt": "Artículo", + "grammarCopySing": "Singular", + "grammarCopyMasc": "Hombre", + "grammarCopyMod": "Modal", + "grammarCopyAdverbial": "Adverbial", + "grammarCopyPeri": "Perifrástico", + "grammarCopyDigit": "Dígitos", + "grammarCopyNot_proper": "No procede", + "grammarCopyCard": "Cardenal", + "grammarCopyProp": "Adecuado", + "grammarCopyDash": "Dash", + "grammarCopyYes": "Sí", + "grammarCopySemi": "Punto y coma", + "grammarCopyComm": "Coma", + "grammarCopyCnd": "Condicional", + "grammarCopyIntRel": "Interrogativo, relativo", + "grammarCopyAcc": "Acusativo", + "grammarCopyPartTag": "Partitivo", + "grammarCopyInt": "Preguntas", + "grammarCopyPast": "Anterior", + "grammarCopySup": "Superlativo", + "grammarCopyColo": "Colon", + "grammarCopy3": "Tercera persona", + "grammarCopyPlur": "Plural", + "grammarCopyNpr": "Nombre propio", + "grammarCopyInterrogative": "Preguntas", + "grammarCopyInfm": "Informal", + "grammarCopyTim": "Tiempo", + "grammarCopyNeg": "Negativo", + "grammarCopyTot": "Total", + "grammarCopyAdnomial": "Adnominal", + "grammarCopyProg": "Progresiva", + "grammarCopySub": "Subjuntivo", + "grammarCopyComplementive": "Complementive", + "grammarCopyNom": "Nominativo", + "grammarCopyFut": "Futuro", + "grammarCopyDat": "Dativo", + "grammarCopyPres": "Presente", + "grammarCopyNeut": "Esterilizar", + "grammarCopyRel": "Relativa", + "grammarCopyFinal_ending": "Final", + "grammarCopyDem": "Demostrativo", + "grammarCopyPre": "Preposición", + "grammarCopyFin": "Finito", + "grammarCopyPos": "Positivo", + "grammarCopyQuot": "Presupuesto", + "grammarCopyGer": "Redondo", + "grammarCopyPass": "Pasivo", + "grammarCopyGen": "Genitivo", + "grammarCopyPrs": "Presente", + "grammarCopyDef": "Definitivo", + "grammarCopyOrd": "Ordinal", + "grammarCopyIns": "Instrumental", + "grammarCopyAccDat": "Acusativo, Dativo", + "grammarCopyInf": "Infinitivo", + "grammarCopyLong": "Largo", + "grammarCopyInd": "Indicativo", + "grammarCopyCmp": "Comparativa", + "grammarCopyRelative_case": "Caso relativo", + "grammarCopyExcl": "Exclamativo", + "grammarCopy1": "En primera persona", + "grammarCopyIni": "Inicial", + "grammarCopyPerson": "Persona", + "grammarCopyForeign": "Extranjero", + "grammarCopyVoice": "Voz", + "grammarCopyVerbType": "Tipo de verbo", + "grammarCopyPoss": "Posesivo", + "grammarCopyPrepCase": "Caso preposicional", + "grammarCopyNumType": "Tipo de número", + "grammarCopyNounType": "Tipo de sustantivo", + "grammarCopyReflex": "Reflexivo", + "grammarCopyPronType": "Tipo de pronombre", + "grammarCopyPunctSide": "Puntuación Lado", + "grammarCopyVerbForm": "Forma verbal", + "grammarCopyGender": "Género", + "grammarCopyMood": "Estado de ánimo", + "grammarCopyAspect": "Aspecto", + "grammarCopyPunctType": "Tipo de puntuación", + "grammarCopyTense": "Tense", + "grammarCopyDegree": "Titulación", + "grammarCopyPolite": "Cortesía", + "grammarCopyAdvType": "Tipo de adverbio", + "grammarCopyNumber": "Número", + "grammarCopyConjType": "Tipo de conjunción", + "grammarCopyPolarity": "Polaridad", + "grammarCopyNumberPsor": "Número del poseedor", + "grammarCopyCase": "Caso", + "grammarCopyDefinite": "Definitividad", + "grammarCopyNumForm": "Forma numérica", + "grammarCopyUnknown": "Desconocido", + "enterPrompt": "Introduzca un mensaje del sistema", + "selectBotLanguage": "Selecciona el idioma del bot", + "chooseVoice": "Elige una voz", + "enterLanguageLevel": "Introduzca un nivel de idioma", + "enterDiscussionTopic": "Introduzca un tema de debate", + "selectBotChatMode": "Selecciona el modo de chat", + "messageNotInTargetLang": "El mensaje no está en la lengua de llegada", + "botConfig": "Configuración del chat", + "chatCapacityNotSet": "Este chat no tiene límite de capacidad.", + "spaceCapacityNotSet": "Este espacio no tiene límite de capacidad.", + "chatExceedsCapacity": "Este chat supera su capacidad.", + "spaceExceedsCapacity": "Este espacio supera su capacidad." +} diff --git a/lib/pangea/pages/class_settings/p_class_widgets/class_description_button.dart b/lib/pangea/pages/class_settings/p_class_widgets/class_description_button.dart index ff7d0068a..cea57995f 100644 --- a/lib/pangea/pages/class_settings/p_class_widgets/class_description_button.dart +++ b/lib/pangea/pages/class_settings/p_class_widgets/class_description_button.dart @@ -52,7 +52,7 @@ class ClassDescriptionButton extends StatelessWidget { title: Text( room.isSpace ? L10n.of(context)!.classDescription - : L10n.of(context)!.chatTopic, + : L10n.of(context)!.chatDescription, style: TextStyle( color: Theme.of(context).colorScheme.secondary, fontWeight: FontWeight.bold, @@ -74,7 +74,7 @@ void setClassTopic(Room room, BuildContext context) { title: Text( room.isSpace ? L10n.of(context)!.classDescription - : L10n.of(context)!.chatTopic, + : L10n.of(context)!.chatDescription, ), content: TextField( controller: textFieldController, diff --git a/lib/pangea/pages/class_settings/p_class_widgets/room_capacity_button.dart b/lib/pangea/pages/class_settings/p_class_widgets/room_capacity_button.dart index 11452830c..5b22c793c 100644 --- a/lib/pangea/pages/class_settings/p_class_widgets/room_capacity_button.dart +++ b/lib/pangea/pages/class_settings/p_class_widgets/room_capacity_button.dart @@ -62,21 +62,17 @@ class RoomCapacityButtonState extends State { ScaffoldMessenger.of(context).showSnackBar( SnackBar( content: Text( - L10n.of(context)!.roomExceedsCapacity, + spaceMode + ? L10n.of(context)!.chatExceedsCapacity + : L10n.of(context)!.spaceExceedsCapacity, ), ), ); } } - String get roomType { - final String chat = L10n.of(context)!.chat; - final String space = L10n.of(context)!.space; - if (widget.room != null) { - return widget.room!.isSpace ? space : chat; - } - return widget.spaceMode ? space : chat; - } + bool get spaceMode => + (widget.room != null && widget.room!.isSpace) || widget.spaceMode; @override Widget build(BuildContext context) { @@ -92,13 +88,17 @@ class RoomCapacityButtonState extends State { ), subtitle: Text( (capacity == null) - ? L10n.of(context)!.capacityNotSet + ? spaceMode + ? L10n.of(context)!.spaceCapacityNotSet + : L10n.of(context)!.chatCapacityNotSet : (nonAdmins != null) ? '$nonAdmins/$capacity' : '$capacity', ), title: Text( - L10n.of(context)!.roomCapacity(roomType), + spaceMode + ? L10n.of(context)!.spaceCapacity + : L10n.of(context)!.chatCapacity, style: TextStyle( color: Theme.of(context).colorScheme.secondary, fontWeight: FontWeight.bold, @@ -116,8 +116,12 @@ class RoomCapacityButtonState extends State { Future setRoomCapacity() async { final input = await showTextInputDialog( context: context, - title: L10n.of(context)!.roomCapacity(roomType), - message: L10n.of(context)!.roomCapacityExplanation(roomType), + title: spaceMode + ? L10n.of(context)!.spaceCapacity + : L10n.of(context)!.chatCapacity, + message: spaceMode + ? L10n.of(context)!.spaceCapacityExplanation + : L10n.of(context)!.chatCapacityExplanation, okLabel: L10n.of(context)!.ok, cancelLabel: L10n.of(context)!.cancel, textFields: [ @@ -133,7 +137,9 @@ class RoomCapacityButtonState extends State { return L10n.of(context)!.enterNumber; } if (nonAdmins != null && int.parse(value) < int.parse(nonAdmins!)) { - return L10n.of(context)!.capacitySetTooLow(roomType); + return spaceMode + ? L10n.of(context)!.spaceCapacitySetTooLow + : L10n.of(context)!.chatCapacitySetTooLow; } return null; }, @@ -159,7 +165,9 @@ class RoomCapacityButtonState extends State { ScaffoldMessenger.of(context).showSnackBar( SnackBar( content: Text( - L10n.of(context)!.roomCapacityHasBeenChanged(roomType), + spaceMode + ? L10n.of(context)!.spaceCapacityHasBeenChanged + : L10n.of(context)!.chatCapacityHasBeenChanged, ), ), );