From b227df7c7cf94a79f322836ed6c9c66067fa8f0a Mon Sep 17 00:00:00 2001 From: Reckless_Satoshi <90936742+Reckless-Satoshi@users.noreply.github.com> Date: Fri, 21 Apr 2023 11:10:47 +0000 Subject: [PATCH] Improve preliminary sats summary, add taker satoshis (#429) * Improve preliminary sats summary, add taker satoshis * Collect phrases --- api/views.py | 4 + .../components/OrderDetails/TakeButton.tsx | 167 +++++++++------ .../src/components/OrderDetails/index.tsx | 194 +++++++++--------- frontend/src/components/TradeBox/index.tsx | 1 + frontend/src/models/Order.model.ts | 3 +- frontend/src/utils/computeSats.ts | 4 +- frontend/static/locales/ca.json | 6 +- frontend/static/locales/cs.json | 6 +- frontend/static/locales/de.json | 6 +- frontend/static/locales/en.json | 6 +- frontend/static/locales/es.json | 6 +- frontend/static/locales/eu.json | 6 +- frontend/static/locales/fr.json | 6 +- frontend/static/locales/it.json | 6 +- frontend/static/locales/pl.json | 6 +- frontend/static/locales/pt.json | 6 +- frontend/static/locales/ru.json | 6 +- frontend/static/locales/sv.json | 6 +- frontend/static/locales/th.json | 6 +- frontend/static/locales/zh-SI.json | 6 +- frontend/static/locales/zh-TR.json | 6 +- 21 files changed, 274 insertions(+), 189 deletions(-) diff --git a/api/views.py b/api/views.py index 588cd30d..b4572829 100644 --- a/api/views.py +++ b/api/views.py @@ -267,11 +267,14 @@ class OrderView(viewsets.ViewSet): # 3.b) Non participants can view details (but only if PUB) if not data["is_participant"] and order.status == Order.Status.PUB: + data["price_now"], data["premium_now"] = Logics.price_and_premium_now(order) + data["satoshis_now"] = Logics.satoshis_now(order) return Response(data, status=status.HTTP_200_OK) # 4) If order is between public and WF2 if order.status >= Order.Status.PUB and order.status < Order.Status.WF2: data["price_now"], data["premium_now"] = Logics.price_and_premium_now(order) + data["satoshis_now"] = Logics.satoshis_now(order) # 4. a) If maker and Public/Paused, add premium percentile # num similar orders, and maker information to enable telegram notifications. @@ -294,6 +297,7 @@ class OrderView(viewsets.ViewSet): data["is_fiat_sent"] = order.is_fiat_sent data["is_disputed"] = order.is_disputed data["ur_nick"] = request.user.username + data["satoshis_now"] = order.last_satoshis # Add whether hold invoices are LOCKED (ACCEPTED) # Is there a maker bond? If so, True if locked, False otherwise diff --git a/frontend/src/components/OrderDetails/TakeButton.tsx b/frontend/src/components/OrderDetails/TakeButton.tsx index 25657699..0852af4b 100644 --- a/frontend/src/components/OrderDetails/TakeButton.tsx +++ b/frontend/src/components/OrderDetails/TakeButton.tsx @@ -1,4 +1,4 @@ -import React, { useState, useMemo } from 'react'; +import React, { useState, useMemo, useEffect } from 'react'; import { useTranslation } from 'react-i18next'; import { Dialog, @@ -13,6 +13,7 @@ import { TextField, useTheme, Typography, + FormHelperText, } from '@mui/material'; import Countdown from 'react-countdown'; @@ -23,12 +24,14 @@ import { apiClient } from '../../services/api'; import { Order } from '../../models'; import { ConfirmationDialog } from '../Dialogs'; import { LoadingButton } from '@mui/lab'; +import { computeSats, pn } from '../../utils'; interface TakeButtonProps { order: Order; setOrder: (state: Order) => void; baseUrl: string; hasRobot: boolean; + info: Info; } interface OpenDialogsProps { @@ -37,7 +40,7 @@ interface OpenDialogsProps { } const closeAll = { inactiveMaker: false, confirmation: false }; -const TakeButton = ({ order, setOrder, baseUrl, hasRobot }: TakeButtonProps): JSX.Element => { +const TakeButton = ({ order, setOrder, baseUrl, hasRobot, info }: TakeButtonProps): JSX.Element => { const { t } = useTranslation(); const theme = useTheme(); @@ -45,6 +48,25 @@ const TakeButton = ({ order, setOrder, baseUrl, hasRobot }: TakeButtonProps): JS const [badRequest, setBadRequest] = useState(''); const [loadingTake, setLoadingTake] = useState(false); const [open, setOpen] = useState(closeAll); + const [satoshis, setSatoshis] = useState(''); + + const satoshisNow = () => { + const tradeFee = info.taker_fee; + const defaultRoutingBudget = 0.001; + const btc_now = order.satoshis_now / 100000000; + const rate = order.amount ? order.amount / btc_now : order.max_amount / btc_now; + const satoshis = computeSats({ + amount: Number(takeAmount), + routingBudget: order.is_buyer ? defaultRoutingBudget : 0, + fee: tradeFee, + rate: rate, + }); + return satoshis; + }; + + useEffect(() => { + setSatoshis(satoshisNow()); + }, [order.satoshis_now, takeAmount]); const currencyCode: string = order.currency == 1000 ? 'Sats' : currencies[`${order.currency}`]; @@ -139,74 +161,91 @@ const TakeButton = ({ order, setOrder, baseUrl, hasRobot }: TakeButtonProps): JS }, }} > - - - - - - - -
+ + + -
- - {t('Take Order')} - -
+
-
-
- + +
- {t('Take Order')} - -
+ +
+ + {t('Take Order')} + +
+
+
+
+ + {t('Take Order')} + +
+
+ {satoshis != '0' && satoshis != '' && !invalidTakeAmount ? ( + + + {order.type === 1 + ? t('You will receive {{satoshis}} Sats (Approx)', { satoshis }) + : t('You will send {{satoshis}} Sats (Approx)', { satoshis })} + + + ) : null} ); diff --git a/frontend/src/components/OrderDetails/index.tsx b/frontend/src/components/OrderDetails/index.tsx index 4f21a20d..3e3052f3 100644 --- a/frontend/src/components/OrderDetails/index.tsx +++ b/frontend/src/components/OrderDetails/index.tsx @@ -57,7 +57,7 @@ const OrderDetails = ({ const theme = useTheme(); const currencyCode: string = currencies[`${order.currency}`]; - const [showSwapDetails, setShowSwapDetails] = useState(false); + const [showSatsDetails, setShowSatsDetails] = useState(false); const amountString = useMemo(() => { // precision to 8 decimal if currency is BTC otherwise 4 decimals @@ -71,11 +71,13 @@ const OrderDetails = ({ ) + ' Sats' ); } else { - return amountToString( - order.amount, - order.amount ? false : order.has_range, - order.min_amount, - order.max_amount, + return ( + amountToString( + order.amount, + order.amount ? false : order.has_range, + order.min_amount, + order.max_amount, + ) + ` ${currencyCode}` ); } }, [order.currency, order.amount, order.min_amount, order.max_amount, order.has_range]); @@ -141,70 +143,76 @@ const OrderDetails = ({ } }; - const swap = useMemo(() => { + const satsSummary = useMemo(() => { let send: string = ''; let receive: string = ''; - let swapSats: string = ''; + let sats: string = ''; - const isSwapIn = (order.type == 0 && order.is_maker) || (order.type == 1 && !order.is_maker); + const isBuyer = (order.type == 0 && order.is_maker) || (order.type == 1 && !order.is_maker); const tradeFee = order.is_maker ? info.maker_fee : info.taker_fee; const defaultRoutingBudget = 0.001; - if (order.currency === 1000) { - if (isSwapIn) { - if (order.amount) { - swapSats = computeSats({ - amount: order.amount, - premium: order.premium, - fee: -tradeFee, - routingBudget: defaultRoutingBudget, - }); - } else { - const swapMin = computeSats({ - amount: Number(order.min_amount), - premium: order.premium, - fee: -tradeFee, - routingBudget: defaultRoutingBudget, - }); - const swapMax = computeSats({ - amount: Number(order.max_amount), - premium: order.premium, - fee: -tradeFee, - routingBudget: defaultRoutingBudget, - }); - swapSats = `${swapMin}-${swapMax}`; - } - send = t('You send via {{method}} {{amount}}', { - amount: amountString, - method: order.payment_method, - }); - receive = t('You receive via Lightning {{amount}} Sats (routing budget may vary)', { - amount: swapSats, + const btc_now = order.satoshis_now / 100000000; + const rate = order.amount ? order.amount / btc_now : order.max_amount / btc_now; + + if (isBuyer) { + if (order.amount) { + sats = computeSats({ + amount: order.amount, + fee: -tradeFee, + routingBudget: defaultRoutingBudget, + rate: rate, }); } else { - if (order.amount) { - swapSats = computeSats({ amount: order.amount, premium: order.premium, fee: tradeFee }); - } else { - const swapMin = computeSats({ - amount: order.min_amount, - premium: order.premium, - fee: tradeFee, - }); - const swapMax = computeSats({ - amount: order.max_amount, - premium: order.premium, - fee: tradeFee, - }); - swapSats = `${swapMin}-${swapMax}`; - } - send = t('You send via Lightning {{amount}} Sats', { amount: swapSats }); - receive = t('You receive via {{method}} {{amount}}', { - amount: amountString, - method: order.payment_method, + const min = computeSats({ + amount: Number(order.min_amount), + fee: -tradeFee, + routingBudget: defaultRoutingBudget, + rate: rate, }); + const max = computeSats({ + amount: Number(order.max_amount), + fee: -tradeFee, + routingBudget: defaultRoutingBudget, + rate: rate, + }); + sats = `${min}-${max}`; } + send = t('You send via {{method}} {{amount}}', { + amount: amountString, + method: order.payment_method, + currencyCode, + }); + receive = t('You receive via Lightning {{amount}} Sats (Approx)', { + amount: sats, + }); + } else { + if (order.amount) { + sats = computeSats({ + amount: order.amount, + fee: tradeFee, + rate: rate, + }); + } else { + const min = computeSats({ + amount: order.min_amount, + fee: tradeFee, + rate: rate, + }); + const max = computeSats({ + amount: order.max_amount, + fee: tradeFee, + rate: rate, + }); + sats = `${min}-${max}`; + } + send = t('You send via Lightning {{amount}} Sats (Approx)', { amount: sats }); + receive = t('You receive via {{method}} {{amount}}', { + amount: amountString, + method: order.payment_method, + }); } - return { send, receive, isSwapIn }; - }, [order.currency, order.amount, order.has_range]); + return { send, receive }; + }, [order.currency, order.satoshis_now, order.amount, order.has_range]); return ( @@ -286,40 +294,36 @@ const OrderDetails = ({ primary={amountString} secondary={order.amount ? 'Amount' : 'Amount Range'} /> - {order.currency === 1000 ? ( - - setShowSwapDetails(!showSwapDetails)}> - {showSwapDetails ? : } - - - ) : null} + + setShowSatsDetails(!showSatsDetails)}> + {showSatsDetails ? : } + + - {order.currency === 1000 ? ( - - - - - - - {swap.send} - + + + + + + + {satsSummary.send} + - - - - - {swap.receive} - - - - ) : null} + + + + + {satsSummary.receive} + + + @@ -428,7 +432,13 @@ const OrderDetails = ({ {!order.is_participant ? ( - + ) : ( <> diff --git a/frontend/src/components/TradeBox/index.tsx b/frontend/src/components/TradeBox/index.tsx index b3a78a30..a24bb0cf 100644 --- a/frontend/src/components/TradeBox/index.tsx +++ b/frontend/src/components/TradeBox/index.tsx @@ -383,6 +383,7 @@ const TradeBox = ({ ); }; bondStatus = 'hide'; // To do: show bond status according to expiry message. + break; // 6: 'Waiting for trade collateral and buyer invoice' case 6: diff --git a/frontend/src/models/Order.model.ts b/frontend/src/models/Order.model.ts index 50956e78..86046d83 100644 --- a/frontend/src/models/Order.model.ts +++ b/frontend/src/models/Order.model.ts @@ -26,7 +26,7 @@ export interface Order { expires_at: Date; type: number; currency: number; - amount: string; + amount: number; has_range: boolean; min_amount: string; max_amount: string; @@ -46,6 +46,7 @@ export interface Order { maker_status: 'Active' | 'Seen recently' | 'Inactive'; taker_status: 'Active' | 'Seen recently' | 'Inactive'; price_now: number | undefined; + satoshis_now: number; premium_now: number | undefined; premium_percentile: number; num_similar_orders: number; diff --git a/frontend/src/utils/computeSats.ts b/frontend/src/utils/computeSats.ts index 26578f8d..ca870531 100644 --- a/frontend/src/utils/computeSats.ts +++ b/frontend/src/utils/computeSats.ts @@ -2,14 +2,14 @@ import { pn } from './prettyNumbers'; interface computeSatsProps { amount: number; - premium: number; + premium?: number; fee: number; routingBudget?: number; rate?: number; } const computeSats = ({ amount, - premium, + premium = 0, fee, routingBudget = 0, rate = 1, diff --git a/frontend/static/locales/ca.json b/frontend/static/locales/ca.json index 82e51d0e..aca72cd4 100644 --- a/frontend/static/locales/ca.json +++ b/frontend/static/locales/ca.json @@ -95,8 +95,8 @@ "Penalty lifted, good to go!": "Sanció revocada, som-hi!", "You cannot take an order yet! Wait {{timeMin}}m {{timeSec}}s": "Encara no pots prendre cap ordre! Espera {{timeMin}}m {{timeSec}}s", "You send via {{method}} {{amount}}": "Envies via {{method}} {{amount}}", - "You receive via Lightning {{amount}} Sats (routing budget may vary)": "Reps via Lightning {{amount}} Sats (routing budget may vary)", - "You send via Lightning {{amount}} Sats": "Envies via Lightning {{amount}} Sats", + "You receive via Lightning {{amount}} Sats (Approx)": "You receive via Lightning {{amount}} Sats (Approx)", + "You send via Lightning {{amount}} Sats (Approx)": "You send via Lightning {{amount}} Sats (Approx)", "You receive via {{method}} {{amount}}": "Reps via {{method}} {{amount}}", "Order maker": "Creador", "Order taker": "Prenedor", @@ -123,6 +123,8 @@ "Enter amount of fiat to exchange for bitcoin": "Introdueix la suma de fiat a canviar per bitcoin", "Amount {{currencyCode}}": "Suma {{currencyCode}}", "You must specify an amount first": "Primer has d'especificar la suma", + "You will receive {{satoshis}} Sats (Approx)": "You will receive {{satoshis}} Sats (Approx)", + "You will send {{satoshis}} Sats (Approx)": "You will send {{satoshis}} Sats (Approx)", "#20": "Phrases in components/Dialogs/StoreToken.tsx", "Store your robot token": "Guarda el teu token", "You might need to recover your robot avatar in the future: store it safely. You can simply copy it into another application.": "Pot ser que necessitis recuperar el teu avatar robot al futur: fes còpia de seguretat del token. Pots simplement copiar-ho a una altra aplicació.", diff --git a/frontend/static/locales/cs.json b/frontend/static/locales/cs.json index 02b8c15b..076565e0 100644 --- a/frontend/static/locales/cs.json +++ b/frontend/static/locales/cs.json @@ -95,8 +95,8 @@ "Penalty lifted, good to go!": "Pokuta zrušena, lze pokračovat!", "You cannot take an order yet! Wait {{timeMin}}m {{timeSec}}s": "Nabídku nemůžeš zatím příjmout! Počkej {{timeMin}}m {{timeSec}}s", "You send via {{method}} {{amount}}": "You send via {{method}} {{amount}}", - "You receive via Lightning {{amount}} Sats (routing budget may vary)": "You receive via Lightning {{amount}} Sats (routing budget may vary)", - "You send via Lightning {{amount}} Sats": "You send via Lightning {{amount}} Sats", + "You receive via Lightning {{amount}} Sats (Approx)": "You receive via Lightning {{amount}} Sats (Approx)", + "You send via Lightning {{amount}} Sats (Approx)": "You send via Lightning {{amount}} Sats (Approx)", "You receive via {{method}} {{amount}}": "You receive via {{method}} {{amount}}", "Order maker": "Tvůrce nabídky", "Order taker": "Příjemce nabídky", @@ -123,6 +123,8 @@ "Enter amount of fiat to exchange for bitcoin": "Zadej částku fiat, kterou chceš vyměnit za bitcoin. ", "Amount {{currencyCode}}": "Částka {{currencyCode}}", "You must specify an amount first": "Nejprve je třeba zadat částku", + "You will receive {{satoshis}} Sats (Approx)": "You will receive {{satoshis}} Sats (Approx)", + "You will send {{satoshis}} Sats (Approx)": "You will send {{satoshis}} Sats (Approx)", "#20": "Phrases in components/Dialogs/StoreToken.tsx", "Store your robot token": "Ulož si svůj robot token", "You might need to recover your robot avatar in the future: store it safely. You can simply copy it into another application.": "Ulož si bezpečně svůj token jednoduše zkopírováním do jiné aplikace. V budoucnu ho možná budeš potřebovat v případě obnovy robota.", diff --git a/frontend/static/locales/de.json b/frontend/static/locales/de.json index 93f60b7b..e389482b 100644 --- a/frontend/static/locales/de.json +++ b/frontend/static/locales/de.json @@ -95,8 +95,8 @@ "Penalty lifted, good to go!": "Die Strafe ist aufgehoben, es kann losgehen!", "You cannot take an order yet! Wait {{timeMin}}m {{timeSec}}s": "Du kannst noch keine Order annehmen! Warte {{timeMin}}m {{timeSec}}s", "You send via {{method}} {{amount}}": "You send via {{method}} {{amount}}", - "You receive via Lightning {{amount}} Sats (routing budget may vary)": "You receive via Lightning {{amount}} Sats (routing budget may vary)", - "You send via Lightning {{amount}} Sats": "You send via Lightning {{amount}} Sats", + "You receive via Lightning {{amount}} Sats (Approx)": "You receive via Lightning {{amount}} Sats (Approx)", + "You send via Lightning {{amount}} Sats (Approx)": "You send via Lightning {{amount}} Sats (Approx)", "You receive via {{method}} {{amount}}": "You receive via {{method}} {{amount}}", "Order maker": "Order-Maker", "Order taker": "Order-Taker", @@ -123,6 +123,8 @@ "Enter amount of fiat to exchange for bitcoin": "Fiat-Betrag für den Umtausch in Bitcoin eingeben", "Amount {{currencyCode}}": "Betrag {{currencyCode}}", "You must specify an amount first": "Du musst zuerst einen Betrag angeben", + "You will receive {{satoshis}} Sats (Approx)": "You will receive {{satoshis}} Sats (Approx)", + "You will send {{satoshis}} Sats (Approx)": "You will send {{satoshis}} Sats (Approx)", "#20": "Phrases in components/Dialogs/StoreToken.tsx", "Store your robot token": "Speicher Roboter-Token", "You might need to recover your robot avatar in the future: store it safely. You can simply copy it into another application.": "Vielleicht musst du deinen Roboter-Avatar in Zukunft wiederherstellen: Bewahre ihn sicher auf. Du kannst ihn einfach in eine andere Anwendung kopieren.", diff --git a/frontend/static/locales/en.json b/frontend/static/locales/en.json index d5e8c202..b9229f5e 100644 --- a/frontend/static/locales/en.json +++ b/frontend/static/locales/en.json @@ -95,8 +95,8 @@ "Penalty lifted, good to go!": "Penalty lifted, good to go!", "You cannot take an order yet! Wait {{timeMin}}m {{timeSec}}s": "You cannot take an order yet! Wait {{timeMin}}m {{timeSec}}s", "You send via {{method}} {{amount}}": "You send via {{method}} {{amount}}", - "You receive via Lightning {{amount}} Sats (routing budget may vary)": "You receive via Lightning {{amount}} Sats (routing budget may vary)", - "You send via Lightning {{amount}} Sats": "You send via Lightning {{amount}} Sats", + "You receive via Lightning {{amount}} Sats (Approx)": "You receive via Lightning {{amount}} Sats (Approx)", + "You send via Lightning {{amount}} Sats (Approx)": "You send via Lightning {{amount}} Sats (Approx)", "You receive via {{method}} {{amount}}": "You receive via {{method}} {{amount}}", "Order maker": "Order maker", "Order taker": "Order taker", @@ -123,6 +123,8 @@ "Enter amount of fiat to exchange for bitcoin": "Enter amount of fiat to exchange for bitcoin", "Amount {{currencyCode}}": "Amount {{currencyCode}}", "You must specify an amount first": "You must specify an amount first", + "You will receive {{satoshis}} Sats (Approx)": "You will receive {{satoshis}} Sats (Approx)", + "You will send {{satoshis}} Sats (Approx)": "You will send {{satoshis}} Sats (Approx)", "#20": "Phrases in components/Dialogs/StoreToken.tsx", "Store your robot token": "Store your robot token", "You might need to recover your robot avatar in the future: store it safely. You can simply copy it into another application.": "You might need to recover your robot avatar in the future: store it safely. You can simply copy it into another application.", diff --git a/frontend/static/locales/es.json b/frontend/static/locales/es.json index a997878d..a8afdf42 100644 --- a/frontend/static/locales/es.json +++ b/frontend/static/locales/es.json @@ -95,8 +95,8 @@ "Penalty lifted, good to go!": "Sanción revocada, ¡Vamos!", "You cannot take an order yet! Wait {{timeMin}}m {{timeSec}}s": "¡No puedes tomar una orden aún! Espera {{timeMin}}m {{timeSec}}s", "You send via {{method}} {{amount}}": "You send via {{method}} {{amount}}", - "You receive via Lightning {{amount}} Sats (routing budget may vary)": "You receive via Lightning {{amount}} Sats (routing budget may vary)", - "You send via Lightning {{amount}} Sats": "You send via Lightning {{amount}} Sats", + "You receive via Lightning {{amount}} Sats (Approx)": "You receive via Lightning {{amount}} Sats (Approx)", + "You send via Lightning {{amount}} Sats (Approx)": "You send via Lightning {{amount}} Sats (Approx)", "You receive via {{method}} {{amount}}": "You receive via {{method}} {{amount}}", "Order maker": "Creador", "Order taker": "Tomador", @@ -123,6 +123,8 @@ "Enter amount of fiat to exchange for bitcoin": "Introduce el monto de fiat a cambiar por bitcoin", "Amount {{currencyCode}}": "Monto {{currencyCode}}", "You must specify an amount first": "Primero debes especificar el monto", + "You will receive {{satoshis}} Sats (Approx)": "You will receive {{satoshis}} Sats (Approx)", + "You will send {{satoshis}} Sats (Approx)": "You will send {{satoshis}} Sats (Approx)", "#20": "Phrases in components/Dialogs/StoreToken.tsx", "Store your robot token": "Guarda el token", "You might need to recover your robot avatar in the future: store it safely. You can simply copy it into another application.": "Puede que necesites recuperar tu robot avatar en el futuro: haz una copia de seguridad del token. Puedes simplemente copiarlo en otra aplicación.", diff --git a/frontend/static/locales/eu.json b/frontend/static/locales/eu.json index 234f7b77..685414cb 100644 --- a/frontend/static/locales/eu.json +++ b/frontend/static/locales/eu.json @@ -95,8 +95,8 @@ "Penalty lifted, good to go!": "Zigorra kendu da, prest!", "You cannot take an order yet! Wait {{timeMin}}m {{timeSec}}s": "Oraindik ezin duzu eskaerarik hartu! Itxaron{{timeMin}}m {{timeSec}}s", "You send via {{method}} {{amount}}": "You send via {{method}} {{amount}}", - "You receive via Lightning {{amount}} Sats (routing budget may vary)": "You receive via Lightning {{amount}} Sats (routing budget may vary)", - "You send via Lightning {{amount}} Sats": "You send via Lightning {{amount}} Sats", + "You receive via Lightning {{amount}} Sats (Approx)": "You receive via Lightning {{amount}} Sats (Approx)", + "You send via Lightning {{amount}} Sats (Approx)": "You send via Lightning {{amount}} Sats (Approx)", "You receive via {{method}} {{amount}}": "You receive via {{method}} {{amount}}", "Order maker": "Eskaera egile", "Order taker": "Eskaera hartzaile", @@ -123,6 +123,8 @@ "Enter amount of fiat to exchange for bitcoin": "Sartu bitcongatik aldatu nahi duzun fiat kopurua", "Amount {{currencyCode}}": "Kopurua {{currencyCode}}", "You must specify an amount first": "Aurrena kopurua zehaztu behar duzu", + "You will receive {{satoshis}} Sats (Approx)": "You will receive {{satoshis}} Sats (Approx)", + "You will send {{satoshis}} Sats (Approx)": "You will send {{satoshis}} Sats (Approx)", "#20": "Phrases in components/Dialogs/StoreToken.tsx", "Store your robot token": "Gorde zure robot tokena", "You might need to recover your robot avatar in the future: store it safely. You can simply copy it into another application.": "Zure robot avatarra berreskuratu nahi izango duzu: gorde seguru. Beste aplikazio batean kopia dezakezu", diff --git a/frontend/static/locales/fr.json b/frontend/static/locales/fr.json index 3043edbb..c80eb6d6 100644 --- a/frontend/static/locales/fr.json +++ b/frontend/static/locales/fr.json @@ -95,8 +95,8 @@ "Penalty lifted, good to go!": "Pénalité levée, vous pouvez y aller!", "You cannot take an order yet! Wait {{timeMin}}m {{timeSec}}s": "Vous ne pouvez pas encore prendre un ordre! Attendez {{timeMin}}m {{timeSec}}s", "You send via {{method}} {{amount}}": "You send via {{method}} {{amount}}", - "You receive via Lightning {{amount}} Sats (routing budget may vary)": "You receive via Lightning {{amount}} Sats (routing budget may vary)", - "You send via Lightning {{amount}} Sats": "You send via Lightning {{amount}} Sats", + "You receive via Lightning {{amount}} Sats (Approx)": "You receive via Lightning {{amount}} Sats (Approx)", + "You send via Lightning {{amount}} Sats (Approx)": "You send via Lightning {{amount}} Sats (Approx)", "You receive via {{method}} {{amount}}": "You receive via {{method}} {{amount}}", "Order maker": "Createur d'ordre", "Order taker": "Preneur d'ordre", @@ -123,6 +123,8 @@ "Enter amount of fiat to exchange for bitcoin": "Saisissez le montant de fiat à échanger contre des bitcoins", "Amount {{currencyCode}}": "Montant {{currencyCode}}", "You must specify an amount first": "Vous devez d'abord spécifier un montant", + "You will receive {{satoshis}} Sats (Approx)": "You will receive {{satoshis}} Sats (Approx)", + "You will send {{satoshis}} Sats (Approx)": "You will send {{satoshis}} Sats (Approx)", "#20": "Phrases in components/Dialogs/StoreToken.tsx", "Store your robot token": "Store your robot token", "You might need to recover your robot avatar in the future: store it safely. You can simply copy it into another application.": "You might need to recover your robot avatar in the future: store it safely. You can simply copy it into another application.", diff --git a/frontend/static/locales/it.json b/frontend/static/locales/it.json index aca44249..a3f48f10 100644 --- a/frontend/static/locales/it.json +++ b/frontend/static/locales/it.json @@ -95,8 +95,8 @@ "Penalty lifted, good to go!": "Penalità rimossa, partiamo!", "You cannot take an order yet! Wait {{timeMin}}m {{timeSec}}s": "Non puoi ancora accettare un ordine! Aspetta {{timeMin}}m {{timeSec}}s", "You send via {{method}} {{amount}}": "You send via {{method}} {{amount}}", - "You receive via Lightning {{amount}} Sats (routing budget may vary)": "You receive via Lightning {{amount}} Sats (routing budget may vary)", - "You send via Lightning {{amount}} Sats": "You send via Lightning {{amount}} Sats", + "You receive via Lightning {{amount}} Sats (Approx)": "You receive via Lightning {{amount}} Sats (Approx)", + "You send via Lightning {{amount}} Sats (Approx)": "You send via Lightning {{amount}} Sats (Approx)", "You receive via {{method}} {{amount}}": "You receive via {{method}} {{amount}}", "Order maker": "Offerente", "Order taker": "Acquirente", @@ -123,6 +123,8 @@ "Enter amount of fiat to exchange for bitcoin": "Inserisci la quantità di fiat da scambiare per bitcoin", "Amount {{currencyCode}}": "Quantità {{currencyCode}}", "You must specify an amount first": "Devi prima specificare una quantità", + "You will receive {{satoshis}} Sats (Approx)": "You will receive {{satoshis}} Sats (Approx)", + "You will send {{satoshis}} Sats (Approx)": "You will send {{satoshis}} Sats (Approx)", "#20": "Phrases in components/Dialogs/StoreToken.tsx", "Store your robot token": "Salva il tuo gettone", "You might need to recover your robot avatar in the future: store it safely. You can simply copy it into another application.": "Potresti aver bisogno di recuperare il tuo Robottino in futuro: custodiscilo con cura. Puoi semplicemente copiarlo in un'altra applicazione.", diff --git a/frontend/static/locales/pl.json b/frontend/static/locales/pl.json index d0cbf1da..89494287 100644 --- a/frontend/static/locales/pl.json +++ b/frontend/static/locales/pl.json @@ -95,8 +95,8 @@ "Penalty lifted, good to go!": "Kara zniesiona, gotowe!", "You cannot take an order yet! Wait {{timeMin}}m {{timeSec}}s": "Nie możesz jeszcze przyjąć zamówienia! Czekać {{timeMin}}m {{timeSec}}s", "You send via {{method}} {{amount}}": "You send via {{method}} {{amount}}", - "You receive via Lightning {{amount}} Sats (routing budget may vary)": "You receive via Lightning {{amount}} Sats (routing budget may vary)", - "You send via Lightning {{amount}} Sats": "You send via Lightning {{amount}} Sats", + "You receive via Lightning {{amount}} Sats (Approx)": "You receive via Lightning {{amount}} Sats (Approx)", + "You send via Lightning {{amount}} Sats (Approx)": "You send via Lightning {{amount}} Sats (Approx)", "You receive via {{method}} {{amount}}": "You receive via {{method}} {{amount}}", "Order maker": "Ekspres zamówienia", "Order taker": "Przyjmujący zamówienia", @@ -123,6 +123,8 @@ "Enter amount of fiat to exchange for bitcoin": "Wprowadź kwotę fiat do wymiany na bitcoin", "Amount {{currencyCode}}": "Ilość {{currencyCode}}", "You must specify an amount first": "Musisz najpierw określić kwotę", + "You will receive {{satoshis}} Sats (Approx)": "You will receive {{satoshis}} Sats (Approx)", + "You will send {{satoshis}} Sats (Approx)": "You will send {{satoshis}} Sats (Approx)", "#20": "Phrases in components/Dialogs/StoreToken.tsx", "Store your robot token": "Store your robot token", "You might need to recover your robot avatar in the future: store it safely. You can simply copy it into another application.": "You might need to recover your robot avatar in the future: store it safely. You can simply copy it into another application.", diff --git a/frontend/static/locales/pt.json b/frontend/static/locales/pt.json index 1534362e..03e3197e 100644 --- a/frontend/static/locales/pt.json +++ b/frontend/static/locales/pt.json @@ -95,8 +95,8 @@ "Penalty lifted, good to go!": "Penalidade levantada, pronto!", "You cannot take an order yet! Wait {{timeMin}}m {{timeSec}}s": "Você ainda não pode fazer um pedido! Espere {{timeMin}}m {{timeSec}}s", "You send via {{method}} {{amount}}": "You send via {{method}} {{amount}}", - "You receive via Lightning {{amount}} Sats (routing budget may vary)": "You receive via Lightning {{amount}} Sats (routing budget may vary)", - "You send via Lightning {{amount}} Sats": "You send via Lightning {{amount}} Sats", + "You receive via Lightning {{amount}} Sats (Approx)": "You receive via Lightning {{amount}} Sats (Approx)", + "You send via Lightning {{amount}} Sats (Approx)": "You send via Lightning {{amount}} Sats (Approx)", "You receive via {{method}} {{amount}}": "You receive via {{method}} {{amount}}", "Order maker": "Criar ordem", "Order taker": "Tomar ordem", @@ -123,6 +123,8 @@ "Enter amount of fiat to exchange for bitcoin": "Insira o valor da moeda fiduciária para trocar por bitcoin", "Amount {{currencyCode}}": "Quantidade {{currencyCode}}", "You must specify an amount first": "Você deve especificar um valor primeiro", + "You will receive {{satoshis}} Sats (Approx)": "You will receive {{satoshis}} Sats (Approx)", + "You will send {{satoshis}} Sats (Approx)": "You will send {{satoshis}} Sats (Approx)", "#20": "Phrases in components/Dialogs/StoreToken.tsx", "Store your robot token": "Armazene seu token de robô", "You might need to recover your robot avatar in the future: store it safely. You can simply copy it into another application.": "Você pode precisar recuperar seu avatar de robô no futuro: armazene-o com segurança. Você pode simplesmente copiá-lo em outra aplicação.", diff --git a/frontend/static/locales/ru.json b/frontend/static/locales/ru.json index bb951d01..063ba659 100644 --- a/frontend/static/locales/ru.json +++ b/frontend/static/locales/ru.json @@ -95,8 +95,8 @@ "Penalty lifted, good to go!": "Пенальти сняты, поехали!", "You cannot take an order yet! Wait {{timeMin}}m {{timeSec}}s": "Вы ещё не можете взять ордер! Подождите {{timeMin}}м {{timeSec}}с", "You send via {{method}} {{amount}}": "You send via {{method}} {{amount}}", - "You receive via Lightning {{amount}} Sats (routing budget may vary)": "You receive via Lightning {{amount}} Sats (routing budget may vary)", - "You send via Lightning {{amount}} Sats": "You send via Lightning {{amount}} Sats", + "You receive via Lightning {{amount}} Sats (Approx)": "You receive via Lightning {{amount}} Sats (Approx)", + "You send via Lightning {{amount}} Sats (Approx)": "You send via Lightning {{amount}} Sats (Approx)", "You receive via {{method}} {{amount}}": "You receive via {{method}} {{amount}}", "Order maker": "Мейкер ордера", "Order taker": "Тейкер ордера", @@ -123,6 +123,8 @@ "Enter amount of fiat to exchange for bitcoin": "Введите количество фиата для обмена на Биткойн", "Amount {{currencyCode}}": "Сумма {{currencyCode}}", "You must specify an amount first": "Сначала необходимо указать сумму", + "You will receive {{satoshis}} Sats (Approx)": "You will receive {{satoshis}} Sats (Approx)", + "You will send {{satoshis}} Sats (Approx)": "You will send {{satoshis}} Sats (Approx)", "#20": "Phrases in components/Dialogs/StoreToken.tsx", "Store your robot token": "Сохранить токен робота", "You might need to recover your robot avatar in the future: store it safely. You can simply copy it into another application.": "В будущем Вам может понадобиться восстановить аватар робота: сохраните его в безопасном месте. Вы можете просто скопировать его в другое приложение.", diff --git a/frontend/static/locales/sv.json b/frontend/static/locales/sv.json index cdb3f90c..ece1e0d1 100644 --- a/frontend/static/locales/sv.json +++ b/frontend/static/locales/sv.json @@ -95,8 +95,8 @@ "Penalty lifted, good to go!": "Straff upphävt, bara att köra!", "You cannot take an order yet! Wait {{timeMin}}m {{timeSec}}s": "Du kan inte ta en order ännu! Vänta {{timeMin}}m {{timeSec}}s", "You send via {{method}} {{amount}}": "You send via {{method}} {{amount}}", - "You receive via Lightning {{amount}} Sats (routing budget may vary)": "You receive via Lightning {{amount}} Sats (routing budget may vary)", - "You send via Lightning {{amount}} Sats": "You send via Lightning {{amount}} Sats", + "You receive via Lightning {{amount}} Sats (Approx)": "You receive via Lightning {{amount}} Sats (Approx)", + "You send via Lightning {{amount}} Sats (Approx)": "You send via Lightning {{amount}} Sats (Approx)", "You receive via {{method}} {{amount}}": "You receive via {{method}} {{amount}}", "Order maker": "Ordermaker", "Order taker": "Ordertaker", @@ -123,6 +123,8 @@ "Enter amount of fiat to exchange for bitcoin": "Ange summa fiat att handla bitcoin för", "Amount {{currencyCode}}": "Summa {{currencyCode}}", "You must specify an amount first": "Du måste ange en summa först", + "You will receive {{satoshis}} Sats (Approx)": "You will receive {{satoshis}} Sats (Approx)", + "You will send {{satoshis}} Sats (Approx)": "You will send {{satoshis}} Sats (Approx)", "#20": "Phrases in components/Dialogs/StoreToken.tsx", "Store your robot token": "Spara din robottoken", "You might need to recover your robot avatar in the future: store it safely. You can simply copy it into another application.": "Du kan behöva återställa din robotavatar i framtiden; förvara den säkert. Du kan kopiera den till en annan applikation.", diff --git a/frontend/static/locales/th.json b/frontend/static/locales/th.json index 949ddf08..09726e6b 100644 --- a/frontend/static/locales/th.json +++ b/frontend/static/locales/th.json @@ -95,8 +95,8 @@ "Penalty lifted, good to go!": "สามารถซื้อขายได้แล้ว!", "You cannot take an order yet! Wait {{timeMin}}m {{timeSec}}s": "คุณยังไม่สามารถดำเนินรายการได้! รออีก {{timeMin}} นาที {{timeSec}} วินาที", "You send via {{method}} {{amount}}": "You send via {{method}} {{amount}}", - "You receive via Lightning {{amount}} Sats (routing budget may vary)": "You receive via Lightning {{amount}} Sats (routing budget may vary)", - "You send via Lightning {{amount}} Sats": "You send via Lightning {{amount}} Sats", + "You receive via Lightning {{amount}} Sats (Approx)": "You receive via Lightning {{amount}} Sats (Approx)", + "You send via Lightning {{amount}} Sats (Approx)": "You send via Lightning {{amount}} Sats (Approx)", "You receive via {{method}} {{amount}}": "You receive via {{method}} {{amount}}", "Order maker": "maker ของรายการ", "Order taker": "taker ของรายการ", @@ -123,6 +123,8 @@ "Enter amount of fiat to exchange for bitcoin": "ระบุจำนวนเงินเฟียตที่จะแลกเปลี่ยนกับ bitcoin", "Amount {{currencyCode}}": "จำนวน {{currencyCode}}", "You must specify an amount first": "คุณต้องระบุจำนวนก่อน", + "You will receive {{satoshis}} Sats (Approx)": "You will receive {{satoshis}} Sats (Approx)", + "You will send {{satoshis}} Sats (Approx)": "You will send {{satoshis}} Sats (Approx)", "#20": "Phrases in components/Dialogs/StoreToken.tsx", "Store your robot token": "เก็บรักษา token โรบอทของคุณ", "You might need to recover your robot avatar in the future: store it safely. You can simply copy it into another application.": "คุณอาจต้องใช้โรบอทอีกในอนาคตจึงควรเก็บรักษามันไว้ให้ดี คุณสามารถคัดลอกมันไปเก็บไว้ในแอพพลิเคชั่นอื่นๆได้อย่างง่ายดาย", diff --git a/frontend/static/locales/zh-SI.json b/frontend/static/locales/zh-SI.json index 5351b3c4..79e90407 100644 --- a/frontend/static/locales/zh-SI.json +++ b/frontend/static/locales/zh-SI.json @@ -95,8 +95,8 @@ "Penalty lifted, good to go!": "罚单已解除,没问题了!", "You cannot take an order yet! Wait {{timeMin}}m {{timeSec}}s": "你暂时还不能吃单!请等{{timeMin}}分 {{timeSec}}秒", "You send via {{method}} {{amount}}": "你通过{{method}}发送{{amount}}", - "You receive via Lightning {{amount}} Sats (routing budget may vary)": "你通过闪电接收{{amount}}聪(路由预算可能会有所差异)", - "You send via Lightning {{amount}} Sats": "你通过闪电发送{amount}}聪", + "You receive via Lightning {{amount}} Sats (Approx)": "You receive via Lightning {{amount}} Sats (Approx)", + "You send via Lightning {{amount}} Sats (Approx)": "You send via Lightning {{amount}} Sats (Approx)", "You receive via {{method}} {{amount}}": "你通过{{method}}接收{{amount}}", "Order maker": "订单挂单方", "Order taker": "订单吃单方", @@ -123,6 +123,8 @@ "Enter amount of fiat to exchange for bitcoin": "输入以兑换比特币的法币金额", "Amount {{currencyCode}}": "{{currencyCode}}金额", "You must specify an amount first": "你必须先指定金额", + "You will receive {{satoshis}} Sats (Approx)": "You will receive {{satoshis}} Sats (Approx)", + "You will send {{satoshis}} Sats (Approx)": "You will send {{satoshis}} Sats (Approx)", "#20": "Phrases in components/Dialogs/StoreToken.tsx", "Store your robot token": "存储你的机器人令牌", "You might need to recover your robot avatar in the future: store it safely. You can simply copy it into another application.": "你将来可能需要恢复你的机器人头像:安全地存放它。你可以轻松地将其复制到另一个应用程序中。", diff --git a/frontend/static/locales/zh-TR.json b/frontend/static/locales/zh-TR.json index d76ad65d..755e4c5e 100644 --- a/frontend/static/locales/zh-TR.json +++ b/frontend/static/locales/zh-TR.json @@ -95,8 +95,8 @@ "Penalty lifted, good to go!": "罰單已解除, 沒問題了!", "You cannot take an order yet! Wait {{timeMin}}m {{timeSec}}s": "你暫時還不能吃單!請等{{timeMin}}分 {{timeSec}}秒", "You send via {{method}} {{amount}}": "你通過{{method}}發送{{amount}}", - "You receive via Lightning {{amount}} Sats (routing budget may vary)": "你通過閃電接收{{amount}}聰(路由預算可能會有所差異)", - "You send via Lightning {{amount}} Sats": "你通過閃電發送{{amount}}聰", + "You receive via Lightning {{amount}} Sats (Approx)": "You receive via Lightning {{amount}} Sats (Approx)", + "You send via Lightning {{amount}} Sats (Approx)": "You send via Lightning {{amount}} Sats (Approx)", "You receive via {{method}} {{amount}}": "你通過{{method}}接收{{amount}}", "Order maker": "訂單掛單方", "Order taker": "訂單吃單方", @@ -123,6 +123,8 @@ "Enter amount of fiat to exchange for bitcoin": "輸入以兌換比特幣的法幣金額", "Amount {{currencyCode}}": "{{currencyCode}} 金額", "You must specify an amount first": "你必須先指定金額", + "You will receive {{satoshis}} Sats (Approx)": "You will receive {{satoshis}} Sats (Approx)", + "You will send {{satoshis}} Sats (Approx)": "You will send {{satoshis}} Sats (Approx)", "#20": "Phrases in components/Dialogs/StoreToken.tsx", "Store your robot token": "存儲你的機器人令牌", "You might need to recover your robot avatar in the future: store it safely. You can simply copy it into another application.": "你將來可能需要恢復你的機器人頭像:安全地存放它。你可以輕鬆地將其複製到另一個應用程序中。",