From f53fcce17c0b2791f56ebcdd268275d641f6fa62 Mon Sep 17 00:00:00 2001 From: Reckless_Satoshi Date: Thu, 19 May 2022 07:43:04 -0700 Subject: [PATCH] Translate failure reasons --- frontend/src/components/TradeBox.js | 15 ++++++++------- frontend/src/locales/en.json | 10 +++++++++- frontend/src/locales/es.json | 10 +++++++++- 3 files changed, 26 insertions(+), 9 deletions(-) diff --git a/frontend/src/components/TradeBox.js b/frontend/src/components/TradeBox.js index 18d5c56c..b1d04594 100644 --- a/frontend/src/components/TradeBox.js +++ b/frontend/src/components/TradeBox.js @@ -1164,7 +1164,7 @@ handleRatingRobosatsChange=(e)=>{ return( - {"Failure reason:"} + {t("Failure reason:")} {t(this.props.data.failure_reason)} @@ -1183,14 +1183,15 @@ handleRatingRobosatsChange=(e)=>{ {t("Lightning Routing Failed")} - - - {t("Your invoice has expired or more than 3 payment attempts have been made.")} - - {this.props.data.failure_reason ? this.failureReason():null} + + + {t("Your invoice has expired or more than 3 payment attempts have been made. Submit a new invoice.")} + + + {this.compatibleWalletsButton()} @@ -1231,7 +1232,7 @@ handleRatingRobosatsChange=(e)=>{ {this.props.data.failure_reason ? this.failureReason():null} - + {t("RoboSats will try to pay your invoice 3 times every 5 minutes. If it keeps failing, you will be able to submit a new invoice. Check whether you have enough inbound liquidity. Remember that lightning nodes must be online in order to receive payments.")} diff --git a/frontend/src/locales/en.json b/frontend/src/locales/en.json index df891cc3..afee9c76 100644 --- a/frontend/src/locales/en.json +++ b/frontend/src/locales/en.json @@ -325,7 +325,7 @@ "RoboSats is trying to pay your lightning invoice. Remember that lightning nodes must be online in order to receive payments.":"RoboSats is trying to pay your lightning invoice. Remember that lightning nodes must be online in order to receive payments.", "Retrying!":"Retrying!", "Lightning Routing Failed":"Lightning Routing Failed", - "Your invoice has expired or more than 3 payment attempts have been made.":"Your invoice has expired or more than 3 payment attempts have been made.", + "Your invoice has expired or more than 3 payment attempts have been made. Submit a new invoice.":"Your invoice has expired or more than 3 payment attempts have been made. Submit a new invoice.", "Check the list of compatible wallets":"Check the list of compatible wallets", "RoboSats will try to pay your invoice 3 times every 5 minutes. If it keeps failing, you will be able to submit a new invoice. Check whether you have enough inbound liquidity. Remember that lightning nodes must be online in order to receive payments.":"RoboSats will try to pay your invoice 3 times every 5 minutes. If it keeps failing, you will be able to submit a new invoice. Check whether you have enough inbound liquidity. Remember that lightning nodes must be online in order to receive payments.", "Next attempt in":"Next attempt in", @@ -357,6 +357,14 @@ "Unpause Order":"Unpause Order", "You risk losing your bond if you do not lock the collateral. Total time to available is {{deposit_timer_hours}}h {{deposit_timer_minutes}}m.":"You risk losing your bond if you do not lock the collateral. Total time to available is {{deposit_timer_hours}}h {{deposit_timer_minutes}}m.", "See Compatible Wallets":"See Compatible Wallets", + "Failure reason:":"Failure reason:", + "Payment isn't failed (yet)":"Payment isn't failed (yet)", + "There are more routes to try, but the payment timeout was exceeded.":"There are more routes to try, but the payment timeout was exceeded.", + "All possible routes were tried and failed permanently. Or there were no routes to the destination at all.":"All possible routes were tried and failed permanently. Or there were no routes to the destination at all.", + "A non-recoverable error has occurred.":"A non-recoverable error has occurred.", + "Payment details are incorrect (unknown hash, invalid amount or invalid final CLTV delta).":"Payment details are incorrect (unknown hash, invalid amount or invalid final CLTV delta).", + "Insufficient unlocked balance in RoboSats' node.":"Insufficient unlocked balance in RoboSats' node.", + "INFO DIALOG - InfoDiagog.js":"App information and clarifications and terms of use", "Close":"Close", diff --git a/frontend/src/locales/es.json b/frontend/src/locales/es.json index 82a6ca3c..3d671c28 100644 --- a/frontend/src/locales/es.json +++ b/frontend/src/locales/es.json @@ -324,7 +324,7 @@ "RoboSats is trying to pay your lightning invoice. Remember that lightning nodes must be online in order to receive payments.": "RoboSats está intentando pagar tu factura de Lightning. Recuerda que los nodos Lightning deben estar en línea para recibir pagos.", "Retrying!": "¡Reintentando!", "Lightning Routing Failed": "Fallo en el enrutamiento de Lightning", - "Your invoice has expired or more than 3 payment attempts have been made.": "Tu factura ha expirado o se han hecho más de 3 intentos de pago.", + "Your invoice has expired or more than 3 payment attempts have been made. Submit a new invoice.": "Tu factura ha expirado o se han hecho más de 3 intentos de pago. Entrega una nueva factura.", "Check the list of compatible wallets": "Mira la lista de carteras compatibles", "RoboSats will try to pay your invoice 3 times every 5 minutes. If it keeps failing, you will be able to submit a new invoice. Check whether you have enough inbound liquidity. Remember that lightning nodes must be online in order to receive payments.": "RoboSats intentará pagar tu factura 3 veces cada 5 minutos. Si sigue fallando, podrás presentar una nueva factura. Comprueba si tienes suficiente liquidez entrante. Recuerda que los nodos de Lightning tienen que estar en línea para poder recibir pagos.", "Next attempt in": "Próximo intento en", @@ -356,6 +356,14 @@ "Unpause Order":"Activar Orden", "You risk losing your bond if you do not lock the collateral. Total time to available is {{deposit_timer_hours}}h {{deposit_timer_minutes}}m.":"Si no bloqueas el colateral te arriesgas a perder tu fianza. Dispones en total de {{deposit_timer_hours}}h {{deposit_timer_minutes}}m.", "See Compatible Wallets":"Ver billeteras compatibles", + "Failure reason:":"Razón del fallo:", + "Payment isn't failed (yet)":"El pago no ha fallado aún", + "There are more routes to try, but the payment timeout was exceeded.":"Quedan rutas por probar, pero el tiempo máximo del intento ha sido excedido.", + "All possible routes were tried and failed permanently. Or there were no routes to the destination at all.":"Todas las rutas posibles han sido probadas y han fallado de forma permanente. O quizá no había ninguna ruta.", + "A non-recoverable error has occurred.":"A non-recoverable error has occurred.", + "Payment details are incorrect (unknown hash, invalid amount or invalid final CLTV delta).":"Los detalles del pago son incorrectos (hash desconocido, cantidad inválida o CLTV delta final inválido).", + "Insufficient unlocked balance in RoboSats' node.":"Balance libre de ser usado en el nodo de RoboSats insuficiente.", + "INFO DIALOG - InfoDiagog.js": "App information and clarifications and terms of use", "Close": "Cerrar",