Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions lib/features/chat/widgets/encrypted_file_message.dart
Original file line number Diff line number Diff line change
Expand Up @@ -497,7 +497,7 @@ class _EncryptedFileMessageState extends ConsumerState<EncryptedFileMessage> {
if (result.type != ResultType.done) {
SnackBarHelper.showTopSnackBar(
context,
'Could not open file: ${result.message}',
S.of(context)!.couldNotOpenFileWithMessage(result.message),
duration: const Duration(seconds: 3),
backgroundColor: Colors.orange,
);
Expand All @@ -507,7 +507,7 @@ class _EncryptedFileMessageState extends ConsumerState<EncryptedFileMessage> {
if (mounted) {
SnackBarHelper.showTopSnackBar(
context,
'Error opening file: $e',
S.of(context)!.errorOpeningFileWithMessage(e.toString()),
backgroundColor: Colors.red,
);
}
Expand Down
2 changes: 1 addition & 1 deletion lib/features/chat/widgets/message_input.dart
Original file line number Diff line number Diff line change
Expand Up @@ -130,7 +130,7 @@ class _MessageInputState extends ConsumerState<MessageInput> {
if (mounted) {
SnackBarHelper.showTopSnackBar(
context,
'Error uploading file: $e',
S.of(context)!.errorUploadingFile(e.toString()),
backgroundColor: Colors.red,
);
}
Expand Down
4 changes: 2 additions & 2 deletions lib/features/disputes/widgets/dispute_input_section.dart
Original file line number Diff line number Diff line change
Expand Up @@ -130,15 +130,15 @@ class _DisputeInputSectionState extends State<DisputeInputSection> {
if (mounted) {
SnackBarHelper.showTopSnackBar(
context,
'Message sent: $message',
S.of(context)!.messageSent(message),
backgroundColor: Colors.green,
);
}
} catch (error) {
if (mounted) {
SnackBarHelper.showTopSnackBar(
context,
'Failed to send message: $error',
S.of(context)!.failedSendMessage(error.toString()),
backgroundColor: Colors.red,
);
}
Expand Down
2 changes: 1 addition & 1 deletion lib/features/disputes/widgets/dispute_message_bubble.dart
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@ class DisputeMessageBubble extends StatelessWidget {
Clipboard.setData(ClipboardData(text: text));
SnackBarHelper.showTopSnackBar(
context,
S.of(context)?.messageCopiedToClipboard ?? 'Message copied to clipboard',
S.of(context)!.messageCopiedToClipboard,
duration: const Duration(seconds: 1),
backgroundColor: Colors.green,
);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ class _AddLightningInvoiceScreenState
if (context.mounted) {
SnackBarHelper.showTopSnackBar(
context,
'Failed to cancel order: ${e.toString()}',
S.of(context)!.failedToCancelOrder(e.toString()),
);
}
}
Expand Down
37 changes: 37 additions & 0 deletions lib/l10n/intl_en.arb
Original file line number Diff line number Diff line change
Expand Up @@ -696,6 +696,13 @@
"copy": "Copy",
"share": "Share",
"failedToShareInvoice": "Failed to share invoice. Please try copying instead.",
"failedToCancelOrder": "Failed to cancel order: {error}",
"@failedToCancelOrder": {
"placeholders": {
"error": { "type": "String" }
}
},
"refreshingExchangeRate": "Refreshing exchange rate...",
"language": "Language",
Comment thread
Catrya marked this conversation as resolved.
"systemDefault": "System Default",
"english": "English",
Expand Down Expand Up @@ -832,6 +839,12 @@
"notAvailable": "Not available",
"unknownDate": "Unknown date",
"messageCopiedToClipboard": "Message copied to clipboard",
"textCopiedToClipboard": "{text} copied to clipboard",
"@textCopiedToClipboard": {
"placeholders": {
"text": { "type": "String" }
}
},

"@_comment_deep_link_errors": "Deep Link Error Messages",
"deepLinkInvalidFormat": "Invalid mostro: URL format",
Expand Down Expand Up @@ -973,6 +986,12 @@
"error": { "type": "String" }
}
},
"messageSent": "Message sent: {message}",
"@messageSent": {
"placeholders": {
"message": { "type": "String" }
}
},
"waitingAdminAssignmentInput": "Waiting for admin assignment...",
"typeYourMessage": "Type your message...",

Expand Down Expand Up @@ -1235,7 +1254,25 @@
"imageDecryptionError": "Error decrypting image",
"imageNotAvailable": "Image not available",
"couldNotOpenFile": "Could not open file",
"couldNotOpenFileWithMessage": "Could not open file: {message}",
"@couldNotOpenFileWithMessage": {
"placeholders": {
"message": { "type": "String" }
}
},
"errorOpeningFile": "Error opening file",
"errorOpeningFileWithMessage": "Error opening file: {error}",
"@errorOpeningFileWithMessage": {
"placeholders": {
"error": { "type": "String" }
}
},
"errorUploadingFile": "Error uploading file: {error}",
"@errorUploadingFile": {
"placeholders": {
"error": { "type": "String" }
}
},

"@_comment_backup_reminder": "Backup reminder notification",
"backupAccountReminder": "You must back up your account",
Expand Down
39 changes: 38 additions & 1 deletion lib/l10n/intl_es.arb
Original file line number Diff line number Diff line change
Expand Up @@ -609,7 +609,14 @@
"copy": "Copiar",
"share": "Compartir",
"failedToShareInvoice": "Error al compartir factura. Por favor intenta copiarla en su lugar.",

"failedToCancelOrder": "Error al cancelar orden: {error}",
"@failedToCancelOrder": {
"placeholders": {
"error": { "type": "String" }
}
},
"refreshingExchangeRate": "Actualizando tasa de cambio...",

Comment thread
Catrya marked this conversation as resolved.
"@_comment_trade_detail_screen_new": "Nuevas cadenas de Pantalla de Detalles de Intercambio",
"orderDetailsTitle": "DETALLES DE ORDEN",
"buyOrderDetailsTitle": "DETALLES DE ORDEN DE COMPRA",
Expand Down Expand Up @@ -835,6 +842,12 @@
"notAvailable": "No disponible",
"unknownDate": "Fecha desconocida",
"messageCopiedToClipboard": "Mensaje copiado al portapapeles",
"textCopiedToClipboard": "{text} copiado al portapapeles",
"@textCopiedToClipboard": {
"placeholders": {
"text": { "type": "String" }
}
},


"@_comment_about_screen_new": "About Screen New Strings",
Expand Down Expand Up @@ -1114,6 +1127,12 @@
"error": { "type": "String" }
}
},
"messageSent": "Mensaje enviado: {message}",
"@messageSent": {
"placeholders": {
"message": { "type": "String" }
}
},
"waitingAdminAssignmentInput": "Esperando asignación de administrador...",
"typeYourMessage": "Escribe tu mensaje...",

Expand Down Expand Up @@ -1211,7 +1230,25 @@
"imageDecryptionError": "Error al desencriptar la imagen",
"imageNotAvailable": "Imagen no disponible",
"couldNotOpenFile": "No se pudo abrir el archivo",
"couldNotOpenFileWithMessage": "No se pudo abrir el archivo: {message}",
"@couldNotOpenFileWithMessage": {
"placeholders": {
"message": { "type": "String" }
}
},
"errorOpeningFile": "Error al abrir archivo",
"errorOpeningFileWithMessage": "Error al abrir archivo: {error}",
"@errorOpeningFileWithMessage": {
"placeholders": {
"error": { "type": "String" }
}
},
"errorUploadingFile": "Error al subir archivo: {error}",
"@errorUploadingFile": {
"placeholders": {
"error": { "type": "String" }
}
},

"@_comment_backup_reminder": "Recordatorio de respaldo de cuenta",
"backupAccountReminder": "Debes respaldar tu cuenta",
Expand Down
39 changes: 38 additions & 1 deletion lib/l10n/intl_it.arb
Original file line number Diff line number Diff line change
Expand Up @@ -639,7 +639,14 @@
"copy": "Copia",
"share": "Condividi",
"failedToShareInvoice": "Errore nel condividere la fattura. Per favore prova a copiarla invece.",

"failedToCancelOrder": "Impossibile annullare l'ordine: {error}",
"@failedToCancelOrder": {
"placeholders": {
"error": { "type": "String" }
}
},
"refreshingExchangeRate": "Aggiornamento tasso di cambio...",

Comment thread
Catrya marked this conversation as resolved.
"@_comment_trade_detail_screen_new": "Nuove Stringhe Schermata Dettagli Scambio",
"orderDetailsTitle": "DETTAGLI ORDINE",
"buyOrderDetailsTitle": "DETTAGLI ORDINE DI ACQUISTO",
Expand Down Expand Up @@ -889,6 +896,12 @@
"notAvailable": "Non disponibile",
"unknownDate": "Data sconosciuta",
"messageCopiedToClipboard": "Messaggio copiato negli appunti",
"textCopiedToClipboard": "{text} copiato negli appunti",
"@textCopiedToClipboard": {
"placeholders": {
"text": { "type": "String" }
}
},

"@_comment_about_screen_new": "About Screen New Strings",
"documentation": "Documentazione",
Expand Down Expand Up @@ -1170,6 +1183,12 @@
"error": { "type": "String" }
}
},
"messageSent": "Messaggio inviato: {message}",
"@messageSent": {
"placeholders": {
"message": { "type": "String" }
}
},
"waitingAdminAssignmentInput": "In attesa dell'assegnazione dell'amministratore...",
"typeYourMessage": "Scrivi il tuo messaggio...",

Expand Down Expand Up @@ -1266,7 +1285,25 @@
"imageDecryptionError": "Errore nella decrittazione dell'immagine",
"imageNotAvailable": "Immagine non disponibile",
"couldNotOpenFile": "Impossibile aprire il file",
"couldNotOpenFileWithMessage": "Impossibile aprire il file: {message}",
"@couldNotOpenFileWithMessage": {
"placeholders": {
"message": { "type": "String" }
}
},
"errorOpeningFile": "Errore nell'apertura del file",
"errorOpeningFileWithMessage": "Errore nell'apertura del file: {error}",
"@errorOpeningFileWithMessage": {
"placeholders": {
"error": { "type": "String" }
}
},
"errorUploadingFile": "Errore nel caricamento del file: {error}",
"@errorUploadingFile": {
"placeholders": {
"error": { "type": "String" }
}
},

"@_comment_backup_reminder": "Promemoria backup account",
"backupAccountReminder": "Devi fare il backup del tuo account",
Expand Down
3 changes: 2 additions & 1 deletion lib/shared/widgets/clickable_text_widget.dart
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ import 'package:flutter/gestures.dart';
import 'package:flutter/material.dart';
import 'package:flutter/services.dart';
import 'package:mostro_mobile/core/app_theme.dart';
import 'package:mostro_mobile/generated/l10n.dart';
import 'package:mostro_mobile/shared/utils/snack_bar_helper.dart';

class ClickableText extends StatefulWidget {
Expand Down Expand Up @@ -38,7 +39,7 @@ class _ClickableTextState extends State<ClickableText> {
void _handleTap() async {
SnackBarHelper.showTopSnackBar(
context,
'${widget.leftText} ${widget.clickableText} copied to clipboard',
S.of(context)!.textCopiedToClipboard(widget.clickableText),
duration: const Duration(seconds: 2),
);
await Clipboard.setData(ClipboardData(text: widget.clickableText));
Comment thread
Catrya marked this conversation as resolved.
Expand Down
3 changes: 2 additions & 1 deletion lib/shared/widgets/exchange_rate_widget.dart
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ import 'package:flutter/material.dart';
import 'package:flutter_riverpod/flutter_riverpod.dart';
import 'package:intl/intl.dart';
import 'package:mostro_mobile/core/app_theme.dart';
import 'package:mostro_mobile/generated/l10n.dart';
import 'package:mostro_mobile/shared/providers/exchange_service_provider.dart';
import 'package:mostro_mobile/shared/utils/snack_bar_helper.dart';

Expand Down Expand Up @@ -48,7 +49,7 @@ class ExchangeRateWidget extends ConsumerWidget {
// Trigger refresh for this specific currency
SnackBarHelper.showTopSnackBar(
context,
'Refreshing exchange rate...',
S.of(context)!.refreshingExchangeRate,
duration: const Duration(seconds: 1),
);
ref
Expand Down